diff --git a/lean/OAI/Analysis/Commutator/BiprodLinkIntertwining.lean b/lean/OAI/Analysis/Commutator/BiprodLinkIntertwining.lean new file mode 100644 index 0000000000000000000000000000000000000000..f8b21e7e3fb4fb21600ccf3185937b6d2a69b019 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/BiprodLinkIntertwining.lean @@ -0,0 +1,35 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.BiprodLinkColumn + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison.BiprodLinkColumn + +open HilbertBiprod PartialIsometryOrder + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable {A : Type*} [CStarAlgebra A] + +lemma component_diagonal_intertwines + (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + (h : Set.centralizer (Set.centralizer (Set.range (diagHom φ ψ)))=Set.range (diagHom φ ψ)) + (v : Intertwiner (BicommutantRange.ofStarHom (diagHom φ ψ) h).commutant) (a : A) : + (component _ v).comp (φ a)=(ψ a).comp (component _ v) := by + apply component_intertwines _ φ ψ v a + have hm : star v.val ∈ ((BicommutantRange.ofStarHom (diagHom φ ψ) h).commutant : Set _) := + (BicommutantRange.ofStarHom (diagHom φ ψ) h).commutant.star_mem' v.mem + rw [VonNeumannAlgebra.coe_commutant] at hm + exact hm _ ⟨a,rfl⟩ + +end Kadison.BiprodLinkColumn +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/BlockDilationBound.lean b/lean/OAI/Analysis/Commutator/BlockDilationBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..ddc0b8ef754f7e7ee5ab65b018ff0cf2f351378f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/BlockDilationBound.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.BalancedSymmetry +import OAI.Analysis.Commutator.MatrixEntryWOT + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.OperatorAmplification + +variable {A H ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] [Fintype ι] + +local instance blockDilationIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance blockDilationFinTwoDecidableEq : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +lemma entry_starHom_matrixRepresentation (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (X : CStarMatrix ι ι A) (i j : ι) : + entry ι (CyclicColumns.matrixRepresentation ρ X) i j=ρ (X i j) := by + ext x + change CyclicColumns.matrixAction (fun i j => ρ (X i j)) (single ι j x) i=ρ (X i j) x + simp only [CyclicColumns.matrixAction_apply, single_apply] + simp only [apply_ite, map_zero, Finset.sum_ite_eq',Finset.mem_univ,ite_true] + +lemma entry_diagonal_commutator (T : H →L[ℂ] H) + (X : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (i j : ι) : + entry ι (diagonal (H:=H) ι T*X-X*diagonal (H:=H) ι T) i j= + T*entry ι X i j-entry ι X i j*T := by + ext v + simp [entry_apply,mul_apply_eq_comp,diagonal_single] + +lemma commutator_entry_norm_le (T : H →L[ℂ] H) + (X : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (i j : ι) : + ‖T*entry ι X i j-entry ι X i j*T‖≤ + ‖diagonal (H:=H) ι T*X-X*diagonal (H:=H) ι T‖ := by + rw [←entry_diagonal_commutator] + exact norm_entry_le ι _ i j + +theorem balanced_symmetry_commutator_dominates + (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (Y : H →L[ℂ] H) (X : A) : + ‖Y*ρ X-ρ X*Y‖≤ + ‖diagonal (H:=H) (Fin 2) Y* + CyclicColumns.matrixRepresentation ρ (BalancedDilation.symmetry X)- + CyclicColumns.matrixRepresentation ρ (BalancedDilation.symmetry X)* + diagonal (H:=H) (Fin 2) Y‖ := by + have he : entry (Fin 2) (CyclicColumns.matrixRepresentation ρ (BalancedDilation.symmetry X)) 0 1=ρ X := by + rw [entry_starHom_matrixRepresentation] + rfl + simpa only [he] using commutator_entry_norm_le Y + (CyclicColumns.matrixRepresentation ρ (BalancedDilation.symmetry X)) (0:Fin 2) 1 + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/BoundedPositiveSequence.lean b/lean/OAI/Analysis/Commutator/BoundedPositiveSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..eb5ad7dd17b25effd86dd81ea24b93fc47cd8d0c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/BoundedPositiveSequence.lean @@ -0,0 +1,43 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BoundedContinuousFunction + +namespace Kadison.BoundedPositiveSequence + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {ι : Type*} [TopologicalSpace ι] [DiscreteTopology ι] + +theorem squareRoot (d : ι →ᵇ A) (hd : ∀ i, 0≤d i) : + ∃ z : ι →ᵇ A, d=star z*z := by + let z : ι →ᵇ A := BoundedContinuousFunction.ofNormedAddCommGroupDiscrete + (fun i => CFC.sqrt (d i)) (Real.sqrt ‖d‖) (fun i => by + rw [CFC.norm_sqrt _ (hd i)] + exact Real.sqrt_le_sqrt (d.norm_coe_le_norm i)) + refine ⟨z,?_⟩ + apply BoundedContinuousFunction.ext + intro i + change d i=star (CFC.sqrt (d i))*CFC.sqrt (d i) + rw [(CFC.sqrt_nonneg (d i)).star_eq,CFC.sqrt_mul_sqrt_self _ (hd i)] + +lemma map_nonneg {B : Type*} [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + (φ : (ι →ᵇ A) →⋆ₐ[ℂ] B) (d : ι →ᵇ A) (hd : ∀ i, 0≤d i) : 0≤φ d := by + obtain ⟨z,rfl⟩ := squareRoot d hd + simpa only [map_mul,map_star] using star_mul_self_nonneg (φ z) + +end Kadison.BoundedPositiveSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/BoundedSequenceClosed.lean b/lean/OAI/Analysis/Commutator/BoundedSequenceClosed.lean new file mode 100644 index 0000000000000000000000000000000000000000..6fa215d4141f5c8f0c1ddcf1868603eb8035833b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/BoundedSequenceClosed.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertSequence +import OAI.Analysis.Commutator.UltrafilterDiagonal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter UniformSpace Completion + +namespace Kadison.HilbertSequence + +variable {A H : Type*} [NormedAddCommGroup A] [NormedSpace ℂ A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +variable (ω : Ultrafilter ℕ) (v : A →L[ℂ] H) + +def mapPre (a : ℕ →ᵇ A) : Pre ω H := + ⟨BoundedContinuousFunction.comp v v.lipschitzWith a⟩ + +def mapVector (a : ℕ →ᵇ A) : Space ω H := (mapPre ω v a : Space ω H) + +omit [InnerProductSpace ℂ H] in +@[simp] lemma seq_sub' (a b : Pre ω H) (i : ℕ) : (a-b).seq i=a.seq i-b.seq i := rfl + +lemma norm_map_difference_tendsto (a b : ℕ →ᵇ A) : + Tendsto (fun i => ‖v (a i)-v (b i)‖) (ω : Filter ℕ) + (𝓝 ‖mapVector ω v a-mapVector ω v b‖) := by + simpa only [mapVector,←Completion.coe_sub,Completion.norm_coe,seq_sub',mapPre,BoundedContinuousFunction.comp_apply] using + tendsto_norm ω H (mapPre ω v a-mapPre ω v b) + +theorem bounded_image_isClosed (hω : (ω : Filter ℕ)≤atTop) + (K : Set A) (C : ℝ) (hK : ∀ a∈K, ‖a‖≤C) : + IsClosed {x : Space ω H | ∃ a : ℕ →ᵇ A, (∀ i, a i∈K) ∧ mapVector ω v a=x} := by + classical + apply isClosed_of_closure_subset + intro x hx + let ε (n : ℕ) : ℝ := (1/2:ℝ)^n + have hε (n : ℕ) : 0<ε n := pow_pos (by norm_num) n + have hanti {j k : ℕ} (hjk : j≤k) : ε k≤ε j := + pow_le_pow_of_le_one (by norm_num) (by norm_num) hjk + have hn (n : ℕ) : ∃ a : ℕ →ᵇ A, (∀ i, a i∈K) ∧ ‖mapVector ω v a-x‖<ε n := by + obtain ⟨y,⟨a,ha,rfl⟩,hy⟩ := Metric.mem_closure_iff.mp hx (ε n) (hε n) + exact ⟨a,ha,by simpa only [dist_eq_norm,norm_sub_rev] using hy⟩ + choose f hf he using hn + have hpair (j k : ℕ) (hjk : j≤k) : + ∀ᶠ i in (ω : Filter ℕ), ‖v (f j i)-v (f k i)‖≤3*ε j := by + have hlt : ‖mapVector ω v (f j)-mapVector ω v (f k)‖<3*ε j := by + have h := norm_sub_le_norm_sub_add_norm_sub (mapVector ω v (f j)) x (mapVector ω v (f k)) + rw [norm_sub_rev x] at h + have hj := he j + have hk := he k + have hk' := hanti hjk + have hp := hε j + linarith + exact (norm_map_difference_tendsto ω v (f j) (f k)).eventually (gt_mem_nhds hlt) |>.mono + (fun _ hi => le_of_lt hi) + let p (n i : ℕ) : Prop := ∀ j≤n, ∀ k≤n, j≤k → ‖v (f j i)-v (f k i)‖≤3*ε j + have hp (n : ℕ) : ∀ᶠ i in (ω : Filter ℕ), p n i := by + have hh : ∀ᶠ i in (ω : Filter ℕ), ∀ j∈Finset.range (n+1), + ∀ k∈Finset.range (n+1), j≤k → ‖v (f j i)-v (f k i)‖≤3*ε j := by + apply (eventually_all_finset (Finset.range (n+1))).mpr + intro j _ + apply (eventually_all_finset (Finset.range (n+1))).mpr + intro k _ + by_cases hjk : j≤k + · exact (hpair j k hjk).mono (fun _ hi _ => hi) + · exact Eventually.of_forall (fun _ hi => (hjk hi).elim) + filter_upwards [hh] with i hi + intro j hj k hk hjk + exact hi j (Finset.mem_range.mpr (by omega)) k (Finset.mem_range.mpr (by omega)) hjk + obtain ⟨d,hd,hreq⟩ := UltrafilterDiagonal.depth hω p hp + let a : ℕ →ᵇ A := BoundedContinuousFunction.mkOfDiscrete (fun i => f (d i/2) i) (2*C) + (fun i j => (dist_le_norm_add_norm _ _).trans (by + have hi := hK _ (hf (d i/2) i) + have hj := hK _ (hf (d j/2) j) + linarith)) + have ha (i : ℕ) : a i∈K := hf (d i/2) i + have hnorm (j : ℕ) : ‖mapVector ω v a-mapVector ω v (f j)‖≤3*ε j := by + apply le_of_tendsto (norm_map_difference_tendsto ω v a (f j)) + filter_upwards [hd.eventually (eventually_ge_atTop (2*j+2))] with i hi + have hleft : j≤d i/2 := by omega + have hright : d i/2 4*ε j) atTop (𝓝 (0:ℝ)) := by + simpa only [mul_zero] using + (tendsto_const_nhds.mul (tendsto_pow_atTop_nhds_zero_of_lt_one + (by norm_num : (0:ℝ)≤1/2) (by norm_num : (1/2:ℝ)<1))) + have hz : ‖mapVector ω v a-x‖≤0 := ge_of_tendsto hlim (Eventually.of_forall hnorm') + exact ⟨a,ha,sub_eq_zero.mp (norm_le_zero_iff.mp hz)⟩ + +end Kadison.HilbertSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/BoundedWordPool.lean b/lean/OAI/Analysis/Commutator/BoundedWordPool.lean new file mode 100644 index 0000000000000000000000000000000000000000..79bd4f763843f1ccd6f7fa0984d2ffe511eaacb0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/BoundedWordPool.lean @@ -0,0 +1,46 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FinitePatching + +variable (I : Type*) [Fintype I] + +def listPool (N : ℕ) : Finset (List I) := by + classical + exact Finset.univ.biUnion (fun n : Fin (N+1) => + Finset.univ.image (fun f : Fin n → I => List.ofFn f)) + +lemma mem_listPool (N : ℕ) (l : List I) : l∈listPool I N ↔ l.length ≤ N := by + classical + constructor + · intro h + simp only [listPool,Finset.mem_biUnion,Finset.mem_univ,Finset.mem_image,true_and] at h + obtain ⟨n,f,rfl⟩ := h + simpa only [List.length_ofFn] using Nat.le_of_lt_succ n.isLt + · intro h + simp only [listPool,Finset.mem_biUnion,Finset.mem_univ,Finset.mem_image,true_and] + exact ⟨⟨l.length,Nat.lt_succ_of_le h⟩,l.get,List.ofFn_get l⟩ + +abbrev SmallList (N : ℕ) := ↥(listPool I N) + +def smallList {N : ℕ} (l : List I) (h : l.length ≤ N) : SmallList I N := + ⟨l,(mem_listPool I N l).mpr h⟩ + +lemma SmallList.length_le {N : ℕ} (l : SmallList I N) : l.val.length ≤ N := + (mem_listPool I N l.val).mp l.property + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CFCIntertwiner.lean b/lean/OAI/Analysis/Commutator/CFCIntertwiner.lean new file mode 100644 index 0000000000000000000000000000000000000000..7fda4830128e803c854b4fd5b81291429ce055e4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CFCIntertwiner.lean @@ -0,0 +1,66 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder ContinuousFunctionalCalculus + +namespace Kadison.CFCIntertwiner + +variable {A : Type*} [CStarAlgebra A] + +local instance : ContinuousFunctionalCalculus ℂ (A × A) IsStarNormal := + IsStarNormal.instContinuousFunctionalCalculus + +local instance : ContinuousFunctionalCalculus ℝ (A × A) IsSelfAdjoint := + IsSelfAdjoint.instContinuousFunctionalCalculus + +lemma semiconj_cfc (x a b : A) (ha : IsSelfAdjoint a) (hb : IsSelfAdjoint b) + (h : x*a=b*x) (f : ℝ → ℝ) (hf : Continuous f) : + x*cfc f a=cfc f b*x := by + have hab : IsSelfAdjoint (a,b) := Prod.ext ha hb + have hc : ∀ g : C(spectrum ℝ (a,b),ℝ), + x*(cfcHom hab g).1=(cfcHom hab g).2*x := by + intro g + induction g using ContinuousMap.induction_on_of_compact with + | const r => + change x*((cfcHom hab) (algebraMap ℝ _ r)).1=((cfcHom hab) (algebraMap ℝ _ r)).2*x + rw [AlgHomClass.commutes] + change x*algebraMap ℝ A r=algebraMap ℝ A r*x + exact (Algebra.commutes r x).symm + | id => simpa only [cfcHom_id] using h + | star_id => simpa only [map_star,cfcHom_id,Prod.fst_star,Prod.snd_star,ha.star_eq,hb.star_eq] using h + | add g k hg hk => simp only [map_add,Prod.fst_add,Prod.snd_add,mul_add,add_mul,hg,hk] + | mul g k hg hk => + simp only [map_mul,Prod.fst_mul,Prod.snd_mul] + calc + x*((cfcHom hab g).1*(cfcHom hab k).1)= + (x*(cfcHom hab g).1)*(cfcHom hab k).1 := (mul_assoc ..).symm + _=((cfcHom hab g).2*x)*(cfcHom hab k).1 := by rw [hg] + _=(cfcHom hab g).2*((cfcHom hab k).2*x) := by rw [mul_assoc,hk] + _=((cfcHom hab g).2*(cfcHom hab k).2)*x := (mul_assoc ..).symm + | frequently g hg => + have closed : IsClosed {k : C(spectrum ℝ (a,b),ℝ) | + x*(cfcHom hab k).1=(cfcHom hab k).2*x} := + isClosed_eq ((cfcHom_continuous hab).fst.const_mul x) + ((cfcHom_continuous hab).snd.mul_const x) + exact closed.mem_of_frequently_of_tendsto hg Filter.tendsto_id + have hh : x*(cfc f (a,b)).1=(cfc f (a,b)).2*x := by + rw [cfc_apply f (a,b) hab hf.continuousOn] + exact hc _ + rw [cfc_map_prod (S := ℂ) f a b hf.continuousOn hab ha hb] at hh + exact hh + +end Kadison.CFCIntertwiner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CFCTraceMoments.lean b/lean/OAI/Analysis/Commutator/CFCTraceMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..554736f2ebd00fd8c2ff4d1ae94e8ad4dbd871d1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CFCTraceMoments.lean @@ -0,0 +1,85 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder ContinuousFunctionalCalculus + +namespace Kadison.CFCTraceMoments + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +local instance : ContinuousFunctionalCalculus ℂ (A × A) IsStarNormal := + IsStarNormal.instContinuousFunctionalCalculus + +local instance : ContinuousFunctionalCalculus ℝ (A × A) IsSelfAdjoint := + IsSelfAdjoint.instContinuousFunctionalCalculus + +lemma trace_cfc_of_powers (τ : A →ₚ[ℂ] ℂ) (a b : A) + (ha : IsSelfAdjoint a) (hb : IsSelfAdjoint b) + (hpow : ∀ n : ℕ,τ (a^n)=τ (b^n)) (f : ℝ → ℝ) (hf : Continuous f) : + τ (cfc f a)=τ (cfc f b) := by + have hab : IsSelfAdjoint (a,b) := Prod.ext ha hb + have hpoly (p : Polynomial ℝ) : τ (Polynomial.aeval a p)=τ (Polynomial.aeval b p) := by + induction p using Polynomial.induction_on' with + | add p q hp hq => simp only [map_add,hp,hq] + | monomial n r => + simp only [Polynomial.aeval_monomial,Algebra.algebraMap_eq_smul_one,smul_mul_assoc,one_mul] + change τ.toLinearMap (r • a^n)=τ.toLinearMap (r • b^n) + rw [LinearMap.map_smul_of_tower,LinearMap.map_smul_of_tower] + exact congrArg (fun z : ℂ => r • z) (hpow n) + let S : Set C(spectrum ℝ (a,b),ℝ) := + {g | τ (cfcHom hab g).1=τ (cfcHom hab g).2} + have hS : IsClosed S := isClosed_eq + ((map_continuous τ).comp (cfcHom_continuous hab).fst) + ((map_continuous τ).comp (cfcHom_continuous hab).snd) + have hsub : (polynomialFunctions (spectrum ℝ (a,b)) : Set C(spectrum ℝ (a,b),ℝ))⊆S := by + rw [polynomialFunctions_coe] + rintro g ⟨p,rfl⟩ + change τ (cfcHom hab (Polynomial.toContinuousMapOnAlgHom (spectrum ℝ (a,b)) p)).1= + τ (cfcHom hab (Polynomial.toContinuousMapOnAlgHom (spectrum ℝ (a,b)) p)).2 + have he : cfcHom hab (Polynomial.toContinuousMapOnAlgHom (spectrum ℝ (a,b)) p)= + Polynomial.aeval (a,b) p := by + rw [← cfc_polynomial p (a,b) hab,cfc_apply p.eval (a,b) hab p.continuous.continuousOn] + rfl + rw [he,Polynomial.aeval_prod_apply] + exact hpoly p + have hd : closure (polynomialFunctions (spectrum ℝ (a,b)) : Set C(spectrum ℝ (a,b),ℝ))=Set.univ := by + rw [←Subalgebra.topologicalClosure_coe,polynomialFunctions.topologicalClosure] + rfl + have all : ∀ g : C(spectrum ℝ (a,b),ℝ),g∈S := + fun g => closure_minimal hsub hS (hd.symm ▸ Set.mem_univ g) + have hm : τ (cfc f (a,b)).1=τ (cfc f (a,b)).2 := by + rw [cfc_apply f (a,b) hab hf.continuousOn] + exact all _ + rw [cfc_map_prod (S := ℂ) f a b hf.continuousOn hab ha hb] at hm + exact hm + +omit [StarOrderedRing A] in +lemma trace_cyclic_powers (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (a b : A) (n : ℕ) : τ ((a*b)^n)=τ ((b*a)^n) := by + cases n with + | zero => simp + | succ n => + have h : SemiconjBy a (b*a) (a*b) := (mul_assoc a b a).symm + have hn := h.pow_right n + change a*(b*a)^n=(a*b)^n*a at hn + calc + τ ((a*b)^(n+1))=τ (((a*b)^n*a)*b) := by rw [pow_succ,mul_assoc] + _=τ ((a*(b*a)^n)*b) := by rw [hn] + _=τ ((b*a)^n*(b*a)) := by rw [mul_assoc,hτ a ((b*a)^n*b),mul_assoc] + _=τ ((b*a)^(n+1)) := by rw [pow_succ] + +end Kadison.CFCTraceMoments + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CStarContractiveLifts.lean b/lean/OAI/Analysis/Commutator/CStarContractiveLifts.lean new file mode 100644 index 0000000000000000000000000000000000000000..1e2d5ed94371ab517e11da0e8be9241a61fc2892 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CStarContractiveLifts.lean @@ -0,0 +1,108 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped CStarAlgebra + +namespace Kadison.CStarContractiveLifts + +def radial (t : ℝ) : ℝ := (Real.sqrt (max 1 |t|))⁻¹ + +lemma radial_continuous : Continuous radial := by + unfold radial + exact (continuous_const.max continuous_abs).sqrt.inv₀ (fun t => + ne_of_gt (Real.sqrt_pos.mpr (lt_of_lt_of_le zero_lt_one (le_max_left 1 |t|)))) + +lemma radial_eq_one {t : ℝ} (ht : |t|≤1) : radial t=1 := by + simp only [radial,max_eq_left ht,Real.sqrt_one,inv_one] + +lemma radial_square (t : ℝ) : radial t*radial t=(max 1 |t|)⁻¹ := by + rw [radial,←mul_inv,←pow_two,Real.sq_sqrt (zero_le_one.trans (le_max_left 1 |t|))] + +lemma radial_bound (t : ℝ) : ‖radial t * t * radial t‖≤1 := by + have hd : 0 < max 1 |t| := lt_of_lt_of_le zero_lt_one (le_max_left 1 |t|) + rw [show radial t*t*radial t=t*(radial t*radial t) by ring,radial_square, + Real.norm_eq_abs,abs_mul,abs_inv,abs_of_pos hd,←div_eq_mul_inv] + exact (div_le_one hd).mpr (le_max_right 1 |t|) + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +def clip (a : A) : A := a*cfc radial (star a*a) + +lemma clip_norm_le (a : A) : ‖clip a‖≤1 := by + have hs : IsSelfAdjoint (star a*a) := IsSelfAdjoint.star_mul_self a + have hk : IsSelfAdjoint (cfc radial (star a*a)) := cfc_predicate _ _ + have he : star (clip a)*clip a=cfc (fun t : ℝ => radial t*t*radial t) (star a*a) := by + rw [clip,star_mul,hk.star_eq] + calc + _=cfc radial (star a*a)*(star a*a)*cfc radial (star a*a) := by noncomm_ring + _=cfc radial (star a*a)*cfc (fun t : ℝ => t) (star a*a)*cfc radial (star a*a) := by + rw [cfc_id' ℝ _ hs] + _=_ := by + rw [←cfc_mul radial (fun t : ℝ => t) _ radial_continuous.continuousOn continuous_id.continuousOn, + ←cfc_mul (fun t : ℝ => radial t*t) radial _ + (radial_continuous.mul continuous_id).continuousOn radial_continuous.continuousOn] + have hn : ‖star (clip a)*clip a‖≤1 := by + rw [he] + exact norm_cfc_le zero_le_one (fun t _ => radial_bound t) + rw [CStarRing.norm_star_mul_self] at hn + nlinarith [norm_nonneg (clip a)] + +lemma clip_fix {a : A} (ha : ‖a‖≤1) : clip a=a := by + nontriviality A + have hn : ‖star a*a‖≤1 := by rw [CStarRing.norm_star_mul_self]; nlinarith [norm_nonneg a] + have he : cfc radial (star a*a)=1 := by + rw [cfc_congr (g := fun _ : ℝ => 1) (fun t ht => + radial_eq_one ((show |t|≤‖star a*a‖ from spectrum.norm_le_norm_of_mem ht).trans hn)), + cfc_const_one ℝ _ (IsSelfAdjoint.star_mul_self a)] + rw [clip,he,mul_one] + +lemma map_clip (φ : A →⋆ₐ[ℂ] B) (a : A) : φ (clip a)=clip (φ a) := by + rw [clip,map_mul,φ.map_cfc radial (star a*a) radial_continuous.continuousOn + (by fun_prop) (IsSelfAdjoint.star_mul_self a) + ((IsSelfAdjoint.star_mul_self a).map φ),map_mul,map_star] + rfl + +theorem contraction (φ : A →⋆ₐ[ℂ] B) {b : B} (hb : ‖b‖≤1) + (hr : b∈Set.range φ) : ∃ a : A, ‖a‖≤1 ∧ φ a=b := by + obtain ⟨a,rfl⟩ := hr + exact ⟨clip a,clip_norm_le a,by rw [map_clip,clip_fix hb]⟩ + +theorem norm_lift (φ : A →⋆ₐ[ℂ] B) {b : B} (hr : b∈Set.range φ) : + ∃ a : A, ‖a‖≤‖b‖ ∧ φ a=b := by + by_cases hb : b=0 + · exact ⟨0,by simp [hb],by simp [hb]⟩ + have hn : ‖b‖≠0 := norm_ne_zero_iff.mpr hb + obtain ⟨y,hy⟩ := hr + let z : ℂ := (‖b‖⁻¹:ℝ) + have hz : ‖z • b‖≤1 := by + rw [norm_smul,show ‖z‖=‖b‖⁻¹ by simp [z], + inv_mul_cancel₀ hn] + obtain ⟨x,hx,hex⟩ := contraction φ hz ⟨z • y,by rw [map_smul,hy]⟩ + refine ⟨(‖b‖:ℂ) • x,?_,?_⟩ + · rw [norm_smul,Complex.norm_real,Real.norm_of_nonneg (norm_nonneg b)] + exact (mul_le_mul_of_nonneg_left hx (norm_nonneg b)).trans_eq (mul_one _) + · rw [map_smul,hex,smul_smul] + have he : (‖b‖:ℂ)*z=1 := by + simp only [z,←Complex.ofReal_mul,mul_inv_cancel₀ hn,Complex.ofReal_one] + rw [he,one_smul] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma operator_norm_lift (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) {T : H →L[ℂ] H} + (hT : T∈Set.range φ) : ∃ a : A, ‖a‖≤‖T‖ ∧ φ a=T := norm_lift φ hT + +end Kadison.CStarContractiveLifts + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CStarRangeLifts.lean b/lean/OAI/Analysis/Commutator/CStarRangeLifts.lean new file mode 100644 index 0000000000000000000000000000000000000000..f2d11acae16f87d4f78e045a76f66b971496b112 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CStarRangeLifts.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyRational + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexStarModule CStarAlgebra + +namespace Kadison.CStarRangeLifts + +open Kaplansky ComplexStarModule + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +variable (φ : A →⋆ₐ[ℂ] B) + +theorem selfAdjoint_contraction {b : B} (hb : IsSelfAdjoint b) (hn : ‖b‖≤1) + (hr : b∈Set.range φ) : ∃ a : A, IsSelfAdjoint a ∧ ‖a‖≤1 ∧ φ a=b := by + obtain ⟨a,ha⟩ := hr + let a₀ : A := ℜ a + have ha₀ : IsSelfAdjoint a₀ := (ℜ a).property + have he : φ a₀=b := by rw [show a₀=(ℜ a:A) from rfl,map_realPart,ha,hb.coe_realPart] + refine ⟨clip (lift a₀),clip_selfAdjoint _,clip_norm_le _,?_⟩ + rw [clip,φ.map_cfc rationalClip (lift a₀) continuous_rationalClip.continuousOn + (by fun_prop) (lift_selfAdjoint _) ((lift_selfAdjoint a₀).map φ),lift, + φ.map_cfc rationalLift a₀ continuous_rationalLift.continuousOn (by fun_prop) ha₀ (ha₀.map φ),he] + exact clip_lift hb hn + +theorem contraction {b : B} (hn : ‖b‖≤1) (hr : b∈Set.range φ) : + ∃ a : A, ‖a‖≤2 ∧ φ a=b := by + obtain ⟨a,ha⟩ := hr + obtain ⟨x,hx,hnx,hex⟩ := selfAdjoint_contraction φ (ℜ b).property + ((realPart.norm_le b).trans hn) ⟨(ℜ a:A),by rw [map_realPart,ha]⟩ + obtain ⟨y,hy,hny,hey⟩ := selfAdjoint_contraction φ (ℑ b).property + ((imaginaryPart.norm_le b).trans hn) ⟨(ℑ a:A),by rw [map_imaginaryPart,ha]⟩ + refine ⟨x+Complex.I • y,?_,?_⟩ + · calc + _≤‖x‖+‖Complex.I • y‖ := norm_add_le _ _ + _=‖x‖+‖y‖ := by rw [norm_smul,Complex.norm_I,one_mul] + _≤2 := by linarith + · rw [map_add,map_smul,hex,hey,realPart_add_I_smul_imaginaryPart] + +end Kadison.CStarRangeLifts + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CbDerivation.lean b/lean/OAI/Analysis/Commutator/CbDerivation.lean new file mode 100644 index 0000000000000000000000000000000000000000..6aeae0892c09467ec7a2cb9758dcab2888f1345e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CbDerivation.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.Commutator.CbDilation +import OAI.Analysis.Commutator.FactorMetric +import OAI.Analysis.Commutator.GramBounds +import OAI.Analysis.Commutator.TriangularCb +import OAI.Analysis.Commutator.TriangularMetric + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.CbFactor + +open RectangularColumn CyclicColumns + +variable {A K F : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +local instance : NormedAddCommGroup (K →L[ℂ] F) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] F) := ContinuousLinearMap.toNormedSpace + +theorem rectangular_implementation (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) + {c : ℝ} (hc : 0≤c) + (hcb : ∀ (ι : Type) [Fintype ι] (X : CStarMatrix ι ι A), + ‖matrixAction (fun i j => D (X i j))‖≤c*‖X‖) : + ∃ V : K →L[ℂ] F,‖V‖≤(1+c)^2 ∧ ∀ a : A,D a=V.comp (σ a)-(lam a).comp V := by + cases subsingleton_or_nontrivial A with + | inl hA => + let := hA + refine ⟨0,by simp; positivity,?_⟩ + intro a + simp [Subsingleton.elim a 0] + | inr hA => + let := hA + let π := triangularHom σ lam D hD + have hp : 0<1+c := by linarith + have hπ : HasMatrixBound π.toLinearMap (1+c) := by + intro ι _ X + exact triangular_matrix_norm_le σ lam D hD hc (hcb ι) X + let ρ := representation π.toLinearMap (1+c) hp hπ + let V := leftOperator π.toLinearMap (1+c) hp hπ + let W := rightOperator π.toLinearMap (1+c) hp hπ + have hfactor : ∀ a : A,π a=V.adjoint.comp ((ρ a).comp W) := by + intro a + exact factorization π.toLinearMap (1+c) hp hπ a + let L := leftCompression ρ V W + have hLW : L.comp W=1 := leftCompression_right π ρ V W hfactor + have hint : ∀ a : A,(π a).comp L=L.comp (ρ a) := + leftCompression_intertwines π ρ V W hfactor + exact implementer_of_factor_metric σ lam D L W hLW + (gram_intertwines π ρ L hint) hp.le + (leftCompression_norm_le ρ V W (leftOperator_norm_le _ _ _ _)) + (rightOperator_norm_le _ _ _ _) + +end Kadison.CbFactor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CbDerivationQuantitative.lean b/lean/OAI/Analysis/Commutator/CbDerivationQuantitative.lean new file mode 100644 index 0000000000000000000000000000000000000000..485ffcf3c0f4e430f0e8b00b8e8634a3ebb50ed3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CbDerivationQuantitative.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.CbDerivation +import OAI.Analysis.Commutator.CyclicCbUnconditional + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.CbFactor + +open RectangularColumn CyclicColumns + +variable {A K F : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +local instance : NormedAddCommGroup (K →L[ℂ] F) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] F) := ContinuousLinearMap.toNormedSpace + +omit [CompleteSpace K] [CompleteSpace F] in +lemma matrixAction_smul {ι : Type*} [Fintype ι] (c : ℝ) (D : ι → ι → K →L[ℂ] F) : + matrixAction (fun i j => c • D i j)=c • matrixAction D := by + ext x i + simp [Finset.smul_sum] + +theorem rectangular_implementation_quantitative (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) + {c : ℝ} (hc : 0≤c) + (hcb : ∀ (ι : Type) [Fintype ι] (X : CStarMatrix ι ι A), + ‖matrixAction (fun i j => D (X i j))‖≤c*‖D‖*‖X‖) : + ∃ V : K →L[ℂ] F,‖V‖≤((1+c)^2)*‖D‖ ∧ ∀ a : A,D a=V.comp (σ a)-(lam a).comp V := by + by_cases hz : D=0 + · refine ⟨0,by simp [hz],?_⟩ + intro a + simp [hz] + have hd : 0<‖D‖ := norm_pos_iff.mpr hz + let Δ : A →L[ℂ] (K →L[ℂ] F) := ‖D‖⁻¹ • D + have hΔ : ∀ a b,Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b) := by + intro a b + simp only [Δ,smul_apply,hD,smul_add, + ContinuousLinearMap.smul_comp,ContinuousLinearMap.comp_smul] + have hnorm : ∀ (ι : Type) [Fintype ι] (X : CStarMatrix ι ι A), + ‖matrixAction (fun i j => Δ (X i j))‖≤c*‖X‖ := by + intro ι _ X + change ‖matrixAction (fun i j => ‖D‖⁻¹ • D (X i j))‖≤c*‖X‖ + rw [matrixAction_smul] + calc + _ ≤ ‖‖D‖⁻¹‖*‖matrixAction (fun i j => D (X i j))‖ := ContinuousLinearMap.opNorm_smul_le _ _ + _ ≤ ‖D‖⁻¹*(c*‖D‖*‖X‖) := by + rw [Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hd)] + exact mul_le_mul_of_nonneg_left (hcb ι X) (inv_nonneg.mpr hd.le) + _ = c*‖X‖ := by field_simp + obtain ⟨V,hV,himpl⟩ := rectangular_implementation σ lam Δ hΔ hc hnorm + refine ⟨‖D‖ • V,?_,?_⟩ + · exact (ContinuousLinearMap.opNorm_smul_le _ _).trans + ((mul_le_mul_of_nonneg_left hV (norm_nonneg (‖D‖))).trans_eq (by + rw [Real.norm_eq_abs,abs_of_nonneg (norm_nonneg D)]; ring)) + · intro a + have hh : ‖D‖ • Δ a=D a := by + simp only [Δ,smul_apply,smul_smul,mul_inv_cancel₀ hd.ne',one_smul] + rw [←hh,himpl,smul_sub,ContinuousLinearMap.smul_comp,ContinuousLinearMap.comp_smul] + +theorem cyclic_implementation (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) + (Ω : K) (hΩ : DenseRange (fun a : A => σ a Ω)) : + ∃ V : K →L[ℂ] F,‖V‖≤289*‖D‖ ∧ ∀ a : A,D a=V.comp (σ a)-(lam a).comp V := by + have h := rectangular_implementation_quantitative σ lam D hD (c:=16) (by norm_num) + (fun _ _ X => cyclic_matrix_bound_unconditional σ lam D hD Ω hΩ X) + norm_num at h + exact h + +end Kadison.CbFactor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CbDilation.lean b/lean/OAI/Analysis/Commutator/CbDilation.lean new file mode 100644 index 0000000000000000000000000000000000000000..255dbd0555d82afbad568e43d620f6309e2f36c7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CbDilation.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.PaulsenDilation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators CStarAlgebra + +namespace Kadison.CbFactor + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def HasMatrixBound (f : A →ₗ[ℂ] (H →L[ℂ] H)) (c : ℝ) : Prop := + ∀ (ι : Type) [Fintype ι] (X : CStarMatrix ι ι A),‖CStarMatrix.mapₗ f X‖≤c*‖X‖ + +lemma normalized_contracts (f : A →ₗ[ℂ] (H →L[ℂ] H)) {c : ℝ} (hc : 0 + let := hA + refine ⟨1,?_⟩ + intro a + simp [Subsingleton.elim a 0] + | inr hA => + let := hA + let ρ := representation π.toLinearMap c hc hπ + let V := leftOperator π.toLinearMap c hc hπ + let W := rightOperator π.toLinearMap c hc hπ + have hfactor : ∀ a : A,π a=V.adjoint.comp ((ρ a).comp W) := by + intro a + exact factorization π.toLinearMap c hc hπ a + let L := leftCompression ρ V W + have hLW : L.comp W=1 := leftCompression_right π ρ V W hfactor + have hint : ∀ a : A,(π a).comp L=L.comp (ρ a) := + leftCompression_intertwines π ρ V W hfactor + exact similarity_of_metric π (L.comp L.adjoint) (gram_strictlyPositive L W hLW) + (gram_intertwines π ρ L hint) + +end Kadison.CbFactor +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CenteredContractionDensity.lean b/lean/OAI/Analysis/Commutator/CenteredContractionDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..84b297d21cfe733665f9feab425b7b39ee782130 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CenteredContractionDensity.lean @@ -0,0 +1,48 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialConjugation +import OAI.Analysis.Commutator.TracialL2Tools + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.TracialL2 + +open TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) + +lemma exists_centered_contraction_dense_sequence [TopologicalSpace.SeparableSpace τ.GNS] : + ∃ x : ℕ → A, (∀ j,‖x j‖ ≤ 1) ∧ (∀ j,τ (x j)=0) ∧ + ∀ a : A,‖a‖ ≤ 1 → τ a=0 → ∀ ε : ℝ,0<ε → ∃ j,norm τ (a-x j)<ε := by + classical + let C := {a : A // ‖a‖ ≤ 1 ∧ τ a=0} + let S : Set τ.GNS := Set.range (fun a : C => algebraVector τ a.val) + have : Nonempty S := + ⟨⟨algebraVector τ 0,⟨⟨0,by simp⟩,rfl⟩⟩⟩ + obtain ⟨u,hu⟩ := TopologicalSpace.exists_dense_seq S + choose x hx using (fun n => (u n).property) + refine ⟨fun n => (x n).val,fun n => (x n).property.1,fun n => (x n).property.2,?_⟩ + intro a ha hc ε hε + obtain ⟨j,hj⟩ := hu.exists_dist_lt ⟨algebraVector τ a,⟨⟨a,ha,hc⟩,rfl⟩⟩ hε + refine ⟨j,?_⟩ + change dist (algebraVector τ a) (u j).val<ε at hj + rw [←hx j,dist_eq_norm,←map_sub] at hj + simpa only [algebraVector_apply,UniformSpace.Completion.norm_coe,norm] using hj + +end Kadison.TracialL2 + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CenteredSpace.lean b/lean/OAI/Analysis/Commutator/CenteredSpace.lean new file mode 100644 index 0000000000000000000000000000000000000000..42a3251f4c0fe147f4f1cb0e442221804e21c3ac --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CenteredSpace.lean @@ -0,0 +1,73 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +abbrev centeredSpace (Ω : E) : Submodule ℂ E := (ℂ ∙ Ω)ᗮ + +def center (Ω : E) : E →L[ℂ] centeredSpace Ω := + (centeredSpace Ω).orthogonalProjectionOnto + +lemma norm_center_le (Ω x : E) : ‖center Ω x‖ ≤ ‖x‖ := + (centeredSpace Ω).norm_orthogonalProjectionOnto_apply_le x + +lemma coe_center (Ω : E) (hΩ : ‖Ω‖ = 1) (x : E) : + (center Ω x : E) = x - inner ℂ Ω x • Ω := by + change (ℂ ∙ Ω)ᗮ.starProjection x = _ + rw [Submodule.starProjection_orthogonal_val, + Submodule.starProjection_unit_singleton ℂ hΩ] + +lemma center_vacuum (Ω : E) : center Ω Ω = 0 := by + apply Subtype.ext + change (ℂ ∙ Ω)ᗮ.starProjection Ω = (0 : E) + exact Submodule.starProjection_orthogonalComplement_singleton_eq_zero Ω + +lemma center_centered (Ω : E) (x : centeredSpace Ω) : center Ω (x : E) = x := + (centeredSpace Ω).orthogonalProjectionOnto_mem_subspace_eq_self x + +lemma denseRange_center {M : Type*} [TopologicalSpace M] (Ω : E) (v : M → E) + (hv : DenseRange v) : DenseRange (fun a => center Ω (v a)) := by + have hc : Function.Surjective (center Ω) := fun x => ⟨x, center_centered Ω x⟩ + exact hc.denseRange.comp hv (center Ω).continuous + +lemma center_isometry (Ω : E) (hΩ : ‖Ω‖ = 1) (U : E →ₗᵢ[ℂ] E) (hU : U Ω = Ω) + (x : E) : U (center Ω x : E) = (center Ω (U x) : E) := by + rw [coe_center Ω hΩ, coe_center Ω hΩ, map_sub, map_smul, hU] + congr 2 + have h := U.inner_map_map Ω x + rw [hU] at h + exact h.symm + +def centeredIsometry (Ω : E) (U : E →ₗᵢ[ℂ] E) (hU : U Ω = Ω) : + centeredSpace Ω →ₗᵢ[ℂ] centeredSpace Ω := + { U.toLinearMap.domRestrict (centeredSpace Ω) |>.codRestrict (centeredSpace Ω) + (fun x => by + change U (x : E) ∈ (ℂ ∙ Ω)ᗮ + rw [Submodule.mem_orthogonal_singleton_iff_inner_right] + have h := U.inner_map_map Ω (x : E) + rw [hU] at h + rw [h] + exact Submodule.mem_orthogonal_singleton_iff_inner_right.mp x.property) with + norm_map' := fun x => U.norm_map x } + +@[simp] lemma centeredIsometry_apply (Ω : E) (U : E →ₗᵢ[ℂ] E) (hU : U Ω = Ω) + (x : centeredSpace Ω) : (centeredIsometry Ω U hU x : E) = U (x : E) := rfl + +lemma centeredIsometry_center (Ω : E) (hΩ : ‖Ω‖ = 1) + (U : E →ₗᵢ[ℂ] E) (hU : U Ω = Ω) (x : E) : + centeredIsometry Ω U hU (center Ω x) = center Ω (U x) := by + apply Subtype.ext + exact center_isometry Ω hΩ U hU x + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralAtoms.lean b/lean/OAI/Analysis/Commutator/CentralAtoms.lean new file mode 100644 index 0000000000000000000000000000000000000000..396ba234e52a0abd120cefb3fc84f1e30e07e2c4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralAtoms.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralCorner +import OAI.Analysis.Commutator.ProjectionBlocks + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.CentralAtoms + +open CentralCorner AtomicFactor ProjectionBlocks + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def Atom (M : VonNeumannAlgebra H) := {p : H →L[ℂ] H // IsMinimalProjection (CentralCorner.center M) p} + +def projection (M : VonNeumannAlgebra H) (p : Atom M) : H →L[ℂ] H := p.val + +lemma isProjection (M : VonNeumannAlgebra H) (p : Atom M) : IsStarProjection (projection M p) := + p.property.2.1 + +lemma orthogonal (M : VonNeumannAlgebra H) (p q : Atom M) (hpq : p≠q) : + projection M p*projection M q=0 := by + let a := projection M p + let b := projection M q + have ha : IsStarProjection a := isProjection M p + have hb : IsStarProjection b := isProjection M q + have hc : Commute a b := (((mem_center M _).mp p.property.1).2 b + ((mem_center M _).mp q.property.1).1).symm + have hab : IsStarProjection (a*b) := ha.mul hb hc + have habM : a*b∈CentralCorner.center M := (CentralCorner.center M).mul_mem p.property.1 q.property.1 + have hpa : a*b≤a := (hab.le_iff_mul_eq_right ha).mpr (by rw [←mul_assoc,ha.isIdempotentElem.eq]) + have hqb : a*b≤b := (hab.le_iff_mul_eq_left hb).mpr (by rw [mul_assoc,hb.isIdempotentElem.eq]) + by_contra hn + have heap : a*b=a := (p.property.2.2.2 _ habM hab hpa).resolve_left hn + have heaq : a*b=b := (q.property.2.2.2 _ habM hab hqb).resolve_left hn + exact hpq (Subtype.ext (heap.symm.trans heaq)) + +def part (M : VonNeumannAlgebra H) : H →L[ℂ] H := (space (projection M)).starProjection + +lemma part_projection (M : VonNeumannAlgebra H) : IsStarProjection (part M) := + isStarProjection_starProjection + +lemma part_mem_center (M : VonNeumannAlgebra H) : part M∈CentralCorner.center M := by + apply (mem_center M _).mpr + constructor + · change part M∈(M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + intro T hT + exact (projection_commutes (projection M) (isProjection M) T (fun p => + (hT (projection M p) ((mem_center M _).mp p.property.1).1).symm)).symm + · intro T hT + exact (projection_commutes (projection M) (isProjection M) T (fun p => + ((mem_center M _).mp p.property.1).2 T hT)).symm + +lemma part_mul (M : VonNeumannAlgebra H) (p : Atom M) : part M*projection M p=projection M p := + projection_left (projection M) p + +theorem no_atom_below_complement (M : VonNeumannAlgebra H) (p : Atom M) : + ¬projection M p≤1-part M := by + intro hp + have he := ((isProjection M p).le_iff_mul_eq_right (part_projection M).one_sub).mp hp + rw [sub_mul,one_mul,part_mul,sub_self] at he + exact p.property.2.2.1 he.symm + +def IsAtomicCenter (M : VonNeumannAlgebra H) : Prop := + ∀ p∈CentralCorner.center M,IsStarProjection p → p≠0 → ∃ q : Atom M,projection M q≤p + +lemma part_eq_one_of_atomic (M : VonNeumannAlgebra H) (h : IsAtomicCenter M) : part M=1 := by + have hz : 1-part M=0 := by + by_contra hn + obtain ⟨q,hq⟩ := h (1-part M) ((CentralCorner.center M).sub_mem (CentralCorner.center M).one_mem (part_mem_center M)) + (part_projection M).one_sub hn + exact no_atom_below_complement M q hq + exact (sub_eq_zero.mp hz).symm + +end Kadison.CentralAtoms +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralAverage.lean b/lean/OAI/Analysis/Commutator/CentralAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..32a72c39309bdafb28dc4d7c73f74fd975d72b73 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralAverage.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralPinching +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.ProjectionCommutant +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped InnerProductSpace Topology + +namespace Kadison.CentralAverage + +open UnitaryOrbit + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_center_average (M : VonNeumannAlgebra H) (Y : H →L[ℂ] H) : + ∃ Y₁ : H →L[ℂ] H, + (∀ a∈M,a∈Set.centralizer (M : Set (H →L[ℂ] H)) → Y₁*a=a*Y₁) ∧ + ‖Y₁-Y‖≤commutatorSeminorm M Y ∧ + commutatorSeminorm M Y₁≤3*commutatorSeminorm M Y := by + classical + choose T hT hcomm using exists_finite_average M Y + let ω : Ultrafilter (Finset (CentralProjection M)) := Ultrafilter.of atTop + have hω : (ω : Filter (Finset (CentralProjection M)))≤atTop := Ultrafilter.of_le atTop + obtain ⟨Y₁,_,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω T + (commutatorSeminorm M Y+‖Y‖) (add_nonneg (commutatorSeminorm_nonneg M Y) (norm_nonneg Y)) + (fun s => hull_norm M (hT s)) + have hd : ‖Y₁-Y‖≤commutatorSeminorm M Y := by + apply WeakOperatorLimit.norm_le_of_tendsto (l := (ω : Filter (Finset (CentralProjection M)))) + (T := fun s => T s-Y) + (fun x y => ?_) (commutatorSeminorm_nonneg M Y) + (Filter.Eventually.of_forall fun s => hull_distance M (hT s)) + simpa only [sub_apply,inner_sub_left] using + (hlim x y).sub_const (inner ℂ (Y x) y) + have hc (p : CentralProjection M) : Y₁*p.val=p.val*Y₁ := by + apply WeakOperatorLimit.intertwine hlim p.val p.val + have he := (Filter.eventually_ge_atTop ({p} : Finset (CentralProjection M))).filter_mono hω + filter_upwards [he] with s hs + exact hcomm s p (hs (Finset.mem_singleton_self p)) + refine ⟨Y₁,?_,hd,?_⟩ + · intro a ha haz + apply commutes_algebra_of_commutes_projections (vonNeumannIntersection M M.commutant) Y₁ + (fun p hp hpp => hc ⟨p,hp.1,hpp,by + simpa only [VonNeumannAlgebra.coe_toStarSubalgebra,VonNeumannAlgebra.coe_commutant] using hp.2⟩) a + exact ⟨ha,by + simpa only [VonNeumannAlgebra.coe_toStarSubalgebra,VonNeumannAlgebra.coe_commutant] using haz⟩ + · exact commutatorSeminorm_three M Y Y₁ hd + +end Kadison.CentralAverage + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralBlockEstimate.lean b/lean/OAI/Analysis/Commutator/CentralBlockEstimate.lean new file mode 100644 index 0000000000000000000000000000000000000000..d61041a033510f6e1e839aff7a2012172ff43887 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralBlockEstimate.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralCorner +import OAI.Analysis.Commutator.SeparableFactorMain + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.CentralCorner + +open ConcreteCorner MatrixCornerHilbert ReducingRepresentation + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) {p : M} (hp : IsStarProjection p) + (hz : (p:H →L[ℂ] H)∈Set.centralizer (M : Set (H →L[ℂ] H))) + +omit [TopologicalSpace.SeparableSpace H] in +lemma invariant_of_commute (Y : H →L[ℂ] H) (hy : Y*(p:H →L[ℂ] H)=(p:H →L[ℂ] H)*Y) : + ∀ x∈Space hp,Y x∈Space hp := by + intro x hx + rw [mem_fixedSpace] at hx ⊢ + change (p:H →L[ℂ] H) x=x at hx + change (p:H →L[ℂ] H) (Y x)=Y x + exact (congrArg (fun operator : H →L[ℂ] H => operator x) hy.symm).trans (congrArg Y hx) + +include hz in +lemma corner_matrix_bound + (hmin : AtomicFactor.IsMinimalProjection (center M) (p:H →L[ℂ] H)) + (Y : H →L[ℂ] H) (hY : ∀ x∈Space hp,Y x∈Space hp) + (h : ℕ) (hh : 1≤h) (X : Matrix (Fin h) (Fin h) M) : + ‖diagonalAmplification h (Y.restrict hY)*matrixOperator h (fun i j => restriction M hp hz (X i j))- + matrixOperator h (fun i j => restriction M hp hz (X i j))*diagonalAmplification h (Y.restrict hY)‖≤ + 3122*commutatorSeminorm M Y*‖matrixOperator h (fun i j => (X i j:H →L[ℂ] H))‖ := by + have hX (i j : Fin h) : restriction M hp hz (X i j)∈vonNeumann hp := by + change restriction M hp hz (X i j)∈(vonNeumann hp).toStarSubalgebra + rw [←restriction_range M hp hz] + exact Set.mem_range_self (X i j) + have hb := uniform_commutator_separable_factor (vonNeumann hp) + (factor_of_minimal_center M hp hz hmin) (Y.restrict hY) h hh + (fun i j => restriction M hp hz (X i j)) hX + have hn := restricted_matrix_norm_le M.toStarSubalgebra.subtype (Space hp) + (invariant M hp hz) h X + have hg := seminorm_le M hp hz Y hY + exact hb.trans ((mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left hg (by norm_num)) + (norm_nonneg (matrixOperator h (fun i j => restriction M hp hz (X i j))))).trans + (mul_le_mul_of_nonneg_left hn + (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg M Y)))) + +include hp hz in +lemma projected_vector_bound + (hmin : AtomicFactor.IsMinimalProjection (center M) (p:H →L[ℂ] H)) + (Y : H →L[ℂ] H) (hy : Y*(p:H →L[ℂ] H)=(p:H →L[ℂ] H)*Y) + (h : ℕ) (hh : 1≤h) (X : Matrix (Fin h) (Fin h) M) + (ξ : PiLp 2 fun _ : Fin h => H) : + ‖(diagonalAmplification h Y*matrixOperator h (fun i j => (X i j:H →L[ℂ] H))- + matrixOperator h (fun i j => (X i j:H →L[ℂ] H))*diagonalAmplification h Y) + (diagonalAmplification h (p:H →L[ℂ] H) ξ)‖≤ + (3122*commutatorSeminorm M Y*‖matrixOperator h (fun i j => (X i j:H →L[ℂ] H))‖)* + ‖diagonalAmplification h (p:H →L[ℂ] H) ξ‖ := by + let K := Space hp + let hy' := invariant_of_commute M hp Y hy + let η : PiLp 2 fun _ : Fin h => K := WithLp.toLp 2 (fun i => project hp (ξ i)) + have heη : diagonalAmplification h (p:H →L[ℂ] H) ξ=matrixInclusion K h η := by + ext i + rfl + have he := congrArg (fun T => T η) (matrix_commutator_intertwines + M.toStarSubalgebra.subtype K (invariant M hp hz) Y hy' h X) + change (diagonalAmplification h Y*matrixOperator h (fun i j => (X i j:H →L[ℂ] H))- + matrixOperator h (fun i j => (X i j:H →L[ℂ] H))*diagonalAmplification h Y) + (matrixInclusion K h η)=matrixInclusion K h + ((diagonalAmplification h (Y.restrict hy')*matrixOperator h (fun i j => restriction M hp hz (X i j))- + matrixOperator h (fun i j => restriction M hp hz (X i j))*diagonalAmplification h (Y.restrict hy')) η) at he + rw [heη,he,(matrixInclusion K h).norm_map,(matrixInclusion K h).norm_map] + exact (ContinuousLinearMap.le_opNorm _ η).trans (mul_le_mul_of_nonneg_right + (corner_matrix_bound M hp hz hmin Y hy' h hh X) (norm_nonneg η)) + +end Kadison.CentralCorner +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralCorner.lean b/lean/OAI/Analysis/Commutator/CentralCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..5400040b8a652b1f17b5b2b4ddef74b1eb93eaa8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralCorner.lean @@ -0,0 +1,143 @@ +import Mathlib +import OAI.Analysis.Commutator.DerivationKaplansky +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.MinimalCorner +import OAI.Analysis.Commutator.ConcreteCornerVonNeumann +import OAI.Analysis.Commutator.ReducingMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.CentralCorner + +open ConcreteCorner MatrixCornerHilbert ReducingRepresentation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def center (M : VonNeumannAlgebra H) : VonNeumannAlgebra H := + vonNeumannIntersection M M.commutant + +lemma mem_center (M : VonNeumannAlgebra H) (a : H →L[ℂ] H) : + a∈center M ↔ a∈M ∧ a∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + change a∈M ∧ a∈M.commutant ↔ _ + rw [VonNeumannAlgebra.mem_commutant_iff] + rfl + +variable (M : VonNeumannAlgebra H) {p : M} (hp : IsStarProjection p) + (hz : (p:H →L[ℂ] H)∈Set.centralizer (M : Set (H →L[ℂ] H))) + +include hz + +lemma invariant (a : M) (x : H) (hx : x∈Space hp) : (a:H →L[ℂ] H) x∈Space hp := by + rw [mem_fixedSpace] at hx ⊢ + change (p:H →L[ℂ] H) x=x at hx + change (p:H →L[ℂ] H) ((a:H →L[ℂ] H) x)=(a:H →L[ℂ] H) x + rw [←mul_apply_eq_comp,←hz a a.property,mul_apply_eq_comp,hx] + +def restriction : M →⋆ₐ[ℂ] (Space hp →L[ℂ] Space hp) := + restrict M.toStarSubalgebra.subtype (Space hp) (invariant M hp hz) + +lemma restriction_apply (a : M) (x : Space hp) : (restriction M hp hz a x:H)=(a:H →L[ℂ] H) (x:H) := rfl + +def cut (a : M) : Corner hp := ⟨p*a,by rw [←mul_assoc,hp.isIdempotentElem.eq],by + have hc : a*p=p*a := Subtype.ext (hz a a.property) + rw [mul_assoc,hc,←mul_assoc,hp.isIdempotentElem.eq]⟩ + +lemma restriction_eq_corner (a : M) : restriction M hp hz a=representation hp (cut M hp hz a) := by + ext x + change (a:H →L[ℂ] H) (x:H)=(p:H →L[ℂ] H) ((a:H →L[ℂ] H) (x:H)) + exact ((mem_fixedSpace _ _).mp (invariant M hp hz a x x.property)).symm + +lemma corner_restriction (a : Corner hp) : restriction M hp hz (a:M)=representation hp a := by + ext x + rfl + +lemma restriction_range : (restriction M hp hz).range=(vonNeumann hp).toStarSubalgebra := by + apply SetLike.coe_injective + change Set.range (restriction M hp hz)=Set.range (representation hp) + apply Set.Subset.antisymm + · rintro _ ⟨a,rfl⟩ + exact ⟨cut M hp hz a,(restriction_eq_corner M hp hz a).symm⟩ + · rintro _ ⟨a,rfl⟩ + exact ⟨(a:M),corner_restriction M hp hz a⟩ + +lemma lift_restriction (T : Space hp →L[ℂ] Space hp) (a : M) : + (a:H →L[ℂ] H)*lift hp T=lift hp (restriction M hp hz a*T) := by + ext x + rfl + +lemma project_mul (a : M) (x : H) : + project hp ((a:H →L[ℂ] H) x)=restriction M hp hz a (project hp x) := by + apply Subtype.ext + exact congrArg (fun T : H →L[ℂ] H => T x) (hz a a.property).symm + +lemma lift_mul_restriction (T : Space hp →L[ℂ] Space hp) (a : M) : + lift hp T*(a:H →L[ℂ] H)=lift hp (T*restriction M hp hz a) := by + ext x + change (T (project hp ((a:H →L[ℂ] H) x)):H)=(T (restriction M hp hz a (project hp x)):H) + rw [project_mul M hp hz] + +lemma lift_central {T : Space hp →L[ℂ] Space hp} + (hT : T∈vonNeumann hp) + (hTc : T∈Set.centralizer (vonNeumann hp : Set (Space hp →L[ℂ] Space hp))) : + lift hp T∈center M := by + apply (mem_center M _).mpr + refine ⟨lift_mem hp (by rw [corner_bicommutant]; exact hT),?_⟩ + intro a ha + rcases (show ∃ b : M,(b:H →L[ℂ] H)=a from ⟨⟨a,ha⟩,rfl⟩) with ⟨b,rfl⟩ + rw [lift_restriction M hp hz,lift_mul_restriction M hp hz] + congr 1 + apply hTc + change restriction M hp hz b∈(vonNeumann hp).toStarSubalgebra + rw [←restriction_range M hp hz] + exact Set.mem_range_self b + +theorem factor_of_minimal_center + (hmin : AtomicFactor.IsMinimalProjection (center M) (p:H →L[ℂ] H)) : + FactorCorner.IsFactor (vonNeumann hp) := by + intro T hT hTc + obtain ⟨c,hc⟩ := AtomicFactor.corner_scalar (center M) hmin + (lift_central M hp hz hT hTc) (lift_left hp T) (lift_right hp T) + refine ⟨c,?_⟩ + ext x + have he := congrArg (fun S : H →L[ℂ] H => S (x:H)) hc + change (T x:H)=c • (x:H) + change (T (project hp (x:H)):H)=c • (p:H →L[ℂ] H) (x:H) at he + rw [project_fixed,show (p:H →L[ℂ] H) (x:H)=(x:H) from MatrixCornerHilbert.fixed_apply (inclusion M p) x] at he + exact he + +lemma bicommutant_restriction : NormalGNS.bicommutant (restriction M hp hz).range=vonNeumann hp := by + rw [restriction_range M hp hz] + apply SetLike.coe_injective + apply Set.ext + intro T + rw [SetLike.mem_coe,SetLike.mem_coe,NormalGNS.mem_bicommutant] + change T∈Set.centralizer (Set.centralizer (vonNeumann hp : Set (Space hp →L[ℂ] Space hp))) ↔ T∈vonNeumann hp + rw [(vonNeumann hp).centralizer_centralizer] + rfl + +theorem seminorm_le (Y : H →L[ℂ] H) + (hY : ∀ x∈Space hp,Y x∈Space hp) : + commutatorSeminorm (vonNeumann hp) (Y.restrict hY)≤commutatorSeminorm M Y := by + rw [←bicommutant_restriction M hp hz] + apply DerivationColumns.seminorm_bicommutant_le _ _ (commutatorSeminorm_nonneg M Y) + intro a + rw [←compression_eq_restrict (Space hp) Y hY] + exact (norm_commutator_compression_le M.toStarSubalgebra.subtype (Space hp) + (invariant M hp hz) Y a).trans (commutator_bound M Y a.property) + +end Kadison.CentralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralGeometryModel.lean b/lean/OAI/Analysis/Commutator/CentralGeometryModel.lean new file mode 100644 index 0000000000000000000000000000000000000000..0c5b0e893bd9b14d145524c07e87fea7fb9a1634 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralGeometryModel.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorModelMain +import OAI.Analysis.Commutator.FiberCommutes +import OAI.Analysis.Commutator.FiberFactorProducer + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem uniform_commutator_in_central_model + (P : VonNeumannAlgebra (Lp H 2 μ)) (Q R : Ω → VonNeumannAlgebra H) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈P ∧ + indicatorOperator (H:=H) μ s hs∈Set.centralizer (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (test cotest : ℕ → Ω → H →L[ℂ] H) + (ht : ∀ n ξ,AEStronglyMeasurable (fun a => test n a ξ) μ) + (hs : ∀ n ξ,AEStronglyMeasurable (fun a => cotest n a ξ) μ) + (htb : ∀ n,∀ᵐ a ∂μ,‖test n a‖≤1) + (hsb : ∀ n,∀ᵐ a ∂μ,‖cotest n a‖≤1) + (htP : ∀ n,operator μ (test n) (ht n) (htb n)∈P) + (hsP : ∀ n,operator μ (cotest n) (hs n) (hsb n)∈P.commutant) + (htQ : ∀ n,∀ᵐ a ∂μ,test n a∈Q a) + (hsR : ∀ n,∀ᵐ a ∂μ,cotest n a∈R a) + (hfiberdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) a ξ) atTop (𝓝 (A ξ))) + (hcofiberdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈R a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => cotest (k n) a ξ) atTop (𝓝 (A ξ))) + (hglobaldense : ∀ A : Lp H 2 μ →L[ℂ] Lp H 2 μ,A∈P → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ f,Tendsto + (fun n => operator μ (test (k n)) (ht (k n)) (htb (k n)) f) atTop (𝓝 (A f))) + (hcoglobaldense : ∀ A : Lp H 2 μ →L[ℂ] Lp H 2 μ,A∈P.commutant → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ f,Tendsto + (fun n => operator μ (cotest (k n)) (hs (k n)) (hsb (k n)) f) atTop (𝓝 (A f))) + (hcenter : ∀ (Z : Lp H 2 μ →L[ℂ] Lp H 2 μ),Z∈P → Z∈P.commutant → + ∀ B : H →L[ℂ] H,Commute + (operator μ (fun _ => B) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (Lp H 2 μ →L[ℂ] Lp H 2 μ)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + have hPd : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈Set.centralizer + (P.commutant : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)) := by + intro s hs B hB + exact (VonNeumannAlgebra.mem_commutant_iff.mp hB _ (hdiag s hs).1).symm + have hPmem : ∀ A,A∈P → FieldMember μ Q A := by + intro A hA + obtain ⟨T,hm,hb,he,hmem⟩ := exists_member_field μ P Q (fun s hs => (hdiag s hs).2) + test ht htb htQ hglobaldense A hA + exact ⟨T,hm,‖A‖,hb,norm_nonneg A,he,hmem⟩ + have hPcmem : ∀ A,A∈P.commutant → FieldMember μ R A := by + intro A hA + obtain ⟨T,hm,hb,he,hmem⟩ := exists_member_field μ P.commutant R hPd + cotest hs hsb hsR hcoglobaldense A hA + exact ⟨T,hm,‖A‖,hb,norm_nonneg A,he,hmem⟩ + have hRQ := commutant_ae_of_dense_commuting_fields μ Q R test cotest ht hs htb hsb + (fun i j => VonNeumannAlgebra.mem_commutant_iff.mp (hsP j) _ (htP i)) + hfiberdense hcofiberdense + have hfac := factors_ae_of_central_geometry μ P Q R hPmem hPcmem hRQ hcenter + exact uniform_commutator_in_factor_model μ P Q hfac hdiag test ht htb htP htQ + hfiberdense hglobaldense Y h hh X hX + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralPinching.lean b/lean/OAI/Analysis/Commutator/CentralPinching.lean new file mode 100644 index 0000000000000000000000000000000000000000..4859a6bd454b54cf484bb83bae2070a944fb9325 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralPinching.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.Commutator.UnitaryOrbitHull + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.CentralAverage + +open UnitaryOrbit + +section Algebra + +variable {A : Type*} [Ring A] [StarRing A] + +def reflection (p : A) (hp : IsStarProjection p) : unitary A := + ⟨p+p-1,by + have hs : star (p+p-1)=p+p-1 := by simp only [star_sub,star_add,star_one,hp.isSelfAdjoint.star_eq] + have hsq : (p+p-1)*(p+p-1)=1 := by noncomm_ring [hp.isIdempotentElem.eq] + exact ⟨by rw [hs,hsq],by rw [hs,hsq]⟩⟩ + +lemma reflection_star (p : A) (hp : IsStarProjection p) : + star (reflection p hp:A)=p+p-1 := by + simp only [reflection,star_sub,star_add,star_one,hp.isSelfAdjoint.star_eq] + +lemma pinch_commutes (p T : A) (hp : IsStarProjection p) : + (T+(p+p-1)*T*(p+p-1))*p=p*(T+(p+p-1)*T*(p+p-1)) := by + have hpp (x : A) : p*(p*x)=p*x := by rw [←mul_assoc,hp.isIdempotentElem.eq] + noncomm_ring [hp.isIdempotentElem.eq,hpp] + +end Algebra + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def CentralProjection := {p : H →L[ℂ] H // p∈M ∧ IsStarProjection p ∧ + p∈Set.centralizer (M : Set (H →L[ℂ] H))} + +def projectionElement (p : CentralProjection M) : M := ⟨p.val,p.property.1⟩ + +lemma projectionElement_projection (p : CentralProjection M) : IsStarProjection (projectionElement M p) := by + constructor + · apply Subtype.ext + exact p.property.2.1.isIdempotentElem.eq + · apply Subtype.ext + exact p.property.2.1.isSelfAdjoint.star_eq + +def pinch (p : CentralProjection M) (T : H →L[ℂ] H) : H →L[ℂ] H := + (1/2:ℝ) • T+(1/2:ℝ) • conjugate M + (reflection (projectionElement M p) (projectionElement_projection M p)) T + +lemma pinch_mem {Y T : H →L[ℂ] H} (p : CentralProjection M) (hT : T∈hull M Y) : + pinch M p T∈hull M Y := + midpoint_mem M hT (conjugate_mem_hull M _ hT) + +lemma pinch_formula (p : CentralProjection M) (T : H →L[ℂ] H) : + pinch M p T=(1/2:ℝ) • (T+(p.val+p.val-1)*T*(p.val+p.val-1)) := by + change (1/2:ℝ) • T+(1/2:ℝ) • ((p.val+p.val-1)*T*star (p.val+p.val-1))=_ + simp only [star_sub,star_add,star_one,p.property.2.1.isSelfAdjoint.star_eq,smul_add] + +lemma pinch_commutes_projection (p : CentralProjection M) (T : H →L[ℂ] H) : + pinch M p T*p.val=p.val*pinch M p T := by + rw [pinch_formula,smul_mul_assoc,mul_smul_comm,pinch_commutes _ _ p.property.2.1] + +lemma pinch_preserves (p q : CentralProjection M) {T : H →L[ℂ] H} + (hT : T*q.val=q.val*T) : pinch M p T*q.val=q.val*pinch M p T := by + have hpq : Commute p.val q.val := (p.property.2.2 _ q.property.1).symm + have hU : Commute (p.val+p.val-1) q.val := (hpq.add_left hpq).sub_left (Commute.one_left _) + have hr := (show Commute T q.val from hT).add_left + ((hU.mul_left hT).mul_left hU) + rw [pinch_formula,smul_mul_assoc,mul_smul_comm,hr.eq] + +theorem exists_finite_average (Y : H →L[ℂ] H) (s : Finset (CentralProjection M)) : + ∃ T : H →L[ℂ] H,T∈hull M Y ∧ ∀ p∈s,T*p.val=p.val*T := by + classical + induction s using Finset.induction_on with + | empty => exact ⟨Y,hull_self M Y,by simp⟩ + | @insert p s hp ih => + obtain ⟨T,hT,hc⟩ := ih + refine ⟨pinch M p T,pinch_mem M p hT,?_⟩ + intro q hq + rcases Finset.mem_insert.mp hq with hqp|hq + · subst q + exact pinch_commutes_projection M p T + · exact pinch_preserves M p q (hc q hq) + +end Kadison.CentralAverage + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralRepresentationModel.lean b/lean/OAI/Analysis/Commutator/CentralRepresentationModel.lean new file mode 100644 index 0000000000000000000000000000000000000000..4be651c44e836a4e5f9fb4e8b4d68e11b9bd43e2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralRepresentationModel.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralGeometryModel +import OAI.Analysis.Commutator.RepresentationFieldTests + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology + +namespace Kadison.Decomposable + +variable {Ω H A B : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] + [TopologicalSpace.SeparableSpace (Lp H 2 μ)] + [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [TopologicalSpace.SeparableSpace A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + [TopologicalSpace.SeparableSpace B] + +theorem uniform_commutator_in_representation_model + (P : VonNeumannAlgebra (Lp H 2 μ)) + (ρ : A →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (σ : Ω → A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (ρc : B →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (σc : Ω → B →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hm : ∀ a ξ,AEStronglyMeasurable (fun x => σ x a ξ) μ) + (hmc : ∀ b ξ,AEStronglyMeasurable (fun x => σc x b ξ) μ) + (hact : ∀ a (f : Lp H 2 μ),ρ a f =ᵐ[μ] fun x => σ x a (f x)) + (hactc : ∀ b (f : Lp H 2 μ),ρc b f =ᵐ[μ] fun x => σc x b (f x)) + (hP : NormalGNS.bicommutant ρ.range=P) + (hPc : NormalGNS.bicommutant ρc.range=P.commutant) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈P ∧ + indicatorOperator (H:=H) μ s hs∈Set.centralizer (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (hcenter : ∀ (Z : Lp H 2 μ →L[ℂ] Lp H 2 μ),Z∈P → Z∈P.commutant → + ∀ C : H →L[ℂ] H,Commute + (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (Lp H 2 μ →L[ℂ] Lp H 2 μ)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + obtain ⟨test,ht,hb,htP,htQ,hfd,hgd⟩ := exists_common_tests μ ρ σ hm hact + obtain ⟨cotest,hs,hc,hsP,hsR,hcfd,hcgd⟩ := exists_common_tests μ ρc σc hmc hactc + rw [hP] at htP hgd + rw [hPc] at hsP hcgd + exact uniform_commutator_in_central_model μ P + (fun x => NormalGNS.bicommutant (σ x).range) + (fun x => NormalGNS.bicommutant (σc x).range) hdiag test cotest ht hs hb hc + htP hsP htQ hsR hfd hcfd hgd hcgd hcenter Y h hh X hX + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralSpectralGeometry.lean b/lean/OAI/Analysis/Commutator/CentralSpectralGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..a79d2bc79d02551a233d2134e2493df0d6162259 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralSpectralGeometry.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.AbelianGNSSpectral +import OAI.Analysis.Commutator.UnitaryCenterTransport +import OAI.Analysis.Commutator.StableCenterRange +import OAI.Analysis.Commutator.StableScalarGeometry + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace ComplexOrder + +namespace Kadison.CentralSpectral + +open CyclicSpectral Decomposable InfiniteAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (μ : Measure (Spectrum M)) + +variable (U : Space ℕ H ≃ₗᵢ[ℂ] Lp (Space ℕ ℂ) 2 μ) + +variable (hU : ∀ (a : CentralCorner.center M) (v : Space ℕ H), + U (map (a : H →L[ℂ] H) v)=scalarVectorMultiplier μ (gelfandStarTransform _ a) (U v)) + +include hU + +lemma conjugate_center (a : CentralCorner.center M) : + U.conjStarAlgEquiv (map a.val)=scalarVectorMultiplier μ (gelfandStarTransform _ a) := by + apply ContinuousLinearMap.ext + intro v + change U (map a.val (U.symm v))=scalarVectorMultiplier μ (gelfandStarTransform _ a) v + rw [hU,U.apply_symm_apply] + +lemma central_indicators + (hind : ∀ (s : Set (Spectrum M)) (hs : MeasurableSet s), + ∃ a : CentralCorner.center M, + scalarMultiplier μ (gelfandStarTransform _ a)=indicatorOperator μ s hs) + (s : Set (Spectrum M)) (hs : MeasurableSet s) : + indicatorOperator (H:=Space ℕ ℂ) μ s hs ∈ + CentralCorner.center (UnitaryTransport.algebra U (algebra M)) := by + obtain ⟨a,ha⟩ := hind s hs + rw [←vector_indicator_of_scalar μ _ s hs ha,←conjugate_center M μ U hU a] + exact (UnitaryTransport.mem_center_algebra U (algebra M) (map a.val)).mpr + ((map_mem_center M a.val).mpr a.property) + +lemma center_commutes_constant + (Z : Lp (Space ℕ ℂ) 2 μ →L[ℂ] Lp (Space ℕ ℂ) 2 μ) + (hZ : Z∈CentralCorner.center (UnitaryTransport.algebra U (algebra M))) + (C : Space ℕ ℂ →L[ℂ] Space ℕ ℂ) : + Commute (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z := by + obtain ⟨a,ha⟩ := stable_center_range M U Z hZ + rw [←ha,conjugate_center M μ U hU a] + exact scalarVectorMultiplier_commutes_constant μ _ C + +end Kadison.CentralSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CentralSpectralModel.lean b/lean/OAI/Analysis/Commutator/CentralSpectralModel.lean new file mode 100644 index 0000000000000000000000000000000000000000..070605fd6e683f520613ce98944919b7fcb66516 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CentralSpectralModel.lean @@ -0,0 +1,108 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralRepresentationModel +import OAI.Analysis.Commutator.ClosedCStarOrder +import OAI.Analysis.Commutator.PointwiseStarHom + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology + +namespace Kadison.Decomposable + +variable {Ω H : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] + [TopologicalSpace.SeparableSpace (Lp H 2 μ)] + +theorem uniform_commutator_in_central_spectral_model_nonzero [NeZero μ] + (P : VonNeumannAlgebra (Lp H 2 μ)) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈P ∧ + indicatorOperator (H:=H) μ s hs∈Set.centralizer (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (hcenter : ∀ (Z : Lp H 2 μ →L[ℂ] Lp H 2 μ),Z∈P → Z∈P.commutant → + ∀ C : H →L[ℂ] H,Commute + (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (Lp H 2 μ →L[ℂ] Lp H 2 μ)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + obtain ⟨S,hclosedS,hsepS,hSP,hSS⟩ := exists_separable_cstar_bicommutant P + obtain ⟨T,hclosedT,hsepT,hTP,hTT⟩ := exists_separable_cstar_bicommutant P.commutant + let : IsClosed (S:Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)) := hclosedS + let : IsClosed (T:Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)) := hclosedT + let : CStarAlgebra S := StarSubalgebra.cstarAlgebra S + let : CStarAlgebra T := StarSubalgebra.cstarAlgebra T + let : StarOrderedRing S := ClosedCStar.starOrderedRing S + let : StarOrderedRing T := ClosedCStar.starOrderedRing T + let : TopologicalSpace.SeparableSpace S := hsepS + let : TopologicalSpace.SeparableSpace T := hsepT + obtain ⟨σ,hm,hact⟩ := exists_pointwise_starHom μ S.subtype (by + intro a s hs + exact (hdiag s hs).2 a (hSP a.property)) + obtain ⟨σc,hmc,hactc⟩ := exists_pointwise_starHom μ T.subtype (by + intro a s hs + exact (VonNeumannAlgebra.mem_commutant_iff.mp (hTP a.property) _ (hdiag s hs).1).symm) + have hrS : S.subtype.range=S := by + ext a + constructor + · rintro ⟨b,rfl⟩ + exact b.property + · intro ha + exact ⟨⟨a,ha⟩,rfl⟩ + have hrT : T.subtype.range=T := by + ext a + constructor + · rintro ⟨b,rfl⟩ + exact b.property + · intro ha + exact ⟨⟨a,ha⟩,rfl⟩ + exact uniform_commutator_in_representation_model μ P S.subtype σ T.subtype σc + hm hmc hact hactc (by rwa [hrS]) (by rwa [hrT]) hdiag hcenter Y h hh X hX + +theorem uniform_commutator_in_central_spectral_model + (P : VonNeumannAlgebra (Lp H 2 μ)) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈P ∧ + indicatorOperator (H:=H) μ s hs∈Set.centralizer (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (hcenter : ∀ (Z : Lp H 2 μ →L[ℂ] Lp H 2 μ),Z∈P → Z∈P.commutant → + ∀ C : H →L[ℂ] H,Commute + (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (Lp H 2 μ →L[ℂ] Lp H 2 μ)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + by_cases hz : μ=0 + · have hY : Y=0 := by + apply ContinuousLinearMap.ext + intro f + apply Lp.ext + simp only [hz,MeasureTheory.ae_zero] + exact Filter.eventually_bot + have hd : diagonalAmplification h Y=0 := by + ext f i + simp [hY,diagonalAmplification_apply] + rw [hd,zero_mul,mul_zero,sub_self,norm_zero] + exact mul_nonneg (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg P Y)) (norm_nonneg _) + · let : NeZero μ := ⟨hz⟩ + exact uniform_commutator_in_central_spectral_model_nonzero μ P hdiag hcenter Y h hh X hX + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ChoiFunctional.lean b/lean/OAI/Analysis/Commutator/ChoiFunctional.lean new file mode 100644 index 0000000000000000000000000000000000000000..2234dd7c6d744da46cdb63cbda13039a0acf550e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ChoiFunctional.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix +import OAI.Analysis.Commutator.OperatorSystem +import OAI.Analysis.Commutator.PositiveExtensionComplex + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.OperatorSystem + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {ι : Type} [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +abbrev CoordinateSpace (ι : Type) [Fintype ι] := PiLp 2 (fun _ : ι => ℂ) + +def basisVector (i : ι) : CoordinateSpace ι := WithLp.toLp 2 (fun j => if j=i then 1 else 0) + +@[simp] lemma basisVector_apply (i j : ι) : basisVector i j=if j=i then 1 else 0 := rfl + +def choi (S : Submodule ℂ A) (f : S →ₗ[ℂ] (CoordinateSpace ι →L[ℂ] CoordinateSpace ι)) : + matrices S ι →ₗ[ℂ] ℂ where + toFun X := ∑ i,∑ j,⟪basisVector i,mapMatrix S f X i j (basisVector j)⟫_ℂ + map_add' X Y := by simp only [map_add,CStarMatrix.add_apply,add_apply,inner_add_right,Finset.sum_add_distrib] + map_smul' c X := by simp only [map_smul,CStarMatrix.smul_apply,smul_apply,inner_smul_right,Finset.mul_sum,smul_eq_mul,RingHom.id_apply] + +lemma choi_nonneg (S : Submodule ℂ A) + (f : S →ₗ[ℂ] (CoordinateSpace ι →L[ℂ] CoordinateSpace ι)) + (hf : IsCompletelyPositive S f) (X : matrices S ι) (hX : 0≤X.val) : 0≤choi S f X := by + let v : PiLp 2 (fun _ : ι => CoordinateSpace ι) := WithLp.toLp 2 basisVector + have hp := map_nonneg + (CyclicColumns.matrixRepresentation (ι:=ι) (StarAlgHom.id ℂ (CoordinateSpace ι →L[ℂ] CoordinateSpace ι))) + (hf ι X hX) + have hh := (ContinuousLinearMap.nonneg_iff_isPositive.mp hp).inner_nonneg_right v + simpa [CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply,PiLp.inner_apply, + v,choi,inner_sum] using hh + +theorem exists_choi_extension (S : Submodule ℂ A) (h1 : (1 : A)∈S) + (hs : ∀ a∈S,star a∈S) + (f : S →ₗ[ℂ] (CoordinateSpace ι →L[ℂ] CoordinateSpace ι)) + (hf : IsCompletelyPositive S f) : + ∃ η : CStarMatrix ι ι A →ₚ[ℂ] ℂ,∀ X : matrices S ι,η X=choi S f X := + PositiveExtension.exists_positive_extension (matrices S ι) (matrices_one S h1) + (matrices_star S hs) (choi S f) (choi_nonneg S f hf) + +end Kadison.OperatorSystem + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ChoiGNS.lean b/lean/OAI/Analysis/Commutator/ChoiGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..6da768ffb22df335d1139434726022a8c5369c3c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ChoiGNS.lean @@ -0,0 +1,95 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.ChoiGNS + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type} [Fintype ι] + +local instance choiGNSDecidableEq : DecidableEq ι := Classical.decEq ι + +def entry (i j : ι) (a : A) : CStarMatrix ι ι A := + CStarMatrix.ofMatrix (fun k l => if k=i ∧ l=j then a else 0) + +omit [Fintype ι] in +@[simp] lemma entry_apply (i j k l : ι) (a : A) : + entry i j a k l=if k=i ∧ l=j then a else 0 := rfl + +omit [Fintype ι] in +@[simp] lemma entry_star (i j : ι) (a : A) : star (entry i j a)=entry j i (star a) := by + ext k l + by_cases h : k=j ∧ l=i <;> simp [CStarMatrix.star_apply,entry_apply,and_comm,h] + +lemma entry_mul (i j k l : ι) (a b : A) : + entry i j a*entry k l b=if j=k then entry i l (a*b) else 0 := by + ext r s + by_cases hjk : j=k <;> by_cases hr : r=i <;> by_cases hs : s=l <;> + simp [CStarMatrix.mul_apply,entry_apply,hjk,hr,hs,ite_mul,mul_ite,eq_comm] + +def diagonal : A →⋆ₐ[ℂ] CStarMatrix ι ι A where + toFun a := CStarMatrix.ofMatrix (fun i j => if i=j then a else 0) + map_zero' := by ext i j; change (if i=j then 0 else 0)=(0 : A); simp + map_one' := by ext i j; rfl + map_add' a b := by + ext i j + change (if i=j then a+b else 0)=(if i=j then a else 0)+(if i=j then b else 0) + by_cases h : i=j <;> simp [h] + map_mul' a b := by + ext i j + rw [CStarMatrix.mul_apply] + change (if i=j then a*b else 0)=∑ k,(if i=k then a else 0)*(if k=j then b else 0) + simp [ite_mul,mul_ite] + commutes' c := by + ext i j + change (if i=j then algebraMap ℂ A c else 0)=(algebraMap ℂ (CStarMatrix ι ι A) c) i j + by_cases h : i=j <;> simp [Algebra.algebraMap_eq_smul_one,h] + map_star' a := by + ext i j + rw [CStarMatrix.star_apply] + change (if i=j then star a else 0)=star (if j=i then a else 0) + by_cases h : i=j <;> simp [h,eq_comm] + +@[simp] lemma diagonal_apply (a : A) (i j : ι) : diagonal a i j=if i=j then a else 0 := rfl + +lemma diagonal_entry (a b : A) (i j : ι) : diagonal a*entry i j b=entry i j (a*b) := by + ext k l + by_cases hki : k=i <;> by_cases hlj : l=j <;> + simp [CStarMatrix.mul_apply,diagonal_apply,entry_apply,ite_mul,mul_ite,hki,hlj] + +lemma entry_diagonal_entry (a : A) (i₀ i j : ι) : + star (entry i₀ i (1 : A))*(diagonal a*entry i₀ j 1)=entry i j a := by + rw [entry_star,star_one,diagonal_entry,mul_one,entry_mul,ite_eq_left rfl,one_mul] + +variable [PartialOrder A] [StarOrderedRing A] + +def vector (η : A →ₚ[ℂ] ℂ) : A →ₗ[ℂ] η.GNS := + UniformSpace.Completion.toComplL.toLinearMap.comp η.toPreGNS.toLinearMap + +@[simp] lemma vector_apply (η : A →ₚ[ℂ] ℂ) (a : A) : vector η a=(η.toPreGNS a : η.GNS) := rfl + +lemma inner_vector (η : A →ₚ[ℂ] ℂ) (a b : A) : + ⟪vector η a,vector η b⟫_ℂ=η (star a*b) := by + simp [vector_apply,UniformSpace.Completion.inner_coe,PositiveLinearMap.preGNS_inner_def] + +lemma representation_vector (η : A →ₚ[ℂ] ℂ) (a b : A) : + η.gnsStarAlgHom a (vector η b)=vector η (a*b) := by + simp [vector_apply,PositiveLinearMap.gnsStarAlgHom] + +end Kadison.ChoiGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ChoiRecovery.lean b/lean/OAI/Analysis/Commutator/ChoiRecovery.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0d81b7335054765b033f944e6ac7076300a0c6d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ChoiRecovery.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.ChoiFunctional +import OAI.Analysis.Commutator.ChoiGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.OperatorSystem + +open ChoiGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {ι : Type} [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +def choiEmbedding (η : CStarMatrix ι ι A →ₚ[ℂ] ℂ) (i₀ : ι) : CoordinateSpace ι →L[ℂ] η.GNS := + ({ toFun x := ∑ i,x i • vector η (entry i₀ i 1) + map_add' x y := by simp [add_smul,Finset.sum_add_distrib] + map_smul' c x := by simp [mul_smul,Finset.smul_sum] } : + CoordinateSpace ι →ₗ[ℂ] η.GNS).toContinuousLinearMap + +@[simp] lemma choiEmbedding_apply (η : CStarMatrix ι ι A →ₚ[ℂ] ℂ) (i₀ : ι) (x : CoordinateSpace ι) : + choiEmbedding η i₀ x=∑ i,x i • vector η (entry i₀ i 1) := rfl + +@[simp] lemma choiEmbedding_basis (η : CStarMatrix ι ι A →ₚ[ℂ] ℂ) (i₀ j : ι) : + choiEmbedding η i₀ (basisVector j)=vector η (entry i₀ j 1) := by + simp [choiEmbedding_apply,basisVector_apply,ite_smul] + +def choiRepresentation (η : CStarMatrix ι ι A →ₚ[ℂ] ℂ) : A →⋆ₐ[ℂ] (η.GNS →L[ℂ] η.GNS) := + η.gnsStarAlgHom.comp diagonal + +lemma choi_coefficient (η : CStarMatrix ι ι A →ₚ[ℂ] ℂ) (i₀ i j : ι) (a : A) : + ⟪basisVector i,(choiEmbedding η i₀).adjoint + (choiRepresentation η a (choiEmbedding η i₀ (basisVector j)))⟫_ℂ=η (entry i j a) := by + rw [ContinuousLinearMap.adjoint_inner_right,choiEmbedding_basis,choiEmbedding_basis] + change ⟪vector η (entry i₀ i 1),η.gnsStarAlgHom (diagonal a) (vector η (entry i₀ j 1))⟫_ℂ=_ + rw [representation_vector,inner_vector,entry_diagonal_entry] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma entry_mem (S : Submodule ℂ A) (a : S) (i j : ι) : entry i j (a : A)∈matrices S ι := by + intro k l + by_cases h : k=i ∧ l=j <;> simp [entry_apply,h,a.property] + +def systemEntry (S : Submodule ℂ A) (a : S) (i j : ι) : matrices S ι := + ⟨entry i j (a : A),entry_mem S a i j⟩ + +omit [PartialOrder A] [StarOrderedRing A] in +lemma mapMatrix_systemEntry (S : Submodule ℂ A) + (f : S →ₗ[ℂ] (CoordinateSpace ι →L[ℂ] CoordinateSpace ι)) (a : S) (i j k l : ι) : + mapMatrix S f (systemEntry S a i j) k l=if k=i ∧ l=j then f a else 0 := by + by_cases h : k=i ∧ l=j + · have he : (⟨(systemEntry S a i j).val k l,(systemEntry S a i j).property k l⟩ : S)=a := by + apply Subtype.ext + simp [systemEntry,entry_apply,h] + rw [mapMatrix_apply,he,ite_eq_left h] + · have he : (⟨(systemEntry S a i j).val k l,(systemEntry S a i j).property k l⟩ : S)=0 := by + apply Subtype.ext + simp [systemEntry,entry_apply,h] + rw [mapMatrix_apply,he,map_zero,ite_eq_right h] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma choi_systemEntry (S : Submodule ℂ A) + (f : S →ₗ[ℂ] (CoordinateSpace ι →L[ℂ] CoordinateSpace ι)) (a : S) (i j : ι) : + choi S f (systemEntry S a i j)=⟪basisVector i,f a (basisVector j)⟫_ℂ := by + change (∑ k,∑ l,⟪basisVector k,mapMatrix S f (systemEntry S a i j) k l (basisVector l)⟫_ℂ)=_ + simp only [mapMatrix_systemEntry] + have he (k l : ι) : ⟪basisVector k,(if k=i ∧ l=j then f a else 0) (basisVector l)⟫_ℂ= + if k=i ∧ l=j then ⟪basisVector k,f a (basisVector l)⟫_ℂ else 0 := by + by_cases h : k=i ∧ l=j <;> simp [h] + simp_rw [he] + simp [ite_and] + +lemma sum_basis (x : CoordinateSpace ι) : ∑ i,x i • basisVector i=x := by + ext j + simp [basisVector_apply] + +lemma basis_inner_ext (T U : CoordinateSpace ι →L[ℂ] CoordinateSpace ι) + (h : ∀ i j,⟪basisVector i,T (basisVector j)⟫_ℂ=⟪basisVector i,U (basisVector j)⟫_ℂ) : T=U := by + have he (j : ι) : T (basisVector j)=U (basisVector j) := by + apply ext_inner_left ℂ + intro x + rw [←sum_basis x] + simp only [sum_inner,inner_smul_left] + exact Finset.sum_congr rfl (fun i _ => by rw [h i j]) + ext x + rw [←sum_basis x] + simp [he] + +end Kadison.OperatorSystem + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ClosedCStarOrder.lean b/lean/OAI/Analysis/Commutator/ClosedCStarOrder.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ca54a80a67768f1332264c651d5abc57b1e2b3e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ClosedCStarOrder.lean @@ -0,0 +1,38 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.ClosedCStar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem starOrderedRing (S : StarSubalgebra ℂ (H →L[ℂ] H)) + [IsClosed (S:Set (H →L[ℂ] H))] : StarOrderedRing S := + StarOrderedRing.of_nonneg_iff' (fun {x y} h z => (show (z : H →L[ℂ] H)+(x : H →L[ℂ] H)≤(z : H →L[ℂ] H)+(y : H →L[ℂ] H) from add_le_add_right (show (x : H →L[ℂ] H)≤(y : H →L[ℂ] H) from h) _)) (by + intro T + constructor + · intro hT + have hm : CFC.sqrt (T : H →L[ℂ] H)∈S := by + rw [CFC.sqrt_eq_real_sqrt (T : H →L[ℂ] H) hT] + exact cfcₙ_mem (𝕜':=ℂ) Real.sqrt T.property + refine ⟨⟨CFC.sqrt (T : H →L[ℂ] H),hm⟩,?_⟩ + apply Subtype.ext + change (T : H →L[ℂ] H)=star (CFC.sqrt (T : H →L[ℂ] H))*CFC.sqrt (T : H →L[ℂ] H) + rw [(CFC.sqrt_nonneg (T : H →L[ℂ] H)).star_eq,CFC.sqrt_mul_sqrt_self (T : H →L[ℂ] H) hT] + · rintro ⟨T,rfl⟩ + exact (star_mul_self_nonneg (T : H →L[ℂ] H))) + +end Kadison.ClosedCStar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CoefficientForm.lean b/lean/OAI/Analysis/Commutator/CoefficientForm.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f461cc2010e1ab167e70d5e971fb36e3a34852e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CoefficientForm.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.Commutator.MultilinearTensors + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.PreHilbert + +open UniformSpace Function + +abbrev wordSpace (E F : PreHilbert) (n : ℕ) := Completion (E ⊗[ℂ] power F n) + +def word (E F : PreHilbert) (n : ℕ) (d : E) (x : Fin n → F) : wordSpace E F n := + (d ⊗ₜ[ℂ] pure F n x : E ⊗[ℂ] power F n) + +@[simp] lemma norm_word (E F : PreHilbert) (n : ℕ) (d : E) (x : Fin n → F) : + ‖word E F n d x‖ = ‖d‖ * ∏ i, ‖x i‖ := by + simp only [word, Completion.norm_coe, TensorProduct.norm_tmul, norm_pure] + +@[simp] lemma inner_word (E F : PreHilbert) (n : ℕ) (d e : E) (x y : Fin n → F) : + inner ℂ (word E F n d x) (word E F n e y) = + inner ℂ d e * ∏ i, inner ℂ (x i) (y i) := by + simp only [word, Completion.inner_coe, TensorProduct.inner_tmul, inner_pure] + +lemma word_add_left (E F : PreHilbert) (n : ℕ) (d e : E) (x : Fin n → F) : + word E F n (d + e) x = word E F n d x + word E F n e x := by + simp only [word, TensorProduct.add_tmul, Completion.coe_add] + +lemma word_smul_left (E F : PreHilbert) (n : ℕ) (c : ℂ) (d : E) (x : Fin n → F) : + word E F n (c • d) x = c • word E F n d x := by + simp only [word, ← TensorProduct.smul_tmul', Completion.coe_smul] + +lemma word_update_add (E F : PreHilbert) (n : ℕ) (d : E) (v : Fin n → F) + (i : Fin n) (x y : F) : + word E F n d (update v i (x + y)) = + word E F n d (update v i x) + word E F n d (update v i y) := by + simp only [word, pure_update_add, TensorProduct.tmul_add, Completion.coe_add] + +lemma word_update_smul (E F : PreHilbert) (n : ℕ) (d : E) (v : Fin n → F) + (i : Fin n) (c : ℂ) (x : F) : + word E F n d (update v i (c • x)) = c • word E F n d (update v i x) := by + simp only [word, pure_update_smul, TensorProduct.tmul_smul, Completion.coe_smul] + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CoefficientForm2.lean b/lean/OAI/Analysis/Commutator/CoefficientForm2.lean new file mode 100644 index 0000000000000000000000000000000000000000..982e0a90bf3ae78d6f9c11cece77c6867f49627f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CoefficientForm2.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors +import OAI.Analysis.Commutator.CoefficientForm + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +open PreHilbert Function + +variable (E F : PreHilbert) (k l : ℕ) + +variable {M : Type*} [AddCommGroup M] [Module ℂ M] [StarAddMonoid M] [StarModule ℂ M] + +def coefficient (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) (A : Option (Fin k ⊕ Fin l) → M) : ℂ := + inner ℂ (word E F l (v₀ (star (A none))) (fun j => v₁ (star (A (some (.inr j)))))) + (Y (word E F k Ω (fun i => v₁ (A (some (.inl i)))))) + +variable [DecidableEq (Option (Fin k ⊕ Fin l))] + +omit [StarModule ℂ M] in +lemma coefficient_update_none_add + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) (A : Option (Fin k ⊕ Fin l) → M) (x y : M) : + coefficient E F k l Y Ω v₀ v₁ (update A none (x+y)) = + coefficient E F k l Y Ω v₀ v₁ (update A none x) + + coefficient E F k l Y Ω v₀ v₁ (update A none y) := by + simp only [coefficient, update_self, update_of_ne (Option.some_ne_none _), + star_add, map_add, word_add_left, inner_add_left] + +lemma coefficient_update_none_smul + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) (A : Option (Fin k ⊕ Fin l) → M) (c : ℂ) (x : M) : + coefficient E F k l Y Ω v₀ v₁ (update A none (c • x)) = + c • coefficient E F k l Y Ω v₀ v₁ (update A none x) := by + simp only [coefficient, update_self, update_of_ne (Option.some_ne_none _), + star_smul, map_smul, word_smul_left, inner_smul_left] + simp + +omit [StarModule ℂ M] in +lemma coefficient_update_inl + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) (A : Option (Fin k ⊕ Fin l) → M) + (i : Fin k) (x : M) : + coefficient E F k l Y Ω v₀ v₁ (update A (some (.inl i)) x) = + inner ℂ (word E F l (v₀ (star (A none))) (fun j => v₁ (star (A (some (.inr j)))))) + (Y (word E F k Ω (update (fun a => v₁ (A (some (.inl a)))) i (v₁ x)))) := by + have he : (fun a => v₁ (update A (some (.inl i)) x (some (.inl a)))) = + update (fun a => v₁ (A (some (.inl a)))) i (v₁ x) := by + funext a + by_cases ha : a = i <;> simp [ha] + have hn : (none : Option (Fin k ⊕ Fin l)) ≠ some (.inl i) := by simp + have hr : ∀ j : Fin l, (some (.inr j) : Option (Fin k ⊕ Fin l)) ≠ some (.inl i) := by simp + simp only [coefficient, update_of_ne hn, update_of_ne (hr _), he] + +omit [StarModule ℂ M] in +lemma coefficient_update_inr + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) (A : Option (Fin k ⊕ Fin l) → M) + (j : Fin l) (x : M) : + coefficient E F k l Y Ω v₀ v₁ (update A (some (.inr j)) x) = + inner ℂ (word E F l (v₀ (star (A none))) + (update (fun b => v₁ (star (A (some (.inr b))))) j (v₁ (star x)))) + (Y (word E F k Ω (fun a => v₁ (A (some (.inl a)))))) := by + have he : (fun b => v₁ (star (update A (some (.inr j)) x (some (.inr b))))) = + update (fun b => v₁ (star (A (some (.inr b))))) j (v₁ (star x)) := by + funext b + by_cases hb : b = j <;> simp [hb] + have hn : (none : Option (Fin k ⊕ Fin l)) ≠ some (.inr j) := by simp + have hr : ∀ i : Fin k, (some (.inl i) : Option (Fin k ⊕ Fin l)) ≠ some (.inr j) := by simp + simp only [coefficient, update_of_ne hn, update_of_ne (hr _), he] + +def coefficientMultilinear + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) : + MultilinearMap ℂ (fun _ : Option (Fin k ⊕ Fin l) => M) ℂ where + toFun := coefficient E F k l Y Ω v₀ v₁ + map_update_add' := by + intro inst A i x y + cases i with + | none => exact coefficient_update_none_add E F k l Y Ω v₀ v₁ A x y + | some i => + cases i with + | inl i => + simp only [coefficient_update_inl, map_add, word_update_add, inner_add_right] + | inr j => + simp only [coefficient_update_inr, star_add, map_add, word_update_add, inner_add_left] + map_update_smul' := by + intro inst A i c x + cases i with + | none => exact coefficient_update_none_smul E F k l Y Ω v₀ v₁ A c x + | some i => + cases i with + | inl i => + simp only [coefficient_update_inl, map_smul, word_update_smul, inner_smul_right, + smul_eq_mul] + | inr j => + simp only [coefficient_update_inr, star_smul, map_smul, word_update_smul, + inner_smul_left, starRingEnd_apply, star_star, smul_eq_mul] + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CoherentComparison.lean b/lean/OAI/Analysis/Commutator/CoherentComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..9e6a8bf4aa8c1d9767f8fcfda83a94b896e430b5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CoherentComparison.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicDimensionComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin in +lemma extend_comparison {p r q : H →L[ℂ] H} (hp : IsStarProjection p) + (hrM : r∈M) (hr : IsStarProjection r) (hqM : q∈M) (hq : IsStarProjection q) + (hqp : q≤p) (v : Link M p r) (hvi : v.initial≤q) + (hdr : dimension M hfac hd q≤dimension M hfac hd r) : + ∃ w : Link M p r,v≤w ∧ w.initial=q := by + let b : Link M q r := ⟨v.val,v.mem,v.triple,hvi,v.target_le⟩ + have hiM : b.initial∈M := M.mul_mem (M.star_mem' b.mem) b.mem + have hfM : b.final∈M := M.mul_mem b.mem (M.star_mem' b.mem) + have heq := dimension_congr_equivalent M hfac hd b.initial_projection b.final_projection + b.equivalentSupports + have hds := dimension_difference M hfac hd hfin hqM hiM hq b.initial_projection b.source_le + have hdt := dimension_difference M hfac hd hfin hrM hfM hr b.final_projection b.target_le + obtain ⟨u,hui⟩ := subEquivalent_of_dimension_le M hfac hd hfin + (M.sub_mem hqM hiM) (M.sub_mem hrM hfM) (b.residual_source_projection hq) + (b.residual_target_projection hr) (by rw [hds,hdt,heq]; linarith) + let z := b.extend hq hr u + have hzp : z.initial≤p := by + apply (z.initial_projection.le_iff_mul_eq_right hp).mpr + calc + p*z.initial = p*(q*z.initial) := by + rw [(z.initial_projection.le_iff_mul_eq_right hq).mp z.source_le] + _ = z.initial := by + rw [←mul_assoc,(hq.le_iff_mul_eq_right hp).mp hqp, + (z.initial_projection.le_iff_mul_eq_right hq).mp z.source_le] + let w : Link M p r := ⟨z.val,z.mem,z.triple,hzp,z.target_le⟩ + refine ⟨w,?_,?_⟩ + · exact b.le_extend hq hr u + · change z.initial=q + rw [Link.extend_initial,hui] + abel + +include hfin in +theorem exists_coherent_comparisons {p r : H →L[ℂ] H} (hp : IsStarProjection p) + (hrM : r∈M) (hr : IsStarProjection r) (P : ℕ → H →L[ℂ] H) + (hPM : ∀ n,P n∈M) (hP : ∀ n,IsStarProjection (P n)) (hmono : Monotone P) + (hPp : ∀ n,P n≤p) (hdim : ∀ n,dimension M hfac hd (P n)≤dimension M hfac hd r) : + ∃ v : ℕ → Link M p r,Monotone v ∧ ∀ n,(v n).initial=P n := by + classical + obtain ⟨b,hb⟩ := subEquivalent_of_dimension_le M hfac hd hfin (hPM 0) hrM (hP 0) hr (hdim 0) + let V (n : ℕ) := {v : Link M p r // v.initial=P n} + let v0 : V 0 := ⟨⟨b.val,b.mem,b.triple,b.source_le.trans (hPp 0),b.target_le⟩,hb⟩ + have hstep (n : ℕ) (v : V n) : ∃ w : V (n+1),v.val≤w.val := by + obtain ⟨w,hvw,hw⟩ := extend_comparison M hfac hd hfin hp hrM hr (hPM (n+1)) + (hP (n+1)) (hPp (n+1)) v.val (by rw [v.property]; exact hmono (Nat.le_succ n)) (hdim (n+1)) + exact ⟨⟨w,hw⟩,hvw⟩ + let step (n : ℕ) (v : V n) : V (n+1) := (hstep n v).choose + let v : (n : ℕ) → V n := fun n => Nat.rec v0 step n + refine ⟨fun n => (v n).val,?_,fun n => (v n).property⟩ + apply monotone_nat_of_le_succ + intro n + exact (hstep n (v n)).choose_spec + +include hfin in +theorem subEquivalent_of_strong_increasing {p r : H →L[ℂ] H} (hp : IsStarProjection p) + (hrM : r∈M) (hr : IsStarProjection r) (P : ℕ → H →L[ℂ] H) + (hPM : ∀ n,P n∈M) (hP : ∀ n,IsStarProjection (P n)) (hmono : Monotone P) + (hPp : ∀ n,P n≤p) (hdim : ∀ n,dimension M hfac hd (P n)≤dimension M hfac hd r) + (hlim : ∀ x,Tendsto (fun n => P n x) atTop (𝓝 (p x))) : SubEquivalent M p r := by + obtain ⟨v,hvmono,hvi⟩ := exists_coherent_comparisons M hfac hd hfin hp hrM hr P hPM hP hmono hPp hdim + have hc : IsChain (·≤·) (Set.range v) := by + rintro _ ⟨n,rfl⟩ _ ⟨m,rfl⟩ hne + rcases le_total n m with h|h + · exact Or.inl (hvmono h) + · exact Or.inr (hvmono h) + obtain ⟨u,hu⟩ := chain_has_upper M hp hr (Set.range v) hc (Set.range_nonempty v) + have hPu (n : ℕ) : P n≤u.initial := by + rw [←hvi n] + exact ((Link.le_def _ _).mp (hu (Set.mem_range_self n))).1 + have hEq : u.initial*p=p := by + ext x + have hconv := u.initial.continuous.tendsto (p x) |>.comp (hlim x) + have heq (n : ℕ) : u.initial (P n x)=P n x := by + exact congrArg (fun T : H →L[ℂ] H => T x) + (((hP n).le_iff_mul_eq_right u.initial_projection).mp (hPu n)) + have hconv' : Tendsto (fun n => u.initial (P n x)) atTop (𝓝 (p x)) := by + simpa only [heq] using hlim x + exact tendsto_nhds_unique hconv hconv' + refine ⟨u,le_antisymm u.source_le ((hp.le_iff_mul_eq_right u.initial_projection).mpr hEq)⟩ + +end Kadison.PartialIsometryOrder.DyadicPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ColumnEstimate.lean b/lean/OAI/Analysis/Commutator/ColumnEstimate.lean new file mode 100644 index 0000000000000000000000000000000000000000..c33f787666443e14463ea53996421a602a90a5dd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ColumnEstimate.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.ColumnModule +import OAI.Analysis.Commutator.LittleGrothendieckSequence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter Set UniformSpace Completion + +namespace Kadison.ColumnModule + +open LittleGrothendieck HilbertSequence + +variable {A E : Type*} [CStarAlgebra A] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +lemma sequence_module_bound (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) + {M : ℝ} (hM : 0≤M) (hmod : ∀ a b : A, ‖T (a*b)‖≤ M*‖a‖*‖T b‖) + (a b : ℕ →ᵇ A) : + ‖sequenceMap ω T (a*b)‖≤ M*‖a‖*‖sequenceMap ω T b‖ := by + apply le_of_tendsto_of_tendsto (sequenceMap_norm_tendsto ω T (a*b)) + (tendsto_const_nhds.mul (sequenceMap_norm_tendsto ω T b)) + apply Filter.Eventually.of_forall + intro n + exact (hmod (a n) (b n)).trans (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left (a.norm_coe_le_norm n) hM) (norm_nonneg _)) + +theorem sum_norm_sq_le {ι : Type*} [Fintype ι] (T : A →L[ℂ] E) + {M : ℝ} (hM : 0≤M) (hmod : ∀ a b : A, ‖T (a*b)‖≤ M*‖a‖*‖T b‖) + (a : ι → A) : ∑ i, ‖T (a i)‖^2≤ M^2*‖T‖^2*‖∑ i,star (a i)*a i‖ := by + classical + obtain ⟨ω,u,hu⟩ := exists_sequence_unitary_max T + let : PartialOrder (ℕ →ᵇ A) := CStarAlgebra.spectralOrder _ + let : StarOrderedRing (ℕ →ᵇ A) := CStarAlgebra.spectralOrderedRing _ + have h := sum_sq_at_max (sequenceMap ω T) hM (sequence_module_bound ω T hM hmod) + u hu (fun i => BoundedContinuousFunction.const ℕ (a i)) + simp only [sequenceMap_const,LinearIsometry.norm_map] at h + have hc : (∑ i,star (BoundedContinuousFunction.const ℕ (a i))* + BoundedContinuousFunction.const ℕ (a i))= + BoundedContinuousFunction.const ℕ (∑ i,star (a i)*a i) := by + ext n + simp + rw [hc,BoundedContinuousFunction.norm_const_eq] at h + exact h.trans (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left + (pow_le_pow_left₀ (norm_nonneg _) (sequenceMap_norm_le ω T) 2) (sq_nonneg M)) (norm_nonneg _)) + +def homOrbit (φ : A →ₐ[ℂ] (E →L[ℂ] E)) {M : ℝ} (_hM : 0≤M) + (hφ : ∀ a, ‖φ a‖≤ M*‖a‖) (ξ : E) : A →L[ℂ] E := + LinearMap.mkContinuous + { toFun a := φ a ξ + map_add' a b := by simp only [map_add,_root_.add_apply] + map_smul' z a := by simp only [map_smul,_root_.smul_apply, RingHom.id_apply] } + (M*‖ξ‖) (by + intro a + exact ((φ a).le_opNorm ξ).trans (by + nlinarith [hφ a,norm_nonneg ξ])) + +@[simp] lemma homOrbit_apply (φ : A →ₐ[ℂ] (E →L[ℂ] E)) {M : ℝ} (hM : 0≤M) + (hφ : ∀ a, ‖φ a‖≤ M*‖a‖) (ξ : E) (a : A) : homOrbit φ hM hφ ξ a=φ a ξ := rfl + +lemma homOrbit_norm (φ : A →ₐ[ℂ] (E →L[ℂ] E)) {M : ℝ} (hM : 0≤M) + (hφ : ∀ a, ‖φ a‖≤ M*‖a‖) (ξ : E) : ‖homOrbit φ hM hφ ξ‖≤ M*‖ξ‖ := + LinearMap.mkContinuous_norm_le _ (mul_nonneg hM (norm_nonneg ξ)) _ + +theorem hom_column_sq {ι : Type*} [Fintype ι] + (φ : A →ₐ[ℂ] (E →L[ℂ] E)) {M : ℝ} (hM : 0≤M) + (hφ : ∀ a, ‖φ a‖≤ M*‖a‖) (a : ι → A) (ξ : E) : + ∑ i, ‖φ (a i) ξ‖^2 ≤ M^4*‖ξ‖^2*‖∑ i,star (a i)*a i‖ := by + have hm (a b : A) : ‖homOrbit φ hM hφ ξ (a*b)‖≤ M*‖a‖*‖homOrbit φ hM hφ ξ b‖ := by + simp only [homOrbit_apply,map_mul,mul_apply_eq_comp] + exact ((φ a).le_opNorm (φ b ξ)).trans + (mul_le_mul_of_nonneg_right (hφ a) (norm_nonneg _)) + have h := sum_norm_sq_le (homOrbit φ hM hφ ξ) hM hm a + calc + _ ≤ M^2*‖homOrbit φ hM hφ ξ‖^2*‖∑ i,star (a i)*a i‖ := h + _ ≤ M^2*(M*‖ξ‖)^2*‖∑ i,star (a i)*a i‖ := + mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left + (pow_le_pow_left₀ (norm_nonneg _) (homOrbit_norm φ hM hφ ξ) 2) (sq_nonneg M)) (norm_nonneg _) + _ = _ := by ring + +end Kadison.ColumnModule + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ColumnModule.lean b/lean/OAI/Analysis/Commutator/ColumnModule.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2a1877443ac43fd926bf0d5f131e25fe533bb01 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ColumnModule.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.Commutator.LittleGrothendieck + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace CStarAlgebra + +open Filter Set + +namespace Kadison.ColumnModule + +variable {A E : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +lemma regularized_factor (a : A) {ε : ℝ} (hε : 0<ε) : + ∃ b c : A, ‖b‖≤ 1 ∧ IsSelfAdjoint c ∧ + c*c=star a*a+ε • (1:A) ∧ a=b*c := by + let d := star a*a+ε • (1:A) + have hd : IsStrictlyPositive d := by + simpa only [d,add_comm] using + (IsStrictlyPositive.smul hε (isStrictlyPositive_one (A:=A))).add_nonneg + (star_mul_self_nonneg a) + let c := CFC.sqrt d + have hc : IsSelfAdjoint c := (CFC.sqrt_nonneg d).isSelfAdjoint + have hcunit : IsUnit c := CFC.isUnit_sqrt_iff_isStrictlyPositive.mpr hd + let v : Aˣ := hcunit.unit + have hv : (v:A)=c := hcunit.unit_spec + have hvs : star (v:A)=(v:A) := by rw [hv]; exact hc.star_eq + have hivi : star ((v⁻¹:Aˣ):A)=((v⁻¹:Aˣ):A) := by + have ht : star v=v := Units.ext hvs + change ((star (v⁻¹):Aˣ):A)=((v⁻¹:Aˣ):A) + rw [star_inv,ht] + let b := a*((v⁻¹:Aˣ):A) + have hcc : c*c=d := CFC.sqrt_mul_sqrt_self d hd.nonneg + have hs : star b*b≤ 1 := by + have hle : star a*a ≤ d := le_add_of_nonneg_right (smul_nonneg hε.le zero_le_one) + have hh := star_left_conjugate_le_conjugate hle (((v⁻¹:Aˣ):A)) + have he : star ((v⁻¹:Aˣ):A)*d*((v⁻¹:Aˣ):A)=1 := by + rw [hivi,←hcc,←hv] + simp only [←mul_assoc,Units.inv_mul,one_mul,Units.mul_inv] + rw [he] at hh + simpa only [b,star_mul,mul_assoc] using hh + have hn : ‖b‖≤ 1 := by + have hh := (CStarAlgebra.norm_le_one_iff_of_nonneg (star b*b) + (star_mul_self_nonneg b)).mpr hs + rw [CStarRing.norm_star_mul_self] at hh + nlinarith [norm_nonneg b] + refine ⟨b,c,hn,hc,hcc,?_⟩ + simp only [b,←hv,mul_assoc,Units.inv_mul,mul_one] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma selfAdjoint_square_max (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) + (a : A) (ha : IsSelfAdjoint a) : + ‖T (a*(u:A))‖^2 ≤ (inner ℂ (T (u:A)) (T ((a*a)*(u:A)))).re := by + let S : A →L[ℂ] E := T.comp ((ContinuousLinearMap.mul ℂ A).flip (u:A)) + have hS : ∀ v : unitary A, ‖S (v:A)‖≤‖S (1:A)‖ := by + intro v + simpa only [S,ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.mul_apply',one_mul,Submonoid.coe_mul] using hu (v*u) + simpa only [S,ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.mul_apply',OneMemClass.coe_one,one_mul] using + LittleGrothendieck.selfAdjoint_square_at_unitary_max S 1 hS a ha + +def maxFunctional (T : A →L[ℂ] E) (u : unitary A) : A →L[ℝ] ℝ := + Complex.reCLM.comp (((innerSL ℂ (T (u:A))).comp + (T.comp ((ContinuousLinearMap.mul ℂ A).flip (u:A)))).restrictScalars ℝ) + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma maxFunctional_apply (T : A →L[ℂ] E) (u : unitary A) (a : A) : + maxFunctional T u a=(inner ℂ (T (u:A)) (T (a*(u:A)))).re := rfl + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma maxFunctional_one (T : A →L[ℂ] E) (u : unitary A) : + maxFunctional T u 1=‖T (u:A)‖^2 := by + simp only [maxFunctional_apply,one_mul] + exact inner_self_eq_norm_sq (𝕜:=ℂ) _ + +lemma maxFunctional_nonneg (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) {a : A} (ha : 0≤a) : + 0≤ maxFunctional T u a := by + have h := selfAdjoint_square_max T u hu (CFC.sqrt a) + (CFC.sqrt_nonneg a).isSelfAdjoint + rw [CFC.sqrt_mul_sqrt_self a ha] at h + exact (sq_nonneg _).trans h + +lemma maxFunctional_mono (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) : + Monotone (maxFunctional T u) := by + intro a b hab + have h := maxFunctional_nonneg T u hu (sub_nonneg.mpr hab) + rwa [map_sub,sub_nonneg] at h + +lemma maxFunctional_bound (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) {a : A} + (ha : IsSelfAdjoint a) : maxFunctional T u a≤‖a‖*‖T (u:A)‖^2 := by + have h := maxFunctional_mono T u hu ha.le_algebraMap_norm_self + simpa only [Algebra.algebraMap_eq_smul_one,map_smul,maxFunctional_one,smul_eq_mul] using h + +lemma module_square_max (T : A →L[ℂ] E) {M : ℝ} (hM : 0≤ M) + (hmod : ∀ a b : A, ‖T (a*b)‖≤ M*‖a‖*‖T b‖) + (u : unitary A) (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) + (a : A) : ‖T (a*(u:A))‖^2≤ M^2*maxFunctional T u (star a*a) := by + have heps (ε : ℝ) (hε : 0<ε) : + ‖T (a*(u:A))‖^2≤ M^2*(maxFunctional T u (star a*a)+ε*maxFunctional T u 1) := by + obtain ⟨b,c,hb,hc,hcc,hbc⟩ := regularized_factor a hε + have hn : ‖T (a*(u:A))‖≤ M*‖T (c*(u:A))‖ := by + rw [hbc,mul_assoc] + exact (hmod b (c*(u:A))).trans (by + simpa only [mul_one] using mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left hb hM) (norm_nonneg (T (c*(u:A))))) + have hs := selfAdjoint_square_max T u hu c hc + change ‖T (c*(u:A))‖^2≤ maxFunctional T u (c*c) at hs + rw [hcc,map_add,map_smul,smul_eq_mul] at hs + calc + _ ≤ (M*‖T (c*(u:A))‖)^2 := pow_le_pow_left₀ (norm_nonneg _) hn 2 + _ = M^2*‖T (c*(u:A))‖^2 := mul_pow _ _ _ + _ ≤ _ := mul_le_mul_of_nonneg_left hs (sq_nonneg M) + have hlim : Tendsto + (fun ε : ℝ => M^2*(maxFunctional T u (star a*a)+ε*maxFunctional T u 1)) + (𝓝[>] 0) (𝓝 (M^2*maxFunctional T u (star a*a))) := by + have h : Continuous (fun ε : ℝ => M^2*(maxFunctional T u (star a*a)+ε*maxFunctional T u 1)) := by + fun_prop + simpa only [zero_mul,add_zero] using + (h.continuousAt (x:=0)).tendsto.mono_left (nhdsWithin_le_nhds (s:=Ioi (0:ℝ))) + exact le_of_tendsto_of_tendsto tendsto_const_nhds hlim + (Filter.eventually_of_mem self_mem_nhdsWithin heps) + +theorem sum_sq_at_max {ι : Type*} [Fintype ι] + (T : A →L[ℂ] E) {M : ℝ} (hM : 0≤ M) + (hmod : ∀ a b : A, ‖T (a*b)‖≤ M*‖a‖*‖T b‖) + (u : unitary A) (hu : ∀ v : unitary A, ‖T (v:A)‖≤‖T (u:A)‖) + (a : ι → A) : ∑ i, ‖T (a i)‖^2≤ M^2*‖T‖^2*‖∑ i,star (a i)*a i‖ := by + classical + let b : ι → A := fun i => a i*(star u:A) + have hb (i : ι) : b i*(u:A)=a i := by + simp only [b,mul_assoc,Unitary.star_mul_self_of_mem u.property,mul_one] + have hs := Finset.sum_le_sum (fun i (_ : i∈Finset.univ) => module_square_max T hM hmod u hu (b i)) + simp only [hb,←Finset.mul_sum,←map_sum] at hs + have hpos : 0≤∑ i,star (b i)*b i := Finset.sum_nonneg (fun _ _ => star_mul_self_nonneg _) + have hn : ‖∑ i,star (b i)*b i‖=‖∑ i,star (a i)*a i‖ := by + have he : (∑ i,star (b i)*b i)=(u:A)*(∑ i,star (a i)*a i)*(star u:A) := by + simp only [b,star_mul,star_star,Finset.mul_sum,Finset.sum_mul,mul_assoc] + rw [he] + change ‖(u:A)*(∑ i,star (a i)*a i)*(↑(star u):A)‖=_ + rw [CStarRing.norm_mul_coe_unitary,CStarRing.norm_coe_unitary_mul] + have huT : ‖T (u:A)‖≤‖T‖ := by + cases subsingleton_or_nontrivial A with + | inl h => simpa only [Subsingleton.elim (u:A) 0,map_zero,norm_zero] using norm_nonneg T + | inr h => simpa only [CStarRing.norm_coe_unitary,mul_one] using T.le_opNorm (u:A) + calc + _ ≤ M^2*maxFunctional T u (∑ i,star (b i)*b i) := hs + _ ≤ M^2*(‖∑ i,star (b i)*b i‖*‖T (u:A)‖^2) := + mul_le_mul_of_nonneg_left (maxFunctional_bound T u hu hpos.isSelfAdjoint) (sq_nonneg M) + _ ≤ M^2*(‖∑ i,star (b i)*b i‖*‖T‖^2) := + mul_le_mul_of_nonneg_left (mul_le_mul_of_nonneg_left + (pow_le_pow_left₀ (norm_nonneg _) huT 2) (norm_nonneg _)) (sq_nonneg M) + _ = _ := by rw [hn]; ring + +end Kadison.ColumnModule + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CommutatorBicommutant.lean b/lean/OAI/Analysis/Commutator/CommutatorBicommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..182e279ce49a6b68f06d31788c1fc1ae637f6828 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CommutatorBicommutant.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.CStarContractiveLifts +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.MatrixTowerGNS + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped Topology + +open Filter ContinuousLinearMap + +namespace Kadison + +variable {H A : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma commutator_normClosure (S : StarSubalgebra ℂ (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (δ : ℝ) + (hb : ∀ a∈S,‖Y*a-a*Y‖≤δ*‖a‖) : + ∀ a∈S.topologicalClosure,‖Y*a-a*Y‖≤δ*‖a‖ := by + have hc : IsClosed {a : H →L[ℂ] H | ‖Y*a-a*Y‖≤δ*‖a‖} := + isClosed_le (by fun_prop) (by fun_prop) + exact closure_minimal hb hc + +lemma commutator_bicommutant_contraction (S : StarSubalgebra ℂ (H →L[ℂ] H)) + (hS : IsClosed (S : Set (H →L[ℂ] H))) (Y : H →L[ℂ] H) (δ : ℝ) (hδ : 0≤δ) + (hb : ∀ a∈S,‖Y*a-a*Y‖≤δ*‖a‖) + (T : H →L[ℂ] H) (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hnT : ‖T‖≤1) : ‖Y*T-T*Y‖≤δ := by + classical + let a := Kaplansky.approximationNet S hS T hT hnT + have ha (j : Finset H × ℕ) := Kaplansky.approximationNet_spec S hS T hT hnT j + have hlim (x : H) : Tendsto (fun j => a j x) atTop (𝓝 (T x)) := + Kaplansky.approximationNet_tendsto S hS T hT hnT x + apply ContinuousLinearMap.opNorm_le_bound _ hδ + intro x + have hcomm : Tendsto (fun j => (Y*a j-a j*Y) x) atTop (𝓝 ((Y*T-T*Y) x)) := + (Y.continuous.tendsto _ |>.comp (hlim x)).sub (hlim (Y x)) + apply le_of_tendsto hcomm.norm + apply Eventually.of_forall + intro j + exact ((Y*a j-a j*Y).le_opNorm x).trans (mul_le_mul_of_nonneg_right + ((hb (a j) (ha j).1).trans ((mul_le_mul_of_nonneg_left (ha j).2.1 hδ).trans_eq (mul_one δ))) + (norm_nonneg x)) + +lemma commutatorSeminorm_bicommutant_le (S : StarSubalgebra ℂ (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (δ : ℝ) (hδ : 0≤δ) + (hb : ∀ a∈S,‖Y*a-a*Y‖≤δ*‖a‖) : + commutatorSeminorm (NormalGNS.bicommutant S) Y≤δ := by + apply commutatorSeminorm_le + intro T hT hnT + apply commutator_bicommutant_contraction S.topologicalClosure S.isClosed_topologicalClosure + Y δ hδ (commutator_normClosure S Y δ hb) T _ hnT + intro R hR + exact ((NormalGNS.mem_bicommutant S T).mp hT) R (fun a ha => hR a (S.le_topologicalClosure ha)) + +variable [CStarAlgebra A] + +lemma commutatorSeminorm_image_bicommutant_le (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (δ : ℝ) (hδ : 0≤δ) + (hb : ∀ a,‖Y*φ a-φ a*Y‖≤δ*‖a‖) : + commutatorSeminorm (NormalGNS.bicommutant φ.range) Y≤δ := by + apply commutatorSeminorm_bicommutant_le _ _ _ hδ + intro b hbr + obtain ⟨a,ha,rfl⟩ := CStarContractiveLifts.norm_lift φ hbr + exact (hb a).trans (mul_le_mul_of_nonneg_left ha hδ) + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CommutatorPerturbation.lean b/lean/OAI/Analysis/Commutator/CommutatorPerturbation.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc20cad5a78a4be144846c3e02f1ce4a3c5a89fa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CommutatorPerturbation.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Commutator.MainCommutantDistance + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma commutatorSeminorm_le (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) (C : ℝ) + (hC : ∀ a : H →L[ℂ] H,a∈P → ‖a‖≤1 → ‖Y*a-a*Y‖≤C) : + commutatorSeminorm P Y≤C := by + apply csSup_le + · exact ⟨0,0,P.zero_mem,by simp,by simp⟩ + · rintro r ⟨a,ha,hna,rfl⟩ + exact hC a ha hna + +lemma commutatorSeminorm_perturb (P : VonNeumannAlgebra H) (Y Z : H →L[ℂ] H) : + commutatorSeminorm P Z≤commutatorSeminorm P Y+2*‖Z-Y‖ := by + apply commutatorSeminorm_le + intro a ha hna + have he : Z*a-a*Z=(Y*a-a*Y)+((Z-Y)*a-a*(Z-Y)) := by + simp only [sub_mul,mul_sub]; abel + rw [he] + calc + _ ≤ ‖Y*a-a*Y‖+‖(Z-Y)*a-a*(Z-Y)‖ := norm_add_le _ _ + _ ≤ commutatorSeminorm P Y+2*‖Z-Y‖*‖a‖ := + add_le_add (commutator_bound_unitball P Y ha hna) (operator_commutator_norm_le _ _) + _ ≤ commutatorSeminorm P Y+2*‖Z-Y‖ := by nlinarith [norm_nonneg (Z-Y)] + +lemma commutatorSeminorm_three (P : VonNeumannAlgebra H) (Y Z : H →L[ℂ] H) + (hZ : ‖Z-Y‖≤commutatorSeminorm P Y) : commutatorSeminorm P Z≤3*commutatorSeminorm P Y := by + have hh := commutatorSeminorm_perturb P Y Z + linarith + +lemma matrix_commutator_perturb (P : VonNeumannAlgebra H) (Y Z : H →L[ℂ] H) + (hZ : ‖Z-Y‖≤commutatorSeminorm P Y) (c : ℝ) (hc : 0≤c) + (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) + (hb : ‖diagonalAmplification h Z*matrixOperator h X-matrixOperator h X*diagonalAmplification h Z‖ ≤ + c*commutatorSeminorm P Z*‖matrixOperator h X‖) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ ≤ + (3*c+2)*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + let A := matrixOperator h X + have he : diagonalAmplification h Y*A-A*diagonalAmplification h Y= + (diagonalAmplification h Z*A-A*diagonalAmplification h Z)+ + (diagonalAmplification h (Y-Z)*A-A*diagonalAmplification h (Y-Z)) := by + rw [diagonalAmplification_sub,sub_mul,mul_sub] + abel + have hdelta : ‖Y-Z‖≤commutatorSeminorm P Y := by rwa [norm_sub_rev] + have herr := (operator_commutator_norm_le (diagonalAmplification h (Y-Z)) A).trans + (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left ((diagonalAmplification_norm_le h (Y-Z)).trans hdelta) (by norm_num)) + (norm_nonneg A)) + have hh := mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left (commutatorSeminorm_three P Y Z hZ) hc) (norm_nonneg A) + change ‖diagonalAmplification h Y*A-A*diagonalAmplification h Y‖≤_ + rw [he] + calc + _ ≤ ‖diagonalAmplification h Z*A-A*diagonalAmplification h Z‖+ + ‖diagonalAmplification h (Y-Z)*A-A*diagonalAmplification h (Y-Z)‖ := norm_add_le _ _ + _ ≤ c*(3*commutatorSeminorm P Y)*‖A‖+2*commutatorSeminorm P Y*‖A‖ := + add_le_add (hb.trans hh) herr + _ = _ := by dsimp [A]; ring + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CompactAverage.lean b/lean/OAI/Analysis/Commutator/CompactAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..6aed464efb8eeb525900ee350022bc520dfebc2c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CompactAverage.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.StrongContinuity +import OAI.Analysis.Commutator.WeakOperatorIntegral + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open MeasureTheory MeasureTheory.Measure + +namespace Kadison.CompactAverage + +variable {G H : Type*} [Group G] [TopologicalSpace G] [IsTopologicalGroup G] + [CompactSpace G] [MeasurableSpace G] [BorelSpace G] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (U : G →* (H ≃ₗᵢ[ℂ] H)) (hU : ∀ x : H, Continuous fun g => U g x) + +variable (Y : H →L[ℂ] H) + +def conjugate (g : G) : H →L[ℂ] H := (U g).conjStarAlgEquiv Y + +omit [CompactSpace G] [MeasurableSpace G] [BorelSpace G] in +include hU in +lemma conjugate_continuous (x : H) : Continuous fun g => conjugate U Y g x := by + have hi : Continuous fun g => (U g).symm x := by + simpa only [Function.comp_def, map_inv,LinearIsometryEquiv.coe_inv] using (hU x).comp continuous_inv + have hj := StrongContinuity.joint (fun g => (U g).toLinearIsometry) hU + exact hj.comp (continuous_id.prodMk (Y.continuous.comp hi)) + +omit [TopologicalSpace G] [IsTopologicalGroup G] [CompactSpace G] [MeasurableSpace G] [BorelSpace G] in +lemma conjugate_norm (g : G) : ‖conjugate U Y g‖ = ‖Y‖ := by + exact StarAlgEquiv.norm_map (U g).conjStarAlgEquiv Y + +omit [TopologicalSpace G] [IsTopologicalGroup G] [CompactSpace G] [MeasurableSpace G] [BorelSpace G] in +lemma conjugate_covariant (g k : G) : + (U g : H →L[ℂ] H) * conjugate U Y k = conjugate U Y (g*k) * (U g : H →L[ℂ] H) := by + ext x + simp [conjugate,mul_apply_eq_comp,map_mul,LinearIsometryEquiv.mul_def] + +include hU in +theorem exists_average (μ : Measure G) [IsProbabilityMeasure μ] [IsMulLeftInvariant μ] : + ∃ V : H →L[ℂ] H, ‖V‖ ≤ ‖Y‖ ∧ + (∀ g, V * (U g : H →L[ℂ] H) = (U g : H →L[ℂ] H) * V) ∧ + (∀ x y, inner ℂ (V x) y = ∫ g, inner ℂ (conjugate U Y g x) y ∂μ) := by + have hI : ∀ x y, Integrable (fun g => inner ℂ (conjugate U Y g x) y) μ := by + intro x y + exact ((conjugate_continuous U hU Y x).inner continuous_const).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + obtain ⟨V,hb,hV⟩ := WeakOperatorIntegral.exists_integral μ (conjugate U Y) hI ‖Y‖ + (norm_nonneg _) (fun g => (conjugate_norm U Y g).le) + refine ⟨V,hb,?_,hV⟩ + intro g + ext x + apply ext_inner_right ℂ + intro y + simp only [mul_apply_eq_comp] + rw [← ContinuousLinearMap.adjoint_inner_right (U g : H →L[ℂ] H),hV,hV] + have hc : ∀ k, inner ℂ (conjugate U Y k x) ((U g : H →L[ℂ] H).adjoint y) = + inner ℂ (conjugate U Y (g*k) ((U g) x)) y := by + intro k + rw [ContinuousLinearMap.adjoint_inner_right] + exact congrArg (fun A : H →L[ℂ] H => inner ℂ (A x) y) (conjugate_covariant U Y g k) + simp_rw [hc] + exact (integral_mul_left_eq_self (fun k => inner ℂ (conjugate U Y k ((U g) x)) y) g).symm + +end Kadison.CompactAverage + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CompactInvariant.lean b/lean/OAI/Analysis/Commutator/CompactInvariant.lean new file mode 100644 index 0000000000000000000000000000000000000000..f47d573a2c1e1c7e0fd630b0a7148a88b308ab8f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CompactInvariant.lean @@ -0,0 +1,76 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Set + +namespace Kadison.CompactInvariant + +variable {G E : Type*} [Monoid G] [TopologicalSpace E] [T2Space E] [MulAction G E] + +def Invariant (S : Set E) : Prop := ∀ g : G,∀ x∈S,g • x∈S + +omit [TopologicalSpace E] [T2Space E] in +lemma invariant_sInter {F : Set (Set E)} (hF : ∀ S∈F,Invariant (G:=G) S) : + Invariant (G:=G) (⋂₀ F) := by + intro g x hx + exact fun S hS => hF S hS g x (hx S hS) + +theorem exists_minimal {C : Set E} (hC : IsCompact C) (hne : C.Nonempty) + (hinv : Invariant (G:=G) C) (P : Set E → Prop) (hP : P C) + (hPi : ∀ F : Set (Set E),F.Nonempty → (∀ S∈F,P S) → P (⋂₀ F)) : + ∃ K : Set E,Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ + Invariant (G:=G) S ∧ P S) K := by + apply zorn_superset + intro F hFC hF + obtain rfl | hFn := F.eq_empty_or_nonempty + · exact ⟨C,⟨subset_rfl,hne,hC.isClosed,hinv,hP⟩,by simp⟩ + have hsub : ⋂₀ F⊆C := by + obtain ⟨S,hS⟩ := hFn + exact (sInter_subset_of_mem hS).trans (hFC hS).1 + have hneI : (⋂₀ F).Nonempty := by + have : Nonempty F := hFn.to_subtype + rw [sInter_eq_iInter] + apply IsCompact.nonempty_iInter_of_directed_nonempty_isCompact_isClosed + · intro S T + obtain hST | hTS := hF.total S.property T.property + · exact ⟨S,subset_rfl,hST⟩ + · exact ⟨T,hTS,subset_rfl⟩ + · exact fun S => (hFC S.property).2.1 + · exact fun S => hC.of_isClosed_subset (hFC S.property).2.2.1 (hFC S.property).1 + · exact fun S => (hFC S.property).2.2.1 + refine ⟨⋂₀ F,⟨hsub,hneI,isClosed_sInter (fun S hS => (hFC hS).2.2.1), + invariant_sInter (fun S hS => (hFC hS).2.2.2.1),hPi F hFn (fun S hS => (hFC hS).2.2.2.2)⟩,?_⟩ + exact fun S hS => sInter_subset_of_mem hS + +lemma exists_minimal_compact {C : Set E} (hC : IsCompact C) (hne : C.Nonempty) + (hinv : Invariant (G:=G) C) : + ∃ K : Set E,Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ + Invariant (G:=G) S) K := by + obtain ⟨K,hK⟩ := exists_minimal hC hne hinv (fun _ => True) trivial (by simp) + refine ⟨K,⟨⟨hK.prop.1,hK.prop.2.1,hK.prop.2.2.1,hK.prop.2.2.2.1⟩,?_⟩⟩ + intro S hS hSK + exact hK.le_of_le ⟨hS.1,hS.2.1,hS.2.2.1,hS.2.2.2,trivial⟩ hSK + +variable [AddCommGroup E] [Module ℝ E] + +lemma exists_minimal_convex {C : Set E} (hC : IsCompact C) (hne : C.Nonempty) + (hinv : Invariant (G:=G) C) (hconv : Convex ℝ C) : + ∃ K : Set E,Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ + Invariant (G:=G) S ∧ Convex ℝ S) K := + exists_minimal hC hne hinv (Convex ℝ) hconv (fun _ _ h => convex_sInter h) + +end Kadison.CompactInvariant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CompletionCentered.lean b/lean/OAI/Analysis/Commutator/CompletionCentered.lean new file mode 100644 index 0000000000000000000000000000000000000000..f5329e8a10601354b9197567ce363996c28eda48 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CompletionCentered.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorCompletion + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.HilbertCompletion + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +def completeEquiv [CompleteSpace E] : E ≃ₗᵢ[ℂ] Completion E := + LinearIsometryEquiv.ofSurjective (coeIsometry E) (by + intro x + induction x using Completion.induction_on with + | hp => exact (coeIsometry E).isometry.isClosedEmbedding.isClosed_range + | ih x => exact ⟨x,rfl⟩) + +@[simp] lemma completeEquiv_apply [CompleteSpace E] (x : E) : + completeEquiv x=(x : Completion E) := rfl + +abbrev centered (Ω : E) : Submodule ℂ E := (ℂ ∙ Ω)ᗮ + +def centeredMap (Ω : E) : Completion (centered Ω) →ₗᵢ[ℂ] + centered (Ω : Completion E) where + toLinearMap := (map (centered Ω).subtypeₗᵢ).toLinearMap.codRestrict _ (by + intro x + rw [Submodule.mem_orthogonal_singleton_iff_inner_right] + change inner ℂ (Ω : Completion E) (map (centered Ω).subtypeₗᵢ x)=0 + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => + rw [map_coe, Completion.inner_coe] + exact Submodule.mem_orthogonal_singleton_iff_inner_right.mp x.property) + norm_map' x := (map (centered Ω).subtypeₗᵢ).norm_map x + +@[simp] lemma centeredMap_coe (Ω : E) (x : centered Ω) : + (centeredMap Ω (x : Completion (centered Ω)) : Completion E) = + ((x : E) : Completion E) := map_coe _ _ + +lemma centeredMap_surjective (Ω : E) (hΩ : ‖Ω‖=1) : + Function.Surjective (centeredMap Ω) := by + let Q := centered (Ω : Completion E) + let R : Submodule ℂ Q := LinearMap.range (centeredMap Ω).toLinearMap + have hR : IsClosed (R : Set Q) := (centeredMap Ω).isometry.isClosedEmbedding.isClosed_range + have hc : ∀ x : E, Q.orthogonalProjectionOnto (x : Completion E) ∈ R := by + intro x + let y : centered Ω := ⟨x-inner ℂ Ω x • Ω, by + rw [Submodule.mem_orthogonal_singleton_iff_inner_right, inner_sub_right, inner_smul_right, + inner_self_eq_norm_sq_to_K, hΩ] + simp⟩ + refine ⟨(y : Completion (centered Ω)), ?_⟩ + apply Subtype.ext + change (centeredMap Ω (y : Completion (centered Ω)) : Completion E) = _ + rw [centeredMap_coe] + change ((x-inner ℂ Ω x • Ω : E) : Completion E) = + (ℂ ∙ (Ω : Completion E))ᗮ.starProjection (x : Completion E) + rw [Submodule.starProjection_orthogonal_val, + Submodule.starProjection_unit_singleton ℂ (by simpa), Completion.coe_sub, + Completion.coe_smul, Completion.inner_coe] + have hd : DenseRange (fun x : E => Q.orthogonalProjectionOnto (x : Completion E)) := by + apply (show Function.Surjective Q.orthogonalProjectionOnto from fun x => + ⟨x, Q.orthogonalProjectionOnto_mem_subspace_eq_self x⟩).denseRange.comp + Completion.denseRange_coe Q.orthogonalProjectionOnto.continuous + intro x + change x ∈ R + exact hR.closure_subset_iff.mpr (Set.range_subset_iff.mpr hc) (hd x) + +def centeredEquiv (Ω : E) (hΩ : ‖Ω‖=1) : Completion (centered Ω) ≃ₗᵢ[ℂ] + centered (Ω : Completion E) := + LinearIsometryEquiv.ofSurjective (centeredMap Ω) (centeredMap_surjective Ω hΩ) + +end Kadison.HilbertCompletion +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConcreteCornerVonNeumann.lean b/lean/OAI/Analysis/Commutator/ConcreteCornerVonNeumann.lean new file mode 100644 index 0000000000000000000000000000000000000000..e6905715e96c01b2c8b7b180a2290b858aaca163 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConcreteCornerVonNeumann.lean @@ -0,0 +1,156 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.CornerCyclic + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.ConcreteCorner + +open MatrixCornerHilbert ReducingRepresentation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +instance closedCarrier : IsClosed (M.toStarSubalgebra : Set (H →L[ℂ] H)) := by + change IsClosed (M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + exact Set.isClosed_centralizer _ + +abbrev Algebra := M.toStarSubalgebra + +def inclusion : Algebra M →⋆ₐ[ℂ] (H →L[ℂ] H) := M.toStarSubalgebra.subtype + +@[simp] lemma inclusion_apply (a : Algebra M) : inclusion M a=(a:H →L[ℂ] H) := rfl + +lemma inclusion_injective : Function.Injective (inclusion M) := Subtype.val_injective + +lemma inclusion_range : Set.range (inclusion M)=(M : Set (H →L[ℂ] H)) := by + ext a + exact ⟨fun ⟨b,h⟩ => h ▸ b.property, fun h => ⟨⟨a,h⟩,rfl⟩⟩ + +variable {M} {p : Algebra M} (hp : IsStarProjection p) + +abbrev Space (_hp : IsStarProjection p) := fixedSpace (inclusion M p) + +abbrev representation := corner (inclusion M) hp + +abbrev project : H →L[ℂ] Space hp := cornerProjection (inclusion M) hp + +@[simp] lemma project_apply (x : H) : (project hp x:H)=(p:H →L[ℂ] H) x := rfl + +lemma representation_project (a : Corner hp) (x : H) : + (representation hp a (project hp x):H)=((a:Algebra M):H →L[ℂ] H) x := by + change ((a:Algebra M):H →L[ℂ] H) ((p:H →L[ℂ] H) x)=((a:Algebra M):H →L[ℂ] H) x + exact congrArg (fun b : Algebra M => (b:H →L[ℂ] H) x) a.property.2 + +lemma representation_injective : Function.Injective (representation hp) := by + intro a b h + apply Subtype.ext + apply Subtype.ext + ext x + have he := congrArg (fun T : Space hp →L[ℂ] Space hp => (T (project hp x):H)) h + simpa only [representation_project] using he + +def lift (T : Space hp →L[ℂ] Space hp) : H →L[ℂ] H := + (fixedSpace (inclusion M p)).subtypeL.comp (T.comp (project hp)) + +@[simp] lemma lift_apply (T : Space hp →L[ℂ] Space hp) (x : H) : + lift hp T x=(T (project hp x):H) := rfl + +@[simp] lemma project_fixed (x : Space hp) : project hp (x:H)=x := + cornerProjection_fixed (inclusion M) hp x + +lemma lift_left (T : Space hp →L[ℂ] Space hp) : (p:H →L[ℂ] H)*lift hp T=lift hp T := by + ext x + exact fixed_apply _ _ + +lemma lift_right (T : Space hp →L[ℂ] Space hp) : lift hp T*(p:H →L[ℂ] H)=lift hp T := by + ext x + change (T (project hp (project hp x:H)):H)=(T (project hp x):H) + rw [project_fixed] + +variable (R : H →L[ℂ] H) (hR : R∈M.commutant) + +include hR in +lemma commutant_preserves (x : H) (hx : x∈Space hp) : R x∈Space hp := by + rw [mem_fixedSpace] at hx ⊢ + have he := VonNeumannAlgebra.mem_commutant_iff.mp hR (p:H →L[ℂ] H) p.property + calc + inclusion M p (R x) = R (inclusion M p x) := congrArg (fun T : H →L[ℂ] H => T x) he + _ = R x := by rw [hx] + +def restrictCommutant : Space hp →L[ℂ] Space hp := R.restrict (commutant_preserves hp R hR) + +@[simp] lemma restrictCommutant_apply (x : Space hp) : (restrictCommutant hp R hR x:H)=R x := rfl + +lemma project_commutant (x : H) : project hp (R x)=restrictCommutant hp R hR (project hp x) := by + apply Subtype.ext + exact congrArg (fun T : H →L[ℂ] H => T x) + (VonNeumannAlgebra.mem_commutant_iff.mp hR (p:H →L[ℂ] H) p.property) + +lemma restrictCommutant_centralizer : restrictCommutant hp R hR ∈ + Set.centralizer (Set.range (representation hp)) := by + rintro _ ⟨a,rfl⟩ + ext x + exact congrArg (fun T : H →L[ℂ] H => T (x:H)) + (VonNeumannAlgebra.mem_commutant_iff.mp hR + ((a:Algebra M):H →L[ℂ] H) (a:Algebra M).property) + +include hR in +lemma lift_commutes {T : Space hp →L[ℂ] Space hp} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (representation hp)))) : + R*lift hp T=lift hp T*R := by + have he := hT _ (restrictCommutant_centralizer hp R hR) + ext x + change R (T (project hp x):H)=(T (project hp (R x)):H) + rw [project_commutant hp R hR] + exact congrArg (fun F : Space hp →L[ℂ] Space hp => (F (project hp x):H)) he + +lemma lift_mem {T : Space hp →L[ℂ] Space hp} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (representation hp)))) : + lift hp T∈M := by + rw [← SetLike.mem_coe,←M.centralizer_centralizer] + intro R hR + exact lift_commutes hp R (VonNeumannAlgebra.mem_commutant_iff.mpr hR) hT + +lemma corner_bicommutant : + Set.centralizer (Set.centralizer (Set.range (representation hp)))= + Set.range (representation hp) := by + apply Set.Subset.antisymm + · intro T hT + let a : Algebra M := ⟨lift hp T,lift_mem hp hT⟩ + let b : Corner hp := ⟨a,Subtype.ext (lift_left hp T),Subtype.ext (lift_right hp T)⟩ + refine ⟨b,?_⟩ + ext x + change (T (project hp (x:H)):H)=(T x:H) + rw [project_fixed] + · intro T hT R hR + exact (hR T hT).symm + +def vonNeumann : VonNeumannAlgebra (Space hp) where + toStarSubalgebra := (representation hp).range + centralizer_centralizer' := by + change Set.centralizer (Set.centralizer (Set.range (representation hp))) = + Set.range (representation hp) + exact corner_bicommutant hp + +lemma vonNeumann_range : Set.range (representation hp)= + (vonNeumann hp : Set (Space hp →L[ℂ] Space hp)) := rfl + +end Kadison.ConcreteCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConjugatedFreeness.lean b/lean/OAI/Analysis/Commutator/ConjugatedFreeness.lean new file mode 100644 index 0000000000000000000000000000000000000000..177d3fd4d1d3f0ffc8f71667b501059c37a4062b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConjugatedFreeness.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.Commutator.ConjugatedWordAlgebra +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.ConjugatedWords + +open Words + +variable {A B : Type} [CStarAlgebra A] [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable (φ : A →⋆ₐ[ℂ] B) (u : unitary B) + +def pair (c : Bool) : StarSubalgebra ℂ B := + if c then φ.range else ((Unitary.conjStarAlgAut ℂ B u).toStarAlgHom.comp φ).range + +variable (S : StarSubalgebra ℂ B) (ρ : B →ₗ[ℂ] ℂ) + +omit [PartialOrder B] [StarOrderedRing B] in +lemma trace_unitary_conjugation (hρ : ∀ a∈S,∀ b∈S,ρ (a*b)=ρ (b*a)) + (v : unitary B) (hv : (v:B)∈S) (a : B) (ha : a∈S) : + ρ ((v:B)*a*star (v:B))=ρ a := by + calc + _ = ρ ((a*star (v:B))*(v:B)) := by + rw [mul_assoc] + exact hρ _ hv _ (S.mul_mem ha (S.star_mem' hv)) + _ = ρ a := by rw [mul_assoc,v.property.1,mul_one] + +omit [PartialOrder B] [StarOrderedRing B] in +include S in +theorem free_of_centered_unitary_words (τ : A →ₗ[ℂ] ℂ) + (hu : (u:B)∈S) (hφ : ∀ a,φ a∈S) + (hρ : ∀ a∈S,∀ b∈S,ρ (a*b)=ρ (b*a)) + (htrace : ∀ a,ρ (φ a)=τ a) + (hword : ∀ (J : Type) (x : J → A),(∀ j,τ (x j)=0) → + ∀ l : List (Letter J Bool),l≠[] → Valid l → + ρ (word (φ ∘ x) signPower (PartialUnitary.ofUnitary u) l)=0) : + FreeMoments.Free (pair φ u) ρ := by + classical + let J := FreeMoments.Letter (pair φ u) ρ + have hpre (a : J) : ∃ x : A,τ x=0 ∧ + a.val=if a.color then φ x else (u:B)*φ x*star (u:B) := by + cases hc : a.color with + | false => + obtain ⟨x,hx⟩ := (show a.val∈((Unitary.conjStarAlgAut ℂ B u).toStarAlgHom.comp φ).range from by + simpa only [pair,hc,Bool.false_eq_true,ite_false] using a.mem) + have he : (u:B)*φ x*star (u:B)=a.val := hx + refine ⟨x,?_,by simpa only [hc,Bool.false_eq_true,ite_false] using he.symm⟩ + rw [←htrace,←trace_unitary_conjugation S ρ hρ u hu (φ x) (hφ x),he] + exact a.centered + | true => + obtain ⟨x,hx⟩ := (show a.val∈φ.range from by simpa only [pair,hc,ite_true] using a.mem) + change φ x=a.val at hx + refine ⟨x,?_,by simpa only [hc,ite_true] using hx.symm⟩ + rw [←htrace,hx] + exact a.centered + choose x hxc hx using hpre + have hval (a : J) : (leftUnitary u a.color:B)*φ (x a)*star (leftUnitary u a.color:B)=a.val := by + cases hc : a.color <;> simpa [leftUnitary,hc] using (hx a).symm + have hmem (a : J) : a.val∈S := by + rw [←hval a] + have hleft : (leftUnitary u a.color:B)∈S := by + cases a.color <;> simp only [leftUnitary] <;> first | exact hu | exact S.one_mem + exact S.mul_mem (S.mul_mem hleft (hφ _)) (S.star_mem' hleft) + intro w hw hne + have hwmem : FreeMoments.word w∈S := by + clear hw hne + induction w with + | nil => exact S.one_mem + | cons a l ih => exact S.mul_mem (hmem a) ih + cases w with + | nil => exact (hne rfl).elim + | cons a l => + let σ := a.color + let c : J → Bool := FreeMoments.Letter.color + have hv := encode_valid c σ (show (a::l).IsChain (fun a b : J => c a≠c b) from hw) + have hz := hword J x hxc (encode c σ (a::l)) (encode_ne_nil c σ (by simp)) hv + rw [word_encode] at hz + have he : ((a::l).map (fun a => (leftUnitary u (c a):B)*(φ ∘ x) a*star (leftUnitary u (c a):B))).prod= + FreeMoments.word (a::l) := by + apply congrArg List.prod + apply List.map_congr_left + intro j _ + exact hval j + rw [he] at hz + change ρ (star (leftUnitary u σ:B)*FreeMoments.word (a::l)*(leftUnitary u σ:B))=0 at hz + have hleft : (star (leftUnitary u σ):B)∈S := by + apply S.star_mem' + cases σ <;> simp only [leftUnitary] <;> first | exact hu | exact S.one_mem + have ht := trace_unitary_conjugation S ρ hρ (star (leftUnitary u σ)) hleft _ hwmem + simp only [Unitary.coe_star,star_star] at ht + exact ht.symm.trans hz + +end Kadison.FinitePatching.ConjugatedWords + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConjugatedWordAlgebra.lean b/lean/OAI/Analysis/Commutator/ConjugatedWordAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..9eda9bb20b8616dc3abcc68c543c1962d77497a0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConjugatedWordAlgebra.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryHom +import OAI.Analysis.Commutator.PartialWordReindex + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.ConjugatedWords + +open Words + +variable {B J : Type*} [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +def signPower (c : Bool) : ℤ := if c then 1 else -1 + +def leftUnitary (u : unitary B) (c : Bool) : unitary B := if c then 1 else u + +def transition (c d : Bool) : Slot Bool := if c=d then none else some (some c) + +def front (color : J → Bool) (σ : Bool) : List J → Bool + | [] => σ + | a::_ => color a + +def encode (color : J → Bool) (σ : Bool) : List J → List (Letter J Bool) + | [] => [] + | a::l => (a,transition (color a) (front color σ l))::encode color σ l + +omit [PartialOrder B] [StarOrderedRing B] in +lemma transition_power (u : unitary B) (c d : Bool) : + slotPower signPower (PartialUnitary.ofUnitary u) (transition c d)= + star (leftUnitary u c:B)*(leftUnitary u d:B) := by + cases c <;> cases d <;> + simp [transition,signPower,slotPower,leftUnitary, + PartialUnitary.ofUnitary_power_one,PartialUnitary.ofUnitary_power_neg_one, + u.property.1] + +@[simp] lemma encode_length (color : J → Bool) (σ : Bool) (l : List J) : + (encode color σ l).length=l.length := by + induction l with + | nil => rfl + | cons a l ih => simp [encode,ih] + +lemma encode_ne_nil (color : J → Bool) (σ : Bool) {l : List J} (hl : l≠[]) : + encode color σ l≠[] := by + intro he + have hh := congrArg List.length he + simp only [encode_length,List.length_nil,List.length_eq_zero_iff] at hh + exact hl hh + +lemma encode_valid (color : J → Bool) (σ : Bool) {l : List J} + (hl : l.IsChain (fun a b => color a≠color b)) : Valid (encode color σ l) := by + induction l with + | nil => + intro s i t he ht + have hh := congrArg List.length he + simp only [encode,List.length_nil,List.length_append,List.length_cons] at hh + omega + | cons a l ih => + rw [encode,valid_cons_iff] + refine ⟨ih hl.tail,?_⟩ + intro hne + cases l with + | nil => exact (hne rfl).elim + | cons b l => + have hab := (List.isChain_cons_cons.mp hl).1 + refine ⟨color a,?_⟩ + change (if color a=color b then (none : Slot Bool) else some (some (color a)))=some (some (color a)) + exact ite_eq_right hab + +omit [PartialOrder B] [StarOrderedRing B] in +lemma word_encode (u : unitary B) (x : J → B) (color : J → Bool) + (σ : Bool) (l : List J) : + word x signPower (PartialUnitary.ofUnitary u) (encode color σ l)= + star (leftUnitary u (front color σ l):B)* + (l.map (fun a => (leftUnitary u (color a):B)*x a*star (leftUnitary u (color a):B))).prod* + (leftUnitary u σ:B) := by + induction l with + | nil => simp only [encode,word_nil,List.map_nil,List.prod_nil,front,mul_one]; exact (leftUnitary u σ).property.1.symm + | cons a l ih => + simp only [encode,word_cons,letter,transition_power,ih,List.map_cons,List.prod_cons,front] + let v := leftUnitary u (color a) + let w := leftUnitary u (front color σ l) + let z := (l.map (fun a => (leftUnitary u (color a):B)*x a*star (leftUnitary u (color a):B))).prod + change x a*(star (v:B)*(w:B))*(star (w:B)*z*(leftUnitary u σ:B))= + star (v:B)*((v:B)*x a*star (v:B)*z)*(leftUnitary u σ:B) + calc + _=x a*star (v:B)*((w:B)*star (w:B))*z*(leftUnitary u σ:B) := by noncomm_ring + _=x a*star (v:B)*z*(leftUnitary u σ:B) := by rw [w.property.2,mul_one] + _=(star (v:B)*(v:B))*(x a*star (v:B)*z)*(leftUnitary u σ:B) := by rw [v.property.1,one_mul] + _=_ := by noncomm_ring + +end Kadison.FinitePatching.ConjugatedWords + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConjugationNormalizer.lean b/lean/OAI/Analysis/Commutator/ConjugationNormalizer.lean new file mode 100644 index 0000000000000000000000000000000000000000..8b9406537d3f1f434c6afeb3ba71d2ba44250705 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConjugationNormalizer.lean @@ -0,0 +1,33 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {M : Type*} [Mul M] + +lemma mem_bicommutant_of_maps_generators (α : M ≃* M) (S : Set M) + (hα : ∀ x∈S, α x∈S) {a : M} (ha : a∈Set.centralizer (Set.centralizer S)) : + α a∈Set.centralizer (Set.centralizer S) := by + intro b hb + have hb' : α.symm b∈Set.centralizer S := by + intro x hx + apply α.injective + simpa only [map_mul,MulEquiv.apply_symm_apply] using hb (α x) (hα x hx) + have h := congrArg α (ha (α.symm b) hb') + simpa only [map_mul,MulEquiv.apply_symm_apply] using h + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConstantSequenceClosedTransport.lean b/lean/OAI/Analysis/Commutator/ConstantSequenceClosedTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..f2a33ec46f9905cf016b7ccb9c958ad67d4a2b68 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConstantSequenceClosedTransport.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.Commutator.ConstantSequenceRange +import OAI.Analysis.Commutator.TraceEquivGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Topology BoundedContinuousFunction + +namespace Kadison.TracialSequence + +open TracialGNS + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma constant_vector_closed_of_GNS (hclosed : IsClosed {x : τ.GNS | ∃ a : A,‖a‖≤1 ∧ algebraVector τ a=x}) : + IsClosed {x : boundedSubspace τ ω | ∃ a : A,‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x} := by + have heq (a : A) : vectorIn τ ω (constantSequence a)=constantIn τ ω (algebraVector τ a) := by + apply Subtype.ext + exact vector_const τ ω a + have hc := (constantIn τ ω).isometry.isClosedEmbedding.isClosedMap _ hclosed + suffices he : {x : boundedSubspace τ ω | ∃ a : A,‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x} = + (constantIn τ ω) '' {x : τ.GNS | ∃ a : A,‖a‖≤1 ∧ algebraVector τ a=x} by + rw [he] + exact hc + ext x + constructor + · rintro ⟨a,ha,hax⟩ + exact ⟨algebraVector τ a,⟨a,ha,rfl⟩,(heq a).symm.trans hax⟩ + · rintro ⟨y,⟨a,ha,rfl⟩,hy⟩ + exact ⟨a,ha,(heq a).trans hy⟩ + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (e : A ≃⋆ₐ[ℂ] M) (σ : M →ₚ[ℂ] ℂ) + +lemma constant_range_bicommutant_of_equiv (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (htrace : ∀ a,σ (e a)=τ a) (hnormal : NormalGNS.BoundedWOTContinuous M σ) : + Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp constantSequence)))=Set.range ((leftRestricted τ ω).comp constantSequence) := by + apply constant_range_bicommutant_of_closed τ ω hτ + apply constant_vector_closed_of_GNS τ ω + exact TraceEquivGNS.vector_unitball_closed e τ σ htrace + (NormalGNS.vector_unitball_isClosed M σ hnormal) + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConstantSequenceRange.lean b/lean/OAI/Analysis/Commutator/ConstantSequenceRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae41c7f1f5be548cba94858322b89ef1a63cee4c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConstantSequenceRange.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialDoubleCompression + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence + +section Represented + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma constant_vectorIn (a : M) : vectorIn τ ω (constantSequence a)=constantIn τ ω (algebraVector τ a) := by + apply Subtype.ext + exact vector_const τ ω a + +lemma constant_vector_unitball_isClosed (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + IsClosed {x : boundedSubspace τ ω | ∃ a : M, ‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x} := by + have hc := (constantIn τ ω).isometry.isClosedEmbedding.isClosedMap _ + (NormalGNS.vector_unitball_isClosed M τ hnormal) + suffices he : {x : boundedSubspace τ ω | ∃ a : M, ‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x} = + (constantIn τ ω) '' {x : τ.GNS | ∃ a : M, ‖a‖≤1 ∧ algebraVector τ a=x} by + exact (congrArg IsClosed he).mpr hc + ext x + constructor + · rintro ⟨a,ha,hax⟩ + exact ⟨algebraVector τ a,⟨a,ha,rfl⟩,(constant_vectorIn M τ ω a).symm.trans hax⟩ + · rintro ⟨y,⟨a,ha,rfl⟩,hy⟩ + exact ⟨a,ha,(constant_vectorIn M τ ω a).trans hy⟩ + +end Represented + +section Abstract + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +include hτ in +lemma constant_bicommutant_contraction (hclosed : IsClosed {x : boundedSubspace τ ω | ∃ a : A, ‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x}) + {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp constantSequence)))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) : + ∃ a : A, ‖a‖≤1 ∧ leftRestricted τ ω (constantSequence a)=T := by + let φ := (leftRestricted τ ω).comp constantSequence + have hx : T (sequenceVacuum τ ω)∈closure + {x : boundedSubspace τ ω | ∃ a : A, ‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x} := by + apply Metric.mem_closure_iff.mpr + intro ε hε + obtain ⟨a,_,hna,ha⟩ := Kaplansky.range_selfAdjoint_contraction_finite_approx + Unit φ hT hsT hnT (fun _ => sequenceVacuum τ ω) ε hε + refine ⟨vectorIn τ ω (constantSequence a),⟨a,hna,rfl⟩,?_⟩ + rw [dist_eq_norm,norm_sub_rev] + change ‖vectorIn τ ω (constantSequence a)-T (sequenceVacuum τ ω)‖<ε + rw [←leftRestricted_vacuum] + exact ha () + rw [hclosed.closure_eq] at hx + obtain ⟨a,hna,ha⟩ := hx + refine ⟨a,hna,bicommutant_eq_of_vacuum τ ω hτ _ _ ?_ ?_ ?_⟩ + · exact Set.subset_centralizer_centralizer (Set.mem_range_self (constantSequence a)) + · intro c hc + apply hT c + rintro _ ⟨b,rfl⟩ + exact hc _ ⟨constantSequence b,rfl⟩ + · simpa only [leftRestricted_vacuum] using ha + +lemma constant_range_bicommutant_of_closed + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (hclosed : IsClosed {x : boundedSubspace τ ω | ∃ a : A, ‖a‖≤1 ∧ vectorIn τ ω (constantSequence a)=x}) : + Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp constantSequence)))= + Set.range ((leftRestricted τ ω).comp constantSequence) := by + exact BicommutantRange.operatorHom_range (H := boundedSubspace τ ω) + ((leftRestricted τ ω).comp constantSequence) fun T hT hsT hnT => + (constant_bicommutant_contraction τ ω hτ hclosed hT hsT hnT).imp fun _ ha => ha.2 + +end Abstract + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma constant_range_bicommutant (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp constantSequence)))= + Set.range ((leftRestricted τ ω).comp constantSequence) := + constant_range_bicommutant_of_closed τ ω hτ (constant_vector_unitball_isClosed M τ ω hnormal) + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ConvexIsometryFix.lean b/lean/OAI/Analysis/Commutator/ConvexIsometryFix.lean new file mode 100644 index 0000000000000000000000000000000000000000..0b92b0c675c7f9d49d7220dffadef965504ef770 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ConvexIsometryFix.lean @@ -0,0 +1,53 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.ConvexIsometry + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_fixed (K : Set H) (hne : K.Nonempty) (hclosed : IsClosed K) + (hconv : Convex ℝ K) : + ∃ z∈K, ∀ U : H →ₗᵢ[ℂ] H, (∀ x∈K, U x∈K) → U z=z := by + let : InnerProductSpace ℝ H := InnerProductSpace.rclikeToReal ℂ H + obtain ⟨z,hz,hmin⟩ := exists_norm_eq_iInf_of_complete_convex hne hclosed.isComplete hconv (0:H) + refine ⟨z,hz,?_⟩ + intro U hUK + have huz := hUK z hz + have hmin' : ‖(0:H)-U z‖=⨅ w : K, ‖(0:H)-(w:H)‖ := by + simpa only [zero_sub,norm_neg,U.norm_map] using hmin + have ha := (norm_eq_iInf_iff_real_inner_le_zero hconv hz).mp hmin (U z) huz + have hb := (norm_eq_iInf_iff_real_inner_le_zero hconv huz).mp hmin' z hz + have hc : ‖U z-z‖^2=‖U z‖^2-2*inner ℝ (U z) z+‖z‖^2 := norm_sub_sq_real _ _ + simp only [zero_sub,inner_neg_left,inner_sub_right,real_inner_self_eq_norm_sq] at ha hb + have he : inner ℝ z (U z)=inner ℝ (U z) z := real_inner_comm _ _ + rw [he] at ha + have hd : ‖U z-z‖=0 := by nlinarith [norm_nonneg (U z-z)] + exact sub_eq_zero.mp (norm_eq_zero.mp hd) + +omit [CompleteSpace H] in +lemma maps_closedConvexHull (U : H →ₗᵢ[ℂ] H) (S : Set H) + (hU : ∀ x∈S, U x∈S) : + ∀ x∈closedConvexHull ℝ S, U x∈closedConvexHull ℝ S := by + have hconv : Convex ℝ (U ⁻¹' closedConvexHull ℝ S) := + convex_closedConvexHull.linear_preimage (U.toLinearMap.restrictScalars ℝ) + have hcl : IsClosed (U ⁻¹' closedConvexHull ℝ S) := + isClosed_closedConvexHull.preimage U.continuous + exact closedConvexHull_min (fun x hx => subset_closedConvexHull (hU x hx)) hconv hcl + +end Kadison.ConvexIsometry + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerAlgebra.lean b/lean/OAI/Analysis/Commutator/CornerAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..47dc7694050fde026395d5e491e71e0da3a9e8a4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerAlgebra.lean @@ -0,0 +1,135 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {A : Type*} [CStarAlgebra A] {p : A} (hp : IsStarProjection p) + +def cornerSubalgebra : NonUnitalStarSubalgebra ℂ A where + carrier := {a | p*a=a ∧ a*p=a} + zero_mem' := by simp + add_mem' := by rintro a b ⟨ha, ha'⟩ ⟨hb,hb'⟩; simp [mul_add, add_mul, ha, ha', hb, 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 rintro c a ⟨ha,ha'⟩; simp [ha, ha'] + star_mem' := by + rintro a ⟨ha,ha'⟩ + constructor + · simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star ha' + · simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star ha + +def Corner : Type _ := ↥(cornerSubalgebra hp) + +instance : CoeOut (Corner hp) A := ⟨Subtype.val⟩ + +instance : Ring (Corner hp) where + __ : NonUnitalRing (Corner hp) := inferInstanceAs (NonUnitalRing (cornerSubalgebra hp)) + one := ⟨p, hp.isIdempotentElem.eq, hp.isIdempotentElem.eq⟩ + one_mul a := Subtype.ext a.property.1 + mul_one a := Subtype.ext a.property.2 + +instance : NormedRing (Corner hp) where + __ : Ring (Corner hp) := inferInstance + __ : NonUnitalNormedRing (Corner hp) := inferInstanceAs (NonUnitalNormedRing (cornerSubalgebra hp)) + +instance : StarRing (Corner hp) := inferInstanceAs (StarRing (cornerSubalgebra hp)) + +instance : Module ℂ (Corner hp) := inferInstanceAs (Module ℂ (cornerSubalgebra hp)) + +instance : NormedSpace ℂ (Corner hp) := inferInstanceAs (NormedSpace ℂ (cornerSubalgebra hp)) + +instance : IsScalarTower ℂ (Corner hp) (Corner hp) := + inferInstanceAs (IsScalarTower ℂ (cornerSubalgebra hp) (cornerSubalgebra hp)) + +instance : SMulCommClass ℂ (Corner hp) (Corner hp) := + inferInstanceAs (SMulCommClass ℂ (cornerSubalgebra hp) (cornerSubalgebra hp)) + +instance : Algebra ℂ (Corner hp) := Algebra.ofModule smul_mul_assoc mul_smul_comm + +instance : NormedAlgebra ℂ (Corner hp) where + norm_smul_le := norm_smul_le + +instance : StarModule ℂ (Corner hp) := inferInstanceAs (StarModule ℂ (cornerSubalgebra hp)) + +instance : CStarRing (Corner hp) where + norm_mul_self_le x := (CStarRing.norm_star_mul_self (x := (x : A))).symm.le + +lemma cornerSubalgebra_closed : IsClosed ((cornerSubalgebra hp : NonUnitalStarSubalgebra ℂ A) : Set A) := + (isClosed_eq (by fun_prop : Continuous (fun a : A => p*a)) continuous_id).inter + (isClosed_eq (by fun_prop : Continuous (fun a : A => a*p)) continuous_id) + +instance : CompleteSpace (Corner hp) := (cornerSubalgebra_closed hp).completeSpace_coe + +instance : CStarAlgebra (Corner hp) where + +@[simp] lemma corner_one : ((1 : Corner hp) : A) = p := rfl + +@[simp] lemma corner_add (a b : Corner hp) : ((a+b : Corner hp) : A) = (a : A)+(b : A) := rfl + +@[simp] lemma corner_mul (a b : Corner hp) : ((a*b : Corner hp) : A) = (a : A)*(b : A) := rfl + +@[simp] lemma corner_star (a : Corner hp) : ((star a : Corner hp) : A) = star (a : A) := rfl + +@[simp] lemma corner_norm (a : Corner hp) : ‖a‖=‖(a : A)‖ := rfl + +end Kadison + +namespace Kadison + +variable {A : Type*} [CStarAlgebra A] {p : A} (hp : IsStarProjection p) + +instance cornerOrder : PartialOrder (Corner hp) := CStarAlgebra.spectralOrder (Corner hp) + +instance cornerStarOrdered : StarOrderedRing (Corner hp) := CStarAlgebra.spectralOrderedRing (Corner hp) + +def cornerInclusion : Corner hp →⋆ₙₐ[ℂ] A := NonUnitalStarSubalgebraClass.subtype (cornerSubalgebra hp) + +@[simp] lemma cornerInclusion_apply (a : Corner hp) : cornerInclusion hp a = (a : A) := rfl + +variable [PartialOrder A] [StarOrderedRing A] + +open scoped ComplexOrder + +def cornerFunctional (τ : A →ₚ[ℂ] ℂ) (r : ℝ) (hr : 0 TracialGNS.algebraVector τ (normalizedStageAlphabet φ p hp e α g)) := by + apply orthonormal_iff_ite.mpr + intro g h + simp only [normalizedStageAlphabet,map_smul,inner_smul_left,inner_smul_right, + Complex.conj_ofReal,TracialGNS.inner_algebraVector,stageAlphabet_gram τ hτ h1] + by_cases heq : g=h + · rw [ite_eq_left heq,ite_eq_left heq,hατ] + rw [←mul_assoc,←sq,normalization_sq α hα,inv_mul_cancel₀ (Complex.ofReal_ne_zero.mpr hα.ne')] + · rw [ite_eq_right heq,ite_eq_right heq,mul_zero,mul_zero] + +omit [PartialOrder A] [StarOrderedRing A] [Nonempty I] in +lemma normalizedStageAlphabet_norm_le (g : G) : ‖normalizedStageAlphabet φ p hp e α g‖≤(Real.sqrt α)⁻¹ := by + rw [normalizedStageAlphabet,norm_smul,Complex.norm_real,Real.norm_eq_abs, + abs_of_nonneg (inv_nonneg.mpr (Real.sqrt_nonneg α))] + simpa only [mul_one] using mul_le_mul_of_nonneg_left (stageAlphabet_norm_le φ p hp e g) + (inv_nonneg.mpr (Real.sqrt_nonneg α)) + +include hα in +omit [PartialOrder A] [StarOrderedRing A] [Nonempty I] in +lemma normalizedStageAlphabet_star_mul (g : G) : + star (normalizedStageAlphabet φ p hp e α g)*normalizedStageAlphabet φ p hp e α g= + ((α:ℂ)⁻¹) • φ p := by + rw [normalizedStageAlphabet,star_smul,smul_mul_smul_comm,Complex.star_def,Complex.conj_ofReal, + stageAlphabet_star_mul,←sq,normalization_sq α hα] + +omit [PartialOrder A] [StarOrderedRing A] [Nonempty I] in +lemma normalizedStageAlphabet_support (g : G) : + normalizedStageAlphabet φ p hp e α g*φ p=normalizedStageAlphabet φ p hp e α g := by + rw [normalizedStageAlphabet,smul_mul_assoc,stageAlphabet_support] + +include hτ h1 in +omit [StarOrderedRing A] in +lemma normalizedStageAlphabet_centered (g : G) (hg : g≠0) : + τ (normalizedStageAlphabet φ p hp e α g)=0 := by + rw [normalizedStageAlphabet,map_smul,stageAlphabet_centered τ hτ h1 φ p hp e g hg,smul_zero] + +include hτ h1 hατ in +omit [StarOrderedRing A] in +lemma projection_rank : (Fintype.card (projectionIndices p hp):ℝ)=α*Fintype.card I := by + have hd : (Fintype.card I:ℂ)≠0 := by exact_mod_cast Fintype.card_ne_zero + have hc : (Fintype.card (projectionIndices p hp):ℂ)=(α:ℂ)*Fintype.card I := by + rw [←hατ,TracialGNS.stage_trace τ hτ h1 φ,projection_trace p hp] + field_simp + have hr := congrArg Complex.re hc + simpa using hr + +include hτ h1 hα hατ hp in +theorem exists_normalized_corner_alphabet (N : ℕ) + (hN : (N+1:ℝ)≤α*Fintype.card I) : + ∃ m : ℕ, N ≤ m ∧ ∃ x : Fin m → A, + Orthonormal ℂ (fun i => TracialGNS.algebraVector τ (x i)) ∧ + ∀ i, τ (x i)=0 ∧ x i*φ p=x i ∧ star (x i)*x i=((α:ℂ)⁻¹) • φ p ∧ + ‖x i‖≤(Real.sqrt α)⁻¹ := by + let r := Fintype.card (projectionIndices p hp) + have hrN : N+1≤r := by + have h := hN.trans_eq (projection_rank τ hτ h1 φ p hp α hατ).symm + exact_mod_cast h + have hr : 0 g=0),Fintype.card_subtype_eq,ZMod.card] + let b : Fin m ≃ J := (Fintype.equivFin J).symm + let x : Fin m → A := fun i => normalizedStageAlphabet φ p hp e α (b i).val + refine ⟨m,by omega,x,?_,?_⟩ + · exact (normalizedStageAlphabet_orthonormal τ hτ h1 φ p hp e α hα hατ).comp + (fun i => (b i).val) (Subtype.val_injective.comp b.injective) + · intro i + exact ⟨normalizedStageAlphabet_centered τ hτ h1 φ p hp e α _ (b i).property, + normalizedStageAlphabet_support φ p hp e α _, + normalizedStageAlphabet_star_mul φ p hp e α hα _, + normalizedStageAlphabet_norm_le φ p hp e α _⟩ + +end Kadison.MatrixCorners + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerCenteredEstimates.lean b/lean/OAI/Analysis/Commutator/CornerCenteredEstimates.lean new file mode 100644 index 0000000000000000000000000000000000000000..d29725781f09eeb9554cfb020d3916a9a03703d4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerCenteredEstimates.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialL2Tools + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching + +open TracialL2 + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +def cornerScalar (p b : A) : ℂ := τ (p*b)/τ p + +def cornerCenter (p b : A) : A := p*b*p-cornerScalar τ p b • p + +lemma projection_trace_real {p : A} (hp : IsStarProjection p) : τ p=((τ p).re:ℂ) := by + apply Complex.ext + · rfl + have h := (τ.map_nonneg hp.nonneg).2 + simpa only [Complex.zero_im,Complex.ofReal_im] using h.symm + +lemma projection_trace_norm {p : A} (hp : IsStarProjection p) : ‖τ p‖=(τ p).re := by + calc + _=‖((τ p).re:ℂ)‖ := congrArg (fun z : ℂ => ‖z‖) (projection_trace_real τ hp) + _=(τ p).re := by + rw [Complex.norm_real,Real.norm_of_nonneg (τ.map_nonneg hp.nonneg).1] + +omit [StarOrderedRing A] in +lemma cornerCenter_left {p : A} (hp : IsStarProjection p) (b : A) : + p*cornerCenter τ p b=cornerCenter τ p b := by + simp only [cornerCenter,mul_sub,mul_smul_comm,←mul_assoc,hp.isIdempotentElem.eq] + +omit [StarOrderedRing A] in +lemma cornerCenter_right {p : A} (hp : IsStarProjection p) (b : A) : + cornerCenter τ p b*p=cornerCenter τ p b := by + simp only [cornerCenter,sub_mul,smul_mul_assoc,mul_assoc,hp.isIdempotentElem.eq] + +include hτ in +omit [StarOrderedRing A] in +lemma cornerCenter_trace {p : A} (hp : IsStarProjection p) (ht : 0<(τ p).re) (b : A) : + τ (cornerCenter τ p b)=0 := by + have ht0 : τ p≠0 := fun h => by rw [h,Complex.zero_re] at ht; exact lt_irrefl _ ht + have he : τ (p*b*p)=τ (p*b) := by rw [hτ (p*b),←mul_assoc,hp.isIdempotentElem.eq] + simp only [cornerCenter,map_sub,map_smul,smul_eq_mul,cornerScalar,he] + rw [div_mul_cancel₀ _ ht0,sub_self] + +lemma compress_center {p q : A} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hqp : q ≤ p) (b : A) : + q*b*q=q*cornerCenter τ p b*q+cornerScalar τ p b • q := by + have h1 := (hq.le_iff_mul_eq_left hp).mp hqp + have h2 := (hq.le_iff_mul_eq_right hp).mp hqp + simp only [cornerCenter,mul_sub,sub_mul,mul_smul_comm,smul_mul_assoc] + have h3 : q*(p*b*p)*q=q*b*q := by + calc + _=(q*p)*b*(p*q) := by noncomm_ring + _=_ := by rw [h1,h2] + rw [h3,h1,hq.isIdempotentElem.eq,sub_add_cancel] + +lemma compressed_bound {p q : A} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hqp : q ≤ p) (b : A) {δ : ℝ} (hδ : 0 ≤ δ) + (hsmall : norm τ (q*cornerCenter τ p b*q)^2 ≤ δ^2*(τ q).re) : + norm τ (q*b*q)*norm τ q ≤ (δ+‖cornerScalar τ p b‖)*(τ q).re := by + have hsmall' : norm τ (q*cornerCenter τ p b*q) ≤ δ*norm τ q := by + apply (sq_le_sq₀ (norm_nonneg τ _) (mul_nonneg hδ (norm_nonneg τ _))).mp + rw [mul_pow,norm_projection_sq τ hq] + exact hsmall + have hh : norm τ (q*b*q) ≤ (δ+‖cornerScalar τ p b‖)*norm τ q := by + rw [compress_center τ hp hq hqp b] + calc + _ ≤ norm τ (q*cornerCenter τ p b*q)+norm τ (cornerScalar τ p b • q) := + norm_add τ _ _ + _ ≤ δ*norm τ q+‖cornerScalar τ p b‖*norm τ q := by + rw [TracialL2.norm_smul] + exact add_le_add hsmall' le_rfl + _=_ := by ring + calc + _ ≤ ((δ+‖cornerScalar τ p b‖)*norm τ q)*norm τ q := + mul_le_mul_of_nonneg_right hh (norm_nonneg τ _) + _ = (δ+‖cornerScalar τ p b‖)*(norm τ q)^2 := by ring + _ = _ := by rw [norm_projection_sq τ hq] + +include hτ in +lemma trace_centered_compression_bound {p q b a c w z : A} + (hp : IsStarProjection p) (hq : IsStarProjection q) (hqp : q ≤ p) + (hw : w*q=w) (hz : q*z=z) + (ha : ‖a‖ ≤ 1) (hc : ‖c‖ ≤ 1) (hwn : ‖w‖ ≤ 1) (hzn : ‖z‖ ≤ 1) + {δ : ℝ} (hδ : 0 ≤ δ) + (hsmall : norm τ (q*cornerCenter τ p b*q)^2 ≤ δ^2*(τ q).re) : + ‖τ (a*w*b*z*c)‖ ≤ (δ+‖cornerScalar τ p b‖)*(τ q).re := + (trace_two_corner_letters τ hτ hq hw hz ha hc hwn hzn).trans + (compressed_bound τ hp hq hqp b hδ hsmall) + +include hτ in +lemma trace_single_support_bound {p q : A} (hp : IsStarProjection p) + (hq : IsStarProjection q) (hqp : q ≤ p) (b : A) {δ : ℝ} (hδ : 0 ≤ δ) + (hsmall : norm τ (q*cornerCenter τ p b*q)^2 ≤ δ^2*(τ q).re) : + ‖τ (q*b)‖ ≤ (δ+‖cornerScalar τ p b‖)*(τ q).re := by + have he : τ (q*b)=τ ((q*b*q)*q) := by + rw [mul_assoc (q*b),hq.isIdempotentElem.eq,hτ (q*b),←mul_assoc,hq.isIdempotentElem.eq] + rw [he] + exact (norm_trace_mul τ hτ _ _).trans (compressed_bound τ hp hq hqp b hδ hsmall) + +lemma cornerScalar_complement_bound {f : A} (hf : IsStarProjection f) (b : A) + {t B : ℝ} (ht : 0 σ a Ω)) (hpΩ : σ p Ω=Ω) : + DenseRange (fun a : Corner hp => corner σ hp a + (⟨Ω,(mem_fixedSpace _ _).mpr hpΩ⟩ : fixedSpace (σ p))) := by + have hs : Function.Surjective (cornerProjection σ hp) := fun x => ⟨(x:H),cornerProjection_fixed σ hp x⟩ + have hd := hs.denseRange.comp hΩ (cornerProjection σ hp).continuous + intro x + apply (closure_mono ?_) (hd x) + rintro _ ⟨a,rfl⟩ + let b : Corner hp := ⟨p*a*p,by rw [←mul_assoc,←mul_assoc,hp.isIdempotentElem.eq], + by rw [mul_assoc _ p p,hp.isIdempotentElem.eq]⟩ + refine ⟨b,?_⟩ + apply Subtype.ext + change σ (p*a*p) Ω=σ p (σ a Ω) + simp only [map_mul,mul_apply_eq_comp,hpΩ] + +end Kadison.ReducingRepresentation + +namespace Kadison.MatrixCornerImplementation + +open MatrixCornerHilbert ReducingRepresentation ConcreteCorner MatrixCornerExtension + +variable {H K ι : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [Fintype ι] [DecidableEq ι] + +variable (M : VonNeumannAlgebra H) + (σ : Algebra M →⋆ₐ[ℂ] (K →L[ℂ] K)) (j : K →ₗᵢ[ℂ] H) + (hj : ∀ a x, j (σ a x)=inclusion M a (j x)) + +variable {p : Algebra M} (hp : IsStarProjection p) + +def cornerEmbedding : fixedSpace (σ p) →ₗᵢ[ℂ] Space hp where + toFun x := ⟨j (x:K),by + rw [mem_fixedSpace,←hj,MatrixCornerHilbert.fixed_apply]⟩ + map_add' x y := Subtype.ext (map_add j (x:K) (y:K)) + map_smul' z x := Subtype.ext (map_smul j z (x:K)) + norm_map' x := j.norm_map (x:K) + +lemma cornerEmbedding_intertwines (a : Corner hp) (x : fixedSpace (σ p)) : + cornerEmbedding M σ j hj hp (corner σ hp a x)= + representation hp a (cornerEmbedding M σ j hj hp x) := by + apply Subtype.ext + exact hj (a:Algebra M) (x:K) + +variable (G : K →L[ℂ] H) (hGp : ∀ x, G (σ p x)=inclusion M p (G x)) + +local instance : NormedAddCommGroup (fixedSpace (σ p) →L[ℂ] Space hp) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (fixedSpace (σ p) →L[ℂ] Space hp) := ContinuousLinearMap.toNormedSpace + +omit [Fintype ι] [DecidableEq ι] in +lemma corner_derivation_bound {ε : ℝ} (hε : 0≤ε) + (hδ : ∀ a : Corner hp, ‖G.comp (σ (a:Algebra M))-(inclusion M (a:Algebra M)).comp G‖≤ε*‖a‖) + (a : Corner hp) : + ‖(cornerMap σ (inclusion M) G hGp).comp (corner σ hp a)- + (representation hp a).comp (cornerMap σ (inclusion M) G hGp)‖≤ε*‖a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg hε (norm_nonneg _)) + intro x + change ‖G (σ (a:Algebra M) (x:K))-inclusion M (a:Algebra M) (G (x:K))‖≤(ε*‖a‖)*‖x‖ + exact ((G.comp (σ (a:Algebra M))-(inclusion M (a:Algebra M)).comp G).le_opNorm (x:K)).trans + (mul_le_mul_of_nonneg_right (hδ a) (norm_nonneg _)) + +include hj hGp in +theorem exists_matrix_corner_intertwiner (v : ι → Algebra M) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + (hGv : ∀ i x, G (σ (v i) x)=inclusion M (v i) (G x)) + (Ω : K) (hΩ : DenseRange (fun a : Algebra M => σ a Ω)) (hpΩ : σ p Ω=Ω) + {ε : ℝ} (hε : 0≤ε) + (hδ : ∀ a : Corner hp, ‖G.comp (σ (a:Algebra M))-(inclusion M (a:Algebra M)).comp G‖≤ε*‖a‖) : + ∃ T : K →L[ℂ] H, (∀ a : Algebra M, T.comp (σ a)=(inclusion M a).comp T) ∧ + ‖G-T‖≤16*ε := by + let Ωp : fixedSpace (σ p) := ⟨Ω,(mem_fixedSpace _ _).mpr hpΩ⟩ + obtain ⟨T,hT,hn⟩ := CyclicSpatial.exists_embedded_cyclic_intertwiner + (corner σ hp) (representation hp) (cornerEmbedding M σ j hj hp) + (cornerEmbedding_intertwines M σ j hj hp) (vonNeumann hp) + (representation_injective hp) (vonNeumann_range hp) + (cornerMap σ (inclusion M) G hGp) Ωp (corner_dense σ hp Ω hΩ hpΩ) hε + (corner_derivation_bound M σ hp G hGp hε hδ) + refine ⟨extend σ (inclusion M) v hcol hinit htotal T,?_,?_⟩ + · exact extend_intertwines σ (inclusion M) hp v hcol hinit htotal T hT + · exact (norm_sub_extend_le σ (inclusion M) v hcol hinit htotal G hGp T hGv).trans hn + +end Kadison.MatrixCornerImplementation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerHaarSequence.lean b/lean/OAI/Analysis/Commutator/CornerHaarSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..0673f80eb78914fa69d92d682a4f1960452503d3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerHaarSequence.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.HaarSequence + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison + +variable {A : Type*} [CStarAlgebra A] {p : A} (hp : IsStarProjection p) + +end Kadison + +namespace Kadison + +variable {A : Type*} [CStarAlgebra A] {p : A} (hp : IsStarProjection p) + +variable [PartialOrder A] [StarOrderedRing A] + +open scoped ComplexOrder + +end Kadison + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open UniformSpace Filter Topology + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : τ 1=1) (z : unitary A) + +end Kadison + +namespace Kadison + +open scoped InnerProductSpace ComplexOrder + +open UniformSpace Filter Topology + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {p : A} (hp : IsStarProjection p) (τ : A →ₚ[ℂ] ℂ) + +variable {r : ℝ} (hr : 0 + (τ.toPreGNS (cornerScaled hp r ((z : Corner hp)^n)) : τ.GNS)) := by + rw [orthonormal_iff_ite] + intro n m + rw [Completion.inner_coe, PositiveLinearMap.preGNS_inner_def] + change τ (star (cornerScaled hp r ((z : Corner hp)^n))* + cornerScaled hp r ((z : Corner hp)^m))=_ + rw [cornerScaled_gram] + exact haar_pow_gram _ (cornerFunctional_normalized hp τ hr hτp) z hH n m + +end Kadison + +namespace Kadison + +open scoped InnerProductSpace ComplexOrder + +open UniformSpace Filter Topology + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {p : A} (hp : IsStarProjection p) (τ : A →ₚ[ℂ] ℂ) + +variable {r : ℝ} (hr : 0 (a : A)) hz + simp only [corner_mul, corner_star, corner_one] at hz' + rw [hz'] + exact Complex.coe_smul _ _ + +include hτp in +lemma cornerHaar_norm_one (z : unitary (Corner hp)) (n : ℕ) + (hH : ∀ k : ℕ, 0 τ (cornerScaled hp r ((z : Corner hp)^n)*a)) atTop (𝓝 0) := by + have hon := cornerHaar_orthonormal hp τ hr hτp z⁻¹ (inverse_haar_moments _ z hH) + have h := orthonormal_inner_tendsto_zero _ hon (τ.toPreGNS a : τ.GNS) + have hs (n : ℕ) : star (cornerScaled hp r (((z⁻¹ : unitary (Corner hp)) : Corner hp)^n)) = + cornerScaled hp r ((z : Corner hp)^n) := by + rw [←cornerScaled_star, star_pow] + congr 2 + exact star_star (z : Corner hp) + simpa only [Completion.inner_coe, PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS, hs] using h + +end Kadison +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerPhaseAveraging.lean b/lean/OAI/Analysis/Commutator/CornerPhaseAveraging.lean new file mode 100644 index 0000000000000000000000000000000000000000..f5657ec027159aa4daf19bd69927e83e275c8886 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerPhaseAveraging.lean @@ -0,0 +1,141 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.CornerPhase + +section Fourier + +variable {N : ℕ} [NeZero N] + +lemma character_sum (a : ZMod N) : + (∑ m : ZMod N, ZMod.stdAddChar (a*m))=if a=0 then (N:ℂ) else 0 := by + classical + split_ifs with ha + · simp [ha] + · exact AddChar.sum_eq_zero_of_ne_one (ZMod.isPrimitive_stdAddChar N ha) + +lemma character_orthogonality (i j : ZMod N) : + (∑ m : ZMod N, star (ZMod.stdAddChar (i*m))*ZMod.stdAddChar (j*m))= + if i=j then (N:ℂ) else 0 := by + classical + have hs (a : ZMod N) : star (ZMod.stdAddChar a)=ZMod.stdAddChar (-a) := by + rw [AddChar.map_neg_eq_inv] + exact ((ZMod.stdAddChar : AddChar (ZMod N) ℂ).inv_apply_eq_conj a).symm + simp only [hs,←AddChar.map_add_eq_mul,←sub_eq_neg_add,←sub_mul] + rw [character_sum] + congr 1 + exact propext (sub_eq_zero.trans eq_comm) + +def phaseSum (b : ZMod N → ℂ) (m : ZMod N) : ℂ := + ∑ j, ZMod.stdAddChar (j*m)*b j + +lemma phase_parseval (b : ZMod N → ℂ) : + (∑ m : ZMod N, ‖phaseSum b m‖^2)=(N:ℝ)*∑ j, ‖b j‖^2 := by + classical + have h : (∑ m : ZMod N, star (phaseSum b m)*phaseSum b m)= + (N:ℂ)*∑ j, star (b j)*b j := by + simp only [phaseSum,star_sum,star_mul,Finset.sum_mul_sum] + calc + _=∑ i : ZMod N, ∑ j : ZMod N, + (star (b i)*b j)*(∑ m : ZMod N, star (ZMod.stdAddChar (i*m))*ZMod.stdAddChar (j*m)) := by + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro i _ + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro j _ + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro m _ + ring + _=(N:ℂ)*∑ j, star (b j)*b j := by + simp only [character_orthogonality] + simp [Finset.sum_ite_eq,Finset.mul_sum,mul_comm] + have hnorm (z : ℂ) : star z*z=((‖z‖^2:ℝ):ℂ) := by + rw [Complex.sq_norm] + exact Complex.normSq_eq_conj_mul_self.symm + simp only [hnorm,←Complex.ofReal_sum,←Complex.ofReal_natCast,←Complex.ofReal_mul] at h + exact Complex.ofReal_injective h + +lemma phase_parseval_mul [Fact N.Prime] (b : ZMod N → ℂ) (k : ZMod N) (hk : k≠0) : + (∑ m : ZMod N, ‖phaseSum b (k*m)‖^2)=(N:ℝ)*∑ j, ‖b j‖^2 := by + rw [←phase_parseval b] + exact Fintype.sum_equiv (Equiv.mulLeft₀ k hk) _ _ (fun _ => rfl) + +end Fourier + +section Algebra + +variable {A : Type*} [CStarAlgebra A] + +variable {I : Type*} [Fintype I] + +variable (e : I → A) (he : ∀ i, IsStarProjection (e i)) + (ho : ∀ i j, i≠j → e i*e j=0) + +def diagonal (c : I → ℂ) : A := ∑ i,c i • e i + +include he ho in +lemma diagonal_mul (c d : I → ℂ) : + diagonal e c*diagonal e d=diagonal e (fun i => c i*d i) := by + simp only [diagonal,Finset.sum_mul_sum,smul_mul_assoc,mul_smul_comm,smul_smul] + apply Finset.sum_congr rfl + intro i _ + rw [Finset.sum_eq_single i] + · rw [(he i).isIdempotentElem.eq,mul_comm] + · intro j _ hji + rw [ho i j hji.symm,smul_zero] + · simp + +include he in +lemma diagonal_star (c : I → ℂ) : star (diagonal e c)=diagonal e (fun i => star (c i)) := by + simp only [diagonal,star_sum,star_smul,(he _).isSelfAdjoint.star_eq] + +include he ho in +lemma diagonal_pow_succ (c : I → ℂ) (k : ℕ) : + diagonal e c^(k+1)=diagonal e (fun i => c i^(k+1)) := by + induction k with + | zero => simp + | succ k ih => + rw [pow_succ,ih,diagonal_mul e he ho] + simp only [pow_succ] + +include he ho in +lemma diagonal_support (c : I → ℂ) : + diagonal e c*(∑ i,e i)=diagonal e c ∧ (∑ i,e i)*diagonal e c=diagonal e c := by + have hq : (∑ i,e i)=diagonal e (fun _ => 1) := by simp [diagonal] + rw [hq,diagonal_mul e he ho,diagonal_mul e he ho] + simp + +include he ho in +lemma diagonal_unitary (c : I → ℂ) (hc : ∀ i, ‖c i‖=1) : + star (diagonal e c)*diagonal e c=∑ i,e i ∧ + diagonal e c*star (diagonal e c)=∑ i,e i := by + have hc' (i : I) : star (c i)*c i=1 := by + change (starRingEnd ℂ) (c i)*c i=1 + rw [←Complex.normSq_eq_conj_mul_self,Complex.normSq_eq_norm_sq,hc i] + norm_num + rw [diagonal_star e he,diagonal_mul e he ho,diagonal_mul e he ho] + constructor + · simp only [hc',diagonal,one_smul] + · simp only [mul_comm (c _) (star (c _)),hc',diagonal,one_smul] + +end Algebra + +end Kadison.CornerPhase + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerPhaseSelection.lean b/lean/OAI/Analysis/Commutator/CornerPhaseSelection.lean new file mode 100644 index 0000000000000000000000000000000000000000..49a889f190482d43eb49544cc5528743ff364cd1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerPhaseSelection.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerPhaseSelectionCore +import OAI.Analysis.Commutator.NormalTraceProjection + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.CornerPhase + +section Represented + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +include hτ in +theorem exists_corner_phase {J : Type*} [Fintype J] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + (hM : DiffuseProjection.HasNoMinimalProjections M) + (q : M) (hq : IsStarProjection q) (hqt : 0<(τ q).re) + (a : J → M) (k : J → ℕ) (hk : ∀ j,0 p ((ZMod.finEquiv N).symm i) + have he : ∀ i,IsStarProjection (e i) := fun i => (hp _).1 + have heo : ∀ i j,i≠j → e i*e j=0 := fun i j hij => + ho _ _ (fun hh => hij ((ZMod.finEquiv N).symm.injective hh)) + have hep : ∑ i,e i=q := by + rw [←hsum] + exact Fintype.sum_equiv (ZMod.finEquiv N).symm.toEquiv _ _ (fun _ => rfl) + obtain ⟨u,h1,h2,h3,h4,h5,h6,_⟩ := exists_phase_finite τ hτ e he heo q hq hep + (fun _ => (hp _).2.2) hqt a k (fun j => ⟨hk j,hkN j⟩) hε hbudget + exact ⟨u,h1,h2,h3,h4,h5,h6⟩ + +end Represented + +end Kadison.CornerPhase +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerPhaseSelectionCore.lean b/lean/OAI/Analysis/Commutator/CornerPhaseSelectionCore.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7500f1a485b342579fdb0c2af4e5af4954f23db --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerPhaseSelectionCore.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerPhaseAveraging +import OAI.Analysis.Commutator.TracialL2Tools + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.CornerPhase + +open TracialL2 + +section Trace + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +lemma trace_projection_mul_le (e a : A) (he : IsStarProjection e) : + ‖τ (e*a)‖ ≤ (τ e).re*‖a‖ := by + have ht : τ (e*a)=τ (e*(a*e)) := by + calc + _=τ (a*e) := hτ _ _ + _=τ ((a*e)*e) := by rw [mul_assoc,he.isIdempotentElem.eq] + _=_ := hτ _ _ + rw [ht] + calc + _ ≤ norm τ e*norm τ (a*e) := norm_trace_mul τ hτ _ _ + _ ≤ norm τ e*(‖a‖*norm τ e) := + mul_le_mul_of_nonneg_left (norm_mul_left τ a e) (norm_nonneg τ e) + _ = (norm τ e)^2*‖a‖ := by ring + _ = (τ e).re*‖a‖ := by rw [norm_projection_sq τ he] + +variable {N : ℕ} [NeZero N] + +variable (e : ZMod N → A) (he : ∀ i,IsStarProjection (e i)) + (ho : ∀ i j,i≠j → e i*e j=0) + +def phaseElement (m : ZMod N) : A := diagonal e (fun j => ZMod.stdAddChar (j*m)) + +omit [PartialOrder A] [StarOrderedRing A] in +include he ho in +lemma phaseElement_corner (m : ZMod N) : + star (phaseElement e m)*phaseElement e m=∑ j,e j ∧ + phaseElement e m*star (phaseElement e m)=∑ j,e j ∧ + phaseElement e m*(∑ j,e j)=phaseElement e m ∧ + (∑ j,e j)*phaseElement e m=phaseElement e m := by + obtain ⟨h1,h2⟩ := diagonal_unitary e he ho (fun j => ZMod.stdAddChar (j*m)) + (fun _ => AddChar.norm_apply _ _) + exact ⟨h1,h2,diagonal_support e he ho _⟩ + +omit [StarOrderedRing A] in +include he ho in +lemma phaseElement_power_trace (m : ZMod N) (k : ℕ) (hk : 0 τ (e j*a)) ((k:ZMod N)*m) := by + obtain ⟨k,rfl⟩ := Nat.exists_eq_succ_of_ne_zero (Nat.ne_of_gt hk) + rw [phaseElement,diagonal_pow_succ e he ho] + simp only [diagonal,Finset.sum_mul,smul_mul_assoc,map_sum,map_smul,smul_eq_mul,phaseSum] + apply Finset.sum_congr rfl + intro j _ + congr 1 + rw [←AddChar.map_nsmul_eq_pow,nsmul_eq_mul] + congr 1 + ring + +include hτ he ho in +lemma phaseElement_mean_bound [Fact N.Prime] (q : A) (hq : IsStarProjection q) + (hpart : ∑ j,e j=q) (ht : ∀ i,(τ (e i)).re=(τ q).re/(N:ℝ)) + (a : A) (k : ℕ) (hk : 0 phaseElement_mean_bound τ hτ e he ho q hq hpart ht + (a j) (k j) (hk j).1 (hk j).2) + _ = (τ q).re^2*(∑ j,‖a j‖^2) := (Finset.mul_sum _ _ _).symm + _ < (τ q).re^2*((N:ℝ)*ε^2) := mul_lt_mul_of_pos_left hbudget (sq_pos_of_pos hqt) + _ = _ := by simp only [Finset.sum_const,Finset.card_univ,ZMod.card,nsmul_eq_mul]; ring + obtain ⟨m,_,hm⟩ := Finset.exists_lt_of_sum_lt hsum + obtain ⟨hu1,hu2,hu3,hu4⟩ := phaseElement_corner e he ho m + rw [hpart] at hu1 hu2 hu3 hu4 + refine ⟨phaseElement e m,hu1,hu2,hu3,hu4,?_,?_,?_⟩ + · have hn : ‖phaseElement e m‖^2=‖q‖ := by + rw [←hu1,CStarRing.norm_star_mul_self,pow_two] + have hqnorm := hq.norm_le q + nlinarith [_root_.norm_nonneg (phaseElement e m)] + · intro j + have hj : ‖τ (phaseElement e m^k j*a j)‖^2 < (ε*(τ q).re)^2 := + (Finset.single_le_sum (fun i _ => sq_nonneg ‖τ (phaseElement e m^k i*a i)‖) + (Finset.mem_univ j)).trans_lt hm + exact (sq_lt_sq₀ (_root_.norm_nonneg _) (mul_nonneg hε.le hqt.le)).mp hj + · intro S hS + exact S.sum_mem (fun i _ => S.smul_mem (hS i) _) + +end Trace + +end Kadison.CornerPhase + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerPolarAlgebra.lean b/lean/OAI/Analysis/Commutator/CornerPolarAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..af333f05631a620a939ac5b3a3ce0138b32f2ac2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerPolarAlgebra.lean @@ -0,0 +1,90 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.CornerPolarAlgebra + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +lemma square_root_defect_le {q a : A} (hq : IsStarProjection q) + (ha : 0≤a) (haq : a*q=a) : + star (q-a)*(q-a) ≤ star (q-a*a)*(q-a*a) := by + have has := (IsSelfAdjoint.of_nonneg ha).star_eq + have hqa : q*a=a := by + simpa only [star_mul,has,hq.isSelfAdjoint.star_eq] using congrArg star haq + have hc : Commute q a := hqa.trans haq.symm + have hsub : IsSelfAdjoint (q-a) := hq.isSelfAdjoint.sub (IsSelfAdjoint.of_nonneg ha) + have hs : 0≤(q-a)*(q-a) := by + simpa only [hsub.star_eq] using star_mul_self_nonneg (q-a) + have hasc : Commute a ((q-a)*(q-a)) := + (hc.symm.sub_right (Commute.refl a)).mul_right (hc.symm.sub_right (Commute.refl a)) + have hqa' : Commute (q-a) q := (Commute.refl q).sub_left hc.symm + have hscq : Commute ((q-a)*(q-a)) q := hqa'.mul_left hqa' + have hc' : Commute (a*((q-a)*(q-a))) (a+(q+q)) := + ((Commute.refl a).mul_left hasc.symm).add_right + ((hc.symm.mul_left hscq).add_right (hc.symm.mul_left hscq)) + have hpos : 0≤a*((q-a)*(q-a))*(a+(q+q)) := + Commute.mul_nonneg (Commute.mul_nonneg ha hs hasc) + (add_nonneg ha (add_nonneg hq.nonneg hq.nonneg)) hc' + have he : star (q-a*a)*(q-a*a)-star (q-a)*(q-a)= + a*((q-a)*(q-a))*(a+(q+q)) := by + simp only [star_sub,star_mul,has,hq.isSelfAdjoint.star_eq] + have hqaa : q*(a*a)=a*a := by rw [←mul_assoc,hqa] + noncomm_ring [hq.isIdempotentElem.eq,hqa,haq,hqaa] + exact sub_nonneg.mp (he.symm ▸ hpos) + +lemma polar_defect_le {q r a v : A} (hq : IsStarProjection q) + (hr : IsStarProjection r) (hrq : r≤q) (ha : 0≤a) + (hra : r*a=a) (haq : a*q=a) (hv : star v*v=r) : + star (v-v*a)*(v-v*a) ≤ star (q-a*a)*(q-a*a) := by + have has := (IsSelfAdjoint.of_nonneg ha).star_eq + have har : a*r=a := by + simpa only [star_mul,has,hr.isSelfAdjoint.star_eq] using congrArg star hra + have hqa : q*a=a := by + simpa only [star_mul,has,hq.isSelfAdjoint.star_eq] using congrArg star haq + have he : star (v-v*a)*(v-v*a)=star (q-a)*(q-a)-(q-r) := by + simp only [star_sub,star_mul,has,hq.isSelfAdjoint.star_eq] + have hva : star v*(v*a)=a := by rw [←mul_assoc,hv,hra] + noncomm_ring [hq.isIdempotentElem.eq,hra,har,hqa,haq,hv,hva] + rw [he] + exact (sub_le_self _ (sub_nonneg.mpr hrq)).trans (square_root_defect_le hq ha haq) + +lemma kernel_defect_le {q r a : A} (hq : IsStarProjection q) + (hr : IsStarProjection r) (ha : 0≤a) (hra : r*a=a) (haq : a*q=a) : + q-r ≤ star (q-a*a)*(q-a*a) := by + have has := (IsSelfAdjoint.of_nonneg ha).star_eq + have har : a*r=a := by + simpa only [star_mul,has,hr.isSelfAdjoint.star_eq] using congrArg star hra + have hqa : q*a=a := by + simpa only [star_mul,has,hq.isSelfAdjoint.star_eq] using congrArg star haq + have he : star (q-a*a)*(q-a*a)-(q-r)=star (r-a*a)*(r-a*a) := by + simp only [star_sub,star_mul,has,hq.isSelfAdjoint.star_eq,hr.isSelfAdjoint.star_eq] + have hqaa : q*(a*a)=a*a := by rw [←mul_assoc,hqa] + have hraa : r*(a*a)=a*a := by rw [←mul_assoc,hra] + noncomm_ring [hq.isIdempotentElem.eq,hr.isIdempotentElem.eq,hqa,haq,hra,har,hqaa,hraa] + exact sub_nonneg.mp (he.symm ▸ star_mul_self_nonneg (r-a*a)) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma norm_partial_isometry_le {r v : A} (hr : IsStarProjection r) + (hv : star v*v=r) : ‖v‖≤1 := by + have hnorm : ‖star v*v‖=‖v‖*‖v‖ := CStarRing.norm_star_mul_self + rw [hv] at hnorm + have hrnorm := hr.norm_le r + nlinarith [norm_nonneg v] + +end Kadison.CornerPolarAlgebra + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerPolarTransfer.lean b/lean/OAI/Analysis/Commutator/CornerPolarTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ff527d5fc61788142bc3b1cbc8447e8ad3242db --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerPolarTransfer.lean @@ -0,0 +1,177 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerPolarAlgebra +import OAI.Analysis.Commutator.PolarSupport +import OAI.Analysis.Commutator.TracialL2Tools +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.CornerPolarTransfer + +open TracialL2 + +section Estimates + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +lemma conjugation_difference (v b y : A) (hv : ‖v‖≤1) : + norm τ (star v*y*v) ≤ norm τ (star b*y*b)+ + (1+‖b‖)*‖y‖*norm τ (v-b) := by + have he : star v*y*v=star b*y*b+star (v-b)*y*v+star b*y*(v-b) := by + simp only [star_sub,sub_mul,mul_sub] + abel + have h1 : norm τ (star (v-b)*y*v)≤‖y‖*norm τ (v-b) := by + calc + _≤norm τ (star (v-b)*y)*‖v‖ := norm_mul_right τ hτ _ _ + _≤norm τ (star (v-b)*y) := mul_le_of_le_one_right (norm_nonneg τ _) hv + _≤norm τ (star (v-b))*‖y‖ := norm_mul_right τ hτ _ _ + _=_ := by rw [norm_star τ hτ,mul_comm] + have h2 : norm τ (star b*y*(v-b))≤‖b‖*‖y‖*norm τ (v-b) := by + calc + _≤‖star b*y‖*norm τ (v-b) := norm_mul_left τ _ _ + _≤(‖star b‖*‖y‖)*norm τ (v-b) := + mul_le_mul_of_nonneg_right (_root_.norm_mul_le _ _) (norm_nonneg τ _) + _=_ := by rw [_root_.norm_star] + calc + _=norm τ (star b*y*b+star (v-b)*y*v+star b*y*(v-b)) := congrArg (norm τ) he + _≤norm τ (star b*y*b)+norm τ (star (v-b)*y*v)+norm τ (star b*y*(v-b)) := + (norm_add τ (star b*y*b+star (v-b)*y*v) (star b*y*(v-b))).trans + (add_le_add (norm_add τ (star b*y*b) (star (v-b)*y*v)) le_rfl) + _≤norm τ (star b*y*b)+‖y‖*norm τ (v-b)+‖b‖*‖y‖*norm τ (v-b) := + add_le_add (add_le_add le_rfl h1) h2 + _=_ := by simp only [add_mul,one_mul,add_assoc] + +include hτ in +lemma range_compression (v y : A) (hv : ‖v‖≤1) : + norm τ ((v*star v)*y*(v*star v))≤norm τ (star v*y*v) := by + calc + _=norm τ (v*(star v*y*v)*star v) := by simp only [mul_assoc] + _≤norm τ (v*(star v*y*v))*‖star v‖ := norm_mul_right τ hτ _ _ + _≤norm τ (v*(star v*y*v)) := + mul_le_of_le_one_right (norm_nonneg τ _) (by simpa using hv) + _≤‖v‖*norm τ (star v*y*v) := norm_mul_left τ _ _ + _≤norm τ (star v*y*v) := mul_le_of_le_one_left (norm_nonneg τ _) hv + +lemma defect_bound {q r a v : A} (hq : IsStarProjection q) + (hr : IsStarProjection r) (hrq : r≤q) (ha : 0≤a) + (hra : r*a=a) (haq : a*q=a) (hv : star v*v=r) : + norm τ (v-v*a) ≤ norm τ (q-a*a) := + norm_mono_square τ (CornerPolarAlgebra.polar_defect_le hq hr hrq ha hra haq hv) + +lemma trace_kernel_bound {q r a : A} (hq : IsStarProjection q) + (hr : IsStarProjection r) (ha : 0≤a) (hra : r*a=a) (haq : a*q=a) : + (τ q).re-(τ r).re≤norm τ (q-a*a)^2 := by + have h := (τ.monotone (CornerPolarAlgebra.kernel_defect_le hq hr ha hra haq)).1 + change (τ (q-r)).re≤(τ (star (q-a*a)*(q-a*a))).re at h + simpa only [map_sub,Complex.sub_re,←norm_sq] using h + +include hτ in +lemma compressed_scalar_polar {p q v b y : A} {c : ℝ} + (hp : IsStarProjection p) (hq : IsStarProjection q) (hpy : p*y=y) (hyp : y*p=y) + (hb : b=c • (p*q)) (hv : ‖v‖≤1) : + norm τ ((v*star v)*y*(v*star v)) ≤ c^2*norm τ (q*y*q)+ + (1+‖b‖)*‖y‖*norm τ (v-b) := by + have he : star b*y*b=(c*c) • (q*y*q) := by + rw [hb] + simp only [star_smul,star_mul,star_trivial,hp.isSelfAdjoint.star_eq, + hq.isSelfAdjoint.star_eq,smul_mul_assoc,mul_smul_comm,smul_smul] + congr 1 + rw [mul_assoc q p y,hpy,←mul_assoc,mul_assoc q y p,hyp] + have hn : norm τ (star b*y*b)=c^2*norm τ (q*y*q) := by + rw [he,norm_real_smul,abs_of_nonneg (mul_self_nonneg c),pow_two] + exact (range_compression τ hτ v y hv).trans ((conjugation_difference τ hτ v b y hv).trans_eq + (by rw [hn])) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma scaled_projection_defect {p q : A} (hp : IsStarProjection p) + (hq : IsStarProjection q) {c t : ℝ} (hct : c*c*t=1) : + q-star (c • (p*q))*(c • (p*q))=(-c*c) • (q*(p-t • (1:A))*q) := by + have hpc : star (p*q)*(p*q)=q*p*q := by + simp only [star_mul,hp.isSelfAdjoint.star_eq,hq.isSelfAdjoint.star_eq] + rw [mul_assoc q p,←mul_assoc p p q,hp.isIdempotentElem.eq,←mul_assoc] + have hcen : q*(p-t • (1:A))*q=q*p*q-t • q := by + simp only [mul_sub,sub_mul,mul_smul_comm,smul_mul_assoc,mul_one, + hq.isIdempotentElem.eq] + have hct' : (-c*c)*t=-1 := by nlinarith only [hct] + rw [hcen,star_smul,star_trivial,smul_mul_assoc,mul_smul_comm,smul_smul,hpc, + smul_sub,smul_smul,hct',neg_one_smul,sub_neg_eq_add,neg_mul,neg_smul,add_comm] + exact sub_eq_add_neg _ _ + +lemma norm_scaled_projection_defect {p q : A} (hp : IsStarProjection p) + (hq : IsStarProjection q) {c t : ℝ} (hct : c*c*t=1) : + norm τ (q-star (c • (p*q))*(c • (p*q)))= + c^2*norm τ (q*(p-t • (1:A))*q) := by + rw [scaled_projection_defect hp hq hct,norm_real_smul, + neg_mul,abs_neg,abs_of_nonneg (mul_self_nonneg c),pow_two] + +end Estimates + +section Represented + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +lemma abs_coe (b : M) : CFC.abs (b : H →L[ℂ] H)=(CFC.abs b : M) := by + apply CFC.sqrt_unique + · exact congrArg (fun x : M => (x : H →L[ℂ] H)) (CFC.abs_mul_abs b) + · exact CFC.abs_nonneg b + +lemma projection_of_coe {p : M} (hp : IsStarProjection (p : H →L[ℂ] H)) : + IsStarProjection p := by + exact ⟨Subtype.ext hp.isIdempotentElem.eq,Subtype.ext hp.isSelfAdjoint.star_eq⟩ + +theorem exists_polar_data (b : M) : + ∃ v : M, v*CFC.abs b=b ∧ + IsStarProjection (star v*v) ∧ IsStarProjection (v*star v) ∧ + (star v*v)*CFC.abs b=CFC.abs b ∧ + ‖v‖≤1 ∧ (∀ (N : VonNeumannAlgebra H), (b : H →L[ℂ] H)∈N → (v : H →L[ℂ] H)∈N) ∧ + (∀ e : M, IsStarProjection e → e*b=b → v*star v≤e) ∧ + (∀ e : M, IsStarProjection e → b*e=b → star v*v≤e) := by + let v : M := ⟨Polar.partialIsometry (b : H →L[ℂ] H), + Polar.partialIsometry_mem_vonNeumann M b.property⟩ + have hi : ((star v*v : M) : H →L[ℂ] H)=Polar.rightSupport (b : H →L[ℂ] H) := + Polar.partialIsometry_initial _ + have hp : IsStarProjection (star v*v) := projection_of_coe M + (hi.symm ▸ Polar.isProjection_rightSupport _) + refine ⟨v,?_,hp,projection_of_coe M (Polar.isProjection_leftSupport _),?_, + CornerPolarAlgebra.norm_partial_isometry_le hp rfl,?_,?_,?_⟩ + · apply Subtype.ext + change Polar.partialIsometry _*((CFC.abs b : M) : H →L[ℂ] H)=_ + rw [←abs_coe M,Polar.factorization] + · apply Subtype.ext + change ((star v*v : M) : H →L[ℂ] H)*((CFC.abs b : M) : H →L[ℂ] H)=_ + rw [hi,←abs_coe M,Polar.initial_mul_abs] + · intro N hb + exact Polar.partialIsometry_mem_vonNeumann N hb + · intro e he heb + change Polar.leftSupport (b : H →L[ℂ] H)≤(e : H →L[ℂ] H) + exact Polar.leftSupport_le _ _ (he.map M.toStarSubalgebra.subtype) + (congrArg (fun x : M => (x : H →L[ℂ] H)) heb) + · intro e he hbe + change ((star v*v : M) : H →L[ℂ] H)≤(e : H →L[ℂ] H) + rw [hi] + exact Polar.rightSupport_le _ _ (he.map M.toStarSubalgebra.subtype) + (congrArg (fun x : M => (x : H →L[ℂ] H)) hbe) + +end Represented + +end Kadison.CornerPolarTransfer + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerSymmetrization.lean b/lean/OAI/Analysis/Commutator/CornerSymmetrization.lean new file mode 100644 index 0000000000000000000000000000000000000000..9bfb9b1474c020503d89cf982d220cf02be25e48 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerSymmetrization.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.Commutator.StageAverage + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology + +open ContinuousLinearMap MeasureTheory MeasureTheory.Measure + +namespace Kadison.CornerSymmetrization + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def vectorState (Ω : H) (a : H →L[ℂ] H) : ℂ := inner ℂ Ω (a Ω) + +def CornerElement (D P : StarSubalgebra ℂ (H →L[ℂ] H)) (Ω : H) (t : ℂ) + (x : H →L[ℂ] H) : Prop := + x∈P ∧ ∃ e : H →L[ℂ] H, e∈D ∧ IsStarProjection e ∧ vectorState Ω e=t ∧ e*x=x ∧ x*e=x + +lemma vectorState_conj (U : H ≃ₗᵢ[ℂ] H) (Ω : H) (hΩ : U Ω=Ω) (a : H →L[ℂ] H) : + vectorState Ω (U.conjStarAlgEquiv a)=vectorState Ω a := by + have hi : U.symm Ω=Ω := by + apply U.injective + rw [LinearIsometryEquiv.apply_symm_apply,hΩ] + change inner ℂ Ω (U (a (U.symm Ω)))=inner ℂ Ω (a Ω) + rw [hi] + calc + inner ℂ Ω (U (a Ω)) = inner ℂ (U Ω) (U (a Ω)) := by rw [hΩ] + _ = inner ℂ Ω (a Ω) := U.inner_map_map Ω (a Ω) + +lemma cornerElement_map (D P : StarSubalgebra ℂ (H →L[ℂ] H)) (Ω : H) (t : ℂ) + (U : H ≃ₗᵢ[ℂ] H) (hΩ : U Ω=Ω) + (hD : ∀ a∈D, U.conjStarAlgEquiv a∈D) (hP : ∀ a∈P, U.conjStarAlgEquiv a∈P) + {x : H →L[ℂ] H} (hx : CornerElement D P Ω t x) : + CornerElement D P Ω t (U.conjStarAlgEquiv x) := by + obtain ⟨hx,e,he,hp,ht,hel,her⟩ := hx + refine ⟨hP x hx,U.conjStarAlgEquiv e,hD e he,?_,?_,?_,?_⟩ + · exact hp.map U.conjStarAlgEquiv + · rw [vectorState_conj U Ω hΩ,ht] + · simpa only [map_mul] using congrArg U.conjStarAlgEquiv hel + · simpa only [map_mul] using congrArg U.conjStarAlgEquiv her + +lemma commutator_conj_norm (α : (H →L[ℂ] H) ≃⋆ₐ[ℂ] (H →L[ℂ] H)) + (G a : H →L[ℂ] H) : + ‖α G*a-a*α G‖=‖G*α.symm a-α.symm a*G‖ := by + calc + _ = ‖α (G*α.symm a-α.symm a*G)‖ := by + simp only [map_sub,map_mul,StarAlgEquiv.apply_symm_apply] + _ = _ := StarAlgEquiv.norm_map α _ + +lemma commutator_adjoint_norm (G a : H →L[ℂ] H) : + ‖G.adjoint*a-a*G.adjoint‖=‖G*star a-star a*G‖ := by + have h : G.adjoint*a-a*G.adjoint = -star (G*star a-star a*G) := by + simp only [star_sub,star_mul,star_star,neg_sub] + rfl + rw [h,norm_neg,norm_star] + +lemma cornerElement_star (D P : StarSubalgebra ℂ (H →L[ℂ] H)) (Ω : H) (t : ℂ) + {x : H →L[ℂ] H} (hx : CornerElement D P Ω t x) : + CornerElement D P Ω t (star x) := by + obtain ⟨hx,e,he,hp,ht,hel,her⟩ := hx + refine ⟨star_mem hx,e,he,hp,ht,?_,?_⟩ + · simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star her + · simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star hel + +lemma fixed_projection_right (U : H ≃ₗᵢ[ℂ] H) (Q : H →L[ℂ] H) + (hQ : IsSelfAdjoint Q) (hU : (U:H →L[ℂ] H)*Q=Q) : + Q*(U:H →L[ℂ] H)=Q := by + have h := congrArg star hU + simp only [star_mul,hQ.star_eq] at h + have hu : star (U:H →L[ℂ] H)*(U:H →L[ℂ] H)=1 := by + rw [LinearIsometryEquiv.star_eq_symm] + ext x + change U.symm (U x)=x + exact U.symm_apply_apply x + have h' := congrArg (fun a : H →L[ℂ] H => a*(U:H →L[ℂ] H)) h + rw [mul_assoc,hu,mul_one] at h' + exact h'.symm + +lemma fixed_compressed_conjugate (U : H ≃ₗᵢ[ℂ] H) (Q s G : H →L[ℂ] H) + (hQ : IsSelfAdjoint Q) (hU : (U:H →L[ℂ] H)*Q=Q) + (hs : (U:H →L[ℂ] H)*s=s*(U:H →L[ℂ] H)) : + Q*(U.conjStarAlgEquiv G*s-s*U.conjStarAlgEquiv G)*Q=Q*(G*s-s*G)*Q := by + let u : H →L[ℂ] H := U + let v : H →L[ℂ] H := U.symm + have huv : u*v=1 := by ext x; exact U.apply_symm_apply x + have hvu : v*u=1 := by ext x; exact U.symm_apply_apply x + have hQu : Q*u=Q := fixed_projection_right U Q hQ hU + have hvQ : v*Q=Q := by + have h := congrArg (fun a => v*a) hU + change v*(u*Q)=v*Q at h + rw [←mul_assoc,hvu,one_mul] at h + exact h.symm + have hvs : v*s=s*v := by + have h := congrArg (fun a => v*a*v) hs + change v*(u*s)*v=v*(s*u)*v at h + have hss : v*(u*s)*v=s*v := by rw [←mul_assoc v u s,hvu,one_mul] + have htt : v*(s*u)*v=v*s := by + calc + _ = (v*s)*(u*v) := by noncomm_ring + _ = v*s := by rw [huv,mul_one] + rw [hss,htt] at h + exact h.symm + change Q*(u*G*v*s-s*(u*G*v))*Q=Q*(G*s-s*G)*Q + simp only [mul_sub,sub_mul] + congr 1 + · calc + Q*(u*G*v*s)*Q = Q*u*G*(v*s)*Q := by noncomm_ring + _ = Q*G*(s*v)*Q := by rw [hQu,hvs] + _ = Q*G*s*(v*Q) := by noncomm_ring + _ = Q*(G*s)*Q := by rw [hvQ]; noncomm_ring + · calc + Q*(s*(u*G*v))*Q=Q*(s*u)*G*(v*Q) := by noncomm_ring + _ = Q*(u*s)*G*Q := by rw [←hs,hvQ] + _ = Q*(s*G)*Q := by rw [←mul_assoc,hQu]; noncomm_ring + +lemma conj_symm (U : H ≃ₗᵢ[ℂ] H) : U.symm.conjStarAlgEquiv=U.conjStarAlgEquiv.symm := by + apply StarAlgEquiv.ext + intro a + apply U.conjStarAlgEquiv.injective + change U.conjStarAlgEquiv (U.symm.conjStarAlgEquiv a)=U.conjStarAlgEquiv (U.conjStarAlgEquiv.symm a) + rw [StarAlgEquiv.apply_symm_apply] + ext x + change U (U.symm (a (U (U.symm x))))=a x + simp only [LinearIsometryEquiv.apply_symm_apply] + +variable (Γ : ℕ → Type*) [∀ n, Group (Γ n)] [∀ n, TopologicalSpace (Γ n)] + [∀ n, IsTopologicalGroup (Γ n)] [∀ n, CompactSpace (Γ n)] + [∀ n, MeasurableSpace (Γ n)] [∀ n, BorelSpace (Γ n)] + +variable (U : ∀ n, Γ n →* (H ≃ₗᵢ[ℂ] H)) + (hU : ∀ n x, Continuous fun g => U n g x) + (hnest : ∀ i j, i≤j → ∀ g : Γ i, ∃ k : Γ j, U j k=U i g) + +variable (μ : ∀ n, Measure (Γ n)) [∀ n, IsProbabilityMeasure (μ n)] [∀ n, IsMulLeftInvariant (μ n)] + +variable (D P : StarSubalgebra ℂ (H →L[ℂ] H)) (Ω : H) (t : ℂ) + (hΩ : ∀ n g, U n g Ω=Ω) + (hD : ∀ n g a, a∈D → (U n g).conjStarAlgEquiv a∈D) + (hP : ∀ n g a, a∈P → (U n g).conjStarAlgEquiv a∈P) + +variable (G : H →L[ℂ] H) (ε : ℝ) (hε : 0≤ε) + (hGD : ∀ a∈D, G*a=a*G) + (hC : ∀ x, CornerElement D P Ω t x → ‖G*x-x*G‖≤ε*‖x‖) + +variable (Q s : H →L[ℂ] H) (hQ : IsSelfAdjoint Q) + (hUQ : ∀ n g, (U n g:H →L[ℂ] H)*Q=Q) + (hUs : ∀ n g, (U n g:H →L[ℂ] H)*s=s*(U n g:H →L[ℂ] H)) + +include hU hnest μ hΩ hD hP hε hGD hC hQ hUQ hUs in +theorem exists_symmetrization : ∃ V : H →L[ℂ] H, + ‖V‖≤‖G‖ ∧ (∀ n g, V*(U n g:H →L[ℂ] H)=(U n g:H →L[ℂ] H)*V) ∧ + (∀ a∈D, V*a=a*V) ∧ + (∀ x, CornerElement D P Ω t x → ‖V*x-x*V‖≤ε*‖x‖) ∧ + (∀ x, CornerElement D P Ω t x → ‖V.adjoint*x-x*V.adjoint‖≤ε*‖x‖) ∧ + Q*(V*s-s*V)*Q=Q*(G*s-s*G)*Q := by + let ι := Sum {a : H →L[ℂ] H // a∈D} {x : H →L[ℂ] H // CornerElement D P Ω t x} + let a : ι → H →L[ℂ] H := Sum.elim Subtype.val Subtype.val + let C : ι → ℝ := Sum.elim (fun _ => 0) (fun x => ε*‖x.val‖) + have hC₀ : ∀ i, 0≤C i := by + intro i + cases i with + | inl x => exact le_rfl + | inr x => exact mul_nonneg hε (norm_nonneg _) + have hstar (n : ℕ) (g : Γ n) : (U n g).conjStarAlgEquiv.symm=(U n g⁻¹).conjStarAlgEquiv := by + rw [map_inv,LinearIsometryEquiv.inv_def,conj_symm] + have hb : ∀ n g i, ‖CompactAverage.conjugate (U n) G g*a i-a i*CompactAverage.conjugate (U n) G g‖≤C i := by + intro n g i + change ‖(U n g).conjStarAlgEquiv G*a i-a i*(U n g).conjStarAlgEquiv G‖≤C i + rw [commutator_conj_norm,hstar] + cases i with + | inl x => + change ‖G*(U n g⁻¹).conjStarAlgEquiv x.val-(U n g⁻¹).conjStarAlgEquiv x.val*G‖≤0 + rw [hGD _ (hD n g⁻¹ x.val x.property),sub_self,norm_zero] + | inr x => + change ‖G*(U n g⁻¹).conjStarAlgEquiv x.val-(U n g⁻¹).conjStarAlgEquiv x.val*G‖≤ε*‖x.val‖ + simpa only [StarAlgEquiv.norm_map] using hC _ + (cornerElement_map D P Ω t (U n g⁻¹) (hΩ n g⁻¹) (hD n g⁻¹) (hP n g⁻¹) x.property) + obtain ⟨V,hV,hVU,hVC,hVQ⟩ := CompactAverage.exists_stage_average Γ U hU hnest μ G a C hC₀ hb Q Q s + (fun n g => fixed_compressed_conjugate (U n g) Q s G hQ (hUQ n g) (hUs n g)) + have hVC' : ∀ x, CornerElement D P Ω t x → ‖V*x-x*V‖≤ε*‖x‖ := by + intro x hx + exact hVC (Sum.inr ⟨x,hx⟩) + refine ⟨V,hV,hVU,?_,hVC',?_,hVQ⟩ + · intro x hx + have h := hVC (Sum.inl ⟨x,hx⟩) + change ‖V*x-x*V‖≤0 at h + exact sub_eq_zero.mp (norm_eq_zero.mp (le_antisymm h (norm_nonneg _))) + · intro x hx + rw [commutator_adjoint_norm] + simpa only [norm_star] using hVC' (star x) (cornerElement_star D P Ω t hx) + +end Kadison.CornerSymmetrization + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CornerWeakZero.lean b/lean/OAI/Analysis/Commutator/CornerWeakZero.lean new file mode 100644 index 0000000000000000000000000000000000000000..49807b16a679b51e4cccc46dd5f6cc870e21f61a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CornerWeakZero.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlphabetGNS +import OAI.Analysis.Commutator.StageGeneration +import OAI.Analysis.Commutator.WeakZeroSelection + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder InnerProductSpace + +open Filter Topology + +open scoped Matrix.Norms.L2Operator + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b, τ (a*b)=τ (b*a)) (h1 : τ 1=1) + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a)=φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hgen : ∀ a : A, τ.gnsStarAlgHom a ∈ Set.centralizer (Set.centralizer + (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)))) + +include e he hgen in +omit [∀ n, Nonempty (I n)] in +lemma separableGNS_of_stages : TopologicalSpace.SeparableSpace τ.GNS := by + apply (dense_stages_of_bicommutant_generation τ I φ e he hgen).isSeparable_iff.mp + apply TopologicalSpace.IsSeparable.iUnion + intro n + let : ProperSpace (Matrix (I n) (I n) ℂ) := FiniteDimensional.proper ℂ _ + exact TopologicalSpace.isSeparable_range (stageVector τ (φ n)).continuous_of_finiteDimensional + +include hτ h1 e he hsize in +lemma corner_arbitrarily_large_alphabet (n : ℕ) (p : Matrix (I n) (I n) ℂ) + (hp : IsStarProjection p) (α : ℝ) (hα : 0<α) (hατ : τ (φ n p)=(α:ℂ)) (N : ℕ) : + ∃ m : ℕ, N ≤ m ∧ ∃ x : Fin m → A, + Orthonormal ℂ (fun i => algebraVector τ (x i)) ∧ + ∀ i, τ (x i)=0 ∧ x i*φ n p=x i ∧ star (x i)*x i=((α:ℂ)⁻¹) • φ n p ∧ + ‖x i‖≤(Real.sqrt α)⁻¹ := by + obtain ⟨q,hq⟩ := exists_nat_ge ((N+1:ℝ)/α) + obtain ⟨k,hk,hqk⟩ := hsize n q + have hN : (N+1:ℝ)≤α*Fintype.card (I k) := by + rw [mul_comm] + exact (div_le_iff₀ hα).mp (hq.trans (by exact_mod_cast hqk)) + have htrace : τ (φ k (e hk p))=(α:ℂ) := by rw [he]; exact hατ + obtain ⟨m,hm,x,hx,hprop⟩ := MatrixCorners.exists_normalized_corner_alphabet τ hτ h1 + (φ k) (e hk p) (hp.map (e hk)) α hα htrace N hN + exact ⟨m,hm,x,hx,by simpa only [he] using hprop⟩ + +include hτ h1 e he hsize hgen in +theorem exists_corner_weak_zero (n : ℕ) (p : Matrix (I n) (I n) ℂ) + (hp : IsStarProjection p) (α : ℝ) (hα : 0<α) (hατ : τ (φ n p)=(α:ℂ)) : + ∃ x : ℕ → A, (∀ k, τ (x k)=0 ∧ x k*φ n p=x k ∧ + star (x k)*x k=((α:ℂ)⁻¹) • φ n p ∧ ‖x k‖≤(Real.sqrt α)⁻¹ ∧ + ‖τ.toPreGNS (x k)‖=1 ∧ ‖τ.toPreGNS (star (x k))‖=1) ∧ + ∀ a : A, Tendsto (fun k => τ (x k*a)) atTop (𝓝 0) := by + classical + let P : Set τ.GNS := {v | ∃ x : A, algebraVector τ x=v ∧ τ x=0 ∧ + x*φ n p=x ∧ star x*x=((α:ℂ)⁻¹) • φ n p ∧ ‖x‖≤(Real.sqrt α)⁻¹} + have hlarge : ∀ N : ℕ, ∃ m : ℕ, N ≤ m ∧ ∃ v : Fin m → τ.GNS, + Orthonormal ℂ v ∧ ∀ i, v i∈P := by + intro N + obtain ⟨m,hm,x,hx,hprop⟩ := corner_arbitrarily_large_alphabet τ hτ h1 I φ e he hsize n p hp α hα hατ N + exact ⟨m,hm,fun i => algebraVector τ (x i),hx,fun i => ⟨x i,rfl,hprop i⟩⟩ + let : TopologicalSpace.SeparableSpace τ.GNS := separableGNS_of_stages τ I φ e he hgen + obtain ⟨v,hv,hvn,hvweak⟩ := Kadison.exists_weak_zero_sequence P (TopologicalSpace.denseSeq τ.GNS) + (TopologicalSpace.denseRange_denseSeq _) hlarge + choose x hx hprop using hv + refine ⟨x,?_,?_⟩ + · intro k + have hn : ‖τ.toPreGNS (x k)‖=1 := by + have h := hvn k + rw [←hx k,algebraVector_apply,UniformSpace.Completion.norm_coe] at h + exact h + exact ⟨(hprop k).1,(hprop k).2.1,(hprop k).2.2.1,(hprop k).2.2.2,hn, + (norm_star_preGNS τ hτ (x k)).trans hn⟩ + · intro a + have ht := (hvweak (algebraVector τ (star a))).star + convert ht using 1 + · funext k + rw [←hx k,←inner_conj_symm,inner_algebraVector,star_star,hτ] + simp + · simp + +end Kadison.TracialGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableFieldHom.lean b/lean/OAI/Analysis/Commutator/CountableFieldHom.lean new file mode 100644 index 0000000000000000000000000000000000000000..0cf140e90bee4ebc85ccde7693cd5ee957681f0f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableFieldHom.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.RationalStarExtension + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology + +namespace Kadison.Decomposable + +variable {Ω H A : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] [CStarAlgebra A] + +local instance : NormedAlgebra ℚ A := NormedAlgebra.restrictScalars ℚ ℂ A + +local instance : NormedAlgebra ℚ (H →L[ℂ] H) := NormedAlgebra.restrictScalars ℚ ℂ (H →L[ℂ] H) + +local instance : StarModule ℚ A where + star_smul r a := by + change star ((r:ℂ) • a)=((star r:ℚ):ℂ) • star a + simp + +local instance : StarModule ℚ (H →L[ℂ] H) where + star_smul r a := by + change star ((r:ℂ) • a)=((star r:ℚ):ℂ) • star a + simp + +omit [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] in +theorem homomorphisms_ae_of_countable_relations + (S : StarSubalgebra ℚ A) [Countable S] + (hd : DenseRange (fun a : S => (a:A))) (hI : Complex.I • (1:A)∈S) + (T : A → Ω → H →L[ℂ] H) + (hb : ∀ a,∀ᵐ x ∂μ,‖T a x‖≤‖a‖) + (ha : ∀ a b,∀ᵐ x ∂μ,T (a+b) x=T a x+T b x) + (hm : ∀ a b,∀ᵐ x ∂μ,T (a*b) x=T a x*T b x) + (hst : ∀ a,∀ᵐ x ∂μ,T (star a) x=star (T a x)) + (hsc : ∀ z : ℂ,∀ᵐ x ∂μ,T (z • (1:A)) x=z • (1:H →L[ℂ] H)) : + ∀ᵐ x ∂μ,∃ Φ : A →⋆ₐ[ℂ] (H →L[ℂ] H),∀ a : S,Φ (a:A)=T (a:A) x := by + filter_upwards [ae_all_iff.mpr (fun a : S => hb (a:A)), + ae_all_iff.mpr (fun a : S => ae_all_iff.mpr (fun b : S => ha (a:A) (b:A))), + ae_all_iff.mpr (fun a : S => ae_all_iff.mpr (fun b : S => hm (a:A) (b:A))), + ae_all_iff.mpr (fun a : S => hst (a:A)), + ae_all_iff.mpr (fun r : ℚ => hsc (r:ℂ)),hsc Complex.I] with x hx ha hm hs hc hi + let φ : S →⋆ₐ[ℚ] (H →L[ℂ] H) := + { toAlgHom := + { toFun := fun a => T (a:A) x + map_one' := by simpa using hc (1:ℚ) + map_zero' := by simpa using hc (0:ℚ) + map_add' := fun a b => ha a b + map_mul' := fun a b => hm a b + commutes' := by + intro r + change T (algebraMap ℚ A r) x=algebraMap ℚ (H →L[ℂ] H) r + rw [Algebra.algebraMap_eq_smul_one,Algebra.algebraMap_eq_smul_one] + exact hc r } + map_star' := fun a => hs a } + obtain ⟨Φ,hΦ,hnb⟩ := RationalStarExtension.exists_complex_extension S hd φ hx hI hi + exact ⟨Φ,hΦ⟩ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableGNSColumn.lean b/lean/OAI/Analysis/Commutator/CountableGNSColumn.lean new file mode 100644 index 0000000000000000000000000000000000000000..12c5675c29a95bc6c39f3c6a9862d748ce6ecde6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableGNSColumn.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.FaithfulNormalRepresentationLinks +import OAI.Analysis.Commutator.NormalGNSSeparable +import OAI.Analysis.Commutator.NormalRepresentationColumns +import OAI.Analysis.Commutator.CountableOrthogonal +import OAI.Analysis.Commutator.InfiniteLinkColumn + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology InnerProductSpace ComplexOrder + +universe u + +namespace Kadison.NormalRepresentation + +open HilbertBiprod PartialIsometryOrder BiprodLinkColumn + +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +private lemma embedding_of_links {G : Type u} {A : Type*} + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + [TopologicalSpace.SeparableSpace H] [TopologicalSpace.SeparableSpace G] + (algebra : VonNeumannAlgebra (Space H G)) + (first : A → (H →L[ℂ] H)) (second : A → (G →L[ℂ] G)) + (links : ∃ family : Set (Intertwiner algebra), + OrthogonalLinks algebra right left family ∧ + (familySpace algebra right left family).starProjection=left) + (intertwines : ∀ (link : Intertwiner algebra) (element : A), + (component algebra link).comp (first element)= + (second element).comp (component algebra link)) : + ∃ ι : Type u, Countable ι ∧ ∃ embedding : H →ₗᵢ[ℂ] lp (fun _ : ι => G) 2, + ∀ (element : A) (vector : H) (index : ι), + embedding (first element vector) index=second element (embedding vector index) := by + obtain ⟨family,orthogonal,spans⟩ := links + let embedding := infiniteColumn algebra family orthogonal spans + refine ⟨family,links_countable algebra right left family orthogonal,embedding,?_⟩ + intro element vector index + exact congrArg (fun operator : H →L[ℂ] G => operator vector) + (intertwines index.val element) + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +theorem exists_countable_gns_embedding [TopologicalSpace.SeparableSpace H] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) : + ∃ ι : Type u, Countable ι ∧ ∃ V : H →ₗᵢ[ℂ] lp (fun _ : ι => τ.GNS) 2, + ∀ (a : M) (x : H) (i : ι),V (a.val x) i=τ.gnsStarAlgHom a (V x i) := by + let : TopologicalSpace.SeparableSpace τ.GNS := NormalGNS.separable_gns M τ hnormal + exact embedding_of_links (H:=H) (G:=τ.GNS) (A:=M) + (diagonalAlgebra M τ hnormal).commutant (fun element => element.val) τ.gnsStarAlgHom + (exists_orthogonal_links_of_faithful (H:=H) M τ hnormal hfaith) + (link_intertwines M τ hnormal) + +end Kadison.NormalRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableOrthogonal.lean b/lean/OAI/Analysis/Commutator/CountableOrthogonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..d6c738edefdc55bead3f650974a3c493ad7e5f62 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableOrthogonal.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.OrthogonalLinkFamily + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +namespace Kadison + +variable {H ι : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [TopologicalSpace.SeparableSpace H] + +lemma countable_of_orthonormal_vectors (v : ι → H) (hn : ∀ i,‖v i‖=1) + (ho : Pairwise (fun i j => inner ℂ (v i) (v j)=0)) : Countable ι := by + have hd : Pairwise (fun i j => Disjoint (Metric.ball (v i) (1/3:ℝ)) (Metric.ball (v j) (1/3:ℝ))) := by + intro i j hij + apply Set.disjoint_left.mpr + intro x hx hy + have hsq := norm_sub_sq (𝕜:=ℂ) (v i) (v j) + rw [hn,hn,ho hij] at hsq + have hdist : dist (v i) (v j)<2/3 := by + have hx' : dist (v i) x<1/3 := by simpa only [Metric.mem_ball,dist_comm] using hx + have hy' : dist x (v j)<1/3 := hy + linarith [dist_triangle (v i) x (v j)] + rw [dist_eq_norm] at hdist + norm_num at hsq + nlinarith [norm_nonneg (v i-v j)] + exact hd.countable_of_isOpen_disjoint (fun _ => Metric.isOpen_ball) + (fun i => ⟨v i,Metric.mem_ball_self (by norm_num)⟩) + +variable [CompleteSpace H] + +namespace PartialIsometryOrder + +variable (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) + +variable (S : Set (Link M e f)) (hS : OrthogonalLinks M e f S) + +include hS + +lemma nonzero_links_countable : Countable {v : S // v.val.val≠0} := by + classical + let I := {v : S // v.val.val≠0} + have he (v : I) : ∃ x : H,v.val.val.val x≠0 := by + by_contra h + apply v.property + ext x + exact not_not.mp (fun hx => h ⟨x,hx⟩) + choose x hx using he + let w (v : I) : H := (‖v.val.val.val (x v)‖:ℂ)⁻¹ • v.val.val.val (x v) + apply countable_of_orthonormal_vectors w + · intro v + simp only [w,norm_smul,norm_inv,Complex.norm_real,Real.norm_of_nonneg (norm_nonneg _)] + exact inv_mul_cancel₀ (norm_ne_zero_iff.mpr (hx v)) + · intro v u hvu + have hne : v.val.val≠u.val.val := fun h => hvu (Subtype.ext (Subtype.ext h)) + have ho := hS v.val.property u.val.property hne + have hi : inner ℂ (v.val.val.val (x v)) (u.val.val.val (x u))=0 := by + rw [←ContinuousLinearMap.adjoint_inner_right] + have hz := congrArg (fun T : H →L[ℂ] H => T (x u)) ho + change v.val.val.val.adjoint (u.val.val.val (x u))=0 at hz + rw [hz,inner_zero_right] + simp only [w,inner_smul_left,inner_smul_right,hi,mul_zero] + +lemma links_countable : Countable S := by + classical + let : Countable {v : S // v.val.val≠0} := nonzero_links_countable M e f S hS + let : Subsingleton {v : S // ¬v.val.val≠0} := ⟨by + intro a b + apply Subtype.ext + apply Subtype.ext + apply Link.ext + exact (not_not.mp a.property).trans (not_not.mp b.property).symm⟩ + exact (Equiv.sumCompl (fun v : S => v.val.val≠0)).symm.injective.countable + +end PartialIsometryOrder + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableProjectionJoin.lean b/lean/OAI/Analysis/Commutator/CountableProjectionJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ddb88087e1f6db623298d4b82a3150fe61a9758 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableProjectionJoin.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicDimensionNormal +import OAI.Analysis.Commutator.ProjectionJoin +import OAI.Analysis.Commutator.ProjectionStrong + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.ProjectionJoin + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def finiteJoin (P : ℕ → H →L[ℂ] H) : ℕ → H →L[ℂ] H + | 0 => 0 + | n+1 => join (finiteJoin P n) (P n) + +lemma finiteJoin_projection (P : ℕ → H →L[ℂ] H) (n : ℕ) : IsStarProjection (finiteJoin P n) := by + induction n with + | zero => exact IsStarProjection.zero _ + | succ n ih => exact join_projection ih _ + +lemma finiteJoin_mem (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) (hP : ∀ n,P n∈M) (n : ℕ) : + finiteJoin P n∈M := by + induction n with + | zero => exact M.zero_mem + | succ n ih => exact join_mem M ih (hP n) + +lemma finiteJoin_mono (P : ℕ → H →L[ℂ] H) : Monotone (finiteJoin P) := + monotone_nat_of_le_succ fun n => left_le (finiteJoin_projection P n) _ + +lemma le_finiteJoin_succ (P : ℕ → H →L[ℂ] H) (hP : ∀ n,IsStarProjection (P n)) (n : ℕ) : + P n≤finiteJoin P (n+1) := right_le (finiteJoin_projection P n) (hP n) + +lemma finiteJoin_le (P : ℕ → H →L[ℂ] H) (hP : ∀ n,IsStarProjection (P n)) + {Q : H →L[ℂ] H} (hQ : IsStarProjection Q) (hle : ∀ n,P n≤Q) (n : ℕ) : finiteJoin P n≤Q := by + induction n with + | zero => exact hQ.nonneg + | succ n ih => exact join_le (finiteJoin_projection P n) (hP n) hQ ih (hle n) + +theorem exists_countable_sup (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) : + ∃ W : H →L[ℂ] H,W∈M ∧ IsStarProjection W ∧ (∀ n,P n≤W) ∧ + (∀ x,Tendsto (fun n => finiteJoin P n x) atTop (𝓝 (W x))) ∧ + ∀ Q : H →L[ℂ] H,IsStarProjection Q → (∀ n,P n≤Q) → W≤Q := by + obtain ⟨W,hWM,hW,hPW,hlim,hle⟩ := ProjectionChains.exists_strong_sup M (finiteJoin P) + (finiteJoin_projection P) (finiteJoin_mem M P hPM) (finiteJoin_mono P) + exact ⟨W,hWM,hW,fun n => (le_finiteJoin_succ P hP n).trans (hPW (n+1)),hlim, + fun Q hQ hPQ => hle Q hQ (finiteJoin_le P hP hQ hPQ)⟩ + +def sup (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) : H →L[ℂ] H := + (exists_countable_sup M P hP hPM).choose + +lemma sup_mem (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) : sup M P hP hPM∈M := + (exists_countable_sup M P hP hPM).choose_spec.1 + +lemma sup_projection (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) : IsStarProjection (sup M P hP hPM) := + (exists_countable_sup M P hP hPM).choose_spec.2.1 + +lemma le_sup (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) (n : ℕ) : P n≤ sup M P hP hPM := + (exists_countable_sup M P hP hPM).choose_spec.2.2.1 n + +lemma sup_strong (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) (x : H) : + Tendsto (fun n => finiteJoin P n x) atTop (𝓝 (sup M P hP hPM x)) := + (exists_countable_sup M P hP hPM).choose_spec.2.2.2.1 x + +lemma sup_le (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hP : ∀ n,IsStarProjection (P n)) (hPM : ∀ n,P n∈M) + {Q : H →L[ℂ] H} (hQ : IsStarProjection Q) (hle : ∀ n,P n≤Q) : sup M P hP hPM≤Q := + (exists_countable_sup M P hP hPM).choose_spec.2.2.2.2 Q hQ hle + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin + +omit [TopologicalSpace.SeparableSpace H] in +lemma dimension_finiteJoin_le (P : ℕ → H →L[ℂ] H) (hP : ∀ n,IsStarProjection (P n)) + (hPM : ∀ n,P n∈M) (n : ℕ) : + dimension M hfac hd (finiteJoin P n)≤∑ k∈Finset.range n,dimension M hfac hd (P k) := by + induction n with + | zero => simpa only [finiteJoin,Finset.range_zero,Finset.sum_empty] using dimension_zero M hfac hd hfin |>.le + | succ n ih => + rw [finiteJoin,Finset.sum_range_succ] + exact (dimension_join_le M hfac hd hfin (finiteJoin_mem M P hPM n) (hPM n) + (finiteJoin_projection P n) (hP n)).trans (by linarith) + +theorem dimension_sup_le (P : ℕ → H →L[ℂ] H) (hP : ∀ n,IsStarProjection (P n)) + (hPM : ∀ n,P n∈M) (b : ℕ → ℝ) (hb : Summable b) + (hPb : ∀ n,dimension M hfac hd (P n)≤b n) : + dimension M hfac hd (sup M P hP hPM)≤∑' n,b n := by + have hlim := dimension_tendsto_of_strong_increasing M hfac hd hfin (sup_mem M P hP hPM) + (sup_projection M P hP hPM) (finiteJoin P) (finiteJoin_mem M P hPM) (finiteJoin_projection P) + (finiteJoin_mono P) (finiteJoin_le P hP (sup_projection M P hP hPM) (le_sup M P hP hPM)) + (sup_strong M P hP hPM) + apply le_of_tendsto_of_tendsto hlim hb.hasSum.tendsto_sum_nat + exact Filter.Eventually.of_forall fun n => (dimension_finiteJoin_le M hfac hd hfin P hP hPM n).trans + (Finset.sum_le_sum fun k _ => hPb k) + +end Kadison.ProjectionJoin + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableStarHomTests.lean b/lean/OAI/Analysis/Commutator/CountableStarHomTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5f6a5621ba89edfecc7afd9aaedb9f580b90163 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableStarHomTests.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyFullRange +import OAI.Analysis.Commutator.StrongDenseTests + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology + +namespace Kadison + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [TopologicalSpace.SeparableSpace A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +abbrev CStarContractions (A : Type*) [CStarAlgebra A] := {a : A // ‖a‖≤1} + +instance contraction_nonempty : Nonempty (CStarContractions A) := ⟨⟨0,by simp⟩⟩ + +def countableContractions : ℕ → A := fun n => + (TopologicalSpace.denseSeq (CStarContractions A) n).val + +omit [PartialOrder A] [StarOrderedRing A] in +lemma countableContractions_norm (n : ℕ) : ‖countableContractions (A:=A) n‖≤1 := + (TopologicalSpace.denseSeq (CStarContractions A) n).property + +omit [PartialOrder A] [StarOrderedRing A] in +lemma countableContractions_approx (a : A) (ha : ‖a‖≤1) {ε : ℝ} (hε : 0<ε) : + ∃ n,‖countableContractions (A:=A) n-a‖<ε := by + obtain ⟨n,hn⟩ := Metric.denseRange_iff.mp + (TopologicalSpace.denseRange_denseSeq (CStarContractions A)) ⟨a,ha⟩ ε hε + exact ⟨n,by simpa only [Subtype.dist_eq,dist_eq_norm,norm_sub_rev,countableContractions] using hn⟩ + +theorem countableContractions_strong_dense (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (T : H →L[ℂ] H) + (hT : T∈Set.centralizer (Set.centralizer (Set.range φ))) (hnT : ‖T‖≤1) : + ∃ k : ℕ → ℕ,∀ ξ,Tendsto + (fun n => φ (countableContractions (A:=A) (k n)) ξ) atTop (𝓝 (T ξ)) := by + classical + let v : ℕ → H := TopologicalSpace.denseSeq H + have hap (n : ℕ) : ∃ k : ℕ,∀ j : Fin n, + ‖φ (countableContractions (A:=A) k) (v j)-T (v j)‖<1/((n:ℝ)+1) := by + let ε : ℝ := 1/((n:ℝ)+1) + have hε : 0<ε := by dsimp [ε]; positivity + obtain ⟨a,ha,he⟩ := Kaplansky.range_contraction_finite_approx φ (Fin n) hT hnT + (fun j => v j) (ε/2) (by positivity) + let M : ℝ := 1+∑ j : Fin n,‖v j‖ + have hM : 0 norm_nonneg (v i)) + (Finset.mem_univ j) + dsimp only [M] + linarith + have hsmall : ‖φ (countableContractions (A:=A) k-a) (v j)‖<ε/2 := by + calc + ‖φ (countableContractions (A:=A) k-a) (v j)‖≤ + ‖φ (countableContractions (A:=A) k-a)‖*‖v j‖ := + (φ (countableContractions (A:=A) k-a)).le_opNorm _ + _≤‖countableContractions (A:=A) k-a‖*‖v j‖ := + mul_le_mul_of_nonneg_right (NonUnitalStarAlgHom.norm_apply_le φ _) (norm_nonneg _) + _≤‖countableContractions (A:=A) k-a‖*M := + mul_le_mul_of_nonneg_left hvM (norm_nonneg _) + _<(ε/2/M)*M := mul_lt_mul_of_pos_right hk hM + _=ε/2 := div_mul_cancel₀ _ (ne_of_gt hM) + have hid : φ (countableContractions (A:=A) k) (v j)-T (v j)= + φ (countableContractions (A:=A) k-a) (v j)+(φ a (v j)-T (v j)) := by + simp only [map_sub,sub_apply] + abel + rw [hid] + exact (norm_add_le _ _).trans_lt (by linarith [he j]) + choose k hk using hap + have hlim (j : ℕ) : Tendsto (fun n => φ (countableContractions (A:=A) (k n)) (v j)) + atTop (𝓝 (T (v j))) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + apply squeeze_zero' (Eventually.of_forall (fun _ => norm_nonneg _)) _ + tendsto_one_div_add_atTop_nhds_zero_nat + filter_upwards [eventually_ge_atTop (j+1)] with n hn + exact (hk n ⟨j,by omega⟩).le + exact ⟨k,strong_tendsto_of_dense_tests v (TopologicalSpace.denseRange_denseSeq H) + (fun n => φ (countableContractions (A:=A) (k n))) T + (fun n => (NonUnitalStarAlgHom.norm_apply_le φ _).trans (countableContractions_norm _)) + hnT hlim⟩ + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableStrongTests.lean b/lean/OAI/Analysis/Commutator/CountableStrongTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..7dec1994824f90fe0912f98c01216be29e74ed4e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableStrongTests.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.Commutator.StrongDenseTests + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +theorem exists_countable_strong_contraction_tests (P : VonNeumannAlgebra H) : + ∃ test : ℕ → H →L[ℂ] H,(∀ n,test n∈P ∧ ‖test n‖≤1) ∧ + ∀ A : H →L[ℂ] H,A∈P → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) ξ) atTop (𝓝 (A ξ)) := by + let v : ℕ → H := TopologicalSpace.denseSeq H + let S : Set (ℕ → H) := {f | ∃ A : H →L[ℂ] H,A∈P ∧ ‖A‖≤1 ∧ ∀ j,f j=A (v j)} + have hS : S.Nonempty := ⟨fun _ => 0,0,P.zero_mem,by simp,by simp⟩ + let : Nonempty S := hS.to_subtype + let s : ℕ → S := TopologicalSpace.denseSeq S + choose test hP hb ht using (fun n => (s n).property) + refine ⟨test,fun n => ⟨hP n,hb n⟩,?_⟩ + intro A hA hnA + let f : S := ⟨fun j => A (v j),A,hA,hnA,fun _ => rfl⟩ + have hd : DenseRange s := TopologicalSpace.denseRange_denseSeq S + obtain ⟨u,hu,hl⟩ := mem_closure_iff_seq_limit.mp (hd f) + choose k hk using hu + have hlim : Tendsto (fun n => s (k n)) atTop (𝓝 f) := by + have he : (fun n => s (k n))=u := funext hk + rwa [he] + have hj (j : ℕ) : Tendsto (fun n => test (k n) (v j)) atTop (𝓝 (A (v j))) := by + have hv := (continuous_apply j |>.comp continuous_subtype_val).tendsto f |>.comp hlim + change Tendsto (fun n => (s (k n)).val j) atTop (𝓝 (A (v j))) at hv + simpa only [ht] using hv + exact ⟨k,strong_tendsto_of_dense_tests v (TopologicalSpace.denseRange_denseSeq H) + (fun n => test (k n)) A (fun n => hb (k n)) hnA hj⟩ + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountableUnitaryTests.lean b/lean/OAI/Analysis/Commutator/CountableUnitaryTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..e81062111d1115fdb88268439f2b4a09a1914345 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountableUnitaryTests.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFullUnitaryTests +import OAI.Analysis.Commutator.PartialWordReindex + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching + +open Words + +section Reindex + +variable {A : Type*} [CStarAlgebra A] + +lemma eventually_letter_truncate (x : ℕ → A) (k : ℕ → ℤ) (v : ℕ → PartialUnitary A) + (i : Letter ℕ ℕ) : ∀ᶠ n : ℕ in atTop, + letter (fun j => x (min j n)) (fun j => k (min j n)) (v n) i=letter x k (v n) i := by + rcases i with ⟨j,s⟩ + cases s with + | none => + filter_upwards [eventually_ge_atTop j] with n hn + simp [letter,slotPower,min_eq_left hn] + | some s => + cases s with + | none => + filter_upwards [eventually_ge_atTop j] with n hn + simp [letter,slotPower,min_eq_left hn] + | some i => + filter_upwards [eventually_ge_atTop j,eventually_ge_atTop i] with n hn hi + simp [letter,slotPower,min_eq_left hn,min_eq_left hi] + +lemma eventually_word_truncate (x : ℕ → A) (k : ℕ → ℤ) (v : ℕ → PartialUnitary A) + (l : List (Letter ℕ ℕ)) : ∀ᶠ n : ℕ in atTop, + word (fun j => x (min j n)) (fun j => k (min j n)) (v n) l=word x k (v n) l := by + induction l with + | nil => exact Eventually.of_forall (fun _ => rfl) + | cons i l ih => + filter_upwards [eventually_letter_truncate x k v i,ih] with n hn hl + simp only [word_cons,hn,hl] + +end Reindex + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R ≤ M) + +variable (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +variable {ι : ℕ → Type*} [∀ n,Fintype (ι n)] [∀ n,LinearOrder (ι n)] + [∀ n,Nonempty (ι n)] + +variable (stage : ∀ n,Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range ≤ (stage m).range) + +include hRM hτ hmono in +theorem exists_countable_unitary_tests + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (ι n) (ι n) ℂ),stage n a*b=b*stage n a) → + ∃ c : ℂ,b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) + (x : ℕ → M) (k : ℕ → ℤ) (hx : ∀ j,‖x j‖ ≤ 1) + (hcenter : ∀ j,τ (x j)=0) (hk : ∀ i,k i≠0) : + ∃ u : ℕ → unitary M, (∀ n, ((u n:M) : H →L[ℂ] H)∈R) ∧ + (∀ i,Tendsto (fun n => τ ((PartialUnitary.ofUnitary (u n)).power (k i))) atTop (𝓝 0)) ∧ + (∀ l : List (Letter ℕ ℕ), l≠[] → Valid l → + Tendsto (fun n => τ (word x k (PartialUnitary.ofUnitary (u n)) l)) atTop (𝓝 0)) := by + classical + have hfinite (n : ℕ) := exists_full_unitary_finite_tests M R hRM τ hτ stage hmono + hnormal hfaith hone hirr hgrow hstage hdiffuse + (fun j : Fin (n+1) => x j) (fun i : Fin (n+1) => k i) + (fun j => hx j) (fun j => hcenter j) (fun i => hk i) n + (pow_pos (by norm_num : (0:ℝ)<1/2) n) + choose u huR hu using hfinite + have hbound (n : ℕ) : MomentBound τ (fun j => x (min j n)) (fun i => k (min i n)) + (PartialUnitary.ofUnitary (u n)) n ((1/2:ℝ)^n) := by + let f : ℕ → Fin (n+1) := fun j => ⟨min j n,Nat.lt_succ_of_le (min_le_right _ _)⟩ + exact momentBound_reindex τ _ _ f f _ (hu n) + have hlim : Tendsto (fun n : ℕ => (1/2:ℝ)^n) atTop (𝓝 0) := + tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num) (by norm_num) + refine ⟨u,huR,?_,?_⟩ + · intro i + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply squeeze_zero' (Eventually.of_forall (fun _ => norm_nonneg _)) _ hlim + filter_upwards [eventually_ge_atTop i] with n hn + simpa only [min_eq_left hn] using (hbound n).1 i + · intro l hl hv + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply squeeze_zero' (Eventually.of_forall (fun _ => norm_nonneg _)) _ hlim + filter_upwards [eventually_ge_atTop l.length, + eventually_word_truncate x k (fun n => PartialUnitary.ofUnitary (u n)) l] with n hn he + rw [←he] + exact (hbound n).2 l hl hn hv + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CountablyGeneratedCStar.lean b/lean/OAI/Analysis/Commutator/CountablyGeneratedCStar.lean new file mode 100644 index 0000000000000000000000000000000000000000..55c4d46681b74b940826f96760a2769f2127f302 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CountablyGeneratedCStar.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.CountableStrongTests +import OAI.Analysis.Commutator.DenseCommutes +import OAI.Analysis.Commutator.MatrixTowerGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +namespace Kadison + +lemma countable_submonoidClosure {A : Type*} [Monoid A] {s : Set A} (hs : s.Countable) : + (Submonoid.closure s : Set A).Countable := by + let := hs.to_subtype + rw [Submonoid.closure_eq_mrange,MonoidHom.coe_mrange] + exact Set.countable_range _ + +lemma separable_starAdjoin {A : Type*} [CStarAlgebra A] {s : Set A} (hs : s.Countable) : + TopologicalSpace.IsSeparable (StarAlgebra.adjoin ℂ s : Set A) := by + have hss : (s ∪ star s).Countable := hs.union (by simpa only [Set.image_star] using hs.image star) + have hh := ((countable_submonoidClosure hss).isSeparable.span (R:=ℂ)) + have he : (StarAlgebra.adjoin ℂ s : Set A)= + (Submodule.span ℂ (Submonoid.closure (s∪star s) : Set A) : Set A) := + congrArg (fun M : Submodule ℂ A => (M:Set A)) (StarAlgebra.adjoin_eq_span (R:=ℂ) s) + rwa [he] + +theorem exists_separable_cstar_bicommutant + {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] (P : VonNeumannAlgebra H) : + ∃ S : StarSubalgebra ℂ (H →L[ℂ] H),IsClosed (S:Set (H →L[ℂ] H)) ∧ + TopologicalSpace.SeparableSpace S ∧ S≤P.toStarSubalgebra ∧ NormalGNS.bicommutant S=P := by + obtain ⟨test,ht,hd⟩ := exists_countable_strong_contraction_tests P + let S := (StarAlgebra.adjoin ℂ (Set.range test)).topologicalClosure + have hclosed : IsClosed (S:Set (H →L[ℂ] H)) := StarSubalgebra.isClosed_topologicalClosure _ + have hsep : TopologicalSpace.SeparableSpace S := by + apply TopologicalSpace.IsSeparable.separableSpace + exact (separable_starAdjoin (Set.countable_range test)).closure + have hSP : S≤P.toStarSubalgebra := StarSubalgebra.topologicalClosure_minimal + (StarAlgebra.adjoin_le (by rintro _ ⟨n,rfl⟩; exact (ht n).1)) (VonNeumannCStar.isClosed P) + have htt (n : ℕ) : test n∈S := StarSubalgebra.le_topologicalClosure _ + (StarAlgebra.subset_adjoin ℂ _ (Set.mem_range_self n)) + refine ⟨S,hclosed,hsep,hSP,?_⟩ + apply SetLike.ext + intro A + rw [NormalGNS.mem_bicommutant] + constructor + · intro ha + have hc := Set.centralizer_subset (Set.centralizer_subset hSP) ha + change A∈Set.centralizer (Set.centralizer (P : Set (H →L[ℂ] H))) at hc + change A∈(P : Set (H →L[ℂ] H)) + rwa [VonNeumannAlgebra.centralizer_centralizer] at hc + · intro hA B hB + exact (commutes_of_dense_contraction_tests P test hd B + (fun n => hB _ (htt n)) A hA).eq.symm + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CpCompression.lean b/lean/OAI/Analysis/Commutator/CpCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..47a35c8aa544e56bf6f0a621302ee32eba70b9e5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CpCompression.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.FaithfulPositive + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.CpCompression + +variable {A H K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def compression (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (V : H →L[ℂ] K) : A →CP (H →L[ℂ] H) where + toLinearMap := + { toFun a := V.adjoint.comp ((ρ a).comp V) + map_add' a b := by simp [ContinuousLinearMap.add_comp,ContinuousLinearMap.comp_add] + map_smul' c a := by simp [ContinuousLinearMap.smul_comp] } + map_cstarMatrix_nonneg' n M hM := by + classical + let : DecidableEq (Fin n) := Classical.decEq (Fin n) + let Vn : PiLp 2 (fun _ : Fin n => H) →L[ℂ] PiLp 2 (fun _ : Fin n => K) := + CyclicColumns.matrixAction (fun i j => if i=j then V else 0) + have hVn (x : PiLp 2 (fun _ : Fin n => H)) (i : Fin n) : Vn x i=V (x i) := by + rw [CyclicColumns.matrixAction_apply] + calc + _ = ∑ j,if i=j then V (x j) else 0 := by + apply Finset.sum_congr rfl + intro j _ + by_cases h : i=j <;> simp [h] + _ = V (x i) := by simp + let R := CyclicColumns.matrixRepresentation (ι:=Fin n) (StarAlgHom.id ℂ (H →L[ℂ] H)) + have hR : Function.Injective R := + CyclicSpatial.matrixRepresentation_injective (ι:=Fin n) + (StarAlgHom.id ℂ (H →L[ℂ] H)) Function.injective_id + have hiff := @faithfulStar_nonneg_iff + (CStarMatrix (Fin n) (Fin n) (H →L[ℂ] H)) + (PiLp 2 (fun _ : Fin n => H) →L[ℂ] PiLp 2 (fun _ : Fin n => H)) + inferInstance inferInstance inferInstance inferInstance inferInstance inferInstance R hR + apply (hiff _).mp + have hp : 0 ≤ CyclicColumns.matrixRepresentation (ι:=Fin n) ρ M := + map_nonneg (CyclicColumns.matrixRepresentation (ι:=Fin n) ρ) hM + apply ContinuousLinearMap.nonneg_iff_isPositive.mpr + apply (ContinuousLinearMap.isPositive_iff_complex _).mpr + intro x + suffices hx : 0 ≤ ⟪R (M.map _ ) x,x⟫_ℂ by + exact ⟨Complex.ext (by simp) (by simpa using hx.2),hx.1⟩ + have hi := ContinuousLinearMap.nonneg_iff_isPositive.mp hp + convert hi.inner_nonneg_left (Vn x) using 1 + dsimp only [R] + simp [CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply, + PiLp.inner_apply,hVn,sum_inner,ContinuousLinearMap.adjoint_inner_left] + +@[simp] lemma compression_apply (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (V : H →L[ℂ] K) (a : A) : + compression ρ V a=V.adjoint.comp ((ρ a).comp V) := rfl + +end Kadison.CpCompression + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CpMapOperations.lean b/lean/OAI/Analysis/Commutator/CpMapOperations.lean new file mode 100644 index 0000000000000000000000000000000000000000..4a8e4fb496f630d841e92f7296aa5958a8ed3a98 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CpMapOperations.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.CpCompression +import OAI.Analysis.Commutator.OperatorSystem +import OAI.Analysis.Commutator.StinespringDilation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.CpOperations + +variable {A B C : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + [CStarAlgebra C] [PartialOrder C] [StarOrderedRing C] + +def comp (g : B →CP C) (f : A →CP B) : A →CP C where + toLinearMap := g.toLinearMap.comp f.toLinearMap + map_cstarMatrix_nonneg' n X hX := by + have h := g.map_cstarMatrix_nonneg _ (f.map_cstarMatrix_nonneg X hX) + convert h using 1 + ext i j + rfl + +@[simp] lemma comp_apply (g : B →CP C) (f : A →CP B) (a : A) : comp g f a=g (f a) := rfl + +lemma isCompletelyPositive_comp (S : Submodule ℂ A) (f : S →ₗ[ℂ] B) + (hf : OperatorSystem.IsCompletelyPositive S f) (g : B →CP C) : + OperatorSystem.IsCompletelyPositive S (g.toLinearMap.comp f) := by + intro ι _ X hX + have h := g.map_cstarMatrix_nonneg _ (hf ι X hX) + convert h using 1 + ext i j + rfl + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def compression (V : K →L[ℂ] H) : (H →L[ℂ] H) →CP (K →L[ℂ] K) := + CpCompression.compression (StarAlgHom.id ℂ (H →L[ℂ] H)) V + +@[simp] lemma compression_apply (V : K →L[ℂ] H) (T : H →L[ℂ] H) : + compression V T=V.adjoint.comp (T.comp V) := rfl + +lemma norm_apply_le (φ : A →CP (H →L[ℂ] H)) (a : A) : ‖φ a‖≤‖φ 1‖*‖a‖ := by + rw [Stinespring.factorization φ a] + have hρ : ‖Stinespring.representation φ a‖≤‖a‖ := NonUnitalStarAlgHom.norm_apply_le (Stinespring.representation φ) a + calc + _ ≤ ‖(Stinespring.embedding φ).adjoint‖ * (‖Stinespring.representation φ a‖ * ‖Stinespring.embedding φ‖) := + (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_left (ContinuousLinearMap.opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ ‖Stinespring.embedding φ‖ * (‖a‖ * ‖Stinespring.embedding φ‖) := by + simp only [LinearIsometryEquiv.norm_map] + gcongr + _ = ‖φ 1‖*‖a‖ := by rw [←Stinespring.embedding_norm_sq]; ring + +end Kadison.CpOperations + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CpUltralimit.lean b/lean/OAI/Analysis/Commutator/CpUltralimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..8203fc39ef02c33940d81bc7215bb96fb385dda9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CpUltralimit.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.FaithfulPositive + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra Topology + +open Filter + +namespace Kadison.CpOperations + +variable {A H I : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma cp_of_weak_limit {l : Filter I} [l.NeBot] (φ : I → A →CP (H →L[ℂ] H)) + (V : A →ₗ[ℂ] (H →L[ℂ] H)) + (hlim : ∀ a x y,Tendsto (fun i => ⟪φ i a x,y⟫_ℂ) l (𝓝 ⟪V a x,y⟫_ℂ)) + (n : ℕ) (X : CStarMatrix (Fin n) (Fin n) A) (hX : 0≤X) : 0≤X.map V := by + classical + let : DecidableEq (Fin n) := Classical.decEq (Fin n) + let R := CyclicColumns.matrixRepresentation (ι:=Fin n) (StarAlgHom.id ℂ (H →L[ℂ] H)) + have hR : Function.Injective R := CyclicSpatial.matrixRepresentation_injective (ι:=Fin n) + (StarAlgHom.id ℂ (H →L[ℂ] H)) Function.injective_id + have hiff := @faithfulStar_nonneg_iff + (CStarMatrix (Fin n) (Fin n) (H →L[ℂ] H)) + (PiLp 2 (fun _ : Fin n => H) →L[ℂ] PiLp 2 (fun _ : Fin n => H)) + inferInstance inferInstance inferInstance inferInstance inferInstance inferInstance R hR + apply (hiff _).mp + apply ContinuousLinearMap.nonneg_iff_isPositive.mpr + apply (ContinuousLinearMap.isPositive_iff_complex _).mpr + intro x + have hp (i : I) : 0≤⟪R (X.map (φ i)) x,x⟫_ℂ := + (ContinuousLinearMap.nonneg_iff_isPositive.mp + (map_nonneg R ((φ i).map_cstarMatrix_nonneg X hX))).inner_nonneg_left x + have hl : Tendsto (fun i => ⟪R (X.map (φ i)) x,x⟫_ℂ) l (𝓝 ⟪R (X.map V) x,x⟫_ℂ) := by + simp [R,CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply, + PiLp.inner_apply,sum_inner,CStarMatrix.map_apply] + apply tendsto_finsetSum + intro k _ + apply tendsto_finsetSum + intro j _ + exact hlim (X k j) (x j) (x k) + have hn : 0≤⟪R (X.map V) x,x⟫_ℂ := ge_of_tendsto hl (Eventually.of_forall hp) + exact ⟨Complex.ext (by simp) (by simpa using hn.2),hn.1⟩ + +theorem exists_cp_ultralimit (ω : Ultrafilter I) (φ : I → A →CP (H →L[ℂ] H)) + (C : ℝ) (hC : 0≤C) (hφ : ∀ i a,‖φ i a‖≤C*‖a‖) : + ∃ Ψ : A →CP (H →L[ℂ] H), (∀ a,‖Ψ a‖≤C*‖a‖) ∧ + ∀ a x y,Tendsto (fun i => ⟪φ i a x,y⟫_ℂ) (ω : Filter I) (𝓝 ⟪Ψ a x,y⟫_ℂ) := by + choose V hV hlim using fun a => WeakOperatorLimit.exists_ultralimit ω + (fun i => φ i a) (C*‖a‖) (mul_nonneg hC (norm_nonneg _)) (fun i => hφ i a) + have hadd (a b : A) : V (a+b)=V a+V b := by + ext x + apply ext_inner_right ℂ + intro y + apply tendsto_nhds_unique (hlim (a+b) x y) + simpa only [map_add,add_apply,inner_add_left] using + (hlim a x y).add (hlim b x y) + have hsmul (c : ℂ) (a : A) : V (c • a)=c • V a := by + ext x + apply ext_inner_right ℂ + intro y + apply tendsto_nhds_unique (hlim (c • a) x y) + simpa only [map_smul,smul_apply,inner_smul_left] using + tendsto_const_nhds.mul (hlim a x y) + let Vₗ : A →ₗ[ℂ] (H →L[ℂ] H) := + { toFun := V + map_add' := hadd + map_smul' := hsmul } + exact ⟨{ toLinearMap := Vₗ + map_cstarMatrix_nonneg' := cp_of_weak_limit φ Vₗ hlim },hV,hlim⟩ + +end Kadison.CpOperations + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CrossingPairings.lean b/lean/OAI/Analysis/Commutator/CrossingPairings.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a82e7621b14c9b55e4c2c3b5794ad34c0c05118 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CrossingPairings.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.Commutator.FinitePairings3 +import OAI.Analysis.Commutator.Pairings + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +namespace Pairing + +def Crosses {k l : ℕ} (τ : Pairing (TailSlots k l)) : Prop := + (∀ a : Fin k, ∃ b : Fin l, τ (.inl a) = .inr b) ∧ + (∀ b : Fin l, ∃ a : Fin k, τ (.inr b) = .inl a) + +def crossPairing {k l : ℕ} (e : Fin k ≃ Fin l) : Pairing (TailSlots k l) := + ⟨{ toFun := Sum.elim (fun a => .inr (e a)) (fun b => .inl (e.symm b)) + invFun := Sum.elim (fun a => .inr (e a)) (fun b => .inl (e.symm b)) + left_inv := by + intro j + cases j with + | inl a => exact congrArg Sum.inl (e.symm_apply_apply a) + | inr b => exact congrArg Sum.inr (e.apply_symm_apply b) + right_inv := by + intro j + cases j with + | inl a => exact congrArg Sum.inl (e.symm_apply_apply a) + | inr b => exact congrArg Sum.inr (e.apply_symm_apply b) }, + by + intro j + cases j with + | inl a => exact congrArg Sum.inl (e.symm_apply_apply a) + | inr b => exact congrArg Sum.inr (e.apply_symm_apply b), + by intro j; cases j <;> intro h <;> cases h⟩ + +@[simp] theorem crossPairing_inl {k l : ℕ} (e : Fin k ≃ Fin l) (a : Fin k) : + crossPairing e (.inl a) = .inr (e a) := rfl + +@[simp] theorem crossPairing_inr {k l : ℕ} (e : Fin k ≃ Fin l) (b : Fin l) : + crossPairing e (.inr b) = .inl (e.symm b) := rfl + +theorem crossPairing_crosses {k l : ℕ} (e : Fin k ≃ Fin l) : + Crosses (crossPairing e) := + ⟨fun a => ⟨e a, rfl⟩, fun b => ⟨e.symm b, rfl⟩⟩ + +theorem crossPairing_injective {k l : ℕ} : + Function.Injective (@crossPairing k l) := by + intro e f h + apply Equiv.ext + intro a + exact Sum.inr_injective (congrArg (fun τ : Pairing (TailSlots k l) => τ (.inl a)) h) + +theorem exists_crossPairing {k l : ℕ} (τ : Pairing (TailSlots k l)) (hτ : Crosses τ) : + ∃ e : Fin k ≃ Fin l, crossPairing e = τ := by + let f : Fin k → Fin l := fun a => (hτ.1 a).choose + have hf (a : Fin k) : τ (.inl a) = .inr (f a) := (hτ.1 a).choose_spec + have hinj : Function.Injective f := by + intro a b hab + apply Sum.inl_injective + apply τ.injective + rw [hf, hf, hab] + have hsurj : Function.Surjective f := by + intro b + obtain ⟨a, ha⟩ := hτ.2 b + refine ⟨a, ?_⟩ + have hh := τ.apply_apply (.inr b) + rw [ha, hf] at hh + exact Sum.inr_injective hh + let e : Fin k ≃ Fin l := Equiv.ofBijective f ⟨hinj, hsurj⟩ + refine ⟨e, ?_⟩ + apply ext + intro j + cases j with + | inl a => exact (hf a).symm + | inr b => + apply τ.injective + erw [τ.apply_apply, crossPairing_inr, hf] + change Sum.inr (e (e.symm b)) = .inr b + rw [e.apply_symm_apply] + +def crossingEquiv (k l : ℕ) : (Fin k ≃ Fin l) ≃ {τ : Pairing (TailSlots k l) // Crosses τ} := + Equiv.ofBijective (fun e => ⟨crossPairing e, crossPairing_crosses e⟩) + ⟨fun _ _ h => crossPairing_injective (congrArg Subtype.val h), by + rintro ⟨τ, hτ⟩ + obtain ⟨e, he⟩ := exists_crossPairing τ hτ + exact ⟨e, Subtype.ext he⟩⟩ + +@[simp] theorem crossingEquiv_val (k l : ℕ) (e : Fin k ≃ Fin l) : + (crossingEquiv k l e).val = crossPairing e := rfl + +theorem contraction_crossPairing {k l : ℕ} {E : Type*} (e : Fin k ≃ Fin l) + (B : E → E → ℂ) (v : TailSlots k l → E) : + contraction (crossPairing e) B v = ∏ a, B (v (.inl a)) (v (.inr (e a))) := by + classical + rw [contraction, Finset.prod_filter] + erw [Fintype.prod_sum_type] + simp only [crossPairing_inl, crossPairing_inr] + change (∏ a : Fin k, if (toLex (.inl a) : TailSlots k l) < toLex (.inr (e a)) + then B (v (toLex (.inl a))) (v (toLex (.inr (e a)))) else 1) * + (∏ b : Fin l, if (toLex (.inr b) : TailSlots k l) < toLex (.inl (e.symm b)) + then B (v (toLex (.inr b))) (v (toLex (.inl (e.symm b)))) else 1) = _ + simp + rfl + +theorem sum_contraction_crossing {k l : ℕ} {E : Type*} + (B : E → E → ℂ) (v : TailSlots k l → E) (c : Pairing (TailSlots k l) → ℂ) + (hz : ∀ τ, ¬ Crosses τ → c τ = 0) : + (∑ τ, c τ * contraction τ B v) = + ∑ e : Fin k ≃ Fin l, c (crossPairing e) * ∏ a, B (v (.inl a)) (v (.inr (e a))) := by + classical + calc + _ = ∑ τ ∈ Finset.univ.filter Crosses, c τ * contraction τ B v := by + symm + apply Finset.sum_subset (Finset.filter_subset _ _) + intro τ _ hτ + rw [hz τ (by simpa using hτ), zero_mul] + _ = ∑ τ : {τ : Pairing (TailSlots k l) // Crosses τ}, + c τ.val * contraction τ.val B v := by + exact Finset.sum_subtype (F := inferInstance) _ (by intro τ; simp) _ + _ = ∑ e : Fin k ≃ Fin l, c (crossPairing e) * contraction (crossPairing e) B v := by + exact (Equiv.sum_comp (crossingEquiv k l) _).symm + _ = _ := by simp_rw [contraction_crossPairing] + +end Pairing + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleEmbeddings.lean b/lean/OAI/Analysis/Commutator/CycleEmbeddings.lean new file mode 100644 index 0000000000000000000000000000000000000000..bae88b039a1fee7e5fdcecff59f14f1dbfedd0bf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleEmbeddings.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants +import OAI.Analysis.Commutator.MatrixClassification +import OAI.Analysis.Commutator.RectangularTensors + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +variable {I K J : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + [Fintype K] [DecidableEq K] [Nonempty K] [Fintype J] [DecidableEq J] + +theorem cycleTrace_map (φ : Matrix I I ℂ →ₐ[ℂ] Matrix K K ℂ) + (σ : Equiv.Perm J) (A : J → Matrix I I ℂ) : + cycleTrace σ (fun j => φ (A j)) = cycleTrace σ A := by + classical + let o : I := Classical.choice ‹Nonempty I› + let E := MatrixModules.corner (MatrixModules.matrixRepresentation φ) o + let R := Fin (Module.finrank ℂ E) + let b : Module.Basis R ℂ E := Module.finBasis ℂ E + let : Nonempty R := MatrixModules.multiplicity_nonempty φ o b + let X := MatrixModules.forwardMatrix φ o b + let Y := MatrixModules.backwardMatrix φ o b + have hYX : Y * X = 1 := MatrixModules.backward_forward φ o b + have hA : (fun j => φ (A j)) = fun j => X * inflateMatrix (R := R) (A j) * Y := by + funext j + exact MatrixModules.classification φ o b (A j) + have hr : rawCycleTrace σ (fun j => φ (A j)) = + rawCycleTrace σ (fun j => inflateMatrix (R := R) (A j)) := by + rw [hA] + exact RectangularTensors.trace_transport X Y hYX _ σ + have hc : Fintype.card K = Fintype.card (I × R) := by + simpa only [Fintype.card_prod] using (MatrixModules.dimensions φ o b).symm + calc + _ = cycleTrace σ (fun j => inflateMatrix (R := R) (A j)) := by + simp only [cycleTrace, hr, hc] + _ = _ := cycleTrace_inflate R σ A + +theorem stable_cycle_coefficients_map + (φ : Matrix I I ℂ →ₐ[ℂ] Matrix K K ℂ) + (b : J → I) (hb : Function.Injective b) (c d : Equiv.Perm J → ℂ) + (h : ∀ A : J → Matrix I I ℂ, + ∑ σ, c σ * cycleTrace σ A = ∑ σ, d σ * cycleTrace σ (fun j => φ (A j))) : + c = d := by + apply cycleTrace_coefficients_unique b hb c d + intro A + simpa only [cycleTrace_map] using h A + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleEmbeddings2.lean b/lean/OAI/Analysis/Commutator/CycleEmbeddings2.lean new file mode 100644 index 0000000000000000000000000000000000000000..634a72c28c643a332a6996d5e3e096ecb239f13f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleEmbeddings2.lean @@ -0,0 +1,48 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleEmbeddings + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +variable {J : Type*} [Fintype J] [DecidableEq J] + +theorem matrix_union_expansion (I : ℕ → Type*) + [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (F : ∀ n, MultilinearMap ℂ (fun _ : J => Matrix (I n) (I n) ℂ) ℂ) + (hinv : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)) (A : J → Matrix (I n) (I n) ℂ), + F n (fun j => (u : Matrix (I n) (I n) ℂ) * A j * star (u : Matrix (I n) (I n) ℂ)) = F n A) + (hcomp : ∀ n m (h : n ≤ m) (A : J → Matrix (I n) (I n) ℂ), + F m (fun j => φ h (A j)) = F n A) : + ∃ c : Equiv.Perm J → ℂ, ∀ n (A : J → Matrix (I n) (I n) ℂ), + F n A = ∑ σ, c σ * cycleTrace σ A := by + classical + obtain ⟨n₀, _, hn₀⟩ := hsize 0 (Fintype.card J) + let b : J ↪ I n₀ := Classical.choice (Function.Embedding.nonempty_of_card_le hn₀) + obtain ⟨c, hc, _⟩ := invariant_multilinear_form_normalized b b.injective (F n₀) (hinv n₀) + refine ⟨c, ?_⟩ + intro n A + obtain ⟨m, hnm, hm⟩ := hsize (max n n₀) (Fintype.card J) + have hn : n ≤ m := (le_max_left n n₀).trans hnm + have hn₀m : n₀ ≤ m := (le_max_right n n₀).trans hnm + let b' : J ↪ I m := Classical.choice (Function.Embedding.nonempty_of_card_le hm) + obtain ⟨d, hd, _⟩ := invariant_multilinear_form_normalized b' b'.injective (F m) (hinv m) + have hcd : c = d := by + apply stable_cycle_coefficients_map (φ hn₀m) b b.injective + intro B + rw [← hc, ← hd, hcomp] + rw [← hcomp n m hn A, hd] + simp only [← hcd, cycleTrace_map] + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleEndpoint.lean b/lean/OAI/Analysis/Commutator/CycleEndpoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..56f802265e98a23a1e1a086fcb3c07b4db3aeb89 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleEndpoint.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants +import OAI.Analysis.Commutator.EndpointElimination +import OAI.Analysis.Commutator.EndpointElimination2 +import OAI.Analysis.Commutator.EndpointElimination3 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.SchurWeyl + +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +variable {J : Type*} [Fintype J] [DecidableEq J] + +theorem endpoint_coefficient_bound {I : Type*} [Fintype I] [DecidableEq I] + (a : J) (b : J → I) (hb : Function.Injective b) + (F : (J → Matrix I I ℂ) → ℂ) (c : Equiv.Perm J → ℂ) (C : ℝ) + (hF : ∀ A, F A = ∑ σ, c σ * cycleTrace σ A) + (hbound : ∀ A, ‖F A‖ ≤ C * matrixL1 (A a) * + ∏ j ∈ Finset.univ.erase a, matrixL2 (A j)) (σ : Equiv.Perm J) : + ‖c σ‖ * ((Fintype.card I : ℝ)⁻¹) ^ cycleCount σ ≤ + C * (Fintype.card I : ℝ)⁻¹ * + (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ (Fintype.card J - 1) := by + classical + let A : J → Matrix I I ℂ := fun j => Matrix.single (b (σ j)) (b j) 1 + have he : F A = c σ * ((Fintype.card I : ℂ)⁻¹) ^ cycleCount σ := by + rw [hF] + simp only [A, cycleTrace_single b hb, mul_ite, mul_zero, + Finset.sum_ite_eq', Finset.mem_univ, ite_true] + have hh := hbound A + rw [he, norm_mul, norm_pow, norm_inv, Complex.norm_natCast] at hh + simpa only [A, matrixL1_single, matrixL2_single, Finset.prod_const, + Finset.card_erase_of_mem (Finset.mem_univ a), Finset.card_univ] using hh + +theorem endpoint_coefficients_vanish + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] + (a : J) (b : ∀ n, J → I n) (hb : ∀ n, Function.Injective (b n)) + (F : ∀ n, (J → Matrix (I n) (I n) ℂ) → ℂ) + (c : Equiv.Perm J → ℂ) (C : ℝ) (hC : 0 ≤ C) + (hF : ∀ n A, F n A = ∑ σ, c σ * cycleTrace σ A) + (hbound : ∀ n A, ‖F n A‖ ≤ C * matrixL1 (A a) * + ∏ j ∈ Finset.univ.erase a, matrixL2 (A j)) + (hunbounded : ∀ B : ℕ, ∃ n, B ≤ Fintype.card (I n)) + (σ : Equiv.Perm J) (hσ : 2 * cycleCount σ < Fintype.card J + 1) : c σ = 0 := by + refine coefficient_zero_of_unbounded_stages + (c σ) C (Fintype.card J) (cycleCount σ) (fun n => Fintype.card (I n)) + hunbounded ?_ hσ + intro n + have hI : 0 < (Fintype.card (I n) : ℝ) := by + have : Nonempty (I n) := ⟨b n a⟩ + exact_mod_cast Fintype.card_pos + have hp : 1 ≤ Fintype.card J := by + have : Nonempty J := ⟨a⟩ + exact Fintype.card_pos + exact square_endpoint_unit_bound ‖c σ‖ C (Fintype.card (I n)) (Fintype.card J) + (cycleCount σ) (norm_nonneg _) hC hI hp + (endpoint_coefficient_bound a (b n) (hb n) (F n) c C (hF n) (hbound n) σ) + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleInvariants.lean b/lean/OAI/Analysis/Commutator/CycleInvariants.lean new file mode 100644 index 0000000000000000000000000000000000000000..1f3f176f1afdda201ca5e150f9387226d2574d8e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleInvariants.lean @@ -0,0 +1,220 @@ +import Mathlib +import OAI.Analysis.Commutator.InvariantForms + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +open Matrix + +variable {𝕜 : Type*} [CommRing 𝕜] + +variable {I J : Type*} [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] + +def rawCycleTrace (σ : Equiv.Perm J) (A : J → Matrix I I 𝕜) : 𝕜 := + Matrix.trace (permutationMatrix σ * tensorMatrices A) + +lemma rawCycleTrace_eq_sum (σ : Equiv.Perm J) (A : J → Matrix I I 𝕜) : + rawCycleTrace σ A = ∑ a : J → I, ∏ j, A j (a (σ j)) (a j) := by + classical + simp only [rawCycleTrace, Matrix.trace, Matrix.diag_apply, Matrix.mul_apply, + permutationMatrix, tensorMatrices] + apply Finset.sum_congr rfl + intro a _ + have he (b : J → I) : a = b ∘ σ.symm ↔ b = a ∘ σ := by + constructor + · intro h; ext j; simpa using (congrFun h (σ j)).symm + · rintro rfl; simp [Function.comp_def] + simp only [he, ite_mul, one_mul, zero_mul] + simp + +def cycleSet (σ : Equiv.Perm J) := Quotient (Equiv.Perm.SameCycle.setoid σ) + +instance (σ : Equiv.Perm J) : Fintype (cycleSet σ) := by + unfold cycleSet + exact Fintype.ofFinite _ + +def cycleCount (σ : Equiv.Perm J) : ℕ := Fintype.card (cycleSet σ) + +omit [DecidableEq J] in +lemma constant_on_cycle {R : Type*} (σ : Equiv.Perm J) (f : J → R) + (hf : ∀ j, f (σ j) = f j) {i j : J} (h : σ.SameCycle i j) : f i = f j := by + obtain ⟨n, rfl⟩ := h.exists_nat_pow_eq + clear h + induction n with + | zero => rfl + | succ n ih => simpa only [pow_succ', Equiv.Perm.mul_apply, hf] using ih + +def fixedLabelEquiv (R : Type*) (σ : Equiv.Perm J) : + {f : J → R // ∀ j, f (σ j) = f j} ≃ (cycleSet σ → R) where + toFun f := Quotient.lift f.val (fun _ _ h => constant_on_cycle σ f.val f.property h) + invFun f := ⟨fun j => f (Quotient.mk _ j), fun j => congrArg f (Quotient.sound (by + exact (Equiv.Perm.SameCycle.refl σ j).apply_left))⟩ + left_inv f := by rfl + right_inv f := by ext q; refine Quotient.inductionOn q (fun j => ?_); rfl + +lemma fixedLabel_card (R : Type*) [Fintype R] [DecidableEq R] (σ : Equiv.Perm J) : + Fintype.card {f : J → R // ∀ j, f (σ j) = f j} = + Fintype.card R ^ cycleCount σ := by + classical + rw [Fintype.card_congr (fixedLabelEquiv R σ), Fintype.card_fun, cycleCount] + +lemma rawCycleTrace_single (b : J → I) (hb : Function.Injective b) + (σ τ : Equiv.Perm J) : + rawCycleTrace σ (fun j => Matrix.single (b (τ j)) (b j) (1 : 𝕜)) = + if σ = τ then 1 else 0 := by + classical + unfold rawCycleTrace + rw [tensorMatrices_single, Matrix.trace_mul_single] + simp only [MulOpposite.op_one, one_smul, permutationMatrix] + have he : b = (fun j => b (τ j)) ∘ σ.symm ↔ σ = τ := by + constructor + · intro h + apply Equiv.ext + intro j + apply hb + simpa using congrFun h (σ j) + · rintro rfl + ext j + simp + by_cases h : σ = τ + · subst τ + simp [Function.comp_def] + · rw [ite_eq_right h, ite_eq_right (fun hh => h (he.mp hh))] + +def inflateMatrix {R : Type*} [DecidableEq R] (A : Matrix I I 𝕜) : + Matrix (I × R) (I × R) 𝕜 := + fun a b => if a.2 = b.2 then A a.1 b.1 else 0 + +omit [Fintype I] [DecidableEq I] [DecidableEq J] in +lemma prod_inflateMatrix {R : Type*} [DecidableEq R] + (σ : Equiv.Perm J) (A : J → Matrix I I 𝕜) (a : J → I) (r : J → R) : + (∏ j, inflateMatrix (A j) (a (σ j), r (σ j)) (a j, r j)) = + if ∀ j, r (σ j) = r j then ∏ j, A j (a (σ j)) (a j) else 0 := by + classical + by_cases h : ∀ j, r (σ j) = r j + · simp [inflateMatrix, h] + · obtain ⟨j, hj⟩ := not_forall.mp h + rw [ite_eq_right h] + exact Finset.prod_eq_zero (Finset.mem_univ j) (ite_eq_right hj) + +omit [Fintype I] [DecidableEq I] in +lemma fixedLabel_indicator_sum (R : Type*) [Fintype R] [DecidableEq R] + (σ : Equiv.Perm J) : + (∑ r : J → R, if ∀ j, r (σ j) = r j then (1 : 𝕜) else 0) = + (Fintype.card R : 𝕜) ^ cycleCount σ := by + classical + calc + _ = (Fintype.card {r : J → R // ∀ j, r (σ j) = r j} : 𝕜) := by + rw [Fintype.card_subtype] + exact Finset.sum_boole _ _ + _ = _ := by rw [fixedLabel_card, Nat.cast_pow] + +lemma rawCycleTrace_inflate (R : Type*) [Fintype R] [DecidableEq R] + (σ : Equiv.Perm J) (A : J → Matrix I I 𝕜) : + rawCycleTrace σ (fun j => inflateMatrix (R := R) (A j)) = + (Fintype.card R : 𝕜) ^ cycleCount σ * rawCycleTrace σ A := by + classical + rw [rawCycleTrace_eq_sum, rawCycleTrace_eq_sum] + calc + _ = ∑ ar : (J → I) × (J → R), + ∏ j, inflateMatrix (A j) (ar.1 (σ j), ar.2 (σ j)) (ar.1 j, ar.2 j) := by + apply Fintype.sum_equiv (Equiv.arrowProdEquivProdArrow J (fun _ => I) (fun _ => R)) + intro x + rfl + _ = ∑ a : J → I, ∑ r : J → R, + ∏ j, inflateMatrix (A j) (a (σ j), r (σ j)) (a j, r j) := + Fintype.sum_prod_type _ + _ = ∑ a : J → I, ∑ r : J → R, + (if ∀ j, r (σ j) = r j then (1 : 𝕜) else 0) * + ∏ j, A j (a (σ j)) (a j) := by + apply Finset.sum_congr rfl + intro a _ + apply Finset.sum_congr rfl + intro r _ + rw [prod_inflateMatrix] + split_ifs <;> simp + _ = _ := by + simp_rw [← Finset.sum_mul, fixedLabel_indicator_sum] + rw [Finset.mul_sum] + +def cycleTrace (σ : Equiv.Perm J) (A : J → Matrix I I ℂ) : ℂ := + (Fintype.card I : ℂ)⁻¹ ^ cycleCount σ * rawCycleTrace σ A + +lemma cycleTrace_inflate (R : Type*) [Fintype R] [DecidableEq R] [Nonempty R] + (σ : Equiv.Perm J) (A : J → Matrix I I ℂ) : + cycleTrace σ (fun j => inflateMatrix (R := R) (A j)) = cycleTrace σ A := by + classical + have hr : (Fintype.card R : ℂ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + simp only [cycleTrace, Fintype.card_prod, Nat.cast_mul, _root_.mul_inv_rev, mul_pow, + rawCycleTrace_inflate] + have hc : ((Fintype.card R : ℂ)⁻¹ ^ cycleCount σ) * + (Fintype.card R : ℂ) ^ cycleCount σ = 1 := by + rw [← mul_pow, inv_mul_cancel₀ hr, one_pow] + calc + _ = (((Fintype.card R : ℂ)⁻¹ ^ cycleCount σ) * + (Fintype.card R : ℂ) ^ cycleCount σ) * + ((Fintype.card I : ℂ)⁻¹ ^ cycleCount σ * rawCycleTrace σ A) := by ring + _ = _ := by rw [hc, one_mul] + +lemma cycleTrace_single (b : J → I) (hb : Function.Injective b) + (σ τ : Equiv.Perm J) : + cycleTrace σ (fun j => Matrix.single (b (τ j)) (b j) 1) = + if σ = τ then (Fintype.card I : ℂ)⁻¹ ^ cycleCount τ else 0 := by + rw [cycleTrace, rawCycleTrace_single b hb] + split_ifs with h + · subst τ; rw [mul_one] + · rw [mul_zero] + +lemma cycleTrace_coefficients_unique [Nonempty I] (b : J → I) + (hb : Function.Injective b) (c d : Equiv.Perm J → ℂ) + (h : ∀ A : J → Matrix I I ℂ, ∑ σ, c σ * cycleTrace σ A = + ∑ σ, d σ * cycleTrace σ A) : c = d := by + classical + funext τ + have he := h (fun j => Matrix.single (b (τ j)) (b j) 1) + simp only [cycleTrace_single b hb, mul_ite, mul_zero] at he + simp only [Finset.sum_ite_eq', Finset.mem_univ, ite_true] at he + apply mul_right_cancel₀ _ he + exact pow_ne_zero _ (inv_ne_zero (by exact_mod_cast Fintype.card_ne_zero)) + +lemma stable_cycle_coefficients [Nonempty I] (R : Type*) [Fintype R] + [DecidableEq R] [Nonempty R] (b : J → I) (hb : Function.Injective b) + (c d : Equiv.Perm J → ℂ) + (h : ∀ A : J → Matrix I I ℂ, ∑ σ, c σ * cycleTrace σ A = + ∑ σ, d σ * cycleTrace σ (fun j => inflateMatrix (R := R) (A j))) : c = d := by + apply cycleTrace_coefficients_unique b hb c d + intro A + simpa only [cycleTrace_inflate] using h A + +theorem invariant_multilinear_form_normalized [Nonempty I] (b : J → I) + (hb : Function.Injective b) (F : MultilinearMap ℂ (fun _ : J => Matrix I I ℂ) ℂ) + (hF : ∀ (U : unitary (Matrix I I ℂ)) (A : J → Matrix I I ℂ), + F (fun j => (U : Matrix I I ℂ) * A j * star (U : Matrix I I ℂ)) = F A) : + ∃! c : Equiv.Perm J → ℂ, ∀ A : J → Matrix I I ℂ, + F A = ∑ σ, c σ * cycleTrace σ A := by + classical + obtain ⟨c, hc⟩ := invariant_multilinear_form b hb F hF + let d : Equiv.Perm J → ℂ := fun σ => c σ * (Fintype.card I : ℂ) ^ cycleCount σ + have hi : (Fintype.card I : ℂ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have hd (A : J → Matrix I I ℂ) : F A = ∑ σ, d σ * cycleTrace σ A := by + rw [hc] + apply Finset.sum_congr rfl + intro σ _ + dsimp only [d, cycleTrace, rawCycleTrace] + rw [mul_assoc, ← mul_assoc ((Fintype.card I : ℂ) ^ cycleCount σ), + ← mul_pow, mul_inv_cancel₀ hi, one_pow, one_mul] + refine ⟨d, hd, ?_⟩ + intro e he + exact cycleTrace_coefficients_unique b hb e d (fun A => (he A).symm.trans (hd A)) + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleInvariants2.lean b/lean/OAI/Analysis/Commutator/CycleInvariants2.lean new file mode 100644 index 0000000000000000000000000000000000000000..392164567f623af32c7b1eb650391ba5582b7b3d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleInvariants2.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +variable {J : Type*} [Fintype J] + +instance (σ : Equiv.Perm J) : DecidableEq (cycleSet σ) := Classical.decEq _ + +def cycleMap (σ : Equiv.Perm J) (j : J) : cycleSet σ := Quotient.mk _ j + +omit [Fintype J] in +@[simp] lemma cycleMap_apply (σ : Equiv.Perm J) (j : J) : + cycleMap σ (σ j) = cycleMap σ j := + Quotient.sound (Equiv.Perm.SameCycle.refl σ j).apply_left + +def cycleCard (σ : Equiv.Perm J) (q : cycleSet σ) : ℕ := + Fintype.card {j : J // cycleMap σ j = q} + +lemma sum_cycleCard (σ : Equiv.Perm J) : + ∑ q, cycleCard σ q = Fintype.card J := by + classical + simp only [cycleCard] + rw [← Fintype.card_sigma] + exact Fintype.card_congr (Equiv.sigmaFiberEquiv (cycleMap σ)) + +lemma cycleCard_pos (σ : Equiv.Perm J) (q : cycleSet σ) : 0 < cycleCard σ q := by + let j : J := Quotient.out q + have hj : cycleMap σ j = q := Quotient.out_eq q + let : Nonempty {j : J // cycleMap σ j = q} := ⟨⟨j, hj⟩⟩ + exact Fintype.card_pos + +lemma two_le_cycleCard (σ : Equiv.Perm J) (j : J) (hj : σ j ≠ j) : + 2 ≤ cycleCard σ (cycleMap σ j) := by + unfold cycleCard + apply Fintype.one_lt_card_iff.mpr + exact ⟨⟨σ j, cycleMap_apply σ j⟩, ⟨j, rfl⟩, fun h => hj (congrArg Subtype.val h)⟩ + +lemma three_le_cycleCard (σ : Equiv.Perm J) (j : J) (hj : σ (σ j) ≠ j) : + 3 ≤ cycleCard σ (cycleMap σ j) := by + have h : σ j ≠ j := by intro e; apply hj; rw [e, e] + unfold cycleCard + apply Fintype.two_lt_card_iff.mpr + refine ⟨⟨j, rfl⟩, ⟨σ j, cycleMap_apply σ j⟩, + ⟨σ (σ j), by simp⟩, ?_, ?_, ?_⟩ + · exact fun e => h (congrArg Subtype.val e).symm + · exact fun e => hj (congrArg Subtype.val e).symm + · exact fun e => h (σ.injective (congrArg Subtype.val e)).symm + +omit [Fintype J] in +lemma cycleMap_eq_fixed (σ : Equiv.Perm J) {a j : J} (ha : σ a = a) + (hj : cycleMap σ j = cycleMap σ a) : j = a := + ((Quotient.exact hj).symm.eq_of_left ha).symm + +lemma minimal_cycle_sum (σ : Equiv.Perm J) (a : J) : + (∑ q : cycleSet σ, if q = cycleMap σ a then 1 else 2) + 1 = + 2 * cycleCount σ := by + classical + calc + _ = (∑ q : cycleSet σ, if q = cycleMap σ a then 1 else 2) + + ∑ q : cycleSet σ, if q = cycleMap σ a then 1 else 0 := by simp + _ = ∑ q : cycleSet σ, ((if q = cycleMap σ a then 1 else 2) + + if q = cycleMap σ a then 1 else 0) := by rw [Finset.sum_add_distrib] + _ = ∑ _q : cycleSet σ, 2 := by + apply Finset.sum_congr rfl + intro q _ + split_ifs <;> rfl + _ = _ := by simp [cycleCount, mul_comm] + +lemma minimal_cycle_bound (σ : Equiv.Perm J) (a : J) + (h : ∀ j, σ j = j → j = a) (q : cycleSet σ) : + (if q = cycleMap σ a then 1 else 2) ≤ cycleCard σ q := by + classical + by_cases hq : q = cycleMap σ a + · rw [ite_eq_left hq]; exact cycleCard_pos σ q + · rw [ite_eq_right hq] + have hj : cycleMap σ (Quotient.out q) = q := Quotient.out_eq q + rw [← hj] + apply two_le_cycleCard + intro hfix + exact hq (hj.symm.trans (congrArg (cycleMap σ) (h _ hfix))) + +theorem endpoint_cycle_classification (σ : Equiv.Perm J) (a : J) + (h : ∀ j, σ j = j → j = a) + (hc : Fintype.card J + 1 ≤ 2 * cycleCount σ) : + σ a = a ∧ ∀ j, σ (σ j) = j := by + classical + have ha : σ a = a := by + by_contra hn + have hall : ∀ j, σ j ≠ j := fun j hj => hn (by simpa [h j hj] using hj) + have hbound (q : cycleSet σ) : 2 ≤ cycleCard σ q := by + have hq : cycleMap σ (Quotient.out q) = q := Quotient.out_eq q + rw [← hq] + exact two_le_cycleCard σ _ (hall _) + have hs := Finset.sum_le_sum (fun q (_ : q ∈ Finset.univ) => hbound q) + simp only [Finset.sum_const, Finset.card_univ, smul_eq_mul, sum_cycleCard] at hs + change cycleCount σ * 2 ≤ Fintype.card J at hs + omega + refine ⟨ha, fun j => ?_⟩ + by_contra hj + have hne : cycleMap σ j ≠ cycleMap σ a := by + intro he + have heq := cycleMap_eq_fixed σ ha he + subst j + exact hj (by rw [ha, ha]) + have hstrict : (∑ q : cycleSet σ, if q = cycleMap σ a then 1 else 2) < + ∑ q : cycleSet σ, cycleCard σ q := by + apply Finset.sum_lt_sum + · exact fun q _ => minimal_cycle_bound σ a h q + · refine ⟨cycleMap σ j, Finset.mem_univ _, ?_⟩ + rw [ite_eq_right hne] + exact three_le_cycleCard σ j hj + rw [sum_cycleCard] at hstrict + have hs := minimal_cycle_sum σ a + omega + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CycleInvariants3.lean b/lean/OAI/Analysis/Commutator/CycleInvariants3.lean new file mode 100644 index 0000000000000000000000000000000000000000..2db116a339644217785b77379d112a833da76fa7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CycleInvariants3.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +variable {𝕜 I J : Type*} [CommRing 𝕜] [Fintype I] [Fintype J] + [DecidableEq I] [DecidableEq J] + +theorem rawCycleTrace_zero_of_fixed_centered (σ : Equiv.Perm J) + (A : J → Matrix I I 𝕜) (j : J) (hj : σ j = j) + (htrace : Matrix.trace (A j) = 0) : rawCycleTrace σ A = 0 := by + classical + have hne (r : {r : J // r ≠ j}) : σ r.1 ≠ j := by + intro he + exact r.2 (σ.injective (he.trans hj.symm)) + let C (b : {r : J // r ≠ j} → I) : 𝕜 := + ∏ r : {r : J // r ≠ j}, A r.1 (b ⟨σ r.1, hne r⟩) (b r) + have hprod (b : {r : J // r ≠ j} → I) (i : I) : + (∏ r, A r ((Equiv.funSplitAt j I).symm (i, b) (σ r)) + ((Equiv.funSplitAt j I).symm (i, b) r)) = A j i i * C b := by + rw [Fintype.prod_eq_mul_prod_subtype_ne _ j] + simp only [hj, Equiv.funSplitAt_symm_apply] + congr 1 + apply Finset.prod_congr rfl + intro r _ + simp [hne r, r.2] + rw [rawCycleTrace_eq_sum] + calc + _ = ∑ bi : I × ({r : J // r ≠ j} → I), + ∏ r, A r ((Equiv.funSplitAt j I).symm bi (σ r)) + ((Equiv.funSplitAt j I).symm bi r) := by + exact Fintype.sum_equiv (Equiv.funSplitAt j I) _ _ + (fun _ => by simp only [Equiv.symm_apply_apply]) + _ = ∑ b : {r : J // r ≠ j} → I, ∑ i : I, A j i i * C b := by + rw [Fintype.sum_prod_type, Finset.sum_comm] + apply Finset.sum_congr rfl + intro b _ + exact Finset.sum_congr rfl (fun i _ => hprod b i) + _ = 0 := by + apply Finset.sum_eq_zero + intro b _ + rw [← Finset.sum_mul] + change Matrix.trace (A j) * C b = 0 + rw [htrace, zero_mul] + +theorem cycleTrace_zero_of_fixed_centered (σ : Equiv.Perm J) + (A : J → Matrix I I ℂ) (j : J) (hj : σ j = j) + (htrace : Matrix.trace (A j) = 0) : cycleTrace σ A = 0 := by + rw [cycleTrace, rawCycleTrace_zero_of_fixed_centered σ A j hj htrace, mul_zero] + +theorem centered_expansion_pairings (a : J) (d : Equiv.Perm J → ℂ) + (hd : ∀ σ, 2 * cycleCount σ < Fintype.card J + 1 → d σ = 0) + (A : J → Matrix I I ℂ) (hA : ∀ j, j ≠ a → Matrix.trace (A j) = 0) : + (∑ σ, d σ * cycleTrace σ A) = + ∑ σ ∈ Finset.univ.filter (fun σ : Equiv.Perm J => + σ a = a ∧ (∀ j, σ (σ j) = j) ∧ ∀ j, σ j = j → j = a), + d σ * cycleTrace σ A := by + classical + symm + apply Finset.sum_subset (Finset.filter_subset _ _) + intro σ _ hn + simp only [Finset.mem_filter, Finset.mem_univ, true_and] at hn + by_cases he : 2 * cycleCount σ < Fintype.card J + 1 + · rw [hd σ he, zero_mul] + by_cases hf : ∀ j, σ j = j → j = a + · obtain ⟨ha, hi⟩ := endpoint_cycle_classification σ a hf (Nat.le_of_not_gt he) + exact (hn ⟨ha, hi, hf⟩).elim + · obtain ⟨j, hj, hja⟩ := by simpa only [not_forall, Classical.not_imp] using hf + rw [cycleTrace_zero_of_fixed_centered σ A j hj (hA j hja), mul_zero] + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclePairTrace.lean b/lean/OAI/Analysis/Commutator/CyclePairTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..357316f75cf5e942b39d025083bf3ec29b59a79c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclePairTrace.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants2 +import OAI.Analysis.Commutator.PairTrace +import OAI.Analysis.Commutator.PairTrace2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.SchurWeyl + +variable {J I : Type*} [Fintype J] [LinearOrder J] [Fintype I] [DecidableEq I] + +def pairingCycleEquiv (σ : Pairing J) : cycleSet σ.val ≃ Pairing.Representatives σ where + toFun := Quotient.lift (fun j => ⟨Pairing.repr σ j, Pairing.repr_lt_apply σ j⟩) + (fun _ _ h => Subtype.ext (constant_on_cycle σ.val (Pairing.repr σ) + (Pairing.repr_apply σ) h)) + invFun r := cycleMap σ.val r + left_inv q := by + refine Quotient.inductionOn q (fun j => ?_) + change cycleMap σ.val (Pairing.repr σ j) = cycleMap σ.val j + rcases le_total j (σ j) with h | h + · rw [Pairing.repr, min_eq_left h] + · rw [Pairing.repr, min_eq_right h] + exact cycleMap_apply σ.val j + right_inv r := by + apply Subtype.ext + exact Pairing.repr_representative σ r + +lemma cycleCount_pairing (σ : Pairing J) : + cycleCount σ.val = Fintype.card (Pairing.Representatives σ) := + Fintype.card_congr (pairingCycleEquiv σ) + +theorem rawCycleTrace_pairing {𝕜 : Type*} [CommRing 𝕜] + (σ : Pairing J) (A : J → Matrix I I 𝕜) : + rawCycleTrace σ.val A = + ∏ r : Pairing.Representatives σ, Matrix.trace (A r * A (σ r)) := by + rw [rawCycleTrace_eq_sum] + rw [Pairing.sum_prod_pairs σ A] + apply Finset.prod_congr rfl + intro r _ + simp only [Matrix.trace, Matrix.diag_apply, Matrix.mul_apply] + rw [Finset.sum_comm] + +theorem cycleTrace_pairing (σ : Pairing J) (A : J → Matrix I I ℂ) : + cycleTrace σ.val A = + ∏ r : Pairing.Representatives σ, + (Fintype.card I : ℂ)⁻¹ * Matrix.trace (A r * A (σ r)) := by + rw [cycleTrace, cycleCount_pairing, rawCycleTrace_pairing, Finset.prod_mul_distrib] + simp only [Finset.prod_const, Finset.card_univ] + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclePairTrace2.lean b/lean/OAI/Analysis/Commutator/CyclePairTrace2.lean new file mode 100644 index 0000000000000000000000000000000000000000..79a800f96382c70b30b6e70cf5c54282a24947e2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclePairTrace2.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclePairTrace + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.SchurWeyl + +variable {J I : Type*} [Fintype J] [LinearOrder J] [Fintype I] [DecidableEq I] + +def endpointPairingPerm (σ : Pairing J) : Equiv.Perm (Option J) := Equiv.optionCongr σ.val + +omit [Fintype J] [LinearOrder J] in +@[simp] lemma endpointPairingPerm_none (σ : Pairing J) : endpointPairingPerm σ none = none := rfl + +omit [Fintype J] [LinearOrder J] in +@[simp] lemma endpointPairingPerm_some (σ : Pairing J) (j : J) : + endpointPairingPerm σ (some j) = some (σ j) := rfl + +def optionPairRepresentative (σ : Pairing J) : Option J → Option (Pairing.Representatives σ) + | none => none + | some j => some ⟨Pairing.repr σ j, Pairing.repr_lt_apply σ j⟩ + +omit [Fintype J] in +lemma optionPairRepresentative_apply (σ : Pairing J) (j : Option J) : + optionPairRepresentative σ (endpointPairingPerm σ j) = optionPairRepresentative σ j := by + cases j with + | none => rfl + | some j => simp only [endpointPairingPerm_some, optionPairRepresentative, + Pairing.repr_apply] + +def endpointPairingCycleEquiv (σ : Pairing J) : + cycleSet (endpointPairingPerm σ) ≃ Option (Pairing.Representatives σ) where + toFun := Quotient.lift (optionPairRepresentative σ) + (fun _ _ h => constant_on_cycle (endpointPairingPerm σ) + (optionPairRepresentative σ) (optionPairRepresentative_apply σ) h) + invFun + | none => cycleMap (endpointPairingPerm σ) none + | some r => cycleMap (endpointPairingPerm σ) (some r.1) + left_inv q := by + refine Quotient.inductionOn q (fun j => ?_) + cases j with + | none => rfl + | some j => + change cycleMap (endpointPairingPerm σ) (some (Pairing.repr σ j)) = + cycleMap (endpointPairingPerm σ) (some j) + rcases le_total j (σ j) with h | h + · rw [Pairing.repr, min_eq_left h] + · rw [Pairing.repr, min_eq_right h] + exact cycleMap_apply (endpointPairingPerm σ) (some j) + right_inv r := by + cases r with + | none => rfl + | some r => + change some (⟨Pairing.repr σ r, _⟩ : Pairing.Representatives σ) = some r + congr 1 + apply Subtype.ext + exact Pairing.repr_representative σ r + +lemma cycleCount_endpointPairing (σ : Pairing J) : + cycleCount (endpointPairingPerm σ) = Fintype.card (Pairing.Representatives σ) + 1 := by + have hh := Fintype.card_congr (endpointPairingCycleEquiv σ) + simpa only [cycleCount, Fintype.card_option] using hh + +theorem rawCycleTrace_option {𝕜 : Type*} [CommRing 𝕜] + (σ : Equiv.Perm J) (A : Option J → Matrix I I 𝕜) : + rawCycleTrace (Equiv.optionCongr σ) A = + Matrix.trace (A none) * rawCycleTrace σ (fun j => A (some j)) := by + classical + rw [rawCycleTrace_eq_sum, rawCycleTrace_eq_sum] + simp only [Fintype.prod_option, Equiv.optionCongr_apply, Option.map_none, Option.map_some] + calc + _ = ∑ b : I × (J → I), A none b.1 b.1 * ∏ j, A (some j) (b.2 (σ j)) (b.2 j) := by + exact Fintype.sum_equiv Equiv.piOptionEquivProd _ _ (fun _ => rfl) + _ = _ := by + rw [Fintype.sum_prod_type] + simp_rw [← Finset.mul_sum] + rw [← Finset.sum_mul] + rfl + +theorem cycleTrace_endpointPairing (σ : Pairing J) (A : Option J → Matrix I I ℂ) : + cycleTrace (endpointPairingPerm σ) A = + (Fintype.card I : ℂ)⁻¹ * Matrix.trace (A none) * + Pairing.contraction σ (fun X Y => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Y)) + (fun j => A (some j)) := by + classical + rw [cycleTrace, cycleCount_endpointPairing] + change (Fintype.card I : ℂ)⁻¹ ^ (Fintype.card (Pairing.Representatives σ) + 1) * + rawCycleTrace (Equiv.optionCongr σ.val) A = _ + rw [rawCycleTrace_option, rawCycleTrace_pairing, pow_succ] + have hc : Pairing.contraction σ + (fun (X Y : Matrix I I ℂ) => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Y)) + (fun j => A (some j)) = + (Fintype.card I : ℂ)⁻¹ ^ Fintype.card (Pairing.Representatives σ) * + ∏ r : Pairing.Representatives σ, Matrix.trace (A (some r.1) * A (some (σ r))) := by + unfold Pairing.contraction + rw [Finset.prod_subtype (p := fun j => j < σ j) (F := inferInstance) _ (by simp)] + rw [Finset.prod_mul_distrib] + simp only [Finset.prod_const, Finset.card_univ] + rw [hc] + ring + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclePairTrace3.lean b/lean/OAI/Analysis/Commutator/CyclePairTrace3.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0b64c5f4a2ce5ac0d4991750fd789c22b304c19 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclePairTrace3.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants3 +import OAI.Analysis.Commutator.CyclePairTrace2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.SchurWeyl + +variable {J : Type*} + +def IsEndpointPairing (σ : Equiv.Perm (Option J)) : Prop := + σ none = none ∧ (∀ j, σ (σ j) = j) ∧ ∀ j, σ j = j → j = none + +lemma some_removeNone_of_fixed (σ : Equiv.Perm (Option J)) (hσ : σ none = none) (j : J) : + some (σ.removeNone j) = σ (some j) := by + apply Equiv.removeNone_some + cases he : σ (some j) with + | none => + have hh := σ.injective (he.trans hσ.symm) + cases hh + | some k => exact ⟨k, rfl⟩ + +def pairingOfEndpointPerm (σ : Equiv.Perm (Option J)) (hσ : IsEndpointPairing σ) : Pairing J := + ⟨σ.removeNone, (by + constructor + · intro j + apply Option.some_injective + rw [some_removeNone_of_fixed σ hσ.1, some_removeNone_of_fixed σ hσ.1] + exact hσ.2.1 (some j) + · intro j hj + have hh : σ (some j) = some j := by + rw [← some_removeNone_of_fixed σ hσ.1, hj] + exact Option.some_ne_none j (hσ.2.2 (some j) hh))⟩ + +def endpointPairingEquiv : Pairing J ≃ {σ : Equiv.Perm (Option J) // IsEndpointPairing σ} where + toFun τ := ⟨endpointPairingPerm τ, (by + refine ⟨rfl, ?_, ?_⟩ + · intro j + cases j with + | none => rfl + | some j => simp only [endpointPairingPerm_some, Pairing.apply_apply] + · intro j hj + cases j with + | none => rfl + | some j => + have hh : τ j = j := Option.some.inj hj + exact (τ.apply_ne j hh).elim)⟩ + invFun σ := pairingOfEndpointPerm σ.1 σ.2 + left_inv τ := by + apply Subtype.ext + exact Equiv.removeNone_optionCongr τ.val + right_inv σ := by + apply Subtype.ext + apply Equiv.ext + intro j + cases j with + | none => exact σ.2.1.symm + | some j => exact some_removeNone_of_fixed σ.1 σ.2.1 j + +variable [Fintype J] [LinearOrder J] + +variable {I : Type*} [Fintype I] [DecidableEq I] + +theorem centered_expansion_contractions (d : Equiv.Perm (Option J) → ℂ) + (hd : ∀ σ, 2 * cycleCount σ < Fintype.card (Option J) + 1 → d σ = 0) + (A : Option J → Matrix I I ℂ) (hA : ∀ j, Matrix.trace (A (some j)) = 0) : + (∑ σ, d σ * cycleTrace σ A) = + ((Fintype.card I : ℂ)⁻¹ * Matrix.trace (A none)) * + ∑ τ : Pairing J, d (endpointPairingPerm τ) * + Pairing.contraction τ + (fun X Y => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Y)) + (fun j => A (some j)) := by + classical + rw [centered_expansion_pairings none d hd A (by + intro j hj + cases j with + | none => exact (hj rfl).elim + | some j => exact hA j)] + have hfilter : (Finset.univ.filter (fun σ : Equiv.Perm (Option J) => + σ none = none ∧ (∀ j, σ (σ j) = j) ∧ ∀ j, σ j = j → j = none)) = + Finset.univ.filter IsEndpointPairing := by + ext σ + simp only [Finset.mem_filter, Finset.mem_univ, true_and, IsEndpointPairing] + rw [hfilter] + rw [Finset.sum_subtype (p := IsEndpointPairing) (F := inferInstance) _ (by simp)] + rw [← endpointPairingEquiv.sum_comp (fun σ => d σ.1 * cycleTrace σ.1 A)] + change (∑ τ : Pairing J, d (endpointPairingPerm τ) * + cycleTrace (endpointPairingPerm τ) A) = _ + simp_rw [cycleTrace_endpointPairing] + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro τ _ + ring + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicCb.lean b/lean/OAI/Analysis/Commutator/CyclicCb.lean new file mode 100644 index 0000000000000000000000000000000000000000..1f8e836fe68887e9729adcb7ea83f58faaccccd7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicCb.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicColumnFactorization +import OAI.Analysis.Commutator.CyclicMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A H F ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] [Fintype ι] + +local instance cyclicCbDecidableEq : DecidableEq ι := Classical.decEq ι + +omit [PartialOrder A] [StarOrderedRing A] in +lemma derivation_matrix_column (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (Δ : A →L[ℂ] (H →L[ℂ] F)) + (hΔ : ∀ a b, Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b)) + (X : CStarMatrix ι ι A) (v : ι → A) (ζ : H) : + matrixAction (fun i j => Δ (X i j)) (WithLp.toLp 2 (fun i => σ (v i) ζ)) = + WithLp.toLp 2 (fun i => Δ (∑ j, X i j*v j) ζ)- + matrixAction (fun i j => lam (X i j)) (WithLp.toLp 2 (fun i => Δ (v i) ζ)) := by + ext i + simp only [matrixAction_apply,PiLp.sub_apply,map_sum,hΔ, + sum_apply,add_apply,ContinuousLinearMap.comp_apply] + simp only [Finset.sum_add_distrib,add_sub_cancel_right] + +theorem cyclic_matrix_bound (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (Δ : A →L[ℂ] (H →L[ℂ] F)) + (hΔ : ∀ a b, Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b)) + (Ω : H) (hΩ : DenseRange (fun a : A => σ a Ω)) (c : ℝ) (hc : 0≤c) + (hcol : ∀ (v : ι → A) (ζ : H), + ‖WithLp.toLp 2 (fun i => Δ (v i) ζ)‖ ≤ c*columnNorm v*‖ζ‖) + (X : CStarMatrix ι ι A) : + ‖matrixAction (fun i j => Δ (X i j))‖ ≤ 4*c*‖X‖ := by + let D := matrixAction (fun i j => Δ (X i j)) + have hbound (ζ : H) (v : ι → A) (hζ : ‖ζ‖≤2) (hv : (∑ i,star (v i)*v i)≤1) : + ‖D (WithLp.toLp 2 (fun i => σ (v i) ζ))‖ ≤ 4*c*‖X‖ := by + have hn : columnNorm v≤1 := columnNorm_le_one v hv + have hm : columnNorm (fun i => ∑ j,X i j*v j)≤‖X‖ := by + exact (columnNorm_matmul_le X v).trans (by simpa using mul_le_mul_of_nonneg_left hn (norm_nonneg X)) + have hdv : ‖WithLp.toLp 2 (fun i => Δ (v i) ζ)‖≤2*c := by + calc _ ≤ c*columnNorm v*‖ζ‖ := hcol v ζ + _ ≤ c*1*2 := by gcongr + _ = 2*c := by ring + have hdxv : ‖WithLp.toLp 2 (fun i => Δ (∑ j, X i j*v j) ζ)‖≤2*c*‖X‖ := by + calc _ ≤ c*columnNorm (fun i => ∑ j, X i j*v j)*‖ζ‖ := hcol _ ζ + _ ≤ c*‖X‖*2 := by gcongr + _ = 2*c*‖X‖ := by ring + have hlam : ‖matrixAction (fun i j => lam (X i j)) + (WithLp.toLp 2 (fun i => Δ (v i) ζ))‖≤2*c*‖X‖ := by + calc _ ≤ ‖matrixRepresentation lam X‖*‖WithLp.toLp 2 (fun i => Δ (v i) ζ)‖ := + ContinuousLinearMap.le_opNorm _ _ + _ ≤ ‖X‖*(2*c) := by gcongr; exact matrixRepresentation_norm_le lam X + _ = 2*c*‖X‖ := by ring + dsimp only [D] + rw [derivation_matrix_column σ lam Δ hΔ] + exact (norm_sub_le _ _).trans (by linarith) + apply ContinuousLinearMap.opNorm_le_of_unit_norm (by positivity) + intro ξ hξ + have hclosed : IsClosed {x : PiLp 2 (fun _ : ι => H) | ‖D x‖≤4*c*‖X‖} := + isClosed_le (D.continuous.norm) continuous_const + apply hclosed.closure_subset + rw [Metric.mem_closure_iff] + intro ε hε + obtain ⟨ζ,v,hζ,hv,ha⟩ := approximate_unit_column σ Ω hΩ ξ hξ ε hε + exact ⟨WithLp.toLp 2 (fun i => σ (v i) ζ),hbound ζ v hζ hv,by rwa [dist_eq_norm]⟩ + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicCbUnconditional.lean b/lean/OAI/Analysis/Commutator/CyclicCbUnconditional.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a0da7635076b4ff9da1b9fa16a71a427a9f38a3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicCbUnconditional.lean @@ -0,0 +1,39 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicCb +import OAI.Analysis.Commutator.RectangularColumn + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A H F ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] [Fintype ι] + +theorem cyclic_matrix_bound_unconditional (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (Δ : A →L[ℂ] (H →L[ℂ] F)) + (hΔ : ∀ a b, Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b)) + (Ω : H) (hΩ : DenseRange (fun a : A => σ a Ω)) + (X : CStarMatrix ι ι A) : + ‖matrixAction (fun i j => Δ (X i j))‖ ≤ (16*‖Δ‖)*‖X‖ := by + have h := cyclic_matrix_bound σ lam Δ hΔ Ω hΩ (4*‖Δ‖) (by positivity) + (fun v ζ => RectangularColumn.column_bound σ lam Δ hΔ v ζ) X + convert h using 1 + ring + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicColumnFactorization.lean b/lean/OAI/Analysis/Commutator/CyclicColumnFactorization.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b56d0e342a3306b09e9c0daa17a21a2e2d2d26f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicColumnFactorization.lean @@ -0,0 +1,135 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A H ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] [Fintype ι] + +theorem regularized_factorization (a : ι → A) (η : ℝ) (hη : 0 < η) : + ∃ (b : A) (v : ι → A), star b=b ∧ + b*b=(∑ i, star (a i)*a i)+η • (1:A) ∧ + (∑ i, star (v i)*v i) ≤ 1 ∧ ∀ i, v i*b=a i := by + let q : A := (∑ i, star (a i)*a i)+η • (1:A) + have hp : IsStrictlyPositive q := + IsStrictlyPositive.nonneg_add (Finset.sum_nonneg (fun i _ => star_mul_self_nonneg (a i))) + (isStrictlyPositive_one.smul hη) + let b : A := CFC.sqrt q + have hb : star b=b := (IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg q)).star_eq + have hbb : b*b=q := CFC.sqrt_mul_sqrt_self q hp.nonneg + have hu : IsUnit b := (CFC.isUnit_sqrt_iff q hp.nonneg).mpr hp.isUnit + let c : A := Ring.inverse b + have hcb : c*b=1 := Ring.inverse_mul_cancel b hu + have hbc : b*c=1 := Ring.mul_inverse_cancel b hu + have hc : star c=c := by dsimp [c]; rw [←Ring.inverse_star,hb] + let v : ι → A := fun i => a i*c + refine ⟨b,v,hb,hbb,?_,?_⟩ + · have hle : (∑ i,star (a i)*a i) ≤ q := + le_add_of_nonneg_right (smul_nonneg hη.le zero_le_one) + have h := star_left_conjugate_le_conjugate hle c + have hright : star c*q*c=1 := by rw [hc,←hbb,←mul_assoc,hcb,one_mul,hbc] + rw [hright] at h + convert h using 1 + dsimp only [v] + simp only [star_mul,Finset.mul_sum,Finset.sum_mul,mul_assoc] + · intro i + dsimp only [v] + rw [mul_assoc,hcb,mul_one] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma norm_image_sq (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (a : A) (Ω : H) : + ‖σ a Ω‖^2 = (inner ℂ Ω (σ (star a*a) Ω)).re := by + rw [map_mul,map_star,mul_apply_eq_comp,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_right] + exact (inner_self_eq_norm_sq (𝕜:=ℂ) (σ a Ω)).symm + +theorem regularized_vector_factorization (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Ω : H) (a : ι → A) (η : ℝ) (hη : 0 < η) : + ∃ (ζ : H) (v : ι → A), (∑ i, star (v i)*v i) ≤ 1 ∧ + (∀ i, σ (v i) ζ=σ (a i) Ω) ∧ + ‖ζ‖^2=(∑ i, ‖σ (a i) Ω‖^2)+η*‖Ω‖^2 := by + obtain ⟨b,v,hb,hbb,hv,hvb⟩ := regularized_factorization a η hη + refine ⟨σ b Ω,v,hv,?_,?_⟩ + · intro i + rw [←mul_apply_eq_comp,←map_mul,hvb] + · rw [norm_image_sq,hb,hbb,map_add,map_sum] + have hsmul : σ (η • (1:A))=η • (1:H →L[ℂ] H) := by + change σ ((η:ℂ) • (1:A))=(η:ℂ) • (1:H →L[ℂ] H) + rw [map_smul,map_one] + rw [hsmul] + simp only [add_apply,sum_apply, + smul_apply,one_apply_eq_self,inner_add_right, + inner_sum,Complex.add_re,Complex.re_sum] + congr 1 + · apply Finset.sum_congr rfl + intro i _ + exact (norm_image_sq σ (a i) Ω).symm + · change (inner ℂ Ω ((η:ℂ) • Ω)).re=η*‖Ω‖^2 + rw [inner_smul_right,Complex.mul_re,Complex.ofReal_re,Complex.ofReal_im] + simp only [zero_mul,sub_zero] + congr 1 + exact inner_self_eq_norm_sq (𝕜:=ℂ) Ω + +theorem bounded_vector_factorization (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Ω : H) (a : ι → A) (ha : (∑ i, ‖σ (a i) Ω‖^2) ≤ 2) : + ∃ (ζ : H) (v : ι → A), ‖ζ‖ ≤ 2 ∧ (∑ i, star (v i)*v i) ≤ 1 ∧ + ∀ i, σ (v i) ζ=σ (a i) Ω := by + let η : ℝ := 1/(‖Ω‖^2+1) + have ht : 0 < ‖Ω‖^2+1 := by positivity + have hη : 0 < η := one_div_pos.mpr ht + obtain ⟨ζ,v,hv,hva,hζ⟩ := regularized_vector_factorization σ Ω a η hη + have hr : η*‖Ω‖^2 ≤ 1 := by + dsimp only [η] + rw [one_div_mul_eq_div] + exact (div_le_one ht).mpr (by linarith) + refine ⟨ζ,v,?_,hv,hva⟩ + have hn := norm_nonneg ζ + nlinarith + +omit [PartialOrder A] [StarOrderedRing A] [Fintype ι] in +lemma denseRange_cyclic_columns (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Ω : H) (hΩ : DenseRange (fun a : A => σ a Ω)) : + DenseRange (fun a : ι → A => WithLp.toLp 2 (fun i => σ (a i) Ω)) := by + have hpi : DenseRange (Pi.map (fun (_ : ι) (a : A) => σ a Ω)) := + DenseRange.piMap (fun _ => hΩ) + exact (PiLp.homeomorph 2 (fun _ : ι => H)).symm.surjective.denseRange.comp hpi + (PiLp.homeomorph 2 (fun _ : ι => H)).symm.continuous + +theorem approximate_unit_column (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Ω : H) (hΩ : DenseRange (fun a : A => σ a Ω)) + (ξ : PiLp 2 (fun _ : ι => H)) (hξ : ‖ξ‖=1) (ε : ℝ) (hε : 0<ε) : + ∃ (ζ : H) (v : ι → A), ‖ζ‖ ≤ 2 ∧ (∑ i, star (v i)*v i) ≤ 1 ∧ + ‖ξ-WithLp.toLp 2 (fun i => σ (v i) ζ)‖ < ε := by + obtain ⟨a,ha⟩ := Metric.denseRange_iff.mp (denseRange_cyclic_columns σ Ω hΩ) + ξ (min ε (1/4)) (lt_min hε (by norm_num)) + rw [dist_eq_norm] at ha + have hnorm : ‖WithLp.toLp 2 (fun i => σ (a i) Ω)‖ < 5/4 := by + have hh := norm_le_norm_add_norm_sub ξ (WithLp.toLp 2 (fun i => σ (a i) Ω)) + rw [hξ] at hh + have ht := lt_of_lt_of_le ha (min_le_right ε (1/4)) + linarith + have hb : (∑ i, ‖σ (a i) Ω‖^2) ≤ 2 := by + rw [←PiLp.norm_sq_eq_of_L2 (fun _ : ι => H) (WithLp.toLp 2 (fun i => σ (a i) Ω))] + have hn := norm_nonneg (WithLp.toLp 2 (fun i => σ (a i) Ω)) + nlinarith + obtain ⟨ζ,v,hζ,hv,heq⟩ := bounded_vector_factorization σ Ω a hb + refine ⟨ζ,v,hζ,hv,?_⟩ + simpa only [heq] using lt_of_lt_of_le ha (min_le_left ε (1/4)) + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicCorner.lean b/lean/OAI/Analysis/Commutator/CyclicCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..4a0dd761a61fadfb1e3adfa1f48fab4609c7c8fb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicCorner.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace Topology + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def cornerOrbit (S : StarSubalgebra ℂ (H →L[ℂ] H)) + (p : H →L[ℂ] H) (ξ : H) : Submodule ℂ H where + carrier := {x | ∃ a : H →L[ℂ] H, a ∈ S ∧ p*a=a ∧ a*p=a ∧ a ξ=x} + zero_mem' := ⟨0,S.zero_mem,by simp,by simp,by simp⟩ + add_mem' := by + rintro x y ⟨a,ha,hpa,hap,rfl⟩ ⟨b,hb,hpb,hbp,rfl⟩ + exact ⟨a+b,S.add_mem ha hb,by rw [mul_add,hpa,hpb],by rw [add_mul,hap,hbp],rfl⟩ + smul_mem' := by + rintro c x ⟨a,ha,hpa,hap,rfl⟩ + exact ⟨c • a,S.smul_mem ha c,by rw [mul_smul_comm,hpa],by rw [smul_mul_assoc,hap],rfl⟩ + +theorem mem_cornerOrbit_closure_iff (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {p : H →L[ℂ] H} (hp : p*p=p) (hpS : p∈S) {ξ : H} (hξ : p ξ=ξ) (x : H) : + x∈(cornerOrbit S p ξ).topologicalClosure ↔ x∈cyclicSubspace S ξ ∧ p x=x := by + constructor + · intro hx + have hsub : (cornerOrbit S p ξ).topologicalClosure ≤ cyclicSubspace S ξ := by + apply Submodule.topologicalClosure_minimal + · rintro y ⟨a,ha,_,_,rfl⟩ + exact (orbitSubmodule S ξ).le_topologicalClosure ⟨a,ha,rfl⟩ + · exact (orbitSubmodule S ξ).isClosed_topologicalClosure + refine ⟨hsub hx, ?_⟩ + apply closure_minimal (t := {y | p y=y}) ?_ (isClosed_eq p.continuous continuous_id) hx + rintro y ⟨a,_,hpa,_,rfl⟩ + exact congrArg (fun T : H →L[ℂ] H => T ξ) hpa + · rintro ⟨hx,hpx⟩ + have hclosed := (cornerOrbit S p ξ).isClosed_topologicalClosure.preimage p.continuous + have hmem : p x∈(cornerOrbit S p ξ).topologicalClosure := by + apply closure_minimal (t := {y | p y∈(cornerOrbit S p ξ).topologicalClosure}) ?_ hclosed hx + rintro y ⟨a,ha,rfl⟩ + apply (cornerOrbit S p ξ).le_topologicalClosure + refine ⟨p*a*p,S.mul_mem (S.mul_mem hpS ha) hpS,?_,?_,?_⟩ + · rw [←mul_assoc,←mul_assoc,hp] + · rw [mul_assoc (p*a),hp] + · change p (a (p ξ))=p (a ξ) + rw [hξ] + rwa [hpx] at hmem + +lemma cyclicSubspace_reduces (S : StarSubalgebra ℂ (H →L[ℂ] H)) (ξ : H) + {a : H →L[ℂ] H} (ha : a∈S) : + (cyclicSubspace S ξ).starProjection*a=a*(cyclicSubspace S ξ).starProjection := + projection_commutes_of_invariant _ a (cyclicSubspace_invariant S ξ ha) + (cyclicSubspace_invariant S ξ (star_mem ha)) + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicCornerRepresentation.lean b/lean/OAI/Analysis/Commutator/CyclicCornerRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..4d42f7a7816a2d2e432e56e23deadf7398a27c4e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicCornerRepresentation.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicCorner +import OAI.Analysis.Commutator.ReducingRepresentation + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace Topology + +open ContinuousLinearMap + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (S : StarSubalgebra ℂ (H →L[ℂ] H)) [IsClosed (S : Set (H →L[ℂ] H))] (ξ : H) + +def cyclicRepresentation : S →⋆ₐ[ℂ] (cyclicSubspace S ξ →L[ℂ] cyclicSubspace S ξ) := + ReducingRepresentation.restrict (A := S) S.subtype (cyclicSubspace S ξ) + (fun a : S => cyclicSubspace_invariant S ξ a.property) + +@[simp] lemma cyclicRepresentation_apply (a : S) (x : cyclicSubspace S ξ) : + (cyclicRepresentation S ξ a x:H)=(a:H →L[ℂ] H) x := rfl + +def cyclicCornerVector (p : S) (hξ : (p:H →L[ℂ] H) ξ=ξ) : + MatrixCornerHilbert.fixedSpace (cyclicRepresentation S ξ p) := + ⟨⟨ξ,mem_cyclicSubspace_self S ξ⟩,(MatrixCornerHilbert.mem_fixedSpace _ _).mpr (Subtype.ext hξ)⟩ + +theorem cyclicCornerVector_cyclic (p : S) (hp : IsStarProjection p) + (hξ : (p:H →L[ℂ] H) ξ=ξ) : + DenseRange (fun a : Corner hp => ReducingRepresentation.corner (cyclicRepresentation S ξ) hp a + (cyclicCornerVector S ξ p hξ)) := by + let K := cyclicSubspace S ξ + let E := MatrixCornerHilbert.fixedSpace (cyclicRepresentation S ξ p) + let m : E → H := fun x => ((x:K):H) + let act : Corner hp → E := fun a => ReducingRepresentation.corner (cyclicRepresentation S ξ) hp a + (cyclicCornerVector S ξ p hξ) + have hm : Topology.IsEmbedding m := + Topology.IsEmbedding.subtypeVal.comp Topology.IsEmbedding.subtypeVal + have himage : m '' Set.range act = (cornerOrbit S (p:H →L[ℂ] H) ξ : Set H) := by + ext x + constructor + · rintro ⟨_,⟨a,rfl⟩,rfl⟩ + exact ⟨((a:S):H →L[ℂ] H),(a:S).property, + congrArg (fun b : S => (b:H →L[ℂ] H)) a.property.1, + congrArg (fun b : S => (b:H →L[ℂ] H)) a.property.2,rfl⟩ + · rintro ⟨a,ha,hpa,hap,rfl⟩ + let ac : Corner hp := ⟨⟨a,ha⟩,Subtype.ext hpa,Subtype.ext hap⟩ + exact ⟨act ac,⟨ac,rfl⟩,rfl⟩ + intro x + change x∈closure (Set.range act) + rw [hm.closure_eq_preimage_closure_image,himage] + change m x∈(cornerOrbit S (p:H →L[ℂ] H) ξ).topologicalClosure + apply (mem_cornerOrbit_closure_iff S + (congrArg (fun b : S => (b:H →L[ℂ] H)) hp.isIdempotentElem.eq) p.property hξ (m x)).mpr + exact ⟨(x:K).property,congrArg (fun y : K => (y:H)) + (MatrixCornerHilbert.fixed_apply (cyclicRepresentation S ξ p) x)⟩ + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicDecomposition.lean b/lean/OAI/Analysis/Commutator/CyclicDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f5ac791bb15dad97c199f1d22a6ee17cd7c675e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicDecomposition.lean @@ -0,0 +1,185 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.OrthogonalLinkSums + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +open Filter + +universe u + +namespace Kadison.CyclicDecomposition + +open PartialIsometryOrder + +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (A : StarSubalgebra ℂ (H →L[ℂ] H)) + +def full : VonNeumannAlgebra H where + toStarSubalgebra := ⊤ + centralizer_centralizer' := by + apply Set.eq_univ_of_univ_subset + exact (Set.subset_centralizer_centralizer (S := (Set.univ : Set (H →L[ℂ] H)))) + +abbrev ProjLink := Link (full (H:=H)) 1 1 + +def cyclicLink (ξ : H) : ProjLink (H:=H) where + val := (cyclicSubspace A ξ).starProjection + mem := by trivial + triple := by + have hp : IsStarProjection (cyclicSubspace A ξ).starProjection := isStarProjection_starProjection + rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq,hp.isIdempotentElem.eq] + source_le := by + have hp : IsStarProjection (cyclicSubspace A ξ).starProjection := isStarProjection_starProjection + rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + exact hp.le_one + target_le := by + have hp : IsStarProjection (cyclicSubspace A ξ).starProjection := isStarProjection_starProjection + rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + exact hp.le_one + +def Good (S : Set (ProjLink (H:=H))) : Prop := + OrthogonalLinks (full (H:=H)) 1 1 S ∧ ∀ v∈S, ∃ ξ : H,ξ≠0 ∧ v=cyclicLink A ξ + +lemma exists_maximal_good : ∃ S : Set (ProjLink (H:=H)),Maximal (Good A) S := by + apply zorn_subset + intro c hc hchain + refine ⟨⋃₀ c,⟨?_,?_⟩,fun s hs => Set.subset_sUnion_of_mem hs⟩ + · intro v hv w hw hne + obtain ⟨s,hs,hvs⟩ := hv + obtain ⟨t,ht,hwt⟩ := hw + rcases hchain.total hs ht with hst|hts + · exact (hc ht).1 (hst hvs) hwt hne + · exact (hc hs).1 hvs (hts hwt) hne + · rintro v ⟨s,hs,hvs⟩ + exact (hc hs).2 v hvs + +variable {A} + +lemma good_projection {S : Set (ProjLink (H:=H))} (hS : Good A S) {v : ProjLink (H:=H)} (hv : v∈S) : + IsStarProjection v.val := by + obtain ⟨ξ,_,rfl⟩ := hS.2 v hv + exact isStarProjection_starProjection + +lemma good_commutes {S : Set (ProjLink (H:=H))} (hS : Good A S) {v : ProjLink (H:=H)} (hv : v∈S) + {a : H →L[ℂ] H} (ha : a∈A) : a*v.val=v.val*a := by + obtain ⟨ξ,_,rfl⟩ := hS.2 v hv + exact cyclic_projection_mem_commutant A ξ a ha + +lemma family_invariant {S : Set (ProjLink (H:=H))} (hS : Good A S) + {a : H →L[ℂ] H} (ha : a∈A) : + ∀ x∈familySpace (full (H:=H)) 1 1 S,a x∈familySpace (full (H:=H)) 1 1 S := by + let K := familySpace (full (H:=H)) 1 1 S + intro x hx + apply closure_minimal (t:={x | a x∈K}) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage a.continuous) hx + change Submodule.span ℂ {x : H | ∃ v∈S,∃ ξ : H,v.val ξ=x} ≤ K.comap a.toLinearMap + apply Submodule.span_le.mpr + rintro y ⟨v,hv,ξ,rfl⟩ + have he : a (v.val ξ)=v.val (a ξ) := congrArg (fun T : H →L[ℂ] H => T ξ) (good_commutes hS hv ha) + change a (v.val ξ)∈K + rw [he] + exact familySpace_generator _ _ _ S hv _ + +theorem maximal_spans {S : Set (ProjLink (H:=H))} (hS : Maximal (Good A) S) : + (familySpace (full (H:=H)) 1 1 S).starProjection=1 := by + classical + let K := familySpace (full (H:=H)) 1 1 S + let q := K.starProjection + have hq : IsStarProjection q := isStarProjection_starProjection + have hqcomm {a : H →L[ℂ] H} (ha : a∈A) : q*a=a*q := + projection_commutes_of_invariant K a (family_invariant hS.1 ha) + (family_invariant hS.1 (A.star_mem' ha)) + by_contra hneq + have hx : ∃ x : H,q x≠x := by + by_contra! h + exact hneq (ContinuousLinearMap.ext h) + obtain ⟨x,hx⟩ := hx + let ξ := x-q x + have hξ : ξ≠0 := by intro h; exact hx (sub_eq_zero.mp h).symm + have hqξ : q ξ=0 := by + change q (x-q x)=0 + rw [map_sub,show q (q x)=q x from congrArg (fun T : H →L[ℂ] H => T x) hq.isIdempotentElem.eq,sub_self] + have hker : cyclicSubspace A ξ ≤ q.ker := by + apply Submodule.topologicalClosure_minimal + · rintro y ⟨a,ha,rfl⟩ + change q (a ξ)=0 + rw [show q (a ξ)=a (q ξ) from congrArg (fun T : H →L[ℂ] H => T ξ) (hqcomm ha),hqξ,map_zero] + · exact q.isClosed_ker + let v := cyclicLink A ξ + have hvp : IsStarProjection v.val := isStarProjection_starProjection + have hqv : q*v.val=0 := by + ext y + exact hker ((cyclicSubspace A ξ).starProjection_apply_mem y) + have hvne : v.val≠0 := by + intro hz + have ht := Submodule.starProjection_eq_self_iff.mpr (mem_cyclicSubspace_self A ξ) + change v.val ξ=ξ at ht + rw [hz,zero_apply] at ht + exact hξ ht.symm + have hort {w : ProjLink (H:=H)} (hw : w∈S) : star w.val*v.val=0 := by + have hqw : q*w.val=w.val := familySpace_projection_mul _ _ _ S hw + have hwq : star w.val*q=star w.val := by + simpa only [star_mul,hq.isSelfAdjoint.star_eq] using congrArg star hqw + calc + _=(star w.val*q)*v.val := by rw [hwq] + _=0 := by rw [mul_assoc,hqv,mul_zero] + have hgood : Good A (insert v S) := by + refine ⟨?_,?_⟩ + · intro a ha b hb hne + rcases ha with rfl|ha <;> rcases hb with rfl|hb + · exact (hne rfl).elim + · simpa only [star_mul,star_star,star_zero] using congrArg star (hort hb) + · exact hort ha + · exact hS.1.1 ha hb hne + · intro w hw + rcases hw with rfl|hw + · exact ⟨ξ,hξ,rfl⟩ + · exact hS.1.2 w hw + have hvS : v∈S := hS.2 hgood (Set.subset_insert _ _) (Set.mem_insert _ _) + have he : q*v.val=v.val := familySpace_projection_mul _ _ _ S hvS + exact hvne (he.symm.trans hqv) + +structure Decomposition (A : StarSubalgebra ℂ (H →L[ℂ] H)) where + I : Type u + ξ : I → H + nonzero : ∀ i,ξ i≠0 + cross : ∀ i j,i≠j → (cyclicSubspace A (ξ i)).starProjection*(cyclicSubspace A (ξ j)).starProjection=0 + strong : ∀ x : H,Tendsto (fun s : Finset I => (∑ i∈s,(cyclicSubspace A (ξ i)).starProjection) x) atTop (𝓝 x) + +variable (A) + +theorem exists_decomposition : Nonempty (Decomposition A) := by + classical + obtain ⟨S,hS⟩ := exists_maximal_good A + choose ξ hξ he using fun v : S => hS.1.2 v.val v.property + have hval (v : S) : v.val.val=(cyclicSubspace A (ξ v)).starProjection := congrArg Link.val (he v) + have hfin (v : S) : v.val.final=(cyclicSubspace A (ξ v)).starProjection := by + rw [Link.final,(good_projection hS.1 v.property).isSelfAdjoint.star_eq, + (good_projection hS.1 v.property).isIdempotentElem.eq,hval] + refine ⟨⟨S,ξ,hξ,?_,?_⟩⟩ + · intro v w hne + have ht := family_cross _ _ _ S hS.1.1 hne + rw [(good_projection hS.1 v.property).isSelfAdjoint.star_eq,hval,hval] at ht + exact ht + · intro x + have ht := finiteProjection_tendsto _ _ _ S hS.1.1 (IsStarProjection.one _) (maximal_spans hS) x + simpa only [finiteProjection,hfin,one_apply_eq_self] using ht + +end Kadison.CyclicDecomposition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicGelfandModel.lean b/lean/OAI/Analysis/Commutator/CyclicGelfandModel.lean new file mode 100644 index 0000000000000000000000000000000000000000..5fbb9d0e4048623361750ec667c3f5c76cad2ae5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicGelfandModel.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpectralUnitary + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory + +open scoped Topology + +namespace Kadison.CyclicSpectral + +variable {A H : Type*} [CommCStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +abbrev spectrumSpace := WeakDual.characterSpace ℂ A + +variable [MeasurableSpace (spectrumSpace (A:=A))] [BorelSpace (spectrumSpace (A:=A))] + +def gelfandRepresentation (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) : + C(spectrumSpace (A:=A),ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H) := + ρ.comp (gelfandStarTransform A).symm.toStarAlgHom + +omit [MeasurableSpace (spectrumSpace (A:=A))] [BorelSpace (spectrumSpace (A:=A))] in +lemma gelfandRepresentation_dense (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hd : DenseRange (fun a : A => ρ a ξ)) : + DenseRange (orbitMap (gelfandRepresentation ρ) ξ) := by + apply hd.mono + rintro y ⟨a,rfl⟩ + refine ⟨gelfandStarTransform A a,?_⟩ + change ρ ((gelfandStarTransform A).symm (gelfandStarTransform A a)) ξ=ρ a ξ + rw [(gelfandStarTransform A).symm_apply_apply] + +theorem exists_gelfand_model (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hd : DenseRange (fun a : A => ρ a ξ)) : + ∃ μ : Measure (spectrumSpace (A:=A)), IsFiniteMeasure μ ∧ + ∃ U : Lp ℂ 2 μ ≃ₗᵢ[ℂ] H, + ∀ (a : A) (v : Lp ℂ 2 μ), U (scalarMultiplier μ (gelfandStarTransform A a) v)=ρ a (U v) := by + let σ := gelfandRepresentation ρ + let μ := measure σ ξ + let U := unitary σ ξ (gelfandRepresentation_dense ρ ξ hd) + refine ⟨μ,inferInstance,U,?_⟩ + intro a v + have h := unitary_intertwines σ ξ (gelfandRepresentation_dense ρ ξ hd) + (gelfandStarTransform A a) v + have he : σ (gelfandStarTransform A a)=ρ a := by + change ρ ((gelfandStarTransform A).symm (gelfandStarTransform A a))=ρ a + rw [(gelfandStarTransform A).symm_apply_apply] + rw [he] at h + exact h + +end Kadison.CyclicSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicImplementationUnconditional.lean b/lean/OAI/Analysis/Commutator/CyclicImplementationUnconditional.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d7d4ea0bbd1f5cad4a63a4296ce9facfdb80873 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicImplementationUnconditional.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.RectangularColumn + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.CyclicSpatial + +open OperatorAmplification CyclicColumns ReducingRepresentation + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (lam : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → lam a x∈K) + +local instance : NormedAddCommGroup (K →L[ℂ] H) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] H) := ContinuousLinearMap.toNormedSpace + +theorem extension_amplified_bound_unconditional (M : VonNeumannAlgebra H) + (hlam : Function.Injective lam) (hrange : Set.range lam=(M : Set (H →L[ℂ] H))) + (G : K →L[ℂ] H) (Ω : K) + (hΩ : DenseRange (fun a : A => restrict lam K hinv a Ω)) : + WOTDistance.AmplifiedBound M (extendZero (K:=K) G) (16*‖delta lam K hinv G‖) := by + have hh := extension_amplified_bound lam K hinv M hlam hrange G Ω hΩ + (c:=4*‖delta lam K hinv G‖) (by positivity) + (fun _ v ζ => RectangularColumn.column_bound (restrict lam K hinv) lam + (delta lam K hinv G) (delta_derivation lam K hinv G) v ζ) + convert hh using 1 + ring + +theorem exists_cyclic_intertwiner_unconditional (M : VonNeumannAlgebra H) + (hlam : Function.Injective lam) (hrange : Set.range lam=(M : Set (H →L[ℂ] H))) + (G : K →L[ℂ] H) (Ω : K) + (hΩ : DenseRange (fun a : A => restrict lam K hinv a Ω)) : + ∃ T : K →L[ℂ] H, (∀ a : A,T.comp (restrict lam K hinv a)=(lam a).comp T) ∧ + ‖G-T‖≤16*‖delta lam K hinv G‖ := by + obtain ⟨T,hT,hn⟩ := exists_cyclic_intertwiner lam K hinv M hlam hrange G Ω hΩ + (c:=4*‖delta lam K hinv G‖) (by positivity) + (fun _ v ζ => RectangularColumn.column_bound (restrict lam K hinv) lam + (delta lam K hinv G) (delta_derivation lam K hinv G) v ζ) + refine ⟨T,hT,?_⟩ + nlinarith + +end Kadison.CyclicSpatial + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicLocalModule.lean b/lean/OAI/Analysis/Commutator/CyclicLocalModule.lean new file mode 100644 index 0000000000000000000000000000000000000000..6263d3633c4d83cdadf350dce4e6fc03a39f57f4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicLocalModule.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerCyclicImplementation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixCornerImplementation + +open ConcreteCorner ReducingRepresentation + +variable {H ι : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] [DecidableEq ι] + +variable (M : VonNeumannAlgebra H) + +lemma cyclic_dense (ξ : H) : + DenseRange (fun a : Algebra M => + restrict (inclusion M) (cyclicSubspace M.toStarSubalgebra ξ) + (fun a => cyclicSubspace_invariant M.toStarSubalgebra ξ a.property) a + ⟨ξ,mem_cyclicSubspace_self M.toStarSubalgebra ξ⟩) := by + let K := cyclicSubspace M.toStarSubalgebra ξ + let act : Algebra M → K := fun a => + ⟨(a:H →L[ℂ] H) ξ,cyclicSubspace_invariant M.toStarSubalgebra ξ a.property ξ + (mem_cyclicSubspace_self M.toStarSubalgebra ξ)⟩ + have hi : (Subtype.val : K → H) '' Set.range act = + (orbitSubmodule M.toStarSubalgebra ξ : Set H) := by + ext x + constructor + · rintro ⟨_,⟨a,rfl⟩,rfl⟩ + exact ⟨a,a.property,rfl⟩ + · rintro ⟨a,ha,rfl⟩ + exact ⟨act ⟨a,ha⟩,⟨⟨a,ha⟩,rfl⟩,rfl⟩ + intro x + change x∈closure (Set.range act) + rw [Topology.IsEmbedding.subtypeVal.closure_eq_preimage_closure_image,hi] + exact x.property + +theorem exists_local_module {p : Algebra M} (hp : IsStarProjection p) + (v : ι → Algebra M) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + (G : H →L[ℂ] H) + (hGp : G.comp (inclusion M p)=(inclusion M p).comp G) + (hGv : ∀ i, G.comp (inclusion M (v i))=(inclusion M (v i)).comp G) + (ξ : H) (hpξ : inclusion M p ξ=ξ) + {ε : ℝ} (hε : 0≤ε) + (hδ : ∀ a : Corner hp, + ‖G.comp (inclusion M (a:Algebra M))-(inclusion M (a:Algebra M)).comp G‖≤ε*‖a‖) : + ∃ T : H →L[ℂ] H, + (∀ a : Algebra M, T.comp (inclusion M a)=(inclusion M a).comp T) ∧ + ∀ z∈cyclicSubspace M.toStarSubalgebra ξ, ‖G z-T z‖≤(16*ε)*‖z‖ := by + let K := cyclicSubspace M.toStarSubalgebra ξ + let hinv : ∀ (a : Algebra M) (x : H), x∈K → inclusion M a x∈K := + fun a => cyclicSubspace_invariant M.toStarSubalgebra ξ a.property + let σ := restrict (inclusion M) K hinv + let j : K →ₗᵢ[ℂ] H := K.subtypeₗᵢ + have hj (a : Algebra M) (x : K) : j (σ a x)=inclusion M a (j x) := rfl + have hGp' (x : K) : (G.comp K.subtypeL) (σ p x)=inclusion M p ((G.comp K.subtypeL) x) := + congrArg (fun F : H →L[ℂ] H => F (x:H)) hGp + have hGv' (i : ι) (x : K) : (G.comp K.subtypeL) (σ (v i) x)= + inclusion M (v i) ((G.comp K.subtypeL) x) := + congrArg (fun F : H →L[ℂ] H => F (x:H)) (hGv i) + let Ω : K := ⟨ξ,mem_cyclicSubspace_self M.toStarSubalgebra ξ⟩ + have hδ' (a : Corner hp) : + ‖(G.comp K.subtypeL).comp (σ (a:Algebra M))- + (inclusion M (a:Algebra M)).comp (G.comp K.subtypeL)‖≤ε*‖a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg hε (norm_nonneg a)) + intro x + change ‖G (inclusion M (a:Algebra M) (x:H))-inclusion M (a:Algebra M) (G (x:H))‖≤_ + exact ((G.comp (inclusion M (a:Algebra M))-(inclusion M (a:Algebra M)).comp G).le_opNorm (x:H)).trans + (mul_le_mul_of_nonneg_right (hδ a) (norm_nonneg _)) + obtain ⟨T,hT,hn⟩ := exists_matrix_corner_intertwiner M σ j hj hp + (G.comp K.subtypeL) hGp' v hcol hinit htotal hGv' Ω (cyclic_dense M ξ) + (Subtype.ext hpξ) hε hδ' + refine ⟨extendZero (K := K) T,extendZero_intertwines (inclusion M) (inclusion M) K hinv T hT,?_⟩ + intro z hz + exact norm_sub_extendZero_apply_le K G T (16*ε) hn ⟨z,hz⟩ + +end Kadison.MatrixCornerImplementation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicMatrix.lean b/lean/OAI/Analysis/Commutator/CyclicMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..fc8f70d52cd8c829035880ce2d66d64e5152b203 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicMatrix.lean @@ -0,0 +1,114 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A H F ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +def matrixAction (X : ι → ι → H →L[ℂ] F) : + PiLp 2 (fun _ : ι => H) →L[ℂ] PiLp 2 (fun _ : ι => F) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => F)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun i => ∑ j : ι, + (X i j).comp (PiLp.proj 2 (fun _ : ι => H) j))) + +omit [CompleteSpace H] [CompleteSpace F] in +@[simp] lemma matrixAction_apply (X : ι → ι → H →L[ℂ] F) + (x : PiLp 2 (fun _ : ι => H)) (i : ι) : + matrixAction X x i=∑ j, X i j (x j) := by + simp [matrixAction] + +def matrixRepresentation (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) : + CStarMatrix ι ι A →⋆ₐ[ℂ] (PiLp 2 (fun _ : ι => H) →L[ℂ] PiLp 2 (fun _ : ι => H)) where + toFun X := matrixAction (fun i j => σ (X i j)) + map_zero' := by ext x i; simp + map_one' := by + classical + ext x i + rw [matrixAction_apply] + change ∑ j, σ ((1 : CStarMatrix ι ι A) i j) (x j)=x i + have he (j : ι) : σ ((1 : CStarMatrix ι ι A) i j) (x j)=if i=j then x j else 0 := by + by_cases h : i=j <;> simp [CStarMatrix.one_apply,h] + simp_rw [he] + simp + map_add' X Y := by + ext x i + simp [CStarMatrix.add_apply,Finset.sum_add_distrib] + map_mul' X Y := by + ext x i + simp only [matrixAction_apply,CStarMatrix.mul_apply,map_sum,map_mul,sum_apply, + mul_apply_eq_comp,map_sum] + rw [Finset.sum_comm] + commutes' c := by + classical + ext x i + rw [matrixAction_apply] + change ∑ j, σ ((algebraMap ℂ (CStarMatrix ι ι A) c) i j) (x j)=c • x i + have he (j : ι) : σ ((algebraMap ℂ (CStarMatrix ι ι A) c) i j) (x j)= + if i=j then c • x j else 0 := by + by_cases h : i=j <;> simp [CStarMatrix.algebraMap_apply,h,Algebra.algebraMap_eq_smul_one] + simp_rw [he] + simp + map_star' X := by + rw [ContinuousLinearMap.star_eq_adjoint] + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [PiLp.inner_apply,matrixAction_apply,CStarMatrix.star_apply,map_star, + ContinuousLinearMap.star_eq_adjoint,sum_inner, + ContinuousLinearMap.adjoint_inner_left,inner_sum] + rw [Finset.sum_comm] + +lemma matrixRepresentation_norm_le (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (X : CStarMatrix ι ι A) : + ‖matrixRepresentation σ X‖ ≤ ‖X‖ := + NonUnitalStarAlgHom.norm_apply_le (matrixRepresentation σ) X + +def columnNorm (v : ι → A) : ℝ := + ‖(WithCStarModule.equiv A (ι → A)).symm (fun i => star (v i))‖ + +lemma columnNorm_sq (v : ι → A) : + columnNorm v ^ 2 = ‖∑ i, star (v i)*v i‖ := by + rw [columnNorm,WithCStarModule.pi_norm_sq] + simp only [WithCStarModule.equiv_symm_pi_apply,WithCStarModule.inner_def,star_star] + +lemma columnNorm_nonneg (v : ι → A) : 0 ≤ columnNorm v := norm_nonneg _ + +lemma columnNorm_le_one (v : ι → A) (hv : (∑ i,star (v i)*v i)≤1) : + columnNorm v ≤ 1 := by + have hp : 0 ≤ ∑ i,star (v i)*v i := Finset.sum_nonneg (fun i _ => star_mul_self_nonneg _) + have hn : ‖∑ i,star (v i)*v i‖ ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ hp).mpr hv + rw [←columnNorm_sq] at hn + nlinarith [columnNorm_nonneg v] + +lemma columnNorm_matmul_le (X : CStarMatrix ι ι A) (v : ι → A) : + columnNorm (fun i => ∑ j, X i j*v j) ≤ ‖X‖*columnNorm v := by + let r := (WithCStarModule.equiv A (ι → A)).symm (fun i => star (v i)) + have heq : (WithCStarModule.equiv A (ι → A)).symm + (fun i => star (∑ j, X i j*v j)) = CStarMatrix.toCLM (star X) r := by + ext i + simp [CStarMatrix.toCLM_apply_eq_sum,CStarMatrix.star_apply,r,star_sum,star_mul] + dsimp only [columnNorm] + rw [heq] + calc ‖CStarMatrix.toCLM (star X) r‖ ≤ ‖CStarMatrix.toCLM (star X)‖*‖r‖ := + ContinuousLinearMap.le_opNorm _ _ + _ = ‖X‖*‖r‖ := by rw [←CStarMatrix.norm_def,norm_star] + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicMatrixApproximation.lean b/lean/OAI/Analysis/Commutator/CyclicMatrixApproximation.lean new file mode 100644 index 0000000000000000000000000000000000000000..79f83c222d8592b69ddf14ce841c967cfdf37585 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicMatrixApproximation.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixCornerExtension +import OAI.Analysis.Commutator.ModuleZeroExtension + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace ENNReal + +open ContinuousLinearMap + +namespace Kadison.HilbertModuleExtension + +variable {ι E F K H : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (V : ι → E →ₗᵢ[ℂ] K) (W : ι → F →ₗᵢ[ℂ] H) + (hV : IsHilbertSum ℂ (fun _ : ι => E) V) (hW : IsHilbertSum ℂ (fun _ : ι => F) W) + +end Kadison.HilbertModuleExtension + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixCornerExtension + +open MatrixCornerHilbert + +variable {A K H ι : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] [DecidableEq ι] + +variable (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +variable {p : A} (hp : IsStarProjection p) (v : ι → A) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + +variable (G : K →L[ℂ] H) (hGp : ∀ x, G (σ p x)=ρ p (G x)) + +end Kadison.MatrixCornerExtension + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.ReducingRepresentation + +open MatrixCornerHilbert MatrixCornerExtension + +variable {A H F ι : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [Fintype ι] [DecidableEq ι] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ρ : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + +variable {p : A} (hp : IsStarProjection p) (v : ι → A) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + +variable (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → σ a x∈K) + +variable (G : H →L[ℂ] F) (hGp : ∀ x, G (σ p x)=ρ p (G x)) + +lemma restrict_intertwining (a : A) (hG : ∀ x, G (σ a x)=ρ a (G x)) (x : K) : + (G.comp K.subtypeL) (restrict σ K hinv a x)=ρ a ((G.comp K.subtypeL) x) := + hG x + +include hcol hinit htotal in +theorem local_module_from_corner + (V : fixedSpace (restrict σ K hinv p) →L[ℂ] fixedSpace (ρ p)) + (hV : ∀ a : Corner hp, + V.comp (corner (restrict σ K hinv) hp a)-(corner ρ hp a).comp V= + (cornerMap (restrict σ K hinv) ρ (G.comp K.subtypeL) + (restrict_intertwining σ ρ K hinv G p hGp)).comp (corner (restrict σ K hinv) hp a)- + (corner ρ hp a).comp (cornerMap (restrict σ K hinv) ρ (G.comp K.subtypeL) + (restrict_intertwining σ ρ K hinv G p hGp))) + (hGv : ∀ i x, G (σ (v i) x)=ρ (v i) (G x)) : + ∃ T : H →L[ℂ] F, + (∀ a : A, T.comp (σ a)=(ρ a).comp T) ∧ + ∀ z∈K, ‖G z-T z‖≤‖V‖*‖z‖ := by + let σK := restrict σ K hinv + let GK := G.comp K.subtypeL + let GE := cornerMap σK ρ GK (restrict_intertwining σ ρ K hinv G p hGp) + let R := GE-V + have hR : ∀ a : Corner hp, R.comp (corner σK hp a)=(corner ρ hp a).comp R := by + intro a + dsimp only [R] + rw [sub_comp,comp_sub] + have he := hV a + change V.comp (corner σK hp a)-(corner ρ hp a).comp V= + GE.comp (corner σK hp a)-(corner ρ hp a).comp GE at he + apply sub_eq_sub_iff_add_eq_add.mpr + exact (sub_eq_sub_iff_add_eq_add.mp he).symm.trans (add_comm _ _) + let TK := MatrixCornerExtension.extend σK ρ v hcol hinit htotal R + have hTK (a : A) : TK.comp (σK a)=(ρ a).comp TK := + MatrixCornerExtension.extend_intertwines σK ρ hp v hcol hinit htotal R hR a + have hnorm : ‖GK-TK‖≤‖V‖ := by + have he := MatrixCornerExtension.norm_sub_extend_le σK ρ v hcol hinit htotal GK + (restrict_intertwining σ ρ K hinv G p hGp) R + (fun i => restrict_intertwining σ ρ K hinv G (v i) (hGv i)) + have hsub : GE-R=V := sub_sub_cancel GE V + exact he.trans_eq (congrArg norm hsub) + refine ⟨extendZero (K := K) TK,extendZero_intertwines σ ρ K hinv TK hTK,?_⟩ + intro z hz + exact norm_sub_extendZero_apply_le K G TK ‖V‖ hnorm ⟨z,hz⟩ + +end Kadison.ReducingRepresentation +end +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicSpatialImplementation.lean b/lean/OAI/Analysis/Commutator/CyclicSpatialImplementation.lean new file mode 100644 index 0000000000000000000000000000000000000000..87b66cf37a6c88e546359f66ffb33f7dfbfa5c3a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicSpatialImplementation.lean @@ -0,0 +1,203 @@ +import Mathlib +import OAI.Analysis.Commutator.ArvesonDistance +import OAI.Analysis.Commutator.CyclicCb +import OAI.Analysis.Commutator.ModuleZeroExtension +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.CyclicSpatial + +open OperatorAmplification CyclicColumns ReducingRepresentation + +variable {A H ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +@[simp] lemma represented_matrix_apply (lam : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (X : CStarMatrix ι ι A) (x : SumSpace (H:=H) ι) (i : ι) : + matrixRepresentation lam X x i=∑ j,lam (X i j) (x j) := + matrixAction_apply _ _ _ + +lemma matrixRepresentation_injective (lam : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hlam : Function.Injective lam) : + Function.Injective (matrixRepresentation (ι:=ι) lam) := by + intro X Y h + apply CStarMatrix.ext + intro i j + apply hlam + ext x + have hh := congrArg (fun T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι => + T (single ι j x) i) h + simpa [matrixRepresentation,matrixAction_apply,single_apply,apply_ite] using hh + +lemma matrixRepresentation_norm_eq (lam : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hlam : Function.Injective lam) (X : CStarMatrix ι ι A) : + ‖matrixRepresentation lam X‖=‖X‖ := + NonUnitalStarAlgHom.norm_map (matrixRepresentation (ι:=ι) lam).toNonUnitalStarAlgHom + (matrixRepresentation_injective lam hlam) X + +variable (lam : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → lam a x∈K) + +local instance : NormedAddCommGroup (K →L[ℂ] H) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] H) := ContinuousLinearMap.toNormedSpace + +def delta (G : K →L[ℂ] H) : A →L[ℂ] (K →L[ℂ] H) := + LinearMap.mkContinuous + { toFun a := G.comp (restrict lam K hinv a)-(lam a).comp G + map_add' a b := by simp [map_add,ContinuousLinearMap.comp_add, + ContinuousLinearMap.add_comp,add_sub_add_comm] + map_smul' z a := by simp [map_smul,ContinuousLinearMap.smul_comp,smul_sub] } + (2*‖G‖) (by + intro a + change ‖G.comp (restrict lam K hinv a)-(lam a).comp G‖≤(2*‖G‖)*‖a‖ + calc + _ ≤ ‖G.comp (restrict lam K hinv a)‖+‖(lam a).comp G‖ := norm_sub_le _ _ + _ ≤ ‖G‖*‖restrict lam K hinv a‖+‖lam a‖*‖G‖ := + add_le_add (ContinuousLinearMap.opNorm_comp_le _ _) (ContinuousLinearMap.opNorm_comp_le _ _) + _ ≤ ‖G‖*‖a‖+‖a‖*‖G‖ := by + exact add_le_add + (mul_le_mul_of_nonneg_left (NonUnitalStarAlgHom.norm_apply_le (restrict lam K hinv) a) (norm_nonneg G)) + (mul_le_mul_of_nonneg_right (NonUnitalStarAlgHom.norm_apply_le lam a) (norm_nonneg G)) + _ = (2*‖G‖)*‖a‖ := by ring) + +@[simp] lemma delta_apply (G : K →L[ℂ] H) (a : A) : + delta lam K hinv G a=G.comp (restrict lam K hinv a)-(lam a).comp G := rfl + +lemma delta_derivation (G : K →L[ℂ] H) (a b : A) : + delta lam K hinv G (a*b)=(delta lam K hinv G a).comp (restrict lam K hinv b)+ + (lam a).comp (delta lam K hinv G b) := by + ext x + simp only [delta_apply,map_mul,_root_.sub_apply,_root_.add_apply, + ContinuousLinearMap.comp_apply,mul_apply_eq_comp,map_sub] + abel + +omit [CompleteSpace H] in +lemma projection_tuple_norm_le (x : SumSpace (H:=H) ι) : + ‖WithLp.toLp 2 (fun i => K.orthogonalProjectionOnto (x i))‖≤‖x‖ := by + have hh : ‖WithLp.toLp 2 (fun i => K.orthogonalProjectionOnto (x i))‖^2≤‖x‖^2 := by + rw [PiLp.norm_sq_eq_of_L2,PiLp.norm_sq_eq_of_L2] + exact Finset.sum_le_sum (fun i _ => pow_le_pow_left₀ (norm_nonneg _) + (K.norm_orthogonalProjectionOnto_apply_le (x i)) 2) + exact (sq_le_sq₀ (norm_nonneg _) (norm_nonneg _)).mp hh + +lemma extension_matrix_commutator (G : K →L[ℂ] H) (X : CStarMatrix ι ι A) + (x : SumSpace (H:=H) ι) : + (diagonal (H:=H) ι (extendZero (K:=K) G)*matrixRepresentation lam X- + matrixRepresentation lam X*diagonal (H:=H) ι (extendZero (K:=K) G)) x = + matrixAction (fun i j => delta lam K hinv G (X i j)) + (WithLp.toLp 2 (fun i => K.orthogonalProjectionOnto (x i))) := by + ext i + simp only [_root_.sub_apply,mul_apply_eq_comp,PiLp.sub_apply,diagonal_apply, + represented_matrix_apply,matrixAction_apply,extendZero,ContinuousLinearMap.comp_apply, + map_sum,delta_apply,Finset.sum_sub_distrib] + congr 1 + apply Finset.sum_congr rfl + intro j _ + rw [project_intertwines lam K hinv] + +lemma extension_matrix_norm_bound + (G : K →L[ℂ] H) (Ω : K) + (hΩ : DenseRange (fun a : A => restrict lam K hinv a Ω)) + {c : ℝ} (hc : 0≤c) + (hcol : ∀ (v : ι → A) (ζ : K), + ‖WithLp.toLp 2 (fun i => delta lam K hinv G (v i) ζ)‖≤c*columnNorm v*‖ζ‖) + (X : CStarMatrix ι ι A) : + ‖diagonal (H:=H) ι (extendZero (K:=K) G)*matrixRepresentation lam X- + matrixRepresentation lam X*diagonal (H:=H) ι (extendZero (K:=K) G)‖≤4*c*‖X‖ := by + have hcb := cyclic_matrix_bound (restrict lam K hinv) lam (delta lam K hinv G) + (delta_derivation lam K hinv G) Ω hΩ c hc hcol X + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro x + rw [extension_matrix_commutator lam K hinv] + calc + _ ≤ ‖matrixAction (fun i j => delta lam K hinv G (X i j))‖* + ‖WithLp.toLp 2 (fun i => K.orthogonalProjectionOnto (x i))‖ := + ContinuousLinearMap.le_opNorm _ _ + _ ≤ (4*c*‖X‖)*‖x‖ := mul_le_mul hcb (projection_tuple_norm_le K x) + (norm_nonneg _) (by positivity) + +theorem extension_amplified_bound (M : VonNeumannAlgebra H) + (hlam : Function.Injective lam) (hrange : Set.range lam=(M : Set (H →L[ℂ] H))) + (G : K →L[ℂ] H) (Ω : K) + (hΩ : DenseRange (fun a : A => restrict lam K hinv a Ω)) + {c : ℝ} (hc : 0≤c) + (hcol : ∀ (n : ℕ) (v : Fin n → A) (ζ : K), + ‖WithLp.toLp 2 (fun i => delta lam K hinv G (v i) ζ)‖≤c*columnNorm v*‖ζ‖) : + WOTDistance.AmplifiedBound M (extendZero (K:=K) G) (4*c) := by + classical + intro n T hT + have hex : ∀ i j,∃ a : A,lam a=entry (Fin n) T i j := by + intro i j + change entry (Fin n) T i j∈Set.range lam + rw [hrange] + exact hT i j + choose a ha using hex + let X : CStarMatrix (Fin n) (Fin n) A := CStarMatrix.ofMatrix a + have hX : matrixRepresentation lam X=T := by + rw [←reconstruct (Fin n) T] + change matrixAction (fun i j => lam (X i j)) = matrixAction (entry (Fin n) T) + congr 1 + funext i j + exact ha i j + have hcb := extension_matrix_norm_bound lam K hinv G Ω hΩ hc (hcol n) X + rw [←matrixRepresentation_norm_eq lam hlam X,hX] at hcb + exact hcb + +omit [PartialOrder A] [StarOrderedRing A] [CompleteSpace H] in +lemma restriction_distance_bound (G : K →L[ℂ] H) (T : H →L[ℂ] H) + {c : ℝ} (hc : 0≤c) (hn : ‖extendZero (K:=K) G-T‖≤c) : + ‖G-T.comp K.subtypeL‖≤c := by + apply ContinuousLinearMap.opNorm_le_bound _ hc + intro x + have he : (G-T.comp K.subtypeL) x=(extendZero (K:=K) G-T) (x:H) := by + change G x-T (x:H)=extendZero (K:=K) G (x:H)-T (x:H) + rw [extendZero_subtype] + rw [he] + exact ((extendZero (K:=K) G-T).le_opNorm (x:H)).trans + (mul_le_mul_of_nonneg_right hn (norm_nonneg _)) + +theorem exists_cyclic_intertwiner (M : VonNeumannAlgebra H) + (hlam : Function.Injective lam) (hrange : Set.range lam=(M : Set (H →L[ℂ] H))) + (G : K →L[ℂ] H) (Ω : K) + (hΩ : DenseRange (fun a : A => restrict lam K hinv a Ω)) + {c : ℝ} (hc : 0≤c) + (hcol : ∀ (n : ℕ) (v : Fin n → A) (ζ : K), + ‖WithLp.toLp 2 (fun i => delta lam K hinv G (v i) ζ)‖≤c*columnNorm v*‖ζ‖) : + ∃ T : K →L[ℂ] H, (∀ a : A,T.comp (restrict lam K hinv a)=(lam a).comp T) ∧ + ‖G-T‖≤4*c := by + obtain ⟨T,hT,hn⟩ := WOTDistance.exists_commutant_approximation M + (extendZero (K:=K) G) (by positivity) + (extension_amplified_bound lam K hinv M hlam hrange G Ω hΩ hc hcol) + refine ⟨T.comp K.subtypeL,?_,?_⟩ + · intro a + ext x + have ha : lam a∈M := by + change lam a ∈ (M : Set (H →L[ℂ] H)) + rw [←hrange] + exact Set.mem_range_self a + have he := (VonNeumannAlgebra.mem_commutant_iff.mp hT) (lam a) ha + exact (congrArg (fun R : H →L[ℂ] H => R (x:H)) he).symm + · exact restriction_distance_bound K G T (by positivity) hn + +end Kadison.CyclicSpatial + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicSpectralMeasure.lean b/lean/OAI/Analysis/Commutator/CyclicSpectralMeasure.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a55d83adde603e1547b0a32b473318f40df90f6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicSpectralMeasure.lean @@ -0,0 +1,73 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory + +open scoped ComplexOrder InnerProductSpace CompactlySupported + +namespace Kadison.CyclicSpectral + +variable {Ω H : Type*} [TopologicalSpace Ω] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def complexify (f : C_c(Ω,ℝ)) : C(Ω,ℂ) := + ⟨fun x => (f x:ℂ),Complex.continuous_ofReal.comp f.continuous⟩ + +lemma complexify_add (f g : C_c(Ω,ℝ)) : complexify (f+g)=complexify f+complexify g := by + ext x + simp [complexify] + +lemma complexify_smul (r : ℝ) (f : C_c(Ω,ℝ)) : complexify (r•f)=(r:ℂ)•complexify f := by + ext x + simp [complexify] + +lemma complexify_sub (f g : C_c(Ω,ℝ)) : complexify (f-g)=complexify f-complexify g := by + ext x + simp [complexify] + +lemma complexify_nonneg {f : C_c(Ω,ℝ)} (hf : 0≤f) : 0≤complexify f := by + intro x + exact Complex.zero_le_real.mpr (hf x) + +def vectorFunctional (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : C_c(Ω,ℝ) →ₚ[ℝ] ℝ where + toFun f := (inner ℂ ξ (ρ (complexify f) ξ)).re + map_add' f g := by simp [complexify_add] + map_smul' r f := by + rw [complexify_smul,map_smul] + simp + monotone' := by + intro f g hfg + have hp : 0≤ρ (complexify (g-f)) := map_nonneg ρ (complexify_nonneg (sub_nonneg.mpr hfg)) + have hi := (ContinuousLinearMap.nonneg_iff_isPositive.mp hp).re_inner_nonneg_right ξ + simpa [complexify_sub,inner_sub_right,sub_nonneg] using hi + +variable [T2Space Ω] [CompactSpace Ω] [MeasurableSpace Ω] [BorelSpace Ω] + +def measure (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : Measure Ω := + RealRMK.rieszMeasure (vectorFunctional ρ ξ) + +instance measure_regular (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : + (measure ρ ξ).Regular := inferInstanceAs (RealRMK.rieszMeasure (vectorFunctional ρ ξ)).Regular + +instance measure_finite (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : + IsFiniteMeasure (measure ρ ξ) := inferInstance + +lemma integral_real (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) (f : C_c(Ω,ℝ)) : + ∫ x,f x ∂measure ρ ξ=(inner ℂ ξ (ρ (complexify f) ξ)).re := + RealRMK.integral_rieszMeasure (vectorFunctional ρ ξ) f + +end Kadison.CyclicSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicSpectralNorm.lean b/lean/OAI/Analysis/Commutator/CyclicSpectralNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1ba28023ae2e72430f57df62de5bfa4614de71a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicSpectralNorm.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpectralMeasure + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory + +open scoped ComplexOrder InnerProductSpace CompactlySupported ComplexConjugate + +namespace Kadison.CyclicSpectral + +variable {Ω H : Type*} [TopologicalSpace Ω] [T2Space Ω] [CompactSpace Ω] + [MeasurableSpace Ω] [BorelSpace Ω] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def normSqFunction (f : C(Ω,ℂ)) : C_c(Ω,ℝ) := + CompactlySupportedContinuousMap.continuousMapEquiv + ⟨fun x => Complex.normSq (f x),Complex.continuous_normSq.comp f.continuous⟩ + +omit [T2Space Ω] [MeasurableSpace Ω] [BorelSpace Ω] in +lemma complexify_normSq (f : C(Ω,ℂ)) : complexify (normSqFunction f)=star f*f := by + ext x + change (Complex.normSq (f x):ℂ)=star (f x)*f x + simp [Complex.normSq_eq_conj_mul_self] + +lemma representation_norm_integral (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) (f : C(Ω,ℂ)) : + ‖ρ f ξ‖^2=∫ x,Complex.normSq (f x) ∂measure ρ ξ := by + have hi := integral_real ρ ξ (normSqFunction f) + rw [complexify_normSq,map_mul,map_star] at hi + change (∫ x,Complex.normSq (f x) ∂measure ρ ξ)= + (inner ℂ ξ ((ρ f).adjoint (ρ f ξ))).re at hi + rw [ContinuousLinearMap.adjoint_inner_right,inner_self_eq_norm_sq_to_K] at hi + change (∫ x,Complex.normSq (f x) ∂measure ρ ξ)= + ((Complex.ofReal ‖ρ f ξ‖)^2).re at hi + rw [←Complex.ofReal_pow, Complex.ofReal_re] at hi + exact hi.symm + +lemma toLp_norm_eq (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) (f : C(Ω,ℂ)) : + ‖ContinuousMap.toLp 2 (measure ρ ξ) ℂ f‖=‖ρ f ξ‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq_eq_re_inner (𝕜:=ℂ),MeasureTheory.ContinuousMap.inner_toLp] + simp_rw [Complex.mul_conj] + rw [integral_complex_ofReal] + simpa using (representation_norm_integral ρ ξ f).symm + +end Kadison.CyclicSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/CyclicSpectralUnitary.lean b/lean/OAI/Analysis/Commutator/CyclicSpectralUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..44a58260a14e66e98ac05c949c180102d4170040 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/CyclicSpectralUnitary.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpectralNorm +import OAI.Analysis.Commutator.DecomposableOperator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.CyclicSpectral + +variable {Ω H : Type*} [TopologicalSpace Ω] [T2Space Ω] [CompactSpace Ω] + [MeasurableSpace Ω] [BorelSpace Ω] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def orbitMap (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : C(Ω,ℂ) →ₗ[ℂ] H where + toFun f := ρ f ξ + map_add' f g := by simp + map_smul' z f := by simp + +def unitary (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hd : DenseRange (orbitMap ρ ξ)) : Lp ℂ 2 (measure ρ ξ) ≃ₗᵢ[ℂ] H := + (LinearEquiv.refl ℂ C(Ω,ℂ)).extendOfIsometry + (ContinuousMap.toLp 2 (measure ρ ξ) ℂ).toLinearMap (orbitMap ρ ξ) + (ContinuousMap.toLp_denseRange ℂ (measure ρ ξ) ℂ (p:=2) (by norm_num)) hd + (fun f => (toLp_norm_eq ρ ξ f).symm) + +lemma unitary_toLp (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hd : DenseRange (orbitMap ρ ξ)) (f : C(Ω,ℂ)) : + unitary ρ ξ hd (ContinuousMap.toLp 2 (measure ρ ξ) ℂ f)=ρ f ξ := by + exact LinearEquiv.extendOfIsometry_eq .. + +variable (μ : Measure Ω) + +def scalarMultiplier (f : C(Ω,ℂ)) : Lp ℂ 2 μ →L[ℂ] Lp ℂ 2 μ := + Decomposable.operator μ (fun x => (f x) • (1 : ℂ →L[ℂ] ℂ)) + (fun z => by + change AEStronglyMeasurable (fun x => f x*z) μ + exact (f.continuous.mul continuous_const).aestronglyMeasurable) + (Eventually.of_forall (fun x => by + simpa using f.norm_coe_le_norm x)) + +omit [T2Space Ω] in +lemma scalarMultiplier_ae (f : C(Ω,ℂ)) (v : Lp ℂ 2 μ) : + scalarMultiplier μ f v=ᵐ[μ] fun x => f x*v x := + Decomposable.operator_ae .. + +omit [T2Space Ω] in +lemma scalarMultiplier_toLp [IsFiniteMeasure μ] (f g : C(Ω,ℂ)) : + scalarMultiplier μ f (ContinuousMap.toLp 2 μ ℂ g)=ContinuousMap.toLp 2 μ ℂ (f*g) := by + apply Lp.ext + filter_upwards [scalarMultiplier_ae μ f (ContinuousMap.toLp 2 μ ℂ g), + ContinuousMap.coeFn_toLp (𝕜:=ℂ) (p:=2) μ g,ContinuousMap.coeFn_toLp (𝕜:=ℂ) (p:=2) μ (f*g)] with x hx hg hfg + rw [hx,hg,hfg] + rfl + +lemma unitary_intertwines (ρ : C(Ω,ℂ) →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hd : DenseRange (orbitMap ρ ξ)) (f : C(Ω,ℂ)) (v : Lp ℂ 2 (measure ρ ξ)) : + unitary ρ ξ hd (scalarMultiplier (measure ρ ξ) f v)=ρ f (unitary ρ ξ hd v) := by + apply (ContinuousMap.toLp_denseRange ℂ (measure ρ ξ) ℂ (p:=2) (by norm_num)).induction_on v + (p:=fun v => unitary ρ ξ hd (scalarMultiplier (measure ρ ξ) f v)=ρ f (unitary ρ ξ hd v)) + · apply isClosed_eq + · exact (unitary ρ ξ hd).continuous.comp (scalarMultiplier (measure ρ ξ) f).continuous + · exact (ρ f).continuous.comp (unitary ρ ξ hd).continuous + · intro g + rw [scalarMultiplier_toLp,unitary_toLp,unitary_toLp,map_mul] + rfl + +end Kadison.CyclicSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DeMarrCenter.lean b/lean/OAI/Analysis/Commutator/DeMarrCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..764daab482af92a778665301d68cff8d647e8a97 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DeMarrCenter.lean @@ -0,0 +1,82 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Set + +open scoped BigOperators + +namespace Kadison.DeMarrCenter + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +theorem exists_center {K : Set E} (hK : IsCompact K) (hne : K.Nonempty) + (D : ℝ) (hD : 0 Metric.ball (x:E) (D/2)) + (fun _ => Metric.isOpen_ball) (by + intro x hx + exact mem_iUnion.mpr ⟨⟨x,hx⟩,by simpa only [Metric.mem_ball,dist_self] using half_pos hD⟩) + have htn : t.Nonempty := by + obtain ⟨x,hx⟩ := hne + obtain ⟨i,hi,_⟩ := mem_iUnion₂.mp (ht hx) + exact ⟨i,hi⟩ + have hcard : 0<(t.card : ℝ) := by exact_mod_cast htn.card_pos + let c : E := (t.card : ℝ)⁻¹ • ∑ i∈t,(i:E) + let r : ℝ := (t.card : ℝ)⁻¹*(D/2+((t.erase htn.choose).card : ℝ)*D) + have herase (i : K) (hi : i∈t) : ((t.erase i).card : ℝ)=(t.card : ℝ)-1 := by + have hc := Finset.card_erase_add_one hi + have hc' : ((t.erase i).card : ℝ)+1=(t.card : ℝ) := by exact_mod_cast hc + linarith + have hcent : c∈convexHull ℝ K := by + have hh := t.centerMass_mem_convexHull (R:=ℝ) (s:=K) (w:=fun _ => (1:ℝ)) + (fun _ _ => zero_le_one) (by simpa only [Finset.sum_const,nsmul_eq_mul,smul_eq_mul,mul_one] using hcard) + (fun i _ => i.property) + simpa only [Finset.centerMass,Finset.sum_const,nsmul_eq_mul,smul_eq_mul,mul_one,one_smul] using hh + have hr : 0≤r := mul_nonneg (inv_nonneg.mpr hcard.le) + (add_nonneg (half_pos hD).le (mul_nonneg (Nat.cast_nonneg _) hD.le)) + have hrD : r hdiam j j.property x hx)) + linarith + have hcx : c-x=(t.card : ℝ)⁻¹ • ∑ j∈t,((j:E)-x) := by + rw [Finset.sum_sub_distrib,smul_sub,Finset.sum_const,← Nat.cast_smul_eq_nsmul ℝ] + dsimp [c] + rw [smul_smul,inv_mul_cancel₀ hcard.ne',one_smul] + rw [dist_eq_norm,hcx,norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hcard)] + calc + _ ≤ (t.card : ℝ)⁻¹*∑ j∈t,‖(j:E)-x‖ := mul_le_mul_of_nonneg_left + (norm_sum_le _ _) (inv_nonneg.mpr hcard.le) + _ ≤ (t.card : ℝ)⁻¹*(D/2+((t.erase i).card : ℝ)*D) := by + simp only [←dist_eq_norm] + exact mul_le_mul_of_nonneg_left hs (inv_nonneg.mpr hcard.le) + _ = r := by dsimp [r]; rw [herase i hi,herase _ htn.choose_spec] + +end Kadison.DeMarrCenter + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableAlgebra.lean b/lean/OAI/Analysis/Commutator/DecomposableAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..48f1ba39016d56420d4279886adfc4ad2f5e9b06 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableAlgebra.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableOperator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +lemma operator_eq_of_ae_apply (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (A : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (hA : ∀ f : Lp H 2 μ,A f =ᵐ[μ] fun a => T a (f a)) : + A=operator μ T hm hb := by + apply ContinuousLinearMap.ext + intro f + apply Lp.ext + exact (hA f).trans (operator_ae μ T hm hb f).symm + +lemma add_measurable (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) (ξ : H) : + AEStronglyMeasurable (fun a => (T a+S a) ξ) μ := (hT ξ).add (hS ξ) + +lemma sub_measurable (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) (ξ : H) : + AEStronglyMeasurable (fun a => (T a-S a) ξ) μ := (hT ξ).sub (hS ξ) + +lemma mul_measurable (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) (ξ : H) : + AEStronglyMeasurable (fun a => (T a*S a) ξ) μ := measurable_apply μ T hT (hS ξ) + +lemma sub_bound (T S : Ω → H →L[ℂ] H) {b c : ℝ} + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + ∀ᵐ a ∂μ,‖T a-S a‖≤b+c := by + filter_upwards [hb,hc] with a ha hb + exact (norm_sub_le _ _).trans (add_le_add ha hb) + +lemma mul_bound (T S : Ω → H →L[ℂ] H) {b c : ℝ} (hb0 : 0≤b) + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + ∀ᵐ a ∂μ,‖T a*S a‖≤b*c := by + filter_upwards [hb,hc] with a ha hc + exact (norm_mul_le _ _).trans (mul_le_mul ha hc (norm_nonneg _) hb0) + +lemma operator_sub (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + operator μ T hT hb-operator μ S hS hc= + operator μ (fun a => T a-S a) (sub_measurable μ T S hT hS) (sub_bound μ T S hb hc) := by + apply operator_eq_of_ae_apply + intro f + filter_upwards [operator_ae μ T hT hb f,operator_ae μ S hS hc f, + Lp.coeFn_sub (operator μ T hT hb f) (operator μ S hS hc f)] with a h1 h2 h3 + change (operator μ T hT hb f-operator μ S hS hc f) a=_ + rw [h3] + exact congrArg₂ (·-·) h1 h2 + +lemma operator_mul (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c : ℝ} (hb0 : 0≤b) (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + operator μ T hT hb*operator μ S hS hc= + operator μ (fun a => T a*S a) (mul_measurable μ T S hT hS) (mul_bound μ T S hb0 hb hc) := by + apply operator_eq_of_ae_apply + intro f + filter_upwards [operator_ae μ T hT hb (operator μ S hS hc f),operator_ae μ S hS hc f] + with a ha hs + change (operator μ T hT hb (operator μ S hS hc f)) a=_ + rw [ha,hs] + rfl + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableConstLimit.lean b/lean/OAI/Analysis/Commutator/DecomposableConstLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..a8eed3c714a1bf31b4c4e8ea008220e5410e65fa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableConstLimit.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.DenseFieldClosure +import OAI.Analysis.Commutator.FiniteVectorLpConvergence + +namespace OAI + +noncomputable section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem mem_ae_of_bounded_const_limit (Q : Ω → VonNeumannAlgebra H) + (T : Ω → H →L[ℂ] H) (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {c : ℝ} (hc : ∀ᵐ a ∂μ,‖T a‖≤c) + (S : ℕ → Ω → H →L[ℂ] H) + (hS : ∀ n ξ,AEStronglyMeasurable (fun a => S n a ξ) μ) + {b : ℝ} (hb : 0≤b) (hSb : ∀ n,∀ᵐ a ∂μ,‖S n a‖≤b) + (hmem : ∀ n,∀ᵐ a ∂μ,S n a∈Q a) + (hlim : ∀ ξ,Tendsto (fun n => operator μ (S n) (hS n) (hSb n) (Lp.const 2 μ ξ)) atTop + (𝓝 (operator μ T hT hc (Lp.const 2 μ ξ)))) : ∀ᵐ a ∂μ,T a∈Q a := by + let v : ℕ → H := TopologicalSpace.denseSeq H + let V : ℕ → Lp H 2 μ := fun j => Lp.constL 2 μ ℂ (v j) + have hconst (j : ℕ) : V j =ᵐ[μ] fun _ => v j := Lp.coeFn_const 2 μ (v j) + have hfinite (m : ℕ) : ∀ᵐ a ∂μ,∃ k : ℕ → ℕ,∀ j : Fin m, + Tendsto (fun n => S (k n) a (v j)) atTop (𝓝 (T a (v j))) := by + obtain ⟨k,hk,hka⟩ := exists_finite_test_subsequence μ + (fun n (j : Fin m) => operator μ (S n) (hS n) (hSb n) (V j)) + (fun (j : Fin m) => operator μ T hT hc (V j)) (fun j => hlim (v j)) + filter_upwards [hka,ae_all_iff.mpr hconst, + ae_all_iff.mpr (fun n => ae_all_iff.mpr (fun j : ℕ => + operator_ae μ (S n) (hS n) (hSb n) (V j))), + ae_all_iff.mpr (fun j : ℕ => operator_ae μ T hT hc (V j))] + with a hka hv hs ht + refine ⟨k,fun j => ?_⟩ + have he (n : ℕ) : operator μ (S (k n)) (hS (k n)) (hSb (k n)) (V j) a= + S (k n) a (v j) := by rw [hs,hv] + have he' : operator μ T hT hc (V j) a=T a (v j) := by rw [ht,hv] + simpa only [he,he'] using hka j + filter_upwards [ae_all_iff.mpr hfinite,ae_all_iff.mpr hSb,ae_all_iff.mpr hmem] + with a hf hba hma + apply mem_vonNeumann_of_dense_finite_tests (Q a) v + (TopologicalSpace.denseRange_denseSeq H) (T a) b hb + intro m + obtain ⟨k,hk⟩ := hf m + have hevent : ∀ᶠ n in atTop,∀ j : Fin m, + ‖S (k n) a (v j)-T a (v j)‖<1/((m:ℝ)+1) := by + apply eventually_all.mpr + intro j + exact (tendsto_iff_norm_sub_tendsto_zero.mp (hk j)).eventually + (gt_mem_nhds (by positivity : (0:ℝ)<1/((m:ℝ)+1))) + obtain ⟨n,hn⟩ := hevent.exists + exact ⟨S (k n) a,hma (k n),hba (k n),fun j => (hn j).le⟩ + +end Kadison.Decomposable +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableDenseLimit.lean b/lean/OAI/Analysis/Commutator/DecomposableDenseLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..df6af6c5e3f35514b36b44bf1de1da795fec52e6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableDenseLimit.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.DenseFieldClosure +import OAI.Analysis.Commutator.FiniteVectorLpConvergence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem mem_ae_of_bounded_dense_const_limit (Q : Ω → VonNeumannAlgebra H) + (T : Ω → H →L[ℂ] H) (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {c : ℝ} (hc : ∀ᵐ a ∂μ,‖T a‖≤c) + (S : ℕ → Ω → H →L[ℂ] H) + (hS : ∀ n ξ,AEStronglyMeasurable (fun a => S n a ξ) μ) + {b : ℝ} (hb : 0≤b) (hSb : ∀ n,∀ᵐ a ∂μ,‖S n a‖≤b) + (hmem : ∀ n,∀ᵐ a ∂μ,S n a∈Q a) + (hlim : ∀ j : ℕ,Tendsto (fun n => operator μ (S n) (hS n) (hSb n) + (Lp.const 2 μ (TopologicalSpace.denseSeq H j))) atTop + (𝓝 (operator μ T hT hc (Lp.const 2 μ (TopologicalSpace.denseSeq H j))))) : ∀ᵐ a ∂μ,T a∈Q a := by + let v : ℕ → H := TopologicalSpace.denseSeq H + let V : ℕ → Lp H 2 μ := fun j => Lp.constL 2 μ ℂ (v j) + have hconst (j : ℕ) : V j =ᵐ[μ] fun _ => v j := Lp.coeFn_const 2 μ (v j) + have hfinite (m : ℕ) : ∀ᵐ a ∂μ,∃ k : ℕ → ℕ,∀ j : Fin m, + Tendsto (fun n => S (k n) a (v j)) atTop (𝓝 (T a (v j))) := by + obtain ⟨k,hk,hka⟩ := exists_finite_test_subsequence μ + (fun n (j : Fin m) => operator μ (S n) (hS n) (hSb n) (V j)) + (fun (j : Fin m) => operator μ T hT hc (V j)) (fun j => hlim j) + filter_upwards [hka,ae_all_iff.mpr hconst, + ae_all_iff.mpr (fun n => ae_all_iff.mpr (fun j : ℕ => + operator_ae μ (S n) (hS n) (hSb n) (V j))), + ae_all_iff.mpr (fun j : ℕ => operator_ae μ T hT hc (V j))] + with a hka hv hs ht + refine ⟨k,fun j => ?_⟩ + have he (n : ℕ) : operator μ (S (k n)) (hS (k n)) (hSb (k n)) (V j) a= + S (k n) a (v j) := by rw [hs,hv] + have he' : operator μ T hT hc (V j) a=T a (v j) := by rw [ht,hv] + simpa only [he,he'] using hka j + filter_upwards [ae_all_iff.mpr hfinite,ae_all_iff.mpr hSb,ae_all_iff.mpr hmem] + with a hf hba hma + apply mem_vonNeumann_of_dense_finite_tests (Q a) v + (TopologicalSpace.denseRange_denseSeq H) (T a) b hb + intro m + obtain ⟨k,hk⟩ := hf m + have hevent : ∀ᶠ n in atTop,∀ j : Fin m, + ‖S (k n) a (v j)-T a (v j)‖<1/((m:ℝ)+1) := by + apply eventually_all.mpr + intro j + exact (tendsto_iff_norm_sub_tendsto_zero.mp (hk j)).eventually + (gt_mem_nhds (by positivity : (0:ℝ)<1/((m:ℝ)+1))) + obtain ⟨n,hn⟩ := hevent.exists + exact ⟨S (k n) a,hma (k n),hba (k n),fun j => (hn j).le⟩ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableLimit.lean b/lean/OAI/Analysis/Commutator/DecomposableLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c9ccebd9047b7ae45c63dec0ce943524ab35407 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableLimit.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.DenseFieldClosure +import OAI.Analysis.Commutator.FiniteVectorLpConvergence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem mem_ae_of_bounded_strong_limit (Q : Ω → VonNeumannAlgebra H) + (T : Ω → H →L[ℂ] H) (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {c : ℝ} (hc : ∀ᵐ a ∂μ,‖T a‖≤c) + (S : ℕ → Ω → H →L[ℂ] H) + (hS : ∀ n ξ,AEStronglyMeasurable (fun a => S n a ξ) μ) + {b : ℝ} (hb : 0≤b) (hSb : ∀ n,∀ᵐ a ∂μ,‖S n a‖≤b) + (hmem : ∀ n,∀ᵐ a ∂μ,S n a∈Q a) + (hlim : ∀ f,Tendsto (fun n => operator μ (S n) (hS n) (hSb n) f) atTop + (𝓝 (operator μ T hT hc f))) : ∀ᵐ a ∂μ,T a∈Q a := by + let v : ℕ → H := TopologicalSpace.denseSeq H + let V : ℕ → Lp H 2 μ := fun j => Lp.constL 2 μ ℂ (v j) + have hconst (j : ℕ) : V j =ᵐ[μ] fun _ => v j := Lp.coeFn_const 2 μ (v j) + have hfinite (m : ℕ) : ∀ᵐ a ∂μ,∃ k : ℕ → ℕ,∀ j : Fin m, + Tendsto (fun n => S (k n) a (v j)) atTop (𝓝 (T a (v j))) := by + obtain ⟨k,hk,hka⟩ := exists_finite_test_subsequence μ + (fun n (j : Fin m) => operator μ (S n) (hS n) (hSb n) (V j)) + (fun (j : Fin m) => operator μ T hT hc (V j)) (fun j => hlim (V j)) + filter_upwards [hka,ae_all_iff.mpr hconst, + ae_all_iff.mpr (fun n => ae_all_iff.mpr (fun j : ℕ => + operator_ae μ (S n) (hS n) (hSb n) (V j))), + ae_all_iff.mpr (fun j : ℕ => operator_ae μ T hT hc (V j))] + with a hka hv hs ht + refine ⟨k,fun j => ?_⟩ + have he (n : ℕ) : operator μ (S (k n)) (hS (k n)) (hSb (k n)) (V j) a= + S (k n) a (v j) := by rw [hs,hv] + have he' : operator μ T hT hc (V j) a=T a (v j) := by rw [ht,hv] + simpa only [he,he'] using hka j + filter_upwards [ae_all_iff.mpr hfinite,ae_all_iff.mpr hSb,ae_all_iff.mpr hmem] + with a hf hba hma + apply mem_vonNeumann_of_dense_finite_tests (Q a) v + (TopologicalSpace.denseRange_denseSeq H) (T a) b hb + intro m + obtain ⟨k,hk⟩ := hf m + have hevent : ∀ᶠ n in atTop,∀ j : Fin m, + ‖S (k n) a (v j)-T a (v j)‖<1/((m:ℝ)+1) := by + apply eventually_all.mpr + intro j + exact (tendsto_iff_norm_sub_tendsto_zero.mp (hk j)).eventually + (gt_mem_nhds (by positivity : (0:ℝ)<1/((m:ℝ)+1))) + obtain ⟨n,hn⟩ := hevent.exists + exact ⟨S (k n) a,hma (k n),hba (k n),fun j => (hn j).le⟩ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableNorm.lean b/lean/OAI/Analysis/Commutator/DecomposableNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..e818367a7ffa5c49fa06ae0f71cf08f477e772ca --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableNorm.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableOperator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology ComplexOrder InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +lemma l2_norm_sq (f : Lp H 2 μ) : ‖f‖^2=∫ a,‖f a‖^2 ∂μ := by + rw [@norm_sq_eq_re_inner ℂ, L2.inner_def, ←integral_re (L2.integrable_inner f f)] + congr 1 + ext a + exact (norm_sq_eq_re_inner (𝕜:=ℂ) (f a)).symm + +lemma indicator_norm_sq (s : Set Ω) (hs : MeasurableSet s) (hμs : μ s≠⊤) (ξ : H) : + ‖indicatorConstLp 2 hs hμs ξ‖^2=∫ _ in s,‖ξ‖^2 ∂μ := by + classical + rw [l2_norm_sq,←integral_indicator hs] + apply integral_congr_ae + filter_upwards [indicatorConstLp_coeFn (p:=2) (hs:=hs) (hμs:=hμs) (c:=ξ)] with a ha + rw [ha] + by_cases hx : a∈s <;> simp [hx] + +lemma operator_indicator_norm_sq (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) + (s : Set Ω) (hs : MeasurableSet s) (hμs : μ s≠⊤) (ξ : H) : + ‖operator μ T hm hb (indicatorConstLp 2 hs hμs ξ)‖^2=∫ a in s,‖T a ξ‖^2 ∂μ := by + classical + rw [l2_norm_sq,←integral_indicator hs] + apply integral_congr_ae + filter_upwards [operator_ae μ T hm hb (indicatorConstLp 2 hs hμs ξ), + indicatorConstLp_coeFn (p:=2) (hs:=hs) (hμs:=hμs) (c:=ξ)] with a ha hc + rw [ha,hc] + by_cases hx : a∈s <;> simp [hx] + +variable [IsFiniteMeasure μ] + +lemma fixed_vector_ae_bound (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b d : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hd : 0≤d) + (hn : ‖operator μ T hm hb‖≤d) (ξ : H) : + ∀ᵐ a ∂μ,‖T a ξ‖≤d*‖ξ‖ := by + have hmem : MemLp (fun a => T a ξ) 2 μ := by + apply (memLp_const ξ).of_le_mul (hm ξ) + filter_upwards [hb] with a ha + exact ((T a).le_opNorm ξ).trans (mul_le_mul_of_nonneg_right ha (norm_nonneg _)) + have hi := (memLp_two_iff_integrable_sq_norm (hm ξ)).mp hmem + have hle : (fun a => ‖T a ξ‖^2) ≤ᵐ[μ] (fun _ => (d*‖ξ‖)^2) := by + apply ae_le_of_forall_setIntegral_le hi (integrable_const _) + intro s hs hμs + let f := indicatorConstLp 2 hs hμs.ne ξ + have hnorm : ‖operator μ T hm hb f‖≤d*‖f‖ := + ((operator μ T hm hb).le_opNorm f).trans (mul_le_mul_of_nonneg_right hn (norm_nonneg f)) + calc + (∫ a in s,‖T a ξ‖^2 ∂μ)=‖operator μ T hm hb f‖^2 := + (operator_indicator_norm_sq μ T hm hb s hs hμs.ne ξ).symm + _≤(d*‖f‖)^2 := (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hd (norm_nonneg f))).mpr hnorm + _=d^2*(∫ a in s,‖ξ‖^2 ∂μ) := by rw [mul_pow,indicator_norm_sq μ s hs hμs.ne ξ] + _=(∫ a in s,(d*‖ξ‖)^2 ∂μ) := by simp only [mul_pow,integral_const_mul] + filter_upwards [hle] with a ha + exact (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hd (norm_nonneg ξ))).mp ha + +theorem operator_norm_le_iff_ae [TopologicalSpace.SeparableSpace H] + (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b d : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hd : 0≤d) : + ‖operator μ T hm hb‖≤d ↔ ∀ᵐ a ∂μ,‖T a‖≤d := by + constructor + · intro hn + have htest (n : ℕ) := fixed_vector_ae_bound μ T hm hb hd hn (TopologicalSpace.denseSeq H n) + filter_upwards [ae_all_iff.mpr htest] with a ha + apply ContinuousLinearMap.opNorm_le_bound _ hd + intro ξ + exact (TopologicalSpace.denseRange_denseSeq H).induction_on ξ + (isClosed_le (T a).continuous.norm (continuous_const.mul continuous_norm)) (ha) + · exact operator_norm_le μ T hm hb hd + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DecomposableOperator.lean b/lean/OAI/Analysis/Commutator/DecomposableOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..d544c88dbd4367017ec0da5d297a63ba14095f91 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DecomposableOperator.lean @@ -0,0 +1,115 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology ComplexOrder InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +lemma measurable_apply_simple (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) (f : SimpleFunc Ω H) : + AEStronglyMeasurable (fun a => T a (f a)) μ := by + classical + induction f with + | const c => exact hm c + | @pcw f g s hs hf hg => + convert AEStronglyMeasurable.piecewise hs hf.restrict hg.restrict using 1 + funext a + change T a (if a∈s then f a else g a)=(if a∈s then T a (f a) else T a (g a)) + split_ifs <;> rfl + +lemma measurable_apply (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {f : Ω → H} (hf : AEStronglyMeasurable f μ) : + AEStronglyMeasurable (fun a => T a (f a)) μ := by + obtain ⟨s,hs⟩ := hf.stronglyMeasurable_mk + apply aestronglyMeasurable_of_tendsto_ae atTop (fun n => measurable_apply_simple μ T hm (s n)) + filter_upwards [hf.ae_eq_mk] with a ha + rw [ha] + exact (T a).continuous.continuousAt.tendsto.comp (hs a) + +lemma memLp_apply (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (f : Lp H 2 μ) : + MemLp (fun a => T a (f a)) 2 μ := by + apply (Lp.memLp f).of_le_mul (measurable_apply μ T hm (Lp.aestronglyMeasurable f)) + filter_upwards [hb] with a ha + exact ((T a).le_opNorm (f a)).trans (mul_le_mul_of_nonneg_right ha (norm_nonneg _)) + +def act (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (f : Lp H 2 μ) : Lp H 2 μ := + (memLp_apply μ T hm hb f).toLp _ + +lemma act_ae (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (f : Lp H 2 μ) : + act μ T hm hb f =ᵐ[μ] fun a => T a (f a) := MemLp.coeFn_toLp _ + +lemma act_add (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (f g : Lp H 2 μ) : + act μ T hm hb (f+g)=act μ T hm hb f+act μ T hm hb g := by + apply Lp.ext + filter_upwards [act_ae μ T hm hb (f+g),act_ae μ T hm hb f,act_ae μ T hm hb g, + Lp.coeFn_add f g,Lp.coeFn_add (act μ T hm hb f) (act μ T hm hb g)] with a h1 h2 h3 h4 h5 + rw [h1,h4,h5] + change T a (f a+g a)=act μ T hm hb f a+act μ T hm hb g a + rw [map_add,h2,h3] + +lemma act_smul (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (c : ℂ) (f : Lp H 2 μ) : + act μ T hm hb (c • f)=c • act μ T hm hb f := by + apply Lp.ext + filter_upwards [act_ae μ T hm hb (c • f),act_ae μ T hm hb f, + Lp.coeFn_smul c f,Lp.coeFn_smul c (act μ T hm hb f)] with a h1 h2 h3 h4 + simp [h1,h2,h3,h4] + +lemma act_norm_le (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b d : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hd : ∀ᵐ a ∂μ,‖T a‖≤d) (f : Lp H 2 μ) : + ‖act μ T hm hb f‖≤d*‖f‖ := by + apply Lp.norm_le_mul_norm_of_ae_le_mul + filter_upwards [act_ae μ T hm hb f,hd] with a ha hda + rw [ha] + exact ((T a).le_opNorm (f a)).trans (mul_le_mul_of_nonneg_right hda (norm_nonneg _)) + +def operator (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : Lp H 2 μ →L[ℂ] Lp H 2 μ := + ({toFun := act μ T hm hb + map_add' := act_add μ T hm hb + map_smul' := act_smul μ T hm hb} : Lp H 2 μ →ₗ[ℂ] Lp H 2 μ).mkContinuous b + (act_norm_le μ T hm hb hb) + +lemma operator_ae (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (f : Lp H 2 μ) : + operator μ T hm hb f =ᵐ[μ] fun a => T a (f a) := act_ae μ T hm hb f + +lemma operator_norm_le (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b d : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hd0 : 0≤d) (hd : ∀ᵐ a ∂μ,‖T a‖≤d) : + ‖operator μ T hm hb‖≤d := + ContinuousLinearMap.opNorm_le_bound _ hd0 (act_norm_le μ T hm hb hd) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/Definitions.lean b/lean/OAI/Analysis/Commutator/Definitions.lean new file mode 100644 index 0000000000000000000000000000000000000000..542664619a70aa9e79e1345aafe8b679f00c3b41 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/Definitions.lean @@ -0,0 +1,39 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +universe u v + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] + [CompleteSpace K] + +def commutatorSeminorm (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : ℝ := + sSup {r : ℝ | ∃ a : K →L[ℂ] K, a ∈ P ∧ ‖a‖ ≤ 1 ∧ r = ‖Y * a - a * Y‖} + +def matrixOperator (h : ℕ) (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) : + (PiLp 2 fun _ : Fin h => K) →L[ℂ] (PiLp 2 fun _ : Fin h => K) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : Fin h => K)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun i => ∑ j : Fin h, + (X i j).comp (PiLp.proj 2 (fun _ : Fin h => K) j))) + +def diagonalAmplification (h : ℕ) (Y : K →L[ℂ] K) : + (PiLp 2 fun _ : Fin h => K) →L[ℂ] (PiLp 2 fun _ : Fin h => K) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : Fin h => K)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun i => Y.comp (PiLp.proj 2 (fun _ : Fin h => K) i))) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DenseCommutes.lean b/lean/OAI/Analysis/Commutator/DenseCommutes.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed2834dddff7a1fc8a6907eaf8123387c951fa7d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DenseCommutes.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology InnerProductSpace + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma commutes_of_dense_contraction_tests (P : VonNeumannAlgebra H) + (test : ℕ → H →L[ℂ] H) + (hdense : ∀ A : H →L[ℂ] H,A∈P → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) ξ) atTop (𝓝 (A ξ))) + (B : H →L[ℂ] H) (htest : ∀ n,Commute (test n) B) + (A : H →L[ℂ] H) (hA : A∈P) : Commute A B := by + let d : ℂ := ((‖A‖+1:ℝ):ℂ) + have hdR : 0<‖A‖+1 := by positivity + have hd : d≠0 := by + dsimp only [d] + exact_mod_cast (ne_of_gt hdR) + have hdn : ‖d⁻¹ • A‖≤1 := by + rw [norm_smul,norm_inv] + have hnd : ‖d‖=‖A‖+1 := by + dsimp only [d] + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_pos hdR] + rw [hnd] + have hi : (‖A‖+1)⁻¹*‖A‖=‖A‖/(‖A‖+1) := by ring + rw [hi] + exact (div_le_one hdR).mpr (by linarith) + obtain ⟨k,hk⟩ := hdense (d⁻¹ • A) (P.smul_mem hA d⁻¹) hdn + have hlim (x y : H) : Tendsto (fun n => inner ℂ (test (k n) x) y) atTop + (𝓝 (inner ℂ ((d⁻¹ • A) x) y)) := (hk x).inner tendsto_const_nhds + have hc := WeakOperatorLimit.intertwine hlim B B + (Eventually.of_forall (fun n => (htest (k n)).eq)) + have h := congrArg (fun C : H →L[ℂ] H => d • C) hc + change A*B=B*A + simpa only [smul_mul_assoc,mul_smul_comm,smul_smul,mul_inv_cancel₀ hd,one_smul] using h + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DenseFieldClosure.lean b/lean/OAI/Analysis/Commutator/DenseFieldClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..580c5f0b997e046a0f599a76c6784b521d50a827 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DenseFieldClosure.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology InnerProductSpace + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem mem_vonNeumann_of_dense_finite_tests (Q : VonNeumannAlgebra H) + (v : ℕ → H) (hv : DenseRange v) (T : H →L[ℂ] H) (b : ℝ) (hb : 0≤b) + (ha : ∀ m : ℕ,∃ A : H →L[ℂ] H,A∈Q ∧ ‖A‖≤b ∧ + ∀ j : Fin m,‖A (v j)-T (v j)‖≤1/((m:ℝ)+1)) : T∈Q := by + choose A hAQ hAb hA using ha + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ)≤atTop := Ultrafilter.of_le _ + obtain ⟨W,hW,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω A b hb hAb + have hWQ : W∈Q := WeakOperatorLimit.mem_vonNeumann hlim Q (Eventually.of_forall hAQ) + have htest (j : ℕ) : W (v j)=T (v j) := by + have hn : Tendsto (fun m => ‖A m (v j)-T (v j)‖) atTop (𝓝 0) := by + apply squeeze_zero' (Eventually.of_forall (fun _ => norm_nonneg _)) _ + tendsto_one_div_add_atTop_nhds_zero_nat + filter_upwards [eventually_ge_atTop (j+1)] with m hm + exact hA m ⟨j,by omega⟩ + have hl : Tendsto (fun m => A m (v j)) atTop (𝓝 (T (v j))) := + tendsto_iff_norm_sub_tendsto_zero.mpr hn + apply ext_inner_right ℂ + intro y + exact tendsto_nhds_unique (hlim (v j) y) + (((continuous_id.inner continuous_const).tendsto (T (v j))).comp (hl.mono_left hω)) + have he : W=T := ContinuousLinearMap.ext (fun x => hv.induction_on x + (isClosed_eq W.continuous T.continuous) htest) + rwa [he] at hWQ + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DenseRationalStar.lean b/lean/OAI/Analysis/Commutator/DenseRationalStar.lean new file mode 100644 index 0000000000000000000000000000000000000000..e9de06715aa64dfdd291f5a9d9112cd24b7be74e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DenseRationalStar.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.CountablyGeneratedCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +namespace Kadison.DenseRationalStar + +variable (A : Type*) [CStarAlgebra A] [TopologicalSpace.SeparableSpace A] + +local instance denseRationalStarNormedAlgebra : NormedAlgebra ℚ A := + NormedAlgebra.restrictScalars ℚ ℂ A + +local instance denseRationalStarStarModule : StarModule ℚ A where + star_smul r a := by + change star ((r:ℂ) • a)=((star r:ℚ):ℂ) • star a + simp + +theorem exists_dense_countable : ∃ S : StarSubalgebra ℚ A, + Countable S ∧ DenseRange (fun a : S => (a:A)) ∧ Complex.I • (1:A)∈S := by + let s : Set A := Set.range (TopologicalSpace.denseSeq A) ∪ {Complex.I • (1:A)} + have hs : s.Countable := (Set.countable_range _).union (Set.countable_singleton _) + let S := StarAlgebra.adjoin ℚ s + have hms : (Submonoid.closure (s∪star s) : Set A).Countable := + countable_submonoidClosure (hs.union (by simpa only [Set.image_star] using hs.image star)) + let M := Submonoid.closure (s∪star s) + let : Countable M := hms.to_subtype + have hc : (Submodule.span ℚ (M:Set A) : Set A).Countable := by + have hr : Set.range (fun a : M => (a:A))=(M:Set A) := by ext a; simp + have : Countable (Submodule.span ℚ (Set.range (fun a : M => (a:A)))) := inferInstance + rw [←hr] + exact Set.countable_coe_iff.mp inferInstance + have he : (S:Set A)=(Submodule.span ℚ (M:Set A) : Set A) := + congrArg (fun N : Submodule ℚ A => (N:Set A)) (StarAlgebra.adjoin_eq_span (R:=ℚ) s) + have hsc : Countable S := Set.countable_coe_iff.mpr (by rw [he]; exact hc) + refine ⟨S,hsc,?_,StarAlgebra.subset_adjoin ℚ s (Or.inr (Set.mem_singleton _))⟩ + apply denseRange_subtype_val.mpr + apply (TopologicalSpace.denseRange_denseSeq A).mono + intro a ha + exact StarAlgebra.subset_adjoin ℚ s (Or.inl ha) + +end Kadison.DenseRationalStar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DerivationBoundTransfer.lean b/lean/OAI/Analysis/Commutator/DerivationBoundTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..b20845bc9c61237c6024a9643e98aeccc33d8848 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DerivationBoundTransfer.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.DerivationKaplansky +import OAI.Analysis.Commutator.DerivationMatrixColumns +import OAI.Analysis.Commutator.MatrixReindexBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace Topology + +namespace Kadison.DerivationColumns + +open CyclicColumns + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (D : A →L[ℂ] (H →L[ℂ] H)) + (hD : ∀ a b,D (a*b)=(D a).comp (σ b)+(σ a).comp (D b)) + +include hD in +theorem matrix_bound_of_bicommutant_bound {c : ℝ} (hc : 0≤c) + (hP : ∀ (Y : H →L[ℂ] H) (h : ℕ),1≤h → + ∀ X : Matrix (Fin h) (Fin h) (H →L[ℂ] H), + (∀ i j,X i j∈NormalGNS.bicommutant σ.range) → + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant σ.range) Y*‖matrixOperator h X‖) + {ι : Type*} [Fintype ι] (X : CStarMatrix ι ι A) : + ‖matrixAction (fun i j => D (X i j))‖≤c*‖D‖*‖X‖ := by + classical + obtain ⟨Q⟩ := CyclicDecomposition.exists_decomposition σ.range + apply matrix_bound_of_fin D (mul_nonneg hc (norm_nonneg D)) ?_ X + intro h hh X + apply norm_le_of_finite_columns σ Q h _ (mul_nonneg (mul_nonneg hc (norm_nonneg D)) (norm_nonneg X)) + intro s + rw [←finite_matrix_identity σ D hD Q s h X] + have hXm : ∀ i j,σ (X i j)∈NormalGNS.bicommutant σ.range := fun i j => + NormalGNS.subset_bicommutant σ.range (Set.mem_range_self (X i j)) + have hb := hP (finiteImplementer σ D hD Q s) h hh (fun i j => σ (X i j)) hXm + change ‖diagonalAmplification h (finiteImplementer σ D hD Q s)*matrixRepresentation σ X- + matrixRepresentation σ X*diagonalAmplification h (finiteImplementer σ D hD Q s)‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant σ.range) (finiteImplementer σ D hD Q s)*‖matrixRepresentation σ X‖ at hb + exact hb.trans (mul_le_mul + (mul_le_mul_of_nonneg_left (finite_seminorm_bound σ D hD Q s) hc) + (matrixRepresentation_norm_le σ X) (norm_nonneg _) (mul_nonneg hc (norm_nonneg D))) + +include hD in +theorem implementation_of_bicommutant_bound {c : ℝ} (hc : 0≤c) + (hP : ∀ (Y : H →L[ℂ] H) (h : ℕ),1≤h → + ∀ X : Matrix (Fin h) (Fin h) (H →L[ℂ] H), + (∀ i j,X i j∈NormalGNS.bicommutant σ.range) → + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant σ.range) Y*‖matrixOperator h X‖) : + ∃ V : H →L[ℂ] H,‖V‖≤(1+c)^2*‖D‖ ∧ ∀ a : A,D a=V.comp (σ a)-(σ a).comp V := + CbFactor.rectangular_implementation_quantitative σ σ D hD hc + (fun _ _ X => matrix_bound_of_bicommutant_bound σ D hD hc hP X) + +end Kadison.DerivationColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DerivationCyclicColumns.lean b/lean/OAI/Analysis/Commutator/DerivationCyclicColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..9905ab7e9f8a133e36ac90ee24094ba3997a3b47 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DerivationCyclicColumns.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.Commutator.CbDerivationQuantitative +import OAI.Analysis.Commutator.CyclicDecomposition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace Topology + +open Filter + +namespace Kadison.DerivationColumns + +open ReducingRepresentation CyclicDecomposition + +variable {A H : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +abbrev Cyclic (ξ : H) := cyclicSubspace σ.range ξ + +theorem invariant (ξ : H) : ∀ (a : A) (x : H),x∈Cyclic σ ξ → σ a x∈Cyclic σ ξ := + fun a => cyclicSubspace_invariant σ.range ξ (Set.mem_range_self a) + +lemma cyclic_dense (ξ : H) : DenseRange (fun a : A => + restrict σ (Cyclic σ ξ) (invariant σ ξ) a ⟨ξ,mem_cyclicSubspace_self σ.range ξ⟩) := by + let K := Cyclic σ ξ + let act : A → K := fun a => ⟨σ a ξ,invariant σ ξ a ξ (mem_cyclicSubspace_self σ.range ξ)⟩ + have hi : (Subtype.val : K → H) '' Set.range act=(orbitSubmodule σ.range ξ : Set H) := by + ext x + constructor + · rintro ⟨_,⟨a,rfl⟩,rfl⟩ + exact ⟨σ a,Set.mem_range_self a,rfl⟩ + · rintro ⟨_,⟨a,rfl⟩,rfl⟩ + exact ⟨act a,⟨a,rfl⟩,rfl⟩ + intro x + change x∈closure (Set.range act) + rw [Topology.IsEmbedding.subtypeVal.closure_eq_preimage_closure_image,hi] + exact x.property + +variable (D : A →L[ℂ] (H →L[ℂ] H)) + (hD : ∀ a b,D (a*b)=(D a).comp (σ b)+(σ a).comp (D b)) + +local instance {K : Type*} [NormedAddCommGroup K] [NormedSpace ℂ K] : + NormedAddCommGroup (K →L[ℂ] H) := ContinuousLinearMap.toNormedAddCommGroup + +local instance {K : Type*} [NormedAddCommGroup K] [NormedSpace ℂ K] : + NormedSpace ℂ (K →L[ℂ] H) := ContinuousLinearMap.toNormedSpace + +def restrictDerivation (ξ : H) : A →L[ℂ] (Cyclic σ ξ →L[ℂ] H) := + ((ContinuousLinearMap.compL ℂ (Cyclic σ ξ) H H).flip (Cyclic σ ξ).subtypeL).comp D + +@[simp] lemma restrictDerivation_apply (ξ : H) (a : A) : + restrictDerivation σ D ξ a=(D a).comp (Cyclic σ ξ).subtypeL := rfl + +include hD in +lemma restrictDerivation_mul (ξ : H) (a b : A) : + restrictDerivation σ D ξ (a*b)=(restrictDerivation σ D ξ a).comp (restrict σ (Cyclic σ ξ) (invariant σ ξ) b)+ + (σ a).comp (restrictDerivation σ D ξ b) := by + ext x + simp only [restrictDerivation_apply,hD,ContinuousLinearMap.comp_apply,_root_.add_apply] + rfl + +variable [PartialOrder A] [StarOrderedRing A] + +include hD in +theorem exists_column (ξ : H) : ∃ V : Cyclic σ ξ →L[ℂ] H,∀ a : A, + (D a).comp (Cyclic σ ξ).subtypeL=V.comp (restrict σ (Cyclic σ ξ) (invariant σ ξ) a)-(σ a).comp V := by + obtain ⟨V,_,hV⟩ := CbFactor.cyclic_implementation + (restrict σ (Cyclic σ ξ) (invariant σ ξ)) σ (restrictDerivation σ D ξ) + (restrictDerivation_mul σ D hD ξ) ⟨ξ,mem_cyclicSubspace_self σ.range ξ⟩ (cyclic_dense σ ξ) + exact ⟨V,hV⟩ + +def column (ξ : H) : Cyclic σ ξ →L[ℂ] H := (exists_column σ D hD ξ).choose + +lemma column_spec (ξ : H) (a : A) : + (D a).comp (Cyclic σ ξ).subtypeL=(column σ D hD ξ).comp (restrict σ (Cyclic σ ξ) (invariant σ ξ) a)- + (σ a).comp (column σ D hD ξ) := (exists_column σ D hD ξ).choose_spec a + +lemma column_commutator (ξ : H) (a : A) : + extendZero (K:=Cyclic σ ξ) (column σ D hD ξ)*σ a- + σ a*extendZero (K:=Cyclic σ ξ) (column σ D hD ξ)=D a*(Cyclic σ ξ).starProjection := by + ext x + have hh := congrArg (fun L : Cyclic σ ξ →L[ℂ] H => L ((Cyclic σ ξ).orthogonalProjectionOnto x)) + (column_spec σ D hD ξ a) + simp only [ContinuousLinearMap.comp_apply,_root_.sub_apply] at hh + change column σ D hD ξ ((Cyclic σ ξ).orthogonalProjectionOnto (σ a x))- + σ a (column σ D hD ξ ((Cyclic σ ξ).orthogonalProjectionOnto x))=D a ((Cyclic σ ξ).starProjection x) + rw [project_intertwines σ (Cyclic σ ξ) (invariant σ ξ)] + exact hh.symm + +variable (Q : Decomposition σ.range) + +def finiteProjection (s : Finset Q.I) : H →L[ℂ] H := ∑ i∈s,(Cyclic σ (Q.ξ i)).starProjection + +def finiteImplementer (s : Finset Q.I) : H →L[ℂ] H := ∑ i∈s,extendZero (K:=Cyclic σ (Q.ξ i)) (column σ D hD (Q.ξ i)) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma finiteProjection_projection (s : Finset Q.I) : IsStarProjection (finiteProjection σ Q s) := by + classical + constructor + · change (∑ i∈s,(Cyclic σ (Q.ξ i)).starProjection)*(∑ i∈s,(Cyclic σ (Q.ξ i)).starProjection)=_ + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · exact (isStarProjection_starProjection (U:=Cyclic σ (Q.ξ i))).isIdempotentElem.eq + · intro j hj hne + exact Q.cross i j hne.symm + · change star (∑ i∈s,(Cyclic σ (Q.ξ i)).starProjection)=_ + rw [star_sum] + exact Finset.sum_congr rfl (fun i hi => (isStarProjection_starProjection (U:=Cyclic σ (Q.ξ i))).isSelfAdjoint.star_eq) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma finiteProjection_norm_le (s : Finset Q.I) : ‖finiteProjection σ Q s‖≤1 := + (finiteProjection_projection σ Q s).norm_le _ + +lemma finite_column_identity (s : Finset Q.I) (a : A) : + finiteImplementer σ D hD Q s*σ a-σ a*finiteImplementer σ D hD Q s=D a*finiteProjection σ Q s := by + simp only [finiteImplementer,finiteProjection,Finset.sum_mul,Finset.mul_sum,←Finset.sum_sub_distrib] + exact Finset.sum_congr rfl (fun i hi => column_commutator σ D hD (Q.ξ i) a) + +lemma finite_scalar_bound (s : Finset Q.I) (a : A) : + ‖finiteImplementer σ D hD Q s*σ a-σ a*finiteImplementer σ D hD Q s‖≤‖D‖*‖a‖ := by + rw [finite_column_identity] + calc + _≤‖D a‖*‖finiteProjection σ Q s‖ := norm_mul_le _ _ + _≤‖D a‖*1 := mul_le_mul_of_nonneg_left (finiteProjection_norm_le σ Q s) (norm_nonneg _) + _≤‖D‖*‖a‖ := by simpa using D.le_opNorm a + +end Kadison.DerivationColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DerivationKaplansky.lean b/lean/OAI/Analysis/Commutator/DerivationKaplansky.lean new file mode 100644 index 0000000000000000000000000000000000000000..4773f0517d6edbd8baa600ca14aaac988298f648 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DerivationKaplansky.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicDecomposition +import OAI.Analysis.Commutator.Definitions +import OAI.Analysis.Commutator.DerivationCyclicColumns +import OAI.Analysis.Commutator.KaplanskyFullRange +import OAI.Analysis.Commutator.MatrixTowerGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace Topology + +open Filter + +namespace Kadison.DerivationColumns + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +theorem seminorm_bicommutant_le (Y : H →L[ℂ] H) {c : ℝ} (hc : 0≤c) + (hY : ∀ a : A,‖Y*σ a-σ a*Y‖≤c*‖a‖) : + commutatorSeminorm (NormalGNS.bicommutant σ.range) Y≤c := by + classical + change sSup {r : ℝ | ∃ T : H →L[ℂ] H,T∈NormalGNS.bicommutant σ.range ∧ ‖T‖≤1 ∧ r=‖Y*T-T*Y‖}≤c + refine csSup_le ⟨0,0,zero_mem _,by simp,by simp⟩ ?_ + rintro r ⟨T,hT,hnT,rfl⟩ + have hTb := (NormalGNS.mem_bicommutant σ.range T).mp hT + apply ContinuousLinearMap.opNorm_le_bound _ hc + intro x + have ht := ((Y.continuous.tendsto (T x)).comp + (Kaplansky.fullNet_tendsto σ T hTb hnT x)).sub + (Kaplansky.fullNet_tendsto σ T hTb hnT (Y x)) + change Tendsto (fun j => (Y*σ (Kaplansky.fullNet σ T hTb hnT j)- + σ (Kaplansky.fullNet σ T hTb hnT j)*Y) x) atTop (𝓝 ((Y*T-T*Y) x)) at ht + apply le_of_tendsto ht.norm + apply Filter.Eventually.of_forall + intro j + calc + _≤‖Y*σ (Kaplansky.fullNet σ T hTb hnT j)-σ (Kaplansky.fullNet σ T hTb hnT j)*Y‖*‖x‖ := + ContinuousLinearMap.le_opNorm _ _ + _≤(c*‖Kaplansky.fullNet σ T hTb hnT j‖)*‖x‖ := + mul_le_mul_of_nonneg_right (hY _) (norm_nonneg x) + _≤c*‖x‖ := by + have hn := (Kaplansky.fullNet_spec σ T hTb hnT j).1 + exact mul_le_mul_of_nonneg_right ((mul_le_mul_of_nonneg_left hn hc).trans_eq (mul_one c)) (norm_nonneg x) + +variable (D : A →L[ℂ] (H →L[ℂ] H)) + (hD : ∀ a b,D (a*b)=(D a).comp (σ b)+(σ a).comp (D b)) + (Q : CyclicDecomposition.Decomposition σ.range) + +lemma finite_seminorm_bound (s : Finset Q.I) : + commutatorSeminorm (NormalGNS.bicommutant σ.range) (finiteImplementer σ D hD Q s)≤‖D‖ := + seminorm_bicommutant_le σ _ (norm_nonneg D) (finite_scalar_bound σ D hD Q s) + +end Kadison.DerivationColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DerivationMatrixColumns.lean b/lean/OAI/Analysis/Commutator/DerivationMatrixColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..b6ff6e28effb7a03e1083f4836ea0777fa6c4ab2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DerivationMatrixColumns.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Commutator.DerivationCyclicColumns +import OAI.Analysis.Commutator.MainMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace Topology + +open Filter + +namespace Kadison.DerivationColumns + +open CyclicColumns CyclicDecomposition + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (D : A →L[ℂ] (H →L[ℂ] H)) + (hD : ∀ a b,D (a*b)=(D a).comp (σ b)+(σ a).comp (D b)) + (Q : Decomposition σ.range) + +lemma finite_matrix_identity (s : Finset Q.I) (h : ℕ) (X : CStarMatrix (Fin h) (Fin h) A) : + diagonalAmplification h (finiteImplementer σ D hD Q s)*matrixRepresentation σ X- + matrixRepresentation σ X*diagonalAmplification h (finiteImplementer σ D hD Q s)= + matrixAction (fun i j => D (X i j))*diagonalAmplification h (finiteProjection σ Q s) := by + ext x i + change (diagonalAmplification h (finiteImplementer σ D hD Q s) + (matrixAction (fun i j => σ (X i j)) x)) i- + (matrixAction (fun i j => σ (X i j)) (diagonalAmplification h (finiteImplementer σ D hD Q s) x)) i=_ + simp only [mul_apply_eq_comp,diagonalAmplification_apply,matrixAction_apply,map_sum,←Finset.sum_sub_distrib] + apply Finset.sum_congr rfl + intro j hj + exact congrArg (fun L : H →L[ℂ] H => L (x j)) (finite_column_identity σ D hD Q s (X i j)) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma finiteProjection_strong (h : ℕ) (x : PiLp 2 (fun _ : Fin h => H)) : + Tendsto (fun s : Finset Q.I => diagonalAmplification h (finiteProjection σ Q s) x) atTop (𝓝 x) := by + have ht : Tendsto (fun s : Finset Q.I => fun i : Fin h => finiteProjection σ Q s (x i)) + atTop (𝓝 (fun i : Fin h => x i)) := tendsto_pi_nhds.mpr (fun i => Q.strong (x i)) + have hconv := ((PiLp.homeomorph 2 (fun _ : Fin h => H)).symm.continuous.tendsto + (fun i : Fin h => x i)).comp ht + have he (s : Finset Q.I) : (PiLp.homeomorph 2 (fun _ : Fin h => H)).symm + (fun i => finiteProjection σ Q s (x i))=diagonalAmplification h (finiteProjection σ Q s) x := by + ext i + rfl + have hx : (PiLp.homeomorph 2 (fun _ : Fin h => H)).symm (fun i => x i)=x := by + ext i + rfl + simpa only [Function.comp_def,he,hx] using hconv + +omit [PartialOrder A] [StarOrderedRing A] in +lemma norm_le_of_finite_columns (h : ℕ) (T : PiLp 2 (fun _ : Fin h => H) →L[ℂ] PiLp 2 (fun _ : Fin h => H)) + {c : ℝ} (hc : 0≤c) + (hT : ∀ s : Finset Q.I,‖T*diagonalAmplification h (finiteProjection σ Q s)‖≤c) : + ‖T‖≤c := by + apply ContinuousLinearMap.opNorm_le_bound _ hc + intro x + have ht := (T.continuous.tendsto x).comp (finiteProjection_strong σ Q h x) + apply le_of_tendsto ht.norm + apply Filter.Eventually.of_forall + intro s + exact ((T*diagonalAmplification h (finiteProjection σ Q s)).le_opNorm x).trans + (mul_le_mul_of_nonneg_right (hT s) (norm_nonneg x)) + +end Kadison.DerivationColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiagonalBlockCommutant.lean b/lean/OAI/Analysis/Commutator/DiagonalBlockCommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..9f7e8400422a925a3f0968d2965a4aa4d95a1cfd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiagonalBlockCommutant.lean @@ -0,0 +1,43 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.HilbertBiprodProjections + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.HilbertBiprod + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable {A : Type*} [CStarAlgebra A] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + +variable (h : Set.centralizer (Set.centralizer (Set.range (diagHom φ ψ)))=Set.range (diagHom φ ψ)) + +lemma left_mem_diagonal_commutant : + left (H:=H) (G:=G)∈(BicommutantRange.ofStarHom (H:=Space H G) (diagHom φ ψ) h).commutant := by + rw [←SetLike.mem_coe,VonNeumannAlgebra.coe_commutant] + rintro _ ⟨a,rfl⟩ + exact left_commutes _ _ + +lemma right_mem_diagonal_commutant : + right (H:=H) (G:=G)∈(BicommutantRange.ofStarHom (H:=Space H G) (diagHom φ ψ) h).commutant := by + rw [←SetLike.mem_coe,VonNeumannAlgebra.coe_commutant] + rintro _ ⟨a,rfl⟩ + exact right_commutes _ _ + +end Kadison.HilbertBiprod + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiagonalCommute.lean b/lean/OAI/Analysis/Commutator/DiagonalCommute.lean new file mode 100644 index 0000000000000000000000000000000000000000..086e1b894676086a028cc9f8a06e3e07d00bf270 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiagonalCommute.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.PointwiseLinearLift +import OAI.Analysis.Commutator.ScalarIndicator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma operator_commutes_indicator (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (s : Set Ω) (hs : MeasurableSet s) : + Commute (operator μ T hm hb) (indicatorOperator μ s hs) := by + classical + change operator μ T hm hb*indicatorOperator μ s hs= + indicatorOperator μ s hs*operator μ T hm hb + apply ContinuousLinearMap.ext + intro f + apply Lp.ext + filter_upwards [operator_ae μ T hm hb (indicatorOperator μ s hs f), + indicatorOperator_ae μ s hs f,indicatorOperator_ae μ s hs (operator μ T hm hb f), + operator_ae μ T hm hb f] with a ha hi hi' ha' + change operator μ T hm hb (indicatorOperator μ s hs f) a= + indicatorOperator μ s hs (operator μ T hm hb f) a + rw [ha,hi,hi'] + by_cases hx : a∈s + · simp only [Set.indicator_of_mem hx,ha'] + · simp [hx] + +variable [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem exists_field_of_commutes_indicator (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (hcomm : ∀ (s : Set Ω) (hs : MeasurableSet s),Commute Y (indicatorOperator μ s hs)) : + ∃ (T : Ω → H →L[ℂ] H) (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hb : ∀ᵐ a ∂μ,‖T a‖≤‖Y‖),Y=operator μ T hm hb := by + let A := Y.comp (Lp.constL 2 μ ℂ) + have hA : ∀ ξ : H,∀ᵐ a ∂μ,‖A ξ a‖≤‖Y‖*‖ξ‖ := fun ξ => + local_constant_ae_bound μ Y hcomm ξ + let T := PointwiseLift.field μ A ‖Y‖ + have hm := PointwiseLift.field_measurable μ A ‖Y‖ (norm_nonneg Y) hA + have hb : ∀ᵐ a ∂μ,‖T a‖≤‖Y‖ := Eventually.of_forall + (PointwiseLift.field_norm_le μ A ‖Y‖ (norm_nonneg Y)) + let M := operator μ T hm hb + have he (ξ : H) : M (Lp.const 2 μ ξ)=Y (Lp.const 2 μ ξ) := by + apply Lp.ext + filter_upwards [operator_ae μ T hm hb (Lp.const 2 μ ξ), + Lp.coeFn_const (p:=2) (μ:=μ) (c:=ξ), + PointwiseLift.field_ae μ A ‖Y‖ (norm_nonneg Y) hA ξ] with a ha hc hf + change M (Lp.const 2 μ ξ) a=T a ((Lp.const 2 μ ξ) a) at ha + change T a ξ=Y (Lp.const 2 μ ξ) a at hf + rw [ha,hc] + exact hf + have hM : M=Y := by + apply ContinuousLinearMap.ext + intro f + apply Lp.induction (by norm_num : (2:ENNReal)≠⊤) (fun f => M f=Y f) + · intro ξ s hs hμs + rw [Lp.simpleFunc.coe_indicatorConst,←indicatorOperator_const μ s hs ξ] + calc + M (indicatorOperator μ s hs (Lp.const 2 μ ξ))= + indicatorOperator μ s hs (M (Lp.const 2 μ ξ)) := + congrArg (fun B : Lp H 2 μ →L[ℂ] Lp H 2 μ => B (Lp.const 2 μ ξ)) + (operator_commutes_indicator μ T hm hb s hs).eq + _=indicatorOperator μ s hs (Y (Lp.const 2 μ ξ)) := by rw [he] + _=Y (indicatorOperator μ s hs (Lp.const 2 μ ξ)) := + congrArg (fun B : Lp H 2 μ →L[ℂ] Lp H 2 μ => B (Lp.const 2 μ ξ)) (hcomm s hs).eq.symm + · intro f g hf hg hd hMf hMg + simp only [map_add,hMf,hMg] + · exact isClosed_eq M.continuous Y.continuous + exact ⟨T,hm,hb,hM.symm⟩ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiagonalField.lean b/lean/OAI/Analysis/Commutator/DiagonalField.lean new file mode 100644 index 0000000000000000000000000000000000000000..39d896fe25e00dc741575cb1c590d1c9068b81af --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiagonalField.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.L2FiniteSum +import OAI.Analysis.Commutator.MainCommutantDistance +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma diagonal_field_measurable (h : ℕ) (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (ξ : PiLp 2 (fun _ : Fin h => H)) : + AEStronglyMeasurable (fun a => diagonalAmplification h (T a) ξ) μ := by + classical + have eqn (a) : diagonalAmplification h (T a) ξ= + ∑ i,OperatorAmplification.single (Fin h) i (T a (ξ i)) := by + ext i + simp [diagonalAmplification_apply,OperatorAmplification.single_apply] + simp_rw [eqn] + exact Finset.aestronglyMeasurable_fun_sum _ (fun i _ => + (OperatorAmplification.single (Fin h) i).continuous.comp_aestronglyMeasurable (hm (ξ i))) + +omit [CompleteSpace H] in +lemma diagonal_field_bound (h : ℕ) (T : Ω → H →L[ℂ] H) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : + ∀ᵐ a ∂μ,‖diagonalAmplification h (T a)‖≤b := by + filter_upwards [hb] with a ha + exact (diagonalAmplification_norm_le h (T a)).trans ha + +omit [CompleteSpace H] in +lemma assemble_diagonal_ae (h : ℕ) (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) + (f : PiLp 2 (fun _ : Fin h => Lp H 2 μ)) : + assemble μ (diagonalAmplification h (operator μ T hm hb) f)=ᵐ[μ] + fun a => diagonalAmplification h (T a) (assemble μ f a) := by + have he : ∀ᵐ a ∂μ,∀ i,operator μ T hm hb (f i) a=T a (f i a) := + ae_all_iff.mpr (fun i => operator_ae μ _ _ _ (f i)) + filter_upwards [assemble_ae μ (diagonalAmplification h (operator μ T hm hb) f), + assemble_ae μ f,he] with a ha hf he + rw [ha,hf] + ext i + exact he i + +lemma diagonal_conjugate (h : ℕ) (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : + (finiteSumEquiv μ).conjStarAlgEquiv (diagonalAmplification h (operator μ T hm hb))= + operator μ (fun a => diagonalAmplification h (T a)) + (diagonal_field_measurable μ h T hm) (diagonal_field_bound μ h T hb) := by + apply operator_eq_of_ae_apply + intro f + have hh := assemble_diagonal_ae μ h T hm hb ((finiteSumEquiv μ).symm f) + change (assemble μ (diagonalAmplification h (operator μ T hm hb) + ((finiteSumEquiv μ).symm f))) =ᵐ[μ] _ + convert hh using 1 + rw [show assemble μ ((finiteSumEquiv μ).symm f)=f from (finiteSumEquiv μ).apply_symm_apply f] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiagonalVonNeumann.lean b/lean/OAI/Analysis/Commutator/DiagonalVonNeumann.lean new file mode 100644 index 0000000000000000000000000000000000000000..1f320ce2680b6ee02a88324396904a665357a3d3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiagonalVonNeumann.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +def matrixUnit (i j : ι) : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι := + (single ι i).comp (PiLp.proj 2 (fun _ : ι => H) j) + +omit [CompleteSpace H] [Fintype ι] in +@[simp] lemma matrixUnit_apply (i j : ι) (x : SumSpace (H:=H) ι) : + matrixUnit ι i j x=single ι i (x j) := rfl + +omit [CompleteSpace H] [Fintype ι] in +lemma matrixUnit_single (i j : ι) (x : H) : + matrixUnit ι i j (single ι j x)=single ι i x := by + simp + +lemma matrixUnit_commutes (i j : ι) (T : H →L[ℂ] H) : + matrixUnit ι (H:=H) i j*diagonal (H:=H) ι T= + diagonal (H:=H) ι T*matrixUnit ι i j := by + ext x k + simp [mul_apply_eq_comp,diagonal_single] + +lemma diagonal_of_matrixUnits (i₀ : ι) (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (hT : ∀ i j, matrixUnit ι i j*T=T*matrixUnit ι i j) : + T=diagonal (H:=H) ι (entry ι T i₀ i₀) := by + have hs : ∀ j x, T (single ι j x)=single ι j (entry ι T i₀ i₀ x) := by + intro j x + have he := congrArg (fun R : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι => R (single ι i₀ x)) (hT j i₀) + simpa [mul_apply_eq_comp,entry_apply] using he.symm + ext x j + conv_lhs => rw [←sum_single ι x] + simp only [map_sum,hs] + simp + +def diagonalVonNeumann (i₀ : ι) (M : VonNeumannAlgebra H) : VonNeumannAlgebra (SumSpace (H:=H) ι) where + toStarSubalgebra := M.toStarSubalgebra.map (diagonal (H:=H) ι) + centralizer_centralizer' := by + ext T + constructor + · intro hT + have hU : ∀ i j, matrixUnit ι i j*T=T*matrixUnit ι i j := by + intro i j + apply hT + rintro R ⟨a,ha,rfl⟩ + exact (matrixUnit_commutes ι i j a).symm + let a := entry ι T i₀ i₀ + have he : T=diagonal (H:=H) ι a := diagonal_of_matrixUnits ι i₀ T hU + have ha : a∈M := by + rw [←SetLike.mem_coe,←M.centralizer_centralizer] + intro b hb + apply entry_commutes ι T b + apply hT + rintro R ⟨d,hd,rfl⟩ + have hh : d*b=b*d := hb d hd + change diagonal (H:=H) ι d * diagonal (H:=H) ι b = + diagonal (H:=H) ι b * diagonal (H:=H) ι d + exact (map_mul (diagonal (H:=H) ι) d b).symm.trans + ((congrArg (diagonal (H:=H) ι) hh).trans (map_mul (diagonal (H:=H) ι) b d)) + exact ⟨a,ha,he.symm⟩ + · rintro ⟨a,ha,rfl⟩ + apply diagonal_bicommutant ι M.toStarSubalgebra + change a ∈ Set.centralizer (Set.centralizer (M : Set (H →L[ℂ] H))) + rw [M.centralizer_centralizer] + exact ha + +@[simp] lemma mem_diagonalVonNeumann (i₀ : ι) (M : VonNeumannAlgebra H) + (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) : + T∈diagonalVonNeumann ι i₀ M ↔ ∃ a∈M,diagonal (H:=H) ι a=T := Iff.rfl + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiffuseHalving.lean b/lean/OAI/Analysis/Commutator/DiffuseHalving.lean new file mode 100644 index 0000000000000000000000000000000000000000..70d68b4eba2c2193c60bb0976bf4361618431c1c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiffuseHalving.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.FactorComparison +import OAI.Analysis.Commutator.SquareZeroMaximal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem diffuse_halving (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) + {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) : + ∃ v : Link M e e, v.val*v.val=0 ∧ v.initial+v.final=e := by + classical + obtain ⟨v,hmax⟩ := exists_maximal_squareZero M he + refine ⟨v.val,v.property,?_⟩ + have hpq := v.val.initial_mul_final_eq_zero v.property + have hsum : IsStarProjection (v.val.initial+v.val.final) := + v.val.initial_projection.add v.val.final_projection hpq + have hsume : v.val.initial+v.val.final≤e := by + apply (hsum.le_iff_mul_eq_right he).mpr + rw [mul_add,(v.val.initial_projection.le_iff_mul_eq_right he).mp v.val.source_le, + (v.val.final_projection.le_iff_mul_eq_right he).mp v.val.target_le] + let r := e-(v.val.initial+v.val.final) + have hr : IsStarProjection r := hsum.sub_of_mul_eq_left he + ((hsum.le_iff_mul_eq_left he).mp hsume) + have hrM : r∈M := M.sub_mem heM (M.add_mem + (M.mul_mem (M.star_mem' v.val.mem) v.val.mem) + (M.mul_mem v.val.mem (M.star_mem' v.val.mem))) + by_contra hn + have hrn : r≠0 := fun hz => hn (sub_eq_zero.mp hz).symm + obtain ⟨a,haM,ha,han,har,hle⟩ := hd r hrM hr hrn + have hrr : IsStarProjection (r-a) := ha.sub_of_mul_eq_left hr + ((ha.le_iff_mul_eq_left hr).mp hle) + have hrrn : r-a≠0 := fun hz => har (sub_eq_zero.mp hz).symm + obtain ⟨w,hwM,hwn,hwt,hwi,hwf⟩ := FactorCorner.exists_linking_partialIsometry M hM + haM (M.sub_mem hrM haM) ha hrr han hrrn + let w₀ : Link M a (r-a) := ⟨w,hwM,hwt,hwi,hwf⟩ + have hww : w*w=0 := by + have har0 : a*(r-a)=0 := by + rw [mul_sub,(ha.le_iff_mul_eq_left hr).mp hle,ha.isIdempotentElem.eq,sub_self] + calc + _=(w*a)*((r-a)*w) := by rw [w₀.mul_source ha,w₀.target_mul hrr] + _=0 := by rw [mul_assoc,←mul_assoc a,har0,zero_mul,mul_zero] + have hir : star w*w≤r := hwi.trans hle + have hfr : w*star w≤r := hwf.trans (sub_le_self r ha.nonneg) + let wr : Link M r r := ⟨w,hwM,hwt,hir,hfr⟩ + have hie : r≤e-v.val.initial := sub_le_sub_left + (le_add_of_nonneg_right v.val.final_projection.nonneg) e + have hfe : r≤e-v.val.final := sub_le_sub_left + (le_add_of_nonneg_left v.val.initial_projection.nonneg) e + let w' : Link M (e-v.val.initial) (e-v.val.final) := + ⟨w,hwM,hwt,hir.trans hie,hfr.trans hfe⟩ + have hvr : v.val.val*r=0 := by + change v.val.val*(e-(v.val.initial+v.val.final))=0 + rw [mul_sub,mul_add,v.val.mul_source he,v.val.mul_initial, + v.val.self_mul_final_eq_zero v.property,add_zero,sub_self] + have hrv : r*v.val.val=0 := by + change (e-(v.val.initial+v.val.final))*v.val.val=0 + rw [sub_mul,add_mul,v.val.target_mul he,v.val.initial_mul_self_eq_zero v.property, + v.val.final_mul,zero_add,sub_self] + have hvw : v.val.val*w=0 := by + calc + _=v.val.val*(r*w) := by rw [wr.target_mul hr] + _=0 := by rw [←mul_assoc,hvr,zero_mul] + have hwv : w*v.val.val=0 := by + calc + _=(w*r)*v.val.val := by rw [wr.mul_source hr] + _=0 := by rw [mul_assoc,hrv,mul_zero] + let u : SquareZeroLink M e := ⟨v.val.extend he he w',by + change (v.val.val+w)*(v.val.val+w)=0 + rw [add_mul,mul_add,mul_add,v.property,hvw,hwv,hww,zero_add,zero_add]⟩ + have hvu : v≤u := v.val.le_extend he he w' + have heq : u=v := le_antisymm (hmax hvu) hvu + have hval := congrArg (fun z : SquareZeroLink M e => z.val.val) heq + change v.val.val+w=v.val.val at hval + exact hwn (add_left_cancel (hval.trans (add_zero v.val.val).symm)) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DiffuseProjection.lean b/lean/OAI/Analysis/Commutator/DiffuseProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..9f3533783eecda77308020b9cf6196d5aca7bd7f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DiffuseProjection.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionChains + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.DiffuseProjection + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def HasNoMinimalProjections (M : VonNeumannAlgebra H) : Prop := + ∀ p∈M, IsStarProjection p → p≠0 → + ∃ q∈M, IsStarProjection q ∧ q≠0 ∧ q≠p ∧ q≤p + +variable (M : VonNeumannAlgebra H) (τ : (H →L[ℂ] H) →ₚ[ℂ] ℂ) + +variable (hM : HasNoMinimalProjections M) + +include hM + +lemma exists_half {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) (hpn : p≠0) : + ∃ q∈M, IsStarProjection q ∧ q≠0 ∧ q≤p ∧ (τ q).re≤(τ p).re/2 := by + obtain ⟨q,hqM,hq,hqn,hqp,hqle⟩ := hM p hpM hp hpn + by_cases hsmall : (τ q).re≤(τ p).re/2 + · exact ⟨q,hqM,hq,hqn,hqle,hsmall⟩ + · have hr : IsStarProjection (p-q) := hq.sub_of_mul_eq_left hp + ((hq.le_iff_mul_eq_left hp).mp hqle) + refine ⟨p-q,M.sub_mem hpM hqM,hr,?_,?_,?_⟩ + · exact fun h => hqp (sub_eq_zero.mp h).symm + · exact sub_le_self p hq.nonneg + · rw [map_sub,Complex.sub_re] + linarith + +lemma exists_geometric {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) (hpn : p≠0) + (n : ℕ) : ∃ q∈M, IsStarProjection q ∧ q≠0 ∧ q≤p ∧ (τ q).re≤(1/2:ℝ)^n*(τ p).re := by + induction n with + | zero => exact ⟨p,hpM,hp,hpn,le_rfl,by simp⟩ + | succ n ih => + obtain ⟨q,hqM,hq,hqn,hqle,hqtrace⟩ := ih + obtain ⟨r,hrM,hr,hrn,hrle,hrtrace⟩ := exists_half M τ hM hqM hq hqn + refine ⟨r,hrM,hr,hrn,hrle.trans hqle,?_⟩ + rw [pow_succ] + nlinarith + +theorem exists_small {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) (hpn : p≠0) + {ε : ℝ} (hε : 0<ε) : ∃ q∈M, IsStarProjection q ∧ q≠0 ∧ q≤p ∧ (τ q).re<ε := by + have hlim : 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)).mul_const (τ p).re + obtain ⟨n,hn⟩ := (hlim.eventually_lt_const hε).exists + obtain ⟨q,hqM,hq,hqn,hqle,hqtrace⟩ := exists_geometric M τ hM hpM hp hpn n + exact ⟨q,hqM,hq,hqn,hqle,hqtrace.trans_lt hn⟩ + +theorem exists_prescribed_trace + (hτ : Continuous (fun T : H →WOT[ℂ] H => (τ T.toCLM).re)) + {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) + {t : ℝ} (ht : 0≤t) (hte : t≤(τ e).re) : + ∃ p∈M, IsStarProjection p ∧ p≤e ∧ (τ p).re=t := by + let p0 : ProjectionChains.TraceCut M τ e t := + ⟨0,M.zero_mem,IsStarProjection.zero _,he.nonneg,by simpa using ht⟩ + let : Nonempty (ProjectionChains.TraceCut M τ e t) := ⟨p0⟩ + obtain ⟨p,hmax⟩ := zorn_le_nonempty + (ProjectionChains.cut_chain_upper M τ e t he hτ) + have hpM := p.property.1 + have hp := p.property.2.1 + have hpe := p.property.2.2.1 + have hpt := p.property.2.2.2 + refine ⟨p.val,hpM,hp,hpe,?_⟩ + apply le_antisymm hpt + by_contra! hlt + have hres : IsStarProjection (e-p.val) := hp.sub_of_mul_eq_left he + ((hp.le_iff_mul_eq_left he).mp hpe) + have hresM : e-p.val∈M := M.sub_mem heM hpM + have hresn : e-p.val≠0 := by + intro hz + have hpE := sub_eq_zero.mp hz + rw [hpE] at hte + exact (not_lt_of_ge hte) hlt + obtain ⟨q,hqM,hq,hqn,hqle,hqtrace⟩ := exists_small M τ hM hresM hres hresn + (sub_pos.mpr hlt) + have hpq : p.val*q=0 := by + have hqfix := (hq.le_iff_mul_eq_right hres).mp hqle + have hpefix := (hp.le_iff_mul_eq_left he).mp hpe + calc + _=p.val*((e-p.val)*q) := by rw [hqfix] + _=0 := by rw [←mul_assoc,mul_sub,hpefix,hp.isIdempotentElem.eq,sub_self,zero_mul] + have hsumproj : IsStarProjection (p.val+q) := hp.add hq hpq + have hsume : p.val+q≤e := by + calc + _≤p.val+(e-p.val) := add_le_add_right hqle _ + _=e := by abel + have hsumtrace : (τ (p.val+q)).re≤t := by + rw [map_add,Complex.add_re] + linarith + let r : ProjectionChains.TraceCut M τ e t := + ⟨p.val+q,M.add_mem hpM hqM,hsumproj,hsume,hsumtrace⟩ + have hpr : p≤r := le_add_of_nonneg_right hq.nonneg + have heq : r=p := le_antisymm (hmax hpr) hpr + have hval := congrArg Subtype.val heq + change p.val+q=p.val at hval + exact hqn (add_left_cancel (hval.trans (add_zero p.val).symm)) + +end Kadison.DiffuseProjection + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DihedralCompressionMoments.lean b/lean/OAI/Analysis/Commutator/DihedralCompressionMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6f63846b6a43e59b5bb0fb3f3d3faaa15233010 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DihedralCompressionMoments.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.Commutator.AlgebraFreeExpectation +import OAI.Analysis.Commutator.HankelAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} (τ : A →ₗ[ℂ] ℂ) + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (hstar : ∀ a : A, τ (star a)=star (τ a)) (hfree : Free S τ) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d : A)∈S i) (hs : (s : A)∈S j) + (hd0 : τ (d : A)=0) (hs0 : τ (s : A)=0) + +variable (hr : MulAut.conj d (d*s)=(d*s)⁻¹) (hd2 : (d : A)*(d : A)=1) + +variable {p : A} (hp : IsStarProjection p) (hpform : p=(1/2 : ℂ) • (1+(d : A))) + (hpd : p*(d : A)=p) (hdp : (d : A)*p=p) + +include htr in +lemma corner_wave_pairing (u : unitary A) (n : ℤ) (b : Corner hp) : + halfCornerTrace hp τ (cosine u hp n*b)=2*τ (wave u n*(b:A)) := by + rw [halfCornerTrace_apply,corner_mul,cosine_coe] + congr 1 + calc + τ ((p*wave u n*p)*(b:A)) = τ (p*(wave u n*(b:A))) := by + simp only [mul_assoc,b.property.1] + _ = τ ((wave u n*(b:A))*p) := htr _ _ + _ = τ (wave u n*(b:A)) := by rw [mul_assoc,b.property.2] + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hpd in +theorem free_compression_wave_pairing (hpD : p∈S i) (e b : Corner hp) + (he : e∈cornerFactor hp (S i) hpD) + (hb : b∈cosineAlgebra (d*s) d hr hp hpform hdp) + (hb0 : halfCornerTrace hp τ b=0) (n : ℤ) : + τ (wave (d*s) n*((e:A)*(b:A)*(e:A)))= + (halfCornerTrace hp τ e)^2*τ (wave (d*s) n*(b:A)) := by + let R := cornerPairFactors (S:=S) d s i hr hp hpform hdp hpD + have hR := corner_cosine_free τ h1 htr hstar hfree d s i j hij hd hs hd0 hs0 + hr hd2 hp hpform hpd hdp hpD + have hn : cosine (d*s) hp n∈R true := cosine_mem (d*s) hp n + have hz := AlgebraFreeExpectation.free_compression_pairing (halfCornerTrace hp τ) + (halfCornerTrace_one τ h1 d hd0 hp hpform) R hR Bool.false_ne_true he hb hn hb0 + rw [corner_wave_pairing τ htr hp,corner_wave_pairing τ htr hp] at hz + change 2*τ (wave (d*s) n*((e:A)*(b:A)*(e:A)))= + (halfCornerTrace hp τ e)^2*(2*τ (wave (d*s) n*(b:A))) at hz + linear_combination (1/2:ℂ)*hz + +include hdp in +lemma reflection_corner (x : Corner hp) : (d:A)*(x:A)=(x:A) := by + calc + (d:A)*(x:A) = (d:A)*(p*(x:A)) := by rw [x.property.1] + _ = (d:A)*p*(x:A) := (mul_assoc _ _ _).symm + _ = (x:A) := by rw [hdp,x.property.1] + +include htr in +lemma rotation_sandwich_trace (u : unitary A) (x : A) (a b : ℤ) : + τ (wave u a*x*wave u (-b))=τ (wave u (a-b)*x) := by + rw [htr,←mul_assoc,←wave_add] + congr 2 + congr 1 + omega + +include hd2 in +lemma symmetry_wave_product (a : ℤ) : (s:A)*wave (d*s) a= + (d:A)*wave (d*s) (a+1) := by + have hw : wave (d*s) (a+1)=((d:A)*(s:A))*wave (d*s) a := by + rw [add_comm a 1,wave_add] + simp only [wave,zpow_one,Submonoid.coe_mul] + rw [hw,←mul_assoc,←mul_assoc,hd2,one_mul] + +include htr hr hd2 hdp in +lemma symmetry_sandwich_trace (x : Corner hp) (a b : ℤ) : + τ ((s:A)*(wave (d*s) a*(x:A)*wave (d*s) (-b)))= + τ (wave (d*s) (-(a+b+1))*(x:A)) := by + calc + _ = τ (wave (d*s) (-b)*((s:A)*wave (d*s) a)*(x:A)) := by + rw [←mul_assoc (s:A),htr] + simp only [mul_assoc] + _ = τ (wave (d*s) (-b)*((d:A)*wave (d*s) (a+1))*(x:A)) := by + rw [symmetry_wave_product d s hd2] + _ = τ (wave (d*s) (-b)*(wave (d*s) (-(a+1))*(d:A))*(x:A)) := by + rw [reflection_wave (d*s) d hr] + _ = τ ((wave (d*s) (-b)*wave (d*s) (-(a+1)))*((d:A)*(x:A))) := by + simp only [mul_assoc] + _ = τ (wave (d*s) (-b+-(a+1))*(x:A)) := by + rw [reflection_corner d hp hdp,←wave_add] + _ = _ := by congr 2; congr 1; omega + +include htr hr hpd hdp in +lemma wave_corner_even (x : Corner hp) (n : ℤ) : + τ (wave (d*s) (-n)*(x:A))=τ (wave (d*s) n*(x:A)) := by + have h := congrArg (fun z : Corner hp => halfCornerTrace hp τ (z*x)) + (cosine_neg (d*s) d hr hp hpd hdp n) + rw [corner_wave_pairing τ htr hp,corner_wave_pairing τ htr hp] at h + linear_combination (1/2:ℂ)*h + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hpd in +lemma compression_rotation_sandwich (hpD : p∈S i) (e b : Corner hp) + (he : e∈cornerFactor hp (S i) hpD) + (hb : b∈cosineAlgebra (d*s) d hr hp hpform hdp) + (hb0 : halfCornerTrace hp τ b=0) (a c : ℤ) : + τ (wave (d*s) a*((e:A)*(b:A)*(e:A))*wave (d*s) (-c))= + (halfCornerTrace hp τ e)^2*τ (wave (d*s) (a-c)*(b:A)) := by + rw [rotation_sandwich_trace τ htr] + exact free_compression_wave_pairing τ h1 htr hstar hfree d s i j hij hd hs hd0 hs0 + hr hd2 hp hpform hpd hdp hpD e b he hb hb0 (a-c) + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hpd in +lemma compression_symmetry_sandwich (hpD : p∈S i) (e b : Corner hp) + (he : e∈cornerFactor hp (S i) hpD) + (hb : b∈cosineAlgebra (d*s) d hr hp hpform hdp) + (hb0 : halfCornerTrace hp τ b=0) (a c : ℤ) : + τ ((s:A)*(wave (d*s) a*((e:A)*(b:A)*(e:A))*wave (d*s) (-c)))= + (halfCornerTrace hp τ e)^2*τ (wave (d*s) (a+c+1)*(b:A)) := by + change τ ((s:A)*(wave (d*s) a*((e*b*e:Corner hp):A)*wave (d*s) (-c)))=_ + rw [symmetry_sandwich_trace τ htr d s hr hd2 hp hdp] + simp only [corner_mul] + rw [free_compression_wave_pairing τ h1 htr hstar hfree d s i j hij hd hs hd0 hs0 + hr hd2 hp hpform hpd hdp hpD e b he hb hb0] + rw [wave_corner_even τ htr d s hr hp hpd hdp] + +end Kadison.DihedralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DihedralExpectationEntries.lean b/lean/OAI/Analysis/Commutator/DihedralExpectationEntries.lean new file mode 100644 index 0000000000000000000000000000000000000000..cccf6366c139877073da6abc14515be01fa870d0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DihedralExpectationEntries.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.DihedralCompressionMoments +import OAI.Analysis.Commutator.DihedralHaar +import OAI.Analysis.Commutator.SubfactorExpectation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +lemma wave_mem (R : StarSubalgebra ℂ A) (u : unitary A) (hu : (u:A)∈R) + (n : ℤ) : wave u n∈R := by + cases n with + | ofNat n => + change wave u (n:ℤ)∈R + rw [wave_nat] + exact R.pow_mem hu n + | negSucc n => + change wave u (-((n+1:ℕ):ℤ))∈R + rw [←wave_star,wave_nat] + exact star_mem (R.pow_mem hu _) + +lemma cosineAlgebra_coe_mem (R : StarSubalgebra ℂ A) (u d : unitary A) + (hr : MulAut.conj d u=u⁻¹) {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hdp : (d:A)*p=p) + (hpR : p∈R) (huR : (u:A)∈R) {b : Corner hp} + (hb : b∈cosineAlgebra u d hr hp hpform hdp) : (b:A)∈R := by + change b∈cosineSpace u hp at hb + induction hb using Submodule.span_induction with + | mem b hb => + obtain ⟨n,rfl⟩ := hb + exact R.mul_mem (R.mul_mem hpR (wave_mem R u huR n)) hpR + | zero => exact R.zero_mem + | add b c _ _ hb hc => exact R.add_mem hb hc + | smul z b _ hb => exact R.smul_mem hb z + +variable (S : Bool → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (hstar : ∀ a : A, τ (star a)=star (τ a)) (hfree : Free S τ) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : τ (d:A)=0) (hs0 : τ (s:A)=0) + +variable (hr : MulAut.conj d (d*s)=(d*s)⁻¹) (hd2 : (d:A)*(d:A)=1) + (hs2 : (s:A)*(s:A)=1) + +variable {p : A} (hp : IsStarProjection p) (hpform : p=(1/2:ℂ) • (1+(d:A))) + (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + +include h1 htr hstar hfree hd hs hd0 hs0 hd2 hpd hs2 in +theorem compression_expectation_pairing (hpD : p∈S false) (e b : Corner hp) + (he : e∈cornerFactor hp (S false) hpD) + (hb : b∈cosineAlgebra (d*s) d hr hp hpform hdp) + (hb0 : halfCornerTrace hp τ b=0) {a : A} (ha : a∈S true) (j k : ℤ) : + τ (a*(wave (d*s) j*((e:A)*(b:A)*(e:A))*wave (d*s) (-k)))= + τ a*(halfCornerTrace hp τ e)^2*τ (wave (d*s) (j-k)*(b:A))+ + τ (a*(s:A))*(halfCornerTrace hp τ e)^2*τ (wave (d*s) (j+k+1)*(b:A)) := by + let R := ⨆ i,SymmetryAlgebra.factors (s:A) (symmetry_star s hs2) hs2 S i + have hDR : S false≤R := le_iSup (fun i => SymmetryAlgebra.factors + (s:A) (symmetry_star s hs2) hs2 S i) false + have hsR : (s:A)∈R := (le_iSup (fun i => SymmetryAlgebra.factors + (s:A) (symmetry_star s hs2) hs2 S i) true) (SymmetryAlgebra.self_mem (s:A) (symmetry_star s hs2) hs2) + have hwR : ((d*s:unitary A):A)∈R := R.mul_mem (hDR hd) hsR + have heR : (e:A)∈R := hDR he + have hbR := cosineAlgebra_coe_mem R (d*s) d hr hp hpform hdp (hDR hpD) hwR hb + have hx : wave (d*s) j*((e:A)*(b:A)*(e:A))*wave (d*s) (-k)∈R := + R.mul_mem (R.mul_mem (wave_mem R _ hwR _) (R.mul_mem (R.mul_mem heR hbR) heR)) + (wave_mem R _ hwR _) + rw [SymmetryAlgebra.pairing_projection (s:A) (symmetry_star s hs2) hs2 S τ + hs hs0 hstar h1 hfree ha hx, + compression_rotation_sandwich τ h1 htr hstar hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hr hd2 hp hpform hpd hdp hpD e b he hb hb0, + compression_symmetry_sandwich τ h1 htr hstar hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hr hd2 hp hpform hpd hdp hpD e b he hb hb0] + ring + +end Kadison.DihedralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DihedralFejer.lean b/lean/OAI/Analysis/Commutator/DihedralFejer.lean new file mode 100644 index 0000000000000000000000000000000000000000..faba76313006a1b5193d7fc9395f03a7824cdd39 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DihedralFejer.lean @@ -0,0 +1,227 @@ +import Mathlib +import OAI.Analysis.Commutator.DihedralHaar +import OAI.Analysis.Commutator.FejerTest +import OAI.Analysis.Commutator.TracialDevelopment + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.DihedralCorner + +open FreeMoments FejerTest + +variable {A : Type*} [CStarAlgebra A] + +lemma star_pow_mul_pow (u : unitary A) (i j : ℕ) : + star ((u:A)^i)*(u:A)^j=wave u (-(i:ℤ)+(j:ℤ)) := by + rw [←wave_nat,←wave_nat,wave_star,←wave_add] + +lemma testPolynomial_expansion (u : unitary A) (m : ℕ) : + testPolynomial (u:A) m= + ((m:ℂ)⁻¹*(m:ℂ)⁻¹) • + (∑ i∈Finset.range m,∑ j∈Finset.range m,wave u (-(i:ℤ)+(j:ℤ))) - + (m:ℂ)⁻¹ • (1:A) := by + have hs : star ((m:ℂ)⁻¹)=(m:ℂ)⁻¹ := by simp + simp only [testPolynomial,powerAverage,star_smul, + star_sum,smul_mul_assoc,mul_smul_comm,Finset.sum_mul,Finset.mul_sum, + star_pow_mul_pow,hs,←Finset.smul_sum,smul_smul] + rw [Finset.sum_comm] + +lemma testPolynomial_reflection_commute (u d : unitary A) + (hr : MulAut.conj d u=u⁻¹) (m : ℕ) : + (d:A)*testPolynomial (u:A) m=testPolynomial (u:A) m*(d:A) := by + rw [testPolynomial_expansion] + simp only [mul_sub,sub_mul,mul_smul_comm,smul_mul_assoc,mul_one,one_mul] + congr 1 + congr 1 + simp only [Finset.mul_sum,Finset.sum_mul,reflection_wave u d hr] + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro i _ + apply Finset.sum_congr rfl + intro j _ + congr 2 + omega + +variable {p : A} (hp : IsStarProjection p) + +def compressCorner : A →ₗ[ℂ] Corner hp where + toFun a := ⟨p*a*p,by constructor <;> simp only [mul_assoc,←mul_assoc p p,hp.isIdempotentElem.eq]⟩ + map_add' a b := by + apply Subtype.ext + change p*(a+b)*p=p*a*p+p*b*p + rw [mul_add,add_mul] + map_smul' z a := by + apply Subtype.ext + change p*(z • a)*p=z • (p*a*p) + simp only [mul_smul_comm,smul_mul_assoc] + +@[simp] lemma compressCorner_coe (a : A) : ((compressCorner hp a:Corner hp):A)=p*a*p := rfl + +@[simp] lemma compressCorner_one : compressCorner hp 1=1 := by + apply Subtype.ext + change p*1*p=p + rw [mul_one,hp.isIdempotentElem.eq] + +@[simp] lemma compressCorner_wave (u : unitary A) (n : ℤ) : + compressCorner hp (wave u n)=cosine u hp n := rfl + +def fejerCorner (u : unitary A) (m : ℕ) : Corner hp := + compressCorner hp (testPolynomial (u:A) m) + +lemma fejerCorner_mem (u d : unitary A) (hr : MulAut.conj d u=u⁻¹) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hdp : (d:A)*p=p) (m : ℕ) : + fejerCorner hp u m∈cosineAlgebra u d hr hp hpform hdp := by + let R := cosineAlgebra u d hr hp hpform hdp + unfold fejerCorner + rw [testPolynomial_expansion] + simp only [map_sub,map_smul,map_sum,compressCorner_wave,compressCorner_one] + exact R.sub_mem (R.smul_mem (R.sum_mem (fun i _ => + R.sum_mem (fun j _ => cosine_mem u hp _))) _) (R.smul_mem R.one_mem _) + +lemma fejerCorner_selfAdjoint (u : unitary A) (m : ℕ) : + IsSelfAdjoint (fejerCorner hp u m) := by + change star (fejerCorner hp u m)=fejerCorner hp u m + apply Subtype.ext + change star (p*testPolynomial (u:A) m*p)=p*testPolynomial (u:A) m*p + simp only [star_mul,hp.isSelfAdjoint.star_eq,(testPolynomial_selfAdjoint (u:A) m).star_eq] + exact (mul_assoc _ _ _).symm + +lemma fejerCorner_coe_right (u d : unitary A) (hr : MulAut.conj d u=u⁻¹) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (m : ℕ) : + ((fejerCorner hp u m:Corner hp):A)=testPolynomial (u:A) m*p := by + change p*testPolynomial (u:A) m*p=_ + have comm : p*testPolynomial (u:A) m=testPolynomial (u:A) m*p := by + rw [hpform] + simp only [smul_mul_assoc,mul_smul_comm,add_mul,mul_add,one_mul,mul_one, + testPolynomial_reflection_commute u d hr] + rw [comm,mul_assoc,hp.isIdempotentElem.eq] + +lemma fejerCorner_norm_le (u : unitary A) (m : ℕ) (hm : 0 < m) : + ‖fejerCorner hp u m‖≤2 := by + nontriviality A + change ‖p*testPolynomial (u:A) m*p‖≤2 + have hp1 : ‖p‖≤1 := hp.norm_le + have hq := norm_testPolynomial_le (u:A) m hm (le_of_eq (CStarRing.norm_coe_unitary u)) + calc + _ ≤ ‖p‖*‖testPolynomial (u:A) m‖*‖p‖ := norm_mul₃_le + _ ≤ 1*2*1 := mul_le_mul + (mul_le_mul hp1 hq (norm_nonneg _) zero_le_one) hp1 (norm_nonneg _) (by norm_num) + _ = 2 := by norm_num + +variable [PartialOrder A] [StarOrderedRing A] + +variable (φ : A →ₚ[ℂ] ℂ) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (h1 : φ 1=1) (htr : ∀ a b : A, φ (a*b)=φ (b*a)) + (hstar : ∀ a : A, φ (star a)=star (φ a)) (hfree : Free S φ.toLinearMap) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d:A)∈S i) (hs : (s:A)∈S j) + (hd0 : φ (d:A)=0) (hs0 : φ (s:A)=0) + +variable (hr : MulAut.conj d (d*s)=(d*s)⁻¹) (hd2 : (d:A)*(d:A)=1) + +variable (hpform : p=(1/2:ℂ) • (1+(d:A))) + +include htr hstar hfree hij hd hs hd0 hs0 hd2 in +omit [StarOrderedRing A] in +lemma testPolynomial_reflection_trace (m : ℕ) (l : ℤ) : + φ (wave (d*s) l*testPolynomial ((d*s:unitary A):A) m*(d:A))=0 := by + have ht (n : ℤ) : φ (wave (d*s) n*(d:A))=0 := + reflection_trace φ.toLinearMap htr hstar hfree d s i j hij hd hs hd0 hs0 hd2 n + rw [testPolynomial_expansion] + simp only [mul_sub,sub_mul,mul_smul_comm,smul_mul_assoc,mul_one, + Finset.mul_sum,Finset.sum_mul,←wave_add,map_sub,map_smul,map_sum, + ht, + smul_zero,Finset.sum_const_zero,sub_zero] + +include htr hstar hfree hij hd hs hd0 hs0 hd2 hr hpform in +omit [StarOrderedRing A] in +lemma fejerCorner_wave_trace (m : ℕ) (l : ℤ) : + φ (wave (d*s) l*((fejerCorner hp (d*s) m:Corner hp):A))= + (1/2:ℂ)*φ (testPolynomial ((d*s:unitary A):A) m*wave (d*s) l) := by + rw [fejerCorner_coe_right hp (d*s) d hr hpform] + let q := testPolynomial ((d*s:unitary A):A) m + have he : wave (d*s) l*(q*p)=(1/2:ℂ) • + (wave (d*s) l*q + wave (d*s) l*q*(d:A)) := by + rw [hpform] + simp only [mul_smul_comm,mul_add,mul_one,mul_assoc] + rw [he] + simp only [map_smul,map_add,smul_eq_mul] + rw [testPolynomial_reflection_trace φ S htr hstar hfree d s i j hij + hd hs hd0 hs0 hd2,add_zero,htr] + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hr hpform in +omit [StarOrderedRing A] in +lemma fejerCorner_centered (m : ℕ) (hm : 0 < m) : + halfCornerTrace hp φ.toLinearMap (fejerCorner hp (d*s) m)=0 := by + have hhaar : HaarMoments φ ((d*s:unitary A):A) := + dihedral_haar φ.toLinearMap h1 hstar hfree d s i j hij hd hs hd0 hs0 + have h := fejerCorner_wave_trace hp φ S htr hstar hfree d s i j hij + hd hs hd0 hs0 hr hd2 hpform m 0 + simp only [wave_zero,one_mul,mul_one,moment_testPolynomial φ _ hhaar h1 m hm, + mul_zero] at h + simp only [halfCornerTrace_apply,PositiveLinearMap.coe_toLinearMap,h,mul_zero] + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hr hpform in +omit [StarOrderedRing A] in +lemma fejerCorner_positive_coefficient (m l : ℕ) (hm : 0 < m) + (hl : 0 < l) (hlm : l < m) : + 2*φ (wave (d*s) (l:ℤ)*((fejerCorner hp (d*s) m:Corner hp):A))= + ((m:ℂ)-(l:ℂ))/(m:ℂ)^2 := by + rw [fejerCorner_wave_trace hp φ S htr hstar hfree d s i j hij + hd hs hd0 hs0 hr hd2 hpform, wave_nat] + have hhaar : HaarMoments φ ((d*s:unitary A):A) := + dihedral_haar φ.toLinearMap h1 hstar hfree d s i j hij hd hs hd0 hs0 + rw [positive_coefficient φ _ hhaar m l hm hl hlm] + ring + +lemma corner_preGNS_norm (a : Corner hp) : + ‖(cornerFunctional hp φ (1/2) (by norm_num)).toPreGNS a‖= + Real.sqrt 2*‖φ.toPreGNS (a:A)‖ := by + rw [PositiveLinearMap.preGNS_norm_def,PositiveLinearMap.preGNS_norm_def] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS,cornerFunctional_apply, + corner_mul,corner_star] + norm_num only [one_div,inv_inv] + rw [Complex.smul_re,smul_eq_mul,Real.sqrt_mul (by norm_num : (0:ℝ)≤2)] + +include h1 htr hstar hfree hij hd hs hd0 hs0 hr hpform in +lemma fejerCorner_preGNS_norm (m : ℕ) (hm : 0 < m) : + ‖(cornerFunctional hp φ (1/2) (by norm_num)).toPreGNS (fejerCorner hp (d*s) m)‖≤ + 2*Real.sqrt 2*Real.sqrt ((m:ℝ)⁻¹) := by + have hhaar : HaarMoments φ ((d*s:unitary A):A) := + dihedral_haar φ.toLinearMap h1 hstar hfree d s i j hij hd hs hd0 hs0 + have hu : ‖((d*s:unitary A):A)‖≤1 := by + nontriviality A + exact le_of_eq (CStarRing.norm_coe_unitary _) + have hq := norm_preGNS_testPolynomial φ _ hhaar h1 m hm hu + rw [corner_preGNS_norm,fejerCorner_coe_right hp (d*s) d hr hpform] + have hmul : ‖φ.toPreGNS (testPolynomial ((d*s:unitary A):A) m*p)‖≤ + ‖φ.toPreGNS (testPolynomial ((d*s:unitary A):A) m)‖ := by + exact ((TracialGNS.rightMulPre φ htr p).le_opNorm + (φ.toPreGNS (testPolynomial ((d*s:unitary A):A) m))).trans + ((mul_le_mul_of_nonneg_right + ((TracialGNS.norm_rightMulPre_le φ htr p).trans hp.norm_le) (norm_nonneg _)).trans_eq + (one_mul _)) + calc + _ ≤ Real.sqrt 2*(2*Real.sqrt ((m:ℝ)⁻¹)) := + mul_le_mul_of_nonneg_left (hmul.trans hq) (Real.sqrt_nonneg _) + _ = _ := by ring + +end Kadison.DihedralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DihedralHaar.lean b/lean/OAI/Analysis/Commutator/DihedralHaar.lean new file mode 100644 index 0000000000000000000000000000000000000000..24537822aeeee9856d15f15785cc5dc04dfa797a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DihedralHaar.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.Commutator.HankelAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} (τ : A →ₗ[ℂ] ℂ) + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (hstar : ∀ a : A, τ (star a)=star (τ a)) (hfree : Free S τ) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d : A)∈S i) (hs : (s : A)∈S j) + (hd0 : τ (d : A)=0) (hs0 : τ (s : A)=0) + +lemma wave_nat (u : unitary A) (n : ℕ) : wave u (n:ℤ)=(u:A)^n := by + simp only [wave,zpow_natCast,SubmonoidClass.coe_pow] + +include hfree hij hd hs hd0 hs0 in +lemma wave_positive_trace (n : ℕ) : τ (wave (d*s) ((n+1:ℕ):ℤ))=0 := by + let D : Letter S τ := ⟨i,d,hd,hd0⟩ + let F : Letter S τ := ⟨j,s,hs,hs0⟩ + have h := alternating_power_centered hfree D F hij n + change τ (((d:A)*(s:A))^(n+1))=0 at h + simpa only [wave_nat,Submonoid.coe_mul] using h + +include hstar hfree hij hd hs hd0 hs0 in +lemma wave_trace_zero (n : ℤ) (hn : n≠0) : τ (wave (d*s) n)=0 := by + cases n with + | ofNat n => + cases n with + | zero => exact (hn rfl).elim + | succ n => exact wave_positive_trace τ hfree d s i j hij hd hs hd0 hs0 n + | negSucc n => + change τ (wave (d*s) (-((n+1:ℕ):ℤ)))=0 + rw [←wave_star,hstar,wave_positive_trace τ hfree d s i j hij hd hs hd0 hs0,star_zero] + +include h1 hstar hfree hij hd hs hd0 hs0 in +lemma wave_trace (n : ℤ) : τ (wave (d*s) n)=if n=0 then 1 else 0 := by + split_ifs with h + · simp [h,h1] + · exact wave_trace_zero τ hstar hfree d s i j hij hd hs hd0 hs0 n h + +include h1 hstar hfree hij hd hs hd0 hs0 in +theorem dihedral_haar (a b : ℕ) : + τ (star (((d:A)*(s:A))^a)*((d:A)*(s:A))^b)=if a=b then 1 else 0 := by + have hw (m : ℕ) : ((d:A)*(s:A))^m=wave (d*s) (m:ℤ) := (wave_nat (d*s) m).symm + rw [hw a,hw b,wave_star,←wave_add,wave_trace τ h1 hstar hfree d s i j hij hd hs hd0 hs0] + have he : (-(a:ℤ)+(b:ℤ)=0) ↔ a=b := by omega + simp only [he] + +include hfree hij hd hs hd0 hs0 in +lemma reflection_positive_trace (n : ℕ) : τ (wave (d*s) (n:ℤ)*(d:A))=0 := by + let D : Letter S τ := ⟨i,d,hd,hd0⟩ + let F : Letter S τ := ⟨j,s,hs,hs0⟩ + have h := alternating_odd_centered hfree F D hij.symm n + have hm : ((d:A)*(s:A))^n*(d:A)=(d:A)*((s:A)*(d:A))^n := by + exact mul_pow_mul (d:A) (s:A) n + rw [wave_nat] + change τ (((d:A)*(s:A))^n*(d:A))=0 + rw [hm] + exact h + +lemma symmetry_star (u : unitary A) (hu : (u:A)*(u:A)=1) : star (u:A)=(u:A) := by + have h := congrArg ((star (u:A)) * ·) hu + simpa only [←mul_assoc,Unitary.coe_star_mul_self,one_mul,mul_one] using h.symm + +include htr hstar hfree hij hd hs hd0 hs0 in +lemma reflection_trace (hd2 : (d:A)*(d:A)=1) (n : ℤ) : + τ (wave (d*s) n*(d:A))=0 := by + cases n with + | ofNat n => exact reflection_positive_trace τ hfree d s i j hij hd hs hd0 hs0 n + | negSucc n => + change τ (wave (d*s) (-((n+1:ℕ):ℤ))*(d:A))=0 + calc + _ = τ ((d:A)*wave (d*s) (-((n+1:ℕ):ℤ))) := htr _ _ + _ = τ (star (wave (d*s) ((n+1:ℕ):ℤ)*(d:A))) := by + rw [star_mul,symmetry_star d hd2,wave_star] + _ = star (τ (wave (d*s) ((n+1:ℕ):ℤ)*(d:A))) := hstar _ + _ = 0 := by rw [reflection_positive_trace τ hfree d s i j hij hd hs hd0 hs0,star_zero] + +end Kadison.DihedralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DoubleCopies.lean b/lean/OAI/Analysis/Commutator/DoubleCopies.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc9a4822d6c9a6e6b1bf3c78e34910b73f302016 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DoubleCopies.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertPadding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.HilbertPadding + +open OperatorAmplification CyclicColumns + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] + +local instance doubleCopiesIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +def doubleCopies : SumSpace (H:=H) ι →ₗᵢ[ℂ] SumSpace (H:=H) ((Fin 2)×ι) where + toFun v := WithLp.toLp 2 (fun p => if p.1=0 then v p.2 else 0) + map_add' v w := by ext p; by_cases h : p.1=0 <;> simp [h] + map_smul' z v := by ext p; by_cases h : p.1=0 <;> simp [h] + norm_map' v := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + simp [PiLp.norm_sq_eq_of_L2,Fintype.sum_prod_type,Fin.sum_univ_two] + +omit [CompleteSpace H] in +@[simp] lemma doubleCopies_apply (v : SumSpace (H:=H) ι) (p : (Fin 2)×ι) : + doubleCopies ι v p=if p.1=0 then v p.2 else 0 := rfl + +lemma doubleCopies_diagonal (a : H →L[ℂ] H) : + (diagonal (H:=H) ((Fin 2)×ι) a).comp (doubleCopies (H:=H) ι).toContinuousLinearMap= + (doubleCopies (H:=H) ι).toContinuousLinearMap.comp (diagonal (H:=H) ι a) := by + ext v p + simp only [comp_apply,diagonal_apply,LinearIsometry.coe_toContinuousLinearMap,doubleCopies_apply] + by_cases h : p.1=0 <;> simp [h] + +lemma doubleCopies_adjoint_diagonal (a : H →L[ℂ] H) : + (doubleCopies (H:=H) ι).toContinuousLinearMap.adjoint.comp (diagonal (H:=H) ((Fin 2)×ι) a)= + (diagonal (H:=H) ι a).comp (doubleCopies (H:=H) ι).toContinuousLinearMap.adjoint := by + have h := congrArg (fun T => T.adjoint) (doubleCopies_diagonal ι (star a)) + simpa only [adjoint_comp,←star_eq_adjoint,←map_star,star_star] using h + +theorem doubleCopies_commutator_norm + (Y : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (a : H →L[ℂ] H) : + ‖extend (doubleCopies ι) Y*diagonal (H:=H) ((Fin 2)×ι) a- + diagonal (H:=H) ((Fin 2)×ι) a*extend (doubleCopies ι) Y‖= + ‖Y*diagonal (H:=H) ι a-diagonal (H:=H) ι a*Y‖ := + norm_extend_commutator _ _ _ _ (doubleCopies_diagonal ι a) (doubleCopies_adjoint_diagonal ι a) + +end Kadison.HilbertPadding + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DyadicCuts.lean b/lean/OAI/Analysis/Commutator/DyadicCuts.lean new file mode 100644 index 0000000000000000000000000000000000000000..14a8c49bc5999cfe0748254666f9e82a4d744f36 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DyadicCuts.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseHalving +import OAI.Analysis.Commutator.FiniteNoReplicas +import OAI.Analysis.Commutator.ProjectionEquivalence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure ProjectionIn (M : VonNeumannAlgebra H) where + val : H →L[ℂ] H + mem : val∈M + projection : IsStarProjection val + +namespace DyadicCuts + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) + +def half (e : ProjectionIn M) : Link M e.val e.val := + (diffuse_halving M hfac hd e.mem e.projection).choose + +lemma half_square (e : ProjectionIn M) : (half M hfac hd e).val*(half M hfac hd e).val=0 := + (diffuse_halving M hfac hd e.mem e.projection).choose_spec.1 + +lemma half_sum (e : ProjectionIn M) : + (half M hfac hd e).initial+(half M hfac hd e).final=e.val := + (diffuse_halving M hfac hd e.mem e.projection).choose_spec.2 + +def next (e : ProjectionIn M) : ProjectionIn M := + ⟨(half M hfac hd e).initial, + M.mul_mem (M.star_mem' (half M hfac hd e).mem) (half M hfac hd e).mem, + (half M hfac hd e).initial_projection⟩ + +def cut : ℕ → ProjectionIn M + | 0 => ⟨1,M.one_mem,IsStarProjection.one _⟩ + | n+1 => next M hfac hd (cut n) + +def link (n : ℕ) := half M hfac hd (cut M hfac hd n) + +def side (n : ℕ) : H →L[ℂ] H := (link M hfac hd n).final + +lemma cut_succ (n : ℕ) : (cut M hfac hd (n+1)).val=(link M hfac hd n).initial := rfl + +lemma side_projection (n : ℕ) : IsStarProjection (side M hfac hd n) := + (link M hfac hd n).final_projection + +lemma side_mem (n : ℕ) : side M hfac hd n∈M := + M.mul_mem (link M hfac hd n).mem (M.star_mem' (link M hfac hd n).mem) + +lemma side_le (n : ℕ) : side M hfac hd n≤(cut M hfac hd n).val := + (link M hfac hd n).target_le + +lemma cut_antitone : Antitone (fun n => (cut M hfac hd n).val) := by + apply antitone_nat_of_succ_le + intro n + exact (link M hfac hd n).source_le + +lemma cut_succ_add_side (n : ℕ) : + (cut M hfac hd (n+1)).val+side M hfac hd n=(cut M hfac hd n).val := + half_sum M hfac hd (cut M hfac hd n) + +lemma side_mul_cut_succ (n : ℕ) : + side M hfac hd n*(cut M hfac hd (n+1)).val=0 := by + have h := (link M hfac hd n).initial_mul_final_eq_zero + (half_square M hfac hd (cut M hfac hd n)) + change (cut M hfac hd (n+1)).val*side M hfac hd n=0 at h + simpa only [star_mul,(side_projection M hfac hd n).isSelfAdjoint.star_eq, + (cut M hfac hd (n+1)).projection.isSelfAdjoint.star_eq,star_zero] using congrArg star h + +lemma side_mul_side_of_lt {n m : ℕ} (hnm : n < m) : side M hfac hd n*side M hfac hd m=0 := by + have hle : side M hfac hd m≤(cut M hfac hd (n+1)).val := + (side_le M hfac hd m).trans (cut_antitone M hfac hd (Nat.succ_le_of_lt hnm)) + have he := ((side_projection M hfac hd m).le_iff_mul_eq_right + (cut M hfac hd (n+1)).projection).mp hle + calc + _=side M hfac hd n*((cut M hfac hd (n+1)).val*side M hfac hd m) := by rw [he] + _=0 := by rw [←mul_assoc,side_mul_cut_succ,zero_mul] + +lemma side_cross (n m : ℕ) (hne : n≠m) : side M hfac hd n*side M hfac hd m=0 := by + rcases lt_or_gt_of_ne hne with h|h + · exact side_mul_side_of_lt M hfac hd h + · simpa only [star_mul,(side_projection M hfac hd n).isSelfAdjoint.star_eq, + (side_projection M hfac hd m).isSelfAdjoint.star_eq,star_zero] using + congrArg star (side_mul_side_of_lt M hfac hd h) + +theorem exists_subEquivalent [TopologicalSpace.SeparableSpace H] + (hfin : IsFiniteAlgebra M) {e : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) (hen : e≠0) : + ∃ n,SubEquivalent M (cut M hfac hd n).val e := by + classical + by_contra hn + push Not at hn + have hrev (n : ℕ) : SubEquivalent M e (cut M hfac hd n).val := by + exact (factor_subEquivalent_total M hfac heM (cut M hfac hd n).mem + he (cut M hfac hd n).projection).resolve_right (hn n) + choose v hv using hrev + let b (n : ℕ) : Link M (cut M hfac hd (n+1)).val (side M hfac hd n) := + ⟨(link M hfac hd n).val,(link M hfac hd n).mem,(link M hfac hd n).triple,le_rfl,le_rfl⟩ + let a (n : ℕ) : Link M e (side M hfac hd n) := + (b n).compFull (v (n+1)) he (cut M hfac hd (n+1)).projection (hv (n+1)) rfl + have hai (n : ℕ) : (a n).initial=e := + (b n).compFull_initial (v (n+1)) he (cut M hfac hd (n+1)).projection (hv (n+1)) rfl + have hac (n m : ℕ) (hne : n≠m) : star (a n).val*(a m).val=0 := by + have hl : star (a n).val*side M hfac hd n=star (a n).val := by + simpa only [star_mul,(side_projection M hfac hd n).isSelfAdjoint.star_eq] using + congrArg star ((a n).target_mul (side_projection M hfac hd n)) + calc + _=(star (a n).val*side M hfac hd n)*(side M hfac hd m*(a m).val) := by + rw [hl,(a m).target_mul (side_projection M hfac hd m)] + _=star (a n).val*(side M hfac hd n*side M hfac hd m)*(a m).val := by noncomm_ring + _=0 := by rw [side_cross M hfac hd n m hne,mul_zero,zero_mul] + exact finite_no_replicas M hfac hfin heM he hen + ⟨fun n => (a n).val,fun n => (a n).mem,hai,hac,fun n => (a n).mul_source he⟩ + +end DyadicCuts + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DyadicDimension.lean b/lean/OAI/Analysis/Commutator/DyadicDimension.lean new file mode 100644 index 0000000000000000000000000000000000000000..5a0a90d97011d1607f5fc87112b62b80e7838d59 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DyadicDimension.lean @@ -0,0 +1,164 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicPartition +import OAI.Analysis.Commutator.PartitionRank +import OAI.Analysis.Commutator.DyadicRankStep + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) + +def lower (e : H →L[ℂ] H) (n : ℕ) : ℝ := + ((partition M hfac hd n).rank e : ℝ)/(2:ℝ)^n + +def upper (e : H →L[ℂ] H) (n : ℕ) : ℝ := + (((partition M hfac hd n).rank e : ℝ)+1)/(2:ℝ)^n + +def dimension (e : H →L[ℂ] H) : ℝ := sSup (Set.range (lower M hfac hd e)) + +lemma lower_nonneg (e : H →L[ℂ] H) (n : ℕ) : 0≤lower M hfac hd e n := + div_nonneg (Nat.cast_nonneg _) (by positivity) + +lemma lower_le_one (e : H →L[ℂ] H) (n : ℕ) : lower M hfac hd e n≤1 := by + apply (div_le_one (by positivity : (0:ℝ)<2^n)).mpr + have h := (partition M hfac hd n).rank_le_card e + rw [cardinality] at h + exact_mod_cast h + +lemma lower_le_upper (e : H →L[ℂ] H) (n : ℕ) : lower M hfac hd e n≤upper M hfac hd e n := by + apply div_le_div_of_nonneg_right _ (by positivity) + linarith + +lemma rank_succ_lower {e : H →L[ℂ] H} (he : IsStarProjection e) (n : ℕ) : + 2*(partition M hfac hd n).rank e≤(partition M hfac hd (n+1)).rank e := by + let D := partition M hfac hd n + let p : ProjectionIn M := ⟨D.base,D.base_mem,D.base_projection⟩ + change 2*D.rank e≤(D.double (DyadicCuts.half M hfac hd p) + (DyadicCuts.half_square M hfac hd p) (DyadicCuts.half_sum M hfac hd p)).rank e + exact D.double_rank_lower (DyadicCuts.half M hfac hd p) + (DyadicCuts.half_square M hfac hd p) (DyadicCuts.half_sum M hfac hd p) he + +lemma rank_succ_upper {e : H →L[ℂ] H} (he : IsStarProjection e) (n : ℕ) : + (partition M hfac hd (n+1)).rank e≤2*(partition M hfac hd n).rank e+1 := by + let D := partition M hfac hd n + let p : ProjectionIn M := ⟨D.base,D.base_mem,D.base_projection⟩ + change (D.double (DyadicCuts.half M hfac hd p) + (DyadicCuts.half_square M hfac hd p) (DyadicCuts.half_sum M hfac hd p)).rank e≤2*D.rank e+1 + exact D.double_rank_upper (DyadicCuts.half M hfac hd p) + (DyadicCuts.half_square M hfac hd p) (DyadicCuts.half_sum M hfac hd p) he + +lemma lower_monotone {e : H →L[ℂ] H} (he : IsStarProjection e) : Monotone (lower M hfac hd e) := by + apply monotone_nat_of_le_succ + intro n + have h : (2:ℝ)*(partition M hfac hd n).rank e≤(partition M hfac hd (n+1)).rank e := + by exact_mod_cast rank_succ_lower M hfac hd he n + dsimp only [lower] + rw [pow_succ] + apply (div_le_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith [pow_pos (by norm_num : (0:ℝ)<2) n] + +lemma upper_antitone {e : H →L[ℂ] H} (he : IsStarProjection e) : Antitone (upper M hfac hd e) := by + apply antitone_nat_of_succ_le + intro n + have h : ((partition M hfac hd (n+1)).rank e:ℝ)≤2*(partition M hfac hd n).rank e+1 := + by exact_mod_cast rank_succ_upper M hfac hd he n + dsimp only [upper] + rw [pow_succ] + apply (div_le_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith [pow_pos (by norm_num : (0:ℝ)<2) n] + +lemma lower_le_dimension (e : H →L[ℂ] H) (n : ℕ) : + lower M hfac hd e n≤dimension M hfac hd e := + le_csSup ⟨1,by rintro _ ⟨k,rfl⟩; exact lower_le_one M hfac hd e k⟩ ⟨n,rfl⟩ + +lemma dimension_le_upper {e : H →L[ℂ] H} (he : IsStarProjection e) (n : ℕ) : + dimension M hfac hd e≤upper M hfac hd e n := by + apply csSup_le (Set.range_nonempty _) + rintro _ ⟨k,rfl⟩ + rcases le_total k n with h|h + · exact (lower_monotone M hfac hd he h).trans (lower_le_upper M hfac hd e n) + · exact (lower_le_upper M hfac hd e k).trans (upper_antitone M hfac hd he h) + +lemma dimension_nonneg (e : H →L[ℂ] H) : 0≤dimension M hfac hd e := + (lower_nonneg M hfac hd e 0).trans (lower_le_dimension M hfac hd e 0) + +lemma dimension_le_one (e : H →L[ℂ] H) : dimension M hfac hd e≤1 := by + apply csSup_le (Set.range_nonempty _) + rintro _ ⟨k,rfl⟩ + exact lower_le_one M hfac hd e k + +lemma upper_sub_lower (e : H →L[ℂ] H) (n : ℕ) : + upper M hfac hd e n-lower M hfac hd e n=(1:ℝ)/2^n := by + dsimp only [upper,lower] + rw [←sub_div] + congr 1 + ring + +lemma lower_tendsto_dimension {e : H →L[ℂ] H} (he : IsStarProjection e) : + Tendsto (lower M hfac hd e) atTop (𝓝 (dimension M hfac hd e)) := by + exact tendsto_atTop_ciSup (lower_monotone M hfac hd he) + ⟨1,by rintro _ ⟨k,rfl⟩; exact lower_le_one M hfac hd e k⟩ + +lemma dimension_mono_subEquivalent {e f : H →L[ℂ] H} (he : IsStarProjection e) + (h : SubEquivalent M e f) : dimension M hfac hd e≤dimension M hfac hd f := by + apply csSup_le (Set.range_nonempty _) + rintro _ ⟨k,rfl⟩ + apply le_trans _ (lower_le_dimension M hfac hd f k) + apply div_le_div_of_nonneg_right _ (by positivity) + exact_mod_cast (partition M hfac hd k).rank_mono_subEquivalent he h + +lemma dimension_congr_equivalent {e f : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) (h : Equivalent M e f) : + dimension M hfac hd e=dimension M hfac hd f := by + apply le_antisymm + · exact dimension_mono_subEquivalent M hfac hd he h.subEquivalent + · exact dimension_mono_subEquivalent M hfac hd hf h.symm.subEquivalent + +lemma dimension_one : dimension M hfac hd 1=1 := by + apply le_antisymm (dimension_le_one M hfac hd 1) + have h := lower_le_dimension M hfac hd 1 0 + simpa only [lower,EqualPartition.rank_one,cardinality,pow_zero,Nat.cast_one,div_one] using h + +lemma dimension_zero [Nontrivial H] (hfin : IsFiniteAlgebra M) : dimension M hfac hd 0=0 := by + apply le_antisymm _ (dimension_nonneg M hfac hd 0) + apply csSup_le (Set.range_nonempty _) + rintro _ ⟨k,rfl⟩ + simp only [lower,EqualPartition.rank_zero _ hfin,Nat.cast_zero,zero_div,le_refl] + +lemma dimension_pos [Nontrivial H] [TopologicalSpace.SeparableSpace H] + (hfin : IsFiniteAlgebra M) {e : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) (hen : e≠0) : 0 (2:ℝ)/2^n) atTop (𝓝 0) := by + have h := (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : 0≤(1/2:ℝ)) + (by norm_num : (1/2:ℝ)<1)).const_mul 2 + simpa only [div_pow,one_pow,mul_one_div,mul_zero] using h + +include hfin in +theorem dimension_orthogonal_add {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) (hef : e*f=0) : + dimension M hfac hd (e+f)=dimension M hfac hd e+dimension M hfac hd f := by + have heT := lower_tendsto_dimension M hfac hd he + have hfT := lower_tendsto_dimension M hfac hd hf + have hefT := lower_tendsto_dimension M hfac hd (he.add hf hef) + apply le_antisymm + · have ht := (heT.add hfT).add dyadic_error_tendsto + rw [add_zero] at ht + exact le_of_tendsto_of_tendsto hefT ht (Eventually.of_forall + (lower_orthogonal_add_upper M hfac hd hfin heM hfM he hf hef)) + · exact le_of_tendsto_of_tendsto (heT.add hfT) hefT (Eventually.of_forall + (lower_orthogonal_add_le M hfac hd hfin heM hfM he hf hef)) + +include hfin in +lemma dimension_complement {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) : + dimension M hfac hd (1-e)=1-dimension M hfac hd e := by + have h := dimension_orthogonal_add M hfac hd hfin heM (M.sub_mem M.one_mem heM) + he he.one_sub he.mul_one_sub_self + have ha : e+(1-e)=1 := by abel + rw [ha,dimension_one] at h + linarith + +end Kadison.PartialIsometryOrder.DyadicPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DyadicDimensionComparison.lean b/lean/OAI/Analysis/Commutator/DyadicDimensionComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..f7e1d1cbbc69f4ef857d6a10371d66eb4e164820 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DyadicDimensionComparison.lean @@ -0,0 +1,141 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicDimensionAdd +import OAI.Analysis.Commutator.ProjectionSumEquivalence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma Link.equivalentSupports {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + (v : Link M e f) : Equivalent M v.initial v.final := + ⟨⟨v.val,v.mem,v.triple,le_rfl,le_rfl⟩,rfl,rfl⟩ + +end Kadison.PartialIsometryOrder + +namespace Kadison.PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin in +lemma dimension_difference {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) (hfe : f≤e) : + dimension M hfac hd (e-f)=dimension M hfac hd e-dimension M hfac hd f := by + have hfe' := (hf.le_iff_mul_eq_left he).mp hfe + have hp := hf.sub_of_mul_eq_left he hfe' + have ho : f*(e-f)=0 := by rw [mul_sub,hfe',hf.isIdempotentElem.eq,sub_self] + have h := dimension_orthogonal_add M hfac hd hfin hfM (M.sub_mem heM hfM) hf hp ho + have ha : f+(e-f)=e := by abel + rw [ha] at h + linarith + +omit [Nontrivial H] in +lemma dimension_mono {e f : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) + (hef : e≤f) : dimension M hfac hd e≤dimension M hfac hd f := + dimension_mono_subEquivalent M hfac hd he (subEquivalent_of_le heM he hef) + +include hfin in +lemma dimension_finset_sum {ι : Type*} (e : ι → H →L[ℂ] H) + (heM : ∀ i,e i∈M) (he : ∀ i,IsStarProjection (e i)) + (hc : ∀ i j,i≠j → e i*e j=0) (s : Finset ι) : + dimension M hfac hd (∑ i∈s,e i)=∑ i∈s,dimension M hfac hd (e i) := by + classical + induction s using Finset.induction_on with + | empty => simpa only [Finset.sum_empty] using dimension_zero M hfac hd hfin + | @insert i s hi ih => + rw [Finset.sum_insert hi,Finset.sum_insert hi, + dimension_orthogonal_add M hfac hd hfin (heM i) (M.sum_mem fun j _ => heM j) + (he i) (orthogonal_sum_projection e he hc s) (orthogonal_mul_sum_eq_zero e hc s hi),ih] + +include hfin in +lemma dimension_base (n : ℕ) : + dimension M hfac hd (partition M hfac hd n).base=(1:ℝ)/2^n := by + let D := partition M hfac hd n + have hp : ∀ i,dimension M hfac hd (D.piece i)=dimension M hfac hd D.base := by + intro i + exact dimension_congr_equivalent M hfac hd (D.piece_projection i) D.base_projection + (D.base_equiv_piece i).symm + have hs := dimension_finset_sum M hfac hd hfin D.piece D.piece_mem D.piece_projection + D.piece_cross Finset.univ + change dimension M hfac hd (D.part Finset.univ)=_ at hs + rw [D.part_univ,dimension_one] at hs + simp only [hp,Finset.sum_const,Finset.card_univ,nsmul_eq_mul] at hs + change 1=(Fintype.card (Index n):ℝ)*dimension M hfac hd D.base at hs + rw [cardinality,Nat.cast_pow,Nat.cast_ofNat] at hs + apply (eq_div_iff (by positivity : (2:ℝ)^n≠0)).mpr + simpa only [mul_comm] using hs.symm + +section Separable + +variable [TopologicalSpace.SeparableSpace H] + +include hfin + +lemma dimension_eq_zero_iff {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) : + dimension M hfac hd e=0 ↔ e=0 := by + constructor + · intro h + by_contra hn + have hp := dimension_pos M hfac hd hfin heM he hn + linarith + · rintro rfl + exact dimension_zero M hfac hd hfin + +lemma subEquivalent_of_dimension_le {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) + (h : dimension M hfac hd e≤dimension M hfac hd f) : SubEquivalent M e f := by + rcases factor_subEquivalent_total M hfac heM hfM he hf with hcmp|hcmp + · exact hcmp + obtain ⟨v,hvi⟩ := hcmp + have hqM : v.final∈M := M.mul_mem v.mem (M.star_mem' v.mem) + have heq : dimension M hfac hd v.final=dimension M hfac hd f := by + exact dimension_congr_equivalent M hfac hd v.final_projection hf + (by simpa only [hvi] using v.equivalentSupports.symm) + have hdiff := dimension_difference M hfac hd hfin heM hqM he v.final_projection v.target_le + have hz : dimension M hfac hd (e-v.final)=0 := by + have hn := dimension_nonneg M hfac hd (e-v.final) + rw [heq] at hdiff + linarith + have heq' : v.final=e := sub_eq_zero.mp + ((dimension_eq_zero_iff M hfac hd hfin (M.sub_mem heM hqM) + (v.residual_target_projection he)).mp hz) |>.symm + refine ⟨v.adjoint,?_⟩ + simpa only [Link.adjoint_initial] using heq' + +lemma equivalent_of_dimension_eq {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) + (h : dimension M hfac hd e=dimension M hfac hd f) : Equivalent M e f := by + obtain ⟨v,hvi⟩ := subEquivalent_of_dimension_le M hfac hd hfin heM hfM he hf h.le + have hqM : v.final∈M := M.mul_mem v.mem (M.star_mem' v.mem) + have hq : dimension M hfac hd v.final=dimension M hfac hd e := + dimension_congr_equivalent M hfac hd v.final_projection he (by simpa only [hvi] using v.equivalentSupports.symm) + have hz : dimension M hfac hd (f-v.final)=0 := by + rw [dimension_difference M hfac hd hfin hfM hqM hf v.final_projection v.target_le,hq,h,sub_self] + have hp := (dimension_eq_zero_iff M hfac hd hfin (M.sub_mem hfM hqM) + (v.residual_target_projection hf)).mp hz + exact ⟨v,hvi,(sub_eq_zero.mp hp).symm⟩ + +end Separable + +end Kadison.PartialIsometryOrder.DyadicPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DyadicDimensionNormal.lean b/lean/OAI/Analysis/Commutator/DyadicDimensionNormal.lean new file mode 100644 index 0000000000000000000000000000000000000000..791f694b83da8c2855200be4c8f08e884d58602b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DyadicDimensionNormal.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Commutator.CoherentComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin in +theorem dimension_tendsto_of_strong_increasing {p : H →L[ℂ] H} + (hpM : p∈M) (hp : IsStarProjection p) (P : ℕ → H →L[ℂ] H) + (hPM : ∀ n,P n∈M) (hP : ∀ n,IsStarProjection (P n)) (hmono : Monotone P) + (hPp : ∀ n,P n≤p) (hlim : ∀ x,Tendsto (fun n => P n x) atTop (𝓝 (p x))) : + Tendsto (fun n => dimension M hfac hd (P n)) atTop (𝓝 (dimension M hfac hd p)) := by + let d (n : ℕ) := dimension M hfac hd (P n) + let L := sSup (Set.range d) + have hdmono : Monotone d := fun n m h => dimension_mono M hfac hd (hPM n) (hP n) (hmono h) + have hb : BddAbove (Set.range d) := ⟨1,by + rintro _ ⟨n,rfl⟩ + exact dimension_le_one M hfac hd (P n)⟩ + have hnL (n : ℕ) : d n≤L := le_csSup hb (Set.mem_range_self n) + have hLpos : 0≤L := (dimension_nonneg M hfac hd (P 0)).trans (hnL 0) + have hLp : L≤dimension M hfac hd p := by + apply csSup_le (Set.range_nonempty d) + rintro _ ⟨n,rfl⟩ + exact dimension_mono M hfac hd (hPM n) (hP n) (hPp n) + have hLeq : L=dimension M hfac hd p := by + by_contra hne + have hlt : L (1:ℝ)/2^n) atTop (𝓝 0) := by + simpa only [div_pow,one_pow] using + (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : 0≤(1/2:ℝ)) + (by norm_num : (1/2:ℝ)<1)) + obtain ⟨n,hn⟩ := (ht.eventually_lt_const (sub_pos.mpr hlt)).exists + let D := partition M hfac hd n + have hDb : dimension M hfac hd D.base=(1:ℝ)/2^n := dimension_base M hfac hd hfin n + have hDpos : 0 if b then w.val else a + have ha : IsStarProjection a := w.initial_projection + have hti : ∀ b,star (t b)*t b=a := by + intro b + cases b <;> simp only [t,Bool.false_eq_true,↓reduceIte,ha.isSelfAdjoint.star_eq, + ha.isIdempotentElem.eq] + rfl + have hts : ∀ b,t b*a=t b := by + intro b + cases b + · exact ha.isIdempotentElem.eq + · exact w.mul_initial + have htb : ∀ b,D.base*t b=t b := by + intro b + cases b + · exact (ha.le_iff_mul_eq_right D.base_projection).mp w.source_le + · exact w.target_mul D.base_projection + have htc : ∀ b c,b≠c → star (t b)*t c=0 := by + intro b c hbc + cases b <;> cases c + · exact (hbc rfl).elim + · simpa only [t,Bool.false_eq_true,↓reduceIte,ha.isSelfAdjoint.star_eq] using + w.initial_mul_self_eq_zero hww + · simpa only [t,Bool.false_eq_true,↓reduceIte,star_mul,star_zero,←show a=w.initial from rfl,ha.isSelfAdjoint.star_eq,star_star] using + congrArg star (w.initial_mul_self_eq_zero hww) + · exact (hbc rfl).elim + have hsumt : (∑ b : Bool,t b*star (t b))=D.base := by + simpa only [Fintype.sum_bool,t,Bool.false_eq_true,↓reduceIte, + ha.isSelfAdjoint.star_eq,ha.isIdempotentElem.eq,add_comm,a,Link.final] using hsum + refine ⟨a,M.mul_mem (M.star_mem' w.mem) w.mem,ha, + fun i => D.v i.1*t i.2,?_,?_,?_,?_,?_⟩ + · intro i + apply M.mul_mem (D.mem i.1) + cases i.2 + · exact M.mul_mem (M.star_mem' w.mem) w.mem + · exact w.mem + · intro i + rw [star_mul,show star (t i.2)*star (D.v i.1)*(D.v i.1*t i.2)= + star (t i.2)*(star (D.v i.1)*D.v i.1)*t i.2 by noncomm_ring, + D.initial,mul_assoc,htb,hti] + · intro i + rw [mul_assoc,hts] + · intro i j hij + rw [star_mul,show star (t i.2)*star (D.v i.1)*(D.v j.1*t j.2)= + star (t i.2)*(star (D.v i.1)*D.v j.1)*t j.2 by noncomm_ring] + by_cases he : i.1=j.1 + · rw [he,D.initial,mul_assoc,htb,htc i.2 j.2 (fun h => hij (Prod.ext he h))] + · rw [D.cross i.1 j.1 he,mul_zero,zero_mul] + · rw [Fintype.sum_prod_type] + simp only [star_mul] + calc + _=∑ i,D.v i*(∑ b : Bool,t b*star (t b))*star (D.v i) := by + apply Finset.sum_congr rfl + intro i hi + simp only [Finset.mul_sum,Finset.sum_mul] + apply Finset.sum_congr rfl + intro b hb + noncomm_ring + _=∑ i,D.v i*star (D.v i) := by simp only [hsumt,D.source] + _=1 := D.total + +lemma double_base (w : Link M D.base D.base) (hww : w.val*w.val=0) + (hsum : w.initial+w.final=D.base) : (D.double w hww hsum).base=w.initial := rfl + +lemma double_val (w : Link M D.base D.base) (hww : w.val*w.val=0) + (hsum : w.initial+w.final=D.base) (i : ι) (b : Bool) : + (D.double w hww hsum).v (i,b)=D.v i*(if b then w.val else w.initial) := rfl + +lemma base_ne_zero [Nontrivial H] : D.base≠0 := by + intro hz + have hv : ∀ i,D.v i=0 := by + intro i + simpa only [hz,mul_zero] using (D.source i).symm + have hone : (1 : H →L[ℂ] H)=0 := by + rw [←D.total] + simp only [hv,zero_mul,Finset.sum_const_zero] + exact one_ne_zero hone + +end EqualPartition + +namespace DyadicPartition + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) + +def Index : ℕ → Type + | 0 => Unit + | n+1 => Index n × Bool + +instance indexFintype : (n : ℕ) → Fintype (Index n) + | 0 => inferInstanceAs (Fintype Unit) + | n+1 => @instFintypeProd (Index n) Bool (indexFintype n) inferInstance + +instance indexNonempty : (n : ℕ) → Nonempty (Index n) + | 0 => inferInstanceAs (Nonempty Unit) + | n+1 => @instNonemptyProd (Index n) Bool (indexNonempty n) inferInstance + +def partition : (n : ℕ) → EqualPartition M (Index n) + | 0 => EqualPartition.singleton M + | n+1 => + let D := partition n + let e : ProjectionIn M := ⟨D.base,D.base_mem,D.base_projection⟩ + D.double (DyadicCuts.half M hfac hd e) (DyadicCuts.half_square M hfac hd e) + (DyadicCuts.half_sum M hfac hd e) + +lemma cardinality (n : ℕ) : Fintype.card (Index n)=2^n := by + induction n with + | zero => rfl + | succ n ih => + change Fintype.card (Index n × Bool)=2^(n+1) + rw [Fintype.card_prod,Fintype.card_bool,ih,pow_succ] + +lemma base_eq_cut (n : ℕ) : (partition M hfac hd n).base=(DyadicCuts.cut M hfac hd n).val := by + induction n with + | zero => rfl + | succ n ih => + change (DyadicCuts.half M hfac hd ⟨(partition M hfac hd n).base,_,_⟩).initial=_ + have he : (⟨(partition M hfac hd n).base,(partition M hfac hd n).base_mem, + (partition M hfac hd n).base_projection⟩ : ProjectionIn M)=DyadicCuts.cut M hfac hd n := by + cases h : DyadicCuts.cut M hfac hd n + simp only [h] at ih + cases ih + rfl + rw [he] + rfl + +lemma exists_base_subEquivalent [TopologicalSpace.SeparableSpace H] + (hfin : IsFiniteAlgebra M) {e : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) (hen : e≠0) : + ∃ n,SubEquivalent M (partition M hfac hd n).base e := by + obtain ⟨n,hn⟩ := DyadicCuts.exists_subEquivalent M hfac hd hfin heM he hen + exact ⟨n,by rwa [base_eq_cut]⟩ + +end DyadicPartition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/DyadicRankStep.lean b/lean/OAI/Analysis/Commutator/DyadicRankStep.lean new file mode 100644 index 0000000000000000000000000000000000000000..3327b434a9d25ace110d8df693d40fb0363c153b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/DyadicRankStep.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicPartition +import OAI.Analysis.Commutator.EqualPartitionSums +import OAI.Analysis.Commutator.PartitionRank + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance : DecidableEq ι := Classical.decEq ι + +variable (w : Link M D.base D.base) (hww : w.val*w.val=0) (hsum : w.initial+w.final=D.base) + +lemma double_piece_sum (i : ι) : + (∑ b : Bool,(D.double w hww hsum).piece (i,b))=D.piece i := by + rw [Fintype.sum_bool] + simp only [piece,double_val,Bool.false_eq_true,↓reduceIte,star_mul, + w.initial_projection.isSelfAdjoint.star_eq] + have hi : w.initial*w.initial=w.initial := w.initial_projection.isIdempotentElem.eq + calc + _=D.v i*(w.final+w.initial*w.initial)*star (D.v i) := by + dsimp only [Link.final] + noncomm_ring + _=D.v i*D.base*star (D.v i) := by rw [hi,add_comm w.final,hsum] + _=D.piece i := by rw [D.source]; rfl + +lemma double_part (s : Finset ι) : + (D.double w hww hsum).part ((s ×ˢ Finset.univ))=D.part s := by + change (∑ j∈(s ×ˢ Finset.univ),(D.double w hww hsum).piece j)=_ + rw [Finset.sum_product] + simp only [double_piece_sum] + rfl + +lemma double_rank_lower {e : H →L[ℂ] H} (he : IsStarProjection e) : + 2*D.rank e≤(D.double w hww hsum).rank e := by + obtain ⟨s,hs,hse⟩ := D.exists_rank e he + have h := (D.double w hww hsum).card_le_rank_of_subEquivalent ((s ×ˢ Finset.univ)) + (by rwa [D.double_part w hww hsum]) + simpa only [Finset.card_product,Finset.card_univ,Fintype.card_bool,hs,Nat.mul_comm] using h + +lemma double_rank_upper {e : H →L[ℂ] H} (he : IsStarProjection e) : + (D.double w hww hsum).rank e≤2*D.rank e+1 := by + by_cases hk : D.rank e=Fintype.card ι + · have h := (D.double w hww hsum).rank_le_card e + rw [Fintype.card_prod,Fintype.card_bool] at h + omega + have hklt : D.rank e.add_right + ((Commute.one_right p).sub_right hc))) (CFC.negPart_nonneg b) + +lemma halfCut_commutes {T A : H →L[ℂ] H} (hTA : Commute T A) (hTAstar : Commute T (star A)) : + Commute (halfCut T) A := by + let b := T+T-1 + have hb : Commute b A := (hTA.add_left hTA).sub_left (Commute.one_left A) + have hbs : Commute b (star A) := (hTAstar.add_left hTAstar).sub_left (Commute.one_left (star A)) + change Commute (rightSupport b⁺) A + simpa only [partialIsometry_of_nonneg (CFC.posPart_nonneg b)] using + partialIsometry_commutes b⁺ A (hb.cfcₙ_real (·⁺)) (hbs.cfcₙ_real (·⁺)) + +def dyadicRemainder (T : H →L[ℂ] H) : ℕ → H →L[ℂ] H + | 0 => T + | n+1 => binaryRemainder (dyadicRemainder T n) + +lemma dyadicRemainder_bounds {T : H →L[ℂ] H} (hT : 0≤T) (hT1 : T≤1) (n : ℕ) : + 0≤dyadicRemainder T n ∧ dyadicRemainder T n≤1 := by + induction n with + | zero => exact ⟨hT,hT1⟩ + | succ n ih => exact ⟨binaryRemainder_nonneg ih.1,binaryRemainder_le_one ih.1 ih.2⟩ + +lemma dyadicRemainder_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) (n : ℕ) : + dyadicRemainder T n∈M := by + induction n with + | zero => exact hT + | succ n ih => exact M.toStarSubalgebra.sub_mem (M.add_mem ih ih) (halfCut_mem M ih) + +def dyadicStep (T : H →L[ℂ] H) (n : ℕ) : H →L[ℂ] H := + ∑ i∈Finset.range n, ((2:ℝ)⁻¹^(i+1)) • halfCut (dyadicRemainder T i) + +lemma dyadicStep_remainder (T : H →L[ℂ] H) (n : ℕ) : + T-dyadicStep T n=((2:ℝ)⁻¹^n) • dyadicRemainder T n := by + induction n with + | zero => simp [dyadicStep,dyadicRemainder] + | succ n ih => + rw [dyadicStep,Finset.sum_range_succ] + rw [←dyadicStep] + change T-(dyadicStep T n+_)=_ + rw [sub_add_eq_sub_sub,ih] + simp only [dyadicRemainder,binaryRemainder,smul_sub,smul_add,pow_succ] + module + +lemma dyadicStep_norm_error {T : H →L[ℂ] H} (hT : 0≤T) (hT1 : T≤1) (n : ℕ) : + ‖T-dyadicStep T n‖≤(2:ℝ)⁻¹^n := by + rw [dyadicStep_remainder,norm_smul,Real.norm_of_nonneg (by positivity)] + have hb := dyadicRemainder_bounds hT hT1 n + exact mul_le_of_le_one_right (by positivity) ((CStarAlgebra.norm_le_one_iff_of_nonneg _ hb.1).mpr hb.2) + +lemma dyadicRemainder_commutes {T A : H →L[ℂ] H} (hA : IsSelfAdjoint A) + (hTA : Commute T A) (n : ℕ) : Commute (dyadicRemainder T n) A := by + induction n with + | zero => exact hTA + | succ n ih => + exact (ih.add_left ih).sub_left (halfCut_commutes ih (by simpa only [hA.star_eq] using ih)) + +lemma dyadicCut_commutes_original {T : H →L[ℂ] H} (hT : IsSelfAdjoint T) (n : ℕ) : + Commute (halfCut (dyadicRemainder T n)) T := by + have hc := dyadicRemainder_commutes hT (Commute.refl T) n + exact halfCut_commutes hc (by simpa only [hT.star_eq] using hc) + +lemma dyadicCuts_commute {T : H →L[ℂ] H} (hT : IsSelfAdjoint T) (n m : ℕ) : + Commute (halfCut (dyadicRemainder T n)) (halfCut (dyadicRemainder T m)) := by + have hp : IsSelfAdjoint (halfCut (dyadicRemainder T m)) := + (isProjection_halfCut _).isSelfAdjoint + have hc := dyadicRemainder_commutes hp (dyadicCut_commutes_original hT m).symm n + exact halfCut_commutes hc (by simpa only [hp.star_eq] using hc) + +theorem exists_positive_spectral_sum (M : VonNeumannAlgebra H) + {T : H →L[ℂ] H} (hTM : T∈M) (hT : 0≤T) (hT1 : T≤1) {ε : ℝ} (hε : 0<ε) : + ∃ n : ℕ, ∃ p : Fin n → H →L[ℂ] H, ∃ c : Fin n → ℝ, + (∀ i,p i∈M ∧ IsStarProjection (p i)) ∧ + (∀ i j,Commute (p i) (p j)) ∧ ‖T-∑ i,c i • p i‖<ε := by + obtain ⟨n,hn⟩ := exists_pow_lt_of_lt_one hε (by norm_num : (2:ℝ)⁻¹<1) + refine ⟨n,fun i => halfCut (dyadicRemainder T i.val),fun i => (2:ℝ)⁻¹^(i.val+1), + fun i => ⟨halfCut_mem M (dyadicRemainder_mem M hTM i.val),isProjection_halfCut _⟩, + fun i j => dyadicCuts_commute (IsSelfAdjoint.of_nonneg hT) i.val j.val,?_⟩ + rw [Fin.sum_univ_eq_sum_range (fun i : ℕ => + (2:ℝ)⁻¹^(i+1) • halfCut (dyadicRemainder T i))] + exact (dyadicStep_norm_error hT hT1 n).trans_lt hn + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EmbeddedCyclicImplementation.lean b/lean/OAI/Analysis/Commutator/EmbeddedCyclicImplementation.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5658f2d589ed3d455a003ee4155ef00e599c9a3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EmbeddedCyclicImplementation.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicImplementationUnconditional + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.CyclicSpatial + +open ReducingRepresentation + +variable {A K H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (j : K →ₗᵢ[ℂ] H) (hj : ∀ a x, j (σ a x)=ρ a (j x)) + +local instance : NormedAddCommGroup (K →L[ℂ] H) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] H) := ContinuousLinearMap.toNormedSpace + +include hj in +omit [PartialOrder A] [StarOrderedRing A] in +lemma range_invariant (a : A) (x : H) (hx : x∈LinearMap.range j.toLinearMap) : + ρ a x∈LinearMap.range j.toLinearMap := by + obtain ⟨y,rfl⟩ := hx + exact ⟨σ a y,hj a y⟩ + +include hj in +theorem exists_embedded_cyclic_intertwiner (M : VonNeumannAlgebra H) + (hρ : Function.Injective ρ) (hrange : Set.range ρ=(M : Set (H →L[ℂ] H))) + (G : K →L[ℂ] H) (Ω : K) (hΩ : DenseRange (fun a : A => σ a Ω)) + {ε : ℝ} (hε : 0≤ε) + (hδ : ∀ a : A, ‖G.comp (σ a)-(ρ a).comp G‖≤ε*‖a‖) : + ∃ T : K →L[ℂ] H, (∀ a : A,T.comp (σ a)=(ρ a).comp T) ∧ ‖G-T‖≤16*ε := by + let J := LinearMap.range j.toLinearMap + let e : K ≃ₗᵢ[ℂ] J := j.equivRange + let : CompleteSpace J := e.symm.toIsometryEquiv.completeSpace + let : NormedAddCommGroup (J →L[ℂ] H) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℂ (J →L[ℂ] H) := ContinuousLinearMap.toNormedSpace + let hinv := range_invariant σ ρ j hj + let ρJ := restrict ρ J hinv + have he (a : A) (x : K) : e (σ a x)=ρJ a (e x) := by + apply Subtype.ext + exact hj a x + have hes (a : A) (x : J) : e.symm (ρJ a x)=σ a (e.symm x) := by + apply e.injective + rw [LinearIsometryEquiv.apply_symm_apply,he,LinearIsometryEquiv.apply_symm_apply] + have hΩJ : DenseRange (fun a : A => ρJ a (e Ω)) := by + have hh := e.surjective.denseRange.comp hΩ e.continuous + have heq : (fun a : A => ρJ a (e Ω)) = e ∘ (fun a : A => σ a Ω) := + funext (fun a => (he a Ω).symm) + rw [heq] + exact hh + let GJ := G.comp e.symm.toLinearIsometry.toContinuousLinearMap + have hed (a : A) : delta ρ J hinv GJ a= + (G.comp (σ a)-(ρ a).comp G).comp e.symm.toLinearIsometry.toContinuousLinearMap := by + ext x + change G (e.symm (ρJ a x))-ρ a (G (e.symm x))=G (σ a (e.symm x))-ρ a (G (e.symm x)) + rw [hes] + have hd : ‖delta ρ J hinv GJ‖≤ε := by + apply ContinuousLinearMap.opNorm_le_bound _ hε + intro a + rw [hed] + calc + _ ≤ ‖G.comp (σ a)-(ρ a).comp G‖*‖e.symm.toLinearIsometry.toContinuousLinearMap‖ := opNorm_comp_le _ _ + _ ≤ (ε*‖a‖)*1 := mul_le_mul (hδ a) e.symm.toLinearIsometry.norm_toContinuousLinearMap_le + (ContinuousLinearMap.opNorm_nonneg _) (mul_nonneg hε (norm_nonneg _)) + _ = _ := mul_one _ + obtain ⟨T,hT,hn⟩ := exists_cyclic_intertwiner_unconditional ρ J hinv M hρ hrange GJ (e Ω) hΩJ + refine ⟨T.comp e.toLinearIsometry.toContinuousLinearMap,?_,?_⟩ + · intro a + ext x + change T (e (σ a x))=ρ a (T (e x)) + rw [he] + exact congrArg (fun R : J →L[ℂ] H => R (e x)) (hT a) + · have heq : G-T.comp e.toLinearIsometry.toContinuousLinearMap=(GJ-T).comp e.toLinearIsometry.toContinuousLinearMap := by + ext x + change G x-T (e x)=G (e.symm (e x))-T (e x) + rw [LinearIsometryEquiv.symm_apply_apply] + rw [heq] + calc + _ ≤ ‖GJ-T‖*‖e.toLinearIsometry.toContinuousLinearMap‖ := opNorm_comp_le _ _ + _ ≤ (16*‖delta ρ J hinv GJ‖)*1 := mul_le_mul hn e.toLinearIsometry.norm_toContinuousLinearMap_le + (ContinuousLinearMap.opNorm_nonneg _) (by positivity) + _ ≤ 16*ε := by nlinarith + +end Kadison.CyclicSpatial + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointElimination.lean b/lean/OAI/Analysis/Commutator/EndpointElimination.lean new file mode 100644 index 0000000000000000000000000000000000000000..b082861c00b22f6eed1049daf445e8c24aa2b6c0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointElimination.lean @@ -0,0 +1,48 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion + +namespace Kadison + +theorem coefficient_zero_of_unbounded_stages + (z : ℂ) (C : ℝ) (p c : ℕ) (m : ℕ → ℕ) + (hm : ∀ B : ℕ, ∃ n, B ≤ m n) + (hbound : ∀ n, ‖z‖ ^ 2 * (m n : ℝ) ^ (p + 1) ≤ + C ^ 2 * (m n : ℝ) ^ (2 * c)) + (hc : 2 * c < p + 1) : z = 0 := by + by_contra hz + have hl : 0 < ‖z‖ ^ 2 := sq_pos_of_pos (norm_pos_iff.mpr hz) + obtain ⟨B, hB⟩ := exists_nat_gt (max (C ^ 2 / ‖z‖ ^ 2) 1) + obtain ⟨n, hn⟩ := hm B + have hmn : (B : ℝ) ≤ m n := by exact_mod_cast hn + have hm1 : 1 < (m n : ℝ) := (lt_of_le_of_lt (le_max_right _ _) hB).trans_le hmn + have ht : C ^ 2 / ‖z‖ ^ 2 < (m n : ℝ) := + (lt_of_le_of_lt (le_max_left _ _) hB).trans_le hmn + have hh := hbound n + have hpow : (m n : ℝ) ^ (2 * c + 1) ≤ (m n : ℝ) ^ (p + 1) := + pow_le_pow_right₀ hm1.le hc + have hpowpos : 0 < (m n : ℝ) ^ (2 * c) := pow_pos (by linarith) _ + have hh' : ‖z‖ ^ 2 * (m n : ℝ) ^ (2 * c + 1) ≤ + C ^ 2 * (m n : ℝ) ^ (2 * c) := + (mul_le_mul_of_nonneg_left hpow hl.le).trans hh + rw [pow_succ (m n : ℝ) (2 * c)] at hh' + have hle : ‖z‖ ^ 2 * (m n : ℝ) ≤ C ^ 2 := by + apply (mul_le_mul_iff_right₀ hpowpos).mp + simpa only [mul_assoc, mul_comm, mul_left_comm] using hh' + have hgt : C ^ 2 < (m n : ℝ) * ‖z‖ ^ 2 := (div_lt_iff₀ hl).mp ht + nlinarith + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointElimination2.lean b/lean/OAI/Analysis/Commutator/EndpointElimination2.lean new file mode 100644 index 0000000000000000000000000000000000000000..bfcbf74dc4114caefc8f6529f1808de4f1a77a1a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointElimination2.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Commutator.EndpointModule2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +variable {I : Type*} [Fintype I] [DecidableEq I] + +def matrixL1 (A : Matrix I I ℂ) : ℝ := + (normalizedTrace (CFC.sqrt (star A * A))).re + +def matrixL2 (A : Matrix I I ℂ) : ℝ := + Real.sqrt (normalizedTrace (star A * A)).re + +lemma single_nonneg (j : I) : 0 ≤ Matrix.single j j (1 : ℂ) := by + have h := star_mul_self_nonneg (Matrix.single j j (1 : ℂ)) + simpa only [Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, + star_one, Matrix.single_mul_single_same, one_mul] using h + +lemma sqrt_single (j : I) : + CFC.sqrt (Matrix.single j j (1 : ℂ)) = Matrix.single j j (1 : ℂ) := by + apply (CFC.sqrt_eq_iff _ _ (single_nonneg j) (single_nonneg j)).mpr + simp only [Matrix.single_mul_single_same, one_mul] + +@[simp] theorem matrixL1_single (i j : I) : + matrixL1 (Matrix.single i j 1) = (Fintype.card I : ℝ)⁻¹ := by + simp only [matrixL1, Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, + star_one, Matrix.single_mul_single_same, sqrt_single, + normalizedTrace, Matrix.trace_single_eq_same, mul_one] + simp only [← Complex.ofReal_natCast, ← Complex.ofReal_inv, Complex.ofReal_re] + +@[simp] theorem matrixL2_single (i j : I) : + matrixL2 (Matrix.single i j 1) = Real.sqrt (Fintype.card I : ℝ)⁻¹ := by + simp only [matrixL2, Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, + star_one, Matrix.single_mul_single_same, + normalizedTrace, Matrix.trace_single_eq_same, mul_one] + congr 1 + simp only [← Complex.ofReal_natCast, ← Complex.ofReal_inv, Complex.ofReal_re] + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointElimination3.lean b/lean/OAI/Analysis/Commutator/EndpointElimination3.lean new file mode 100644 index 0000000000000000000000000000000000000000..bab2f478a5dd9a61127147979a8cec64bfc5b878 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointElimination3.lean @@ -0,0 +1,38 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +theorem square_endpoint_unit_bound (r C m : ℝ) (p c : ℕ) + (hr : 0 ≤ r) (hC : 0 ≤ C) (hm : 0 < m) (hp : 1 ≤ p) + (h : r * (m⁻¹) ^ c ≤ C * m⁻¹ * (Real.sqrt m⁻¹) ^ (p - 1)) : + r ^ 2 * m ^ (p + 1) ≤ C ^ 2 * m ^ (2 * c) := by + have hq : 0 ≤ m⁻¹ := inv_nonneg.mpr hm.le + have hleft : (r * (m⁻¹) ^ c) ^ 2 = r ^ 2 * (m⁻¹) ^ (2 * c) := by + rw [mul_pow, ← pow_mul, Nat.mul_comm c 2] + have hright : (C * m⁻¹ * (Real.sqrt m⁻¹) ^ (p - 1)) ^ 2 = + C ^ 2 * (m⁻¹) ^ (p + 1) := by + simp only [mul_pow] + rw [pow_right_comm (Real.sqrt m⁻¹) (p - 1) 2, Real.sq_sqrt hq, + mul_assoc, ← pow_add, show 2 + (p - 1) = p + 1 by omega] + have hs := (sq_le_sq₀ (mul_nonneg hr (pow_nonneg hq _)) + (mul_nonneg (mul_nonneg hC hq) (pow_nonneg (Real.sqrt_nonneg _) _))).mpr h + rw [hleft, hright, inv_pow, inv_pow, ← div_eq_mul_inv, ← div_eq_mul_inv] at hs + exact (div_le_div_iff₀ (pow_pos hm _) (pow_pos hm _)).mp hs + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointGNS.lean b/lean/OAI/Analysis/Commutator/EndpointGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..b4113a99762620dbf6de80e4e4773de1575b9338 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointGNS.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleEmbeddings2 +import OAI.Analysis.Commutator.MatrixGNS +import OAI.Analysis.Commutator.TensorActions + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +abbrev fullSpace : PreHilbert := ⟨τ.GNS⟩ + +abbrev zeroSpace : PreHilbert := ⟨centeredSpace (vacuum τ)⟩ + +noncomputable def wordConjugation (u : unitary A) (k : ℕ) : + wordSpace (fullSpace τ) (zeroSpace τ) k →ₗᵢ[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) k := + wordMap (fullSpace τ) (zeroSpace τ) (conjugation τ hτ u) + (centeredIsometry (vacuum τ) (conjugation τ hτ u) (conjugation_vacuum τ hτ u)) k + +variable {k l : ℕ} + +variable (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +noncomputable def stageCoefficient (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) : + MultilinearMap ℂ (fun _ : Option (Fin k ⊕ Fin l) => Matrix I I ℂ) ℂ := + coefficientMultilinear (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ φ) (centeredStageVector τ φ) + +omit [Nonempty I] in +include h1 in +lemma stageCoefficient_invariant (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (u : unitary (Matrix I I ℂ)) + (hY : Y.comp (wordConjugation τ hτ (stageUnitary φ u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary φ u) l).toContinuousLinearMap.comp Y) + (v : Option (Fin k ⊕ Fin l) → Matrix I I ℂ) : + stageCoefficient τ Y φ (fun i => (u : Matrix I I ℂ) * v i * star (u : Matrix I I ℂ)) = + stageCoefficient τ Y φ v := by + apply coefficient_invariant (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ φ) (centeredStageVector τ φ) (conjugation τ hτ (stageUnitary φ u)) + (centeredIsometry (vacuum τ) (conjugation τ hτ (stageUnitary φ u)) + (conjugation_vacuum τ hτ _)) (fun a => (u : Matrix I I ℂ) * a * star (u : Matrix I I ℂ)) + · intro a + simp only [star_mul, star_star, mul_assoc] + · intro a + exact (stage_conjugation τ hτ φ u a).symm + · intro a + exact (centered_stage_conjugation τ hτ h1 φ u a).symm + · exact conjugation_vacuum τ hτ _ + · exact hY + +variable {K : Type*} [Fintype K] [DecidableEq K] [Nonempty K] + +omit [Nonempty I] [Nonempty K] in +lemma stageCoefficient_compatible (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (ψ : Matrix K K ℂ →⋆ₐ[ℂ] A) (e : Matrix I I ℂ →⋆ₐ[ℂ] Matrix K K ℂ) + (he : ∀ a, ψ (e a) = φ a) (v : Option (Fin k ⊕ Fin l) → Matrix I I ℂ) : + stageCoefficient τ Y ψ (fun i => e (v i)) = stageCoefficient τ Y φ v := by + change coefficient (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ ψ) (centeredStageVector τ ψ) (fun i => e (v i)) = + coefficient (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ φ) (centeredStageVector τ φ) v + simp only [coefficient, stageVector, centeredStageVector, LinearMap.comp_apply, + AlgHom.toLinearMap_apply, StarAlgHom.coe_toAlgHom, map_star, he] + +include h1 in +theorem stageCoefficient_expansion (I : ℕ → Type*) + [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) : + ∃ c : Equiv.Perm (Option (Fin k ⊕ Fin l)) → ℂ, + ∀ n (v : Option (Fin k ⊕ Fin l) → Matrix (I n) (I n) ℂ), + stageCoefficient τ Y (φ n) v = ∑ σ, c σ * SchurWeyl.cycleTrace σ v := by + apply SchurWeyl.matrix_union_expansion I (fun h => (e h).toAlgHom) hsize + (fun n => stageCoefficient τ Y (φ n)) + · intro n u v + exact stageCoefficient_invariant τ hτ h1 Y (φ n) u (hY n u) v + · intro n m h v + exact stageCoefficient_compatible τ Y (φ n) (φ m) (e h) (he n m h) v + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointGNS2.lean b/lean/OAI/Analysis/Commutator/EndpointGNS2.lean new file mode 100644 index 0000000000000000000000000000000000000000..e87132acf0836c2b9cfdd811e802b1a0ed345c43 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointGNS2.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Commutator.EndpointGNS +import OAI.Analysis.Commutator.EndpointModule2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +noncomputable def stageRepresentation (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) : + Matrix I I ℂ →⋆ₐ[ℂ] (τ.GNS →L[ℂ] τ.GNS) := τ.gnsStarAlgHom.comp φ + +omit [Nonempty I] in +@[simp] lemma stageRepresentation_vacuum (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (a : Matrix I I ℂ) : + stageRepresentation τ φ a (vacuum τ) = stageVector τ φ a := by + change τ.gnsStarAlgHom (φ a) (τ.toPreGNS 1 : τ.GNS) = (τ.toPreGNS (φ a) : τ.GNS) + rw [left_coe, mul_one] + +include hτ h1 in +lemma stageRepresentation_trace (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (a : Matrix I I ℂ) : + inner ℂ (vacuum τ) (stageRepresentation τ φ a (vacuum τ)) = normalizedTrace a := by + rw [stageRepresentation_vacuum] + change inner ℂ (vacuum τ) (algebraVector τ (φ a)) = _ + rw [inner_vacuum_algebraVector, stage_trace τ hτ h1 φ] + rfl + +include hτ h1 in +lemma norm_centeredStageVector_single (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (i j : I) : + ‖centeredStageVector τ φ (Matrix.single i j 1)‖ ≤ Real.sqrt (Fintype.card I : ℝ)⁻¹ := by + calc + _ ≤ ‖stageVector τ φ (Matrix.single i j 1)‖ := + norm_center_le (vacuum τ) _ + _ = _ := by + rw [← stageRepresentation_vacuum] + exact MatrixModule.norm_vector_single (stageRepresentation τ φ) (vacuum τ) + (stageRepresentation_trace τ hτ h1 φ) i j + +noncomputable def wordLeft (a : A) (k : ℕ) : + wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) k := + HilbertTensor.map (τ.gnsStarAlgHom a) (1 : power (zeroSpace τ) k →L[ℂ] power (zeroSpace τ) k) + +variable {k l : ℕ} + +variable (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +include hτ h1 in +lemma stageCoefficient_rank_one (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (hY : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) + (b : Option (Fin k ⊕ Fin l) → I) + (σ : Equiv.Perm (Option (Fin k ⊕ Fin l))) : + ‖stageCoefficient τ Y φ (fun j => Matrix.single (b (σ j)) (b j) 1)‖ ≤ + ‖Y‖ * (Fintype.card I : ℝ)⁻¹ * + (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ (Fintype.card (Option (Fin k ⊕ Fin l)) - 1) := by + let v : Option (Fin k ⊕ Fin l) → Matrix I I ℂ := + fun j => Matrix.single (b (σ j)) (b j) 1 + have hleft (a : Matrix I I ℂ) : + Y.comp (HilbertTensor.map (stageRepresentation τ φ a) + (1 : power (zeroSpace τ) k →L[ℂ] power (zeroSpace τ) k)) = + (HilbertTensor.map (stageRepresentation τ φ a) + (1 : power (zeroSpace τ) l →L[ℂ] power (zeroSpace τ) l)).comp Y := hY (φ a) + have h := MatrixModule.endpoint_unit_bound (stageRepresentation τ φ) (vacuum τ) + (stageRepresentation_trace τ hτ h1 φ) Y hleft (b none) (b (σ none)) + (pure (zeroSpace τ) k (fun i => centeredStageVector τ φ (v (some (.inl i))))) + (pure (zeroSpace τ) l (fun i => centeredStageVector τ φ (star (v (some (.inr i)))))) + have hs (j) : star (v j) = Matrix.single (b j) (b (σ j)) 1 := by + simp only [v, Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, star_one] + have hcoeff : ‖stageCoefficient τ Y φ v‖ ≤ + ‖Y‖ * (Fintype.card I : ℝ)⁻¹ * + ‖pure (zeroSpace τ) k (fun i => centeredStageVector τ φ (v (some (.inl i))))‖ * + ‖pure (zeroSpace τ) l (fun i => centeredStageVector τ φ (star (v (some (.inr i)))))‖ := by + change ‖coefficient (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ φ) (centeredStageVector τ φ) v‖ ≤ _ + simpa only [coefficient, word, hs, stageRepresentation_vacuum] using h + have hx : ‖pure (zeroSpace τ) k (fun i => centeredStageVector τ φ (v (some (.inl i))))‖ ≤ + (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ k := by + rw [norm_pure] + calc + _ ≤ ∏ _ : Fin k, Real.sqrt (Fintype.card I : ℝ)⁻¹ := + Finset.prod_le_prod₀ (by intros; positivity) (fun i _ => norm_centeredStageVector_single τ hτ h1 φ _ _) + _ = _ := by simp + have hz : ‖pure (zeroSpace τ) l (fun i => centeredStageVector τ φ (star (v (some (.inr i)))))‖ ≤ + (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ l := by + rw [norm_pure] + calc + _ ≤ ∏ _ : Fin l, Real.sqrt (Fintype.card I : ℝ)⁻¹ := + Finset.prod_le_prod₀ (by intros; positivity) (fun i _ => by + rw [hs]; exact norm_centeredStageVector_single τ hτ h1 φ _ _) + _ = _ := by simp + calc + _ ≤ _ := hcoeff + _ ≤ ‖Y‖ * (Fintype.card I : ℝ)⁻¹ * + (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ k * (Real.sqrt (Fintype.card I : ℝ)⁻¹) ^ l := by + gcongr + _ = _ := by simp only [Fintype.card_option, Fintype.card_sum, Fintype.card_fin, + Nat.add_sub_cancel_right, pow_add]; ring + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointModule.lean b/lean/OAI/Analysis/Commutator/EndpointModule.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd139203c31c98dcab0cd21bec70791d60016074 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointModule.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorDevelopment + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion + +namespace Kadison.HilbertTensor + +variable {E F G : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + +lemma inner_map_left_symmetric (a : E →L[ℂ] E) + (ha : ∀ x y, inner ℂ (a x) y = inner ℂ x (a y)) + (x y : Completion (E ⊗[ℂ] F)) : + inner ℂ (map a (1 : F →L[ℂ] F) x) y = + inner ℂ x (map a (1 : F →L[ℂ] F) y) := by + induction x, y using Completion.induction_on₂ with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x y => + induction x using TensorProduct.inductionOn with + | add x x' hx hx' => + simp only [Completion.coe_add, map_add, inner_add_left, hx, hx'] + | tmul x v => + induction y using TensorProduct.inductionOn with + | add y y' hy hy' => + simp only [Completion.coe_add, map_add, inner_add_right, hy, hy'] + | tmul y w => + simp only [map_coe_tmul, one_apply_eq_self, Completion.inner_coe, + TensorProduct.inner_tmul, ha] + +lemma endpoint_projection_bound + (Y : Completion (E ⊗[ℂ] F) →L[ℂ] Completion (E ⊗[ℂ] G)) + (p : E →L[ℂ] E) + (hp : ∀ x y, inner ℂ (p x) y = inner ℂ x (p y)) + (hY : Y.comp (map p (1 : F →L[ℂ] F)) = + (map p (1 : G →L[ℂ] G)).comp Y) + (Ω a : E) (ha : p a = a) (x : F) (z : G) : + ‖inner ℂ ((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) + (Y ((Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _))‖ ≤ + ‖Y‖ * ‖a‖ * ‖p Ω‖ * ‖x‖ * ‖z‖ := by + have htest : map p (1 : G →L[ℂ] G) + ((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) = + ((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) := by + simp [ha] + have heq : inner ℂ ((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) + (Y ((Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _)) = + inner ℂ ((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) + (Y ((p Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _)) := by + conv_lhs => rw [← htest] + rw [inner_map_left_symmetric p hp, ← ContinuousLinearMap.comp_apply, + ← hY, ContinuousLinearMap.comp_apply, map_coe_tmul, one_apply_eq_self] + rw [heq] + calc + _ ≤ ‖((a ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _)‖ * + ‖Y ((p Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _)‖ := norm_inner_le_norm _ _ + _ ≤ (‖a‖ * ‖z‖) * (‖Y‖ * (‖p Ω‖ * ‖x‖)) := by + simp only [Completion.norm_coe, TensorProduct.norm_tmul] + gcongr + simpa only [Completion.norm_coe, TensorProduct.norm_tmul] using + (Y.le_opNorm ((p Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _)) + _ = _ := by ring + +end Kadison.HilbertTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointModule2.lean b/lean/OAI/Analysis/Commutator/EndpointModule2.lean new file mode 100644 index 0000000000000000000000000000000000000000..31d684bf90755efeb0c79cc4dae6b6758a979796 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointModule2.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.EndpointModule + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion + +namespace Kadison + +variable {I : Type*} [Fintype I] [DecidableEq I] + +def normalizedTrace (A : Matrix I I ℂ) : ℂ := + (Fintype.card I : ℂ)⁻¹ * Matrix.trace A + +namespace MatrixModule + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + +variable (ρ : Matrix I I ℂ →⋆ₐ[ℂ] (E →L[ℂ] E)) (Ω : E) + (htrace : ∀ a, inner ℂ Ω (ρ a Ω) = normalizedTrace a) + +include htrace in +lemma inner_vector (a b : Matrix I I ℂ) : + inner ℂ (ρ a Ω) (ρ b Ω) = normalizedTrace (star a * b) := by + rw [← ContinuousLinearMap.adjoint_inner_right] + change inner ℂ Ω (star (ρ a) (ρ b Ω)) = _ + rw [← map_star] + change inner ℂ Ω ((ρ (star a) * ρ b) Ω) = _ + rw [← map_mul, htrace] + +include htrace in +lemma norm_vector_single (i j : I) : + ‖ρ (Matrix.single i j 1) Ω‖ = Real.sqrt (Fintype.card I : ℝ)⁻¹ := by + have hs : ‖ρ (Matrix.single i j 1) Ω‖ ^ 2 = (Fintype.card I : ℝ)⁻¹ := by + rw [norm_sq_eq_re_inner (𝕜 := ℂ), inner_vector ρ Ω htrace] + simp only [Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, + star_one, Matrix.single_mul_single_same, normalizedTrace, + Matrix.trace_single_eq_same, mul_one] + change ((Fintype.card I : ℂ)⁻¹).re = _ + rw [Complex.inv_re] + simp + rw [← hs, Real.sqrt_sq (norm_nonneg _)] + +lemma projection_symmetric (i : I) : + ∀ x y : E, inner ℂ (ρ (Matrix.single i i 1) x) y = + inner ℂ x (ρ (Matrix.single i i 1) y) := by + intro x y + rw [← ContinuousLinearMap.adjoint_inner_right] + change inner ℂ x (star (ρ (Matrix.single i i 1)) y) = _ + rw [← map_star] + simp only [Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, star_one] + +lemma projection_fixes_single (i j : I) : + ρ (Matrix.single i i 1) (ρ (Matrix.single i j 1) Ω) = + ρ (Matrix.single i j 1) Ω := by + change (ρ (Matrix.single i i 1) * ρ (Matrix.single i j 1)) Ω = _ + rw [← map_mul, Matrix.single_mul_single_same, one_mul] + +variable {F G : Type*} + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + +include htrace in +lemma endpoint_unit_bound + (Y : Completion (E ⊗[ℂ] F) →L[ℂ] Completion (E ⊗[ℂ] G)) + (hY : ∀ a, Y.comp (HilbertTensor.map (ρ a) (1 : F →L[ℂ] F)) = + (HilbertTensor.map (ρ a) (1 : G →L[ℂ] G)).comp Y) + (i j : I) (x : F) (z : G) : + ‖inner ℂ ((ρ (Matrix.single i j 1) Ω ⊗ₜ[ℂ] z : E ⊗[ℂ] G) : Completion _) + (Y ((Ω ⊗ₜ[ℂ] x : E ⊗[ℂ] F) : Completion _))‖ ≤ + ‖Y‖ * (Fintype.card I : ℝ)⁻¹ * ‖x‖ * ‖z‖ := by + have h := HilbertTensor.endpoint_projection_bound Y (ρ (Matrix.single i i 1)) + (projection_symmetric ρ i) (hY _) Ω (ρ (Matrix.single i j 1) Ω) + (projection_fixes_single ρ Ω i j) x z + rw [norm_vector_single ρ Ω htrace, norm_vector_single ρ Ω htrace, + mul_assoc ‖Y‖, ← sq, Real.sq_sqrt (inv_nonneg.mpr (Nat.cast_nonneg _))] at h + exact h + +end MatrixModule + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EndpointRankOne.lean b/lean/OAI/Analysis/Commutator/EndpointRankOne.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d6c4824b4a775291d84557a0fc0e099f9ebfae5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EndpointRankOne.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Commutator.CycleInvariants +import OAI.Analysis.Commutator.EndpointElimination +import OAI.Analysis.Commutator.EndpointElimination3 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.SchurWeyl + +variable {J : Type*} [Fintype J] [DecidableEq J] + +theorem endpoint_coefficients_vanish_of_rank_one + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] + (a : J) (b : ∀ n, J → I n) (hb : ∀ n, Function.Injective (b n)) + (F : ∀ n, (J → Matrix (I n) (I n) ℂ) → ℂ) + (c : Equiv.Perm J → ℂ) (C : ℝ) (hC : 0 ≤ C) + (hF : ∀ n A, F n A = ∑ σ, c σ * cycleTrace σ A) + (hbound : ∀ n (σ : Equiv.Perm J), ‖F n (fun j => Matrix.single (b n (σ j)) (b n j) 1)‖ ≤ + C * (Fintype.card (I n) : ℝ)⁻¹ * + (Real.sqrt (Fintype.card (I n) : ℝ)⁻¹) ^ (Fintype.card J - 1)) + (hunbounded : ∀ B : ℕ, ∃ n, B ≤ Fintype.card (I n)) + (σ : Equiv.Perm J) (hσ : 2 * cycleCount σ < Fintype.card J + 1) : c σ = 0 := by + refine coefficient_zero_of_unbounded_stages + (c σ) C (Fintype.card J) (cycleCount σ) (fun n => Fintype.card (I n)) + hunbounded ?_ hσ + intro n + have hI : 0 < (Fintype.card (I n) : ℝ) := by + have : Nonempty (I n) := ⟨b n a⟩ + exact_mod_cast Fintype.card_pos + have hp : 1 ≤ Fintype.card J := by + have : Nonempty J := ⟨a⟩ + exact Fintype.card_pos + apply square_endpoint_unit_bound ‖c σ‖ C (Fintype.card (I n)) (Fintype.card J) + (cycleCount σ) (norm_nonneg _) hC hI hp + have he : F n (fun j => Matrix.single (b n (σ j)) (b n j) 1) = + c σ * ((Fintype.card (I n) : ℂ)⁻¹) ^ cycleCount σ := by + rw [hF] + simp only [cycleTrace_single (b n) (hb n), mul_ite, mul_zero, + Finset.sum_ite_eq', Finset.mem_univ, ite_true] + have hh := hbound n σ + simpa only [he, norm_mul, norm_pow, norm_inv, Complex.norm_natCast] using hh + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EqualPartitionSums.lean b/lean/OAI/Analysis/Commutator/EqualPartitionSums.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c9d1aa45456bd0e3422796ccb384b0c2c5b0515 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EqualPartitionSums.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.Commutator.EqualProjectionPartition +import OAI.Analysis.Commutator.ProjectionSumEquivalence +import OAI.Analysis.Commutator.DyadicPartition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance equalPartitionSumsDecidableEq : DecidableEq ι := Classical.decEq ι + +def piece (i : ι) : H →L[ℂ] H := D.v i*star (D.v i) + +def part (s : Finset ι) : H →L[ℂ] H := ∑ i∈s,D.piece i + +lemma piece_mem (i : ι) : D.piece i∈M := M.mul_mem (D.mem i) (M.star_mem' (D.mem i)) + +lemma piece_projection (i : ι) : IsStarProjection (D.piece i) := D.final_projection i + +lemma piece_cross (i j : ι) (hij : i≠j) : D.piece i*D.piece j=0 := D.final_cross i j hij + +lemma part_mem (s : Finset ι) : D.part s∈M := M.sum_mem (fun i _ => D.piece_mem i) + +lemma part_projection (s : Finset ι) : IsStarProjection (D.part s) := + orthogonal_sum_projection D.piece D.piece_projection D.piece_cross s + +@[simp] lemma part_empty : D.part ∅=0 := by simp [part] + +@[simp] lemma part_univ : D.part Finset.univ=1 := D.total + +@[simp] lemma part_singleton (i : ι) : D.part {i}=D.piece i := by simp [part] + +lemma part_insert (s : Finset ι) {i : ι} (hi : i∉s) : D.part (insert i s)=D.piece i+D.part s := by + exact Finset.sum_insert hi + +lemma part_mono {s t : Finset ι} (hst : s⊆t) : D.part s≤D.part t := by + apply Finset.sum_le_sum_of_subset_of_nonneg hst + intro i _ _ + exact (D.piece_projection i).nonneg + +lemma part_le_one (s : Finset ι) : D.part s≤1 := by + simpa only [D.part_univ] using D.part_mono (Finset.subset_univ s) + +lemma part_cross {s t : Finset ι} (hst : Disjoint s t) : D.part s*D.part t=0 := by + rw [part,Finset.sum_mul] + apply Finset.sum_eq_zero + intro i hi + apply orthogonal_mul_sum_eq_zero D.piece D.piece_cross t + exact fun ht => (Finset.disjoint_left.mp hst) hi ht + +lemma base_equiv_piece (i : ι) : Equivalent M D.base (D.piece i) := by + exact ⟨⟨D.v i,D.mem i,D.triple i,(D.initial i).le,le_rfl⟩,D.initial i,rfl⟩ + +lemma piece_equiv (i j : ι) : Equivalent M (D.piece i) (D.piece j) := + (D.base_equiv_piece i).symm.trans (D.piece_projection i) D.base_projection (D.base_equiv_piece j) + +lemma part_equiv_of_card_eq (s t : Finset ι) (hst : s.card=t.card) : + Equivalent M (D.part s) (D.part t) := by + let f : s ≃ t := Fintype.equivOfCardEq (by simpa only [Fintype.card_coe] using hst) + have h := Equivalent.finset_sum (M:=M) (fun i : s => D.piece i.val) + (fun i : s => D.piece (f i).val) + (fun i => D.piece_projection i.val) (fun i => D.piece_projection (f i).val) + (fun i j hne => D.piece_cross i.val j.val (fun h => hne (Subtype.ext h))) + (fun i j hne => D.piece_cross (f i).val (f j).val + (fun h => hne (f.injective (Subtype.ext h)))) + (fun i => D.piece_equiv i.val (f i).val) Finset.univ + have hf : (∑ i : s,D.piece (f i).val)=D.part t := by + exact (f.sum_comp (fun j : t => D.piece j.val)).trans (Finset.sum_coe_sort t D.piece) + simpa only [part,Finset.sum_coe_sort,hf] using h + +lemma part_subEquivalent_of_card_le (s t : Finset ι) (hst : s.card≤t.card) : + SubEquivalent M (D.part s) (D.part t) := by + obtain ⟨r,hrt,hr⟩ := Finset.exists_subset_card_eq hst + exact (D.part_equiv_of_card_eq s r hr.symm).subEquivalent.trans + (D.part_projection s) (D.part_projection r) + (subEquivalent_of_le (D.part_mem r) (D.part_projection r) (D.part_mono hrt)) + +lemma piece_ne_zero [Nontrivial H] (i : ι) : D.piece i≠0 := by + intro hz + have hv : D.v i=0 := by + have ht := D.triple i + change D.piece i*D.v i=D.v i at ht + simpa only [hz,zero_mul] using ht.symm + exact D.base_ne_zero (by rw [←D.initial i,hv,star_zero,zero_mul]) + +lemma part_ne_zero_of_nonempty [Nontrivial H] {s : Finset ι} (hs : s.Nonempty) : D.part s≠0 := by + obtain ⟨i,hi⟩ := hs + intro hz + have hle : D.piece i≤D.part s := by + simpa only [D.part_singleton] using D.part_mono (Finset.singleton_subset_iff.mpr hi) + exact D.piece_ne_zero i (le_antisymm (hz ▸ hle) (D.piece_projection i).nonneg) + +end EqualPartition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EqualProjectionPartition.lean b/lean/OAI/Analysis/Commutator/EqualProjectionPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce50153c1a410bdc72fee8c5ab714e6f1c317569 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EqualProjectionPartition.lean @@ -0,0 +1,154 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseHalving +import OAI.Analysis.Commutator.MatrixUnits +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure EqualPartition (M : VonNeumannAlgebra H) (ι : Type*) [Fintype ι] where + base : H →L[ℂ] H + base_mem : base∈M + base_projection : IsStarProjection base + v : ι → H →L[ℂ] H + mem : ∀ i,v i∈M + initial : ∀ i,star (v i)*v i=base + source : ∀ i,v i*base=v i + cross : ∀ i j,i≠j → star (v i)*v j=0 + total : ∑ i,v i*star (v i)=1 + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance : DecidableEq ι := Classical.decEq ι + +lemma triple (i : ι) : D.v i*star (D.v i)*D.v i=D.v i := by + rw [mul_assoc,D.initial,D.source] + +lemma final_projection (i : ι) : IsStarProjection (D.v i*star (D.v i)) := + ⟨by change (D.v i*star (D.v i))*(D.v i*star (D.v i))=D.v i*star (D.v i) + rw [←mul_assoc,D.triple],IsSelfAdjoint.mul_star_self _⟩ + +lemma final_cross (i j : ι) (hij : i≠j) : + (D.v i*star (D.v i))*(D.v j*star (D.v j))=0 := by + rw [mul_assoc,←mul_assoc (star (D.v i)),D.cross i j hij,zero_mul,mul_zero] + +def matrixHom : Matrix ι ι ℂ →⋆ₐ[ℂ] M := by + classical + let q : M := ⟨D.base,D.base_mem⟩ + let v : ι → M := fun i => ⟨D.v i,D.mem i⟩ + let p : ι → M := fun i => v i*star (v i) + exact MatrixUnits.ofPartialIsometries q p v + (fun i => Subtype.ext (D.initial i)) (fun _ => rfl) + (fun i => Subtype.ext (D.source i)) (fun i => Subtype.ext (D.triple i)) + (fun i => IsSelfAdjoint.star_eq (IsSelfAdjoint.mul_star_self (v i))) + (fun i j hij => Subtype.ext (D.final_cross i j hij)) + (Subtype.ext (by + change M.toStarSubalgebra.subtype (∑ i,p i)=M.toStarSubalgebra.subtype 1 + rw [map_sum,map_one] + exact D.total)) + +include D in +theorem exists_double (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) : Nonempty (EqualPartition M (ι × Bool)) := by + classical + obtain ⟨w,hww,hsum⟩ := diffuse_halving M hfac hd D.base_mem D.base_projection + let a := w.initial + let t : Bool → H →L[ℂ] H := fun b => if b then w.val else a + have ha : IsStarProjection a := w.initial_projection + have hti : ∀ b,star (t b)*t b=a := by + intro b + cases b <;> simp only [t,Bool.false_eq_true,↓reduceIte,ha.isSelfAdjoint.star_eq, + ha.isIdempotentElem.eq] + rfl + have hts : ∀ b,t b*a=t b := by + intro b + cases b + · exact ha.isIdempotentElem.eq + · exact w.mul_initial + have htb : ∀ b,D.base*t b=t b := by + intro b + cases b + · exact (ha.le_iff_mul_eq_right D.base_projection).mp w.source_le + · exact w.target_mul D.base_projection + have htc : ∀ b c,b≠c → star (t b)*t c=0 := by + intro b c hbc + cases b <;> cases c + · exact (hbc rfl).elim + · simpa only [t,Bool.false_eq_true,↓reduceIte,ha.isSelfAdjoint.star_eq] using + w.initial_mul_self_eq_zero hww + · simpa only [t,Bool.false_eq_true,↓reduceIte,star_mul,star_zero,←show a=w.initial from rfl,ha.isSelfAdjoint.star_eq,star_star] using + congrArg star (w.initial_mul_self_eq_zero hww) + · exact (hbc rfl).elim + have hsumt : (∑ b : Bool,t b*star (t b))=D.base := by + simpa only [Fintype.sum_bool,t,Bool.false_eq_true,↓reduceIte, + ha.isSelfAdjoint.star_eq,ha.isIdempotentElem.eq,add_comm,a,Link.final] using hsum + refine ⟨⟨a,M.mul_mem (M.star_mem' w.mem) w.mem,ha, + fun i => D.v i.1*t i.2,?_,?_,?_,?_,?_⟩⟩ + · intro i + apply M.mul_mem (D.mem i.1) + cases i.2 + · exact M.mul_mem (M.star_mem' w.mem) w.mem + · exact w.mem + · intro i + rw [star_mul,show star (t i.2)*star (D.v i.1)*(D.v i.1*t i.2)= + star (t i.2)*(star (D.v i.1)*D.v i.1)*t i.2 by noncomm_ring, + D.initial,mul_assoc,htb,hti] + · intro i + rw [mul_assoc,hts] + · intro i j hij + rw [star_mul,show star (t i.2)*star (D.v i.1)*(D.v j.1*t j.2)= + star (t i.2)*(star (D.v i.1)*D.v j.1)*t j.2 by noncomm_ring] + by_cases he : i.1=j.1 + · rw [he,D.initial,mul_assoc,htb,htc i.2 j.2 (fun h => hij (Prod.ext he h))] + · rw [D.cross i.1 j.1 he,mul_zero,zero_mul] + · rw [Fintype.sum_prod_type] + simp only [star_mul] + calc + _=∑ i,D.v i*(∑ b : Bool,t b*star (t b))*star (D.v i) := by + apply Finset.sum_congr rfl + intro i hi + simp only [Finset.mul_sum,Finset.sum_mul] + apply Finset.sum_congr rfl + intro b hb + noncomm_ring + _=∑ i,D.v i*star (D.v i) := by simp only [hsumt,D.source] + _=1 := D.total + +def singleton (M : VonNeumannAlgebra H) : EqualPartition M Unit where + base := 1 + base_mem := M.one_mem + base_projection := IsStarProjection.one _ + v := fun _ => 1 + mem := fun _ => M.one_mem + initial := by simp + source := by simp + cross := by intros; contradiction + total := by simp + +end EqualPartition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EqualTraceRefinement.lean b/lean/OAI/Analysis/Commutator/EqualTraceRefinement.lean new file mode 100644 index 0000000000000000000000000000000000000000..e40d0f1fea0f1998f0ef98e77006f363b5e5a004 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EqualTraceRefinement.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionRounding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.NormalGNS + +open ProjectionSum + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (hnormal : BoundedWOTContinuous M τ) + +variable (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + +variable {J : Type} [Fintype J] + +include hτ hnormal hfaith hone in +theorem equal_trace_refinement (hM : DiffuseProjection.HasNoMinimalProjections M) + (p : J → M) (hp : ∀ j,IsStarProjection (p j)) + (horth : ∀ j k,j≠k → p j*p k=0) (hsum : ∑ j,p j=1) + (b : ℕ) (hb : 0 + exists_rational_subprojection M τ hτ hnormal hfaith hM (p j) (hp j) b hb + have hsorth : ∀ j k,j≠k → s j*s k=0 := fun j k hjk => + subprojections_orthogonal (hs j) (hs k) (hp j) (hp k) (hsp j) (hsp k) (horth j k hjk) + let S : M := ∑ j,s j + have hS : IsStarProjection S := projection_sum s hs hsorth + have hSle : S≤1 := by simpa only [hsum] using projection_sum_le s p hsp + have htS : (τ S).re=(∑ j,n j : ℕ)/(b:ℝ) := by + change (τ (∑ j,s j)).re=_ + rw [map_sum] + change Complex.reAddGroupHom (∑ j,τ (s j))=_ + rw [map_sum] + change (∑ j,(τ (s j)).re)=_ + simp only [hts,←Finset.sum_div,Nat.cast_sum] + have hN : (∑ j,n j)≤b := by + have hnonneg := (τ.map_nonneg (sub_nonneg.mpr hSle)).1 + rw [map_sub,Complex.sub_re,hone,Complex.one_re,Complex.zero_re,htS] at hnonneg + have h : ((∑ j,n j : ℕ):ℝ)≤(b:ℝ) := by + have hh := (div_le_iff₀ hbR).mp (show ((∑ j,n j : ℕ):ℝ)/(b:ℝ)≤1 by linarith) + simpa only [one_mul] using hh + exact_mod_cast h + let m : ℕ := b-∑ j,n j + have hrem : IsStarProjection (1-S) := hS.one_sub + have htrem : (τ (1-S)).re=(m:ℝ)*(1/(b:ℝ)) := by + rw [map_sub,Complex.sub_re,hone,Complex.one_re,htS] + dsimp [m] + rw [Nat.cast_sub hN] + field_simp + have hpart (j : J) : ∃ r : Fin (n j) → M, + (∀ k,IsStarProjection (r k) ∧ r k ≤ s j ∧ (τ (r k)).re=1/(b:ℝ)) ∧ + (∀ k l,k≠l → r k*r l=0) ∧ ∑ k,r k=s j := by + apply exists_projection_partition M τ hτ hnormal hfaith hM (n j) (s j) (hs j) + (by positivity : (0:ℝ)≤1/(b:ℝ)) + rw [hts]; ring + choose r hr hrorth hrsum using hpart + obtain ⟨z,hz,hzorth,hzsum⟩ := exists_projection_partition M τ hτ hnormal hfaith hM + m (1-S) hrem (by positivity : (0:ℝ)≤1/(b:ℝ)) htrem + let I := (Σ j : J,Fin (n j)) ⊕ Fin m + let q : I → M := Sum.elim (fun i => r i.1 i.2) z + have hleS (j : J) (k : Fin (n j)) : r j k≤S := + (hr j k).2.1.trans (Finset.single_le_sum (fun l _ => (hs l).nonneg) (Finset.mem_univ j)) + have hcross (j : J) (k : Fin (n j)) (l : Fin m) : r j k*z l=0 := + subprojections_orthogonal (hr j k).1 (hz l).1 hS hrem (hleS j k) (hz l).2.1 + hS.mul_one_sub_self + refine ⟨I,inferInstance,q,s,?_,?_,?_,?_⟩ + · intro i + cases i with + | inl i => exact ⟨(hr i.1 i.2).1,(hr i.1 i.2).2.2⟩ + | inr i => exact ⟨(hz i).1,(hz i).2.2⟩ + · intro i k hik + cases i with + | inl i => + cases k with + | inl k => + obtain ⟨j,a⟩ := i + obtain ⟨l,c⟩ := k + change r j a*r l c=0 + by_cases hjl : j=l + · subst l + exact hrorth j a c (fun hac => hik (by subst c; rfl)) + · exact subprojections_orthogonal (hr j a).1 (hr l c).1 (hs j) (hs l) + (hr j a).2.1 (hr l c).2.1 (hsorth j l hjl) + | inr k => exact hcross i.1 i.2 k + | inr i => + cases k with + | inl k => + change z i*r k.1 k.2=0 + simpa only [star_mul,(hr k.1 k.2).1.isSelfAdjoint.star_eq, + (hz i).1.isSelfAdjoint.star_eq,star_zero] using congrArg star (hcross k.1 k.2 i) + | inr k => exact hzorth i k (fun he => hik (congrArg Sum.inr he)) + · change (∑ i : (Σ j : J,Fin (n j)) ⊕ Fin m,Sum.elim (fun i => r i.1 i.2) z i)=1 + rw [Fintype.sum_sum_type,Fintype.sum_sigma] + change (∑ j,∑ k,r j k)+(∑ k,z k)=1 + simp only [hrsum,hzsum] + change S+(1-S)=1 + abel + · intro j + refine ⟨hs j,hsp j,herror j,?_⟩ + rw [←hrsum j] + apply (StarAlgebra.adjoin ℂ (Set.range q)).sum_mem + intro k hk + exact StarAlgebra.subset_adjoin ℂ (Set.range q) ⟨Sum.inl ⟨j,k⟩,rfl⟩ + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/EquivariantBicommutant.lean b/lean/OAI/Analysis/Commutator/EquivariantBicommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..da4d882c507fe008cfb4db336cec90a72ca7b46a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/EquivariantBicommutant.lean @@ -0,0 +1,56 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.EquivariantBicommutant + +variable {A B : Type*} [Monoid A] [Monoid B] + +lemma mem_centralizer_image (e : A ≃* B) (s : Set A) (x : A) : + e x∈Set.centralizer (e '' s) ↔ x∈Set.centralizer s := by + constructor + · intro h y hy + apply e.injective + simpa only [map_mul] using h (e y) ⟨y,hy,rfl⟩ + · rintro h _ ⟨y,hy,rfl⟩ + simpa only [map_mul] using congrArg e (h y hy) + +lemma centralizer_image (e : A ≃* B) (s : Set A) : + Set.centralizer (e '' s)=e '' Set.centralizer s := by + ext x + constructor + · intro hx + refine ⟨e.symm x,?_,e.apply_symm_apply x⟩ + apply (mem_centralizer_image e s (e.symm x)).mp + simpa only [e.apply_symm_apply] using hx + · rintro ⟨y,hy,rfl⟩ + exact (mem_centralizer_image e s y).mpr hy + +lemma bicommutant_image (e : A ≃* B) (s : Set A) : + Set.centralizer (Set.centralizer (e '' s))=e '' Set.centralizer (Set.centralizer s) := by + rw [centralizer_image,centralizer_image] + +lemma bicommutant_range {C : Type*} (e : A ≃* B) (f : C → A) + (hf : Set.centralizer (Set.centralizer (Set.range f))=Set.range f) : + Set.centralizer (Set.centralizer (Set.range (e ∘ f)))=Set.range (e ∘ f) := by + rw [Set.range_comp,bicommutant_image,hf] + +lemma bicommutant_mono {s t : Set A} (h : s⊆t) : + Set.centralizer (Set.centralizer s)⊆Set.centralizer (Set.centralizer t) := by + intro x hx y hy + exact hx y (fun z hz => hy z (h hz)) + +end Kadison.EquivariantBicommutant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ExponentialMomentBudget.lean b/lean/OAI/Analysis/Commutator/ExponentialMomentBudget.lean new file mode 100644 index 0000000000000000000000000000000000000000..af1589bb70617d980f45db5d742e9b71610d0b24 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ExponentialMomentBudget.lean @@ -0,0 +1,80 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FinitePatching + +def momentBudget (ε K t : ℝ) : ℝ := ε*Real.exp (K*t) + +def budgetSlope (N : ℕ) (η : ℝ) : ℝ := ((N:ℝ)+1)^2*(1+2/η) + +lemma budgetSlope_ge_one (N : ℕ) {η : ℝ} (hη : 0<η) : 1 ≤ budgetSlope N η := by + have hn : 0 ≤ (N:ℝ) := Nat.cast_nonneg N + have hd : 0 ≤ 2/η := by positivity + have h1 : 1 ≤ ((N:ℝ)+1)^2 := by nlinarith + exact (one_mul (1:ℝ)).symm ▸ mul_le_mul h1 (by linarith : 1 ≤ 1+2/η) + (by norm_num) (by positivity) + +lemma momentBudget_nonneg {ε : ℝ} (hε : 0 ≤ ε) (K t : ℝ) : 0 ≤ momentBudget ε K t := + mul_nonneg hε (Real.exp_pos _).le + +lemma le_momentBudget {ε K t : ℝ} (hε : 0 ≤ ε) (hK : 0 ≤ K) (ht : 0 ≤ t) : + ε ≤ momentBudget ε K t := by + exact le_mul_of_one_le_right hε (Real.one_le_exp (mul_nonneg hK ht)) + +lemma momentBudget_step {ε K t q : ℝ} (hε : 0 ≤ ε) : + momentBudget ε K t+K*momentBudget ε K t*q ≤ momentBudget ε K (t+q) := by + have hh := mul_le_mul_of_nonneg_left (Real.add_one_le_exp (K*q)) + (momentBudget_nonneg hε K t) + calc + _=momentBudget ε K t*(K*q+1) := by ring + _ ≤ momentBudget ε K t*Real.exp (K*q) := hh + _=momentBudget ε K (t+q) := by simp only [momentBudget,mul_add,Real.exp_add,mul_assoc] + +lemma word_momentBudget_step {ε η t q : ℝ} (hε : 0 ≤ ε) (hη : 0<η) + (ht : 0 ≤ t) (hq : 0 ≤ q) {n N : ℕ} (hn : n ≤ N) : + momentBudget ε (budgetSlope N η) t+ + ((n:ℝ)+(n:ℝ)^2)*(ε+2*momentBudget ε (budgetSlope N η) t/η)*q ≤ + momentBudget ε (budgetSlope N η) (t+q) := by + let B := momentBudget ε (budgetSlope N η) t + have hB : 0 ≤ B := momentBudget_nonneg hε _ _ + have hK : 0 ≤ budgetSlope N η := (by norm_num : (0:ℝ) ≤ 1).trans (budgetSlope_ge_one N hη) + have hεB : ε ≤ B := le_momentBudget hε hK ht + have hn' : (n:ℝ) ≤ (N:ℝ) := Nat.cast_le.mpr hn + have hn0 : 0 ≤ (n:ℝ) := Nat.cast_nonneg n + have hN0 : 0 ≤ (N:ℝ) := Nat.cast_nonneg N + have hf : (n:ℝ)+(n:ℝ)^2 ≤ ((N:ℝ)+1)^2 := by nlinarith + have hd : ε+2*B/η ≤ (1+2/η)*B := by + calc + _ ≤ B+2*B/η := add_le_add hεB le_rfl + _=_ := by ring + have hh : ((n:ℝ)+(n:ℝ)^2)*(ε+2*B/η) ≤ budgetSlope N η*B := by + calc + _ ≤ ((N:ℝ)+1)^2*((1+2/η)*B) := mul_le_mul hf hd (by positivity) (by positivity) + _=_ := by dsimp [budgetSlope]; ring + exact (add_le_add le_rfl (mul_le_mul_of_nonneg_right hh hq)).trans (momentBudget_step hε) + +lemma pure_momentBudget_step {ε η t q : ℝ} (hε : 0 ≤ ε) (hη : 0<η) + (ht : 0 ≤ t) (hq : 0 ≤ q) (N : ℕ) : + momentBudget ε (budgetSlope N η) t+ε*q ≤ momentBudget ε (budgetSlope N η) (t+q) := by + have hK := budgetSlope_ge_one N hη + have hB := momentBudget_nonneg hε (budgetSlope N η) t + have hεB := le_momentBudget hε ((by norm_num : (0:ℝ) ≤ 1).trans hK) ht + have hh : ε ≤ budgetSlope N η*momentBudget ε (budgetSlope N η) t := + hεB.trans (le_mul_of_one_le_left hB hK) + exact (add_le_add le_rfl (mul_le_mul_of_nonneg_right hh hq)).trans (momentBudget_step hε) + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorComparison.lean b/lean/OAI/Analysis/Commutator/FactorComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..207326629f845e0097bfa8031859cf6338ac8508 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorComparison.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.PartialIsometryMaximal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + +lemma residual_source_projection (v : Link M e f) (he : IsStarProjection e) : + IsStarProjection (e-v.initial) := + v.initial_projection.sub_of_mul_eq_left he + ((v.initial_projection.le_iff_mul_eq_left he).mp v.source_le) + +lemma residual_target_projection (v : Link M e f) (hf : IsStarProjection f) : + IsStarProjection (f-v.final) := + v.final_projection.sub_of_mul_eq_left hf + ((v.final_projection.le_iff_mul_eq_left hf).mp v.target_le) + +lemma residual_mul_initial (v : Link M e f) (he : IsStarProjection e) + (w : Link M (e-v.initial) (f-v.final)) : w.val*v.initial=0 := by + have hep := (v.initial_projection.le_iff_mul_eq_right he).mp v.source_le + calc + _=(w.val*(e-v.initial))*v.initial := by + rw [w.mul_source (v.residual_source_projection he)] + _=0 := by rw [mul_assoc,sub_mul,hep,v.initial_projection.isIdempotentElem.eq,sub_self,mul_zero] + +lemma final_mul_residual (v : Link M e f) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : v.final*w.val=0 := by + have hqf := (v.final_projection.le_iff_mul_eq_left hf).mp v.target_le + calc + _=v.final*((f-v.final)*w.val) := by + rw [w.target_mul (v.residual_target_projection hf)] + _=0 := by rw [←mul_assoc,mul_sub,hqf,v.final_projection.isIdempotentElem.eq,sub_self,zero_mul] + +lemma residual_cross (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : + star v.val*w.val=0 ∧ v.val*star w.val=0 := by + constructor + · have hstar := congrArg star v.final_mul + simp only [star_mul,v.final_projection.isSelfAdjoint.star_eq] at hstar + calc + _=(star v.val*v.final)*w.val := by rw [hstar] + _=0 := by rw [mul_assoc,v.final_mul_residual hf w,mul_zero] + · have hstar := congrArg star (v.residual_mul_initial he w) + simp only [star_mul,v.initial_projection.isSelfAdjoint.star_eq,star_zero] at hstar + calc + _=(v.val*v.initial)*star w.val := by rw [v.mul_initial] + _=0 := by rw [mul_assoc,hstar,mul_zero] + +def extend (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : Link M e f := by + have hvw := (v.residual_cross he hf w).1 + have hvw' := (v.residual_cross he hf w).2 + have hwv : star w.val*v.val=0 := by simpa only [star_mul,star_star,star_zero] using congrArg star hvw + have hwv' : w.val*star v.val=0 := by simpa only [star_mul,star_star,star_zero] using congrArg star hvw' + have hinit : star (v.val+w.val)*(v.val+w.val)=v.initial+w.initial := by + simp only [star_add,add_mul,mul_add,hvw,hwv,add_zero,zero_add,initial] + have hfinal : (v.val+w.val)*star (v.val+w.val)=v.final+w.final := by + simp only [star_add,add_mul,mul_add,hvw',hwv',add_zero,zero_add,final] + refine ⟨v.val+w.val,M.add_mem v.mem w.mem,?_,?_,?_⟩ + · rw [star_add] + simp only [add_mul,mul_add,hvw',hwv',zero_add,add_zero] + rw [v.triple,w.triple] + have h1 : v.val*star v.val*w.val=0 := by rw [mul_assoc,hvw,mul_zero] + have h2 : w.val*star w.val*v.val=0 := by rw [mul_assoc,hwv,mul_zero] + rw [h1,h2,add_zero,zero_add] + · rw [hinit] + calc + _ ≤ v.initial+(e-v.initial) := add_le_add_right w.source_le _ + _=e := by abel + · rw [hfinal] + calc + _ ≤ v.final+(f-v.final) := add_le_add_right w.target_le _ + _=f := by abel + +@[simp] lemma extend_val (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : (v.extend he hf w).val=v.val+w.val := rfl + +lemma le_extend (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : v≤v.extend he hf w := by + obtain ⟨hvw,_⟩ := v.residual_cross he hf w + have hwv : star w.val*v.val=0 := by simpa only [star_mul,star_star,star_zero] using congrArg star hvw + apply (le_def _ _).mpr + constructor + · change v.initial ≤ star (v.val+w.val)*(v.val+w.val) + simp only [star_add,add_mul,mul_add,hvw,hwv,add_zero,zero_add] + exact le_add_of_nonneg_right w.initial_projection.nonneg + · change (v.val+w.val)*v.initial=v.val + rw [add_mul,v.mul_initial,v.residual_mul_initial he w,add_zero] + +end Link + +theorem factor_comparison (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) : + ∃ v : Link M e f, v.initial=e ∨ v.final=f := by + obtain ⟨v,hv⟩ := exists_maximal M he hf + refine ⟨v,?_⟩ + by_contra h + have hresE : e-v.initial≠0 := fun hh => h (Or.inl (sub_eq_zero.mp hh).symm) + have hresF : f-v.final≠0 := fun hh => h (Or.inr (sub_eq_zero.mp hh).symm) + have hmemE : e-v.initial∈M := M.sub_mem heM (M.mul_mem (M.star_mem' v.mem) v.mem) + have hmemF : f-v.final∈M := M.sub_mem hfM (M.mul_mem v.mem (M.star_mem' v.mem)) + obtain ⟨w,hwM,hwn,hwt,hwi,hwf⟩ := FactorCorner.exists_linking_partialIsometry M hM + hmemE hmemF (v.residual_source_projection he) (v.residual_target_projection hf) hresE hresF + let w' : Link M (e-v.initial) (f-v.final) := ⟨w,hwM,hwt,hwi,hwf⟩ + have hvu := v.le_extend he hf w' + have heq : v.extend he hf w'=v := le_antisymm (hv hvu) hvu + have hval := congrArg Link.val heq + change v.val+w=v.val at hval + exact hwn (add_left_cancel (hval.trans (add_zero v.val).symm)) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorCorner.lean b/lean/OAI/Analysis/Commutator/FactorCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..66b1d583fc8dab6faade2388fe2de25e675cc6d4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorCorner.lean @@ -0,0 +1,141 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.PolarSupport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.FactorCorner + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def supportSpace (M : VonNeumannAlgebra H) (e : H →L[ℂ] H) : Submodule ℂ H := + (Submodule.span ℂ {x | ∃ a∈M, ∃ ξ : H, a (e ξ)=x}).topologicalClosure + +instance (M : VonNeumannAlgebra H) (e : H →L[ℂ] H) : CompleteSpace (supportSpace M e) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +lemma generator_mem (M : VonNeumannAlgebra H) (e : H →L[ℂ] H) + {a : H →L[ℂ] H} (ha : a∈M) (ξ : H) : a (e ξ)∈supportSpace M e := + Submodule.le_topologicalClosure _ (Submodule.subset_span ⟨a,ha,ξ,rfl⟩) + +lemma supportSpace_invariant (M : VonNeumannAlgebra H) (e B : H →L[ℂ] H) + (hB : ∀ a∈M, ∀ ξ : H, B (a (e ξ))∈supportSpace M e) : + ∀ x∈supportSpace M e, B x∈supportSpace M e := by + intro x hx + apply closure_minimal (t := {x | B x∈supportSpace M e}) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage B.continuous) hx + exact (Submodule.span_le.mpr (by rintro y ⟨a,ha,ξ,rfl⟩; exact hB a ha ξ) : + Submodule.span ℂ {x | ∃ a∈M, ∃ ξ : H, a (e ξ)=x} ≤ (supportSpace M e).comap B.toLinearMap) + +lemma invariant_of_mem (M : VonNeumannAlgebra H) (e : H →L[ℂ] H) + {B : H →L[ℂ] H} (hB : B∈M) : + ∀ x∈supportSpace M e, B x∈supportSpace M e := by + apply supportSpace_invariant + intro a ha ξ + exact generator_mem M e (M.mul_mem hB ha) ξ + +lemma invariant_of_commutant (M : VonNeumannAlgebra H) {e B : H →L[ℂ] H} + (he : e∈M) (hB : B∈Set.centralizer (M : Set (H →L[ℂ] H))) : + ∀ x∈supportSpace M e, B x∈supportSpace M e := by + apply supportSpace_invariant + intro a ha ξ + have hba : B*a=a*B := (hB a ha).symm + have hbe : B*e=e*B := (hB e he).symm + change B (a (e ξ))∈supportSpace M e + rw [show B (a (e ξ))=a (B (e ξ)) from congrArg (fun T : H →L[ℂ] H => T (e ξ)) hba, + show B (e ξ)=e (B ξ) from congrArg (fun T : H →L[ℂ] H => T ξ) hbe] + exact generator_mem M e ha (B ξ) + +lemma projection_commutant (M : VonNeumannAlgebra H) (e : H →L[ℂ] H) : + (supportSpace M e).starProjection∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + intro a ha + exact (projection_commutes_of_invariant _ a (invariant_of_mem M e ha) + (invariant_of_mem M e (M.star_mem' ha))).symm + +lemma projection_mem (M : VonNeumannAlgebra H) {e : H →L[ℂ] H} (he : e∈M) : + (supportSpace M e).starProjection∈M := by + change (supportSpace M e).starProjection∈M.carrier + rw [←M.centralizer_centralizer'] + intro a ha + have hsa : star a∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + intro b hb + simpa only [star_mul,star_star] using congrArg star (ha (star b) (M.star_mem' hb)).symm + exact (projection_commutes_of_invariant _ a (invariant_of_commutant M he ha) + (invariant_of_commutant M he hsa)).symm + +def IsFactor (M : VonNeumannAlgebra H) : Prop := + ∀ z∈M, z∈Set.centralizer (M : Set (H →L[ℂ] H)) → ∃ c : ℂ, z=c • (1 : H →L[ℂ] H) + +lemma centralSupport_eq_one (M : VonNeumannAlgebra H) (hf : IsFactor M) + {e : H →L[ℂ] H} (he : e∈M) (hne : e≠0) : + (supportSpace M e).starProjection=1 := by + obtain ⟨c,hc⟩ := hf _ (projection_mem M he) (projection_commutant M e) + have hex : ∃ ξ : H, e ξ≠0 := by + by_contra! h + apply hne + ext ξ + exact h ξ + obtain ⟨ξ,hξ⟩ := hex + have hg : e ξ∈supportSpace M e := by simpa using generator_mem M e M.one_mem ξ + have hfix := Submodule.starProjection_eq_self_iff.mpr hg + rw [hc] at hfix + change c • e ξ=e ξ at hfix + have hzero : (c-1) • e ξ=0 := by rw [sub_smul,one_smul,hfix,sub_self] + have hcone : c=1 := sub_eq_zero.mp ((smul_eq_zero.mp hzero).resolve_right hξ) + rw [hc,hcone,one_smul] + +theorem exists_nonzero_corner (M : VonNeumannAlgebra H) (hf : IsFactor M) + {e f : H →L[ℂ] H} (he : e∈M) (hee : e≠0) (hff : f≠0) : + ∃ a∈M, f*a*e≠0 := by + by_contra! h + have hz : ∀ x∈supportSpace M e, f x=0 := by + intro x hx + apply closure_minimal (t := {x | f x=0}) ?_ + (isClosed_eq f.continuous continuous_const) hx + have hspan : Submodule.span ℂ {x | ∃ a∈M, ∃ ξ : H, a (e ξ)=x} ≤ LinearMap.ker f.toLinearMap := by + apply Submodule.span_le.mpr + rintro y ⟨a,ha,ξ,rfl⟩ + exact congrArg (fun T : H →L[ℂ] H => T ξ) (h a ha) + exact hspan + apply hff + ext x + have hm := (supportSpace M e).starProjection_apply_mem x + rw [centralSupport_eq_one M hf he hee] at hm + exact hz x hm + +theorem exists_linking_partialIsometry (M : VonNeumannAlgebra H) (hf : IsFactor M) + {e f : H →L[ℂ] H} (he : e∈M) (hfM : f∈M) + (hpe : IsStarProjection e) (hpf : IsStarProjection f) (hne : e≠0) (hnf : f≠0) : + ∃ v∈M, v≠0 ∧ v*star v*v=v ∧ star v*v≤e ∧ v*star v≤f := by + obtain ⟨a,ha,hna⟩ := exists_nonzero_corner M hf he hne hnf + let x := f*a*e + have hx : x∈M := M.mul_mem (M.mul_mem hfM ha) he + have hfx : f*x=x := by dsimp only [x]; rw [←mul_assoc,←mul_assoc,hpf.isIdempotentElem.eq] + have hxe : x*e=x := by dsimp only [x]; rw [mul_assoc,hpe.isIdempotentElem.eq] + refine ⟨Polar.partialIsometry x,Polar.partialIsometry_mem_vonNeumann M hx,?_, + Polar.partialIsometry_triple x,?_,?_⟩ + · intro hzero + apply hna + have hfact := Polar.factorization x + rw [hzero,zero_mul] at hfact + exact hfact.symm + · rw [Polar.partialIsometry_initial] + exact Polar.rightSupport_le x e hpe hxe + · exact Polar.leftSupport_le x f hpf hfx + +end Kadison.FactorCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorFieldBound.lean b/lean/OAI/Analysis/Commutator/FactorFieldBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..937060473fe68dc89ef791376a16c8659055f697 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorFieldBound.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.DiagonalField +import OAI.Analysis.Commutator.FiberCommutator +import OAI.Analysis.Commutator.MatrixField +import OAI.Analysis.Commutator.SeparableFactorMain +import OAI.Analysis.Commutator.UnitaryMainTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω : Type*} {H : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem matrix_commutator_bound_of_factor_fields + (Q : Ω → VonNeumannAlgebra H) (hfac : ∀ᵐ a ∂μ,FactorCorner.IsFactor (Q a)) + (T : Ω → H →L[ℂ] H) + (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b d : ℝ} (hb0 : 0≤b) (hd : 0≤d) (hb : ∀ᵐ a ∂μ,‖T a‖≤b) + (hg : ∀ᵐ a ∂μ,commutatorSeminorm (Q a) (T a)≤d) + (h : ℕ) (hh : 1≤h) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hX : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + {c : Fin h → Fin h → ℝ} (hc0 : ∀ i j,0≤c i j) + (hc : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤c i j) + (hmem : ∀ᵐ a ∂μ,∀ i j,X i j a∈Q a) : + ‖diagonalAmplification h (operator μ T hT hb)* + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))- + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))* + diagonalAmplification h (operator μ T hT hb)‖≤ + 3122*d*‖matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))‖ := by + let D := fun a => diagonalAmplification h (T a) + let M := fun a => matrixOperator h (fun i j => X i j a) + let G := matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j)) + have hD := diagonal_field_measurable μ h T hT + have hM := matrix_field_measurable μ h X hX + have hDb := diagonal_field_bound μ h T hb + have hMb := matrix_field_bound μ h X hc + have hcnonneg : 0≤∑ i,∑ j,c i j := + Finset.sum_nonneg (fun i _ => Finset.sum_nonneg (fun j _ => hc0 i j)) + have hmatrix : ∀ᵐ a ∂μ,‖M a‖≤‖G‖ := by + apply (operator_norm_le_iff_ae μ M hM hMb (norm_nonneg G)).mp + rw [←matrix_conjugate μ h X hX hc,UnitaryTransport.conj_norm] + have hfiber : ∀ᵐ a ∂μ,‖D a*M a-M a*D a‖≤3122*d*‖G‖ := by + filter_upwards [hfac,hmem,hg,hmatrix] with a hfa hma hga hna + have hf := uniform_commutator_separable_factor (Q a) hfa (T a) h hh + (fun i j => X i j a) hma + exact hf.trans (mul_le_mul (mul_le_mul_of_nonneg_left hga (by norm_num)) hna + (norm_nonneg _) (mul_nonneg (by norm_num) hd)) + have hn := operator_norm_le μ (fun a => D a*M a-M a*D a) + (commutator_measurable μ D M hD hM) + (commutator_field_bound μ D M hb0 hcnonneg hDb hMb) + (mul_nonneg (mul_nonneg (by norm_num : (0:ℝ)≤3122) hd) (norm_nonneg G)) hfiber + rw [←operator_commutator μ D M hD hM hb0 hcnonneg hDb hMb] at hn + change ‖operator μ D hD hDb*operator μ M hM hMb- + operator μ M hM hMb*operator μ D hD hDb‖≤_ at hn + rw [←diagonal_conjugate μ h T hT hb,←matrix_conjugate μ h X hX hc, + ←map_mul,←map_mul,←map_sub,UnitaryTransport.conj_norm] at hn + exact hn + +theorem matrix_commutator_bound_of_countable_factor_fields + (P : VonNeumannAlgebra (Lp H 2 μ)) (Q : Ω → VonNeumannAlgebra H) + (hfac : ∀ᵐ a ∂μ,FactorCorner.IsFactor (Q a)) + (T : Ω → H →L[ℂ] H) + (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb0 : 0≤b) (hb : ∀ᵐ a ∂μ,‖T a‖≤b) + (test : ℕ → Ω → H →L[ℂ] H) + (ht : ∀ n ξ,AEStronglyMeasurable (fun a => test n a ξ) μ) + (htb : ∀ n,∀ᵐ a ∂μ,‖test n a‖≤1) + (htmem : ∀ n,operator μ (test n) (ht n) (htb n)∈P) + (htdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) a ξ) atTop (𝓝 (A ξ))) + (h : ℕ) (hh : 1≤h) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hX : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + {c : Fin h → Fin h → ℝ} (hc0 : ∀ i j,0≤c i j) + (hc : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤c i j) + (hmem : ∀ᵐ a ∂μ,∀ i j,X i j a∈Q a) : + ‖diagonalAmplification h (operator μ T hT hb)* + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))- + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))* + diagonalAmplification h (operator μ T hT hb)‖≤ + 3122*commutatorSeminorm P (operator μ T hT hb)* + ‖matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))‖ := + matrix_commutator_bound_of_factor_fields μ Q hfac T hT hb0 + (commutatorSeminorm_nonneg P _) hb + (seminorm_ae_le μ P Q T hT hb0 hb test ht htb htmem htdense) + h hh X hX hc0 hc hmem + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorFieldLocalization.lean b/lean/OAI/Analysis/Commutator/FactorFieldLocalization.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f4666561550c3c077cbe4adb8fa67950c7439d1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorFieldLocalization.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralAverage +import OAI.Analysis.Commutator.DiagonalCommute +import OAI.Analysis.Commutator.FactorFieldBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω : Type*} {H : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem localized_matrix_commutator_bound + (P : VonNeumannAlgebra (Lp H 2 μ)) (Q : Ω → VonNeumannAlgebra H) + (hfac : ∀ᵐ a ∂μ,FactorCorner.IsFactor (Q a)) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈P ∧ + indicatorOperator (H:=H) μ s hs∈Set.centralizer (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (test : ℕ → Ω → H →L[ℂ] H) + (ht : ∀ n ξ,AEStronglyMeasurable (fun a => test n a ξ) μ) + (htb : ∀ n,∀ᵐ a ∂μ,‖test n a‖≤1) + (htmem : ∀ n,operator μ (test n) (ht n) (htb n)∈P) + (htdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) a ξ) atTop (𝓝 (A ξ))) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (h : ℕ) (hh : 1≤h) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hX : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + {c : Fin h → Fin h → ℝ} (hc0 : ∀ i j,0≤c i j) + (hc : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤c i j) + (hmem : ∀ᵐ a ∂μ,∀ i j,X i j a∈Q a) : + ‖diagonalAmplification h Y* + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))- + matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))* + diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y* + ‖matrixOperator h (fun i j => operator μ (X i j) (hX i j) (hc i j))‖ := by + obtain ⟨Z,hz,hd,_⟩ := CentralAverage.exists_center_average P Y + have hcomm (s : Set Ω) (hs : MeasurableSet s) : Commute Z (indicatorOperator μ s hs) := + hz _ (hdiag s hs).1 (hdiag s hs).2 + obtain ⟨T,hT,hb,he⟩ := exists_field_of_commutes_indicator μ Z hcomm + have hbnd := matrix_commutator_bound_of_countable_factor_fields μ P Q hfac T hT + (norm_nonneg Z) hb test ht htb htmem htdense h hh X hX hc0 hc hmem + rw [←he] at hbnd + convert matrix_commutator_perturb P Y Z hd 3122 (by norm_num) h + (fun i j => operator μ (X i j) (hX i j) (hc i j)) hbnd using 1 + norm_num + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorGeneratedSpace.lean b/lean/OAI/Analysis/Commutator/FactorGeneratedSpace.lean new file mode 100644 index 0000000000000000000000000000000000000000..d9ed1856443f542d55b05b111fc7159b79d4ec2e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorGeneratedSpace.lean @@ -0,0 +1,105 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace CStarAlgebra + +namespace Kadison.CbFactor + +variable {A H K : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def generated (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) : Submodule ℂ K := + (Submodule.span ℂ {x : K | ∃ a : A,∃ u : H,ρ a (W u)=x}).topologicalClosure + +instance (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) : IsClosed (generated ρ W : Set K) := + Submodule.isClosed_topologicalClosure _ + +lemma generated_generator (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) (a : A) (u : H) : + ρ a (W u)∈generated ρ W := + Submodule.le_topologicalClosure _ (Submodule.subset_span ⟨a,u,rfl⟩) + +lemma generated_right (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) (u : H) : + W u∈generated ρ W := by simpa using generated_generator ρ W 1 u + +lemma generated_invariant (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) (a : A) : + ∀ x∈generated ρ W,ρ a x∈generated ρ W := by + intro x hx + apply closure_minimal (t:={x | ρ a x∈generated ρ W}) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage (ρ a).continuous) hx + change Submodule.span ℂ {x : K | ∃ b : A,∃ u : H,ρ b (W u)=x} ≤ + (generated ρ W).comap (ρ a).toLinearMap + apply Submodule.span_le.mpr + rintro y ⟨b,u,rfl⟩ + change ρ a (ρ b (W u))∈generated ρ W + simpa only [map_mul,mul_apply_eq_comp] using generated_generator ρ W (a*b) u + +lemma generated_projection_commutes (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) (a : A) : + (generated ρ W).starProjection * ρ a=ρ a * (generated ρ W).starProjection := by + ext x + change (generated ρ W).starProjection (ρ a x)=ρ a ((generated ρ W).starProjection x) + apply Submodule.eq_starProjection_of_mem_of_inner_eq_zero + · exact generated_invariant ρ W a _ ((generated ρ W).starProjection_apply_mem x) + · intro w hw + rw [←map_sub,←ContinuousLinearMap.adjoint_inner_right] + apply Submodule.starProjection_inner_eq_zero x + simpa only [map_star,ContinuousLinearMap.star_eq_adjoint] using generated_invariant ρ W (star a) w hw + +lemma generated_projection_right (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (W : H →L[ℂ] K) : + (generated ρ W).starProjection.comp W=W := by + ext x + exact Submodule.starProjection_eq_self_iff.mpr (generated_right ρ W x) + +variable [CompleteSpace H] (π : A →ₐ[ℂ] (H →L[ℂ] H)) (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (V W : H →L[ℂ] K) + (hfactor : ∀ a : A,π a=V.adjoint.comp ((ρ a).comp W)) + +include hfactor in +lemma factor_intertwines_on_generated (a : A) {x : K} (hx : x∈generated ρ W) : + π a (V.adjoint x)=V.adjoint (ρ a x) := by + let D : K →L[ℂ] H := (π a).comp V.adjoint-V.adjoint.comp (ρ a) + have hd : generated ρ W ≤ D.ker := by + apply Submodule.topologicalClosure_minimal _ ?_ D.isClosed_ker + apply Submodule.span_le.mpr + rintro y ⟨b,u,rfl⟩ + change π a (V.adjoint (ρ b (W u)))-V.adjoint (ρ a (ρ b (W u)))=0 + apply sub_eq_zero.mpr + have hb := congrArg (fun T : H →L[ℂ] H => T u) (hfactor b) + have hab := congrArg (fun T : H →L[ℂ] H => T u) (hfactor (a*b)) + simp only [ContinuousLinearMap.comp_apply] at hb hab + rw [←hb,←mul_apply_eq_comp,←map_mul,hab] + simp only [map_mul,mul_apply_eq_comp] + exact sub_eq_zero.mp (hd hx) + +def leftCompression : K →L[ℂ] H := V.adjoint.comp (generated ρ W).starProjection + +include hfactor in +lemma leftCompression_right : (leftCompression ρ V W).comp W=1 := by + rw [leftCompression,ContinuousLinearMap.comp_assoc,generated_projection_right] + simpa [ContinuousLinearMap.one_def] using (hfactor 1).symm + +include hfactor in +lemma leftCompression_intertwines (a : A) : + (π a).comp (leftCompression ρ V W)=(leftCompression ρ V W).comp (ρ a) := by + ext x + change π a (V.adjoint ((generated ρ W).starProjection x))= + V.adjoint ((generated ρ W).starProjection (ρ a x)) + rw [factor_intertwines_on_generated π ρ V W hfactor a ((generated ρ W).starProjection_apply_mem x)] + congr 1 + exact (congrArg (fun T : K →L[ℂ] K => T x) (generated_projection_commutes ρ W a)).symm + +end Kadison.CbFactor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FactorMetric.lean b/lean/OAI/Analysis/Commutator/FactorMetric.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ed798507115bca9dacbc8c654115a2b741d945f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FactorMetric.lean @@ -0,0 +1,68 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace CStarAlgebra + +namespace Kadison.CbFactor + +variable {A H K : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma gram_strictlyPositive (L : K →L[ℂ] H) (W : H →L[ℂ] K) + (hLW : L.comp W=1) : IsStrictlyPositive (L.comp L.adjoint) := by + let T := W.comp W.adjoint + let c : ℝ := ‖T‖+1 + have hc : 0 test n a ξ) μ) + (htb : ∀ n,∀ᵐ a ∂μ,‖test n a‖≤1) + (htP : ∀ n,operator μ (test n) (ht n) (htb n)∈P) + (htQ : ∀ n,∀ᵐ a ∂μ,test n a∈Q a) + (hfiberdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) a ξ) atTop (𝓝 (A ξ))) + (hglobaldense : ∀ A : Lp H 2 μ →L[ℂ] Lp H 2 μ,A∈P → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ f,Tendsto + (fun n => operator μ (test (k n)) (ht (k n)) (htb (k n)) f) atTop (𝓝 (A f))) + (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (Lp H 2 μ →L[ℂ] Lp H 2 μ)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + choose T hm hb he hq using (fun i j => exists_member_field μ P Q + (fun s hs => (hdiag s hs).2) test ht htb htQ hglobaldense (X i j) (hX i j)) + have hmem : ∀ᵐ a ∂μ,∀ i j,T i j a∈Q a := + ae_all_iff.mpr (fun i => ae_all_iff.mpr (fun j => hq i j)) + have hg := localized_matrix_commutator_bound μ P Q hfac hdiag test ht htb htP + hfiberdense Y h hh T hm (fun i j => norm_nonneg (X i j)) hb hmem + simpa only [←he] using hg + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FaithfulNormalFunctional.lean b/lean/OAI/Analysis/Commutator/FaithfulNormalFunctional.lean new file mode 100644 index 0000000000000000000000000000000000000000..95c6f8b414bf2bafa5400375918592f227dfc5a4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FaithfulNormalFunctional.lean @@ -0,0 +1,113 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.FaithfulNormalFunctional + +variable {H : Type*} [NormedAddCommGroup H] + +variable (x : ℕ → H) + +def weight (n : ℕ) : ℝ := (1/2:ℝ)^n/(1+‖x n‖^2) + +lemma weight_pos (n : ℕ) : 0 term x n T) := + ((summable_geometric_of_norm_lt_one (by norm_num : ‖(1/2:ℝ)‖<1)).mul_right ‖T‖).of_norm_bounded + (fun n => term_bound x n T) + +lemma term_add (n : ℕ) (S T : H →L[ℂ] H) : term x n (S+T)=term x n S+term x n T := by + simp [term,mul_add] + +lemma term_smul (n : ℕ) (z : ℂ) (T : H →L[ℂ] H) : term x n (z•T)=z*term x n T := by + simp only [term,smul_apply,inner_smul_right] + ring + +lemma term_nonneg (n : ℕ) {T : H →L[ℂ] H} (hT : 0≤T) : 0≤term x n T := by + apply mul_nonneg (Complex.zero_le_real.mpr (weight_pos x n).le) + exact (ContinuousLinearMap.nonneg_iff_isPositive.mp hT).inner_nonneg_right _ + +def functional : (H →L[ℂ] H) →ₚ[ℂ] ℂ where + toFun T := ∑' n,term x n T + map_add' S T := by simp_rw [term_add]; exact (term_summable x S).tsum_add (term_summable x T) + map_smul' z T := by simp_rw [term_smul,tsum_mul_left]; rfl + monotone' := by + intro S T hST + have hnon : 0≤∑' n,term x n (T-S) := tsum_nonneg (fun n => term_nonneg x n (sub_nonneg.mpr hST)) + have hsub : (∑' n,term x n (T-S))=(∑' n,term x n T)-(∑' n,term x n S) := by + rw [←(term_summable x T).tsum_sub (term_summable x S)] + congr 1 + ext n + simp [term,mul_sub] + rw [hsub] at hnon + exact sub_nonneg.mp hnon + +variable [CompleteSpace H] + +lemma functional_faithful (hd : DenseRange x) (T : H →L[ℂ] H) + (hz : functional x (star T*T)=0) : T=0 := by + have hzero (n : ℕ) : T (x n)=0 := by + have hterm : term x n (star T*T)=0 := by + apply le_antisymm ?_ (term_nonneg x n (star_mul_self_nonneg _)) + have ht := (term_summable x (star T*T)).le_tsum n + (fun j _ => term_nonneg x j (star_mul_self_nonneg _)) + exact ht.trans_eq hz + change (weight x n:ℂ)*inner ℂ (x n) (T.adjoint (T (x n)))=0 at hterm + rw [ContinuousLinearMap.adjoint_inner_right] at hterm + exact inner_self_eq_zero.mp ((mul_eq_zero.mp hterm).resolve_left + (Complex.ofReal_ne_zero.mpr (ne_of_gt (weight_pos x n)))) + ext y + exact hd.induction_on y (isClosed_eq T.continuous continuous_const) hzero + +lemma functional_boundedWOT (C : ℝ) : + Continuous (fun a : {T : H →WOT[ℂ] H // ‖T.toCLM‖≤C} => functional x a.val.toCLM) := by + apply continuous_tsum + (u:=fun n => (1/2:ℝ)^n*max C 0) + · intro n + exact continuous_const.mul (ContinuousLinearMapWOT.continuous_inner_apply + continuous_subtype_val (x n) (x n)) + · exact (summable_geometric_of_norm_lt_one (by norm_num : ‖(1/2:ℝ)‖<1)).mul_right _ + · intro n a + exact (term_bound x n a.val.toCLM).trans (mul_le_mul_of_nonneg_left + (a.property.trans (le_max_left _ _)) (by positivity)) + +end Kadison.FaithfulNormalFunctional + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FaithfulNormalRepresentationLinks.lean b/lean/OAI/Analysis/Commutator/FaithfulNormalRepresentationLinks.lean new file mode 100644 index 0000000000000000000000000000000000000000..c71fb3f54c7de0700f5a14053ddcf116c7c73097 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FaithfulNormalRepresentationLinks.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalRepresentationLinks +import OAI.Analysis.Commutator.StandardTrace +import OAI.Analysis.Commutator.FullCentralSupportLinks + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.NormalRepresentation + +open HilbertBiprod PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +private lemma faithful_diagonal_support {G A : Type*} + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] [CStarAlgebra A] + (first : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (second : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + (bicommutant : Set.centralizer (Set.centralizer (Set.range (diagHom first second))) = + Set.range (diagHom first second)) (faithful : Function.Injective second) : + (FactorCorner.supportSpace (BicommutantRange.ofStarHom (diagHom first second) + bicommutant).commutant (right (H:=H) (G:=G))).starProjection=1 := by + let algebra := BicommutantRange.ofStarHom (diagHom first second) bicommutant + let projection := (FactorCorner.supportSpace algebra.commutant + (right (H:=H) (G:=G))).starProjection + have membership : projection ∈ algebra := by + have membership := FactorCorner.projection_commutant algebra.commutant + (right (H:=H) (G:=G)) + rw [VonNeumannAlgebra.coe_commutant] at membership + rwa [algebra.centralizer_centralizer] at membership + obtain ⟨element,image_eq⟩ := membership + have fixes_right : projection * right=right := by + apply ContinuousLinearMap.ext + intro vector + apply Submodule.starProjection_eq_self_iff.mpr + exact FactorCorner.generator_mem algebra.commutant + (right (H:=H) (G:=G)) algebra.commutant.one_mem vector + rw [←image_eq] at fixes_right + have second_eq : second element=1 := by + apply ContinuousLinearMap.ext + intro vector + have evaluation := congrArg (fun operator : Space H G →L[ℂ] Space H G => + (operator (inr vector)).ofLp.2) fixes_right + exact evaluation + have element_eq : element=1 := faithful (by simpa using second_eq) + change projection=1 + rw [←image_eq,element_eq,map_one] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma right_full_central_support (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) : + (FactorCorner.supportSpace (diagonalAlgebra M τ hnormal).commutant + (right (H:=H) (G:=τ.GNS))).starProjection=1 := by + exact faithful_diagonal_support (A:=M) (H:=H) (G:=τ.GNS) + M.toStarSubalgebra.subtype τ.gnsStarAlgHom + (NormalOperatorHom.diagonal_gns_range M τ hnormal) (NormalGNS.gns_injective M τ hfaith) + +theorem exists_orthogonal_links_of_faithful + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) : + ∃ S : Set (Link (diagonalAlgebra M τ hnormal).commutant + (right (H:=H) (G:=τ.GNS)) left), + OrthogonalLinks _ _ _ S ∧ (familySpace _ _ _ S).starProjection=left := by + obtain ⟨S,hS⟩ := exists_maximal_orthogonalLinks (diagonalAlgebra M τ hnormal).commutant + (right (H:=H) (G:=τ.GNS)) left + refine ⟨S,hS.1,?_⟩ + exact maximal_family_spans_of_full_support _ _ _ + (right_full_central_support M τ hnormal hfaith) + (right_mem_commutant M τ hnormal) (left_mem_commutant M τ hnormal) + right_projection left_projection S hS + +end Kadison.NormalRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FaithfulNormalStateProducer.lean b/lean/OAI/Analysis/Commutator/FaithfulNormalStateProducer.lean new file mode 100644 index 0000000000000000000000000000000000000000..9f3a981a732e9e6d2ba64752d047870e7c0929d7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FaithfulNormalStateProducer.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.Commutator.FaithfulNormalFunctional +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology ComplexOrder + +namespace Kadison + +namespace FaithfulNormalFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (x : ℕ → H) (M : VonNeumannAlgebra H) + +def restricted : M →ₚ[ℂ] ℂ where + toFun a := functional x (a : H →L[ℂ] H) + map_add' _ _ := (functional x).map_add _ _ + map_smul' _ _ := (functional x).map_smul _ _ + monotone' := fun _ _ h => (functional x).monotone h + +lemma restricted_faithful (hd : DenseRange x) (a : M) + (hz : restricted x M (star a*a)=0) : a=0 := + Subtype.ext (functional_faithful x hd (a : H →L[ℂ] H) hz) + +lemma restricted_normal : NormalGNS.BoundedWOTContinuous M (restricted x M) := by + intro C + let f : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} → + {T : H →WOT[ℂ] H // ‖T.toCLM‖≤C} := fun a => ⟨a.val,a.property.2⟩ + have hf : Continuous f := continuous_subtype_val.subtype_mk (fun a => a.property.2) + exact (functional_boundedWOT x C).comp hf + +end FaithfulNormalFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_faithful_normal_positive [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) : + ∃ τ : M →ₚ[ℂ] ℂ, NormalGNS.BoundedWOTContinuous M τ ∧ + ∀ a : M,τ (star a*a)=0 → a=0 := by + obtain ⟨x,hx⟩ := TopologicalSpace.exists_dense_seq H + exact ⟨FaithfulNormalFunctional.restricted x M, + FaithfulNormalFunctional.restricted_normal x M, + FaithfulNormalFunctional.restricted_faithful x M hx⟩ + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FaithfulPositive.lean b/lean/OAI/Analysis/Commutator/FaithfulPositive.lean new file mode 100644 index 0000000000000000000000000000000000000000..3eda65dffc1fd2b9a3686ad57edbc3d88c78f6bb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FaithfulPositive.lean @@ -0,0 +1,39 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped CStarAlgebra + +namespace Kadison + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] + +lemma faithfulStar_nonneg_iff (φ : A →⋆ₐ[ℂ] B) (hφ : Function.Injective φ) (a : A) : + 0 ≤ φ a ↔ 0 ≤ a := by + refine ⟨fun h => ?_,fun h => map_nonneg φ h⟩ + have hb : IsSelfAdjoint (φ a) := IsSelfAdjoint.of_nonneg h + have ha : IsSelfAdjoint a := by + apply hφ + simpa only [map_star] using hb.star_eq + apply (CFC.posPart_eq_self a).mp + apply hφ + rw [CFC.posPart_def] + change φ.toNonUnitalStarAlgHom (cfcₙ (fun r : ℝ => r⁺) a)=φ a + rw [φ.toNonUnitalStarAlgHom.map_cfcₙ (fun r : ℝ => r⁺) a (ha:=ha) (hφa:=hb)] + exact (CFC.posPart_eq_self (φ a)).mpr h + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FaithfulVectorGNS.lean b/lean/OAI/Analysis/Commutator/FaithfulVectorGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..e36461561d992360838ffd8ac3fa73264e30d868 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FaithfulVectorGNS.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.FaithfulNormalStateProducer +import OAI.Analysis.Commutator.GNSVectorEmbedding +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology ENNReal + +namespace Kadison.FaithfulNormalFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (x : ℕ → H) + +def weighted (n : ℕ) : H := (Real.sqrt (weight x n) : ℂ) • x n + +omit [CompleteSpace H] in +lemma weighted_norm_sq (n : ℕ) : ‖weighted x n‖^2=weight x n*‖x n‖^2 := by + rw [weighted,norm_smul,mul_pow,Complex.norm_real,Real.norm_of_nonneg (Real.sqrt_nonneg _), + Real.sq_sqrt (weight_pos x n).le] + +omit [CompleteSpace H] in +lemma weighted_mem : Memℓp (weighted x) 2 := by + apply (memℓp_gen_iff (by norm_num : 0<(2:ℝ≥0∞).toReal)).mpr + have hs : Summable (fun n => ‖weighted x n‖^2) := + Summable.of_nonneg_of_le (fun n => sq_nonneg _) (fun n => by + rw [weighted_norm_sq]; exact weight_norm_bound x n) + (summable_geometric_of_norm_lt_one (by norm_num : ‖(1/2:ℝ)‖<1)) + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using hs + +def vector : InfiniteAmplification.Space ℕ H := ⟨weighted x,weighted_mem x⟩ + +lemma vector_inner (T : H →L[ℂ] H) : + inner ℂ (vector x) ((InfiniteAmplification.diagonal (H:=H) (ι:=ℕ)) T (vector x))=functional x T := by + rw [lp.inner_eq_tsum] + apply tsum_congr + intro n + change inner ℂ ((Real.sqrt (weight x n):ℂ) • x n) + (T ((Real.sqrt (weight x n):ℂ) • x n))=term x n T + rw [map_smul,inner_smul_left,inner_smul_right] + simp only [Complex.conj_ofReal,term] + rw [←mul_assoc,←Complex.ofReal_mul,←pow_two,Real.sq_sqrt (weight_pos x n).le] + +variable (M : VonNeumannAlgebra H) + +def gnsEmbedding : (restricted x M).GNS →ₗᵢ[ℂ] InfiniteAmplification.Space ℕ H := + VectorGNS.embedding (restricted x M) + ((InfiniteAmplification.diagonal (H:=H) (ι:=ℕ)).comp M.subtype) (vector x) (fun a => (vector_inner x a.val).symm) + +lemma gnsEmbedding_intertwines (a : M) (v : (restricted x M).GNS) (n : ℕ) : + gnsEmbedding x M ((restricted x M).gnsStarAlgHom a v) n=a.val (gnsEmbedding x M v n) := by + exact congrArg (fun T : (restricted x M).GNS →L[ℂ] InfiniteAmplification.Space ℕ H => T v n) + (VectorGNS.intertwines (restricted x M) + ((InfiniteAmplification.diagonal (H:=H) (ι:=ℕ)).comp M.subtype) (vector x) + (fun a => (vector_inner x a.val).symm) a) + +end Kadison.FaithfulNormalFunctional + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FejerTest.lean b/lean/OAI/Analysis/Commutator/FejerTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..1da71f7a052bc9152a8bc7ee14dcd90d82912498 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FejerTest.lean @@ -0,0 +1,204 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.FejerTest + +lemma sum_fin_val (n : ℕ) : + (∑ i : Fin n, (i.val : ℝ)) = (n : ℝ) * ((n : ℝ)-1) / 2 := by + induction n with + | zero => simp + | succ n ih => + rw [Fin.sum_univ_castSucc] + simp only [Fin.val_castSucc, Fin.val_last, ih, Nat.cast_add, Nat.cast_one] + ring + +lemma hankel_average (N : ℕ) (hN : 0 < N) : + (N : ℝ)⁻¹ * ∑ j : Fin N, ∑ k : Fin N, + (((2*N : ℝ) - j.val - k.val - 1) / (2*N : ℝ)^2) = 1/4 := by + have hn : (N : ℝ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hN) + simp only [← Finset.sum_div, Finset.sum_sub_distrib, Finset.sum_const, + Finset.card_univ, Fintype.card_fin, nsmul_eq_mul, sum_fin_val] + simp only [← Finset.mul_sum, sum_fin_val] + field_simp [hn] + ring + +lemma triangular_count (m l : ℕ) : + (∑ j ∈ Finset.range m, ∑ i ∈ Finset.range m, + if i = j+l then (1 : ℂ) else 0) = ((m-l : ℕ) : ℂ) := by + have hs (j : ℕ) : (∑ i ∈ Finset.range m, if i = j+l then (1 : ℂ) else 0) = + if j+l < m then 1 else 0 := by simp [Finset.mem_range] + simp only [hs] + have he : ∀ j : ℕ, j+l < m ↔ j < m-l := by omega + simp only [he] + rw [← Finset.sum_filter] + have hf : (Finset.range m).filter (fun j => j < m-l) = Finset.range (m-l) := by + ext j + simp only [Finset.mem_filter, Finset.mem_range] + omega + simp [hf] + +variable {A : Type*} [CStarAlgebra A] + +def powerAverage (w : A) (m : ℕ) : A := + ((m : ℂ)⁻¹) • ∑ i ∈ Finset.range m, w^i + +def testPolynomial (w : A) (m : ℕ) : A := + star (powerAverage w m) * powerAverage w m - ((m : ℂ)⁻¹) • (1 : A) + +lemma norm_powerAverage_le (w : A) (m : ℕ) (hm : 0 < m) (hw : ‖w‖ ≤ 1) : + ‖powerAverage w m‖ ≤ 1 := by + nontriviality A + have hm' : (0 : ℝ) < m := by exact_mod_cast hm + unfold powerAverage + rw [norm_smul, norm_inv, Complex.norm_natCast] + calc + _ ≤ (m : ℝ)⁻¹ * ∑ _i ∈ Finset.range m, (1 : ℝ) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr (le_of_lt hm')) + apply (norm_sum_le _ _).trans + apply Finset.sum_le_sum + intro i _ + cases i with + | zero => simp + | succ i => + exact (norm_pow_le' w (Nat.succ_pos i)).trans + ((pow_le_pow_left₀ (norm_nonneg _) hw _).trans_eq (one_pow _)) + _ = 1 := by simp [ne_of_gt hm'] + +lemma testPolynomial_selfAdjoint (w : A) (m : ℕ) : + IsSelfAdjoint (testPolynomial w m) := by + unfold testPolynomial + exact (IsSelfAdjoint.star_mul_self _).sub + (IsSelfAdjoint.smul (by simp [IsSelfAdjoint]) (IsSelfAdjoint.one A)) + +lemma norm_testPolynomial_le (w : A) (m : ℕ) (hm : 0 < m) (hw : ‖w‖ ≤ 1) : + ‖testPolynomial w m‖ ≤ 2 := by + nontriviality A + have hq := norm_powerAverage_le w m hm hw + have hm' : (1 : ℝ) ≤ m := by exact_mod_cast hm + calc + _ ≤ ‖star (powerAverage w m) * powerAverage w m‖ + ‖((m : ℂ)⁻¹) • (1 : A)‖ := + norm_sub_le _ _ + _ ≤ 1+1 := by + apply add_le_add + · apply (norm_mul_le _ _).trans + simpa only [norm_star, mul_one] using + (mul_le_mul hq hq (norm_nonneg _) zero_le_one) + · rw [norm_smul, norm_inv, Complex.norm_natCast] + exact (mul_le_mul_of_nonneg_left (le_of_eq (norm_one (α := A))) (by positivity)).trans + (by simpa using (inv_le_one₀ (by positivity : (0 : ℝ) < m)).mpr hm') + _ = 2 := by norm_num + +variable [PartialOrder A] [StarOrderedRing A] + +variable (φ : A →ₚ[ℂ] ℂ) (w : A) + +def HaarMoments : Prop := + ∀ i j : ℕ, φ (star (w^i) * w^j) = if i=j then 1 else 0 + +variable (hhaar : HaarMoments φ w) + +include hhaar + +omit [StarOrderedRing A] in +lemma moment_power (l : ℕ) : φ (w^l) = if l=0 then 1 else 0 := by + simpa [eq_comm] using hhaar 0 l + +omit [StarOrderedRing A] in +lemma moment_square_shift (m l : ℕ) : + φ (star (powerAverage w m) * powerAverage w m * w^l) = + (m : ℂ)⁻¹ * (m : ℂ)⁻¹ * ((m-l : ℕ) : ℂ) := by + change ∀ i j : ℕ, φ (star (w^i) * w^j) = if i=j then 1 else 0 at hhaar + have hs : star ((m : ℂ)⁻¹) = (m : ℂ)⁻¹ := by simp + simp only [powerAverage, star_smul, hs, star_sum, + smul_mul_assoc, mul_smul_comm, Finset.sum_mul, Finset.mul_sum, map_smul, + map_sum, smul_eq_mul, mul_assoc, ← pow_add, hhaar] + simp only [← Finset.mul_sum, ← mul_assoc] + rw [triangular_count] + +omit [StarOrderedRing A] in +lemma moment_square (m : ℕ) (hm : 0 < m) : + φ (star (powerAverage w m) * powerAverage w m) = (m : ℂ)⁻¹ := by + have hm' : (m : ℂ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hm) + simpa [hm'] using moment_square_shift φ w hhaar m 0 + +omit [StarOrderedRing A] in +lemma moment_testPolynomial (h1 : φ 1 = 1) (m : ℕ) (hm : 0 < m) : + φ (testPolynomial w m) = 0 := by + simp [testPolynomial, moment_square φ w hhaar m hm, h1] + +omit [StarOrderedRing A] in +lemma positive_coefficient (m l : ℕ) (hm : 0 < m) + (hl : 0 < l) (hlm : l < m) : + φ (testPolynomial w m * w^l) = ((m : ℂ) - (l : ℂ)) / (m : ℂ)^2 := by + have hm' : (m : ℂ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hm) + simp only [testPolynomial, sub_mul, smul_mul_assoc, one_mul, map_sub, map_smul, + moment_square_shift φ w hhaar, moment_power φ w hhaar, + ite_eq_right (Nat.ne_of_gt hl), smul_zero, sub_zero] + rw [Nat.cast_sub (Nat.le_of_lt hlm)] + field_simp + +omit hhaar in +lemma preGNS_mul_norm_le (a b : A) : + ‖φ.toPreGNS (a*b)‖ ≤ ‖a‖ * ‖φ.toPreGNS b‖ := by + have hn : ‖φ.leftMulMapPreGNS a‖ ≤ ‖a‖ := + LinearMap.mkContinuous_norm_le _ (norm_nonneg _) _ + exact ((φ.leftMulMapPreGNS a).le_opNorm (φ.toPreGNS b)).trans + (mul_le_mul_of_nonneg_right hn (norm_nonneg _)) + +omit hhaar in +lemma norm_preGNS_one (h1 : φ 1 = 1) : ‖φ.toPreGNS 1‖ = 1 := by + simp [PositiveLinearMap.preGNS_norm_def, h1] + +lemma norm_preGNS_powerAverage (m : ℕ) (hm : 0 < m) : + ‖φ.toPreGNS (powerAverage w m)‖ = Real.sqrt ((m : ℝ)⁻¹) := by + rw [PositiveLinearMap.preGNS_norm_def] + change Real.sqrt (φ (star (powerAverage w m) * powerAverage w m)).re = _ + rw [moment_square φ w hhaar m hm] + congr 1 + rw [← Complex.ofReal_natCast, ← Complex.ofReal_inv, Complex.ofReal_re] + +lemma norm_preGNS_testPolynomial (h1 : φ 1 = 1) (m : ℕ) (hm : 0 < m) + (hw : ‖w‖ ≤ 1) : + ‖φ.toPreGNS (testPolynomial w m)‖ ≤ 2 * Real.sqrt ((m : ℝ)⁻¹) := by + have hm' : (1 : ℝ) ≤ m := by exact_mod_cast hm + have hs := norm_preGNS_powerAverage φ w hhaar m hm + have hq := norm_powerAverage_le w m hm hw + have hi : (m : ℝ)⁻¹ ≤ Real.sqrt ((m : ℝ)⁻¹) := by + have hp : 0 ≤ (m : ℝ)⁻¹ := by positivity + have hu : (m : ℝ)⁻¹ ≤ 1 := (inv_le_one₀ (by positivity)).mpr hm' + have hh := Real.sq_sqrt hp + have := Real.sqrt_nonneg ((m : ℝ)⁻¹) + nlinarith [mul_nonneg hp (sub_nonneg.mpr hu)] + calc + _ ≤ ‖φ.toPreGNS (star (powerAverage w m) * powerAverage w m)‖ + + ‖φ.toPreGNS (((m : ℂ)⁻¹) • (1 : A))‖ := by + simpa only [testPolynomial, map_sub] using + norm_sub_le (φ.toPreGNS (star (powerAverage w m) * powerAverage w m)) + (φ.toPreGNS (((m : ℂ)⁻¹) • (1 : A))) + _ ≤ Real.sqrt ((m : ℝ)⁻¹) + (m : ℝ)⁻¹ := by + apply add_le_add + · apply (preGNS_mul_norm_le φ _ _).trans + rw [norm_star, hs] + simpa only [one_mul] using + mul_le_mul_of_nonneg_right hq (Real.sqrt_nonneg _) + · simp only [map_smul, norm_smul, norm_inv, Complex.norm_natCast, + norm_preGNS_one φ h1, mul_one, le_refl] + _ ≤ _ := by linarith + +end Kadison.FejerTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiberCommutator.lean b/lean/OAI/Analysis/Commutator/FiberCommutator.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ced47b8c8429510e2aaac7567e21dab70ec9277 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiberCommutator.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.DecomposableNorm +import OAI.Analysis.Commutator.StrongContractionLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma commutator_measurable (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) (ξ : H) : + AEStronglyMeasurable (fun a => (T a*S a-S a*T a) ξ) μ := + (mul_measurable μ T S hT hS ξ).sub (mul_measurable μ S T hS hT ξ) + +omit [CompleteSpace H] in +lemma commutator_field_bound (T S : Ω → H →L[ℂ] H) {b c : ℝ} (hb0 : 0≤b) (hc0 : 0≤c) + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + ∀ᵐ a ∂μ,‖T a*S a-S a*T a‖≤2*b*c := by + filter_upwards [mul_bound μ T S hb0 hb hc,mul_bound μ S T hc0 hc hb] with a h1 h2 + exact (norm_sub_le _ _).trans (by nlinarith) + +omit [CompleteSpace H] in +lemma operator_commutator (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c : ℝ} (hb0 : 0≤b) (hc0 : 0≤c) + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) : + operator μ T hT hb*operator μ S hS hc-operator μ S hS hc*operator μ T hT hb= + operator μ (fun a => T a*S a-S a*T a) (commutator_measurable μ T S hT hS) + (commutator_field_bound μ T S hb0 hc0 hb hc) := by + apply operator_eq_of_ae_apply + intro f + filter_upwards [operator_ae μ T hT hb (operator μ S hS hc f), + operator_ae μ S hS hc (operator μ T hT hb f),operator_ae μ T hT hb f, + operator_ae μ S hS hc f, + Lp.coeFn_sub (operator μ T hT hb (operator μ S hS hc f)) + (operator μ S hS hc (operator μ T hT hb f))] with a h1 h2 h3 h4 h5 + change (operator μ T hT hb (operator μ S hS hc f)-operator μ S hS hc (operator μ T hT hb f)) a=_ + rw [h5] + change operator μ T hT hb (operator μ S hS hc f) a- + operator μ S hS hc (operator μ T hT hb f) a=_ + rw [h1,h2,h3,h4] + rfl + +variable [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +omit [CompleteSpace H] in +lemma commutator_ae_bound (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ : H,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c d : ℝ} (hb0 : 0≤b) (hc0 : 0≤c) (hd : 0≤d) + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) + (hn : ‖operator μ T hT hb*operator μ S hS hc-operator μ S hS hc*operator μ T hT hb‖≤d) : + ∀ᵐ a ∂μ,‖T a*S a-S a*T a‖≤d := by + rw [operator_commutator μ T S hT hS hb0 hc0 hb hc] at hn + exact (operator_norm_le_iff_ae μ _ _ _ hd).mp hn + +theorem seminorm_ae_le (P : VonNeumannAlgebra (Lp H 2 μ)) (Q : Ω → VonNeumannAlgebra H) + (T : Ω → H →L[ℂ] H) + (hT : ∀ ξ : H,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb0 : 0≤b) (hb : ∀ᵐ a ∂μ,‖T a‖≤b) + (c : ℕ → Ω → H →L[ℂ] H) + (hm : ∀ n ξ,AEStronglyMeasurable (fun a => c n a ξ) μ) + (hc : ∀ n,∀ᵐ a ∂μ,‖c n a‖≤1) + (hmem : ∀ n,operator μ (c n) (hm n) (hc n)∈P) + (hdense : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => c (k n) a ξ) atTop (𝓝 (A ξ))) : + ∀ᵐ a ∂μ,commutatorSeminorm (Q a) (T a)≤commutatorSeminorm P (operator μ T hT hb) := by + let d := commutatorSeminorm P (operator μ T hT hb) + have hd : 0≤d := commutatorSeminorm_nonneg P _ + have ht (n : ℕ) : ∀ᵐ a ∂μ,‖T a*c n a-c n a*T a‖≤d := by + apply commutator_ae_bound μ T (c n) hT (hm n) hb0 (by norm_num) hd hb (hc n) + exact commutator_bound_unitball P _ (hmem n) + (operator_norm_le μ (c n) (hm n) (hc n) (by norm_num) (hc n)) + filter_upwards [ae_all_iff.mpr ht,hdense] with a ha hda + apply commutatorSeminorm_le + intro A hA hnA + obtain ⟨k,hk⟩ := hda A hA hnA + apply StrongContractionLimit.norm_le_of_strong (l:=atTop) (fun n => T a*c (k n) a-c (k n) a*T a) _ _ hd + (Eventually.of_forall (fun n => ha (k n))) + intro ξ + exact ((T a).continuous.tendsto (A ξ) |>.comp (hk ξ)).sub (hk (T a ξ)) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiberCommutes.lean b/lean/OAI/Analysis/Commutator/FiberCommutes.lean new file mode 100644 index 0000000000000000000000000000000000000000..3bcf99d1a7ed2cb1f09f74aad95e3547b11f6534 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiberCommutes.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.DenseCommutes +import OAI.Analysis.Commutator.FiberCommutator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma commute_ae_of_commuting_fields (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c : ℝ} (hb0 : 0≤b) (hc0 : 0≤c) + (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) + (hcomm : Commute (operator μ T hT hb) (operator μ S hS hc)) : + ∀ᵐ a ∂μ,Commute (T a) (S a) := by + have hnorm := commutator_ae_bound μ T S hT hS hb0 hc0 (by norm_num : (0:ℝ)≤0) hb hc + (by rw [hcomm.eq,sub_self,norm_zero]) + filter_upwards [hnorm] with a ha + exact sub_eq_zero.mp (norm_eq_zero.mp (le_antisymm ha (norm_nonneg _))) + +theorem commutant_ae_of_dense_commuting_fields + (Q R : Ω → VonNeumannAlgebra H) + (T S : ℕ → Ω → H →L[ℂ] H) + (hT : ∀ n ξ,AEStronglyMeasurable (fun a => T n a ξ) μ) + (hS : ∀ n ξ,AEStronglyMeasurable (fun a => S n a ξ) μ) + (hTb : ∀ n,∀ᵐ a ∂μ,‖T n a‖≤1) (hSb : ∀ n,∀ᵐ a ∂μ,‖S n a‖≤1) + (hcomm : ∀ i j,Commute (operator μ (T i) (hT i) (hTb i)) + (operator μ (S j) (hS j) (hSb j))) + (hTd : ∀ᵐ a ∂μ,∀ A : H →L[ℂ] H,A∈Q a → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => T (k n) a ξ) atTop (𝓝 (A ξ))) + (hSd : ∀ᵐ a ∂μ,∀ B : H →L[ℂ] H,B∈R a → ‖B‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => S (k n) a ξ) atTop (𝓝 (B ξ))) : + ∀ᵐ a ∂μ,R a≤(Q a).commutant := by + have ht (i j : ℕ) := commute_ae_of_commuting_fields μ (T i) (S j) (hT i) (hS j) + (by norm_num) (by norm_num) (hTb i) (hSb j) (hcomm i j) + filter_upwards [hTd,hSd,ae_all_iff.mpr (fun i => ae_all_iff.mpr (fun j => ht i j))] + with a hTd hSd hc + intro B hB + apply VonNeumannAlgebra.mem_commutant_iff.mpr + intro A hA + have hcQ (j : ℕ) : Commute A (S j a) := commutes_of_dense_contraction_tests (Q a) + (fun i => T i a) hTd (S j a) (fun i => hc i j) A hA + exact (commutes_of_dense_contraction_tests (R a) (fun j => S j a) hSd A + (fun j => (hcQ j).symm) B hB).eq.symm + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiberFactorProducer.lean b/lean/OAI/Analysis/Commutator/FiberFactorProducer.lean new file mode 100644 index 0000000000000000000000000000000000000000..026eafe7208888342b09927b911380538522e776 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiberFactorProducer.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.FieldBicommutant +import OAI.Analysis.Commutator.FieldUniqueness +import OAI.Analysis.Commutator.ProjectionCommutant +import OAI.Analysis.Commutator.RankOneFactor + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +omit [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] in +lemma fieldMember_mono {Q R : Ω → VonNeumannAlgebra H} + (hQR : ∀ᵐ a ∂μ,Q a≤R a) {A : Lp H 2 μ →L[ℂ] Lp H 2 μ} + (hA : FieldMember μ Q A) : FieldMember μ R A := by + obtain ⟨T,hm,b,hb,hb0,he,hmem⟩ := hA + refine ⟨T,hm,b,hb,hb0,he,?_⟩ + filter_upwards [hQR,hmem] with a ha hm + exact ha hm + +def fiberJoin (Q R : VonNeumannAlgebra H) : VonNeumannAlgebra H := + (vonNeumannIntersection Q.commutant R.commutant).commutant + +omit [TopologicalSpace.SeparableSpace H] in +lemma le_fiberJoin_left (Q R : VonNeumannAlgebra H) : Q≤fiberJoin Q R := by + intro A hA + apply VonNeumannAlgebra.mem_commutant_iff.mpr + intro Z hZ + exact (VonNeumannAlgebra.mem_commutant_iff.mp hZ.1 A hA).symm + +omit [TopologicalSpace.SeparableSpace H] in +lemma le_fiberJoin_right (Q R : VonNeumannAlgebra H) : R≤fiberJoin Q R := by + intro A hA + apply VonNeumannAlgebra.mem_commutant_iff.mpr + intro Z hZ + exact (VonNeumannAlgebra.mem_commutant_iff.mp hZ.2 A hA).symm + +omit [TopologicalSpace.SeparableSpace H] in +lemma factor_of_rankOne_mem_join (Q R : VonNeumannAlgebra H) + (hRQ : R≤Q.commutant) (v : ℕ → H) (hv : DenseRange v) + (hmem : ∀ i j,InnerProductSpace.rankOne ℂ (v i) (v j)∈fiberJoin Q R) : + FactorCorner.IsFactor Q := by + intro Z hZ hZc + apply scalar_of_dense_rankOne_tests v hv Z + intro i j + apply VonNeumannAlgebra.mem_commutant_iff.mp (hmem i j) Z + exact ⟨VonNeumannAlgebra.mem_commutant_iff.mpr hZc, + VonNeumannAlgebra.mem_commutant_iff.mpr (fun B hB => + (VonNeumannAlgebra.mem_commutant_iff.mp (hRQ hB) Z hZ).symm)⟩ + +theorem factors_ae_of_central_geometry + (P : VonNeumannAlgebra (Lp H 2 μ)) (Q R : Ω → VonNeumannAlgebra H) + (hP : ∀ A,A∈P → FieldMember μ Q A) + (hPc : ∀ A,A∈P.commutant → FieldMember μ R A) + (hRQ : ∀ᵐ a ∂μ,R a≤(Q a).commutant) + (hcenter : ∀ (Z : Lp H 2 μ →L[ℂ] Lp H 2 μ),Z∈P → Z∈P.commutant → + ∀ B : H →L[ℂ] H,Commute + (operator μ (fun _ => B) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z) : + ∀ᵐ a ∂μ,FactorCorner.IsFactor (Q a) := by + let J : Ω → VonNeumannAlgebra H := fun a => fiberJoin (Q a) (R a) + let N := fieldVonNeumann μ J + have hPN : P≤N := fun A hA => fieldMember_mono μ + (Eventually.of_forall (fun a => le_fiberJoin_left (Q a) (R a))) (hP A hA) + have hPcN : P.commutant≤N := fun A hA => fieldMember_mono μ + (Eventually.of_forall (fun a => le_fiberJoin_right (Q a) (R a))) (hPc A hA) + have hconstant (B : H →L[ℂ] H) : ∀ᵐ a ∂μ,B∈J a := by + let C := operator μ (fun _ => B) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) + have hCN : C∈N := by + change C∈N.carrier + rw [←N.centralizer_centralizer'] + intro Z hZ + have hZc : Z∈P.commutant := + VonNeumannAlgebra.mem_commutant_iff.mpr (fun A hA => hZ A (hPN hA)) + have hZP : Z∈P := by + change Z∈P.carrier + rw [←P.centralizer_centralizer'] + intro A hA + exact hZ A (hPcN (VonNeumannAlgebra.mem_commutant_iff.mpr hA)) + exact (hcenter Z hZP hZc B).eq.symm + obtain ⟨T,hm,b,hb,_,he,hmem⟩ := hCN + have heae := field_eq_ae_of_operator_eq μ T (fun _ => B) hm + (fun _ => aestronglyMeasurable_const) hb + (Eventually.of_forall (fun _ => le_rfl)) he.symm + filter_upwards [heae,hmem] with a ha hm + rwa [ha] at hm + let v : ℕ → H := TopologicalSpace.denseSeq H + filter_upwards [hRQ,ae_all_iff.mpr (fun i => ae_all_iff.mpr + (fun j => hconstant (InnerProductSpace.rankOne ℂ (v i) (v j))))] with a ha hm + exact factor_of_rankOne_mem_join (Q a) (R a) ha v + (TopologicalSpace.denseRange_denseSeq H) hm + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldAdjoint.lean b/lean/OAI/Analysis/Commutator/FieldAdjoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..5839a9842cee76a09c82a94e3ebec7ac23d9c3df --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldAdjoint.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Commutator.ScalarIndicator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] + +omit [CompleteSpace H] in +lemma field_inner_integrable (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (ξ η : H) : + Integrable (fun a => inner ℂ (T a ξ) η) μ := by + apply (integrable_const (b*‖ξ‖*‖η‖)).mono' ((hm ξ).inner aestronglyMeasurable_const) + filter_upwards [hb] with a ha + exact (norm_inner_le_norm (T a ξ) η).trans + (mul_le_mul_of_nonneg_right (((T a).le_opNorm ξ).trans + (mul_le_mul_of_nonneg_right ha (norm_nonneg ξ))) (norm_nonneg η)) + +omit [CompleteSpace H] in +lemma field_inner_right_integrable (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (ξ η : H) : + Integrable (fun a => inner ℂ ξ (T a η)) μ := by + apply (integrable_const (‖ξ‖*(b*‖η‖))).mono' (aestronglyMeasurable_const.inner (hm η)) + filter_upwards [hb] with a ha + exact (norm_inner_le_norm ξ (T a η)).trans + (mul_le_mul_of_nonneg_left (((T a).le_opNorm η).trans + (mul_le_mul_of_nonneg_right ha (norm_nonneg η))) (norm_nonneg ξ)) + +omit [CompleteSpace H] in +lemma operator_const_inner_indicator (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (ξ η : H) (s : Set Ω) (hs : MeasurableSet s) : + inner ℂ (operator μ T hm hb (Lp.const 2 μ ξ)) + (indicatorOperator μ s hs (Lp.const 2 μ η))=∫ a in s,inner ℂ (T a ξ) η ∂μ := by + classical + rw [L2.inner_def,←integral_indicator hs] + apply integral_congr_ae + filter_upwards [operator_ae μ T hm hb (Lp.const 2 μ ξ), + Lp.coeFn_const 2 μ ξ,Lp.coeFn_const 2 μ η, + indicatorOperator_ae μ s hs (Lp.const 2 μ η)] with a h1 h2 h3 h4 + rw [h1,h2,h4] + by_cases ha : a∈s + · simp only [Set.indicator_of_mem ha,h3,Function.const_apply] + · simp [ha] + +omit [CompleteSpace H] in +lemma const_inner_operator_indicator (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (ξ η : H) (s : Set Ω) (hs : MeasurableSet s) : + inner ℂ (Lp.const 2 μ ξ) + (operator μ T hm hb (indicatorOperator μ s hs (Lp.const 2 μ η)))= + ∫ a in s,inner ℂ ξ (T a η) ∂μ := by + classical + rw [L2.inner_def,←integral_indicator hs] + apply integral_congr_ae + filter_upwards [operator_ae μ T hm hb (indicatorOperator μ s hs (Lp.const 2 μ η)), + Lp.coeFn_const 2 μ ξ,Lp.coeFn_const 2 μ η, + indicatorOperator_ae μ s hs (Lp.const 2 μ η)] with a h1 h2 h3 h4 + rw [h1,h2,h4] + by_cases ha : a∈s + · simp only [Set.indicator_of_mem ha,h3,Function.const_apply] + · simp [ha] + +theorem adjoint_ae [TopologicalSpace.SeparableSpace H] + (T U : Ω → H →L[ℂ] H) + (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hU : ∀ ξ,AEStronglyMeasurable (fun a => U a ξ) μ) + {b c : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖U a‖≤c) + (h : operator μ U hU hc=(operator μ T hT hb).adjoint) : + ∀ᵐ a ∂μ,U a=(T a).adjoint := by + have hp (ξ η : H) : ∀ᵐ a ∂μ,inner ℂ (U a ξ) η=inner ℂ ξ (T a η) := by + apply Integrable.ae_eq_of_forall_setIntegral_eq _ _ + (field_inner_integrable μ U hU hc ξ η) + (field_inner_right_integrable μ T hT hb ξ η) + intro s hs _ + rw [←operator_const_inner_indicator μ U hU hc ξ η s hs, + ←const_inner_operator_indicator μ T hT hb ξ η s hs,h] + exact ContinuousLinearMap.adjoint_inner_left _ _ _ + let v : ℕ → H := TopologicalSpace.denseSeq H + have hv : DenseRange v := TopologicalSpace.denseRange_denseSeq H + filter_upwards [ae_all_iff.mpr (fun i => ae_all_iff.mpr (fun j => hp (v i) (v j)))] + with a ha + apply ContinuousLinearMap.ext + intro ξ + apply ext_inner_right ℂ + intro η + rw [ContinuousLinearMap.adjoint_inner_left] + exact hv.induction_on ξ + (isClosed_eq ((U a).continuous.inner continuous_const) + (continuous_id.inner continuous_const)) + (fun i => hv.induction_on η + (isClosed_eq (continuous_const.inner continuous_id) + (continuous_const.inner (T a).continuous)) (ha i)) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldAlgebra.lean b/lean/OAI/Analysis/Commutator/FieldAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..7120259a5c4fa714259981081df1e6b18f4a87c7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldAlgebra.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.AddField +import OAI.Analysis.Commutator.ScalarField +import OAI.Analysis.Commutator.StarField + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def FieldMember (Q : Ω → VonNeumannAlgebra H) (A : Lp H 2 μ →L[ℂ] Lp H 2 μ) : Prop := + ∃ (T : Ω → H →L[ℂ] H) (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (b : ℝ) (hb : ∀ᵐ a ∂μ,‖T a‖≤b),0≤b ∧ A=operator μ T hm hb ∧ ∀ᵐ a ∂μ,T a∈Q a + +lemma fieldMember_const (Q : Ω → VonNeumannAlgebra H) (T : H →L[ℂ] H) + (hmem : ∀ᵐ a ∂μ,T∈Q a) : + FieldMember μ Q (operator μ (fun _ => T) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) := + ⟨(fun _ => T),(fun _ => aestronglyMeasurable_const),‖T‖, + Eventually.of_forall (fun _ => le_rfl),norm_nonneg T,rfl,hmem⟩ + +lemma fieldMember_zero (Q : Ω → VonNeumannAlgebra H) : FieldMember μ Q 0 := by + have he : (0 : Lp H 2 μ →L[ℂ] Lp H 2 μ)= + operator μ (fun _ => (0:H →L[ℂ] H)) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) := by + apply operator_eq_of_ae_apply + intro f + filter_upwards [Lp.coeFn_zero H 2 μ] with a ha + exact ha + rw [he] + exact fieldMember_const μ Q 0 (Eventually.of_forall (fun a => (Q a).zero_mem)) + +lemma fieldMember_one (Q : Ω → VonNeumannAlgebra H) : FieldMember μ Q 1 := by + have he : (1 : Lp H 2 μ →L[ℂ] Lp H 2 μ)= + operator μ (fun _ => (1:H →L[ℂ] H)) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) := by + apply operator_eq_of_ae_apply + intro f + exact Eventually.of_forall (fun _ => rfl) + rw [he] + exact fieldMember_const μ Q 1 (Eventually.of_forall (fun a => (Q a).one_mem)) + +lemma fieldMember_add (Q : Ω → VonNeumannAlgebra H) + {A B : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) + (hB : FieldMember μ Q B) : FieldMember μ Q (A+B) := by + obtain ⟨T,hT,b,hb,hb0,rfl,hTm⟩ := hA + obtain ⟨S,hS,c,hc,hc0,rfl,hSm⟩ := hB + refine ⟨(fun a => T a+S a),add_measurable μ T S hT hS,b+c, + add_field_bound μ T S hb hc,add_nonneg hb0 hc0,(operator_add μ T S hT hS hb hc).symm,?_⟩ + filter_upwards [hTm,hSm] with a ha hb + exact (Q a).add_mem ha hb + +lemma fieldMember_mul (Q : Ω → VonNeumannAlgebra H) + {A B : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) + (hB : FieldMember μ Q B) : FieldMember μ Q (A*B) := by + obtain ⟨T,hT,b,hb,hb0,rfl,hTm⟩ := hA + obtain ⟨S,hS,c,hc,hc0,rfl,hSm⟩ := hB + refine ⟨(fun a => T a*S a),mul_measurable μ T S hT hS,b*c, + mul_bound μ T S hb0 hb hc,mul_nonneg hb0 hc0,operator_mul μ T S hT hS hb0 hb hc,?_⟩ + filter_upwards [hTm,hSm] with a ha hb + exact (Q a).mul_mem ha hb + +lemma fieldMember_smul (Q : Ω → VonNeumannAlgebra H) (z : ℂ) + {A : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) : + FieldMember μ Q (z • A) := by + obtain ⟨T,hT,b,hb,hb0,rfl,hTm⟩ := hA + refine ⟨(fun a => z • T a),smul_measurable μ z T hT,‖z‖*b, + smul_field_bound μ z T hb,mul_nonneg (norm_nonneg z) hb0, + (operator_smul μ z T hT hb).symm,?_⟩ + filter_upwards [hTm] with a ha + exact (Q a).smul_mem ha z + +variable [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma fieldMember_star (Q : Ω → VonNeumannAlgebra H) + {A : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) : + FieldMember μ Q (star A) := by + obtain ⟨T,hT,b,hb,hb0,rfl,hTm⟩ := hA + refine ⟨(fun a => (T a).adjoint),adjoint_measurable μ T hT hb,b, + adjoint_field_bound μ T hb,hb0,(operator_adjoint μ T hT hb).symm,?_⟩ + filter_upwards [hTm] with a ha + exact (Q a).star_mem' ha + +def fieldAlgebra (Q : Ω → VonNeumannAlgebra H) : + StarSubalgebra ℂ (Lp H 2 μ →L[ℂ] Lp H 2 μ) where + carrier := FieldMember μ Q + zero_mem' := fieldMember_zero μ Q + one_mem' := fieldMember_one μ Q + add_mem' := fieldMember_add μ Q + mul_mem' := fieldMember_mul μ Q + algebraMap_mem' z := by + change FieldMember μ Q (algebraMap ℂ _ z) + simpa only [Algebra.algebraMap_eq_smul_one] using + fieldMember_smul μ Q z (fieldMember_one μ Q) + star_mem' := fieldMember_star μ Q + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldBicommutant.lean b/lean/OAI/Analysis/Commutator/FieldBicommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0c96db17989beda03632acf54762473de39469d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldBicommutant.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableDenseLimit +import OAI.Analysis.Commutator.FieldNormClosure +import OAI.Analysis.Commutator.KaplanskyFull + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma fieldMember_of_bicommutant_contraction (Q : Ω → VonNeumannAlgebra H) + (A : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (hA : A∈Set.centralizer (Set.centralizer (fieldAlgebra μ Q : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)))) + (hnA : ‖A‖≤1) : FieldMember μ Q A := by + have hcomm (s : Set Ω) (hs : MeasurableSet s) : Commute A (indicatorOperator μ s hs) := by + exact (hA (indicatorOperator μ s hs) + (fun B hB => (fieldMember_commutes_indicator μ Q hB s hs).eq)).symm + obtain ⟨T,hm,hb,he⟩ := exists_field_of_commutes_indicator μ A hcomm + let v : ℕ → H := TopologicalSpace.denseSeq H + have hap (n : ℕ) : ∃ B : Lp H 2 μ →L[ℂ] Lp H 2 μ, + B∈fieldAlgebra μ Q ∧ ‖B‖≤1 ∧ ∀ j : Fin n, + ‖B (Lp.const 2 μ (v j))-A (Lp.const 2 μ (v j))‖<1/((n:ℝ)+1) := + Kaplansky.contraction_finite_approx (Fin n) (fieldAlgebra μ Q) (fieldAlgebra_isClosed μ Q) + hA hnA (fun j => Lp.const 2 μ (v j)) _ (by positivity) + choose B hB hBn hBe using hap + choose S hS hSb hSe hSm using (fun n => fieldMember_tight μ Q (hB n) (by norm_num : (0:ℝ)≤1) (hBn n)) + have hlim (j : ℕ) : Tendsto (fun n => operator μ (S n) (hS n) (hSb n) + (Lp.const 2 μ (TopologicalSpace.denseSeq H j))) atTop + (𝓝 (operator μ T hm hb (Lp.const 2 μ (TopologicalSpace.denseSeq H j)))) := by + simp only [←hSe,←he] + apply tendsto_iff_norm_sub_tendsto_zero.mpr + apply squeeze_zero' (Eventually.of_forall (fun _ => norm_nonneg _)) _ + tendsto_one_div_add_atTop_nhds_zero_nat + filter_upwards [eventually_ge_atTop (j+1)] with n hn + exact (hBe n ⟨j,by omega⟩).le + exact ⟨T,hm,‖A‖,hb,norm_nonneg A,he, + mem_ae_of_bounded_dense_const_limit μ Q T hm hb S hS (by norm_num) hSb hSm hlim⟩ + +lemma fieldMember_of_bicommutant (Q : Ω → VonNeumannAlgebra H) + (A : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (hA : A∈Set.centralizer (Set.centralizer (fieldAlgebra μ Q : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)))) : + FieldMember μ Q A := by + let d : ℂ := ((‖A‖+1:ℝ):ℂ) + have hdR : 0<‖A‖+1 := by positivity + have hd : d≠0 := by + dsimp only [d] + exact_mod_cast (ne_of_gt hdR) + have hdn : ‖d⁻¹ • A‖≤1 := by + rw [norm_smul,norm_inv] + have hnd : ‖d‖=‖A‖+1 := by + dsimp only [d] + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_pos hdR] + rw [hnd] + have hi : (‖A‖+1)⁻¹*‖A‖=‖A‖/(‖A‖+1) := by ring + rw [hi] + exact (div_le_one hdR).mpr (by linarith) + have hdc : d⁻¹ • A∈Set.centralizer (Set.centralizer + (fieldAlgebra μ Q : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) := by + intro B hB + change B*(d⁻¹ • A)=(d⁻¹ • A)*B + rw [mul_smul_comm,smul_mul_assoc,hA B hB] + have hmem := fieldMember_smul μ Q d + (fieldMember_of_bicommutant_contraction μ Q (d⁻¹ • A) hdc hdn) + simpa only [smul_smul,mul_inv_cancel₀ hd,one_smul] using hmem + +def fieldVonNeumann (Q : Ω → VonNeumannAlgebra H) : VonNeumannAlgebra (Lp H 2 μ) where + __ := fieldAlgebra μ Q + centralizer_centralizer' := Set.Subset.antisymm + (fun A hA => fieldMember_of_bicommutant μ Q A hA) + (fun A hA _ hB => (hB A hA).symm) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldMembership.lean b/lean/OAI/Analysis/Commutator/FieldMembership.lean new file mode 100644 index 0000000000000000000000000000000000000000..f72b055d8df3732719bd7013efeb122bd76ce8d9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldMembership.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableLimit +import OAI.Analysis.Commutator.DiagonalCommute +import OAI.Analysis.Commutator.ScalarField + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +theorem exists_member_field (P : VonNeumannAlgebra (Lp H 2 μ)) + (Q : Ω → VonNeumannAlgebra H) + (hdiag : ∀ (s : Set Ω) (hs : MeasurableSet s), + indicatorOperator (H:=H) μ s hs∈Set.centralizer + (P : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ))) + (test : ℕ → Ω → H →L[ℂ] H) + (ht : ∀ n ξ,AEStronglyMeasurable (fun a => test n a ξ) μ) + (htb : ∀ n,∀ᵐ a ∂μ,‖test n a‖≤1) + (htmem : ∀ n,∀ᵐ a ∂μ,test n a∈Q a) + (htdense : ∀ A : Lp H 2 μ →L[ℂ] Lp H 2 μ,A∈P → ‖A‖≤1 → + ∃ k : ℕ → ℕ,∀ f,Tendsto + (fun n => operator μ (test (k n)) (ht (k n)) (htb (k n)) f) atTop (𝓝 (A f))) + (A : Lp H 2 μ →L[ℂ] Lp H 2 μ) (hA : A∈P) : + ∃ (T : Ω → H →L[ℂ] H) (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hb : ∀ᵐ a ∂μ,‖T a‖≤‖A‖),A=operator μ T hm hb ∧ ∀ᵐ a ∂μ,T a∈Q a := by + obtain ⟨T,hm,hb,he⟩ := exists_field_of_commutes_indicator μ A + (fun s hs => (hdiag s hs) A hA) + refine ⟨T,hm,hb,he,?_⟩ + let d : ℂ := ((‖A‖+1:ℝ):ℂ) + have hdR : 0<‖A‖+1 := by positivity + have hd : d≠0 := by + dsimp only [d] + exact_mod_cast (ne_of_gt hdR) + have hdn : ‖d⁻¹ • A‖≤1 := by + rw [norm_smul,norm_inv] + have hnd : ‖d‖=‖A‖+1 := by + dsimp only [d] + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_pos hdR] + rw [hnd] + have hi : (‖A‖+1)⁻¹*‖A‖=‖A‖/(‖A‖+1) := by ring + rw [hi] + exact (div_le_one hdR).mpr (by linarith) + obtain ⟨k,hk⟩ := htdense (d⁻¹ • A) (P.smul_mem hA d⁻¹) hdn + have hlim : ∀ f,Tendsto + (fun n => operator μ (test (k n)) (ht (k n)) (htb (k n)) f) atTop + (𝓝 (operator μ (fun a => d⁻¹ • T a) (smul_measurable μ d⁻¹ T hm) + (smul_field_bound μ d⁻¹ T hb) f)) := by + intro f + rw [operator_smul μ d⁻¹ T hm hb,←he] + exact hk f + have hmem := mem_ae_of_bounded_strong_limit μ Q + (fun a => d⁻¹ • T a) (smul_measurable μ d⁻¹ T hm) + (smul_field_bound μ d⁻¹ T hb) (fun n => test (k n)) (fun n => ht (k n)) + (by norm_num : (0:ℝ)≤1) (fun n => htb (k n)) (fun n => htmem (k n)) hlim + filter_upwards [hmem] with a ha + have h := (Q a).smul_mem (r:=d) ha + change T a∈(Q a).toStarSubalgebra + simpa only [smul_smul,mul_inv_cancel₀ hd,one_smul] using h + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldNormClosure.lean b/lean/OAI/Analysis/Commutator/FieldNormClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..58df53e1a92b20585b428752d0909a0d11d70d00 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldNormClosure.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableLimit +import OAI.Analysis.Commutator.TightField + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma fieldAlgebra_isClosed (Q : Ω → VonNeumannAlgebra H) : + IsClosed (fieldAlgebra μ Q : Set (Lp H 2 μ →L[ℂ] Lp H 2 μ)) := by + apply isClosed_of_closure_subset + intro A hA + have hcomm (s : Set Ω) (hs : MeasurableSet s) : Commute A (indicatorOperator μ s hs) := by + apply closure_minimal (t:={B : Lp H 2 μ →L[ℂ] Lp H 2 μ | + B*indicatorOperator μ s hs=indicatorOperator μ s hs*B}) ?_ + (isClosed_eq (continuous_id.mul continuous_const) (continuous_const.mul continuous_id)) hA + intro B hB + exact fieldMember_commutes_indicator μ Q hB s hs + obtain ⟨T,hm,hb,he⟩ := exists_field_of_commutes_indicator μ A hcomm + have hseq (n : ℕ) : ∃ B : Lp H 2 μ →L[ℂ] Lp H 2 μ, + B∈fieldAlgebra μ Q ∧ ‖B-A‖<1/((n:ℝ)+1) := by + obtain ⟨B,hB,hd⟩ := Metric.mem_closure_iff.mp hA (1/((n:ℝ)+1)) (by positivity) + exact ⟨B,hB,by simpa only [dist_eq_norm,norm_sub_rev] using hd⟩ + choose B hB hdist using hseq + have hBn (n : ℕ) : ‖B n‖≤‖A‖+1 := by + have heps : 1/((n:ℝ)+1)≤1 := (div_le_one (by positivity)).mpr (by linarith [Nat.cast_nonneg (α:=ℝ) n]) + have hnorm := norm_sub_le (B n-A) (-A) + have hn : ‖B n‖≤‖B n-A‖+‖A‖ := by simpa using hnorm + linarith [hdist n] + have hfields (n : ℕ) := fieldMember_tight μ Q (hB n) (by positivity : 0≤‖A‖+1) (hBn n) + choose S hS hSb hSe hSm using hfields + have hlimB : Tendsto B atTop (𝓝 A) := by + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨N,hN⟩ := exists_nat_one_div_lt hε + filter_upwards [eventually_ge_atTop N] with n hn + rw [dist_eq_norm] + apply (hdist n).trans_le + exact (one_div_le_one_div_of_le (by positivity) (by exact_mod_cast Nat.succ_le_succ hn)).trans hN.le + have hlim (f : Lp H 2 μ) : Tendsto + (fun n => operator μ (S n) (hS n) (hSb n) f) atTop + (𝓝 (operator μ T hm hb f)) := by + have hh : Tendsto (fun n => B n f) atTop (𝓝 (A f)) := + (ContinuousLinearMap.apply ℂ (Lp H 2 μ) f).continuous.tendsto A |>.comp hlimB + simpa only [←hSe,←he] using hh + exact ⟨T,hm,‖A‖,hb,norm_nonneg A,he, + mem_ae_of_bounded_strong_limit μ Q T hm hb S hS (by positivity) hSb hSm hlim⟩ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FieldUniqueness.lean b/lean/OAI/Analysis/Commutator/FieldUniqueness.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5caf26d4efe31994893c78e26b6d0477185e20e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FieldUniqueness.lean @@ -0,0 +1,42 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.DecomposableNorm + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma field_eq_ae_of_operator_eq (T S : Ω → H →L[ℂ] H) + (hT : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hS : ∀ ξ,AEStronglyMeasurable (fun a => S a ξ) μ) + {b c : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖S a‖≤c) + (he : operator μ T hT hb=operator μ S hS hc) : T=ᵐ[μ]S := by + have hz : operator μ (fun a => T a-S a) (sub_measurable μ T S hT hS) + (sub_bound μ T S hb hc)=0 := by + rw [←operator_sub μ T S hT hS hb hc,he,sub_self] + have hn := (operator_norm_le_iff_ae μ (fun a => T a-S a) + (sub_measurable μ T S hT hS) (sub_bound μ T S hb hc) (by norm_num : (0:ℝ)≤0)).mp + (by rw [hz]; simp) + filter_upwards [hn] with a ha + exact sub_eq_zero.mp (norm_eq_zero.mp (le_antisymm ha (norm_nonneg _))) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteCancellation.lean b/lean/OAI/Analysis/Commutator/FiniteCancellation.lean new file mode 100644 index 0000000000000000000000000000000000000000..a64fd68b7fc5dffe8c07f24fc8fed996d651b085 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteCancellation.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def IsFiniteAlgebra (M : VonNeumannAlgebra H) : Prop := + ∀ v∈M,star v*v=1 → v*star v=1 + +lemma IsFiniteAlgebra.coisometry {M : VonNeumannAlgebra H} (hM : IsFiniteAlgebra M) + {v : H →L[ℂ] H} (hv : v∈M) (h : v*star v=1) : star v*v=1 := by + simpa only [star_star] using hM (star v) (M.star_mem' hv) (by simpa only [star_star] using h) + +lemma finite_corner_cancel {M : VonNeumannAlgebra H} (hM : IsFiniteAlgebra M) + {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) + (v : Link M e e) (hve : v.initial=e) : v.final=e := by + let r := 1-e + have hr : IsStarProjection r := he.one_sub + have hvr : v.val*r=0 := by + change v.val*(1-e)=0 + rw [mul_sub,mul_one,v.mul_source he,sub_self] + have hrv : r*v.val=0 := by + change (1-e)*v.val=0 + rw [sub_mul,one_mul,v.target_mul he,sub_self] + have hsvr : star v.val*r=0 := by + simpa only [star_mul,hr.isSelfAdjoint.star_eq,star_zero] using congrArg star hrv + have hrsv : r*star v.val=0 := by + simpa only [star_mul,hr.isSelfAdjoint.star_eq,star_zero] using congrArg star hvr + have hi : star (v.val+r)*(v.val+r)=1 := by + rw [star_add,hr.isSelfAdjoint.star_eq,add_mul,mul_add,mul_add,hsvr,hrv, + hr.isIdempotentElem.eq,add_zero,zero_add] + change v.initial+(1-e)=1 + rw [hve]; abel + have hf := hM (v.val+r) (M.add_mem v.mem (M.sub_mem M.one_mem heM)) hi + rw [star_add,hr.isSelfAdjoint.star_eq,add_mul,mul_add,mul_add,hvr,hrsv, + hr.isIdempotentElem.eq,add_zero,zero_add] at hf + change v.final+(1-e)=1 at hf + have := congrArg (fun x : H →L[ℂ] H => x-(1-e)) hf + have hc : (1 : H →L[ℂ] H)-(1-e)=e := by abel + simpa only [add_sub_cancel_right,hc] using this + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + +lemma extend_initial (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : (v.extend he hf w).initial=v.initial+w.initial := by + obtain ⟨hvw,_⟩ := v.residual_cross he hf w + have hwv : star w.val*v.val=0 := by simpa only [star_mul,star_star,star_zero] using congrArg star hvw + change star (v.val+w.val)*(v.val+w.val)=v.initial+w.initial + simp only [star_add,add_mul,mul_add,hvw,hwv,add_zero,zero_add,initial] + +lemma extend_final (v : Link M e f) (he : IsStarProjection e) (hf : IsStarProjection f) + (w : Link M (e-v.initial) (f-v.final)) : (v.extend he hf w).final=v.final+w.final := by + obtain ⟨_,hvw⟩ := v.residual_cross he hf w + have hwv : w.val*star v.val=0 := by simpa only [star_mul,star_star,star_zero] using congrArg star hvw + change (v.val+w.val)*star (v.val+w.val)=v.final+w.final + simp only [star_add,add_mul,mul_add,hvw,hwv,add_zero,zero_add,final] + +end Link + +theorem finite_unitary_extension (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {p q : H →L[ℂ] H} (hpM : p∈M) (hqM : q∈M) + (hp : IsStarProjection p) (hq : IsStarProjection q) + (v : Link M p q) (hvi : v.initial=p) (hvf : v.final=q) : + ∃ u∈M,star u*u=1 ∧ u*star u=1 ∧ u*p=v.val := by + let b : Link M 1 1 := ⟨v.val,v.mem,v.triple,v.source_le.trans hp.le_one,v.target_le.trans hq.le_one⟩ + have hbi : b.initial=p := hvi + have hbf : b.final=q := hvf + have hiM : 1-b.initial∈M := by rw [hbi]; exact M.sub_mem M.one_mem hpM + have hfM : 1-b.final∈M := by rw [hbf]; exact M.sub_mem M.one_mem hqM + obtain ⟨w,hw⟩ := factor_comparison M hfac hiM hfM + (b.residual_source_projection (IsStarProjection.one _)) + (b.residual_target_projection (IsStarProjection.one _)) + let z := b.extend (IsStarProjection.one _) (IsStarProjection.one _) w + have hz : z.initial=1 ∧ z.final=1 := by + rcases hw with hw|hw + · have he : z.initial=1 := by + rw [show z.initial=b.initial+w.initial from b.extend_initial _ _ w,hw]; abel + exact ⟨he,hfin z.val z.mem he⟩ + · have he : z.final=1 := by + rw [show z.final=b.final+w.final from b.extend_final _ _ w,hw]; abel + exact ⟨hfin.coisometry z.mem he,he⟩ + refine ⟨z.val,z.mem,hz.1,hz.2,?_⟩ + simpa only [hbi] using (b.le_extend (IsStarProjection.one _) (IsStarProjection.one _) w).2 + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteDimensionalAverage.lean b/lean/OAI/Analysis/Commutator/FiniteDimensionalAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..fad2e4e19326737fe21d8f1d457530fc03295f2d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteDimensionalAverage.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Commutator.Average +import OAI.Analysis.Commutator.CompactAverage +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.UnitaryHaar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap MeasureTheory + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def algebraUnitaryLift (P : VonNeumannAlgebra K) : unitary P →* unitary (K →L[ℂ] K) where + toFun v := ⟨((v:P):K →L[ℂ] K),Unitary.map_mem P.toStarSubalgebra.subtype v.property⟩ + map_one' := rfl + map_mul' _ _ := rfl + +def algebraUnitaryRepresentation (P : VonNeumannAlgebra K) : unitary P →* (K ≃ₗᵢ[ℂ] K) := + Unitary.linearIsometryEquiv.toMonoidHom.comp + (algebraUnitaryLift P) + +@[simp] lemma algebraUnitaryRepresentation_coe (P : VonNeumannAlgebra K) (v : unitary P) : + (algebraUnitaryRepresentation P v : K →L[ℂ] K)=((v:P):K →L[ℂ] K) := rfl + +lemma algebraUnitaryRepresentation_continuous (P : VonNeumannAlgebra K) (x : K) : + Continuous fun v : unitary P => algebraUnitaryRepresentation P v x := by + change Continuous fun v : unitary P => ((v:P):K →L[ℂ] K) x + exact (continuous_subtype_val.comp continuous_subtype_val).clm_apply continuous_const + +lemma commutes_algebra_of_commutes_unitaries (P : VonNeumannAlgebra K) (T : K →L[ℂ] K) + (hT : ∀ v : unitary P,T*((v:P):K →L[ℂ] K)=((v:P):K →L[ℂ] K)*T) : + ∀ a : P,T*(a:K →L[ℂ] K)=(a:K →L[ℂ] K)*T := by + have hz : innerDerivation P T=0 := by + apply ContinuousLinearMap.coe_injective + apply LinearMap.ext_on (CStarAlgebra.span_unitary P) + intro v hv + exact sub_eq_zero.mpr (hT ⟨v,hv⟩) + intro a + exact sub_eq_zero.mp (congrArg (fun f : P →L[ℂ] (K →L[ℂ] K) => f a) hz) + +lemma unitary_conjugate_distance (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) (v : unitary P) : + ‖CompactAverage.conjugate (algebraUnitaryRepresentation P) Y v-Y‖≤commutatorSeminorm P Y := by + let w : unitary (K →L[ℂ] K) := algebraUnitaryLift P v + have he : CompactAverage.conjugate (algebraUnitaryRepresentation P) Y v-Y= + (((w:K →L[ℂ] K)*Y-Y*(w:K →L[ℂ] K))*star (w:K →L[ℂ] K)) := by + change (w:K →L[ℂ] K)*Y*star (w:K →L[ℂ] K)-Y=_ + rw [sub_mul,mul_assoc Y (w:K →L[ℂ] K) (star (w:K →L[ℂ] K)),w.property.2,mul_one] + rw [he] + rw [CStarRing.norm_mul_mem_unitary _ (Unitary.star_mem w.property), norm_sub_rev] + apply commutator_bound_unitball P Y (v:P).property + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro x + change ‖(w:K →L[ℂ] K) x‖≤1*‖x‖ + rw [one_mul] + exact (Unitary.norm_map w x).le + +theorem finiteDimensional_commutant_approximation (P : VonNeumannAlgebra K) + [FiniteDimensional ℂ P] (Y : K →L[ℂ] K) : + ∃ Y₀ : K →L[ℂ] K, (∀ a : P,Y₀*(a:K →L[ℂ] K)=(a:K →L[ℂ] K)*Y₀) ∧ + ‖Y-Y₀‖≤commutatorSeminorm P Y := by + cases subsingleton_or_nontrivial K with + | inl h => + exact ⟨Y,fun a => Subsingleton.elim _ _,by simpa using commutatorSeminorm_nonneg P Y⟩ + | inr h => + let := UnitaryHaar.compactUnitary P + let : MeasurableSpace (unitary P) := borel (unitary P) + let : BorelSpace (unitary P) := ⟨rfl⟩ + let U := algebraUnitaryRepresentation P + have hU := algebraUnitaryRepresentation_continuous P + let μ := UnitaryHaar.probability (unitary P) + obtain ⟨Y₀,_,hc,hcoeff⟩ := CompactAverage.exists_average U hU Y μ + refine ⟨Y₀,commutes_algebra_of_commutes_unitaries P Y₀ hc,?_⟩ + rw [norm_sub_rev] + apply WeakOperatorIntegral.difference_norm μ (CompactAverage.conjugate U Y) _ Y₀ hcoeff Y + (commutatorSeminorm_nonneg P Y) (unitary_conjugate_distance P Y) + intro x y + exact ((CompactAverage.conjugate_continuous U hU Y x).inner continuous_const).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteDimensionalMain.lean b/lean/OAI/Analysis/Commutator/FiniteDimensionalMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0ba7db00f77f7045cdc5acc20c345d14926b1ea --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteDimensionalMain.lean @@ -0,0 +1,37 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteDimensionalAverage +import OAI.Analysis.Commutator.MainCommutantDistance + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem uniform_commutator_finiteDimensional + (P : VonNeumannAlgebra K) [FiniteDimensional ℂ P] + (Y : K →L[ℂ] K) (h : ℕ) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ ≤ + 2*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + obtain ⟨Y₀,hcomm,hnear⟩ := finiteDimensional_commutant_approximation P Y + exact matrix_commutator_bound_of_commutant_approximation P Y Y₀ hnear hcomm h X hX + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFactorComparison.lean b/lean/OAI/Analysis/Commutator/FiniteFactorComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..ebb5fe5c979177b77b4475b8e98a1b9522bee07e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFactorComparison.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorComparison +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + +lemma initial_mem (v : Link M e f) : v.initial∈M := M.mul_mem (M.star_mem' v.mem) v.mem + +lemma final_mem (v : Link M e f) : v.final∈M := M.mul_mem v.mem (M.star_mem' v.mem) + +lemma trace_initial_final (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (v : Link M e f) : τ ⟨v.initial,v.initial_mem⟩=τ ⟨v.final,v.final_mem⟩ := + hτ (star (⟨v.val,v.mem⟩ : M)) ⟨v.val,v.mem⟩ + +end Link + +lemma faithful_projection (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) + (hz : τ ⟨p,hpM⟩=0) : p=0 := by + have hsq : star (⟨p,hpM⟩ : M)*⟨p,hpM⟩=⟨p,hpM⟩ := by + apply Subtype.ext + change star p*p=p + rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + have hzero := hfaith ⟨p,hpM⟩ (by rw [hsq]; exact hz) + exact congrArg Subtype.val hzero + +theorem finite_factor_comparison (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) + (hle : τ ⟨e,heM⟩≤τ ⟨f,hfM⟩) : + ∃ v : Link M e f, v.initial=e := by + obtain ⟨v,hv⟩ := factor_comparison M hM heM hfM he hf + refine ⟨v,?_⟩ + rcases hv with hv|hv + · exact hv + · have htf : (⟨v.final,v.final_mem⟩ : M)=⟨f,hfM⟩ := Subtype.ext hv + have hti : τ ⟨v.initial,v.initial_mem⟩=τ ⟨f,hfM⟩ := by + rw [v.trace_initial_final τ hτ,htf] + have hmem : e-v.initial∈M := M.sub_mem heM v.initial_mem + have hnonneg : 0≤τ ⟨e-v.initial,hmem⟩ := τ.map_nonneg + (show (0 : M)≤⟨e-v.initial,hmem⟩ from sub_nonneg.mpr v.source_le) + have hzero : τ ⟨e-v.initial,hmem⟩=0 := by + apply le_antisymm ?_ hnonneg + change τ ((⟨e,heM⟩ : M)-⟨v.initial,v.initial_mem⟩)≤0 + rw [map_sub,hti] + exact sub_nonpos.mpr hle + exact (sub_eq_zero.mp (faithful_projection M τ hfaith hmem + (v.residual_source_projection he) hzero)).symm + +theorem finite_factor_equivalence (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) + (heq : τ ⟨e,heM⟩=τ ⟨f,hfM⟩) : + ∃ v∈M, star v*v=e ∧ v*star v=f := by + obtain ⟨v,hvi⟩ := finite_factor_comparison M hM τ hτ hfaith heM hfM he hf heq.le + have hti : τ ⟨v.initial,v.initial_mem⟩=τ ⟨e,heM⟩ := + congrArg τ (Subtype.ext hvi) + have htf : τ ⟨v.final,v.final_mem⟩=τ ⟨f,hfM⟩ := + (v.trace_initial_final τ hτ).symm.trans (hti.trans heq) + have hmem : f-v.final∈M := M.sub_mem hfM v.final_mem + have hzero : τ ⟨f-v.final,hmem⟩=0 := by + change τ ((⟨f,hfM⟩ : M)-⟨v.final,v.final_mem⟩)=0 + rw [map_sub,htf,sub_self] + have hvf := (sub_eq_zero.mp (faithful_projection M τ hfaith hmem + (v.residual_target_projection hf) hzero)).symm + exact ⟨v.val,v.mem,hvi,hvf⟩ + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFactorCornerTransport.lean b/lean/OAI/Analysis/Commutator/FiniteFactorCornerTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..827f10b8cda39c0722ca31f801d61108a5e32307 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFactorCornerTransport.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFactorUnitary + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem finite_factor_unitary_subequivalence (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + (e f : M) (he : IsStarProjection e) (hf : IsStarProjection f) + (hle : τ e≤τ f) : ∃ u : unitary M,(u:M)*e*star (u:M)≤f := by + obtain ⟨v,hvi⟩ := finite_factor_comparison M hM τ hτ hfaith e.property f.property + (he.map M.toStarSubalgebra.subtype) (hf.map M.toStarSubalgebra.subtype) hle + let p : M := ⟨v.final,v.final_mem⟩ + have hp : IsStarProjection p := by + constructor + · apply Subtype.ext + exact v.final_projection.isIdempotentElem.eq + · apply Subtype.ext + exact v.final_projection.isSelfAdjoint.star_eq + have htrace : τ e=τ p := by + have hi : (⟨v.initial,v.initial_mem⟩:M)=e := Subtype.ext hvi + exact (congrArg τ hi).symm.trans (v.trace_initial_final τ hτ) + obtain ⟨u,hu⟩ := finite_factor_unitary_equivalence M hM τ hτ hfaith e p he hp htrace + exact ⟨u,hu.le.trans v.target_le⟩ + +end Kadison.PartialIsometryOrder + +namespace Kadison.CornerTransport + +variable {A B : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] [CStarAlgebra B] + +variable {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma conjugate_corner (e f : A) (he : IsStarProjection e) (hf : IsStarProjection f) + (u : unitary A) (hle : (u:A)*f*star (u:A)≤e) (z : A) (hz : f*z*f=z) : + e*((u:A)*z*star (u:A))*e=(u:A)*z*star (u:A) := by + have hu : star (u:A)*(u:A)=1 := u.property.1 + have hp : IsStarProjection ((u:A)*f*star (u:A)) := by + constructor + · calc + _=(u:A)*f*(star (u:A)*(u:A))*f*star (u:A) := by noncomm_ring + _=(u:A)*f*star (u:A) := by rw [hu,mul_one,mul_assoc (u:A) f f,hf.isIdempotentElem.eq] + · change star ((u:A)*f*star (u:A))=(u:A)*f*star (u:A) + simp only [star_mul,star_star,hf.isSelfAdjoint.star_eq,mul_assoc] + have hleft := (hp.le_iff_mul_eq_right he).mp hle + have hef : e*(u:A)*f=(u:A)*f := by + have h := congrArg (fun x : A => x*(u:A)) hleft + simpa only [mul_assoc,hu,mul_one] using h + have hfue : f*star (u:A)*e=f*star (u:A) := by + simpa only [star_mul,he.isSelfAdjoint.star_eq,hf.isSelfAdjoint.star_eq,mul_assoc] using congrArg star hef + calc + _=e*((u:A)*(f*z*f)*star (u:A))*e := by rw [hz] + _=(e*(u:A)*f)*z*(f*star (u:A)*e) := by noncomm_ring + _=((u:A)*f)*z*(f*star (u:A)) := by rw [hef,hfue] + _=(u:A)*(f*z*f)*star (u:A) := by noncomm_ring + _=(u:A)*z*star (u:A) := by rw [hz] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma bound_under_unitary (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (T : K →L[ℂ] K) + (u : unitary A) (hTu : T*ρ (u:A)=ρ (u:A)*T) + (hTu' : T*ρ (star (u:A))=ρ (star (u:A))*T) (z : A) {c : ℝ} + (h : ‖T*ρ ((u:A)*z*star (u:A))-ρ ((u:A)*z*star (u:A))*T‖≤c*‖(u:A)*z*star (u:A)‖) : + ‖T*ρ z-ρ z*T‖≤c*‖z‖ := by + have he : T*ρ ((u:A)*z*star (u:A))-ρ ((u:A)*z*star (u:A))*T= + ρ (u:A)*(T*ρ z-ρ z*T)*ρ (star (u:A)) := by + simp only [map_mul] + calc + _=(T*ρ (u:A))*ρ z*ρ (star (u:A))-ρ (u:A)*ρ z*(ρ (star (u:A))*T) := by noncomm_ring + _=(ρ (u:A)*T)*ρ z*ρ (star (u:A))-ρ (u:A)*ρ z*(T*ρ (star (u:A))) := by rw [hTu,←hTu'] + _=_ := by noncomm_ring + have hU := Unitary.map_mem ρ u.property + have hU' := Unitary.map_mem ρ (Unitary.star_mem u.property) + rw [he,CStarRing.norm_mul_mem_unitary _ hU',CStarRing.norm_mem_unitary_mul _ hU, + CStarRing.norm_mul_mem_unitary _ (Unitary.star_mem u.property),CStarRing.norm_mem_unitary_mul _ u.property] at h + exact h + +end Kadison.CornerTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFactorMatrices.lean b/lean/OAI/Analysis/Commutator/FiniteFactorMatrices.lean new file mode 100644 index 0000000000000000000000000000000000000000..fa73affa204071195e9baea2f99a1335f3d22a2e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFactorMatrices.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFactorComparison +import OAI.Analysis.Commutator.MatrixUnits +import OAI.Analysis.Commutator.NormalTraceProjection + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem finite_factor_equivalence_link (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) + (heq : τ ⟨e,heM⟩=τ ⟨f,hfM⟩) : + ∃ v : Link M e f, v.initial=e ∧ v.final=f := by + obtain ⟨v,hvi⟩ := finite_factor_comparison M hM τ hτ hfaith heM hfM he hf heq.le + have hti : τ ⟨v.initial,v.initial_mem⟩=τ ⟨e,heM⟩ := congrArg τ (Subtype.ext hvi) + have htf : τ ⟨v.final,v.final_mem⟩=τ ⟨f,hfM⟩ := + (v.trace_initial_final τ hτ).symm.trans (hti.trans heq) + have hmem : f-v.final∈M := M.sub_mem hfM v.final_mem + have hzero : τ ⟨f-v.final,hmem⟩=0 := by + change τ ((⟨f,hfM⟩ : M)-⟨v.final,v.final_mem⟩)=0 + rw [map_sub,htf,sub_self] + have hvf := (sub_eq_zero.mp (faithful_projection M τ hfaith hmem + (v.residual_target_projection hf) hzero)).symm + exact ⟨v,hvi,hvf⟩ + +end Kadison.PartialIsometryOrder + +namespace Kadison.FiniteFactorMatrices + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +theorem partition_representation (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (p : I→M) (hp : ∀ i, IsStarProjection (p i)) + (heq : ∀ i j, τ (p i)=τ (p j)) + (horth : ∀ i j, i≠j → p i*p j=0) (hone : ∑ i,p i=1) : + ∃ φ : Matrix I I ℂ →⋆ₐ[ℂ] M, + ∀ i, φ (Matrix.single i i (1:ℂ))=p i := by + let i₀ : I := Classical.choice inferInstance + have hv : ∀ i, ∃ v : PartialIsometryOrder.Link M (p i₀) (p i), + v.initial=p i₀ ∧ v.final=p i := by + intro i + exact PartialIsometryOrder.finite_factor_equivalence_link M hM τ hτ hfaith + (p i₀).property (p i).property + ((hp i₀).map M.toStarSubalgebra.subtype) ((hp i).map M.toStarSubalgebra.subtype) + (heq i₀ i) + choose v hvi hvf using hv + let u : I→M := fun i => ⟨(v i).val,(v i).mem⟩ + have hsource : ∀ i, star (u i)*u i=p i₀ := fun i => Subtype.ext (hvi i) + have hfinal : ∀ i, u i*star (u i)=p i := fun i => Subtype.ext (hvf i) + have hfix : ∀ i, u i*p i₀=u i := by + intro i + apply Subtype.ext + change (v i).val*(p i₀ : H →L[ℂ] H)=(v i).val + simpa only [hvi i] using (v i).mul_initial + have htarget : ∀ i, p i*u i=u i := by + intro i + apply Subtype.ext + change (p i : H →L[ℂ] H)*(v i).val=(v i).val + simpa only [hvf i] using (v i).final_mul + refine ⟨MatrixUnits.ofPartialIsometries (p i₀) p u hsource hfinal hfix htarget + (fun i => (hp i).isSelfAdjoint.star_eq) horth hone,?_⟩ + intro i + rw [MatrixUnits.ofPartialIsometries_single,hfinal] + +theorem exists_matrix_embedding (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hone : τ 1=1) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (n : ℕ) (hn : 0 (hp i).1) + heq horth hpsum + have hneq : (0:M)≠1 := by + intro h + have hbad := congrArg τ h + rw [map_zero,hone] at hbad + exact zero_ne_one hbad + let : Nontrivial M := ⟨⟨0,1,hneq⟩⟩ + exact ⟨φ,φ.toAlgHom.toRingHom.injective⟩ + +end Kadison.FiniteFactorMatrices + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFactorTrace.lean b/lean/OAI/Analysis/Commutator/FiniteFactorTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..4b910616c327a8a93abda9979ed53e33c3d622c7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFactorTrace.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalGNS +import OAI.Analysis.Commutator.NormalizedTrace +import OAI.Analysis.Commutator.OrbitFixedTrace +import OAI.Analysis.Commutator.ProjectionNormalBridge + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.OrbitStateHull + +open PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfac hd hfin + +lemma hull_projectionContinuousAtOne (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) : + PositiveWOT.ProjectionContinuousAtOne M (positive M x f hf) := by + intro P hP hmono hlim + exact hull_projection_tendsto M hfac hd hfin x hf 1 (IsStarProjection.one _) P hP hmono + (fun n => (hP n).le_one) hlim + +theorem hull_norm_separable (x : H) : + TopologicalSpace.IsSeparable (WeakDual.toStrongDual '' hull M x) := by + apply (NormalPredual.finiteTests_separable M (TopologicalSpace.denseSeq H)).closure.mono + rintro _ ⟨f,hf,rfl⟩ + exact PositiveWOT.mem_predual M (positive M x f hf) + (hull_projectionContinuousAtOne M hfac hd hfin x hf) + +theorem hull_normal (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) : + NormalGNS.BoundedWOTContinuous M (positive M x f hf) := + PositiveWOT.boundedWOTContinuous M (positive M x f hf) + (hull_projectionContinuousAtOne M hfac hd hfin x hf) + +theorem exists_faithful_normal_trace : + ∃ τ : M →ₚ[ℂ] ℂ,(∀ a b : M,τ (a*b)=τ (b*a)) ∧ + NormalGNS.BoundedWOTContinuous M τ ∧ (∀ a : M,τ (star a*a)=0 → a=0) ∧ τ 1=1 := by + obtain ⟨x,hx⟩ := exists_norm_eq H (show (0:ℝ)≤1 from zero_le_one) + obtain ⟨f,hf,htr⟩ := exists_tracial_hull_of_norm_separable M x (hull_norm_separable M hfac hd hfin x) + let τ := positive M x f hf + have ht : ∀ a b : M,τ (a*b)=τ (b*a) := htr + have hone : τ 1=1 := by + change f 1=1 + rw [hull_one M x hf,hx] + norm_num + exact ⟨τ,ht,hull_normal M hfac hd hfin x hf, + TraceDimension.faithful M τ ht hfac hd hfin hone,hone⟩ + +end Kadison.OrbitStateHull + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFactorUnitary.lean b/lean/OAI/Analysis/Commutator/FiniteFactorUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..3cf2fb3a1ed3357448085e0588c5db035a7f783b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFactorUnitary.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFactorMatrices + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f e' f' : H →L[ℂ] H} + +lemma source_cross_zero (v : Link M e f) (w : Link M e' f') + (h : v.initial*w.initial=0) : v.val*star w.val=0 := by + have hw : w.initial*star w.val=star w.val := by + simpa only [star_mul,w.initial_projection.isSelfAdjoint.star_eq] using congrArg star w.mul_initial + calc + _=(v.val*v.initial)*(w.initial*star w.val) := by rw [v.mul_initial,hw] + _=v.val*(v.initial*w.initial)*star w.val := by noncomm_ring + _=0 := by rw [h,mul_zero,zero_mul] + +lemma target_cross_zero (v : Link M e f) (w : Link M e' f') + (h : v.final*w.final=0) : star v.val*w.val=0 := by + have hv : star v.val*v.final=star v.val := by + simpa only [star_mul,v.final_projection.isSelfAdjoint.star_eq] using congrArg star v.final_mul + calc + _=(star v.val*v.final)*(w.final*w.val) := by rw [hv,w.final_mul] + _=star v.val*(v.final*w.final)*w.val := by noncomm_ring + _=0 := by rw [h,mul_zero,zero_mul] + +end Link + +theorem finite_factor_unitary_equivalence (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (e f : M) (he : IsStarProjection e) (hf : IsStarProjection f) + (heq : τ e=τ f) : ∃ u : unitary M, (u:M)*e*star (u:M)=f := by + have hep := he.map M.toStarSubalgebra.subtype + have hfp := hf.map M.toStarSubalgebra.subtype + have heid : (e:H →L[ℂ] H)*(e:H →L[ℂ] H)=(e:H →L[ℂ] H) := hep.isIdempotentElem.eq + have hfid : (f:H →L[ℂ] H)*(f:H →L[ℂ] H)=(f:H →L[ℂ] H) := hfp.isIdempotentElem.eq + obtain ⟨v,hvi,hvf⟩ := finite_factor_equivalence_link M hM τ hτ hfaith + e.property f.property hep hfp heq + have hcomp : τ (1-e)=τ (1-f) := by simp only [map_sub,heq] + obtain ⟨w,hwi,hwf⟩ := finite_factor_equivalence_link M hM τ hτ hfaith + (1-e).property (1-f).property + ((he.one_sub).map M.toStarSubalgebra.subtype) ((hf.one_sub).map M.toStarSubalgebra.subtype) hcomp + have hscross : v.val*star w.val=0 := v.source_cross_zero w (by + rw [hvi,hwi] + change (e:H →L[ℂ] H)*(1-(e:H →L[ℂ] H))=0 + rw [mul_sub,mul_one,heid,sub_self]) + have htcross : star v.val*w.val=0 := v.target_cross_zero w (by + rw [hvf,hwf] + change (f:H →L[ℂ] H)*(1-(f:H →L[ℂ] H))=0 + rw [mul_sub,mul_one,hfid,sub_self]) + have hscross' : w.val*star v.val=0 := by simpa using congrArg star hscross + have htcross' : star w.val*v.val=0 := by simpa using congrArg star htcross + let U : M := ⟨v.val+w.val,M.add_mem v.mem w.mem⟩ + have hU : U∈unitary M := by + constructor + · apply Subtype.ext + change star (v.val+w.val)*(v.val+w.val)=1 + rw [star_add,add_mul,mul_add,mul_add,htcross,htcross',add_zero,zero_add] + change v.initial+w.initial=1 + rw [hvi,hwi] + change (e:H →L[ℂ] H)+(1-(e:H →L[ℂ] H))=1 + abel + · apply Subtype.ext + change (v.val+w.val)*star (v.val+w.val)=1 + rw [star_add,add_mul,mul_add,mul_add,hscross,hscross',add_zero,zero_add] + change v.final+w.final=1 + rw [hvf,hwf] + change (f:H →L[ℂ] H)+(1-(f:H →L[ℂ] H))=1 + abel + refine ⟨⟨U,hU⟩,?_⟩ + apply Subtype.ext + change (v.val+w.val)*(e:H →L[ℂ] H)*star (v.val+w.val)=(f:H →L[ℂ] H) + have hve : v.val*(e:H →L[ℂ] H)=v.val := by simpa only [hvi] using v.mul_initial + have hwe : w.val*(e:H →L[ℂ] H)=0 := by + calc + _=(w.val*w.initial)*(e:H →L[ℂ] H) := by rw [w.mul_initial] + _=w.val*((1-(e:H →L[ℂ] H))*(e:H →L[ℂ] H)) := by rw [hwi,mul_assoc]; rfl + _=0 := by rw [sub_mul,one_mul,heid,sub_self,mul_zero] + rw [add_mul,hve,hwe,add_zero,star_add,mul_add,hscross,add_zero] + exact hvf + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteFullUnitaryTests.lean b/lean/OAI/Analysis/Commutator/FiniteFullUnitaryTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8befdef0400e5240e554d97c3585e4372b8eb2f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteFullUnitaryTests.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteWordMaximalPatching +import OAI.Analysis.Commutator.PartialUnitaryCompletion +import OAI.Analysis.Commutator.FiniteTestCompletion + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching + +open Words + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R ≤ M) + +variable (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +variable {ι : ℕ → Type*} [∀ n,Fintype (ι n)] [∀ n,LinearOrder (ι n)] + [∀ n,Nonempty (ι n)] + +variable (stage : ∀ n,Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range ≤ (stage m).range) + +include hRM hτ hmono in +theorem exists_full_unitary_finite_tests {J K : Type*} [Fintype J] [Fintype K] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (ι n) (ι n) ℂ),stage n a*b=b*stage n a) → + ∃ c : ℂ,b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) + (x : J → M) (k : K → ℤ) (hx : ∀ j,‖x j‖ ≤ 1) + (hcenter : ∀ j,τ (x j)=0) (hk : ∀ i,k i≠0) + (N : ℕ) {α : ℝ} (hα : 0<α) : + ∃ u : unitary M, ((u:M) : H →L[ℂ] H)∈R ∧ + MomentBound τ x k (PartialUnitary.ofUnitary u) N α := by + classical + let m := Finset.univ.sup (fun i => (k i).natAbs) + have hkm (i : K) : (k i).natAbs ≤ m := Finset.le_sup (f := fun i : K => (k i).natAbs) (s:=Finset.univ) (by simp) + let C : ℝ := ((N+1)*(m+2):ℕ) + have hC : 0 (toDual ℂ H).symm (coefficientDual φ b) + map_add' := by + intro b c + apply ext_inner_right ℂ + intro a + simp only [inner_add_left,toDual_symm_apply,coefficientDual_apply, + map_add] + map_smul' := by + intro z b + apply ext_inner_right ℂ + intro a + simp only [inner_smul_left,toDual_symm_apply,coefficientDual_apply, + map_smulₛₗ,RingHom.id_apply,smul_eq_mul] } + ‖φ‖ (by + intro b + change ‖(toDual ℂ H).symm (coefficientDual φ b)‖≤_ + rw [LinearIsometryEquiv.norm_map] + apply opNorm_le_bound _ (mul_nonneg (norm_nonneg _) (norm_nonneg _)) + intro a + change ‖φ (rankOne ℂ a b)‖≤_ + exact (φ.le_opNorm (rankOne ℂ a b)).trans_eq (by simp [mul_comm,mul_left_comm,mul_assoc])) + +@[simp] lemma inner_coefficient (φ : StrongDual ℂ (H →L[ℂ] H)) (a b : H) : + inner ℂ (coefficient φ b) a=φ (rankOne ℂ a b) := by + change inner ℂ ((toDual ℂ H).symm (coefficientDual φ b)) a=_ + rw [toDual_symm_apply,coefficientDual_apply] + +variable {ι : Type*} [Fintype ι] + +lemma eq_sum_coefficients (φ : StrongDual ℂ (H →L[ℂ] H)) + (b : OrthonormalBasis ι ℂ H) (T : H →L[ℂ] H) : + φ T=∑ i, inner ℂ (coefficient φ (b i)) (T (b i)) := by + simp only [inner_coefficient,←map_sum] + congr 1 + ext x + simp only [sum_apply,rankOne_apply] + simpa only [map_sum,map_smul,OrthonormalBasis.repr_apply_apply] using congrArg T (b.sum_repr x).symm + +omit [CompleteSpace H] in +lemma norm_sq_sum_of_orthogonal (v : ι → H) + (hv : Pairwise (fun i j => inner ℂ (v i) (v j)=0)) : + ‖∑ i, v i‖^2=∑ i, ‖v i‖^2 := by + classical + simp only [@norm_sq_eq_re_inner ℂ H, sum_inner,inner_sum,map_sum] + apply Finset.sum_congr rfl + intro i _ + refine Finset.sum_eq_single i ?_ ?_ + · intro j _ hji + simp [hv hji] + · simp + +omit [CompleteSpace H] [Fintype ι] in +lemma inner_normalized_of_ne (v : ι → H) + (hv : Pairwise (fun i j => inner ℂ (v i) (v j)=0)) : + Pairwise (fun i j => inner ℂ ((‖v i‖⁻¹ : ℝ) • v i) + ((‖v j‖⁻¹ : ℝ) • v j)=0) := by + intro i j hij + simp [hv hij] + +omit [CompleteSpace H] in +lemma orthogonalColumn_norm_le (b : OrthonormalBasis ι ℂ H) (u : ι → H) + (hu : Pairwise (fun i j => inner ℂ (u i) (u j)=0)) + (hn : ∀ i, ‖u i‖≤1) : ‖∑ i, rankOne ℂ (u i) (b i)‖≤1 := by + apply opNorm_le_bound _ zero_le_one + intro x + simp only [one_mul,sum_apply,rankOne_apply] + apply (sq_le_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq_sum_of_orthogonal _ (by + intro i j hij + simp [hu hij])] + calc + _ ≤ ∑ i, ‖inner ℂ (b i) x‖^2 := by + apply Finset.sum_le_sum + intro i _ + rw [norm_smul,mul_pow] + exact mul_le_of_le_one_right (sq_nonneg _) (by nlinarith [norm_nonneg (u i),hn i]) + _ ≤ ‖x‖^2 := b.orthonormal.sum_inner_products_le x + +omit [CompleteSpace H] in +lemma orthogonalColumn_apply_basis (b : OrthonormalBasis ι ℂ H) (u : ι → H) (j : ι) : + (∑ i, rankOne ℂ (u i) (b i)) (b j)=u j := by + classical + simp [sum_apply,rankOne_apply,b.inner_eq_ite] + +variable [FiniteDimensional ℂ H] + +def singularBasis (R : H →L[ℂ] H) : + OrthonormalBasis (Fin (Module.finrank ℂ H)) ℂ H := + (R.toLinearMap.isSymmetric_adjoint_comp_self).eigenvectorBasis rfl + +lemma singularBasis_orthogonal (R : H →L[ℂ] H) : + Pairwise (fun i j => inner ℂ (R (singularBasis R i)) (R (singularBasis R j))=0) := by + intro i j hij + rw [←ContinuousLinearMap.adjoint_inner_left] + change inner ℂ ((R.toLinearMap.adjoint ∘ₗ R.toLinearMap) (singularBasis R i)) + (singularBasis R j)=0 + have he : (R.toLinearMap.adjoint ∘ₗ R.toLinearMap) (singularBasis R i)= + (R.toLinearMap.isSymmetric_adjoint_comp_self.eigenvalues rfl i : ℂ) • singularBasis R i := + R.toLinearMap.isSymmetric_adjoint_comp_self.apply_eigenvectorBasis rfl i + rw [he] + simp [(singularBasis R).inner_eq_zero hij] + +omit [CompleteSpace H] [FiniteDimensional ℂ H] in +lemma norm_inv_smul_norm_le_one (v : H) : ‖(‖v‖⁻¹ : ℝ) • v‖≤1 := by + by_cases hv : v=0 + · simp [hv] + · have hn : ‖v‖≠0 := norm_ne_zero_iff.mpr hv + simp [norm_smul,hn] + +omit [CompleteSpace H] [FiniteDimensional ℂ H] in +lemma inner_norm_inv_smul (v : H) : + inner ℂ v ((‖v‖⁻¹ : ℝ) • v)=(‖v‖ : ℂ) := by + by_cases hv : v=0 + · simp [hv] + · have hn : ‖v‖≠0 := norm_ne_zero_iff.mpr hv + rw [inner_smul_right_eq_smul,inner_self_eq_norm_sq_to_K,Complex.real_smul] + push_cast + field_simp [Complex.ofReal_ne_zero.mpr hn] + rfl + +lemma sum_singular_coefficients_le (φ : StrongDual ℂ (H →L[ℂ] H)) : + ∑ i, ‖coefficient φ (singularBasis (coefficient φ) i)‖≤‖φ‖ := by + let b := singularBasis (coefficient φ) + let v := fun i => coefficient φ (b i) + let u := fun i => (‖v i‖⁻¹ : ℝ) • v i + let P := ∑ i, rankOne ℂ (u i) (b i) + have hP : ‖P‖≤1 := orthogonalColumn_norm_le b u + (inner_normalized_of_ne v (singularBasis_orthogonal (coefficient φ))) + (fun i => norm_inv_smul_norm_le_one (v i)) + have hφP : φ P=(∑ i, ‖v i‖ : ℝ) := by + rw [eq_sum_coefficients φ b P,Complex.ofReal_sum] + apply Finset.sum_congr rfl + intro i _ + change inner ℂ (v i) (P (b i))=_ + change inner ℂ (v i) ((∑ j, rankOne ℂ (u j) (b j)) (b i))=_ + rw [orthogonalColumn_apply_basis] + exact inner_norm_inv_smul (v i) + have hh := (φ.le_opNorm P).trans (mul_le_of_le_one_right (norm_nonneg φ) hP) + rw [hφP,Complex.norm_real,Real.norm_eq_abs,abs_of_nonneg (Finset.sum_nonneg (fun _ _ => norm_nonneg _))] at hh + exact hh + +omit [CompleteSpace H] [FiniteDimensional ℂ H] in +lemma balanced_inner (v b : H) (T : H →L[ℂ] H) : + inner ℂ ((Real.sqrt ‖v‖)⁻¹ • v) (T (Real.sqrt ‖v‖ • b))=inner ℂ v (T b) := by + by_cases hv : v=0 + · simp [hv] + have hs : Real.sqrt ‖v‖≠0 := Real.sqrt_ne_zero'.mpr (norm_pos_iff.mpr hv) + rw [map_smul_of_tower,inner_smul_left_eq_smul,inner_smul_right_eq_smul, + smul_smul,inv_mul_cancel₀ hs,one_smul] + +omit [CompleteSpace H] [FiniteDimensional ℂ H] in +lemma balanced_right_norm_sq (v : H) : ‖(Real.sqrt ‖v‖)⁻¹ • v‖^2=‖v‖ := by + by_cases hv : v=0 + · simp [hv] + have hs : Real.sqrt ‖v‖≠0 := Real.sqrt_ne_zero'.mpr (norm_pos_iff.mpr hv) + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg (inv_nonneg.mpr (Real.sqrt_nonneg _)),mul_pow,inv_pow] + rw [Real.sq_sqrt (norm_nonneg v)] + field_simp [norm_ne_zero_iff.mpr hv] + +omit [CompleteSpace H] [FiniteDimensional ℂ H] in +lemma balanced_left_norm_sq (v b : H) (hb : ‖b‖=1) : + ‖Real.sqrt ‖v‖ • b‖^2=‖v‖ := by + simp [norm_smul,hb,Real.sq_sqrt (norm_nonneg v)] + +theorem exists_finite_factorization (φ : StrongDual ℂ (H →L[ℂ] H)) : + ∃ x y : PiLp 2 (fun _ : Fin (Module.finrank ℂ H) => H), + (∀ T : H →L[ℂ] H, φ T=∑ i, inner ℂ (y i) (T (x i))) ∧ ‖x‖*‖y‖≤‖φ‖ := by + let b := singularBasis (coefficient φ) + let v := fun i => coefficient φ (b i) + let x : PiLp 2 (fun _ : Fin (Module.finrank ℂ H) => H) := + WithLp.toLp 2 (fun i => Real.sqrt ‖v i‖ • b i) + let y : PiLp 2 (fun _ : Fin (Module.finrank ℂ H) => H) := + WithLp.toLp 2 (fun i => (Real.sqrt ‖v i‖)⁻¹ • v i) + refine ⟨x,y,?_,?_⟩ + · intro T + rw [eq_sum_coefficients φ b T] + apply Finset.sum_congr rfl + intro i _ + exact (balanced_inner (v i) (b i) T).symm + · have hx : ‖x‖^2=∑ i, ‖v i‖ := by + rw [PiLp.norm_sq_eq_of_L2] + apply Finset.sum_congr rfl + intro i _ + exact balanced_left_norm_sq (v i) (b i) (b.orthonormal.1 i) + have hy : ‖y‖^2=∑ i, ‖v i‖ := by + rw [PiLp.norm_sq_eq_of_L2] + apply Finset.sum_congr rfl + intro i _ + exact balanced_right_norm_sq (v i) + have hxy : ‖x‖=‖y‖ := (sq_eq_sq₀ (norm_nonneg x) (norm_nonneg y)).mp (hx.trans hy.symm) + rw [←hxy,←pow_two,hx] + exact sum_singular_coefficients_le φ + +end Kadison.OperatorFunctionals + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteHankel.lean b/lean/OAI/Analysis/Commutator/FiniteHankel.lean new file mode 100644 index 0000000000000000000000000000000000000000..4830d0e2284bd5f4ffb2a86351adcf26d3579059 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteHankel.lean @@ -0,0 +1,329 @@ +import Mathlib +import OAI.Analysis.Commutator.FejerTest + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.FreeCorner + +variable {H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def compress (V : K →ₗᵢ[ℂ] H) (T : H →L[ℂ] H) : K →L[ℂ] K := + (V.toContinuousLinearMap.adjoint.comp T).comp V.toContinuousLinearMap + +lemma norm_compress_le (V : K →ₗᵢ[ℂ] H) (T : H →L[ℂ] H) : + ‖compress V T‖ ≤ ‖T‖ := by + have hv : ‖V.toContinuousLinearMap‖ ≤ 1 := V.norm_toContinuousLinearMap_le + have hv' : ‖V.toContinuousLinearMap.adjoint‖ ≤ 1 := by rw [adjoint.norm_map]; exact hv + calc + ‖compress V T‖ ≤ ‖V.toContinuousLinearMap.adjoint‖ * ‖T‖ * + ‖V.toContinuousLinearMap‖ := (opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_right (opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ 1 * ‖T‖ * 1 := mul_le_mul + (mul_le_mul_of_nonneg_right hv' (norm_nonneg _)) hv (norm_nonneg _) + (by positivity) + _ = ‖T‖ := by ring + +lemma compression_commutator_identity (V : K →ₗᵢ[ℂ] H) + (G L : H →L[ℂ] H) (J : K →L[ℂ] K) : + compress V (G * L - L * G) = + J * compress V L - compress V L * J + + (G.adjoint.comp V.toContinuousLinearMap - + V.toContinuousLinearMap.comp J.adjoint).adjoint.comp + (L.comp V.toContinuousLinearMap) - + V.toContinuousLinearMap.adjoint.comp + (L.comp (G.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp J)) := by + simp only [compress, mul_def, comp_sub, sub_comp, map_sub, + adjoint_comp, adjoint_adjoint, comp_assoc] + abel + +lemma norm_compression_commutator_le (V : K →ₗᵢ[ℂ] H) + (G L : H →L[ℂ] H) (J : K →L[ℂ] K) {d d' : ℝ} + (hd : ‖G.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp J‖ ≤ d) + (hd' : ‖G.adjoint.comp V.toContinuousLinearMap - + V.toContinuousLinearMap.comp J.adjoint‖ ≤ d') : + ‖J * compress V L - compress V L * J‖ ≤ + ‖G * L - L * G‖ + (d + d') * ‖L‖ := by + have hd0 : 0 ≤ d := (norm_nonneg _).trans hd + have hd0' : 0 ≤ d' := (norm_nonneg _).trans hd' + let R := G.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp J + let R' := G.adjoint.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp J.adjoint + have hv : ‖V.toContinuousLinearMap‖ ≤ 1 := V.norm_toContinuousLinearMap_le + have hv' : ‖V.toContinuousLinearMap.adjoint‖ ≤ 1 := by rw [adjoint.norm_map]; exact hv + have h1 : ‖R'.adjoint.comp (L.comp V.toContinuousLinearMap)‖ ≤ d' * ‖L‖ := by + calc + _ ≤ ‖R'.adjoint‖ * (‖L‖ * ‖V.toContinuousLinearMap‖) := + (opNorm_comp_le _ _).trans (mul_le_mul_of_nonneg_left (opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ d' * (‖L‖ * 1) := mul_le_mul + (by simpa only [adjoint.norm_map, R'] using hd') + (mul_le_mul_of_nonneg_left hv (norm_nonneg _)) (by positivity) hd0' + _ = d' * ‖L‖ := by ring + have h2 : ‖V.toContinuousLinearMap.adjoint.comp (L.comp R)‖ ≤ d * ‖L‖ := by + calc + _ ≤ ‖V.toContinuousLinearMap.adjoint‖ * (‖L‖ * ‖R‖) := + (opNorm_comp_le _ _).trans (mul_le_mul_of_nonneg_left (opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ 1 * (‖L‖ * d) := mul_le_mul hv' + (mul_le_mul_of_nonneg_left hd (norm_nonneg _)) (by positivity) (by positivity) + _ = d * ‖L‖ := by ring + have heq : J * compress V L - compress V L * J = + compress V (G * L - L * G) - R'.adjoint.comp (L.comp V.toContinuousLinearMap) + + V.toContinuousLinearMap.adjoint.comp (L.comp R) := by + rw [compression_commutator_identity] + dsimp [R, R'] + abel + rw [heq] + calc + _ ≤ ‖compress V (G * L - L * G)‖ + + ‖R'.adjoint.comp (L.comp V.toContinuousLinearMap)‖ + + ‖V.toContinuousLinearMap.adjoint.comp (L.comp R)‖ := (norm_add_le _ _).trans + (add_le_add (norm_sub_le _ _) le_rfl) + _ ≤ ‖G * L - L * G‖ + d' * ‖L‖ + d * ‖L‖ := + add_le_add (add_le_add (norm_compress_le V _) h1) h2 + _ = _ := by ring + +lemma compressed_commutator_bound (V : K →ₗᵢ[ℂ] H) + (G L : H →L[ℂ] H) (J : K →L[ℂ] K) {c ε : ℝ} + (hG : ‖G * L - L * G‖ ≤ ε * ‖L‖) + (hR : ‖G.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp J‖ ≤ 2*c*ε) + (hR' : ‖G.adjoint.comp V.toContinuousLinearMap - + V.toContinuousLinearMap.comp J.adjoint‖ ≤ 2*c*ε) : + ‖J * compress V L - compress V L * J‖ ≤ (1+4*c)*ε*‖L‖ := by + calc + _ ≤ ‖G * L - L * G‖ + (2*c*ε + 2*c*ε)*‖L‖ := + norm_compression_commutator_le V G L J hR hR' + _ ≤ ε*‖L‖ + (2*c*ε + 2*c*ε)*‖L‖ := add_le_add hG le_rfl + _ = _ := by ring + +end Kadison.FreeCorner + +namespace Kadison.FiniteCompression + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +variable {H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable {I : Type*} [Fintype I] [DecidableEq I] + +omit [CompleteSpace H] [DecidableEq I] in +lemma inner_sum_diagonal (x y : I → H) + (h : ∀ i j, i ≠ j → inner ℂ (x i) (y j) = 0) : + inner ℂ (∑ i, x i) (∑ i, y i) = ∑ i, inner ℂ (x i) (y i) := by + simp only [sum_inner, inner_sum] + apply Finset.sum_congr rfl + intro i _ + exact Finset.sum_eq_single i (fun j _ hji => h j i hji) (by simp) + +omit [CompleteSpace H] [DecidableEq I] in +lemma norm_sum_sq (x : I → H) (h : ∀ i j, i ≠ j → inner ℂ (x i) (x j) = 0) : + ‖∑ i, x i‖^2 = ∑ i, ‖x i‖^2 := by + rw [norm_sq_eq_re_inner (𝕜 := ℂ), inner_sum_diagonal x x h, map_sum] + exact Finset.sum_congr rfl (fun i _ => (norm_sq_eq_re_inner (𝕜 := ℂ) (x i)).symm) + +def average (c : ℝ) (U : I → K →L[ℂ] H) : K →L[ℂ] H := + (c : ℂ) • ∑ i, U i + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +@[simp] lemma average_apply (c : ℝ) (U : I → K →L[ℂ] H) (x : K) : + average c U x = (c : ℂ) • ∑ i, U i x := by simp [average] + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +lemma average_inner (c : ℝ) (U : I → K →ₗᵢ[ℂ] H) + (horth : ∀ i j, i ≠ j → ∀ x y : K, inner ℂ (U i x) (U j y) = 0) + (hscale : c^2 * Fintype.card I = 1) (x y : K) : + inner ℂ (average c (fun i => (U i).toContinuousLinearMap) x) + (average c (fun i => (U i).toContinuousLinearMap) y) = inner ℂ x y := by + simp only [average_apply, inner_smul_left, inner_smul_right, + Complex.conj_ofReal, LinearIsometry.coe_toContinuousLinearMap] + rw [inner_sum_diagonal (fun i => U i x) (fun i => U i y) + (fun i j hij => horth i j hij x y)] + simp only [LinearIsometry.inner_map_map, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] + have hs : (c : ℂ)^2 * (Fintype.card I : ℂ) = 1 := by exact_mod_cast hscale + calc + _ = ((c : ℂ)^2 * (Fintype.card I : ℂ)) * inner ℂ x y := by ring + _ = _ := by rw [hs, one_mul] + +def averageIsometry (c : ℝ) (U : I → K →ₗᵢ[ℂ] H) + (horth : ∀ i j, i ≠ j → ∀ x y : K, inner ℂ (U i x) (U j y) = 0) + (hscale : c^2 * Fintype.card I = 1) : K →ₗᵢ[ℂ] H where + toLinearMap := (average c (fun i => (U i).toContinuousLinearMap)).toLinearMap + norm_map' x := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq_eq_re_inner (𝕜 := ℂ), norm_sq_eq_re_inner (𝕜 := ℂ)] + exact congrArg Complex.re (average_inner c U horth hscale x x) + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +@[simp] lemma averageIsometry_toCLM (c : ℝ) (U : I → K →ₗᵢ[ℂ] H) horth hscale : + (averageIsometry c U horth hscale).toContinuousLinearMap = + average c (fun i => (U i).toContinuousLinearMap) := rfl + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +lemma norm_average_le (c : ℝ) (U : I → K →L[ℂ] H) + (horth : ∀ i j, i ≠ j → ∀ x : K, inner ℂ (U i x) (U j x) = 0) + (hscale : c^2 * Fintype.card I = 1) {d : ℝ} (hd : 0 ≤ d) + (hU : ∀ i, ‖U i‖ ≤ d) : ‖average c U‖ ≤ d := by + apply (average c U).opNorm_le_bound hd + intro x + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hd (norm_nonneg x))).mp + rw [average_apply, norm_smul, mul_pow, Complex.norm_real, + Real.norm_eq_abs, sq_abs, norm_sum_sq _ (fun i j hij => horth i j hij x)] + calc + c^2 * ∑ i, ‖U i x‖^2 ≤ c^2 * ∑ _i : I, (d*‖x‖)^2 := by + apply mul_le_mul_of_nonneg_left _ (sq_nonneg c) + apply Finset.sum_le_sum + intro i _ + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hd (norm_nonneg x))).mpr + exact ((U i).le_opNorm x).trans (mul_le_mul_of_nonneg_right (hU i) (norm_nonneg x)) + _ = (d*‖x‖)^2 := by + simp only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] + rw [← mul_assoc, hscale, one_mul] + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +lemma comp_sum' (U : I → K →L[ℂ] H) (G : H →L[ℂ] H) : + G.comp (∑ i, U i) = ∑ i, G.comp (U i) := by + ext x + simp + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +lemma sum_comp' (U : I → K →L[ℂ] H) (B : K →L[ℂ] K) : + (∑ i, U i).comp B = ∑ i, (U i).comp B := by + ext x + simp + +omit [CompleteSpace H] [CompleteSpace K] [DecidableEq I] in +lemma average_error (c : ℝ) (U : I → K →L[ℂ] H) (G : H →L[ℂ] H) (B : K →L[ℂ] K) : + G.comp (average c U) - (average c U).comp B = + average c (fun i => G.comp (U i) - (U i).comp B) := by + simp only [average, comp_smul, smul_comp, comp_sum', sum_comp', + Finset.sum_sub_distrib, smul_sub] + +omit [DecidableEq I] in +lemma average_compression (c : ℝ) (U : I → K →L[ℂ] H) (T : H →L[ℂ] H) : + ((average c U).adjoint.comp T).comp (average c U) = + ((c : ℂ)^2) • ∑ i, ∑ j, ((U i).adjoint.comp T).comp (U j) := by + unfold average + rw [map_smulₛₗ, map_sum] + have hc : starRingEnd ℂ (c : ℂ) = (c : ℂ) := Complex.conj_ofReal c + rw [hc] + ext x + simp only [ContinuousLinearMap.comp_apply, smul_apply, + sum_apply, map_smul, map_sum] + simp only [Finset.smul_sum, smul_smul, pow_two] + rw [Finset.sum_comm] + +omit [DecidableEq I] in +lemma average_compression_entries (c : ℝ) (U : I → K →ₗᵢ[ℂ] H) + (horth : ∀ i j, i ≠ j → ∀ x y : K, inner ℂ (U i x) (U j y) = 0) + (hscale : c^2 * Fintype.card I = 1) + (T : H →L[ℂ] H) (S : K →L[ℂ] K) (u : ℂ) (a b : I → I → ℂ) + (hentry : ∀ i j, ((U i).toContinuousLinearMap.adjoint.comp T).comp + (U j).toContinuousLinearMap = u • (a i j • 1 + b i j • S)) : + FreeCorner.compress (averageIsometry c U horth hscale) T = + u • (((c : ℂ)^2 * ∑ i, ∑ j, a i j) • 1 + + ((c : ℂ)^2 * ∑ i, ∑ j, b i j) • S) := by + rw [FreeCorner.compress, averageIsometry_toCLM, average_compression] + simp only [hentry, smul_add, smul_smul, Finset.sum_add_distrib, + ← Finset.sum_smul, ← Finset.mul_sum] + module + +end Kadison.FiniteCompression + +namespace Kadison.FiniteHankel + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap FiniteCompression + +variable {H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem norm_commutator_le_of_finite_entries + (N : ℕ) (hN : 0 < N) (U : Fin N → K →ₗᵢ[ℂ] H) + (horth : ∀ i j, i ≠ j → ∀ x y : K, inner ℂ (U i x) (U j y) = 0) + (G L : H →L[ℂ] H) (B S : K →L[ℂ] K) (u c ε : ℝ) + (hu : 0 < u) (hc : 0 ≤ c) (hε : 0 ≤ ε) + (hL : ‖L‖ ≤ 4*u) + (hG : ‖G*L-L*G‖ ≤ ε*‖L‖) + (hR : ∀ i, ‖G.comp (U i).toContinuousLinearMap - + (U i).toContinuousLinearMap.comp B‖ ≤ 2*c*ε) + (hR' : ∀ i, ‖G.adjoint.comp (U i).toContinuousLinearMap - + (U i).toContinuousLinearMap.comp B.adjoint‖ ≤ 2*c*ε) + (hRorth : ∀ i j, i ≠ j → ∀ x : K, + inner ℂ (G (U i x) - U i (B x)) (G (U j x) - U j (B x)) = 0) + (hRorth' : ∀ i j, i ≠ j → ∀ x : K, + inner ℂ (G.adjoint (U i x) - U i (B.adjoint x)) + (G.adjoint (U j x) - U j (B.adjoint x)) = 0) + (a : Fin N → Fin N → ℂ) + (hentry : ∀ i j, ((U i).toContinuousLinearMap.adjoint.comp L).comp + (U j).toContinuousLinearMap = (u : ℂ) • (a i j • 1 + + (Complex.ofReal (((2*N : ℝ) - i.val - j.val - 1)/(2*N : ℝ)^2)) • S)) : + ‖B*S-S*B‖ ≤ 16*(1+4*c)*ε := by + let v : ℝ := (Real.sqrt (N : ℝ))⁻¹ + have hn : (N : ℝ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hN) + have hv2 : v^2 = (N : ℝ)⁻¹ := by + dsimp [v] + rw [inv_pow, Real.sq_sqrt (Nat.cast_nonneg N)] + have hscale : v^2 * Fintype.card (Fin N) = 1 := by + rw [hv2, Fintype.card_fin, inv_mul_cancel₀ hn] + let V := averageIsometry v U horth hscale + have hRV : ‖G.comp V.toContinuousLinearMap - V.toContinuousLinearMap.comp B‖ ≤ 2*c*ε := by + rw [averageIsometry_toCLM, average_error] + exact norm_average_le v _ (fun i j hij x => hRorth i j hij x) hscale (by positivity) hR + have hRV' : ‖G.adjoint.comp V.toContinuousLinearMap - + V.toContinuousLinearMap.comp B.adjoint‖ ≤ 2*c*ε := by + rw [averageIsometry_toCLM, average_error] + exact norm_average_le v _ (fun i j hij x => hRorth' i j hij x) hscale (by positivity) hR' + have hb : (v : ℂ)^2 * ∑ i : Fin N, ∑ j : Fin N, + (Complex.ofReal (((2*N : ℝ) - i.val - j.val - 1)/(2*N : ℝ)^2)) = 1/4 := by + have h : v^2 * ∑ i : Fin N, ∑ j : Fin N, + (((2*N : ℝ) - i.val - j.val - 1)/(2*N : ℝ)^2) = 1/4 := by + rw [hv2] + exact FejerTest.hankel_average N hN + simpa only [Complex.ofReal_mul, Complex.ofReal_pow, Complex.ofReal_sum, + Complex.ofReal_div, Complex.ofReal_one, Complex.ofReal_ofNat] using + congrArg Complex.ofReal h + have hcomp : FreeCorner.compress V L = (u : ℂ) • + (((v : ℂ)^2 * ∑ i, ∑ j, a i j) • 1 + (1/4 : ℂ) • S) := by + have h := average_compression_entries v U horth hscale L S (u : ℂ) a + (fun i j => (Complex.ofReal (((2*N : ℝ) - i.val - j.val - 1)/(2*N : ℝ)^2))) hentry + rw [hb] at h + exact h + have heq : B * FreeCorner.compress V L - FreeCorner.compress V L * B = + ((u/4 : ℝ) : ℂ) • (B*S-S*B) := by + rw [hcomp] + simp only [smul_add, mul_add, add_mul, mul_smul_comm, smul_mul_assoc, mul_one, + one_mul, smul_sub, smul_smul, Complex.ofReal_div, Complex.ofReal_ofNat] + module + have hbound := FreeCorner.compressed_commutator_bound V G L B hG hRV hRV' + rw [heq, norm_smul, Complex.norm_real, Real.norm_eq_abs, + abs_of_pos (div_pos hu (by norm_num))] at hbound + have hbound' : (u/4)*‖B*S-S*B‖ ≤ (1+4*c)*ε*(4*u) := + hbound.trans (mul_le_mul_of_nonneg_left hL (by positivity)) + apply (mul_le_mul_iff_right₀ (div_pos hu (by norm_num : (0 : ℝ) < 4))).mp + calc + _ ≤ (1+4*c)*ε*(4*u) := hbound' + _ = (u/4)*(16*(1+4*c)*ε) := by ring + +end Kadison.FiniteHankel + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteMatrixSmallCorner.lean b/lean/OAI/Analysis/Commutator/FiniteMatrixSmallCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..305920f02f26cefdb960444df69f7d8f641edb5f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteMatrixSmallCorner.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteSmallCorner +import OAI.Analysis.Commutator.MatrixCommute +import OAI.Analysis.Commutator.MatrixCornerInclusion + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.OperatorAmplification + +variable {H K : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (ι : Type) [Fintype ι] (i₀ : ι) (M Q : VonNeumannAlgebra H) (hQM : Q≤M) + +local instance : DecidableEq ι := Classical.decEq ι + +lemma matrixInclusion_commutes (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (T : K →L[ℂ] K) + (hT : ∀ q : Q,T*ρ (NormalSubalgebra.inclusion M Q hQM q)= + ρ (NormalSubalgebra.inclusion M Q hQM q)*T) + (X : matrixVonNeumann ι i₀ Q) : + diagonal (H:=K) ι T*CyclicColumns.matrixRepresentation ρ (matrixInclusion ι i₀ M Q hQM X)= + CyclicColumns.matrixRepresentation ρ (matrixInclusion ι i₀ M Q hQM X)*diagonal (H:=K) ι T := by + apply CyclicColumns.diagonal_commutes_matrixRepresentation + intro i j + let q : Q := ⟨entry ι (X:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i j, + (mem_matrixVonNeumann ι i₀ Q X).mp X.property i j⟩ + have he : matrixInclusion ι i₀ M Q hQM X i j=NormalSubalgebra.inclusion M Q hQM q := by + apply Subtype.ext + exact matrixInclusion_entry ι i₀ M Q hQM X i j + rw [he] + exact hT q + +theorem matrix_small_corner_bound (hQ : FactorCorner.IsFactor Q) + (σ : Q →ₚ[ℂ] ℂ) (hσ : ∀ a b : Q,σ (a*b)=σ (b*a)) + (hfaith : ∀ a : Q,σ (star a*a)=0 → a=0) (h1 : σ 1=1) + (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (T : K →L[ℂ] K) + (hT : ∀ q : Q,T*ρ (NormalSubalgebra.inclusion M Q hQM q)= + ρ (NormalSubalgebra.inclusion M Q hQM q)*T) + {c : ℝ} (hc : 0≤c) (hbound : ∀ a : M,‖T*ρ a-ρ a*T‖≤c*‖a‖) + (f : matrixVonNeumann ι i₀ Q) (hf : IsStarProjection f) + (htrace : matrixTrace ι i₀ Q σ f≤(Fintype.card ι : ℂ)⁻¹) + (X : CStarMatrix ι ι M) + (hX : matrixInclusion ι i₀ M Q hQM f*X*matrixInclusion ι i₀ M Q hQM f=X) : + ‖diagonal (H:=K) ι T*CyclicColumns.matrixRepresentation ρ X- + CyclicColumns.matrixRepresentation ρ X*diagonal (H:=K) ι T‖≤c*‖X‖ := by + let e : matrixVonNeumann ι i₀ Q := matrixEquiv ι i₀ Q (MatrixGNS.rowMatrix i₀ (1:Q)) + have he : IsStarProjection e := + (MatrixGNS.rowMatrix_projection (A:=Q) i₀).map (matrixEquiv ι i₀ Q).toStarAlgHom + have hje : matrixInclusion ι i₀ M Q hQM e=MatrixGNS.rowMatrix i₀ (1:M) := + matrixInclusion_row ι i₀ M Q hQM i₀ + have hte : matrixTrace ι i₀ Q σ e=(Fintype.card ι : ℂ)⁻¹ := by + change matrixTrace ι i₀ Q σ (matrixEquiv ι i₀ Q (MatrixGNS.rowMatrix i₀ (1:Q)))=_ + rw [matrixTrace_equiv,MatrixGNS.rowMatrix_trace σ h1] + refine CornerTransport.finite_small_corner_bound (matrixVonNeumann ι i₀ Q) + (factor_matrixVonNeumann ι i₀ Q hQ) (matrixTrace ι i₀ Q σ) + (matrixTrace_tracial ι i₀ Q σ hσ) (matrixTrace_faithful ι i₀ Q σ hfaith) + (matrixInclusion ι i₀ M Q hQM) (CyclicColumns.matrixRepresentation ρ) + (diagonal (H:=K) ι T) (matrixInclusion_commutes ι i₀ M Q hQM ρ T hT) + e he ?_ f hf (by rw [hte]; exact htrace) X hX + intro Z hZ + rw [hje] at hZ + exact MatrixGNS.row_corner_commutator_bound ρ T hc hbound i₀ Z hZ + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteNoReplicas.lean b/lean/OAI/Analysis/Commutator/FiniteNoReplicas.lean new file mode 100644 index 0000000000000000000000000000000000000000..2dd8136d8d12f566e2a16641db75ac4267af52a6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteNoReplicas.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialDecomposition +import OAI.Analysis.Commutator.PartialDecompositionCountable +import OAI.Analysis.Commutator.ProperIsometryReplicas +import OAI.Analysis.Commutator.ReplicaPacking + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +theorem finite_no_replicas (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {r : H →L[ℂ] H} (hrM : r∈M) (hr : IsStarProjection r) (hrn : r≠0) + (R : Replicas M r) : False := by + classical + obtain ⟨D⟩ := exists_partialDecomposition M hfac hrM hr hrn + have := D.countable + obtain ⟨e,he⟩ := Countable.exists_injective_nat (D.I × Bool) + let f : D.I → ℕ := fun i => e (i,false) + let g : D.I → ℕ := fun i => e (i,true) + have hf : Function.Injective f := fun i j h => (Prod.mk.inj (he h)).1 + have hg : Function.Injective g := fun i j h => (Prod.mk.inj (he h)).1 + have hfg : ∀ i j,f i≠g j := by + intro i j hij + have := (Prod.mk.inj (he hij)).2 + contradiction + obtain ⟨s,hs,hsv⟩ := D.exists_packing R hr f hf + obtain ⟨t,ht,htv⟩ := D.exists_packing R hr g hg + have hsi : star s*s=1 := D.packing_isometry R hr f hf hsv + have hti : star t*t=1 := D.packing_isometry R hr g hg htv + have hst : star s*t=0 := D.packings_orthogonal R f g hfg hsv htv + have hsf : s*star s=1 := hfin s hs hsi + have htz : t=0 := by + calc + t=(s*star s)*t := by rw [hsf,one_mul] + _=0 := by rw [mul_assoc,hst,mul_zero] + have hone : (1 : H →L[ℂ] H)=0 := by simpa only [htz,mul_zero] using hti.symm + exact hrn (by simpa only [mul_one,mul_zero] using congrArg (fun z : H →L[ℂ] H => r*z) hone) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FinitePairings.lean b/lean/OAI/Analysis/Commutator/FinitePairings.lean new file mode 100644 index 0000000000000000000000000000000000000000..30087d994467d7fa4162acfd68d2222161f37ab3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FinitePairings.lean @@ -0,0 +1,32 @@ +import Mathlib +import OAI.Analysis.Commutator.CoefficientForm + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.PreHilbert + +lemma word_orthonormal (E F : PreHilbert) (Ω : E) (hΩ : ‖Ω‖ = 1) + {ι : Type*} (v : ι → F) (hv : Orthonormal ℂ v) (n : ℕ) : + Orthonormal ℂ (fun b : Fin n → ι => word E F n Ω (fun i => v (b i))) := by + classical + apply orthonormal_iff_ite.mpr + intro b c + rw [inner_word, inner_self_eq_norm_sq_to_K, hΩ] + have hh := orthonormal_iff_ite.mp (pure_orthonormal F v hv n) b c + simpa [inner_pure] using hh + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FinitePairings2.lean b/lean/OAI/Analysis/Commutator/FinitePairings2.lean new file mode 100644 index 0000000000000000000000000000000000000000..070447204b3a7a58e34a525a8634207836199924 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FinitePairings2.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Commutator.Pairings + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.Pairing + +variable {J : Type*} [LinearOrder J] + +def finiteLabels (σ : Pairing J) (p : J) {N : ℕ} (n : Fin (N+1)) (j : J) : + J × Fin (N+1) := + (repr σ j, if repr σ j = repr σ p then n else 0) + +@[simp] lemma finiteLabels_eq_iff (σ : Pairing J) (p : J) {N : ℕ} + (n : Fin (N+1)) (i j : J) : + finiteLabels σ p n i = finiteLabels σ p n j ↔ j = i ∨ j = σ i := by + constructor + · intro h + exact (repr_eq_iff σ i j).mp (congrArg Prod.fst h) + · intro h + have hh := (repr_eq_iff σ i j).mpr h + simp only [finiteLabels, hh] + +variable [Fintype J] + +lemma finite_contraction_isolation {E : Type*} (τ σ : Pairing J) (p : J) {N : ℕ} + (n : Fin (N+1)) (v : J × Fin (N+1) → E) (B : E → E → ℂ) + (hv : ∀ a b, B (v a) (v b) = if a = b then 1 else 0) : + contraction σ B (fun j => v (finiteLabels τ p n j)) = if σ = τ then 1 else 0 := by + classical + unfold contraction + simp_rw [hv] + rw [Finset.prod_ite_zero] + simp only [Finset.mem_filter, Finset.mem_univ, true_and, Finset.prod_const_one] + have he : (∀ j, j < σ j → finiteLabels τ p n j = finiteLabels τ p n (σ j)) ↔ σ = τ := by + rw [pair_tests_iff] + constructor + · intro h + apply ext + intro j + rcases (finiteLabels_eq_iff τ p n j (σ j)).mp (h j) with hh | hh + · exact (σ.apply_ne j hh).elim + · exact hh + · rintro rfl j + exact (finiteLabels_eq_iff σ p n j (σ j)).mpr (Or.inr rfl) + simp only [he] + +end Kadison.Pairing +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FinitePairings3.lean b/lean/OAI/Analysis/Commutator/FinitePairings3.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce4288b5d14603bcf4a5f5f3b3d6d79526716d76 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FinitePairings3.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Commutator.FinitePairings +import OAI.Analysis.Commutator.FinitePairings2 +import OAI.Analysis.Commutator.HilbertTensors + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +open PreHilbert + +abbrev TailSlots (k l : ℕ) := Fin k ⊕ₗ Fin l + +lemma finite_constant_coefficient_bound {E F : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + {N : ℕ} (T : E →L[ℂ] F) (v : Fin (N+1) → E) (hv : Orthonormal ℂ v) + (w : F) (hw : ‖w‖ = 1) (c : ℂ) (hc : ∀ n, inner ℂ w (T (v n)) = c) : + (N+1 : ℝ) * ‖c‖ ^ 2 ≤ ‖T‖ ^ 2 := by + have hh := hv.sum_inner_products_le (T.adjoint w) (s := Finset.univ) + have hc' (n) : ‖inner ℂ (v n) (T.adjoint w)‖ = ‖c‖ := by + rw [← norm_inner_symm, ContinuousLinearMap.adjoint_inner_left, hc] + simp only [hc', Finset.sum_const, Finset.card_univ, Fintype.card_fin, nsmul_eq_mul, + Nat.cast_add, Nat.cast_one] at hh + have hn := T.adjoint.le_opNorm w + rw [ContinuousLinearMap.adjoint.norm_map, hw, mul_one] at hn + exact hh.trans (pow_le_pow_left₀ (norm_nonneg _) hn 2) + +lemma finite_pairing_source_bound (E F : PreHilbert) (k l N : ℕ) + (Ω : E) (hΩ : ‖Ω‖ = 1) (T : wordSpace E F k →L[ℂ] wordSpace E F l) + (c : Pairing (TailSlots k l) → ℂ) (h : TailSlots k l × Fin (N+1) → F) + (horth : Orthonormal ℂ h) + (hexp : ∀ v : TailSlots k l → TailSlots k l × Fin (N+1), + inner ℂ (word E F l Ω (fun j => h (v (.inr j)))) + (T (word E F k Ω (fun i => h (v (.inl i))))) = + ∑ σ, c σ * Pairing.contraction σ (fun a b => if a = b then 1 else 0) v) + (τ : Pairing (TailSlots k l)) (a b : Fin k) (hab : τ (.inl a) = .inl b) : + (N+1 : ℝ) * ‖c τ‖ ^ 2 ≤ ‖T‖ ^ 2 := by + classical + let labels := fun (n : Fin (N+1)) => Pairing.finiteLabels τ (.inl a) n + let source := fun n (i : Fin k) => labels n (.inl i) + let test := fun (j : Fin l) => labels (0 : Fin (N+1)) (.inr j) + have htest (n : Fin (N+1)) (j : Fin l) : labels n (.inr j) = test j := by + have hne : Pairing.repr τ (.inr j) ≠ Pairing.repr τ (.inl a) := by + intro hh + rcases (Pairing.repr_eq_iff τ (.inl a) (.inr j)).mp hh.symm with hh | hh + · cases hh + · rw [hab] at hh + cases hh + simp only [labels, test, Pairing.finiteLabels, ite_eq_right hne] + have hinj : Function.Injective source := by + intro n m he + have hh := congrArg Prod.snd (congrFun he a) + simpa only [source, labels, Pairing.finiteLabels, ite_true] using hh + have hsource : Orthonormal ℂ + (fun n => word E F k Ω (fun i => h (source n i))) := + (word_orthonormal E F Ω hΩ h horth k).comp source hinj + refine finite_constant_coefficient_bound T _ hsource + (word E F l Ω (fun j => h (test j))) ?_ (c τ) ?_ + · rw [norm_word, hΩ] + simp only [horth.norm_eq_one, Finset.prod_const_one, mul_one] + · intro n + have hh := hexp (labels n) + have hsum : (∑ σ, c σ * Pairing.contraction σ + (fun a b => if a = b then 1 else 0) (labels n)) = c τ := by + have hcon (σ) : Pairing.contraction σ + (fun a b => if a = b then 1 else 0) (labels n) = if σ = τ then 1 else 0 := by + exact Pairing.finite_contraction_isolation τ σ (.inl a) n + id (fun a b => if a = b then 1 else 0) (fun _ _ => rfl) + simp only [hcon, mul_ite, mul_one, mul_zero, Finset.sum_ite_eq', Finset.mem_univ, + ite_true] + rw [hsum] at hh + simpa only [source, htest] using hh + +lemma finite_pairing_test_bound (E F : PreHilbert) (k l N : ℕ) + (Ω : E) (hΩ : ‖Ω‖ = 1) (T : wordSpace E F k →L[ℂ] wordSpace E F l) + (c : Pairing (TailSlots k l) → ℂ) (h : TailSlots k l × Fin (N+1) → F) + (horth : Orthonormal ℂ h) + (hexp : ∀ v : TailSlots k l → TailSlots k l × Fin (N+1), + inner ℂ (word E F l Ω (fun j => h (v (.inr j)))) + (T (word E F k Ω (fun i => h (v (.inl i))))) = + ∑ σ, c σ * Pairing.contraction σ (fun a b => if a = b then 1 else 0) v) + (τ : Pairing (TailSlots k l)) (a b : Fin l) (hab : τ (.inr a) = .inr b) : + (N+1 : ℝ) * ‖c τ‖ ^ 2 ≤ ‖T‖ ^ 2 := by + classical + let labels := fun (n : Fin (N+1)) => Pairing.finiteLabels τ (.inr a) n + let source := fun (i : Fin k) => labels (0 : Fin (N+1)) (.inl i) + let test := fun n (j : Fin l) => labels n (.inr j) + have hsource (n : Fin (N+1)) (i : Fin k) : labels n (.inl i) = source i := by + have hne : Pairing.repr τ (.inl i) ≠ Pairing.repr τ (.inr a) := by + intro hh + rcases (Pairing.repr_eq_iff τ (.inr a) (.inl i)).mp hh.symm with hh | hh + · cases hh + · rw [hab] at hh + cases hh + simp only [labels, source, Pairing.finiteLabels, ite_eq_right hne] + have hinj : Function.Injective test := by + intro n m he + have hh := congrArg Prod.snd (congrFun he a) + simpa only [test, labels, Pairing.finiteLabels, ite_true] using hh + have htest : Orthonormal ℂ + (fun n => word E F l Ω (fun j => h (test n j))) := + (word_orthonormal E F Ω hΩ h horth l).comp test hinj + have hc (n : Fin (N+1)) : inner ℂ (word E F l Ω (fun j => h (test n j))) + (T (word E F k Ω (fun i => h (source i)))) = c τ := by + have hh := hexp (labels n) + have hsum : (∑ σ, c σ * Pairing.contraction σ + (fun a b => if a = b then 1 else 0) (labels n)) = c τ := by + have hcon (σ) : Pairing.contraction σ + (fun a b => if a = b then 1 else 0) (labels n) = if σ = τ then 1 else 0 := by + exact Pairing.finite_contraction_isolation τ σ (.inr a) n + id (fun a b => if a = b then 1 else 0) (fun _ _ => rfl) + simp only [hcon, mul_ite, mul_one, mul_zero, Finset.sum_ite_eq', Finset.mem_univ, + ite_true] + rw [hsum] at hh + simpa only [test, hsource] using hh + have hh := htest.sum_inner_products_le + (T (word E F k Ω (fun i => h (source i)))) (s := Finset.univ) + simp only [hc, Finset.sum_const, Finset.card_univ, Fintype.card_fin, nsmul_eq_mul, + Nat.cast_add, Nat.cast_one] at hh + have hn := T.le_opNorm (word E F k Ω (fun i => h (source i))) + rw [norm_word, hΩ] at hn + simp only [horth.norm_eq_one, Finset.prod_const_one, mul_one] at hn + exact hh.trans (pow_le_pow_left₀ (norm_nonneg _) hn 2) + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteRectangularBound.lean b/lean/OAI/Analysis/Commutator/FiniteRectangularBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..b60b241c5ee5dc86899a1d101f0e41715ad8bd6e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteRectangularBound.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteRectangularContraction +import OAI.Analysis.Commutator.HomogeneousBound + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type) [Fintype ι] [Fintype κ] [Nonempty κ] (k₀ : κ) + +local instance finiteRectangularBoundIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance finiteRectangularBoundColumnDecidableEq : DecidableEq κ := Classical.decEq κ + +local instance finiteRectangularBoundSumDecidableEq : DecidableEq (κ⊕ι) := Classical.decEq _ + +local instance finiteRectangularBoundDoubledSumDecidableEq : DecidableEq ((Fin 2)×(κ⊕ι)) := Classical.decEq _ + +omit [Nonempty κ] in +private lemma rectangular_bound_from_unitball + {A K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (π : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (Y : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι) + (C : ℝ) + (h : ∀ X : CStarMatrix κ κ A, ‖X‖ ≤ 1 → + ‖diagonal (H:=SumSpace (H:=K) ι) κ Y * + matrixRepresentation ((diagonal (H:=K) ι).comp π) X - + matrixRepresentation ((diagonal (H:=K) ι).comp π) X * + diagonal (H:=SumSpace (H:=K) ι) κ Y‖ ≤ C) + (X : CStarMatrix κ κ A) : + ‖diagonal (H:=SumSpace (H:=K) ι) κ Y * + matrixRepresentation ((diagonal (H:=K) ι).comp π) X - + matrixRepresentation ((diagonal (H:=K) ι).comp π) X * + diagonal (H:=SumSpace (H:=K) ι) κ Y‖ ≤ C * ‖X‖ := by + let ρ := (diagonal (H:=K) ι).comp π + let f := representedCommutator (matrixRepresentation (ι:=κ) ρ) + (diagonal (H:=SumSpace (H:=K) ι) κ Y) + exact linear_norm_bound_from_unitball f C h X + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×(κ⊕ι)) τ) ω + (matrixVonNeumann ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) (generated M E)) + (matrixInclusion ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) M (generated M E) (generated_le M E))) + +include hnormal hω F in +theorem rectangular_bound_after_average + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + {δ : ℝ} (hδ : 0 ≤ δ) + (hY : ∀ a : M,‖Y*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖ ≤ δ*‖a‖) + (X : CStarMatrix κ κ M) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y* + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X- + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X* + diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y‖ ≤ (3122*δ)*‖X‖ := by + have preF := rectangular_contraction_after_average ι κ k₀ M E τ hnormal ω hω + change _ at preF F + delta finiteRectangularContractionDoubledSumDecidableEq at preF + delta finiteRectangularBoundDoubledSumDecidableEq at F + have withF := preF F + have withData := withF hE hirr hτ hfaith h1 + have withY := withData Y hδ hY + exact rectangular_bound_from_unitball ι κ τ.gnsStarAlgHom Y (3122*δ) withY X + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteRectangularContraction.lean b/lean/OAI/Analysis/Commutator/FiniteRectangularContraction.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad26c9dc53347be7c68160c18c506d9a355ac10d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteRectangularContraction.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteSquareContraction +import OAI.Analysis.Commutator.RightCopies +import OAI.Analysis.Commutator.MatrixPadding + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type) [Fintype ι] [Fintype κ] [Nonempty κ] (k₀ : κ) + +local instance finiteRectangularContractionIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance finiteRectangularContractionColumnDecidableEq : DecidableEq κ := Classical.decEq κ + +local instance finiteRectangularContractionSumDecidableEq : DecidableEq (κ⊕ι) := Classical.decEq _ + +local instance finiteRectangularContractionDoubledSumDecidableEq : DecidableEq ((Fin 2)×(κ⊕ι)) := Classical.decEq _ + +omit [Fintype ι] [Fintype κ] [Nonempty κ] in +@[defeq] private theorem rectangular_index_decidable_eq : + (inferInstance : DecidableEq ((Fin 2)×(κ⊕ι))) = Classical.decEq _ := rfl + +omit [Nonempty κ] in +private lemma rectangular_contraction_norm_eq + {A K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (π : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (Y : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι) + (X : CStarMatrix κ κ A) : + ‖diagonal (H:=SumSpace (H:=K) ι) κ Y * + matrixRepresentation ((diagonal (H:=K) ι).comp π) X - + matrixRepresentation ((diagonal (H:=K) ι).comp π) X * + diagonal (H:=SumSpace (H:=K) ι) κ Y‖ = + ‖diagonal (H:=SumSpace (H:=K) (κ⊕ι)) (κ⊕ι) + (extend (rightCopies (H:=K) ι κ) Y) * + matrixRepresentation ((diagonal (H:=K) (κ⊕ι)).comp π) (padMatrix κ ι X) - + matrixRepresentation ((diagonal (H:=K) (κ⊕ι)).comp π) (padMatrix κ ι X) * + diagonal (H:=SumSpace (H:=K) (κ⊕ι)) (κ⊕ι) + (extend (rightCopies (H:=K) ι κ) Y)‖ := by + let ρ := (diagonal (H:=K) ι).comp π + let σ := (diagonal (H:=K) (κ⊕ι)).comp π + let Z := extend (rightCopies (H:=K) ι κ) Y + have hp := matrix_padding_commutator_norm κ ι σ Z X + have hreduce (a : A) := rightCopies_diagonal ι κ (π a) + have hr := amplified_extension_commutator_norm κ (rightCopies (H:=K) ι κ) ρ σ hreduce Y X + exact (hp.trans hr).symm + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×(κ⊕ι)) τ) ω + (matrixVonNeumann ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) (generated M E)) + (matrixInclusion ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) M (generated M E) (generated_le M E))) + +include hnormal hω F in +theorem rectangular_contraction_after_average + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + {δ : ℝ} (hδ : 0 ≤ δ) + (hY : ∀ a : M,‖Y*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖ ≤ δ*‖a‖) + (X : CStarMatrix κ κ M) (hX : ‖X‖≤1) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y* + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X- + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X* + diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y‖ ≤ 3122*δ := by + let J := κ⊕ι + let Z := extend (rightCopies (H:=τ.GNS) ι κ) Y + have hZ (a : M) := + (rightCopies_commutator_norm ι κ Y (τ.gnsStarAlgHom a)).le.trans (hY a) + have preF := square_contraction_after_average (H:=H) J (Sum.inl k₀) M E τ hnormal ω hω + -- Normalize index dictionaries before comparing the matrix algebra parameters. + change _ at preF F + dsimp (config := {instances := true}) only + [J, finiteSquareContractionDoubledIndexDecidableEq] at preF + dsimp (config := {instances := true}) only [rectangular_index_decidable_eq ι κ] at F + have withF := preF F + have withData := withF hE hirr hτ hfaith h1 + have withY := withData Z hδ hZ + have hbound := withY (padMatrix κ ι X) ((norm_padMatrix_le κ ι X).trans hX) + have h := rectangular_contraction_norm_eq ι κ τ.gnsStarAlgHom Y X + exact h.le.trans hbound + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteSmallCorner.lean b/lean/OAI/Analysis/Commutator/FiniteSmallCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..81c361e0ca63d7ea5a7646993c454ab55eaf1394 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteSmallCorner.lean @@ -0,0 +1,51 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFactorCornerTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder + +namespace Kadison.CornerTransport + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {H K : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem finite_small_corner_bound (Q : VonNeumannAlgebra H) (hQ : FactorCorner.IsFactor Q) + (σ : Q →ₚ[ℂ] ℂ) (hσ : ∀ a b : Q,σ (a*b)=σ (b*a)) + (hfaith : ∀ a : Q,σ (star a*a)=0 → a=0) + (j : Q →⋆ₐ[ℂ] A) (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (T : K →L[ℂ] K) (hT : ∀ q : Q,T*ρ (j q)=ρ (j q)*T) + (e : Q) (he : IsStarProjection e) {c : ℝ} + (hbound : ∀ z : A,j e*z*j e=z → ‖T*ρ z-ρ z*T‖≤c*‖z‖) + (f : Q) (hf : IsStarProjection f) (htrace : σ f≤σ e) + (z : A) (hz : j f*z*j f=z) : ‖T*ρ z-ρ z*T‖≤c*‖z‖ := by + obtain ⟨u,hu⟩ := PartialIsometryOrder.finite_factor_unitary_subequivalence Q hQ σ hσ hfaith f e hf he htrace + let v : unitary A := ⟨j (u:Q),Unitary.map_mem j u.property⟩ + have hv : (v:A)*j f*star (v:A)≤j e := by + change j (u:Q)*j f*star (j (u:Q))≤j e + rw [←map_star,←map_mul,←map_mul] + exact OrderHomClass.monotone j hu + have hcorner := conjugate_corner (j e) (j f) (he.map j) (hf.map j) v hv z hz + apply bound_under_unitary ρ T v (hT (u:Q)) ?_ z (hbound _ hcorner) + change T*ρ (star (j (u:Q)))=ρ (star (j (u:Q)))*T + rw [←map_star] + exact hT (star (u:Q)) + +end Kadison.CornerTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteSquareConditionalBound.lean b/lean/OAI/Analysis/Commutator/FiniteSquareConditionalBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..3ecef7e029b21e8331e63cad8c0c0a7b65120d9c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteSquareConditionalBound.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.Commutator.LittleGrothendieckSequence +import OAI.Analysis.Commutator.MatrixVectorTrace +import OAI.Analysis.Commutator.MatrixFreeSymmetry +import OAI.Analysis.Commutator.NormalCopiesAverage + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison + +variable {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +omit [CompleteSpace K] in +lemma commutator_perturbation_unitball (Y Z A : K →L[ℂ] K) {b e : ℝ} + (hb : ‖Z*A-A*Z‖ ≤ b) (he : ‖Y-Z‖ ≤ e) (hA : ‖A‖ ≤ 1) : + ‖Y*A-A*Y‖ ≤ b+2*e := by + have hid : Y*A-A*Y=(Z*A-A*Z)+((Y-Z)*A-A*(Y-Z)) := by + simp only [sub_mul,mul_sub]; abel + rw [hid] + have hn : 0 ≤ e := (norm_nonneg _).trans he + calc + _ ≤ ‖Z*A-A*Z‖+‖(Y-Z)*A-A*(Y-Z)‖ := norm_add_le _ _ + _ ≤ b+2*‖Y-Z‖*‖A‖ := add_le_add hb (operator_commutator_norm_le _ _) + _ ≤ b+2*e := by nlinarith [norm_nonneg (Y-Z),norm_nonneg A] + +private lemma commutator_perturbation_starHom + {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + (f : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (g : B →⋆ₐ[ℂ] (K →L[ℂ] K)) + (Y Z : A) (s : unitary B) {b e : ℝ} + (hb : ‖f Z*g (s:B)-g (s:B)*f Z‖ ≤ b) (he : ‖Z-Y‖ ≤ e) : + ‖f Y*g (s:B)-g (s:B)*f Y‖ ≤ b+2*e := by + apply commutator_perturbation_unitball (f Y) (f Z) (g (s:B)) hb + · rw [← map_sub] + exact (NonUnitalStarAlgHom.norm_apply_le f (Y-Z)).trans + (by simpa only [norm_sub_rev] using he) + · exact (NonUnitalStarAlgHom.norm_apply_le g (s:B)).trans + (LittleGrothendieck.unitary_norm_le_one s) + +namespace MatrixTower + +open OperatorAmplification TracialSequence + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] [Nonempty ι] (i₀ : ι) + +local instance finiteSquareConditionalBoundDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=ι) τ) ω + (matrixVonNeumann ι i₀ (generated M E)) + (matrixInclusion ι i₀ M (generated M E) (generated_le M E))) + +omit [Nonempty ι] in +include hnormal in +private theorem square_original_copies_average + (hE : Monotone (fun n => (E n).hom.range)) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + {δ : ℝ} (hδ : 0≤δ) + (hY : ∀ a : M, ‖Y*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖≤δ*‖a‖) : + ∃ Z : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι, + ‖Z‖≤‖Y‖ ∧ ‖Z-Y‖≤δ ∧ + (∀ a : M, (a:H →L[ℂ] H)∈generated M E → + Z*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)= + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Z) ∧ + (∀ a : M, ‖Z*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Z‖≤(3*δ)*‖a‖) := by + exact original_copies_average (H:=H) M E τ hnormal ι hE Y hδ hY + +include hnormal hω F in +theorem square_symmetry_after_average + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + {δ : ℝ} (hδ : 0 ≤ δ) + (hY : ∀ a : M,‖Y*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖ ≤ δ*‖a‖) + (s : unitary (CStarMatrix ι ι M)) (hs0 : MatrixGNS.trace (ι:=ι) τ (s:CStarMatrix ι ι M)=0) + (hs2 : (s:CStarMatrix ι ι M)*(s:CStarMatrix ι ι M)=1) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) ι Y*MatrixGNS.representation τ (s:CStarMatrix ι ι M)- + MatrixGNS.representation τ (s:CStarMatrix ι ι M)*diagonal (H:=SumSpace (H:=τ.GNS) ι) ι Y‖ ≤ 3122*δ := by + have havg := square_original_copies_average ι M E τ hnormal hE Y hδ hY + obtain ⟨Z, _, hd, hZQ, hZ⟩ := havg + have symmetry := matrix_free_symmetry_bound (H := H) ι i₀ M + have atGenerated := symmetry (generated M E) (generated_le M E) τ + have atFilter := atGenerated ω hω + change _ at * + delta finiteSquareConditionalBoundDecidableEq matrixFreeSymmetryDecidableEq at * + have inFreePosition := atFilter F + have inFactor := inFreePosition (generated_factor M E hirr) hτ hfaith h1 + have forAverage := inFactor Z + have hs := forAverage (fun q => hZQ _ q.property) (mul_nonneg (by norm_num) hδ) hZ s hs0 hs2 + have h := commutator_perturbation_starHom + (diagonal (H:=SumSpace (H:=τ.GNS) ι) ι) + (MatrixGNS.representation (ι:=ι) τ) Y Z s hs hd + convert h using 1; ring + +end MatrixTower + +end Kadison + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteSquareContraction.lean b/lean/OAI/Analysis/Commutator/FiniteSquareContraction.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec84ee71d2bb087c0b9cce4e3b28dcb555c56eb2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteSquareContraction.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteSquareConditionalBound +import OAI.Analysis.Commutator.MatrixFlattenRepresentation +import OAI.Analysis.Commutator.DoubleCopies +import OAI.Analysis.Commutator.AmplificationIsometry + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] [Nonempty ι] (i₀ : ι) + +local instance : DecidableEq ι := Classical.decEq ι + +local instance finiteSquareContractionDoubledIndexDecidableEq : DecidableEq ((Fin 2)×ι) := Classical.decEq _ + +omit [Fintype ι] [Nonempty ι] in +@[defeq] private theorem square_index_decidable_eq : + (inferInstance : DecidableEq ((Fin 2)×ι)) = Classical.decEq _ := rfl + +omit [Nonempty ι] in +private lemma square_contraction_norm_le + {A K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (π : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (Y : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι) + (X : CStarMatrix ι ι A) (hX : ‖X‖ ≤ 1) : + ‖diagonal (H:=SumSpace (H:=K) ι) ι Y* + matrixRepresentation ((diagonal (H:=K) ι).comp π) X- + matrixRepresentation ((diagonal (H:=K) ι).comp π) X* + diagonal (H:=SumSpace (H:=K) ι) ι Y‖ ≤ + ‖diagonal (H:=SumSpace (H:=K) ((Fin 2)×ι)) ((Fin 2)×ι) + (extend (doubleCopies (H:=K) ι) Y)* + matrixRepresentation ((diagonal (H:=K) ((Fin 2)×ι)).comp π) + (MatrixGNS.flatBalancedUnitary ι X hX)- + matrixRepresentation ((diagonal (H:=K) ((Fin 2)×ι)).comp π) + (MatrixGNS.flatBalancedUnitary ι X hX)* + diagonal (H:=SumSpace (H:=K) ((Fin 2)×ι)) ((Fin 2)×ι) + (extend (doubleCopies (H:=K) ι) Y)‖ := by + let ρ := (diagonal (H:=K) ι).comp π + let σ := (diagonal (H:=K) ((Fin 2)×ι)).comp π + let Z := extend (doubleCopies (H:=K) ι) Y + have hd := MatrixGNS.flatBalanced_commutator_dominates ι σ Z X hX + have hreduce (a : A) := doubleCopies_diagonal ι (π a) + have hr := amplified_extension_commutator_norm ι (doubleCopies (H:=K) ι) ρ σ hreduce Y X + rw [hr] at hd + exact hd + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×ι) τ) ω + (matrixVonNeumann ((Fin 2)×ι) (0,i₀) (generated M E)) + (matrixInclusion ((Fin 2)×ι) (0,i₀) M (generated M E) (generated_le M E))) + +include hnormal hω F in +theorem square_contraction_after_average + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + {δ : ℝ} (hδ : 0 ≤ δ) + (hY : ∀ a : M,‖Y*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖ ≤ δ*‖a‖) + (X : CStarMatrix ι ι M) (hX : ‖X‖≤1) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) ι Y*MatrixGNS.representation τ X- + MatrixGNS.representation τ X*diagonal (H:=SumSpace (H:=τ.GNS) ι) ι Y‖ ≤ 3122*δ := by + let J := (Fin 2)×ι + let Z := extend (doubleCopies (H:=τ.GNS) ι) Y + have hZ (a : M) := + (doubleCopies_commutator_norm ι Y (τ.gnsStarAlgHom a)).le.trans (hY a) + have boundRule := square_symmetry_after_average J (0,i₀) M E τ hnormal ω hω + change _ at boundRule F + dsimp (config := { instances := true }) only [J, finiteSquareConditionalBoundDecidableEq] at boundRule + dsimp (config := { instances := true }) only + [square_index_decidable_eq ι] at F + have positioned := boundRule F + have towerBound := positioned hE hirr hτ hfaith h1 + have forZ := towerBound Z hδ hZ + have hbound := forZ + (MatrixGNS.flatBalancedUnitary ι X hX) + (MatrixGNS.flatBalancedUnitary_trace ι τ hτ X hX) + (MatrixGNS.flatBalancedUnitary_sq ι X hX) + have h := square_contraction_norm_le ι τ.gnsStarAlgHom Y X hX + exact h.trans hbound + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardCompression.lean b/lean/OAI/Analysis/Commutator/FiniteStandardCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..da166e0b288675f8d0d52a042d19a77c12a0a598 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardCompression.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FiniteStandardUnconditional +import OAI.Analysis.Commutator.IntertwinerMatrixTransfer +import OAI.Analysis.Commutator.IntertwinerSeminorm +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.RepresentationMatrixNorm +import OAI.Analysis.Commutator.StandardTrace + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.NormalRepresentation + +open OperatorAmplification IntertwinerCompression MatrixTower + +private lemma diagonal_compression_bound + {H K : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (M : VonNeumannAlgebra H) (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (hπ : Function.Injective π) (ι : Type) [Fintype ι] [Nonempty ι] [DecidableEq ι] + (Q : VonNeumannAlgebra (SumSpace (H := K) ι)) + (hrange : ∀ b ∈ Q, ∃ a : M, diagonal (H := K) ι (π a) = b) + (h : ℕ) + (hbound : ∀ (Z : SumSpace (H := K) ι →L[ℂ] SumSpace (H := K) ι) + (B : Matrix (Fin h) (Fin h) (SumSpace (H := K) ι →L[ℂ] SumSpace (H := K) ι)), + (∀ i j, B i j ∈ Q) → + ‖diagonalAmplification h Z * matrixOperator h B - + matrixOperator h B * diagonalAmplification h Z‖ ≤ + (3122 * commutatorSeminorm Q Z) * ‖matrixOperator h B‖) + (T : H →L[ℂ] SumSpace (H := K) ι) (hcon : ‖T‖ ≤ 1) + (hT : ∀ a : M, T.comp (a : H →L[ℂ] H) = + (diagonal (H := K) ι (π a)).comp T) + (Y : H →L[ℂ] H) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) + (hX : ∀ i j, X i j ∈ M) + (hmem : ∀ a : M, diagonal (H := K) ι (π a) ∈ Q) : + ‖diagonalAmplification h ((T.adjoint.comp T) * Y * (T.adjoint.comp T)) * matrixOperator h X - + matrixOperator h X * diagonalAmplification h ((T.adjoint.comp T) * Y * (T.adjoint.comp T))‖ ≤ + (3122 * commutatorSeminorm M Y) * ‖matrixOperator h X‖ := by + let ψ := (diagonal (H := K) ι).comp π + have hψ : Function.Injective ψ := by + intro a b hab + apply hπ + let i : ι := Classical.choice (inferInstance : Nonempty ι) + ext x + have he := congrArg (fun U : SumSpace (H := K) ι →L[ℂ] SumSpace (H := K) ι => + U (single ι i x) i) hab + simpa only [ψ, StarAlgHom.comp_apply, diagonal_apply, single_apply, ite_true] using he + have hsemi := seminorm_le M Q ψ hψ hrange T hcon hT Y + let A : Matrix (Fin h) (Fin h) M := fun i j => ⟨X i j, hX i j⟩ + have hA : ∀ i j, ψ (A i j) ∈ Q := fun i j => hmem (A i j) + have hb := hbound (transfer T Y) (fun i j => ψ (A i j)) hA + have hp := pullback_matrix_commutator_norm_le M.toStarSubalgebra.subtype ψ T hT hcon h A (transfer T Y) + rw [transfer_back] at hp + refine hp.trans (hb.trans ?_) + apply mul_le_mul + · exact mul_le_mul_of_nonneg_left hsemi (by norm_num) + · exact matrixOperator_subtype_norm_le M ψ h X hX + · exact norm_nonneg _ + · exact mul_nonneg (by norm_num) (commutatorSeminorm_nonneg M Y) + + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (τ : M →ₚ[ℂ] ℂ) + +variable (ι : Type) [Fintype ι] [Nonempty ι] + +local instance finiteStandardCompressionDecidableEq : DecidableEq ι := Classical.decEq ι + +theorem finite_standard_compression_bound [TopologicalSpace.SeparableSpace τ.GNS] + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (T : H →L[ℂ] SumSpace (H:=τ.GNS) ι) (hcon : ‖T‖≤1) + (hT : ∀ a : M,T.comp (a:H →L[ℂ] H)= + (diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)).comp T) + (h : ℕ) (hh : 1≤h) (Y : H →L[ℂ] H) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈M) : + ‖diagonalAmplification h ((T.adjoint.comp T)*Y*(T.adjoint.comp T))*matrixOperator h X- + matrixOperator h X*diagonalAmplification h ((T.adjoint.comp T)*Y*(T.adjoint.comp T))‖≤ + (3122*commutatorSeminorm M Y)*‖matrixOperator h X‖ := by + apply diagonal_compression_bound M τ.gnsStarAlgHom + (NormalGNS.gns_injective M τ hfaith) ι (finiteStandardAlgebra ι M τ) + (fun b hb => (finiteStandard_range ι M τ hτ hnormal b).mp hb) + h ?_ T hcon hT Y X hX + (fun a => (finiteStandard_range ι M τ hτ hnormal _).mpr ⟨a, rfl⟩) + intro Z B hB + have bound := finite_standard_bound M τ ι hτ hnormal hfaith hone hfac hdiffuse + exact bound h hh Z B hB + +end Kadison.NormalRepresentation + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardGauge.lean b/lean/OAI/Analysis/Commutator/FiniteStandardGauge.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a371f0a7443d68135bdd51e1e060f1d8ada19cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardGauge.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.FiniteRectangularBound + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type) [Fintype ι] [Nonempty ι] [Fintype κ] [Nonempty κ] (k₀ : κ) + +local instance finiteStandardGaugeIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance finiteStandardGaugeColumnDecidableEq : DecidableEq κ := Classical.decEq κ + +local instance finiteStandardGaugeSumDecidableEq : DecidableEq (κ⊕ι) := Classical.decEq _ + +local instance finiteStandardGaugeDoubledSumDecidableEq : DecidableEq ((Fin 2)×(κ⊕ι)) := Classical.decEq _ + +omit [Nonempty κ] in +private theorem finite_standard_representation_estimates + {A K : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (π : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (hπ : Function.Injective π) + (Y : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι) + (X : CStarMatrix κ κ A) : + ‖matrixRepresentation ((diagonal (H:=K) ι).comp π) X‖ = ‖X‖ ∧ + ∀ a : A, + ‖Y * ((diagonal (H:=K) ι).comp π) a - ((diagonal (H:=K) ι).comp π) a * Y‖ ≤ + commutatorSeminorm (NormalGNS.bicommutant (((diagonal (H:=K) ι).comp π).range)) Y * ‖a‖ := by + let ρ := (diagonal (H:=K) ι).comp π + let P := NormalGNS.bicommutant ρ.range + have hdiag : Function.Injective (diagonal (H:=K) ι) := by + intro a b hab + ext x + let i : ι := Classical.choice (inferInstance : Nonempty ι) + have hh := congrArg (fun T : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι => + T (single ι i x) i) hab + simpa only [diagonal_apply,single_apply,ite_true] using hh + constructor + · exact CyclicSpatial.matrixRepresentation_norm_eq ρ (hdiag.comp hπ) X + · intro a + have hmem : ρ a ∈ P := NormalGNS.subset_bicommutant ρ.range ⟨a,rfl⟩ + exact (commutator_bound P Y hmem).trans + (mul_le_mul_of_nonneg_left (NonUnitalStarAlgHom.norm_apply_le ρ a) + (commutatorSeminorm_nonneg P Y)) + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×(κ⊕ι)) τ) ω + (matrixVonNeumann ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) (generated M E)) + (matrixInclusion ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) M (generated M E) (generated_le M E))) + +def finiteStandardAlgebra : VonNeumannAlgebra (SumSpace (H:=τ.GNS) ι) := + NormalGNS.bicommutant (((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom).range) + +include hnormal hω F in +theorem finite_standard_gauge_bound + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + (X : CStarMatrix κ κ M) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y* + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X- + matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X* + diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y‖ ≤ + (3122*commutatorSeminorm (finiteStandardAlgebra ι M τ) Y)* + ‖matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) X‖ := by + have estimates := finite_standard_representation_estimates ι κ τ.gnsStarAlgHom + (TracialGNS.left_faithful τ hfaith) Y X + have hδ := commutatorSeminorm_nonneg (finiteStandardAlgebra ι M τ) Y + have preF := rectangular_bound_after_average ι κ k₀ M E τ hnormal ω hω + change _ at preF F + delta finiteRectangularBoundDoubledSumDecidableEq finiteStandardGaugeDoubledSumDecidableEq at preF F + have withF := preF F + have withData := withF hE hirr hτ hfaith h1 + have withY := withData Y hδ estimates.2 + exact (withY X).trans_eq (congrArg + (fun r : ℝ => (3122 * commutatorSeminorm (finiteStandardAlgebra ι M τ) Y) * r) + estimates.1.symm) + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardMainInterface.lean b/lean/OAI/Analysis/Commutator/FiniteStandardMainInterface.lean new file mode 100644 index 0000000000000000000000000000000000000000..57c610cc08c05572ebc85cb7ea471316345418b6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardMainInterface.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteStandardRepresented + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] [Nonempty ι] (h : ℕ) (hh : 1 ≤ h) + +local instance finiteStandardMainInterfaceIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance finiteStandardMainInterfaceColumnDecidableEq : DecidableEq (Fin h) := Classical.decEq (Fin h) + +local instance finiteStandardMainInterfaceSumDecidableEq : DecidableEq (Fin h⊕ι) := Classical.decEq _ + +local instance finiteStandardMainInterfaceDoubledSumDecidableEq : DecidableEq ((Fin 2)×(Fin h⊕ι)) := Classical.decEq _ + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×(Fin h⊕ι)) τ) ω + (matrixVonNeumann ((Fin 2)×(Fin h⊕ι)) (0,Sum.inl (⟨0,lt_of_lt_of_le Nat.zero_lt_one hh⟩ : Fin h)) (generated M E)) + (matrixInclusion ((Fin 2)×(Fin h⊕ι)) (0,Sum.inl (⟨0,lt_of_lt_of_le Nat.zero_lt_one hh⟩ : Fin h)) M (generated M E) (generated_le M E))) + +include hnormal hω F in +theorem finite_standard_matrixOperator_bound + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + (X : Matrix (Fin h) (Fin h) (SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι)) + (hX : ∀ i j,X i j∈finiteStandardAlgebra ι M τ) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖ ≤ + (3122*commutatorSeminorm (finiteStandardAlgebra ι M τ) Y)*‖matrixOperator h X‖ := by + let k₀ : Fin h := ⟨0,lt_of_lt_of_le Nat.zero_lt_one hh⟩ + let : Nonempty (Fin h) := ⟨k₀⟩ + have represented := finite_standard_entrywise_bound ι (Fin h) k₀ M E τ hnormal ω hω + change _ at represented F + delta finiteStandardRepresentedDoubledSumDecidableEq + finiteStandardMainInterfaceDoubledSumDecidableEq at represented F + exact represented F hE hirr hτ hfaith h1 Y X hX + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardRange.lean b/lean/OAI/Analysis/Commutator/FiniteStandardRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..fc793a85622999232ac3b25dbd7052024e766a26 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardRange.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteStandardGauge + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.MatrixTower + +open OperatorAmplification + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] [Nonempty ι] + +local instance finiteStandardRangeIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +private lemma diagonal_range_of_closed_range + {A K : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (π : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (N : VonNeumannAlgebra K) + (hN : ∀ b : K →L[ℂ] K, b∈N ↔ ∃ a : A, π a=b) + (T : SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι) : + T∈NormalGNS.bicommutant (((diagonal (H:=K) ι).comp π).range) ↔ + ∃ a : A, diagonal (H:=K) ι (π a)=T := by + let ρ := (diagonal (H:=K) ι).comp π + let i₀ : ι := Classical.choice (inferInstance : Nonempty ι) + let Q := diagonalVonNeumann ι i₀ N + have hQ : (Q : Set (SumSpace (H:=K) ι →L[ℂ] SumSpace (H:=K) ι))=Set.range ρ := by + ext S + change (∃ b∈N,diagonal (H:=K) ι b=S) ↔ ∃ a : A,ρ a=S + constructor + · rintro ⟨b,hb,hbS⟩ + obtain ⟨a,rfl⟩ := (hN b).mp hb + exact ⟨a,hbS⟩ + · rintro ⟨a,rfl⟩ + exact ⟨π a,(hN _).mpr ⟨a,rfl⟩,rfl⟩ + change T∈NormalGNS.bicommutant ρ.range ↔ ∃ a : A,ρ a=T + rw [NormalGNS.mem_bicommutant] + change T∈Set.centralizer (Set.centralizer (Set.range ρ)) ↔ T∈Set.range ρ + rw [←hQ,Q.centralizer_centralizer] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +theorem finiteStandard_range + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (T : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) : + T∈finiteStandardAlgebra ι M τ ↔ + ∃ a : M,diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)=T := by + let N := NormalGNS.bicommutant τ.gnsStarAlgHom.range + have hrange := NormalGNS.range_bicommutant M τ hτ hnormal + have hN := fun b => (NormalGNS.mem_bicommutant τ.gnsStarAlgHom.range b).trans + (Set.ext_iff.mp hrange b) + exact diagonal_range_of_closed_range ι τ.gnsStarAlgHom N hN T + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardRepresented.lean b/lean/OAI/Analysis/Commutator/FiniteStandardRepresented.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2b00a3277fc2d2d7192ff964ba4adc44b99311d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardRepresented.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteStandardRange + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type) [Fintype ι] [Nonempty ι] [Fintype κ] [Nonempty κ] (k₀ : κ) + +local instance finiteStandardRepresentedIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance finiteStandardRepresentedColumnDecidableEq : DecidableEq κ := Classical.decEq κ + +local instance finiteStandardRepresentedSumDecidableEq : DecidableEq (κ⊕ι) := Classical.decEq _ + +local instance finiteStandardRepresentedDoubledSumDecidableEq : DecidableEq ((Fin 2)×(κ⊕ι)) := Classical.decEq _ + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (E : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=(Fin 2)×(κ⊕ι)) τ) ω + (matrixVonNeumann ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) (generated M E)) + (matrixInclusion ((Fin 2)×(κ⊕ι)) (0,Sum.inl k₀) M (generated M E) (generated_le M E))) + +include hnormal hω F in +theorem finite_standard_entrywise_bound + (hE : Monotone (fun n => (E n).hom.range)) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + (X : Matrix κ κ (SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι)) + (hX : ∀ i j,X i j∈finiteStandardAlgebra ι M τ) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y*matrixAction X- + matrixAction X*diagonal (H:=SumSpace (H:=τ.GNS) ι) κ Y‖ ≤ + (3122*commutatorSeminorm (finiteStandardAlgebra ι M τ) Y)*‖matrixAction X‖ := by + have hlift (i j : κ) := (finiteStandard_range ι M τ hτ hnormal (X i j)).mp (hX i j) + let A : CStarMatrix κ κ M := CStarMatrix.ofMatrix (fun i j => Classical.choose (hlift i j)) + have hA (i j : κ) : diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom (A i j))=X i j := + Classical.choose_spec (hlift i j) + have hrep : matrixRepresentation ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) A=matrixAction X := by + apply ContinuousLinearMap.ext + intro v + apply PiLp.ext + intro i + simp only [CyclicSpatial.represented_matrix_apply,StarAlgHom.comp_apply,hA] + exact (CyclicColumns.matrixAction_apply X v i).symm + have gauge := finite_standard_gauge_bound ι κ k₀ M E τ hnormal ω hω + change _ at gauge F + delta finiteStandardGaugeDoubledSumDecidableEq finiteStandardRepresentedDoubledSumDecidableEq at gauge F + have hb := gauge F hE hirr hτ hfaith h1 Y A + simpa only [hrep] using hb + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStandardUnconditional.lean b/lean/OAI/Analysis/Commutator/FiniteStandardUnconditional.lean new file mode 100644 index 0000000000000000000000000000000000000000..b692ebe29ad9d430fd49b1743ae855eb3688ce24 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStandardUnconditional.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteStandardMainInterface +import OAI.Analysis.Commutator.MatrixFreePositionProducer + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator Topology + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence CyclicColumns HilbertPadding + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) [Nontrivial M] + +variable (τ : M →ₚ[ℂ] ℂ) + +omit [Nontrivial M] in +theorem exists_irreducible_stage_tower [TopologicalSpace.SeparableSpace τ.GNS] + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) : + ∃ E : ℕ → Stage M, Monotone (fun n => (E n).hom.range) ∧ + (∀ n,n+1 ≤ Fintype.card (E n).I) ∧ + (∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) := by + obtain ⟨x,hx,hxden⟩ := exists_selfAdjoint_dense_sequence M τ + let E := tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx + refine ⟨E,tower_increasing M τ hτ hnormal hfaith hone hfac hdiffuse x hx, + tower_size M τ hτ hnormal hfaith hone hfac hdiffuse x hx,?_⟩ + intro a ha + refine ⟨τ a,?_⟩ + exact scalar_of_commutes M τ hτ hone x hxden E + (fun j _ hε => tower_requirement M τ hτ hnormal hfaith hone hfac hdiffuse x hx j hε) + hfaith a ha + +variable (ι : Type) [Fintype ι] [Nonempty ι] + +local instance finiteStandardUnconditionalIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +theorem finite_standard_bound [TopologicalSpace.SeparableSpace τ.GNS] + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (h : ℕ) (hh : 1 ≤ h) + (Y : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + (X : Matrix (Fin h) (Fin h) (SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι)) + (hX : ∀ i j,X i j∈finiteStandardAlgebra ι M τ) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖ ≤ + (3122*commutatorSeminorm (finiteStandardAlgebra ι M τ) Y)*‖matrixOperator h X‖ := by + obtain ⟨E,hE,hsize,hirr⟩ := exists_irreducible_stage_tower M τ hτ hnormal hfaith hone hfac hdiffuse + let k₀ : Fin h := ⟨0,lt_of_lt_of_le Nat.zero_lt_one hh⟩ + let i₀ : (Fin 2)×(Fin h⊕ι) := (0,Sum.inl k₀) + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨F⟩ := exists_matrix_freeCornerPosition ((Fin 2)×(Fin h⊕ι)) i₀ M E τ ω + hE hsize hirr hτ hnormal hfaith hone hω + have bound := finite_standard_matrixOperator_bound ι h hh M E τ hnormal ω hω + change _ at bound F + delta finiteStandardMainInterfaceDoubledSumDecidableEq + matrixFreePositionProducerDecidableEq at bound F + exact bound F hE hirr hτ hfaith hone Y X hX + +end Kadison.MatrixTower + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteStrongTest.lean b/lean/OAI/Analysis/Commutator/FiniteStrongTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..f6bdb5df5fe73a4d7966af0d42826b3b94d9bb11 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteStrongTest.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology + +namespace Kadison.FiniteStrongTest + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def evaluation (M : VonNeumannAlgebra H) (x : H) : M →L[ℂ] H := + LinearMap.mkContinuous + { toFun := fun a => (a : H →L[ℂ] H) x + map_add' := by intros; rfl + map_smul' := by intros; rfl } + ‖x‖ (fun a => by + change ‖(a : H →L[ℂ] H) x‖≤‖x‖*‖(a:H →L[ℂ] H)‖ + rw [mul_comm] + exact (a : H →L[ℂ] H).le_opNorm x) + +def testMap (M : VonNeumannAlgebra H) (v : ℕ → H) (N : ℕ) : M →L[ℂ] PiLp 2 (fun _ : Fin N => H) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : Fin N => H)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun j : Fin N => evaluation M (v j))) + +@[simp] lemma testMap_apply (M : VonNeumannAlgebra H) (v : ℕ → H) (N : ℕ) (a : M) + (j : Fin N) : testMap M v N a j=(a : H →L[ℂ] H) (v j) := rfl + +lemma strong_null_of_dense_tests (M : VonNeumannAlgebra H) (v : ℕ → H) (hv : DenseRange v) + (T : ℕ → M) (hT : ∀ n,‖T n‖≤1) + (ht : ∀ n,∀ j : Fin n,‖(T n : H →L[ℂ] H) (v j)‖≤1/((n:ℝ)+1)) : + ∀ x,Tendsto (fun n => (T n : H →L[ℂ] H) x) atTop (𝓝 0) := by + intro x + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨j,hj⟩ := hv.exists_dist_lt x (by positivity : (0:ℝ)<ε/3) + obtain ⟨N,hN⟩ := eventually_atTop.mp + (tendsto_one_div_add_atTop_nhds_zero_nat.eventually_lt_const (by positivity : (0:ℝ)<ε/3)) + refine ⟨max N (j+1),?_⟩ + intro n hn + have hnN : N≤n := le_trans (le_max_left _ _) hn + have hjn : j (T n : H →L[ℂ] H) x) atTop (𝓝 0)) → + Tendsto (fun n => f (T n)) atTop (𝓝 0)) + (ε : ℝ) (hε : 0<ε) : + ∃ N : ℕ,∀ a : M,‖a‖≤1 → (∀ j : Fin N,‖(a : H →L[ℂ] H) (v j)‖≤1/((N:ℝ)+1)) → + ‖f a‖≤ε := by + by_contra h + push Not at h + choose T hT ht hlarge using h + have hlim := (hf T hT (strong_null_of_dense_tests M v hv T hT ht)).norm + have hsmall : ∀ᶠ n in atTop,‖f (T n)‖<ε := by + apply hlim.eventually_lt_const + simpa only [norm_zero] using hε + obtain ⟨n,hn⟩ := hsmall.exists + exact (hlarge n).not_ge hn.le + +end Kadison.FiniteStrongTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteSupportFactorization.lean b/lean/OAI/Analysis/Commutator/FiniteSupportFactorization.lean new file mode 100644 index 0000000000000000000000000000000000000000..18854d7c140290cadb23cd231ff13eafab39beb3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteSupportFactorization.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteFunctionalFactorization + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorFunctionals + +open ContinuousLinearMap + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (K : Submodule ℂ H) [K.HasOrthogonalProjection] + +def extendOperator : (K →L[ℂ] K) →L[ℂ] (H →L[ℂ] H) := + LinearMap.mkContinuous + { toFun := fun (R : K →L[ℂ] K) => K.subtypeL.comp (R.comp K.orthogonalProjectionOnto) + map_add' := by intro R S; ext x; rfl + map_smul' := by intro z R; ext x; rfl } + 1 (by + intro R + rw [one_mul] + apply opNorm_le_bound _ (norm_nonneg R) + intro x + change ‖R (K.orthogonalProjectionOnto x)‖≤‖R‖*‖x‖ + exact (R.le_opNorm _).trans (mul_le_mul_of_nonneg_left + (K.norm_orthogonalProjectionOnto_apply_le x) (norm_nonneg R))) + +omit [CompleteSpace H] in +@[simp] lemma extendOperator_apply (R : K →L[ℂ] K) (x : H) : + extendOperator K R x=(R (K.orthogonalProjectionOnto x) : H) := rfl + +local instance : NormedSpace ℂ (K →L[ℂ] K) := ContinuousLinearMap.toNormedSpace + +local instance : NormedAddCommGroup (K →L[ℂ] K) := ContinuousLinearMap.toNormedAddCommGroup + +lemma extendOperator_norm : ‖extendOperator K‖≤1 := by + apply LinearMap.mkContinuous_norm_le _ zero_le_one + +variable {ι : Type*} [Fintype ι] + +def finiteFunctional (x y : ι → H) : StrongDual ℂ (H →L[ℂ] H) := + ∑ i, (innerSL ℂ (y i)).comp (ContinuousLinearMap.apply ℂ H (x i)) + +omit [CompleteSpace H] in +@[simp] lemma finiteFunctional_apply (x y : ι → H) (T : H →L[ℂ] H) : + finiteFunctional x y T=∑ i, inner ℂ (y i) (T (x i)) := by + simp [finiteFunctional] + +omit [CompleteSpace H] [K.HasOrthogonalProjection] in +lemma tuple_coe_norm {n : ℕ} (x : PiLp 2 (fun _ : Fin n => K)) : + ‖(WithLp.toLp 2 (fun i => (x i : H)) : PiLp 2 (fun _ : Fin n => H))‖=‖x‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + simp only [PiLp.norm_sq_eq_of_L2] + rfl + +theorem exists_finite_support_factorization (a b : ι → H) : + ∃ (n : ℕ) (x y : PiLp 2 (fun _ : Fin n => H)), + (∀ T : H →L[ℂ] H, finiteFunctional a b T=∑ i, inner ℂ (y i) (T (x i))) ∧ + ‖x‖*‖y‖≤‖finiteFunctional a b‖ := by + let L : Submodule ℂ H := Submodule.span ℂ (Set.range a ∪ Set.range b) + let : FiniteDimensional ℂ L := FiniteDimensional.span_of_finite ℂ + ((Set.finite_range a).union (Set.finite_range b)) + have ha : ∀ i, a i∈L := fun i => Submodule.subset_span (Or.inl ⟨i,rfl⟩) + have hb : ∀ i, b i∈L := fun i => Submodule.subset_span (Or.inr ⟨i,rfl⟩) + let ψ := (finiteFunctional a b).comp (extendOperator L) + obtain ⟨x,y,hxy,hn⟩ := exists_finite_factorization ψ + let x' : PiLp 2 (fun _ : Fin (Module.finrank ℂ L) => H) := WithLp.toLp 2 (fun i => (x i : H)) + let y' : PiLp 2 (fun _ : Fin (Module.finrank ℂ L) => H) := WithLp.toLp 2 (fun i => (y i : H)) + refine ⟨Module.finrank ℂ L,x',y',?_,?_⟩ + · intro T + let Tc : L →L[ℂ] L := L.orthogonalProjectionOnto.comp (T.comp L.subtypeL) + have he : ψ Tc=finiteFunctional a b T := by + change finiteFunctional a b (extendOperator L Tc)=finiteFunctional a b T + simp only [finiteFunctional_apply,extendOperator_apply] + apply Finset.sum_congr rfl + intro i _ + have hpa : L.orthogonalProjectionOnto (a i)=⟨a i,ha i⟩ := + L.orthogonalProjectionOnto_mem_subspace_eq_self ⟨a i,ha i⟩ + rw [hpa] + change inner ℂ (⟨b i,hb i⟩ : L) (L.orthogonalProjectionOnto (T (a i)))=_ + exact Submodule.inner_orthogonalProjectionOnto_eq_of_mem_left ⟨b i,hb i⟩ _ + rw [←he,hxy Tc] + apply Finset.sum_congr rfl + intro i _ + exact Submodule.inner_orthogonalProjectionOnto_eq_of_mem_left (y i) (T (x i)) + · rw [tuple_coe_norm L x,tuple_coe_norm L y] + exact hn.trans ((opNorm_comp_le _ _).trans + (mul_le_of_le_one_right (norm_nonneg _) (extendOperator_norm L))) + +end Kadison.OperatorFunctionals + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteTestCompletion.lean b/lean/OAI/Analysis/Commutator/FiniteTestCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..2cc6613dbae9a0a6f1112793c50dfadcdc002435 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteTestCompletion.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialWordContinuity +import OAI.Analysis.Commutator.PartialUnitaryCompletion + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.Words + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +variable (x : J → A) (k : K → ℤ) + +lemma slotCost_le {m : ℕ} (hk : ∀ i,(k i).natAbs ≤ m) (s : Slot K) : slotCost k s ≤ m+2 := by + cases s with + | none => simp [slotCost] + | some s => + cases s with + | none => simp [slotCost] + | some i => exact Nat.add_le_add_right (hk i) 2 + +lemma wordCost_le {m : ℕ} (hk : ∀ i,(k i).natAbs ≤ m) (l : List (Letter J K)) : + wordCost k l ≤ l.length*(m+2) := by + induction l with + | nil => simp [wordCost] + | cons i l ih => + have hh := Nat.add_le_add (slotCost_le k hk i.2) ih + simpa only [wordCost,List.map_cons,List.sum_cons,List.length_cons,Nat.add_mul, + one_mul,Nat.add_comm] using hh + +include hτ in +lemma momentBound_completed (hone : τ 1=1) (hx : ∀ j,‖x j‖ ≤ 1) + (v : PartialUnitary A) {N : ℕ} {B C : ℝ} + (hB : MomentBound τ x k v N B) + (hpower : ∀ i,((k i).natAbs:ℝ)+2 ≤ C) + (hword : ∀ l : List (Letter J K),l.length ≤ N → (wordCost k l:ℝ) ≤ C) : + MomentBound τ x k v.completed N (B+C*Real.sqrt (1-(τ v.support).re)) := by + have he := v.completion_norm_sub τ hone + constructor + · intro i + have hd : ‖τ (v.completed.power (k i))-τ (v.power (k i))‖ ≤ + C*Real.sqrt (1-(τ v.support).re) := by + rw [←map_sub] + exact (TracialL2.norm_trace_le τ hτ hone _).trans + ((v.completed.power_norm_sub τ hτ v (k i)).trans (by + rw [he] + exact mul_le_mul_of_nonneg_right (hpower i) (Real.sqrt_nonneg _))) + exact (norm_le_insert (τ (v.power (k i))) (τ (v.completed.power (k i)))).trans + (by simpa only [norm_sub_rev] using add_le_add (hB.1 i) hd) + · intro l hl hlen hvalid + have hd : ‖τ (word x k v.completed l)-τ (word x k v l)‖ ≤ + C*Real.sqrt (1-(τ v.support).re) := by + exact (trace_word_norm_sub τ hτ x k hone hx v.completed v l).trans (by + rw [he] + exact mul_le_mul_of_nonneg_right (hword l hlen) (Real.sqrt_nonneg _)) + exact (norm_le_insert (τ (word x k v l)) (τ (word x k v.completed l))).trans + (by simpa only [norm_sub_rev] using add_le_add (hB.2 l hl hlen hvalid) hd) + +omit [StarOrderedRing A] in +lemma momentBound_mono {v : PartialUnitary A} {N : ℕ} {B C : ℝ} + (hB : MomentBound τ x k v N B) (hBC : B ≤ C) : MomentBound τ x k v N C := + ⟨fun i => (hB.1 i).trans hBC,fun l hl hn hv => (hB.2 l hl hn hv).trans hBC⟩ + +end Kadison.FinitePatching.Words + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteTestHahnBanach.lean b/lean/OAI/Analysis/Commutator/FiniteTestHahnBanach.lean new file mode 100644 index 0000000000000000000000000000000000000000..f90dac82dd6498d1f153e2267fa27b387224ff05 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteTestHahnBanach.lean @@ -0,0 +1,107 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FiniteTestHahnBanach + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + [NormedAddCommGroup F] [NormedSpace ℂ F] + +lemma scaled_test_bound (f : StrongDual ℂ E) (A : E →L[ℂ] F) + {ε δ : ℝ} (hε : 0<ε) (hδ : 0<δ) + (h : ∀ x : E,‖x‖≤1 → ‖A x‖≤δ → ‖f x‖≤ε) (x : E) : + ‖f x‖≤ε*max ‖x‖ (‖A x‖/δ) := by + by_cases hx : x=0 + · subst x + simp only [map_zero,norm_zero] + exact mul_nonneg hε.le (le_max_left _ _) + let r : ℝ := max ‖x‖ (‖A x‖/δ) + have hr : 0.trans_eq (mul_comm _ _) + have hc : ‖((r⁻¹:ℝ):ℂ)‖=r⁻¹ := by + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hr)] + have hx1 : ‖((r⁻¹:ℝ):ℂ) • x‖≤1 := by + rw [norm_smul,hc] + calc + _ ≤ r⁻¹*r := mul_le_mul_of_nonneg_left hxr (le_of_lt (inv_pos.mpr hr)) + _ = 1 := inv_mul_cancel₀ hr.ne' + have ha1 : ‖A (((r⁻¹:ℝ):ℂ) • x)‖≤δ := by + rw [map_smul,norm_smul,hc] + calc + _ ≤ r⁻¹*(δ*r) := mul_le_mul_of_nonneg_left har (le_of_lt (inv_pos.mpr hr)) + _ = δ := by field_simp + have hh := h (((r⁻¹:ℝ):ℂ) • x) hx1 ha1 + rw [map_smul,norm_smul,hc] at hh + have ht := mul_le_mul_of_nonneg_left hh hr.le + simpa only [←mul_assoc,mul_inv_cancel₀ hr.ne',one_mul,mul_comm] using ht + +theorem exists_approx_comp (f : StrongDual ℂ E) (A : E →L[ℂ] F) + {ε δ : ℝ} (hε : 0<ε) (hδ : 0<δ) + (h : ∀ x : E,‖x‖≤1 → ‖A x‖≤δ → ‖f x‖≤ε) : + ∃ ψ : StrongDual ℂ F,‖f-ψ.comp A‖≤ε := by + let g : E →L[ℂ] E×F := ((ε:ℂ) • ContinuousLinearMap.id ℂ E).prod (((ε/δ:ℝ):ℂ) • A) + have hg (x : E) : g x=((ε:ℂ) • x,((ε/δ:ℝ):ℂ) • A x) := rfl + have hgnorm (x : E) : ‖g x‖=ε*max ‖x‖ (‖A x‖/δ) := by + rw [hg,Prod.norm_def] + simp only [norm_smul,Complex.norm_real,Real.norm_eq_abs, + abs_of_pos hε,abs_of_pos (div_pos hε hδ)] + rw [mul_max_of_nonneg _ _ hε.le] + congr 1 + ring + have hgi : Function.Injective g := by + intro x y hxy + have hh : (ε:ℂ) • x=(ε:ℂ) • y := congrArg Prod.fst hxy + exact (smul_right_injective E (by exact_mod_cast hε.ne')) hh + let e := LinearEquiv.ofInjective g.toLinearMap hgi + have heb (y : g.toLinearMap.range) : ‖f (e.symm y)‖≤‖y‖ := by + have hh := scaled_test_bound f A hε hδ h (e.symm y) + rw [←hgnorm] at hh + have he : g (e.symm y)=(y:E×F) := LinearEquiv.ofInjective_symm_apply g.toLinearMap y + rw [he] at hh + exact hh + let l : StrongDual ℂ g.toLinearMap.range := + (f.toLinearMap.comp e.symm.toLinearMap).mkContinuous 1 (by + intro y + change ‖f (e.symm y)‖≤1*‖y‖ + simpa only [one_mul] using heb y) + have hln : ‖l‖≤1 := LinearMap.mkContinuous_norm_le _ zero_le_one _ + obtain ⟨G,hGe,hGn⟩ := exists_extension_norm_eq g.toLinearMap.range l + have hG : ‖G‖≤1 := hGn.trans_le hln + have hGg (x : E) : G (g x)=f x := by + have hh := hGe (e x) + change G (g x)=f (e.symm (e x)) at hh + simpa only [LinearEquiv.symm_apply_apply] using hh + let ψ : StrongDual ℂ F := G.comp (((ε/δ:ℝ):ℂ) • ContinuousLinearMap.inr ℂ E F) + refine ⟨ψ,?_⟩ + apply (f-ψ.comp A).opNorm_le_bound hε.le + intro x + have he : (f-ψ.comp A) x=G ((ε:ℂ) • x,0) := by + change f x-G (((ε/δ:ℝ):ℂ) • ((0:E),A x))=_ + rw [Prod.smul_mk,smul_zero] + rw [←hGg x,hg,←map_sub] + congr 1 + simp + rw [he] + calc + _ ≤ ‖G‖*‖((ε:ℂ) • x,(0:F))‖ := G.le_opNorm _ + _ ≤ 1*‖((ε:ℂ) • x,(0:F))‖ := mul_le_mul_of_nonneg_right hG (norm_nonneg _) + _ = ε*‖x‖ := by + simp [Prod.norm_def,norm_smul,abs_of_pos hε,mul_nonneg hε.le (norm_nonneg x)] + +end Kadison.FiniteTestHahnBanach + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteTestPatching.lean b/lean/OAI/Analysis/Commutator/FiniteTestPatching.lean new file mode 100644 index 0000000000000000000000000000000000000000..89092581967de728f546442803a2f29bd23ae05c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteTestPatching.lean @@ -0,0 +1,739 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.FiniteTest + +section Signs + +variable {I : Type*} [DecidableEq I] + +def sign (b : Bool) : ℝ := if b then -1 else 1 + +@[simp] lemma sign_not (b : Bool) : sign (!b) = -sign b := by cases b <;> simp [sign] + +@[simp] lemma sign_sq (b : Bool) : sign b * sign b = 1 := by cases b <;> norm_num [sign] + +def flip (i : I) (σ : I → Bool) : I → Bool := Function.update σ i (!(σ i)) + +lemma flip_involutive (i : I) : Function.Involutive (flip i) := by + intro σ + funext j + by_cases h : j = i + · subst j; simp [flip] + · simp [flip, h] + +def flipEquiv (i : I) : (I → Bool) ≃ (I → Bool) := (flip_involutive i).toPerm + +def character (s : Finset I) (σ : I → Bool) : ℝ := ∏ i ∈ s, sign (σ i) + +omit [DecidableEq I] in +@[simp] lemma character_empty (σ : I → Bool) : character ∅ σ = 1 := by simp [character] + +omit [DecidableEq I] in +lemma character_sq (s : Finset I) (σ : I → Bool) : character s σ * character s σ = 1 := by + rw [character, ← Finset.prod_mul_distrib] + simp + +lemma character_flip (s : Finset I) (i : I) (σ : I → Bool) : + character s (flip i σ) = (if i ∈ s then -1 else 1) * character s σ := by + have hfun : (fun j => sign (flip i σ j)) = Function.update (fun j => sign (σ j)) i (-sign (σ i)) := by + funext j + by_cases h : j = i + · subst j; simp [flip] + · simp [flip, h] + rw [character, hfun] + by_cases hi : i ∈ s + · rw [Finset.prod_update_of_mem hi] + rw [ite_eq_left hi] + have hprod := Finset.mul_prod_erase s (fun j => sign (σ j)) hi + simp only [Finset.sdiff_singleton_eq_erase] + simpa only [character, neg_mul, neg_one_mul, one_mul] using congrArg Neg.neg hprod + · rw [Finset.prod_update_of_notMem hi, ite_eq_right hi, one_mul] + rfl + +variable [Fintype I] + +lemma character_sum_zero (s : Finset I) (hs : s.Nonempty) : + ∑ σ : I → Bool, character s σ = 0 := by + obtain ⟨i, hi⟩ := hs + have h := (flipEquiv i).sum_comp (character s) + simp only [flipEquiv, Function.Involutive.coe_toPerm, character_flip, ite_eq_left hi, + neg_one_mul, Finset.sum_neg_distrib] at h + linarith + +lemma different_character_sum (s t : Finset I) (hst : s ≠ t) : + ∑ σ : I → Bool, character s σ * character t σ = 0 := by + have hex : ∃ i, (i ∈ s ∧ i ∉ t) ∨ (i ∉ s ∧ i ∈ t) := by + by_contra! h + apply hst + ext i + specialize h i + tauto + obtain ⟨i, hi⟩ := hex + have h := (flipEquiv i).sum_comp (fun σ => character s σ * character t σ) + simp only [flipEquiv, Function.Involutive.coe_toPerm, character_flip] at h + rcases hi with hi | hi + · simp only [ite_eq_left hi.1, ite_eq_right hi.2, one_mul, neg_mul, + Finset.sum_neg_distrib] at h + linarith + · simp only [ite_eq_right hi.1, ite_eq_left hi.2, neg_one_mul, one_mul, mul_neg, + Finset.sum_neg_distrib] at h + linarith + +lemma character_gram (s t : Finset I) : + ∑ σ : I → Bool, character s σ * character t σ = + if s = t then (Fintype.card (I → Bool) : ℝ) else 0 := by + by_cases h : s = t + · subst t + simp [character_sq] + · rw [ite_eq_right h] + exact different_character_sum s t h + +end Signs + +section Hilbert + +variable {I J H : Type*} [Fintype I] [DecidableEq I] [Fintype J] + [NormedAddCommGroup H] [InnerProductSpace ℝ H] + +lemma sign_parseval (f : J → Finset I) (hf : Function.Injective f) (x : J → H) : + (∑ σ : I → Bool, ‖∑ j, character (f j) σ • x j‖ ^ 2) = + (Fintype.card (I → Bool) : ℝ) * ∑ j, ‖x j‖ ^ 2 := by + classical + have he (σ : I → Bool) : ‖∑ j, character (f j) σ • x j‖ ^ 2 = + ∑ j, ∑ k, (character (f j) σ * character (f k) σ) * inner ℝ (x j) (x k) := by + rw [← real_inner_self_eq_norm_sq] + simp only [sum_inner, inner_sum, real_inner_smul_left, real_inner_smul_right] + simp only [mul_assoc] + apply Finset.sum_congr rfl + intro j hj + apply Finset.sum_congr rfl + intro k hk + rw [real_inner_comm (x k) (x j)] + simp_rw [he] + calc + (∑ σ : I → Bool, ∑ j, ∑ k, + (character (f j) σ * character (f k) σ) * inner ℝ (x j) (x k)) = + ∑ j, ∑ k, (∑ σ : I → Bool, character (f j) σ * character (f k) σ) * + inner ℝ (x j) (x k) := by + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro j hj + rw [Finset.sum_comm] + simp only [Finset.sum_mul] + _ = _ := by simp [character_gram, hf.eq_iff, Finset.mul_sum] + +end Hilbert + +section UpperTriangle + +variable {I : Type*} [Fintype I] [LinearOrder I] + +abbrev Upper := {p : I × I // p.1 < p.2} + +def label : Option (Upper (I := I)) → Finset I + | none => ∅ + | some p => {p.val.1, p.val.2} + +omit [Fintype I] in +lemma label_injective : Function.Injective (label (I := I)) := by + intro a b hab + cases a with + | none => + cases b with + | none => rfl + | some b => + have hb : b.val.1 ∈ label (some b) := by simp [label] + rw [← hab] at hb + simp [label] at hb + | some a => + cases b with + | none => + have ha : a.val.1 ∈ label (some a) := by simp [label] + rw [hab] at ha + simp [label] at ha + | some b => + have h₁ : a.val.1 = b.val.1 ∨ a.val.1 = b.val.2 := by + have ha : a.val.1 ∈ label (some a) := by simp [label] + rw [hab] at ha + simpa [label] using ha + have h₂ : b.val.1 = a.val.1 ∨ b.val.1 = a.val.2 := by + have hb : b.val.1 ∈ label (some b) := by simp [label] + rw [← hab] at hb + simpa [label] using hb + have he₁ : a.val.1 = b.val.1 := by + rcases h₁ with h₁ | h₁ + · exact h₁ + rcases h₂ with h₂ | h₂ + · exact h₂.symm + · have ha := a.property + have hb := b.property + rw [h₁, ← h₂] at ha + exact (lt_asymm ha hb).elim + have he₂ : a.val.2 = b.val.2 := by + have ha : a.val.2 ∈ label (some a) := by simp [label] + rw [hab] at ha + have hh : a.val.2 = b.val.1 ∨ a.val.2 = b.val.2 := by simpa [label] using ha + rcases hh with hh | hh + · exact ((ne_of_gt a.property) (hh.trans he₁.symm)).elim + · exact hh + congr 1 + exact Subtype.ext (Prod.ext he₁ he₂) + +variable {V : Type*} [AddCommMonoid V] + +lemma sum_upper (f : I × I → V) : + (∑ p : Upper (I := I), f p.val) = ∑ i, ∑ j, if i < j then f (i,j) else 0 := by + rw [← Finset.sum_subtype (Finset.univ.filter (fun p : I × I => p.1 < p.2)) + (by simp) f, Finset.sum_filter, Fintype.sum_prod_type] + +lemma sum_matrix_split (x : I → I → V) : + (∑ i, ∑ j, x i j) = (∑ i, x i i) + + ∑ p : Upper (I := I), (x p.val.1 p.val.2 + x p.val.2 p.val.1) := by + have he (i j : I) : x i j = (if i = j then x i j else 0) + + (if i < j then x i j else 0) + (if j < i then x i j else 0) := by + rcases lt_trichotomy i j with h | h | h + · simp [h, ne_of_lt h, not_lt_of_ge h.le] + · subst j; simp + · simp [h, ne_of_gt h, not_lt_of_ge h.le] + calc + (∑ i, ∑ j, x i j) = (∑ i, x i i) + + (∑ i, ∑ j, if i < j then x i j else 0) + + (∑ i, ∑ j, if j < i then x i j else 0) := by + conv_lhs => arg 2; ext i; arg 2; ext j; rw [he i j] + simp only [Finset.sum_add_distrib] + simp + _ = _ := by + rw [sum_upper (fun p : I × I => x p.1 p.2 + x p.2 p.1)] + rw [Finset.sum_comm (f := fun i j => if j < i then x i j else 0)] + have hh (i j : I) : (if i < j then x i j + x j i else 0) = + (if i < j then x i j else 0) + (if i < j then x j i else 0) := by + split_ifs <;> simp + simp_rw [hh] + simp only [Finset.sum_add_distrib, add_assoc] + +end UpperTriangle + +section MatrixSigns + +variable {I H : Type*} [Fintype I] [LinearOrder I] + [NormedAddCommGroup H] [InnerProductSpace ℝ H] + +def matrixSignSum (x : I → I → H) (σ : I → Bool) : H := + ∑ i, ∑ j, (sign (σ i) * sign (σ j)) • x i j + +def matrixCoefficient (x : I → I → H) : Option (Upper (I := I)) → H + | none => ∑ i, x i i + | some p => x p.val.1 p.val.2 + x p.val.2 p.val.1 + +lemma matrixSignSum_eq (x : I → I → H) (σ : I → Bool) : + matrixSignSum x σ = + ∑ p : Option (Upper (I := I)), character (label p) σ • matrixCoefficient x p := by + rw [Fintype.sum_option, matrixSignSum, sum_matrix_split] + simp only [label, character_empty, matrixCoefficient, one_smul, sign_sq] + congr 1 + apply Finset.sum_congr rfl + intro p hp + have hne : p.val.1 ≠ p.val.2 := ne_of_lt p.property + simp [character, hne, smul_add, mul_comm] + +omit [InnerProductSpace ℝ H] in +lemma norm_add_sq_bound (a b : H) : ‖a+b‖^2 ≤ 2*(‖a‖^2+‖b‖^2) := by + have h := norm_add_le a b + nlinarith [norm_nonneg (a+b), norm_nonneg a, norm_nonneg b, sq_nonneg (‖a‖-‖b‖)] + +omit [InnerProductSpace ℝ H] in +lemma upper_norm_sum_bound (x : I → I → H) : + (∑ p : Upper (I := I), ‖x p.val.1 p.val.2 + x p.val.2 p.val.1‖^2) ≤ + 2 * ∑ i, ∑ j, ‖x i j‖^2 := by + calc + _ ≤ ∑ p : Upper (I := I), 2*(‖x p.val.1 p.val.2‖^2+‖x p.val.2 p.val.1‖^2) := + Finset.sum_le_sum (fun _ _ => norm_add_sq_bound _ _) + _ = 2 * ∑ p : Upper (I := I), (‖x p.val.1 p.val.2‖^2+‖x p.val.2 p.val.1‖^2) := + (Finset.mul_sum ..).symm + _ ≤ _ := by + rw [sum_matrix_split (fun i j => ‖x i j‖^2)] + have h : 0 ≤ ∑ i, ‖x i i‖^2 := Finset.sum_nonneg (fun _ _ => sq_nonneg _) + linarith + +theorem exists_matrix_sign_bound (x : I → I → H) : + ∃ σ : I → Bool, ‖matrixSignSum x σ‖^2 ≤ + ‖∑ i, x i i‖^2 + 2 * ∑ i, ∑ j, ‖x i j‖^2 := by + let B := ‖∑ i, x i i‖^2 + 2 * ∑ i, ∑ j, ‖x i j‖^2 + have he := sign_parseval (label (I := I)) label_injective (matrixCoefficient x) + simp_rw [← matrixSignSum_eq] at he + rw [Fintype.sum_option] at he + simp only [matrixCoefficient] at he + have hle : (∑ σ : I → Bool, ‖matrixSignSum x σ‖^2) ≤ ∑ _σ : I → Bool, B := by + rw [he, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] + exact mul_le_mul_of_nonneg_left + (add_le_add le_rfl (upper_norm_sum_bound x)) (Nat.cast_nonneg _) + obtain ⟨σ, _, hσ⟩ := Finset.exists_le_of_sum_le Finset.univ_nonempty hle + exact ⟨σ, hσ⟩ + +end MatrixSigns + +section MatrixAlgebra + +open Matrix + +variable {A I : Type*} [CStarAlgebra A] [Fintype I] [DecidableEq I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +def unit (i j : I) : A := φ (single i j 1) + +@[simp] lemma unit_star (i j : I) : star (unit φ i j) = unit φ j i := by + simp [unit, ← map_star, Matrix.star_eq_conjTranspose] + +@[simp] lemma unit_mul (i j k l : I) : + unit φ i j * unit φ k l = if j = k then unit φ i l else 0 := by + by_cases h : j = k + · subst k; simp [unit, ← map_mul] + · simp [unit, ← map_mul, h] + +@[simp] lemma unit_sum : ∑ i, unit φ i i = 1 := by + simp only [unit, ← map_sum, Matrix.sum_single_one, map_one] + +def column (i₀ : I) (σ : I → Bool) : A := ∑ i, sign (σ i) • unit φ i i₀ + +lemma star_column (i₀ : I) (σ : I → Bool) : + star (column φ i₀ σ) = ∑ i, sign (σ i) • unit φ i₀ i := by + simp only [column, star_sum, star_smul, star_trivial, unit_star] + +lemma column_right (i₀ : I) (σ : I → Bool) : + column φ i₀ σ * unit φ i₀ i₀ = column φ i₀ σ := by + simp [column, Finset.sum_mul] + +lemma column_inner (i₀ : I) (σ : I → Bool) : + star (column φ i₀ σ) * column φ i₀ σ = (Fintype.card I : ℝ) • unit φ i₀ i₀ := by + rw [star_column, column, Finset.sum_mul] + simp only [Finset.mul_sum, smul_mul_assoc, mul_smul_comm, unit_mul] + have hs (i : I) : + (∑ j, sign (σ j) • sign (σ i) • (if i = j then unit φ i₀ i₀ else 0)) = + unit φ i₀ i₀ := by + rw [Finset.sum_eq_single i] + · rw [ite_eq_left rfl, smul_smul, sign_sq, one_smul] + · intro j hj hji + simp [Ne.symm hji] + · simp + simp only [hs, Finset.sum_const, Finset.card_univ] + exact (Nat.cast_smul_eq_nsmul ℝ ..).symm + +lemma column_sandwich (i₀ : I) (σ : I → Bool) (x : A) : + star (column φ i₀ σ) * x * column φ i₀ σ = + ∑ i, ∑ j, (sign (σ i) * sign (σ j)) • (unit φ i₀ i * x * unit φ j i₀) := by + rw [star_column, column] + simp only [Finset.sum_mul, Finset.mul_sum, smul_mul_assoc, mul_smul_comm, + Finset.smul_sum, smul_smul] + rw [Finset.sum_comm] + congr 1 + ext i + congr 1 + ext j + rw [mul_comm] + +def traceSquare (τ : A →ₗ[ℝ] ℝ) (x : A) : ℝ := τ (star x * x) + +lemma traceSquare_smul (τ : A →ₗ[ℝ] ℝ) (r : ℝ) (x : A) : + traceSquare τ (r • x) = r^2 * traceSquare τ x := by + simp [traceSquare, star_smul, smul_smul, pow_two, + mul_assoc] + +variable (τ : A →ₗ[ℝ] ℝ) (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) + +include hτ in +lemma trace_rotate (a b c : A) : τ (a*b*c) = τ (b*c*a) := by + rw [mul_assoc, hτ] + +include hτ in +lemma unit_trace_eq (i j : I) : τ (unit φ i i) = τ (unit φ j j) := by + simpa only [unit_mul, ite_true] using hτ (unit φ i j) (unit φ j i) + +include hτ in +lemma unit_trace (h1 : τ 1 = 1) (i : I) : τ (unit φ i i) = (Fintype.card I : ℝ)⁻¹ := by + have : Nonempty I := ⟨i⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have he : (Fintype.card I : ℝ) * τ (unit φ i i) = 1 := by + calc + _ = ∑ j, τ (unit φ j j) := by + simp only [← unit_trace_eq φ τ hτ i, Finset.sum_const, Finset.card_univ, + nsmul_eq_mul] + _ = τ 1 := by rw [← map_sum, unit_sum] + _ = 1 := h1 + apply mul_left_cancel₀ hc + rw [he, mul_inv_cancel₀ hc] + +def signProjection (i₀ : I) (σ : I → Bool) : A := + (Fintype.card I : ℝ)⁻¹ • (column φ i₀ σ * star (column φ i₀ σ)) + +lemma signProjection_star (i₀ : I) (σ : I → Bool) : + star (signProjection φ i₀ σ) = signProjection φ i₀ σ := by + simp [signProjection] + +lemma signProjection_idem (i₀ : I) (σ : I → Bool) : + signProjection φ i₀ σ * signProjection φ i₀ σ = signProjection φ i₀ σ := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have he : (column φ i₀ σ * star (column φ i₀ σ)) * + (column φ i₀ σ * star (column φ i₀ σ)) = + (Fintype.card I : ℝ) • (column φ i₀ σ * star (column φ i₀ σ)) := by + rw [mul_assoc, ← mul_assoc (star _), column_inner, smul_mul_assoc, + mul_smul_comm, ← mul_assoc, column_right] + simp only [signProjection, smul_mul_assoc, mul_smul_comm, he, smul_smul] + congr 1 + field_simp + +lemma isStarProjection_signProjection (i₀ : I) (σ : I → Bool) : + IsStarProjection (signProjection φ i₀ σ) := + ⟨signProjection_idem φ i₀ σ, signProjection_star φ i₀ σ⟩ + +include hτ in +lemma signProjection_trace (h1 : τ 1 = 1) (i₀ : I) (σ : I → Bool) : + τ (signProjection φ i₀ σ) = (Fintype.card I : ℝ)⁻¹ := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + rw [signProjection, map_smul, smul_eq_mul, hτ, column_inner, map_smul, + smul_eq_mul, unit_trace φ τ hτ h1] + field_simp + +include hτ in +lemma block_traceSquare (i₀ i j : I) (x : A) : + traceSquare τ (unit φ i₀ i * x * unit φ j i₀) = + τ (star x * unit φ i i * x * unit φ j j) := by + have he : star (unit φ i₀ i * x * unit φ j i₀) * + (unit φ i₀ i * x * unit φ j i₀) = + unit φ i₀ j * (star x * unit φ i i * x * unit φ j i₀) := by + simp only [star_mul, unit_star, mul_assoc] + rw [← mul_assoc (unit φ i i₀), unit_mul, ite_eq_left rfl] + rw [traceSquare, he, hτ, mul_assoc (star x * unit φ i i * x), unit_mul, ite_eq_left rfl] + +include hτ in +lemma sum_block_traceSquare (i₀ : I) (x : A) : + (∑ i, ∑ j, traceSquare τ (unit φ i₀ i * x * unit φ j i₀)) = traceSquare τ x := by + simp_rw [block_traceSquare φ τ hτ] + simp only [← map_sum, ← Finset.mul_sum, unit_sum, mul_one] + rw [← Finset.sum_mul, ← Finset.mul_sum, unit_sum, mul_one] + rfl + +lemma column_left_star (i₀ : I) (σ : I → Bool) : + unit φ i₀ i₀ * star (column φ i₀ σ) = star (column φ i₀ σ) := by + simpa only [star_mul, unit_star] using congrArg star (column_right φ i₀ σ) + +lemma column_compression_left (i₀ : I) (σ : I → Bool) (x : A) : + unit φ i₀ i₀ * (star (column φ i₀ σ) * x * column φ i₀ σ) = + star (column φ i₀ σ) * x * column φ i₀ σ := by + rw [← mul_assoc, ← mul_assoc, column_left_star] + +lemma column_compression_right (i₀ : I) (σ : I → Bool) (x : A) : + (star (column φ i₀ σ) * x * column φ i₀ σ) * unit φ i₀ i₀ = + star (column φ i₀ σ) * x * column φ i₀ σ := by + rw [mul_assoc _ (column _ _ _), column_right] + +include hτ in +lemma column_outer_traceSquare (i₀ : I) (σ : I → Bool) (z : A) + (hzl : unit φ i₀ i₀ * z = z) (hzr : z * unit φ i₀ i₀ = z) : + traceSquare τ (column φ i₀ σ * z * star (column φ i₀ σ)) = + (Fintype.card I : ℝ)^2 * traceSquare τ z := by + have he : star (column φ i₀ σ * z * star (column φ i₀ σ)) * + (column φ i₀ σ * z * star (column φ i₀ σ)) = + (Fintype.card I : ℝ) • + (column φ i₀ σ * (star z * z) * star (column φ i₀ σ)) := by + simp only [star_mul, star_star, mul_assoc] + rw [← mul_assoc (star (column φ i₀ σ)), column_inner, smul_mul_assoc, + ← mul_assoc (unit φ i₀ i₀), hzl, mul_smul_comm, mul_smul_comm] + rw [traceSquare, he, map_smul, smul_eq_mul, + trace_rotate τ hτ, mul_assoc, column_inner, mul_smul_comm, map_smul, + smul_eq_mul, mul_assoc (star z), hzr, traceSquare, pow_two] + ring + +include hτ in +lemma signProjection_compression_traceSquare (i₀ : I) (σ : I → Bool) (x : A) : + traceSquare τ (signProjection φ i₀ σ * x * signProjection φ i₀ σ) = + (Fintype.card I : ℝ)⁻¹^2 * + traceSquare τ (star (column φ i₀ σ) * x * column φ i₀ σ) := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have he : signProjection φ i₀ σ * x * signProjection φ i₀ σ = + (Fintype.card I : ℝ)⁻¹^2 • + (column φ i₀ σ * (star (column φ i₀ σ) * x * column φ i₀ σ) * + star (column φ i₀ σ)) := by + simp only [signProjection, smul_mul_assoc, mul_smul_comm, smul_smul, + pow_two, mul_assoc] + rw [he, traceSquare_smul, column_outer_traceSquare φ τ hτ _ _ _ + (column_compression_left φ i₀ σ x) (column_compression_right φ i₀ σ x)] + field_simp + +def expectation (x : A) : A := + (Fintype.card I : ℝ)⁻¹ • ∑ i, ∑ j, unit φ i j * x * unit φ j i + +lemma expectation_left (x : A) (k l : I) : + unit φ k l * expectation φ x = + (Fintype.card I : ℝ)⁻¹ • ∑ j, unit φ k j * x * unit φ j l := by + rw [expectation, mul_smul_comm, Finset.mul_sum] + simp only [Finset.mul_sum, ← mul_assoc, unit_mul] + rw [Finset.sum_eq_single l] + · simp only [ite_true] + · intro i hi hil + simp [Ne.symm hil] + · simp + +lemma expectation_right (x : A) (k l : I) : + expectation φ x * unit φ k l = + (Fintype.card I : ℝ)⁻¹ • ∑ j, unit φ k j * x * unit φ j l := by + rw [expectation, smul_mul_assoc, Finset.sum_mul] + simp only [Finset.sum_mul, mul_assoc, unit_mul] + rw [Finset.sum_eq_single k] + · simp only [ite_true, ← mul_assoc] + · intro i hi hik + simp [hik] + · simp + +lemma expectation_commutes (x : A) (k l : I) : + unit φ k l * expectation φ x = expectation φ x * unit φ k l := by + rw [expectation_left, expectation_right] + +lemma expectation_star (x : A) : star (expectation φ x) = expectation φ (star x) := by + simp only [expectation, star_smul, star_trivial, + star_sum, star_mul, unit_star, mul_assoc] + +include hτ in +lemma unit_mul_trace (w : A) (hw : ∀ i j, unit φ i j * w = w * unit φ i j) (i₀ : I) : + τ (unit φ i₀ i₀ * w) = (Fintype.card I : ℝ)⁻¹ * τ w := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have he (i j : I) : τ (unit φ i i * w) = τ (unit φ j j * w) := by + have h := hτ (unit φ i j) (unit φ j i * w) + rw [← mul_assoc, unit_mul, ite_eq_left rfl, mul_assoc, ← hw, + ← mul_assoc, unit_mul, ite_eq_left rfl] at h + exact h + have hs : (Fintype.card I : ℝ) * τ (unit φ i₀ i₀ * w) = τ w := by + calc + _ = ∑ i, τ (unit φ i i * w) := by + simp only [← he i₀, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] + _ = τ ((∑ i, unit φ i i) * w) := by rw [Finset.sum_mul, map_sum] + _ = τ w := by rw [unit_sum, one_mul] + apply mul_left_cancel₀ hc + rw [hs, ← mul_assoc, mul_inv_cancel₀ hc, one_mul] + +lemma expectation_star_commutes (x : A) (i j : I) : + unit φ i j * star (expectation φ x) = star (expectation φ x) * unit φ i j := by + rw [expectation_star] + exact expectation_commutes φ (star x) i j + +include hτ in +lemma diagonal_traceSquare (i₀ : I) (x : A) : + traceSquare τ (∑ i, unit φ i₀ i * x * unit φ i i₀) = + (Fintype.card I : ℝ) * traceSquare τ (expectation φ x) := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have he : (∑ i, unit φ i₀ i * x * unit φ i i₀) = + (Fintype.card I : ℝ) • (unit φ i₀ i₀ * expectation φ x) := by + rw [expectation_left, smul_smul, mul_inv_cancel₀ hc, one_smul] + have hw : ∀ i j, unit φ i j * (star (expectation φ x) * expectation φ x) = + (star (expectation φ x) * expectation φ x) * unit φ i j := by + intro i j + rw [← mul_assoc, expectation_star_commutes, mul_assoc, expectation_commutes, + ← mul_assoc] + have ht : traceSquare τ (unit φ i₀ i₀ * expectation φ x) = + (Fintype.card I : ℝ)⁻¹ * traceSquare τ (expectation φ x) := by + rw [traceSquare, star_mul, unit_star, mul_assoc, + ← mul_assoc (unit φ i₀ i₀), unit_mul, ite_eq_left rfl, + ← mul_assoc, ← expectation_star_commutes, mul_assoc, unit_mul_trace φ τ hτ _ hw] + rfl + rw [he, traceSquare_smul, ht] + field_simp + +end MatrixAlgebra + +section CompressionBound + +open Matrix + +variable {A I H : Type*} [CStarAlgebra A] [Fintype I] [LinearOrder I] + [NormedAddCommGroup H] [InnerProductSpace ℝ H] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (τ : A →ₗ[ℝ] ℝ) + (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) + (v : A →ₗ[ℝ] H) (hv : ∀ a, ‖v a‖^2 = traceSquare τ a) + +lemma matrixSignSum_vector (i₀ : I) (x : A) (σ : I → Bool) : + matrixSignSum (fun i j => v (unit φ i₀ i * x * unit φ j i₀)) σ = + v (star (column φ i₀ σ) * x * column φ i₀ σ) := by + rw [column_sandwich] + simp only [matrixSignSum, map_sum, map_smul] + +include hτ hv in +theorem exists_signProjection_bound (i₀ : I) (x : A) : + ∃ σ : I → Bool, + traceSquare τ (signProjection φ i₀ σ * x * signProjection φ i₀ σ) ≤ + (Fintype.card I : ℝ)⁻¹ * traceSquare τ (expectation φ x) + + 2 * (Fintype.card I : ℝ)⁻¹^2 * traceSquare τ x := by + have : Nonempty I := ⟨i₀⟩ + have hc : (Fintype.card I : ℝ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + obtain ⟨σ, hσ⟩ := exists_matrix_sign_bound + (fun i j => v (unit φ i₀ i * x * unit φ j i₀)) + rw [matrixSignSum_vector, ← map_sum, hv, hv, diagonal_traceSquare φ τ hτ] at hσ + simp_rw [hv] at hσ + rw [sum_block_traceSquare φ τ hτ] at hσ + refine ⟨σ, ?_⟩ + rw [signProjection_compression_traceSquare φ τ hτ] + calc + _ ≤ (Fintype.card I : ℝ)⁻¹^2 * + ((Fintype.card I : ℝ) * traceSquare τ (expectation φ x) + 2 * traceSquare τ x) := + mul_le_mul_of_nonneg_left hσ (sq_nonneg _) + _ = _ := by field_simp + +end CompressionBound + +section FiniteFamily + +open Matrix + +variable {A I J H : Type*} [CStarAlgebra A] [Fintype I] [LinearOrder I] + [Fintype J] [NormedAddCommGroup H] [InnerProductSpace ℝ H] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (τ : A →ₗ[ℝ] ℝ) + (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) + (v : A →ₗ[ℝ] H) (hv : ∀ a, ‖v a‖^2 = traceSquare τ a) + +def familyVector : (J → A) →ₗ[ℝ] PiLp 2 (fun _ : J => H) := + (WithLp.linearEquiv 2 ℝ (J → H)).symm.toLinearMap.comp + (LinearMap.pi (fun j => v.comp (LinearMap.proj j))) + +omit [Fintype J] in +@[simp] lemma familyVector_apply (x : J → A) (j : J) : + (familyVector v x).ofLp j = v (x j) := rfl + +def familyTrace : (J → A) →ₗ[ℝ] ℝ := ∑ j, τ.comp (LinearMap.proj j) + +@[simp] lemma familyTrace_apply (x : J → A) : familyTrace τ x = ∑ j, τ (x j) := by + simp [familyTrace] + +include hτ in +lemma familyTrace_tracial (x y : J → A) : + familyTrace τ (x*y) = familyTrace τ (y*x) := by + simp only [familyTrace_apply, Pi.mul_apply, hτ] + +include hv in +lemma familyVector_norm_sq (x : J → A) : + ‖familyVector v x‖^2 = traceSquare (familyTrace τ) x := by + rw [PiLp.norm_sq_eq_of_L2] + simp only [familyVector_apply, hv, traceSquare, familyTrace_apply, + Pi.mul_apply, Pi.star_apply] + +def familyHom : Matrix I I ℂ →⋆ₐ[ℂ] (J → A) := + ({ Pi.constAlgHom ℂ J A with map_star' := fun _ => rfl } : A →⋆ₐ[ℂ] (J → A)).comp φ + +omit [Fintype J] in +@[simp] lemma familyHom_apply (a : Matrix I I ℂ) (j : J) : familyHom φ a j = φ a := rfl + +@[simp] lemma unit_family (i j : I) (t : J) : unit (familyHom (J := J) φ) i j t = unit φ i j := rfl + +@[simp] lemma column_family (i₀ : I) (σ : I → Bool) (t : J) : + column (familyHom (J := J) φ) i₀ σ t = column φ i₀ σ := by + simp [column] + +@[simp] lemma signProjection_family (i₀ : I) (σ : I → Bool) (t : J) : + signProjection (familyHom (J := J) φ) i₀ σ t = signProjection φ i₀ σ := by + simp only [signProjection, Pi.smul_apply, Pi.mul_apply, Pi.star_apply, column_family] + +@[simp] lemma expectation_family (x : J → A) (t : J) : + expectation (familyHom (J := J) φ) x t = expectation φ (x t) := by + simp only [expectation, Pi.smul_apply, Finset.sum_apply, Pi.mul_apply, unit_family] + +include hτ hv in +theorem exists_signProjection_family_bound (i₀ : I) (x : J → A) : + ∃ σ : I → Bool, + (∑ j, traceSquare τ (signProjection φ i₀ σ * x j * signProjection φ i₀ σ)) ≤ + (Fintype.card I : ℝ)⁻¹ * (∑ j, traceSquare τ (expectation φ (x j))) + + 2 * (Fintype.card I : ℝ)⁻¹^2 * ∑ j, traceSquare τ (x j) := by + obtain ⟨σ, hσ⟩ := exists_signProjection_bound (familyHom (J := J) φ) (familyTrace τ) + (familyTrace_tracial τ hτ) (familyVector v) (familyVector_norm_sq τ v hv) i₀ x + refine ⟨σ, ?_⟩ + simpa only [traceSquare, familyTrace_apply, Pi.mul_apply, Pi.star_apply, + signProjection_family, expectation_family] using hσ + +end FiniteFamily + +section ActualGNS + +open scoped ComplexOrder + +open UniformSpace + +variable {A I J : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype I] [LinearOrder I] [Fintype J] + +variable (τ : A →ₚ[ℂ] ℂ) + +def realTrace : A →ₗ[ℝ] ℝ := + Complex.reCLM.toLinearMap.comp (τ.toLinearMap.restrictScalars ℝ) + +omit [StarOrderedRing A] in +@[simp] lemma realTrace_apply (a : A) : realTrace τ a = (τ a).re := rfl + +def vector : A →ₗ[ℝ] τ.GNS := + ((Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS).toLinearMap.comp + τ.toPreGNS.toLinearMap).restrictScalars ℝ + +@[simp] lemma vector_apply (a : A) : vector τ a = (τ.toPreGNS a : τ.GNS) := rfl + +lemma vector_norm_sq (a : A) : ‖vector τ a‖^2 = traceSquare (realTrace τ) a := by + rw [InnerProductSpace.norm_sq_eq_re_inner (𝕜 := ℂ)] + simp only [vector_apply, Completion.inner_coe, PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS, traceSquare, realTrace_apply] + rfl + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma real_smul_mem_range (r : ℝ) {a : A} (ha : a ∈ φ.range) : r • a ∈ φ.range := by + obtain ⟨b, rfl⟩ := ha + exact ⟨r • b, φ.toLinearMap.map_smul_of_tower r b⟩ + +omit [PartialOrder A] [StarOrderedRing A] in +lemma signProjection_mem_range (i₀ : I) (σ : I → Bool) : + signProjection φ i₀ σ ∈ φ.range := by + have hu (i j : I) : unit φ i j ∈ φ.range := ⟨_, rfl⟩ + have hc : column φ i₀ σ ∈ φ.range := + Subalgebra.sum_mem _ (fun i _ => real_smul_mem_range φ _ (hu i i₀)) + have hcs : star (column φ i₀ σ) ∈ φ.range := φ.range.star_mem' hc + exact real_smul_mem_range φ _ (φ.range.mul_mem hc hcs) + +theorem exists_rankOne_finite_test (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) + (hone : τ 1 = 1) (i₀ : I) (x : J → A) : + ∃ q : A, q ∈ φ.range ∧ IsStarProjection q ∧ + (τ q).re = (Fintype.card I : ℝ)⁻¹ ∧ + (∑ j, ‖vector τ (q * x j * q)‖^2) ≤ + (Fintype.card I : ℝ)⁻¹ * (∑ j, ‖vector τ (expectation φ (x j))‖^2) + + 2 * (Fintype.card I : ℝ)⁻¹^2 * (∑ j, ‖vector τ (x j)‖^2) := by + let : InnerProductSpace ℝ τ.GNS := InnerProductSpace.complexToReal + have hr : ∀ a b : A, realTrace τ (a*b) = realTrace τ (b*a) := + fun a b => congrArg Complex.re (hτ a b) + obtain ⟨σ, hσ⟩ := exists_signProjection_family_bound φ (realTrace τ) hr + (vector τ) (vector_norm_sq τ) i₀ x + refine ⟨signProjection φ i₀ σ, signProjection_mem_range φ i₀ σ, + isStarProjection_signProjection φ i₀ σ, ?_, ?_⟩ + · exact signProjection_trace φ (realTrace τ) hr (by simp [hone]) i₀ σ + · simpa only [vector_norm_sq] using hσ + +end ActualGNS + +end Kadison.FiniteTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteTrace.lean b/lean/OAI/Analysis/Commutator/FiniteTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..670d695ae5013fd7133a6f4274ca6ba0b07869e2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteTrace.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FiniteFactorComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.FiniteTrace + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : (H →L[ℂ] H) →ₚ[ℂ] ℂ) + +def restrict : M →ₚ[ℂ] ℂ where + toLinearMap := τ.toLinearMap.comp M.toStarSubalgebra.subtype.toLinearMap + monotone' := fun _ _ h => τ.monotone h + +@[simp] lemma restrict_apply (a : M) : restrict M τ a=τ (a : H →L[ℂ] H) := rfl + +lemma projection_trace_pos + (hfaith : ∀ a∈M, τ (star a*a)=0 → a=0) + {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) (hpn : p≠0) : 0<(τ p).re := by + have hn := τ.map_nonneg hp.nonneg + apply lt_of_le_of_ne hn.1 + intro heq + have hz : τ p=0 := Complex.ext heq.symm hn.2.symm + apply hpn + apply hfaith p hpM + rwa [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + +lemma restrict_tracial (hτ : ∀ a∈M, ∀ b∈M, τ (a*b)=τ (b*a)) : + ∀ a b : M, restrict M τ (a*b)=restrict M τ (b*a) := + fun a b => hτ a a.property b b.property + +lemma restrict_faithful (hfaith : ∀ a∈M, τ (star a*a)=0 → a=0) : + ∀ a : M, restrict M τ (star a*a)=0 → a=0 := + fun a ha => Subtype.ext (hfaith a a.property ha) + +theorem noMinimal_of_small (hM : FactorCorner.IsFactor M) + (hτ : ∀ a∈M, ∀ b∈M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a∈M, τ (star a*a)=0 → a=0) + (hsmall : ∀ ε : ℝ, 0<ε → ∃ q∈M, IsStarProjection q ∧ q≠0 ∧ (τ q).re<ε) : + DiffuseProjection.HasNoMinimalProjections M := by + intro p hpM hp hpn + obtain ⟨q,hqM,hq,hqn,hqt⟩ := hsmall (τ p).re (projection_trace_pos M τ hfaith hpM hp hpn) + have hle : τ q≤τ p := ⟨hqt.le,(τ.map_nonneg hq.nonneg).2.symm.trans (τ.map_nonneg hp.nonneg).2⟩ + obtain ⟨v,hvi⟩ := PartialIsometryOrder.finite_factor_comparison M hM (restrict M τ) + (restrict_tracial M τ hτ) (restrict_faithful M τ hfaith) hqM hpM hq hp hle + have htrace : τ v.final=τ q := by + have h := (v.trace_initial_final (restrict M τ) (restrict_tracial M τ hτ)).symm + change τ v.final=τ v.initial at h + rwa [hvi] at h + have hpos : 0<(τ v.final).re := by rw [htrace]; exact projection_trace_pos M τ hfaith hqM hq hqn + refine ⟨v.final,v.final_mem,v.final_projection,?_,?_,v.target_le⟩ + · intro hz + rw [hz,map_zero] at hpos + exact (lt_irrefl (0 : ℝ)) hpos + · intro heq + rw [heq] at htrace + exact (ne_of_lt hqt) (congrArg Complex.re htrace.symm) + +end Kadison.FiniteTrace + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteVectorLpConvergence.lean b/lean/OAI/Analysis/Commutator/FiniteVectorLpConvergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..365d47bbf2e64ac2328d4d85aead0dc595a12430 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteVectorLpConvergence.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.Commutator.L2FiniteSum + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H ι : Type*} [MeasurableSpace Ω] (μ : Measure Ω) [Fintype ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +theorem exists_finite_test_subsequence (f : ℕ → ι → Lp H 2 μ) (g : ι → Lp H 2 μ) + (h : ∀ i,Tendsto (fun n => f n i) atTop (𝓝 (g i))) : + ∃ k : ℕ → ℕ,StrictMono k ∧ + ∀ᵐ a ∂μ,∀ i,Tendsto (fun n => f (k n) i a) atTop (𝓝 (g i a)) := by + let F : ℕ → PiLp 2 (fun _ : ι => Lp H 2 μ) := fun n => WithLp.toLp 2 (f n) + let G : PiLp 2 (fun _ : ι => Lp H 2 μ) := WithLp.toLp 2 g + have hFG : Tendsto F atTop (𝓝 G) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => Lp H 2 μ)).symm.continuous.tendsto g |>.comp + (tendsto_pi_nhds.mpr h) + have hL : Tendsto (fun n => assemble μ (F n)) atTop (𝓝 (assemble μ G)) := + (assembleIsometry μ).continuous.tendsto G |>.comp hFG + obtain ⟨k,hk,hka⟩ := (tendstoInMeasure_of_tendsto_Lp hL).exists_seq_tendsto_ae + refine ⟨k,hk,?_⟩ + filter_upwards [hka,assemble_ae μ G,ae_all_iff.mpr (fun n => assemble_ae μ (F n))] + with a hka hG hF + intro i + have he (n : ℕ) : assemble μ (F (k n)) a=WithLp.toLp 2 (fun i => f (k n) i a) := hF (k n) + simp only [he] at hka + rw [hG] at hka + exact (PiLp.proj 2 (fun _ : ι => H) i : PiLp 2 (fun _ : ι => H) →L[ℂ] H).continuous.tendsto _ |>.comp hka + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteWordMaximalPatching.lean b/lean/OAI/Analysis/Commutator/FiniteWordMaximalPatching.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb30489570de1c09ec120fff6d7924d329f08d0f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteWordMaximalPatching.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.Commutator.ExponentialMomentBudget +import OAI.Analysis.Commutator.FiniteWordPatchProducer +import OAI.Analysis.Commutator.PartialMomentBudget +import OAI.Analysis.Commutator.PartialUnitaryChain +import OAI.Analysis.Commutator.PartialWordContinuity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching + +open Words + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) + +variable (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +variable {J K : Type*} (x : J → M) (k : K → ℤ) + +def Admissible (N : ℕ) (ε η : ℝ) : Set (PartialUnitary M) := + {v | (v.val : H →L[ℂ] H)∈R ∧ (τ v.support).re ≤ 1-η ∧ + MomentBound τ x k v N (momentBudget ε (budgetSlope N η) (τ v.support).re)} + +lemma zero_admissible (hcenter : ∀ j,τ (x j)=0) (N : ℕ) {ε η : ℝ} + (hε : 0 ≤ ε) (hη : η ≤ 1) : PartialUnitary.zero∈Admissible M R τ x k N ε η := by + refine ⟨R.zero_mem,?_,zero_momentBound τ x k hcenter N (momentBudget_nonneg hε _ _)⟩ + change (τ 0).re ≤ 1-η + simp only [map_zero,Complex.zero_re] + linarith + +include hτ in +lemma admissible_chain_upper (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hone : τ 1=1) (hx : ∀ j,‖x j‖ ≤ 1) + (N : ℕ) (ε η : ℝ) (c : Set (PartialUnitary M)) + (hcs : c ⊆ Admissible M R τ x k N ε η) (hc : IsChain (·≤·) c) (hne : c.Nonempty) : + ∃ v∈Admissible M R τ x k N ε η,∀ w∈c,w ≤ v := by + obtain ⟨v,hv,hmem,ω,hω,htr,hl2⟩ := + PartialUnitary.chain_upper_with_L2_and_membership M τ hnormal c hc hne + have hl2' : Tendsto (fun w : c => TracialL2.norm τ (w.val.val-v.val)) (ω : Filter c) (𝓝 0) := by + apply hl2.congr' + exact Eventually.of_forall fun w => by + simp only [TracialL2.norm,map_sub,norm_sub_rev] + have hB : Tendsto (fun w : c => momentBudget ε (budgetSlope N η) (τ w.val.support).re) + (ω : Filter c) (𝓝 (momentBudget ε (budgetSlope N η) (τ v.support).re)) := by + exact ((Real.continuous_exp.tendsto _).comp (htr.const_mul (budgetSlope N η))).const_mul ε + refine ⟨v,⟨hmem R (fun w hw => (hcs hw).1),?_,?_⟩,hv⟩ + · exact le_of_tendsto_of_tendsto htr tendsto_const_nhds + (Eventually.of_forall fun w : c => (hcs w.property).2.1) + · exact momentBound_limit τ hτ x k hone hx (fun w : c => w.val) v _ _ N hl2' hB + (fun w => (hcs w.property).2.2) + +variable [Fintype J] [Fintype K] + +variable {ι : ℕ → Type*} [∀ n,Fintype (ι n)] [∀ n,LinearOrder (ι n)] + [∀ n,Nonempty (ι n)] + +variable (stage : ∀ n,Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range ≤ (stage m).range) + +include hτ hmono in +theorem exists_almost_full_finite_tests (hRM : R ≤ M) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (ι n) (ι n) ℂ),stage n a*b=b*stage n a) → + ∃ c : ℂ,b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) + (hx : ∀ j,‖x j‖ ≤ 1) (hcenter : ∀ j,τ (x j)=0) (hk : ∀ i,k i≠0) + (N : ℕ) {ε η : ℝ} (hε : 0<ε) (hη : 0<η) (hη1 : η ≤ 1) : + ∃ v : PartialUnitary M, (v.val : H →L[ℂ] H)∈R ∧ (τ v.support).re=1-η ∧ + MomentBound τ x k v N (momentBudget ε (budgetSlope N η) (1-η)) := by + have hzero := zero_admissible M R τ x k hcenter N hε.le hη1 + obtain ⟨v,hv⟩ := zorn_le₀ (Admissible M R τ x k N ε η) (by + intro c hcs hc + rcases c.eq_empty_or_nonempty with he | hne + · exact ⟨PartialUnitary.zero,hzero,fun w hw => (he ▸ hw : w∈(∅ : Set (PartialUnitary M))).elim⟩ + · exact admissible_chain_upper M R τ hτ x k hnormal hone hx N ε η c hcs hc hne) + have hcut : (τ v.support).re=1-η := by + apply le_antisymm hv.1.2.1 + by_contra hn + have hlt : (τ v.support).re<1-η := lt_of_not_ge hn + have hrest : η ≤ (τ (1-v.support)).re := by + rw [map_sub,hone,Complex.sub_re,Complex.one_re] + linarith [hv.1.2.1] + have hvR : (v.support : H →L[ℂ] H)∈R := by + rw [←v.star_mul] + exact R.mul_mem (R.star_mem' hv.1.1) hv.1.1 + obtain ⟨w,hwR,_,hqp,horth,hqt,hqsmall,hpure,hsmall,hphase⟩ := + exists_finite_word_patch M R hRM τ hτ stage hmono hnormal hfaith hone hirr hgrow hstage + hdiffuse x k hk v hvR (hη.trans_le hrest) N hε + (show 0<1-η-(τ v.support).re by linarith) + have hnew : v.add w horth∈Admissible M R τ x k N ε η := by + refine ⟨R.add_mem hv.1.1 hwR,?_,?_⟩ + · change (τ (v.support+w.support)).re ≤ 1-η + rw [map_add,Complex.add_re] + linarith + · exact momentBound_add τ hτ x k hx v w horth hqp hε.le hη hrest hv.1.2.2 + hpure hsmall hphase + have hp := (hv.2 hnew (v.le_add w horth)).1 + have htp := (τ.monotone hp).1 + change (τ (v.support+w.support)).re ≤ (τ v.support).re at htp + rw [map_add,Complex.add_re] at htp + linarith + exact ⟨v,hv.1.1,hcut,by simpa only [hcut] using hv.1.2.2⟩ + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteWordPatchProducer.lean b/lean/OAI/Analysis/Commutator/FiniteWordPatchProducer.lean new file mode 100644 index 0000000000000000000000000000000000000000..617ecc0244c9fd34aeac510fd152c353ad5ee1fa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteWordPatchProducer.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.BoundedWordPool +import OAI.Analysis.Commutator.CornerCenteredEstimates +import OAI.Analysis.Commutator.PartialUnitaryWords +import OAI.Analysis.Commutator.RelativeCornerPhase +import OAI.Analysis.Commutator.RelativeCornerQuantization + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching + +open Words + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R ≤ M) + +variable (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +variable {ι : ℕ → Type*} [∀ n,Fintype (ι n)] [∀ n,LinearOrder (ι n)] + [∀ n,Nonempty (ι n)] + +variable (stage : ∀ n,Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range ≤ (stage m).range) + +include hRM hτ hmono in +theorem exists_finite_word_patch {J K : Type*} [Fintype J] [Fintype K] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (ι n) (ι n) ℂ),stage n a*b=b*stage n a) → + ∃ c : ℂ,b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) + (x : J → M) (k : K → ℤ) (hk : ∀ i,k i≠0) + (v : PartialUnitary M) (hvR : (v.support : H →L[ℂ] H)∈R) + (hrest : 0<(τ (1-v.support)).re) (N : ℕ) {δ ζ : ℝ} (hδ : 0<δ) (hζ : 0<ζ) : + ∃ w : PartialUnitary M, (w.val : H →L[ℂ] H)∈R ∧ + (w.support : H →L[ℂ] H)∈R ∧ w.support ≤ 1-v.support ∧ + v.support*w.support=0 ∧ 0<(τ w.support).re ∧ (τ w.support).re<ζ ∧ + (∀ i,‖τ (w.power (k i))‖ ≤ δ*(τ w.support).re) ∧ + (∀ (s : List (Letter J K)) (j : J),s.length ≤ N → + TracialL2.norm τ (w.support*cornerCenter τ (1-v.support) + (word x k v s*x j)*w.support)^2 ≤ δ^2*(τ w.support).re) ∧ + (∀ (s t : List (Letter J K)) (j : J) (i : K),s.length ≤ N → t.length ≤ N → + ‖τ (w.power (k i)*(word x k v t*word x k v s*x j))‖ ≤ δ*(τ w.support).re) := by + classical + let L := SmallList (Letter J K) N + let c : L×J → M := fun a => cornerCenter τ (1-v.support) (word x k v a.1.val*x a.2) + have hpR : ((1-v.support:M) : H →L[ℂ] H)∈R := R.sub_mem R.one_mem hvR + obtain ⟨q,hqR,hq,hqp,hqt,hqζ,hsmall⟩ := + RelativeCornerQuantization.exists_relative_centered_compression M τ hτ stage hmono + hnormal hfaith hone hirr hgrow R hstage (1-v.support) hpR v.projection.one_sub hrest + c (fun a => cornerCenter_trace τ hτ v.projection.one_sub hrest _) + (fun a => cornerCenter_left τ v.projection.one_sub _) + (fun a => cornerCenter_right τ v.projection.one_sub _) hδ hζ + let a : Option (L×L×J)×K → M := fun i => match i.1 with + | none => 1 + | some t => word x k v t.2.1.val*word x k v t.1.val*x t.2.2 + obtain ⟨w,hwq,hphase,hwR⟩ := CornerPhase.exists_relative_signed_phase M R hRM τ hτ + hnormal hfaith hdiffuse q hq hqR hqt a (fun i => k i.2) (fun i => hk i.2) hδ + have horth : v.support*w.support=0 := by + rw [hwq] + have hh := (hq.le_iff_mul_eq_right v.projection.one_sub).mp hqp + rw [sub_mul,one_mul] at hh + exact sub_eq_self.mp hh + refine ⟨w,hwR,by simpa only [hwq] using hqR,by simpa only [hwq] using hqp, + horth,by simpa only [hwq] using hqt,by simpa only [hwq] using hqζ,?_,?_,?_⟩ + · intro i + have hh := (hphase (none,i)).le + simpa only [a,mul_one,hwq] using hh + · intro s j hs + have hh := (hsmall (smallList (Letter J K) s hs,j)).le + simpa only [c,smallList,hwq] using hh + · intro s t j i hs ht + have hh := (hphase (some (smallList (Letter J K) s hs,smallList (Letter J K) t ht,j),i)).le + simpa only [a,smallList,hwq] using hh + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FiniteWordTelescoping.lean b/lean/OAI/Analysis/Commutator/FiniteWordTelescoping.lean new file mode 100644 index 0000000000000000000000000000000000000000..a3f3075205c4b6a32bcc049589618d7fb8b43025 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FiniteWordTelescoping.lean @@ -0,0 +1,112 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.FinitePatching + +variable {A I : Type*} [NormedRing A] + +def wordProduct (a : I → A) (l : List I) : A := (l.map a).prod + +@[simp] lemma wordProduct_nil (a : I → A) : wordProduct a []=1 := rfl + +@[simp] lemma wordProduct_cons (a : I → A) (i : I) (l : List I) : + wordProduct a (i::l)=a i*wordProduct a l := rfl + +lemma wordProduct_append (a : I → A) (l r : List I) : + wordProduct a (l++r)=wordProduct a l*wordProduct a r := by + simp [wordProduct,List.map_append,List.prod_append] + +lemma wordProduct_norm [NormOneClass A] (a : I → A) (l : List I) + (ha : ∀ i∈l,‖a i‖ ≤ 1) : ‖wordProduct a l‖ ≤ 1 := by + induction l with + | nil => simp + | cons i l ih => + rw [wordProduct_cons] + exact (norm_mul_le _ _).trans + ((mul_le_mul (ha i (by simp)) (ih (fun j hj => ha j (by simp [hj]))) + (norm_nonneg _) (by norm_num)).trans_eq (one_mul (1:ℝ))) + +variable [NormedAlgebra ℂ A] + +lemma trace_word_difference_bound (τ : A →ₗ[ℂ] ℂ) (old new : I → A) + (l : List I) (a : A) {B : ℝ} (_hB : 0 ≤ B) + (h : ∀ s i t, l=s++i::t → + ‖τ (a*wordProduct old s*new i*wordProduct (fun j => old j+new j) t)‖ ≤ B) : + ‖τ (a*wordProduct (fun j => old j+new j) l)-τ (a*wordProduct old l)‖ ≤ + (l.length:ℝ)*B := by + induction l generalizing a with + | nil => simp + | cons i l ih => + have hi := h [] i l rfl + simp only [wordProduct_nil,mul_one] at hi + have ht := ih (a*old i) (by + intro s j t he + have hh := h (i::s) j t (by simp only [List.cons_append,he]) + simpa only [wordProduct_cons,mul_assoc] using hh) + have he : τ (a*wordProduct (fun j => old j+new j) (i::l))- + τ (a*wordProduct old (i::l))= + τ (a*new i*wordProduct (fun j => old j+new j) l)+ + (τ ((a*old i)*wordProduct (fun j => old j+new j) l)- + τ ((a*old i)*wordProduct old l)) := by + simp only [wordProduct_cons,←mul_assoc,add_mul,mul_add,map_add] + ring + rw [he] + calc + _ ≤ ‖τ (a*new i*wordProduct (fun j => old j+new j) l)‖+ + ‖τ ((a*old i)*wordProduct (fun j => old j+new j) l)- + τ ((a*old i)*wordProduct old l)‖ := norm_add_le _ _ + _ ≤ B+(l.length:ℝ)*B := add_le_add hi ht + _=_ := by simp only [List.length_cons,Nat.cast_add,Nat.cast_one]; ring + +lemma trace_word_second_order_bound (τ : A →ₗ[ℂ] ℂ) (old new : I → A) + (l : List I) {S D : ℝ} (hS : 0 ≤ S) (hD : 0 ≤ D) + (hsingle : ∀ s i t, l=s++i::t → + ‖τ (wordProduct old s*new i*wordProduct old t)‖ ≤ S) + (hdouble : ∀ s i t j r, l=s++i::(t++j::r) → + ‖τ (wordProduct old s*new i*wordProduct old t*new j* + wordProduct (fun k => old k+new k) r)‖ ≤ D) : + ‖τ (wordProduct (fun i => old i+new i) l)-τ (wordProduct old l)‖ ≤ + (l.length:ℝ)*S+(l.length:ℝ)^2*D := by + have hh : ∀ s i t, l=s++i::t → + ‖τ (wordProduct old s*new i*wordProduct (fun j => old j+new j) t)‖ ≤ + S+(l.length:ℝ)*D := by + intro s i t he + have ht := trace_word_difference_bound τ old new t (wordProduct old s*new i) hD (by + intro u j r ht + exact hdouble s i u j r (by rw [he,ht])) + have hlen : (t.length:ℝ) ≤ (l.length:ℝ) := by + apply Nat.cast_le.mpr + rw [he,List.length_append,List.length_cons] + omega + calc + _ ≤ ‖τ (wordProduct old s*new i*wordProduct old t)‖+ + ‖τ (wordProduct old s*new i*wordProduct (fun j => old j+new j) t)- + τ (wordProduct old s*new i*wordProduct old t)‖ := by + simpa only [norm_sub_rev] using norm_le_insert + (τ (wordProduct old s*new i*wordProduct old t)) + (τ (wordProduct old s*new i*wordProduct (fun j => old j+new j) t)) + _ ≤ S+(t.length:ℝ)*D := add_le_add (hsingle s i t he) ht + _ ≤ S+(l.length:ℝ)*D := add_le_add le_rfl (mul_le_mul_of_nonneg_right hlen hD) + have h := trace_word_difference_bound τ old new l 1 + (show 0 ≤ S+(l.length:ℝ)*D by positivity) (by + intro s i t he + simpa only [one_mul] using hh s i t he) + simpa only [one_mul,mul_add,←mul_assoc,←pow_two] using h + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeAction.lean b/lean/OAI/Analysis/Commutator/FreeAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..32e2dd538db40dd44aa985aa9b940d5acfade1d8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeAction.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertDiagonal +import OAI.Analysis.Commutator.TensorActions +import OAI.Analysis.Commutator.FreeWordDecomposition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (α : ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ i a, a∈S i → α i a∈S i) + (hτ : ∀ i a, t.functional (α i a)=t.functional a) + +def letter (a : Letter S t.functional.toLinearMap) : Letter S t.functional.toLinearMap where + color := a.color + val := α a.color a.val + mem := hmem _ _ a.mem + centered := (hτ _ _).trans a.centered + +@[simp] lemma letter_color (a : Letter S t.functional.toLinearMap) : + (letter t S α hmem hτ a).color=a.color := rfl + +@[simp] lemma letter_val (a : Letter S t.functional.toLinearMap) : + (letter t S α hmem hτ a).val=α a.color a.val := rfl + +lemma reduced_map {w : List (Letter S t.functional.toLinearMap)} (hw : Reduced w) : + Reduced (w.map (letter t S α hmem hτ)) := (List.isChain_map _).mpr hw + +def letterLinear (i : ι) : letterSpace t S i →ₗ[ℂ] letterSpace t S i where + toFun x := ⟨t.functional.toPreGNS (α i (letterValue t S i x)), + hmem _ _ x.property.1, by exact (hτ _ _).trans x.property.2⟩ + map_add' x y := by apply Subtype.ext; simp [map_add] + map_smul' c x := by apply Subtype.ext; simp [map_smul] + +lemma letterLinear_value (i : ι) (x : letterSpace t S i) : + letterValue t S i (letterLinear t S α hmem hτ i x)=α i (letterValue t S i x) := rfl + +lemma letterLinear_inner (i : ι) (x y : letterSpace t S i) : + inner ℂ (letterLinear t S α hmem hτ i x) (letterLinear t S α hmem hτ i y)=inner ℂ x y := by + rw [inner_letter,inner_letter,letterLinear_value,letterLinear_value,←map_star,←map_mul,hτ] + +def letterIso (i : ι) : letterSpace t S i →ₗᵢ[ℂ] letterSpace t S i where + toLinearMap := letterLinear t S α hmem hτ i + norm_map' x := by + rw [norm_eq_sqrt_re_inner (𝕜:=ℂ),norm_eq_sqrt_re_inner (𝕜:=ℂ), + letterLinear_inner] + +def tensorIso : ∀ is : List ι, tensor t S is →ₗᵢ[ℂ] tensor t S is + | [] => LinearIsometry.id + | i::is => TensorProduct.mapIsometry (letterIso t S α hmem hτ i) (tensorIso is) + +def mapParams : ∀ is, Params t S is → Params t S is + | [], _ => PUnit.unit + | i::is, x => (letterIso t S α hmem hτ i x.1,mapParams is x.2) + +lemma tensorIso_pure : ∀ is (x : Params t S is), + tensorIso t S α hmem hτ is (pure t S is x)=pure t S is (mapParams t S α hmem hτ is x) + | [], _ => rfl + | i::is,x => by + change (letterIso t S α hmem hτ i x.1) ⊗ₜ[ℂ] + (tensorIso t S α hmem hτ is (pure t S is x.2)) = _ + rw [tensorIso_pure is x.2] + rfl + +lemma mapParams_letters : ∀ is (x : Params t S is), + letters t S is (mapParams t S α hmem hτ is x)= + (letters t S is x).map (letter t S α hmem hτ) + | [], _ => rfl + | i::is,x => by + change asLetter t S i (letterIso t S α hmem hτ i x.1) :: _ = _ :: _ + congr 1 + exact mapParams_letters is x.2 + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +def action : t.functional.GNS →ₗᵢ[ℂ] t.functional.GNS := + HilbertDiagonal.onSum (wordSpace t S) (wordInclusion t S hfree) + (isHilbertSum_of_generation t S hfree hgen) + (fun is => completionIsometry (tensorIso t S α hmem hτ is.val)) + +lemma action_word (w : List (Letter S t.functional.toLinearMap)) (hw : Reduced w) : + action t S α hmem hτ hfree hgen (t.functional.toPreGNS (word w) : t.functional.GNS) = + (t.functional.toPreGNS (word (w.map (letter t S α hmem hτ))) : t.functional.GNS) := by + let is : ColorSeq ι := ⟨w.map Letter.color,(List.isChain_map _).mpr hw⟩ + have hv : (t.functional.toPreGNS (word w) : t.functional.GNS)= + wordInclusion t S hfree is (pure t S is.val (paramsOfLetters t S w) : wordSpace t S is) := by + change _=wordEmbedding t S hfree is.val is.property _ + rw [wordEmbedding_coe,readPre_pure] + simp only [is,letters_paramsOfLetters] + rw [hv] + unfold action + rw [HilbertDiagonal.onSum_insert,completionIsometry_coe,tensorIso_pure] + change wordEmbedding t S hfree is.val is.property _ = _ + rw [wordEmbedding_coe,readPre_pure,mapParams_letters] + simp only [is,letters_paramsOfLetters] + +end Kadison.FreeWordAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActionBlock.lean b/lean/OAI/Analysis/Commutator/FreeActionBlock.lean new file mode 100644 index 0000000000000000000000000000000000000000..9124e4caf5db952bdc4e135463bc3af315792d21 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActionBlock.lean @@ -0,0 +1,108 @@ +import Mathlib +import OAI.Analysis.Commutator.Regroup +import OAI.Analysis.Commutator.FreeActionCovariance +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) + +def mapBlockD (T : letterSpace t S i → letterSpace t S i) : + ∀ n, BlockParams t S i j n → BlockParams t S i j n + | 0,x => x + | n+1,x => ((x.1.1,T x.1.2),mapBlockD T n x.2) + +lemma paramD_mapBlockD (T : letterSpace t S i → letterSpace t S i) : + ∀ n (x : BlockParams t S i j n) (k : Fin n), + paramD t S n (mapBlockD t S i j T n x) k=T (paramD t S n x k) + | 0,_,k => Fin.elim0 k + | n+1,x,k => by + refine Fin.cases ?_ (fun k => ?_) k + · rfl + · exact paramD_mapBlockD T n x.2 k + +lemma paramJ_mapBlockD (T : letterSpace t S i → letterSpace t S i) : + ∀ n (x : BlockParams t S i j n), + paramJ t S n (mapBlockD t S i j T n x)=paramJ t S n x + | 0,_ => rfl + | n+1,x => by + change x.1.1 ⊗ₜ[ℂ] paramJ t S n (mapBlockD t S i j T n x.2)=_ + rw [paramJ_mapBlockD T n x.2] + rfl + +variable (α : ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ k a, a∈S k → α k a∈S k) + (hτ : ∀ k a, t.functional (α k a)=t.functional a) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +lemma action_left_apply (k : ι) (a : A) (ha : a∈S k) (x : t.functional.GNS) : + action t S α hmem hτ hfree hgen (t.functional.gnsStarAlgHom a x)= + t.functional.gnsStarAlgHom (α k a) (action t S α hmem hτ hfree hgen x) := + congrArg (fun T : t.functional.GNS →L[ℂ] t.functional.GNS => T x) + (action_left t S α hmem hτ hfree hgen k a ha) + +lemma action_algebra_of_mem (k : ι) (a : A) (ha : a∈S k) : + action t S α hmem hτ hfree hgen (TracialGNS.algebraVector t.functional a)= + TracialGNS.algebraVector t.functional (α k a) := by + simpa only [word_nil,List.map_nil,mul_one] using + action_generator_word t S α hmem hτ hfree hgen k a ha [] reduced_nil + +lemma action_vector_mul (k : ι) (a : A) (ha : a∈S k) (b : A) : + action t S α hmem hτ hfree hgen (TracialGNS.algebraVector t.functional (a*b))= + t.functional.gnsStarAlgHom (α k a) + (action t S α hmem hτ hfree hgen (TracialGNS.algebraVector t.functional b)) := by + simpa only [TracialGNS.algebraVector_apply,TracialGNS.left_coe] using (action_left_apply t S α hmem hτ hfree hgen k a ha + (TracialGNS.algebraVector t.functional b)) + +include hfree hgen in +lemma action_blockRead_pure (hj : ∀ a∈S j, α j a=a) : + ∀ n (x : BlockParams t S i j n), + action t S α hmem hτ hfree hgen + (TracialGNS.algebraVector t.functional (blockRead t S n (blockPure t S n x))) = + TracialGNS.algebraVector t.functional + (blockRead t S n (blockPure t S n + (mapBlockD t S i j (letterIso t S α hmem hτ i) n x))) + | 0,x => by + change action t S α hmem hτ hfree hgen + (TracialGNS.algebraVector t.functional (factorValue t S j x))=_ + rw [action_algebra_of_mem t S α hmem hτ hfree hgen j (factorValue t S j x) (show factorValue t S j x ∈ S j from x.property), + hj (factorValue t S j x) (show factorValue t S j x ∈ S j from x.property)] + rfl + | n+1,x => by + change action t S α hmem hτ hfree hgen + (TracialGNS.algebraVector t.functional + (letterValue t S j x.1.1 * (letterValue t S i x.1.2 * + blockRead t S n (blockPure t S n x.2))))=_ + rw [action_vector_mul t S α hmem hτ hfree hgen j (letterValue t S j x.1.1) (show letterValue t S j x.1.1∈S j from x.1.1.property.1), + action_vector_mul t S α hmem hτ hfree hgen i (letterValue t S i x.1.2) (show letterValue t S i x.1.2∈S i from x.1.2.property.1), + action_blockRead_pure hj n x.2,hj (letterValue t S j x.1.1) (show letterValue t S j x.1.1∈S j from x.1.1.property.1)] + simp only [TracialGNS.algebraVector_apply,TracialGNS.left_coe] + rfl + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActionCovariance.lean b/lean/OAI/Analysis/Commutator/FreeActionCovariance.lean new file mode 100644 index 0000000000000000000000000000000000000000..99a9b1fbbadff790bc495177776bb84a96c3188c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActionCovariance.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeAction +import OAI.Analysis.Commutator.FreeSymmetry15 +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (α : ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ i a, a∈S i → α i a∈S i) + (hτ : ∀ i a, t.functional (α i a)=t.functional a) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +include hfree hgen in +lemma ext_reduced {E : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + (F G : t.functional.GNS →L[ℂ] E) + (hw : ∀ w : List (Letter S t.functional.toLinearMap), Reduced w → + F (TracialGNS.algebraVector t.functional (word w))= + G (TracialGNS.algebraVector t.functional (word w))) : F=G := by + apply ActualHilbertSum.map_ext (wordSpace t S) (wordInclusion t S hfree) + (isHilbertSum_of_generation t S hfree hgen) + intro is + ext x + change F (wordEmbedding t S hfree is.val is.property x) = G (wordEmbedding t S hfree is.val is.property x) + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => + simp only [wordEmbedding_coe] + have hs : x∈Submodule.span ℂ (Set.range (pure t S is.val)) := by rw [span_pure]; trivial + induction hs using Submodule.span_induction with + | mem y hy => + obtain ⟨p,rfl⟩ := hy + rw [readPre_pure] + exact hw _ (letters_reduced t S is.val p is.property) + | zero => simp [Completion.coe_zero] + | add x y _ _ hx hy => simp only [map_add, Completion.coe_add] at *; exact congrArg₂ (·+·) hx hy + | smul c x _ hx => simp only [map_smul, Completion.coe_smul] at *; exact congrArg (c • ·) hx + +lemma action_generator_word (i : ι) (a : A) (ha : a∈S i) + (w : List (Letter S t.functional.toLinearMap)) (hw : Reduced w) : + action t S α hmem hτ hfree hgen (TracialGNS.algebraVector t.functional (a*word w)) = + TracialGNS.algebraVector t.functional + (α i a*word (w.map (letter t S α hmem hτ))) := by + let V := TracialGNS.algebraVector t.functional + let W := action t S α hmem hτ hfree hgen + have hword : ∀ w, Reduced w → W (V (word w))=V (word (w.map (letter t S α hmem hτ))) := + fun w hw => action_word t S α hmem hτ hfree hgen w hw + have hone : W (V 1)=V 1 := hword [] reduced_nil + let c : Letter S t.functional.toLinearMap := + ⟨i,a-t.functional a • (1:A),sub_mem ha (SMulMemClass.smul_mem _ (one_mem _)), + by simp [map_sub,map_smul,t.normalized]⟩ + change W (V (a*word w))=V (α i a*word (w.map (letter t S α hmem hτ))) + cases w with + | nil => + have h := hword [c] (List.IsChain.singleton c) + change W (V ((a-t.functional a • (1:A))*1)) = + V (α i (a-t.functional a • (1:A))*1) at h + simp only [mul_one,map_sub,map_smul,map_one,hone] at h + simpa only [word_nil,List.map_nil,mul_one] using (sub_left_inj.mp h) + | cons b w => + by_cases hib : i=b.color + · let d : Letter S t.functional.toLinearMap := + ⟨i,a*b.val-t.functional (a*b.val) • (1:A), + sub_mem (mul_mem ha (by simpa only [hib] using b.mem)) + (SMulMemClass.smul_mem _ (one_mem _)), + by simp [map_sub,map_smul,t.normalized]⟩ + have hd : Reduced (d::w) := by + exact hw.imp_head (by intro c hc; simpa only [d,hib] using hc) + have ht := hword w hw.tail + have h := hword (d::w) hd + have hid : (a*b.val-t.functional (a*b.val) • (1:A))*word w = + a*word (b::w)-t.functional (a*b.val) • word w := by + simp only [word_cons,sub_mul,smul_mul_assoc,one_mul,mul_assoc] + have hj : α i (a*b.val-t.functional (a*b.val) • (1:A))* + word (w.map (letter t S α hmem hτ)) = + α i a*word ((b::w).map (letter t S α hmem hτ)) - + t.functional (a*b.val) • word (w.map (letter t S α hmem hτ)) := by + simp only [map_sub,map_smul,map_mul,map_one,List.map_cons,word_cons,letter_val, + sub_mul,smul_mul_assoc,one_mul,mul_assoc,hib] + change W (V ((a*b.val-t.functional (a*b.val) • (1:A))*word w)) = + V (α i (a*b.val-t.functional (a*b.val) • (1:A))* + word (w.map (letter t S α hmem hτ))) at h + rw [hid,hj] at h + simp only [map_sub,map_smul,ht] at h + exact sub_left_inj.mp h + · have hc : Reduced (c::b::w) := by + exact List.isChain_cons_cons.mpr ⟨hib,hw⟩ + have ht := hword (b::w) hw + have h := hword (c::b::w) hc + change W (V ((a-t.functional a • (1:A))*word (b::w))) = + V (α i (a-t.functional a • (1:A))*word ((b::w).map (letter t S α hmem hτ))) at h + simp only [sub_mul,smul_mul_assoc,one_mul,map_sub,map_smul,map_one,ht] at h + exact sub_left_inj.mp h + +lemma action_left (i : ι) (a : A) (ha : a∈S i) : + (action t S α hmem hτ hfree hgen).toContinuousLinearMap.comp (t.functional.gnsStarAlgHom a) = + (t.functional.gnsStarAlgHom (α i a)).comp (action t S α hmem hτ hfree hgen).toContinuousLinearMap := by + apply ext_reduced t S hfree hgen + intro w hw + simp only [ContinuousLinearMap.comp_apply,LinearIsometry.coe_toContinuousLinearMap, + TracialGNS.algebraVector_apply,TracialGNS.left_coe] + rw [action_word t S α hmem hτ hfree hgen w hw] + rw [TracialGNS.left_coe] + exact action_generator_word t S α hmem hτ hfree hgen i a ha w hw + +end Kadison.FreeWordAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActionGroup.lean b/lean/OAI/Analysis/Commutator/FreeActionGroup.lean new file mode 100644 index 0000000000000000000000000000000000000000..b2ee699310f6007d6af2a13b7a7e37400055c185 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActionGroup.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeActionCovariance +import OAI.Analysis.Commutator.HilbertStrong + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable {G : Type*} [Monoid G] (α : G → ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ g i a, a∈S i → α g i a∈S i) + (hτ : ∀ g i a, t.functional (α g i a)=t.functional a) + +lemma action_one (h1 : ∀ i a, α 1 i a=a) : + action t S (α 1) (hmem 1) (hτ 1) hfree hgen=LinearIsometry.id := by + apply LinearIsometry.toContinuousLinearMap_injective + apply ext_reduced t S hfree hgen + intro w hw + change action t S (α 1) (hmem 1) (hτ 1) hfree hgen + (TracialGNS.algebraVector t.functional (word w))=TracialGNS.algebraVector t.functional (word w) + simp only [TracialGNS.algebraVector_apply] + rw [action_word t S _ _ _ hfree hgen w hw] + congr 2 + simp only [word,List.map_map,Function.comp_def,letter_val,h1] + +lemma action_mul (hmul : ∀ g h i a, α (g*h) i a=α g i (α h i a)) (g h : G) : + action t S (α (g*h)) (hmem (g*h)) (hτ (g*h)) hfree hgen= + (action t S (α g) (hmem g) (hτ g) hfree hgen).comp + (action t S (α h) (hmem h) (hτ h) hfree hgen) := by + apply LinearIsometry.toContinuousLinearMap_injective + apply ext_reduced t S hfree hgen + intro w hw + change action t S (α (g*h)) (hmem (g*h)) (hτ (g*h)) hfree hgen + (TracialGNS.algebraVector t.functional (word w))= + action t S (α g) (hmem g) (hτ g) hfree hgen + (action t S (α h) (hmem h) (hτ h) hfree hgen + (TracialGNS.algebraVector t.functional (word w))) + simp only [TracialGNS.algebraVector_apply] + rw [action_word t S _ _ _ hfree hgen w hw,action_word t S _ _ _ hfree hgen w hw, + action_word t S _ _ _ hfree hgen _ (reduced_map t S _ _ _ hw)] + congr 2 + simp only [word,List.map_map,Function.comp_def,letter_val,letter_color,hmul] + +end Kadison.FreeWordAction + +namespace Kadison.TracialGNS + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +lemma algebraVector_continuous (τ : A →ₚ[ℂ] ℂ) : Continuous (algebraVector τ) := by + have he : (algebraVector τ : A → τ.GNS) = fun a => τ.gnsStarAlgHom a (vacuum τ) := by + funext a + exact (left_vacuum τ a).symm + rw [he] + exact (map_continuous τ.gnsStarAlgHom).clm_apply continuous_const + +end Kadison.TracialGNS + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {X : Type*} [TopologicalSpace X] (α : X → ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ g i a, a∈S i → α g i a∈S i) + (hτ : ∀ g i a, t.functional (α g i a)=t.functional a) + (hc : ∀ i a, Continuous fun g => α g i a) + +include hc + +lemma letterIso_continuous (i : ι) (x : letterSpace t S i) : + Continuous fun g => letterIso t S (α g) (hmem g) (hτ g) i x := by + apply Continuous.subtype_mk + apply (Completion.isUniformEmbedding_coe (preSpace t)).isEmbedding.continuous_iff.mpr + exact (TracialGNS.algebraVector_continuous t.functional).comp (hc i (letterValue t S i x)) + +lemma tensorIso_continuous : ∀ is (x : tensor t S is), + Continuous fun g => tensorIso t S (α g) (hmem g) (hτ g) is x + | [], _ => continuous_const + | i::is,x => StrongContinuity.tensor _ _ (letterIso_continuous t S α hmem hτ hc i) + (tensorIso_continuous is) x + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +lemma action_continuous (x : t.functional.GNS) : + Continuous fun g => action t S (α g) (hmem g) (hτ g) hfree hgen x := by + apply StrongContinuity.hilbertSum (wordInclusion t S hfree) + (isHilbertSum_of_generation t S hfree hgen) _ _ x + intro is y + have he : (fun g => action t S (α g) (hmem g) (hτ g) hfree hgen + (wordInclusion t S hfree is y)) = fun g => wordInclusion t S hfree is + (completionIsometry (tensorIso t S (α g) (hmem g) (hτ g) is.val) y) := by + funext g + exact HilbertDiagonal.onSum_insert _ _ _ _ _ _ + rw [he] + exact (wordInclusion t S hfree is).continuous.comp + (StrongContinuity.completion _ (tensorIso_continuous t S α hmem hτ hc is.val) y) + +end Kadison.FreeWordAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActionUnitary.lean b/lean/OAI/Analysis/Commutator/FreeActionUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..4aa3f22b91316b8d62292ca2362a53b3540a6da2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActionUnitary.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeActionGroup + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable {G : Type*} [Group G] (α : G → ι → A ≃⋆ₐ[ℂ] A) + (hmem : ∀ g i a, a∈S i → α g i a∈S i) + (hτ : ∀ g i a, t.functional (α g i a)=t.functional a) + (h1 : ∀ i a, α 1 i a=a) + (hmul : ∀ g h i a, α (g*h) i a=α g i (α h i a)) + +include h1 hmul in +lemma action_inv (g : G) (x : t.functional.GNS) : + action t S (α g⁻¹) (hmem g⁻¹) (hτ g⁻¹) hfree hgen + (action t S (α g) (hmem g) (hτ g) hfree hgen x)=x := by + have h := congrArg (fun T : t.functional.GNS →ₗᵢ[ℂ] t.functional.GNS => T x) + (action_mul t S hfree hgen α hmem hτ hmul g⁻¹ g) + rw [inv_mul_cancel,action_one t S hfree hgen α hmem hτ h1] at h + exact h.symm + +def equiv (g : G) : t.functional.GNS ≃ₗᵢ[ℂ] t.functional.GNS where + toLinearEquiv := + { (action t S (α g) (hmem g) (hτ g) hfree hgen).toLinearMap with + invFun := action t S (α g⁻¹) (hmem g⁻¹) (hτ g⁻¹) hfree hgen + left_inv := action_inv t S hfree hgen α hmem hτ h1 hmul g + right_inv := by + intro x + change action t S (α g) (hmem g) (hτ g) hfree hgen + (action t S (α g⁻¹) (hmem g⁻¹) (hτ g⁻¹) hfree hgen x)=x + simpa only [inv_inv] using action_inv t S hfree hgen α hmem hτ h1 hmul g⁻¹ x } + norm_map' := (action t S (α g) (hmem g) (hτ g) hfree hgen).norm_map + +@[simp] lemma equiv_apply (g : G) (x : t.functional.GNS) : + equiv t S hfree hgen α hmem hτ h1 hmul g x= + action t S (α g) (hmem g) (hτ g) hfree hgen x := rfl + +def representation : G →* (t.functional.GNS ≃ₗᵢ[ℂ] t.functional.GNS) where + toFun := equiv t S hfree hgen α hmem hτ h1 hmul + map_one' := by + ext x + change action t S (α 1) (hmem 1) (hτ 1) hfree hgen x=x + rw [action_one t S hfree hgen α hmem hτ h1] + rfl + map_mul' g h := by + ext x + change action t S (α (g*h)) (hmem (g*h)) (hτ (g*h)) hfree hgen x= + action t S (α g) (hmem g) (hτ g) hfree hgen + (action t S (α h) (hmem h) (hτ h) hfree hgen x) + rw [action_mul t S hfree hgen α hmem hτ hmul] + rfl + +@[simp] lemma representation_apply (g : G) (x : t.functional.GNS) : + representation t S hfree hgen α hmem hτ h1 hmul g x= + action t S (α g) (hmem g) (hτ g) hfree hgen x := rfl + +lemma representation_continuous [TopologicalSpace G] + (hc : ∀ i a, Continuous fun g => α g i a) (x : t.functional.GNS) : + Continuous fun g => representation t S hfree hgen α hmem hτ h1 hmul g x := + action_continuous t S α hmem hτ hc hfree hgen x + +end Kadison.FreeWordAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActualCovariance.lean b/lean/OAI/Analysis/Commutator/FreeActualCovariance.lean new file mode 100644 index 0000000000000000000000000000000000000000..e2baa88523c98ce02d817ab8783977d048b178d9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActualCovariance.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeActionBlock +import OAI.Analysis.Commutator.FreeActionUnitary +import OAI.Analysis.Commutator.FreeCovariance +import OAI.Analysis.Commutator.FreeLetterIntertwine +import OAI.Analysis.Commutator.FreeSymmetry16 + +namespace OAI + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +abbrev innerRepresentation : unitary D →* (t.functional.GNS ≃ₗᵢ[ℂ] t.functional.GNS) := + representation t S hfree hgen (innerFamily f i) (innerFamily_mem f S i hS) + (innerFamily_trace t ht f i) (innerFamily_one f i) (innerFamily_mul f i) + +omit [PartialOrder D] [StarOrderedRing D] in +lemma innerRepresentation_continuous (x : t.functional.GNS) : + Continuous fun u => innerRepresentation t ht f S i hS hfree hgen u x := + representation_continuous t S hfree hgen (innerFamily f i) (innerFamily_mem f S i hS) + (innerFamily_trace t ht f i) (innerFamily_one f i) (innerFamily_mul f i) + (innerFamily_continuous f i) x + +private abbrev sourceConjugation (u : unitary D) (n : ℕ) : + sourceLevel t f hf S j n →L[ℂ] sourceLevel t f hf S j n := + HilbertTensor.map + (PreHilbert.wordMap (factorFull t f hf) (factorZero t f hf) + (TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (centeredIsometry (TracialGNS.vacuum (factorTrace t f hf)) + (TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (TracialGNS.conjugation_vacuum (factorTrace t f hf) + (factorTrace_tracial t f hf ht) u)) n).toContinuousLinearMap + (1 : multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +lemma sumConjugation_levelWord (u : unitary D) (d : D) (n : ℕ) + (x : BlockParams t S i j n) : + sourceConjugation t ht f hf S j u n (levelWord t f hf S i j hS d n x) = + levelWord t f hf S i j hS ((u:D)*d*star (u:D)) n + (mapBlockD t S i j + (letterIso t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) i) n x) := by + simp only [sourceConjugation, levelWord, HilbertTensor.map_pair, + LinearIsometry.coe_toContinuousLinearMap, one_apply_eq_self, + paramJ_mapBlockD,paramD_mapBlockD] + apply congrArg (fun y : sourceScalar t f hf n => + HilbertTensor.pair y (paramJ t S n x : multiplicityLevel t S j n)) + have hw := PreHilbert.wordMap_word (factorFull t f hf) (factorZero t f hf) + (TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (centeredIsometry (TracialGNS.vacuum (factorTrace t f hf)) + (TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (TracialGNS.conjugation_vacuum (factorTrace t f hf) (factorTrace_tracial t f hf ht) u)) + n (TracialGNS.algebraVector (factorTrace t f hf) d) + (fun k => (letterGNSIso t f hf S i hS (paramD t S n x k : Completion (letterSpace t S i)) : + TracialGNS.zeroSpace (factorTrace t f hf))) + refine hw.trans ?_ + have hd := TracialGNS.conjugation_coe (factorTrace t f hf) + (factorTrace_tracial t f hf ht) u d + change TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u + (TracialGNS.algebraVector (factorTrace t f hf) d)= + TracialGNS.algebraVector (factorTrace t f hf) ((u:D)*d*star (u:D)) at hd + rw [hd] + congr 1 + funext k + exact (letterGNSIso_conjugation t f hf S i hS ht u (paramD t S n x k)).symm + +variable (hij : i≠j) + +lemma innerRepresentation_word (u : unitary D) (d : D) (n : ℕ) + (x : BlockParams t S i j n) : + innerRepresentation t ht f S i hS hfree hgen u + (sourceLevelEmbedding t f hf S i j hS hfree hij n + (levelWord t f hf S i j hS d n x)) = + sourceLevelEmbedding t f hf S i j hS hfree hij n + (levelWord t f hf S i j hS ((u:D)*d*star (u:D)) n + (mapBlockD t S i j + (letterIso t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) i) n x)) := by + rw [sourceLevelEmbedding_word,sourceLevelEmbedding_word] + have hfd : f d∈S i := by rw [hS]; exact ⟨d,rfl⟩ + change action t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) hfree hgen + (t.functional.gnsStarAlgHom (f d) + (TracialGNS.algebraVector t.functional (blockRead t S n (blockPure t S n x)))) = _ + rw [action_left_apply t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) hfree hgen i (f d) hfd, + action_blockRead_pure t S i j (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) hfree hgen + (fun a _ => innerFamily_other f i u hij.symm a) n x] + congr 2 + simp only [innerFamily_self,map_mul] + +lemma innerRepresentation_level (u : unitary D) (n : ℕ) : + (innerRepresentation t ht f S i hS hfree hgen u).toLinearIsometry.toContinuousLinearMap.comp + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap = + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap.comp + (sourceConjugation t ht f hf S j u n) := by + apply sourceLevel_ext t f hf S i j hS + intro d x + change innerRepresentation t ht f S i hS hfree hgen u + (sourceLevelEmbedding t f hf S i j hS hfree hij n + (levelWord t f hf S i j hS d n x)) = + sourceLevelEmbedding t f hf S i j hS hfree hij n + (sourceConjugation t ht f hf S j u n (levelWord t f hf S i j hS d n x)) + exact (innerRepresentation_word t ht f hf S i j hS hfree hgen hij u d n x).trans + (congrArg (sourceLevelEmbedding t f hf S i j hS hfree hij n) + (sumConjugation_levelWord t ht f hf S i j hS u d n x).symm) + +end Kadison.FreeBlocks + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeActualStructure.lean b/lean/OAI/Analysis/Commutator/FreeActualStructure.lean new file mode 100644 index 0000000000000000000000000000000000000000..555123c269e4e15c06054273765bf5ee83baa43d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeActualStructure.lean @@ -0,0 +1,242 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeActualCovariance + +namespace OAI + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable (hij : i≠j) (hcolors : ∀ c : ι, c=i ∨ c=j) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + +variable (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + +variable (he : ∀ n m (h : n ≤ m) a, φ m (e h a)=φ n a) + +variable (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + +variable (hDgen : ∀ a : D, (factorTrace t f hf).gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra (factorTrace t f hf) I φ : Set _))) + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (hGL : ∀ a : D, G.comp (t.functional.gnsStarAlgHom (f a))= + (t.functional.gnsStarAlgHom (f a)).comp G) + +variable (hGW : ∀ n u, G.comp + (innerRepresentation t ht f S i hS hfree hgen (TracialGNS.stageUnitary (φ n) u)).toLinearIsometry.toContinuousLinearMap = + (innerRepresentation t ht f S i hS hfree hgen (TracialGNS.stageUnitary (φ n) u)).toLinearIsometry.toContinuousLinearMap.comp G) + +private abbrev embeddedSourceWord (level : ℕ) (scalar : factorFull t f hf) + (centered : factorZero t f hf) (coefficient : multiplicityLevel t S j level) : + t.functional.GNS := + sourceLevelEmbedding t f hf S i j hS hfree hij level + (HilbertTensor.pair (E := sourceScalar t f hf level) (J := multiplicityLevel t S j level) + (PreHilbert.word (factorFull t f hf) (factorZero t f hf) level scalar + (fun _ => centered)) coefficient) + +private structure WordActions (algebra : Type) [CStarAlgebra algebra] where + full : PreHilbert + centered : PreHilbert + left : algebra → full →L[ℂ] full + conjugation : unitary algebra → full →ₗᵢ[ℂ] full + centeredConjugation : unitary algebra → centered →ₗᵢ[ℂ] centered + +private def tracialWordActions (functional : D →ₚ[ℂ] ℂ) + (tracial : ∀ first second : D, functional (first * second) = + functional (second * first)) : WordActions D where + full := TracialGNS.fullSpace functional + centered := TracialGNS.zeroSpace functional + left := functional.gnsStarAlgHom + conjugation := TracialGNS.conjugation functional tracial + centeredConjugation unitary := centeredIsometry (TracialGNS.vacuum functional) + (TracialGNS.conjugation functional tracial unitary) + (TracialGNS.conjugation_vacuum functional tracial unitary) + +private def faithfulWordActions (state : FaithfulState D) + (tracial : ∀ first second : D, state.functional (first * second) = + state.functional (second * first)) : WordActions D where + full := ⟨state.functional.GNS⟩ + centered := ⟨HilbertCompletion.centered + ((state.functional.toPreGNS 1 : preSpace state) : state.functional.GNS)⟩ + left := state.functional.gnsStarAlgHom + conjugation := TracialGNS.conjugation state.functional tracial + centeredConjugation unitary := centeredIsometry (TracialGNS.vacuum state.functional) + (TracialGNS.conjugation state.functional tracial unitary) + (TracialGNS.conjugation_vacuum state.functional tracial unitary) + +private theorem faithfulWordActions_eq (state : FaithfulState D) + (tracial : ∀ first second : D, state.functional (first * second) = + state.functional (second * first)) : + faithfulWordActions state tracial = tracialWordActions state.functional tracial := by + rfl + +private abbrev wordLevel (actions : WordActions D) (multiplicity : ℕ → Type*) + [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] (level : ℕ) := + Completion (PreHilbert.wordSpace actions.full actions.centered level ⊗[ℂ] multiplicity level) + +private abbrev wordLeftAction (actions : WordActions D) (multiplicity : ℕ → Type*) + [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] (element : D) (level : ℕ) : + wordLevel actions multiplicity level →L[ℂ] wordLevel actions multiplicity level := + HilbertTensor.map (HilbertTensor.map (actions.left element) + (1 : PreHilbert.power actions.centered level →L[ℂ] PreHilbert.power actions.centered level)) + (1 : multiplicity level →L[ℂ] multiplicity level) + +private abbrev wordConjugationAction (actions : WordActions D) (multiplicity : ℕ → Type*) + [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] (unitary : unitary D) (level : ℕ) : + wordLevel actions multiplicity level →L[ℂ] wordLevel actions multiplicity level := + HilbertTensor.map (PreHilbert.wordMap actions.full actions.centered + (actions.conjugation unitary) (actions.centeredConjugation unitary) level).toContinuousLinearMap + (1 : multiplicity level →L[ℂ] multiplicity level) + +private abbrev wordStructure (full centered : PreHilbert) + (multiplicity : ℕ → Type*) [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] + [∀ level, CompleteSpace (multiplicity level)] + (ambient : Type*) [NormedAddCommGroup ambient] [InnerProductSpace ℂ ambient] [CompleteSpace ambient] + (embedding : ∀ level, Completion + (PreHilbert.wordSpace full centered level ⊗[ℂ] multiplicity level) →ₗᵢ[ℂ] ambient) + (operator : ambient →L[ℂ] ambient) : Prop := + ∃ coefficient : ∀ level, multiplicity level →L[ℂ] multiplicity level, + (∀ level, ‖coefficient level‖ ≤ ‖operator‖) ∧ + (∀ level (scalar : full) (letter : centered) (vector : multiplicity level), + operator (embedding level (HilbertTensor.pair + (PreHilbert.word full centered level scalar (fun _ => letter)) vector)) = + embedding level (HilbertTensor.pair + (PreHilbert.word full centered level scalar (fun _ => letter)) (coefficient level vector))) ∧ + (∀ level (scalar : full) (letter : centered) (vector : multiplicity level), + operator.adjoint (embedding level (HilbertTensor.pair + (PreHilbert.word full centered level scalar (fun _ => letter)) vector)) = + embedding level (HilbertTensor.pair + (PreHilbert.word full centered level scalar (fun _ => letter)) + ((coefficient level).adjoint vector))) + +private def wordStructureRule (actions : WordActions D) + (multiplicity : ℕ → Type*) [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] + [∀ level, CompleteSpace (multiplicity level)] + (ambient : Type*) [NormedAddCommGroup ambient] [InnerProductSpace ℂ ambient] [CompleteSpace ambient] + : Prop := + ∀ (embedding : ∀ level, wordLevel actions multiplicity level →ₗᵢ[ℂ] ambient), + IsHilbertSum ℂ (wordLevel actions multiplicity) embedding → + ∀ (left : D → ambient →L[ℂ] ambient) + (symmetries : ∀ stage, unitary (Matrix (I stage) (I stage) ℂ) → ambient →L[ℂ] ambient) + (operator : ambient →L[ℂ] ambient), + (∀ element level, (left element).comp (embedding level).toContinuousLinearMap = + (embedding level).toContinuousLinearMap.comp + (wordLeftAction actions multiplicity element level)) → + (∀ stage unitary level, + (symmetries stage unitary).comp (embedding level).toContinuousLinearMap = + (embedding level).toContinuousLinearMap.comp + (wordConjugationAction actions multiplicity + (TracialGNS.stageUnitary (φ stage) unitary) level)) → + (∀ element, operator.comp (left element) = (left element).comp operator) → + (∀ stage unitary, operator.comp (symmetries stage unitary) = + (symmetries stage unitary).comp operator) → + wordStructure actions.full actions.centered multiplicity ambient embedding operator + +include he hsize in +private theorem tracial_word_structure (functional : D →ₚ[ℂ] ℂ) + (tracial : ∀ first second : D, functional (first * second) = + functional (second * first)) (normalized : functional 1 = 1) + (generation : ∀ element : D, functional.gnsStarAlgHom element ∈ + Set.centralizer (Set.centralizer (TracialGNS.stageAlgebra functional I φ : Set _))) + (multiplicity : ℕ → Type*) [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] + [∀ level, CompleteSpace (multiplicity level)] + (ambient : Type*) [NormedAddCommGroup ambient] [InnerProductSpace ℂ ambient] [CompleteSpace ambient] : + wordStructureRule I φ (tracialWordActions functional tracial) multiplicity ambient := by + intro embedding total left symmetries operator left_covariant symmetries_covariant + commutes_left commutes_symmetries + exact TracialGNS.actual_word_structure functional tracial normalized multiplicity embedding total + I φ e he hsize generation left symmetries left_covariant symmetries_covariant operator + commutes_left commutes_symmetries + +include he hsize in +private theorem faithful_word_structure (state : FaithfulState D) + (tracial : ∀ first second : D, state.functional (first * second) = + state.functional (second * first)) + (generation : ∀ element : D, state.functional.gnsStarAlgHom element ∈ + Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra state.functional I φ : Set _))) + (multiplicity : ℕ → Type*) [∀ level, NormedAddCommGroup (multiplicity level)] + [∀ level, InnerProductSpace ℂ (multiplicity level)] + [∀ level, CompleteSpace (multiplicity level)] + (ambient : Type*) [NormedAddCommGroup ambient] [InnerProductSpace ℂ ambient] [CompleteSpace ambient] : + wordStructureRule I φ (faithfulWordActions state tracial) multiplicity ambient := by + rw [faithfulWordActions_eq] + exact tracial_word_structure I φ e he hsize state.functional tracial state.normalized generation + multiplicity ambient + +private lemma faithful_left_level (a : D) (n : ℕ) : + (t.functional.gnsStarAlgHom (f a)).comp + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap = + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap.comp + (wordLeftAction (faithfulWordActions (pullbackState t f hf) + (factorTrace_tracial t f hf ht)) (multiplicityLevel t S j) a n) := by + exact (sourceLevelEmbedding_left t f hf S i j hS hfree hij a n).symm + +private lemma faithful_conjugation_level (u : unitary D) (n : ℕ) : + (innerRepresentation t ht f S i hS hfree hgen u).toLinearIsometry.toContinuousLinearMap.comp + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap = + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap.comp + (wordConjugationAction (faithfulWordActions (pullbackState t f hf) + (factorTrace_tracial t f hf ht)) (multiplicityLevel t S j) u n) := by + exact innerRepresentation_level t ht f hf S i j hS hfree hgen hij u n + +include hgen hcolors he hsize hDgen hGL hGW in +theorem free_word_structure : ∃ B : ∀ k, multiplicityLevel t S j k →L[ℂ] multiplicityLevel t S j k, + (∀ k, ‖B k‖ ≤ ‖G‖) ∧ + (∀ k (d : factorFull t f hf) + (x : factorZero t f hf) (a : multiplicityLevel t S j k), + G (embeddedSourceWord t f hf S i j hS hfree hij k d x a) = + embeddedSourceWord t f hf S i j hS hfree hij k d x (B k a)) ∧ + (∀ k (d : factorFull t f hf) + (x : factorZero t f hf) (a : multiplicityLevel t S j k), + G.adjoint (embeddedSourceWord t f hf S i j hS hfree hij k d x a) = + embeddedSourceWord t f hf S i j hS hfree hij k d x ((B k).adjoint a)) := by + have hcov (stage : ℕ) (u : unitary (Matrix (I stage) (I stage) ℂ)) (level : ℕ) := + faithful_conjugation_level t ht f hf S i j hS hfree hgen hij + (by exact TracialGNS.stageUnitary (φ stage) u) level + have rule := faithful_word_structure I φ e he hsize (pullbackState t f hf) + (factorTrace_tracial t f hf ht) hDgen (multiplicityLevel t S j) t.functional.GNS + have embedded := rule (sourceLevelEmbedding t f hf S i j hS hfree hij) + (sourceLevelIsHilbertSum t f hf S i j hS hfree hij hcolors hgen) + have h := embedded (fun a => t.functional.gnsStarAlgHom (f a)) + (fun n u => (innerRepresentation t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) u)).toLinearIsometry.toContinuousLinearMap) + G (faithful_left_level t ht f hf S i j hS hfree hij) hcov hGL hGW + exact h + +end Kadison.FreeBlocks + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBaseCompression.lean b/lean/OAI/Analysis/Commutator/FreeBaseCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..c93fb06da008eb7c9174e593df97a90cb0dacb9a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBaseCompression.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeHilbertEntries +import OAI.Analysis.Commutator.GNSVectorEmbedding +import OAI.Analysis.Commutator.IsometryCompression + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments ContinuousLinearMap + +variable {A B : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable (τ : B →ₚ[ℂ] ℂ) (t : FaithfulState A) (f : B →⋆ₐ[ℂ] A) + (htrace : ∀ a,τ a=t.functional (f a)) + +omit [StarOrderedRing B] in +include htrace in +lemma pullback_vector_trace (a : B) : + τ a=inner ℂ (TracialGNS.vacuum t.functional) + ((t.functional.gnsStarAlgHom.comp f) a (TracialGNS.vacuum t.functional)) := by + change τ a=inner ℂ (TracialGNS.vacuum t.functional) + (t.functional.gnsStarAlgHom (f a) (TracialGNS.vacuum t.functional)) + rw [TracialGNS.left_vacuum] + change τ a=inner ℂ (TracialGNS.vacuum t.functional) (TracialGNS.algebraVector t.functional (f a)) + rw [TracialGNS.inner_vacuum_algebraVector] + exact htrace a + +def originalEmbedding : τ.GNS →ₗᵢ[ℂ] t.functional.GNS := + VectorGNS.embedding τ (t.functional.gnsStarAlgHom.comp f) (TracialGNS.vacuum t.functional) + (pullback_vector_trace τ t f htrace) + +@[simp] lemma originalEmbedding_coe (a : B) : + originalEmbedding τ t f htrace (TracialGNS.algebraVector τ a)= + TracialGNS.algebraVector t.functional (f a) := by + rw [originalEmbedding,VectorGNS.embedding_coe] + exact TracialGNS.left_vacuum _ _ + +variable (R : Bool → StarSubalgebra ℂ A) (hfree : Free R t.functional.toLinearMap) + +lemma originalEmbedding_range (hf : ∀ a : B,f a∈R true) : + Set.range (originalEmbedding τ t f htrace)⊆Set.range (baseEmbedding t R hfree) := by + rintro _ ⟨x,rfl⟩ + refine (TracialGNS.algebraVector_dense τ).induction_on x + ((baseEmbedding t R hfree).isometry.isClosedEmbedding.isClosed_range.preimage + (originalEmbedding τ t f htrace).continuous) ?_ + intro a + refine ⟨(factorOf t R true (f a) (hf a) : multiplicityLevel t R true 0),?_⟩ + rw [baseEmbedding_factorOf,originalEmbedding_coe] + rfl + +theorem original_commutator_le_base (hf : ∀ a : B,f a∈R true) + (G : t.functional.GNS →L[ℂ] t.functional.GNS) (T : τ.GNS →L[ℂ] τ.GNS) + (hGT : ∀ x,G (originalEmbedding τ t f htrace x)=originalEmbedding τ t f htrace (T x)) + (a : B) : + ‖T*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*T‖≤ + ‖FreeCorner.compress (K:=multiplicityLevel t R true 0) (H:=t.functional.GNS) (baseEmbedding t R hfree) + (G*t.functional.gnsStarAlgHom (f a)-t.functional.gnsStarAlgHom (f a)*G)‖ := by + have hcomp : VectorGNS.compression τ (t.functional.gnsStarAlgHom.comp f) + (TracialGNS.vacuum t.functional) (pullback_vector_trace τ t f htrace) G=T := by + ext x + exact VectorGNS.compression_on_preserved _ _ _ _ G x (T x) (hGT x) + rw [←hcomp,VectorGNS.compression_commutator] + exact @FreeCorner.norm_compress_le_of_range_subset + t.functional.GNS (multiplicityLevel t R true 0) τ.GNS + inferInstance inferInstance inferInstance + inferInstance inferInstance inferInstance + inferInstance inferInstance inferInstance + (originalEmbedding τ t f htrace) (baseEmbedding t R hfree) + (originalEmbedding_range τ t f htrace R hfree hf) _ + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockTensor.lean b/lean/OAI/Analysis/Commutator/FreeBlockTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..fae66adf25f340de039417e7800066f6ff18ac3d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockTensor.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockWords2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} + +def factorSpace (i : ι) : Submodule ℂ (preSpace t) where + carrier := {x | t.functional.ofPreGNS x ∈ S i} + zero_mem' := by simp + add_mem' := by intro x y hx hy; simpa using add_mem hx hy + smul_mem' := by intro c x hx; simpa using SMulMemClass.smul_mem c hx + +def factorValue (i : ι) : factorSpace t S i →ₗ[ℂ] A := + t.functional.ofPreGNS.toLinearMap.comp (factorSpace t S i).subtype + +abbrev spaceTensor (E F : Space) : Space := ⟨E ⊗[ℂ] F⟩ + +@[reducible] def blockTensor (i j : ι) : ℕ → Space + | 0 => ⟨factorSpace t S j⟩ + | n+1 => spaceTensor ⟨letterSpace t S j⟩ (spaceTensor ⟨letterSpace t S i⟩ (blockTensor i j n)) + +@[reducible] def BlockParams (i j : ι) : ℕ → Type + | 0 => factorSpace t S j + | n+1 => Letters t S i j × BlockParams i j n + +def blockPure : ∀ n, BlockParams t S i j n → blockTensor t S i j n + | 0, z => z + | n+1, x => x.1.1 ⊗ₜ[ℂ] (x.1.2 ⊗ₜ[ℂ] blockPure n x.2) + +def paramLetters : ∀ n, BlockParams t S i j n → List (Letters t S i j) + | 0, _ => [] + | n+1, x => x.1 :: paramLetters n x.2 + +def paramEnd : ∀ n, BlockParams t S i j n → factorSpace t S j + | 0, z => z + | n+1, x => paramEnd n x.2 + +@[simp] lemma paramLetters_length : ∀ n (x : BlockParams t S i j n), + (paramLetters t S n x).length=n + | 0, _ => rfl + | n+1, x => by simp [paramLetters, paramLetters_length n x.2] + +def blockRead : ∀ n, blockTensor t S i j n →ₗ[ℂ] A + | 0 => factorValue t S j + | n+1 => (TensorProduct.lift (LinearMap.mul ℂ A)).comp + (TensorProduct.map (letterValue t S j) + ((TensorProduct.lift (LinearMap.mul ℂ A)).comp + (TensorProduct.map (letterValue t S i) (blockRead n)))) + +@[simp] lemma blockRead_pure : ∀ n (x : BlockParams t S i j n), + blockRead t S n (blockPure t S n x) = + blockValue t S (paramLetters t S n x) (factorValue t S j (paramEnd t S n x)) + | 0, _ => rfl + | n+1, x => by + change letterValue t S j x.1.1 * (letterValue t S i x.1.2 * + blockRead t S n (blockPure t S n x.2)) = _ + rw [blockRead_pure n x.2] + rfl + +lemma span_blockPure (n : ℕ) : + Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n))=⊤ := by + induction n with + | zero => simp [blockPure] + | succ n ih => + apply Submodule.eq_top_iff'.mpr + intro z + induction z using TensorProduct.inductionOn with + | add x y hx hy => exact Submodule.add_mem _ hx hy + | tmul a w => + induction w using TensorProduct.inductionOn with + | add x y hx hy => simpa only [TensorProduct.tmul_add] using + (Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) (n+1)))).add_mem hx hy + | tmul d w => + have hw : w ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n)) := by rw [ih]; trivial + induction hw using Submodule.span_induction with + | mem w hw => + obtain ⟨v,rfl⟩ := hw + exact Submodule.subset_span ⟨((a,d),v),rfl⟩ + | zero => simp only [TensorProduct.tmul_zero, Submodule.zero_mem] + | add x y _ _ hx hy => simpa only [TensorProduct.tmul_add] using + (Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) (n+1)))).add_mem hx hy + | smul c w _ hw => simpa only [TensorProduct.tmul_smul] using + (Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) (n+1)))).smul_mem c hw + +def blockReadPre (n : ℕ) : blockTensor t S i j n →ₗ[ℂ] preSpace t := + t.functional.toPreGNS.toLinearMap.comp (blockRead t S n) + +@[simp] lemma blockReadPre_pure (n : ℕ) (x : BlockParams t S i j n) : + (blockReadPre t S n (blockPure t S n x) : t.functional.GNS) = + blockVector t S (paramLetters t S n x) (factorValue t S j (paramEnd t S n x)) := by + change (t.functional.toPreGNS (blockRead t S n (blockPure t S n x)) : t.functional.GNS)=_ + rw [blockRead_pure] + rfl + +variable (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +include hfree hij + +lemma inner_blockReadPre_pure : ∀ n (x y : BlockParams t S i j n), + inner ℂ (blockReadPre t S n (blockPure t S n x)) + (blockReadPre t S n (blockPure t S n y)) = + inner ℂ (blockPure t S n x) (blockPure t S n y) + | 0, x, y => by + change inner ℂ (t.functional.toPreGNS (t.functional.ofPreGNS (x : preSpace t))) + (t.functional.toPreGNS (t.functional.ofPreGNS (y : preSpace t))) = inner ℂ x y + simp + | n+1, x, y => by + rw [←Completion.inner_coe, blockReadPre_pure, blockReadPre_pure] + change inner ℂ (blockVector t S (x.1::paramLetters t S n x.2) + (factorValue t S j (paramEnd t S n x.2))) + (blockVector t S (y.1::paramLetters t S n y.2) + (factorValue t S j (paramEnd t S n y.2))) = _ + rw [blockVector_cons_gram t S hfree hij _ _ _ _ + (z := factorValue t S j (paramEnd t S n x.2)) + (v := factorValue t S j (paramEnd t S n y.2)) + (paramEnd t S n x.2).property (paramEnd t S n y.2).property] + rw [←blockReadPre_pure, ←blockReadPre_pure, Completion.inner_coe, + inner_blockReadPre_pure n x.2 y.2] + simp only [blockPure, TensorProduct.inner_tmul, mul_assoc] + +lemma inner_blockReadPre (n : ℕ) (x y : blockTensor t S i j n) : + inner ℂ (blockReadPre t S n x) (blockReadPre t S n y) = inner ℂ x y := by + have hx : x ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n)) := by rw [span_blockPure]; trivial + have hy : y ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n)) := by rw [span_blockPure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v,rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => obtain ⟨w,rfl⟩ := hy; exact inner_blockReadPre_pure t S hfree hij n v w + | zero => simp + | add x y _ _ hx hy => simp only [map_add, inner_add_right, hx, hy] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy] + | zero => simp + | add x y _ _ hx hy => simp only [map_add, inner_add_left, hx, hy] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx] + +def blockIsometry (n : ℕ) : blockTensor t S i j n →ₗᵢ[ℂ] preSpace t := + (blockReadPre t S n).isometryOfInner (inner_blockReadPre t S hfree hij n) + +def blockEmbedding (n : ℕ) : Completion (blockTensor t S i j n) →ₗᵢ[ℂ] t.functional.GNS where + toLinearMap := (blockIsometry t S hfree hij n).toContinuousLinearMap.completion.toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => simp + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockTensor2.lean b/lean/OAI/Analysis/Commutator/FreeBlockTensor2.lean new file mode 100644 index 0000000000000000000000000000000000000000..45c825c639987b630fdaff3e7f9232adfb1fe0fa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockTensor2.lean @@ -0,0 +1,178 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) {i j : ι} (hij : i≠j) + +include hij in +lemma blockReadPre_mem_tail (n : ℕ) (x : blockTensor t S i j n) : + (blockReadPre t S n x : t.functional.GNS) ∈ tailSpace t S i := by + have hx : x ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n)) := by rw [span_blockPure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v,rfl⟩ := hx + rw [blockReadPre_pure] + exact blockVector_mem_tail t S hij _ (paramEnd t S n v).property + | zero => simp only [map_zero, Completion.coe_zero, Submodule.zero_mem] + | add x y _ _ hx hy => simpa only [map_add, Completion.coe_add] using + (tailSpace t S i).add_mem hx hy + | smul c x _ hx => simpa only [map_smul, Completion.coe_smul] using + (tailSpace t S i).smul_mem c hx + +include hfree hij in +lemma inner_blockReadPre_ne {n m : ℕ} (hnm : n≠m) + (x : blockTensor t S i j n) (y : blockTensor t S i j m) : + inner ℂ (blockReadPre t S n x) (blockReadPre t S m y)=0 := by + have hx : x ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) n)) := by rw [span_blockPure]; trivial + have hy : y ∈ Submodule.span ℂ (Set.range (blockPure t S (i := i) (j := j) m)) := by rw [span_blockPure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v,rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨w,rfl⟩ := hy + rw [←Completion.inner_coe, blockReadPre_pure, blockReadPre_pure] + exact blockVector_orthogonal t S hfree hij _ _ + (by simpa only [paramLetters_length] using hnm) + (paramEnd t S n v).property (paramEnd t S m w).property + | zero => simp + | add x y _ _ hx hy => simp only [map_add, inner_add_right, hx, hy, add_zero] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy, mul_zero] + | zero => simp + | add x y _ _ hx hy => simp only [map_add, inner_add_left, hx, hy, add_zero] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx, mul_zero] + +def endpointTensor (i j : ι) (n : ℕ) : Space := + spaceTensor ⟨factorSpace t S i⟩ (blockTensor t S i j n) + +def endpointRead (n : ℕ) : endpointTensor t S i j n →ₗ[ℂ] preSpace t := + t.functional.toPreGNS.toLinearMap.comp + ((TensorProduct.lift (LinearMap.mul ℂ A)).comp + (TensorProduct.map (factorValue t S i) (blockRead t S n))) + +lemma endpointRead_tmul (n : ℕ) (a : factorSpace t S i) (x : blockTensor t S i j n) : + (endpointRead t S n (a ⊗ₜ[ℂ] x) : t.functional.GNS) = + t.functional.gnsStarAlgHom (factorValue t S i a) + (blockReadPre t S n x : t.functional.GNS) := by + change (t.functional.toPreGNS (factorValue t S i a * blockRead t S n x) : + t.functional.GNS) = _ + simp [blockReadPre, PositiveLinearMap.gnsStarAlgHom] + +lemma endpointTensor_induction_on (n : ℕ) {P : endpointTensor t S i j n → Prop} + (x : endpointTensor t S i j n) (h0 : P 0) + (ht : ∀ a : factorSpace t S i, ∀ b : blockTensor t S i j n, P (a ⊗ₜ[ℂ] b)) + (ha : ∀ x y : endpointTensor t S i j n, P x → P y → P (x+y)) : P x := by + by_cases hx : x = 0 + · simpa only [hx] using h0 + · exact TensorProduct.inductionOn x ht ha + +include hfree hij in +lemma inner_endpointRead_tmul (n : ℕ) (a b : factorSpace t S i) + (x y : blockTensor t S i j n) : + inner ℂ (endpointRead t S n (a ⊗ₜ[ℂ] x)) (endpointRead t S n (b ⊗ₜ[ℂ] y)) = + inner ℂ (a ⊗ₜ[ℂ] x) (b ⊗ₜ[ℂ] y) := by + rw [←Completion.inner_coe, endpointRead_tmul, endpointRead_tmul, + inner_mul_two_tailSpace t S hfree i (a := factorValue t S i a) + (b := factorValue t S i b) a.property b.property + (blockReadPre_mem_tail t S hij n x) (blockReadPre_mem_tail t S hij n y), + Completion.inner_coe, inner_blockReadPre t S hfree hij] + rw [TensorProduct.inner_tmul] + rfl + +include hfree hij in +lemma inner_endpointRead (n : ℕ) (x y : endpointTensor t S i j n) : + inner ℂ (endpointRead t S n x) (endpointRead t S n y)=inner ℂ x y := by + induction x using endpointTensor_induction_on t S n with + | h0 => simp + | ha x z hx hz => simpa only [map_add, inner_add_left] using congrArg₂ (·+·) hx hz + | ht a x => + change inner ℂ (endpointRead t S n (a ⊗ₜ[ℂ] x)) (endpointRead t S n y) = + inner ℂ (a ⊗ₜ[ℂ] x : endpointTensor t S i j n) y + induction y using endpointTensor_induction_on t S n with + | h0 => + rw [map_zero, inner_zero_right] + exact (inner_zero_right (𝕜 := ℂ) (E := endpointTensor t S i j n) (a ⊗ₜ[ℂ] x)).symm + | ha y z hy hz => + rw [map_add, inner_add_right] + exact (congrArg₂ (·+·) hy hz).trans + (inner_add_right (𝕜 := ℂ) (E := endpointTensor t S i j n) (a ⊗ₜ[ℂ] x) y z).symm + | ht b y => exact inner_endpointRead_tmul t S hfree hij n a b x y + +include hfree hij in +lemma inner_endpointRead_ne {n m : ℕ} (hnm : n≠m) + (x : endpointTensor t S i j n) (y : endpointTensor t S i j m) : + inner ℂ (endpointRead t S n x) (endpointRead t S m y)=0 := by + induction x using endpointTensor_induction_on t S n with + | h0 => simp + | ha x z hx hz => simp only [map_add, inner_add_left, hx, hz, add_zero] + | ht a x => + induction y using endpointTensor_induction_on t S m with + | h0 => simp + | ha y z hy hz => simp only [map_add, inner_add_right, hy, hz, add_zero] + | ht b y => + rw [←Completion.inner_coe, endpointRead_tmul, endpointRead_tmul, + inner_mul_two_tailSpace t S hfree i (a := factorValue t S i a) + (b := factorValue t S i b) a.property b.property + (blockReadPre_mem_tail t S hij n x) (blockReadPre_mem_tail t S hij m y), + Completion.inner_coe, inner_blockReadPre_ne t S hfree hij hnm, mul_zero] + +def endpointIsometry (n : ℕ) : endpointTensor t S i j n →ₗᵢ[ℂ] preSpace t := + (endpointRead t S n).isometryOfInner (inner_endpointRead t S hfree hij n) + +def levelEmbedding (n : ℕ) : Completion (endpointTensor t S i j n) →ₗᵢ[ℂ] t.functional.GNS where + toLinearMap := (endpointIsometry t S hfree hij n).toContinuousLinearMap.completion.toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => simp + +@[simp] lemma levelEmbedding_coe (n : ℕ) (x : endpointTensor t S i j n) : + levelEmbedding t S hfree hij n (x : Completion (endpointTensor t S i j n)) = + (endpointRead t S n x : t.functional.GNS) := by + change (endpointIsometry t S hfree hij n).toContinuousLinearMap.completion _ = _ + simp [endpointIsometry] + +lemma levelEmbedding_orthogonal {n m : ℕ} (hnm : n≠m) + (x : Completion (endpointTensor t S i j n)) (y : Completion (endpointTensor t S i j m)) : + inner ℂ (levelEmbedding t S hfree hij n x) (levelEmbedding t S hfree hij m y) = 0 := by + induction x, y using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih x y => + rw [levelEmbedding_coe, levelEmbedding_coe, Completion.inner_coe] + exact inner_endpointRead_ne t S hfree hij hnm x y + +lemma levelFamily_orthogonal : + OrthogonalFamily ℂ (fun n => Completion (endpointTensor t S i j n)) + (levelEmbedding t S hfree hij) := by + intro n m hnm x y + exact levelEmbedding_orthogonal t S hfree hij hnm x y + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockTensor3.lean b/lean/OAI/Analysis/Commutator/FreeBlockTensor3.lean new file mode 100644 index 0000000000000000000000000000000000000000..b44143a259f871da60bd2907c45305574bd80acf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockTensor3.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (hcolors : ∀ c : ι, c=i ∨ c=j) + +def factorOf (i : ι) (a : A) (ha : a∈S i) : factorSpace t S i := + ⟨t.functional.toPreGNS a, by simpa [factorSpace] using ha⟩ + +def letterOf (i : ι) (a : A) (ha : a∈S i) (ha0 : t.functional a=0) : letterSpace t S i := + ⟨t.functional.toPreGNS a, by simpa [letterSpace] using And.intro ha ha0⟩ + +@[simp] lemma factorValue_factorOf (i : ι) (a : A) (ha : a∈S i) : + factorValue t S i (factorOf t S i a ha)=a := by simp [factorValue, factorOf] + +@[simp] lemma letterValue_letterOf (i : ι) (a : A) (ha : a∈S i) (ha0 : t.functional a=0) : + letterValue t S i (letterOf t S i a ha ha0)=a := by simp [letterValue, letterOf] + +include hcolors in +lemma tail_word_as_block (w : List (Letter t S)) (hw : Reduced w) + (hiw : CanPrepend t S i w) : + ∃ (n : ℕ) (p : BlockParams t S i j n), word w = blockRead t S n (blockPure t S n p) := by + induction w using List.twoStepInduction with + | nil => + refine ⟨0, factorOf t S j 1 (one_mem _), ?_⟩ + exact (factorValue_factorOf t S j 1 (one_mem _)).symm + | singleton a => + have hai : i≠a.color := by simpa [CanPrepend] using hiw + have haj : a.color=j := (hcolors a.color).resolve_left (Ne.symm hai) + refine ⟨0, factorOf t S j a.val (haj ▸ a.mem), ?_⟩ + simp only [word_cons, word_nil, mul_one, blockRead, blockPure, factorValue_factorOf] + | cons_cons a b w ih => + have hai : i≠a.color := by simpa [CanPrepend] using hiw + have haj : a.color=j := (hcolors a.color).resolve_left (Ne.symm hai) + have hbi : b.color=i := (hcolors b.color).resolve_right (by + intro hbj; exact hw.rel (haj.trans hbj.symm)) + have hiw' : CanPrepend t S i w := by + cases w with + | nil => simp [CanPrepend] + | cons c w => simpa [CanPrepend, hbi] using hw.tail.rel + obtain ⟨n,p,hp⟩ := ih hw.tail.tail hiw' + let aa := letterOf t S j a.val (haj ▸ a.mem) a.centered + let bb := letterOf t S i b.val (hbi ▸ b.mem) b.centered + refine ⟨n+1, ((aa,bb),p), ?_⟩ + change a.val*(b.val*word w) = letterValue t S j aa * + (letterValue t S i bb * blockRead t S n (blockPure t S n p)) + simp only [aa, bb, letterValue_letterOf, hp] + +include hcolors in +lemma word_as_endpoint (w : List (Letter t S)) (hw : Reduced w) : + ∃ (n : ℕ) (x : endpointTensor t S i j n), + (t.functional.toPreGNS (word w))=endpointRead t S n x := by + classical + by_cases hiw : CanPrepend t S i w + · obtain ⟨n,p,hp⟩ := tail_word_as_block t S hcolors w hw hiw + refine ⟨n, factorOf t S i 1 (one_mem _) ⊗ₜ[ℂ] blockPure t S n p, ?_⟩ + change t.functional.toPreGNS (word w) = t.functional.toPreGNS + (factorValue t S i (factorOf t S i 1 (one_mem _))*blockRead t S n (blockPure t S n p)) + rw [factorValue_factorOf, one_mul, hp] + · cases w with + | nil => exact False.elim (hiw (by simp [CanPrepend])) + | cons a w => + have hai : a.color=i := by simpa [CanPrepend] using (show i=a.color by simpa [CanPrepend] using hiw).symm + have hiw' : CanPrepend t S i w := by + cases w with + | nil => simp [CanPrepend] + | cons b w => simpa [CanPrepend, hai] using hw.rel + obtain ⟨n,p,hp⟩ := tail_word_as_block t S hcolors w hw.tail hiw' + refine ⟨n, factorOf t S i a.val (hai ▸ a.mem) ⊗ₜ[ℂ] blockPure t S n p, ?_⟩ + change t.functional.toPreGNS (a.val*word w) = t.functional.toPreGNS + (factorValue t S i (factorOf t S i a.val (hai ▸ a.mem))*blockRead t S n (blockPure t S n p)) + rw [factorValue_factorOf, hp] + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockTensor4.lean b/lean/OAI/Analysis/Commutator/FreeBlockTensor4.lean new file mode 100644 index 0000000000000000000000000000000000000000..f0a707ed46abc6a2e38d1bb3c46cf483228b8687 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockTensor4.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.FreeBlockTensor3 +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) {i j : ι} (hij : i≠j) + +variable (hcolors : ∀ c : ι, c=i ∨ c=j) + +include hcolors + +lemma wordVector_mem_levels (w : List (Letter t S)) (hw : Reduced w) : + wordVector t S w ∈ ⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap := by + obtain ⟨n,x,hx⟩ := word_as_endpoint t S hcolors w hw + apply Submodule.mem_iSup_of_mem n + refine ⟨(x : Completion (endpointTensor t S i j n)), ?_⟩ + rw [LinearIsometry.coe_toLinearMap, levelEmbedding_coe] + exact congrArg (fun x : preSpace t => (x : t.functional.GNS)) hx.symm + +lemma generated_mem_levels {a : A} (ha : a ∈ iSup S) : + (t.functional.toPreGNS a : t.functional.GNS) ∈ + ⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap := by + have ha' : a ∈ FreeMoments.wordSpan S t.functional.toLinearMap := by + change a ∈ (FreeMoments.reducedAlgebra S (fun a => map_star t.functional a) t.normalized) + rw [FreeMoments.reducedAlgebra_eq_iSup] + exact ha + clear ha + induction ha' using Submodule.span_induction with + | mem a ha => obtain ⟨w,hw,rfl⟩ := ha; exact wordVector_mem_levels t S hfree hij hcolors w hw + | zero => simp only [map_zero, Completion.coe_zero, Submodule.zero_mem] + | add a b _ _ ha hb => simpa only [map_add, Completion.coe_add] using + (⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap).add_mem ha hb + | smul c a _ ha => simpa only [map_smul, Completion.coe_smul] using + (⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap).smul_mem c ha + +lemma total_levels + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + (⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap).topologicalClosure=⊤ := by + apply Submodule.eq_top_iff'.mpr + intro x + induction x using Completion.induction_on with + | hp => exact (⨆ n, LinearMap.range + (levelEmbedding t S hfree hij n).toLinearMap).isClosed_topologicalClosure + | ih x => + let ξ : t.functional.GNS := (t.functional.toPreGNS 1 : t.functional.GNS) + have h := Kadison.bicommutant_mem_cyclicSubspace (generatedOperators t S) + (hgen (t.functional.ofPreGNS x)) ξ + have heq : t.functional.gnsStarAlgHom (t.functional.ofPreGNS x) ξ = + (x : t.functional.GNS) := by + simp [ξ, PositiveLinearMap.gnsStarAlgHom] + rw [heq] at h + apply Submodule.topologicalClosure_mono ?_ h + rintro y ⟨a,ha,rfl⟩ + obtain ⟨b,hb,rfl⟩ := ha + simpa [ξ, PositiveLinearMap.gnsStarAlgHom] using generated_mem_levels t S hfree hij hcolors hb + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockWords.lean b/lean/OAI/Analysis/Commutator/FreeBlockWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..99a37fd9a3a9a05a9277c2cf4ff4f67cf26875cd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockWords.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeCreation + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor UniformSpace + +open scoped InnerProductSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +include hfree in +lemma inner_mul_two_wordVector {i : ι} {w z : List (Letter t S)} + (hw : Reduced w) (hz : Reduced z) + (hiw : CanPrepend t S i w) (hiz : CanPrepend t S i z) + {a b : A} (ha : a ∈ S i) (hb : b ∈ S i) : + inner ℂ (t.functional.gnsStarAlgHom a (wordVector t S w)) + (t.functional.gnsStarAlgHom b (wordVector t S z)) = + t.functional (star a*b)*inner ℂ (wordVector t S w) (wordVector t S z) := by + rw [mul_wordVector, mul_wordVector, Completion.inner_coe, inner_wordVector] + change t.functional (star (a*word w)*(b*word z))=_ + simpa only [star_mul, mul_assoc] using + middle_factor t S hfree hw hz hiw hiz (mul_mem (star_mem ha) hb) + +include hfree in +lemma inner_mul_two_tailSpan (i : ι) {a b : A} (ha : a ∈ S i) (hb : b ∈ S i) + {x y : t.functional.GNS} (hx : x ∈ tailSpan t S i) (hy : y ∈ tailSpan t S i) : + inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom b y) = + t.functional (star a*b)*inner ℂ x y := by + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨w, hw, hiw, rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨z, hz, hiz, rfl⟩ := hy + exact inner_mul_two_wordVector t S hfree hw hz hiw hiz ha hb + | zero => simp + | add y z _ _ hy hz => simp only [map_add, inner_add_right, hy, hz, mul_add] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy]; ring + | zero => simp + | add x z _ _ hx hz => simp only [map_add, inner_add_left, hx, hz, mul_add] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx]; ring + +include hfree in +lemma inner_mul_two_tailSpace (i : ι) {a b : A} (ha : a ∈ S i) (hb : b ∈ S i) + {x y : t.functional.GNS} (hx : x ∈ tailSpace t S i) (hy : y ∈ tailSpace t S i) : + inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom b y) = + t.functional (star a*b)*inner ℂ x y := by + apply closure_minimal (s := (tailSpan t S i : Set _)) + (t := {x | inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom b y) = + t.functional (star a*b)*inner ℂ x y}) ?_ ?_ hx + · intro x hx + apply closure_minimal (s := (tailSpan t S i : Set _)) + (t := {y | inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom b y) = + t.functional (star a*b)*inner ℂ x y}) ?_ ?_ hy + · intro y hy + exact inner_mul_two_tailSpan t S hfree i ha hb hx hy + · apply isClosed_eq <;> fun_prop + · apply isClosed_eq <;> fun_prop + +lemma vacuum_mem_tailSpan (i : ι) : wordVector t S [] ∈ tailSpan t S i := + Submodule.subset_span ⟨[], reduced_nil, by simp [CanPrepend], rfl⟩ + +lemma factor_vector_mem_tailSpan {i j : ι} (hij : i≠j) {a : A} (ha : a∈S j) : + (t.functional.toPreGNS a : t.functional.GNS) ∈ tailSpan t S i := by + let a0 : Letter t S := + ⟨j, a-t.functional a • (1 : A), + sub_mem ha (SMulMemClass.smul_mem _ (one_mem (S j))), + by simp [map_sub, map_smul, t.normalized]⟩ + have hc : wordVector t S [a0] ∈ tailSpan t S i := + Submodule.subset_span ⟨[a0], reduced_singleton _, by simpa [CanPrepend, a0] using hij, rfl⟩ + have hh := (tailSpan t S i).add_mem hc ((tailSpan t S i).smul_mem + (t.functional a) (vacuum_mem_tailSpan t S i)) + convert hh using 1 + simp only [wordVector, word_cons, word_nil, mul_one, a0, map_sub, map_smul, + Completion.coe_sub, Completion.coe_smul, sub_add_cancel] + +lemma factor_vector_mem_tailSpace {i j : ι} (hij : i≠j) {a : A} (ha : a∈S j) : + (t.functional.toPreGNS a : t.functional.GNS) ∈ tailSpace t S i := + (tailSpan t S i).le_topologicalClosure (factor_vector_mem_tailSpan t S hij ha) + +end Kadison.FreeCreation +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeBlockWords2.lean b/lean/OAI/Analysis/Commutator/FreeBlockWords2.lean new file mode 100644 index 0000000000000000000000000000000000000000..1fef52345ea719d7ced09dcc466b18d5cf356bff --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeBlockWords2.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockWords +import OAI.Analysis.Commutator.FreeWordTensor + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) {i j : ι} (hij : i ≠ j) + +abbrev Letters (i j : ι) := letterSpace t S j × letterSpace t S i + +def blockValue : List (Letters t S i j) → A → A + | [], z => z + | x::xs, z => letterValue t S j x.1 * + (letterValue t S i x.2 * blockValue xs z) + +def blockVector (xs : List (Letters t S i j)) (z : A) : t.functional.GNS := + (t.functional.toPreGNS (blockValue t S xs z) : t.functional.GNS) + +@[simp] lemma blockVector_nil (z : A) : blockVector t S ([] : List (Letters t S i j)) z = + (t.functional.toPreGNS z : t.functional.GNS) := rfl + +lemma blockVector_cons (x : Letters t S i j) (xs : List (Letters t S i j)) (z : A) : + blockVector t S (x::xs) z = t.functional.gnsStarAlgHom (letterValue t S j x.1) + (t.functional.gnsStarAlgHom (letterValue t S i x.2) (blockVector t S xs z)) := by + simp [blockVector, blockValue, PositiveLinearMap.gnsStarAlgHom] + +include hij in +lemma blockVector_mem_tail (xs : List (Letters t S i j)) {z : A} (hz : z ∈ S j) : + blockVector t S xs z ∈ tailSpace t S i := by + induction xs with + | nil => exact factor_vector_mem_tailSpace t S hij hz + | cons x xs ih => + rw [blockVector_cons] + apply headSpace_le_other_tailSpace t S hij.symm + apply creation_mem_headSpace t S j x.1.property.1 x.1.property.2 + apply headSpace_le_other_tailSpace t S hij + exact creation_mem_headSpace t S i (a := letterValue t S i x.2) x.2.property.1 x.2.property.2 ih + +include hfree hij in +lemma blockVector_cons_gram (x y : Letters t S i j) + (xs ys : List (Letters t S i j)) {z v : A} (hz : z ∈ S j) (hv : v ∈ S j) : + inner ℂ (blockVector t S (x::xs) z) (blockVector t S (y::ys) v) = + (inner ℂ x.1 y.1 * inner ℂ x.2 y.2)* + inner ℂ (blockVector t S xs z) (blockVector t S ys v) := by + rw [blockVector_cons, blockVector_cons] + have hx := blockVector_mem_tail t S hij xs hz + have hy := blockVector_mem_tail t S hij ys hv + rw [inner_mul_two_tailSpace t S hfree j (a := letterValue t S j x.1) (b := letterValue t S j y.1) x.1.property.1 y.1.property.1 + (headSpace_le_other_tailSpace t S hij + (creation_mem_headSpace t S i (a := letterValue t S i x.2) x.2.property.1 x.2.property.2 hx)) + (headSpace_le_other_tailSpace t S hij + (creation_mem_headSpace t S i (a := letterValue t S i y.2) y.2.property.1 y.2.property.2 hy)), + inner_mul_two_tailSpace t S hfree i (a := letterValue t S i x.2) (b := letterValue t S i y.2) x.2.property.1 y.2.property.1 hx hy] + rw [inner_letter, inner_letter, mul_assoc] + +include hfree hij in +lemma blockVector_cons_nil (x : Letters t S i j) + (xs : List (Letters t S i j)) {z v : A} (hz : z ∈ S j) (hv : v ∈ S j) : + inner ℂ (blockVector t S (x::xs) z) (blockVector t S ([] : List (Letters t S i j)) v) = 0 := by + rw [blockVector_cons, ← ContinuousLinearMap.adjoint_inner_right] + change inner ℂ _ ((star (t.functional.gnsStarAlgHom (letterValue t S j x.1))) _) = 0 + rw [← map_star] + have hm : t.functional.gnsStarAlgHom (star (letterValue t S j x.1)) + (blockVector t S ([] : List (Letters t S i j)) v) = + (t.functional.toPreGNS (star (letterValue t S j x.1)*v) : t.functional.GNS) := by + simp [blockVector_nil, PositiveLinearMap.gnsStarAlgHom] + rw [hm] + have ht := factor_vector_mem_tailSpace t S hij (mul_mem (star_mem x.1.property.1) hv) + have hh := headSpace_le_tailSpace_orthogonal t S hfree i + (creation_mem_headSpace t S i (a := letterValue t S i x.2) x.2.property.1 x.2.property.2 + (blockVector_mem_tail t S hij xs hz)) + exact inner_eq_zero_symm.mp (hh _ ht) + +include hfree hij in +lemma blockVector_orthogonal (xs ys : List (Letters t S i j)) + (hlen : xs.length ≠ ys.length) {z v : A} (hz : z ∈ S j) (hv : v ∈ S j) : + inner ℂ (blockVector t S xs z) (blockVector t S ys v) = 0 := by + induction xs generalizing ys with + | nil => + cases ys with + | nil => exact (hlen rfl).elim + | cons y ys => exact inner_eq_zero_symm.mp (blockVector_cons_nil t S hfree hij y ys hv hz) + | cons x xs ih => + cases ys with + | nil => exact blockVector_cons_nil t S hfree hij x xs hz hv + | cons y ys => + rw [blockVector_cons_gram t S hfree hij x y xs ys hz hv, + ih ys (by simpa using hlen), mul_zero] + +include hfree hij in +lemma endpoint_gram (xs ys : List (Letters t S i j)) {a b z v : A} + (ha : a ∈ S i) (hb : b ∈ S i) (hz : z ∈ S j) (hv : v ∈ S j) : + inner ℂ (t.functional.gnsStarAlgHom a (blockVector t S xs z)) + (t.functional.gnsStarAlgHom b (blockVector t S ys v)) = + t.functional (star a*b)*inner ℂ (blockVector t S xs z) (blockVector t S ys v) := + inner_mul_two_tailSpace t S hfree i ha hb + (blockVector_mem_tail t S hij xs hz) (blockVector_mem_tail t S hij ys hv) + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeCompressionNorm.lean b/lean/OAI/Analysis/Commutator/FreeCompressionNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..4f38235fc993a70c64d61a63c8ea15a9ec589a22 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeCompressionNorm.lean @@ -0,0 +1,315 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeCreation +import OAI.Analysis.Commutator.FreeWordTensor + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FreeCorner + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma three_block_bound (E P T : H →L[ℂ] H) {a b : ℝ} + (hE : ‖E‖ ≤ 1) + (hzero : (1-P)*T*(1-P) = 0) + (hleft : ‖E*P‖ ≤ a) (hright : ‖P*E‖ ≤ a) + (hcreate : ‖T*(1-P)‖ ≤ b) (hannihilate : ‖(1-P)*T‖ ≤ b) : + ‖E*T*E‖ ≤ 2*a*b + a*a*‖T‖ := by + have ha : 0 ≤ a := (norm_nonneg _).trans hleft + have hb : 0 ≤ b := (norm_nonneg _).trans hcreate + have hid : E*T*E = (E*P)*(T*(1-P))*E + + E*((1-P)*T)*(P*E) + (E*P)*T*(P*E) := by + calc + E*T*E = (E*P)*(T*(1-P))*E + E*((1-P)*T)*(P*E) + + (E*P)*T*(P*E) + E*((1-P)*T*(1-P))*E := by noncomm_ring + _ = _ := by rw [hzero, mul_zero, zero_mul, add_zero] + have h1 : ‖(E*P)*(T*(1-P))*E‖ ≤ a*b := by + calc + _ ≤ ‖E*P‖ * ‖T*(1-P)‖ * ‖E‖ := norm_mul₃_le + _ ≤ a*b*1 := mul_le_mul + (mul_le_mul hleft hcreate (norm_nonneg _) ha) hE (norm_nonneg _) (mul_nonneg ha hb) + _ = _ := mul_one _ + have h2 : ‖E*((1-P)*T)*(P*E)‖ ≤ a*b := by + calc + _ ≤ ‖E‖ * ‖(1-P)*T‖ * ‖P*E‖ := norm_mul₃_le + _ ≤ 1*b*a := mul_le_mul + (mul_le_mul hE hannihilate (norm_nonneg _) zero_le_one) hright + (norm_nonneg _) (by positivity) + _ = _ := by ring + have h3 : ‖(E*P)*T*(P*E)‖ ≤ a*a*‖T‖ := by + calc + _ ≤ ‖E*P‖ * ‖T‖ * ‖P*E‖ := norm_mul₃_le + _ ≤ a*‖T‖*a := mul_le_mul + (mul_le_mul_of_nonneg_right hleft (norm_nonneg _)) hright + (norm_nonneg _) (by positivity) + _ = _ := by ring + rw [hid] + exact (norm_add₃_le).trans (by linarith) + +end Kadison.FreeCorner + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +lemma gns_injective : Function.Injective t.functional.gnsStarAlgHom := by + intro a b hab + have h := congrArg (fun T : t.functional.GNS →L[ℂ] t.functional.GNS => + T (t.functional.toPreGNS 1 : t.functional.GNS)) hab + have hab' : (t.functional.toPreGNS a : t.functional.GNS) = + (t.functional.toPreGNS b : t.functional.GNS) := by + simpa [PositiveLinearMap.gnsStarAlgHom] using h + exact t.functional.toPreGNS.injective (Completion.coe_injective _ hab') + +lemma norm_gns (a : A) : ‖t.functional.gnsStarAlgHom a‖ = ‖a‖ := + NonUnitalStarAlgHom.norm_map _ (gns_injective t) a + +lemma norm_preGNS_projection {e : A} (he : IsStarProjection e) : + ‖t.functional.toPreGNS e‖ = Real.sqrt (t.functional e).re := by + rw [t.functional.preGNS_norm_def] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, he.isSelfAdjoint.star_eq, + he.isIdempotentElem.eq] + +lemma norm_preGNS_projection_sq {e : A} (he : IsStarProjection e) : + ‖t.functional.toPreGNS e‖ ^ 2 = (t.functional e).re := by + have hn := t.functional.preGNS_norm_sq (t.functional.toPreGNS e) + have h := congrArg Complex.re hn + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS, he.isSelfAdjoint.star_eq, + he.isIdempotentElem.eq, RCLike.ofReal_eq_complex_ofReal, + ← Complex.ofReal_pow, Complex.ofReal_re] using h + +include hfree in +lemma one_sub_headProjection (i : ι) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + 1 - (headSpace t S i).starProjection = (tailSpace t S i).starProjection := by + simp only [headSpace_eq_tailSpace_orthogonal t S hfree i hgen, + Submodule.starProjection_orthogonal', sub_sub_cancel] + +include hfree in +lemma norm_left_headProjection {i j : ι} (hij : i ≠ j) {a : A} (ha : a ∈ S i) : + ‖t.functional.gnsStarAlgHom a * (headSpace t S j).starProjection‖ ≤ + ‖t.functional.toPreGNS a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + change ‖t.functional.gnsStarAlgHom a ((headSpace t S j).starProjection x)‖ ≤ _ + rw [norm_mul_tailSpace t S hfree i ha + (headSpace_le_other_tailSpace t S hij.symm ((headSpace t S j).starProjection_apply_mem x))] + exact mul_le_mul_of_nonneg_left ((headSpace t S j).norm_starProjection_apply_le x) + (norm_nonneg _) + +include hfree in +lemma norm_right_headProjection {i j : ι} (hij : i ≠ j) {a : A} + (ha : a ∈ S i) (haStar : IsSelfAdjoint a) : + ‖(headSpace t S j).starProjection * t.functional.gnsStarAlgHom a‖ ≤ + ‖t.functional.toPreGNS a‖ := by + have heq : star (t.functional.gnsStarAlgHom a * (headSpace t S j).starProjection) = + (headSpace t S j).starProjection * t.functional.gnsStarAlgHom a := by + rw [star_mul, (isSelfAdjoint_starProjection _).star_eq, + (haStar.map t.functional.gnsStarAlgHom).star_eq] + rw [← heq, norm_star] + exact norm_left_headProjection t S hfree hij ha + +include hfree in +lemma norm_creation (i : ι) {a : A} (ha : a ∈ S i) : + ‖t.functional.gnsStarAlgHom a * (tailSpace t S i).starProjection‖ ≤ + ‖t.functional.toPreGNS a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + change ‖t.functional.gnsStarAlgHom a ((tailSpace t S i).starProjection x)‖ ≤ _ + rw [norm_mul_tailSpace t S hfree i ha ((tailSpace t S i).starProjection_apply_mem x)] + exact mul_le_mul_of_nonneg_left ((tailSpace t S i).norm_starProjection_apply_le x) + (norm_nonneg _) + +include hfree in +lemma norm_annihilation (i : ι) {a : A} (ha : a ∈ S i) (haStar : IsSelfAdjoint a) : + ‖(tailSpace t S i).starProjection * t.functional.gnsStarAlgHom a‖ ≤ + ‖t.functional.toPreGNS a‖ := by + have heq : star (t.functional.gnsStarAlgHom a * (tailSpace t S i).starProjection) = + (tailSpace t S i).starProjection * t.functional.gnsStarAlgHom a := by + rw [star_mul, (isSelfAdjoint_starProjection _).star_eq, + (haStar.map t.functional.gnsStarAlgHom).star_eq] + rw [← heq, norm_star] + exact norm_creation t S hfree i ha + +include hfree in +lemma creation_zero_block (i : ι) {a : A} (ha : a ∈ S i) (ha0 : t.functional a = 0) : + (tailSpace t S i).starProjection * t.functional.gnsStarAlgHom a * + (tailSpace t S i).starProjection = 0 := by + ext x + change (tailSpace t S i).starProjection + (t.functional.gnsStarAlgHom a ((tailSpace t S i).starProjection x)) = 0 + rw [Submodule.starProjection_apply, Submodule.coe_eq_zero] + apply Submodule.orthogonalProjectionOnto_apply_of_mem_orthogonal + apply headSpace_le_tailSpace_orthogonal t S hfree i + exact creation_mem_headSpace t S i ha ha0 ((tailSpace t S i).starProjection_apply_mem x) + +include hfree in +theorem free_compression_norm {i j : ι} (hij : i ≠ j) {e b : A} + (he : IsStarProjection e) (he_mem : e ∈ S i) + (hb : IsSelfAdjoint b) (hb_mem : b ∈ S j) (hb0 : t.functional b = 0) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + ‖e*b*e‖ ≤ 2 * Real.sqrt (t.functional e).re * ‖t.functional.toPreGNS b‖ + + (t.functional e).re * ‖b‖ := by + let π := t.functional.gnsStarAlgHom + let P := (headSpace t S j).starProjection + have hP : 1 - P = (tailSpace t S j).starProjection := + one_sub_headProjection t S hfree j hgen + have h := Kadison.FreeCorner.three_block_bound (π e) P (π b) + (a := ‖t.functional.toPreGNS e‖) (b := ‖t.functional.toPreGNS b‖) + ((he.map π).norm_le _) (by rw [hP]; exact creation_zero_block t S hfree j hb_mem hb0) + (norm_left_headProjection t S hfree hij he_mem) + (norm_right_headProjection t S hfree hij he_mem he.isSelfAdjoint) + (by rw [hP]; exact norm_creation t S hfree j hb_mem) + (by rw [hP]; exact norm_annihilation t S hfree j hb_mem hb) + have hn : ‖t.functional.toPreGNS e‖ * ‖t.functional.toPreGNS e‖ = + (t.functional e).re := by simpa only [pow_two] using norm_preGNS_projection_sq t he + rw [hn, norm_preGNS_projection t he] at h + simpa only [π, ← map_mul, norm_gns] using h + +end Kadison.FreeCreation + +namespace Kadison.FreeMoments + +variable {A B : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + [Ring B] [Algebra ℂ B] [StarRing B] [StarModule ℂ B] + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + (f : B →⋆ₐ[ℂ] A) + +def liftLetter (a : Letter (fun i => (S i).comap f) (τ.comp f.toLinearMap)) : Letter S τ := + ⟨a.color,f a.val,a.mem,a.centered⟩ + +@[simp] lemma liftLetter_color (a) : (liftLetter S τ f a).color=a.color := rfl + +@[simp] lemma liftLetter_val (a) : (liftLetter S τ f a).val=f a.val := rfl + +lemma word_liftLetter (w : List (Letter (fun i => (S i).comap f) (τ.comp f.toLinearMap))) : + word (w.map (liftLetter S τ f))=f (word w) := by + induction w with + | nil => simp + | cons a w ih => simp only [List.map_cons,word_cons,liftLetter_val,ih,map_mul] + +lemma Free.comap (h : Free S τ) : Free (fun i => (S i).comap f) (τ.comp f.toLinearMap) := by + intro w hw hne + have hr : Reduced (w.map (liftLetter S τ f)) := by + rw [Reduced,List.isChain_map] + exact hw + have hz := h (w.map (liftLetter S τ f)) hr (by simpa using hne) + change τ (f (word w))=0 + rwa [word_liftLetter] at hz + +end Kadison.FreeMoments + +namespace Kadison.FreeWordTensor + +open scoped ComplexOrder + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +def restrictedState : FaithfulState D where + functional := + { toLinearMap := t.functional.toLinearMap.comp f.toLinearMap + monotone' := fun _ _ hab => t.functional.monotone + ((NonUnitalStarRingHom.ofClass f).map_le_map_of_map_star hab) } + normalized := by change t.functional (f 1)=1; simpa using t.normalized + faithful := by + intro a ha + apply hf + rw [map_zero] + apply t.faithful + change t.functional (f (star a*a))=0 at ha + simpa only [map_mul,map_star] using ha + +end Kadison.FreeWordTensor + +namespace Kadison.FreeCreation + +open FreeWordTensor + +open scoped ComplexOrder + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) + +include hfree in +theorem free_compression_norm_intrinsic {i j : ι} (hij : i≠j) {e b : A} + (he : IsStarProjection e) (he_mem : e∈S i) + (hb : IsSelfAdjoint b) (hb_mem : b∈S j) (hb0 : t.functional b=0) : + ‖e*b*e‖ ≤ 2*Real.sqrt (t.functional e).re*‖t.functional.toPreGNS b‖ + + (t.functional e).re*‖b‖ := by + let C := (iSup S).topologicalClosure + let : IsClosed (C : Set A) := StarSubalgebra.isClosed_topologicalClosure _ + let : PartialOrder C := CStarAlgebra.spectralOrder C + let : StarOrderedRing C := CStarAlgebra.spectralOrderedRing C + let f : C →⋆ₐ[ℂ] A := C.subtype + let tC := restrictedState t f Subtype.val_injective + let R : ι → StarSubalgebra ℂ C := fun i => (S i).comap f + have hR : FreeMoments.Free R tC.functional.toLinearMap := hfree.comap S _ f + have hinc : iSup S ≤ (iSup R).map f := by + apply iSup_le + intro k a ha + exact ⟨⟨a,StarSubalgebra.le_topologicalClosure _ ((le_iSup S k) ha)⟩, + (le_iSup R k) ha,rfl⟩ + have hgen : ∀ a : C, tC.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators tC R : Set _)) := by + let inc : ↥(iSup S) → C := fun x => ⟨x.val,StarSubalgebra.le_topologicalClosure _ x.property⟩ + have hd : DenseRange inc := by + change DenseRange (Set.inclusion (StarSubalgebra.le_topologicalClosure (iSup S))) + apply (denseRange_inclusion_iff _).2 + exact fun _ h => h + intro a + apply closure_minimal (s := Set.range inc) ?_ + ((Set.isClosed_centralizer _).preimage + (AddMonoidHomClass.continuous_of_bound tC.functional.gnsStarAlgHom 1 + (by intro x; simpa using NonUnitalStarAlgHom.norm_apply_le tC.functional.gnsStarAlgHom x))) (hd a) + rintro _ ⟨x,rfl⟩ + have hm : inc x ∈ iSup R := by + obtain ⟨y,hy,hxy⟩ := hinc x.property + have heq : y=inc x := Subtype.ext hxy + exact heq ▸ hy + exact Set.subset_centralizer_centralizer ⟨inc x,hm,rfl⟩ + let eC : C := ⟨e,StarSubalgebra.le_topologicalClosure _ ((le_iSup S i) he_mem)⟩ + let bC : C := ⟨b,StarSubalgebra.le_topologicalClosure _ ((le_iSup S j) hb_mem)⟩ + have heC : IsStarProjection eC := ⟨by apply Subtype.ext; exact he.isIdempotentElem, + by apply Subtype.ext; exact he.isSelfAdjoint⟩ + have hbC : IsSelfAdjoint bC := by apply Subtype.ext; exact hb + have h := free_compression_norm tC R hR hij heC he_mem hbC hb_mem hb0 hgen + have hn : ‖tC.functional.toPreGNS bC‖=‖t.functional.toPreGNS b‖ := by + rw [PositiveLinearMap.preGNS_norm_def,PositiveLinearMap.preGNS_norm_def] + rfl + rw [hn] at h + exact h + +end Kadison.FreeCreation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeCornerFromUnitary.lean b/lean/OAI/Analysis/Commutator/FreeCornerFromUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9007c818bece5704fa13123bbfc0dda078d7c51 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeCornerFromUnitary.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.Commutator.AbstractFreeCornerFromUnitary +import OAI.Analysis.Commutator.ConstantSequenceRange + +namespace OAI + +noncomputable section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching.ConjugatedWords + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R≤M) + +variable (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (size : ℕ → ℕ) + +variable (stage : ∀ n,Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] M) + +variable (inc : ∀ {n m : ℕ},n ≤ m → Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] + Matrix (Fin (size m+1)) (Fin (size m+1)) ℂ) + +theorem freeCornerPosition_of_unitary + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ), + stage n a*b=b*stage n a) → ∃ c : ℂ,b=algebraMap ℂ M c) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hinc : ∀ n m (h : n ≤ m) a,stage m (inc h a)=stage n a) + (hsize : ∀ n q : ℕ,∃ m,n ≤ m ∧ q ≤ size m+1) + (U : unitary (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)) + (hu : (U:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence (NormalSubalgebra.inclusion M R hRM)))) + (hfree : FreeMoments.Free (pair (A := M) (B := boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) (constantAction τ ω) U) (sequenceTrace τ ω).toLinearMap) : + Nonempty (FreeCornerPosition τ ω R (NormalSubalgebra.inclusion M R hRM)) := by + apply freeCornerPosition_of_unitary_abstract R (NormalSubalgebra.inclusion M R hRM) + τ ω size stage inc hτ hω (constant_range_bicommutant M τ ω hτ hnormal) + hfaith hone hirr _ hinc hsize U hu hfree + intro n a + exact ⟨⟨stage n a,hstage n a⟩,rfl⟩ + +end Kadison.TracialSequence +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeCovariance.lean b/lean/OAI/Analysis/Commutator/FreeCovariance.lean new file mode 100644 index 0000000000000000000000000000000000000000..89e0e5a9b601931b31527a8b57ef637cc74937fe --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeCovariance.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry14 +import OAI.Analysis.Commutator.FreeSymmetry6 +import OAI.Analysis.Commutator.TensorMultiplicity2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace +open scoped InnerProductSpace ENNReal +open ContinuousLinearMap +open scoped InnerProductSpace ENNReal +open scoped ComplexOrder InnerProductSpace TensorProduct +open UniformSpace ContinuousLinearMap + +namespace Kadison.FreeBlocks + +open FreeWordTensor UniformSpace PreHilbert + +open scoped ComplexOrder InnerProductSpace TensorProduct + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +def factorBounded (d : D) : factorSpace t S i := + factorPreMap t f hf S i hS ((pullbackState t f hf).functional.toPreGNS d) + +lemma factorBounded_surjective : Function.Surjective (factorBounded t f hf S i hS) := by + intro a + obtain ⟨v,hv⟩ := factorPreMap_surjective t f hf S i hS a + refine ⟨(pullbackState t f hf).functional.ofPreGNS v,?_⟩ + simpa only [factorBounded,PositiveLinearMap.toPreGNS_ofPreGNS] using hv + +@[simp] lemma factorBounded_value (d : D) : + factorValue t S i (factorBounded t f hf S i hS d)=f d := rfl + +@[simp] lemma factorBounded_GNS (d : D) : + factorGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (aLetters t S i) (factorBounded t f hf S i hS d)) = + TracialGNS.algebraVector (factorTrace t f hf) d := by + exact factorGNSIso_coe t f hf S i hS d + +def levelWord (d : D) (n : ℕ) (x : BlockParams t S i j n) : sourceLevel t f hf S j n := + HilbertTensor.pair (E := sourceScalar t f hf n) (J := multiplicityLevel t S j n) + (by + exact PreHilbert.word (factorFull t f hf) + (factorZero t f hf) n + (TracialGNS.algebraVector (factorTrace t f hf) d) + (fun k => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) (paramD t S n x k)))) + (paramJ t S n x : multiplicityLevel t S j n) + +lemma sourceLevelShuffle_bounded (d : D) (n : ℕ) (x : BlockParams t S i j n) : + sourceLevelShuffle t f hf S i j hS n + (HilbertCompletion.coeIsometry (endpointTensor t S i j n) + (factorBounded t f hf S i hS d ⊗ₜ[ℂ] blockPure t S n x)) = + levelWord t f hf S i j hS d n x := by + have result := sourceLevelShuffle_pure t f hf S i j hS n (factorBounded t f hf S i hS d) x + rw [factorBounded_GNS] at result + dsimp only [levelWord, sourceScalar, factorFull, factorZero, TracialGNS.fullSpace, + TracialGNS.zeroSpace, TracialGNS.vacuum, factorTrace, HilbertCompletion.centered, + centeredSpace] at result ⊢ + exact result + +def endpointCoordinate (n : ℕ) : endpointTensor t S i j n →ₗ[ℂ] sourceLevel t f hf S j n := + (sourceLevelShuffle t f hf S i j hS n).toLinearMap.comp + (HilbertCompletion.coeIsometry (endpointTensor t S i j n)).toLinearMap + +lemma endpointCoordinate_pure (d : D) (n : ℕ) (x : BlockParams t S i j n) : + endpointCoordinate t f hf S i j hS n + (factorBounded t f hf S i hS d ⊗ₜ[ℂ] blockPure t S n x) = + levelWord t f hf S i j hS d n x := + sourceLevelShuffle_bounded t f hf S i j hS d n x + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + +lemma sourceLevel_ext (n : ℕ) (F G : sourceLevel t f hf S j n →L[ℂ] E) + (h : ∀ d x, F (levelWord t f hf S i j hS d n x)=G (levelWord t f hf S i j hS d n x)) : + F=G := by + ext v + obtain ⟨v,rfl⟩ := (sourceLevelShuffle t f hf S i j hS n).surjective v + change F (sourceLevelShuffle t f hf S i j hS n v)=G (sourceLevelShuffle t f hf S i j hS n v) + induction v using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih v => + change F (endpointCoordinate t f hf S i j hS n v)=G (endpointCoordinate t f hf S i j hS n v) + induction v using endpointTensor_induction_on t S n with + | h0 => simp + | ha v w hv hw => simpa only [map_add] using congrArg₂ (·+·) hv hw + | ht a b => + obtain ⟨d,rfl⟩ := factorBounded_surjective t f hf S i hS a + let Q : blockTensor t S i j n →ₗ[ℂ] endpointTensor t S i j n := + TensorProduct.mk ℂ (factorSpace t S i) (blockTensor t S i j n) + (factorBounded t f hf S i hS d) + let K : blockTensor t S i j n →ₗ[ℂ] E := + ((F.toLinearMap-G.toLinearMap).comp (endpointCoordinate t f hf S i j hS n)).comp Q + have hker : Submodule.span ℂ (Set.range (blockPure t S (i:=i) (j:=j) n)) ≤ K.ker := by + apply Submodule.span_le.mpr + rintro _ ⟨x,rfl⟩ + change F (endpointCoordinate t f hf S i j hS n + (factorBounded t f hf S i hS d ⊗ₜ[ℂ] blockPure t S n x)) - + G (endpointCoordinate t f hf S i j hS n + (factorBounded t f hf S i hS d ⊗ₜ[ℂ] blockPure t S n x))=0 + exact sub_eq_zero.mpr ((congrArg F (endpointCoordinate_pure t f hf S i j hS d n x)).trans + ((h d x).trans (congrArg G (endpointCoordinate_pure t f hf S i j hS d n x)).symm)) + have hb : b∈Submodule.span ℂ (Set.range (blockPure t S (i:=i) (j:=j) n)) := by + rw [span_blockPure]; trivial + exact sub_eq_zero.mp (hker hb) + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) (hij : i≠j) + +lemma sourceLevelEmbedding_word (d : D) (n : ℕ) (x : BlockParams t S i j n) : + sourceLevelEmbedding t f hf S i j hS hfree hij n (levelWord t f hf S i j hS d n x) = + t.functional.gnsStarAlgHom (f d) + (blockReadPre t S n (blockPure t S n x) : t.functional.GNS) := by + rw [←sourceLevelShuffle_bounded,sourceLevelEmbedding_shuffle] + exact (levelEmbedding_coe t S hfree hij n + (factorBounded t f hf S i hS d ⊗ₜ[ℂ] blockPure t S n x)).trans + (endpointRead_tmul t S n (factorBounded t f hf S i hS d) (blockPure t S n x)) + +def sourceLeft (a : D) (n : ℕ) : sourceLevel t f hf S j n →L[ℂ] sourceLevel t f hf S j n := + HilbertTensor.map + (HilbertTensor.map ((factorTrace t f hf).gnsStarAlgHom a) + (1 : power (factorZero t f hf) n →L[ℂ] power (factorZero t f hf) n)) + (1 : multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +lemma sourceLeft_word (a d : D) (n : ℕ) (x : BlockParams t S i j n) : + sourceLeft t f hf S j a n (levelWord t f hf S i j hS d n x)= + levelWord t f hf S i j hS (a*d) n x := by + simp only [sourceLeft, levelWord, PreHilbert.word, HilbertTensor.map_pair, + HilbertTensor.map_coe_tmul, one_apply_eq_self, TracialGNS.algebraVector_apply, + TracialGNS.left_coe] + +lemma sourceLevelEmbedding_left (a : D) (n : ℕ) : + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap.comp + (sourceLeft t f hf S j a n) = + (t.functional.gnsStarAlgHom (f a)).comp + (sourceLevelEmbedding t f hf S i j hS hfree hij n).toContinuousLinearMap := by + apply sourceLevel_ext t f hf S i j hS + intro d x + simp only [ContinuousLinearMap.comp_apply,LinearIsometry.coe_toContinuousLinearMap, + sourceLeft_word,sourceLevelEmbedding_word,map_mul] + rfl + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeCreation.lean b/lean/OAI/Analysis/Commutator/FreeCreation.lean new file mode 100644 index 0000000000000000000000000000000000000000..9b7de335e1fb2d2e91f9d0d2216f68841daf9156 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeCreation.lean @@ -0,0 +1,324 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.FreeMoments +import OAI.Analysis.Commutator.FreeWordDecomposition + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +abbrev Letter := FreeMoments.Letter S t.functional.toLinearMap + +def wordVector (w : List (Letter t S)) : t.functional.GNS := + (t.functional.toPreGNS (word w) : t.functional.GNS) + +lemma inner_wordVector (w z : List (Letter t S)) : + inner ℂ (wordVector t S w) (wordVector t S z) = + t.functional (star (word w) * word z) := by + rw [wordVector, wordVector, Completion.inner_coe] + rfl + +lemma mul_wordVector (a : A) (w : List (Letter t S)) : + t.functional.gnsStarAlgHom a (wordVector t S w) = + (t.functional.toPreGNS (a * word w) : t.functional.GNS) := by + simp [wordVector, PositiveLinearMap.gnsStarAlgHom] + +def CanPrepend (i : ι) (w : List (Letter t S)) : Prop := + ∀ a ∈ w.head?, i ≠ a.color + +lemma reduced_prepend {i : ι} {w : List (Letter t S)} (hw : Reduced w) + (hi : CanPrepend t S i w) (a : Letter t S) (ha : a.color = i) : + Reduced (a :: w) := by + cases w with + | nil => exact reduced_singleton a + | cons b w => + exact List.isChain_cons_cons.mpr ⟨by simpa [ha] using hi b (by simp), hw⟩ + +lemma colors_ne_prepend {i : ι} {w z : List (Letter t S)} + (hi : CanPrepend t S i w) (a : Letter t S) (ha : a.color = i) : + w.map FreeMoments.Letter.color ≠ (a :: z).map FreeMoments.Letter.color := by + cases w with + | nil => simp + | cons b w => + intro h + have hc : b.color = a.color := (List.cons.inj h).1 + exact hi b (by simp) (ha ▸ hc.symm) + +include hfree in +lemma centered_middle_zero {i : ι} {w z : List (Letter t S)} + (hw : Reduced w) (hz : Reduced z) + (hiw : CanPrepend t S i w) (hiz : CanPrepend t S i z) + (a : Letter t S) (ha : a.color = i) : + t.functional (star (word w) * (a.val * word z)) = 0 := by + change t.functional.toLinearMap (star (word w) * word (a :: z)) = 0 + rw [gram_word (fun a => map_star t.functional a) t.normalized hfree _ _ hw + (reduced_prepend t S hz hiz a ha)] + exact gram_zero_of_colors_ne _ _ (colors_ne_prepend t S hiw a ha) + +include hfree in +lemma middle_factor {i : ι} {w z : List (Letter t S)} + (hw : Reduced w) (hz : Reduced z) + (hiw : CanPrepend t S i w) (hiz : CanPrepend t S i z) + {a : A} (ha : a ∈ S i) : + t.functional (star (word w) * (a * word z)) = + t.functional a * t.functional (star (word w) * word z) := by + let a0 : Letter t S := + ⟨i, a - t.functional a • (1 : A), + sub_mem ha (SMulMemClass.smul_mem _ (one_mem (S i))), + by simp [map_sub, map_smul, t.normalized]⟩ + have h := centered_middle_zero t S hfree hw hz hiw hiz a0 rfl + change t.functional (star (word w) * + ((a - t.functional a • (1 : A)) * word z)) = 0 at h + simp only [sub_mul, smul_mul_assoc, one_mul, mul_sub, mul_smul_comm, + map_sub, map_smul] at h + exact sub_eq_zero.mp h + +include hfree in +lemma inner_mul_wordVector {i : ι} {w z : List (Letter t S)} + (hw : Reduced w) (hz : Reduced z) + (hiw : CanPrepend t S i w) (hiz : CanPrepend t S i z) + {a : A} (ha : a ∈ S i) : + inner ℂ (t.functional.gnsStarAlgHom a (wordVector t S w)) + (t.functional.gnsStarAlgHom a (wordVector t S z)) = + t.functional (star a * a) * inner ℂ (wordVector t S w) (wordVector t S z) := by + rw [mul_wordVector, mul_wordVector, Completion.inner_coe, inner_wordVector] + change t.functional (star (a * word w) * (a * word z)) = _ + simpa only [star_mul, mul_assoc] using + middle_factor t S hfree hw hz hiw hiz (mul_mem (star_mem ha) ha) + +def tailSpan (i : ι) : Submodule ℂ t.functional.GNS := + Submodule.span ℂ {x | ∃ w : List (Letter t S), + Reduced w ∧ CanPrepend t S i w ∧ wordVector t S w = x} + +def tailSpace (i : ι) : Submodule ℂ t.functional.GNS := + (tailSpan t S i).topologicalClosure + +instance (i : ι) : IsClosed ((tailSpace t S i : Submodule ℂ t.functional.GNS) : Set t.functional.GNS) := + (tailSpan t S i).isClosed_topologicalClosure + +include hfree in +lemma inner_mul_tailSpan (i : ι) {a : A} (ha : a ∈ S i) + {x y : t.functional.GNS} (hx : x ∈ tailSpan t S i) (hy : y ∈ tailSpan t S i) : + inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom a y) = + t.functional (star a * a) * inner ℂ x y := by + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨w, hw, hiw, rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨z, hz, hiz, rfl⟩ := hy + exact inner_mul_wordVector t S hfree hw hz hiw hiz ha + | zero => simp + | add y z _ _ hy hz => simp only [map_add, inner_add_right, hy, hz, mul_add] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy]; ring + | zero => simp + | add x z _ _ hx hz => simp only [map_add, inner_add_left, hx, hz, mul_add] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx]; ring + +include hfree in +lemma inner_mul_tailSpace (i : ι) {a : A} (ha : a ∈ S i) + {x y : t.functional.GNS} (hx : x ∈ tailSpace t S i) (hy : y ∈ tailSpace t S i) : + inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom a y) = + t.functional (star a * a) * inner ℂ x y := by + apply closure_minimal (s := (tailSpan t S i : Set _)) + (t := {x | inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom a y) = + t.functional (star a * a) * inner ℂ x y}) ?_ ?_ hx + · intro x hx + apply closure_minimal (s := (tailSpan t S i : Set _)) + (t := {y | inner ℂ (t.functional.gnsStarAlgHom a x) (t.functional.gnsStarAlgHom a y) = + t.functional (star a * a) * inner ℂ x y}) ?_ ?_ hy + · intro y hy + exact inner_mul_tailSpan t S hfree i ha hx hy + · apply isClosed_eq <;> fun_prop + · apply isClosed_eq <;> fun_prop + +include hfree in +lemma norm_mul_tailSpace (i : ι) {a : A} (ha : a ∈ S i) + {x : t.functional.GNS} (hx : x ∈ tailSpace t S i) : + ‖t.functional.gnsStarAlgHom a x‖ = ‖t.functional.toPreGNS a‖ * ‖x‖ := by + have h := inner_mul_tailSpace t S hfree i ha hx hx + have hn := t.functional.preGNS_norm_sq (t.functional.toPreGNS a) + change (‖t.functional.toPreGNS a‖ : ℂ) ^ 2 = t.functional (star a * a) at hn + rw [inner_self_eq_norm_sq_to_K, inner_self_eq_norm_sq_to_K, ← hn] at h + have hr : ‖t.functional.gnsStarAlgHom a x‖ ^ 2 = + ‖t.functional.toPreGNS a‖ ^ 2 * ‖x‖ ^ 2 := by + have hr := congrArg Complex.re h + simpa only [RCLike.ofReal_eq_complex_ofReal, ← Complex.ofReal_pow, + ← Complex.ofReal_mul, Complex.ofReal_re] using hr + nlinarith [norm_nonneg (t.functional.gnsStarAlgHom a x), + mul_nonneg (norm_nonneg (t.functional.toPreGNS a)) (norm_nonneg x)] + +def Starts (i : ι) (w : List (Letter t S)) : Prop := + ∃ a z, w = a :: z ∧ a.color = i + +def headSpan (i : ι) : Submodule ℂ t.functional.GNS := + Submodule.span ℂ {x | ∃ w : List (Letter t S), + Reduced w ∧ Starts t S i w ∧ wordVector t S w = x} + +def headSpace (i : ι) : Submodule ℂ t.functional.GNS := + (headSpan t S i).topologicalClosure + +instance (i : ι) : IsClosed ((headSpace t S i : Submodule ℂ t.functional.GNS) : Set t.functional.GNS) := + (headSpan t S i).isClosed_topologicalClosure + +include hfree in +lemma headSpace_le_tailSpace_orthogonal (i : ι) : + headSpace t S i ≤ (tailSpace t S i)ᗮ := by + apply (headSpan t S i).topologicalClosure_minimal ?_ (Submodule.isClosed_orthogonal _) + rw [tailSpace, Submodule.orthogonal_closure] + apply Submodule.span_le.mpr + rintro x ⟨z, hz, ⟨a, z, rfl, ha⟩, rfl⟩ + intro y hy + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨w, hw, hiw, rfl⟩ := hy + rw [inner_wordVector] + change t.functional.toLinearMap (star (word w) * word (a :: z)) = 0 + rw [gram_word (fun a => map_star t.functional a) t.normalized hfree _ _ hw hz] + exact gram_zero_of_colors_ne _ _ (colors_ne_prepend t S hiw a ha) + | zero => simp + | add y z _ _ hy hz => simp [inner_add_left, hy, hz] + | smul c y _ hy => simp [inner_smul_left, hy] + +lemma headSpace_le_other_tailSpace {i j : ι} (hij : i ≠ j) : + headSpace t S i ≤ tailSpace t S j := by + apply Submodule.topologicalClosure_mono + apply Submodule.span_le.mpr + rintro x ⟨w, hw, ⟨a, z, rfl, ha⟩, rfl⟩ + apply Submodule.subset_span + refine ⟨a :: z, hw, ?_, rfl⟩ + intro b hb + have hb' : b = a := (by simpa using hb : a = b).symm + subst b + simpa [ha] using hij.symm + +lemma creation_mem_headSpan (i : ι) {a : A} (ha : a ∈ S i) + (ha0 : t.functional a = 0) {x : t.functional.GNS} (hx : x ∈ tailSpan t S i) : + t.functional.gnsStarAlgHom a x ∈ headSpan t S i := by + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨w, hw, hiw, rfl⟩ := hx + let b : Letter t S := ⟨i, a, ha, ha0⟩ + apply Submodule.subset_span + refine ⟨b :: w, reduced_prepend t S hw hiw b rfl, ⟨b, w, rfl, rfl⟩, ?_⟩ + rw [mul_wordVector] + rfl + | zero => simp + | add x y _ _ hx hy => simpa using (headSpan t S i).add_mem hx hy + | smul c x _ hx => simpa using (headSpan t S i).smul_mem c hx + +lemma creation_mem_headSpace (i : ι) {a : A} (ha : a ∈ S i) + (ha0 : t.functional a = 0) {x : t.functional.GNS} (hx : x ∈ tailSpace t S i) : + t.functional.gnsStarAlgHom a x ∈ headSpace t S i := by + apply closure_minimal (s := (tailSpan t S i : Set _)) + (t := {x | t.functional.gnsStarAlgHom a x ∈ headSpace t S i}) ?_ ?_ hx + · intro x hx + exact (headSpan t S i).le_topologicalClosure + (creation_mem_headSpan t S i ha ha0 hx) + · exact (headSpan t S i).isClosed_topologicalClosure.preimage + (t.functional.gnsStarAlgHom a).continuous + +lemma wordVector_mem_head_sup_tail (i : ι) (w : List (Letter t S)) (hw : Reduced w) : + wordVector t S w ∈ headSpace t S i ⊔ tailSpace t S i := by + classical + cases w with + | nil => + apply Submodule.mem_sup_right + apply (tailSpan t S i).le_topologicalClosure + exact Submodule.subset_span ⟨[], hw, by simp [CanPrepend], rfl⟩ + | cons a w => + by_cases hi : a.color = i + · apply Submodule.mem_sup_left + apply (headSpan t S i).le_topologicalClosure + exact Submodule.subset_span ⟨a :: w, hw, ⟨a, w, rfl, hi⟩, rfl⟩ + · apply Submodule.mem_sup_right + apply (tailSpan t S i).le_topologicalClosure + exact Submodule.subset_span ⟨a :: w, hw, by simpa [CanPrepend] using Ne.symm hi, rfl⟩ + +lemma generated_mem_head_sup_tail (i : ι) {a : A} (ha : a ∈ iSup S) : + (t.functional.toPreGNS a : t.functional.GNS) ∈ headSpace t S i ⊔ tailSpace t S i := by + have ha' : a ∈ FreeMoments.wordSpan S t.functional.toLinearMap := by + change a ∈ (FreeMoments.reducedAlgebra S (fun a => map_star t.functional a) t.normalized) + rw [FreeMoments.reducedAlgebra_eq_iSup] + exact ha + clear ha + induction ha' using Submodule.span_induction with + | mem a ha => + obtain ⟨w, hw, rfl⟩ := ha + exact wordVector_mem_head_sup_tail t S i w hw + | zero => simp only [map_zero, Completion.coe_zero, Submodule.zero_mem] + | add a b _ _ ha hb => simpa only [map_add, Completion.coe_add] using + (headSpace t S i ⊔ tailSpace t S i).add_mem ha hb + | smul c a _ ha => simpa only [map_smul, Completion.coe_smul] using + (headSpace t S i ⊔ tailSpace t S i).smul_mem c ha + +lemma total_head_sup_tail (i : ι) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + (headSpace t S i ⊔ tailSpace t S i).topologicalClosure = ⊤ := by + apply Submodule.eq_top_iff'.mpr + intro x + induction x using Completion.induction_on with + | hp => exact (headSpace t S i ⊔ tailSpace t S i).isClosed_topologicalClosure + | ih x => + let ξ : t.functional.GNS := (t.functional.toPreGNS 1 : t.functional.GNS) + have h := Kadison.bicommutant_mem_cyclicSubspace (generatedOperators t S) + (hgen (t.functional.ofPreGNS x)) ξ + have heq : t.functional.gnsStarAlgHom (t.functional.ofPreGNS x) ξ = + (x : t.functional.GNS) := by + simp [ξ, PositiveLinearMap.gnsStarAlgHom] + rw [heq] at h + apply Submodule.topologicalClosure_mono ?_ h + rintro y ⟨a, ha, rfl⟩ + obtain ⟨b, hb, rfl⟩ := ha + simpa [ξ, PositiveLinearMap.gnsStarAlgHom] using generated_mem_head_sup_tail t S i hb + +include hfree in +lemma headSpace_eq_tailSpace_orthogonal (i : ι) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + headSpace t S i = (tailSpace t S i)ᗮ := by + apply le_antisymm (headSpace_le_tailSpace_orthogonal t S hfree i) + intro x hx + let P := headSpace t S i + have hp : P.starProjection x ∈ P := P.starProjection_apply_mem x + have hy : x - P.starProjection x ∈ Pᗮ ⊓ (tailSpace t S i)ᗮ := + ⟨P.sub_starProjection_mem_orthogonal x, + (tailSpace t S i)ᗮ.sub_mem hx (headSpace_le_tailSpace_orthogonal t S hfree i hp)⟩ + have hbot : Pᗮ ⊓ (tailSpace t S i)ᗮ = ⊥ := by + rw [Submodule.inf_orthogonal, ← Submodule.orthogonal_closure, + total_head_sup_tail t S i hgen, Submodule.top_orthogonal_eq_bot] + rw [hbot, Submodule.mem_bot] at hy + rw [sub_eq_zero.mp hy] + exact hp + +end Kadison.FreeCreation +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeDihedralColumns.lean b/lean/OAI/Analysis/Commutator/FreeDihedralColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..ab84a917c40f4088e5abe85b8f253e88c6cfe50a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeDihedralColumns.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeHilbertEntries +import OAI.Analysis.Commutator.FreeNormalizedColumns + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor DihedralCorner + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (hfree : Free S t.functional.toLinearMap) + +lemma norm_letterOf_unitary (i : Bool) (u : unitary A) + (hu : (u:A)∈S i) (hu0 : t.functional (u:A)=0) : + ‖letterOf t S i (u:A) hu hu0‖=1 := by + change ‖t.functional.toPreGNS (u:A)‖=1 + rw [PositiveLinearMap.preGNS_norm_def] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS] + rw [Unitary.star_mul_self_of_mem u.property,t.normalized,Complex.one_re,Real.sqrt_one] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma dihedral_negative_wave (d s : unitary A) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) (n : ℕ) : + wave (d*s) (-(n:ℤ))=((s:A)*(d:A))^n := by + have hd : d⁻¹=d := inv_eq_of_mul_eq_one_right (Subtype.ext hd2) + have hs : s⁻¹=s := inv_eq_of_mul_eq_one_right (Subtype.ext hs2) + rw [wave,zpow_neg,zpow_natCast,←inv_pow,mul_inv_rev,hd,hs] + simp only [Submonoid.coe_mul,SubmonoidClass.coe_pow] + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S false=f.range) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) + +variable (e : D) (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e‖) + +include hd2 hs2 in +theorem normalizedColumn_eq_dihedral (n : ℕ) : + (normalizedColumn t S f hf hS hfree Bool.false_ne_true e + (letterOf t S true (s:A) hs hs0) (norm_letterOf_unitary t S true s hs hs0) + (letterOf t S false (d:A) hd hd0) (norm_letterOf_unitary t S false d hd hd0) hr n + ).toContinuousLinearMap= + dihedralColumn t S hfree (f e) (d*s) + ‖TracialGNS.algebraVector (factorTrace t f hf) e‖⁻¹ n := by + apply ContinuousLinearMap.ext + intro v + induction v using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih v => + change normalizedColumn t S f hf hS hfree Bool.false_ne_true e + (letterOf t S true (s:A) hs hs0) (norm_letterOf_unitary t S true s hs hs0) + (letterOf t S false (d:A) hd hd0) (norm_letterOf_unitary t S false d hd hd0) hr n + (v : multiplicityLevel t S true 0)=_ + rw [normalizedColumn_apply,repeatedOutput_bounded] + rw [letterValue_letterOf,letterValue_letterOf] + rw [dihedralColumn_coe,dihedral_negative_wave d s hd2 hs2] + change (_:ℂ) • t.functional.gnsStarAlgHom (f e) + (t.functional.gnsStarAlgHom (((s:A)*(d:A))^n) + (baseEmbedding t S hfree (v : multiplicityLevel t S true 0)))=_ + rw [baseEmbedding_coe,TracialGNS.left_coe,TracialGNS.left_coe] + apply congrArg (fun a : A => + ((‖TracialGNS.algebraVector (factorTrace t f hf) e‖⁻¹:ℝ):ℂ) • + (t.functional.toPreGNS a : t.functional.GNS)) + exact (mul_assoc _ _ _).symm + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeDihedralEntries.lean b/lean/OAI/Analysis/Commutator/FreeDihedralEntries.lean new file mode 100644 index 0000000000000000000000000000000000000000..6357735670f2cd1290bf8a2876aea1af1f6b06cf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeDihedralEntries.lean @@ -0,0 +1,158 @@ +import Mathlib +import OAI.Analysis.Commutator.DihedralExpectationEntries +import OAI.Analysis.Commutator.FreeHilbertEntries + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor DihedralCorner + +lemma inner_scaled_operator_apply {E : Type*} [NormedAddCommGroup E] + [InnerProductSpace ℂ E] (α β γ : ℂ) (T : E →L[ℂ] E) (v z : E) : + inner ℂ z ((α • (β • ContinuousLinearMap.id ℂ E+γ • T)) v)= + α*(β*inner ℂ z v+γ*inner ℂ z (T v)) := by + change inner ℂ z (α • (β • v+γ • T v))=_ + rw [inner_smul_right,inner_add_right,inner_smul_right,inner_smul_right] + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (hfree : Free S t.functional.toLinearMap) + +lemma base_compression_of_entries + (U V : multiplicityLevel t S true 0 →L[ℂ] t.functional.GNS) + (L : t.functional.GNS →L[ℂ] t.functional.GNS) + (α β γ : ℂ) (R : multiplicityLevel t S true 0 →L[ℂ] multiplicityLevel t S true 0) + (hh : ∀ v z : factorSpace t S true, + inner ℂ (U (z : multiplicityLevel t S true 0)) + (L (V (v : multiplicityLevel t S true 0)))= + α*(β*inner ℂ (z : multiplicityLevel t S true 0) (v : multiplicityLevel t S true 0)+ + γ*inner ℂ (z : multiplicityLevel t S true 0) (R (v : multiplicityLevel t S true 0)))) : + (ContinuousLinearMap.adjoint (E := multiplicityLevel t S true 0) (F := t.functional.GNS) U).comp + (L.comp V)=α • (β • ContinuousLinearMap.id ℂ (multiplicityLevel t S true 0)+γ • R) := by + apply base_operator_ext t S + intro v z + dsimp only [ContinuousLinearMap.comp_apply] + rw [ContinuousLinearMap.adjoint_inner_right + (E := multiplicityLevel t S true 0) (F := t.functional.GNS)] + change inner ℂ (U (z : multiplicityLevel t S true 0)) + (L (V (v : multiplicityLevel t S true 0)))= + inner ℂ (z : Completion (factorSpace t S true)) + (α • (β • (v : Completion (factorSpace t S true))+ + γ • R (v : multiplicityLevel t S true 0))) + rw [inner_smul_right (𝕜 := ℂ) (E := Completion (factorSpace t S true)),inner_add_right (𝕜 := ℂ) (E := Completion (factorSpace t S true)), + inner_smul_right (𝕜 := ℂ) (E := Completion (factorSpace t S true)),inner_smul_right (𝕜 := ℂ) (E := Completion (factorSpace t S true))] + exact hh v z + +variable (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hr : MulAut.conj d (d*s)=(d*s)⁻¹) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) + +variable {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + (hpD : p∈S false) + +variable (e b : Corner hp) (he : e∈cornerFactor hp (S false) hpD) + (hb : b∈cosineAlgebra (d*s) d hr hp hpform hdp) + (hb0 : halfCornerTrace hp t.functional.toLinearMap b=0) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma corner_projection_coe (heproj : IsStarProjection e) : IsStarProjection (e:A) where + isSelfAdjoint := by + show star (e:A)=(e:A) + exact congrArg (fun a : Corner hp => (a:A)) heproj.isSelfAdjoint.star_eq + isIdempotentElem := by + show (e:A)*(e:A)=(e:A) + exact congrArg (fun a : Corner hp => (a:A)) heproj.isIdempotentElem.eq + +omit [PartialOrder A] [StarOrderedRing A] in +lemma sandwich_supported (heproj : IsStarProjection e) : + (e:A)*((e:A)*(b:A)*(e:A))*(e:A)=(e:A)*(b:A)*(e:A) := by + have h := (corner_projection_coe hp (e := e) heproj).isIdempotentElem.eq + calc + _ = ((e:A)*(e:A))*(b:A)*((e:A)*(e:A)) := by simp only [mul_assoc] + _ = _ := by rw [h] + +include htr hd hs hd0 hs0 hd2 hs2 hpd he hb hb0 in +theorem dihedral_entry_pairing (heproj : IsStarProjection e) + (c : ℝ) (n m : ℕ) (v z : factorSpace t S true) : + inner ℂ (dihedralColumn t S hfree (e:A) (d*s) c n (z : multiplicityLevel t S true 0)) + (t.functional.gnsStarAlgHom ((e:A)*(b:A)*(e:A)) + (dihedralColumn t S hfree (e:A) (d*s) c m (v : multiplicityLevel t S true 0)))= + ((c:ℂ)^2*(halfCornerTrace hp t.functional.toLinearMap e)^2)* + (t.functional (wave (d*s) ((n:ℤ)-m)*(b:A))* + inner ℂ (z : multiplicityLevel t S true 0) (v : multiplicityLevel t S true 0)+ + t.functional (wave (d*s) ((n:ℤ)+m+1)*(b:A))* + inner ℂ (z : multiplicityLevel t S true 0) + (baseAction t S hfree (s:A) (v : multiplicityLevel t S true 0))) := by + rw [dihedralColumn_inner t S hfree (e:A) _ (corner_projection_coe hp (e := e) heproj) + (sandwich_supported hp (e := e) (b := b) heproj),base_inner,baseAction_inner] + have hv : factorValue t S true v∈S true := by exact v.property + have hz : factorValue t S true z∈S true := by exact z.property + have hh := compression_expectation_pairing S t.functional.toLinearMap t.normalized htr + (fun a => map_star t.functional a) hfree d s hd hs hd0 hs0 hr hd2 hs2 + hp hpform hpd hdp hpD e b he hb hb0 ((S true).mul_mem hv ((S true).star_mem' hz)) + (n:ℤ) (m:ℤ) + have hrot : t.functional (star (factorValue t S true z)* + (wave (d*s) (n:ℤ)*((e:A)*(b:A)*(e:A))*wave (d*s) (-(m:ℤ)))* + factorValue t S true v)= + t.functional ((factorValue t S true v*star (factorValue t S true z))* + (wave (d*s) (n:ℤ)*((e:A)*(b:A)*(e:A))*wave (d*s) (-(m:ℤ)))) := by + rw [htr] + congr 1 + exact mul_assoc _ _ _ |>.symm + rw [hrot] + change (c:ℂ)^2*t.functional.toLinearMap _=_ + rw [hh] + have hrot0 := htr (factorValue t S true v) (star (factorValue t S true z)) + have hrot1 : t.functional (factorValue t S true v*star (factorValue t S true z)*(s:A))= + t.functional (star (factorValue t S true z)*(s:A)*factorValue t S true v) := by + rw [mul_assoc,htr] + change (c:ℂ)^2*(t.functional _*_ * t.functional _ +t.functional _*_ * t.functional _)=_ + rw [hrot0,hrot1] + ring + +include htr hd hs hd0 hs0 hd2 hs2 hpd he hb hb0 in +theorem dihedral_entry_operator (heproj : IsStarProjection e) + (c : ℝ) (n m : ℕ) : + (ContinuousLinearMap.adjoint (E := multiplicityLevel t S true 0) (F := t.functional.GNS) + (dihedralColumn t S hfree (e:A) (d*s) c n)).comp + ((t.functional.gnsStarAlgHom ((e:A)*(b:A)*(e:A))).comp + (dihedralColumn t S hfree (e:A) (d*s) c m))= + ((c:ℂ)^2*(halfCornerTrace hp t.functional.toLinearMap e)^2) • + (t.functional (wave (d*s) ((n:ℤ)-m)*(b:A)) • + ContinuousLinearMap.id ℂ (multiplicityLevel t S true 0)+ + t.functional (wave (d*s) ((n:ℤ)+m+1)*(b:A)) • baseAction t S hfree (s:A)) := by + exact base_compression_of_entries t S + (dihedralColumn t S hfree (e:A) (d*s) c n) + (dihedralColumn t S hfree (e:A) (d*s) c m) + (t.functional.gnsStarAlgHom ((e:A)*(b:A)*(e:A))) + ((c:ℂ)^2*(halfCornerTrace hp t.functional.toLinearMap e)^2) + (t.functional (wave (d*s) ((n:ℤ)-m)*(b:A))) + (t.functional (wave (d*s) ((n:ℤ)+m+1)*(b:A))) + (baseAction t S hfree (s:A)) + (dihedral_entry_pairing t S hfree htr d s hd hs hd0 hs0 hr hd2 hs2 + hp hpform hpd hdp hpD e b he hb hb0 heproj c n m) + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeExpectation.lean b/lean/OAI/Analysis/Commutator/FreeExpectation.lean new file mode 100644 index 0000000000000000000000000000000000000000..394a868f90d79187e26fc8a003ba80dc5b29d2df --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeExpectation.lean @@ -0,0 +1,267 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeWordTensor + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison.FreeMoments + +attribute [local instance] Classical.propDecidable + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +variable {S τ} + +variable (hstar : ∀ a : A, τ (star a) = star (τ a)) + +variable (h1 : τ 1 = 1) + +end Kadison.FreeMoments + +open scoped InnerProductSpace TensorProduct ComplexOrder + +open UniformSpace + +namespace Kadison.FreeWordTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +attribute [instance] Space.normed Space.inner + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) + +include hfree + +end Kadison.FreeWordTensor + +open scoped InnerProductSpace Topology + +noncomputable section + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +end Kadison + +namespace Kadison.FreeWordTensor + +open scoped InnerProductSpace Topology + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) + +end Kadison.FreeWordTensor + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +end Kadison.FreeCreation + +namespace Kadison.FreeCorner + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +end Kadison.FreeCorner + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +end Kadison.FreeCreation + +namespace Kadison.FreeExpectation + +open FreeMoments FreeWordTensor + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +lemma centered_mem {i : ι} {a : A} (ha : a ∈ S i) : + a - t.functional a • (1 : A) ∈ S i := + sub_mem ha (SMulMemClass.smul_mem _ (one_mem (S i))) + +lemma centered_zero (a : A) : t.functional (a - t.functional a • (1 : A)) = 0 := by + simp [map_sub, map_smul, t.normalized] + +include hfree in +lemma free_two {i j : ι} (hij : i ≠ j) {a b : A} (ha : a ∈ S i) (hb : b ∈ S j) + (ha0 : t.functional a = 0) (hb0 : t.functional b = 0) : + t.functional (a*b) = 0 := by + let x : Letter S t.functional.toLinearMap := ⟨i, a, ha, ha0⟩ + let y : Letter S t.functional.toLinearMap := ⟨j, b, hb, hb0⟩ + have h := hfree [x, y] (by simpa [Reduced, List.isChain_cons_cons, x, y]) (by simp) + simpa [word, x, y] using h + +include hfree in +lemma free_three {i j : ι} (hij : i ≠ j) {a b c : A} + (ha : a ∈ S i) (hb : b ∈ S j) (hc : c ∈ S i) + (ha0 : t.functional a = 0) (hb0 : t.functional b = 0) (hc0 : t.functional c = 0) : + t.functional (a*b*c) = 0 := by + let x : Letter S t.functional.toLinearMap := ⟨i, a, ha, ha0⟩ + let y : Letter S t.functional.toLinearMap := ⟨j, b, hb, hb0⟩ + let z : Letter S t.functional.toLinearMap := ⟨i, c, hc, hc0⟩ + have h := hfree [x, y, z] + (by simp [Reduced, List.isChain_cons_cons, x, y, z, hij, hij.symm]) (by simp) + simpa [word, x, y, z, mul_assoc] using h + +include hfree in +lemma free_four {i j : ι} (hij : i ≠ j) {a b c d : A} + (ha : a ∈ S i) (hb : b ∈ S j) (hc : c ∈ S i) (hd : d ∈ S j) + (ha0 : t.functional a = 0) (hb0 : t.functional b = 0) + (hc0 : t.functional c = 0) (hd0 : t.functional d = 0) : + t.functional (a*b*c*d) = 0 := by + let x : Letter S t.functional.toLinearMap := ⟨i, a, ha, ha0⟩ + let y : Letter S t.functional.toLinearMap := ⟨j, b, hb, hb0⟩ + let z : Letter S t.functional.toLinearMap := ⟨i, c, hc, hc0⟩ + let w : Letter S t.functional.toLinearMap := ⟨j, d, hd, hd0⟩ + have h := hfree [x, y, z, w] + (by simp [Reduced, List.isChain_cons_cons, x, y, z, w, hij, hij.symm]) (by simp) + simpa [word, x, y, z, w, mul_assoc] using h + +include hfree in +lemma centered_mul_zero {i j : ι} (hij : i ≠ j) {a b : A} + (ha : a ∈ S i) (hb : b ∈ S j) (ha0 : t.functional a = 0) : + t.functional (a*b) = 0 := by + have h := free_two t S hfree hij ha (centered_mem t S hb) ha0 (centered_zero t b) + simpa [mul_sub, mul_smul_comm, map_sub, map_smul, ha0] using h + +include hfree in +lemma mul_centered_zero {i j : ι} (hij : i ≠ j) {a b : A} + (ha : a ∈ S i) (hb : b ∈ S j) (hb0 : t.functional b = 0) : + t.functional (a*b) = 0 := by + have h := free_two t S hfree hij (centered_mem t S ha) hb (centered_zero t a) hb0 + simpa [sub_mul, smul_mul_assoc, map_sub, map_smul, hb0] using h + +include hfree in +lemma centered_middle_pairing {i j : ι} (hij : i ≠ j) {a b c : A} + (ha : a ∈ S i) (hb : b ∈ S j) (hc : c ∈ S j) + (ha0 : t.functional a = 0) (hb0 : t.functional b = 0) : + t.functional (c*a*b) = 0 := by + have h := free_three t S hfree hij.symm (centered_mem t S hc) ha hb + (centered_zero t c) ha0 hb0 + have hab := free_two t S hfree hij ha hb ha0 hb0 + simpa [sub_mul, smul_mul_assoc, map_sub, map_smul, hab, mul_assoc] using h + +include hfree in +lemma centered_sandwich_pairing {i j : ι} (hij : i ≠ j) {a b c : A} + (ha : a ∈ S i) (hb : b ∈ S j) (hc : c ∈ S j) + (ha0 : t.functional a = 0) (hb0 : t.functional b = 0) : + t.functional (c*a*b*a) = 0 := by + have h := free_four t S hfree hij.symm (centered_mem t S hc) ha hb ha + (centered_zero t c) ha0 hb0 ha0 + have hab := free_three t S hfree hij ha hb ha ha0 hb0 ha0 + simpa [sub_mul, smul_mul_assoc, map_sub, map_smul, hab] using h + +include hfree in +theorem free_compression_pairing {i j : ι} (hij : i ≠ j) {e b c : A} + (he : e ∈ S i) (hb : b ∈ S j) (hc : c ∈ S j) (hb0 : t.functional b = 0) : + t.functional (c * (e*b*e)) = (t.functional e)^2 * t.functional (c*b) := by + let a := e - t.functional e • (1 : A) + have ha : a ∈ S i := centered_mem t S he + have ha0 : t.functional a = 0 := centered_zero t e + have h1 := centered_sandwich_pairing t S hfree hij ha hb hc ha0 hb0 + have h2 := centered_middle_pairing t S hfree hij ha hb hc ha0 hb0 + have h3 := mul_centered_zero t S hfree hij.symm (mul_mem hc hb) ha ha0 + have hid : c * (e*b*e) = c*a*b*a + t.functional e • (c*a*b) + + t.functional e • (c*b*a) + ((t.functional e)^2) • (c*b) := by + dsimp [a] + simp only [sub_mul, mul_sub, smul_mul_assoc, mul_smul_comm, mul_one, + smul_sub, smul_smul, pow_two] + noncomm_ring + rw [hid] + simp only [map_add, map_smul, h1, h2, h3, smul_eq_mul, mul_zero, zero_add] + +def factorSpace (j : ι) : Submodule ℂ t.functional.GNS := + (Submodule.map ((UniformSpace.Completion.toComplₗᵢ : + t.functional.PreGNS →ₗᵢ[ℂ] t.functional.GNS).toLinearMap.comp + t.functional.toPreGNS.toLinearMap) (S j).toSubmodule).topologicalClosure + +instance (j : ι) : IsClosed (factorSpace t S j : Set t.functional.GNS) := + Submodule.isClosed_topologicalClosure _ + +lemma vector_mem_factorSpace {j : ι} {b : A} (hb : b ∈ S j) : + (t.functional.toPreGNS b : t.functional.GNS) ∈ factorSpace t S j := + Submodule.le_topologicalClosure _ ⟨b, hb, rfl⟩ + +include hfree in +lemma compression_error_orthogonal {i j : ι} (hij : i ≠ j) {e b : A} + (he : e ∈ S i) (hb : b ∈ S j) (hb0 : t.functional b = 0) : + (t.functional.toPreGNS (e*b*e) : t.functional.GNS) - + (t.functional e)^2 • (t.functional.toPreGNS b : t.functional.GNS) ∈ + (factorSpace t S j)ᗮ := by + rw [Submodule.mem_orthogonal] + intro x hx + apply closure_minimal (s := (Submodule.map ((UniformSpace.Completion.toComplₗᵢ : + t.functional.PreGNS →ₗᵢ[ℂ] t.functional.GNS).toLinearMap.comp + t.functional.toPreGNS.toLinearMap) (S j).toSubmodule : Set _)) ?_ + (isClosed_eq (continuous_id.inner continuous_const) continuous_const) hx + rintro _ ⟨c, hc, rfl⟩ + change inner ℂ (t.functional.toPreGNS c : t.functional.GNS) _ = 0 + rw [inner_sub_right, inner_smul_right, Completion.inner_coe, Completion.inner_coe] + change t.functional (star c * (e*b*e)) - (t.functional e)^2 * + t.functional (star c*b) = 0 + rw [free_compression_pairing t S hfree hij he hb (star_mem hc) hb0, sub_self] + +include hfree in +theorem free_compression_projection {i j : ι} (hij : i ≠ j) {e b : A} + (he : e ∈ S i) (hb : b ∈ S j) (hb0 : t.functional b = 0) : + (factorSpace t S j).starProjection (t.functional.toPreGNS (e*b*e) : t.functional.GNS) = + (t.functional e)^2 • (t.functional.toPreGNS b : t.functional.GNS) := by + have h := compression_error_orthogonal t S hfree hij he hb hb0 + have hp := (factorSpace t S j).orthogonalProjectionOnto_apply_of_mem_orthogonal h + have heq : (factorSpace t S j).starProjection + ((t.functional.toPreGNS (e*b*e) : t.functional.GNS) - + (t.functional e)^2 • (t.functional.toPreGNS b : t.functional.GNS)) = 0 := + congrArg (fun x : factorSpace t S j => (x : t.functional.GNS)) hp + exact (sub_eq_zero.mp (by simpa only [map_sub, map_smul, + Submodule.starProjection_eq_self_iff.mpr (vector_mem_factorSpace t S hb)] using heq)) + +end Kadison.FreeExpectation +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeFejerNorm.lean b/lean/OAI/Analysis/Commutator/FreeFejerNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..044d6c53d06413c424d8836f20692bba22e35c9f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeFejerNorm.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeCompressionNorm +import OAI.Analysis.Commutator.HankelAlgebra +import OAI.Analysis.Commutator.DihedralFejer + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor DihedralCorner + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (hfree : Free S t.functional.toLinearMap) + +variable (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hr : MulAut.conj d (d*s)=(d*s)⁻¹) + (hd2 : (d:A)*(d:A)=1) + +variable {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + (hpD : p∈S false) + +include hd0 hpform in +lemma half_projection_trace : t.functional p=((1/2:ℝ):ℂ) := by + rw [hpform,map_smul,map_add,t.normalized,hd0,add_zero,smul_eq_mul,mul_one] + norm_num + +def halfCornerState (hpt : t.functional p=((1/2:ℝ):ℂ)) : FaithfulState (Corner hp) where + functional := cornerFunctional hp t.functional (1/2) (by norm_num) + normalized := cornerFunctional_normalized hp t.functional (by norm_num) hpt + faithful := cornerFunctional_faithful hp t.functional (by norm_num) t.faithful + +lemma halfCornerState_linear (hpt : t.functional p=((1/2:ℝ):ℂ)) : + (halfCornerState t hp hpt).functional.toLinearMap=halfCornerTrace hp t.functional.toLinearMap := by + ext a + change (1/2:ℝ)⁻¹ • t.functional (a:A)=2*t.functional (a:A) + norm_num [Complex.real_smul] + +include hfree htr hd hs hd0 hs0 hr hd2 hpform hpd hdp in +theorem free_fejer_norm (e : Corner hp) (heproj : IsStarProjection e) + (he : e∈cornerFactor hp (S false) hpD) (m : ℕ) (hm : 0 < m) : + ‖(e:A)*((fejerCorner hp (d*s) m:Corner hp):A)*(e:A)‖≤ + 4*Real.sqrt 2*Real.sqrt (halfCornerTrace hp t.functional.toLinearMap e).re* + Real.sqrt ((m:ℝ)⁻¹)+2*(halfCornerTrace hp t.functional.toLinearMap e).re := by + let tc := halfCornerState t hp (half_projection_trace t d hd0 hpform) + let R := cornerPairFactors (S:=S) d s false hr hp hpform hdp hpD + have hR : Free R tc.functional.toLinearMap := by + rw [halfCornerState_linear] + exact corner_cosine_free t.functional.toLinearMap t.normalized htr + (fun a => map_star t.functional a) hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hr hd2 hp hpform hpd hdp hpD + have heR : e∈R false := he + have hbR : fejerCorner hp (d*s) m∈R true := fejerCorner_mem hp (d*s) d hr hpform hdp m + have hb0 : tc.functional (fejerCorner hp (d*s) m)=0 := by + change tc.functional.toLinearMap (fejerCorner hp (d*s) m)=0 + rw [halfCornerState_linear] + exact fejerCorner_centered hp t.functional S t.normalized htr + (fun a => map_star t.functional a) hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hr hd2 hpform m hm + have hn := FreeCreation.free_compression_norm_intrinsic tc R hR Bool.false_ne_true + heproj heR (fejerCorner_selfAdjoint hp (d*s) m) hbR hb0 + have htce : tc.functional e = halfCornerTrace hp t.functional.toLinearMap e := + congrArg (fun f : Corner hp →ₗ[ℂ] ℂ => f e) (halfCornerState_linear t hp _) + rw [htce] at hn + have hu : 0≤(halfCornerTrace hp t.functional.toLinearMap e).re := by + rw [←htce,←FreeCreation.norm_preGNS_projection_sq tc heproj] + positivity + have hb2 := fejerCorner_preGNS_norm hp t.functional S t.normalized htr + (fun a => map_star t.functional a) hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hr hpform m hm + have hbnorm := fejerCorner_norm_le hp (d*s) m hm + change ‖e*fejerCorner hp (d*s) m*e‖≤_ + calc + _ ≤ 2*Real.sqrt (halfCornerTrace hp t.functional.toLinearMap e).re* + ‖tc.functional.toPreGNS (fejerCorner hp (d*s) m)‖+ + (halfCornerTrace hp t.functional.toLinearMap e).re*‖fejerCorner hp (d*s) m‖ := hn + _ ≤ 2*Real.sqrt (halfCornerTrace hp t.functional.toLinearMap e).re* + (2*Real.sqrt 2*Real.sqrt ((m:ℝ)⁻¹))+ + (halfCornerTrace hp t.functional.toLinearMap e).re*2 := + add_le_add (mul_le_mul_of_nonneg_left hb2 (by positivity)) + (mul_le_mul_of_nonneg_left hbnorm hu) + _ = _ := by ring + +lemma fejer_numeric_bound (u : ℝ) (m : ℕ) (hm : 0 < m) (hsize : 8≤(m:ℝ)*u) : + 4*Real.sqrt 2*Real.sqrt u*Real.sqrt ((m:ℝ)⁻¹)+2*u≤4*u := by + have hm' : 0<(m:ℝ) := by exact_mod_cast hm + have hu : 0 Completion (factorSpace t S true) + +lemma concrete_hankel_assembly + (N : ℕ) (hN : 0 < N) (U : Fin N → CE →ₗᵢ[ℂ] t.functional.GNS) + (horth : ∀ i j, i ≠ j → ∀ x y : CE, inner ℂ (U i x) (U j y) = 0) + (G L : t.functional.GNS →L[ℂ] t.functional.GNS) (B Q : CE →L[ℂ] CE) (u c ε : ℝ) + (hu : 0 < u) (hc : 0 ≤ c) (hε : 0 ≤ ε) + (hL : ‖L‖ ≤ 4*u) + (hG : ‖G*L-L*G‖ ≤ ε*‖L‖) + (hR : ∀ i, ‖G.comp (U i).toContinuousLinearMap - + (U i).toContinuousLinearMap.comp B‖ ≤ 2*c*ε) + (hR' : ∀ i, ‖(ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=t.functional.GNS) (F:=t.functional.GNS) G).comp (U i).toContinuousLinearMap - + (U i).toContinuousLinearMap.comp (ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=CE) (F:=CE) B)‖ ≤ 2*c*ε) + (hRorth : ∀ i j, i ≠ j → ∀ x : CE, + inner ℂ (G (U i x) - U i (B x)) (G (U j x) - U j (B x)) = 0) + (hRorth' : ∀ i j, i ≠ j → ∀ x : CE, + inner ℂ ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=t.functional.GNS) (F:=t.functional.GNS) G) (U i x) - U i ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=CE) (F:=CE) B) x)) + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=t.functional.GNS) (F:=t.functional.GNS) G) (U j x) - U j ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=CE) (F:=CE) B) x)) = 0) + (a : Fin N → Fin N → ℂ) + (hentry : ∀ i j, ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=CE) (F:=t.functional.GNS) (U i).toContinuousLinearMap).comp L).comp + (U j).toContinuousLinearMap = (u : ℂ) • (a i j • 1 + + (Complex.ofReal (((2*N : ℝ) - i.val - j.val - 1)/(2*N : ℝ)^2)) • Q)) : + ‖B*Q-Q*B‖ ≤ 16*(1+4*c)*ε := by + exact @FiniteHankel.norm_commutator_le_of_finite_entries + t.functional.GNS (Completion (factorSpace t S true)) + (inferInstanceAs (NormedAddCommGroup t.functional.GNS)) + (inferInstanceAs (InnerProductSpace ℂ t.functional.GNS)) + (inferInstanceAs (CompleteSpace t.functional.GNS)) + (inferInstanceAs (NormedAddCommGroup (Completion (factorSpace t S true)))) + (inferInstanceAs (InnerProductSpace ℂ (Completion (factorSpace t S true)))) + (inferInstanceAs (CompleteSpace (Completion (factorSpace t S true)))) + N hN U horth G L B Q u c ε hu hc hε hL hG hR hR' hRorth hRorth' a hentry + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S false=f.range) + +variable (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hrot : MulAut.conj d (d*s)=(d*s)⁻¹) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) + +variable {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + (hpD : p∈S false) +local notation "sl" => (letterOf t S true (s:A) hs hs0) +local notation "sn" => (norm_letterOf_unitary t S true s hs hs0) +local notation "dl" => (letterOf t S false (d:A) hd hd0) +local notation "dn" => (norm_letterOf_unitary t S false d hd hd0) + +include htr hd hs hd0 hs0 hrot hd2 hs2 hpform hpd hdp hpD in +lemma normalized_fejer_entry (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) + (he : e∈cornerFactor hp (S false) hpD) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) + (N : ℕ) (hN : 0 < N) (i j : Fin N) : + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=Completion (factorSpace t S true)) (F:=t.functional.GNS) + (normalizedColumn t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr i.val).toContinuousLinearMap).comp + (t.functional.gnsStarAlgHom ((e:A)*((fejerCorner hp (d*s) (2*N):Corner hp):A)*(e:A)))).comp + (normalizedColumn t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr j.val).toContinuousLinearMap = + ((halfCornerTrace hp t.functional.toLinearMap e).re:ℂ) • + ((2*t.functional (wave (d*s) ((i.val:ℤ)-j.val)* + ((fejerCorner hp (d*s) (2*N):Corner hp):A))) • + (1:Completion (factorSpace t S true) →L[ℂ] Completion (factorSpace t S true))+ + (Complex.ofReal (((2*N:ℝ)-i.val-j.val-1)/(2*N:ℝ)^2)) • baseAction t S hfree (s:A)) := by + rw [normalizedColumn_eq_dihedral t S hfree f hf hS d s hd hs hd0 hs0 hd2 hs2 e0 hr, + normalizedColumn_eq_dihedral t S hfree f hf hS d s hd hs hd0 hs0 hd2 hs2 e0 hr,heq] + exact finite_fejer_entry t S hfree f hf hp htr d s hd hs hd0 hs0 hrot hd2 hs2 hpform hpd hdp hpD + e0 e heq heproj he hr N hN i j + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S true n →L[ℂ] multiplicityLevel t S true n) + +variable (hB : ∀ n a (x : letterSpace t S false) v, + G (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x n v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x n (B n v)) + +variable (hB' : ∀ n a (x : letterSpace t S false) v, + G.adjoint (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x n v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x n + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true n) + (F:=multiplicityLevel t S true n) (B n)) v)) + +include hB hB' in +lemma normalized_errors (e0 : D) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) + (N : ℕ) (δ : ℝ) (hδ : 0≤δ) + (hprop : ∀ n v, ‖B n (repeatInsertion t S sl sn n v)- + repeatInsertion t S sl sn n (B 0 v)‖≤δ*‖v‖) + (hprop' : ∀ n v, + ‖(ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true n) + (F:=multiplicityLevel t S true n) (B n)) (repeatInsertion t S sl sn n v)- + repeatInsertion t S sl sn n + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) + (F:=multiplicityLevel t S true 0) (B 0)) v)‖≤δ*‖v‖) : + let E := Completion (factorSpace t S true) + let U : Fin N → E →ₗᵢ[ℂ] t.functional.GNS := fun i => + normalizedColumn t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr i.val + (∀ i : Fin N, ‖G.comp (U i).toContinuousLinearMap- + (U i).toContinuousLinearMap.comp (B 0)‖≤δ) ∧ + (∀ i : Fin N, ‖G.adjoint.comp (U i).toContinuousLinearMap- + (U i).toContinuousLinearMap.comp + (ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0))‖≤δ) ∧ + (∀ i j : Fin N, i≠j → ∀ x : E, + inner ℂ (G (U i x)-U i (B 0 x)) (G (U j x)-U j (B 0 x))=0) ∧ + (∀ i j : Fin N, i≠j → ∀ x : E, + inner ℂ (G.adjoint (U i x)-U i ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0)) x)) + (G.adjoint (U j x)-U j ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0)) x))=0) := by + dsimp only + let E := Completion (factorSpace t S true) + let U : Fin N → E →ₗᵢ[ℂ] t.functional.GNS := fun i => + normalizedColumn t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr i.val + have hR : ∀ i : Fin N, ‖G.comp (U i).toContinuousLinearMap- + (U i).toContinuousLinearMap.comp (B 0)‖≤δ := by + intro i + exact norm_normalizedColumn_error_le t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr + G B hB _ hδ i.val (hprop i.val) + have hR' : ∀ i : Fin N, ‖G.adjoint.comp (U i).toContinuousLinearMap- + (U i).toContinuousLinearMap.comp + (ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0))‖≤δ := by + intro i + exact norm_normalizedColumn_error_le t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr + G.adjoint (fun n => ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true n) + (F:=multiplicityLevel t S true n) (B n)) hB' _ hδ i.val (hprop' i.val) + have hRorth : ∀ i j : Fin N, i≠j → ∀ x : E, + inner ℂ (G (U i x)-U i (B 0 x)) (G (U j x)-U j (B 0 x))=0 := by + intro i j hij x + exact normalizedColumn_error_orthogonal t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr + G B hB (mt Fin.ext hij) x x + have hRorth' : ∀ i j : Fin N, i≠j → ∀ x : E, + inner ℂ (G.adjoint (U i x)-U i ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0)) x)) + (G.adjoint (U j x)-U j ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=E) (B 0)) x))=0 := by + intro i j hij x + exact normalizedColumn_error_orthogonal t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr + G.adjoint (fun n => ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true n) + (F:=multiplicityLevel t S true n) (B n)) hB' (mt Fin.ext hij) x x + exact ⟨hR,hR',hRorth,hRorth'⟩ + +include htr hd hs hd0 hs0 hrot hd2 hs2 hpform hpd hdp hpD hB hB' in +theorem free_hankel_bound (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) + (he : e∈cornerFactor hp (S false) hpD) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) + (c ε : ℝ) (hc : 0≤c) (hε : 0≤ε) + (hsmall : ∀ a : A, (e:A)*a*(e:A)=a → + ‖G*t.functional.gnsStarAlgHom a-t.functional.gnsStarAlgHom a*G‖≤ε*‖a‖) + (hprop : ∀ n v, ‖B n (repeatInsertion t S sl sn n v)- + repeatInsertion t S sl sn n (B 0 v)‖≤(2*c*ε)*‖v‖) + (hprop' : ∀ n v, + ‖(ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true n) + (F:=multiplicityLevel t S true n) (B n)) (repeatInsertion t S sl sn n v)- + repeatInsertion t S sl sn n + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) + (F:=multiplicityLevel t S true 0) (B 0)) v)‖≤(2*c*ε)*‖v‖) : + ‖B 0*baseAction t S hfree (s:A)-baseAction t S hfree (s:A)*B 0‖≤16*(1+4*c)*ε := by + let E := Completion (factorSpace t S true) + let u : ℝ := (halfCornerTrace hp t.functional.toLinearMap e).re + have hu : 0 + normalizedColumn t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr i.val + let L := t.functional.gnsStarAlgHom ((e:A)*((fejerCorner hp (d*s) (2*N):Corner hp):A)*(e:A)) + have horth : ∀ i j : Fin N, i≠j → ∀ x y : E, inner ℂ (U i x) (U j y)=0 := by + intro i j hij x y + exact normalizedColumn_orthogonal t S f hf hS hfree Bool.false_ne_true e0 sl sn dl dn hr + (mt Fin.ext hij) x y + have hL : ‖L‖≤4*u := free_fejer_gns_norm t S hfree htr d s hd hs hd0 hs0 hrot hd2 + hp hpform hpd hdp hpD e heproj he (2*N) (by omega) hsize + have hG : ‖G*L-L*G‖≤ε*‖L‖ := by + dsimp only [L] + rw [FreeCreation.norm_gns] + exact hsmall _ (sandwich_supported hp e (fejerCorner hp (d*s) (2*N)) heproj) + obtain ⟨hR,hR',hRorth,hRorth'⟩ := normalized_errors t S hfree f hf hS d s hd hs hd0 hs0 + G B hB hB' e0 hr N (2*c*ε) (by positivity) hprop hprop' + let a : Fin N → Fin N → ℂ := fun i j => 2*t.functional + (wave (d*s) ((i.val:ℤ)-j.val)*((fejerCorner hp (d*s) (2*N):Corner hp):A)) + have hentry : ∀ i j : Fin N, ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=E) (F:=t.functional.GNS) + (U i).toContinuousLinearMap).comp L).comp + (U j).toContinuousLinearMap=(u:ℂ) • (a i j • (1:E→L[ℂ]E)+ + Complex.ofReal (((2*N:ℝ)-i.val-j.val-1)/(2*N:ℝ)^2) • baseAction t S hfree (s:A)) := by + intro i j + exact normalized_fejer_entry t S hfree f hf hS htr d s hd hs hd0 hs0 hrot hd2 hs2 + hp hpform hpd hdp hpD e0 e heq heproj he hr N hN i j + have hfinal := concrete_hankel_assembly t S + N hN U horth G L (B 0) (baseAction t S hfree (s:A)) u c ε hu hc hε + hL hG hR hR' hRorth hRorth' a hentry + exact hfinal + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeHankelEntries.lean b/lean/OAI/Analysis/Commutator/FreeHankelEntries.lean new file mode 100644 index 0000000000000000000000000000000000000000..4f81f7d5b9886a209cf6b4f53b9ae5a1ff7b2119 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeHankelEntries.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.Commutator.DihedralFejer +import OAI.Analysis.Commutator.FreeDihedralEntries +import OAI.Analysis.Commutator.FreeSymmetry14 + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor DihedralCorner + +lemma two_scaled_sum {M : Type*} [AddCommGroup M] [Module ℂ M] + (u a b c : ℂ) (x y : M) (hc : 2*b=c) : + (2*u) • (a • x+b • y)=u • ((2*a) • x+c • y) := by + rw [←hc] + module + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (hfree : Free S t.functional.toLinearMap) + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {p : A} (hp : IsStarProjection p) + +lemma projection_factor_trace (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) : + t.functional (e:A)=((‖TracialGNS.algebraVector (factorTrace t f hf) e0‖^2:ℝ):ℂ) := by + have hn := (factorTrace t f hf).preGNS_norm_sq ((factorTrace t f hf).toPreGNS e0) + have he := corner_projection_coe hp (e:=e) heproj + symm + simpa only [TracialGNS.algebraVector_apply,Completion.norm_coe, + Complex.ofReal_pow,PositiveLinearMap.ofPreGNS_toPreGNS,pullbackState_apply, + map_mul,map_star,heq,he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq] using hn + +lemma halfCornerTrace_normalization (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) : + halfCornerTrace hp t.functional.toLinearMap e= + ((2*‖TracialGNS.algebraVector (factorTrace t f hf) e0‖^2:ℝ):ℂ) := by + rw [halfCornerTrace_apply,PositiveLinearMap.coe_toLinearMap, + projection_factor_trace t f hf hp e0 e heq heproj] + push_cast + rfl + +lemma halfCornerTrace_normalization_re (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) : + (halfCornerTrace hp t.functional.toLinearMap e).re= + 2*‖TracialGNS.algebraVector (factorTrace t f hf) e0‖^2 := by + rw [halfCornerTrace_normalization t f hf hp e0 e heq heproj,Complex.ofReal_re] + +lemma normalized_dihedral_scalar (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) : + (((‖TracialGNS.algebraVector (factorTrace t f hf) e0‖⁻¹:ℝ):ℂ)^2 * + (halfCornerTrace hp t.functional.toLinearMap e)^2)= + 2*((halfCornerTrace hp t.functional.toLinearMap e).re:ℂ) := by + rw [halfCornerTrace_normalization t f hf hp e0 e heq heproj,Complex.ofReal_re] + have hn : (‖TracialGNS.algebraVector (factorTrace t f hf) e0‖:ℂ)≠0 := + Complex.ofReal_ne_zero.mpr (ne_of_gt hr) + push_cast + field_simp + +variable (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hrot : MulAut.conj d (d*s)=(d*s)⁻¹) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) + +variable (hpform : p=(1/2:ℂ) • (1+(d:A))) (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + (hpD : p∈S false) + +include hfree htr hd hs hd0 hs0 hrot hd2 hs2 hpform hpd hdp in +theorem finite_fejer_entry (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) + (he : e∈cornerFactor hp (S false) hpD) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) + (N : ℕ) (hN : 0 < N) (i j : Fin N) : + ((ContinuousLinearMap.adjoint (E:=multiplicityLevel t S true 0) (F:=t.functional.GNS) + (dihedralColumn t S hfree (e:A) (d*s) + ‖TracialGNS.algebraVector (factorTrace t f hf) e0‖⁻¹ i.val)).comp + (t.functional.gnsStarAlgHom ((e:A)*((fejerCorner hp (d*s) (2*N):Corner hp):A)*(e:A)))).comp + (dihedralColumn t S hfree (e:A) (d*s) + ‖TracialGNS.algebraVector (factorTrace t f hf) e0‖⁻¹ j.val)= + ((halfCornerTrace hp t.functional.toLinearMap e).re:ℂ) • + ((2*t.functional (wave (d*s) ((i.val:ℤ)-j.val)* + ((fejerCorner hp (d*s) (2*N):Corner hp):A))) • + ContinuousLinearMap.id ℂ (multiplicityLevel t S true 0)+ + (Complex.ofReal (((2*N:ℝ)-i.val-j.val-1)/(2*N:ℝ)^2)) • baseAction t S hfree (s:A)) := by + have hm : 0 < 2*N := by omega + have hb := fejerCorner_mem hp (d*s) d hrot hpform hdp (2*N) + have hb0 := fejerCorner_centered hp t.functional S t.normalized htr + (fun a => map_star t.functional a) hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hrot hd2 hpform (2*N) hm + have hentry := dihedral_entry_operator t S hfree htr d s hd hs hd0 hs0 hrot hd2 hs2 + hp hpform hpd hdp hpD e (fejerCorner hp (d*s) (2*N)) he hb hb0 heproj + ‖TracialGNS.algebraVector (factorTrace t f hf) e0‖⁻¹ i.val j.val + rw [normalized_dihedral_scalar t f hf hp e0 e heq heproj hr] at hentry + have hcoef := fejerCorner_positive_coefficient hp t.functional S t.normalized htr + (fun a => map_star t.functional a) hfree d s false true Bool.false_ne_true + hd hs hd0 hs0 hrot hd2 hpform (2*N) (i.val+j.val+1) hm (by omega) (by omega) + have hcoef' : 2*t.functional (wave (d*s) ((i.val:ℤ)+j.val+1)* + ((fejerCorner hp (d*s) (2*N):Corner hp):A))= + Complex.ofReal (((2*N:ℝ)-i.val-j.val-1)/(2*N:ℝ)^2) := by + simpa only [Nat.cast_add,Nat.cast_mul,Nat.cast_ofNat,Nat.cast_one, + Complex.ofReal_div,Complex.ofReal_sub,Complex.ofReal_mul,Complex.ofReal_pow, + Complex.ofReal_ofNat,Complex.ofReal_natCast,Complex.ofReal_one, + sub_add_eq_sub_sub] using hcoef + rw [ContinuousLinearMap.comp_assoc,hentry] + exact two_scaled_sum + (M:=Completion (factorSpace t S true) →L[ℂ] Completion (factorSpace t S true)) + _ _ _ _ _ _ hcoef' + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeHilbertEntries.lean b/lean/OAI/Analysis/Commutator/FreeHilbertEntries.lean new file mode 100644 index 0000000000000000000000000000000000000000..f789d5793ac787d7743937e619fbede9fe07f4b1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeHilbertEntries.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor3 +import OAI.Analysis.Commutator.HankelAlgebra +import OAI.Analysis.Commutator.Regroup +import OAI.Analysis.Commutator.TracialDevelopment + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (hfree : Free S t.functional.toLinearMap) + +abbrev baseEmbedding : multiplicityLevel t S true 0 →ₗᵢ[ℂ] t.functional.GNS := + blockEmbedding t S hfree Bool.false_ne_true 0 + +lemma baseEmbedding_coe (v : factorSpace t S true) : + baseEmbedding t S hfree (v : multiplicityLevel t S true 0)= + (t.functional.toPreGNS (factorValue t S true v) : t.functional.GNS) := by + simp [baseEmbedding,blockEmbedding,blockIsometry,blockReadPre,blockRead] + +lemma baseEmbedding_factorOf (a : A) (ha : a∈S true) : + baseEmbedding t S hfree + (factorOf t S true a ha : multiplicityLevel t S true 0)= + (t.functional.toPreGNS a : t.functional.GNS) := by + rw [baseEmbedding_coe,factorValue_factorOf] + +lemma inner_gns_coe (a b : A) : + inner ℂ (t.functional.toPreGNS a : t.functional.GNS) + (t.functional.toPreGNS b : t.functional.GNS)=t.functional (star a*b) := by + rw [Completion.inner_coe] + rfl + +def baseAction (a : A) : multiplicityLevel t S true 0 →L[ℂ] multiplicityLevel t S true 0 := + (ContinuousLinearMap.adjoint (E := multiplicityLevel t S true 0) (F := t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((t.functional.gnsStarAlgHom a).comp (baseEmbedding t S hfree).toContinuousLinearMap) + +lemma baseAction_inner (a : A) (v z : factorSpace t S true) : + inner ℂ (z : multiplicityLevel t S true 0) + (baseAction t S hfree a (v : multiplicityLevel t S true 0))= + t.functional (star (factorValue t S true z)*a*factorValue t S true v) := by + dsimp only [baseAction,ContinuousLinearMap.comp_apply] + rw [ContinuousLinearMap.adjoint_inner_right + (E := multiplicityLevel t S true 0) (F := t.functional.GNS)] + change inner ℂ (baseEmbedding t S hfree (z : multiplicityLevel t S true 0)) + (t.functional.gnsStarAlgHom a + (baseEmbedding t S hfree (v : multiplicityLevel t S true 0)))=_ + rw [baseEmbedding_coe,baseEmbedding_coe,TracialGNS.left_coe,inner_gns_coe,mul_assoc] + +lemma base_inner (v z : factorSpace t S true) : + inner ℂ (z : multiplicityLevel t S true 0) (v : multiplicityLevel t S true 0)= + t.functional (star (factorValue t S true z)*factorValue t S true v) := by + rw [Completion.inner_coe] + rfl + +def dihedralColumn (e : A) (w : unitary A) (c : ℝ) (n : ℕ) : + multiplicityLevel t S true 0 →L[ℂ] t.functional.GNS := + (c:ℂ) • ((t.functional.gnsStarAlgHom (e*DihedralCorner.wave w (-(n:ℤ)))).comp + (baseEmbedding t S hfree).toContinuousLinearMap) + +lemma dihedralColumn_coe (e : A) (w : unitary A) (c : ℝ) (n : ℕ) + (v : factorSpace t S true) : + dihedralColumn t S hfree e w c n (v : multiplicityLevel t S true 0)= + (c:ℂ) • (t.functional.toPreGNS + (e*DihedralCorner.wave w (-(n:ℤ))*factorValue t S true v) : t.functional.GNS) := by + change (c:ℂ) • t.functional.gnsStarAlgHom _ + (baseEmbedding t S hfree (v : multiplicityLevel t S true 0))=_ + rw [baseEmbedding_coe,TracialGNS.left_coe] + +lemma dihedralColumn_inner (e h : A) (he : IsStarProjection e) (heh : e*h*e=h) + (w : unitary A) (c : ℝ) (n m : ℕ) (v z : factorSpace t S true) : + inner ℂ (dihedralColumn t S hfree e w c n (z : multiplicityLevel t S true 0)) + (t.functional.gnsStarAlgHom h + (dihedralColumn t S hfree e w c m (v : multiplicityLevel t S true 0)))= + ((c:ℂ)^2)*t.functional (star (factorValue t S true z)* + (DihedralCorner.wave w (n:ℤ)*h*DihedralCorner.wave w (-(m:ℤ)))* + factorValue t S true v) := by + rw [dihedralColumn_coe,dihedralColumn_coe,map_smul,inner_smul_left,inner_smul_right, + TracialGNS.left_coe,inner_gns_coe] + rw [star_mul,star_mul,he.isSelfAdjoint.star_eq,DihedralCorner.wave_star,neg_neg] + rw [show (starRingEnd ℂ) (c:ℂ)=(c:ℂ) from Complex.conj_ofReal c] + change (c:ℂ)*((c:ℂ)*t.functional + (star (factorValue t S true z)*(DihedralCorner.wave w (n:ℤ)*e)* + (h*(e*DihedralCorner.wave w (-(m:ℤ))*factorValue t S true v))))=_ + rw [←mul_assoc (star (factorValue t S true z))] + have hm : star (factorValue t S true z)*DihedralCorner.wave w (n:ℤ)*e* + (h*(e*DihedralCorner.wave w (-(m:ℤ))*factorValue t S true v))= + star (factorValue t S true z)* + (DihedralCorner.wave w (n:ℤ)*h*DihedralCorner.wave w (-(m:ℤ)))* + factorValue t S true v := by + calc + _ = star (factorValue t S true z)* + (DihedralCorner.wave w (n:ℤ)*(e*h*e)*DihedralCorner.wave w (-(m:ℤ)))* + factorValue t S true v := by simp only [mul_assoc] + _ = _ := by rw [heh] + rw [hm,pow_two] + ring + +lemma base_operator_ext + (T R : multiplicityLevel t S true 0 →L[ℂ] multiplicityLevel t S true 0) + (h : ∀ v z : factorSpace t S true, + inner ℂ (z : multiplicityLevel t S true 0) (T (v : multiplicityLevel t S true 0))= + inner ℂ (z : multiplicityLevel t S true 0) (R (v : multiplicityLevel t S true 0))) : T=R := by + ext v + apply ext_inner_left ℂ + intro z + induction v,z using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih v z => exact h v z + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeInnerFamily.lean b/lean/OAI/Analysis/Commutator/FreeInnerFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..960c6076bf1f991c9e46287dc09b045a9abf1637 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeInnerFamily.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeWordTensor + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct CStarAlgebra + +open UniformSpace + +namespace Kadison.FreeWordAction + +open FreeWordTensor FreeMoments + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) + (hS : S i=f.range) + +def innerFamily (u : unitary D) (k : ι) : A ≃⋆ₐ[ℂ] A := by + classical + exact if k=i then Unitary.conjStarAlgAut ℂ A (⟨f (u:D),Unitary.map_mem f u.property⟩) + else StarAlgEquiv.refl ℂ A + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +@[simp] lemma innerFamily_self (u : unitary D) (a : A) : + innerFamily f i u i a=f (u:D)*a*f (star (u:D)) := by + simp [innerFamily,map_star] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +lemma innerFamily_other (u : unitary D) {k : ι} (hk : k≠i) (a : A) : + innerFamily f i u k a=a := by simp [innerFamily,hk] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +include hS in +lemma innerFamily_mem (u : unitary D) (k : ι) (a : A) (ha : a∈S k) : + innerFamily f i u k a∈S k := by + by_cases hk : k=i + · subst k + rw [innerFamily_self] + have hf (d : D) : f d∈S i := by rw [hS]; exact ⟨d,rfl⟩ + exact mul_mem (mul_mem (hf _) ha) (hf _) + · simpa only [innerFamily_other f i u hk a] using ha + +omit [PartialOrder D] [StarOrderedRing D] in +include ht in +lemma innerFamily_trace (u : unitary D) (k : ι) (a : A) : + t.functional (innerFamily f i u k a)=t.functional a := by + by_cases hk : k=i + · subst k + rw [innerFamily_self,ht,←mul_assoc,←map_mul,Unitary.star_mul_self_of_mem u.property, + map_one,one_mul] + · rw [innerFamily_other f i u hk a] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +lemma innerFamily_one (k : ι) (a : A) : innerFamily f i 1 k a=a := by + by_cases hk : k=i + · subst k; simp + · exact innerFamily_other f i 1 hk a + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +lemma innerFamily_mul (u v : unitary D) (k : ι) (a : A) : + innerFamily f i (u*v) k a=innerFamily f i u k (innerFamily f i v k a) := by + by_cases hk : k=i + · subst k + rw [innerFamily_self,innerFamily_self,innerFamily_self] + change f ((u:D)*(v:D))*a*f (star ((u:D)*(v:D))) = + f (u:D)*(f (v:D)*a*f (star (v:D)))*f (star (u:D)) + rw [map_mul,star_mul,map_mul] + simp only [mul_assoc] + · simp only [innerFamily_other f i _ hk] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder D] [StarOrderedRing D] in +lemma innerFamily_continuous (k : ι) (a : A) : + Continuous fun u : unitary D => innerFamily f i u k a := by + by_cases hk : k=i + · subst k + simp only [innerFamily_self] + exact (((map_continuous f).comp continuous_subtype_val).mul continuous_const).mul + ((map_continuous f).comp continuous_subtype_val.star) + · simpa only [innerFamily_other f i _ hk] using (continuous_const : Continuous fun _ : unitary D => a) + +end Kadison.FreeWordAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeLetterIntertwine.lean b/lean/OAI/Analysis/Commutator/FreeLetterIntertwine.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd6e4c14780466ac36e2754632028c1042b41ea6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeLetterIntertwine.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry14 +import OAI.Analysis.Commutator.FreeAction +import OAI.Analysis.Commutator.FreeInnerFamily +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) (hS : S i=f.range) + +lemma letterGNSIso_value (x : letterSpace t S i) (d : D) (hd : f d=letterValue t S i x) : + (letterGNSIso t f hf S i hS (x : Completion (letterSpace t S i)) : + (factorTrace t f hf).GNS)=TracialGNS.algebraVector (factorTrace t f hf) d := by + let xp : HilbertCompletion.centered ((pullbackState t f hf).functional.toPreGNS 1) := + ⟨(pullbackState t f hf).functional.toPreGNS d,by + rw [Submodule.mem_orthogonal_singleton_iff_inner_right,inner_pre_one] + change t.functional (f d)=0 + rw [hd] + exact x.property.2⟩ + have hx : letterPreMap t f hf S i hS xp=x := by + apply Subtype.ext + change t.functional.toPreGNS (f d)=(x : preSpace t) + rw [hd] + exact PositiveLinearMap.toPreGNS_ofPreGNS _ _ + have h := letterGNSIso_pre t f hf S i hS xp + rw [hx] at h + exact h + +variable (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +include ht in +lemma factorTrace_tracial (a b : D) : + factorTrace t f hf (a*b)=factorTrace t f hf (b*a) := by + change t.functional (f (a*b))=t.functional (f (b*a)) + simp only [map_mul,ht] + +lemma letterGNSIso_conjugation (u : unitary D) (x : letterSpace t S i) : + letterGNSIso t f hf S i hS + (letterIso t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) i x : Completion (letterSpace t S i)) = + centeredIsometry (TracialGNS.vacuum (factorTrace t f hf)) + (TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (TracialGNS.conjugation_vacuum (factorTrace t f hf) (factorTrace_tracial t f hf ht) u) + (letterGNSIso t f hf S i hS (x : Completion (letterSpace t S i))) := by + have hxm : letterValue t S i x ∈ f.range := hS ▸ x.property.1 + obtain ⟨d,hd⟩ := hxm + change f d=letterValue t S i x at hd + have hd' : f ((u:D)*d*star (u:D)) = letterValue t S i + (letterIso t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) i x) := by + change f ((u:D)*d*star (u:D))=innerFamily f i u i (letterValue t S i x) + rw [innerFamily_self,map_mul,map_mul,hd] + apply Subtype.ext + change (letterGNSIso t f hf S i hS + (letterIso t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) i x : Completion (letterSpace t S i)) : + (factorTrace t f hf).GNS) = + TracialGNS.conjugation (factorTrace t f hf) (factorTrace_tracial t f hf ht) u + (letterGNSIso t f hf S i hS (x : Completion (letterSpace t S i)) : + (factorTrace t f hf).GNS) + rw [letterGNSIso_value t f hf S i hS _ _ hd', + letterGNSIso_value t f hf S i hS x d hd] + exact (TracialGNS.conjugation_coe (factorTrace t f hf) (factorTrace_tracial t f hf ht) u d).symm + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeMoments.lean b/lean/OAI/Analysis/Commutator/FreeMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..08351620a72d2e82f3f0da00d4dc245b5a2b55e5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeMoments.lean @@ -0,0 +1,350 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.FreeMoments + +attribute [local instance] Classical.propDecidable + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +structure Letter where + color : ι + val : A + mem : val ∈ S color + centered : τ val = 0 + +variable {S τ} + +def word (w : List (Letter S τ)) : A := (w.map Letter.val).prod + +def Reduced (w : List (Letter S τ)) : Prop := + w.IsChain (fun a b => a.color ≠ b.color) + +def Free (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) : Prop := + ∀ w : List (Letter S τ), Reduced w → w ≠ [] → τ (word w) = 0 + +@[simp] lemma word_nil : word ([] : List (Letter S τ)) = 1 := rfl + +@[simp] lemma word_cons (a : Letter S τ) (w : List (Letter S τ)) : + word (a :: w) = a.val * word w := rfl + +@[simp] lemma word_append (w z : List (Letter S τ)) : + word (w ++ z) = word w * word z := by simp [word, List.prod_append] + +@[simp] lemma reduced_nil : Reduced ([] : List (Letter S τ)) := List.isChain_nil + +@[simp] lemma reduced_singleton (a : Letter S τ) : Reduced [a] := List.IsChain.singleton a + +lemma Reduced.tail {a : Letter S τ} {w : List (Letter S τ)} + (h : Reduced (a :: w)) : Reduced w := List.IsChain.tail h + +variable (hstar : ∀ a : A, τ (star a) = star (τ a)) + +def Letter.conj (a : Letter S τ) : Letter S τ where + color := a.color + val := star a.val + mem := star_mem a.mem + centered := by rw [hstar, a.centered, star_zero] + +@[simp] lemma star_color (a : Letter S τ) : (a.conj hstar).color = a.color := rfl + +@[simp] lemma star_val (a : Letter S τ) : (a.conj hstar).val = star a.val := rfl + +def reverseStar (w : List (Letter S τ)) : List (Letter S τ) := + (w.map (Letter.conj hstar)).reverse + +@[simp] lemma word_reverseStar (w : List (Letter S τ)) : + word (reverseStar hstar w) = star (word w) := by + induction w with + | nil => simp [reverseStar] + | cons a w ih => + rw [show reverseStar hstar (a :: w) = reverseStar hstar w ++ [a.conj hstar] by + simp only [reverseStar, List.map_cons, List.reverse_cons]] + simp [ih, star_mul] + +lemma Reduced.reverseStar {w : List (Letter S τ)} (h : Reduced w) : + Reduced (reverseStar hstar w) := by + apply List.isChain_reverse.mpr + apply (List.isChain_map _).mpr + exact h.imp (fun _ _ hab => hab.symm) + +lemma reduced_join {a b : Letter S τ} {w z : List (Letter S τ)} + (hw : Reduced (a :: w)) (hz : Reduced (b :: z)) (hab : a.color ≠ b.color) : + Reduced (reverseStar hstar (a :: w) ++ b :: z) := by + apply (Reduced.reverseStar hstar hw).append hz + intro x hx y hy + simp only [List.head?_cons, Option.mem_some_iff] at hy + subst y + have hx' : x = a.conj hstar := by + exact (by simpa [reverseStar, List.getLast?_reverse] using hx : _ = x).symm + subst x + exact hab + +include hstar in +lemma gram_different_head (hfree : Free S τ) {a b : Letter S τ} + {w z : List (Letter S τ)} (hw : Reduced (a :: w)) (hz : Reduced (b :: z)) + (hab : a.color ≠ b.color) : + τ (star (word (a :: w)) * word (b :: z)) = 0 := by + have h := hfree (reverseStar hstar (a :: w) ++ b :: z) + (reduced_join hstar hw hz hab) (by simp) + simpa using h + +variable (h1 : τ 1 = 1) + +def centeredPair (a b : Letter S τ) (hab : a.color = b.color) : Letter S τ where + color := a.color + val := star a.val * b.val - τ (star a.val * b.val) • (1 : A) + mem := sub_mem + (mul_mem (star_mem a.mem) (by simpa [hab] using b.mem)) + (SMulMemClass.smul_mem _ (one_mem (S a.color))) + centered := by simp [map_sub, map_smul, h1] + +lemma reduced_pair_join {a b : Letter S τ} {w z : List (Letter S τ)} + (hw : Reduced (a :: w)) (hz : Reduced (b :: z)) (hab : a.color = b.color) : + Reduced (reverseStar hstar w ++ centeredPair h1 a b hab :: z) := by + have hz' : Reduced (centeredPair h1 a b hab :: z) := by + apply hz.imp_head + intro c hc + exact hab ▸ hc + apply (Reduced.reverseStar hstar hw.tail).append hz' + intro x hx y hy + simp only [List.head?_cons, Option.mem_some_iff] at hy + subst y + cases w with + | nil => simp [reverseStar] at hx + | cons c w => + have hx' : x = c.conj hstar := by + exact (by simpa [reverseStar, List.getLast?_reverse] using hx : _ = x).symm + subst x + exact hw.rel.symm + +include hstar h1 in +lemma gram_same_head (hfree : Free S τ) {a b : Letter S τ} + {w z : List (Letter S τ)} (hw : Reduced (a :: w)) (hz : Reduced (b :: z)) + (hab : a.color = b.color) : + τ (star (word (a :: w)) * word (b :: z)) = + τ (star a.val * b.val) * τ (star (word w) * word z) := by + have h := hfree (reverseStar hstar w ++ centeredPair h1 a b hab :: z) + (reduced_pair_join hstar h1 hw hz hab) (by simp) + have hid : star (word w) * (star a.val * b.val - τ (star a.val * b.val) • (1 : A)) * word z = + star (word (a :: w)) * word (b :: z) - + τ (star a.val * b.val) • (star (word w) * word z) := by + simp only [word_cons, star_mul, mul_sub, sub_mul, mul_smul_comm, smul_mul_assoc, + mul_one, mul_assoc] + simp only [word_append, word_reverseStar, word_cons, centeredPair] at h + rw [← mul_assoc, hid, map_sub, map_smul] at h + exact sub_eq_zero.mp h + +def gram : List (Letter S τ) → List (Letter S τ) → ℂ + | [], [] => 1 + | [], _ :: _ => 0 + | _ :: _, [] => 0 + | a :: w, b :: z => if a.color = b.color then τ (star a.val * b.val) * gram w z else 0 + +include hstar h1 in +theorem gram_word (hfree : Free S τ) (w z : List (Letter S τ)) + (hw : Reduced w) (hz : Reduced z) : + τ (star (word w) * word z) = gram w z := by + classical + induction w generalizing z with + | nil => + cases z with + | nil => simpa [gram] using h1 + | cons b z => simpa [gram] using hfree (b :: z) hz (by simp) + | cons a w ih => + cases z with + | nil => + rw [word_nil, mul_one, hstar, hfree (a :: w) hw (by simp)] + simp only [star_zero, gram] + | cons b z => + by_cases hab : a.color = b.color + · rw [gram, ite_eq_left hab, gram_same_head hstar h1 hfree hw hz hab, + ih z hw.tail hz.tail] + · rw [gram, ite_eq_right hab, gram_different_head hstar hfree hw hz hab] + +lemma gram_zero_of_colors_ne (w z : List (Letter S τ)) + (h : w.map Letter.color ≠ z.map Letter.color) : gram w z = 0 := by + induction w generalizing z with + | nil => cases z <;> simp_all [gram] + | cons a w ih => + cases z with + | nil => rfl + | cons b z => + by_cases hab : a.color = b.color + · rw [gram, ite_eq_left hab] + have ht : w.map Letter.color ≠ z.map Letter.color := by + intro ht + exact h (by simp [hab, ht]) + rw [ih z ht, mul_zero] + · simp only [gram, ite_eq_right hab] + +lemma gram_ofFn {n : ℕ} (v w : Fin n → Letter S τ) + (hc : ∀ i, (v i).color = (w i).color) : + gram (List.ofFn v) (List.ofFn w) = ∏ i, τ (star (v i).val * (w i).val) := by + induction n with + | zero => simp [gram] + | succ n ih => + rw [List.ofFn_succ, List.ofFn_succ, gram, ite_eq_left (hc 0), + ih (fun i => v i.succ) (fun i => w i.succ) (fun i => hc i.succ), Fin.prod_univ_succ] + +include hstar h1 in +lemma reduced_word_orthogonal (hfree : Free S τ) (w z : List (Letter S τ)) + (hw : Reduced w) (hz : Reduced z) (hc : w.map Letter.color ≠ z.map Letter.color) : + τ (star (word w) * word z) = 0 := by + rw [gram_word hstar h1 hfree w z hw hz, gram_zero_of_colors_ne w z hc] + +include hstar h1 in +lemma reduced_word_inner {n : ℕ} (hfree : Free S τ) (v w : Fin n → Letter S τ) + (hv : Reduced (List.ofFn v)) (hw : Reduced (List.ofFn w)) + (hc : ∀ i, (v i).color = (w i).color) : + τ (star (word (List.ofFn v)) * word (List.ofFn w)) = + ∏ i, τ (star (v i).val * (w i).val) := by + rw [gram_word hstar h1 hfree _ _ hv hw, gram_ofFn v w hc] + +def centerLetter (i : ι) (a : A) (ha : a ∈ S i) : Letter S τ where + color := i + val := a - τ a • (1 : A) + mem := sub_mem ha (SMulMemClass.smul_mem _ (one_mem (S i))) + centered := by simp [map_sub, map_smul, h1] + +def wordSpan (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) : Submodule ℂ A := + Submodule.span ℂ {a | ∃ w : List (Letter S τ), Reduced w ∧ word w = a} + +lemma word_mem_span {w : List (Letter S τ)} (hw : Reduced w) : + word w ∈ wordSpan S τ := Submodule.subset_span ⟨w, hw, rfl⟩ + +lemma one_mem_wordSpan : (1 : A) ∈ wordSpan S τ := + word_mem_span (w := []) reduced_nil + +include h1 in +lemma generator_mem_wordSpan (i : ι) (a : A) (ha : a ∈ S i) : a ∈ wordSpan S τ := by + have hc := word_mem_span (reduced_singleton (centerLetter h1 i a ha)) + have hs := (wordSpan S τ).smul_mem (τ a) one_mem_wordSpan + have hd : word [centerLetter h1 i a ha] + τ a • (1 : A) = a := by + simp [centerLetter] + rw [← hd] + exact (wordSpan S τ).add_mem hc hs + +include h1 in +lemma generator_mul_word (i : ι) (a : A) (ha : a ∈ S i) + (w : List (Letter S τ)) (hw : Reduced w) : a * word w ∈ wordSpan S τ := by + cases w with + | nil => simpa using generator_mem_wordSpan h1 i a ha + | cons b w => + by_cases hc : i = b.color + · have hab : a * b.val ∈ S i := mul_mem ha (by simpa [hc] using b.mem) + let c := centerLetter h1 i (a * b.val) hab + have hw' : Reduced (c :: w) := by + apply hw.imp_head + intro z hz + change i ≠ z.color + simpa [hc] using hz + have hmem := (wordSpan S τ).add_mem (word_mem_span hw') + ((wordSpan S τ).smul_mem (τ (a * b.val)) (word_mem_span hw.tail)) + have heq : word (c :: w) + τ (a * b.val) • word w = a * word (b :: w) := by + simp only [word_cons, c, centerLetter, sub_mul, smul_mul_assoc, one_mul, mul_assoc] + exact sub_add_cancel _ _ + rwa [heq] at hmem + · let c := centerLetter h1 i a ha + have hw' : Reduced (c :: b :: w) := List.isChain_cons_cons.mpr ⟨hc, hw⟩ + have hmem := (wordSpan S τ).add_mem (word_mem_span hw') + ((wordSpan S τ).smul_mem (τ a) (word_mem_span hw)) + have heq : word (c :: b :: w) + τ a • word (b :: w) = a * word (b :: w) := by + change (a - τ a • (1 : A)) * word (b :: w) + τ a • word (b :: w) = _ + simp only [sub_mul, smul_mul_assoc, one_mul, sub_add_cancel] + rwa [heq] at hmem + +include h1 in +lemma generator_mul_span (i : ι) (a : A) (ha : a ∈ S i) + {b : A} (hb : b ∈ wordSpan S τ) : a * b ∈ wordSpan S τ := by + induction hb using Submodule.span_induction with + | mem b hb => + obtain ⟨w, hw, rfl⟩ := hb + exact generator_mul_word h1 i a ha w hw + | zero => simp only [mul_zero, Submodule.zero_mem] + | add b c _ _ hb hc => simpa only [mul_add] using (wordSpan S τ).add_mem hb hc + | smul z b _ hb => simpa only [mul_smul_comm] using (wordSpan S τ).smul_mem z hb + +include h1 in +lemma word_mul_span (w : List (Letter S τ)) {b : A} (hb : b ∈ wordSpan S τ) : + word w * b ∈ wordSpan S τ := by + induction w with + | nil => simpa using hb + | cons a w ih => + simpa only [word_cons, mul_assoc] using generator_mul_span h1 a.color a.val a.mem ih + +include h1 in +lemma mul_mem_wordSpan {a b : A} (ha : a ∈ wordSpan S τ) (hb : b ∈ wordSpan S τ) : + a * b ∈ wordSpan S τ := by + induction ha using Submodule.span_induction with + | mem a ha => + obtain ⟨w, _, rfl⟩ := ha + exact word_mul_span h1 w hb + | zero => simp only [zero_mul, Submodule.zero_mem] + | add a c _ _ ha hc => simpa only [add_mul] using (wordSpan S τ).add_mem ha hc + | smul z a _ ha => simpa only [smul_mul_assoc] using (wordSpan S τ).smul_mem z ha + +include hstar in +lemma star_mem_wordSpan {a : A} (ha : a ∈ wordSpan S τ) : star a ∈ wordSpan S τ := by + induction ha using Submodule.span_induction with + | mem a ha => + obtain ⟨w, hw, rfl⟩ := ha + rw [← word_reverseStar hstar] + exact word_mem_span (Reduced.reverseStar hstar hw) + | zero => simp only [star_zero, Submodule.zero_mem] + | add a c _ _ ha hc => simpa only [star_add] using (wordSpan S τ).add_mem ha hc + | smul z a _ ha => simpa only [star_smul] using (wordSpan S τ).smul_mem (star z) ha + +variable (S) in + +def reducedAlgebra : StarSubalgebra ℂ A where + carrier := wordSpan S τ + zero_mem' := (wordSpan S τ).zero_mem + add_mem' := (wordSpan S τ).add_mem + one_mem' := one_mem_wordSpan + mul_mem' := mul_mem_wordSpan h1 + algebraMap_mem' z := by + change algebraMap ℂ A z ∈ wordSpan S τ + rw [Algebra.algebraMap_eq_smul_one] + exact (wordSpan S τ).smul_mem z one_mem_wordSpan + star_mem' := star_mem_wordSpan hstar + +include hstar h1 in +lemma generator_le_reducedAlgebra (i : ι) : S i ≤ reducedAlgebra S hstar h1 := + fun a ha => generator_mem_wordSpan h1 i a ha + +lemma reducedAlgebra_eq_iSup : reducedAlgebra S hstar h1 = ⨆ i, S i := by + apply le_antisymm + · intro a ha + change a ∈ wordSpan S τ at ha + induction ha using Submodule.span_induction with + | mem a ha => + obtain ⟨w, hw, rfl⟩ := ha + clear hw + induction w with + | nil => exact one_mem _ + | cons b w ih => + exact mul_mem ((le_iSup S b.color) b.mem) ih + | zero => exact zero_mem _ + | add a b _ _ ha hb => exact add_mem ha hb + | smul z a _ ha => exact SMulMemClass.smul_mem z ha + · exact iSup_le (fun i => generator_le_reducedAlgebra (S := S) (hstar := hstar) (h1 := h1) i) + +end Kadison.FreeMoments +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeMomentsMonotone.lean b/lean/OAI/Analysis/Commutator/FreeMomentsMonotone.lean new file mode 100644 index 0000000000000000000000000000000000000000..6e18ec651f18dc6ede111c6a1790dbbc820f90b9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeMomentsMonotone.lean @@ -0,0 +1,36 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FreeMoments + +variable {A ι : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {S T : ι → StarSubalgebra ℂ A} {τ : A →ₗ[ℂ] ℂ} + +lemma Free.mono (hfree : Free T τ) (hle : ∀ i,S i≤T i) : Free S τ := by + let f : Letter S τ → Letter T τ := fun a => ⟨a.color,a.val,hle _ a.mem,a.centered⟩ + intro w hw hne + have hr : Reduced (w.map f) := (List.isChain_map _).mpr hw + have hn : w.map f≠[] := by + cases w with + | nil => exact (hne rfl).elim + | cons a w => intro h; cases h + have h := hfree (w.map f) hr hn + simpa only [word,List.map_map,Function.comp_def] using h + +end Kadison.FreeMoments + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeMomentsTransport.lean b/lean/OAI/Analysis/Commutator/FreeMomentsTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..96b92d8cd9a80d5a09b506779208289d5aa6821c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeMomentsTransport.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FreeMoments + +variable {A B : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + [Ring B] [Algebra ℂ B] [StarRing B] [StarModule ℂ B] + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (U : ι → StarSubalgebra ℂ B) + (τ : A →ₗ[ℂ] ℂ) (ρ : B →ₗ[ℂ] ℂ) + (j : A →⋆ₐ[ℂ] B) (htrace : ∀ a,ρ (j a)=τ a) + (hSU : ∀ i a,a∈S i → j a∈U i) + +def Letter.transport (a : Letter S τ) : Letter U ρ where + color := a.color + val := j a.val + mem := hSU _ _ a.mem + centered := (htrace _).trans a.centered + +lemma word_transport (w : List (Letter S τ)) : + word (w.map (Letter.transport S U τ ρ j htrace hSU))=j (word w) := by + induction w with + | nil => simp + | cons a w ih => simp only [List.map_cons,word_cons,Letter.transport,ih,map_mul] + +include htrace hSU in +theorem free_of_map (hfree : Free U ρ) : Free S τ := by + intro w hw hne + let F := Letter.transport S U τ ρ j htrace hSU + have hr : Reduced (w.map F) := by + simpa only [Reduced,List.isChain_map,F,Letter.transport] using hw + have hn : w.map F≠[] := fun h => hne (List.map_eq_nil_iff.mp h) + have hz := hfree (w.map F) hr hn + rw [word_transport,htrace] at hz + exact hz + +end Kadison.FreeMoments + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeNormalizedColumns.lean b/lean/OAI/Analysis/Commutator/FreeNormalizedColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..52610b4f3311259c002cd2c30796cb5e2f41323f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeNormalizedColumns.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeRepeatedWords + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace TensorProduct ComplexOrder + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + (hS : S i=f.range) (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +variable (d : D) (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (hx : ‖x‖=1) + +variable (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) d‖) + +def normalizedColumn (n : ℕ) : multiplicityLevel t S j 0 →ₗᵢ[ℂ] t.functional.GNS where + toLinearMap := (((‖TracialGNS.algebraVector (factorTrace t f hf) d‖⁻¹:ℝ):ℂ) • + (repeatedOutput t S f hf hS hfree hij d x n).comp + (repeatInsertion t S s hs n).toContinuousLinearMap).toLinearMap + norm_map' v := by + change ‖((‖TracialGNS.algebraVector (factorTrace t f hf) d‖⁻¹:ℝ):ℂ) • + repeatedOutput t S f hf hS hfree hij d x n (repeatInsertion t S s hs n v)‖=‖v‖ + rw [norm_smul,Complex.norm_real,Real.norm_eq_abs,abs_inv, + abs_of_nonneg (norm_nonneg _),norm_repeatedOutput,hx,one_pow,mul_one, + (repeatInsertion t S s hs n).norm_map,←mul_assoc, + inv_mul_cancel₀ (ne_of_gt hr),one_mul] + +lemma normalizedColumn_apply (n : ℕ) (v : multiplicityLevel t S j 0) : + normalizedColumn t S f hf hS hfree hij d s hs x hx hr n v= + ((‖TracialGNS.algebraVector (factorTrace t f hf) d‖⁻¹:ℝ):ℂ) • + repeatedOutput t S f hf hS hfree hij d x n (repeatInsertion t S s hs n v) := rfl + +lemma repeatedOutput_orthogonal {n m : ℕ} (hnm : n≠m) + (v : multiplicityLevel t S j n) (z : multiplicityLevel t S j m) : + inner ℂ (repeatedOutput t S f hf hS hfree hij d x n v) + (repeatedOutput t S f hf hS hfree hij d x m z)=0 := by + exact sourceLevelEmbedding_orthogonal t f hf S i j hS hfree hij hnm _ _ + +lemma normalizedColumn_orthogonal : OrthogonalFamily ℂ + (fun _ : ℕ => multiplicityLevel t S j 0) + (normalizedColumn t S f hf hS hfree hij d s hs x hx hr) := by + intro n m hnm v z + simp only [normalizedColumn_apply t S f hf hS hfree hij d s hs x hx hr,inner_smul_left,inner_smul_right, + repeatedOutput_orthogonal t S f hf hS hfree hij d x hnm,mul_zero] + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +variable (hB : ∀ n d (x : letterSpace t S i) v, + G (repeatedOutput t S f hf hS hfree hij d x n v)= + repeatedOutput t S f hf hS hfree hij d x n (B n v)) + +include hB in +lemma normalizedColumn_error (n : ℕ) (v : multiplicityLevel t S j 0) : + G (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n v)- + normalizedColumn t S f hf hS hfree hij d s hs x hx hr n (B 0 v)= + ((‖TracialGNS.algebraVector (factorTrace t f hf) d‖⁻¹:ℝ):ℂ) • + repeatedOutput t S f hf hS hfree hij d x n + (B n (repeatInsertion t S s hs n v)-repeatInsertion t S s hs n (B 0 v)) := by + simp only [normalizedColumn_apply t S f hf hS hfree hij d s hs x hx hr,map_smul,hB,map_sub,smul_sub] + +include hB in +lemma normalizedColumn_error_norm (n : ℕ) (v : multiplicityLevel t S j 0) : + ‖G (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n v)- + normalizedColumn t S f hf hS hfree hij d s hs x hx hr n (B 0 v)‖= + ‖B n (repeatInsertion t S s hs n v)-repeatInsertion t S s hs n (B 0 v)‖ := by + rw [normalizedColumn_error t S f hf hS hfree hij d s hs x hx hr G B hB, + norm_smul,Complex.norm_real,Real.norm_eq_abs,abs_inv,abs_of_nonneg (norm_nonneg _), + norm_repeatedOutput,hx,one_pow,mul_one,←mul_assoc, + inv_mul_cancel₀ (ne_of_gt hr),one_mul] + +include hB in +lemma normalizedColumn_error_orthogonal {n m : ℕ} (hnm : n≠m) + (v z : multiplicityLevel t S j 0) : + inner ℂ (G (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n v)- + normalizedColumn t S f hf hS hfree hij d s hs x hx hr n (B 0 v)) + (G (normalizedColumn t S f hf hS hfree hij d s hs x hx hr m z)- + normalizedColumn t S f hf hS hfree hij d s hs x hx hr m (B 0 z))=0 := by + simp only [normalizedColumn_error t S f hf hS hfree hij d s hs x hx hr G B hB, + inner_smul_left,inner_smul_right, + repeatedOutput_orthogonal t S f hf hS hfree hij d x hnm,mul_zero] + +include hB in +lemma norm_normalizedColumn_error_le (δ : ℝ) (hδ : 0≤δ) (n : ℕ) + (he : ∀ v, ‖B n (repeatInsertion t S s hs n v)-repeatInsertion t S s hs n (B 0 v)‖≤δ*‖v‖) : + ‖G.comp (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n).toContinuousLinearMap- + (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n).toContinuousLinearMap.comp (B 0)‖≤δ := by + let T := G.comp (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n).toContinuousLinearMap- + (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n).toContinuousLinearMap.comp (B 0) + change sInf {r : ℝ | 0≤r ∧ ∀ v, ‖T v‖≤r*‖v‖}≤δ + refine csInf_le ⟨0,fun r h => h.1⟩ ⟨hδ,?_⟩ + intro v + change ‖G (normalizedColumn t S f hf hS hfree hij d s hs x hx hr n v)- + normalizedColumn t S f hf hS hfree hij d s hs x hx hr n (B 0 v)‖≤_ + rw [normalizedColumn_error_norm t S f hf hS hfree hij d s hs x hx hr G B hB] + exact he v + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeNormalizer.lean b/lean/OAI/Analysis/Commutator/FreeNormalizer.lean new file mode 100644 index 0000000000000000000000000000000000000000..04f6c2d35eefb7f84ce57d49277c15a5a7ba0ac3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeNormalizer.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.ConjugationNormalizer +import OAI.Analysis.Commutator.FreeActualCovariance + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace TensorProduct + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +lemma innerRepresentation_conj_generator (u : unitary D) (k : ι) (a : A) (ha : a∈S k) : + (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv + (t.functional.gnsStarAlgHom a) = + t.functional.gnsStarAlgHom (innerFamily f i u k a) := by + ext x + let W := innerRepresentation t ht f S i hS hfree hgen u + change W (t.functional.gnsStarAlgHom a (W.symm x))=_ + have h := action_left_apply t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) hfree hgen k a ha (W.symm x) + change W (t.functional.gnsStarAlgHom a (W.symm x))= + t.functional.gnsStarAlgHom (innerFamily f i u k a) (W (W.symm x)) at h + simpa only [LinearIsometryEquiv.apply_symm_apply] using h + +lemma innerRepresentation_conj_mem_generated (u : unitary D) + {a : t.functional.GNS →L[ℂ] t.functional.GNS} (ha : a∈generatedOperators t S) : + (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv a ∈ generatedOperators t S := by + let α := (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv + have hle : iSup S ≤ ((generatedOperators t S).comap α.toStarAlgHom).comap + t.functional.gnsStarAlgHom := by + refine iSup_le fun k => ?_ + intro b hb + change α (t.functional.gnsStarAlgHom b) ∈ generatedOperators t S + rw [innerRepresentation_conj_generator t ht f S i hS hfree hgen u k b hb] + exact ⟨innerFamily f i u k b,(le_iSup S k) (innerFamily_mem f S i hS u k b hb),rfl⟩ + obtain ⟨b,hb,rfl⟩ := ha + exact hle hb + +lemma innerRepresentation_conj_mem_bicommutant (u : unitary D) + {a : t.functional.GNS →L[ℂ] t.functional.GNS} + (ha : a∈Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _)) := by + exact mem_bicommutant_of_maps_generators + (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv.toMulEquiv + (generatedOperators t S : Set _) (fun _ h => + innerRepresentation_conj_mem_generated t ht f S i hS hfree hgen u h) ha + +lemma innerRepresentation_vacuum (u : unitary D) : + innerRepresentation t ht f S i hS hfree hgen u (TracialGNS.vacuum t.functional)= + TracialGNS.vacuum t.functional := by + exact action_word t S (innerFamily f i u) (innerFamily_mem f S i hS u) + (innerFamily_trace t ht f i u) hfree hgen [] reduced_nil + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeOriginalBound.lean b/lean/OAI/Analysis/Commutator/FreeOriginalBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..314675d023e0e69f1862dde670c7074be6b980e5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeOriginalBound.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBaseCompression +import OAI.Analysis.Commutator.NormalFreeCorner + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Matrix.Norms.L2Operator + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeWordAction + +variable {A B : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (D : VonNeumannAlgebra H) + (t : FaithfulState A) (htr : ∀ a b : A,t.functional (a*b)=t.functional (b*a)) + (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + (R : Bool → StarSubalgebra ℂ A) (hR : R false=f.range) + (hfree : Free R t.functional.toLinearMap) + (hgen : ∀ a : A,t.functional.gnsStarAlgHom a∈ + Set.centralizer (Set.centralizer (generatedOperators t R : Set _))) + (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] [∀ n,Nonempty (I n)] + (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ},n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a,φ m (inc h a)=φ n a) + (hsize : ∀ n q : ℕ,∃ m,n ≤ m ∧ q ≤ Fintype.card (I m)) + (hDgen : ∀ a : D,(factorTrace t f hf).gnsStarAlgHom a∈ + Set.centralizer (Set.centralizer (TracialGNS.stageAlgebra (factorTrace t f hf) I φ : Set _))) + +include htr hR hfree hgen hinc hsize hDgen in +theorem normal_free_original_bound + (hnormal : NormalGNS.BoundedWOTContinuous D (factorTrace t f hf)) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections D) + (τ : B →ₚ[ℂ] ℂ) (j : B →⋆ₐ[ℂ] A) (htrace : ∀ a,τ a=t.functional (j a)) + (hj : ∀ a : B,j a∈R true) + (G : t.functional.GNS →L[ℂ] t.functional.GNS) (T : τ.GNS →L[ℂ] τ.GNS) + (hGT : ∀ x,G (originalEmbedding τ t j htrace x)=originalEmbedding τ t j htrace (T x)) + (hGD : ∀ a : D,G*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*G) + (s : unitary B) (hs0 : τ (s:B)=0) (hs2 : (s:B)*(s:B)=1) + (ε β : ℝ) (hε : 0≤ε) (hβ : 0<β) (hβ1 : β≤1) + (hC : ∀ x,CornerSymmetrization.CornerElement (factorOperators t f) (ambientOperators t R) + (TracialGNS.vacuum t.functional) (β:ℂ) x → ‖G*x-x*G‖≤ε*‖x‖) : + ‖T*τ.gnsStarAlgHom (s:B)-τ.gnsStarAlgHom (s:B)*T‖≤1040*ε := by + let u : unitary A := ⟨j (s:B),Unitary.map_mem j s.property⟩ + have hu0 : t.functional (u:A)=0 := (htrace (s:B)).symm.trans hs0 + have hu2 : (u:A)*(u:A)=1 := by change j (s:B)*j (s:B)=1; rw [←map_mul,hs2,map_one] + exact (original_commutator_le_base τ t j htrace R hfree hj G T hGT (s:B)).trans + (normal_free_corner_bound D t htr f hf R hR hfree hgen I φ inc hinc hsize hDgen + hnormal hdiffuse G hGD u (hj (s:B)) hu0 hu2 ε β hε hβ hβ1 hC) + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreePositionObstruction.lean b/lean/OAI/Analysis/Commutator/FreePositionObstruction.lean new file mode 100644 index 0000000000000000000000000000000000000000..5fd54d516977e98c9ed16aad3e2e2864a884f2e1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreePositionObstruction.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison.FreeMoments + +variable {A ι : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + (hstar : ∀ a : A,τ (star a)=star (τ a)) + (hfaith : ∀ a : A,τ (star a*a)=0 → a=0) + +include hstar hfaith in +theorem centered_intersection_zero (hfree : Free S τ) {i j : ι} (hij : i≠j) + (a : A) (hi : a∈S i) (hj : a∈S j) (ha : τ a=0) : a=0 := by + let l : Letter S τ := ⟨i,a,hi,ha⟩ + let r : Letter S τ := ⟨j,a,hj,ha⟩ + have h := gram_different_head hstar hfree (reduced_singleton l) (reduced_singleton r) hij + apply hfaith + simpa only [word_cons,word_nil,mul_one] using h + +include hstar hfaith in +theorem intersection_scalar (h1 : τ 1=1) (hfree : Free S τ) {i j : ι} (hij : i≠j) + (a : A) (hi : a∈S i) (hj : a∈S j) : a=τ a • (1:A) := by + have hb : τ (a-τ a • (1:A))=0 := by simp [h1] + have hzero := centered_intersection_zero S τ hstar hfaith hfree hij (a-τ a • (1:A)) + ((S i).sub_mem hi ((S i).smul_mem ((S i).one_mem) (τ a))) + ((S j).sub_mem hj ((S j).smul_mem ((S j).one_mem) (τ a))) hb + exact sub_eq_zero.mp hzero + +include hstar hfaith in +theorem not_free_of_common_centered {i j : ι} (hij : i≠j) + (a : A) (hi : a∈S i) (hj : a∈S j) (ha : τ a=0) (hne : a≠0) : ¬Free S τ := by + intro hf + exact hne (centered_intersection_zero S τ hstar hfaith hf hij a hi hj ha) + +end Kadison.FreeMoments + +namespace Kadison.FreeMoments + +variable {A B ι : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + [Ring B] [Algebra ℂ B] [StarRing B] [StarModule ℂ B] + +variable (S : ι → StarSubalgebra ℂ B) (τ : A →ₗ[ℂ] ℂ) (ρ : B →ₗ[ℂ] ℂ) + (j : A →⋆ₐ[ℂ] B) (htrace : ∀ a,ρ (j a)=τ a) + (hstar : ∀ a : B,ρ (star a)=star (ρ a)) + (hfaith : ∀ a : A,τ (star a*a)=0 → a=0) + +include htrace hstar hfaith in +omit [StarModule ℂ A] in +theorem mapped_centered_intersection_zero (hfree : Free S ρ) {i k : ι} (hik : i≠k) + (a : A) (hi : j a∈S i) (hk : j a∈S k) (ha : τ a=0) : a=0 := by + let l : Letter S ρ := ⟨i,j a,hi,(htrace a).trans ha⟩ + let r : Letter S ρ := ⟨k,j a,hk,(htrace a).trans ha⟩ + have h := gram_different_head hstar hfree (reduced_singleton l) (reduced_singleton r) hik + have hz : ρ (star (j a)*j a)=0 := by + simpa only [word_cons,word_nil,mul_one] using h + apply hfaith + rw [←map_star,←map_mul,htrace] at hz + exact hz + +include htrace hstar hfaith in +omit [StarModule ℂ A] in +theorem mapped_intersection_scalar (h1 : τ 1=1) (hfree : Free S ρ) {i k : ι} (hik : i≠k) + (a : A) (hi : j a∈S i) (hk : j a∈S k) : a=τ a • (1:A) := by + have hb : τ (a-τ a • (1:A))=0 := by simp [h1] + have hm : j (a-τ a • (1:A))=j a-τ a • (1:B) := by simp + have hz := mapped_centered_intersection_zero S τ ρ j htrace hstar hfaith hfree hik + (a-τ a • (1:A)) + (hm ▸ (S i).sub_mem hi ((S i).smul_mem (S i).one_mem (τ a))) + (hm ▸ (S k).sub_mem hk ((S k).smul_mem (S k).one_mem (τ a))) hb + exact sub_eq_zero.mp hz + +end Kadison.FreeMoments +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreePropagation.lean b/lean/OAI/Analysis/Commutator/FreePropagation.lean new file mode 100644 index 0000000000000000000000000000000000000000..28bca5747ac8af93021af591078a47d22e808463 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreePropagation.lean @@ -0,0 +1,342 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeCreation + +namespace OAI + +noncomputable section + +section + +open scoped ComplexOrder InnerProductSpace + +noncomputable section + +namespace Kadison + +open Filter _root_.Topology + +variable {H : Type*} [NormedAddCommGroup H] [NormedSpace ℂ H] + +def zeroLimitSpace (F : ℕ → H →L[ℂ] H) : Submodule ℂ H where + carrier := {x | Tendsto (fun n => F n x) atTop (𝓝 0)} + zero_mem' := by simp + add_mem' := by + intro x y hx hy + change Tendsto (fun n => F n (x+y)) atTop (𝓝 0) + simpa only [map_add, add_zero] using hx.add hy + smul_mem' := by + intro c x hx + change Tendsto (fun n => F n (c • x)) atTop (𝓝 0) + simpa only [map_smul, smul_zero] using hx.const_smul c + +lemma zeroLimitSpace_closed (F : ℕ → H →L[ℂ] H) (hb : ∀ n, ‖F n‖ ≤ 1) : + IsClosed (zeroLimitSpace F : Set H) := by + have hF : Equicontinuous (fun n x => F n x) := + (LipschitzWith.uniformEquicontinuous (fun n x => F n x) 1 + (fun n => (F n).lipschitzWith.weaken (by exact_mod_cast hb n))).equicontinuous + exact hF.isClosed_setOfPred_tendsto continuous_const + +end Kadison + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor Filter _root_.Topology + +attribute [local instance] Classical.propDecidable + +open scoped InnerProductSpace + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +include hfree in +lemma tailProjection_mul_tail {i : ι} {a : A} (ha : a ∈ S i) + {x : t.functional.GNS} (hx : x ∈ tailSpace t S i) : + (tailSpace t S i).starProjection (t.functional.gnsStarAlgHom a x) = + t.functional a • x := by + let c := a - t.functional a • (1 : A) + have hc : c ∈ S i := sub_mem ha (SMulMemClass.smul_mem _ (one_mem _)) + have hc0 : t.functional c = 0 := by simp [c, t.normalized] + have hcx := headSpace_le_tailSpace_orthogonal t S hfree i + (creation_mem_headSpace t S i hc hc0 hx) + have hp : (tailSpace t S i).starProjection (t.functional.gnsStarAlgHom c x) = 0 := by + simp only [Submodule.starProjection_apply, + Submodule.orthogonalProjectionOnto_apply_of_mem_orthogonal hcx, ZeroMemClass.coe_zero] + have heq : t.functional.gnsStarAlgHom c x = + t.functional.gnsStarAlgHom a x - t.functional a • x := by + simp [c] + rw [heq, map_sub, map_smul, (tailSpace t S i).starProjection_eq_self_iff.mpr hx] at hp + exact sub_eq_zero.mp hp + +include hfree in +lemma tailProjection_mul_centered_tail {i : ι} {a : A} (ha : a ∈ S i) + (ha0 : t.functional a=0) {x : t.functional.GNS} (hx : x ∈ tailSpace t S i) : + (tailSpace t S i).starProjection (t.functional.gnsStarAlgHom a x)=0 := by + rw [tailProjection_mul_tail t S hfree ha hx, ha0, zero_smul] + +include hfree in +lemma norm_tailProjection_mul (i : ι) {a : A} (ha : a ∈ S i) : + ‖(tailSpace t S i).starProjection * t.functional.gnsStarAlgHom a‖ ≤ + ‖t.functional.toPreGNS (star a)‖ := by + have hn : ‖t.functional.gnsStarAlgHom (star a) * (tailSpace t S i).starProjection‖ ≤ + ‖t.functional.toPreGNS (star a)‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + change ‖t.functional.gnsStarAlgHom (star a) ((tailSpace t S i).starProjection x)‖ ≤ _ + rw [norm_mul_tailSpace t S hfree i (star_mem ha) + ((tailSpace t S i).starProjection_apply_mem x)] + exact mul_le_mul_of_nonneg_left ((tailSpace t S i).norm_starProjection_apply_le x) + (norm_nonneg _) + have heq : star (t.functional.gnsStarAlgHom (star a) * (tailSpace t S i).starProjection) = + (tailSpace t S i).starProjection * t.functional.gnsStarAlgHom a := by + rw [star_mul, (isSelfAdjoint_starProjection _).star_eq, ← map_star, star_star] + rw [← heq, norm_star] + exact hn + +lemma wordVector_mem_tail {i : ι} {w : List (Letter t S)} + (hw : Reduced w) (hi : CanPrepend t S i w) : + wordVector t S w ∈ tailSpace t S i := + Submodule.le_topologicalClosure _ (Submodule.subset_span ⟨w, hw, hi, rfl⟩) + +include hfree in +lemma tailProjection_mul_word (i : ι) {a : A} (ha : a ∈ S i) + (ha0 : t.functional a=0) {w : List (Letter t S)} (hw : Reduced w) : + (tailSpace t S i).starProjection (t.functional.gnsStarAlgHom a (wordVector t S w)) = + match w with + | [] => 0 + | b :: z => if b.color=i then t.functional (a*b.val) • wordVector t S z else 0 := by + cases w with + | nil => + exact tailProjection_mul_centered_tail t S hfree ha ha0 + (wordVector_mem_tail t S reduced_nil (by simp [CanPrepend])) + | cons b z => + change _ = if b.color=i then t.functional (a*b.val) • wordVector t S z else 0 + by_cases hb : b.color=i + · rw [ite_eq_left hb] + have hz : CanPrepend t S i z := by + cases z with + | nil => simp [CanPrepend] + | cons c z => + have := hw.rel + simpa [CanPrepend, hb] using this + have heq : t.functional.gnsStarAlgHom a (wordVector t S (b::z)) = + t.functional.gnsStarAlgHom (a*b.val) (wordVector t S z) := by + simp only [mul_wordVector, word_cons, mul_assoc] + rw [heq] + exact tailProjection_mul_tail t S hfree + (mul_mem ha (by simpa [hb] using b.mem)) (wordVector_mem_tail t S hw.tail hz) + · rw [ite_eq_right hb] + exact tailProjection_mul_centered_tail t S hfree ha ha0 + (wordVector_mem_tail t S hw (by simpa [CanPrepend] using Ne.symm hb)) + +include hfree in +theorem tailProjection_mul_tendsto_zero (i : ι) (x : ℕ → A) + (hx : ∀ n, x n ∈ S i) (hx0 : ∀ n, t.functional (x n)=0) + (hbound : ∀ n, ‖t.functional.toPreGNS (star (x n))‖ ≤ 1) + (hmoment : ∀ a ∈ S i, Tendsto (fun n => t.functional (x n*a)) atTop (𝓝 0)) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (y : t.functional.GNS) : + Tendsto (fun n => (tailSpace t S i).starProjection (t.functional.gnsStarAlgHom (x n) y)) + atTop (𝓝 0) := by + let F : ℕ → t.functional.GNS →L[ℂ] t.functional.GNS := + fun n => (tailSpace t S i).starProjection * t.functional.gnsStarAlgHom (x n) + let P := zeroLimitSpace F + have hP : IsClosed (P : Set t.functional.GNS) := + zeroLimitSpace_closed F (fun n => (norm_tailProjection_mul t S hfree i (hx n)).trans (hbound n)) + have hw : ∀ w : List (Letter t S), Reduced w → wordVector t S w ∈ P := by + intro w hw + change Tendsto _ _ _ + simp only [F, mul_apply_eq_comp, + tailProjection_mul_word t S hfree i (hx _) (hx0 _) hw] + cases w with + | nil => exact tendsto_const_nhds + | cons b z => + by_cases hb : b.color=i + · simp only [ite_eq_left hb] + simpa only [zero_smul] using + (hmoment b.val (by simpa [hb] using b.mem)).smul_const (wordVector t S z) + · simp only [ite_eq_right hb] + exact tendsto_const_nhds + have hg : ∀ a ∈ iSup S, (t.functional.toPreGNS a : t.functional.GNS) ∈ P := by + intro a ha + have ha' : a ∈ FreeMoments.wordSpan S t.functional.toLinearMap := by + change a ∈ (FreeMoments.reducedAlgebra S (fun a => map_star t.functional a) t.normalized) + rw [FreeMoments.reducedAlgebra_eq_iSup] + exact ha + clear ha + induction ha' using Submodule.span_induction with + | mem a ha => obtain ⟨w, hr, rfl⟩ := ha; exact hw w hr + | zero => simp only [map_zero, Completion.coe_zero, Submodule.zero_mem] + | add a b _ _ ha hb => simpa only [map_add, Completion.coe_add] using P.add_mem ha hb + | smul c a _ ha => simpa only [map_smul, Completion.coe_smul] using P.smul_mem c ha + have hall : ∀ z : t.functional.GNS, z ∈ P := by + intro z + induction z using Completion.induction_on with + | hp => exact hP + | ih z => + let ξ : t.functional.GNS := (t.functional.toPreGNS 1 : t.functional.GNS) + have hz := Kadison.bicommutant_mem_cyclicSubspace (generatedOperators t S) + (hgen (t.functional.ofPreGNS z)) ξ + have heq : t.functional.gnsStarAlgHom (t.functional.ofPreGNS z) ξ = + (z : t.functional.GNS) := by + simp [ξ, PositiveLinearMap.gnsStarAlgHom] + rw [heq] at hz + apply closure_minimal (s := (Kadison.orbitSubmodule (generatedOperators t S) ξ : Set _)) + ?_ hP hz + rintro f ⟨a, ha, rfl⟩ + obtain ⟨b, hb, rfl⟩ := ha + simpa [ξ, PositiveLinearMap.gnsStarAlgHom] using hg b hb + exact hall y + +end Kadison.FreeCreation + +namespace Kadison.FreeCreation + +open FreeMoments FreeWordTensor Filter _root_.Topology + +open scoped InnerProductSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable (hfree : Free S t.functional.toLinearMap) + +include hfree in +lemma mul_head_norm {i j : ι} (hij : i ≠ j) {a : A} (ha : a ∈ S j) + (ha0 : t.functional a=0) (ha1 : ‖t.functional.toPreGNS a‖=1) + {y : t.functional.GNS} (hy : y ∈ headSpace t S i) : + t.functional.gnsStarAlgHom a y ∈ headSpace t S j ∧ + ‖t.functional.gnsStarAlgHom a y‖=‖y‖ := by + have ht := headSpace_le_other_tailSpace t S hij hy + exact ⟨creation_mem_headSpace t S j ha ha0 ht, + by rw [norm_mul_tailSpace t S hfree j ha ht, ha1, one_mul]⟩ + +include hfree in +lemma repeated_prefix_head {i j : ι} (hij : i ≠ j) {x s : A} + (hx : x ∈ S i) (hx0 : t.functional x=0) (hx1 : ‖t.functional.toPreGNS x‖=1) + (hs : s ∈ S j) (hs0 : t.functional s=0) (hs1 : ‖t.functional.toPreGNS s‖=1) + (k : ℕ) {y : t.functional.GNS} (hy : y ∈ headSpace t S i) : + t.functional.gnsStarAlgHom ((s*x)^k*s) y ∈ headSpace t S j ∧ + ‖t.functional.gnsStarAlgHom ((s*x)^k*s) y‖=‖y‖ := by + induction k with + | zero => simpa using mul_head_norm t S hfree hij hs hs0 hs1 hy + | succ k ih => + have h1 := mul_head_norm t S hfree hij.symm hx hx0 hx1 ih.1 + have h2 := mul_head_norm t S hfree hij hs hs0 hs1 h1.1 + have heq : t.functional.gnsStarAlgHom ((s*x)^(k+1)*s) y = + t.functional.gnsStarAlgHom s (t.functional.gnsStarAlgHom x + (t.functional.gnsStarAlgHom ((s*x)^k*s) y)) := by + simp only [pow_succ', mul_assoc, map_mul, mul_apply_eq_comp] + rw [heq] + exact ⟨h2.1, h2.2.trans (h1.2.trans ih.2)⟩ + +include hfree in +lemma prefix_split_bound {i j : ι} (hij : i ≠ j) {x s : A} + (hx : x ∈ S i) (hx0 : t.functional x=0) (hx1 : ‖t.functional.toPreGNS x‖=1) + (hs : s ∈ S j) (hs0 : t.functional s=0) (hs1 : ‖t.functional.toPreGNS s‖=1) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (k : ℕ) (y : t.functional.GNS) : + ‖t.functional.gnsStarAlgHom ((s*x)^k*s) y‖ ≤ ‖y‖ + + ‖(s*x)^k*s‖ * ‖(tailSpace t S i).starProjection y‖ := by + let P := (tailSpace t S i).starProjection + let L := t.functional.gnsStarAlgHom ((s*x)^k*s) + have hhead : y-P y ∈ headSpace t S i := by + rw [headSpace_eq_tailSpace_orthogonal t S hfree i hgen] + exact (tailSpace t S i).sub_starProjection_mem_orthogonal y + have hi := (repeated_prefix_head t S hfree hij hx hx0 hx1 hs hs0 hs1 k hhead).2 + have hnorm : ‖y-P y‖ ≤ ‖y‖ := by + have h := ((tailSpace t S i)ᗮ).norm_starProjection_apply_le y + simpa only [Submodule.starProjection_orthogonal', sub_apply, one_apply_eq_self] using h + calc + ‖L y‖ = ‖L (y-P y)+L (P y)‖ := by rw [← map_add, sub_add_cancel] + _ ≤ ‖L (y-P y)‖+‖L (P y)‖ := norm_add_le _ _ + _ ≤ ‖y‖+‖L‖*‖P y‖ := add_le_add (hi.le.trans hnorm) (L.le_opNorm _) + _ ≤ ‖y‖+‖(s*x)^k*s‖*‖P y‖ := by + exact add_le_add le_rfl (mul_le_mul_of_nonneg_right + (NonUnitalStarAlgHom.norm_apply_le t.functional.gnsStarAlgHom _) (norm_nonneg _)) + +include hfree in +theorem repeated_prefix_eventual_bound {i j : ι} (hij : i ≠ j) + (x : ℕ → A) (s : A) + (hx : ∀ n, x n ∈ S i) (hx0 : ∀ n, t.functional (x n)=0) + (hx1 : ∀ n, ‖t.functional.toPreGNS (x n)‖=1) + (hxs : ∀ n, ‖t.functional.toPreGNS (star (x n))‖≤1) + (hs : s ∈ S j) (hs0 : t.functional s=0) (hs1 : ‖t.functional.toPreGNS s‖=1) + (hmoment : ∀ a ∈ S i, Tendsto (fun n => t.functional (x n*a)) atTop (𝓝 0)) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (k : ℕ) (M : ℝ) (hM : ∀ n, ‖(s*x n)^k*s‖≤M) + (y : t.functional.GNS) (η : ℝ) (hη : 0<η) : + ∀ᶠ n in atTop, ‖t.functional.gnsStarAlgHom ((s*x n)^k*s) + (t.functional.gnsStarAlgHom (x n) y)‖ ≤ + ‖t.functional.gnsStarAlgHom (x n) y‖+η := by + have hz := tailProjection_mul_tendsto_zero t S hfree i x hx hx0 hxs hmoment hgen y + have hz' : Tendsto (fun n => M*‖(tailSpace t S i).starProjection + (t.functional.gnsStarAlgHom (x n) y)‖) atTop (𝓝 0) := by + simpa only [norm_zero, mul_zero] using hz.norm.const_mul M + have he : ∀ᶠ n in atTop, M*‖(tailSpace t S i).starProjection + (t.functional.gnsStarAlgHom (x n) y)‖<η := hz'.eventually_lt_const hη + filter_upwards [he] with n hn + exact (prefix_split_bound t S hfree hij (hx n) (hx0 n) (hx1 n) hs hs0 hs1 hgen k _).trans + (add_le_add le_rfl ((mul_le_mul_of_nonneg_right (hM n) (norm_nonneg _)).trans hn.le)) + +end Kadison.FreeCreation + +namespace Kadison.FreeCreation + +open FreeWordTensor + +open scoped InnerProductSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) + +lemma norm_mul_supported (x q : A) (c : ℝ) (hc : 0≤c) + (hxx : star x*x=(c : ℂ) • q) (y : t.functional.GNS) + (hy : t.functional.gnsStarAlgHom q y=y) : + ‖t.functional.gnsStarAlgHom x y‖=Real.sqrt c*‖y‖ := by + have hi := ContinuousLinearMap.adjoint_inner_right (t.functional.gnsStarAlgHom x) y + (t.functional.gnsStarAlgHom x y) + change inner ℂ y ((star (t.functional.gnsStarAlgHom x)*t.functional.gnsStarAlgHom x) y) = _ at hi + rw [←map_star, ←map_mul, hxx, map_smul, smul_apply, hy, inner_smul_right, + inner_self_eq_norm_sq_to_K, inner_self_eq_norm_sq_to_K] at hi + have hr := congrArg Complex.re hi + have heq : c*‖y‖^2=‖t.functional.gnsStarAlgHom x y‖^2 := by + simpa only [RCLike.ofReal_eq_complex_ofReal, ← Complex.ofReal_pow, + ←Complex.ofReal_mul, Complex.ofReal_re] using hr + have hs := Real.sq_sqrt hc + have hpos := mul_nonneg (Real.sqrt_nonneg c) (norm_nonneg y) + nlinarith [norm_nonneg (t.functional.gnsStarAlgHom x y)] + +end Kadison.FreeCreation + +namespace Kadison + +open Filter _root_.Topology + +lemma propagation_limit_bound (D R : ℝ) (a b : ℕ → ℝ) + (hD : ∀ n, D≤R+a n) (ha : ∀ n, a n≤R+b n) + (hb : Tendsto b atTop (𝓝 0)) : D≤2*R := by + apply le_of_forall_pos_le_add + intro η hη + obtain ⟨n, hn⟩ := (hb.eventually_le_const hη).exists + have h := (hD n).trans (add_le_add le_rfl ((ha n).trans (add_le_add le_rfl hn))) + linarith + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreePropagationCorner.lean b/lean/OAI/Analysis/Commutator/FreePropagationCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..5a171ce4f0a33d66941d36c564e33c5b09771bb0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreePropagationCorner.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.FreePropagationEstimate +import OAI.Analysis.Commutator.RepresentedLocalModule + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open Filter Topology ContinuousLinearMap + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +variable (hB : ∀ n d (x : letterSpace t S i) v, + G (repeatedOutput t S f hf hS hfree hij d x n v)= + repeatedOutput t S f hf hS hfree hij d x n (B n v)) + +variable (hGL : ∀ d : D, G.comp (t.functional.gnsStarAlgHom (f d))= + (t.functional.gnsStarAlgHom (f d)).comp G) + +variable (M : VonNeumannAlgebra t.functional.GNS) + (hM : ∀ a : A, t.functional.gnsStarAlgHom a∈M) + +include hB hGL hM in +theorem propagation_from_corner {κ : Type*} [Fintype κ] [DecidableEq κ] + (s : letterSpace t S j) (hs : ‖s‖=1) + (q : D) (hq : IsStarProjection q) + (w : κ → D) + (hcol : ∀ i j, star (w i)*w j=if i=j then q else 0) + (hinit : ∀ i, q*star (w i)=star (w i)) + (htotal : ∑ i, w i*star (w i)=1) + (c : ℝ) (hc : 0≤c) + (x : ℕ → letterSpace t S i) (hx : ∀ n, ‖x n‖=1) + (hxq : ∀ n, letterValue t S i (x n)*f q=letterValue t S i (x n)) + (hxx : ∀ n, star (letterValue t S i (x n))*letterValue t S i (x n)=(c:ℂ) • f q) + (hxs : ∀ n, ‖t.functional.toPreGNS (star (letterValue t S i (x n)))‖≤1) + (hmoment : ∀ a ∈ S i, Tendsto (fun n => t.functional (letterValue t S i (x n)*a)) atTop (𝓝 0)) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (k : ℕ) (R : ℝ) + (hR : ∀ n, ‖(letterValue t S j s*letterValue t S i (x n))^k*letterValue t S j s‖≤R) + (ε : ℝ) (hε : 0≤ε) + (hsmall : ∀ a : t.functional.GNS →L[ℂ] t.functional.GNS, a∈M → + t.functional.gnsStarAlgHom (f q)*a=a → a*t.functional.gnsStarAlgHom (f q)=a → + ‖G.comp a-a.comp G‖≤ε*‖a‖) + (v : multiplicityLevel t S j 0) : + ‖B (k+1) (repeatInsertion t S s hs (k+1) v)- + repeatInsertion t S s hs (k+1) (B 0 v)‖≤32*ε*‖v‖ := by + let L := t.functional.gnsStarAlgHom + let ξ := L (f q) (blockEmbedding t S hfree hij 0 v) + have hfix : L (f q) ξ=ξ := by + change (L (f q)*L (f q)) _=L (f q) _ + rw [←map_mul,←map_mul,hq.isIdempotentElem.eq] + have hc' (i j : κ) : star (f (w i))*f (w j)=if i=j then f q else 0 := by + simpa only [map_mul,map_star,apply_ite,map_zero] using congrArg f (hcol i j) + have hi' (i : κ) : f q*star (f (w i))=star (f (w i)) := by + simpa only [map_mul,map_star] using congrArg f (hinit i) + have ht' : ∑ i, f (w i)*star (f (w i))=1 := by + simpa only [map_sum,map_mul,map_star,map_one] using congrArg f htotal + obtain ⟨T,hT,hn⟩ := MatrixCornerImplementation.exists_represented_local_module + L M hM (hq.map f) (fun i => f (w i)) hc' hi' ht' G (hGL q) + (fun i => hGL (w i)) ξ hfix hε hsmall + have h := propagation_of_local_module t S f hf hS hfree hij G B hB s hs q hq c hc + x hx hxq hxx hxs hmoment hgen k R hR (16*ε) (by positivity) v T hT hn + convert h using 1; ring + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreePropagationEstimate.lean b/lean/OAI/Analysis/Commutator/FreePropagationEstimate.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ba1817837f0ec1109d4d19bfbe8ef4ae14b8f2d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreePropagationEstimate.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.Commutator.FreePropagation +import OAI.Analysis.Commutator.FreeRepeatedWords + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open Filter _root_.Topology ContinuousLinearMap + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +lemma norm_factorVector (d : D) : + ‖TracialGNS.algebraVector (factorTrace t f hf) d‖= + ‖(t.functional.toPreGNS (f d) : t.functional.GNS)‖ := by + simp only [TracialGNS.algebraVector_apply,UniformSpace.Completion.norm_coe, + PositiveLinearMap.preGNS_norm_def,PositiveLinearMap.ofPreGNS_toPreGNS, + pullbackState_apply,map_mul,map_star] + +lemma scale_normalization (q : D) (hq : IsStarProjection q) (x : A) + (hx : ‖t.functional.toPreGNS x‖=1) (hxq : x*f q=x) (c : ℝ) (hc : 0≤c) + (hxx : star x*x=(c:ℂ) • f q) : + Real.sqrt c*‖TracialGNS.algebraVector (factorTrace t f hf) q‖=1 := by + let y : t.functional.GNS := t.functional.toPreGNS (f q) + have hy : t.functional.gnsStarAlgHom (f q) y=y := by + change t.functional.gnsStarAlgHom (f q) (t.functional.toPreGNS (f q) : t.functional.GNS)=_ + rw [TracialGNS.left_coe,←map_mul,hq.isIdempotentElem.eq] + have hn := FreeCreation.norm_mul_supported t x (f q) c hc hxx y hy + have hn' : ‖t.functional.gnsStarAlgHom x y‖=1 := by + change ‖t.functional.gnsStarAlgHom x (t.functional.toPreGNS (f q) : t.functional.GNS)‖=1 + rw [TracialGNS.left_coe,hxq,UniformSpace.Completion.norm_coe,hx] + rw [hn'] at hn + rw [norm_factorVector] + exact hn.symm + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +variable (hB : ∀ n d (x : letterSpace t S i) v, + G (repeatedOutput t S f hf hS hfree hij d x n v)= + repeatedOutput t S f hf hS hfree hij d x n (B n v)) + +include hB in +theorem propagation_of_local_module + (s : letterSpace t S j) (hs : ‖s‖=1) + (q : D) (hq : IsStarProjection q) (c : ℝ) (hc : 0≤c) + (x : ℕ → letterSpace t S i) (hx : ∀ n, ‖x n‖=1) + (hxq : ∀ n, letterValue t S i (x n)*f q=letterValue t S i (x n)) + (hxx : ∀ n, star (letterValue t S i (x n))*letterValue t S i (x n)=(c:ℂ) • f q) + (hxs : ∀ n, ‖t.functional.toPreGNS (star (letterValue t S i (x n)))‖≤1) + (hmoment : ∀ a ∈ S i, Tendsto (fun n => t.functional (letterValue t S i (x n)*a)) atTop (𝓝 0)) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (k : ℕ) (M : ℝ) (hM : ∀ n, ‖(letterValue t S j s*letterValue t S i (x n))^k*letterValue t S j s‖≤M) + (δ : ℝ) (hδ : 0≤δ) (v : multiplicityLevel t S j 0) + (T : t.functional.GNS →L[ℂ] t.functional.GNS) + (hT : ∀ a : A, T.comp (t.functional.gnsStarAlgHom a)=(t.functional.gnsStarAlgHom a).comp T) + (happrox : ∀ z ∈ cyclicSubspace t.functional.gnsStarAlgHom.range + (t.functional.gnsStarAlgHom (f q) (blockEmbedding t S hfree hij 0 v)), + ‖G z-T z‖≤δ*‖z‖) : + ‖B (k+1) (repeatInsertion t S s hs (k+1) v)- + repeatInsertion t S s hs (k+1) (B 0 v)‖≤2*δ*‖v‖ := by + have hscale : Real.sqrt c*‖TracialGNS.algebraVector (factorTrace t f hf) q‖≤1 := by + apply (scale_normalization t f hf q hq (letterValue t S i (x 0)) ?_ (hxq 0) c hc (hxx 0)).le + change ‖t.functional.toPreGNS (t.functional.ofPreGNS (x 0 : preSpace t))‖=1 + rw [PositiveLinearMap.toPreGNS_ofPreGNS] + exact hx 0 + let L := t.functional.gnsStarAlgHom + let b0 := blockEmbedding t S hfree hij 0 + let ξ := L (f q) (b0 v) + let y := T ξ-G ξ + have hTapp (a : A) (z : t.functional.GNS) : T (L a z)=L a (T z) := + congrArg (fun R : t.functional.GNS →L[ℂ] t.functional.GNS => R z) (hT a) + have hqξ : L (f q) ξ=ξ := by + change (L (f q)*L (f q)) (b0 v)=L (f q) (b0 v) + rw [←map_mul,←map_mul,hq.isIdempotentElem.eq] + have hGξ : G ξ=L (f q) (b0 (B 0 v)) := + base_intertwining t S f hf hS hfree hij G B hB s hs (x 0) q v + have hqy : L (f q) y=y := by + dsimp only [y] + rw [map_sub,←hTapp,hqξ,hGξ] + change T ξ-(L (f q)*L (f q)) (b0 (B 0 v))=T ξ-L (f q) (b0 (B 0 v)) + rw [←map_mul,←map_mul,hq.isIdempotentElem.eq] + have hy : ‖y‖≤δ*(‖TracialGNS.algebraVector (factorTrace t f hf) q‖*‖v‖) := by + have he := happrox ξ (mem_cyclicSubspace_self _ _) + rw [norm_sub_rev] at he + have hn := norm_base_mul t S f hf hS hfree hij s hs (x 0) q v + exact he.trans_eq (congrArg (fun r : ℝ => δ*r) hn) + have hxy (n : ℕ) : ‖L (letterValue t S i (x n)) y‖≤δ*‖v‖ := by + rw [FreeCreation.norm_mul_supported t _ (f q) c hc (hxx n) y hqy] + calc + _ ≤ Real.sqrt c*(δ*(‖TracialGNS.algebraVector (factorTrace t f hf) q‖*‖v‖)) := + mul_le_mul_of_nonneg_left hy (Real.sqrt_nonneg c) + _ = (Real.sqrt c*‖TracialGNS.algebraVector (factorTrace t f hf) q‖)*(δ*‖v‖) := by ring + _ ≤ 1*(δ*‖v‖) := mul_le_mul_of_nonneg_right hscale (mul_nonneg hδ (norm_nonneg _)) + _ = _ := one_mul _ + have hnormx (n : ℕ) : ‖t.functional.toPreGNS (letterValue t S i (x n))‖=1 := by + change ‖t.functional.toPreGNS (t.functional.ofPreGNS (x n : preSpace t))‖=1 + rw [PositiveLinearMap.toPreGNS_ofPreGNS] + exact hx n + have hnorms : ‖t.functional.toPreGNS (letterValue t S j s)‖=1 := by + change ‖t.functional.toPreGNS (t.functional.ofPreGNS (s : preSpace t))‖=1 + rw [PositiveLinearMap.toPreGNS_ofPreGNS] + exact hs + apply le_of_forall_pos_le_add + intro η hη + have hevent := FreeCreation.repeated_prefix_eventual_bound t S hfree hij + (fun n => letterValue t S i (x n)) (letterValue t S j s) + (fun n => (x n).property.1) (fun n => (x n).property.2) hnormx hxs + s.property.1 s.property.2 hnorms hmoment hgen k M hM y η hη + obtain ⟨n, hn⟩ := hevent.exists + let a := (letterValue t S j s*letterValue t S i (x n))^k*letterValue t S j s + let ξn := L ((letterValue t S j s*letterValue t S i (x n))^(k+1)) (b0 v) + have hp : (letterValue t S j s*letterValue t S i (x n))^(k+1)=a*letterValue t S i (x n) := by + dsimp only [a] + rw [pow_succ,mul_assoc] + have hξn : ξn=L (a*letterValue t S i (x n)) ξ := by + dsimp only [ξn,ξ] + rw [hp] + change L (a*letterValue t S i (x n)) (b0 v)= + (L (a*letterValue t S i (x n))*L (f q)) (b0 v) + have hsupp : (a*letterValue t S i (x n))*f q=a*letterValue t S i (x n) := + (mul_assoc _ _ _).trans (congrArg (fun b : A => a*b) (hxq n)) + rw [←map_mul,hsupp] + have hmem : ξn ∈ cyclicSubspace L.range ξ := by + rw [hξn] + exact cyclicSubspace_invariant L.range ξ (show L _ ∈ L.range from ⟨_,rfl⟩) ξ (mem_cyclicSubspace_self _ _) + have hξnorm : ‖ξn‖=‖v‖ := repeated_norm t S f hf hS hfree hij s hs (x n) (hx n) (k+1) v + have hcomp (z : t.functional.GNS) : L a (L (letterValue t S i (x n)) (L (f q) z))= + L ((letterValue t S j s*letterValue t S i (x n))^(k+1)) z := by + change (L a*(L (letterValue t S i (x n))*L (f q))) z=_ + rw [←map_mul,hxq n,←map_mul,←hp] + have heq : G ξn-L ((letterValue t S j s*letterValue t S i (x n))^(k+1)) (b0 (B 0 v))= + (G ξn-T ξn)+L a (L (letterValue t S i (x n)) y) := by + rw [hξn,hTapp] + dsimp only [y] + rw [map_sub,map_sub,hGξ,hcomp] + simp only [map_mul,mul_apply_eq_comp] + abel + have hfixed := repeated_error_norm t S f hf hS hfree hij G B hB s hs (x n) (hx n) (k+1) v + rw [←hfixed] + change ‖G ξn-L _ (b0 (B 0 v))‖≤_ + rw [heq] + have hfirst := happrox ξn hmem + rw [hξnorm] at hfirst + have hsecond : ‖L a (L (letterValue t S i (x n)) y)‖≤δ*‖v‖+η := + hn.trans (add_le_add (hxy n) le_rfl) + exact (norm_add_le _ _).trans ((add_le_add hfirst hsecond).trans_eq (by ring)) + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreePropagationStage.lean b/lean/OAI/Analysis/Commutator/FreePropagationStage.lean new file mode 100644 index 0000000000000000000000000000000000000000..28f751c4bc385eb25a448f3af6a597091faf0e05 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreePropagationStage.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerWeakZero +import OAI.Analysis.Commutator.FreeLetterIntertwine +import OAI.Analysis.Commutator.FreePropagationCorner + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open Filter Topology ContinuousLinearMap + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a)=φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hDgen : ∀ a : D, (factorTrace t f hf).gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra (factorTrace t f hf) I φ : Set _))) + +variable (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +variable (hB : ∀ n d (x : letterSpace t S i) v, + G (repeatedOutput t S f hf hS hfree hij d x n v)= + repeatedOutput t S f hf hS hfree hij d x n (B n v)) + +variable (hGL : ∀ d : D, G.comp (t.functional.gnsStarAlgHom (f d))= + (t.functional.gnsStarAlgHom (f d)).comp G) + +variable (M : VonNeumannAlgebra t.functional.GNS) + (hM : ∀ a : A, t.functional.gnsStarAlgHom a∈M) + +include htr he hsize hDgen hgen hB hGL hM in +theorem propagation_from_stage {κ : Type*} [Fintype κ] [DecidableEq κ] + (s : letterSpace t S j) (hs : ‖s‖=1) + (n : ℕ) (p : Matrix (I n) (I n) ℂ) (hp : IsStarProjection p) + (α : ℝ) (hα : 0<α) (hατ : factorTrace t f hf (φ n p)=(α:ℂ)) + (w : κ → D) + (hcol : ∀ i j, star (w i)*w j=if i=j then φ n p else 0) + (hinit : ∀ i, φ n p*star (w i)=star (w i)) + (htotal : ∑ i, w i*star (w i)=1) + (ε : ℝ) (hε : 0≤ε) + (hsmall : ∀ a : t.functional.GNS →L[ℂ] t.functional.GNS, a∈M → + t.functional.gnsStarAlgHom (f (φ n p))*a=a → + a*t.functional.gnsStarAlgHom (f (φ n p))=a → ‖G.comp a-a.comp G‖≤ε*‖a‖) + (k : ℕ) (v : multiplicityLevel t S j 0) : + ‖B (k+1) (repeatInsertion t S s hs (k+1) v)- + repeatInsertion t S s hs (k+1) (B 0 v)‖≤32*ε*‖v‖ := by + have h1 : factorTrace t f hf 1=1 := by + change t.functional (f 1)=1 + simpa only [map_one] using t.normalized + obtain ⟨y,hy,hm⟩ := TracialGNS.exists_corner_weak_zero (factorTrace t f hf) + (factorTrace_tracial t f hf htr) h1 I φ e he hsize hDgen n p hp α hα hατ + have hy0 (l : ℕ) : t.functional (f (y l))=0 := (hy l).1 + have hym (l : ℕ) : f (y l)∈S i := by rw [hS]; exact ⟨y l,rfl⟩ + let x : ℕ → letterSpace t S i := fun l => letterOf t S i (f (y l)) (hym l) (hy0 l) + have hxv (l : ℕ) : letterValue t S i (x l)=f (y l) := letterValue_letterOf _ _ _ _ _ _ + have hnorm (a : D) : ‖t.functional.toPreGNS (f a)‖=‖(factorTrace t f hf).toPreGNS a‖ := by + have ht := norm_factorVector t f hf a + simpa only [TracialGNS.algebraVector_apply,UniformSpace.Completion.norm_coe] using ht.symm + have hxn (l : ℕ) : ‖x l‖=1 := by + change ‖t.functional.toPreGNS (f (y l))‖=1 + rw [hnorm] + exact (hy l).2.2.2.2.1 + have hxq (l : ℕ) : letterValue t S i (x l)*f (φ n p)=letterValue t S i (x l) := by + rw [hxv,←map_mul,(hy l).2.1] + have hxx (l : ℕ) : star (letterValue t S i (x l))*letterValue t S i (x l)= + ((α⁻¹:ℝ):ℂ) • f (φ n p) := by + rw [hxv,←map_star,←map_mul,(hy l).2.2.1,map_smul,Complex.ofReal_inv] + have hxs (l : ℕ) : ‖t.functional.toPreGNS (star (letterValue t S i (x l)))‖≤1 := by + rw [hxv,←map_star,hnorm,(hy l).2.2.2.2.2] + have hxmoment : ∀ a ∈ S i, + Tendsto (fun l => t.functional (letterValue t S i (x l)*a)) atTop (𝓝 0) := by + intro a ha + rw [hS] at ha + obtain ⟨b,rfl⟩ := ha + have hb := hm b + change Tendsto (fun l => t.functional (f (y l*b))) atTop (𝓝 0) at hb + change Tendsto (fun l => t.functional (letterValue t S i (x l)*f b)) atTop (𝓝 0) + simpa only [hxv,map_mul] using hb + have hxb (l : ℕ) : ‖letterValue t S i (x l)‖≤(Real.sqrt α)⁻¹ := by + rw [hxv] + exact (NonUnitalStarAlgHom.norm_apply_le f _).trans (hy l).2.2.2.1 + let : Nontrivial A := ⟨⟨1,0,by + intro h + have hh := t.normalized + rw [h,map_zero] at hh + exact zero_ne_one hh⟩⟩ + let R := (‖letterValue t S j s‖*(Real.sqrt α)⁻¹)^k*‖letterValue t S j s‖ + have hR (l : ℕ) : ‖(letterValue t S j s*letterValue t S i (x l))^k*letterValue t S j s‖≤R := by + apply (norm_mul_le _ _).trans + apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) + apply (norm_pow_le _ _).trans + exact pow_le_pow_left₀ (norm_nonneg _) ((norm_mul_le _ _).trans + (mul_le_mul_of_nonneg_left (hxb l) (norm_nonneg _))) k + exact propagation_from_corner t S f hf hS hfree hij G B hB hGL M hM s hs + (φ n p) (hp.map (φ n)) w hcol hinit htotal α⁻¹ (by positivity) x hxn hxq hxx hxs + hxmoment hgen k R hR ε hε hsmall v + +lemma repeatInsertion_zero (s : letterSpace t S j) (hs : ‖s‖=1) + (v : multiplicityLevel t S j 0) : repeatInsertion t S s hs 0 v=v := by + induction v using UniformSpace.Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih v => rw [repeatInsertion_coe]; rfl + +include htr he hsize hDgen hgen hB hGL hM in +theorem propagation_from_stage_all {κ : Type*} [Fintype κ] [DecidableEq κ] + (s : letterSpace t S j) (hs : ‖s‖=1) + (n : ℕ) (p : Matrix (I n) (I n) ℂ) (hp : IsStarProjection p) + (α : ℝ) (hα : 0<α) (hατ : factorTrace t f hf (φ n p)=(α:ℂ)) + (w : κ → D) + (hcol : ∀ i j, star (w i)*w j=if i=j then φ n p else 0) + (hinit : ∀ i, φ n p*star (w i)=star (w i)) + (htotal : ∑ i, w i*star (w i)=1) + (ε : ℝ) (hε : 0≤ε) + (hsmall : ∀ a : t.functional.GNS →L[ℂ] t.functional.GNS, a∈M → + t.functional.gnsStarAlgHom (f (φ n p))*a=a → + a*t.functional.gnsStarAlgHom (f (φ n p))=a → ‖G.comp a-a.comp G‖≤ε*‖a‖) + (k : ℕ) (v : multiplicityLevel t S j 0) : + ‖B k (repeatInsertion t S s hs k v)- + repeatInsertion t S s hs k (B 0 v)‖≤32*ε*‖v‖ := by + cases k with + | zero => + rw [repeatInsertion_zero t S s hs v,repeatInsertion_zero t S s hs (B 0 v),sub_self] + change ‖(0 : UniformSpace.Completion (factorSpace t S j))‖≤32*ε*‖v‖ + calc + ‖(0 : UniformSpace.Completion (factorSpace t S j))‖ = 0 := _root_.norm_zero + _ ≤ 32*ε*‖v‖ := by positivity + | succ k => + exact propagation_from_stage t htr S f hf hS hfree hij I φ e he + hsize hDgen hgen G B hB hGL M hM s hs n p hp α hα hατ w hcol hinit htotal + ε hε hsmall k v + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeRepeatedWords.lean b/lean/OAI/Analysis/Commutator/FreeRepeatedWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..c8350d6459c1f85efd31e8753d6af68b18809445 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeRepeatedWords.lean @@ -0,0 +1,278 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeCovariance + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace TensorProduct ComplexOrder + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} + +def repeatedParams (s : letterSpace t S j) (x : letterSpace t S i) + (v : factorSpace t S j) : ∀ n, BlockParams t S i j n + | 0 => v + | n+1 => ((s,x),repeatedParams s x v n) + +@[simp] lemma repeatedParams_D (s : letterSpace t S j) (x : letterSpace t S i) + (v : factorSpace t S j) (n : ℕ) : + paramD t S n (repeatedParams t S s x v n)=fun _ => x := by + induction n with + | zero => funext k; exact Fin.elim0 k + | succ n ih => + funext k + refine Fin.cases ?_ (fun k => ?_) k + · rfl + · exact congrFun ih _ + +def repeatPre (s : letterSpace t S j) : ∀ n, + factorSpace t S j →ₗ[ℂ] multiplicityTensor t S j n + | 0 => LinearMap.id + | n+1 => (TensorProduct.mk ℂ (letterSpace t S j) (multiplicityTensor t S j n) s).comp + (repeatPre s n) + +@[simp] lemma repeatedParams_J (s : letterSpace t S j) (x : letterSpace t S i) + (v : factorSpace t S j) (n : ℕ) : + paramJ t S n (repeatedParams t S s x v n)=repeatPre t S s n v := by + induction n with + | zero => rfl + | succ n ih => + change s ⊗ₜ[ℂ] paramJ t S n (repeatedParams t S s x v n)= + s ⊗ₜ[ℂ] repeatPre t S s n v + rw [ih] + +lemma norm_repeatPre (s : letterSpace t S j) (n : ℕ) (v : factorSpace t S j) : + ‖repeatPre t S s n v‖=‖s‖^n*‖v‖ := by + induction n with + | zero => simp [repeatPre] + | succ n ih => + change ‖s ⊗ₜ[ℂ] repeatPre t S s n v‖=_ + rw [TensorProduct.norm_tmul,ih,pow_succ'] + exact (mul_assoc _ _ _).symm + +def repeatPreIsometry (s : letterSpace t S j) (hs : ‖s‖=1) (n : ℕ) : + factorSpace t S j →ₗᵢ[ℂ] multiplicityTensor t S j n where + toLinearMap := repeatPre t S s n + norm_map' v := by rw [norm_repeatPre,hs,one_pow,one_mul] + +def repeatInsertion (s : letterSpace t S j) (hs : ‖s‖=1) (n : ℕ) : + multiplicityLevel t S j 0 →ₗᵢ[ℂ] multiplicityLevel t S j n := + HilbertCompletion.map (repeatPreIsometry t S s hs n) + +@[simp] lemma repeatInsertion_coe (s : letterSpace t S j) (hs : ‖s‖=1) + (n : ℕ) (v : factorSpace t S j) : + repeatInsertion t S s hs n (v : multiplicityLevel t S j 0)= + (repeatPre t S s n v : multiplicityLevel t S j n) := by + exact HilbertCompletion.map_coe (repeatPreIsometry t S s hs n) v + +@[simp] lemma blockRead_repeated (s : letterSpace t S j) (x : letterSpace t S i) + (n : ℕ) (v : factorSpace t S j) : + blockRead t S n (blockPure t S n (repeatedParams t S s x v n))= + (letterValue t S j s*letterValue t S i x)^n*factorValue t S j v := by + induction n with + | zero => simp [repeatedParams,blockPure,blockRead] + | succ n ih => + change letterValue t S j s*(letterValue t S i x* + blockRead t S n (blockPure t S n (repeatedParams t S s x v n)))=_ + rw [ih,pow_succ'] + simp only [mul_assoc] + +variable (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +private def tensorOutput {Left Right Target : Type*} + [NormedAddCommGroup Left] [InnerProductSpace ℂ Left] + [NormedAddCommGroup Right] [InnerProductSpace ℂ Right] + [NormedAddCommGroup Target] [InnerProductSpace ℂ Target] + (embedding : Completion (Left ⊗[ℂ] Right) →ₗᵢ[ℂ] Target) (vector : Left) : + Right →L[ℂ] Target := + embedding.toContinuousLinearMap.comp (HilbertTensor.insertLeft vector) + +private lemma norm_tensorOutput {Left Right Target : Type*} + [NormedAddCommGroup Left] [InnerProductSpace ℂ Left] + [NormedAddCommGroup Right] [InnerProductSpace ℂ Right] + [NormedAddCommGroup Target] [InnerProductSpace ℂ Target] + (embedding : Completion (Left ⊗[ℂ] Right) →ₗᵢ[ℂ] Target) + (vector : Left) (value : Right) : + ‖tensorOutput embedding vector value‖ = ‖vector‖ * ‖value‖ := by + change ‖embedding (HilbertTensor.pair vector value)‖ = _ + rw [embedding.norm_map, HilbertTensor.norm_pair] + +def repeatedOutput (d : D) (x : letterSpace t S i) (n : ℕ) : + multiplicityLevel t S j n →L[ℂ] t.functional.GNS := + tensorOutput (Left := sourceScalar t f hf n) (Right := multiplicityLevel t S j n) + (sourceLevelEmbedding t f hf S i j hS hfree hij n) + (PreHilbert.word (factorFull t f hf) (factorZero t f hf) n + (TracialGNS.algebraVector (factorTrace t f hf) d) + (fun _ => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x))) + +lemma repeatedOutput_bounded (d : D) (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (n : ℕ) (v : factorSpace t S j) : + repeatedOutput t S f hf hS hfree hij d x n + (repeatInsertion t S s hs n (v : multiplicityLevel t S j 0))= + t.functional.gnsStarAlgHom (f d) + (t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 (v : multiplicityLevel t S j 0))) := by + have hn : repeatedOutput t S f hf hS hfree hij d x n + (repeatInsertion t S s hs n (v : multiplicityLevel t S j 0))= + sourceLevelEmbedding t f hf S i j hS hfree hij n + (levelWord t f hf S i j hS d n (repeatedParams t S s x v n)) := by + rw [repeatInsertion_coe] + simp only [repeatedOutput,tensorOutput,ContinuousLinearMap.comp_apply,HilbertTensor.insertLeft_apply, + levelWord,repeatedParams_D,repeatedParams_J] + rfl + rw [hn,sourceLevelEmbedding_word] + congr 1 + change (t.functional.toPreGNS + (blockRead t S n (blockPure t S n (repeatedParams t S s x v n))) : t.functional.GNS)=_ + rw [blockRead_repeated] + have hv : blockEmbedding t S hfree hij 0 (v : multiplicityLevel t S j 0)= + (t.functional.toPreGNS (factorValue t S j v) : t.functional.GNS) := by + simp [blockEmbedding,blockIsometry,blockReadPre,blockRead] + rw [hv] + simp [PositiveLinearMap.gnsStarAlgHom] + +lemma norm_repeatedOutput_one (x : letterSpace t S i) (hx : ‖x‖=1) + (n : ℕ) (v : multiplicityLevel t S j n) : + ‖repeatedOutput t S f hf hS hfree hij 1 x n v‖=‖v‖ := by + rw [repeatedOutput, norm_tensorOutput] + have hw := PreHilbert.norm_word (factorFull t f hf) + (factorZero t f hf) n + (TracialGNS.algebraVector (factorTrace t f hf) 1) + (fun _ => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x)) + have hnorm : ‖TracialGNS.algebraVector (factorTrace t f hf) 1‖=1 := by + apply TracialGNS.vacuum_norm + change t.functional (f 1)=1 + simpa using t.normalized + have hxnorm : ∀ k : Fin n, + ‖letterGNSIso t f hf S i hS (HilbertCompletion.coeIsometry (dLetters t S i) x)‖=1 := by + intro k + exact (letterGNSIso t f hf S i hS).norm_map _ |>.trans + ((HilbertCompletion.coeIsometry (dLetters t S i)).norm_map _ |>.trans hx) + have hw1 : ‖PreHilbert.word (factorFull t f hf) + (factorZero t f hf) n + (TracialGNS.algebraVector (factorTrace t f hf) 1) + (fun _ => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x))‖=1 := + hw.trans (by rw [hnorm,one_mul]; exact Finset.prod_eq_one (fun k _ => hxnorm k)) + exact (congrArg (fun r : ℝ => r*‖v‖) hw1).trans (one_mul _) + +lemma repeatedOutput_inserted (d : D) (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (n : ℕ) (v : multiplicityLevel t S j 0) : + repeatedOutput t S f hf hS hfree hij d x n + (repeatInsertion t S s hs n v)=t.functional.gnsStarAlgHom (f d) + (t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 v)) := by + induction v using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih v => exact repeatedOutput_bounded t S f hf hS hfree hij d s hs x n v + +lemma repeatedOutput_zero (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (d : D) (v : multiplicityLevel t S j 0) : + repeatedOutput t S f hf hS hfree hij d x 0 v= + t.functional.gnsStarAlgHom (f d) (blockEmbedding t S hfree hij 0 v) := by + have hr : repeatInsertion t S s hs 0 v=v := by + induction v using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih v => rw [repeatInsertion_coe]; rfl + simpa [hr] using + repeatedOutput_inserted t S f hf hS hfree hij d s hs x 0 v + +lemma norm_repeatedOutput (d : D) (x : letterSpace t S i) + (n : ℕ) (v : multiplicityLevel t S j n) : + ‖repeatedOutput t S f hf hS hfree hij d x n v‖= + ‖TracialGNS.algebraVector (factorTrace t f hf) d‖*‖x‖^n*‖v‖ := by + rw [repeatedOutput, norm_tensorOutput] + have hw := PreHilbert.norm_word (factorFull t f hf) + (factorZero t f hf) n + (TracialGNS.algebraVector (factorTrace t f hf) d) + (fun _ => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x)) + have hxnorm (k : Fin n) : ‖letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x)‖ = ‖x‖ := by + exact (letterGNSIso t f hf S i hS).norm_map _ |>.trans + ((HilbertCompletion.coeIsometry (dLetters t S i)).norm_map _) + have hprod : ∏ k : Fin n, ‖letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) x)‖ = ‖x‖^n := by + calc + _ = ∏ _k : Fin n, ‖x‖ := Finset.prod_congr rfl (fun k _ => hxnorm k) + _ = _ := by simp + exact congrArg (fun r : ℝ => r*‖v‖) + (hw.trans (congrArg (fun r : ℝ => ‖TracialGNS.algebraVector (factorTrace t f hf) d‖*r) hprod)) + +include hS in +lemma norm_base_mul (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (d : D) (v : multiplicityLevel t S j 0) : + ‖t.functional.gnsStarAlgHom (f d) (blockEmbedding t S hfree hij 0 v)‖= + ‖TracialGNS.algebraVector (factorTrace t f hf) d‖*‖v‖ := by + rw [←repeatedOutput_zero t S f hf hS hfree hij s hs x d v, + norm_repeatedOutput] + simp + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (B : ∀ n, multiplicityLevel t S j n →L[ℂ] multiplicityLevel t S j n) + +variable (hB : ∀ n d (x : letterSpace t S i) v, + G (repeatedOutput t S f hf hS hfree hij d x n v)= + repeatedOutput t S f hf hS hfree hij d x n (B n v)) + +include hB in +lemma base_intertwining (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (d : D) (v : multiplicityLevel t S j 0) : + G (t.functional.gnsStarAlgHom (f d) (blockEmbedding t S hfree hij 0 v))= + t.functional.gnsStarAlgHom (f d) (blockEmbedding t S hfree hij 0 (B 0 v)) := by + simpa only [repeatedOutput_zero t S f hf hS hfree hij s hs x] using hB 0 d x v + +include hB in +lemma repeated_error_norm (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (hx : ‖x‖=1) (n : ℕ) (v : multiplicityLevel t S j 0) : + ‖G (t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 v))- + t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 (B 0 v))‖= + ‖B n (repeatInsertion t S s hs n v)-repeatInsertion t S s hs n (B 0 v)‖ := by + have hout (z : multiplicityLevel t S j 0) : + repeatedOutput t S f hf hS hfree hij 1 x n (repeatInsertion t S s hs n z)= + t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 z) := by + simpa using repeatedOutput_inserted t S f hf hS hfree hij 1 s hs x n z + rw [←hout v,←hout (B 0 v),hB,←map_sub] + exact norm_repeatedOutput_one t S f hf hS hfree hij x hx n _ + +include hf hS in +lemma repeated_norm (s : letterSpace t S j) (hs : ‖s‖=1) + (x : letterSpace t S i) (hx : ‖x‖=1) (n : ℕ) (v : multiplicityLevel t S j 0) : + ‖t.functional.gnsStarAlgHom ((letterValue t S j s*letterValue t S i x)^n) + (blockEmbedding t S hfree hij 0 v)‖=‖v‖ := by + have hout := repeatedOutput_inserted t S f hf hS hfree hij 1 s hs x n v + simp only [map_one,one_apply_eq_self] at hout + rw [←hout,norm_repeatedOutput_one t S f hf hS hfree hij x hx, + (repeatInsertion t S s hs n).norm_map] + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSequenceUnitary.lean b/lean/OAI/Analysis/Commutator/FreeSequenceUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..d044a8ec1afbcf7a36c612cafc0111552a28a6c2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSequenceUnitary.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.Commutator.ConjugatedFreeness +import OAI.Analysis.Commutator.FreeMoments +import OAI.Analysis.Commutator.NormalSubalgebra +import OAI.Analysis.Commutator.TracialSmallCorners +import OAI.Analysis.Commutator.UnitarySequence +import OAI.Analysis.Commutator.WordScaling + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching FinitePatching.Words FinitePatching.ConjugatedWords + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma sequenceUnitary_free (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (hω : (ω : Filter ℕ)≤atTop) (u : ℕ → unitary A) + (hlim : ∀ (J : Type) (x : J → A),(∀ j,‖x j‖≤1) → (∀ j,τ (x j)=0) → + ∀ l : List (Letter J Bool),l≠[] → Valid l → + Tendsto (fun n => τ (word x signPower (PartialUnitary.ofUnitary (u n)) l)) atTop (𝓝 0)) : + FreeMoments.Free (pair (A := A) (B := boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + ((leftRestricted τ ω).comp constantSequence) (sequenceUnitary τ ω u)) + (sequenceTrace τ ω).toLinearMap := by + apply free_of_centered_unitary_words (A := A) (B := boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + _ _ (leftRestricted τ ω).range (sequenceTrace τ ω).toLinearMap + τ.toLinearMap + · exact ⟨boundedUnitary u,rfl⟩ + · intro a + exact ⟨constantSequence a,rfl⟩ + · rintro _ ⟨a,rfl⟩ _ ⟨b,rfl⟩ + change sequenceTrace τ ω (leftRestricted τ ω a * leftRestricted τ ω b)= + sequenceTrace τ ω (leftRestricted τ ω b * leftRestricted τ ω a) + exact (congrArg (fun T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + sequenceTrace τ ω T) (map_mul (leftRestricted τ ω) a b)).symm.trans + ((trace_mul τ ω hτ a b).trans + (congrArg (fun T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + sequenceTrace τ ω T) (map_mul (leftRestricted τ ω) b a))) + · exact trace_constant τ ω + · intro J x hx l hl hv + apply trace_sequence_word τ ω hω u x signPower l + exact moment_limit_of_contractions τ signPower (fun n => PartialUnitary.ofUnitary (u n)) + (hlim J) x hx l hl hv + +section Relative + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R≤M) + +variable (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +def restrictBoundedUnitary (u : ℕ → unitary M) (hu : ∀ n,((u n:M):H →L[ℂ] H)∈R) : ℕ →ᵇ R := + BoundedContinuousFunction.ofNormedAddCommGroupDiscrete (fun n => ⟨u n,hu n⟩) 1 + (fun n => (PartialUnitary.ofUnitary (u n)).norm_le_one) + +lemma map_restrictBoundedUnitary (u : ℕ → unitary M) (hu : ∀ n,((u n:M):H →L[ℂ] H)∈R) : + mapSequence (NormalSubalgebra.inclusion M R hRM) (restrictBoundedUnitary M R u hu)=boundedUnitary u := by + ext n + rfl + +lemma sequenceUnitary_in_relative_range (u : ℕ → unitary M) + (hu : ∀ n,((u n:M):H →L[ℂ] H)∈R) : + (sequenceUnitary τ ω u : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence (NormalSubalgebra.inclusion M R hRM))) := by + refine ⟨restrictBoundedUnitary M R u hu,?_⟩ + change leftRestricted τ ω (mapSequence _ _)=leftRestricted τ ω (boundedUnitary u) + exact congrArg (leftRestricted τ ω) (map_restrictBoundedUnitary M R hRM u hu) + +lemma constant_in_relative_range (a : M) (ha : (a:H →L[ℂ] H)∈R) : + leftRestricted τ ω (constantSequence a)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence (NormalSubalgebra.inclusion M R hRM))) := by + refine ⟨constantSequence (⟨a,ha⟩ : R),?_⟩ + change leftRestricted τ ω (mapSequence _ _)=leftRestricted τ ω (constantSequence a) + congr 1 + +end Relative + +end Kadison.TracialSequence + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeStageAverage.lean b/lean/OAI/Analysis/Commutator/FreeStageAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..b09e9c6417f8bd329346792c16a91294b3a5c691 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeStageAverage.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeHilbertEntries +import OAI.Analysis.Commutator.FreeSymmetrization + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace MeasureTheory + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + (S : Bool → StarSubalgebra ℂ A) (f : D →⋆ₐ[ℂ] A) (hS : S false=f.range) + (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +lemma baseEmbedding_mem_baseSpace (v : multiplicityLevel t S true 0) : + baseEmbedding t S hfree v∈baseSpace t S true := by + induction v using Completion.induction_on with + | hp => + exact (show IsClosed (baseSpace t S true : Set t.functional.GNS) from isClosed_closure).preimage (baseEmbedding t S hfree).continuous + | ih v => + rw [baseEmbedding_coe] + apply subset_closure + refine ⟨t.functional.gnsStarAlgHom (factorValue t S true v), + ⟨factorValue t S true v,v.property,rfl⟩,?_⟩ + simp only [TracialGNS.vacuum,TracialGNS.left_coe,mul_one] + +lemma baseProjection_comp_embedding : + (baseSpace t S true).starProjection.comp (baseEmbedding t S hfree).toContinuousLinearMap= + (baseEmbedding t S hfree).toContinuousLinearMap := by + ext x + exact (baseSpace t S true).starProjection_eq_self_iff.mpr + (baseEmbedding_mem_baseSpace t S hfree x) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a, φ m (inc h a)=φ n a) + +omit [PartialOrder D] [StarOrderedRing D] [∀ n, Nonempty (I n)] in +include hinc in +theorem free_stage_symmetrization (G : t.functional.GNS →L[ℂ] t.functional.GNS) + (ε : ℝ) (hε : 0≤ε) (β : ℂ) (s : A) (hs : s∈S true) + (hGD : ∀ a : D, G*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*G) + (hC : ∀ x, CornerSymmetrization.CornerElement + (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) β x → ‖G*x-x*G‖≤ε*‖x‖) : + ∃ V : t.functional.GNS →L[ℂ] t.functional.GNS, + ‖V‖≤‖G‖ ∧ + (∀ n u, V*(innerRepresentation t htr f S false hS hfree hgen (TracialGNS.stageUnitary (φ n) u): + t.functional.GNS →L[ℂ] t.functional.GNS)= + (innerRepresentation t htr f S false hS hfree hgen (TracialGNS.stageUnitary (φ n) u): + t.functional.GNS →L[ℂ] t.functional.GNS)*V) ∧ + (∀ a : D, V*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*V) ∧ + (∀ x, CornerSymmetrization.CornerElement + (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) β x → ‖V*x-x*V‖≤ε*‖x‖) ∧ + (ContinuousLinearMap.adjoint (𝕜 := ℂ) (E := multiplicityLevel t S true 0) (F := t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((V*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*V).comp + (baseEmbedding t S hfree).toContinuousLinearMap)= + (ContinuousLinearMap.adjoint (𝕜 := ℂ) (E := multiplicityLevel t S true 0) (F := t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((G*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*G).comp + (baseEmbedding t S hfree).toContinuousLinearMap) := by + obtain ⟨V,hV,hVU,hVD,hVC,_,hVe⟩ := exists_free_symmetrization t htr f S false true hS + hfree hgen I φ inc hinc G hGD ε hε β hC s hs (by decide) + refine ⟨V,hV,hVU,hVD,hVC,?_⟩ + let F := (baseEmbedding t S hfree).toContinuousLinearMap + let F' := ContinuousLinearMap.adjoint (𝕜 := ℂ) (E := multiplicityLevel t S true 0) (F := t.functional.GNS) F + let Q := (baseSpace t S true).starProjection + have hQF : Q.comp F=F := baseProjection_comp_embedding t S hfree + have hFQ : F'.comp Q=F' := by + have hh := congrArg (ContinuousLinearMap.adjoint (𝕜:=ℂ) + (E := multiplicityLevel t S true 0) (F := t.functional.GNS)) hQF + have hQa : Q.adjoint=Q := (isSelfAdjoint_starProjection (baseSpace t S true)).star_eq + simpa only [ContinuousLinearMap.adjoint_comp,hQa] using hh + have hh := congrArg (fun a : t.functional.GNS →L[ℂ] t.functional.GNS => F'.comp (a.comp F)) hVe + change F'.comp ((Q.comp ((V*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*V).comp Q)).comp F)= + F'.comp ((Q.comp ((G*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*G).comp Q)).comp F) at hh + have hc (X : t.functional.GNS →L[ℂ] t.functional.GNS) : + F'.comp ((Q.comp (X.comp Q)).comp F)=F'.comp (X.comp F) := by + calc + _ = (F'.comp Q).comp (X.comp (Q.comp F)) := by + simp only [ContinuousLinearMap.comp_assoc] + _ = _ := by rw [hFQ,hQF] + rw [hc,hc] at hh + exact hh + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeStageHankel.lean b/lean/OAI/Analysis/Commutator/FreeStageHankel.lean new file mode 100644 index 0000000000000000000000000000000000000000..a745fcd134cf3d25eb5d3b0a39f68c36d1df8c22 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeStageHankel.lean @@ -0,0 +1,231 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerSymmetrization +import OAI.Analysis.Commutator.FreeActualStructure +import OAI.Analysis.Commutator.FreeHankelBound +import OAI.Analysis.Commutator.FreePropagationStage + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open UniformSpace + +open scoped InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments DihedralCorner + +lemma compressed_commutator_eq {H E : Type*} [NormedAddCommGroup H] + [InnerProductSpace ℂ H] [CompleteSpace H] [NormedAddCommGroup E] + [InnerProductSpace ℂ E] [CompleteSpace E] + (U : E →L[ℂ] H) (G L : H →L[ℂ] H) (B : E →L[ℂ] E) + (hG : G.comp U=U.comp B) (hG' : G.adjoint.comp U=U.comp B.adjoint) : + U.adjoint.comp ((G*L-L*G).comp U)= + B*(U.adjoint.comp (L.comp U))-(U.adjoint.comp (L.comp U))*B := by + have hl : U.adjoint.comp G=B.comp U.adjoint := by + simpa only [adjoint_comp,adjoint_adjoint] using + congrArg (adjoint (𝕜:=ℂ) (E:=E) (F:=H)) hG' + calc + _ = (U.adjoint.comp G).comp (L.comp U) - + (U.adjoint.comp L).comp (G.comp U) := by + change U.adjoint.comp ((G.comp L-L.comp G).comp U)=_ + simp only [sub_comp,comp_sub,←comp_assoc] + _ = (B.comp U.adjoint).comp (L.comp U) - + (U.adjoint.comp L).comp (U.comp B) := by rw [hl,hG] + _ = _ := by simp only [←comp_assoc]; rfl + +lemma adjoint_commutes_representation {H D : Type*} [NormedAddCommGroup H] + [InnerProductSpace ℂ H] [CompleteSpace H] [CStarAlgebra D] + (π : D →⋆ₐ[ℂ] (H →L[ℂ] H)) (G : H →L[ℂ] H) + (h : ∀ a, G.comp (π a)=(π a).comp G) : + ∀ a, G.adjoint.comp (π a)=(π a).comp G.adjoint := by + intro a + have hh : G*π (star a)=π (star a)*G := h (star a) + have hh' := congrArg star hh + change G.adjoint*π a=π a*G.adjoint + simpa only [star_mul,map_star,star_star,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_adjoint] using hh'.symm + +lemma adjoint_corner_bound {H : Type*} [NormedAddCommGroup H] + [InnerProductSpace ℂ H] [CompleteSpace H] + (M : StarSubalgebra ℂ (H →L[ℂ] H)) (p G : H →L[ℂ] H) + (hp : IsStarProjection p) (ε : ℝ) + (h : ∀ a : H →L[ℂ] H, a∈M → p*a=a → a*p=a → ‖G.comp a-a.comp G‖≤ε*‖a‖) : + ∀ a : H →L[ℂ] H, a∈M → p*a=a → a*p=a → + ‖G.adjoint.comp a-a.comp G.adjoint‖≤ε*‖a‖ := by + intro a ha hl hr + have hl' : p*star a=star a := by + simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star hr + have hr' : star a*p=star a := by + simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star hl + change ‖G.adjoint*a-a*G.adjoint‖≤_ + rw [CornerSymmetrization.commutator_adjoint_norm] + have hh := h (star a) (star_mem ha) hl' hr' + change ‖G*star a-star a*G‖≤ε*‖star a‖ at hh + rw [_root_.norm_star a] at hh + exact hh + +section Base + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) + (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S false=f.range) + (hfree : Free S t.functional.toLinearMap) + +lemma base_block_intertwines + (G : t.functional.GNS →L[ℂ] t.functional.GNS) + (B : ∀ k, multiplicityLevel t S true k →L[ℂ] multiplicityLevel t S true k) + (hb : ∀ k a (x : letterSpace t S false) v, + G (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k (B k v)) + (sl : letterSpace t S true) (sn : ‖sl‖=1) : + G.comp (baseEmbedding t S hfree).toContinuousLinearMap= + (baseEmbedding t S hfree).toContinuousLinearMap.comp (B 0) := by + ext v + change G (baseEmbedding t S hfree v)=baseEmbedding t S hfree (B 0 v) + simpa only [map_one,one_apply_eq_self] using + base_intertwining t S f hf hS hfree Bool.false_ne_true G B hb sl sn 0 1 v + +lemma base_block_compression + (G L : t.functional.GNS →L[ℂ] t.functional.GNS) + (B : ∀ k, multiplicityLevel t S true k →L[ℂ] multiplicityLevel t S true k) + (hb : ∀ k a (x : letterSpace t S false) v, + G (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k (B k v)) + (hb' : ∀ k a (x : letterSpace t S false) v, + G.adjoint (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k ((B k).adjoint v)) + (sl : letterSpace t S true) (sn : ‖sl‖=1) : + (ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) (F:=t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((G*L-L*G).comp (baseEmbedding t S hfree).toContinuousLinearMap)= + B 0*((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) (F:=t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + (L.comp (baseEmbedding t S hfree).toContinuousLinearMap))- + ((ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) (F:=t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + (L.comp (baseEmbedding t S hfree).toContinuousLinearMap))*B 0 := by + have h0 := base_block_intertwines t S f hf hS hfree G B hb sl sn + have h1 := base_block_intertwines t S f hf hS hfree G.adjoint + (fun k => (B k).adjoint) hb' sl sn + exact @compressed_commutator_eq t.functional.GNS (multiplicityLevel t S true 0) + (inferInstanceAs (NormedAddCommGroup t.functional.GNS)) + (inferInstanceAs (InnerProductSpace ℂ t.functional.GNS)) + (inferInstanceAs (CompleteSpace t.functional.GNS)) + (inferInstanceAs (NormedAddCommGroup (multiplicityLevel t S true 0))) + (inferInstanceAs (InnerProductSpace ℂ (multiplicityLevel t S true 0))) + (inferInstanceAs (CompleteSpace (multiplicityLevel t S true 0))) + (baseEmbedding t S hfree).toContinuousLinearMap G L (B 0) h0 h1 + +end Base + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (S : Bool → StarSubalgebra ℂ A) + (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) (hS : S false=f.range) + (hfree : Free S t.functional.toLinearMap) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a, φ m (inc h a)=φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hDgen : ∀ a : D, (factorTrace t f hf).gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra (factorTrace t f hf) I φ : Set _))) + +variable (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + (hGL : ∀ a : D, G.comp (t.functional.gnsStarAlgHom (f a))= + (t.functional.gnsStarAlgHom (f a)).comp G) + (hGW : ∀ n u, G.comp + (innerRepresentation t htr f S false hS hfree hgen (TracialGNS.stageUnitary (φ n) u)).toLinearIsometry.toContinuousLinearMap = + (innerRepresentation t htr f S false hS hfree hgen (TracialGNS.stageUnitary (φ n) u)).toLinearIsometry.toContinuousLinearMap.comp G) + +variable (M : VonNeumannAlgebra t.functional.GNS) (hM : ∀ a : A, t.functional.gnsStarAlgHom a∈M) + +variable (d s : unitary A) (hd : (d:A)∈S false) (hs : (s:A)∈S true) + (hd0 : t.functional (d:A)=0) (hs0 : t.functional (s:A)=0) + (hrot : MulAut.conj d (d*s)=(d*s)⁻¹) + (hd2 : (d:A)*(d:A)=1) (hs2 : (s:A)*(s:A)=1) + +variable {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2:ℂ) • (1+(d:A))) (hpd : p*(d:A)=p) (hdp : (d:A)*p=p) + (hpD : p∈S false) + +include htr hinc hsize hDgen hgen hGL hGW hM hd hs hd0 hs0 hrot hd2 hs2 hpform hpd hdp hpD in +theorem stage_hankel_bound {κ : Type*} [Fintype κ] [DecidableEq κ] + (n : ℕ) (q : Matrix (I n) (I n) ℂ) (hq : IsStarProjection q) + (α : ℝ) (hα : 0<α) (hατ : factorTrace t f hf (φ n q)=(α:ℂ)) + (w : κ → D) + (hcol : ∀ i j, star (w i)*w j=if i=j then φ n q else 0) + (hinit : ∀ i, φ n q*star (w i)=star (w i)) + (htotal : ∑ i, w i*star (w i)=1) + (e0 : D) (e : Corner hp) + (heq : f e0=(e:A)) (heproj : IsStarProjection e) + (he : e∈cornerFactor hp (S false) hpD) + (hr : 0<‖TracialGNS.algebraVector (factorTrace t f hf) e0‖) + (ε : ℝ) (hε : 0≤ε) + (hsmallq : ∀ a : t.functional.GNS →L[ℂ] t.functional.GNS, a∈M → + t.functional.gnsStarAlgHom (f (φ n q))*a=a → + a*t.functional.gnsStarAlgHom (f (φ n q))=a → ‖G.comp a-a.comp G‖≤ε*‖a‖) + (hsmalle : ∀ a : A, (e:A)*a*(e:A)=a → + ‖G*t.functional.gnsStarAlgHom a-t.functional.gnsStarAlgHom a*G‖≤ε*‖a‖) : + ‖(ContinuousLinearMap.adjoint (𝕜 := ℂ) (E := multiplicityLevel t S true 0) (F := t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((G*t.functional.gnsStarAlgHom (s:A)-t.functional.gnsStarAlgHom (s:A)*G).comp + (baseEmbedding t S hfree).toContinuousLinearMap)‖≤1040*ε := by + obtain ⟨B,hBn,hB,hB'⟩ := free_word_structure t htr f hf S false true hS hfree hgen + Bool.false_ne_true (fun b => by cases b <;> simp) I φ inc hinc hsize hDgen G hGL hGW + have hb : ∀ k a (x : letterSpace t S false) v, + G (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k (B k v) := by + intro k a x v + exact hB k _ _ v + have hb' : ∀ k a (x : letterSpace t S false) v, + G.adjoint (repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k v)= + repeatedOutput t S f hf hS hfree Bool.false_ne_true a x k ((B k).adjoint v) := by + intro k a x v + exact hB' k _ _ v + let sl := letterOf t S true (s:A) hs hs0 + have sn : ‖sl‖=1 := norm_letterOf_unitary t S true s hs hs0 + have hg' := adjoint_commutes_representation (t.functional.gnsStarAlgHom.comp f) G hGL + have hpq : IsStarProjection (t.functional.gnsStarAlgHom (f (φ n q))) := + ((hq.map (φ n)).map f).map t.functional.gnsStarAlgHom + have hsmallq' := adjoint_corner_bound M.toStarSubalgebra _ G hpq ε hsmallq + have hprop := propagation_from_stage_all t htr S f hf hS hfree Bool.false_ne_true + I φ inc hinc hsize hDgen hgen G B hb hGL M hM sl sn n q hq α hα hατ w hcol + hinit htotal ε hε hsmallq + have hprop' := propagation_from_stage_all t htr S f hf hS hfree Bool.false_ne_true + I φ inc hinc hsize hDgen hgen G.adjoint (fun k => (B k).adjoint) hb' hg' M hM + sl sn n q hq α hα hατ w hcol hinit htotal ε hε hsmallq' + have hbnd := free_hankel_bound t S hfree f hf hS htr d s hd hs hd0 hs0 hrot hd2 hs2 + hp hpform hpd hdp hpD G B hb hb' e0 e heq heproj he hr 16 ε (by norm_num) hε + hsmalle (by simpa only [show (2:ℝ)*16=32 by norm_num] using hprop) + (by simpa only [show (2:ℝ)*16=32 by norm_num] using hprop') + rw [base_block_compression t S f hf hS hfree G _ B hb hb' sl sn] + change ‖B 0*baseAction t S hfree (s:A)-baseAction t S hfree (s:A)*B 0‖≤1040*ε + simpa only [show (16:ℝ)*(1+4*16)=1040 by norm_num] using hbnd + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetrization.lean b/lean/OAI/Analysis/Commutator/FreeSymmetrization.lean new file mode 100644 index 0000000000000000000000000000000000000000..162fc15fd6075c2eddf63c629e4ea14d21d8d1c8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetrization.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerSymmetrization +import OAI.Analysis.Commutator.FreeNormalizer +import OAI.Analysis.Commutator.MatrixCompactGroup + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Matrix.Norms.L2Operator + +open MeasureTheory MeasureTheory.Measure + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +abbrev factorOperators : StarSubalgebra ℂ (t.functional.GNS →L[ℂ] t.functional.GNS) := + (t.functional.gnsStarAlgHom.comp f).range + +def ambientOperators : StarSubalgebra ℂ (t.functional.GNS →L[ℂ] t.functional.GNS) := + StarSubalgebra.centralizer ℂ ↑(StarSubalgebra.centralizer ℂ (generatedOperators t S : Set (t.functional.GNS →L[ℂ] t.functional.GNS))) + +lemma mem_ambientOperators {a : t.functional.GNS →L[ℂ] t.functional.GNS} : + a∈ambientOperators t S ↔ a ∈ Set.centralizer (Set.centralizer (generatedOperators t S : Set _)) := by + change a ∈ (ambientOperators t S : Set _) ↔ _ + rw [ambientOperators,StarSubalgebra.coe_centralizer_centralizer,StarMemClass.star_coe_eq,Set.union_self] + +lemma innerRepresentation_conj_mem_factor (u : unitary D) + {a : t.functional.GNS →L[ℂ] t.functional.GNS} (ha : a∈factorOperators t f) : + (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv a ∈ factorOperators t f := by + obtain ⟨b,rfl⟩ := ha + change (innerRepresentation t ht f S i hS hfree hgen u).conjStarAlgEquiv + (t.functional.gnsStarAlgHom (f b)) ∈ factorOperators t f + rw [innerRepresentation_conj_generator t ht f S i hS hfree hgen u i (f b) + (by rw [hS]; exact ⟨b,rfl⟩),innerFamily_self] + refine ⟨(u:D)*b*star (u:D),?_⟩ + change t.functional.gnsStarAlgHom (f ((u:D)*b*star (u:D)))=_ + simp only [map_mul,map_star] + +lemma innerRepresentation_commutes_other (hji : j≠i) (u : unitary D) (a : A) (ha : a∈S j) : + (innerRepresentation t ht f S i hS hfree hgen u : t.functional.GNS →L[ℂ] t.functional.GNS)* + t.functional.gnsStarAlgHom a = t.functional.gnsStarAlgHom a* + (innerRepresentation t ht f S i hS hfree hgen u : t.functional.GNS →L[ℂ] t.functional.GNS) := by + let W := innerRepresentation t ht f S i hS hfree hgen u + have h := innerRepresentation_conj_generator t ht f S i hS hfree hgen u j a ha + rw [innerFamily_other f i u hji] at h + ext x + have hh := congrArg (fun T : t.functional.GNS →L[ℂ] t.functional.GNS => T (W x)) h + change W (t.functional.gnsStarAlgHom a (W.symm (W x)))=t.functional.gnsStarAlgHom a (W x) at hh + change W (t.functional.gnsStarAlgHom a x)=t.functional.gnsStarAlgHom a (W x) + simpa only [LinearIsometryEquiv.symm_apply_apply] using hh + +abbrev baseSpace : Submodule ℂ t.functional.GNS := + cyclicSubspace ((S j).map t.functional.gnsStarAlgHom) (TracialGNS.vacuum t.functional) + +lemma innerRepresentation_fixes_base (hji : j≠i) (u : unitary D) + {x : t.functional.GNS} (hx : x∈baseSpace t S j) : + innerRepresentation t ht f S i hS hfree hgen u x=x := by + let W := innerRepresentation t ht f S i hS hfree hgen u + apply closure_minimal (t := {x | W x=x}) ?_ (isClosed_eq W.continuous continuous_id) hx + rintro y ⟨a,⟨b,hb,rfl⟩,rfl⟩ + have h := congrArg (fun T : t.functional.GNS →L[ℂ] t.functional.GNS => + T (TracialGNS.vacuum t.functional)) + (innerRepresentation_commutes_other t ht f S i j hS hfree hgen hji u b hb) + change W (t.functional.gnsStarAlgHom b (TracialGNS.vacuum t.functional))= + t.functional.gnsStarAlgHom b (W (TracialGNS.vacuum t.functional)) at h + rw [innerRepresentation_vacuum t ht f S i hS hfree hgen u] at h + exact h + +lemma innerRepresentation_fixes_baseProjection (hji : j≠i) (u : unitary D) : + (innerRepresentation t ht f S i hS hfree hgen u : t.functional.GNS →L[ℂ] t.functional.GNS)* + (baseSpace t S j).starProjection=(baseSpace t S j).starProjection := by + ext x + exact innerRepresentation_fixes_base t ht f S i j hS hfree hgen hji u + ((baseSpace t S j).starProjection_apply_mem x) + +end Kadison.FreeBlocks + +namespace Kadison.TracialGNS + +variable {D : Type*} [CStarAlgebra D] + +variable {I : Type*} [Fintype I] [DecidableEq I] + +def stageUnitaryHom (φ : Matrix I I ℂ →⋆ₐ[ℂ] D) : unitary (Matrix I I ℂ) →* unitary D where + toFun := stageUnitary φ + map_one' := Subtype.ext (map_one φ) + map_mul' a b := Subtype.ext (map_mul φ (a:Matrix I I ℂ) (b:Matrix I I ℂ)) + +lemma stageUnitaryHom_continuous (φ : Matrix I I ℂ →⋆ₐ[ℂ] D) : Continuous (stageUnitaryHom φ) := by + exact (φ.toLinearMap.continuous_of_finiteDimensional.comp continuous_subtype_val).subtype_mk _ + +end Kadison.TracialGNS + +namespace Kadison.FreeBlocks + +open FreeWordTensor FreeMoments FreeWordAction + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (ht : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + +variable (f : D →⋆ₐ[ℂ] A) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +variable (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + +variable (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + +variable (he : ∀ n m (h : n ≤ m) a, φ m (e h a)=φ n a) + +variable (G : t.functional.GNS →L[ℂ] t.functional.GNS) + +variable (hGL : ∀ a : D, G*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*G) + +variable (ε : ℝ) (hε : 0≤ε) (r : ℂ) + +variable (hC : ∀ x, CornerSymmetrization.CornerElement (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) r x → ‖G*x-x*G‖≤ε*‖x‖) + +variable (s : A) (hs : s∈S j) (hji : j≠i) + +omit [PartialOrder D] [StarOrderedRing D] in +include he hGL hε hC hs hji in +theorem exists_free_symmetrization : ∃ V : t.functional.GNS →L[ℂ] t.functional.GNS, + ‖V‖≤‖G‖ ∧ + (∀ n u, V*(innerRepresentation t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) u) : t.functional.GNS →L[ℂ] t.functional.GNS)= + (innerRepresentation t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) u) : t.functional.GNS →L[ℂ] t.functional.GNS)*V) ∧ + (∀ a : D, V*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*V) ∧ + (∀ x, CornerSymmetrization.CornerElement (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) r x → ‖V*x-x*V‖≤ε*‖x‖) ∧ + (∀ x, CornerSymmetrization.CornerElement (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) r x → ‖V.adjoint*x-x*V.adjoint‖≤ε*‖x‖) ∧ + (baseSpace t S j).starProjection*(V*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*V)* + (baseSpace t S j).starProjection= + (baseSpace t S j).starProjection*(G*t.functional.gnsStarAlgHom s-t.functional.gnsStarAlgHom s*G)* + (baseSpace t S j).starProjection := by + let Γ := fun n : ℕ => ↥(unitary (Matrix (I n) (I n) ℂ)) + let : ∀ n, MeasurableSpace (Γ n) := fun n => borel (Γ n) + let : ∀ n, BorelSpace (Γ n) := fun _ => ⟨rfl⟩ + let U : ∀ n, Γ n →* (t.functional.GNS ≃ₗᵢ[ℂ] t.functional.GNS) := fun n => + (innerRepresentation t ht f S i hS hfree hgen).comp (TracialGNS.stageUnitaryHom (φ n)) + have hU : ∀ n x, Continuous fun g => U n g x := by + intro n x + exact (innerRepresentation_continuous t ht f S i hS hfree hgen x).comp + (TracialGNS.stageUnitaryHom_continuous (φ n)) + have hnest : ∀ n m, n ≤ m → ∀ g : Γ n, ∃ k : Γ m, U m k=U n g := by + intro n m h g + refine ⟨TracialGNS.stageUnitary (e h) g,?_⟩ + apply congrArg (innerRepresentation t ht f S i hS hfree hgen) + exact Subtype.ext (he n m h (g:Matrix (I n) (I n) ℂ)) + obtain ⟨V,hV,hVU,hVF,hVC,hVCs,hVQ⟩ := CornerSymmetrization.exists_symmetrization Γ U hU hnest + (fun n => compactHaarProbability (Γ n)) (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) r + (fun n g => innerRepresentation_vacuum t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) g)) + (fun n g _ ha => innerRepresentation_conj_mem_factor t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) g) ha) + (fun n g _ ha => (mem_ambientOperators t S).mpr + (innerRepresentation_conj_mem_bicommutant t ht f S i hS hfree hgen + (TracialGNS.stageUnitary (φ n) g) ((mem_ambientOperators t S).mp ha))) + G ε hε (fun _ ⟨a,ha⟩ => by subst ha; exact hGL a) hC + (baseSpace t S j).starProjection (t.functional.gnsStarAlgHom s) + (isSelfAdjoint_starProjection _) + (fun n g => innerRepresentation_fixes_baseProjection t ht f S i j hS hfree hgen hji + (TracialGNS.stageUnitary (φ n) g)) + (fun n g => innerRepresentation_commutes_other t ht f S i j hS hfree hgen hji + (TracialGNS.stageUnitary (φ n) g) s hs) + exact ⟨V,hV,hVU,(fun a => hVF _ ⟨a,rfl⟩),hVC,hVCs,hVQ⟩ + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ef4465393c9ab33a1f0b57d1b58b1af228d7658 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.EndpointGNS2 +import OAI.Analysis.Commutator.EndpointRankOne + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +variable {k l : ℕ} + +variable (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +include h1 in +theorem stageCoefficient_cycleCutoff (I : ℕ → Type*) + [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) : + ∃ c : Equiv.Perm (Option (Fin k ⊕ Fin l)) → ℂ, + (∀ n (v : Option (Fin k ⊕ Fin l) → Matrix (I n) (I n) ℂ), + stageCoefficient τ Y (φ n) v = ∑ σ, c σ * SchurWeyl.cycleTrace σ v) ∧ + ∀ σ, 2 * SchurWeyl.cycleCount σ < Fintype.card (Option (Fin k ⊕ Fin l)) + 1 → c σ = 0 := by + classical + obtain ⟨c, hc⟩ := stageCoefficient_expansion τ hτ h1 Y I φ e he hsize hY + refine ⟨c, hc, ?_⟩ + intro σ hσ + let J := Option (Fin k ⊕ Fin l) + choose j hj using fun n => hsize 0 (max n (Fintype.card J)) + have hjJ (n) : Fintype.card J ≤ Fintype.card (I (j n)) := + (le_max_right n (Fintype.card J)).trans (hj n).2 + let b (n) : J ↪ I (j n) := Classical.choice (Function.Embedding.nonempty_of_card_le (hjJ n)) + apply SchurWeyl.endpoint_coefficients_vanish_of_rank_one (fun n => I (j n)) + (none : J) (fun n => b n) (fun n => (b n).injective) + (fun n => stageCoefficient τ Y (φ (j n))) c ‖Y‖ (ContinuousLinearMap.opNorm_nonneg Y) (fun n => hc (j n)) + · intro n ρ + exact stageCoefficient_rank_one τ hτ h1 Y (φ (j n)) hleft (b n) ρ + · intro B + exact ⟨B, (le_max_left B (Fintype.card J)).trans (hj B).2⟩ + · exact hσ + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry10.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry10.lean new file mode 100644 index 0000000000000000000000000000000000000000..bbcbc39d79076e17ee6c04590acaa6a5b12e48dd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry10.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor +import OAI.Analysis.Commutator.TensorCompletion + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor UniformSpace + +open scoped ComplexOrder InnerProductSpace + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +include hf in +def pullbackState : FaithfulState D where + functional := + { toLinearMap := t.functional.toLinearMap.comp f.toLinearMap + monotone' := fun _ _ hab => t.functional.monotone + ((NonUnitalStarRingHom.ofClass f).map_le_map_of_map_star hab) } + normalized := by change t.functional (f 1)=1; simpa using t.normalized + faithful := by + intro a ha + apply hf + rw [map_zero] + apply t.faithful + change t.functional (f (star a*a))=0 at ha + simpa only [map_mul, map_star] using ha + +@[simp] lemma pullbackState_apply (a : D) : + (pullbackState t f hf).functional a = t.functional (f a) := rfl + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) (hS : S i=f.range) + +def factorPreMap : preSpace (pullbackState t f hf) →ₗᵢ[ℂ] factorSpace t S i where + toLinearMap := + { toFun := fun x => ⟨t.functional.toPreGNS (f ((pullbackState t f hf).functional.ofPreGNS x)), by + change f _ ∈ S i + rw [hS] + exact ⟨_,rfl⟩⟩ + map_add' := by intro x y; apply Subtype.ext; simp + map_smul' := by intro c x; apply Subtype.ext; simp } + norm_map' x := by + change ‖t.functional.toPreGNS (f ((pullbackState t f hf).functional.ofPreGNS x))‖ = ‖x‖ + simp only [PositiveLinearMap.preGNS_norm_def, PositiveLinearMap.ofPreGNS_toPreGNS, + pullbackState_apply, map_mul, map_star] + +lemma factorPreMap_surjective : Function.Surjective (factorPreMap t f hf S i hS) := by + intro y + have hy : t.functional.ofPreGNS (y : preSpace t) ∈ f.range := hS ▸ y.property + obtain ⟨x,hx⟩ := hy + refine ⟨(pullbackState t f hf).functional.toPreGNS x, ?_⟩ + apply Subtype.ext + change t.functional.toPreGNS (f x)=(y : preSpace t) + change f x=t.functional.ofPreGNS (y : preSpace t) at hx + rw [hx, PositiveLinearMap.toPreGNS_ofPreGNS] + +def factorPreIso : preSpace (pullbackState t f hf) ≃ₗᵢ[ℂ] factorSpace t S i := + LinearIsometryEquiv.ofSurjective (factorPreMap t f hf S i hS) + (factorPreMap_surjective t f hf S i hS) + +def factorGNSIso : Completion (factorSpace t S i) ≃ₗᵢ[ℂ] + (pullbackState t f hf).functional.GNS := + (HilbertCompletion.congr (factorPreIso t f hf S i hS)).symm + +@[simp] lemma factorGNSIso_coe (a : D) : + factorGNSIso t f hf S i hS + ((⟨t.functional.toPreGNS (f a), by exact (factorPreMap t f hf S i hS + ((pullbackState t f hf).functional.toPreGNS a)).property⟩ : factorSpace t S i) : + Completion (factorSpace t S i)) = + ((pullbackState t f hf).functional.toPreGNS a : (pullbackState t f hf).functional.GNS) := by + apply (HilbertCompletion.congr (factorPreIso t f hf S i hS)).injective + simp only [factorGNSIso, LinearIsometryEquiv.apply_symm_apply, HilbertCompletion.congr_coe] + rfl + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry11.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry11.lean new file mode 100644 index 0000000000000000000000000000000000000000..12a17559194766b5ab8d05b067c7ef16d0a597f4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry11.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.CompletionCentered +import OAI.Analysis.Commutator.FreeSymmetry10 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor UniformSpace + +open scoped ComplexOrder InnerProductSpace + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) (hS : S i=f.range) + +lemma inner_pre_one (x : preSpace (pullbackState t f hf)) : + inner ℂ ((pullbackState t f hf).functional.toPreGNS 1) x = + (pullbackState t f hf).functional ((pullbackState t f hf).functional.ofPreGNS x) := by + simp only [PositiveLinearMap.preGNS_inner_def, PositiveLinearMap.ofPreGNS_toPreGNS, + star_one, one_mul] + +def letterPreMap : + HilbertCompletion.centered ((pullbackState t f hf).functional.toPreGNS 1) →ₗᵢ[ℂ] + letterSpace t S i where + toLinearMap := + { toFun := fun x => ⟨factorPreMap t f hf S i hS (x : preSpace (pullbackState t f hf)), + (factorPreMap t f hf S i hS (x : preSpace (pullbackState t f hf))).property, by + have hx := Submodule.mem_orthogonal_singleton_iff_inner_right.mp x.property + rw [inner_pre_one] at hx + exact hx⟩ + map_add' := by + intro x y + apply Subtype.ext + exact congrArg (fun z : factorSpace t S i => (z : preSpace t)) + ((factorPreMap t f hf S i hS).map_add + (x : preSpace (pullbackState t f hf)) (y : preSpace (pullbackState t f hf))) + map_smul' := by + intro c x + apply Subtype.ext + exact congrArg (fun z : factorSpace t S i => (z : preSpace t)) + ((factorPreMap t f hf S i hS).map_smul c (x : preSpace (pullbackState t f hf))) } + norm_map' x := (factorPreMap t f hf S i hS).norm_map x + +lemma letterPreMap_surjective : Function.Surjective (letterPreMap t f hf S i hS) := by + intro y + obtain ⟨x,hx⟩ := factorPreMap_surjective t f hf S i hS ⟨y,y.property.1⟩ + have hx0 : (pullbackState t f hf).functional ((pullbackState t f hf).functional.ofPreGNS x)=0 := by + have hx' := congrArg (fun z : factorSpace t S i => t.functional (t.functional.ofPreGNS z)) hx + exact hx'.trans y.property.2 + refine ⟨⟨x,?_⟩,?_⟩ + · rwa [Submodule.mem_orthogonal_singleton_iff_inner_right, inner_pre_one] + · apply Subtype.ext + change ((factorPreMap t f hf S i hS) x : preSpace t)=(y : preSpace t) + exact congrArg (fun z : factorSpace t S i => (z : preSpace t)) hx + +def letterPreIso : HilbertCompletion.centered ((pullbackState t f hf).functional.toPreGNS 1) ≃ₗᵢ[ℂ] + letterSpace t S i := + LinearIsometryEquiv.ofSurjective (letterPreMap t f hf S i hS) + (letterPreMap_surjective t f hf S i hS) + +lemma pullback_pre_one_norm : ‖(pullbackState t f hf).functional.toPreGNS 1‖=1 := by + rw [PositiveLinearMap.preGNS_norm_def] + simp [map_one, t.normalized] + +def letterGNSIso : Completion (letterSpace t S i) ≃ₗᵢ[ℂ] + HilbertCompletion.centered + (((pullbackState t f hf).functional.toPreGNS 1 : preSpace (pullbackState t f hf)) : + (pullbackState t f hf).functional.GNS) := + (HilbertCompletion.congr (letterPreIso t f hf S i hS)).symm |>.trans + (HilbertCompletion.centeredEquiv _ (pullback_pre_one_norm t f hf)) + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry12.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry12.lean new file mode 100644 index 0000000000000000000000000000000000000000..2dda85282af1115d3c867a69909a7e6d8faead52 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry12.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor4 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped InnerProductSpace TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} (hfree : Free S t.functional.toLinearMap) (hij : i≠j) + +variable (hcolors : ∀ c : ι, c=i ∨ c=j) + +variable (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +include hcolors hgen in +theorem freeLevelIsHilbertSum : IsHilbertSum ℂ + (fun n => Completion (endpointTensor t S i j n)) (levelEmbedding t S hfree hij) := + IsHilbertSum.mk (levelFamily_orthogonal t S hfree hij) + (le_of_eq (total_levels t S hfree hij hcolors hgen).symm) + +include hfree hij hcolors hgen in +def freeLevelSum : t.functional.GNS ≃ₗᵢ[ℂ] + lp (fun n => Completion (endpointTensor t S i j n)) 2 := + (freeLevelIsHilbertSum t S hfree hij hcolors hgen).linearIsometryEquiv + +@[simp] lemma freeLevelSum_symm_single (n : ℕ) + (x : Completion (endpointTensor t S i j n)) : + (freeLevelSum t S hfree hij hcolors hgen).symm (lp.single 2 n x) = + levelEmbedding t S hfree hij n x := + IsHilbertSum.linearIsometryEquiv_symm_apply_single + (freeLevelIsHilbertSum t S hfree hij hcolors hgen) x + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry13.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry13.lean new file mode 100644 index 0000000000000000000000000000000000000000..39e10c29d37564a0a20e6964044dddda297d1dcd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry13.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry11 +import OAI.Analysis.Commutator.Regroup +import OAI.Analysis.Commutator.TensorPowerCompletion + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor UniformSpace + +open scoped ComplexOrder InnerProductSpace TensorProduct + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i : ι) (hS : S i=f.range) + +abbrev factorFull : PreHilbert := ⟨(pullbackState t f hf).functional.GNS⟩ + +abbrev factorZero : PreHilbert := ⟨HilbertCompletion.centered + (((pullbackState t f hf).functional.toPreGNS 1 : preSpace (pullbackState t f hf)) : + (pullbackState t f hf).functional.GNS)⟩ + +def scalarGNSIso (n : ℕ) : scalarLevel t S i n ≃ₗᵢ[ℂ] + Completion (factorFull t f hf ⊗[ℂ] PreHilbert.power (factorZero t f hf) n) := + HilbertCompletion.wordEquiv (aLetters t S i) (dLetters t S i) + (factorFull t f hf) (factorZero t f hf) + ((factorGNSIso t f hf S i hS).trans HilbertCompletion.completeEquiv) + ((letterGNSIso t f hf S i hS).trans HilbertCompletion.completeEquiv) n + +lemma letterGNSIso_pre (x : HilbertCompletion.centered + ((pullbackState t f hf).functional.toPreGNS 1)) : + (letterGNSIso t f hf S i hS + (letterPreMap t f hf S i hS x : Completion (letterSpace t S i)) : + (pullbackState t f hf).functional.GNS) = + ((x : preSpace (pullbackState t f hf)) : (pullbackState t f hf).functional.GNS) := by + change (HilbertCompletion.centeredMap _ + ((HilbertCompletion.congr (letterPreIso t f hf S i hS)).symm + (letterPreMap t f hf S i hS x : Completion (letterSpace t S i))) : + (pullbackState t f hf).functional.GNS) = _ + have hx : (letterPreMap t f hf S i hS x : Completion (letterSpace t S i)) = + HilbertCompletion.congr (letterPreIso t f hf S i hS) + (x : Completion (HilbertCompletion.centered + ((pullbackState t f hf).functional.toPreGNS 1))) := + (HilbertCompletion.congr_coe (letterPreIso t f hf S i hS) x).symm + rw [hx, LinearIsometryEquiv.symm_apply_apply, HilbertCompletion.centeredMap_coe] + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry14.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry14.lean new file mode 100644 index 0000000000000000000000000000000000000000..043f0d3216bfd0916435dd96ca5cbabedabdec74 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry14.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.Commutator.EndpointGNS +import OAI.Analysis.Commutator.FreeBlockTensor4 +import OAI.Analysis.Commutator.FreeSymmetry13 +import OAI.Analysis.Commutator.TensorMultiplicity + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeWordTensor UniformSpace PreHilbert + +open scoped ComplexOrder InnerProductSpace TensorProduct + +variable {A D : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra D] [PartialOrder D] [StarOrderedRing D] + +variable (t : FaithfulState A) (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (i j : ι) (hS : S i=f.range) + +abbrev factorTrace := (pullbackState t f hf).functional + +abbrev sourceScalar (n : ℕ) := PreHilbert.wordSpace + (factorFull t f hf) (factorZero t f hf) n + +abbrev sourceLevel (n : ℕ) := Completion (sourceScalar t f hf n ⊗[ℂ] multiplicityLevel t S j n) + +lemma scalarGNSIso_pure (n : ℕ) (a : aLetters t S i) (x : Fin n → dLetters t S i) : + scalarGNSIso t f hf S i hS n + ((a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n x) : scalarLevel t S i n) = + PreHilbert.word (factorFull t f hf) (factorZero t f hf) n + (factorGNSIso t f hf S i hS (HilbertCompletion.coeIsometry (aLetters t S i) a)) + (fun k => letterGNSIso t f hf S i hS (HilbertCompletion.coeIsometry (dLetters t S i) (x k))) := by + have result := HilbertCompletion.wordEquiv_pure (aLetters t S i) (dLetters t S i) + (factorFull t f hf) (factorZero t f hf) + ((factorGNSIso t f hf S i hS).trans HilbertCompletion.completeEquiv) + ((letterGNSIso t f hf S i hS).trans HilbertCompletion.completeEquiv) + n a (factorGNSIso t f hf S i hS (HilbertCompletion.coeIsometry (aLetters t S i) a)) + rfl x (fun index => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) (x index))) (fun _ => rfl) + dsimp only [scalarGNSIso, PreHilbert.word, factorFull, factorZero, + TracialGNS.fullSpace, TracialGNS.zeroSpace, TracialGNS.vacuum, factorTrace, + HilbertCompletion.centered, centeredSpace] at result ⊢ + exact result + +def sourceLevelShuffle (n : ℕ) : Completion (endpointTensor t S i j n) ≃ₗᵢ[ℂ] + sourceLevel t f hf S j n := + (levelShuffle t S n).trans (HilbertCompletion.congr + (TensorProduct.congrIsometry (scalarGNSIso t f hf S i hS n) + (.refl ℂ (multiplicityLevel t S j n)))) + +lemma sourceLevelShuffle_word (n : ℕ) (a : aLetters t S i) (x : BlockParams t S i j n) : + sourceLevelShuffle t f hf S i j hS n + (HilbertCompletion.coeIsometry (endpointTensor t S i j n) (a ⊗ₜ[ℂ] blockPure t S n x)) = + HilbertTensor.pair (E := sourceScalar t f hf n) (scalarGNSIso t f hf S i hS n + ((a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x)) : scalarLevel t S i n)) + (paramJ t S n x : multiplicityLevel t S j n) := by + change HilbertCompletion.congr _ (levelShuffle t S n + (HilbertCompletion.coeIsometry (endpointTensor t S i j n) (a ⊗ₜ[ℂ] blockPure t S n x))) = _ + rw [levelShuffle_pure t S n a x, HilbertCompletion.congr_coe] + rfl + +lemma sourceLevelShuffle_pure (n : ℕ) (a : aLetters t S i) (x : BlockParams t S i j n) : + sourceLevelShuffle t f hf S i j hS n + (HilbertCompletion.coeIsometry (endpointTensor t S i j n) (a ⊗ₜ[ℂ] blockPure t S n x)) = + HilbertTensor.pair (E := sourceScalar t f hf n) + (PreHilbert.word (factorFull t f hf) (factorZero t f hf) n + (factorGNSIso t f hf S i hS (HilbertCompletion.coeIsometry (aLetters t S i) a)) + (fun k => letterGNSIso t f hf S i hS + (HilbertCompletion.coeIsometry (dLetters t S i) (paramD t S n x k)))) + (paramJ t S n x : multiplicityLevel t S j n) := by + rw [sourceLevelShuffle_word] + exact congrArg (fun b : sourceScalar t f hf n => + HilbertTensor.pair b (paramJ t S n x : multiplicityLevel t S j n)) + (scalarGNSIso_pure t f hf S i hS n a (fun k => (paramD t S n x k : dLetters t S i))) + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) (hij : i≠j) + +def sourceLevelEmbedding (n : ℕ) : sourceLevel t f hf S j n →ₗᵢ[ℂ] t.functional.GNS := + (levelEmbedding t S hfree hij n).comp + (sourceLevelShuffle t f hf S i j hS n).symm.toLinearIsometry + +lemma sourceLevelEmbedding_shuffle (n : ℕ) (x : Completion (endpointTensor t S i j n)) : + sourceLevelEmbedding t f hf S i j hS hfree hij n + (sourceLevelShuffle t f hf S i j hS n x) = levelEmbedding t S hfree hij n x := by + simp [sourceLevelEmbedding] + +lemma sourceLevelEmbedding_range (n : ℕ) : + LinearMap.range (sourceLevelEmbedding t f hf S i j hS hfree hij n).toLinearMap = + LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap := by + ext y + constructor + · rintro ⟨x,rfl⟩ + exact ⟨(sourceLevelShuffle t f hf S i j hS n).symm x,rfl⟩ + · rintro ⟨x,rfl⟩ + exact ⟨sourceLevelShuffle t f hf S i j hS n x, + sourceLevelEmbedding_shuffle t f hf S i j hS hfree hij n x⟩ + +lemma sourceLevelEmbedding_orthogonal : + OrthogonalFamily ℂ (fun n => sourceLevel t f hf S j n) + (sourceLevelEmbedding t f hf S i j hS hfree hij) := by + intro n m hnm x y + exact levelEmbedding_orthogonal t S hfree hij hnm + ((sourceLevelShuffle t f hf S i j hS n).symm x) + ((sourceLevelShuffle t f hf S i j hS m).symm y) + +variable (hcolors : ∀ c : ι, c=i ∨ c=j) + +variable (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + +include hcolors hgen in +lemma sourceLevelIsHilbertSum : IsHilbertSum ℂ (sourceLevel t f hf S j) + (sourceLevelEmbedding t f hf S i j hS hfree hij) := by + apply IsHilbertSum.mk (sourceLevelEmbedding_orthogonal t f hf S i j hS hfree hij) + have hr : (⨆ n, LinearMap.range (sourceLevelEmbedding t f hf S i j hS hfree hij n).toLinearMap) = + ⨆ n, LinearMap.range (levelEmbedding t S hfree hij n).toLinearMap := by + congr 1 + funext n + exact sourceLevelEmbedding_range t f hf S i j hS hfree hij n + rw [hr] + exact le_of_eq (total_levels t S hfree hij hcolors hgen).symm + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry15.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry15.lean new file mode 100644 index 0000000000000000000000000000000000000000..31db297a63d10de486ebd161ee8e7ca36f0bd605 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry15.lean @@ -0,0 +1,186 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace +open scoped InnerProductSpace ENNReal +open ContinuousLinearMap + +namespace Kadison.ActualHilbertSum + +variable {ι H : Type*} (E : ι → Type*) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [∀ i, NormedAddCommGroup (E i)] [∀ i, InnerProductSpace ℂ (E i)] + [∀ i, CompleteSpace (E i)] + +variable (U : ∀ i, E i →ₗᵢ[ℂ] H) + +abbrev insert (i : ι) := (U i).toContinuousLinearMap + +def project (i : ι) : H →L[ℂ] E i := (insert E U i).adjoint + +def block (T : H →L[ℂ] H) (i j : ι) : E j →L[ℂ] E i := + ((project E U i).comp T).comp (insert E U j) + +@[simp] lemma project_insert (i : ι) : (project E U i).comp (insert E U i) = 1 := by + ext x + apply ext_inner_left ℂ + intro y + simp only [comp_apply, project, adjoint_inner_right, insert, + LinearIsometry.coe_toContinuousLinearMap, LinearIsometry.inner_map_map, + one_apply_eq_self] + +lemma norm_project_le (i : ι) : ‖project E U i‖ ≤ 1 := by + rw [project, adjoint.norm_map] + exact (U i).norm_toContinuousLinearMap_le + +lemma norm_block_le (T : H →L[ℂ] H) (i j : ι) : ‖block E U T i j‖ ≤ ‖T‖ := by + calc + ‖block E U T i j‖ ≤ (‖project E U i‖ * ‖T‖) * ‖insert E U j‖ := + (opNorm_comp_le _ _).trans (mul_le_mul_of_nonneg_right + (opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ (1 * ‖T‖) * 1 := mul_le_mul + (mul_le_mul_of_nonneg_right (norm_project_le E U i) (norm_nonneg T)) + (U j).norm_toContinuousLinearMap_le (norm_nonneg _) + (by simp) + _ = ‖T‖ := by ring + +@[simp] lemma block_adjoint (T : H →L[ℂ] H) (i j : ι) : + block E U T.adjoint i j = (block E U T j i).adjoint := by + simp only [block, project, adjoint_comp, adjoint_adjoint, comp_assoc] + +variable (hU : IsHilbertSum ℂ E U) + +lemma project_coordinates (i : ι) (x : H) : + project E U i x = hU.linearIsometryEquiv x i := by + classical + apply ext_inner_left ℂ + intro y + rw [project, adjoint_inner_right] + change inner ℂ (U i y) x = _ + rw [← hU.linearIsometryEquiv_symm_apply_single y] + have := hU.linearIsometryEquiv.symm.inner_map_map + (lp.single 2 i y) (hU.linearIsometryEquiv x) + simpa only [LinearIsometryEquiv.symm_apply_apply, lp.inner_single_left] using this + +include hU in +lemma ext_vectors {x y : H} (h : ∀ i, project E U i x=project E U i y) : x=y := by + apply hU.linearIsometryEquiv.injective + ext i + simpa only [project_coordinates E U hU] using h i + +include hU in +lemma project_insert_ne {i j : ι} (hij : i≠j) : + (project E U i).comp (insert E U j) = 0 := by + ext x + apply ext_inner_left ℂ + intro y + simp only [comp_apply, project, adjoint_inner_right, insert, + LinearIsometry.coe_toContinuousLinearMap, zero_apply, inner_zero_right] + exact hU.OrthogonalFamily hij y x + +include hU in +lemma reduces_of_offdiagonal (T : H →L[ℂ] H) + (h : ∀ i j, i≠j → block E U T i j=0) (j : ι) : + T.comp (insert E U j)=(insert E U j).comp (block E U T j j) := by + ext x + apply ext_vectors E U hU + intro i + by_cases hij : i=j + · subst i + change block E U T j j x = ((project E U j).comp (insert E U j)) _ + rw [project_insert,one_apply_eq_self] + rfl + · change block E U T i j x = ((project E U i).comp (insert E U j)) _ + rw [h i j hij,project_insert_ne E U hU hij] + rfl + +include hU in +lemma adjoint_reduces_of_offdiagonal (T : H →L[ℂ] H) + (h : ∀ i j, i≠j → block E U T i j=0) (j : ι) : + T.adjoint.comp (insert E U j)=(insert E U j).comp (block E U T j j).adjoint := by + rw [←block_adjoint] + apply reduces_of_offdiagonal E U hU + intro i k hik + rw [block_adjoint,h k i hik.symm,map_zero] + +variable {F : Type*} [NormedAddCommGroup F] [NormedSpace ℂ F] + +omit [∀ i, CompleteSpace (E i)] in +include hU in +lemma map_ext (T R : H →L[ℂ] F) + (h : ∀ i, T.comp (insert E U i)=R.comp (insert E U i)) : T=R := by + classical + have he : T.comp hU.linearIsometryEquiv.symm.toContinuousLinearEquiv.toContinuousLinearMap = + R.comp hU.linearIsometryEquiv.symm.toContinuousLinearEquiv.toContinuousLinearMap := by + apply lp.ext_continuousLinearMap (by norm_num : (2 : ℝ≥0∞) ≠ ⊤) + intro i + ext x + have hi := congrArg (fun K : E i →L[ℂ] F => K x) (h i) + change T (hU.linearIsometryEquiv.symm (lp.single 2 i x)) = + R (hU.linearIsometryEquiv.symm (lp.single 2 i x)) + rw [hU.linearIsometryEquiv_symm_apply_single] + exact hi + ext x + have hx := congrArg (fun K : lp E 2 →L[ℂ] F => K (hU.linearIsometryEquiv x)) he + simpa only [comp_apply, ContinuousLinearEquiv.coe_coe, + LinearIsometryEquiv.coe_toContinuousLinearEquiv, + LinearIsometryEquiv.symm_apply_apply] using hx + +include hU in +lemma project_covariant (L : H →L[ℂ] H) (l : ∀ i, E i →L[ℂ] E i) + (h : ∀ i, L.comp (insert E U i)=(insert E U i).comp (l i)) (i : ι) : + (project E U i).comp L=(l i).comp (project E U i) := by + apply map_ext E U hU + intro j + rw [comp_assoc, h j, ←comp_assoc, comp_assoc (l i)] + by_cases hij : i=j + · subst i + rw [project_insert] + ext x + rfl + · rw [project_insert_ne E U hU hij] + simp + +omit hU in +lemma block_covariant (T L R : H →L[ℂ] H) (l r : ∀ i, E i →L[ℂ] E i) + (h : T.comp L=R.comp T) + (hL : ∀ j, L.comp (insert E U j)=(insert E U j).comp (l j)) + (hR : ∀ i, (project E U i).comp R=(r i).comp (project E U i)) + (i j : ι) : (block E U T i j).comp (l j)=(r i).comp (block E U T i j) := by + simp only [block,comp_assoc] + rw [←hL,←comp_assoc T,h,comp_assoc R,←comp_assoc (project E U i),hR,comp_assoc] + +include hU in +lemma block_covariant_of_insert (T L : H →L[ℂ] H) (l : ∀ i, E i →L[ℂ] E i) + (h : T.comp L=L.comp T) + (hL : ∀ j, L.comp (insert E U j)=(insert E U j).comp (l j)) (i j : ι) : + (block E U T i j).comp (l j)=(l i).comp (block E U T i j) := + block_covariant E U T L L l l h hL (project_covariant E U hU L l hL) i j + +omit hU in +lemma project_covariant_of_adjoint (L : H →L[ℂ] H) (l : ∀ i, E i →L[ℂ] E i) + (h : ∀ i, L.adjoint.comp (insert E U i)=(insert E U i).comp (l i).adjoint) (i : ι) : + (project E U i).comp L=(l i).comp (project E U i) := by + have hi := congrArg ContinuousLinearMap.adjoint (h i) + simpa only [adjoint_comp,adjoint_adjoint,project] using hi + +end Kadison.ActualHilbertSum +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry16.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry16.lean new file mode 100644 index 0000000000000000000000000000000000000000..b3b00abf7e06f1cea6dab3c57365125b24c1df94 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry16.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertDiagonal +import OAI.Analysis.Commutator.InvariantSum + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace +open scoped InnerProductSpace ENNReal +open ContinuousLinearMap +open scoped InnerProductSpace ENNReal +open scoped ComplexOrder InnerProductSpace TensorProduct +open UniformSpace ContinuousLinearMap +open scoped ComplexOrder InnerProductSpace TensorProduct +open UniformSpace ContinuousLinearMap + +namespace Kadison.TracialGNS + +open PreHilbert HilbertTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +variable (J : ℕ → Type*) [∀ k, NormedAddCommGroup (J k)] + [∀ k, InnerProductSpace ℂ (J k)] + +def sumConjugationIso (u : unitary A) (k : ℕ) : sumLevel τ J k →ₗᵢ[ℂ] sumLevel τ J k := + completionIsometry (TensorProduct.mapIsometry (wordConjugation τ hτ u k) LinearIsometry.id) + +lemma sumConjugationIso_pair (u : unitary A) (k : ℕ) + (x : wordSpace (fullSpace τ) (zeroSpace τ) k) (a : J k) : + sumConjugationIso τ hτ J u k (pair x a)=pair (wordConjugation τ hτ u k x) a := by + exact completionIsometry_coe + (TensorProduct.mapIsometry (wordConjugation τ hτ u k) LinearIsometry.id) (x ⊗ₜ[ℂ] a) + +lemma sumConjugationIso_toCLM (u : unitary A) (k : ℕ) : + (sumConjugationIso τ hτ J u k).toContinuousLinearMap=sumConjugation τ hτ J u k := by + apply completion_ext + intro x a + change sumConjugationIso τ hτ J u k (pair x a)= + HilbertTensor.map (wordConjugation τ hτ u k).toContinuousLinearMap 1 (pair x a) + rw [sumConjugationIso_pair,map_pair] + rfl + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (U : ∀ k, sumLevel τ J k →ₗᵢ[ℂ] H) (hU : IsHilbertSum ℂ (sumLevel τ J) U) + +def freeConjugation (u : unitary A) : H →ₗᵢ[ℂ] H := + HilbertDiagonal.onSum (sumLevel τ J) U hU (sumConjugationIso τ hτ J u) + +lemma freeConjugation_comp (u : unitary A) (k : ℕ) : + (freeConjugation τ hτ J U hU u).toContinuousLinearMap.comp (U k).toContinuousLinearMap = + (U k).toContinuousLinearMap.comp (sumConjugation τ hτ J u k) := by + unfold freeConjugation + rw [HilbertDiagonal.onSum_comp, sumConjugationIso_toCLM] + +lemma conjugation_one : conjugation τ hτ 1 = LinearIsometry.id := by + apply LinearIsometry.ext + have h := (algebraVector_dense τ).equalizer (conjugation τ hτ 1).continuous + (LinearIsometry.id (R:=ℂ) (E:=τ.GNS)).continuous (by + funext a + simp only [Function.comp_apply,algebraVector_apply,conjugation_coe,OneMemClass.coe_one, + one_mul,star_one,mul_one,LinearIsometry.id_apply]) + exact congrFun h + +lemma conjugation_mul (u v : unitary A) : + conjugation τ hτ (u*v)=(conjugation τ hτ u).comp (conjugation τ hτ v) := by + apply LinearIsometry.ext + have h := (algebraVector_dense τ).equalizer (conjugation τ hτ (u*v)).continuous + ((conjugation τ hτ u).comp (conjugation τ hτ v)).continuous (by + funext a + change conjugation τ hτ (u*v) (τ.toPreGNS a : τ.GNS)= + conjugation τ hτ u (conjugation τ hτ v (τ.toPreGNS a : τ.GNS)) + simp only [conjugation_coe,Submonoid.coe_mul,star_mul,mul_assoc]) + exact congrFun h + +lemma wordConjugation_one (k : ℕ) : wordConjugation τ hτ 1 k=LinearIsometry.id := by + apply LinearIsometry.toContinuousLinearMap_injective + apply continuousLinearMap_ext_word + intro d x + simp only [LinearIsometry.coe_toContinuousLinearMap,wordConjugation,wordMap_word, + conjugation_one,LinearIsometry.id_apply] + rfl + +lemma wordConjugation_mul (u v : unitary A) (k : ℕ) : + wordConjugation τ hτ (u*v) k=(wordConjugation τ hτ u k).comp + (wordConjugation τ hτ v k) := by + apply LinearIsometry.toContinuousLinearMap_injective + apply continuousLinearMap_ext_word + intro d x + simp only [LinearIsometry.coe_toContinuousLinearMap,LinearIsometry.coe_comp, + Function.comp_apply,wordConjugation,wordMap_word,conjugation_mul] + rfl + +lemma sumConjugationIso_one (k : ℕ) : sumConjugationIso τ hτ J 1 k=LinearIsometry.id := by + apply LinearIsometry.toContinuousLinearMap_injective + apply HilbertTensor.completion_ext + intro a b + change sumConjugationIso τ hτ J 1 k (pair a b)=pair a b + rw [sumConjugationIso_pair,wordConjugation_one,LinearIsometry.id_apply] + +lemma sumConjugationIso_mul (u v : unitary A) (k : ℕ) : + sumConjugationIso τ hτ J (u*v) k=(sumConjugationIso τ hτ J u k).comp + (sumConjugationIso τ hτ J v k) := by + apply LinearIsometry.toContinuousLinearMap_injective + apply HilbertTensor.completion_ext + intro a b + change sumConjugationIso τ hτ J (u*v) k (pair a b)= + sumConjugationIso τ hτ J u k (sumConjugationIso τ hτ J v k (pair a b)) + rw [sumConjugationIso_pair,sumConjugationIso_pair,sumConjugationIso_pair,wordConjugation_mul] + rfl + +lemma freeConjugation_one : freeConjugation τ hτ J U hU 1=LinearIsometry.id := by + unfold freeConjugation + have h : sumConjugationIso τ hτ J 1=fun _ => LinearIsometry.id := + funext (sumConjugationIso_one τ hτ J) + rw [h] + exact HilbertDiagonal.onSum_one (sumLevel τ J) U hU + +lemma freeConjugation_mul (u v : unitary A) : + freeConjugation τ hτ J U hU (u*v)=(freeConjugation τ hτ J U hU u).comp + (freeConjugation τ hτ J U hU v) := by + unfold freeConjugation + rw [HilbertDiagonal.onSum_mul] + congr 1 + funext k + exact sumConjugationIso_mul τ hτ J u v k + +lemma freeConjugation_star_left (u : unitary A) : + (freeConjugation τ hτ J U hU (star u)).comp (freeConjugation τ hτ J U hU u)=LinearIsometry.id := by + rw [←freeConjugation_mul,Unitary.star_mul_self,freeConjugation_one] + +lemma freeConjugation_surjective (u : unitary A) : + Function.Surjective (freeConjugation τ hτ J U hU u) := by + intro x + refine ⟨freeConjugation τ hτ J U hU (star u) x,?_⟩ + have h := congrArg (fun V : H →ₗᵢ[ℂ] H => V x) + (freeConjugation_star_left τ hτ J U hU (star u)) + change freeConjugation τ hτ J U hU (star (star u)) + (freeConjugation τ hτ J U hU (star u) x)=x at h + simpa only [star_star] using h + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry2.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry2.lean new file mode 100644 index 0000000000000000000000000000000000000000..4c43cdfee2a4324896fe3a870d4c765db3c016c9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry2.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclePairTrace3 +import OAI.Analysis.Commutator.EndpointGNS +import OAI.Analysis.Commutator.FinitePairings3 +import OAI.Analysis.Commutator.HermitianAlphabet +import OAI.Analysis.Commutator.HermitianAlphabet2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +variable {k l : ℕ} (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +lemma stage_pairing_expansion (d : Equiv.Perm (Option (TailSlots k l)) → ℂ) + (hd : ∀ σ, 2 * SchurWeyl.cycleCount σ < Fintype.card (Option (TailSlots k l)) + 1 → d σ = 0) + (hexp : ∀ v : Option (TailSlots k l) → Matrix I I ℂ, + stageCoefficient τ Y φ v = ∑ σ, d σ * SchurWeyl.cycleTrace σ v) + (v : TailSlots k l → Matrix I I ℂ) (hv : ∀ j, Matrix.trace (v j) = 0) : + stageCoefficient τ Y φ (fun o => o.elim (1 : Matrix I I ℂ) v) = + ∑ σ : Pairing (TailSlots k l), d (SchurWeyl.endpointPairingPerm σ) * + Pairing.contraction σ (fun X Z => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Z)) v := by + have hh := SchurWeyl.centered_expansion_contractions d hd + (fun o : Option (TailSlots k l) => o.elim (1 : Matrix I I ℂ) v) (fun j => hv j) + have hm : (Fintype.card I : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr Fintype.card_ne_zero + simp only [Option.elim_none, Option.elim_some, Matrix.trace_one, + inv_mul_cancel₀ hm, one_mul] at hh + exact (hexp (fun o : Option (TailSlots k l) => o.elim (1 : Matrix I I ℂ) v)).trans hh + +omit [Nonempty I] in +lemma stage_alphabet_coefficient {J : Type*} [DecidableEq J] + (c : Pairing (TailSlots k l) → ℂ) + (hexp : ∀ v : TailSlots k l → Matrix I I ℂ, (∀ j, Matrix.trace (v j) = 0) → + stageCoefficient τ Y φ (fun o => o.elim (1 : Matrix I I ℂ) v) = + ∑ σ, c σ * Pairing.contraction σ + (fun X Z => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Z)) v) + (a : J → Matrix I I ℂ) (ha : ∀ j, star (a j) = a j) + (hat : ∀ j, Matrix.trace (a j) = 0) + (hai : ∀ i j, (Fintype.card I : ℂ)⁻¹ * Matrix.trace (a i * a j) = + if i = j then 1 else 0) (v : TailSlots k l → J) : + inner ℂ (word (fullSpace τ) (zeroSpace τ) l (vacuum τ) + (fun j => centeredStageVector τ φ (a (v (.inr j))))) + (Y (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) + (fun i => centeredStageVector τ φ (a (v (.inl i)))))) = + ∑ σ, c σ * Pairing.contraction σ (fun i j => if i = j then 1 else 0) v := by + have hh := hexp (fun j => a (v j)) (fun j => hat (v j)) + change coefficient (fullSpace τ) (zeroSpace τ) k l Y (vacuum τ) + (stageVector τ φ) (centeredStageVector τ φ) + (fun o : Option (Fin k ⊕ Fin l) => o.elim (1 : Matrix I I ℂ) (fun j => a (v j))) = + ∑ σ, c σ * Pairing.contraction σ + (fun X Z => (Fintype.card I : ℂ)⁻¹ * Matrix.trace (X * Z)) (fun j => a (v j)) at hh + dsimp only [coefficient, Option.elim_none, Option.elim_some] at hh + simp only [star_one, stage_vacuum, ha] at hh + rw [hh] + apply Finset.sum_congr rfl + intro σ _ + congr 1 + simp only [Pairing.contraction, hai] + +include hτ h1 in +theorem stage_pairing_same_side_zero (Is : ℕ → Type*) + [∀ n, Fintype (Is n)] [∀ n, DecidableEq (Is n)] [∀ n, Nonempty (Is n)] + (φs : ∀ n, Matrix (Is n) (Is n) ℂ →⋆ₐ[ℂ] A) + (hsize : ∀ q : ℕ, ∃ n, q ≤ Fintype.card (Is n)) + (c : Pairing (TailSlots k l) → ℂ) + (hexp : ∀ n (v : TailSlots k l → Matrix (Is n) (Is n) ℂ), + (∀ j, Matrix.trace (v j) = 0) → + stageCoefficient τ Y (φs n) (fun o => o.elim (1 : Matrix (Is n) (Is n) ℂ) v) = + ∑ σ, c σ * Pairing.contraction σ + (fun X Z => (Fintype.card (Is n) : ℂ)⁻¹ * Matrix.trace (X * Z)) v) + (σ : Pairing (TailSlots k l)) + (hsame : (∃ a b : Fin k, σ (.inl a) = .inl b) ∨ + (∃ a b : Fin l, σ (.inr a) = .inr b)) : c σ = 0 := by + classical + have hbound (N : ℕ) : (N+1 : ℝ) * ‖c σ‖ ^ 2 ≤ ‖Y‖ ^ 2 := by + let J := TailSlots k l × Fin (N+1) + obtain ⟨n, hn⟩ := hsize (Fintype.card (Option J)) + let b : Option J ↪ Is n := Classical.choice (Function.Embedding.nonempty_of_card_le hn) + let bt : J ↪ Is n := ⟨fun j => b (some j), fun x y h => Option.some.inj (b.injective h)⟩ + have hb (j : J) : bt j ≠ b none := by + intro h + exact Option.some_ne_none j (b.injective h) + let a : J → Matrix (Is n) (Is n) ℂ := fun j => MatrixAlphabet.normalizedLetter (b none) (bt j) + let h : J → zeroSpace τ := fun j => centeredStageVector τ (φs n) (a j) + have horth : Orthonormal ℂ h := normalizedLetter_orthonormal τ hτ h1 (φs n) (b none) bt hb + have ha (j) : star (a j) = a j := MatrixAlphabet.star_normalizedLetter _ _ + have hat (j) : Matrix.trace (a j) = 0 := MatrixAlphabet.trace_normalizedLetter _ _ (hb j) + have hai (i j) : (Fintype.card (Is n) : ℂ)⁻¹ * Matrix.trace (a i * a j) = + if i = j then 1 else 0 := by + rw [MatrixAlphabet.normalized_trace_mul _ _ _ (hb i) (hb j)] + simp only [EmbeddingLike.apply_eq_iff_eq] + have he (v : TailSlots k l → J) := + stage_alphabet_coefficient τ Y (φs n) c (hexp n) a ha hat hai v + rcases hsame with ⟨i, j, hij⟩ | ⟨i, j, hij⟩ + · exact finite_pairing_source_bound (fullSpace τ) (zeroSpace τ) k l N + (vacuum τ) (vacuum_norm τ h1) Y c h horth he σ i j hij + · exact finite_pairing_test_bound (fullSpace τ) (zeroSpace τ) k l N + (vacuum τ) (vacuum_norm τ h1) Y c h horth he σ i j hij + by_contra hc + have hz : 0 < ‖c σ‖ ^ 2 := sq_pos_of_pos (norm_pos_iff.mpr hc) + obtain ⟨N, hN⟩ := exists_nat_gt (‖Y‖ ^ 2 / ‖c σ‖ ^ 2) + have hgt : ‖Y‖ ^ 2 < (N : ℝ) * ‖c σ‖ ^ 2 := (div_lt_iff₀ hz).mp hN + have hh := hbound N + nlinarith + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry3.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry3.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2acb90729204e1ca263f35e9512187c28b0603b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry3.lean @@ -0,0 +1,46 @@ +import Mathlib +import OAI.Analysis.Commutator.CrossingPairings + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.Pairing + +lemma not_crosses_iff_same_side {k l : ℕ} (σ : Pairing (TailSlots k l)) : + ¬ Crosses σ ↔ (∃ a b : Fin k, σ (.inl a) = .inl b) ∨ + (∃ a b : Fin l, σ (.inr a) = .inr b) := by + constructor + · intro hn + by_contra h + apply hn + constructor + · intro a + cases he : σ (.inl a) with + | inl b => exact (h (Or.inl ⟨a, b, he⟩)).elim + | inr b => exact ⟨b, rfl⟩ + · intro a + cases he : σ (.inr a) with + | inl b => exact ⟨b, rfl⟩ + | inr b => exact (h (Or.inr ⟨a, b, he⟩)).elim + · rintro (⟨a, b, he⟩ | ⟨a, b, he⟩) hc + · obtain ⟨j, hj⟩ := hc.1 a + rw [he] at hj + cases hj + · obtain ⟨j, hj⟩ := hc.2 a + rw [he] at hj + cases hj + +end Kadison.Pairing +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry4.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry4.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd7d3fbb88986c8a39a14be6183c0e0f566605cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry4.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry +import OAI.Analysis.Commutator.FreeSymmetry2 +import OAI.Analysis.Commutator.FreeSymmetry3 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +variable {k l : ℕ} (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +include h1 in +theorem stageCoefficient_crossing (I : ℕ → Type*) + [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) : + ∃ c : (Fin k ≃ Fin l) → ℂ, ∀ n (a : Matrix (I n) (I n) ℂ) + (v : TailSlots k l → Matrix (I n) (I n) ℂ), (∀ j, Matrix.trace (v j) = 0) → + stageCoefficient τ Y (φ n) (fun o => o.elim a v) = + ((Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace a) * + ∑ b : Fin k ≃ Fin l, c b * ∏ i, + ((Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace (v (.inl i) * v (.inr (b i)))) := by + classical + obtain ⟨d₀, hexp₀, hd₀⟩ := stageCoefficient_cycleCutoff τ hτ h1 Y I φ e he hsize hY hleft + let d : Equiv.Perm (Option (TailSlots k l)) → ℂ := d₀ + have hexp (n) (v : Option (TailSlots k l) → Matrix (I n) (I n) ℂ) : + stageCoefficient τ Y (φ n) v = ∑ σ, d σ * SchurWeyl.cycleTrace σ v := hexp₀ n v + have hd (σ : Equiv.Perm (Option (TailSlots k l))) + (hσ : 2 * SchurWeyl.cycleCount σ < Fintype.card (Option (TailSlots k l)) + 1) : + d σ = 0 := hd₀ σ hσ + let c : Pairing (TailSlots k l) → ℂ := fun σ => d (SchurWeyl.endpointPairingPerm σ) + have hc (n) (v : TailSlots k l → Matrix (I n) (I n) ℂ) (hv : ∀ j, (v j).trace = 0) : + stageCoefficient τ Y (φ n) (fun o => o.elim (1 : Matrix (I n) (I n) ℂ) v) = + ∑ σ, c σ * Pairing.contraction σ + (fun X Z => (Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace (X * Z)) v := + stage_pairing_expansion τ Y (φ n) d hd (hexp n) v hv + have hz (σ : Pairing (TailSlots k l)) (hσ : ¬ σ.Crosses) : c σ = 0 := + stage_pairing_same_side_zero τ hτ h1 Y I φ + (fun q => let ⟨m, hm⟩ := hsize 0 q; ⟨m, hm.2⟩) c hc σ + ((Pairing.not_crosses_iff_same_side σ).mp hσ) + refine ⟨fun b => c (Pairing.crossPairing b), ?_⟩ + intro n a v hv + have hh := SchurWeyl.centered_expansion_contractions d hd + (fun o : Option (TailSlots k l) => o.elim a v) (fun j => hv j) + have hs := Pairing.sum_contraction_crossing + (fun X Z : Matrix (I n) (I n) ℂ => (Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace (X * Z)) v c hz + have hh' : (∑ σ, d σ * SchurWeyl.cycleTrace σ (fun o : Option (TailSlots k l) => o.elim a v)) = + ((Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace a) * + ∑ σ, c σ * Pairing.contraction σ + (fun X Z => (Fintype.card (I n) : ℂ)⁻¹ * Matrix.trace (X * Z)) v := hh + rw [hs] at hh' + exact (hexp n (fun o : Option (TailSlots k l) => o.elim a v)).trans hh' + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry5.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry5.lean new file mode 100644 index 0000000000000000000000000000000000000000..9792107f9ea2257ff58897069775ea78a1823607 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry5.lean @@ -0,0 +1,48 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorDevelopment + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.HilbertTensor + +open UniformSpace + +open scoped TensorProduct + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +lemma inner_map_left_adjoint (a b : E →L[ℂ] E) + (hab : ∀ x y, inner ℂ (a x) y = inner ℂ x (b y)) + (x y : Completion (E ⊗[ℂ] F)) : + inner ℂ (map a (1 : F →L[ℂ] F) x) y = + inner ℂ x (map b (1 : F →L[ℂ] F) y) := by + induction x, y using Completion.induction_on₂ with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x y => + induction x using TensorProduct.inductionOn with + | add x x' hx hx' => + simp only [Completion.coe_add, map_add, inner_add_left, hx, hx'] + | tmul x v => + induction y using TensorProduct.inductionOn with + | add y y' hy hy' => + simp only [Completion.coe_add, map_add, inner_add_right, hy, hy'] + | tmul y w => + simp only [map_coe_tmul, one_apply_eq_self, Completion.inner_coe, + TensorProduct.inner_tmul, hab] + +end Kadison.HilbertTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry6.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry6.lean new file mode 100644 index 0000000000000000000000000000000000000000..aea020c1e39d6ea10754ca96441c2434c014f4a1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry6.lean @@ -0,0 +1,159 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry4 +import OAI.Analysis.Commutator.FreeSymmetry5 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert UniformSpace + +open scoped TensorProduct + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +lemma wordLeft_inner (a : A) (n : ℕ) + (x y : wordSpace (fullSpace τ) (zeroSpace τ) n) : + inner ℂ (wordLeft τ a n x) y = inner ℂ x (wordLeft τ (star a) n y) := by + apply HilbertTensor.inner_map_left_adjoint + intro x y + rw [map_star, ContinuousLinearMap.star_eq_adjoint] + exact (ContinuousLinearMap.adjoint_inner_right (τ.gnsStarAlgHom a) x y).symm + +lemma wordLeft_word (a d : A) (n : ℕ) (x : Fin n → zeroSpace τ) : + wordLeft τ a n (word (fullSpace τ) (zeroSpace τ) n (algebraVector τ d) x) = + word (fullSpace τ) (zeroSpace τ) n (algebraVector τ (a*d)) x := by + simp only [wordLeft, word, HilbertTensor.map_coe_tmul, one_apply_eq_self, + algebraVector_apply, left_coe] + +variable {k l : ℕ} + +variable (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +lemma word_inner_move_endpoint + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) + (d c : A) (x : Fin k → zeroSpace τ) (y : Fin l → zeroSpace τ) : + inner ℂ (word (fullSpace τ) (zeroSpace τ) l (algebraVector τ c) y) + (Y (word (fullSpace τ) (zeroSpace τ) k (algebraVector τ d) x)) = + inner ℂ (word (fullSpace τ) (zeroSpace τ) l (algebraVector τ (star d * c)) y) + (Y (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x)) := by + have hd : word (fullSpace τ) (zeroSpace τ) k (algebraVector τ d) x = + wordLeft τ d k (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x) := by + have hv : algebraVector τ (1 : A) = vacuum τ := rfl + simpa only [mul_one, hv] using (wordLeft_word τ d 1 k x).symm + have hy : Y (wordLeft τ d k (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x)) = + wordLeft τ d l (Y (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x)) := + congrArg (fun T : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l => + T (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x)) (hleft d) + have hm := wordLeft_inner τ (star d) l + (word (fullSpace τ) (zeroSpace τ) l (algebraVector τ c) y) + (Y (word (fullSpace τ) (zeroSpace τ) k (vacuum τ) x)) + rw [wordLeft_word, star_star] at hm + rw [hd, hy] + exact hm.symm + +omit [Nonempty I] in +lemma word_inner_stageCoefficient (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) + (d c : Matrix I I ℂ) (x : Fin k → Matrix I I ℂ) (y : Fin l → Matrix I I ℂ) : + inner ℂ (word (fullSpace τ) (zeroSpace τ) l (stageVector τ φ c) + (fun j => centeredStageVector τ φ (y j))) + (Y (word (fullSpace τ) (zeroSpace τ) k (stageVector τ φ d) + (fun i => centeredStageVector τ φ (x i)))) = + stageCoefficient τ Y φ (fun o : Option (Fin k ⊕ Fin l) => + o.elim (star c * d) (Sum.elim x (fun j => star (y j)))) := by + have h := word_inner_move_endpoint τ Y hleft (φ d) (φ c) + (fun i => centeredStageVector τ φ (x i)) (fun j => centeredStageVector τ φ (y j)) + simp only [stageCoefficient, coefficientMultilinear, MultilinearMap.coe_mk] + simp only [coefficient, Option.elim_none, Option.elim_some, Sum.elim_inl, + Sum.elim_inr, star_mul, star_star] + have ha : stageVector τ φ (star d * c) = algebraVector τ (star (φ d) * φ c) := by + change algebraVector τ (φ (star d * c)) = _ + rw [map_mul, map_star] + rw [ha] + exact h + +include hτ h1 in +lemma centeredStageVector_of_trace_zero (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (a : Matrix I I ℂ) (ha : a.trace = 0) : + (centeredStageVector τ φ a : τ.GNS) = stageVector τ φ a := by + rw [stage_centered τ hτ h1, ha, mul_zero, zero_smul, sub_zero] + +include hτ h1 in +lemma centeredStageVector_inner (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (a b : Matrix I I ℂ) (ha : a.trace = 0) (hb : b.trace = 0) : + inner ℂ (centeredStageVector τ φ a) (centeredStageVector τ φ b) = + (Fintype.card I : ℂ)⁻¹ * Matrix.trace (b * star a) := by + change inner ℂ (centeredStageVector τ φ a : τ.GNS) + (centeredStageVector τ φ b : τ.GNS) = _ + rw [centeredStageVector_of_trace_zero τ hτ h1 φ a ha, + centeredStageVector_of_trace_zero τ hτ h1 φ b hb, stage_inner τ hτ h1] + rw [Matrix.trace_mul_comm] + +include hτ h1 in +theorem stageWord_inner_classification (I : ℕ → Type*) + [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) : + ∃ c₀ : (Fin k ≃ Fin l) → ℂ, ∀ n (d c : Matrix (I n) (I n) ℂ) + (x : Fin k → Matrix (I n) (I n) ℂ) (y : Fin l → Matrix (I n) (I n) ℂ), + (∀ i, Matrix.trace (x i) = 0) → (∀ j, Matrix.trace (y j) = 0) → + inner ℂ (word (fullSpace τ) (zeroSpace τ) l (stageVector τ (φ n) c) + (fun j => centeredStageVector τ (φ n) (y j))) + (Y (word (fullSpace τ) (zeroSpace τ) k (stageVector τ (φ n) d) + (fun i => centeredStageVector τ (φ n) (x i)))) = + inner ℂ (stageVector τ (φ n) c) (stageVector τ (φ n) d) * + ∑ b : Fin k ≃ Fin l, c₀ b * ∏ i, + inner ℂ (centeredStageVector τ (φ n) (y (b i))) + (centeredStageVector τ (φ n) (x i)) := by + classical + obtain ⟨c₀, hc₀⟩ := stageCoefficient_crossing τ hτ h1 Y I φ e he hsize hY hleft + refine ⟨c₀, ?_⟩ + intro n d c x y hx hy + rw [word_inner_stageCoefficient τ Y (φ n) hleft] + let v : TailSlots k l → Matrix (I n) (I n) ℂ := Sum.elim x (fun j => star (y j)) + have hv (j : TailSlots k l) : (v j).trace = 0 := by + cases j with + | inl i => exact hx i + | inr j => simp only [v, Sum.elim_inr, Matrix.star_eq_conjTranspose, + Matrix.trace_conjTranspose, hy j, star_zero] + have h := hc₀ n (star c * d) v hv + change stageCoefficient τ Y (φ n) + (fun o : Option (TailSlots k l) => o.elim (star c * d) v) = _ + refine h.trans ?_ + rw [stage_inner τ hτ h1] + congr 1 + apply Finset.sum_congr rfl + intro b _ + congr 1 + apply Finset.prod_congr rfl + intro i _ + exact (centeredStageVector_inner τ hτ h1 (φ n) (y (b i)) (x i) (hy _) (hx _)).symm + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry7.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry7.lean new file mode 100644 index 0000000000000000000000000000000000000000..efeac26f2878fc3337ebc9d9d72d7467b59a6bc6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry7.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry6 +import OAI.Analysis.Commutator.StageDensity +import OAI.Analysis.Commutator.WordPermutations +import OAI.Analysis.Commutator.WordTopology3 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) (h1 : τ 1 = 1) + +variable {k l : ℕ} + +include h1 in +theorem word_intertwiner (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hd : Dense (⋃ n, stageSet τ I φ n)) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) : + ∃ c₀ : (Fin k ≃ Fin l) → ℂ, + Y = ∑ b : Fin k ≃ Fin l, c₀ b • + (wordReindex (fullSpace τ) (zeroSpace τ) b).toContinuousLinearMap := by + classical + obtain ⟨c₀, hc₀⟩ := stageWord_inner_classification τ hτ h1 Y I φ e he hsize hY hleft + refine ⟨c₀, ?_⟩ + apply operator_ext_dense_stages (fullSpace τ) (zeroSpace τ) k l + (stageSet τ I φ) (centeredStageSet τ I φ) + (stageSet_mono τ I φ e he) (centeredStageSet_mono τ I φ e he) + hd (dense_centeredStageSet τ I φ hd) + intro n d hd x hx c hc y hy + obtain ⟨d, rfl⟩ := hd + obtain ⟨c, rfl⟩ := hc + choose a ha hax using hx + choose b hb hby using hy + have hxa : x = fun i => centeredStageVector τ (φ n) (a i) := funext (fun i => (hax i).symm) + have hyb : y = fun i => centeredStageVector τ (φ n) (b i) := funext (fun i => (hby i).symm) + rw [hxa, hyb, hc₀ n d c a b ha hb] + simp only [sum_apply, smul_apply, + inner_sum, inner_smul_right, LinearIsometry.coe_toContinuousLinearMap, wordReindex_inner] + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro z _ + ring + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry8.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry8.lean new file mode 100644 index 0000000000000000000000000000000000000000..74f1b5e8042d31968db927aa2e71db3c1fa5a728 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry8.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry7 +import OAI.Analysis.Commutator.TensorMultiplicity2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert HilbertTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) (h1 : τ 1 = 1) + +variable {k l : ℕ} {J K : Type*} + [NormedAddCommGroup J] [InnerProductSpace ℂ J] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] + +include h1 in +theorem word_multiplicity_slices + (T : Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J) →L[ℂ] + Completion (wordSpace (fullSpace τ) (zeroSpace τ) l ⊗[ℂ] K)) + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hd : Dense (⋃ n, stageSet τ I φ n)) + (hT : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + T.comp (HilbertTensor.map (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap 1) = + (HilbertTensor.map (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap 1).comp T) + (hleft : ∀ a : A, T.comp (HilbertTensor.map (wordLeft τ a k) 1) = + (HilbertTensor.map (wordLeft τ a l) 1).comp T) : + ∀ a : J, ∀ b : K, ∃ c : (Fin k ≃ Fin l) → ℂ, + scalarSlice T a b = ∑ σ, c σ • + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap := by + intro a b + apply word_intertwiner τ hτ h1 (scalarSlice T a b) I φ e he hsize hd + · intro n u + exact scalarSlice_covariant T _ _ (hT n u) a b + · intro x + exact scalarSlice_covariant T _ _ (hleft x) a b + +theorem word_multiplicity_offlevel + (T : Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J) →L[ℂ] + Completion (wordSpace (fullSpace τ) (zeroSpace τ) l ⊗[ℂ] K)) + (hkl : k ≠ l) + (hclass : ∀ a : J, ∀ b : K, ∃ c : (Fin k ≃ Fin l) → ℂ, + scalarSlice T a b = ∑ σ, c σ • + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap) : T = 0 := by + classical + let : IsEmpty (Fin k ≃ Fin l) := ⟨fun b => hkl (by simpa using Fintype.card_congr b)⟩ + apply eq_zero_of_scalarSlice + intro a b + obtain ⟨c, hc⟩ := hclass a b + simpa only [Finset.univ_eq_empty, Finset.sum_empty] using hc + +include h1 in +theorem word_multiplicity_repeated [CompleteSpace J] + (T : Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J) →L[ℂ] + Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J)) + (hclass : ∀ a b : J, ∃ c : Equiv.Perm (Fin k) → ℂ, + scalarSlice T a b = ∑ σ, c σ • + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap) + (z : zeroSpace τ) (hz : ‖z‖ = 1) : + ∃ B : J →L[ℂ] J, ‖B‖ ≤ ‖T‖ ∧ + ∀ (d : fullSpace τ) (x : zeroSpace τ) (a : J), + T (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a) = + pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) (B a) := by + let v := word (fullSpace τ) (zeroSpace τ) k (vacuum τ) (fun _ => z) + have hv : ‖v‖ = 1 := by + simp only [v, norm_word, vacuum_norm τ h1, hz, Finset.prod_const_one, mul_one] + refine ⟨multiplicityCompression T v, norm_multiplicityCompression_le T v hv, ?_⟩ + intro d x a + apply repeated_pair T (fun σ : Equiv.Perm (Fin k) => + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap) hclass v _ hv + · intro σ + simp only [v, LinearIsometry.coe_toContinuousLinearMap, wordReindex_word, Function.comp_def] + · intro σ + simp only [LinearIsometry.coe_toContinuousLinearMap, wordReindex_word, Function.comp_def] + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeSymmetry9.lean b/lean/OAI/Analysis/Commutator/FreeSymmetry9.lean new file mode 100644 index 0000000000000000000000000000000000000000..199cf3c3623782a819cbee3ec67166a2f6e059fb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeSymmetry9.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry7 +import OAI.Analysis.Commutator.StageGeneration +import OAI.Analysis.Commutator.TensorAdjoints + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open PreHilbert HilbertTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) (h1 : τ 1 = 1) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + +include hτ h1 φ in +lemma exists_unit_centered_letter (hsize : ∃ n, 2 ≤ Fintype.card (I n)) : + ∃ z : zeroSpace τ, ‖z‖ = 1 := by + classical + obtain ⟨n, hn⟩ := hsize + have hc : Fintype.card (Fin 2) ≤ Fintype.card (I n) := by simpa using hn + obtain ⟨b⟩ := (Function.Embedding.nonempty_of_card_le hc) + let a : Unit ↪ I n := ⟨fun _ => b 1, fun _ _ _ => Subsingleton.elim _ _⟩ + have ha : ∀ j, a j ≠ b 0 := fun _ => b.injective.ne (by decide : (1 : Fin 2) ≠ 0) + exact ⟨centeredStageVector τ (φ n) (MatrixAlphabet.normalizedLetter (b 0) (b 1)), + (normalizedLetter_orthonormal τ hτ h1 (φ n) (b 0) a ha).norm_eq_one ()⟩ + +include h1 in +theorem invariant_intertwiner {k l : ℕ} + (Y : wordSpace (fullSpace τ) (zeroSpace τ) k →L[ℂ] + wordSpace (fullSpace τ) (zeroSpace τ) l) + (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hgen : ∀ a : A, τ.gnsStarAlgHom a ∈ Set.centralizer (Set.centralizer + (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)))) + (hY : ∀ n (u : unitary (Matrix (I n) (I n) ℂ)), + Y.comp (wordConjugation τ hτ (stageUnitary (φ n) u) k).toContinuousLinearMap = + (wordConjugation τ hτ (stageUnitary (φ n) u) l).toContinuousLinearMap.comp Y) + (hleft : ∀ a : A, Y.comp (wordLeft τ a k) = (wordLeft τ a l).comp Y) : + ∃ c : (Fin k ≃ Fin l) → ℂ, + Y = ∑ σ, c σ • (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap := + word_intertwiner τ hτ h1 Y I φ e he hsize + (dense_stages_of_bicommutant_generation τ I φ e he hgen) hY hleft + +include h1 in +theorem word_multiplicity_both {k : ℕ} {J : Type*} + [NormedAddCommGroup J] [InnerProductSpace ℂ J] [CompleteSpace J] + (T : Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J) →L[ℂ] + Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J)) + (hclass : ∀ a b : J, ∃ c : Equiv.Perm (Fin k) → ℂ, + scalarSlice T a b = ∑ σ, c σ • + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap) + (z : zeroSpace τ) (hz : ‖z‖ = 1) : + ∃ B : J →L[ℂ] J, ‖B‖ ≤ ‖T‖ ∧ + (∀ (d : fullSpace τ) (x : zeroSpace τ) (a : J), + T (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a) = + pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) (B a)) ∧ + (∀ (d : fullSpace τ) (x : zeroSpace τ) (a : J), + T.adjoint (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a) = + pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) (B.adjoint a)) := by + let v := word (fullSpace τ) (zeroSpace τ) k (vacuum τ) (fun _ => z) + have hv : ‖v‖ = 1 := by + simp only [v, norm_word, vacuum_norm τ h1, hz, Finset.prod_const_one, mul_one] + refine ⟨multiplicityCompression T v, norm_multiplicityCompression_le T v hv, ?_, ?_⟩ + · intro d x a + apply repeated_pair T (fun σ : Equiv.Perm (Fin k) => + (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap) hclass v _ hv + · intro σ + simp only [v, LinearIsometry.coe_toContinuousLinearMap, wordReindex_word, Function.comp_def] + · intro σ + simp only [LinearIsometry.coe_toContinuousLinearMap, wordReindex_word, Function.comp_def] + · intro d x a + apply repeated_pair_adjoint T (wordReindex (fullSpace τ) (zeroSpace τ)) hclass v _ hv + · intro σ + simp only [v, wordReindex_word, Function.comp_def] + · intro σ + simp only [wordReindex_word, Function.comp_def] + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeWordDecomposition.lean b/lean/OAI/Analysis/Commutator/FreeWordDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..d8c2ffac54fe028d967ce235e5b36d1a62c59b31 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeWordDecomposition.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.FreeWordTensor + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology + +namespace Kadison.FreeWordTensor + +open scoped InnerProductSpace _root_.Topology + +open UniformSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +def boundedLetter (a : FreeMoments.Letter S t.functional.toLinearMap) : + letterSpace t S a.color := + ⟨t.functional.toPreGNS a.val, by exact ⟨a.mem, a.centered⟩⟩ + +@[simp] lemma asLetter_boundedLetter (a : FreeMoments.Letter S t.functional.toLinearMap) : + asLetter t S a.color (boundedLetter t S a) = a := by cases a; rfl + +def paramsOfLetters : (w : List (FreeMoments.Letter S t.functional.toLinearMap)) → + Params t S (w.map FreeMoments.Letter.color) + | [] => PUnit.unit + | a :: w => (boundedLetter t S a, paramsOfLetters w) + +@[simp] lemma letters_paramsOfLetters : + ∀ w : List (FreeMoments.Letter S t.functional.toLinearMap), + letters t S (w.map FreeMoments.Letter.color) (paramsOfLetters t S w) = w + | [] => rfl + | a :: w => by + change asLetter t S a.color (boundedLetter t S a) :: + letters t S (w.map FreeMoments.Letter.color) (paramsOfLetters t S w) = a :: w + rw [asLetter_boundedLetter, letters_paramsOfLetters w] + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) + +noncomputable def hilbertWordSpan : Submodule ℂ t.functional.GNS := + ⨆ is : ColorSeq ι, LinearMap.range (wordInclusion t S hfree is).toLinearMap + +lemma bounded_word_mem (w : List (FreeMoments.Letter S t.functional.toLinearMap)) + (hw : FreeMoments.Reduced w) : + (t.functional.toPreGNS (FreeMoments.word w) : t.functional.GNS) ∈ + hilbertWordSpan t S hfree := by + let is : ColorSeq ι := ⟨w.map FreeMoments.Letter.color, (List.isChain_map _).mpr hw⟩ + apply Submodule.mem_iSup_of_mem is + use (pure t S is.val (paramsOfLetters t S w) : wordSpace t S is) + change wordEmbedding t S hfree is.val is.property _ = _ + rw [wordEmbedding_coe, readPre_pure] + simp only [is, letters_paramsOfLetters] + +lemma generated_mem_span {a : A} (ha : a ∈ iSup S) : + (t.functional.toPreGNS a : t.functional.GNS) ∈ hilbertWordSpan t S hfree := by + have ha' : a ∈ FreeMoments.wordSpan S t.functional.toLinearMap := by + change a ∈ (FreeMoments.reducedAlgebra S (fun a => map_star t.functional a) t.normalized) + rw [FreeMoments.reducedAlgebra_eq_iSup] + exact ha + clear ha + induction ha' using Submodule.span_induction with + | mem a ha => + obtain ⟨w, hw, rfl⟩ := ha + exact bounded_word_mem t S hfree w hw + | zero => simp only [map_zero, Completion.coe_zero, Submodule.zero_mem] + | add a b _ _ ha hb => simpa only [map_add, Completion.coe_add] using + (hilbertWordSpan t S hfree).add_mem ha hb + | smul c a _ ha => simpa only [map_smul, Completion.coe_smul] using + (hilbertWordSpan t S hfree).smul_mem c ha + +def generatedOperators : StarSubalgebra ℂ (t.functional.GNS →L[ℂ] t.functional.GNS) := + (iSup S).map t.functional.gnsStarAlgHom + +lemma total_words_from_generation + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + (hilbertWordSpan t S hfree).topologicalClosure = ⊤ := by + apply Submodule.eq_top_iff'.mpr + intro x + induction x using Completion.induction_on with + | hp => exact (hilbertWordSpan t S hfree).isClosed_topologicalClosure + | ih x => + let ξ : t.functional.GNS := (t.functional.toPreGNS 1 : t.functional.GNS) + have h := Kadison.bicommutant_mem_cyclicSubspace (generatedOperators t S) + (hgen (t.functional.ofPreGNS x)) ξ + have heq : t.functional.gnsStarAlgHom (t.functional.ofPreGNS x) ξ = + (x : t.functional.GNS) := by + simp [ξ, PositiveLinearMap.gnsStarAlgHom] + rw [heq] at h + apply Submodule.topologicalClosure_mono ?_ h + rintro y ⟨a, ha, rfl⟩ + obtain ⟨b, hb, rfl⟩ := ha + simpa [ξ, PositiveLinearMap.gnsStarAlgHom] using generated_mem_span t S hfree hb + +theorem isHilbertSum_of_generation + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) : + IsHilbertSum ℂ (wordSpace t S) (wordInclusion t S hfree) := by + apply IsHilbertSum.mk (wordFamily_orthogonal t S hfree) + change ⊤ ≤ (hilbertWordSpan t S hfree).topologicalClosure + rw [total_words_from_generation t S hfree hgen] + +end Kadison.FreeWordTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FreeWordTensor.lean b/lean/OAI/Analysis/Commutator/FreeWordTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..a83d59dc0e82b59eff2672b7ca72221a4c683f1a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FreeWordTensor.lean @@ -0,0 +1,268 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace + +namespace Kadison.FreeWordTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +structure FaithfulState (A : Type) [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] where + functional : A →ₚ[ℂ] ℂ + normalized : functional 1 = 1 + faithful : ∀ a : A, functional (star a * a) = 0 → a = 0 + +variable (t : FaithfulState A) + +abbrev preSpace := t.functional.PreGNS + +noncomputable instance faithfulNormed : NormedAddCommGroup (preSpace t) := + NormedAddCommGroup.ofSeparation fun x hx => by + apply t.functional.ofPreGNS.injective + change t.functional.ofPreGNS x = 0 + apply t.faithful + have hs := t.functional.preGNS_norm_sq x + rw [hx] at hs + simpa using hs.symm + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +def letterSpace (i : ι) : Submodule ℂ (preSpace t) where + carrier := {x | t.functional.ofPreGNS x ∈ S i ∧ t.functional (t.functional.ofPreGNS x) = 0} + zero_mem' := by simp + add_mem' := by rintro x y ⟨hx, hx0⟩ ⟨hy, hy0⟩; simp [map_add, add_mem hx hy, hx0, hy0] + smul_mem' := by + rintro c x ⟨hx, hx0⟩ + exact ⟨by simpa using SMulMemClass.smul_mem c hx, by simp [hx0]⟩ + +def letterValue (i : ι) : letterSpace t S i →ₗ[ℂ] A := + t.functional.ofPreGNS.toLinearMap.comp (letterSpace t S i).subtype + +def asLetter (i : ι) (x : letterSpace t S i) : FreeMoments.Letter S t.functional.toLinearMap where + color := i + val := letterValue t S i x + mem := x.property.1 + centered := x.property.2 + +structure Space where + carrier : Type + [normed : NormedAddCommGroup carrier] + [inner : InnerProductSpace ℂ carrier] + +attribute [instance] Space.normed Space.inner + +instance : CoeSort Space Type := ⟨Space.carrier⟩ + +@[reducible] noncomputable def tensor : List ι → Space + | [] => ⟨ℂ⟩ + | i :: is => ⟨letterSpace t S i ⊗[ℂ] tensor is⟩ + +@[reducible] def Params : List ι → Type + | [] => PUnit + | i :: is => letterSpace t S i × Params is + +noncomputable def pure : ∀ is, Params t S is → tensor t S is + | [], _ => (1 : ℂ) + | _ :: is, x => x.1 ⊗ₜ[ℂ] pure is x.2 + +def letters : ∀ is, Params t S is → List (FreeMoments.Letter S t.functional.toLinearMap) + | [], _ => [] + | i :: is, x => asLetter t S i x.1 :: letters is x.2 + +@[simp] lemma letters_colors : ∀ is (x : Params t S is), + (letters t S is x).map FreeMoments.Letter.color = is + | [], _ => rfl + | _ :: is, x => by simp [letters, asLetter, letters_colors is x.2] + +lemma letters_reduced (is : List ι) (x : Params t S is) (his : is.IsChain (· ≠ ·)) : + FreeMoments.Reduced (letters t S is x) := by + rw [← letters_colors t S is x] at his + exact (List.isChain_map _).mp his + +noncomputable def read : ∀ is, tensor t S is →ₗ[ℂ] A + | [] => Algebra.linearMap ℂ A + | i :: is => (TensorProduct.lift (LinearMap.mul ℂ A)).comp + (TensorProduct.map (letterValue t S i) (read is)) + +@[simp] lemma read_pure : ∀ is (x : Params t S is), + read t S is (pure t S is x) = FreeMoments.word (letters t S is x) + | [], _ => by + change algebraMap ℂ A 1 = 1 + exact map_one _ + | i :: is, x => by + change letterValue t S i x.1 * read t S is (pure t S is x.2) = + letterValue t S i x.1 * FreeMoments.word (letters t S is x.2) + rw [read_pure is x.2] + +lemma span_pure (is : List ι) : + Submodule.span ℂ (Set.range (pure t S is)) = ⊤ := by + induction is with + | nil => + apply Submodule.eq_top_iff'.mpr + intro z + have h : (1 : ℂ) ∈ Submodule.span ℂ (Set.range (pure t S [])) := + Submodule.subset_span ⟨PUnit.unit, rfl⟩ + simpa using (Submodule.span ℂ (Set.range (pure t S []))).smul_mem z h + | cons i is ih => + apply Submodule.eq_top_iff'.mpr + intro z + induction z using TensorProduct.inductionOn with + | add x y hx hy => exact Submodule.add_mem _ hx hy + | tmul x y => + have hy : y ∈ Submodule.span ℂ (Set.range (pure t S is)) := by rw [ih]; trivial + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨v, rfl⟩ := hy + exact Submodule.subset_span ⟨(x,v), rfl⟩ + | zero => simp only [TensorProduct.tmul_zero, Submodule.zero_mem] + | add y z _ _ hy hz => + simpa only [TensorProduct.tmul_add] using + (Submodule.span ℂ (Set.range (pure t S (i::is)))).add_mem hy hz + | smul c y _ hy => + simpa only [TensorProduct.tmul_smul] using + (Submodule.span ℂ (Set.range (pure t S (i::is)))).smul_mem c hy + +lemma inner_letter (i : ι) (x y : letterSpace t S i) : + inner ℂ x y = t.functional (star (letterValue t S i x) * letterValue t S i y) := by + rfl + +lemma inner_pure : ∀ is (x y : Params t S is), + inner ℂ (pure t S is x) (pure t S is y) = + FreeMoments.gram (letters t S is x) (letters t S is y) + | [], _, _ => by simp [pure, letters, FreeMoments.gram] + | i :: is, x, y => by + change inner ℂ (x.1 ⊗ₜ[ℂ] pure t S is x.2) (y.1 ⊗ₜ[ℂ] pure t S is y.2) = _ + rw [TensorProduct.inner_tmul, inner_pure is x.2 y.2, inner_letter] + simp [FreeMoments.gram, letters, asLetter] + +noncomputable def readPre (is : List ι) : tensor t S is →ₗ[ℂ] preSpace t := + t.functional.toPreGNS.toLinearMap.comp (read t S is) + +@[simp] lemma readPre_pure (is : List ι) (x : Params t S is) : + readPre t S is (pure t S is x) = + t.functional.toPreGNS (FreeMoments.word (letters t S is x)) := by + change t.functional.toPreGNS (read t S is (pure t S is x)) = _ + rw [read_pure] + +variable (hfree : FreeMoments.Free S t.functional.toLinearMap) + +include hfree + +lemma inner_readPre_pure (is : List ι) (his : is.IsChain (· ≠ ·)) + (x y : Params t S is) : + inner ℂ (readPre t S is (pure t S is x)) (readPre t S is (pure t S is y)) = + inner ℂ (pure t S is x) (pure t S is y) := by + rw [readPre_pure, readPre_pure, inner_pure] + exact FreeMoments.gram_word (fun a => map_star t.functional a) t.normalized hfree _ _ + (letters_reduced t S is x his) (letters_reduced t S is y his) + +lemma inner_readPre (is : List ι) (his : is.IsChain (· ≠ ·)) + (x y : tensor t S is) : + inner ℂ (readPre t S is x) (readPre t S is y) = inner ℂ x y := by + have hx : x ∈ Submodule.span ℂ (Set.range (pure t S is)) := by rw [span_pure]; trivial + have hy : y ∈ Submodule.span ℂ (Set.range (pure t S is)) := by rw [span_pure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v, rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨w, rfl⟩ := hy + exact inner_readPre_pure t S hfree is his v w + | zero => simp + | add y z _ _ hy hz => simp only [map_add, inner_add_right, hy, hz] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy] + | zero => simp + | add x z _ _ hx hz => simp only [map_add, inner_add_left, hx, hz] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx] + +noncomputable def readIsometry (is : List ι) (his : is.IsChain (· ≠ ·)) : + tensor t S is →ₗᵢ[ℂ] preSpace t := + (readPre t S is).isometryOfInner (inner_readPre t S hfree is his) + +noncomputable def wordEmbedding (is : List ι) (his : is.IsChain (· ≠ ·)) : + Completion (tensor t S is) →ₗᵢ[ℂ] t.functional.GNS where + toLinearMap := (readIsometry t S hfree is his).toContinuousLinearMap.completion.toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => simp + +@[simp] lemma wordEmbedding_coe (is : List ι) (his : is.IsChain (· ≠ ·)) + (x : tensor t S is) : + wordEmbedding t S hfree is his (x : Completion (tensor t S is)) = + (readPre t S is x : t.functional.GNS) := by + change (readIsometry t S hfree is his).toContinuousLinearMap.completion _ = _ + simp [readIsometry] + +lemma inner_readPre_pure_ne (is js : List ι) + (his : is.IsChain (· ≠ ·)) (hjs : js.IsChain (· ≠ ·)) (hne : is ≠ js) + (x : Params t S is) (y : Params t S js) : + inner ℂ (readPre t S is (pure t S is x)) (readPre t S js (pure t S js y)) = 0 := by + rw [readPre_pure, readPre_pure] + change t.functional.toLinearMap (star (FreeMoments.word (letters t S is x)) * + FreeMoments.word (letters t S js y)) = 0 + rw [FreeMoments.gram_word (fun a => map_star t.functional a) t.normalized hfree _ _ + (letters_reduced t S is x his) (letters_reduced t S js y hjs)] + apply FreeMoments.gram_zero_of_colors_ne + simpa only [letters_colors] using hne + +lemma inner_readPre_ne (is js : List ι) + (his : is.IsChain (· ≠ ·)) (hjs : js.IsChain (· ≠ ·)) (hne : is ≠ js) + (x : tensor t S is) (y : tensor t S js) : + inner ℂ (readPre t S is x) (readPre t S js y) = 0 := by + have hx : x ∈ Submodule.span ℂ (Set.range (pure t S is)) := by rw [span_pure]; trivial + have hy : y ∈ Submodule.span ℂ (Set.range (pure t S js)) := by rw [span_pure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v, rfl⟩ := hx + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨w, rfl⟩ := hy + exact inner_readPre_pure_ne t S hfree is js his hjs hne v w + | zero => simp + | add y z _ _ hy hz => simp only [map_add, inner_add_right, hy, hz, add_zero] + | smul c y _ hy => simp only [map_smul, inner_smul_right, hy, mul_zero] + | zero => simp + | add x z _ _ hx hz => simp only [map_add, inner_add_left, hx, hz, add_zero] + | smul c x _ hx => simp only [map_smul, inner_smul_left, hx, mul_zero] + +lemma wordEmbedding_orthogonal (is js : List ι) + (his : is.IsChain (· ≠ ·)) (hjs : js.IsChain (· ≠ ·)) (hne : is ≠ js) + (x : Completion (tensor t S is)) (y : Completion (tensor t S js)) : + inner ℂ (wordEmbedding t S hfree is his x) (wordEmbedding t S hfree js hjs y) = 0 := by + induction x, y using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih x y => + rw [wordEmbedding_coe, wordEmbedding_coe, Completion.inner_coe] + exact inner_readPre_ne t S hfree is js his hjs hne x y + +def ColorSeq (ι : Type*) := {is : List ι // is.IsChain (· ≠ ·)} + +abbrev wordSpace (is : ColorSeq ι) := Completion (tensor t S is.val) + +noncomputable def wordInclusion (is : ColorSeq ι) : wordSpace t S is →ₗᵢ[ℂ] t.functional.GNS := + wordEmbedding t S hfree is.val is.property + +lemma wordFamily_orthogonal : + OrthogonalFamily ℂ (wordSpace t S) (wordInclusion t S hfree) := by + intro is js hne x y + exact wordEmbedding_orthogonal t S hfree is.val js.val is.property js.property + (fun h => hne (Subtype.ext h)) x y + +end Kadison.FreeWordTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/FullCentralSupportLinks.lean b/lean/OAI/Analysis/Commutator/FullCentralSupportLinks.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b55c31575a7a3a129055d8965d92066065f8d3b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/FullCentralSupportLinks.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.Commutator.OrthogonalLinkFamily + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.FactorCorner + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_nonzero_corner_of_full_support (M : VonNeumannAlgebra H) + {e f : H →L[ℂ] H} (hsupport : (supportSpace M e).starProjection=1) (hff : f≠0) : + ∃ a∈M, f*a*e≠0 := by + by_contra! h + have hz : ∀ x∈supportSpace M e, f x=0 := by + intro x hx + apply closure_minimal (t := {x | f x=0}) ?_ + (isClosed_eq f.continuous continuous_const) hx + have hspan : Submodule.span ℂ {x | ∃ a∈M, ∃ ξ : H, a (e ξ)=x} ≤ LinearMap.ker f.toLinearMap := by + apply Submodule.span_le.mpr + rintro y ⟨a,ha,ξ,rfl⟩ + exact congrArg (fun T : H →L[ℂ] H => T ξ) (h a ha) + exact hspan + apply hff + ext x + have hm := (supportSpace M e).starProjection_apply_mem x + rw [hsupport] at hm + exact hz x hm + +theorem exists_linking_partialIsometry_of_full_support (M : VonNeumannAlgebra H) + {e f : H →L[ℂ] H} (he : e∈M) (hfM : f∈M) + (hpe : IsStarProjection e) (hpf : IsStarProjection f) + (hsupport : (supportSpace M e).starProjection=1) (hnf : f≠0) : + ∃ v∈M, v≠0 ∧ v*star v*v=v ∧ star v*v≤e ∧ v*star v≤f := by + obtain ⟨a,ha,hna⟩ := exists_nonzero_corner_of_full_support M hsupport hnf + let x := f*a*e + have hx : x∈M := M.mul_mem (M.mul_mem hfM ha) he + have hfx : f*x=x := by dsimp only [x]; rw [←mul_assoc,←mul_assoc,hpf.isIdempotentElem.eq] + have hxe : x*e=x := by dsimp only [x]; rw [mul_assoc,hpe.isIdempotentElem.eq] + refine ⟨Polar.partialIsometry x,Polar.partialIsometry_mem_vonNeumann M hx,?_, + Polar.partialIsometry_triple x,?_,?_⟩ + · intro hzero + apply hna + have hfact := Polar.factorization x + rw [hzero,zero_mul] at hfact + exact hfact.symm + · rw [Polar.partialIsometry_initial] + exact Polar.rightSupport_le x e hpe hxe + · exact Polar.leftSupport_le x f hpf hfx + +end Kadison.FactorCorner + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) + +theorem maximal_family_spans_of_full_support + (hsupport : (FactorCorner.supportSpace M e).starProjection=1) + (heM : e∈M) (hfM : f∈M) (he : IsStarProjection e) (hf : IsStarProjection f) + (S : Set (Link M e f)) (hS : Maximal (OrthogonalLinks M e f) S) : + (familySpace M e f S).starProjection=f := by + let q := (familySpace M e f S).starProjection + have hq : IsStarProjection q := isStarProjection_starProjection + have hqM : q∈M := familySpace_projection_mem M e f S + have hfq : f*q=q := familySpace_target_mul M e f S hf + have hqf : q*f=q := by simpa only [star_mul,hq.isSelfAdjoint.star_eq,hf.isSelfAdjoint.star_eq] using congrArg star hfq + have hr : IsStarProjection (f-q) := hq.sub_of_mul_eq_left hf hqf + by_contra hqne + have hrne : f-q≠0 := by + intro hz + exact hqne (sub_eq_zero.mp hz).symm + obtain ⟨w,hwM,hwne,hwtr,hwsrc,hwtgt⟩ := + FactorCorner.exists_linking_partialIsometry_of_full_support M heM (M.sub_mem hfM hqM) he hr hsupport hrne + let w' : Link M e (f-q) := ⟨w,hwM,hwtr,hwsrc,hwtgt⟩ + have hrw : (f-q)*w=w := w'.target_mul hr + have hwf : w*star w≤f := hwtgt.trans (sub_le_self _ hq.nonneg) + let v : Link M e f := ⟨w,hwM,hwtr,hwsrc,hwf⟩ + have hvorth (u : Link M e f) (hu : u∈S) : star u.val*w=0 := by + have hqu : q*u.val=u.val := familySpace_projection_mul M e f S hu + have hsuq : star u.val*q=star u.val := by + simpa only [star_mul,hq.isSelfAdjoint.star_eq] using congrArg star hqu + have huf : star u.val*f=star u.val := by + simpa only [star_mul,hf.isSelfAdjoint.star_eq] using congrArg star (u.target_mul hf) + calc + _=star u.val*((f-q)*w) := by rw [hrw] + _=0 := by rw [←mul_assoc,mul_sub,huf,hsuq,sub_self,zero_mul] + have hins : OrthogonalLinks M e f (insert v S) := by + intro a ha b hb hne' + rcases ha with rfl|ha <;> rcases hb with rfl|hb + · exact (hne' rfl).elim + · simpa only [star_mul,star_star,star_zero] using congrArg star (hvorth b hb) + · exact hvorth a ha + · exact hS.1 ha hb hne' + have hvS : v∈S := hS.2 hins (Set.subset_insert v S) (Set.mem_insert v S) + have hqw : q*w=w := familySpace_projection_mul M e f S hvS + have hqr : q*(f-q)=0 := by rw [mul_sub,hqf,hq.isIdempotentElem.eq,sub_self] + have : q*w=0 := by calc + _=q*((f-q)*w) := by rw [hrw] + _=0 := by rw [←mul_assoc,hqr,zero_mul] + exact hwne (hqw.symm.trans this) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GNSCornerTransport.lean b/lean/OAI/Analysis/Commutator/GNSCornerTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..11264b86695bb69dabb64631378e41080602cc4b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GNSCornerTransport.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerSymmetrization +import OAI.Analysis.Commutator.FreeSymmetrization +import OAI.Analysis.Commutator.NormalTraceProjection +import OAI.Analysis.Commutator.TracialVectorSubalgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.VectorGNS + +open FreeWordTensor FreeMoments FreeWordAction FreeBlocks + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (ξ : H) + +variable (htr : ∀ a b : M,subalgebraTrace M ξ (a*b)=subalgebraTrace M ξ (b*a)) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + +abbrev vectorState : FaithfulState M where + functional := subalgebraTrace M ξ + normalized := hone + faithful := hfaith + +include htr in +lemma ambient_range (R : Bool → StarSubalgebra ℂ M) + {X : (subalgebraTrace M ξ).GNS →L[ℂ] (subalgebraTrace M ξ).GNS} + (hX : X∈ambientOperators (vectorState M ξ hfaith hone) R) : + ∃ a : M,(subalgebraTrace M ξ).gnsStarAlgHom a=X := by + have hb : X∈Set.centralizer (Set.centralizer (Set.range (subalgebraTrace M ξ).gnsStarAlgHom)) := by + intro Y hY + apply (mem_ambientOperators _ _).mp hX Y + rintro Z ⟨a,_,rfl⟩ + exact hY _ ⟨a,rfl⟩ + rw [NormalGNS.range_bicommutant M (subalgebraTrace M ξ) htr + (subalgebraTrace_normal M ξ)] at hb + exact hb + +variable {D : Type} [CStarAlgebra D] (f : D →⋆ₐ[ℂ] M) + (R : Bool → StarSubalgebra ℂ M) + +private lemma corner_preimage (a : M) (β : ℂ) + (hX : CornerSymmetrization.CornerElement + (factorOperators (vectorState M ξ hfaith hone) f) + (ambientOperators (vectorState M ξ hfaith hone) R) + (TracialGNS.vacuum (subalgebraTrace M ξ)) β + ((subalgebraTrace M ξ).gnsStarAlgHom a)) : + ∃ q : D, IsStarProjection (f q) ∧ subalgebraTrace M ξ (f q)=β ∧ + f q*a=a ∧ a*f q=a := by + obtain ⟨_,e,⟨q,hqe⟩,he,het,hel,her⟩ := hX + change (subalgebraTrace M ξ).gnsStarAlgHom (f q)=e at hqe + subst e + have hq := (NormalGNS.gns_projection_iff M (subalgebraTrace M ξ) hfaith (f q)).mp he + have hqt : subalgebraTrace M ξ (f q)=β := by + change inner ℂ (TracialGNS.vacuum (subalgebraTrace M ξ)) + ((subalgebraTrace M ξ).gnsStarAlgHom (f q) (TracialGNS.vacuum (subalgebraTrace M ξ)))=β at het + rw [TracialGNS.left_vacuum] at het + exact (TracialGNS.inner_vacuum_algebraVector _ _).symm.trans het + change (subalgebraTrace M ξ).gnsStarAlgHom (f q)*(subalgebraTrace M ξ).gnsStarAlgHom a= + (subalgebraTrace M ξ).gnsStarAlgHom a at hel + change (subalgebraTrace M ξ).gnsStarAlgHom a*(subalgebraTrace M ξ).gnsStarAlgHom (f q)= + (subalgebraTrace M ξ).gnsStarAlgHom a at her + have hl : f q*a=a := NormalGNS.gns_injective M (subalgebraTrace M ξ) hfaith + ((map_mul (subalgebraTrace M ξ).gnsStarAlgHom (f q) a).trans hel) + have hr : a*f q=a := NormalGNS.gns_injective M (subalgebraTrace M ξ) hfaith + ((map_mul (subalgebraTrace M ξ).gnsStarAlgHom a (f q)).trans her) + exact ⟨q,hq,hqt,hl,hr⟩ + +include htr in +theorem corner_bound (T : H →L[ℂ] H) (ε : ℝ) (β : ℂ) + (hbound : ∀ q : D,IsStarProjection (f q) → subalgebraTrace M ξ (f q)=β → + ∀ a : M,f q*a=a → a*f q=a → + ‖T*(a:H →L[ℂ] H)-(a:H →L[ℂ] H)*T‖≤ε*‖a‖) + (X : (subalgebraTrace M ξ).GNS →L[ℂ] (subalgebraTrace M ξ).GNS) + (hX : CornerSymmetrization.CornerElement + (factorOperators (vectorState M ξ hfaith hone) f) + (ambientOperators (vectorState M ξ hfaith hone) R) + (TracialGNS.vacuum (subalgebraTrace M ξ)) β X) : + ‖compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) T*X- + X*compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) T‖≤ε*‖X‖ := by + have hrange := ambient_range M ξ htr hfaith hone R hX.1 + obtain ⟨a,rfl⟩ := hrange + have hpreimage := corner_preimage M ξ hfaith hone f R a β hX + obtain ⟨q,hq,hqt,hl,hr⟩ := hpreimage + calc + _ ≤ ‖T*(a:H →L[ℂ] H)-(a:H →L[ℂ] H)*T‖ := norm_commutator_compression_le (subalgebraTrace M ξ) + M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) T a + _ ≤ ε*‖a‖ := hbound q hq hqt a hl hr + _ = _ := by rw [NormalGNS.gns_norm M (subalgebraTrace M ξ) hfaith] + +lemma commutes (T : H →L[ℂ] H) (a : M) + (ha : T*(a:H →L[ℂ] H)=(a:H →L[ℂ] H)*T) : + compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) T* + (subalgebraTrace M ξ).gnsStarAlgHom a= + (subalgebraTrace M ξ).gnsStarAlgHom a* + compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) T := by + apply sub_eq_zero.mp + refine (compression_commutator (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ + (subalgebraTrace_subtype M ξ) T a).trans ?_ + change compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) + (T*(a:H →L[ℂ] H)-(a:H →L[ℂ] H)*T)=0 + rw [ha,sub_self] + simp only [compression,FreeCorner.compress,comp_zero,zero_comp] + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GNSVectorEmbedding.lean b/lean/OAI/Analysis/Commutator/GNSVectorEmbedding.lean new file mode 100644 index 0000000000000000000000000000000000000000..a7ec6f2a82e70bf962a906251ac9c3bbfce69d39 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GNSVectorEmbedding.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteHankel +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open UniformSpace ContinuousLinearMap + +namespace Kadison.VectorGNS + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (τ : A →ₚ[ℂ] ℂ) (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hτ : ∀ a,τ a=inner ℂ ξ (φ a ξ)) + +def preMap : τ.PreGNS →ₗ[ℂ] H where + toFun x := φ (τ.ofPreGNS x) ξ + map_add' x y := by simp only [map_add,add_apply] + map_smul' c x := by simp only [map_smul,smul_apply,RingHom.id_apply] + +include hτ in +lemma inner_preMap (x y : τ.PreGNS) : + inner ℂ (preMap τ φ ξ x) (preMap τ φ ξ y)=inner ℂ x y := by + rw [PositiveLinearMap.preGNS_inner_def,hτ,map_mul,map_star] + change inner ℂ (φ (τ.ofPreGNS x) ξ) (φ (τ.ofPreGNS y) ξ)= + inner ℂ ξ ((φ (τ.ofPreGNS x)).adjoint (φ (τ.ofPreGNS y) ξ)) + exact (adjoint_inner_right _ _ _).symm + +def preIsometry : τ.PreGNS →ₗᵢ[ℂ] H := + (preMap τ φ ξ).isometryOfInner (inner_preMap τ φ ξ hτ) + +def embedding : τ.GNS →ₗᵢ[ℂ] H where + toLinearMap := ((preIsometry τ φ ξ hτ).toContinuousLinearMap.extend + (Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS)).toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => + change ‖((preIsometry τ φ ξ hτ).toContinuousLinearMap.extend + (Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS)) + ((Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS) x)‖=‖(x:τ.GNS)‖ + rw [extend_eq _ Completion.denseRange_coe (Completion.isUniformInducing_coe _), + LinearIsometry.coe_toContinuousLinearMap,LinearIsometry.norm_map,Completion.norm_coe] + +@[simp] lemma embedding_coe (a : A) : + embedding τ φ ξ hτ (TracialGNS.algebraVector τ a)=φ a ξ := by + change ((preIsometry τ φ ξ hτ).toContinuousLinearMap.extend + (Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS)) + ((Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS) (τ.toPreGNS a))=_ + rw [extend_eq _ Completion.denseRange_coe (Completion.isUniformInducing_coe _)] + rfl + +lemma embedding_vacuum : embedding τ φ ξ hτ (TracialGNS.vacuum τ)=ξ := by + change embedding τ φ ξ hτ (TracialGNS.algebraVector τ 1)=ξ + rw [embedding_coe,map_one,one_apply_eq_self] + +lemma intertwines (a : A) : + (embedding τ φ ξ hτ).toContinuousLinearMap.comp (τ.gnsStarAlgHom a)= + (φ a).comp (embedding τ φ ξ hτ).toContinuousLinearMap := by + apply ContinuousLinearMap.ext + intro x + refine (TracialGNS.algebraVector_dense τ).induction_on x + (isClosed_eq (by fun_prop) (by fun_prop)) ?_ + intro b + have hl : τ.gnsStarAlgHom a (TracialGNS.algebraVector τ b)= + TracialGNS.algebraVector τ (a*b) := TracialGNS.left_coe τ a b + simp only [comp_apply,LinearIsometry.coe_toContinuousLinearMap,hl,embedding_coe, + map_mul,mul_apply_eq_comp] + +lemma adjoint_intertwines (a : A) : + (τ.gnsStarAlgHom a).comp (embedding τ φ ξ hτ).toContinuousLinearMap.adjoint= + (embedding τ φ ξ hτ).toContinuousLinearMap.adjoint.comp (φ a) := by + have he := congrArg (fun T : τ.GNS →L[ℂ] H => T.adjoint) (intertwines τ φ ξ hτ (star a)) + simpa only [adjoint_comp,map_star,star_eq_adjoint,adjoint_adjoint] using he + +def compression (T : H →L[ℂ] H) : τ.GNS →L[ℂ] τ.GNS := + FreeCorner.compress (embedding τ φ ξ hτ) T + +lemma compression_commutator (T : H →L[ℂ] H) (a : A) : + compression τ φ ξ hτ T*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*compression τ φ ξ hτ T= + compression τ φ ξ hτ (T*φ a-φ a*T) := by + simp only [compression,FreeCorner.compress,mul_def,comp_sub,sub_comp] + congr 1 + · simp only [comp_assoc] + rw [intertwines τ φ ξ hτ a] + · simp only [←comp_assoc] + rw [adjoint_intertwines τ φ ξ hτ a] + +lemma norm_commutator_compression_le (T : H →L[ℂ] H) (a : A) : + ‖compression τ φ ξ hτ T*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*compression τ φ ξ hτ T‖≤ + ‖T*φ a-φ a*T‖ := by + rw [compression_commutator] + exact FreeCorner.norm_compress_le _ _ + +lemma compression_on_preserved (T : H →L[ℂ] H) (x y : τ.GNS) + (hxy : T (embedding τ φ ξ hτ x)=embedding τ φ ξ hτ y) : + compression τ φ ξ hτ T x=y := by + change (embedding τ φ ξ hτ).toContinuousLinearMap.adjoint + (T (embedding τ φ ξ hτ x))=y + rw [hxy] + have he := congrArg (fun B : τ.GNS →L[ℂ] τ.GNS => B y) + (LinearIsometry.adjoint_comp_self (embedding τ φ ξ hτ)) + exact he + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GNSVectorUnitary.lean b/lean/OAI/Analysis/Commutator/GNSVectorUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..7108457dbb87339e8d6c1f7a671a376ac68925f8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GNSVectorUnitary.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.GNSVectorEmbedding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.VectorGNS + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (τ : A →ₚ[ℂ] ℂ) (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) + (hτ : ∀ a,τ a=inner ℂ ξ (φ a ξ)) (hcyc : DenseRange (fun a : A => φ a ξ)) + +include hcyc in +lemma embedding_surjective : Function.Surjective (embedding τ φ ξ hτ) := by + have hd : DenseRange (embedding τ φ ξ hτ) := by + apply hcyc.mono + rintro y ⟨a,rfl⟩ + exact ⟨TracialGNS.algebraVector τ a,embedding_coe τ φ ξ hτ a⟩ + intro y + exact (embedding τ φ ξ hτ).isometry.isClosedEmbedding.isClosed_range.closure_subset (hd y) + +def equivalence : τ.GNS ≃ₗᵢ[ℂ] H := + LinearIsometryEquiv.ofSurjective (embedding τ φ ξ hτ) (embedding_surjective τ φ ξ hτ hcyc) + +lemma equivalence_algebraVector (a : A) : + equivalence τ φ ξ hτ hcyc (TracialGNS.algebraVector τ a)=φ a ξ := + embedding_coe τ φ ξ hτ a + +lemma equivalence_intertwines (a : A) (v : τ.GNS) : + equivalence τ φ ξ hτ hcyc (τ.gnsStarAlgHom a v)=φ a (equivalence τ φ ξ hτ hcyc v) := + congrArg (fun T : τ.GNS →L[ℂ] H => T v) (intertwines τ φ ξ hτ a) + +lemma equivalence_conjugates (a : A) : + (equivalence τ φ ξ hτ hcyc).conjStarAlgEquiv (τ.gnsStarAlgHom a)=φ a := by + ext v + change equivalence τ φ ξ hτ hcyc + (τ.gnsStarAlgHom a ((equivalence τ φ ξ hτ hcyc).symm v))=φ a v + rw [equivalence_intertwines,LinearIsometryEquiv.apply_symm_apply] + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GeneratedFreePair.lean b/lean/OAI/Analysis/Commutator/GeneratedFreePair.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc249ba01cd42edc35624e08b222914a101535c2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GeneratedFreePair.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMomentsTransport +import OAI.Analysis.Commutator.MatrixTowerGNS +import OAI.Analysis.Commutator.VectorFreeGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.GeneratedFreePair + +open FreeMoments + +variable {H A : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [CStarAlgebra A] + +variable (D : VonNeumannAlgebra H) (k : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +def algebra : VonNeumannAlgebra H := NormalGNS.bicommutant (D.toStarSubalgebra⊔k.range) + +lemma left_mem (d : D) : (d:H →L[ℂ] H)∈algebra D k := + NormalGNS.subset_bicommutant _ ((show D.toStarSubalgebra ≤ D.toStarSubalgebra ⊔ k.range from le_sup_left) d.property) + +lemma right_mem (a : A) : k a∈algebra D k := + NormalGNS.subset_bicommutant _ ((show k.range ≤ D.toStarSubalgebra ⊔ k.range from le_sup_right) ⟨a,rfl⟩) + +lemma left_le : D.toStarSubalgebra≤(algebra D k).toStarSubalgebra := fun a ha => + left_mem D k ⟨a,ha⟩ + +abbrev leftHom : D →⋆ₐ[ℂ] algebra D k := VectorGNS.inclusion (algebra D k) D (left_le D k) + +def rightHom : A →⋆ₐ[ℂ] algebra D k := k.codRestrict (algebra D k).toStarSubalgebra (right_mem D k) + +def ambient (b : Bool) : StarSubalgebra ℂ (H →L[ℂ] H) := + if b then k.range else D.toStarSubalgebra + +def factors (b : Bool) : StarSubalgebra ℂ (algebra D k) := + (ambient D k b).comap (algebra D k).toStarSubalgebra.subtype + +lemma false_range : factors D k false=(leftHom D k).range := by + ext a + change (a:H →L[ℂ] H)∈D ↔ ∃ d : D,leftHom D k d=a + constructor + · intro ha + exact ⟨⟨a,ha⟩,Subtype.ext rfl⟩ + · rintro ⟨d,rfl⟩ + exact d.property + +lemma right_factor (a : A) : rightHom D k a∈factors D k true := by + change k a∈k.range + exact ⟨a,rfl⟩ + +lemma original_generation (a : algebra D k) : (a:H →L[ℂ] H)∈Set.centralizer + (Set.centralizer (((iSup (factors D k)).map (algebra D k).toStarSubalgebra.subtype) : Set _)) := by + have hj : D.toStarSubalgebra⊔k.range≤ + (iSup (factors D k)).map (algebra D k).toStarSubalgebra.subtype := by + apply sup_le + · intro d hd + exact ⟨leftHom D k ⟨d,hd⟩,(le_iSup (factors D k) false) hd,rfl⟩ + · rintro b ⟨x,rfl⟩ + exact ⟨rightHom D k x,(le_iSup (factors D k) true) (right_factor D k x),rfl⟩ + have hb := (NormalGNS.mem_bicommutant _ _).mp a.property + intro T hT + apply hb T + intro x hx + exact hT x (hj hx) + +lemma le_ambient (M : VonNeumannAlgebra H) (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + (hkM : ∀ a : A,k a∈M) : (algebra D k).toStarSubalgebra≤M.toStarSubalgebra := by + intro a ha + change a∈(M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + have hb := (NormalGNS.mem_bicommutant _ _).mp ha + have hj : D.toStarSubalgebra⊔k.range≤M.toStarSubalgebra := sup_le hDM (by + rintro b ⟨x,rfl⟩ + exact hkM x) + intro T hT + apply hb T + intro x hx + exact hT x (hj hx) + +include D k in +theorem free_in_generated (ξ : H) + (hfree : Free (ambient D k) (VectorFunctional.functional ξ).toLinearMap) : + Free (factors D k) (VectorGNS.subalgebraTrace (algebra D k) ξ).toLinearMap := by + apply free_of_map (factors D k) (ambient D k) + (VectorGNS.subalgebraTrace (algebra D k) ξ).toLinearMap + (VectorFunctional.functional ξ).toLinearMap (algebra D k).toStarSubalgebra.subtype + (fun _ => rfl) (fun _ _ ha => ha) hfree + +lemma in_bicommutant (S : StarSubalgebra ℂ (H →L[ℂ] H)) + (hD : ∀ d : D,(d:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hk : ∀ a : A,k a∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (a : algebra D k) : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := by + have hle := le_ambient D k (NormalGNS.bicommutant S) + (fun d hd => (NormalGNS.mem_bicommutant _ _).mpr (hD ⟨d,hd⟩)) + (fun b => (NormalGNS.mem_bicommutant _ _).mpr (hk b)) + exact (NormalGNS.mem_bicommutant _ _).mp (hle a.property) + +lemma in_range_bicommutant {B : Type*} [Ring B] [Algebra ℂ B] [StarRing B] [StarModule ℂ B] + (l : B →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hD : ∀ d : D,(d:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (Set.range l))) + (hk : ∀ a : A,k a∈Set.range l) + (a : algebra D k) : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (Set.range l)) := by + exact in_bicommutant D k l.range hD + (fun b => Set.subset_centralizer_centralizer (hk b)) a + +end Kadison.GeneratedFreePair + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GeneratedMatrixBicommutant.lean b/lean/OAI/Analysis/Commutator/GeneratedMatrixBicommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..38693c307bbefab9e84185e8078c67b2749f16f0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GeneratedMatrixBicommutant.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Commutator.EquivariantBicommutant +import OAI.Analysis.Commutator.MatrixStageGNSGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.GeneratedMatrixBicommutant + +variable {H A : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [CStarAlgebra A] + +variable (size : ℕ → ℕ) + +variable (stage : ∀ n,Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] A) + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +def stages : StarSubalgebra ℂ (H →L[ℂ] H) := ⨆ n,(φ.comp (stage n)).range + +def algebra : VonNeumannAlgebra H := NormalGNS.bicommutant (stages size stage φ) + +lemma stage_mem (n : ℕ) (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ) : + φ (stage n a)∈algebra size stage φ := + NormalGNS.subset_bicommutant _ ((le_iSup (fun n => (φ.comp (stage n)).range) n) ⟨a,rfl⟩) + +def stageHom (n : ℕ) : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] algebra size stage φ := + (φ.comp (stage n)).codRestrict (algebra size stage φ).toStarSubalgebra (stage_mem size stage φ n) + +lemma representedStages_eq : NormalGNS.representedStages (algebra size stage φ) + (fun n => Fin (size n+1)) (stageHom size stage φ)=stages size stage φ := by + apply iSup_congr + intro n + rfl + +lemma in_represented (a : algebra size stage φ) : + (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer + (NormalGNS.representedStages (algebra size stage φ) (fun n => Fin (size n+1)) + (stageHom size stage φ) : Set (H →L[ℂ] H))) := by + rw [representedStages_eq] + exact (NormalGNS.mem_bicommutant _ _).mp a.property + +lemma le_vonNeumann (N : VonNeumannAlgebra H) + (hstage : ∀ n a,φ (stage n a)∈N) : algebra size stage φ≤N := by + have hle : stages size stage φ≤N.toStarSubalgebra := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + exact hstage n b + intro a ha + have hd := EquivariantBicommutant.bicommutant_mono hle ((NormalGNS.mem_bicommutant _ _).mp ha) + change a∈N.carrier + rw [←N.centralizer_centralizer'] + exact hd + +lemma in_range (hφ : Set.centralizer (Set.centralizer (Set.range φ))=Set.range φ) + (a : algebra size stage φ) : (a:H →L[ℂ] H)∈Set.range φ := by + have hle : stages size stage φ≤φ.range := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + exact ⟨stage n b,rfl⟩ + have hd := EquivariantBicommutant.bicommutant_mono hle ((NormalGNS.mem_bicommutant _ _).mp a.property) + rw [show (φ.range : Set (H →L[ℂ] H))=Set.range φ from rfl,hφ] at hd + exact hd + +lemma factor (hφ : Set.centralizer (Set.centralizer (Set.range φ))=Set.range φ) + (hinj : Function.Injective φ) + (hirr : ∀ b : A,(∀ n (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ), + stage n a*b=b*stage n a) → ∃ c : ℂ,b=algebraMap ℂ A c) : + FactorCorner.IsFactor (algebra size stage φ) := by + intro z hz hcentral + obtain ⟨b,hb⟩ := in_range size stage φ hφ ⟨z,hz⟩ + change φ b=z at hb + obtain ⟨c,hc⟩ := hirr b (by + intro n a + apply hinj + simp only [map_mul,hb] + exact hcentral _ (stage_mem size stage φ n a)) + refine ⟨c,?_⟩ + rw [←hb,hc,Algebra.algebraMap_eq_smul_one,map_smul,map_one] + +end Kadison.GeneratedMatrixBicommutant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/GramBounds.lean b/lean/OAI/Analysis/Commutator/GramBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..f823a42cb46e4ca9c43b944304fb44064cd39a2f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/GramBounds.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorGeneratedSpace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace CStarAlgebra + +namespace Kadison.CbFactor + +variable {H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma gram_boundedBelow (L : K →L[ℂ] H) (W : H →L[ℂ] K) + (hLW : L.comp W=1) {c : ℝ} (hc : 0≤c) (hW : ‖W‖≤c) (x : H) : + ‖x‖≤c^2*‖L (L.adjoint x)‖ := by + have hadj := congrArg ContinuousLinearMap.adjoint hLW + simp only [ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_one] at hadj + have he : W.adjoint (L.adjoint x)=x := congrArg (fun T : H →L[ℂ] H => T x) hadj + have hn : ‖x‖≤c*‖L.adjoint x‖ := by + calc + ‖x‖=‖W.adjoint (L.adjoint x)‖ := congrArg norm he.symm + _ ≤ c*‖L.adjoint x‖ := (W.adjoint.le_opNorm _).trans + (mul_le_mul_of_nonneg_right (by simpa using hW) (norm_nonneg _)) + have hi : ‖L.adjoint x‖^2=(inner ℂ x (L (L.adjoint x))).re := by + rw [←ContinuousLinearMap.adjoint_inner_left,inner_self_eq_norm_sq_to_K] + simp [←Complex.ofReal_pow] + have hh : (inner ℂ x (L (L.adjoint x))).re≤‖x‖*‖L (L.adjoint x)‖ := re_inner_le_norm (𝕜:=ℂ) _ _ + have hs := pow_le_pow_left₀ (norm_nonneg x) hn 2 + rw [mul_pow,hi] at hs + have hmul := mul_le_mul_of_nonneg_left hh (pow_nonneg hc 2) + by_cases hx : ‖x‖=0 + · rw [hx]; positivity + · have hx0 : 0<‖x‖ := lt_of_le_of_ne (norm_nonneg x) (Ne.symm hx) + nlinarith + +lemma gram_inverse_norm_le (L : K →L[ℂ] H) (W : H →L[ℂ] K) + (hLW : L.comp W=1) {c : ℝ} (hc : 0≤c) (hW : ‖W‖≤c) + (u : (H →L[ℂ] H)ˣ) (hu : (u : H →L[ℂ] H)=L.comp L.adjoint) : + ‖(↑(u⁻¹) : H →L[ℂ] H)‖≤c^2 := by + apply ContinuousLinearMap.opNorm_le_bound _ (sq_nonneg c) + intro x + have h := gram_boundedBelow L W hLW hc hW ((↑(u⁻¹) : H →L[ℂ] H) x) + have he : L (L.adjoint ((↑(u⁻¹) : H →L[ℂ] H) x))=x := by + change ((L.comp L.adjoint)*(↑(u⁻¹) : H →L[ℂ] H)) x=x + rw [←hu,Units.mul_inv] + rfl + simpa only [he] using h + +variable {A : Type*} [CStarAlgebra A] + +lemma leftCompression_norm_le (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (V W : H →L[ℂ] K) + (hV : ‖V‖≤1) : ‖leftCompression ρ V W‖≤1 := by + unfold leftCompression + refine (ContinuousLinearMap.opNorm_comp_le _ _).trans ?_ + have hp : ‖(generated ρ W).starProjection‖≤1 := Submodule.starProjection_norm_le _ + exact (mul_le_mul (by simpa using hV) hp (norm_nonneg _) zero_le_one).trans_eq (one_mul 1) + +end Kadison.CbFactor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HaarSequence.lean b/lean/OAI/Analysis/Commutator/HaarSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ed62d9fff079b305ce8fd3ceb60bf2570ccd59d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HaarSequence.lean @@ -0,0 +1,90 @@ +import Mathlib + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open UniformSpace Filter Topology + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +lemma orthonormal_inner_tendsto_zero (v : ℕ → H) (hv : Orthonormal ℂ v) (y : H) : + Tendsto (fun n => inner ℂ (v n) y) atTop (𝓝 0) := by + have hs := (hv.inner_products_summable (x := y)).tendsto_atTop_zero + have hn : Tendsto (fun n => ‖inner ℂ (v n) y‖) atTop (𝓝 0) := by + simpa only [Real.sqrt_sq (norm_nonneg _), Real.sqrt_zero] using hs.sqrt + exact tendsto_zero_iff_norm_tendsto_zero.mpr hn + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : τ 1=1) (z : unitary A) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma unitary_pow_gram_of_le {n m : ℕ} (hnm : n ≤ m) : + star ((z : A)^n)*(z : A)^m=(z : A)^(m-n) := by + have hm : m=n+(m-n) := by omega + rw [hm, pow_add, ←mul_assoc] + have hz : star ((z : A)^n)*(z : A)^n=1 := by + simpa only [SubmonoidClass.coe_pow] using Unitary.coe_star_mul_self (z^n) + rw [hz, one_mul] + congr 1 + omega + +include hτ in +lemma haar_pow_gram (hH : ∀ n : ℕ, 0 (τ.toPreGNS ((z : A)^n) : τ.GNS)) := by + rw [orthonormal_iff_ite] + intro n m + rw [Completion.inner_coe] + exact haar_pow_gram τ hτ z hH n m + +include hτ in +lemma haar_moments_tendsto_zero (hH : ∀ n : ℕ, 0 τ (star ((z : A)^n)*a)) atTop (𝓝 0) := by + have h := orthonormal_inner_tendsto_zero _ (haar_powers_orthonormal τ hτ z hH) + (τ.toPreGNS a : τ.GNS) + simpa only [Completion.inner_coe, PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS] using h + +lemma inverse_haar_moments (hH : ∀ n : ℕ, 0 τ ((z : A)^n*a)) atTop (𝓝 0) := by + have h := haar_moments_tendsto_zero τ hτ z⁻¹ (inverse_haar_moments τ z hH) a + have hz (n : ℕ) : star (((z⁻¹ : unitary A) : A)^n)=(z : A)^n := by + rw [star_pow] + congr 1 + exact star_star (z : A) + simpa only [hz] using h + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HankelAlgebra.lean b/lean/OAI/Analysis/Commutator/HankelAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..a90e6872e9093032659c4eb876a7d61df2e88fa5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HankelAlgebra.lean @@ -0,0 +1,848 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + +include h1 htr in +theorem free_of_different_endpoints + (hcyc : ∀ (a b : Letter S τ) (m : List (Letter S τ)), + Reduced (a :: m ++ [b]) → a.color≠b.color → τ (word (a :: m ++ [b]))=0) : + Free S τ := by + intro w + induction hn : w.length using Nat.strong_induction_on generalizing w with + | h n ih => + intro hw hne + cases w with + | nil => exact (hne rfl).elim + | cons a w => + cases w using List.reverseRecOn with + | nil => simpa using a.centered + | append_singleton m b => + by_cases hab : a.color=b.color + · have hmne : m≠[] := by + intro hm + subst m + exact hw.rel hab + have hm : Reduced m := hw.tail.left_of_append + have ham : Reduced (a::m) := + (show Reduced ((a::m)++[b]) from hw).left_of_append + let c : Letter S τ := { + color := a.color + val := b.val*a.val - τ (b.val*a.val) • 1 + mem := sub_mem (mul_mem (by simpa [hab] using b.mem) a.mem) + (SMulMemClass.smul_mem _ (one_mem _)) + centered := by simp [map_sub, map_smul, h1] } + have hc : Reduced (c::m) := by + apply ham.imp_head + intro z hz + exact hz + have hc0 : τ (word (c::m)) = 0 := + ih _ (by simp at hn ⊢; omega) (c::m) rfl hc (by simp) + have hm0 : τ (word m)=0 := ih _ (by simp at hn ⊢; omega) m rfl hm hmne + have heq : word (c::m) = b.val*a.val*word m - τ (b.val*a.val) • word m := by + simp [word_cons, c, sub_mul] + rw [heq, map_sub, map_smul, hm0, smul_zero, sub_zero] at hc0 + rw [word_cons, word_append, word_cons, word_nil, mul_one] + calc + τ (a.val * (word m*b.val)) = τ (b.val*(a.val*word m)) := by + rw [←mul_assoc, htr] + _ = 0 := by simpa only [mul_assoc] using hc0 + · exact hcyc a b m hw hab + +end Kadison.FreeMoments + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} + +omit [StarRing A] [StarModule ℂ A] in +lemma product_vanish_on_spans (B : ι → Set A) (colors : List ι) (φ : A →ₗ[ℂ] ℂ) + (h : ∀ v : List A, List.Forall₂ (fun i x => x ∈ B i) colors v → φ v.prod=0) : + ∀ v : List A, List.Forall₂ (fun i x => x ∈ Submodule.span ℂ (B i)) colors v → φ v.prod=0 := by + induction colors generalizing φ with + | nil => intro v hv; cases hv; exact h [] .nil + | cons i colors ih => + intro v hv + cases hv with + | cons hx hv => + rename_i x v + let ψ : A →ₗ[ℂ] ℂ := φ.comp (LinearMap.mulLeft ℂ x) + apply ih ψ ?_ v hv + intro w hw + change φ (x*w.prod)=0 + induction hx using Submodule.span_induction with + | mem x hx => exact h (x::w) (.cons hx hw) + | zero => simp + | add x y _ _ hx hy => simp only [add_mul, map_add, hx, hy, add_zero] + | smul c x _ hx => simp only [smul_mul_assoc, map_smul, hx, smul_zero] + +variable (S : ι → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +lemma letterList_of_values {colors : List ι} {v : List A} + (hv : List.Forall₂ (fun i x => x∈S i ∧ τ x=0) colors v) : + ∃ w : List (Letter S τ), w.map Letter.color=colors ∧ w.map Letter.val=v := by + induction hv with + | nil => exact ⟨[],rfl,rfl⟩ + | @cons i x colors v hx hv ih => + obtain ⟨w,hwc,hwv⟩ := ih + exact ⟨⟨i,x,hx.1,hx.2⟩::w, by simp [hwc], by simp [hwv]⟩ + +theorem free_of_spanning_alphabets (B : ι → Set A) + (hspan : ∀ i x, x∈S i → τ x=0 → x∈Submodule.span ℂ (B i)) + (hvan : ∀ (colors : List ι) (v : List A), + colors.IsChain (·≠·) → colors≠[] → + List.Forall₂ (fun i x => x∈B i) colors v → τ v.prod=0) : Free S τ := by + intro w hw hne + let colors := w.map Letter.color + have hchain : colors.IsChain (·≠·) := (List.isChain_map _).mpr hw + have hcne : colors≠[] := by simpa [colors] using hne + apply product_vanish_on_spans B colors τ (hvan colors · hchain hcne) (w.map Letter.val) + change List.Forall₂ (fun i x => x∈Submodule.span ℂ (B i)) (w.map Letter.color) (w.map Letter.val) + clear hw hne hchain hcne colors + induction w with + | nil => exact .nil + | cons a w ih => exact .cons (hspan a.color a.val a.mem a.centered) ih + +end Kadison.FreeMoments + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} {τ : A →ₗ[ℂ] ℂ} + +def paired (s : Letter S τ) (v : List (Letter S τ)) : List (Letter S τ) := + v.flatMap (fun a => [a,s]) + +@[simp] lemma paired_nil (s : Letter S τ) : paired s []=[] := rfl + +@[simp] lemma paired_cons (s a : Letter S τ) (v : List (Letter S τ)) : + paired s (a::v)=a::s::paired s v := rfl + +@[simp] lemma paired_append (s : Letter S τ) (v z : List (Letter S τ)) : + paired s (v++z)=paired s v++paired s z := by simp [paired] + +lemma paired_reduced (s : Letter S τ) (v : List (Letter S τ)) + (h : ∀ a∈v, a.color≠s.color) : Reduced (s::paired s v) := by + induction v with + | nil => exact List.IsChain.singleton _ + | cons a v ih => + apply List.isChain_cons_cons.mpr + refine ⟨(h a (by simp)).symm, ?_⟩ + apply List.isChain_cons_cons.mpr + exact ⟨h a (by simp), ih (fun b hb => h b (by simp [hb]))⟩ + +lemma paired_moment (hfree : Free S τ) (s : Letter S τ) (v : List (Letter S τ)) + (hne : v≠[]) (h : ∀ a∈v, a.color≠s.color) : τ (word (paired s v))=0 := by + apply hfree _ (paired_reduced s v h).tail + cases v with + | nil => exact (hne rfl).elim + | cons a v => simp + +@[simp] lemma word_paired_replicate (s d : Letter S τ) (n : ℕ) : + word (paired s (List.replicate n d))=(d.val*s.val)^n := by + induction n with + | zero => simp + | succ n ih => simp [List.replicate_succ, ih, pow_succ', mul_assoc] + +def dihedralBlocks (d : Letter S τ) (v : List (Letter S τ × ℕ)) : List (Letter S τ) := + v.flatMap (fun x => x.1 :: List.replicate x.2 d) + +lemma word_dihedralBlocks (s d : Letter S τ) (v : List (Letter S τ × ℕ)) : + word (paired s (dihedralBlocks d v)) = + (v.map (fun x => x.1.val*s.val*(d.val*s.val)^x.2)).prod := by + induction v with + | nil => simp [dihedralBlocks] + | cons x v ih => + simp only [dihedralBlocks, List.flatMap_cons, List.cons_append, paired_cons, + paired_append, word_cons, word_append, word_paired_replicate, + List.map_cons, List.prod_cons] at * + rw [ih] + simp only [mul_assoc] + +theorem dihedral_cyclic_moment (hfree : Free S τ) (s d : Letter S τ) + (hsd : d.color≠s.color) (v : List (Letter S τ × ℕ)) (hne : v≠[]) + (hcolor : ∀ x∈v, x.1.color≠s.color) + (hd : ∀ x∈v, x.1.val*d.val=x.1.val) : + τ ((v.map (fun x => x.1.val*(d.val*s.val)^(x.2+1))).prod)=0 := by + have hblocks : ∀ a∈dihedralBlocks d v, a.color≠s.color := by + intro a ha + obtain ⟨x,hx,ha⟩ := List.mem_flatMap.mp ha + simp only [List.mem_cons, List.mem_replicate] at ha + rcases ha with rfl | ⟨_,rfl⟩ + · exact hcolor x hx + · exact hsd + have hbne : dihedralBlocks d v≠[] := by + cases v with + | nil => exact (hne rfl).elim + | cons x v => simp [dihedralBlocks] + have hm := paired_moment hfree s (dihedralBlocks d v) hbne hblocks + rw [word_dihedralBlocks] at hm + convert hm using 2 + apply congrArg List.prod + apply List.map_congr_left + intro x hx + rw [pow_succ', ←mul_assoc, ←mul_assoc, hd x hx] + +end Kadison.FreeMoments + +namespace Kadison.CornerMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] + +variable (p : A) + +omit [Algebra ℂ A] in +lemma left_support_prod (v : List (A×A)) (hne : v≠[]) + (h : ∀ x∈v, p*x.1=x.1) : + p * (v.map (fun x => x.1*x.2)).prod = (v.map (fun x => x.1*x.2)).prod := by + cases v with + | nil => exact (hne rfl).elim + | cons x v => simp only [List.map_cons, List.prod_cons, ←mul_assoc, h x (by simp)] + +omit [Algebra ℂ A] in +lemma compressed_prod (v : List (A×A)) (hne : v≠[]) + (h : ∀ x∈v, p*x.1=x.1) : + (v.map (fun x => x.1*x.2*p)).prod = (v.map (fun x => x.1*x.2)).prod*p := by + induction v with + | nil => exact (hne rfl).elim + | cons x v ih => + by_cases hv : v=[] + · subst v; simp + · have ht : ∀ y∈v, p*y.1=y.1 := fun y hy => h y (by simp [hy]) + simp only [List.map_cons, List.prod_cons] + rw [ih hv ht] + simp only [mul_assoc] + rw [←mul_assoc p, left_support_prod p v hv ht] + +lemma traceremove (τ : A →ₗ[ℂ] ℂ) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (v : List (A×A)) (hne : v≠[]) (h : ∀ x∈v, p*x.1=x.1) : + τ ((v.map (fun x => x.1*x.2*p)).prod)=τ ((v.map (fun x => x.1*x.2)).prod) := by + rw [compressed_prod p v hne h, htr, left_support_prod p v hne h] + +end Kadison.CornerMoments + +namespace Kadison.DihedralCorner + +open scoped ComplexOrder + +variable {A : Type*} [CStarAlgebra A] + +variable (u d : unitary A) + +def wave (n : ℤ) : A := (u^n : unitary A) + +@[simp] lemma wave_zero : wave u 0=(1 : A) := by simp [wave] + +lemma wave_add (n m : ℤ) : wave u (n+m)=wave u n*wave u m := by + simp [wave, zpow_add] + +@[simp] lemma wave_star (n : ℤ) : star (wave u n)=wave u (-n) := by + rw [wave, wave, zpow_neg, ←Unitary.star_eq_inv, Unitary.coe_star] + +variable (hr : MulAut.conj d u=u⁻¹) + +include hr in +lemma reflection_wave (n : ℤ) : (d : A)*wave u n=wave u (-n)*(d : A) := by + have h : d*u^n=u^(-n)*d := by + calc + d*u^n = (MulAut.conj d (u^n))*d := by simp [MulAut.conj_apply, mul_assoc] + _ = (u⁻¹)^n*d := by rw [map_zpow, hr] + _ = u^(-n)*d := by simp + exact congrArg (fun z : unitary A => (z : A)) h + +variable {p : A} (hp : IsStarProjection p) + (hpform : p=(1/2 : ℂ) • (1+(d : A))) + +def cosine (n : ℤ) : Corner hp := + ⟨p*wave u n*p, by constructor <;> simp [mul_assoc, ←mul_assoc p p, hp.isIdempotentElem.eq]⟩ + +@[simp] lemma cosine_coe (n : ℤ) : ((cosine u hp n : Corner hp) : A)=p*wave u n*p := rfl + +@[simp] lemma cosine_zero : cosine u hp 0=1 := by + apply Subtype.ext + simp [hp.isIdempotentElem.eq] + +@[simp] lemma cosine_star (n : ℤ) : star (cosine u hp n)=cosine u hp (-n) := by + apply Subtype.ext + change star (p*wave u n*p)=p*wave u (-n)*p + simp only [star_mul, hp.isSelfAdjoint.star_eq, wave_star, mul_assoc] + +variable (hpd : p*(d : A)=p) (hdp : (d : A)*p=p) + +include hr hpd hdp in +lemma cosine_neg (n : ℤ) : cosine u hp (-n)=cosine u hp n := by + apply Subtype.ext + change p*wave u (-n)*p=p*wave u n*p + calc + p*wave u (-n)*p = p*wave u (-n)*((d : A)*p) := by rw [hdp] + _ = p*((d : A)*wave u n)*p := by rw [reflection_wave u d hr n]; noncomm_ring + _ = p*wave u n*p := by rw [←mul_assoc p, hpd] + +include hr hpform hdp in +lemma cosine_mul (n m : ℤ) : cosine u hp n*cosine u hp m = + (1/2 : ℂ) • (cosine u hp (n+m)+cosine u hp (n-m)) := by + apply Subtype.ext + change (p*wave u n*p)*(p*wave u m*p)= + (1/2 : ℂ) •(p*wave u (n+m)*p+p*wave u (n-m)*p) + calc + _ = p*wave u n*(p*p)*wave u m*p := by noncomm_ring + _ = p*wave u n*p*wave u m*p := by rw [hp.isIdempotentElem.eq] + _ = (1/2 : ℂ) •(p*wave u n*wave u m*p+p*wave u n*(d : A)*wave u m*p) := by + conv_lhs => arg 1; arg 1; arg 2; rw [hpform] + simp only [mul_smul_comm, smul_mul_assoc, mul_add, add_mul, mul_one, mul_assoc] + _ = (1/2 : ℂ) •(p*wave u (n+m)*p+p*wave u (n-m)*p) := by + rw [wave_add, sub_eq_add_neg, wave_add] + apply congrArg ((1/2 : ℂ) • ·) + apply congrArg₂ (·+·) + · noncomm_ring + · calc + p*wave u n*(d : A)*wave u m*p = p*wave u n*((d : A)*wave u m)*p := by noncomm_ring + _ = p*wave u n*(wave u (-m)*(d : A))*p := by rw [reflection_wave u d hr m] + _ = p*(wave u n*wave u (-m))*p := by + simp only [mul_assoc, hdp] + +end Kadison.DihedralCorner + +namespace Kadison.DihedralCorner + +open scoped ComplexOrder + +variable {A : Type*} [CStarAlgebra A] + +variable (u d : unitary A) (hr : MulAut.conj d u=u⁻¹) + +variable {p : A} (hp : IsStarProjection p) (hpform : p=(1/2 : ℂ) • (1+(d : A))) + (hpd : p*(d : A)=p) (hdp : (d : A)*p=p) + +def cosineSpace : Submodule ℂ (Corner hp) := Submodule.span ℂ (Set.range (cosine u hp)) + +lemma cosine_mem (n : ℤ) : cosine u hp n∈cosineSpace u hp := + Submodule.subset_span ⟨n,rfl⟩ + +include hr hpform hdp in +lemma cosineSpace_mul {a b : Corner hp} (ha : a∈cosineSpace u hp) (hb : b∈cosineSpace u hp) : + a*b∈cosineSpace u hp := by + induction ha using Submodule.span_induction with + | mem a ha => + obtain ⟨n,rfl⟩ := ha + induction hb using Submodule.span_induction with + | mem b hb => + obtain ⟨m,rfl⟩ := hb + rw [cosine_mul u d hr hp hpform hdp] + exact (cosineSpace u hp).smul_mem _ ((cosineSpace u hp).add_mem + (cosine_mem u hp _) (cosine_mem u hp _)) + | zero => simp + | add b c _ _ hb hc => simpa only [mul_add] using (cosineSpace u hp).add_mem hb hc + | smul z b _ hb => simpa only [mul_smul_comm] using (cosineSpace u hp).smul_mem z hb + | zero => simp + | add a c _ _ ha hc => simpa only [add_mul] using (cosineSpace u hp).add_mem ha hc + | smul z a _ ha => simpa only [smul_mul_assoc] using (cosineSpace u hp).smul_mem z ha + +lemma cosineSpace_star {a : Corner hp} (ha : a∈cosineSpace u hp) : star a∈cosineSpace u hp := by + induction ha using Submodule.span_induction with + | mem a ha => obtain ⟨n,rfl⟩ := ha; simpa using cosine_mem u hp (-n) + | zero => simp + | add a b _ _ ha hb => simpa only [star_add] using (cosineSpace u hp).add_mem ha hb + | smul z a _ ha => simpa only [star_smul] using (cosineSpace u hp).smul_mem (star z) ha + +def cosineAlgebra : StarSubalgebra ℂ (Corner hp) where + __ : Subalgebra ℂ (Corner hp) := + { __ := cosineSpace u hp + one_mem' := by simpa using cosine_mem u hp 0 + mul_mem' := cosineSpace_mul u d hr hp hpform hdp + algebraMap_mem' := fun z => by + change algebraMap ℂ (Corner hp) z∈cosineSpace u hp + simpa only [Algebra.algebraMap_eq_smul_one] using + (cosineSpace u hp).smul_mem z (by simpa using cosine_mem u hp 0) } + star_mem' := cosineSpace_star u hp + +def positiveCosines : Set (Corner hp) := Set.range (fun n : ℕ => cosine u hp (n+1)) + +include hr hpd hdp in +lemma cosine_nonzero_mem_positive {n : ℤ} (hn : n≠0) : + cosine u hp n∈Submodule.span ℂ (positiveCosines u hp) := by + by_cases hpos : 0 + obtain ⟨n,rfl⟩ := ha + by_cases hn : n=0 + · subst n; simp [hτ1] + · rw [hτ0 n hn, zero_smul, sub_zero] + exact cosine_nonzero_mem_positive u d hr hp hpd hdp hn + | zero => simp + | add a b _ _ ha hb => + simpa only [map_add, add_smul, add_sub_add_comm] using + (Submodule.span ℂ (positiveCosines u hp)).add_mem ha hb + | smul z a _ ha => + simpa only [map_smul, smul_eq_mul, mul_smul, smul_sub] using + (Submodule.span ℂ (positiveCosines u hp)).smul_mem z ha + +include hr hpform hpd hdp in +lemma centered_cosineAlgebra_span (τ : Corner hp →ₗ[ℂ] ℂ) (hτ1 : τ 1=1) + (hτ0 : ∀ n : ℤ, n≠0 → τ (cosine u hp n)=0) + {a : Corner hp} (ha : a∈cosineAlgebra u d hr hp hpform hdp) (ha0 : τ a=0) : + a∈Submodule.span ℂ (positiveCosines u hp) := by + simpa only [ha0, zero_smul, sub_zero] using + center_cosineSpace u d hr hp hpd hdp τ hτ1 hτ0 ha + +end Kadison.DihedralCorner + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} {τ : A →ₗ[ℂ] ℂ} + +lemma alternating_power_centered (hfree : Free S τ) (d s : Letter S τ) + (hds : d.color≠s.color) (n : ℕ) : τ ((d.val*s.val)^(n+1))=0 := by + have h := paired_moment hfree s (List.replicate (n+1) d) (by simp) + (by intro a ha; simpa only [List.mem_replicate] using (show a.color≠s.color from by + obtain ⟨_,rfl⟩ := List.mem_replicate.mp ha; exact hds)) + rwa [word_paired_replicate] at h + +lemma alternating_odd_centered (hfree : Free S τ) (d s : Letter S τ) + (hds : d.color≠s.color) (n : ℕ) : τ (s.val*(d.val*s.val)^n)=0 := by + have h := hfree (s::paired s (List.replicate n d)) + (paired_reduced s (List.replicate n d) (by + intro a ha; obtain ⟨_,rfl⟩ := List.mem_replicate.mp ha; exact hds)) (by simp) + rwa [word_cons, word_paired_replicate] at h + +end Kadison.FreeMoments + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} (τ : A →ₗ[ℂ] ℂ) + +variable (htr : ∀ a b : A, τ (a*b)=τ (b*a)) (hfree : Free S τ) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d : A)∈S i) (hs : (s : A)∈S j) + (hd0 : τ (d : A)=0) (hs0 : τ (s : A)=0) + +variable {p : A} (hp : IsStarProjection p) (hpform : p=(1/2 : ℂ) • (1+(d : A))) + (hd2 : (d : A)*(d : A)=1) + +include htr hfree hij hd hs hd0 hs0 hpform hd2 in +lemma cosine_positive_centered (n : ℕ) : τ ((cosine (d*s) hp (n+1) : Corner hp) : A)=0 := by + let D : Letter S τ := ⟨i,d,hd,hd0⟩ + let F : Letter S τ := ⟨j,s,hs,hs0⟩ + have hpow := alternating_power_centered hfree D F hij n + have hodd := alternating_odd_centered hfree D F hij n + change τ (((d : A)*(s : A))^(n+1))=0 at hpow + change τ ((s : A)*((d : A)*(s : A))^n)=0 at hodd + have hwave : wave (d*s) (n+1)=((d : A)*(s : A))^(n+1) := by + change (((d*s)^((n+1 : ℕ) : ℤ) : unitary A) : A)=_ + rw [zpow_natCast] + simp only [SubmonoidClass.coe_pow, Submonoid.coe_mul] + have hdw : (d : A)*wave (d*s) (n+1)=(s : A)*((d : A)*(s : A))^n := by + rw [hwave, pow_succ', ←mul_assoc, ←mul_assoc, hd2, one_mul] + change τ (p*wave (d*s) (n+1)*p)=0 + rw [htr, ←mul_assoc, hp.isIdempotentElem.eq, hpform] + rw [smul_mul_assoc, add_mul, one_mul, map_smul, map_add, hwave, hpow] + rw [←hwave, hdw, hodd] + simp + +end Kadison.DihedralCorner + +namespace Kadison + +variable {A : Type*} [CStarAlgebra A] {p : A} (hp : IsStarProjection p) + +def cornerFactor (D : StarSubalgebra ℂ A) (hpD : p∈D) : StarSubalgebra ℂ (Corner hp) where + carrier := {a | (a : A)∈D} + zero_mem' := zero_mem D + add_mem' := by + intro a b ha hb + change (a : A)+(b : A)∈D + exact add_mem ha hb + mul_mem' := by + intro a b ha hb + change (a : A)*(b : A)∈D + exact mul_mem ha hb + one_mem' := hpD + algebraMap_mem' c := by + change c • p∈D + exact D.smul_mem hpD c + star_mem' := by + intro a ha + change star (a : A)∈D + exact star_mem ha + +lemma corner_list_prod_coe (v : List (Corner hp)) (hne : v≠[]) : + ((v.prod : Corner hp) : A)=(v.map (fun a : Corner hp => (a : A))).prod := by + induction v with + | nil => exact (hne rfl).elim + | cons a v ih => + by_cases hv : v=[] + · subst v; simp + · simp only [List.prod_cons,List.map_cons,corner_mul] + exact congrArg ((a : A)*·) (ih hv) + +def halfCornerTrace (τ : A →ₗ[ℂ] ℂ) : Corner hp →ₗ[ℂ] ℂ := + (2 : ℂ) • τ.comp (cornerSubalgebra hp).toSubmodule.subtype + +@[simp] lemma halfCornerTrace_apply (τ : A →ₗ[ℂ] ℂ) (a : Corner hp) : + halfCornerTrace hp τ a=2*τ (a : A) := rfl + +lemma halfCornerTrace_tracial (τ : A →ₗ[ℂ] ℂ) + (htr : ∀ a b : A, τ (a*b)=τ (b*a)) (a b : Corner hp) : + halfCornerTrace hp τ (a*b)=halfCornerTrace hp τ (b*a) := by + simp only [halfCornerTrace_apply,corner_mul,htr] + +lemma halfCornerTrace_star (τ : A →ₗ[ℂ] ℂ) + (hstar : ∀ a : A, τ (star a)=star (τ a)) (a : Corner hp) : + halfCornerTrace hp τ (star a)=star (halfCornerTrace hp τ a) := by + simp only [halfCornerTrace_apply,corner_star,hstar,star_mul,star_ofNat] + exact mul_comm _ _ + +end Kadison + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} (τ : A →ₗ[ℂ] ℂ) + +variable (htr : ∀ a b : A, τ (a*b)=τ (b*a)) (hfree : Free S τ) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d : A)∈S i) (hs : (s : A)∈S j) + (hd0 : τ (d : A)=0) (hs0 : τ (s : A)=0) + +variable {p : A} (hp : IsStarProjection p) (hpd : p*(d : A)=p) + +include htr hfree hij hd hs hd0 hs0 hpd in +theorem corner_cosine_pair_moment (v : List (Corner hp × ℕ)) (hne : v≠[]) + (hD : ∀ x∈v, (x.1 : A)∈S i) + (h0 : ∀ x∈v, halfCornerTrace hp τ x.1=0) : + halfCornerTrace hp τ ((v.map (fun x => x.1*cosine (d*s) hp (x.2+1))).prod)=0 := by + let D : Letter S τ := ⟨i,d,hd,hd0⟩ + let F : Letter S τ := ⟨j,s,hs,hs0⟩ + have hc : ∀ x∈v, τ (x.1 : A)=0 := by + intro x hx + have h := h0 x hx + simpa only [halfCornerTrace_apply,mul_eq_zero,OfNat.ofNat_ne_zero,false_or] using h + let letters : List (Letter S τ × ℕ) := v.attach.map (fun x => + (⟨i,x.1.1,hD x.1 x.2,hc x.1 x.2⟩,x.1.2)) + have hletters : letters≠[] := by simp [letters,hne] + have hcolor : ∀ x∈letters, x.1.color≠F.color := by + intro x hx + obtain ⟨y,_,rfl⟩ := List.mem_map.mp hx + exact hij + have had : ∀ x∈letters, x.1.val*D.val=x.1.val := by + intro x hx + obtain ⟨y,_,rfl⟩ := List.mem_map.mp hx + change (y.1.1 : A)*(d : A)=(y.1.1 : A) + rw [←y.1.1.property.2, mul_assoc, hpd, y.1.1.property.2] + have hm := dihedral_cyclic_moment hfree F D hij letters hletters hcolor had + have hl : (letters.map (fun x => x.1.val*(D.val*F.val)^(x.2+1))).prod = + (v.map (fun x => (x.1 : A)*((d : A)*(s : A))^(x.2+1))).prod := by + exact (congrArg List.prod List.map_map).trans + (congrArg List.prod (List.attach_map_val + (f := fun x : Corner hp × ℕ => (x.1 : A)*((d : A)*(s : A))^(x.2+1)))) + rw [hl] at hm + have hprod : (((v.map (fun x => x.1*cosine (d*s) hp (x.2+1))).prod : Corner hp) : A) = + (v.map (fun x => ((x.1*cosine (d*s) hp (x.2+1) : Corner hp) : A))).prod := by + exact (corner_list_prod_coe hp _ (by simpa using hne)).trans + (congrArg List.prod List.map_map) + rw [halfCornerTrace_apply,hprod] + have hv : (v.map (fun x => ((x.1*cosine (d*s) hp (x.2+1) : Corner hp) : A))) = + v.map (fun x => (x.1 : A)*((d : A)*(s : A))^(x.2+1)*p) := by + apply List.map_congr_left + intro x hx + change (x.1 : A)*(p*wave (d*s) (x.2+1)*p)=_ + rw [←mul_assoc, ←mul_assoc, x.1.property.2] + have he : wave (d*s) (x.2+1)=((d : A)*(s : A))^(x.2+1) := by + change (((d*s)^((x.2+1 : ℕ) : ℤ) : unitary A) : A)=_ + rw [zpow_natCast] + simp only [SubmonoidClass.coe_pow,Submonoid.coe_mul] + rw [he] + change 2*τ ((v.map (fun x => ((x.1*cosine (d*s) hp (x.2+1) : Corner hp) : A))).prod)=0 + rw [hv] + have hr := CornerMoments.traceremove p τ htr + (v.map (fun x => ((x.1 : A),((d : A)*(s : A))^(x.2+1)))) + (by simpa using hne) (by + intro x hx; obtain ⟨y,_,rfl⟩ := List.mem_map.mp hx; exact y.1.property.1) + simp only [List.map_map,Function.comp_def] at hr + rw [hr,hm,mul_zero] + +end Kadison.DihedralCorner + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {S : Bool → StarSubalgebra ℂ A} {τ : A →ₗ[ℂ] ℂ} + +def flattenPairs (v : List (Letter S τ × Letter S τ)) : List (Letter S τ) := + v.flatMap (fun x => [x.1,x.2]) + +@[simp] lemma flattenPairs_nil : flattenPairs ([] : List (Letter S τ × Letter S τ))=[] := rfl + +@[simp] lemma flattenPairs_cons (x : Letter S τ × Letter S τ) (v) : + flattenPairs (x::v)=x.1::x.2::flattenPairs v := rfl + +lemma word_flattenPairs (v : List (Letter S τ × Letter S τ)) : + word (flattenPairs v)=(v.map (fun x => x.1.val*x.2.val)).prod := by + induction v with + | nil => rfl + | cons x v ih => simp only [flattenPairs_cons, word_cons, ih, List.map_cons, + List.prod_cons, mul_assoc] + +lemma flattenPairs_parse (a b : Letter S τ) (m : List (Letter S τ)) + (ha : a.color=false) (hb : b.color=true) (hw : Reduced (a::m++[b])) : + ∃ v : List (Letter S τ × Letter S τ), v≠[] ∧ + flattenPairs v=a::m++[b] ∧ ∀ x∈v, x.1.color=false ∧ x.2.color=true := by + induction hn : m.length using Nat.strong_induction_on generalizing a m with + | h n ih => + cases m with + | nil => exact ⟨[(a,b)],by simp,by rfl,by intro x hx; obtain rfl := List.mem_singleton.mp hx; exact ⟨ha,hb⟩⟩ + | cons c m => + have hc : c.color=true := by + have hac : a.color≠c.color := hw.rel + cases hcc : c.color <;> simp_all + cases m with + | nil => + have hcb : c.color≠b.color := hw.tail.rel + exact (hcb (hc.trans hb.symm)).elim + | cons d m => + have hd : d.color=false := by + have hcd : c.color≠d.color := hw.tail.rel + cases hdd : d.color <;> simp_all + obtain ⟨v,hv,hvw,hvc⟩ := ih m.length (by simp at hn; omega) d m hd hw.tail.tail rfl + refine ⟨(a,c)::v,by simp,?_,?_⟩ + · simp only [flattenPairs_cons, hvw, List.cons_append] + · intro x hx + rcases List.mem_cons.mp hx with rfl|hx + · exact ⟨ha,hc⟩ + · exact hvc x hx + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (hstar : ∀ a : A, τ (star a)=star (τ a)) + +include h1 htr hstar in +theorem free_bool_of_pair_moments + (hpair : ∀ v : List (Letter S τ × Letter S τ), v≠[] → + (∀ x∈v, x.1.color=false ∧ x.2.color=true) → + τ ((v.map (fun x => x.1.val*x.2.val)).prod)=0) : Free S τ := by + apply free_of_different_endpoints S τ h1 htr + intro a b m hw hab + have hdir : ∀ (a b : Letter S τ) (m : List (Letter S τ)), + a.color=false → b.color=true → Reduced (a::m++[b]) → τ (word (a::m++[b]))=0 := by + intro a b m ha hb hw + obtain ⟨v,hv,hvw,hvc⟩ := flattenPairs_parse a b m ha hb hw + rw [←hvw,word_flattenPairs] + exact hpair v hv hvc + cases ha : a.color with + | false => + have hb : b.color=true := by cases hb : b.color <;> simp_all + exact hdir a b m ha hb hw + | true => + have hb : b.color=false := by cases hb : b.color <;> simp_all + have heq : reverseStar hstar (a::m++[b]) = + b.conj hstar :: reverseStar hstar m ++ [a.conj hstar] := by + simp [reverseStar] + have hz := hdir (b.conj hstar) (a.conj hstar) (reverseStar hstar m) hb ha + (by rw [←heq]; exact hw.reverseStar hstar) + rw [←heq,word_reverseStar,hstar] at hz + exact star_eq_zero.mp hz + +omit [StarRing A] [StarModule ℂ A] in +lemma paired_vanish_on_spans (B : Set A) (a : List A) (φ : A →ₗ[ℂ] ℂ) + (h : ∀ b : List A, List.Forall₂ (fun _ x => x∈B) a b → + φ ((List.zipWith (·*·) a b).prod)=0) : + ∀ b : List A, List.Forall₂ (fun _ x => x∈Submodule.span ℂ B) a b → + φ ((List.zipWith (·*·) a b).prod)=0 := by + induction a generalizing φ with + | nil => intro b hb; cases hb; exact h [] .nil + | cons a as ih => + intro b hb + cases hb with + | cons hx hbs => + rename_i x xs + let ψ : A →ₗ[ℂ] ℂ := φ.comp (LinearMap.mulLeft ℂ (a*x)) + apply ih ψ ?_ xs hbs + intro ys hys + change φ ((a*x)*(List.zipWith (·*·) as ys).prod)=0 + induction hx using Submodule.span_induction with + | mem x hx => exact h (x::ys) (.cons hx hys) + | zero => simp + | add x y _ _ hx hy => simp only [mul_add, add_mul, map_add, hx,hy,add_zero] + | smul c x _ hx => simp only [mul_smul_comm,smul_mul_assoc,map_smul,hx,smul_zero] + +end Kadison.FreeMoments + +namespace Kadison.FreeMoments + +lemma pair_generators_witness {A I : Type*} (c : I → A) {a b : List A} + (hb : List.Forall₂ (fun _ x => x∈Set.range c) a b) : + ∃ v : List (A×I), v.map Prod.fst=a ∧ v.map (fun x => c x.2)=b := by + induction hb with + | nil => exact ⟨[],rfl,rfl⟩ + | @cons a b as bs hb hbs ih => + obtain ⟨i,rfl⟩ := hb + obtain ⟨v,rfl,rfl⟩ := ih + exact ⟨(a,i)::v,rfl,rfl⟩ + +lemma zipWith_same_maps {A B C E : Type*} (m : B → C → E) (f : A → B) (g : A → C) + (v : List A) : List.zipWith m (v.map f) (v.map g) = v.map (fun x => m (f x) (g x)) := by + induction v with + | nil => rfl + | cons a v ih => simp only [List.map_cons,List.zipWith_cons_cons,ih] + +variable {A : Type*} [Ring A] [Algebra ℂ A] + +lemma pairs_vanish_on_second_span {I : Type*} (F : Set A) (c : I → A) + (φ : A →ₗ[ℂ] ℂ) + (h : ∀ v : List (A×I), v≠[] → (∀ x∈v,x.1∈F) → + φ ((v.map (fun x => x.1*c x.2)).prod)=0) + (v : List (A×A)) (hne : v≠[]) + (hF : ∀ x∈v,x.1∈F) (hB : ∀ x∈v,x.2∈Submodule.span ℂ (Set.range c)) : + φ ((v.map (fun x => x.1*x.2)).prod)=0 := by + have hz := paired_vanish_on_spans (Set.range c) (v.map Prod.fst) φ (fun b hb => ?_) + (v.map Prod.snd) (by + rw [List.forall₂_map_left_iff,List.forall₂_map_right_iff,List.forall₂_same] + exact hB) + · simpa only [zipWith_same_maps] using hz + obtain ⟨w,hw,hwb⟩ := pair_generators_witness c hb + have hwne : w≠[] := by + intro he; simp only [he,List.map_nil] at hw + exact hne (List.map_eq_nil_iff.mp hw.symm) + have hwF : ∀ x∈w,x.1∈F := by + intro x hx + have hm : x.1∈v.map Prod.fst := hw ▸ List.mem_map_of_mem hx + obtain ⟨y,hy,hxy⟩ := List.mem_map.mp hm + exact hxy ▸ hF y hy + rw [←hw,←hwb,zipWith_same_maps] + exact h w hwne hwF + +end Kadison.FreeMoments + +namespace Kadison.DihedralCorner + +open FreeMoments + +variable {A : Type*} [CStarAlgebra A] + +variable {ι : Type*} {S : ι → StarSubalgebra ℂ A} (τ : A →ₗ[ℂ] ℂ) + +variable (h1 : τ 1=1) (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + (hstar : ∀ a : A, τ (star a)=star (τ a)) (hfree : Free S τ) + +variable (d s : unitary A) (i j : ι) (hij : i≠j) + +variable (hd : (d : A)∈S i) (hs : (s : A)∈S j) + (hd0 : τ (d : A)=0) (hs0 : τ (s : A)=0) + +variable (hr : MulAut.conj d (d*s)=(d*s)⁻¹) (hd2 : (d : A)*(d : A)=1) + +variable {p : A} (hp : IsStarProjection p) (hpform : p=(1/2 : ℂ) • (1+(d : A))) + (hpd : p*(d : A)=p) (hdp : (d : A)*p=p) + +include h1 hd0 hpform in +lemma halfCornerTrace_one : halfCornerTrace hp τ 1=1 := by + simp only [halfCornerTrace_apply,corner_one,hpform,map_smul,map_add,h1,hd0] + norm_num + +include htr hfree hij hd hs hd0 hs0 hr hd2 hpform hpd hdp in +lemma cosine_centered (n : ℤ) (hn : n≠0) : halfCornerTrace hp τ (cosine (d*s) hp n)=0 := by + have hpos (m : ℕ) : halfCornerTrace hp τ (cosine (d*s) hp (m+1))=0 := by + rw [halfCornerTrace_apply, + cosine_positive_centered τ htr hfree d s i j hij hd hs hd0 hs0 hp hpform hd2,mul_zero] + cases n with + | ofNat n => + cases n with + | zero => exact (hn rfl).elim + | succ m => exact hpos m + | negSucc m => + change halfCornerTrace hp τ (cosine (d*s) hp (-((m+1 : ℕ) : ℤ)))=0 + rw [cosine_neg (d*s) d hr hp hpd hdp] + exact hpos m + +def cornerPairFactors (hpD : p∈S i) : Bool → StarSubalgebra ℂ (Corner hp) := + fun b => if b then cosineAlgebra (d*s) d hr hp hpform hdp else cornerFactor hp (S i) hpD + +include h1 htr hstar hfree hij hd hs hd0 hs0 hd2 hpd in +theorem corner_cosine_free (hpD : p∈S i) : + Free (cornerPairFactors (S:=S) d s i hr hp hpform hdp hpD) (halfCornerTrace hp τ) := by + let R := cornerPairFactors (S:=S) d s i hr hp hpform hdp hpD + have hτ1 := halfCornerTrace_one τ h1 d hd0 hp hpform + have hτ0 := cosine_centered τ htr hfree d s i j hij hd hs hd0 hs0 hr hd2 hp hpform hpd hdp + apply free_bool_of_pair_moments (S := R) (τ := halfCornerTrace hp τ) hτ1 + (halfCornerTrace_tracial hp τ htr) (halfCornerTrace_star hp τ hstar) + intro v hv hcolor + let F : Set (Corner hp) := {a | (a : A)∈S i ∧ halfCornerTrace hp τ a=0} + have hD : ∀ x∈v, x.1.val∈F := by + intro x hx + have hm := x.1.mem + rw [(hcolor x hx).1] at hm + exact ⟨hm,x.1.centered⟩ + have hB : ∀ x∈v, x.2.val∈Submodule.span ℂ (positiveCosines (d*s) hp) := by + intro x hx + have hm := x.2.mem + rw [(hcolor x hx).2] at hm + exact centered_cosineAlgebra_span (d*s) d hr hp hpform hpd hdp + (halfCornerTrace hp τ) hτ1 hτ0 hm x.2.centered + have hz := pairs_vanish_on_second_span F (fun n : ℕ => cosine (d*s) hp (n+1)) + (halfCornerTrace hp τ) + (fun w hw hwF => corner_cosine_pair_moment τ htr hfree d s i j hij hd hs hd0 hs0 hp hpd + w hw (fun x hx => (hwF x hx).1) (fun x hx => (hwF x hx).2)) + (v.map (fun x => (x.1.val,x.2.val))) (by simpa using hv) (by + intro x hx; obtain ⟨y,hy,rfl⟩ := List.mem_map.mp hx; exact hD y hy) (by + intro x hx; obtain ⟨y,hy,rfl⟩ := List.mem_map.mp hx; exact hB y hy) + simpa only [List.map_map,Function.comp_def] using hz + +end Kadison.DihedralCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HermitianAlphabet.lean b/lean/OAI/Analysis/Commutator/HermitianAlphabet.lean new file mode 100644 index 0000000000000000000000000000000000000000..4bfd15d9d4cda99c7c011a2336037c905e188e4e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HermitianAlphabet.lean @@ -0,0 +1,79 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.MatrixAlphabet + +open Matrix + +variable {I : Type*} [Fintype I] [DecidableEq I] + +def letter (o i : I) : Matrix I I ℂ := single o i 1 + single i o 1 + +omit [Fintype I] in +@[simp] lemma star_letter (o i : I) : star (letter o i) = letter o i := by + simp only [letter, star_add, Matrix.star_eq_conjTranspose, Matrix.conjTranspose_single, + star_one, add_comm] + +lemma trace_letter (o i : I) (hi : i ≠ o) : (letter o i).trace = 0 := by + simp [letter, Matrix.trace_single_eq_of_ne _ _ _ hi, Matrix.trace_single_eq_of_ne _ _ _ hi.symm] + +lemma trace_mul_letter (o i j : I) (hi : i ≠ o) (hj : j ≠ o) : + (letter o i * letter o j).trace = if i = j then 2 else 0 := by + classical + simp only [letter, add_mul, mul_add, Matrix.trace_add] + rw [Matrix.single_mul_single_of_ne (1 : ℂ) o i o hi 1, + Matrix.single_mul_single_same, Matrix.single_mul_single_of_ne (1 : ℂ) i o j hj.symm 1] + simp only [Matrix.trace_zero, zero_add, one_mul] + by_cases h : i = j + · subst j + norm_num + · rw [Matrix.single_mul_single_of_ne (1 : ℂ) o i j h 1] + simp [h, Matrix.trace_single_eq_of_ne _ _ _ h] + +noncomputable def scale : ℂ := (Real.sqrt ((Fintype.card I : ℝ) / 2) : ℂ) + +omit [DecidableEq I] in +@[simp] lemma star_scale : star (scale (I := I)) = scale (I := I) := by + simp [scale] + +omit [DecidableEq I] in +lemma scale_sq : (scale (I := I)) ^ 2 = (Fintype.card I : ℂ) / 2 := by + rw [scale, ← Complex.ofReal_pow, Real.sq_sqrt (by positivity)] + push_cast + rfl + +noncomputable def normalizedLetter (o i : I) : Matrix I I ℂ := scale (I := I) • letter o i + +@[simp] lemma star_normalizedLetter (o i : I) : + star (normalizedLetter o i) = normalizedLetter o i := by + simp only [normalizedLetter, star_smul, star_scale, star_letter] + +lemma trace_normalizedLetter (o i : I) (hi : i ≠ o) : (normalizedLetter o i).trace = 0 := by + simp only [normalizedLetter, Matrix.trace_smul, trace_letter o i hi, smul_zero] + +lemma normalized_trace_mul [Nonempty I] (o i j : I) (hi : i ≠ o) (hj : j ≠ o) : + (Fintype.card I : ℂ)⁻¹ * (normalizedLetter o i * normalizedLetter o j).trace = + if i = j then 1 else 0 := by + have hm : (Fintype.card I : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr (Fintype.card_ne_zero) + rw [normalizedLetter, normalizedLetter, smul_mul_smul_comm, Matrix.trace_smul, + trace_mul_letter o i j hi hj] + simp only [smul_eq_mul, ← sq, scale_sq] + split_ifs <;> field_simp + norm_num + +end Kadison.MatrixAlphabet +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HermitianAlphabet2.lean b/lean/OAI/Analysis/Commutator/HermitianAlphabet2.lean new file mode 100644 index 0000000000000000000000000000000000000000..1275c1f01c154add040c7cae90bd4ba618592cf7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HermitianAlphabet2.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixGNS +import OAI.Analysis.Commutator.HermitianAlphabet + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open MatrixAlphabet + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) (h1 : τ 1 = 1) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +include hτ h1 in +lemma centered_normalizedLetter (o i : I) (hi : i ≠ o) : + (centeredStageVector τ φ (normalizedLetter o i) : τ.GNS) = + stageVector τ φ (normalizedLetter o i) := by + rw [stage_centered τ hτ h1, trace_normalizedLetter o i hi, mul_zero, zero_smul, sub_zero] + +include hτ h1 in +lemma normalizedLetter_orthonormal {J : Type*} (o : I) (b : J ↪ I) + (hb : ∀ j, b j ≠ o) : + Orthonormal ℂ (fun j => centeredStageVector τ φ (normalizedLetter o (b j))) := by + classical + apply orthonormal_iff_ite.mpr + intro i j + change inner ℂ (centeredStageVector τ φ (normalizedLetter o (b i)) : τ.GNS) + (centeredStageVector τ φ (normalizedLetter o (b j)) : τ.GNS) = _ + rw [centered_normalizedLetter τ hτ h1 φ o _ (hb i), + centered_normalizedLetter τ hτ h1 φ o _ (hb j), stage_inner τ hτ h1, + star_normalizedLetter, normalized_trace_mul o _ _ (hb i) (hb j)] + simp only [EmbeddingLike.apply_eq_iff_eq] + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertBiprod.lean b/lean/OAI/Analysis/Commutator/HilbertBiprod.lean new file mode 100644 index 0000000000000000000000000000000000000000..eb9d9fa4eaaced33ce9e15ad2f28a40577ff63c2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertBiprod.lean @@ -0,0 +1,137 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +namespace Kadison.HilbertBiprod + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + +abbrev Space (H G : Type*) := WithLp 2 (H × G) + +def inlL : H →L[ℂ] Space H G := + (WithLp.prodContinuousLinearEquiv 2 ℂ H G).symm.toContinuousLinearMap.comp + ((ContinuousLinearMap.id ℂ H).prod 0) + +def inrL : G →L[ℂ] Space H G := + (WithLp.prodContinuousLinearEquiv 2 ℂ H G).symm.toContinuousLinearMap.comp + ((0 : G →L[ℂ] H).prod (ContinuousLinearMap.id ℂ G)) + +@[simp] lemma inlL_apply (x : H) : inlL (G:=G) x=WithLp.toLp 2 (x,0) := rfl + +@[simp] lemma inrL_apply (y : G) : inrL (H:=H) y=WithLp.toLp 2 (0,y) := rfl + +def inl : H →ₗᵢ[ℂ] Space H G := + (inlL (H:=H) (G:=G)).toLinearMap.isometryOfInner (by + intro x y + simp [WithLp.prod_inner_apply]) + +def inr : G →ₗᵢ[ℂ] Space H G := + (inrL (H:=H) (G:=G)).toLinearMap.isometryOfInner (by + intro x y + simp [WithLp.prod_inner_apply]) + +@[simp] lemma inl_apply (x : H) : inl (G:=G) x=WithLp.toLp 2 (x,0) := rfl + +@[simp] lemma inr_apply (y : G) : inr (H:=H) y=WithLp.toLp 2 (0,y) := rfl + +def block (S : H →L[ℂ] H) (T : G →L[ℂ] G) : Space H G →L[ℂ] Space H G := + (WithLp.prodContinuousLinearEquiv 2 ℂ H G).symm.toContinuousLinearMap.comp + ((S.prodMap T).comp (WithLp.prodContinuousLinearEquiv 2 ℂ H G).toContinuousLinearMap) + +@[simp] lemma block_apply (S : H →L[ℂ] H) (T : G →L[ℂ] G) (x : Space H G) : + block S T x=WithLp.toLp 2 (S x.ofLp.1,T x.ofLp.2) := rfl + +lemma ext {S T : Space H G →L[ℂ] Space H G} + (h : ∀ x,(S x).ofLp=(T x).ofLp) : S=T := by + ext x + exact WithLp.ofLp_injective 2 (h x) + +@[simp] lemma block_zero : block (0:H →L[ℂ] H) (0:G →L[ℂ] G)=0 := by + apply ext + intro x + rfl + +@[simp] lemma block_one : block (1:H →L[ℂ] H) (1:G →L[ℂ] G)=1 := by + apply ext + intro x + rfl + +lemma block_mul (S S' : H →L[ℂ] H) (T T' : G →L[ℂ] G) : + block (S*S') (T*T')=block S T*block S' T' := by + apply ext + intro x + rfl + +lemma block_add (S S' : H →L[ℂ] H) (T T' : G →L[ℂ] G) : + block (S+S') (T+T')=block S T+block S' T' := by + apply ext + intro x + rfl + +lemma block_smul (z : ℂ) (S : H →L[ℂ] H) (T : G →L[ℂ] G) : + block (z • S) (z • T)=z • block S T := by + apply ext + intro x + rfl + +variable [CompleteSpace H] [CompleteSpace G] + +lemma block_star (S : H →L[ℂ] H) (T : G →L[ℂ] G) : + block (star S) (star T)=star (block S T) := by + apply ContinuousLinearMap.ext + intro x + apply ext_inner_right ℂ + intro y + simp only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left, + block_apply,WithLp.prod_inner_apply] + +variable {A : Type*} [CStarAlgebra A] + +def diagHom (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) : + A →⋆ₐ[ℂ] (Space H G →L[ℂ] Space H G) where + toFun a := block (φ a) (ψ a) + map_one' := by simp + map_mul' a b := by simp only [map_mul,block_mul] + map_zero' := by simp + map_add' a b := by simp only [map_add,block_add] + commutes' z := by + simp only [Algebra.algebraMap_eq_smul_one, map_smul, map_one, block_smul, block_one] + map_star' a := by simp only [map_star,block_star] + +@[simp] lemma diagHom_apply (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + (a : A) : diagHom φ ψ a=block (φ a) (ψ a) := rfl + +omit [CompleteSpace H] [CompleteSpace G] in +lemma block_inl (S : H →L[ℂ] H) (T : G →L[ℂ] G) (x : H) : + block S T (inl x)=inl (S x) := by simp + +omit [CompleteSpace H] [CompleteSpace G] in +lemma block_inr (S : H →L[ℂ] H) (T : G →L[ℂ] G) (y : G) : + block S T (inr y)=inr (T y) := by simp + +lemma diagHom_injective (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + (hφ : Function.Injective φ) : Function.Injective (diagHom φ ψ) := by + intro a b hab + apply hφ + apply ContinuousLinearMap.ext + intro x + have h := congrArg (fun U : Space H G →L[ℂ] Space H G => (U (inl x)).ofLp.1) hab + simpa using h + +end Kadison.HilbertBiprod + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertBiprodProjections.lean b/lean/OAI/Analysis/Commutator/HilbertBiprodProjections.lean new file mode 100644 index 0000000000000000000000000000000000000000..6cabda3444417d54e4a7ca1905f91aa9d70a56e7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertBiprodProjections.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertBiprod + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.HilbertBiprod + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +abbrev left : Space H G →L[ℂ] Space H G := block 1 0 + +abbrev right : Space H G →L[ℂ] Space H G := block 0 1 + +lemma left_projection : IsStarProjection (left (H:=H) (G:=G)) := by + constructor + · change block 1 0*block 1 0=block 1 0 + rw [←block_mul,one_mul,zero_mul] + · change star (block (1:H →L[ℂ] H) (0:G →L[ℂ] G))=block 1 0 + rw [←block_star,star_one,star_zero] + +lemma right_projection : IsStarProjection (right (H:=H) (G:=G)) := by + constructor + · change block 0 1*block 0 1=block 0 1 + rw [←block_mul,one_mul,zero_mul] + · change star (block (0:H →L[ℂ] H) (1:G →L[ℂ] G))=block 0 1 + rw [←block_star,star_one,star_zero] + +omit [CompleteSpace H] [CompleteSpace G] in +lemma left_add_right : left (H:=H) (G:=G)+right=1 := by + rw [left,right,←block_add] + simp + +omit [CompleteSpace H] [CompleteSpace G] in +lemma left_mul_right : left (H:=H) (G:=G)*right=0 := by + rw [left,right,←block_mul] + simp + +omit [CompleteSpace H] [CompleteSpace G] in +lemma left_commutes (S : H →L[ℂ] H) (T : G →L[ℂ] G) : + block S T*left=left*block S T := by + rw [left,←block_mul,←block_mul] + simp + +omit [CompleteSpace H] [CompleteSpace G] in +lemma right_commutes (S : H →L[ℂ] H) (T : G →L[ℂ] G) : + block S T*right=right*block S T := by + rw [right,←block_mul,←block_mul] + simp + +lemma adjoint_inlL : (inlL (H:=H) (G:=G)).adjoint=WithLp.fstL 2 ℂ H G := by + ext x + apply ext_inner_right ℂ + intro y + simp only [ContinuousLinearMap.adjoint_inner_left,inlL_apply,WithLp.prod_inner_apply, + inner_zero_right,add_zero] + rfl + +lemma adjoint_inrL : (inrL (H:=H) (G:=G)).adjoint=WithLp.sndL 2 ℂ H G := by + ext x + apply ext_inner_right ℂ + intro y + simp only [ContinuousLinearMap.adjoint_inner_left,inrL_apply,WithLp.prod_inner_apply, + inner_zero_right,zero_add] + rfl + +lemma inl_adjoint : (inlL (H:=H) (G:=G)).comp inlL.adjoint=left := by + rw [adjoint_inlL] + apply ext + intro x + rfl + +lemma inr_adjoint : (inrL (H:=H) (G:=G)).comp inrL.adjoint=right := by + rw [adjoint_inrL] + apply ext + intro x + rfl + +omit [CompleteSpace H] [CompleteSpace G] in +lemma right_ne_zero [Nontrivial G] : right (H:=H) (G:=G)≠0 := by + obtain ⟨x,hx⟩ := exists_ne (0:G) + intro hz + apply hx + have he := congrArg (fun T : Space H G →L[ℂ] Space H G => (T (inr x)).ofLp.2) hz + change x=0 at he + exact he + +end Kadison.HilbertBiprod + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertBlocks.lean b/lean/OAI/Analysis/Commutator/HilbertBlocks.lean new file mode 100644 index 0000000000000000000000000000000000000000..854d2f759a1b1726e2e3dd1cb09cfddd450e5dc0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertBlocks.lean @@ -0,0 +1,122 @@ +import Mathlib + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace Topology + +open ContinuousLinearMap + +namespace Kadison.HilbertSum + +variable {ι : Type*} [DecidableEq ι] (E : ι → Type*) + [∀ i, NormedAddCommGroup (E i)] [∀ i, InnerProductSpace ℂ (E i)] + [∀ i, CompleteSpace (E i)] + +abbrev space := lp E 2 + +def insert (i : ι) : E i →L[ℂ] space E := lp.singleContinuousLinearMap ℂ E 2 i + +def project (i : ι) : space E →L[ℂ] E i := lp.evalCLM ℂ E 2 i + +omit [∀ i, CompleteSpace (E i)] in +@[simp] lemma insert_apply (i : ι) (x : E i) : insert E i x = lp.single 2 i x := rfl + +omit [DecidableEq ι] [∀ i, CompleteSpace (E i)] in +@[simp] lemma project_apply (i : ι) (x : space E) : project E i x = x i := rfl + +omit [∀ i, CompleteSpace (E i)] in +@[simp] lemma inner_insert (i : ι) (x : E i) (y : space E) : + inner ℂ (insert E i x) y = inner ℂ x (project E i y) := lp.inner_single_left _ _ _ + +@[simp] lemma adjoint_insert (i : ι) : (insert E i).adjoint = project E i := by + ext x + apply ext_inner_left ℂ + intro y + simp only [adjoint_inner_right, inner_insert] + +@[simp] lemma adjoint_project (i : ι) : (project E i).adjoint = insert E i := by + rw [← adjoint_insert, adjoint_adjoint] + +omit [∀ i, CompleteSpace (E i)] in +@[simp] lemma norm_insert_apply (i : ι) (x : E i) : ‖insert E i x‖ = ‖x‖ := + lp.norm_single (by norm_num) _ _ + +omit [DecidableEq ι] [∀ i, CompleteSpace (E i)] in +lemma norm_project_apply_le (i : ι) (x : space E) : ‖project E i x‖ ≤ ‖x‖ := + lp.norm_apply_le_norm (by norm_num) x i + +omit [∀ i, CompleteSpace (E i)] in +@[simp] lemma project_insert (i : ι) : (project E i).comp (insert E i) = 1 := by + ext x + simp only [comp_apply, project_apply, insert_apply, lp.single_apply, Pi.single_eq_same, + one_apply_eq_self] + +omit [∀ i, CompleteSpace (E i)] in +lemma project_insert_ne {i j : ι} (h : i ≠ j) : (project E i).comp (insert E j) = 0 := by + ext x + simp only [comp_apply, project_apply, insert_apply, lp.single_apply, Pi.single_eq_of_ne h, + zero_apply] + +def block (T : space E →L[ℂ] space E) (i j : ι) : E j →L[ℂ] E i := + ((project E i).comp T).comp (insert E j) + +omit [∀ i, CompleteSpace (E i)] in +@[simp] lemma block_apply (T : space E →L[ℂ] space E) (i j : ι) (x : E j) : + block E T i j x = (T (insert E j x)) i := rfl + +lemma norm_block_le (T : space E →L[ℂ] space E) (i j : ι) : ‖block E T i j‖ ≤ ‖T‖ := by + apply opNorm_le_bound _ (norm_nonneg _) + intro x + exact (norm_project_apply_le E i (T (insert E j x))).trans + ((le_opNorm T (insert E j x)).trans_eq (by rw [norm_insert_apply])) + +@[simp] lemma block_adjoint (T : space E →L[ℂ] space E) (i j : ι) : + block E T.adjoint i j = (block E T j i).adjoint := by + simp only [block, adjoint_comp, adjoint_project, adjoint_insert, comp_assoc] + +omit [∀ i, CompleteSpace (E i)] in +lemma reduces_of_offdiagonal (T : space E →L[ℂ] space E) + (h : ∀ i j, i ≠ j → block E T i j = 0) (j : ι) : + T.comp (insert E j) = (insert E j).comp (block E T j j) := by + ext x i + by_cases hij : i = j + · subst i + simp only [comp_apply, insert_apply, lp.single_apply, Pi.single_eq_same, block_apply] + · have ht := congrArg (fun R : E j →L[ℂ] E i => R x) (h i j hij) + simpa only [block_apply, zero_apply, comp_apply, insert_apply, lp.single_apply, + Pi.single_eq_of_ne hij] using ht + +lemma adjoint_reduces_of_offdiagonal (T : space E →L[ℂ] space E) + (h : ∀ i j, i ≠ j → block E T i j = 0) (j : ι) : + T.adjoint.comp (insert E j) = (insert E j).comp (block E T j j).adjoint := by + rw [← block_adjoint] + apply reduces_of_offdiagonal + intro i k hik + rw [block_adjoint, h k i hik.symm, map_zero] + +omit [∀ i, CompleteSpace (E i)] in +lemma block_covariant (T L R : space E →L[ℂ] space E) + (l r : ∀ i, E i →L[ℂ] E i) + (h : T.comp L = R.comp T) + (hL : ∀ j, L.comp (insert E j) = (insert E j).comp (l j)) + (hR : ∀ i, (project E i).comp R = (r i).comp (project E i)) + (i j : ι) : (block E T i j).comp (l j) = (r i).comp (block E T i j) := by + simp only [block, comp_assoc] + rw [← hL, ← comp_assoc T, h, comp_assoc R, ← comp_assoc (project E i), hR, comp_assoc] + +lemma project_covariant_of_adjoint (L : space E →L[ℂ] space E) + (l : ∀ i, E i →L[ℂ] E i) + (h : ∀ i, L.adjoint.comp (insert E i) = (insert E i).comp (l i).adjoint) (i : ι) : + (project E i).comp L = (l i).comp (project E i) := by + have hi := congrArg (ContinuousLinearMap.adjoint) (h i) + simpa only [adjoint_comp, adjoint_insert, adjoint_adjoint] using hi + +end Kadison.HilbertSum +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertDiagonal.lean b/lean/OAI/Analysis/Commutator/HilbertDiagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..71ea00d2715b4f626fd9d7dd461abd517af04daf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertDiagonal.lean @@ -0,0 +1,96 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace +open scoped InnerProductSpace ENNReal +open ContinuousLinearMap +open scoped InnerProductSpace ENNReal + +namespace Kadison.HilbertDiagonal + +variable {ι : Type*} (E : ι → Type*) + [∀ i, NormedAddCommGroup (E i)] [∀ i, InnerProductSpace ℂ (E i)] + +def onLp (V : ∀ i, E i →ₗᵢ[ℂ] E i) : lp E 2 →ₗᵢ[ℂ] lp E 2 where + toFun x := ⟨fun i => V i (x i), (lp.memℓp x).mono' (fun i => le_of_eq ((V i).norm_map _))⟩ + map_add' _ _ := by ext i; exact (V i).map_add _ _ + map_smul' _ _ := by ext i; exact (V i).map_smul _ _ + norm_map' x := by + simp only [lp.norm_eq_tsum_rpow (by norm_num : (0 : ℝ) < (2 : ℝ≥0∞).toReal)] + congr 2 + funext i + exact congrArg (fun a : ℝ => a ^ (2 : ℝ≥0∞).toReal) ((V i).norm_map (x i)) + +@[simp] lemma onLp_apply (V : ∀ i, E i →ₗᵢ[ℂ] E i) (x : lp E 2) (i : ι) : + onLp E V x i=V i (x i) := rfl + +@[simp] lemma onLp_single [DecidableEq ι] (V : ∀ i, E i →ₗᵢ[ℂ] E i) (i : ι) (x : E i) : + onLp E V (lp.single 2 i x)=lp.single 2 i (V i x) := by + ext j + by_cases hji : j=i + · subst j + simp only [onLp_apply,lp.single_apply,Pi.single_eq_same] + · simp only [onLp_apply,lp.single_apply,Pi.single_eq_of_ne hji,map_zero] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (U : ∀ i, E i →ₗᵢ[ℂ] H) (hU : IsHilbertSum ℂ E U) + +def onSum (V : ∀ i, E i →ₗᵢ[ℂ] E i) : H →ₗᵢ[ℂ] H := + hU.linearIsometryEquiv.symm.toLinearIsometry.comp + ((onLp E V).comp hU.linearIsometryEquiv.toLinearIsometry) + +@[simp] lemma onSum_insert (V : ∀ i, E i →ₗᵢ[ℂ] E i) (i : ι) (x : E i) : + onSum E U hU V (U i x)=U i (V i x) := by + classical + have he : hU.linearIsometryEquiv (U i x)=lp.single 2 i x := by + rw [←hU.linearIsometryEquiv_symm_apply_single x,LinearIsometryEquiv.apply_symm_apply] + change hU.linearIsometryEquiv.symm (onLp E V (hU.linearIsometryEquiv (U i x))) = _ + rw [he,onLp_single,hU.linearIsometryEquiv_symm_apply_single] + +lemma onSum_comp (V : ∀ i, E i →ₗᵢ[ℂ] E i) (i : ι) : + (onSum E U hU V).toContinuousLinearMap.comp (U i).toContinuousLinearMap = + (U i).toContinuousLinearMap.comp (V i).toContinuousLinearMap := by + ext x + exact onSum_insert E U hU V i x + +lemma onSum_one : onSum E U hU (fun _ => LinearIsometry.id)=LinearIsometry.id := by + ext x + change hU.linearIsometryEquiv.symm (onLp E (fun _ => LinearIsometry.id) + (hU.linearIsometryEquiv x))=x + have he : onLp E (fun _ => LinearIsometry.id) (hU.linearIsometryEquiv x)=hU.linearIsometryEquiv x := by + ext i + rfl + rw [he,LinearIsometryEquiv.symm_apply_apply] + +lemma onSum_mul (V W : ∀ i, E i →ₗᵢ[ℂ] E i) : + (onSum E U hU V).comp (onSum E U hU W)= + onSum E U hU (fun i => (V i).comp (W i)) := by + ext x + change hU.linearIsometryEquiv.symm (onLp E V (hU.linearIsometryEquiv + (hU.linearIsometryEquiv.symm (onLp E W (hU.linearIsometryEquiv x))))) = _ + rw [LinearIsometryEquiv.apply_symm_apply] + apply congrArg hU.linearIsometryEquiv.symm + ext i + rfl + +end Kadison.HilbertDiagonal +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertFiniteMaps.lean b/lean/OAI/Analysis/Commutator/HilbertFiniteMaps.lean new file mode 100644 index 0000000000000000000000000000000000000000..43e40f2e9f636e07775de801659e6d8e4912d00e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertFiniteMaps.lean @@ -0,0 +1,85 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology + +namespace Kadison.HilbertFiniteMaps + +variable {H G K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (ι : Type*) [Fintype ι] + +abbrev Copies (H ι : Type*) := PiLp 2 (fun _ : ι => H) + +def column (T : ι → H →L[ℂ] G) : H →L[ℂ] Copies G ι := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => G)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi T) + +omit [CompleteSpace H] [CompleteSpace G] [Fintype ι] in +@[simp] lemma column_apply (T : ι → H →L[ℂ] G) (x : H) (i : ι) : column ι T x i=T i x := rfl + +lemma adjoint_column_apply (T : ι → H →L[ℂ] G) (y : Copies G ι) : + (column ι T).adjoint y=∑ i,(T i).adjoint (y i) := by + apply ext_inner_right ℂ + intro x + simp only [ContinuousLinearMap.adjoint_inner_left,PiLp.inner_apply,column_apply,sum_inner] + +lemma adjoint_column_comp (T : ι → H →L[ℂ] G) : + (column ι T).adjoint.comp (column ι T)=∑ i,(T i).adjoint.comp (T i) := by + ext x + simp only [ContinuousLinearMap.comp_apply,adjoint_column_apply,column_apply,sum_apply] + +lemma column_norm_le_one (T : ι → H →L[ℂ] G) + (hT : ‖∑ i,(T i).adjoint.comp (T i)‖≤1) : ‖column ι T‖≤1 := by + rw [←adjoint_column_comp,ContinuousLinearMap.norm_adjoint_comp_self] at hT + nlinarith [norm_nonneg (column ι T)] + +def amplify (T : H →L[ℂ] G) : Copies H ι →L[ℂ] Copies G ι := + column ι (fun i => T.comp (PiLp.proj 2 (fun _ : ι => H) i)) + +omit [CompleteSpace H] [CompleteSpace G] in +@[simp] lemma amplify_apply (T : H →L[ℂ] G) (x : Copies H ι) (i : ι) : + amplify ι T x i=T (x i) := rfl + +omit [CompleteSpace H] [CompleteSpace G] in +lemma amplify_norm_le (T : H →L[ℂ] G) : ‖amplify ι T‖≤‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + have hs : ‖amplify ι T x‖^2≤(‖T‖*‖x‖)^2 := by + rw [PiLp.norm_sq_eq_of_L2,mul_pow,PiLp.norm_sq_eq_of_L2,Finset.mul_sum] + exact Finset.sum_le_sum (fun i _ => by + rw [amplify_apply,←mul_pow] + exact pow_le_pow_left₀ (norm_nonneg _) (T.le_opNorm (x i)) 2) + exact (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg T) (norm_nonneg x))).mp hs + +omit [CompleteSpace H] [CompleteSpace G] [CompleteSpace K] in +lemma amplify_comp (T : H →L[ℂ] G) (U : G →L[ℂ] K) : + amplify ι (U.comp T)=(amplify ι U).comp (amplify ι T) := by ext x i; rfl + +lemma amplify_adjoint (T : H →L[ℂ] G) : amplify ι T.adjoint=(amplify ι T).adjoint := by + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [PiLp.inner_apply,amplify_apply,ContinuousLinearMap.adjoint_inner_left] + +omit [CompleteSpace H] [CompleteSpace G] in +lemma amplify_sub (T U : H →L[ℂ] G) : amplify ι (T-U)=amplify ι T-amplify ι U := by + ext x i + rfl + +end Kadison.HilbertFiniteMaps + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertMatrixCorner.lean b/lean/OAI/Analysis/Commutator/HilbertMatrixCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ca6dc1aa4c635b46b5dbb8571226a58912b1189 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertMatrixCorner.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.ChoiGNS +import OAI.Analysis.Commutator.MatrixEntryWOT + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace CStarAlgebra + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {ι : Type} [Fintype ι] + +local instance hilbertMatrixCornerDecidableEq : DecidableEq ι := Classical.decEq ι + +lemma single_adjoint (i : ι) : (single (H:=H) ι i).adjoint=PiLp.proj 2 (fun _ : ι => H) i := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp [PiLp.inner_apply,apply_ite] + +omit [CompleteSpace H] in +lemma norm_single_le_one (i : ι) : ‖single (H:=H) ι i‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro x + simp [norm_single_eq] + +lemma representation_corner (X : CStarMatrix ι ι (H →L[ℂ] H)) (i j : ι) : + (single ι i).adjoint.comp + ((CyclicColumns.matrixRepresentation (StarAlgHom.id ℂ (H →L[ℂ] H)) X).comp + (single ι j))=X i j := by + rw [single_adjoint] + ext x + simp [CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply,apply_ite] + +end Kadison.OperatorAmplification + +namespace Kadison.ChoiGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable {ι : Type} [Fintype ι] + +local instance choiMatrixCornerDecidableEq : DecidableEq ι := Classical.decEq ι + +omit [PartialOrder A] [StarOrderedRing A] in +lemma entry_one_projection (i : ι) : IsStarProjection (entry i i (1 : A)) := by + refine ⟨?_,?_⟩ + · exact by simp [IsIdempotentElem,entry_mul] + · exact by simp [IsSelfAdjoint] + +lemma norm_entry_one_le_one (i j : ι) : ‖entry i j (1 : A)‖≤1 := by + have hn := (entry_one_projection (A:=A) j).norm_le + have he : star (entry i j (1:A))*entry i j 1=entry j j 1 := by simp [entry_mul] + rw [←he,CStarRing.norm_star_mul_self] at hn + nlinarith [norm_nonneg (entry i j (1:A))] + +end Kadison.ChoiGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertModuleExtension.lean b/lean/OAI/Analysis/Commutator/HilbertModuleExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..54390896742ac95327dc4cb896fbddfd435b213d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertModuleExtension.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry15 + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ENNReal + +open ContinuousLinearMap + +namespace Kadison.HilbertModuleExtension + +variable {ι E F K H : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (V : ι → E →ₗᵢ[ℂ] K) (W : ι → F →ₗᵢ[ℂ] H) + (hV : IsHilbertSum ℂ (fun _ : ι => E) V) (hW : IsHilbertSum ℂ (fun _ : ι => F) W) + +def extend (T : E →L[ℂ] F) : K →L[ℂ] H := + hW.linearIsometryEquiv.symm.toLinearIsometry.toContinuousLinearMap.comp + ((lp.mapCLM 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl)).comp + hV.linearIsometryEquiv.toLinearIsometry.toContinuousLinearMap) + +omit [CompleteSpace E] [CompleteSpace F] in +lemma extend_norm_le (T : E →L[ℂ] F) : ‖extend V W hV hW T‖ ≤ ‖T‖ := by + apply opNorm_le_bound _ (norm_nonneg _) + intro x + change ‖hW.linearIsometryEquiv.symm + (lp.mapCLM 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl) + (hV.linearIsometryEquiv x))‖ ≤ _ + rw [LinearIsometryEquiv.norm_map] + exact ((lp.mapCLM 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl)).le_of_opNorm_le + (lp.norm_mapCLM_le 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl)) _).trans_eq + (by rw [LinearIsometryEquiv.norm_map]) + +omit [CompleteSpace E] [CompleteSpace F] in +@[simp] lemma extend_insert (T : E →L[ℂ] F) (i : ι) (x : E) : + extend V W hV hW T (V i x)=W i (T x) := by + classical + change hW.linearIsometryEquiv.symm + (lp.mapCLM 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl) + (hV.linearIsometryEquiv (V i x))) = _ + rw [←hV.linearIsometryEquiv_symm_apply_single x,LinearIsometryEquiv.apply_symm_apply] + have h : lp.mapCLM 2 (fun _ : ι => T) (norm_nonneg T) (fun _ => le_rfl) + (lp.single 2 i x)=lp.single 2 i (T x) := by + ext j + by_cases hji : j=i + · subst j; simp + · simp [lp.single_apply,Pi.single_eq_of_ne hji] + rw [h,hW.linearIsometryEquiv_symm_apply_single] + +omit [CompleteSpace E] [CompleteSpace F] in +lemma extend_sub (T R : E →L[ℂ] F) : + extend V W hV hW (T-R)=extend V W hV hW T-extend V W hV hW R := by + apply ActualHilbertSum.map_ext (fun _ : ι => E) V hV + intro i + ext x + simp only [comp_apply,ActualHilbertSum.insert,LinearIsometry.coe_toContinuousLinearMap, + extend_insert,sub_apply,map_sub] + +include hV hW in +omit [CompleteSpace E] [CompleteSpace F] in +lemma eq_extend (G : K →L[ℂ] H) (T : E →L[ℂ] F) + (h : ∀ i x, G (V i x)=W i (T x)) : G=extend V W hV hW T := by + apply ActualHilbertSum.map_ext (fun _ : ι => E) V hV + intro i + ext x + exact (h i x).trans (extend_insert V W hV hW T i x).symm + +include hV hW in +omit [CompleteSpace E] [CompleteSpace F] in +lemma norm_sub_extend_le (G : K →L[ℂ] H) (T R : E →L[ℂ] F) + (h : ∀ i x, G (V i x)=W i (R x)) : + ‖G-extend V W hV hW T‖ ≤ ‖R-T‖ := by + rw [eq_extend V W hV hW G R h,←extend_sub] + exact extend_norm_le V W hV hW (R-T) + +lemma project_extend (T : E →L[ℂ] F) (i : ι) (x : K) : + ActualHilbertSum.project (fun _ : ι => F) W i (extend V W hV hW T x) = + T (ActualHilbertSum.project (fun _ : ι => E) V i x) := by + rw [ActualHilbertSum.project_coordinates _ W hW,ActualHilbertSum.project_coordinates _ V hV] + change (hW.linearIsometryEquiv (hW.linearIsometryEquiv.symm _)) i = _ + rw [LinearIsometryEquiv.apply_symm_apply] + rfl + +lemma extend_intertwines (T : E →L[ℂ] F) (a : K →L[ℂ] K) (b : H →L[ℂ] H) + (h : ∀ i j x, + T (ActualHilbertSum.project (fun _ : ι => E) V i (a (V j x))) = + ActualHilbertSum.project (fun _ : ι => F) W i (b (W j (T x)))) : + (extend V W hV hW T).comp a=b.comp (extend V W hV hW T) := by + apply ActualHilbertSum.map_ext (fun _ : ι => E) V hV + intro j + ext x + apply ActualHilbertSum.ext_vectors (fun _ : ι => F) W hW + intro i + change ActualHilbertSum.project _ W i (extend V W hV hW T (a (V j x))) = + ActualHilbertSum.project _ W i (b (extend V W hV hW T (V j x))) + rw [project_extend,extend_insert] + exact h i j x + +end Kadison.HilbertModuleExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertModuleSchroederBernstein.lean b/lean/OAI/Analysis/Commutator/HilbertModuleSchroederBernstein.lean new file mode 100644 index 0000000000000000000000000000000000000000..778d49a399ae5536540e55b83e87778eb1b942f3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertModuleSchroederBernstein.lean @@ -0,0 +1,205 @@ +import Mathlib +import OAI.Analysis.Commutator.BiprodLinkColumn +import OAI.Analysis.Commutator.ProjectionSchroederBernstein + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.HilbertModuleSB + +open HilbertBiprod PartialIsometryOrder + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable {A : Type*} [CStarAlgebra A] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + +def intertwinerAlgebra : VonNeumannAlgebra (Space H G) where + toStarSubalgebra := StarSubalgebra.centralizer ℂ ((diagHom φ ψ).range : Set _) + centralizer_centralizer' := by + change Set.centralizer (Set.centralizer (Set.centralizer + (((diagHom φ ψ).range : Set (Space H G →L[ℂ] Space H G)) ∪ star ((diagHom φ ψ).range : Set (Space H G →L[ℂ] Space H G))))) = _ + exact Set.centralizer_centralizer_centralizer _ + +lemma mem_intertwinerAlgebra (T : Space H G →L[ℂ] Space H G) : + T∈intertwinerAlgebra φ ψ ↔ ∀ a,block (φ a) (ψ a)*T=T*block (φ a) (ψ a) := by + change T∈StarSubalgebra.centralizer ℂ ((diagHom φ ψ).range : Set _) ↔ _ + rw [←SetLike.mem_coe,StarSubalgebra.coe_centralizer,StarMemClass.star_coe_eq,Set.union_self] + constructor + · intro h a; exact h _ ⟨a,rfl⟩ + · rintro h _ ⟨a,rfl⟩; exact h a + +lemma left_mem : left (H:=H) (G:=G) ∈ intertwinerAlgebra φ ψ := + (mem_intertwinerAlgebra φ ψ _).mpr (fun scalar => left_commutes (φ scalar) (ψ scalar)) + +lemma right_mem : right (H:=H) (G:=G) ∈ intertwinerAlgebra φ ψ := + (mem_intertwinerAlgebra φ ψ _).mpr (fun scalar => right_commutes (φ scalar) (ψ scalar)) + +def offDiagonal (V : H →ₗᵢ[ℂ] G) : Space H G →L[ℂ] Space H G := + inrL.comp (V.toContinuousLinearMap.comp inlL.adjoint) + +lemma offDiagonal_apply (V : H →ₗᵢ[ℂ] G) (x : Space H G) : + offDiagonal V x=WithLp.toLp 2 (0,V x.ofLp.1) := by + simp only [offDiagonal,ContinuousLinearMap.comp_apply,adjoint_inlL,inrL_apply] + rfl + +lemma offDiagonal_initial (V : H →ₗᵢ[ℂ] G) : + star (offDiagonal V)*offDiagonal V=left := by + change (offDiagonal V).adjoint.comp (offDiagonal V)=left + simp only [offDiagonal,ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_adjoint] + have hr : (inrL (H:=H) (G:=G)).adjoint.comp inrL=1 := + (inr (H:=H) (G:=G)).adjoint_comp_self + have hv := V.adjoint_comp_self + simp only [ContinuousLinearMap.comp_assoc] at * + rw [←ContinuousLinearMap.comp_assoc (inrL (H:=H) (G:=G)).adjoint (inrL (H:=H) (G:=G)),hr] + simp only [ContinuousLinearMap.one_def,ContinuousLinearMap.id_comp] + rw [←ContinuousLinearMap.comp_assoc V.toContinuousLinearMap.adjoint V.toContinuousLinearMap (inlL (H:=H) (G:=G)).adjoint,hv] + simp only [ContinuousLinearMap.one_def,ContinuousLinearMap.id_comp,inl_adjoint] + +lemma offDiagonal_right (V : H →ₗᵢ[ℂ] G) : right*offDiagonal V=offDiagonal V := by + ext x + simp only [mul_apply_eq_comp,offDiagonal_apply,block_apply] + rfl + +lemma offDiagonal_left (V : H →ₗᵢ[ℂ] G) : offDiagonal V*left=offDiagonal V := by + ext x + simp only [mul_apply_eq_comp,offDiagonal_apply,block_apply] + rfl + +lemma offDiagonal_mem (V : H →ₗᵢ[ℂ] G) + (hV : ∀ a x,V (φ a x)=ψ a (V x)) : offDiagonal V∈intertwinerAlgebra φ ψ := by + apply (mem_intertwinerAlgebra φ ψ _).mpr + intro a + ext x + simp only [mul_apply_eq_comp,offDiagonal_apply,block_apply,map_zero] + rw [hV] + +lemma subEquivalent_of_embedding (V : H →ₗᵢ[ℂ] G) + (hV : ∀ a x,V (φ a x)=ψ a (V x)) : + SubEquivalent (intertwinerAlgebra φ ψ) left right := by + let v := offDiagonal V + have hi : star v*v=left := offDiagonal_initial V + have ht : v*star v*v=v := by rw [mul_assoc,hi]; exact offDiagonal_left V + have hp : IsStarProjection (v*star v) := ⟨by change (v*star v)*(v*star v)=v*star v; rw [←mul_assoc,ht],by simp⟩ + have hle : v*star v≤right := (hp.le_iff_mul_eq_right right_projection).mpr (by + rw [←mul_assoc,offDiagonal_right]) + exact ⟨⟨v,offDiagonal_mem φ ψ V hV,ht,hi.le,hle⟩,hi⟩ + +def offDiagonalReverse (V : G →ₗᵢ[ℂ] H) : Space H G →L[ℂ] Space H G := + inlL.comp (V.toContinuousLinearMap.comp inrL.adjoint) + +lemma offDiagonalReverse_apply (V : G →ₗᵢ[ℂ] H) (x : Space H G) : + offDiagonalReverse V x=WithLp.toLp 2 (V x.ofLp.2,0) := by + simp only [offDiagonalReverse,ContinuousLinearMap.comp_apply,adjoint_inrL,inlL_apply] + rfl + +lemma offDiagonalReverse_initial (V : G →ₗᵢ[ℂ] H) : + star (offDiagonalReverse V)*offDiagonalReverse V=right := by + change (offDiagonalReverse V).adjoint.comp (offDiagonalReverse V)=right + simp only [offDiagonalReverse,ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_adjoint] + have hr : (inlL (H:=H) (G:=G)).adjoint.comp inlL=1 := + (inl (H:=H) (G:=G)).adjoint_comp_self + have hv := V.adjoint_comp_self + simp only [ContinuousLinearMap.comp_assoc] at * + rw [←ContinuousLinearMap.comp_assoc (inlL (H:=H) (G:=G)).adjoint (inlL (H:=H) (G:=G)),hr] + simp only [ContinuousLinearMap.one_def,ContinuousLinearMap.id_comp] + rw [←ContinuousLinearMap.comp_assoc V.toContinuousLinearMap.adjoint V.toContinuousLinearMap (inrL (H:=H) (G:=G)).adjoint,hv] + simp only [ContinuousLinearMap.one_def,ContinuousLinearMap.id_comp,inr_adjoint] + +lemma offDiagonalReverse_left (V : G →ₗᵢ[ℂ] H) : left*offDiagonalReverse V=offDiagonalReverse V := by + ext x + simp only [mul_apply_eq_comp,offDiagonalReverse_apply,block_apply] + rfl + +lemma offDiagonalReverse_right (V : G →ₗᵢ[ℂ] H) : offDiagonalReverse V*right=offDiagonalReverse V := by + ext x + simp only [mul_apply_eq_comp,offDiagonalReverse_apply,block_apply] + rfl + +lemma offDiagonalReverse_mem (V : G →ₗᵢ[ℂ] H) + (hV : ∀ a x,V (ψ a x)=φ a (V x)) : offDiagonalReverse V∈intertwinerAlgebra φ ψ := by + apply (mem_intertwinerAlgebra φ ψ _).mpr + intro a + ext x + simp only [mul_apply_eq_comp,offDiagonalReverse_apply,block_apply,map_zero] + rw [hV] + +lemma subEquivalent_of_reverse_embedding (V : G →ₗᵢ[ℂ] H) + (hV : ∀ a x,V (ψ a x)=φ a (V x)) : + SubEquivalent (intertwinerAlgebra φ ψ) right left := by + let v := offDiagonalReverse V + have hi : star v*v=right := offDiagonalReverse_initial V + have ht : v*star v*v=v := by rw [mul_assoc,hi]; exact offDiagonalReverse_right V + have hp : IsStarProjection (v*star v) := ⟨by change (v*star v)*(v*star v)=v*star v; rw [←mul_assoc,ht],by simp⟩ + have hle : v*star v≤left := (hp.le_iff_mul_eq_right left_projection).mpr (by + rw [←mul_assoc,offDiagonalReverse_left]) + exact ⟨⟨v,offDiagonalReverse_mem φ ψ V hV,ht,hi.le,hle⟩,hi⟩ + +lemma link_component_isometry (N : VonNeumannAlgebra (Space H G)) + (v : Link N left right) (hi : v.initial=left) : + Isometry (BiprodLinkColumn.component N v.adjoint) := by + apply (ContinuousLinearMap.isometry_iff_adjoint_comp_self _).mpr + rw [BiprodLinkColumn.component_square,Link.adjoint_final,hi] + have hl : (left (H:=H) (G:=G)).comp inlL=inlL := by ext x; rfl + rw [hl] + exact (inl (H:=H) (G:=G)).adjoint_comp_self + +lemma link_component_coisometry (N : VonNeumannAlgebra (Space H G)) + (v : Link N left right) (hf : v.final=right) : + (BiprodLinkColumn.component N v.adjoint).comp + (BiprodLinkColumn.component N v.adjoint).adjoint=1 := by + have hl : v.val.comp (left (H:=H) (G:=G))=v.val := v.mul_source left_projection + have hf' : v.val.comp v.val.adjoint=right := hf + have hr : (right (H:=H) (G:=G)).comp inrL=inrL := by ext x; rfl + have hs : v.adjoint.val.adjoint=v.val := by + change (star v.val).adjoint=v.val + simp only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_adjoint] + rw [BiprodLinkColumn.component_adjoint,BiprodLinkColumn.component,hs] + change (inrL.adjoint.comp (v.val.comp inlL)).comp + (inlL.adjoint.comp (v.val.adjoint.comp inrL)) = 1 + calc + _=inrL.adjoint.comp ((v.val.comp left).comp (v.val.adjoint.comp inrL)) := by + simp only [←inl_adjoint,ContinuousLinearMap.comp_assoc] + _=inrL.adjoint.comp ((v.val.comp v.val.adjoint).comp inrL) := by + rw [hl,ContinuousLinearMap.comp_assoc] + _=1 := by rw [hf',hr]; exact (inr (H:=H) (G:=G)).adjoint_comp_self + +theorem exists_unitary_of_embeddings + (V : H →ₗᵢ[ℂ] G) (W : G →ₗᵢ[ℂ] H) + (hV : ∀ a x,V (φ a x)=ψ a (V x)) + (hW : ∀ a x,W (ψ a x)=φ a (W x)) : + ∃ U : H ≃ₗᵢ[ℂ] G, ∀ a x,U (φ a x)=ψ a (U x) := by + let N := intertwinerAlgebra φ ψ + obtain ⟨v,hi,hf⟩ := subEquivalent_antisymm N (left_mem φ ψ) left_projection right_projection + (subEquivalent_of_embedding φ ψ V hV) (subEquivalent_of_reverse_embedding φ ψ W hW) + let T := BiprodLinkColumn.component N v.adjoint + let F : H →ₗᵢ[ℂ] G := ⟨T.toLinearMap, + (AddMonoidHomClass.isometry_iff_norm T).mp (link_component_isometry N v hi)⟩ + have hsur : Function.Surjective F := by + intro y + refine ⟨T.adjoint y,?_⟩ + exact congrArg (fun R : G →L[ℂ] G => R y) (link_component_coisometry N v hf) + refine ⟨LinearIsometryEquiv.ofSurjective F hsur,?_⟩ + intro a x + have hc : block (φ a) (ψ a)*star v.adjoint.val=star v.adjoint.val*block (φ a) (ψ a) := by + simpa only [Link.adjoint,star_star] using (mem_intertwinerAlgebra φ ψ v.val).mp v.mem a + exact congrArg (fun R : H →L[ℂ] G => R x) + (BiprodLinkColumn.component_intertwines N φ ψ v.adjoint a hc) + +end Kadison.HilbertModuleSB + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertPadding.lean b/lean/OAI/Analysis/Commutator/HilbertPadding.lean new file mode 100644 index 0000000000000000000000000000000000000000..1d89765d1d31d4fb02b710a04dbc45984defe351 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertPadding.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.IsometryCompression +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.HilbertPadding + +variable {H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def extend (E : H →ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : K →L[ℂ] K := + (E.toContinuousLinearMap.comp T).comp E.toContinuousLinearMap.adjoint + +lemma norm_extend_le (E : H →ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : ‖extend E T‖ ≤ ‖T‖ := by + have he : ‖E.toContinuousLinearMap‖ ≤ 1 := E.norm_toContinuousLinearMap_le + have he' : ‖E.toContinuousLinearMap.adjoint‖ ≤ 1 := by rw [adjoint.norm_map]; exact he + calc + _ ≤ ‖E.toContinuousLinearMap‖*‖T‖*‖E.toContinuousLinearMap.adjoint‖ := + (opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_right (opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ 1*‖T‖*1 := mul_le_mul (mul_le_mul_of_nonneg_right he (norm_nonneg _)) + he' (norm_nonneg _) (by positivity) + _ = ‖T‖ := by ring + +lemma compress_extend (E : H →ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : + FreeCorner.compress E (extend E T)=T := by + ext x + change E.toContinuousLinearMap.adjoint (E (T (E.toContinuousLinearMap.adjoint (E x))))=T x + simp only [FreeCorner.isometry_adjoint_apply] + +lemma norm_extend (E : H →ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : ‖extend E T‖=‖T‖ := by + apply le_antisymm (norm_extend_le E T) + simpa only [compress_extend] using FreeCorner.norm_compress_le E (extend E T) + +lemma extend_commutator (E : H →ₗᵢ[ℂ] K) (T a : H →L[ℂ] H) (b : K →L[ℂ] K) + (hl : b.comp E.toContinuousLinearMap=E.toContinuousLinearMap.comp a) + (hr : E.toContinuousLinearMap.adjoint.comp b=a.comp E.toContinuousLinearMap.adjoint) : + extend E T*b-b*extend E T=extend E (T*a-a*T) := by + simp only [extend,mul_def,comp_sub,sub_comp,comp_assoc] + rw [hr,←comp_assoc b,hl] + simp only [comp_assoc] + +lemma norm_extend_commutator (E : H →ₗᵢ[ℂ] K) (T a : H →L[ℂ] H) (b : K →L[ℂ] K) + (hl : b.comp E.toContinuousLinearMap=E.toContinuousLinearMap.comp a) + (hr : E.toContinuousLinearMap.adjoint.comp b=a.comp E.toContinuousLinearMap.adjoint) : + ‖extend E T*b-b*extend E T‖=‖T*a-a*T‖ := by + rw [extend_commutator E T a b hl hr,norm_extend] + +open OperatorAmplification + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +def leftCopies : SumSpace (H:=H) ι →ₗᵢ[ℂ] SumSpace (H:=H) (ι⊕κ) where + toFun v := WithLp.toLp 2 (Sum.elim (fun i => v i) (fun _ => 0)) + map_add' v w := by ext i; cases i <;> simp + map_smul' z v := by ext i; cases i <;> simp + norm_map' v := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + simp [PiLp.norm_sq_eq_of_L2, Fintype.sum_sum_type] + +omit [CompleteSpace H] in +@[simp] lemma leftCopies_inl (v : SumSpace (H:=H) ι) (i : ι) : + leftCopies ι κ v (Sum.inl i)=v i := rfl + +omit [CompleteSpace H] in +@[simp] lemma leftCopies_inr (v : SumSpace (H:=H) ι) (k : κ) : + leftCopies ι κ v (Sum.inr k)=0 := rfl + +local instance : DecidableEq ι := Classical.decEq ι + +local instance : DecidableEq κ := Classical.decEq κ + +lemma leftCopies_diagonal (a : H →L[ℂ] H) : + (diagonal (H:=H) (ι⊕κ) a).comp (leftCopies (H:=H) ι κ).toContinuousLinearMap= + (leftCopies (H:=H) ι κ).toContinuousLinearMap.comp (diagonal (H:=H) ι a) := by + ext v i + cases i <;> simp + +lemma adjoint_leftCopies_diagonal (a : H →L[ℂ] H) : + (leftCopies (H:=H) ι κ).toContinuousLinearMap.adjoint.comp (diagonal (H:=H) (ι⊕κ) a)= + (diagonal (H:=H) ι a).comp (leftCopies (H:=H) ι κ).toContinuousLinearMap.adjoint := by + have h := congrArg (fun T => T.adjoint) (leftCopies_diagonal ι κ (star a)) + simpa only [adjoint_comp, ←star_eq_adjoint, ←map_star, star_star] using h + +theorem copy_padding_commutator_norm + (Y : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (a : H →L[ℂ] H) : + ‖extend (leftCopies ι κ) Y*diagonal (H:=H) (ι⊕κ) a- + diagonal (H:=H) (ι⊕κ) a*extend (leftCopies ι κ) Y‖= + ‖Y*diagonal (H:=H) ι a-diagonal (H:=H) ι a*Y‖ := + norm_extend_commutator _ _ _ _ (leftCopies_diagonal ι κ a) (adjoint_leftCopies_diagonal ι κ a) + +end Kadison.HilbertPadding + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertPair.lean b/lean/OAI/Analysis/Commutator/HilbertPair.lean new file mode 100644 index 0000000000000000000000000000000000000000..31048191b6c96576946fb5992c369bf147a6f7f5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertPair.lean @@ -0,0 +1,89 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.HilbertPair + +variable (F K : Type*) [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +abbrev Space := WithLp 2 (F × K) + +def left : F →ₗᵢ[ℂ] Space F K where + toFun x := WithLp.toLp 2 (x,0) + map_add' x y := by + apply (WithLp.equiv 2 (F × K)).injective + simp + map_smul' z x := by + apply (WithLp.equiv 2 (F × K)).injective + simp + norm_map' x := WithLp.norm_toLp_fst 2 F K x + +def right : K →ₗᵢ[ℂ] Space F K where + toFun x := WithLp.toLp 2 (0,x) + map_add' x y := by + apply (WithLp.equiv 2 (F × K)).injective + simp + map_smul' z x := by + apply (WithLp.equiv 2 (F × K)).injective + simp + norm_map' x := WithLp.norm_toLp_snd 2 F K x + +omit [CompleteSpace F] [CompleteSpace K] in +@[simp] lemma left_apply (x : F) : left F K x=WithLp.toLp 2 (x,0) := rfl + +omit [CompleteSpace F] [CompleteSpace K] in +@[simp] lemma right_apply (x : K) : right F K x=WithLp.toLp 2 (0,x) := rfl + +lemma left_adjoint : (left F K).toContinuousLinearMap.adjoint=WithLp.fstL 2 ℂ F K := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp [WithLp.prod_inner_apply] + +lemma right_adjoint : (right F K).toContinuousLinearMap.adjoint=WithLp.sndL 2 ℂ F K := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp [WithLp.prod_inner_apply] + +@[simp] lemma left_adjoint_left : + (left F K).toContinuousLinearMap.adjoint.comp (left F K).toContinuousLinearMap=1 := by + rw [left_adjoint] + ext x + rfl + +@[simp] lemma right_adjoint_right : + (right F K).toContinuousLinearMap.adjoint.comp (right F K).toContinuousLinearMap=1 := by + rw [right_adjoint] + ext x + rfl + +@[simp] lemma left_adjoint_right : + (left F K).toContinuousLinearMap.adjoint.comp (right F K).toContinuousLinearMap=0 := by + rw [left_adjoint] + ext x + rfl + +@[simp] lemma right_adjoint_left : + (right F K).toContinuousLinearMap.adjoint.comp (left F K).toContinuousLinearMap=0 := by + rw [right_adjoint] + ext x + rfl + +end Kadison.HilbertPair + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertSequence.lean b/lean/OAI/Analysis/Commutator/HilbertSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..d76038676d6c5b5ae80388b9e96b9bab20e89499 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertSequence.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Commutator.ScalarUltralimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter UniformSpace Completion + +namespace Kadison.HilbertSequence + +variable (ω : Ultrafilter ℕ) (H : Type*) [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +structure Pre (ω : Ultrafilter ℕ) (H : Type*) [NormedAddCommGroup H] where + seq : ℕ →ᵇ H + +def equiv : Pre ω H ≃ (ℕ →ᵇ H) where + toFun := Pre.seq + invFun := Pre.mk + left_inv := fun _ => rfl + right_inv := fun _ => rfl + +instance : AddCommGroup (Pre ω H) := (equiv ω H).addCommGroup + +instance : Module ℂ (Pre ω H) := (equiv ω H).addEquiv.module ℂ + +omit [InnerProductSpace ℂ H] in +@[simp] lemma seq_add (x y : Pre ω H) (i : ℕ) : (x+y).seq i=x.seq i+y.seq i := rfl + +@[simp] lemma seq_smul (r : ℂ) (x : Pre ω H) (i : ℕ) : (r • x).seq i=r • x.seq i := rfl + +omit [InnerProductSpace ℂ H] in +@[simp] lemma seq_zero (i : ℕ) : (0 : Pre ω H).seq i=0 := rfl + +lemma inner_bounded (x y : Pre ω H) : ∃ C : ℝ, ∀ i, + ‖inner ℂ (x.seq i) (y.seq i)‖≤C := by + refine ⟨‖x.seq‖*‖y.seq‖,fun i => ?_⟩ + exact (norm_inner_le_norm _ _).trans (mul_le_mul (x.seq.norm_coe_le_norm i) + (y.seq.norm_coe_le_norm i) (norm_nonneg _) (norm_nonneg _)) + +def form (x y : Pre ω H) : ℂ := + ScalarUltralimit.limit ω (fun i => inner ℂ (x.seq i) (y.seq i)) (inner_bounded ω H x y) + +lemma tendsto_form (x y : Pre ω H) : + Tendsto (fun i => inner ℂ (x.seq i) (y.seq i)) (ω : Filter ℕ) (𝓝 (form ω H x y)) := + ScalarUltralimit.tendsto_limit ω _ _ + +instance core : PreInnerProductSpace.Core ℂ (Pre ω H) where + inner := form ω H + conj_inner_symm x y := by + apply tendsto_nhds_unique _ (tendsto_form ω H x y) + simpa only [RCLike.star_def,inner_conj_symm] using (tendsto_form ω H y x).star + re_inner_nonneg x := by + apply ge_of_tendsto (Complex.continuous_re.tendsto _ |>.comp (tendsto_form ω H x x)) + exact Filter.Eventually.of_forall (fun i => (inner_self_nonneg (𝕜 := ℂ) (x := x.seq i))) + add_left x y z := by + apply tendsto_nhds_unique (tendsto_form ω H (x+y) z) + simpa only [seq_add,inner_add_left] using (tendsto_form ω H x z).add (tendsto_form ω H y z) + smul_left x y r := by + apply tendsto_nhds_unique (tendsto_form ω H (r • x) y) + simpa only [seq_smul,inner_smul_left] using tendsto_const_nhds.mul (tendsto_form ω H x y) + +instance : SeminormedAddCommGroup (Pre ω H) := + InnerProductSpace.Core.toSeminormedAddCommGroup (c := core ω H) + +instance : InnerProductSpace ℂ (Pre ω H) := InnerProductSpace.ofCore (core ω H) + +@[simp] lemma pre_inner (x y : Pre ω H) : inner ℂ x y=form ω H x y := rfl + +lemma tendsto_inner (x y : Pre ω H) : + Tendsto (fun i => inner ℂ (x.seq i) (y.seq i)) (ω : Filter ℕ) (𝓝 (inner ℂ x y)) := + tendsto_form ω H x y + +lemma tendsto_norm (x : Pre ω H) : + Tendsto (fun i => ‖x.seq i‖) (ω : Filter ℕ) (𝓝 ‖x‖) := by + have h := (Complex.continuous_re.tendsto _ |>.comp (tendsto_inner ω H x x)).sqrt + simpa only [Function.comp_apply, ← RCLike.re_to_complex, inner_self_eq_norm_sq,Real.sqrt_sq (norm_nonneg _)] using h + +abbrev Space := Completion (Pre ω H) + +lemma norm_coe_tendsto (x : Pre ω H) : + Tendsto (fun i => ‖x.seq i‖) (ω : Filter ℕ) (𝓝 ‖(x : Space ω H)‖) := by + rw [Completion.norm_coe] + exact tendsto_norm ω H x + +lemma coe_eq_zero_iff (x : Pre ω H) : (x : Space ω H)=0 ↔ + Tendsto (fun i => ‖x.seq i‖) (ω : Filter ℕ) (𝓝 0) := by + constructor + · intro hx + simpa only [hx,norm_zero] using norm_coe_tendsto ω H x + · intro hx + apply norm_eq_zero.mp + exact tendsto_nhds_unique (norm_coe_tendsto ω H x) hx + +def constantPre (x : H) : Pre ω H := ⟨BoundedContinuousFunction.const ℕ x⟩ + +lemma norm_constantPre (x : H) : ‖constantPre ω H x‖=‖x‖ := + tendsto_nhds_unique (tendsto_norm ω H _) tendsto_const_nhds + +def constantPreMap : H →ₗᵢ[ℂ] Pre ω H where + toFun := constantPre ω H + map_add' := by + intro x y + apply (equiv ω H).injective + apply BoundedContinuousFunction.ext + intro i + rfl + map_smul' := by + intro r x + apply (equiv ω H).injective + apply BoundedContinuousFunction.ext + intro i + rfl + norm_map' := norm_constantPre ω H + +def constant : H →ₗᵢ[ℂ] Space ω H := + (toComplₗᵢ : Pre ω H →ₗᵢ[ℂ] Space ω H).comp (constantPreMap ω H) + +@[simp] lemma constant_apply (x : H) : constant ω H x=(constantPre ω H x : Space ω H) := rfl + +end Kadison.HilbertSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertSequenceOperator.lean b/lean/OAI/Analysis/Commutator/HilbertSequenceOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..2975857a09ecf67aa7ee1fd778e6b0b728ff6493 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertSequenceOperator.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertSequence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter UniformSpace Completion + +namespace Kadison.HilbertSequence + +variable (ω : Ultrafilter ℕ) + +variable {E F G : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + +lemma point_action_bound (T : ℕ →ᵇ (E →L[ℂ] F)) (x : Pre ω E) (i : ℕ) : + ‖T i (x.seq i)‖≤‖T‖*‖x.seq‖ := + (T i).le_of_opNorm_le (T.norm_coe_le_norm i) _ |>.trans + (mul_le_mul_of_nonneg_left (x.seq.norm_coe_le_norm i) (norm_nonneg _)) + +def actPreLinear (T : ℕ →ᵇ (E →L[ℂ] F)) : Pre ω E →ₗ[ℂ] Pre ω F where + toFun x := ⟨BoundedContinuousFunction.mkOfDiscrete (fun i => T i (x.seq i)) + (2*(‖T‖*‖x.seq‖)) (by + intro i j + exact (dist_le_norm_add_norm _ _).trans (by + have hi := point_action_bound ω T x i + have hj := point_action_bound ω T x j + linarith))⟩ + map_add' x y := by + apply (equiv ω F).injective + apply BoundedContinuousFunction.ext + intro i + exact map_add (T i) _ _ + map_smul' r x := by + apply (equiv ω F).injective + apply BoundedContinuousFunction.ext + intro i + exact map_smul (T i) r _ + +@[simp] lemma actPreLinear_seq (T : ℕ →ᵇ (E →L[ℂ] F)) (x : Pre ω E) (i : ℕ) : + (actPreLinear ω T x).seq i=T i (x.seq i) := rfl + +lemma norm_actPreLinear_le (T : ℕ →ᵇ (E →L[ℂ] F)) (x : Pre ω E) : + ‖actPreLinear ω T x‖≤‖T‖*‖x‖ := by + apply le_of_tendsto_of_tendsto (tendsto_norm ω F (actPreLinear ω T x)) + (tendsto_const_nhds.mul (tendsto_norm ω E x)) + exact Filter.Eventually.of_forall (fun i => (T i).le_of_opNorm_le (T.norm_coe_le_norm i) _) + +def actPre (T : ℕ →ᵇ (E →L[ℂ] F)) : Pre ω E →L[ℂ] Pre ω F := + (actPreLinear ω T).mkContinuous ‖T‖ (norm_actPreLinear_le ω T) + +def act (T : ℕ →ᵇ (E →L[ℂ] F)) : Space ω E →L[ℂ] Space ω F := + (actPre ω T).completion + +@[simp] lemma act_coe (T : ℕ →ᵇ (E →L[ℂ] F)) (x : Pre ω E) : + act ω T x=(actPreLinear ω T x : Space ω F) := + ContinuousLinearMap.completion_apply_coe _ _ + +lemma norm_act_apply_le (T : ℕ →ᵇ (E →L[ℂ] F)) (x : Space ω E) : + ‖act ω T x‖≤‖T‖*‖x‖ := by + induction x using Completion.induction_on with + | hp => exact isClosed_le (by fun_prop) (by fun_prop) + | ih x => simpa only [act_coe,Completion.norm_coe] using norm_actPreLinear_le ω T x + +lemma norm_act_le (T : ℕ →ᵇ (E →L[ℂ] F)) : ‖act ω T‖≤‖T‖ := + ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg T) (norm_act_apply_le ω T) + +lemma act_eq_of_coe (S T : Space ω E →L[ℂ] Space ω F) + (h : ∀ x : Pre ω E, S x=T x) : S=T := by + ext x + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => exact h x + +lemma act_add (S T : ℕ →ᵇ (E →L[ℂ] F)) : act ω (S+T)=act ω S+act ω T := by + apply act_eq_of_coe ω + intro x + rw [add_apply,act_coe,act_coe,act_coe,← Completion.coe_add] + congr 1 + +lemma act_smul (r : ℂ) (T : ℕ →ᵇ (E →L[ℂ] F)) : act ω (r • T)=r • act ω T := by + apply act_eq_of_coe ω + intro x + rw [smul_apply,act_coe,act_coe,← Completion.coe_smul] + congr 1 + +lemma act_constant (T : E →L[ℂ] F) (x : E) : + act ω (BoundedContinuousFunction.const ℕ T) (constant ω E x)=constant ω F (T x) := by + rw [constant_apply,act_coe,constant_apply] + congr 1 + +lemma norm_act_constant (T : E →L[ℂ] F) : + ‖act ω (BoundedContinuousFunction.const ℕ T)‖=‖T‖ := by + apply le_antisymm + · simpa using norm_act_le ω (BoundedContinuousFunction.const ℕ T) + · apply ContinuousLinearMap.opNorm_le_bound T (norm_nonneg (act ω (BoundedContinuousFunction.const ℕ T))) + intro x + have h := (act ω (BoundedContinuousFunction.const ℕ T)).le_opNorm (constant ω E x) + simpa only [act_constant,LinearIsometry.norm_map] using h + +lemma act_zero : act ω (0 : ℕ →ᵇ (E →L[ℂ] F))=0 := by + apply act_eq_of_coe ω + intro x + rw [act_coe,zero_apply,← Completion.coe_zero] + congr 1 + +lemma act_mul (S T : ℕ →ᵇ (E →L[ℂ] E)) : act ω (S*T)=act ω S*act ω T := by + apply act_eq_of_coe ω + intro x + rw [mul_apply_eq_comp,act_coe,act_coe,act_coe] + congr 1 + +lemma act_one : act ω (1 : ℕ →ᵇ (E →L[ℂ] E))=1 := by + apply act_eq_of_coe ω + intro x + rw [act_coe,one_apply_eq_self] + congr 1 + +variable [CompleteSpace E] + +lemma act_star (T : ℕ →ᵇ (E →L[ℂ] E)) : act ω (star T)=star (act ω T) := by + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => + induction y using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih y => + rw [act_coe,act_coe,Completion.inner_coe,Completion.inner_coe] + apply tendsto_nhds_unique (tendsto_inner ω E (actPreLinear ω (star T) x) y) + have h := tendsto_inner ω E x (actPreLinear ω T y) + simpa only [actPreLinear_seq,BoundedContinuousFunction.star_apply, + ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left] using h + +def actionHom : (ℕ →ᵇ (E →L[ℂ] E)) →⋆ₐ[ℂ] (Space ω E →L[ℂ] Space ω E) where + toFun := act ω + map_one' := act_one ω + map_zero' := act_zero ω + map_add' := act_add ω + map_mul' := act_mul ω + map_star' := act_star ω + commutes' r := by + change act ω (r • (1 : ℕ →ᵇ (E →L[ℂ] E)))=r • (1 : Space ω E →L[ℂ] Space ω E) + rw [act_smul,act_one] + +end Kadison.HilbertSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertStrong.lean b/lean/OAI/Analysis/Commutator/HilbertStrong.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d2d98d2c7a424a3862e636b04a63681fd15a658 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertStrong.lean @@ -0,0 +1,138 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry16 +import OAI.Analysis.Commutator.StrongContinuity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped TensorProduct InnerProductSpace Topology CStarAlgebra ComplexOrder + +open UniformSpace + +namespace Kadison + +namespace StrongContinuity + +variable {X E F : Type*} [TopologicalSpace X] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +lemma completion (T : X → E →ₗᵢ[ℂ] E) + (hT : ∀ x, Continuous fun g => T g x) (x : Completion E) : + Continuous fun g => completionIsometry (T g) x := by + apply of_denseRange _ (fun x : E => (x : Completion E)) Completion.denseRange_coe _ x + intro y + simpa only [completionIsometry_coe, Function.comp_def] using (Completion.continuous_coe E).comp (hT y) + +lemma tensor (T : X → E →ₗᵢ[ℂ] E) (S : X → F →ₗᵢ[ℂ] F) + (hT : ∀ x, Continuous fun g => T g x) (hS : ∀ x, Continuous fun g => S g x) + (x : E ⊗[ℂ] F) : Continuous fun g => TensorProduct.mapIsometry (T g) (S g) x := by + induction x using TensorProduct.inductionOn with + | add x y hx hy => + convert hx.add hy using 1 + ext g + exact map_add (TensorProduct.mapIsometry (T g) (S g)) x y + | tmul x y => + simpa only [TensorProduct.mapIsometry_apply,TensorProduct.map_tmul,LinearIsometry.coe_toLinearMap,Function.comp_def] + using (TensorProduct.continuous_tmul (𝕜:=ℂ) (E:=E) (F:=F)).comp ((hT x).prodMk (hS y)) + +lemma hilbertSum {ι H : Type*} {V : ι → Type*} + [∀ i, NormedAddCommGroup (V i)] [∀ i, InnerProductSpace ℂ (V i)] [∀ i, CompleteSpace (V i)] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (U : ∀ i, V i →ₗᵢ[ℂ] H) (hU : IsHilbertSum ℂ V U) + (T : X → H →ₗᵢ[ℂ] H) (hT : ∀ i x, Continuous fun g => T g (U i x)) + (x : H) : Continuous fun g => T g x := by + have hs : (⨆ i, LinearMap.range (U i).toLinearMap) ≤ vectors T := by + apply iSup_le + rintro i _ ⟨x,rfl⟩ + exact hT i x + have ht := Submodule.topologicalClosure_minimal _ hs (isClosed_vectors T) + rw [← hU.OrthogonalFamily.range_linearIsometry, + LinearMap.range_eq_top.mpr hU.surjective_isometry] at ht + exact ht (Submodule.mem_top : x∈(⊤:Submodule ℂ H)) + +end StrongContinuity + +namespace PreHilbert + +variable {X : Type*} [TopologicalSpace X] + +lemma powerMap_continuous (E : PreHilbert) (T : X → E →ₗᵢ[ℂ] E) + (hT : ∀ x, Continuous fun g => T g x) (n : ℕ) (x : power E n) : + Continuous fun g => powerMap E (T g) n x := by + induction n with + | zero => exact continuous_const + | succ n ih => exact StrongContinuity.tensor T (fun g => powerMap E (T g) n) hT ih x + +lemma wordMap_continuous (E F : PreHilbert) (T : X → E →ₗᵢ[ℂ] E) (S : X → F →ₗᵢ[ℂ] F) + (hT : ∀ x, Continuous fun g => T g x) (hS : ∀ x, Continuous fun g => S g x) + (n : ℕ) (x : wordSpace E F n) : Continuous fun g => wordMap E F (T g) (S g) n x := + StrongContinuity.completion _ + (StrongContinuity.tensor T (fun g => powerMap F (S g) n) hT (powerMap_continuous F S hS n)) x + +end PreHilbert + +namespace TracialGNS + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +lemma conjugation_continuous (x : τ.GNS) : Continuous fun u : unitary A => conjugation τ hτ u x := by + change Continuous fun u : unitary A => τ.gnsStarAlgHom (u:A) + (rightStarAlgHom τ hτ (MulOpposite.op (star (u:A))) x) + have hL : Continuous fun u : unitary A => τ.gnsStarAlgHom (u:A) := + (map_continuous τ.gnsStarAlgHom).comp continuous_subtype_val + have hR : Continuous fun u : unitary A => rightStarAlgHom τ hτ (MulOpposite.op (star (u:A))) := + (map_continuous (rightStarAlgHom τ hτ)).comp (MulOpposite.continuous_op.comp continuous_subtype_val.star) + exact hL.clm_apply (hR.clm_apply continuous_const) + +lemma centeredConjugation_continuous (x : zeroSpace τ) : Continuous fun u : unitary A => + centeredIsometry (vacuum τ) (conjugation τ hτ u) (conjugation_vacuum τ hτ u) x := by + apply Continuous.subtype_mk + exact conjugation_continuous τ hτ x + +lemma wordConjugation_continuous (n : ℕ) (x : PreHilbert.wordSpace (fullSpace τ) (zeroSpace τ) n) : + Continuous fun u : unitary A => wordConjugation τ hτ u n x := + PreHilbert.wordMap_continuous (fullSpace τ) (zeroSpace τ) _ _ + (conjugation_continuous τ hτ) (centeredConjugation_continuous τ hτ) n x + +variable (J : ℕ → Type*) [∀ n, NormedAddCommGroup (J n)] [∀ n, InnerProductSpace ℂ (J n)] + +lemma sumConjugation_continuous (n : ℕ) (x : sumLevel τ J n) : + Continuous fun u : unitary A => sumConjugationIso τ hτ J u n x := + StrongContinuity.completion _ (StrongContinuity.tensor _ _ + (wordConjugation_continuous τ hτ n) (fun _ => continuous_const)) x + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (U : ∀ k, sumLevel τ J k →ₗᵢ[ℂ] H) (hU : IsHilbertSum ℂ (sumLevel τ J) U) + +lemma freeConjugation_continuous (x : H) : + Continuous fun u : unitary A => freeConjugation τ hτ J U hU u x := by + apply StrongContinuity.hilbertSum U hU _ _ x + intro n y + have he : (fun u => freeConjugation τ hτ J U hU u (U n y)) = + fun u => U n (sumConjugationIso τ hτ J u n y) := by + funext u + exact congrArg (fun T : sumLevel τ J n →L[ℂ] H => T y) + ((freeConjugation_comp τ hτ J U hU u n).trans + (congrArg ((U n).toContinuousLinearMap.comp) (sumConjugationIso_toCLM τ hτ J u n).symm)) + rw [he] + exact (U n).continuous.comp (sumConjugation_continuous τ hτ J n y) + +end TracialGNS + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertTensors.lean b/lean/OAI/Analysis/Commutator/HilbertTensors.lean new file mode 100644 index 0000000000000000000000000000000000000000..d33e41fa8225401d8111a64b2f740a6d3aa91476 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertTensors.lean @@ -0,0 +1,92 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +structure PreHilbert where + carrier : Type + [normed : NormedAddCommGroup carrier] + [ipSpace : InnerProductSpace ℂ carrier] + +attribute [instance] PreHilbert.normed PreHilbert.ipSpace + +instance : CoeSort PreHilbert Type := ⟨PreHilbert.carrier⟩ + +namespace PreHilbert + +abbrev scalar : PreHilbert := ⟨ℂ⟩ + +abbrev tensor (E F : PreHilbert) : PreHilbert := ⟨E ⊗[ℂ] F⟩ + +@[reducible] def power (E : PreHilbert) : ℕ → PreHilbert + | 0 => scalar + | n + 1 => tensor E (power E n) + +def pure (E : PreHilbert) : ∀ n, (Fin n → E) → power E n + | 0, _ => (1 : ℂ) + | n + 1, v => v 0 ⊗ₜ[ℂ] pure E n (Fin.tail v) + +@[simp] theorem pure_zero (E : PreHilbert) (v : Fin 0 → E) : + pure E 0 v = (1 : ℂ) := rfl + +@[simp] theorem pure_succ (E : PreHilbert) (n : ℕ) (v : Fin (n+1) → E) : + pure E (n+1) v = v 0 ⊗ₜ[ℂ] pure E n (Fin.tail v) := rfl + +@[simp] theorem norm_pure (E : PreHilbert) (n : ℕ) (v : Fin n → E) : + ‖pure E n v‖ = ∏ i, ‖v i‖ := by + induction n with + | zero => simp [pure, power, scalar] + | succ n ih => + rw [pure_succ, TensorProduct.norm_tmul, ih, Fin.prod_univ_succ] + rfl + +@[simp] theorem inner_pure (E : PreHilbert) (n : ℕ) (v w : Fin n → E) : + inner ℂ (pure E n v) (pure E n w) = ∏ i, inner ℂ (v i) (w i) := by + induction n with + | zero => simp [pure, power, scalar] + | succ n ih => + rw [pure_succ, pure_succ, TensorProduct.inner_tmul, ih, Fin.prod_univ_succ] + rfl + +theorem span_pure (E : PreHilbert) (n : ℕ) : + Submodule.span ℂ (Set.range (pure E n)) = ⊤ := by + induction n with + | zero => + apply Submodule.eq_top_iff'.mpr + intro z + have h : (1 : ℂ) ∈ Submodule.span ℂ (Set.range (pure E 0)) := + Submodule.subset_span ⟨Fin.elim0, rfl⟩ + simpa using (Submodule.span ℂ (Set.range (pure E 0))).smul_mem z h + | succ n ih => + apply Submodule.eq_top_iff'.mpr + intro z + induction z using TensorProduct.inductionOn with + | add x y hx hy => exact Submodule.add_mem _ hx hy + | tmul x y => + have hy : y ∈ Submodule.span ℂ (Set.range (pure E n)) := by rw [ih]; trivial + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨v, rfl⟩ := hy + apply Submodule.subset_span + exact ⟨Fin.cons x v, by simp [pure]⟩ + | zero => simp only [TensorProduct.tmul_zero, Submodule.zero_mem] + | add y z _ _ hy hz => + simpa only [TensorProduct.tmul_add] using + (Submodule.span ℂ (Set.range (pure E (n+1)))).add_mem hy hz + | smul c y _ hy => + simpa only [TensorProduct.tmul_smul] using + (Submodule.span ℂ (Set.range (pure E (n+1)))).smul_mem c hy + +end PreHilbert + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertTensors2.lean b/lean/OAI/Analysis/Commutator/HilbertTensors2.lean new file mode 100644 index 0000000000000000000000000000000000000000..3a24a136e2c32643b2033b58e4143dd2a695aef5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertTensors2.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.PreHilbert + +theorem pure_orthonormal (E : PreHilbert) {ι : Type*} (v : ι → E) + (hv : Orthonormal ℂ v) (n : ℕ) : + Orthonormal ℂ (fun b : Fin n → ι => pure E n (fun i => v (b i))) := by + classical + apply orthonormal_iff_ite.mpr + intro b c + rw [inner_pure] + simp_rw [orthonormal_iff_ite.mp hv] + rw [Finset.prod_ite_zero] + simp only [Finset.mem_univ, forall_const, Finset.prod_const_one] + congr 1 + exact propext funext_iff.symm + +abbrev hilbertPower (E : PreHilbert) (n : ℕ) := UniformSpace.Completion (power E n) + +def hilbertPure (E : PreHilbert) (n : ℕ) (v : Fin n → E) : hilbertPower E n := + (pure E n v : UniformSpace.Completion (power E n)) + +@[simp] theorem norm_hilbertPure (E : PreHilbert) (n : ℕ) (v : Fin n → E) : + ‖hilbertPure E n v‖ = ∏ i, ‖v i‖ := by + rw [hilbertPure, UniformSpace.Completion.norm_coe, norm_pure] + +@[simp] theorem inner_hilbertPure (E : PreHilbert) (n : ℕ) (v w : Fin n → E) : + inner ℂ (hilbertPure E n v) (hilbertPure E n w) = ∏ i, inner ℂ (v i) (w i) := by + rw [hilbertPure, hilbertPure, UniformSpace.Completion.inner_coe, inner_pure] + +theorem hilbertPure_orthonormal (E : PreHilbert) {ι : Type*} (v : ι → E) + (hv : Orthonormal ℂ v) (n : ℕ) : + Orthonormal ℂ (fun b : Fin n → ι => hilbertPure E n (fun i => v (b i))) := by + classical + apply orthonormal_iff_ite.mpr + intro b c + rw [hilbertPure, hilbertPure, UniformSpace.Completion.inner_coe] + exact orthonormal_iff_ite.mp (pure_orthonormal E v hv n) b c + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertTensors3.lean b/lean/OAI/Analysis/Commutator/HilbertTensors3.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6afb239f04b7a2715421fde630b5e00a0e1a603 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertTensors3.lean @@ -0,0 +1,34 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +theorem constant_orthonormal_coefficient_zero (v : ℕ → E) (hv : Orthonormal ℂ v) + (x : E) (c : ℂ) (hc : ∀ n, inner ℂ (v n) x = c) : c = 0 := by + have hs := hv.inner_products_summable x + simp_rw [hc] at hs + have h0 : ‖c‖ ^ 2 = 0 := (summable_const_iff _).mp hs + have hn : ‖c‖ = 0 := by nlinarith [norm_nonneg c] + exact norm_eq_zero.mp hn + +theorem constant_operator_coefficient_zero [CompleteSpace E] [CompleteSpace F] + (T : E →L[ℂ] F) (v : ℕ → E) (hv : Orthonormal ℂ v) + (x : F) (c : ℂ) (hc : ∀ n, inner ℂ (T (v n)) x = c) : c = 0 := by + apply constant_orthonormal_coefficient_zero v hv (T.adjoint x) c + intro n + rw [ContinuousLinearMap.adjoint_inner_right, hc] + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertTensors4.lean b/lean/OAI/Analysis/Commutator/HilbertTensors4.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce3bdabdd88b6f14cfb3a19e978eb4f9f18e9ecd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertTensors4.lean @@ -0,0 +1,28 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +theorem constant_right_orthonormal_coefficient_zero (v : ℕ → E) + (hv : Orthonormal ℂ v) (x : E) (c : ℂ) + (hc : ∀ n, inner ℂ x (v n) = c) : c = 0 := by + have hs : Summable (fun n => ‖inner ℂ x (v n)‖ ^ 2) := + (hv.inner_products_summable x).congr (fun n => by rw [norm_inner_symm]) + simp_rw [hc] at hs + have h0 : ‖c‖ ^ 2 = 0 := (summable_const_iff _).mp hs + have hn : ‖c‖ = 0 := by nlinarith [norm_nonneg c] + exact norm_eq_zero.mp hn + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HilbertTensors5.lean b/lean/OAI/Analysis/Commutator/HilbertTensors5.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b35941deb487d2bd093002b6137c694e69c8ba7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HilbertTensors5.lean @@ -0,0 +1,27 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors4 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +theorem constant_operator_right_coefficient_zero [CompleteSpace E] [CompleteSpace F] + (T : E →L[ℂ] F) (v : ℕ → E) (hv : Orthonormal ℂ v) + (x : F) (c : ℂ) (hc : ∀ n, inner ℂ x (T (v n)) = c) : c = 0 := by + apply constant_right_orthonormal_coefficient_zero v hv (T.adjoint x) c + intro n + rw [ContinuousLinearMap.adjoint_inner_left, hc] + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/HomogeneousBound.lean b/lean/OAI/Analysis/Commutator/HomogeneousBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..241ffe53be345e20adf76e22bc377a6417478ba0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/HomogeneousBound.lean @@ -0,0 +1,52 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {V W : Type*} + [NormedAddCommGroup V] [NormedSpace ℂ V] + [NormedAddCommGroup W] [NormedSpace ℂ W] + +lemma linear_norm_bound_from_unitball (f : V →ₗ[ℂ] W) (C : ℝ) + (h : ∀ x : V,‖x‖≤1 → ‖f x‖≤C) (x : V) : ‖f x‖≤C*‖x‖ := by + by_cases hx : x=0 + · simp [hx] + have hp : 0<‖x‖ := norm_pos_iff.mpr hx + let z : ℂ := ((‖x‖⁻¹ : ℝ) : ℂ) + have hz : ‖z‖=‖x‖⁻¹ := by simp [z] + have hu : ‖z • x‖≤1 := by + rw [norm_smul,hz,inv_mul_cancel₀ hp.ne'] + have hb : ‖x‖⁻¹*‖f x‖≤C := by + simpa only [map_smul,norm_smul,hz] using h (z • x) hu + have hb' := (inv_mul_le_iff₀ hp).mp hb + simpa only [mul_comm] using hb' + +section Algebra + +variable {A B : Type*} [Ring A] [Ring B] [Algebra ℂ A] [Algebra ℂ B] [Star A] [Star B] + +def representedCommutator (ρ : A →⋆ₐ[ℂ] B) (Y : B) : A →ₗ[ℂ] B where + toFun x := Y*ρ x-ρ x*Y + map_add' x y := by + simp only [map_add,mul_add,add_mul] + abel + map_smul' z x := by + simp only [map_smul,mul_smul_comm,smul_mul_assoc,smul_sub,RingHom.id_apply] + +end Algebra + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteAmplification.lean b/lean/OAI/Analysis/Commutator/InfiniteAmplification.lean new file mode 100644 index 0000000000000000000000000000000000000000..8b8fca97b481d70d5417af670ce26054a89e8fbd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteAmplification.lean @@ -0,0 +1,84 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace ENNReal + +namespace Kadison.InfiniteAmplification + +variable {ι : Type*} + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +abbrev Space (ι H : Type*) [NormedAddCommGroup H] := lp (fun _ : ι => H) 2 + +omit [CompleteSpace H] [CompleteSpace G] in +lemma map_mem (T : H →L[ℂ] G) (x : Space ι H) : Memℓp (fun i => T (x i)) 2 := by + apply ((lp.memℓp x).norm.const_smul ‖T‖).mono + intro i + exact T.le_opNorm (x i) + +def mapLinear (T : H →L[ℂ] G) : Space ι H →ₗ[ℂ] Space ι G where + toFun x := ⟨fun i => T (x i),map_mem T x⟩ + map_add' x y := by ext i; exact map_add _ _ _ + map_smul' c x := by ext i; exact map_smul _ _ _ + +omit [CompleteSpace H] [CompleteSpace G] in +lemma norm_mapLinear_le (T : H →L[ℂ] G) (x : Space ι H) : + ‖mapLinear T x‖≤‖T‖*‖x‖ := by + calc + _≤‖(‖T‖:ℂ) • x‖ := lp.norm_mono (by norm_num) (by + intro i + change ‖T (x i)‖≤‖(‖T‖:ℂ) • x i‖ + simpa only [norm_smul,Complex.norm_real,Real.norm_of_nonneg (norm_nonneg T)] using T.le_opNorm (x i)) + _=_ := by rw [norm_smul,Complex.norm_real,Real.norm_of_nonneg (norm_nonneg T)] + +def map (T : H →L[ℂ] G) : Space ι H →L[ℂ] Space ι G := + (mapLinear T).mkContinuous ‖T‖ (norm_mapLinear_le T) + +omit [CompleteSpace H] [CompleteSpace G] in +@[simp] lemma map_apply (T : H →L[ℂ] G) (x : Space ι H) (i : ι) : map T x i=T (x i) := rfl + +lemma map_adjoint (T : H →L[ℂ] G) : (map (ι:=ι) T).adjoint=map T.adjoint := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [lp.inner_eq_tsum,map_apply,ContinuousLinearMap.adjoint_inner_left] + +def diagonal : (H →L[ℂ] H) →⋆ₐ[ℂ] (Space ι H →L[ℂ] Space ι H) where + toFun := map + map_one' := by ext x i; rfl + map_zero' := by ext x i; rfl + map_add' a b := by ext x i; rfl + map_mul' a b := by ext x i; rfl + commutes' c := by ext x i; rfl + map_star' a := (map_adjoint a).symm + +@[simp] lemma diagonal_apply (T : H →L[ℂ] H) (x : Space ι H) (i : ι) : (diagonal (ι:=ι) (H:=H)) T x i=T (x i) := rfl + +def mapIsometry (V : H →ₗᵢ[ℂ] G) : Space ι H →ₗᵢ[ℂ] Space ι G where + toLinearMap := (map V.toContinuousLinearMap).toLinearMap + norm_map' x := by + apply le_antisymm + · exact lp.norm_mono (by norm_num) (fun i => (V.norm_map (x i)).le) + · exact lp.norm_mono (by norm_num) (fun i => (V.norm_map (x i)).ge) + +omit [CompleteSpace H] [CompleteSpace G] in +@[simp] lemma mapIsometry_apply (V : H →ₗᵢ[ℂ] G) (x : Space ι H) (i : ι) : + mapIsometry V x i=V (x i) := rfl + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteBoundTransfer.lean b/lean/OAI/Analysis/Commutator/InfiniteBoundTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..beefa90a96b9dd83c57c72cd4c1ba319f07069cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteBoundTransfer.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.InfiniteCenter +import OAI.Analysis.Commutator.RepresentationMatrixNorm +import OAI.Analysis.Commutator.IntertwinerMatrixTransfer + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +local instance infiniteBoundTransferDecidableEq {α : Sort*} : DecidableEq α := Classical.decEq α + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.InfiniteAmplification + +open IntertwinerCompression + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def single0 : H →ₗᵢ[ℂ] Space ℕ H := + (lp.singleContinuousLinearMap ℂ (fun _ : ℕ => H) 2 0).toLinearMap.isometryOfInner + (fun x y => by + change inner ℂ (lp.single (E:=fun _ : ℕ => H) 2 0 x) + (lp.single (E:=fun _ : ℕ => H) 2 0 y)=inner ℂ x y + rw [lp.inner_single_left,lp.single_apply,Pi.single_eq_same]) + +lemma single0_adjoint : (single0 (H:=H)).toContinuousLinearMap.adjoint= + lp.evalCLM ℂ (fun _ : ℕ => H) 2 0 := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + exact (lp.inner_single_right (𝕜:=ℂ) 0 y x).symm + +omit [CompleteSpace H] in +lemma single0_intertwines (T : H →L[ℂ] H) : + (single0 (H:=H)).toContinuousLinearMap.comp T=(map T).comp single0.toContinuousLinearMap := by + ext x i + change lp.single (E:=fun _ : ℕ => H) 2 0 (T x) i=T (lp.single (E:=fun _ : ℕ => H) 2 0 x i) + by_cases hi : i=0 <;> simp [lp.single_apply,hi] + +lemma pullback_map (Y : H →L[ℂ] H) : + transfer (single0 (H:=H)).toContinuousLinearMap.adjoint (map Y)=Y := by + rw [transfer,ContinuousLinearMap.adjoint_adjoint,single0_adjoint] + ext x + change Y (lp.single (E:=fun _ : ℕ => H) 2 0 x 0)=Y x + simp only [lp.single_apply,Pi.single_eq_same] + +lemma seminorm_map_le (M : VonNeumannAlgebra H) (Y : H →L[ℂ] H) : + commutatorSeminorm (algebra M) (map Y)≤commutatorSeminorm M Y := by + apply commutatorSeminorm_le + rintro _ ⟨a,rfl⟩ ha + change ‖diagonal (ι:=ℕ) (H:=H) Y*diagonal (ι:=ℕ) (H:=H) a.val- + diagonal (ι:=ℕ) (H:=H) a.val*diagonal (ι:=ℕ) (H:=H) Y‖≤_ + rw [←map_mul,←map_mul,←map_sub] + change ‖map (ι:=ℕ) (Y*a.val-a.val*Y)‖≤_ + rw [map_norm] + exact commutator_bound_unitball M Y a.property (by + change ‖map (ι:=ℕ) a.val‖≤1 at ha + rwa [map_norm] at ha) + +theorem bound_of_stable_bound (M : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈M) + {c : ℝ} (hc : 0≤c) + (hb : ‖diagonalAmplification h (map Y)*matrixOperator h (fun i j => map (ι:=ℕ) (X i j))- + matrixOperator h (fun i j => map (ι:=ℕ) (X i j))*diagonalAmplification h (map Y)‖≤ + c*commutatorSeminorm (algebra M) (map Y)*‖matrixOperator h (fun i j => map (ι:=ℕ) (X i j))‖) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm M Y*‖matrixOperator h X‖ := by + let ψ := (diagonal (ι:=ℕ) (H:=H)).comp M.subtype + have hT : ∀ a : M,single0.toContinuousLinearMap.comp (a:H →L[ℂ] H)= + (ψ a).comp single0.toContinuousLinearMap := fun a => single0_intertwines a.val + have hnorm : ‖(single0 (H:=H)).toContinuousLinearMap‖≤1 := + (single0 (H:=H)).norm_toContinuousLinearMap_le + have hp := pullback_matrix_commutator_norm_le (A:=M) (H:=H) (G:=Space ℕ H) + M.subtype ψ (single0 (H:=H)).toContinuousLinearMap hT + hnorm h (fun i j => ⟨X i j,hX i j⟩) (map Y) + rw [pullback_map] at hp + apply hp.trans (hb.trans ?_) + exact mul_le_mul + (mul_le_mul_of_nonneg_left (seminorm_map_le M Y) hc) + (matrixOperator_subtype_norm_le M ψ h X hX) (norm_nonneg _) + (mul_nonneg hc (commutatorSeminorm_nonneg M Y)) + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteCenter.lean b/lean/OAI/Analysis/Commutator/InfiniteCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..def9bffb915510571645717c9971ed839604773f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteCenter.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralCorner +import OAI.Analysis.Commutator.InfiniteDiagonalRange + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +local instance infiniteCenterDecidableEq {α : Sort*} : DecidableEq α := Classical.decEq α + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.InfiniteAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma map_injective : Function.Injective (map (ι:=ℕ) (H:=H) (G:=H)) := by + intro S T h + ext x + have he := congrArg (fun R : Space ℕ H →L[ℂ] Space ℕ H => R (lp.single 2 0 x) 0) h + simpa only [map_apply,lp.single_apply,Pi.single_eq_same] using he + +lemma map_norm (T : H →L[ℂ] H) : ‖map (ι:=ℕ) T‖=‖T‖ := + NonUnitalStarAlgHom.norm_map (diagonal (ι:=ℕ) (H:=H)).toNonUnitalStarAlgHom map_injective T + +lemma mem_algebra (M : VonNeumannAlgebra H) (T : Space ℕ H →L[ℂ] Space ℕ H) : + T∈algebra M ↔ ∃ a : M,map (a : H →L[ℂ] H)=T := Iff.rfl + +lemma map_mem_algebra (M : VonNeumannAlgebra H) (a : H →L[ℂ] H) (ha : a∈M) : + map (ι:=ℕ) a∈algebra M := ⟨⟨a,ha⟩,rfl⟩ + +lemma map_mem_center (M : VonNeumannAlgebra H) (a : H →L[ℂ] H) : + map (ι:=ℕ) a∈CentralCorner.center (algebra M) ↔ a∈CentralCorner.center M := by + rw [CentralCorner.mem_center,CentralCorner.mem_center] + constructor + · rintro ⟨⟨b,hb⟩,hc⟩ + have hba : (b:H →L[ℂ] H)=a := map_injective hb + refine ⟨hba ▸ b.property,?_⟩ + intro c hc' + apply map_injective + change diagonal (ι:=ℕ) (H:=H) (c*a)=diagonal (ι:=ℕ) (H:=H) (a*c) + rw [map_mul,map_mul] + exact hc (map c) (map_mem_algebra M c hc') + · rintro ⟨ha,hc⟩ + refine ⟨map_mem_algebra M a ha,?_⟩ + rintro _ ⟨b,rfl⟩ + change diagonal (ι:=ℕ) (H:=H) b.val*diagonal (ι:=ℕ) (H:=H) a= + diagonal (ι:=ℕ) (H:=H) a*diagonal (ι:=ℕ) (H:=H) b.val + rw [←map_mul,←map_mul,hc b b.property] + +lemma center_range (M : VonNeumannAlgebra H) (T : Space ℕ H →L[ℂ] Space ℕ H) + (hT : T∈CentralCorner.center (algebra M)) : + ∃ a : CentralCorner.center M,map (a : H →L[ℂ] H)=T := by + obtain ⟨a,rfl⟩ := (mem_algebra M T).mp ((CentralCorner.mem_center _ _).mp hT).1 + exact ⟨⟨a,(map_mem_center M a).mp hT⟩,rfl⟩ + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteDiagonalRange.lean b/lean/OAI/Analysis/Commutator/InfiniteDiagonalRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..4e3163bdb7e2f5d6a0ea26f7dc766495ee8c9aba --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteDiagonalRange.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +local instance {α : Sort*} : DecidableEq α := Classical.decEq α + +open scoped InnerProductSpace Topology + +namespace Kadison.InfiniteAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def block (i j : ℕ) : Space ℕ H →L[ℂ] Space ℕ H := + (lp.singleContinuousLinearMap ℂ (fun _ : ℕ => H) 2 i).comp (lp.evalCLM ℂ (fun _ : ℕ => H) 2 j) + +omit [CompleteSpace H] in +lemma block_map_commute (T : H →L[ℂ] H) (i j : ℕ) : + map T*block (H:=H) i j=block i j*map T := by + ext x k + change T (lp.single (E:=fun _ : ℕ => H) 2 i (x j) k)=lp.single (E:=fun _ : ℕ => H) 2 i (T (x j)) k + by_cases hk : k=i <;> simp [lp.single_apply,hk] + +def zeroth (T : Space ℕ H →L[ℂ] Space ℕ H) : H →L[ℂ] H := + (lp.evalCLM ℂ (fun _ : ℕ => H) 2 0).comp + (T.comp (lp.singleContinuousLinearMap ℂ (fun _ : ℕ => H) 2 0)) + +omit [CompleteSpace H] in +lemma eq_map_of_blocks (T : Space ℕ H →L[ℂ] Space ℕ H) + (hT : ∀ i j,block i j*T=T*block i j) : T=map (zeroth T) := by + ext x i + have he := congrArg (fun S : Space ℕ H →L[ℂ] Space ℕ H => S x 0) (hT 0 i) + change lp.single (E:=fun _ : ℕ => H) 2 0 (T x i) 0=T (lp.single (E:=fun _ : ℕ => H) 2 0 (x i)) 0 at he + change T x i=T (lp.single (E:=fun _ : ℕ => H) 2 0 (x i)) 0 + simpa only [lp.single_apply,Pi.single_eq_same] using he + +lemma diagonal_bicommutant_range (M : VonNeumannAlgebra H) : + Set.centralizer (Set.centralizer (Set.range ((diagonal (ι:=ℕ) (H:=H)).comp M.subtype)))= + Set.range ((diagonal (ι:=ℕ) (H:=H)).comp M.subtype) := by + apply Set.Subset.antisymm + · intro T hT + have hb : ∀ i j,block i j*T=T*block i j := fun i j => hT (block i j) (by + rintro _ ⟨a,rfl⟩ + exact block_map_commute a.val i j) + have he := eq_map_of_blocks T hb + have hz : zeroth T∈M := by + change zeroth T∈(M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + intro b hb + have hm : map b∈Set.centralizer (Set.range ((diagonal (ι:=ℕ) (H:=H)).comp M.subtype)) := by + rintro _ ⟨a,rfl⟩ + change map (a : H →L[ℂ] H)*map b=map b*map a + ext x i + exact congrArg (fun R : H →L[ℂ] H => R (x i)) (hb a a.property) + have hcomm := hT (map b) hm + rw [he] at hcomm + ext x + have h := congrArg (fun R : Space ℕ H →L[ℂ] Space ℕ H => R (lp.single (E:=fun _ : ℕ => H) 2 0 x) 0) hcomm + simpa only [mul_apply_eq_comp,map_apply,lp.single_apply,Pi.single_eq_same] using h + exact ⟨⟨zeroth T,hz⟩,he.symm⟩ + · exact Set.subset_centralizer_centralizer + +def algebra (M : VonNeumannAlgebra H) : VonNeumannAlgebra (Space ℕ H) where + toStarSubalgebra := ((diagonal (ι:=ℕ) (H:=H)).comp M.subtype).range + centralizer_centralizer' := diagonal_bicommutant_range M + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteLinkColumn.lean b/lean/OAI/Analysis/Commutator/InfiniteLinkColumn.lean new file mode 100644 index 0000000000000000000000000000000000000000..f01bfe85292e404304893086bc43ded34a25ea17 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteLinkColumn.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Commutator.BiprodLinkColumn + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace ENNReal NNReal + +open Filter + +namespace Kadison.BiprodLinkColumn + +open HilbertBiprod PartialIsometryOrder HilbertFiniteMaps + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable (N : VonNeumannAlgebra (Space H G)) + +variable (S : Set (Intertwiner N)) (hS : OrthogonalLinks N right left S) + +variable (hspan : (familySpace N right left S).starProjection=left) + +lemma finite_sum_norm_sq (s : Finset S) (x : H) : + ∑ v∈s,‖component N v.val x‖^2=(inner ℂ x (compression N S s x)).re := by + have he := congrArg (fun T : H →L[ℂ] H => inner ℂ x (T x)) (column_square N S s) + rw [ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_right] at he + rw [←he] + change _ = RCLike.re (inner ℂ (finiteColumn N S s x) (finiteColumn N S s x)) + rw [←norm_sq_eq_re_inner (𝕜:=ℂ)] + rw [PiLp.norm_sq_eq_of_L2] + exact (Finset.sum_attach s (fun v => ‖component N v.val x‖^2)).symm + +include hS hspan + +lemma column_hasSum (x : H) : + HasSum (fun v : S => ‖component N v.val x‖^2) (‖x‖^2) := by + have hc : Continuous (fun y : H => (inner ℂ x y).re) := + Complex.continuous_re.comp (continuous_const.inner continuous_id) + have ht := (hc.tendsto x).comp (compression_tendsto N S hS hspan x) + have hn : (inner ℂ x x).re=‖x‖^2 := (norm_sq_eq_re_inner (𝕜:=ℂ) x).symm + change Tendsto (fun s : Finset S => ∑ v∈s,‖component N v.val x‖^2) atTop (𝓝 (‖x‖^2)) + convert ht using 1 + · ext s + exact finite_sum_norm_sq N S s x + · rw [hn] + +lemma column_memℓp (x : H) : Memℓp (fun v : S => component N v.val x) 2 := by + apply (memℓp_gen_iff (by norm_num : (0:ℝ)<(2:ℝ≥0∞).toReal)).mpr + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (column_hasSum N S hS hspan x).summable + +def infiniteColumn : H →ₗᵢ[ℂ] lp (fun _ : S => G) 2 where + toFun x := ⟨fun v => component N v.val x,column_memℓp N S hS hspan x⟩ + map_add' x y := by ext v; exact map_add _ _ _ + map_smul' c x := by ext v; exact map_smul _ _ _ + norm_map' x := by + let v : lp (fun _ : S => G) 2 := ⟨fun v => component N v.val x,column_memℓp N S hS hspan x⟩ + have hn : ‖v‖^2=‖x‖^2 := by + have he := lp.norm_rpow_eq_tsum (by norm_num : (0:ℝ)<(2:ℝ≥0∞).toReal) v + simp only [ENNReal.toReal_ofNat,Real.rpow_two] at he + exact he.trans (column_hasSum N S hS hspan x).tsum_eq + exact (sq_eq_sq₀ (norm_nonneg v) (norm_nonneg x)).mp hn + +@[simp] lemma infiniteColumn_apply (x : H) (v : S) : + infiniteColumn N S hS hspan x v=component N v.val x := rfl + +end Kadison.BiprodLinkColumn + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteReindex.lean b/lean/OAI/Analysis/Commutator/InfiniteReindex.lean new file mode 100644 index 0000000000000000000000000000000000000000..55a739651ea14d6ede190e6a9bac958ff0943091 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteReindex.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace ENNReal + +namespace Kadison.InfiniteAmplification + +variable {ι κ : Type*} + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +lemma norm_sq (x : Space ι H) : ‖x‖^2=∑' i,‖x i‖^2 := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using + lp.norm_rpow_eq_tsum (by norm_num : 0<(2:ℝ≥0∞).toReal) x + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +lemma extend_sq (e : ι ↪ κ) (x : ι → H) (k : κ) : + ‖Function.extend e x 0 k‖^2=Function.extend e (fun i => ‖x i‖^2) 0 k := by + classical + by_cases hk : k∈Set.range e + · obtain ⟨i,rfl⟩ := hk + simp only [e.injective.extend_apply] + · rw [Function.extend_apply' _ _ _ hk,Function.extend_apply' _ _ _ hk] + simp + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +lemma reindex_mem (e : ι ↪ κ) (x : Space ι H) : Memℓp (Function.extend e x 0) 2 := by + apply (memℓp_gen_iff (by norm_num : 0<(2:ℝ≥0∞).toReal)).mpr + simp only [ENNReal.toReal_ofNat,Real.rpow_two,extend_sq] + apply (summable_extend_zero e.injective).mpr + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (lp.memℓp x).summable + (by norm_num : 0<(2:ℝ≥0∞).toReal) + +def reindex (e : ι ↪ κ) : Space ι H →ₗᵢ[ℂ] Space κ H where + toFun x := ⟨Function.extend e x 0,reindex_mem e x⟩ + map_add' x y := by + classical + ext k + by_cases hk : k∈Set.range e + · obtain ⟨i,rfl⟩ := hk + simp only [e.injective.extend_apply,lp.coeFn_add,Pi.add_apply] + · simp only [lp.coeFn_add,Pi.add_apply,Function.extend_apply' _ _ _ hk,Pi.zero_apply,add_zero] + map_smul' c x := by + classical + ext k + by_cases hk : k∈Set.range e + · obtain ⟨i,rfl⟩ := hk + simp only [e.injective.extend_apply,lp.coeFn_smul,Pi.smul_apply,RingHom.id_apply] + · simp only [lp.coeFn_smul,Pi.smul_apply,Function.extend_apply' _ _ _ hk,Pi.zero_apply,smul_zero] + norm_map' x := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq,norm_sq] + change (∑' k,‖Function.extend e x 0 k‖^2)=∑' i,‖x i‖^2 + simp only [extend_sq] + exact tsum_extend_zero e.injective (fun i => ‖x i‖^2) + +omit [CompleteSpace H] in +@[simp] lemma reindex_apply (e : ι ↪ κ) (x : Space ι H) (i : ι) : reindex e x (e i)=x i := + e.injective.extend_apply _ _ _ + +omit [CompleteSpace H] in +lemma reindex_intertwines (e : ι ↪ κ) (T : H →L[ℂ] H) (x : Space ι H) : + reindex e (map T x)=map T (reindex e x) := by + classical + ext k + by_cases hk : k∈Set.range e + · obtain ⟨i,rfl⟩ := hk + simp only [reindex_apply,map_apply] + · change Function.extend e (map T x) 0 k=T (Function.extend e x 0 k) + rw [Function.extend_apply' _ _ _ hk,Function.extend_apply' _ _ _ hk] + exact (map_zero T).symm + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +lemma flatten_mem (x : Space ι (Space κ H)) : Memℓp (fun p : ι×κ => x p.1 p.2) 2 := by + apply (memℓp_gen_iff (by norm_num : 0<(2:ℝ≥0∞).toReal)).mpr + simp only [ENNReal.toReal_ofNat,Real.rpow_two] + apply (summable_prod_of_nonneg (fun p => sq_nonneg ‖x p.1 p.2‖)).mpr + constructor + · intro i + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (lp.memℓp (x i)).summable + (by norm_num : 0<(2:ℝ≥0∞).toReal) + · simp only [←norm_sq] + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (lp.memℓp x).summable + (by norm_num : 0<(2:ℝ≥0∞).toReal) + +def flatten : Space ι (Space κ H) →ₗᵢ[ℂ] Space (ι×κ) H where + toFun x := ⟨fun p => x p.1 p.2,flatten_mem x⟩ + map_add' x y := by ext p; rfl + map_smul' c x := by ext p; rfl + norm_map' x := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq,norm_sq] + have hs : Summable (fun p : ι×κ => ‖x p.1 p.2‖^2) := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (flatten_mem x).summable + (by norm_num : 0<(2:ℝ≥0∞).toReal) + change (∑' p : ι×κ,‖x p.1 p.2‖^2)=∑' i,‖x i‖^2 + rw [hs.tsum_prod] + exact tsum_congr (fun i => (norm_sq (x i)).symm) + +omit [CompleteSpace H] in +@[simp] lemma flatten_apply (x : Space ι (Space κ H)) (p : ι×κ) : flatten x p=x p.1 p.2 := rfl + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteSeparable.lean b/lean/OAI/Analysis/Commutator/InfiniteSeparable.lean new file mode 100644 index 0000000000000000000000000000000000000000..0519978100c0bf973c3b4215dc7242f234d85087 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteSeparable.lean @@ -0,0 +1,47 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology + +namespace Kadison.InfiniteAmplification + +variable {ι H : Type*} [Countable ι] [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] [TopologicalSpace.SeparableSpace H] + +theorem separable_space : TopologicalSpace.SeparableSpace (Space ι H) := by + classical + obtain ⟨x,hx⟩ := TopologicalSpace.exists_dense_seq H + let v : ι × ℕ → Space ι H := fun p => lp.single 2 p.1 (x p.2) + let K : Submodule ℂ (Space ι H) := Submodule.span ℂ (Set.range v) + have hK : K.topologicalClosure=⊤ := by + apply Submodule.topologicalClosure_eq_top_iff.mpr + apply le_antisymm ?_ bot_le + intro f hf + have hv (i : ι) (n : ℕ) : inner ℂ (x n) (f i)=0 := by + have hh := (K.mem_orthogonal f).mp hf _ (Submodule.subset_span (Set.mem_range_self (i,n))) + exact (lp.inner_single_left (𝕜:=ℂ) i (x n) f).symm.trans hh + have hf0 : f=0 := by + ext i + exact hx.eq_of_inner_right ℂ (fun n => by simpa only [lp.coeFn_zero,Pi.zero_apply,inner_zero_right] using hv i n) + simpa only [Submodule.mem_bot] using hf0 + have hs : TopologicalSpace.IsSeparable (K.topologicalClosure : Set (Space ι H)) := + ((Set.countable_range v).isSeparable.span (R:=ℂ)).closure + rw [hK] at hs + exact TopologicalSpace.isSeparable_univ_iff.mp hs + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InfiniteUnitary.lean b/lean/OAI/Analysis/Commutator/InfiniteUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..121663300c7dfe666b9aa9bd5c13babdda5b7f31 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InfiniteUnitary.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.InfiniteAmplification + +variable {ι H G : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +def mapEquiv (U : H ≃ₗᵢ[ℂ] G) : Space ι H ≃ₗᵢ[ℂ] Space ι G := + LinearIsometryEquiv.ofSurjective (mapIsometry U.toLinearIsometry) (fun x => + ⟨mapIsometry U.symm.toLinearIsometry x,by ext i; exact U.apply_symm_apply (x i)⟩) + +omit [CompleteSpace H] [CompleteSpace G] in +@[simp] lemma mapEquiv_apply (U : H ≃ₗᵢ[ℂ] G) (x : Space ι H) (i : ι) : + mapEquiv U x i=U (x i) := rfl + +omit [CompleteSpace H] [CompleteSpace G] in +lemma mapEquiv_intertwines (U : H ≃ₗᵢ[ℂ] G) (S : H →L[ℂ] H) (T : G →L[ℂ] G) + (hU : ∀ x,U (S x)=T (U x)) (x : Space ι H) : mapEquiv U (map S x)=map T (mapEquiv U x) := by + ext i + exact hU (x i) + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/IntertwinerCompression.lean b/lean/OAI/Analysis/Commutator/IntertwinerCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..834cca0e7b3bc09a2c90dac508eb3411ba7c3be7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/IntertwinerCompression.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertFiniteMaps +import OAI.Analysis.Commutator.MainMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.IntertwinerCompression + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable {A : Type*} [CStarAlgebra A] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + +variable (T : H →L[ℂ] G) (hT : ∀ a,T.comp (φ a)=(ψ a).comp T) + +def transfer (Y : H →L[ℂ] H) : G →L[ℂ] G := T.comp (Y.comp T.adjoint) + +include hT + +lemma adjoint_intertwines (a : A) : T.adjoint.comp (ψ a)=(φ a).comp T.adjoint := by + have h := congrArg (fun U : H →L[ℂ] G => U.adjoint) (hT (star a)) + simpa only [adjoint_comp,map_star,star_eq_adjoint,adjoint_adjoint] using h.symm + +lemma transfer_left (Y : H →L[ℂ] H) (a : A) : + transfer T (φ a*Y)=ψ a*transfer T Y := by + simp only [transfer,mul_def,←comp_assoc] + rw [hT a] + +lemma transfer_right (Y : H →L[ℂ] H) (a : A) : + transfer T (Y*φ a)=transfer T Y*ψ a := by + simp only [transfer,mul_def,comp_assoc] + rw [adjoint_intertwines φ ψ T hT] + +omit hT + +lemma transfer_sub (Y Z : H →L[ℂ] H) : transfer T (Y-Z)=transfer T Y-transfer T Z := by + simp only [transfer,comp_sub,sub_comp] + +lemma transfer_norm_le (hcon : ‖T‖≤1) (Y : H →L[ℂ] H) : ‖transfer T Y‖≤‖Y‖ := by + calc + _≤‖T‖*(‖Y‖*‖T.adjoint‖) := (opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_left (opNorm_comp_le _ _) (norm_nonneg _)) + _≤1*(‖Y‖*1) := mul_le_mul hcon + (mul_le_mul_of_nonneg_left (by simpa only [adjoint.norm_map] using hcon) (norm_nonneg _)) + (mul_nonneg (norm_nonneg _) (norm_nonneg _)) (by norm_num) + _=‖Y‖ := by ring + +include hT + +lemma transfer_commutator (Y : H →L[ℂ] H) (a : A) : + transfer T (Y*φ a-φ a*Y)=transfer T Y*ψ a-ψ a*transfer T Y := by + rw [transfer_sub,transfer_left φ ψ T hT,transfer_right φ ψ T hT] + +lemma transfer_commutator_norm_le (hcon : ‖T‖≤1) (Y : H →L[ℂ] H) (a : A) : + ‖transfer T Y*ψ a-ψ a*transfer T Y‖≤‖Y*φ a-φ a*Y‖ := by + rw [←transfer_commutator φ ψ T hT] + exact transfer_norm_le T hcon _ + +include hT + +lemma amplify_intertwines (h : ℕ) (X : Matrix (Fin h) (Fin h) A) : + (HilbertFiniteMaps.amplify (Fin h) T).comp (matrixOperator h (fun i j => φ (X i j)))= + (matrixOperator h (fun i j => ψ (X i j))).comp (HilbertFiniteMaps.amplify (Fin h) T) := by + ext x i + change T (matrixOperator h (fun i j => φ (X i j)) x i)= + matrixOperator h (fun i j => ψ (X i j)) (HilbertFiniteMaps.amplify (Fin h) T x) i + rw [@Kadison.matrixOperator_apply H _ _ h (fun i j => φ (X i j)) x i, + @Kadison.matrixOperator_apply G _ _ h (fun i j => ψ (X i j)) (HilbertFiniteMaps.amplify (Fin h) T x) i, + map_sum] + simp only [HilbertFiniteMaps.amplify_apply] + apply Finset.sum_congr rfl + intro j hj + exact congrArg (fun U : H →L[ℂ] G => U (x j)) (hT (X i j)) + +omit hT + +lemma amplify_transfer (h : ℕ) (Y : H →L[ℂ] H) : + diagonalAmplification h (transfer T Y)= + transfer (HilbertFiniteMaps.amplify (Fin h) T) (diagonalAmplification h Y) := by + change HilbertFiniteMaps.amplify (Fin h) (transfer T Y)=_ + rw [transfer,HilbertFiniteMaps.amplify_comp,HilbertFiniteMaps.amplify_comp, + HilbertFiniteMaps.amplify_adjoint] + rfl + +end Kadison.IntertwinerCompression + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/IntertwinerMatrixTransfer.lean b/lean/OAI/Analysis/Commutator/IntertwinerMatrixTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..229b82aa85e032eb606212286cd41351cead4070 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/IntertwinerMatrixTransfer.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.IntertwinerCompression + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.IntertwinerCompression + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +lemma transfer_raw_commutator (T : H →L[ℂ] G) (A : H →L[ℂ] H) (B : G →L[ℂ] G) + (hleft : T.comp A=B.comp T) (hright : T.adjoint.comp B=A.comp T.adjoint) + (Y : H →L[ℂ] H) : + transfer T (Y*A-A*Y)=transfer T Y*B-B*transfer T Y := by + have hl : transfer T (A*Y)=B*transfer T Y := by + simp only [transfer,mul_def,←comp_assoc] + rw [hleft] + have hr : transfer T (Y*A)=transfer T Y*B := by + simp only [transfer,mul_def,comp_assoc] + rw [hright] + rw [transfer_sub,hl,hr] + +lemma transfer_raw_commutator_norm_le (T : H →L[ℂ] G) (hcon : ‖T‖≤1) + (A : H →L[ℂ] H) (B : G →L[ℂ] G) + (hleft : T.comp A=B.comp T) (hright : T.adjoint.comp B=A.comp T.adjoint) + (Y : H →L[ℂ] H) : + ‖transfer T Y*B-B*transfer T Y‖≤‖Y*A-A*Y‖ := by + rw [←transfer_raw_commutator T A B hleft hright] + exact transfer_norm_le T hcon _ + +variable {A : Type*} [CStarAlgebra A] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + +variable (T : H →L[ℂ] G) (hT : ∀ a,T.comp (φ a)=(ψ a).comp T) + +include hT + +lemma pullback_matrix_commutator_norm_le (hcon : ‖T‖≤1) (h : ℕ) + (X : Matrix (Fin h) (Fin h) A) (Z : G →L[ℂ] G) : + ‖diagonalAmplification h (transfer T.adjoint Z)*matrixOperator h (fun i j => φ (X i j))- + matrixOperator h (fun i j => φ (X i j))*diagonalAmplification h (transfer T.adjoint Z)‖≤ + ‖diagonalAmplification h Z*matrixOperator h (fun i j => ψ (X i j))- + matrixOperator h (fun i j => ψ (X i j))*diagonalAmplification h Z‖ := by + rw [amplify_transfer] + apply transfer_raw_commutator_norm_le + · exact (HilbertFiniteMaps.amplify_norm_le _ _).trans (by simpa only [adjoint.norm_map] using hcon) + · exact amplify_intertwines ψ φ T.adjoint (adjoint_intertwines φ ψ T hT) h X + · rw [←HilbertFiniteMaps.amplify_adjoint,adjoint_adjoint] + exact amplify_intertwines φ ψ T hT h X + +omit hT + +lemma transfer_back (Y : H →L[ℂ] H) : + transfer T.adjoint (transfer T Y)=(T.adjoint.comp T)*Y*(T.adjoint.comp T) := by + simp only [transfer,adjoint_adjoint,mul_def,comp_assoc] + +end Kadison.IntertwinerCompression + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/IntertwinerSeminorm.lean b/lean/OAI/Analysis/Commutator/IntertwinerSeminorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c33e211a025f1cbccb4e18210ed8e96b8832db1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/IntertwinerSeminorm.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Commutator.IntertwinerCompression + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.IntertwinerCompression + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +lemma seminorm_le_of_ball (Q : VonNeumannAlgebra G) (Z : G →L[ℂ] G) (δ : ℝ) + (hball : ∀ b∈Q,‖b‖≤1 → ‖Z*b-b*Z‖≤δ) : commutatorSeminorm Q Z≤δ := by + apply csSup_le + · exact ⟨0,0,Q.zero_mem,by simp,by simp⟩ + rintro r ⟨b,hb,hbn,rfl⟩ + exact hball b hb hbn + +lemma faithful_norm (M : VonNeumannAlgebra H) + (ψ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) (hinj : Function.Injective ψ) (a : M) : ‖ψ a‖=‖a‖ := + NonUnitalStarAlgHom.norm_map ψ.toNonUnitalStarAlgHom hinj a + +lemma seminorm_le (M : VonNeumannAlgebra H) (Q : VonNeumannAlgebra G) + (ψ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) (hinj : Function.Injective ψ) + (hrange : ∀ b∈Q,∃ a : M,ψ a=b) + (T : H →L[ℂ] G) (hcon : ‖T‖≤1) + (hT : ∀ a : M,T.comp (a:H →L[ℂ] H)=(ψ a).comp T) (Y : H →L[ℂ] H) : + commutatorSeminorm Q (transfer T Y)≤commutatorSeminorm M Y := by + apply seminorm_le_of_ball + intro b hb hbn + obtain ⟨a,rfl⟩ := hrange b hb + have han : ‖(a:H →L[ℂ] H)‖≤1 := by + change ‖a‖≤1 + have hn : ‖ψ a‖=‖a‖ := faithful_norm M ψ hinj a + rwa [hn] at hbn + exact (transfer_commutator_norm_le (A:=M) (H:=H) (G:=G) M.toStarSubalgebra.subtype ψ T hT hcon Y a).trans + (commutator_bound_unitball M Y a.property han) + +end Kadison.IntertwinerCompression + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InvariantForms.lean b/lean/OAI/Analysis/Commutator/InvariantForms.lean new file mode 100644 index 0000000000000000000000000000000000000000..d70f8249e2095bf7c4a52bcc4298c1b95f40355a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InvariantForms.lean @@ -0,0 +1,137 @@ +import Mathlib +import OAI.Analysis.Commutator.SchurWeylDevelopment + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +open Matrix + +variable {𝕜 : Type*} [CommRing 𝕜] + +variable {I J : Type*} [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] + +def tensorMatrices (A : J → Matrix I I 𝕜) : Matrix (J → I) (J → I) 𝕜 := + fun a b => ∏ j, A j (a j) (b j) + +omit [DecidableEq I] in +lemma tensorMatrices_mul (A B : J → Matrix I I 𝕜) : + tensorMatrices (fun j => A j * B j) = tensorMatrices A * tensorMatrices B := by + classical + ext a b + simp only [tensorMatrices, Matrix.mul_apply] + rw [Fintype.prod_sum] + simp only [← Finset.prod_mul_distrib] + +omit [Fintype I] [DecidableEq J] in +lemma tensorMatrices_single (a b : J → I) : + tensorMatrices (fun j => Matrix.single (a j) (b j) (1 : 𝕜)) = Matrix.single a b 1 := by + classical + ext c d + simp only [tensorMatrices, Matrix.single_apply] + by_cases h : c = a ∧ d = b + · rcases h with ⟨rfl, rfl⟩; simp + · rw [ite_eq_right (by simpa [eq_comm] using h)] + have he : ∃ j, ¬ (a j = c j ∧ b j = d j) := by + by_contra! hn + exact h ⟨funext fun j => (hn j).1.symm, funext fun j => (hn j).2.symm⟩ + obtain ⟨j, hj⟩ := he + exact Finset.prod_eq_zero (Finset.mem_univ j) (ite_eq_right hj) + +def traceForm (T : Matrix (J → I) (J → I) 𝕜) : + MultilinearMap 𝕜 (fun _ : J => Matrix I I 𝕜) 𝕜 := + ∑ a, ∑ b, T a b • ((MultilinearMap.mkPiRing 𝕜 J 1).compLinearMap + fun j => Matrix.entryLinearMap 𝕜 𝕜 (b j) (a j)) + +omit [DecidableEq I] in +lemma traceForm_apply (T : Matrix (J → I) (J → I) 𝕜) (A : J → Matrix I I 𝕜) : + traceForm T A = Matrix.trace (T * tensorMatrices A) := by + simp [traceForm, Matrix.trace, Matrix.mul_apply, tensorMatrices, + _root_.smul_apply, MultilinearMap.compLinearMap_apply, + MultilinearMap.mkPiRing_apply, smul_eq_mul] + +lemma traceForm_single (T : Matrix (J → I) (J → I) 𝕜) (a b : J → I) : + traceForm T (fun j => Matrix.single (a j) (b j) 1) = T b a := by + rw [traceForm_apply, tensorMatrices_single, Matrix.trace_mul_single] + simp + +def coefficientMatrix (F : MultilinearMap 𝕜 (fun _ : J => Matrix I I 𝕜) 𝕜) : + Matrix (J → I) (J → I) 𝕜 := + fun a b => F (fun j => Matrix.single (b j) (a j) 1) + +lemma traceForm_coefficientMatrix (F : MultilinearMap 𝕜 (fun _ : J => Matrix I I 𝕜) 𝕜) : + traceForm (coefficientMatrix F) = F := by + apply Module.Basis.ext_multilinear (fun _ => Matrix.stdBasis 𝕜 I I) + intro v + have hb (p : I × I) : Matrix.stdBasis 𝕜 I I p = Matrix.single p.1 p.2 1 := by + rcases p with ⟨i, j⟩ + exact Matrix.stdBasis_eq_single 𝕜 i j + simp only [hb, traceForm_single, coefficientMatrix] + +lemma coefficientMatrix_traceForm (T : Matrix (J → I) (J → I) 𝕜) : + coefficientMatrix (traceForm T) = T := by + ext a b + exact traceForm_single T b a + +lemma traceForm_injective : Function.Injective (traceForm (I := I) (J := J) (𝕜 := 𝕜)) := by + intro T S h + simpa only [coefficientMatrix_traceForm] using congrArg coefficientMatrix h + +omit [DecidableEq I] in +lemma traceForm_conjugate (T : Matrix (J → I) (J → I) 𝕜) + (U V : Matrix I I 𝕜) (A : J → Matrix I I 𝕜) : + traceForm T (fun j => U * A j * V) = + traceForm (tensorPower V * T * tensorPower U) A := by + simp only [traceForm_apply, tensorMatrices_mul] + change Matrix.trace (T * (tensorPower U * tensorMatrices A * tensorPower V)) = _ + simp only [← Matrix.mul_assoc] + rw [Matrix.trace_mul_cycle] + simp only [Matrix.mul_assoc] + +lemma coefficientMatrix_commute_unitary + (F : MultilinearMap ℂ (fun _ : J => Matrix I I ℂ) ℂ) + (hF : ∀ (U : unitary (Matrix I I ℂ)) (A : J → Matrix I I ℂ), + F (fun j => (U : Matrix I I ℂ) * A j * star (U : Matrix I I ℂ)) = F A) + (U : unitary (Matrix I I ℂ)) : + coefficientMatrix F * tensorPower (U : Matrix I I ℂ) = + tensorPower (U : Matrix I I ℂ) * coefficientMatrix F := by + have hconj : tensorPower (star (U : Matrix I I ℂ)) * coefficientMatrix F * + tensorPower (U : Matrix I I ℂ) = coefficientMatrix F := by + apply traceForm_injective + apply MultilinearMap.ext + intro A + rw [← traceForm_conjugate, traceForm_coefficientMatrix, hF] + have hu : tensorPower (U : Matrix I I ℂ) * tensorPower (star (U : Matrix I I ℂ)) = + (1 : Matrix (J → I) (J → I) ℂ) := by + rw [← tensorPower_mul, ← Unitary.coe_star, Unitary.coe_mul_star_self, tensorPower_one] + have hh := congrArg (fun T => tensorPower (U : Matrix I I ℂ) * T) hconj + simpa only [← Matrix.mul_assoc, hu, Matrix.one_mul] using hh + +theorem invariant_multilinear_form (b : J → I) (hb : Function.Injective b) + (F : MultilinearMap ℂ (fun _ : J => Matrix I I ℂ) ℂ) + (hF : ∀ (U : unitary (Matrix I I ℂ)) (A : J → Matrix I I ℂ), + F (fun j => (U : Matrix I I ℂ) * A j * star (U : Matrix I I ℂ)) = F A) : + ∃ c : Equiv.Perm J → ℂ, ∀ A : J → Matrix I I ℂ, + F A = ∑ σ, c σ * Matrix.trace (permutationMatrix σ * tensorMatrices A) := by + let T := coefficientMatrix F + have he : T = ∑ σ : Equiv.Perm J, T (b ∘ σ.symm) b • permutationMatrix σ := + commutant_unitary_tensorPower b hb T (coefficientMatrix_commute_unitary F hF) + refine ⟨fun σ => T (b ∘ σ.symm) b, fun A => ?_⟩ + have ht : F A = Matrix.trace (T * tensorMatrices A) := by + rw [← traceForm_apply, traceForm_coefficientMatrix] + calc + F A = Matrix.trace (T * tensorMatrices A) := ht + _ = Matrix.trace ((∑ σ : Equiv.Perm J, T (b ∘ σ.symm) b • permutationMatrix σ) * + tensorMatrices A) := congrArg (fun V => Matrix.trace (V * tensorMatrices A)) he + _ = _ := by simp [Matrix.sum_mul, Matrix.trace_smul, smul_eq_mul] + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InvariantSum.lean b/lean/OAI/Analysis/Commutator/InvariantSum.lean new file mode 100644 index 0000000000000000000000000000000000000000..da8074ad8d3dc3e65791cb2abd18882a415f5d86 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InvariantSum.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetry15 +import OAI.Analysis.Commutator.FreeSymmetry8 +import OAI.Analysis.Commutator.FreeSymmetry9 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace +open scoped InnerProductSpace ENNReal +open ContinuousLinearMap +open scoped InnerProductSpace ENNReal +open scoped ComplexOrder InnerProductSpace TensorProduct +open UniformSpace ContinuousLinearMap + +namespace Kadison.TracialGNS + +open PreHilbert HilbertTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) (h1 : τ 1=1) + +variable (J : ℕ → Type*) [∀ k, NormedAddCommGroup (J k)] + [∀ k, InnerProductSpace ℂ (J k)] [∀ k, CompleteSpace (J k)] + +abbrev sumLevel (k : ℕ) := Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J k) + +instance sumLevelNormed (k : ℕ) : NormedAddCommGroup (sumLevel τ J k) := + inferInstanceAs (NormedAddCommGroup (Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J k))) + +instance sumLevelInner (k : ℕ) : InnerProductSpace ℂ (sumLevel τ J k) := + inferInstanceAs (InnerProductSpace ℂ (Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J k))) + +instance sumLevelComplete (k : ℕ) : CompleteSpace (sumLevel τ J k) := + inferInstanceAs (CompleteSpace (Completion (wordSpace (fullSpace τ) (zeroSpace τ) k ⊗[ℂ] J k))) + +def sumLeft (a : A) (k : ℕ) : sumLevel τ J k →L[ℂ] sumLevel τ J k := + HilbertTensor.map (wordLeft τ a k) 1 + +def sumConjugation (u : unitary A) (k : ℕ) : sumLevel τ J k →L[ℂ] sumLevel τ J k := + HilbertTensor.map (wordConjugation τ hτ u k).toContinuousLinearMap 1 + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (U : ∀ k, sumLevel τ J k →ₗᵢ[ℂ] H) (hU : IsHilbertSum ℂ (sumLevel τ J) U) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + +variable (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + +variable (he : ∀ n m (h : n ≤ m) a, φ m (e h a)=φ n a) + +variable (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + +variable (hgen : ∀ a : A, τ.gnsStarAlgHom a ∈ Set.centralizer (Set.centralizer + (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)))) + +variable (L : A → H →L[ℂ] H) + +variable (W : ∀ n, unitary (Matrix (I n) (I n) ℂ) → H →L[ℂ] H) + +variable (hL : ∀ a k, (L a).comp (U k).toContinuousLinearMap = + (U k).toContinuousLinearMap.comp (sumLeft τ J a k)) + +variable (hW : ∀ n u k, (W n u).comp (U k).toContinuousLinearMap = + (U k).toContinuousLinearMap.comp + (sumConjugation τ hτ J (stageUnitary (φ n) u) k)) + +variable (G : H →L[ℂ] H) + +variable (hGL : ∀ a, G.comp (L a)=(L a).comp G) + +variable (hGW : ∀ n u, G.comp (W n u)=(W n u).comp G) + +omit [∀ k, CompleteSpace (J k)] [∀ n, Nonempty (I n)] in +include hU hW hGW in +lemma actual_block_conjugation (k l n : ℕ) (u : unitary (Matrix (I n) (I n) ℂ)) : + (ActualHilbertSum.block (sumLevel τ J) U G l k).comp + (sumConjugation τ hτ J (stageUnitary (φ n) u) k) = + (sumConjugation τ hτ J (stageUnitary (φ n) u) l).comp + (ActualHilbertSum.block (sumLevel τ J) U G l k) := by + exact ActualHilbertSum.block_covariant_of_insert (sumLevel τ J) U hU G (W n u) + (fun k => sumConjugation τ hτ J (stageUnitary (φ n) u) k) + (hGW n u) (hW n u) l k + +omit [∀ k, CompleteSpace (J k)] in +include hU hL hGL in +lemma actual_block_left (k l : ℕ) (a : A) : + (ActualHilbertSum.block (sumLevel τ J) U G l k).comp (sumLeft τ J a k) = + (sumLeft τ J a l).comp (ActualHilbertSum.block (sumLevel τ J) U G l k) := by + exact ActualHilbertSum.block_covariant_of_insert (sumLevel τ J) U hU G (L a) + (fun k => sumLeft τ J a k) (hGL a) (hL a) l k + +omit [∀ k, CompleteSpace (J k)] in +include h1 hU he hsize hgen hL hW hGL hGW in +lemma actual_block_classification (k l : ℕ) : + ∀ a : J k, ∀ b : J l, ∃ c : (Fin k ≃ Fin l) → ℂ, + scalarSlice (ActualHilbertSum.block (sumLevel τ J) U G l k) a b = + ∑ σ, c σ • (wordReindex (fullSpace τ) (zeroSpace τ) σ).toContinuousLinearMap := by + exact word_multiplicity_slices τ hτ h1 _ I φ e he hsize + (dense_stages_of_bicommutant_generation τ I φ e he hgen) + (actual_block_conjugation τ hτ J U hU I φ W hW G hGW k l) + (actual_block_left τ J U hU L hL G hGL k l) + +include h1 hU he hsize hgen hL hW hGL hGW in +theorem actual_word_structure : ∃ B : ∀ k, J k →L[ℂ] J k, + (∀ k, ‖B k‖ ≤ ‖G‖) ∧ + (∀ k (d : fullSpace τ) (x : zeroSpace τ) (a : J k), + G (U k (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a)) = + U k (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) (B k a))) ∧ + (∀ k (d : fullSpace τ) (x : zeroSpace τ) (a : J k), + G.adjoint (U k (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a)) = + U k (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) ((B k).adjoint a))) := by + classical + have hclass := actual_block_classification τ hτ h1 J U hU I φ e he hsize hgen L W hL hW G hGL hGW + have hoff : ∀ i j, i≠j → ActualHilbertSum.block (sumLevel τ J) U G i j=0 := by + intro i j hij + exact word_multiplicity_offlevel τ _ hij.symm (hclass j i) + obtain ⟨z,hz⟩ := exists_unit_centered_letter τ hτ h1 I φ (by + obtain ⟨n,_,hn⟩ := hsize 0 2 + exact ⟨n,hn⟩) + have hex (k : ℕ) := word_multiplicity_both τ h1 + (ActualHilbertSum.block (sumLevel τ J) U G k k) (hclass k k) z hz + choose B hB hG hGa using hex + refine ⟨B,fun k => (hB k).trans (ActualHilbertSum.norm_block_le (sumLevel τ J) U G k k),?_,?_⟩ + · intro k d x a + have hr := congrArg (fun T : sumLevel τ J k →L[ℂ] H => + T (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a)) + (ActualHilbertSum.reduces_of_offdiagonal (sumLevel τ J) U hU G hoff k) + exact hr.trans (congrArg (U k) (hG k d x a)) + · intro k d x a + have hr := congrArg (fun T : sumLevel τ J k →L[ℂ] H => + T (pair (word (fullSpace τ) (zeroSpace τ) k d (fun _ => x)) a)) + (ActualHilbertSum.adjoint_reduces_of_offdiagonal (sumLevel τ J) U hU G hoff k) + exact hr.trans (congrArg (U k) (hGa k d x a)) + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/InverseLimit.lean b/lean/OAI/Analysis/Commutator/InverseLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..cae1dadbc00483cc5d6d29606410168e511252da --- /dev/null +++ b/lean/OAI/Analysis/Commutator/InverseLimit.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.PositiveCauchySchwarz +import OAI.Analysis.Commutator.PositiveWOT + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H J : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma units_inverse_mem (M : VonNeumannAlgebra H) (A : (H →L[ℂ] H)ˣ) + (hA : (A:H →L[ℂ] H)∈M) : (↑A⁻¹:H →L[ℂ] H)∈M := by + change (↑A⁻¹:H →L[ℂ] H)∈M.carrier + rw [←M.centralizer_centralizer'] + intro T hT + exact (show Commute (A:H →L[ℂ] H) T from hT _ hA).units_inv_left.eq.symm + +theorem exists_injective_inverse_limit (M : VonNeumannAlgebra H) + (S : ℕ → H →L[ℂ] H) (hSM : ∀ n,S n∈M) (hone : ∀ n,1≤S n) + (hmono : Monotone S) (v : J → H) (hdense : DenseRange v) + (hbounded : ∀ j,∃ C : ℝ,∀ n,(inner ℂ (S n (v j)) (v j)).re≤C) : + ∃ B : H →L[ℂ] H,B∈M ∧ 0≤B ∧ B≤1 ∧ Function.Injective B ∧ + (∀ n,B≤Ring.inverse (S n)) ∧ + (∀ x,Tendsto (fun n => Ring.inverse (S n) x) atTop (𝓝 (B x))) := by + let U (n : ℕ) : (H →L[ℂ] H)ˣ := (CStarAlgebra.isUnit_of_le 1 (hone n)).unit + have hu (n : ℕ) : (U n:H →L[ℂ] H)=S n := IsUnit.unit_spec _ + have hp (n : ℕ) : 0≤(U n:H →L[ℂ] H) := by rw [hu]; exact zero_le_one.trans (hone n) + let P (n : ℕ) : H →L[ℂ] H := (↑(U n)⁻¹:H →L[ℂ] H) + have hPeq (n : ℕ) : P n=Ring.inverse (S n) := by rw [←hu,Ring.inverse_unit] + have hPM (n : ℕ) : P n∈M := units_inverse_mem M (U n) (by rw [hu]; exact hSM n) + have hPpos (n : ℕ) : 0≤P n := CFC.inv_nonneg_of_nonneg (U n) (hp n) + have hPone (n : ℕ) : P n≤1 := CStarAlgebra.inv_le_one (by change (1:H →L[ℂ] H)≤(U n:H →L[ℂ] H); rw [hu]; exact hone n) + have hPmono : Antitone P := by + intro n m hnm + exact CStarAlgebra.inv_le_inv (hp n) (by rw [hu,hu]; exact hmono hnm) + obtain ⟨B,hBM,hBpos,hB1,hBP,hlim⟩ := exists_strong_inf M P hPM hPpos hPone hPmono + have hker : ∀ x,B x=0 → x=0 := by + intro x hx + have hin (j : J) : inner ℂ x (v j)=0 := by + obtain ⟨C,hC⟩ := hbounded j + have hh (n : ℕ) : ‖inner ℂ x (v j)‖^2≤(inner ℂ (P n x) x).re*C := by + have hcs := inverse_cauchySchwarz (U n) (hp n) x (v j) + rw [hu] at hcs + exact hcs.trans (mul_le_mul_of_nonneg_left (hC n) + ((ContinuousLinearMap.nonneg_iff_isPositive.mp (hPpos n)).re_inner_nonneg_left x)) + have ht : Tendsto (fun n => (inner ℂ (P n x) x).re*C) atTop (𝓝 0) := by + have hh := (Complex.continuous_re.tendsto _ |>.comp + ((hlim x).inner (tendsto_const_nhds (x:=x)))).mul_const C + simpa only [hx,inner_zero_left,Complex.zero_re,zero_mul,Function.comp_apply] using hh + have hz : ‖inner ℂ x (v j)‖^2≤0 := ge_of_tendsto ht (Eventually.of_forall hh) + exact norm_eq_zero.mp (by nlinarith [norm_nonneg (inner ℂ x (v j))]) + apply (inner_self_eq_zero (𝕜:=ℂ)).mp + exact hdense.induction_on (p:=fun y => inner ℂ x y=0) x + (isClosed_eq (continuous_const.inner continuous_id) continuous_const) hin + refine ⟨B,hBM,hBpos,hB1,?_,?_,?_⟩ + · intro x y hxy + apply sub_eq_zero.mp + apply hker + simp only [map_sub,hxy,sub_self] + · intro n; rw [←hPeq]; exact hBP n + · intro x; simpa only [hPeq] using hlim x + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/IrreducibleMatrixTower.lean b/lean/OAI/Analysis/Commutator/IrreducibleMatrixTower.lean new file mode 100644 index 0000000000000000000000000000000000000000..7799e94c1eaf857d2c19b3fc8d1cd9060e2867de --- /dev/null +++ b/lean/OAI/Analysis/Commutator/IrreducibleMatrixTower.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTowerClosure +import OAI.Analysis.Commutator.MatrixTowerDiffuse +import OAI.Analysis.Commutator.MatrixTowerIrreducible + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def generatedStage (F : ℕ → Stage M) (n : ℕ) : Stage (generated M F) where + I := (F n).I + finite := (F n).finite + dec := (F n).dec + nonempty := (F n).nonempty + hom := stageHom M F n + +lemma generatedStage_monotone (F : ℕ → Stage M) + (hF : Monotone (fun n => (F n).hom.range)) : + Monotone (fun n => (generatedStage M F n).hom.range) := by + intro n m hnm a ha + rcases ha with ⟨b,rfl⟩ + obtain ⟨c,hc⟩ := hF hnm (show (F n).hom b∈(F n).hom.range from ⟨b,rfl⟩) + exact ⟨c,Subtype.ext (congrArg (fun a : M => (a:H →L[ℂ] H)) hc)⟩ + +variable (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + +include hτ hnormal hfaith hone hfac hdiffuse in +theorem exists_irreducible_tower [TopologicalSpace.SeparableSpace τ.GNS] : + ∃ F : ℕ → Stage M, + Monotone (fun n => (F n).hom.range) ∧ + (∀ n,n+1≤Fintype.card (F n).I) ∧ + (∀ a : H →L[ℂ] H,a∈M → a∈Set.centralizer (generated M F : Set (H →L[ℂ] H)) → + ∃ z : ℂ,a=z • (1:H →L[ℂ] H)) ∧ + FactorCorner.IsFactor (generated M F) ∧ + DiffuseProjection.HasNoMinimalProjections (generated M F) := by + obtain ⟨x,hx,hxden⟩ := exists_selfAdjoint_dense_sequence M τ + let F := tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx + have hsize : ∀ n,n+1≤Fintype.card (F n).I := tower_size M τ hτ hnormal hfaith hone hfac hdiffuse x hx + have hirr : ∀ a : M,(∀ n b,(F n).hom b*a=a*(F n).hom b) → ∃ z : ℂ,a=z • (1:M) := by + intro a ha + refine ⟨τ a,?_⟩ + exact scalar_of_commutes M τ hτ hone x hxden F + (fun j _ hε => tower_requirement M τ hτ hnormal hfaith hone hfac hdiffuse x hx j hε) hfaith a ha + have hR := generated_factor M F hirr + refine ⟨F,tower_increasing M τ hτ hnormal hfaith hone hfac hdiffuse x hx,hsize, + generated_irreducible M F hirr,hR,?_⟩ + let ρ := NormalSubalgebra.trace M (generated M F) (generated_le M F) τ + apply diffuse_of_stages (generated M F) ρ + (NormalSubalgebra.tracial M _ _ τ hτ) + (NormalSubalgebra.faithful M _ _ τ hfaith) + (NormalSubalgebra.one M _ _ τ hone) hR (generatedStage M F) + intro N + exact ⟨N,lt_of_lt_of_le (Nat.lt_succ_self N) (hsize N)⟩ + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/IrreducibleTowerAveraging.lean b/lean/OAI/Analysis/Commutator/IrreducibleTowerAveraging.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d11861cb6456ebdfc2d74dc0b11c3fd6d54fe62 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/IrreducibleTowerAveraging.lean @@ -0,0 +1,244 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalRelativeCommutant +import OAI.Analysis.Commutator.MatrixExpectationNested + +namespace OAI + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator Topology + +open Filter + +namespace Kadison.IrreducibleTowerAveraging + +open TracialGNS NormalGNS MatrixExpectation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +variable {ι : ℕ → Type*} [∀ n, Fintype (ι n)] [∀ n, DecidableEq (ι n)] + [∀ n, Nonempty (ι n)] + +variable (stage : ∀ n, Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ}, n ≤ m → (stage n).range ≤ (stage m).range) + +def stageUnitaries : Submonoid (unitary M) where + carrier := {u | ∃ n, (u:M) ∈ (stage n).range} + one_mem' := ⟨0, by simp⟩ + mul_mem' := by + rintro u v ⟨n,hn⟩ ⟨m,hm⟩ + exact ⟨max n m, (stage (max n m)).range.mul_mem + (hmono (Nat.le_max_left _ _) hn) (hmono (Nat.le_max_right _ _) hm)⟩ + +def orbit (a : M) : Set τ.GNS := + Set.range (fun u : stageUnitaries M stage hmono => + algebraVector τ ((u.val:M)*a*star (u.val:M))) + +omit [∀ n, Nonempty (ι n)] in +lemma orbit_self (a : M) : algebraVector τ a ∈ orbit M τ stage hmono a := by + refine ⟨1,?_⟩ + simp + +omit [∀ n, Nonempty (ι n)] in +lemma conjugation_orbit (a : M) (u : stageUnitaries M stage hmono) : + ∀ x∈orbit M τ stage hmono a, + conjugation τ hτ u.val x∈orbit M τ stage hmono a := by + rintro x ⟨v,rfl⟩ + refine ⟨u*v,?_⟩ + simp only [algebraVector_apply,conjugation_coe,Submonoid.coe_mul, + star_mul,mul_assoc] + +omit [∀ n, Nonempty (ι n)] in +lemma hull_bounded (hnormal : BoundedWOTContinuous M τ) (a : M) (ha : ‖a‖≤1) : + closedConvexHull ℝ (orbit M τ stage hmono a) ⊆ + {x : τ.GNS | ∃ b : M, ‖b‖≤1 ∧ algebraVector τ b=x} := by + apply closedConvexHull_min _ (NormalRelativeCommutant.vector_unitball_convex M τ) + (vector_unitball_isClosed M τ hnormal) + rintro x ⟨u,rfl⟩ + refine ⟨(u.val:M)*a*star (u.val:M),?_,rfl⟩ + have hn : ‖(u.val:M)*a*star (u.val:M)‖=‖a‖ := by + exact (CStarRing.norm_mul_coe_unitary _ (star u.val)).trans + (CStarRing.norm_coe_unitary_mul u.val a) + rwa [hn] + +include hτ in +omit [∀ n, Nonempty (ι n)] in +lemma hull_trace (a : M) : + ∀ x∈closedConvexHull ℝ (orbit M τ stage hmono a), inner ℂ (vacuum τ) x=τ a := by + apply closedConvexHull_min + · rintro x ⟨u,rfl⟩ + change inner ℂ (vacuum τ) (algebraVector τ ((u.val:M)*a*star (u.val:M)))=τ a + rw [inner_vacuum_algebraVector,hτ,←mul_assoc] + rw [u.val.property.1,one_mul] + · exact (convex_singleton (τ a)).linear_preimage + ((innerSL ℂ (vacuum τ)).toLinearMap.restrictScalars ℝ) + · exact isClosed_eq (continuous_const.inner continuous_id) continuous_const + +include hτ in +omit [∀ n, Nonempty (ι n)] in +theorem scalar_mem_hull + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ n (x : Matrix (ι n) (ι n) ℂ), stage n x*b=b*stage n x) → + ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) (ha : ‖a‖≤1) : + (τ a) • vacuum τ ∈ closedConvexHull ℝ (orbit M τ stage hmono a) := by + obtain ⟨z,hz,hfix⟩ := ConvexIsometry.exists_fixed + (closedConvexHull ℝ (orbit M τ stage hmono a)) + ⟨algebraVector τ a,subset_closedConvexHull (orbit_self M τ stage hmono a)⟩ + isClosed_closedConvexHull convex_closedConvexHull + obtain ⟨b,_,hb⟩ := hull_bounded M τ stage hmono hnormal a ha hz + have hcomm (n : ℕ) (x : Matrix (ι n) (ι n) ℂ) : stage n x*b=b*stage n x := by + apply NormalRelativeCommutant.commutes_of_fixed M τ hτ (stage n) b hfaith _ x + intro u + let v : stageUnitaries M stage hmono := + ⟨NormalRelativeCommutant.liftedUnitary M (stage n) u, n, ⟨u,rfl⟩⟩ + rw [hb] + exact hfix _ (ConvexIsometry.maps_closedConvexHull _ _ + (conjugation_orbit M τ hτ stage hmono a v)) + obtain ⟨c,hc⟩ := hirr b hcomm + have htc : τ b=c := by + rw [hc,Algebra.algebraMap_eq_smul_one,map_smul,hone,smul_eq_mul,mul_one] + have hta : τ b=τ a := by + rw [←inner_vacuum_algebraVector,hb] + exact hull_trace M τ hτ stage hmono a z hz + have hz' : z=(τ a) • vacuum τ := by + rw [←hb,hc,Algebra.algebraMap_eq_smul_one,map_smul,←hta,htc] + rfl + rwa [hz'] at hz + +section SingleStage + +variable {A I : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype I] [DecidableEq I] [Nonempty I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (ρ : A →ₚ[ℂ] ℂ) + (hρ : ∀ a b : A, ρ (a*b)=ρ (b*a)) + +include hρ in +omit [Nonempty I] in +lemma vector_expectation_conjugation (u : unitary A) (hu : (u:A)∈φ.range) (a : A) : + algebraVector ρ (expectation φ ((u:A)*a*star (u:A)))= + algebraVector ρ (expectation φ a) := by + apply (algebraVector_dense ρ).eq_of_inner_left ℂ + intro b + rw [inner_symm φ ρ hρ,inner_symm φ ρ hρ,inner_algebraVector,inner_algebraVector] + obtain ⟨v,hv⟩ := hu + change φ v=(u:A) at hv + have hc : (u:A)*expectation φ b=expectation φ b*(u:A) := by + rw [←hv] + exact commutes φ b v + simp only [star_mul,star_star] + have he : star (u:A)*expectation φ b*(u:A)=expectation φ b := by + rw [mul_assoc,←hc,←mul_assoc,u.property.1,one_mul] + calc + _ = ρ ((u:A)*(star a*(star (u:A)*expectation φ b))) := by + simp only [mul_assoc] + _ = ρ ((star a*(star (u:A)*expectation φ b))*(u:A)) := hρ _ _ + _ = ρ (star a*(star (u:A)*expectation φ b*(u:A))) := by + simp only [mul_assoc] + _ = _ := by rw [he] + +end SingleStage + +def eventualFiber (a : M) : Set τ.GNS := + {v | ∃ b : M, algebraVector τ b=v ∧ ∀ᶠ n in atTop, + algebraVector τ (expectation (stage n) b)=algebraVector τ (expectation (stage n) a)} + +omit [∀ n, Nonempty (ι n)] in +lemma eventualFiber_convex (a : M) : Convex ℝ (eventualFiber M τ stage a) := by + rintro x ⟨b,rfl,hb⟩ y ⟨c,rfl,hc⟩ r s _ _ hrs + have hvec (t : ℝ) (d : M) : + algebraVector τ (t • d) = t • algebraVector τ d := by + rw [← Complex.coe_smul, (algebraVector τ).map_smul, Complex.coe_smul] + have hexp (n : ℕ) (t : ℝ) (d : M) : + expectation (stage n) (t • d) = t • expectation (stage n) d := by + rw [← Complex.coe_smul, (expectation (stage n)).map_smul, Complex.coe_smul] + refine ⟨r • b+s • c,?_,?_⟩ + · simp only [map_add, hvec] + · filter_upwards [hb,hc] with n hn kn + simp only [map_add, hexp, hvec, hn, kn, ←add_smul, hrs, one_smul] + +include hτ in +omit [∀ n, Nonempty (ι n)] in +lemma orbit_subset_eventualFiber (a : M) : + orbit M τ stage hmono a ⊆ eventualFiber M τ stage a := by + rintro x ⟨u,rfl⟩ + refine ⟨(u.val:M)*a*star (u.val:M),rfl,?_⟩ + obtain ⟨N,hN⟩ := u.property + filter_upwards [eventually_ge_atTop N] with n hn + exact vector_expectation_conjugation (stage n) τ hτ u.val (hmono hn hN) a + +include hτ hmono in +theorem expectation_tendsto + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ n (x : Matrix (ι n) (ι n) ℂ), stage n x*b=b*stage n x) → + ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) (ha : ‖a‖≤1) : + Tendsto (fun n => algebraVector τ (expectation (stage n) a)) atTop + (𝓝 ((τ a) • vacuum τ)) := by + have hh := scalar_mem_hull M τ hτ stage hmono hnormal hfaith hone hirr a ha + rw [closedConvexHull_eq_closure_convexHull] at hh + have hf : convexHull ℝ (orbit M τ stage hmono a) ⊆ eventualFiber M τ stage a := + convexHull_min (orbit_subset_eventualFiber M τ hτ stage hmono a) + (eventualFiber_convex M τ stage a) + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨v,hv,hd⟩ := Metric.mem_closure_iff.mp hh ε hε + obtain ⟨b,hb,hba⟩ := hf hv + filter_upwards [hba] with n hn + rw [dist_comm] at hd + have hvac : algebraVector τ ((τ a) • (1:M)) = (τ a) • vacuum τ := + (algebraVector τ).map_smul (τ a) 1 + have hsub : algebraVector τ (b-(τ a) • (1:M)) = + algebraVector τ b - (τ a) • vacuum τ := by + rw [(algebraVector τ).map_sub b ((τ a) • (1:M)), hvac] + have hsmall : ‖algebraVector τ (b-(τ a) • (1:M))‖<ε := by + simpa only [dist_eq_norm, hsub, hb] using hd + have he : algebraVector τ (expectation (stage n) (b-(τ a) • (1:M)))= + algebraVector τ (expectation (stage n) a)-(τ a) • vacuum τ := by + have hexp : expectation (stage n) (b-(τ a) • (1:M)) = + expectation (stage n) b - (τ a) • (1:M) := + ((expectation (stage n)).map_sub b ((τ a) • (1:M))).trans + (congrArg (fun d : M => expectation (stage n) b - d) + (fixes_scalar (stage n) (τ a))) + have hvec : algebraVector τ (expectation (stage n) b - (τ a) • (1:M)) = + algebraVector τ (expectation (stage n) b) - (τ a) • vacuum τ := + ((algebraVector τ).map_sub (expectation (stage n) b) ((τ a) • (1:M))).trans + (congrArg (fun v : τ.GNS => algebraVector τ (expectation (stage n) b) - v) hvac) + exact (congrArg (algebraVector τ) hexp).trans + (hvec.trans (congrArg (fun v : τ.GNS => v - (τ a) • vacuum τ) hn)) + rw [dist_eq_norm,←he] + exact (norm_vector_le (stage n) τ hτ _).trans_lt hsmall + +include hτ hmono in +theorem expectation_tendsto_any + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ n (x : Matrix (ι n) (ι n) ℂ), stage n x*b=b*stage n x) → + ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) : + Tendsto (fun n => algebraVector τ (expectation (stage n) a)) atTop + (𝓝 ((τ a) • vacuum τ)) := by + let c : ℝ := ‖a‖+1 + have hc : 0 T x) F.adjoint_comp_self + +omit [CompleteSpace L] in +lemma isometry_project_range (E : L →ₗᵢ[ℂ] H) (F : K →ₗᵢ[ℂ] H) + (hEF : Set.range E⊆Set.range F) (x : L) : + F (F.toContinuousLinearMap.adjoint (E x))=E x := by + obtain ⟨y,hy⟩ := hEF (Set.mem_range_self x) + rw [←hy,isometry_adjoint_apply] + +def factorIsometry (E : L →ₗᵢ[ℂ] H) (F : K →ₗᵢ[ℂ] H) + (hEF : Set.range E⊆Set.range F) : L →ₗᵢ[ℂ] K where + toLinearMap := (F.toContinuousLinearMap.adjoint.comp E.toContinuousLinearMap).toLinearMap + norm_map' x := by + change ‖F.toContinuousLinearMap.adjoint (E x)‖=‖x‖ + rw [←F.norm_map,isometry_project_range E F hEF,E.norm_map] + +omit [CompleteSpace L] in +lemma factorIsometry_comp (E : L →ₗᵢ[ℂ] H) (F : K →ₗᵢ[ℂ] H) + (hEF : Set.range E⊆Set.range F) : + F.toContinuousLinearMap.comp (factorIsometry E F hEF).toContinuousLinearMap= + E.toContinuousLinearMap := by + ext x + exact isometry_project_range E F hEF x + +lemma compress_factorIsometry (E : L →ₗᵢ[ℂ] H) (F : K →ₗᵢ[ℂ] H) + (hEF : Set.range E⊆Set.range F) (T : H →L[ℂ] H) : + compress E T=compress (factorIsometry E F hEF) (compress F T) := by + have he := factorIsometry_comp E F hEF + conv_lhs => rw [compress,←he,adjoint_comp] + simp only [compress,comp_assoc] + +lemma norm_compress_le_of_range_subset (E : L →ₗᵢ[ℂ] H) (F : K →ₗᵢ[ℂ] H) + (hEF : Set.range E⊆Set.range F) (T : H →L[ℂ] H) : + ‖compress E T‖≤‖compress F T‖ := by + rw [compress_factorIsometry E F hEF T] + exact norm_compress_le _ _ + +end Kadison.FreeCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyDensity.lean b/lean/OAI/Analysis/Commutator/KaplanskyDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..98e2efdd9bb7e6d3ef73875a6230ce25598e4826 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyDensity.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyRational +import OAI.Analysis.Commutator.KaplanskySelfAdjoint + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.Kaplansky + +open OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma contraction_apply {a : H →L[ℂ] H} (ha : ‖a‖≤1) (x : H) : ‖a x‖≤‖x‖ := by + calc + ‖a x‖≤‖a‖*‖x‖ := a.le_opNorm x + _≤1*‖x‖ := mul_le_mul_of_nonneg_right ha (norm_nonneg x) + _=‖x‖ := one_mul _ + +lemma clip_difference_apply {a b : H →L[ℂ] H} (ha : IsSelfAdjoint a) + (hb : IsSelfAdjoint b) (x : H) : + ‖clip a x-clip b x‖≤2*‖(a-b) (kernel b x)‖+‖(a-b) (b (kernel b x))‖ := by + rw [←sub_apply,clip_difference ha hb] + simp only [sub_apply,smul_apply,mul_apply_eq_comp] + calc + ‖(2:ℝ) • (kernel a ((a-b) (kernel b x)))-clip a ((a-b) (b (kernel b x)))‖ + ≤‖(2:ℝ) • (kernel a ((a-b) (kernel b x)))‖+ + ‖clip a ((a-b) (b (kernel b x)))‖ := norm_sub_le _ _ + _≤2*‖(a-b) (kernel b x)‖+‖(a-b) (b (kernel b x))‖ := by + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (by norm_num : (0:ℝ)<2)] + exact add_le_add (mul_le_mul_of_nonneg_left + (contraction_apply (kernel_norm_le a) _) (by norm_num)) + (contraction_apply (clip_norm_le a) _) + +lemma cfc_bicommutant (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (f : ℝ → ℝ) : cfc f T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := by + intro c hc + exact ((show Commute c T from hT c hc).symm.cfc_real f).symm.eq + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +theorem selfAdjoint_contraction_finite_approx + (S : StarSubalgebra ℂ (H →L[ℂ] H)) (hS : IsClosed (S : Set (H →L[ℂ] H))) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) (x : ι → H) (ε : ℝ) (hε : 0<ε) : + ∃ a : H →L[ℂ] H, a∈S ∧ IsSelfAdjoint a ∧ ‖a‖≤1 ∧ ∀ i, ‖a (x i)-T (x i)‖<ε := by + let : IsClosed (S : Set (H →L[ℂ] H)) := hS + let b := lift T + have hb : b∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := + cfc_bicommutant S hT rationalLift + have hsb : IsSelfAdjoint b := lift_selfAdjoint T + have hcb : clip b=T := clip_lift hsT hnT + let v : SumSpace (H:=H) (ι⊕ι) := WithLp.toLp 2 + (Sum.elim (fun i => kernel b (x i)) (fun i => b (kernel b (x i)))) + obtain ⟨a,ha,hsa,he⟩ := selfAdjoint_finite_approx (ι⊕ι) S hb hsb v (ε/3) (by positivity) + refine ⟨clip a,?_,clip_selfAdjoint a,clip_norm_le a,?_⟩ + · exact cfc_mem (𝕜:=ℝ) (𝕜':=ℂ) (s:=S) rationalClip ha + · intro i + have h₁ : ‖(a-b) (kernel b (x i))‖<ε/3 := by + have h := (PiLp.norm_apply_le (p:=2) + (diagonal (H:=H) (ι⊕ι) a v-diagonal (H:=H) (ι⊕ι) b v) (Sum.inl i)).trans_lt he + simpa only [PiLp.sub_apply,diagonal_apply,v,WithLp.ofLp_toLp, + Sum.elim_inl,sub_apply] using h + have h₂ : ‖(a-b) (b (kernel b (x i)))‖<ε/3 := by + have h := (PiLp.norm_apply_le (p:=2) + (diagonal (H:=H) (ι⊕ι) a v-diagonal (H:=H) (ι⊕ι) b v) (Sum.inr i)).trans_lt he + simpa only [PiLp.sub_apply,diagonal_apply,v,WithLp.ofLp_toLp, + Sum.elim_inr,sub_apply] using h + rw [←hcb] + exact (clip_difference_apply hsa hsb (x i)).trans_lt (by linarith) + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyFull.lean b/lean/OAI/Analysis/Commutator/KaplanskyFull.lean new file mode 100644 index 0000000000000000000000000000000000000000..4613ad7fc3fc7634dcb363de824fd011d03f800f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyFull.lean @@ -0,0 +1,129 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyDensity +import OAI.Analysis.Commutator.MatrixAlgebraDensity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.Kaplansky + +open OperatorAmplification + +local instance : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def offDiagonal (a : H →L[ℂ] H) : SumSpace (H:=H) (Fin 2) →L[ℂ] SumSpace (H:=H) (Fin 2) := + matrixUnit (Fin 2) 0 1*diagonal (H:=H) (Fin 2) a+ + matrixUnit (Fin 2) 1 0*diagonal (H:=H) (Fin 2) (star a) + +@[simp] lemma offDiagonal_zero (a : H →L[ℂ] H) (x : SumSpace (H:=H) (Fin 2)) : + offDiagonal a x 0=a (x 1) := by + simp [offDiagonal,mul_apply_eq_comp,matrixUnit_apply,single_apply] + +@[simp] lemma offDiagonal_one (a : H →L[ℂ] H) (x : SumSpace (H:=H) (Fin 2)) : + offDiagonal a x 1=star a (x 0) := by + simp [offDiagonal,mul_apply_eq_comp,matrixUnit_apply,single_apply] + +lemma offDiagonal_selfAdjoint (a : H →L[ℂ] H) : IsSelfAdjoint (offDiagonal a) := by + apply ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mpr + intro x y + simp only [ContinuousLinearMap.coe_coe,PiLp.inner_apply,Fin.sum_univ_two, + offDiagonal_zero,offDiagonal_one,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_left,ContinuousLinearMap.adjoint_inner_right] + exact add_comm _ _ + +lemma offDiagonal_norm_le {a : H →L[ℂ] H} (ha : ‖a‖≤1) : ‖offDiagonal a‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro x + rw [one_mul] + apply (sq_le_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [PiLp.norm_sq_eq_of_L2,PiLp.norm_sq_eq_of_L2] + simp only [Fin.sum_univ_two,offDiagonal_zero,offDiagonal_one] + have h₀ := contraction_apply ha (x 1) + have h₁ := contraction_apply (a:=star a) (by simpa only [norm_star] using ha) (x 0) + nlinarith [norm_nonneg (a (x 1)),norm_nonneg (star a (x 0)),norm_nonneg (x 0),norm_nonneg (x 1)] + +lemma entry_offDiagonal (a : H →L[ℂ] H) (i j : Fin 2) : + entry (Fin 2) (offDiagonal a) i j=if i=0 ∧ j=1 then a else if i=1 ∧ j=0 then star a else 0 := by + ext x + fin_cases i <;> fin_cases j <;> + simp [entry_apply,single_apply] + +lemma star_bicommutant (S : StarSubalgebra ℂ (H →L[ℂ] H)) {a : H →L[ℂ] H} + (ha : a∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + star a∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := by + let B := StarSubalgebra.centralizer ℂ ((StarSubalgebra.centralizer ℂ (S : Set (H →L[ℂ] H))) : Set (H →L[ℂ] H)) + have he : (B : Set (H →L[ℂ] H))=Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := by + simp only [B,StarSubalgebra.coe_centralizer_centralizer,StarMemClass.star_coe_eq,Set.union_self] + have hm : a∈B := by + change a∈(B : Set (H →L[ℂ] H)) + rw [he] + exact ha + rw [←he] + exact B.star_mem' hm + +lemma offDiagonal_bicommutant (S : StarSubalgebra ℂ (H →L[ℂ] H)) + [IsClosed (S : Set (H →L[ℂ] H))] {a : H →L[ℂ] H} + (ha : a∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + offDiagonal a∈Set.centralizer (Set.centralizer (fullMatrixAlgebra (Fin 2) S : + Set (SumSpace (H:=H) (Fin 2) →L[ℂ] SumSpace (H:=H) (Fin 2)))) := by + apply bicommutant_fullMatrix_of_entries (Fin 2) S 0 + intro i j + rw [entry_offDiagonal] + split_ifs + · exact ha + · exact star_bicommutant S ha + · intro T _ + simp + +omit [CompleteSpace H] in +lemma single_norm (i : Fin 2) (x : H) : ‖single (Fin 2) i x‖=‖x‖ := by + have he : single (Fin 2) i x=PiLp.single 2 i x := by + ext j + simp [single_apply,PiLp.single_apply] + rw [he,PiLp.norm_single] + +lemma entry_norm_le (T : SumSpace (H:=H) (Fin 2) →L[ℂ] SumSpace (H:=H) (Fin 2)) (i j : Fin 2) : + ‖entry (Fin 2) T i j‖≤‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + calc + _≤‖T (single (Fin 2) j x)‖ := PiLp.norm_apply_le _ _ + _≤‖T‖*‖single (Fin 2) j x‖ := T.le_opNorm _ + _=‖T‖*‖x‖ := by rw [single_norm] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +theorem contraction_finite_approx + (S : StarSubalgebra ℂ (H →L[ℂ] H)) (hS : IsClosed (S : Set (H →L[ℂ] H))) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hnT : ‖T‖≤1) (x : ι → H) (ε : ℝ) (hε : 0<ε) : + ∃ a : H →L[ℂ] H, a∈S ∧ ‖a‖≤1 ∧ ∀ i, ‖a (x i)-T (x i)‖<ε := by + let : IsClosed (S : Set (H →L[ℂ] H)) := hS + obtain ⟨A,hA,_,hnA,he⟩ := selfAdjoint_contraction_finite_approx ι + (fullMatrixAlgebra (Fin 2) S) (fullMatrixAlgebra_closed (Fin 2) S) + (offDiagonal_bicommutant S hT) (offDiagonal_selfAdjoint T) (offDiagonal_norm_le hnT) + (fun i => single (Fin 2) 1 (x i)) ε hε + refine ⟨entry (Fin 2) A 0 1,(mem_fullMatrixAlgebra_iff (Fin 2) S A).mp hA 0 1, + (entry_norm_le A 0 1).trans hnA,?_⟩ + intro i + have h := (PiLp.norm_apply_le + (A (single (Fin 2) 1 (x i))-offDiagonal T (single (Fin 2) 1 (x i))) 0).trans_lt (he i) + simpa only [entry_apply,PiLp.sub_apply,offDiagonal_zero,single_apply,ite_true] using h + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyFullRange.lean b/lean/OAI/Analysis/Commutator/KaplanskyFullRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..31b6430e0de2db5eb0d53cebd126220441e412d0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyFullRange.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyFull +import OAI.Analysis.Commutator.KaplanskyRange + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace Topology + +open Filter + +namespace Kadison.Kaplansky + +open OperatorAmplification CyclicColumns CyclicSpatial + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +local instance : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +lemma matrixUnit_mem_matrixRange (i j : Fin 2) : + matrixUnit (H:=H) (Fin 2) i j ∈ (matrixRepresentation (ι:=Fin 2) φ).range := by + let X : CStarMatrix (Fin 2) (Fin 2) A := CStarMatrix.ofMatrix + (fun k l => if k=i ∧ l=j then 1 else 0) + refine ⟨X,?_⟩ + ext x k + change (∑ l,φ (X k l) (x l))=single (Fin 2) i (x j) k + change (∑ l,φ (if k=i ∧ l=j then 1 else 0) (x l))=single (Fin 2) i (x j) k + by_cases hk : k=i + · fin_cases j <;> simp [hk,single_apply] + · simp [hk,single_apply] + +lemma diagonal_mem_matrixRange (a : A) : + diagonal (H:=H) (Fin 2) (φ a) ∈ (matrixRepresentation (ι:=Fin 2) φ).range := by + let X : CStarMatrix (Fin 2) (Fin 2) A := CStarMatrix.ofMatrix + (fun k l => if k=l then a else 0) + refine ⟨X,?_⟩ + ext x k + change (∑ l,φ (if k=l then a else 0) (x l))=φ a (x k) + fin_cases k <;> simp + +lemma offDiagonal_matrixRange_bicommutant {T : H →L[ℂ] H} + (hT : T∈Set.centralizer (Set.centralizer (Set.range φ))) : + offDiagonal T∈Set.centralizer (Set.centralizer + (Set.range (matrixRepresentation (ι:=Fin 2) φ))) := by + intro R hR + have hU : ∀ i j,matrixUnit (Fin 2) i j*R=R*matrixUnit (Fin 2) i j := + fun i j => hR _ (matrixUnit_mem_matrixRange φ i j) + let a := entry (Fin 2) R 0 0 + have he : R=diagonal (H:=H) (Fin 2) a := diagonal_of_matrixUnits (Fin 2) 0 R hU + have ha : a∈Set.centralizer (Set.range φ) := by + rintro _ ⟨b,rfl⟩ + exact entry_commutes (Fin 2) R (φ b) (hR _ (diagonal_mem_matrixRange φ b)) 0 0 + rw [he] + apply commutes_of_entries (Fin 2) + intro i j + rw [entry_offDiagonal] + split_ifs + · exact hT a ha + · exact star_bicommutant φ.range hT a ha + · simp + +theorem range_contraction_finite_approx (ι : Type*) [Fintype ι] [DecidableEq ι] + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (Set.range φ))) + (hnT : ‖T‖≤1) (x : ι → H) (ε : ℝ) (hε : 0<ε) : + ∃ a : A,‖a‖≤1 ∧ ∀ i,‖φ a (x i)-T (x i)‖<ε := by + obtain ⟨X,_,hnX,he⟩ := range_selfAdjoint_contraction_finite_approx ι + (matrixRepresentation (ι:=Fin 2) φ) (offDiagonal_matrixRange_bicommutant φ hT) + (offDiagonal_selfAdjoint T) (offDiagonal_norm_le hnT) + (fun i => single (Fin 2) 1 (x i)) ε hε + refine ⟨X 0 1,CStarMatrix.norm_entry_le_norm.trans hnX,?_⟩ + intro i + have h := (PiLp.norm_apply_le + (matrixRepresentation φ X (single (Fin 2) 1 (x i))-offDiagonal T (single (Fin 2) 1 (x i))) 0).trans_lt (he i) + simpa [represented_matrix_apply,single_apply,apply_ite] using h + +variable (T : H →L[ℂ] H) + (hT : T∈Set.centralizer (Set.centralizer (Set.range φ))) (hnT : ‖T‖≤1) + +include hT hnT in +lemma fullNet_exists (j : Finset H × ℕ) : ∃ a : A, + ‖a‖≤1 ∧ ∀ x∈j.1,‖φ a x-T x‖<(j.2+1:ℝ)⁻¹ := by + classical + obtain ⟨a,ha,he⟩ := range_contraction_finite_approx φ j.1 hT hnT + (fun x => (x:H)) ((j.2+1:ℝ)⁻¹) (by positivity) + exact ⟨a,ha,fun x hx => he ⟨x,hx⟩⟩ + +def fullNet (j : Finset H × ℕ) : A := (fullNet_exists φ T hT hnT j).choose + +lemma fullNet_spec (j : Finset H × ℕ) : + ‖fullNet φ T hT hnT j‖≤1 ∧ ∀ x∈j.1,‖φ (fullNet φ T hT hnT j) x-T x‖<(j.2+1:ℝ)⁻¹ := + (fullNet_exists φ T hT hnT j).choose_spec + +lemma fullNet_tendsto (x : H) : + Tendsto (fun j => φ (fullNet φ T hT hnT j) x) atTop (𝓝 (T x)) := by + classical + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨N,hN⟩ := exists_nat_one_div_lt hε + filter_upwards [eventually_ge_atTop (({x}:Finset H),N)] with j hj + rw [dist_eq_norm] + apply (fullNet_spec φ T hT hnT j).2 x (hj.1 (Finset.mem_singleton_self x)) |>.trans_le + have hn : (N+1:ℝ)≤j.2+1 := by exact_mod_cast Nat.succ_le_succ hj.2 + exact (inv_anti₀ (by positivity) hn).trans (by simpa only [one_div] using hN.le) + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyNet.lean b/lean/OAI/Analysis/Commutator/KaplanskyNet.lean new file mode 100644 index 0000000000000000000000000000000000000000..13bc72b3d59ba5a75aa7db0b2913c1f23858a72a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyNet.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyFull + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +open Filter + +namespace Kadison.Kaplansky + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (S : StarSubalgebra ℂ (H →L[ℂ] H)) (hS : IsClosed (S : Set (H →L[ℂ] H))) + +variable (T : H →L[ℂ] H) + (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) (hnT : ‖T‖≤1) + +include hS hT hnT + +lemma net_approx_exists (j : Finset H × ℕ) : ∃ a : H →L[ℂ] H, + a∈S ∧ ‖a‖≤1 ∧ ∀ x∈j.1,‖a x-T x‖<(j.2+1:ℝ)⁻¹ := by + classical + obtain ⟨a,ha,hna,he⟩ := contraction_finite_approx j.1 S hS hT hnT + (fun x => (x:H)) ((j.2+1:ℝ)⁻¹) (by positivity) + exact ⟨a,ha,hna,fun x hx => he ⟨x,hx⟩⟩ + +def approximationNet (j : Finset H × ℕ) : H →L[ℂ] H := + (net_approx_exists S hS T hT hnT j).choose + +lemma approximationNet_spec (j : Finset H × ℕ) : + approximationNet S hS T hT hnT j∈S ∧ ‖approximationNet S hS T hT hnT j‖≤1 ∧ + ∀ x∈j.1,‖approximationNet S hS T hT hnT j x-T x‖<(j.2+1:ℝ)⁻¹ := + (net_approx_exists S hS T hT hnT j).choose_spec + +lemma approximationNet_tendsto (x : H) : + Tendsto (fun j => approximationNet S hS T hT hnT j x) atTop (𝓝 (T x)) := by + classical + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨N,hN⟩ := exists_nat_one_div_lt hε + filter_upwards [eventually_ge_atTop (({x}:Finset H),N)] with j hj + rw [dist_eq_norm] + have hxj : x∈j.1 := hj.1 (Finset.mem_singleton_self x) + apply (approximationNet_spec S hS T hT hnT j).2.2 x hxj |>.trans_le + have hnj : (N+1:ℝ)≤j.2+1 := by exact_mod_cast Nat.succ_le_succ hj.2 + exact (inv_anti₀ (by positivity) hnj).trans (by simpa only [one_div] using hN.le) + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyRange.lean b/lean/OAI/Analysis/Commutator/KaplanskyRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..2202bc1094979d48bbc2023617bd681202588fb7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyRange.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Commutator.CStarRangeLifts +import OAI.Analysis.Commutator.KaplanskyDensity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace CStarAlgebra ComplexStarModule + +namespace Kadison.Kaplansky + +open OperatorAmplification ComplexStarModule + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +theorem selfAdjoint_contraction_finite_approx_of_clip + (S : StarSubalgebra ℂ (H →L[ℂ] H)) (hclip : ∀ a∈S, IsSelfAdjoint a → clip a∈S) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) (x : ι → H) (ε : ℝ) (hε : 0<ε) : + ∃ a : H →L[ℂ] H, a∈S ∧ IsSelfAdjoint a ∧ ‖a‖≤1 ∧ ∀ i, ‖a (x i)-T (x i)‖<ε := by + let b := lift T + have hb : b∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := + cfc_bicommutant S hT rationalLift + have hsb : IsSelfAdjoint b := lift_selfAdjoint T + have hcb : clip b=T := clip_lift hsT hnT + let v : SumSpace (H:=H) (ι⊕ι) := WithLp.toLp 2 + (Sum.elim (fun i => kernel b (x i)) (fun i => b (kernel b (x i)))) + obtain ⟨a,ha,hsa,he⟩ := selfAdjoint_finite_approx (ι⊕ι) S hb hsb v (ε/3) (by positivity) + refine ⟨clip a,?_,clip_selfAdjoint a,clip_norm_le a,?_⟩ + · exact hclip a ha hsa + · intro i + have h₁ : ‖(a-b) (kernel b (x i))‖<ε/3 := by + have h := (PiLp.norm_apply_le (p:=2) + (diagonal (H:=H) (ι⊕ι) a v-diagonal (H:=H) (ι⊕ι) b v) (Sum.inl i)).trans_lt he + simpa only [PiLp.sub_apply,diagonal_apply,v,WithLp.ofLp_toLp, + Sum.elim_inl,sub_apply] using h + have h₂ : ‖(a-b) (b (kernel b (x i)))‖<ε/3 := by + have h := (PiLp.norm_apply_le (p:=2) + (diagonal (H:=H) (ι⊕ι) a v-diagonal (H:=H) (ι⊕ι) b v) (Sum.inr i)).trans_lt he + simpa only [PiLp.sub_apply,diagonal_apply,v,WithLp.ofLp_toLp, + Sum.elim_inr,sub_apply] using h + rw [←hcb] + exact (clip_difference_apply hsa hsb (x i)).trans_lt (by linarith) + +variable {A : Type*} [CStarAlgebra A] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +lemma clip_mem_range {b : H →L[ℂ] H} (hb : IsSelfAdjoint b) + (hr : b∈φ.range) : clip b∈φ.range := by + obtain ⟨a,ha⟩ := hr + change φ a=b at ha + let a₀ : A := ℜ a + have ha₀ : IsSelfAdjoint a₀ := (ℜ a).property + have he : φ a₀=b := by rw [show a₀=(ℜ a:A) from rfl,map_realPart,ha,hb.coe_realPart] + refine ⟨clip a₀,?_⟩ + change φ (clip a₀)=clip b + rw [clip,φ.map_cfc rationalClip a₀ continuous_rationalClip.continuousOn + (by fun_prop) ha₀ (ha₀.map φ),he] + rfl + +theorem range_selfAdjoint_contraction_finite_approx + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (φ.range : Set (H →L[ℂ] H)))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) (x : ι → H) (ε : ℝ) (hε : 0<ε) : + ∃ a : A, IsSelfAdjoint a ∧ ‖a‖≤1 ∧ ∀ i, ‖φ a (x i)-T (x i)‖<ε := by + obtain ⟨b,hb,hsb,hnb,he⟩ := selfAdjoint_contraction_finite_approx_of_clip ι φ.range + (fun _ hr hs => clip_mem_range φ hs hr) hT hsT hnT x ε hε + obtain ⟨a,hsa,hna,ha⟩ := CStarRangeLifts.selfAdjoint_contraction φ hsb hnb hb + exact ⟨a,hsa,hna,by simpa only [ha] using he⟩ + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyRational.lean b/lean/OAI/Analysis/Commutator/KaplanskyRational.lean new file mode 100644 index 0000000000000000000000000000000000000000..045d794dc9de72697833f49f10e43b0cce47b00b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyRational.lean @@ -0,0 +1,146 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.Kaplansky + +def rationalClip (t : ℝ) : ℝ := 2*t/(1+t^2) + +def rationalKernel (t : ℝ) : ℝ := (1+t^2)⁻¹ + +lemma denom_pos (t : ℝ) : 0<1+t^2 := by positivity + +lemma continuous_rationalKernel : Continuous rationalKernel := by + unfold rationalKernel + exact (continuous_const.add (continuous_id.pow 2)).inv₀ (fun t => ne_of_gt (denom_pos t)) + +lemma continuous_rationalClip : Continuous rationalClip := by + unfold rationalClip + exact (continuous_const.mul continuous_id).div + (continuous_const.add (continuous_id.pow 2)) (fun t => ne_of_gt (denom_pos t)) + +lemma rationalKernel_bound (t : ℝ) : ‖rationalKernel t‖≤1 := by + rw [rationalKernel,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr (denom_pos t))] + exact (inv_le_one₀ (denom_pos t)).mpr (by nlinarith [sq_nonneg t]) + +lemma rationalClip_bound (t : ℝ) : ‖rationalClip t‖≤1 := by + rw [rationalClip,Real.norm_eq_abs,abs_div,abs_of_pos (denom_pos t)] + apply (div_le_one (denom_pos t)).mpr + rw [abs_mul,abs_of_pos (by norm_num : (0:ℝ)<2)] + nlinarith [sq_nonneg (|t|-1),sq_abs t] + +def rationalLift (t : ℝ) : ℝ := t/(1+Real.sqrt (1-t^2)) + +lemma lift_denom_pos (t : ℝ) : 0<1+Real.sqrt (1-t^2) := by positivity + +lemma continuous_rationalLift : Continuous rationalLift := by + unfold rationalLift + exact continuous_id.div + (continuous_const.add ((continuous_const.sub (continuous_id.pow 2)).sqrt)) + (fun t => ne_of_gt (lift_denom_pos t)) + +lemma rationalClip_lift {t : ℝ} (ht : |t|≤1) : + rationalClip (rationalLift t)=t := by + have ht2 : 0≤1-t^2 := by + have := sq_abs t + nlinarith [abs_nonneg t] + have hs := Real.sq_sqrt ht2 + have hd := ne_of_gt (lift_denom_pos t) + unfold rationalClip rationalLift + apply (div_eq_iff (ne_of_gt (denom_pos _))).mpr + field_simp + have he : (1+Real.sqrt (1-t^2))^2+t^2=2*(1+Real.sqrt (1-t^2)) := by nlinarith + rw [he] + ring + +variable {A : Type*} [CStarAlgebra A] + +def kernel (a : A) : A := cfc rationalKernel a + +def clip (a : A) : A := cfc rationalClip a + +lemma kernel_norm_le (a : A) : ‖kernel a‖≤1 := + norm_cfc_le (by norm_num) (fun t _ => rationalKernel_bound t) + +lemma clip_norm_le (a : A) : ‖clip a‖≤1 := + norm_cfc_le (by norm_num) (fun t _ => rationalClip_bound t) + +lemma clip_selfAdjoint (a : A) : IsSelfAdjoint (clip a) := cfc_predicate _ _ + +lemma kernel_selfAdjoint (a : A) : IsSelfAdjoint (kernel a) := cfc_predicate _ _ + +lemma clip_formula {a : A} (ha : IsSelfAdjoint a) : + clip a=(2:ℝ) • (a*kernel a) := by + unfold clip rationalClip kernel + have he : (fun t : ℝ => 2*t/(1+t^2))=(fun t => 2*(t*rationalKernel t)) := by + funext t + simp only [rationalKernel,div_eq_mul_inv,mul_assoc] + rw [he,cfc_const_mul (2:ℝ) (fun t => t*rationalKernel t) a + (continuous_id.mul continuous_rationalKernel).continuousOn, + cfc_mul (fun t:ℝ=>t) rationalKernel a continuous_id.continuousOn + continuous_rationalKernel.continuousOn,cfc_id' ℝ a ha] + +lemma kernel_commute {a : A} (ha : IsSelfAdjoint a) : Commute a (kernel a) := by + have h := cfc_commute_cfc (fun t : ℝ => t) rationalKernel a + rwa [cfc_id' ℝ a ha] at h + +lemma kernel_den {a : A} (ha : IsSelfAdjoint a) : kernel a*(1+a*a)=1 := by + have hden : cfc (fun t : ℝ => 1+t^2) a=1+a*a := by + rw [cfc_const_add (1:ℝ) (fun t => t^2) a (continuous_id.pow 2).continuousOn ha, + cfc_pow_id a 2 ha,pow_two,map_one] + rw [←hden, kernel,←cfc_mul rationalKernel (fun t : ℝ => 1+t^2) a + continuous_rationalKernel.continuousOn (continuous_const.add (continuous_id.pow 2)).continuousOn] + have he : (fun t : ℝ => rationalKernel t*(1+t^2))=(fun _ => 1) := by + funext t + exact inv_mul_cancel₀ (ne_of_gt (denom_pos t)) + rw [he,cfc_const_one ℝ a ha] + +lemma den_kernel {a : A} (ha : IsSelfAdjoint a) : (1+a*a)*kernel a=1 := by + have h := congrArg star (kernel_den ha) + simpa only [star_mul,star_add,star_one,ha.star_eq,(kernel_selfAdjoint a).star_eq] using h + +lemma clip_difference {a b : A} (ha : IsSelfAdjoint a) (hb : IsSelfAdjoint b) : + clip a-clip b=(2:ℝ) • (kernel a*(a-b)*kernel b)- + clip a*(a-b)*b*kernel b := by + have hka := kernel_commute ha + have hab : a*kernel a-b*kernel b= + kernel a*(a-b)*kernel b-a*kernel a*(a-b)*b*kernel b := by + calc + a*kernel a-b*kernel b = + a*kernel a*((1+b*b)*kernel b)-(kernel a*(1+a*a))*b*kernel b := by + rw [den_kernel hb,kernel_den ha,mul_one,one_mul] + _ = _ := by noncomm_ring [hka.eq] + rw [clip_formula ha,clip_formula hb,←smul_sub,hab,smul_sub] + simp only [smul_mul_assoc] + +def lift (a : A) : A := cfc rationalLift a + +lemma lift_selfAdjoint (a : A) : IsSelfAdjoint (lift a) := cfc_predicate _ _ + +lemma clip_lift {a : A} (ha : IsSelfAdjoint a) (hn : ‖a‖≤1) : clip (lift a)=a := by + nontriviality A + rw [clip,lift,←cfc_comp rationalClip rationalLift a ha + continuous_rationalClip.continuousOn continuous_rationalLift.continuousOn] + calc + cfc (rationalClip ∘ rationalLift) a = cfc (fun t:ℝ=>t) a := by + apply cfc_congr + intro t ht + exact rationalClip_lift ((spectrum.norm_le_norm_of_mem ht).trans hn) + _=a := cfc_id' ℝ a ha + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskySelfAdjoint.lean b/lean/OAI/Analysis/Commutator/KaplanskySelfAdjoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..2c5065e48a4cd7de16d754ccf069a52acd939622 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskySelfAdjoint.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison.Kaplansky + +open OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +local instance kaplanskySelfAdjointRealInnerProductSpace : InnerProductSpace ℝ H := + InnerProductSpace.rclikeToReal ℂ H + +def selfAdjointOrbit (S : StarSubalgebra ℂ (H →L[ℂ] H)) (x : H) : Submodule ℝ H where + carrier := {y | ∃ a : H →L[ℂ] H, a∈S ∧ IsSelfAdjoint a ∧ a x=y} + zero_mem' := ⟨0,S.zero_mem,IsSelfAdjoint.zero _,rfl⟩ + add_mem' := by + rintro y z ⟨a,ha,hsa,rfl⟩ ⟨b,hb,hsb,rfl⟩ + exact ⟨a+b,S.add_mem ha hb,hsa.add hsb,rfl⟩ + smul_mem' := by + rintro c y ⟨a,ha,hsa,rfl⟩ + refine ⟨c • a,?_,(IsSelfAdjoint.all c).smul hsa,rfl⟩ + simpa only [Complex.coe_smul] using S.smul_mem ha (c:ℂ) + +def symmetrize (a : H →L[ℂ] H) : H →L[ℂ] H := (1/2:ℝ) • (a+star a) + +lemma symmetrize_selfAdjoint (a : H →L[ℂ] H) : IsSelfAdjoint (symmetrize a) := by + simp [IsSelfAdjoint,symmetrize,star_smul,add_comm] + +lemma symmetrize_eq {a : H →L[ℂ] H} (ha : IsSelfAdjoint a) : symmetrize a=a := by + rw [symmetrize,ha.star_eq,←two_smul ℝ a,smul_smul] + norm_num + +lemma symmetrize_mem (S : StarSubalgebra ℂ (H →L[ℂ] H)) {a : H →L[ℂ] H} (ha : a∈S) : + symmetrize a∈S := by + have h := S.smul_mem (S.add_mem ha (S.star_mem' ha)) ((1/2:ℝ):ℂ) + simpa only [symmetrize, Complex.coe_smul] using h + +def pair (x y : H) : SumSpace (H:=H) (Fin 2) := WithLp.toLp 2 ![x,y] + +omit [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] in +@[simp] lemma pair_zero (x y : H) : pair x y 0=x := rfl + +omit [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] in +@[simp] lemma pair_one (x y : H) : pair x y 1=y := rfl + +lemma crossed_pairing (a : H →L[ℂ] H) (x z : H) : + inner ℝ (pair z x) (diagonal (H:=H) (Fin 2) a (pair x z))= + 2*inner ℝ z (symmetrize a x) := by + change (inner ℂ (pair z x) (diagonal (H:=H) (Fin 2) a (pair x z))).re = + 2 * (inner ℂ z (symmetrize a x)).re + simp only [PiLp.inner_apply,Fin.sum_univ_two,diagonal_apply,pair_zero,pair_one, + symmetrize,smul_apply,add_apply] + rw [←Complex.coe_smul,inner_smul_right,inner_add_right] + simp only [Complex.mul_re,Complex.ofReal_re,Complex.ofReal_im,zero_mul,sub_zero, + Complex.add_re] + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + have hi := inner_re_symm (𝕜:=ℂ) (a z) x + dsimp only [RCLike.re_eq_complex_re] at hi + simpa only [smul_eq_mul] using (by linarith : + (inner ℂ z (a x)).re + (inner ℂ x (a z)).re = + 2 * ((1/2:ℝ) * ((inner ℂ z (a x)).re + (inner ℂ (a z) x).re))) + +lemma selfAdjoint_mem_orbit_closure (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hsT : IsSelfAdjoint T) (x : H) : + T x∈(selfAdjointOrbit S x).topologicalClosure := by + rw [←Submodule.orthogonal_orthogonal_eq_closure] + intro z hz + let X := pair x z + let Z := pair z x + have horbit : ∀ b : H →L[ℂ] H, b∈S → + inner ℝ Z (diagonal (H:=H) (Fin 2) b X)=0 := by + intro b hb + rw [crossed_pairing] + have he := hz (symmetrize b x) + ⟨symmetrize b,symmetrize_mem S hb,symmetrize_selfAdjoint b,rfl⟩ + rw [real_inner_comm] at he + rw [he,mul_zero] + have hcl := bicommutant_mem_cyclicSubspace (S.map (diagonal (H:=H) (Fin 2))) + (diagonal_bicommutant (Fin 2) S hT) X + change diagonal (H:=H) (Fin 2) T X∈closure + (orbitSubmodule (S.map (diagonal (H:=H) (Fin 2))) X : Set (SumSpace (H:=H) (Fin 2))) at hcl + have hzT : inner ℝ Z (diagonal (H:=H) (Fin 2) T X)=0 := by + apply (closure_minimal ?_ (isClosed_eq (continuous_const.inner continuous_id) continuous_const)) hcl + rintro y ⟨a,⟨b,hb,rfl⟩,rfl⟩ + exact horbit b hb + rw [crossed_pairing] at hzT + have hs : symmetrize T=T := symmetrize_eq hsT + rw [hs] at hzT + linarith + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +theorem selfAdjoint_finite_approx (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {T : H →L[ℂ] H} (hT : T∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hsT : IsSelfAdjoint T) (x : SumSpace (H:=H) ι) (ε : ℝ) (hε : 0<ε) : + ∃ a : H →L[ℂ] H, a∈S ∧ IsSelfAdjoint a ∧ + ‖diagonal (H:=H) ι a x-diagonal (H:=H) ι T x‖<ε := by + have h := selfAdjoint_mem_orbit_closure (S.map (diagonal (H:=H) ι)) + (diagonal_bicommutant ι S hT) (hsT.map (diagonal (H:=H) ι)) x + change diagonal (H:=H) ι T x∈closure + (selfAdjointOrbit (S.map (diagonal (H:=H) ι)) x : Set (SumSpace (H:=H) ι)) at h + obtain ⟨y,⟨a,⟨b,hb,hba⟩,hsa,hay⟩,hy⟩ := Metric.mem_closure_iff.mp h ε hε + + refine ⟨symmetrize b,symmetrize_mem S hb,symmetrize_selfAdjoint b,?_⟩ + change diagonal (H:=H) ι b=a at hba + have he : diagonal (H:=H) ι (symmetrize b)=a := by + have : diagonal (H:=H) ι (symmetrize b)=symmetrize (diagonal (H:=H) ι b) := by + have hs : diagonal (H:=H) ι (star b)=star (diagonal (H:=H) ι b) := map_star _ _ + rw [symmetrize,symmetrize,←hs] + ext v i + simp only [diagonal_apply,smul_apply,add_apply,PiLp.smul_apply,PiLp.add_apply] + rw [this,hba,symmetrize_eq hsa] + rw [he,hay] + rwa [dist_eq_norm,norm_sub_rev] at hy + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/KaplanskyStarHomNet.lean b/lean/OAI/Analysis/Commutator/KaplanskyStarHomNet.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb0f6d036f7a86f84c74de5ec539be7029d7b44d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/KaplanskyStarHomNet.lean @@ -0,0 +1,63 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyRange + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +open Filter + +namespace Kadison.Kaplansky + +variable {A H : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +variable (T : H →L[ℂ] H) + (hT : T∈Set.centralizer (Set.centralizer (Set.range φ))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖ ≤ 1) + +include hT hsT hnT in +lemma starHom_net_approx_exists (j : Finset H × ℕ) : ∃ a : A, + ‖a‖ ≤ 1 ∧ ∀ x∈j.1,‖φ a x-T x‖<(j.2+1:ℝ)⁻¹ := by + classical + obtain ⟨a,_,hna,he⟩ := range_selfAdjoint_contraction_finite_approx j.1 φ hT hsT hnT + (fun x => (x:H)) ((j.2+1:ℝ)⁻¹) (by positivity) + exact ⟨a,hna,fun x hx => he ⟨x,hx⟩⟩ + +def starHomNet (j : Finset H × ℕ) : A := + (starHom_net_approx_exists φ T hT hsT hnT j).choose + +lemma starHomNet_spec (j : Finset H × ℕ) : + ‖starHomNet φ T hT hsT hnT j‖ ≤ 1 ∧ + ∀ x∈j.1,‖φ (starHomNet φ T hT hsT hnT j) x-T x‖<(j.2+1:ℝ)⁻¹ := + (starHom_net_approx_exists φ T hT hsT hnT j).choose_spec + +lemma starHomNet_tendsto (x : H) : + Tendsto (fun j => φ (starHomNet φ T hT hsT hnT j) x) atTop (𝓝 (T x)) := by + classical + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨N,hN⟩ := exists_nat_one_div_lt hε + filter_upwards [eventually_ge_atTop (({x}:Finset H),N)] with j hj + rw [dist_eq_norm] + have hxj : x∈j.1 := hj.1 (Finset.mem_singleton_self x) + apply (starHomNet_spec φ T hT hsT hnT j).2 x hxj |>.trans_le + have hnj : (N+1:ℝ) ≤ j.2+1 := by exact_mod_cast Nat.succ_le_succ hj.2 + exact (inv_anti₀ (by positivity) hnj).trans (by simpa only [one_div] using hN.le) + +end Kadison.Kaplansky + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/L2FiniteSum.lean b/lean/OAI/Analysis/Commutator/L2FiniteSum.lean new file mode 100644 index 0000000000000000000000000000000000000000..27c33983439fa4599bb87af1ac4238387a0cda19 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/L2FiniteSum.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableNorm + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H ι : Type*} [MeasurableSpace Ω] (μ : Measure Ω) [Fintype ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma memLp_vector (f : PiLp 2 (fun _ : ι => Lp H 2 μ)) : + MemLp (fun a => WithLp.toLp 2 (fun i => f i a)) 2 μ := by + have hm : MemLp (fun a i => f i a) 2 μ := memLp_pi_iff.mpr (fun i => Lp.memLp (f i)) + exact hm.continuousLinearMap_comp (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => H)).symm.toContinuousLinearMap + +def assemble (f : PiLp 2 (fun _ : ι => Lp H 2 μ)) : Lp (PiLp 2 (fun _ : ι => H)) 2 μ := + (memLp_vector μ f).toLp _ + +omit [CompleteSpace H] in +lemma assemble_ae (f : PiLp 2 (fun _ : ι => Lp H 2 μ)) : + assemble μ f =ᵐ[μ] fun a => WithLp.toLp 2 (fun i => f i a) := MemLp.coeFn_toLp _ + +omit [CompleteSpace H] in +lemma assemble_add (f g : PiLp 2 (fun _ : ι => Lp H 2 μ)) : + assemble μ (f+g)=assemble μ f+assemble μ g := by + apply Lp.ext + have hv : ∀ᵐ a ∂μ,∀ i,(f i+g i) a=f i a+g i a := ae_all_iff.mpr (fun i => Lp.coeFn_add (f i) (g i)) + filter_upwards [assemble_ae μ (f+g),assemble_ae μ f,assemble_ae μ g, + Lp.coeFn_add (assemble μ f) (assemble μ g),hv] with a h1 h2 h3 h4 ha + rw [h1,h4] + change _=assemble μ f a+assemble μ g a + rw [h2,h3] + ext i + exact ha i + +omit [CompleteSpace H] in +lemma assemble_smul (c : ℂ) (f : PiLp 2 (fun _ : ι => Lp H 2 μ)) : + assemble μ (c • f)=c • assemble μ f := by + apply Lp.ext + have hv : ∀ᵐ a ∂μ,∀ i,(c • f i) a=c • (f i a) := ae_all_iff.mpr (fun i => Lp.coeFn_smul c (f i)) + filter_upwards [assemble_ae μ (c • f),assemble_ae μ f,Lp.coeFn_smul c (assemble μ f),hv] + with a h1 h2 h3 ha + rw [h1,h3] + change _=c • (assemble μ f a) + rw [h2] + ext i + exact ha i + +omit [CompleteSpace H] in +lemma assemble_norm (f : PiLp 2 (fun _ : ι => Lp H 2 μ)) : ‖assemble μ f‖=‖f‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [l2_norm_sq,PiLp.norm_sq_eq_of_L2] + calc + _=(∫ a,∑ i,‖f i a‖^2 ∂μ) := by + apply integral_congr_ae + filter_upwards [assemble_ae μ f] with a ha + rw [ha,PiLp.norm_sq_eq_of_L2] + _=∑ i,∫ a,‖f i a‖^2 ∂μ := integral_finsetSum _ (fun i _ => + (memLp_two_iff_integrable_sq_norm (Lp.aestronglyMeasurable (f i))).mp (Lp.memLp (f i))) + _=_ := by congr 1; ext i; exact (l2_norm_sq μ (f i)).symm + +def assembleIsometry : PiLp 2 (fun _ : ι => Lp H 2 μ) →ₗᵢ[ℂ] Lp (PiLp 2 (fun _ : ι => H)) 2 μ where + toFun := assemble μ + map_add' := assemble_add μ + map_smul' := assemble_smul μ + norm_map' := assemble_norm μ + +omit [CompleteSpace H] in +lemma assemble_surjective : Function.Surjective (assembleIsometry (H:=H) (ι:=ι) μ) := by + intro f + let g : PiLp 2 (fun _ : ι => Lp H 2 μ) := + WithLp.toLp 2 (fun i => (PiLp.proj 2 (fun _ : ι => H) i : PiLp 2 (fun _ : ι => H) →L[ℂ] H).compLp f) + refine ⟨g,?_⟩ + apply Lp.ext + have hg : ∀ᵐ a ∂μ,∀ i,g i a=f a i := ae_all_iff.mpr (fun i => ContinuousLinearMap.coeFn_compLp _ _) + filter_upwards [assemble_ae μ g,hg] with a ha hb + change assemble μ g a=f a + rw [ha] + ext i + exact hb i + +def finiteSumEquiv : PiLp 2 (fun _ : ι => Lp H 2 μ) ≃ₗᵢ[ℂ] Lp (PiLp 2 (fun _ : ι => H)) 2 μ := + LinearIsometryEquiv.ofSurjective (assembleIsometry μ) (assemble_surjective μ) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/L2InfiniteSum.lean b/lean/OAI/Analysis/Commutator/L2InfiniteSum.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8a4842274af2e953ea372e9d401ab4481e18624 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/L2InfiniteSum.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +local instance l2InfiniteSumDecidableEq {α : Sort*} : DecidableEq α := Classical.decEq α + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace ENNReal + +namespace Kadison.Decomposable + +variable {Ω H ι : Type*} [MeasurableSpace Ω] (μ : Measure Ω) [Countable ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +open InfiniteAmplification + +def singleL (i : ι) : Lp H 2 μ →L[ℂ] Lp (Space ι H) 2 μ := + (lp.singleContinuousLinearMap ℂ (fun _ : ι => H) 2 i).compLpL 2 μ + +def evalL (i : ι) : Lp (Space ι H) 2 μ →L[ℂ] Lp H 2 μ := + (lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLpL 2 μ + +omit [Countable ι] [CompleteSpace H] in +lemma inner_singleL (i : ι) (f : Lp H 2 μ) (g : Lp (Space ι H) 2 μ) : + inner ℂ (singleL μ i f) g=inner ℂ f (evalL μ i g) := by + classical + simp only [L2.inner_def] + apply integral_congr_ae + filter_upwards [ContinuousLinearMap.coeFn_compLp + (lp.singleContinuousLinearMap ℂ (fun _ : ι => H) 2 i) f, + ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) g] with a ha hb + change inner ℂ ((lp.singleContinuousLinearMap ℂ (fun _ : ι => H) 2 i).compLp f a) (g a)= + inner ℂ (f a) ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp g a) + rw [ha,hb] + exact lp.inner_single_left (𝕜:=ℂ) i (f a) (g a) + +omit [Countable ι] [CompleteSpace H] in +lemma evalL_singleL (i j : ι) (f : Lp H 2 μ) : + evalL μ i (singleL μ j f)=if i=j then f else 0 := by + classical + apply Lp.ext + filter_upwards [ContinuousLinearMap.coeFn_compLp + (lp.evalCLM ℂ (fun _ : ι => H) 2 i) (singleL μ j f), + ContinuousLinearMap.coeFn_compLp (lp.singleContinuousLinearMap ℂ (fun _ : ι => H) 2 j) f, + Lp.coeFn_zero H 2 μ] with a ha hb hz + change ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp (singleL μ j f)) a=_ + rw [ha] + change singleL μ j f a i=_ + change ((lp.singleContinuousLinearMap ℂ (fun _ : ι => H) 2 j).compLp f) a i=_ + rw [hb] + change lp.single (E:=fun _ : ι => H) 2 j (f a) i=_ + by_cases hij : i=j + · subst j + simp [lp.single_apply] + · rw [ite_eq_right hij,hz] + simp [lp.single_apply,hij] + +def singleLI (i : ι) : Lp H 2 μ →ₗᵢ[ℂ] Lp (Space ι H) 2 μ := + (singleL μ i).toLinearMap.isometryOfInner (fun f g => by + change inner ℂ (singleL μ i f) (singleL μ i g)=inner ℂ f g + rw [inner_singleL,evalL_singleL,ite_eq_left rfl]) + +omit [Countable ι] [CompleteSpace H] in +lemma singleLI_orthogonal : OrthogonalFamily ℂ (fun _ : ι => Lp H 2 μ) (singleLI μ) := by + intro i j hij f g + change inner ℂ (singleL μ i f) (singleL μ j g)=0 + rw [inner_singleL,evalL_singleL,ite_eq_right hij,inner_zero_right] + +omit [CompleteSpace H] in +lemma evalL_separates (f : Lp (Space ι H) 2 μ) (hf : ∀ i,evalL μ i f=0) : f=0 := by + classical + apply Lp.ext + have hcoord : ∀ᵐ a ∂μ,∀ i : ι,f a i=0 := ae_all_iff.mpr (fun i => by + filter_upwards [ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) f, + Lp.coeFn_zero H 2 μ] with a ha hz + have he : (evalL μ i f) a=0 := by rw [hf]; exact hz + change ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp f) a=0 at he + rw [ha] at he + exact he) + filter_upwards [hcoord,Lp.coeFn_zero (Space ι H) 2 μ] with a ha hz + rw [hz] + ext i + exact ha i + +lemma singleLI_total : + ⊤≤(⨆ i,LinearMap.range (singleLI (H:=H) (ι:=ι) μ i).toLinearMap).topologicalClosure := by + let K : Submodule ℂ (Lp (Space ι H) 2 μ) := + (⨆ i,LinearMap.range (singleLI μ i).toLinearMap).topologicalClosure + have hclosed : IsClosed (K : Set (Lp (Space ι H) 2 μ)) := Submodule.isClosed_topologicalClosure _ + have : CompleteSpace K := hclosed.completeSpace_coe + have hbot : Kᗮ=⊥ := by + apply le_antisymm ?_ bot_le + intro f hf + rw [Submodule.mem_bot] + apply evalL_separates μ f + intro i + apply (inner_self_eq_zero (𝕜:=ℂ)).mp + rw [←inner_singleL] + exact Submodule.inner_right_of_mem_orthogonal + ((Submodule.le_topologicalClosure _) + ((le_iSup (fun i => LinearMap.range (singleLI μ i).toLinearMap) i) + ⟨evalL μ i f,rfl⟩)) hf + exact le_of_eq ((Submodule.orthogonal_eq_bot_iff).mp hbot).symm + +def infiniteSumEquiv : Space ι (Lp H 2 μ) ≃ₗᵢ[ℂ] Lp (Space ι H) 2 μ := + (IsHilbertSum.mk (singleLI_orthogonal (ι:=ι) μ) (singleLI_total μ)).linearIsometryEquiv.symm + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/L2InfiniteSumCoordinates.lean b/lean/OAI/Analysis/Commutator/L2InfiniteSumCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..d49c6b19e4f91ddca5faf3974614c3ca45639582 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/L2InfiniteSumCoordinates.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableOperator +import OAI.Analysis.Commutator.L2InfiniteSum + +namespace OAI + +noncomputable section + +section + +noncomputable section + +local instance l2InfiniteSumCoordinatesDecidableEq {α : Sort*} : DecidableEq α := Classical.decEq α + +open MeasureTheory Filter + +open scoped InnerProductSpace Topology ENNReal + +namespace Kadison.Decomposable + +open InfiniteAmplification + +variable {Ω H ι : Type*} [MeasurableSpace Ω] (μ : Measure Ω) [Countable ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma infiniteSumEquiv_single (i : ι) (f : Lp H 2 μ) : + infiniteSumEquiv μ (lp.single 2 i f)=singleL μ i f := by + classical + exact IsHilbertSum.linearIsometryEquiv_symm_apply_single _ _ + +lemma evalL_infiniteSumEquiv (i : ι) (f : Space ι (Lp H 2 μ)) : + evalL μ i (infiniteSumEquiv μ f)=f i := by + apply ext_inner_left ℂ + intro g + rw [←inner_singleL,←infiniteSumEquiv_single] + exact ((infiniteSumEquiv (H:=H) (ι:=ι) μ).inner_map_map + (lp.single (E:=fun _ : ι => Lp H 2 μ) 2 i g) f).trans + (lp.inner_single_left (𝕜:=ℂ) i g f) + +variable [TopologicalSpace Ω] [CompactSpace Ω] [BorelSpace Ω] + +def scalarVectorMultiplier (f : C(Ω,ℂ)) : Lp H 2 μ →L[ℂ] Lp H 2 μ := + operator μ (fun x => f x • (1 : H →L[ℂ] H)) + (fun z => f.continuous.aestronglyMeasurable.smul aestronglyMeasurable_const) + (Eventually.of_forall (fun x => by + calc + ‖f x • (1 : H →L[ℂ] H)‖=‖f x‖*‖(1 : H →L[ℂ] H)‖ := norm_smul _ _ + _≤‖f x‖*1 := mul_le_mul_of_nonneg_left ContinuousLinearMap.norm_id_le (norm_nonneg _) + _≤‖f‖ := by simpa using f.norm_coe_le_norm x)) + +lemma scalarVectorMultiplier_ae (f : C(Ω,ℂ)) (v : Lp H 2 μ) : + scalarVectorMultiplier μ f v=ᵐ[μ] fun x => f x • v x := operator_ae .. + +omit [Countable ι] in +lemma evalL_scalarMultiplier (i : ι) (f : C(Ω,ℂ)) (v : Lp (Space ι H) 2 μ) : + evalL μ i (scalarVectorMultiplier μ f v)=scalarVectorMultiplier μ f (evalL μ i v) := by + apply Lp.ext + filter_upwards [ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) + (scalarVectorMultiplier μ f v),scalarVectorMultiplier_ae μ f v, + scalarVectorMultiplier_ae μ f (evalL μ i v), + ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) v] with x h₁ h₂ h₃ h₄ + change ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp (scalarVectorMultiplier μ f v)) x=_ + rw [h₁,h₃] + change (scalarVectorMultiplier μ f v) x i=f x • ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp v) x + rw [h₂,h₄] + rfl + +lemma infiniteSumEquiv_scalar (f : C(Ω,ℂ)) (v : Space ι (Lp H 2 μ)) : + infiniteSumEquiv μ (map (scalarVectorMultiplier μ f) v)= + scalarVectorMultiplier μ f (infiniteSumEquiv μ v) := by + apply sub_eq_zero.mp + apply evalL_separates μ + intro i + rw [map_sub,evalL_infiniteSumEquiv,evalL_scalarMultiplier,evalL_infiniteSumEquiv] + simp only [map_apply,sub_self] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/LittleGrothendieck.lean b/lean/OAI/Analysis/Commutator/LittleGrothendieck.lean new file mode 100644 index 0000000000000000000000000000000000000000..71f1682bf32fd8c1e24af66ba13e3940f8b70435 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/LittleGrothendieck.lean @@ -0,0 +1,169 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open Filter Set + +namespace Kadison.LittleGrothendieck + +lemma second_deriv_nonpos {f : ℝ → ℝ} {t d : ℝ} + (hm : IsLocalMax f t) (hc : ContinuousAt f t) + (h : HasDerivAt (deriv f) d t) : d ≤ 0 := by + by_contra! hd + have hmin := isLocalMin_of_deriv_deriv_pos (by rwa [h.deriv]) hm.deriv_eq_zero hc + have heq : f =ᶠ[𝓝 t] fun _ => f t := by + filter_upwards [hm,hmin] with x hx hy + exact le_antisymm hx hy + have hz := heq.deriv.deriv_eq + rw [h.deriv, deriv_const', deriv_const] at hz + exact (ne_of_gt hd) hz + +variable {A E : Type*} [CStarAlgebra A] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +theorem selfAdjoint_square_at_unitary_max + (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖ ≤ ‖T (u:A)‖) + (a : A) (ha : IsSelfAdjoint a) : + ‖T ((u:A)*a)‖^2 ≤ (inner ℂ (T (u:A)) (T ((u:A)*(a*a)))).re := by + let : InnerProductSpace ℝ E := InnerProductSpace.rclikeToReal ℂ E + let b : A := Complex.I • a + let c : ℝ → A := fun t => (u:A)*NormedSpace.exp (t • b) + have hc (t : ℝ) : HasDerivAt c (c t*b) t := by + simpa only [c, mul_assoc] using (hasDerivAt_exp_smul_const b t).const_mul (u:A) + let v : ℝ → E := fun t => T (c t) + let v' : ℝ → E := fun t => T (c t*b) + have hv (t : ℝ) : HasDerivAt v (v' t) t := by + exact (T.restrictScalars ℝ).hasFDerivAt.comp_hasDerivAt t (hc t) + have hv' (t : ℝ) : HasDerivAt v' (T (c t*b*b)) t := by + exact (T.restrictScalars ℝ).hasFDerivAt.comp_hasDerivAt t ((hc t).mul_const b) + let f : ℝ → ℝ := fun t => ‖v t‖^2 + have hf (t : ℝ) : HasDerivAt f (2*(inner ℂ (v t) (v' t)).re) t := by + simpa only [f, real_inner_eq_re_inner ℂ, ← RCLike.re_to_complex] using (hv t).norm_sq + have hfun : deriv f=fun t => 2*(inner ℂ (v t) (v' t)).re := by + funext t + exact (hf t).deriv + have hsecond : HasDerivAt (deriv f) + (2*((inner ℂ (v' 0) (v' 0)).re+ + (inner ℂ (v 0) (T (c 0*b*b))).re)) 0 := by + rw [hfun] + simpa only [Function.comp_apply, Complex.reCLM_apply, Complex.add_re, add_comm] using + ((Complex.reCLM.hasFDerivAt.comp_hasDerivAt 0 + ((hv 0).inner ℂ (hv' 0))).const_mul 2) + have hmax : IsLocalMax f 0 := by + apply Filter.Eventually.of_forall + intro t + have ht : NormedSpace.exp (t • b) ∈ unitary A := by + change NormedSpace.exp (t • (Complex.I • a)) ∈ unitary A + have hs : IsSelfAdjoint (t • a) := (IsSelfAdjoint.all t).smul ha + rw [smul_comm t Complex.I a] + exact (selfAdjoint.expUnitary (⟨t • a,hs⟩ : selfAdjoint A)).property + have hh := hu (u*⟨NormedSpace.exp (t • b),ht⟩) + apply pow_le_pow_left₀ (norm_nonneg _) ?_ 2 + simpa only [f,v,c,zero_smul,NormedSpace.exp_zero,mul_one,Submonoid.coe_mul] using hh + have hs := second_deriv_nonpos hmax (hf 0).continuousAt hsecond + have hzero : c 0=(u:A) := by simp [c] + have hbb : b*b=-(a*a) := by + simp only [b,smul_mul_assoc,mul_smul_comm,smul_smul,Complex.I_mul_I,neg_one_smul] + have hb2 : c 0*b*b=-((u:A)*(a*a)) := by rw [hzero,mul_assoc,hbb,mul_neg] + have hvzero : v 0=T (u:A) := by simp only [v,hzero] + have hv'zero : v' 0=Complex.I • T ((u:A)*a) := by + simp only [v',hzero,b,mul_smul_comm,map_smul] + rw [hvzero,hv'zero,hb2,map_neg,inner_neg_right,Complex.neg_re] at hs + have hi : (inner ℂ (Complex.I • T ((u:A)*a)) (Complex.I • T ((u:A)*a))).re = + ‖T ((u:A)*a)‖^2 := by simp [norm_smul, ← Complex.ofReal_pow] + rw [hi] at hs + linarith + +theorem square_at_unitary_max + (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖ ≤ ‖T (u:A)‖) (a : A) : + ‖T ((u:A)*a)‖^2 ≤ + (inner ℂ (T (u:A)) (T ((u:A)*(star a*a+a*star a)))).re := by + let h : A := realPart a + let k : A := imaginaryPart a + have hh := selfAdjoint_square_at_unitary_max T u hu h (realPart a).property + have hk := selfAdjoint_square_at_unitary_max T u hu k (imaginaryPart a).property + have hsplit : T ((u:A)*a)=T ((u:A)*h)+Complex.I • T ((u:A)*k) := by + conv_lhs => rw [← realPart_add_I_smul_imaginaryPart a] + simp only [mul_add, mul_smul_comm, map_add, map_smul, h, k] + have hn : ‖T ((u:A)*a)‖ ≤ ‖T ((u:A)*h)‖+‖T ((u:A)*k)‖ := by + rw [hsplit] + simpa only [norm_smul, Complex.norm_I, one_mul] using + norm_add_le (T ((u:A)*h)) (Complex.I • T ((u:A)*k)) + have hs : ‖T ((u:A)*a)‖^2 ≤ 2*(‖T ((u:A)*h)‖^2+‖T ((u:A)*k)‖^2) := by + nlinarith [norm_nonneg (T ((u:A)*h)), norm_nonneg (T ((u:A)*k)), + norm_nonneg (T ((u:A)*a)), sq_nonneg (‖T ((u:A)*h)‖-‖T ((u:A)*k)‖)] + have heq : (inner ℂ (T (u:A)) (T ((u:A)*(star a*a+a*star a)))).re = + 2*((inner ℂ (T (u:A)) (T ((u:A)*(h*h)))).re+ + (inner ℂ (T (u:A)) (T ((u:A)*(k*k)))).re) := by + rw [star_mul_self_add_self_mul_star] + simp only [two_smul, mul_add, map_add, inner_add_right, Complex.add_re, h, k] + ring + rw [heq] + linarith + +theorem sum_sq_le_at_unitary_max {ι : Type*} [Fintype ι] + (T : A →L[ℂ] E) (u : unitary A) + (hu : ∀ v : unitary A, ‖T (v:A)‖ ≤ ‖T (u:A)‖) (a : ι → A) : + ∑ i, ‖T (a i)‖^2 ≤ ‖T‖^2 * (‖∑ i, star (a i)*a i‖+‖∑ i, a i*star (a i)‖) := by + classical + let b : ι → A := fun i => (star u:A)*a i + have hb (i : ι) : (u:A)*b i=a i := by + simp only [b, ← mul_assoc, Unitary.mul_star_self_of_mem u.property, one_mul] + have hpoint (i : ι) := square_at_unitary_max T u hu (b i) + simp only [hb] at hpoint + have hsum := Finset.sum_le_sum (fun i (_ : i ∈ Finset.univ) => hpoint i) + have hinner : (∑ i, (inner ℂ (T (u:A)) + (T ((u:A)*(star (b i)*b i+b i*star (b i))))).re) = + (inner ℂ (T (u:A)) (T ((u:A)*∑ i, (star (b i)*b i+b i*star (b i))))).re := by + simp only [Finset.mul_sum, map_sum, inner_sum, Complex.re_sum] + rw [hinner] at hsum + have hub : ‖T (u:A)‖ ≤ ‖T‖ := by + calc + _ ≤ ‖T‖*‖(u:A)‖ := T.le_opNorm _ + _ ≤ ‖T‖*1 := mul_le_mul_of_nonneg_left (by + cases subsingleton_or_nontrivial A with + | inl h => simpa only [Subsingleton.elim (u:A) 0, norm_zero] using (zero_le_one : (0:ℝ)≤1) + | inr h => exact le_of_eq (CStarRing.norm_coe_unitary u)) (norm_nonneg _) + _ = _ := mul_one _ + have hc : ‖∑ i, star (b i)*b i‖ = ‖∑ i, star (a i)*a i‖ := by + congr 1 + apply Finset.sum_congr rfl + intro i _ + simp only [b, star_mul, star_star, mul_assoc] + rw [← mul_assoc (u:A), Unitary.mul_star_self_of_mem u.property, one_mul] + have hr : ‖∑ i, b i*star (b i)‖ = ‖∑ i, a i*star (a i)‖ := by + have heq : (∑ i, b i*star (b i))=(star u:A)*(∑ i, a i*star (a i))*(u:A) := by + simp only [Finset.mul_sum, Finset.sum_mul, b, star_mul, star_star, mul_assoc] + rw [heq, CStarRing.norm_mul_coe_unitary] + exact CStarRing.norm_coe_unitary_mul (star u) _ + calc + _ ≤ (inner ℂ (T (u:A)) (T ((u:A)*∑ i, (star (b i)*b i+b i*star (b i))))).re := hsum + _ ≤ ‖T (u:A)‖*‖T ((u:A)*∑ i, (star (b i)*b i+b i*star (b i)))‖ := + (Complex.re_le_norm _).trans (norm_inner_le_norm _ _) + _ ≤ ‖T‖*(‖T‖*‖(u:A)*∑ i, (star (b i)*b i+b i*star (b i))‖) := + mul_le_mul hub (T.le_opNorm _) (norm_nonneg _) (norm_nonneg _) + _ = ‖T‖^2*‖∑ i, (star (b i)*b i+b i*star (b i))‖ := by + rw [CStarRing.norm_coe_unitary_mul]; ring + _ ≤ ‖T‖^2*(‖∑ i, star (b i)*b i‖+‖∑ i, b i*star (b i)‖) := by + rw [Finset.sum_add_distrib] + exact mul_le_mul_of_nonneg_left (norm_add_le _ _) (sq_nonneg _) + _ = _ := by rw [hc,hr] + +end Kadison.LittleGrothendieck + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/LittleGrothendieckSequence.lean b/lean/OAI/Analysis/Commutator/LittleGrothendieckSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..ef5b4486ce28e0249f6e266c811a192bd5fbf3c5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/LittleGrothendieckSequence.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertSequence +import OAI.Analysis.Commutator.LittleGrothendieck + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter Set UniformSpace Completion + +namespace Kadison.LittleGrothendieck + +open HilbertSequence + +variable {A E : Type*} [CStarAlgebra A] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +def sequenceLinear (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) : + (ℕ →ᵇ A) →ₗ[ℂ] Pre ω E where + toFun x := ⟨T.compLeftContinuousBounded ℕ x⟩ + map_add' x y := by + apply (equiv ω E).injective + exact map_add (T.compLeftContinuousBounded ℕ) x y + map_smul' z x := by + apply (equiv ω E).injective + exact map_smul (T.compLeftContinuousBounded ℕ) z x + +@[simp] lemma sequenceLinear_seq (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) + (x : ℕ →ᵇ A) (n : ℕ) : (sequenceLinear ω T x).seq n=T (x n) := rfl + +lemma sequenceLinear_bound (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) (x : ℕ →ᵇ A) : + ‖sequenceLinear ω T x‖≤‖T‖*‖x‖ := by + apply le_of_tendsto (tendsto_norm ω E (sequenceLinear ω T x)) + exact Filter.Eventually.of_forall (fun n => (T.le_opNorm (x n)).trans + (mul_le_mul_of_nonneg_left (x.norm_coe_le_norm n) (norm_nonneg _))) + +def sequenceMap (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) : + (ℕ →ᵇ A) →L[ℂ] Space ω E := + (toComplₗᵢ : Pre ω E →ₗᵢ[ℂ] Space ω E).toContinuousLinearMap.comp + ((sequenceLinear ω T).mkContinuous ‖T‖ (sequenceLinear_bound ω T)) + +@[simp] lemma sequenceMap_apply (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) + (x : ℕ →ᵇ A) : sequenceMap ω T x=(sequenceLinear ω T x : Space ω E) := rfl + +lemma sequenceMap_norm_le (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) : + ‖sequenceMap ω T‖≤‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + rw [sequenceMap_apply, Completion.norm_coe] + exact sequenceLinear_bound ω T x + +lemma sequenceMap_norm_tendsto (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) (x : ℕ →ᵇ A) : + Tendsto (fun n => ‖T (x n)‖) (ω : Filter ℕ) (𝓝 ‖sequenceMap ω T x‖) := + norm_coe_tendsto ω E (sequenceLinear ω T x) + +lemma sequenceMap_const (ω : Ultrafilter ℕ) (T : A →L[ℂ] E) (x : A) : + sequenceMap ω T (BoundedContinuousFunction.const ℕ x)=constant ω E (T x) := rfl + +lemma unitary_norm_le_one (u : unitary A) : ‖(u:A)‖≤1 := by + cases subsingleton_or_nontrivial A with + | inl h => simpa only [Subsingleton.elim (u:A) 0,norm_zero] using (zero_le_one : (0:ℝ)≤1) + | inr h => exact le_of_eq (CStarRing.norm_coe_unitary u) + +theorem exists_sequence_unitary_max (T : A →L[ℂ] E) : + ∃ (ω : Ultrafilter ℕ) (u : unitary (ℕ →ᵇ A)), + ∀ v : unitary (ℕ →ᵇ A), ‖sequenceMap ω T (v:ℕ →ᵇ A)‖ ≤ + ‖sequenceMap ω T (u:ℕ →ᵇ A)‖ := by + classical + let S : Set ℝ := range (fun u : unitary A => ‖T (u:A)‖) + have hSne : S.Nonempty := ⟨‖T (1:A)‖,1,rfl⟩ + have hSb : BddAbove S := ⟨‖T‖,by + rintro r ⟨u,rfl⟩ + exact (T.le_opNorm _).trans (by nlinarith [unitary_norm_le_one u, norm_nonneg T])⟩ + obtain ⟨r,_,hr,hmem⟩ := exists_seq_tendsto_sSup hSne hSb + choose u hu using hmem + let U : ℕ →ᵇ A := BoundedContinuousFunction.ofNormedAddCommGroupDiscrete + (fun n => (u n:A)) 1 (fun n => unitary_norm_le_one (u n)) + have hU : U ∈ unitary (ℕ →ᵇ A) := by + constructor <;> apply BoundedContinuousFunction.ext <;> intro n + · exact Unitary.coe_star_mul_self (u n) + · exact Unitary.coe_mul_star_self (u n) + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ)≤atTop := Ultrafilter.of_le _ + have hlim : ‖sequenceMap ω T U‖=sSup S := by + apply tendsto_nhds_unique (sequenceMap_norm_tendsto ω T U) + change Tendsto (fun n => ‖T (u n:A)‖) (ω : Filter ℕ) (𝓝 (sSup S)) + simpa only [hu] using hr.mono_left hω + refine ⟨ω,⟨U,hU⟩,fun v => ?_⟩ + rw [show (⟨U,hU⟩ : unitary (ℕ →ᵇ A)).val=U from rfl,hlim] + apply le_of_tendsto (sequenceMap_norm_tendsto ω T (v:ℕ →ᵇ A)) + apply Filter.Eventually.of_forall + intro n + have hv : (v:ℕ →ᵇ A) n ∈ unitary A := by + constructor + · exact congrArg (fun f : ℕ →ᵇ A => f n) (Unitary.coe_star_mul_self v) + · exact congrArg (fun f : ℕ →ᵇ A => f n) (Unitary.coe_mul_star_self v) + exact le_csSup hSb ⟨⟨(v:ℕ →ᵇ A) n,hv⟩,rfl⟩ + +theorem sum_norm_sq_le {ι : Type*} [Fintype ι] (T : A →L[ℂ] E) (a : ι → A) : + ∑ i, ‖T (a i)‖^2 ≤ ‖T‖^2*(‖∑ i, star (a i)*a i‖+‖∑ i, a i*star (a i)‖) := by + classical + obtain ⟨ω,u,hu⟩ := exists_sequence_unitary_max T + have h := sum_sq_le_at_unitary_max (sequenceMap ω T) u hu + (fun i => BoundedContinuousFunction.const ℕ (a i)) + simp only [sequenceMap_const, LinearIsometry.norm_map] at h + have hc : (∑ i, star (BoundedContinuousFunction.const ℕ (a i))* + BoundedContinuousFunction.const ℕ (a i))= + BoundedContinuousFunction.const ℕ (∑ i, star (a i)*a i) := by + ext n + simp + have hr : (∑ i, BoundedContinuousFunction.const ℕ (a i)* + star (BoundedContinuousFunction.const ℕ (a i)))= + BoundedContinuousFunction.const ℕ (∑ i, a i*star (a i)) := by + ext n + simp + rw [hc,hr,BoundedContinuousFunction.norm_const_eq,BoundedContinuousFunction.norm_const_eq] at h + exact h.trans (mul_le_mul_of_nonneg_right + (pow_le_pow_left₀ (norm_nonneg _) (sequenceMap_norm_le ω T) 2) + (add_nonneg (norm_nonneg _) (norm_nonneg _))) + +end Kadison.LittleGrothendieck + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/LocalQuantization.lean b/lean/OAI/Analysis/Commutator/LocalQuantization.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae575d620fe536a3034c8cd944ed440517a31586 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/LocalQuantization.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteTestPatching +import OAI.Analysis.Commutator.IrreducibleTowerAveraging +import OAI.Analysis.Commutator.MatrixExpectation +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology BigOperators + +open Filter + +namespace Kadison.LocalQuantization + +open TracialGNS + +section Bridge + +variable {A I : Type*} [CStarAlgebra A] [Fintype I] [DecidableEq I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +lemma expectation_eq (x : A) : + FiniteTest.expectation φ x=MatrixExpectation.expectation φ x := by + rw [FiniteTest.expectation,MatrixExpectation.expectation_apply, + RCLike.real_smul_eq_coe_smul (K := ℂ)] + simp only [FiniteTest.unit] + congr 1 + change Complex.ofReal ((Fintype.card I : ℝ)⁻¹)=(Fintype.card I : ℂ)⁻¹ + simp + +variable [PartialOrder A] [StarOrderedRing A] (τ : A →ₚ[ℂ] ℂ) + +lemma vector_eq (a : A) : FiniteTest.vector τ a=algebraVector τ a := rfl + +end Bridge + +section FiniteTests + +variable {A J : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype J] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) (hone : τ 1=1) + +variable {ι : ℕ → Type*} [∀ n, Fintype (ι n)] [∀ n, LinearOrder (ι n)] + [∀ n, Nonempty (ι n)] + +variable (stage : ∀ n, Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] A) + +include hτ hone in +theorem exists_small_projection + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (x : J → A) + (hx : ∀ j, Tendsto (fun n => algebraVector τ (MatrixExpectation.expectation (stage n) (x j))) + atTop (𝓝 0)) + {ε η : ℝ} (hε : 0<ε) (hη : 0<η) : + ∃ (n : ℕ) (q : A), q∈(stage n).range ∧ IsStarProjection q ∧ + 0<(τ q).re ∧ (τ q).re<η ∧ + (∑ j, ‖algebraVector τ (q*x j*q)‖^2)<ε^2*(τ q).re := by + have hinv : Tendsto (fun n => (Fintype.card (ι n):ℝ)⁻¹) atTop (𝓝 0) := + tendsto_inv_atTop_zero.comp hgrow + have hsum : Tendsto + (fun n => ∑ j, ‖algebraVector τ (MatrixExpectation.expectation (stage n) (x j))‖^2) + atTop (𝓝 0) := by + simpa only [norm_zero,zero_pow (by omega : 2≠0),Finset.sum_const_zero] using + tendsto_finsetSum Finset.univ (fun j _ => (hx j).norm.pow 2) + have herr : Tendsto + (fun n => (∑ j, ‖algebraVector τ (MatrixExpectation.expectation (stage n) (x j))‖^2) + + 2*(Fintype.card (ι n):ℝ)⁻¹*(∑ j, ‖algebraVector τ (x j)‖^2)) atTop (𝓝 0) := by + simpa only [mul_zero,zero_mul,add_zero] using + hsum.add ((tendsto_const_nhds.mul hinv).mul_const (∑ j, ‖algebraVector τ (x j)‖^2)) + have hev := (hinv.eventually (gt_mem_nhds hη)).and + (herr.eventually (gt_mem_nhds (sq_pos_of_pos hε))) + obtain ⟨n,hn,herrn⟩ := hev.exists + obtain ⟨q,hq,hproj,htrace,hbound⟩ := + FiniteTest.exists_rankOne_finite_test τ (stage n) hτ hone (Classical.arbitrary (ι n)) x + simp only [vector_eq,expectation_eq] at hbound + have hp : 0<(Fintype.card (ι n):ℝ)⁻¹ := by + exact inv_pos.mpr (by exact_mod_cast Fintype.card_pos) + refine ⟨n,q,hq,hproj,htrace ▸ hp,htrace ▸ hn,?_⟩ + rw [htrace] + calc + _ ≤ (Fintype.card (ι n):ℝ)⁻¹ * + ((∑ j, ‖algebraVector τ (MatrixExpectation.expectation (stage n) (x j))‖^2) + + 2*(Fintype.card (ι n):ℝ)⁻¹*(∑ j, ‖algebraVector τ (x j)‖^2)) := by + nlinarith [hbound] + _ < (Fintype.card (ι n):ℝ)⁻¹*ε^2 := mul_lt_mul_of_pos_left herrn hp + _ = _ := mul_comm _ _ + +end FiniteTests + +section ActualGeometry + +variable {H J : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype J] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +variable {ι : ℕ → Type*} [∀ n, Fintype (ι n)] [∀ n, LinearOrder (ι n)] + [∀ n, Nonempty (ι n)] + +variable (stage : ∀ n, Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ}, n ≤ m → (stage n).range ≤ (stage m).range) + +include hτ hmono in +theorem exists_centered_compression + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ n (x : Matrix (ι n) (ι n) ℂ), stage n x*b=b*stage n x) → + ∃ c : ℂ, b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (x : J → M) (hx : ∀ j, τ (x j)=0) + {ε η : ℝ} (hε : 0<ε) (hη : 0<η) : + ∃ (n : ℕ) (q : M), q∈(stage n).range ∧ IsStarProjection q ∧ + 0<(τ q).re ∧ (τ q).re<η ∧ + (∑ j, ‖algebraVector τ (q*x j*q)‖^2)<ε^2*(τ q).re := by + apply exists_small_projection τ hτ hone stage hgrow x _ hε hη + intro j + simpa only [hx,zero_smul] using + IrreducibleTowerAveraging.expectation_tendsto_any M τ hτ stage hmono + hnormal hfaith hone hirr (x j) + +end ActualGeometry + +end Kadison.LocalQuantization + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/Main.lean b/lean/OAI/Analysis/Commutator/Main.lean new file mode 100644 index 0000000000000000000000000000000000000000..1ce4a0f81764d7f37ca9a19ef40d28560757d30f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/Main.lean @@ -0,0 +1,655 @@ +import OAI.Analysis.Commutator.Definitions +import OAI.Analysis.Commutator.InfiniteAmplification +import OAI.Analysis.Commutator.InfiniteSeparable +import OAI.Analysis.Commutator.InfiniteReindex +import OAI.Analysis.Commutator.CyclicColumnFactorization +import OAI.Analysis.Commutator.CyclicMatrix +import OAI.Analysis.Commutator.TracialDevelopment +import OAI.Analysis.Commutator.TracialConjugation +import OAI.Analysis.Commutator.CenteredSpace +import OAI.Analysis.Commutator.MatrixTrace +import OAI.Analysis.Commutator.MatrixGNS +import OAI.Analysis.Commutator.HilbertTensors +import OAI.Analysis.Commutator.HilbertTensors2 +import OAI.Analysis.Commutator.HilbertTensors3 +import OAI.Analysis.Commutator.HilbertTensors4 +import OAI.Analysis.Commutator.HilbertTensors5 +import OAI.Analysis.Commutator.MultilinearTensors +import OAI.Analysis.Commutator.CoefficientForm +import OAI.Analysis.Commutator.CoefficientForm2 +import OAI.Analysis.Commutator.TensorActions +import OAI.Analysis.Commutator.SchurWeylDevelopment +import OAI.Analysis.Commutator.InvariantForms +import OAI.Analysis.Commutator.CycleInvariants +import OAI.Analysis.Commutator.CycleInvariants2 +import OAI.Analysis.Commutator.CycleInvariants3 +import OAI.Analysis.Commutator.MatrixModules +import OAI.Analysis.Commutator.MatrixClassification +import OAI.Analysis.Commutator.RectangularTensors +import OAI.Analysis.Commutator.CycleEmbeddings +import OAI.Analysis.Commutator.CycleEmbeddings2 +import OAI.Analysis.Commutator.EndpointGNS +import OAI.Analysis.Commutator.TensorDevelopment +import OAI.Analysis.Commutator.EndpointModule +import OAI.Analysis.Commutator.EndpointModule2 +import OAI.Analysis.Commutator.EndpointGNS2 +import OAI.Analysis.Commutator.EndpointElimination +import OAI.Analysis.Commutator.EndpointElimination2 +import OAI.Analysis.Commutator.EndpointElimination3 +import OAI.Analysis.Commutator.CycleEndpoint +import OAI.Analysis.Commutator.EndpointRankOne +import OAI.Analysis.Commutator.FreeSymmetry +import OAI.Analysis.Commutator.Pairings +import OAI.Analysis.Commutator.PairTrace +import OAI.Analysis.Commutator.PairTrace2 +import OAI.Analysis.Commutator.CyclePairTrace +import OAI.Analysis.Commutator.CyclePairTrace2 +import OAI.Analysis.Commutator.CyclePairTrace3 +import OAI.Analysis.Commutator.HermitianAlphabet +import OAI.Analysis.Commutator.HermitianAlphabet2 +import OAI.Analysis.Commutator.FinitePairings +import OAI.Analysis.Commutator.FinitePairings2 +import OAI.Analysis.Commutator.FinitePairings3 +import OAI.Analysis.Commutator.FreeSymmetry2 +import OAI.Analysis.Commutator.CrossingPairings +import OAI.Analysis.Commutator.FreeSymmetry3 +import OAI.Analysis.Commutator.FreeSymmetry4 +import OAI.Analysis.Commutator.FreeSymmetry5 +import OAI.Analysis.Commutator.FreeSymmetry6 +import OAI.Analysis.Commutator.WordTopology +import OAI.Analysis.Commutator.WordTopology2 +import OAI.Analysis.Commutator.WordTopology3 +import OAI.Analysis.Commutator.TensorPermutations +import OAI.Analysis.Commutator.TensorPermutations2 +import OAI.Analysis.Commutator.WordPermutations +import OAI.Analysis.Commutator.StageDensity +import OAI.Analysis.Commutator.FreeSymmetry7 +import OAI.Analysis.Commutator.TensorMultiplicity +import OAI.Analysis.Commutator.TensorMultiplicity2 +import OAI.Analysis.Commutator.FreeSymmetry8 +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.StageGeneration +import OAI.Analysis.Commutator.TensorAdjoints +import OAI.Analysis.Commutator.FreeSymmetry9 +import OAI.Analysis.Commutator.FreeMoments +import OAI.Analysis.Commutator.FreeWordTensor +import OAI.Analysis.Commutator.FreeWordDecomposition +import OAI.Analysis.Commutator.FreeCreation +import OAI.Analysis.Commutator.FreeBlockWords +import OAI.Analysis.Commutator.FreeBlockWords2 +import OAI.Analysis.Commutator.FreeBlockTensor +import OAI.Analysis.Commutator.FreeBlockTensor2 +import OAI.Analysis.Commutator.FreeBlockTensor3 +import OAI.Analysis.Commutator.FreeBlockTensor4 +import OAI.Analysis.Commutator.TensorCompletion +import OAI.Analysis.Commutator.Regroup +import OAI.Analysis.Commutator.FreeSymmetry10 +import OAI.Analysis.Commutator.CompletionCentered +import OAI.Analysis.Commutator.FreeSymmetry11 +import OAI.Analysis.Commutator.TensorPowerCompletion +import OAI.Analysis.Commutator.FreeSymmetry12 +import OAI.Analysis.Commutator.FreeSymmetry13 +import OAI.Analysis.Commutator.FreeSymmetry14 +import OAI.Analysis.Commutator.FreeSymmetry15 +import OAI.Analysis.Commutator.HilbertDiagonal +import OAI.Analysis.Commutator.InvariantSum +import OAI.Analysis.Commutator.FreeCovariance +import OAI.Analysis.Commutator.FreeSymmetry16 +import OAI.Analysis.Commutator.OperatorAmplification +import OAI.Analysis.Commutator.KaplanskySelfAdjoint +import OAI.Analysis.Commutator.KaplanskyRational +import OAI.Analysis.Commutator.KaplanskyDensity +import OAI.Analysis.Commutator.CStarRangeLifts +import OAI.Analysis.Commutator.KaplanskyRange +import OAI.Analysis.Commutator.KaplanskyStarHomNet +import OAI.Analysis.Commutator.WeakOperatorLimit +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.VonNeumannCStar +import OAI.Analysis.Commutator.NormalOperatorHom +import OAI.Analysis.Commutator.TracialCommutation +import OAI.Analysis.Commutator.TracialRightClosure +import OAI.Analysis.Commutator.NormalGNS +import OAI.Analysis.Commutator.NormalGNSContinuity +import OAI.Analysis.Commutator.HilbertBiprod +import OAI.Analysis.Commutator.NormalBiprodGNS +import OAI.Analysis.Commutator.HilbertBiprodProjections +import OAI.Analysis.Commutator.DiagonalBlockCommutant +import OAI.Analysis.Commutator.PolarDecomposition +import OAI.Analysis.Commutator.PolarSupport +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.RepresentedFactorTransport +import OAI.Analysis.Commutator.PolarExtension +import OAI.Analysis.Commutator.PartialIsometryOrder +import OAI.Analysis.Commutator.PartialIsometryMaximal +import OAI.Analysis.Commutator.FactorComparison +import OAI.Analysis.Commutator.OrthogonalLinkFamily +import OAI.Analysis.Commutator.OrthogonalLinkSums +import OAI.Analysis.Commutator.NormalRepresentationLinks +import OAI.Analysis.Commutator.FullCentralSupportLinks +import OAI.Analysis.Commutator.ScalarUltralimit +import OAI.Analysis.Commutator.HilbertSequence +import OAI.Analysis.Commutator.HilbertSequenceOperator +import OAI.Analysis.Commutator.MatrixCornerHilbert +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.ReducingRepresentation +import OAI.Analysis.Commutator.TracialSequence +import OAI.Analysis.Commutator.TracialSequenceRight +import OAI.Analysis.Commutator.TracialSequenceTrace +import OAI.Analysis.Commutator.StandardTrace +import OAI.Analysis.Commutator.FaithfulNormalRepresentationLinks +import OAI.Analysis.Commutator.HilbertFiniteMaps +import OAI.Analysis.Commutator.BiprodLinkColumn +import OAI.Analysis.Commutator.InfiniteLinkColumn +import OAI.Analysis.Commutator.CountableOrthogonal +import OAI.Analysis.Commutator.WOTCompact +import OAI.Analysis.Commutator.WOTBallSeparable +import OAI.Analysis.Commutator.NormalGNSSeparable +import OAI.Analysis.Commutator.NormalRepresentationColumns +import OAI.Analysis.Commutator.CountableGNSColumn +import OAI.Analysis.Commutator.FaithfulNormalFunctional +import OAI.Analysis.Commutator.FaithfulNormalStateProducer +import OAI.Analysis.Commutator.FreeCompressionNorm +import OAI.Analysis.Commutator.FejerTest +import OAI.Analysis.Commutator.FiniteHankel +import OAI.Analysis.Commutator.ReducingCompression +import OAI.Analysis.Commutator.GNSVectorEmbedding +import OAI.Analysis.Commutator.FaithfulVectorGNS +import OAI.Analysis.Commutator.ProjectionChains +import OAI.Analysis.Commutator.ProjectionStrong +import OAI.Analysis.Commutator.ProjectionShift +import OAI.Analysis.Commutator.FiniteCancellation +import OAI.Analysis.Commutator.ProjectionEquivalence +import OAI.Analysis.Commutator.ProjectionSchroederBernstein +import OAI.Analysis.Commutator.HilbertModuleSchroederBernstein +import OAI.Analysis.Commutator.StableGNSModule +import OAI.Analysis.Commutator.InfiniteUnitary +import OAI.Analysis.Commutator.DecomposableOperator +import OAI.Analysis.Commutator.DecomposableNorm +import OAI.Analysis.Commutator.L2InfiniteSum +import OAI.Analysis.Commutator.CyclicSpectralMeasure +import OAI.Analysis.Commutator.CyclicSpectralNorm +import OAI.Analysis.Commutator.CyclicSpectralUnitary +import OAI.Analysis.Commutator.L2InfiniteSumCoordinates +import OAI.Analysis.Commutator.StableSpectralUnitary +import OAI.Analysis.Commutator.AbelianGNSMaximal +import OAI.Analysis.Commutator.CyclicGelfandModel +import OAI.Analysis.Commutator.FiniteFunctionalFactorization +import OAI.Analysis.Commutator.FiniteSupportFactorization +import OAI.Analysis.Commutator.WOTFunctionals +import OAI.Analysis.Commutator.ArvesonAnnihilator +import OAI.Analysis.Commutator.ArvesonDistance +import OAI.Analysis.Commutator.CyclicCb +import OAI.Analysis.Commutator.ModuleZeroExtension +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.CornerCyclic +import OAI.Analysis.Commutator.ConcreteCornerVonNeumann +import OAI.Analysis.Commutator.SpectralCutoff +import OAI.Analysis.Commutator.DyadicSpectral +import OAI.Analysis.Commutator.ProjectionPartition +import OAI.Analysis.Commutator.SelfAdjointSpectral +import OAI.Analysis.Commutator.ProjectionCommutant +import OAI.Analysis.Commutator.FiniteFactorComparison +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.MinimalProjection +import OAI.Analysis.Commutator.MinimalCorner +import OAI.Analysis.Commutator.LittleGrothendieck +import OAI.Analysis.Commutator.ColumnModule +import OAI.Analysis.Commutator.LittleGrothendieckSequence +import OAI.Analysis.Commutator.ColumnEstimate +import OAI.Analysis.Commutator.RectangularColumn +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.ReducingMatrix +import OAI.Analysis.Commutator.DiagonalVonNeumann +import OAI.Analysis.Commutator.MatrixAlgebraDensity +import OAI.Analysis.Commutator.KaplanskyFull +import OAI.Analysis.Commutator.KaplanskyFullRange +import OAI.Analysis.Commutator.HilbertPair +import OAI.Analysis.Commutator.MatrixEntryWOT +import OAI.Analysis.Commutator.RowOperator +import OAI.Analysis.Commutator.CFCIntertwiner +import OAI.Analysis.Commutator.CFCTraceMoments +import OAI.Analysis.Commutator.BalancedDefect +import OAI.Analysis.Commutator.BalancedSymmetry +import OAI.Analysis.Commutator.BlockDilationBound +import OAI.Analysis.Commutator.IsometryCompression +import OAI.Analysis.Commutator.HilbertPadding +import OAI.Analysis.Commutator.AmplificationIsometry +import OAI.Analysis.Commutator.FaithfulPositive +import OAI.Analysis.Commutator.MatrixVectorTrace +import OAI.Analysis.Commutator.MatrixTraceFaithful +import OAI.Analysis.Commutator.MatrixFlatten +import OAI.Analysis.Commutator.MatrixScalar +import OAI.Analysis.Commutator.PositiveExtensionReal +import OAI.Analysis.Commutator.PositiveExtensionComplex +import OAI.Analysis.Commutator.OperatorSystem +import OAI.Analysis.Commutator.TwoByTwoPositive +import OAI.Analysis.Commutator.PaulsenSystem +import OAI.Analysis.Commutator.SchurTransfer +import OAI.Analysis.Commutator.PaulsenPositive +import OAI.Analysis.Commutator.ChoiFunctional +import OAI.Analysis.Commutator.ChoiGNS +import OAI.Analysis.Commutator.ChoiRecovery +import OAI.Analysis.Commutator.CpCompression +import OAI.Analysis.Commutator.ArvesonFinite +import OAI.Analysis.Commutator.StinespringKernel +import OAI.Analysis.Commutator.StinespringAction +import OAI.Analysis.Commutator.StinespringRepresentation +import OAI.Analysis.Commutator.StinespringDilation +import OAI.Analysis.Commutator.CpMapOperations +import OAI.Analysis.Commutator.ArvesonCorner +import OAI.Analysis.Commutator.CpUltralimit +import OAI.Analysis.Commutator.ArvesonExtension +import OAI.Analysis.Commutator.HilbertMatrixCorner +import OAI.Analysis.Commutator.PaulsenExtension +import OAI.Analysis.Commutator.PaulsenDilation +import OAI.Analysis.Commutator.CbDilation +import OAI.Analysis.Commutator.TriangularCb +import OAI.Analysis.Commutator.FactorGeneratedSpace +import OAI.Analysis.Commutator.FactorMetric +import OAI.Analysis.Commutator.GramBounds +import OAI.Analysis.Commutator.TriangularMetric +import OAI.Analysis.Commutator.CbDerivation +import OAI.Analysis.Commutator.CyclicCbUnconditional +import OAI.Analysis.Commutator.CbDerivationQuantitative +import OAI.Analysis.Commutator.CyclicDecomposition +import OAI.Analysis.Commutator.DerivationCyclicColumns +import OAI.Analysis.Commutator.KaplanskyNet +import OAI.Analysis.Commutator.NormalGNSClosure +import OAI.Analysis.Commutator.MatrixExpectation +import OAI.Analysis.Commutator.MatrixDiagonal +import OAI.Analysis.Commutator.NormalTraceProjection +import OAI.Analysis.Commutator.ProjectionRounding +import OAI.Analysis.Commutator.EqualTraceRefinement +import OAI.Analysis.Commutator.ProjectionWeighted +import OAI.Analysis.Commutator.SpectralStep +import OAI.Analysis.Commutator.MatrixUnits +import OAI.Analysis.Commutator.FiniteFactorMatrices +import OAI.Analysis.Commutator.MatrixApproximation +import OAI.Analysis.Commutator.MatrixScalarApproximation +import OAI.Analysis.Commutator.RelativeMatrix +import OAI.Analysis.Commutator.NormalSubalgebra +import OAI.Analysis.Commutator.MatrixTensor +import OAI.Analysis.Commutator.MatrixExpectationNested +import OAI.Analysis.Commutator.MatrixStageExtension +import OAI.Analysis.Commutator.MatrixTower +import OAI.Analysis.Commutator.MatrixTowerIrreducible +import OAI.Analysis.Commutator.MatrixTowerClosure +import OAI.Analysis.Commutator.FiniteTrace +import OAI.Analysis.Commutator.MatrixDiffuse +import OAI.Analysis.Commutator.MatrixColumnCorner +import OAI.Analysis.Commutator.MatrixTowerDiffuse +import OAI.Analysis.Commutator.IrreducibleMatrixTower +import OAI.Analysis.Commutator.MatrixTowerGNS +import OAI.Analysis.Commutator.DerivationKaplansky +import OAI.Analysis.Commutator.CentralCorner +import OAI.Analysis.Commutator.AbelianGNSSpectral +import OAI.Analysis.Commutator.ScalarIndicator +import OAI.Analysis.Commutator.MaximalAbelianTransport +import OAI.Analysis.Commutator.AbelianSpectralIndicators +import OAI.Analysis.Commutator.StableCentralSpectral +import OAI.Analysis.Commutator.StableScalarGeometry +import OAI.Analysis.Commutator.InfiniteDiagonalRange +import OAI.Analysis.Commutator.InfiniteCenter +import OAI.Analysis.Commutator.MainCommutantDistance +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.EquivariantBicommutant +import OAI.Analysis.Commutator.UnitaryMainTransport +import OAI.Analysis.Commutator.UnitaryCenterTransport +import OAI.Analysis.Commutator.StableCenterRange +import OAI.Analysis.Commutator.CentralSpectralGeometry +import OAI.Analysis.Commutator.RationalDense +import OAI.Analysis.Commutator.PointwiseLinearLift +import OAI.Analysis.Commutator.DiagonalCommute +import OAI.Analysis.Commutator.L2FiniteSum +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.StrongContractionLimit +import OAI.Analysis.Commutator.FiberCommutator +import OAI.Analysis.Commutator.MatrixField +import OAI.Analysis.Commutator.DiagonalField +import OAI.Analysis.Commutator.PositiveWOT +import OAI.Analysis.Commutator.PositiveCauchySchwarz +import OAI.Analysis.Commutator.InverseLimit +import OAI.Analysis.Commutator.WeightedSubsequence +import OAI.Analysis.Commutator.SmoothingSubsequence +import OAI.Analysis.Commutator.SpectralThreshold +import OAI.Analysis.Commutator.SpectralThresholdBounds +import OAI.Analysis.Commutator.SpectralExhaustion +import OAI.Analysis.Commutator.SpectralCompression +import OAI.Analysis.Commutator.ProjectionNormalPositive +import OAI.Analysis.Commutator.ProjectionNormalStrong +import OAI.Analysis.Commutator.FiniteStrongTest +import OAI.Analysis.Commutator.FiniteTestHahnBanach +import OAI.Analysis.Commutator.NormalPredual +import OAI.Analysis.Commutator.ProjectionNormalBridge +import OAI.Analysis.Commutator.SquareZeroPolar +import OAI.Analysis.Commutator.SquareZeroMaximal +import OAI.Analysis.Commutator.DiffuseHalving +import OAI.Analysis.Commutator.EqualProjectionPartition +import OAI.Analysis.Commutator.PartialDecomposition +import OAI.Analysis.Commutator.ProperIsometryReplicas +import OAI.Analysis.Commutator.ReplicaPacking +import OAI.Analysis.Commutator.OrthogonalCountability +import OAI.Analysis.Commutator.PartialDecompositionCountable +import OAI.Analysis.Commutator.FiniteNoReplicas +import OAI.Analysis.Commutator.DyadicCuts +import OAI.Analysis.Commutator.ProjectionAddition +import OAI.Analysis.Commutator.DyadicPartition +import OAI.Analysis.Commutator.ProjectionSumEquivalence +import OAI.Analysis.Commutator.EqualPartitionSums +import OAI.Analysis.Commutator.PartitionRankComparison +import OAI.Analysis.Commutator.PartitionRank +import OAI.Analysis.Commutator.DyadicRankStep +import OAI.Analysis.Commutator.DyadicDimension +import OAI.Analysis.Commutator.ProjectionComplements +import OAI.Analysis.Commutator.OrthogonalRank +import OAI.Analysis.Commutator.DyadicDimensionAdd +import OAI.Analysis.Commutator.DyadicDimensionComparison +import OAI.Analysis.Commutator.CoherentComparison +import OAI.Analysis.Commutator.DyadicDimensionNormal +import OAI.Analysis.Commutator.ProjectionJoin +import OAI.Analysis.Commutator.CountableProjectionJoin +import OAI.Analysis.Commutator.ProjectionDimensionTopology +import OAI.Analysis.Commutator.ProjectionDimensionUnitary +import OAI.Analysis.Commutator.WeakDualHull +import OAI.Analysis.Commutator.OrbitStateHull +import OAI.Analysis.Commutator.UnitaryDualAction +import OAI.Analysis.Commutator.CompactInvariant +import OAI.Analysis.Commutator.MinimalOrbit +import OAI.Analysis.Commutator.BaireSmallPiece +import OAI.Analysis.Commutator.MinimalNormCompact +import OAI.Analysis.Commutator.DeMarrCenter +import OAI.Analysis.Commutator.NormSeparableFixedPoint +import OAI.Analysis.Commutator.OrbitFixedTrace +import OAI.Analysis.Commutator.TraceDimension +import OAI.Analysis.Commutator.ProjectionFaithfulFunctional +import OAI.Analysis.Commutator.NormalizedTrace +import OAI.Analysis.Commutator.FiniteFactorTrace +import OAI.Analysis.Commutator.BiprodLinkEmpty +import OAI.Analysis.Commutator.FreeAction +import OAI.Analysis.Commutator.FreeActionCovariance +import OAI.Analysis.Commutator.StrongContinuity +import OAI.Analysis.Commutator.HilbertStrong +import OAI.Analysis.Commutator.FreeActionGroup +import OAI.Analysis.Commutator.FreeActionBlock +import OAI.Analysis.Commutator.FreeInnerFamily +import OAI.Analysis.Commutator.FreeLetterIntertwine +import OAI.Analysis.Commutator.FreeActionUnitary +import OAI.Analysis.Commutator.FreeActualCovariance +import OAI.Analysis.Commutator.FreeActualStructure +import OAI.Analysis.Commutator.FreePropagation +import OAI.Analysis.Commutator.FreeRepeatedWords +import OAI.Analysis.Commutator.FreePropagationEstimate +import OAI.Analysis.Commutator.CyclicImplementationUnconditional +import OAI.Analysis.Commutator.EmbeddedCyclicImplementation +import OAI.Analysis.Commutator.HilbertModuleExtension +import OAI.Analysis.Commutator.MatrixCornerExtension +import OAI.Analysis.Commutator.CornerCyclicImplementation +import OAI.Analysis.Commutator.CyclicLocalModule +import OAI.Analysis.Commutator.RepresentedLocalModule +import OAI.Analysis.Commutator.FreePropagationCorner +import OAI.Analysis.Commutator.MatrixProjectionDiagonal +import OAI.Analysis.Commutator.MatrixCutEmbedding +import OAI.Analysis.Commutator.MatrixUnitaryAlphabet +import OAI.Analysis.Commutator.CornerAlphabetGNS +import OAI.Analysis.Commutator.WeakZeroSelection +import OAI.Analysis.Commutator.CornerWeakZero +import OAI.Analysis.Commutator.FreePropagationStage +import OAI.Analysis.Commutator.SubfactorExpectation +import OAI.Analysis.Commutator.HankelAlgebra +import OAI.Analysis.Commutator.DihedralHaar +import OAI.Analysis.Commutator.AlgebraFreeExpectation +import OAI.Analysis.Commutator.DihedralCompressionMoments +import OAI.Analysis.Commutator.DihedralExpectationEntries +import OAI.Analysis.Commutator.DihedralFejer +import OAI.Analysis.Commutator.FreeHilbertEntries +import OAI.Analysis.Commutator.FreeDihedralEntries +import OAI.Analysis.Commutator.FreeNormalizedColumns +import OAI.Analysis.Commutator.FreeDihedralColumns +import OAI.Analysis.Commutator.FreeFejerNorm +import OAI.Analysis.Commutator.FreeHankelEntries +import OAI.Analysis.Commutator.FreeHankelBound +import OAI.Analysis.Commutator.WeakOperatorIntegral +import OAI.Analysis.Commutator.Average +import OAI.Analysis.Commutator.CompactAverage +import OAI.Analysis.Commutator.WeakConvergence +import OAI.Analysis.Commutator.StageAverage +import OAI.Analysis.Commutator.CornerSymmetrization +import OAI.Analysis.Commutator.FreeStageHankel +import OAI.Analysis.Commutator.ConjugationNormalizer +import OAI.Analysis.Commutator.FreeNormalizer +import OAI.Analysis.Commutator.MatrixCompactGroup +import OAI.Analysis.Commutator.FreeSymmetrization +import OAI.Analysis.Commutator.FreeStageAverage +import OAI.Analysis.Commutator.NormalCornerExtension +import OAI.Analysis.Commutator.NormalFreeCorner +import OAI.Analysis.Commutator.FreeBaseCompression +import OAI.Analysis.Commutator.FreeOriginalBound +import OAI.Analysis.Commutator.UltrafilterDiagonal +import OAI.Analysis.Commutator.BoundedSequenceClosed +import OAI.Analysis.Commutator.TracialUltrapower +import OAI.Analysis.Commutator.CStarContractiveLifts +import OAI.Analysis.Commutator.TracialSequenceCompression +import OAI.Analysis.Commutator.TracialUltrapowerTransfer +import OAI.Analysis.Commutator.TracialVectorSubalgebra +import OAI.Analysis.Commutator.GNSCornerTransport +import OAI.Analysis.Commutator.BoundedPositiveSequence +import OAI.Analysis.Commutator.ProjectionLifts +import OAI.Analysis.Commutator.TracialSmallCorners +import OAI.Analysis.Commutator.TracialGNSCorners +import OAI.Analysis.Commutator.VectorFreeGeneration +import OAI.Analysis.Commutator.MatrixStageGNSGeneration +import OAI.Analysis.Commutator.VectorStageGeneration +import OAI.Analysis.Commutator.RepresentedCornerBound +import OAI.Analysis.Commutator.VectorFreeOriginalBound +import OAI.Analysis.Commutator.TracialRangeCommutation +import OAI.Analysis.Commutator.TracialDoubleCompression +import OAI.Analysis.Commutator.TracialRepresentedCorner +import OAI.Analysis.Commutator.TracialFreeOriginal +import OAI.Analysis.Commutator.FreeMomentsTransport +import OAI.Analysis.Commutator.GeneratedFreePair +import OAI.Analysis.Commutator.TracialGeneratedAlgebra +import OAI.Analysis.Commutator.TracialGeneratedFreeBound +import OAI.Analysis.Commutator.TracialFreePositionCriterion +import OAI.Analysis.Commutator.MatrixVonNeumann +import OAI.Analysis.Commutator.MatrixAlgebraEquiv +import OAI.Analysis.Commutator.MatrixNormalTrace +import OAI.Analysis.Commutator.MatrixInclusion +import OAI.Analysis.Commutator.MatrixRowCorner +import OAI.Analysis.Commutator.MatrixCornerInclusion +import OAI.Analysis.Commutator.MatrixCommute +import OAI.Analysis.Commutator.FiniteFactorUnitary +import OAI.Analysis.Commutator.FiniteFactorCornerTransport +import OAI.Analysis.Commutator.FiniteSmallCorner +import OAI.Analysis.Commutator.FiniteMatrixSmallCorner +import OAI.Analysis.Commutator.GNSVectorUnitary +import OAI.Analysis.Commutator.MatrixGNSUnitary +import OAI.Analysis.Commutator.UnitaryCommuteNorm +import OAI.Analysis.Commutator.MatrixGNSCornerBound +import OAI.Analysis.Commutator.MatrixGNSRealCorner +import OAI.Analysis.Commutator.MatrixFreeSymmetry +import OAI.Analysis.Commutator.NormalOriginalTower +import OAI.Analysis.Commutator.MatrixTowerInclusion +import OAI.Analysis.Commutator.UnitaryHaar +import OAI.Analysis.Commutator.FiniteDimensionalAverage +import OAI.Analysis.Commutator.MatrixTowerAverage +import OAI.Analysis.Commutator.RepresentedTowerAverage +import OAI.Analysis.Commutator.NormalCopiesAverage +import OAI.Analysis.Commutator.FiniteSquareConditionalBound +import OAI.Analysis.Commutator.MatrixFlattenRepresentation +import OAI.Analysis.Commutator.DoubleCopies +import OAI.Analysis.Commutator.FiniteSquareContraction +import OAI.Analysis.Commutator.MatrixPadding +import OAI.Analysis.Commutator.RightCopies +import OAI.Analysis.Commutator.FiniteRectangularContraction +import OAI.Analysis.Commutator.HomogeneousBound +import OAI.Analysis.Commutator.FiniteRectangularBound +import OAI.Analysis.Commutator.FiniteStandardGauge +import OAI.Analysis.Commutator.FiniteStandardRange +import OAI.Analysis.Commutator.FiniteStandardRepresented +import OAI.Analysis.Commutator.FiniteStandardMainInterface +import OAI.Analysis.Commutator.GeneratedMatrixBicommutant +import OAI.Analysis.Commutator.ConstantSequenceRange +import OAI.Analysis.Commutator.TraceFaithfulHomInjective +import OAI.Analysis.Commutator.PartialUnitaryAlgebra +import OAI.Analysis.Commutator.TracialL2Tools +import OAI.Analysis.Commutator.PartialUnitaryOrder +import OAI.Analysis.Commutator.TracialL2Continuity +import OAI.Analysis.Commutator.PartialUnitaryCompletion +import OAI.Analysis.Commutator.FiniteWordTelescoping +import OAI.Analysis.Commutator.PartialUnitaryWords +import OAI.Analysis.Commutator.CornerCenteredEstimates +import OAI.Analysis.Commutator.PartialWordPerturbation +import OAI.Analysis.Commutator.PartialWordReindex +import OAI.Analysis.Commutator.PartialUnitaryHom +import OAI.Analysis.Commutator.UnitarySequence +import OAI.Analysis.Commutator.PartialWordContinuity +import OAI.Analysis.Commutator.WordCoefficientContinuity +import OAI.Analysis.Commutator.WordScaling +import OAI.Analysis.Commutator.ConjugatedWordAlgebra +import OAI.Analysis.Commutator.ConjugatedFreeness +import OAI.Analysis.Commutator.RelativeSequenceRange +import OAI.Analysis.Commutator.FreeSequenceUnitary +import OAI.Analysis.Commutator.FreeMomentsMonotone +import OAI.Analysis.Commutator.AbstractFreeCornerFromUnitary +import OAI.Analysis.Commutator.TraceEquivGNS +import OAI.Analysis.Commutator.ConstantSequenceClosedTransport +import OAI.Analysis.Commutator.UnitaryEquivMoments +import OAI.Analysis.Commutator.ConvexIsometryFix +import OAI.Analysis.Commutator.NormalRelativeCommutant +import OAI.Analysis.Commutator.IrreducibleTowerAveraging +import OAI.Analysis.Commutator.FiniteTestPatching +import OAI.Analysis.Commutator.LocalQuantization +import OAI.Analysis.Commutator.CornerPolarAlgebra +import OAI.Analysis.Commutator.CornerPolarTransfer +import OAI.Analysis.Commutator.RelativeCornerQuantization +import OAI.Analysis.Commutator.CornerPhaseAveraging +import OAI.Analysis.Commutator.CornerPhaseSelectionCore +import OAI.Analysis.Commutator.RelativeCornerPhase +import OAI.Analysis.Commutator.BoundedWordPool +import OAI.Analysis.Commutator.FiniteWordPatchProducer +import OAI.Analysis.Commutator.ExponentialMomentBudget +import OAI.Analysis.Commutator.PartialMomentBudget +import OAI.Analysis.Commutator.PartialUnitaryChain +import OAI.Analysis.Commutator.FiniteWordMaximalPatching +import OAI.Analysis.Commutator.FiniteTestCompletion +import OAI.Analysis.Commutator.FiniteFullUnitaryTests +import OAI.Analysis.Commutator.CountableUnitaryTests +import OAI.Analysis.Commutator.CenteredContractionDensity +import OAI.Analysis.Commutator.AllUnitaryTests +import OAI.Analysis.Commutator.RelativeEquivFreePosition +import OAI.Analysis.Commutator.MatrixIndexEquiv +import OAI.Analysis.Commutator.NormalizedTowerFreePosition +import OAI.Analysis.Commutator.MatrixDiffuseTransfer +import OAI.Analysis.Commutator.AmplifiedTowerStage +import OAI.Analysis.Commutator.MatrixTensorRange +import OAI.Analysis.Commutator.AmplifiedTowerGeometry +import OAI.Analysis.Commutator.MatrixStandardForm +import OAI.Analysis.Commutator.MatrixFreePositionProducer +import OAI.Analysis.Commutator.FiniteStandardUnconditional +import OAI.Analysis.Commutator.IntertwinerCompression +import OAI.Analysis.Commutator.IntertwinerSeminorm +import OAI.Analysis.Commutator.IntertwinerMatrixTransfer +import OAI.Analysis.Commutator.RepresentationMatrixNorm +import OAI.Analysis.Commutator.FiniteStandardCompression +import OAI.Analysis.Commutator.AmplifiedStrongLimit +import OAI.Analysis.Commutator.NormalTracedFactorMain +import OAI.Analysis.Commutator.TracedSeparableFactorMain +import OAI.Analysis.Commutator.AtomicDecomposition +import OAI.Analysis.Commutator.AtomicCoefficients +import OAI.Analysis.Commutator.AtomicFinite +import OAI.Analysis.Commutator.AtomicShift +import OAI.Analysis.Commutator.AtomicInfinite +import OAI.Analysis.Commutator.FiniteDimensionalMain +import OAI.Analysis.Commutator.ProperlyInfinite +import OAI.Analysis.Commutator.ProperlyInfiniteBound +import OAI.Analysis.Commutator.TwoIsometries +import OAI.Analysis.Commutator.ProperlyInfiniteMain +import OAI.Analysis.Commutator.AtomicFactorMain +import OAI.Analysis.Commutator.NonfiniteFactor +import OAI.Analysis.Commutator.SeparableFactorMain +import OAI.Analysis.Commutator.FactorFieldBound +import OAI.Analysis.Commutator.UnitaryOrbitHull +import OAI.Analysis.Commutator.CentralPinching +import OAI.Analysis.Commutator.CentralAverage +import OAI.Analysis.Commutator.FactorFieldLocalization +import OAI.Analysis.Commutator.FiniteVectorLpConvergence +import OAI.Analysis.Commutator.DenseFieldClosure +import OAI.Analysis.Commutator.DecomposableLimit +import OAI.Analysis.Commutator.ScalarField +import OAI.Analysis.Commutator.FieldMembership +import OAI.Analysis.Commutator.FactorModelMain +import OAI.Analysis.Commutator.FieldAdjoint +import OAI.Analysis.Commutator.ScalarIndicatorAdjoint +import OAI.Analysis.Commutator.StarField +import OAI.Analysis.Commutator.AddField +import OAI.Analysis.Commutator.FieldAlgebra +import OAI.Analysis.Commutator.TightField +import OAI.Analysis.Commutator.FieldNormClosure +import OAI.Analysis.Commutator.DecomposableDenseLimit +import OAI.Analysis.Commutator.FieldBicommutant +import OAI.Analysis.Commutator.FieldUniqueness +import OAI.Analysis.Commutator.RankOneFactor +import OAI.Analysis.Commutator.FiberFactorProducer +import OAI.Analysis.Commutator.DenseCommutes +import OAI.Analysis.Commutator.FiberCommutes +import OAI.Analysis.Commutator.CentralGeometryModel +import OAI.Analysis.Commutator.StrongDenseTests +import OAI.Analysis.Commutator.CountableStarHomTests +import OAI.Analysis.Commutator.RepresentationFieldTests +import OAI.Analysis.Commutator.CentralRepresentationModel +import OAI.Analysis.Commutator.RationalStarExtension +import OAI.Analysis.Commutator.CountableStrongTests +import OAI.Analysis.Commutator.CountablyGeneratedCStar +import OAI.Analysis.Commutator.DenseRationalStar +import OAI.Analysis.Commutator.StarHomFieldRaw +import OAI.Analysis.Commutator.CountableFieldHom +import OAI.Analysis.Commutator.StarHomFieldLip +import OAI.Analysis.Commutator.PointwiseStarHom +import OAI.Analysis.Commutator.ClosedCStarOrder +import OAI.Analysis.Commutator.CentralSpectralModel +import OAI.Analysis.Commutator.UnitaryBoundTransfer +import OAI.Analysis.Commutator.StableModelBound +import OAI.Analysis.Commutator.InfiniteBoundTransfer +import OAI.Analysis.Commutator.SeparableReducingHull +import OAI.Analysis.Commutator.SeparableTestGeometry +import OAI.Analysis.Commutator.SeparableBoundTransfer +import OAI.Analysis.Commutator.SeparableSmall +import OAI.Analysis.Commutator.SeparableUniverseTransfer +import OAI.Analysis.Commutator.StableUniversalAssembly +import OAI.Analysis.Commutator.UniversalMain +import OAI.Analysis.Commutator.DerivationMatrixColumns +import OAI.Analysis.Commutator.MatrixReindexBound +import OAI.Analysis.Commutator.DerivationBoundTransfer +import OAI.Analysis.Commutator.AllDerivationsMain +import OAI.Analysis.Commutator.BiprodLinkIntertwining +import OAI.Analysis.Commutator.MetricSimilarity +import OAI.Analysis.Commutator.UniformCommutantApproximation +import OAI.Analysis.Commutator.CbSimilarity +import OAI.Analysis.Commutator.TracialDCorner +import OAI.Analysis.Commutator.FreeCornerFromUnitary +import OAI.Analysis.Commutator.CornerPhaseSelection +import OAI.Analysis.Commutator.RelativeTowerFreePosition +import OAI.Analysis.Commutator.DecomposableConstLimit +import OAI.Analysis.Commutator.SimilarityMidpointObstruction +import OAI.Analysis.Commutator.TracialConstantFreeObstruction +import OAI.Analysis.Commutator.CyclicCorner +import OAI.Analysis.Commutator.CentralBlockEstimate +import OAI.Analysis.Commutator.CentralAtoms +import OAI.Analysis.Commutator.AtomicCenterMain +import OAI.Analysis.Commutator.CyclicCornerRepresentation +import OAI.Analysis.Commutator.CommutatorBicommutant +import OAI.Analysis.Commutator.ProjectionBlocks +import OAI.Analysis.Commutator.AmplifiedProjectionBlocks +import OAI.Analysis.Commutator.FreePositionObstruction +import OAI.Analysis.Commutator.NonseparableReduction +import OAI.Analysis.Commutator.HaarSequence +import OAI.Analysis.Commutator.TracialRelativeCommutant +import OAI.Analysis.Commutator.HilbertBlocks +import OAI.Analysis.Commutator.CyclicMatrixApproximation +import OAI.Analysis.Commutator.CornerHaarSequence +import OAI.Analysis.Commutator.TensorPermutations3 +import OAI.Analysis.Commutator.PairingElimination +import OAI.Analysis.Commutator.TracialAdjoint +import OAI.Analysis.Commutator.PairingOperators +import OAI.Analysis.Commutator.FreeExpectation diff --git a/lean/OAI/Analysis/Commutator/MainCommutantDistance.lean b/lean/OAI/Analysis/Commutator/MainCommutantDistance.lean new file mode 100644 index 0000000000000000000000000000000000000000..701f5eb1c2ffb9524b6d681cf2fed3b1d2c9ffc6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MainCommutantDistance.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.MainMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +open ContinuousLinearMap + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +omit [CompleteSpace K] in +lemma diagonalAmplification_norm_le (h : ℕ) (Y : K →L[ℂ] K) : + ‖diagonalAmplification h Y‖≤‖Y‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg Y) + intro x + have hs : ‖diagonalAmplification h Y x‖^2≤(‖Y‖*‖x‖)^2 := by + rw [PiLp.norm_sq_eq_of_L2,mul_pow,PiLp.norm_sq_eq_of_L2,Finset.mul_sum] + exact Finset.sum_le_sum (fun i _ => by + rw [diagonalAmplification_apply,←mul_pow] + exact pow_le_pow_left₀ (norm_nonneg _) (le_opNorm Y (x i)) 2) + exact (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg Y) (norm_nonneg x))).mp hs + +omit [CompleteSpace K] in +@[simp] lemma diagonalAmplification_sub (h : ℕ) (Y Z : K →L[ℂ] K) : + diagonalAmplification h (Y-Z)=diagonalAmplification h Y-diagonalAmplification h Z := by + ext x i + simp + +omit [CompleteSpace K] in +lemma diagonal_matrix_commute (h : ℕ) (Z : K →L[ℂ] K) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) + (hZ : ∀ i j,Z*X i j=X i j*Z) : + diagonalAmplification h Z*matrixOperator h X=matrixOperator h X*diagonalAmplification h Z := by + ext x i + simp only [mul_apply_eq_comp,diagonalAmplification_apply,matrixOperator_apply,map_sum] + apply Finset.sum_congr rfl + intro j _ + exact congrArg (fun A : K →L[ℂ] K => A (x j)) (hZ i j) + +omit [CompleteSpace K] in +lemma operator_commutator_norm_le (Y Z : K →L[ℂ] K) : ‖Y*Z-Z*Y‖≤2*‖Y‖*‖Z‖ := by + calc + _ ≤ ‖Y*Z‖+‖Z*Y‖ := norm_sub_le _ _ + _ ≤ ‖Y‖*‖Z‖+‖Z‖*‖Y‖ := add_le_add (norm_mul_le _ _) (norm_mul_le _ _) + _ = _ := by ring + +theorem matrix_commutator_bound_of_commutant_approximation + (P : VonNeumannAlgebra K) (Y Z : K →L[ℂ] K) {c : ℝ} (hc : ‖Y-Z‖≤c) + (hZ : ∀ a : P,Z*(a:K →L[ℂ] K)=(a:K →L[ℂ] K)*Z) + (h : ℕ) (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ ≤ + 2*c*‖matrixOperator h X‖ := by + have hcomm := diagonal_matrix_commute h Z X (fun i j => hZ ⟨X i j,hX i j⟩) + have he : diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y= + diagonalAmplification h (Y-Z)*matrixOperator h X-matrixOperator h X*diagonalAmplification h (Y-Z) := by + rw [diagonalAmplification_sub,sub_mul,mul_sub,hcomm] + abel + rw [he] + exact (operator_commutator_norm_le _ _).trans (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left ((diagonalAmplification_norm_le h (Y-Z)).trans hc) (by norm_num)) + (norm_nonneg _)) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MainMatrix.lean b/lean/OAI/Analysis/Commutator/MainMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..426173dd00ab88d71992530931d80e55d94641aa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MainMatrix.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.Commutator.Definitions +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +universe u + +open scoped InnerProductSpace BigOperators ComplexOrder + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma commutator_ball_bdd (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + BddAbove {r : ℝ | ∃ a : K →L[ℂ] K, a∈P ∧ ‖a‖ ≤ 1 ∧ r=‖Y*a-a*Y‖} := by + refine ⟨2*‖Y‖,?_⟩ + rintro r ⟨a,_,ha,rfl⟩ + calc + ‖Y*a-a*Y‖ ≤ ‖Y*a‖+‖a*Y‖ := norm_sub_le _ _ + _ ≤ ‖Y‖*‖a‖+‖a‖*‖Y‖ := add_le_add (norm_mul_le _ _) (norm_mul_le _ _) + _ ≤ 2*‖Y‖ := by nlinarith [norm_nonneg Y] + +lemma commutatorSeminorm_nonneg (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + 0 ≤ commutatorSeminorm P Y := + le_csSup (commutator_ball_bdd P Y) ⟨0,zero_mem P,by simp,by simp⟩ + +lemma commutator_bound_unitball (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) + {a : K →L[ℂ] K} (ha : a∈P) (hn : ‖a‖ ≤ 1) : + ‖Y*a-a*Y‖ ≤ commutatorSeminorm P Y := + le_csSup (commutator_ball_bdd P Y) ⟨a,ha,hn,rfl⟩ + +lemma commutator_bound (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) + {a : K →L[ℂ] K} (ha : a∈P) : + ‖Y*a-a*Y‖ ≤ commutatorSeminorm P Y*‖a‖ := by + by_cases hz : a=0 + · simp [hz] + have hpos := norm_pos_iff.mpr hz + have hn : ‖((‖a‖⁻¹:ℝ):ℂ) • a‖ ≤ 1 := by + rw [norm_smul,Complex.norm_real,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hpos),inv_mul_cancel₀ hpos.ne'] + have hb := commutator_bound_unitball P Y (P.toStarSubalgebra.smul_mem ha (((‖a‖⁻¹:ℝ):ℂ))) hn + have he : Y*(((‖a‖⁻¹:ℝ):ℂ) • a)-(((‖a‖⁻¹:ℝ):ℂ) • a)*Y=((‖a‖⁻¹:ℝ):ℂ) • (Y*a-a*Y) := by + simp only [mul_smul_comm,smul_mul_assoc,smul_sub] + rw [he,norm_smul,Complex.norm_real,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hpos)] at hb + have hh := mul_le_mul_of_nonneg_left hb hpos.le + rw [←mul_assoc,mul_inv_cancel₀ hpos.ne',one_mul] at hh + simpa only [mul_comm ‖a‖] using hh + +def innerDerivation (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + P →L[ℂ] (K →L[ℂ] K) := + ({ toFun := fun a => Y*(a:K →L[ℂ] K)-(a:K →L[ℂ] K)*Y + map_add' := by + intro a b + change Y*((a:K →L[ℂ] K)+b)-((a:K →L[ℂ] K)+b)*Y= + (Y*a-(a:K →L[ℂ] K)*Y)+(Y*b-(b:K →L[ℂ] K)*Y) + noncomm_ring + map_smul' := by + intro c a + change Y*(c • (a:K →L[ℂ] K))-(c • (a:K →L[ℂ] K))*Y=c • (Y*a-(a:K →L[ℂ] K)*Y) + simp only [mul_smul_comm,smul_mul_assoc,smul_sub] } : + P →ₗ[ℂ] (K →L[ℂ] K)).mkContinuous (commutatorSeminorm P Y) + (fun a => commutator_bound P Y a.property) + +@[simp] lemma innerDerivation_apply (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) (a : P) : + innerDerivation P Y a=Y*(a:K →L[ℂ] K)-(a:K →L[ℂ] K)*Y := rfl + +lemma innerDerivation_norm_le (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + ‖innerDerivation P Y‖ ≤ commutatorSeminorm P Y := + ContinuousLinearMap.opNorm_le_bound _ (commutatorSeminorm_nonneg P Y) + (fun a => commutator_bound P Y a.property) + +lemma innerDerivation_mul (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) (a b : P) : + innerDerivation P Y (a*b)=(innerDerivation P Y a).comp (b:K →L[ℂ] K)+ + (a:K →L[ℂ] K).comp (innerDerivation P Y b) := by + change Y*((a:K →L[ℂ] K)*b)-(a:K →L[ℂ] K)*b*Y= + (Y*a-(a:K →L[ℂ] K)*Y)*b+(a:K →L[ℂ] K)*(Y*b-(b:K →L[ℂ] K)*Y) + noncomm_ring + +omit [CompleteSpace K] in +@[simp] lemma diagonalAmplification_apply (h : ℕ) (Y : K →L[ℂ] K) + (x : PiLp 2 (fun _ : Fin h => K)) (i : Fin h) : diagonalAmplification h Y x i=Y (x i) := by + simp [diagonalAmplification] + +omit [CompleteSpace K] in +@[simp] lemma matrixOperator_apply (h : ℕ) (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) + (x : PiLp 2 (fun _ : Fin h => K)) (i : Fin h) : matrixOperator h X x i=∑ j,X i j (x j) := by + simp [matrixOperator] + +lemma diagonalAmplification_adjoint (h : ℕ) (Y : K →L[ℂ] K) : + (diagonalAmplification h Y).adjoint=diagonalAmplification h Y.adjoint := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [PiLp.inner_apply,diagonalAmplification_apply,ContinuousLinearMap.adjoint_inner_left] + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixAlgebraDensity.lean b/lean/OAI/Analysis/Commutator/MatrixAlgebraDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..01070ce738ca52c8f9b31ab47a505268cd3e5d3b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixAlgebraDensity.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.Commutator.DiagonalVonNeumann +import OAI.Analysis.Commutator.CyclicSpatialImplementation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +open CyclicColumns CyclicSpatial + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] + +local instance matrixAlgebraDensityDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (S : StarSubalgebra ℂ (H →L[ℂ] H)) [IsClosed (S : Set (H →L[ℂ] H))] + +local instance : PartialOrder S := CStarAlgebra.spectralOrder S + +local instance : StarOrderedRing S := CStarAlgebra.spectralOrderedRing S + +def fullMatrixAlgebra : StarSubalgebra ℂ (SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) := + (matrixRepresentation (ι:=ι) S.subtype).range + +lemma fullMatrixAlgebra_closed : IsClosed (fullMatrixAlgebra ι S : + Set (SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι)) := by + exact (NonUnitalStarAlgHom.isometry (matrixRepresentation (ι:=ι) S.subtype) + (matrixRepresentation_injective S.subtype Subtype.val_injective)).isClosedEmbedding.isClosed_range + +lemma entry_represented (X : CStarMatrix ι ι S) (i j : ι) : + entry ι (matrixRepresentation S.subtype X) i j=(X i j:H →L[ℂ] H) := by + ext x + simp [entry_apply,represented_matrix_apply,single_apply,apply_ite] + +lemma mem_fullMatrixAlgebra_iff (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) : + T∈fullMatrixAlgebra ι S ↔ ∀ i j, entry ι T i j∈S := by + constructor + · rintro ⟨X,rfl⟩ i j + change entry ι (matrixRepresentation S.subtype X) i j ∈ S + rw [entry_represented] + exact (X i j).property + · intro h + let X : CStarMatrix ι ι S := CStarMatrix.ofMatrix (fun i j => ⟨entry ι T i j,h i j⟩) + refine ⟨X,?_⟩ + change CyclicColumns.matrixAction (entry ι T)=T + exact reconstruct ι T + +lemma diagonal_mem_fullMatrixAlgebra {a : H →L[ℂ] H} (ha : a∈S) : + diagonal (H:=H) ι a∈fullMatrixAlgebra ι S := by + rw [mem_fullMatrixAlgebra_iff] + intro i j + have he : entry ι (diagonal (H:=H) ι a) i j=if i=j then a else 0 := by + ext x + by_cases hij : i=j <;> simp [entry_apply,diagonal_apply,single_apply,hij] + rw [he] + split_ifs <;> simp_all + +lemma matrixUnit_mem_fullMatrixAlgebra (i j : ι) : + matrixUnit (H:=H) ι i j∈fullMatrixAlgebra ι S := by + rw [mem_fullMatrixAlgebra_iff] + intro k l + have he : entry ι (matrixUnit (H:=H) ι i j) k l=if k=i ∧ j=l then 1 else 0 := by + ext x + by_cases hki : k=i <;> by_cases hjl : j=l <;> + simp [entry_apply,matrixUnit_apply,single_apply,hki,hjl] + rw [he] + split_ifs <;> simp + +lemma bicommutant_fullMatrix_of_entries (i₀ : ι) + (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (hT : ∀ i j, entry ι T i j∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + T∈Set.centralizer (Set.centralizer (fullMatrixAlgebra ι S : + Set (SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι))) := by + intro R hR + have hU : ∀ i j, matrixUnit ι i j*R=R*matrixUnit ι i j := + fun i j => hR _ (matrixUnit_mem_fullMatrixAlgebra ι S i j) + have he := diagonal_of_matrixUnits ι i₀ R hU + let a := entry ι R i₀ i₀ + have ha : a∈Set.centralizer (S : Set (H →L[ℂ] H)) := by + intro b hb + exact entry_commutes ι R b (hR _ (diagonal_mem_fullMatrixAlgebra ι S hb)) i₀ i₀ + rw [he] + exact commutes_of_entries ι T a (fun i j => hT i j a ha) + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixAlgebraEquiv.lean b/lean/OAI/Analysis/Commutator/MatrixAlgebraEquiv.lean new file mode 100644 index 0000000000000000000000000000000000000000..7deed226fdf7e8edc813b8a348cd5a41e554a6a8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixAlgebraEquiv.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixVonNeumann + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def rangeRestriction {B : Type*} [CStarAlgebra B] + (P : VonNeumannAlgebra H) (φ : B →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hφ : ∀ b,φ b∈P) : B →⋆ₐ[ℂ] P := + φ.codRestrict P.toStarSubalgebra hφ + +variable (ι : Type*) [Fintype ι] (i₀ : ι) (M : VonNeumannAlgebra H) + +local instance : DecidableEq ι := Classical.decEq ι + +lemma entry_matrixRepresentation (X : CStarMatrix ι ι M) (i j : ι) : + entry ι (CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype X) i j= + (X i j:H →L[ℂ] H) := by + ext x + simp only [entry_apply,CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply, + StarAlgHom.coe_mk] + simp [apply_ite] + rfl + +def matrixHom : CStarMatrix ι ι M →⋆ₐ[ℂ] matrixVonNeumann ι i₀ M := + rangeRestriction (matrixVonNeumann ι i₀ M) + (CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype) + (matrix_representation_mem ι i₀ M) + +lemma coe_matrixHom (X : CStarMatrix ι ι M) : + (matrixHom ι i₀ M X:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι)= + CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype X := rfl + +lemma matrixHom_bijective : Function.Bijective (matrixHom ι i₀ M) := by + constructor + · intro X Y h + apply CStarMatrix.ext + intro i j + apply Subtype.ext + have he := congrArg (fun T : matrixVonNeumann ι i₀ M => + entry ι (T:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i j) h + simpa only [coe_matrixHom,entry_matrixRepresentation] using he + · intro T + obtain ⟨X,hX⟩ := matrixVonNeumann_is_range ι i₀ M T T.property + exact ⟨X,Subtype.ext hX⟩ + +def matrixEquiv : CStarMatrix ι ι M ≃⋆ₐ[ℂ] matrixVonNeumann ι i₀ M := + StarAlgEquiv.ofBijective (matrixHom ι i₀ M) (matrixHom_bijective ι i₀ M) + +lemma matrixEquiv_apply (X : CStarMatrix ι ι M) : + matrixEquiv ι i₀ M X=matrixHom ι i₀ M X := rfl + +lemma matrixEquiv_symm_entry (T : matrixVonNeumann ι i₀ M) (i j : ι) : + ((matrixEquiv ι i₀ M).symm T i j:H →L[ℂ] H)= + entry ι (T:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i j := by + rw [←entry_matrixRepresentation] + have h := congrArg (fun X : matrixVonNeumann ι i₀ M => + entry ι (X:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i j) + ((matrixEquiv ι i₀ M).apply_symm_apply T) + exact h + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixApproximation.lean b/lean/OAI/Analysis/Commutator/MatrixApproximation.lean new file mode 100644 index 0000000000000000000000000000000000000000..b40c10454efa914eb9b86cbc62f483e52f438eae --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixApproximation.lean @@ -0,0 +1,147 @@ +import Mathlib +import OAI.Analysis.Commutator.EqualTraceRefinement +import OAI.Analysis.Commutator.FiniteFactorMatrices +import OAI.Analysis.Commutator.SpectralStep + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.MatrixApproximation + +open TracialGNS ProjectionSum + +section Norm + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) + +lemma vector_norm_le (hone : τ 1=1) (a : A) : ‖algebraVector τ a‖≤‖a‖ := by + rw [algebraVector_apply,←left_vacuum] + calc + _≤‖τ.gnsStarAlgHom a‖*‖vacuum τ‖ := ContinuousLinearMap.le_opNorm _ _ + _≤‖a‖ := by rw [vacuum_norm τ hone,mul_one]; exact NonUnitalStarAlgHom.norm_apply_le _ a + +lemma step_error {J : Type*} [Fintype J] (p s : J → A) (c : J → ℝ) + (hp : ∀ j,IsStarProjection (p j)) (hs : ∀ j,IsStarProjection (s j)) + (hsp : ∀ j,s j ≤ p j) {d : ℝ} (hd : 0≤d) + (ht : ∀ j,(τ (p j-s j)).re≤d^2) : + ‖algebraVector τ ((∑ j,(c j:ℂ) • p j)-(∑ j,(c j:ℂ) • s j))‖≤(∑ j,‖c j‖)*d := by + have hn (j : J) : ‖algebraVector τ (p j-s j)‖≤d := by + have hproj := ((hs j).le_iff_sub (hp j)).mp (hsp j) + have hsq := vector_projection_norm_sq τ hproj + have hn0 := norm_nonneg (algebraVector τ (p j-s j)) + nlinarith [ht j] + rw [←Finset.sum_sub_distrib] + simp only [←smul_sub,map_sum,map_smul] + calc + _≤∑ j,‖(c j:ℂ) • algebraVector τ (p j-s j)‖ := norm_sum_le _ _ + _≤∑ j,‖c j‖*d := Finset.sum_le_sum (fun j _ => by + rw [norm_smul,Complex.norm_real] + exact mul_le_mul_of_nonneg_left (hn j) (norm_nonneg _)) + _=(∑ j,‖c j‖)*d := (Finset.sum_mul _ _ _).symm + +end Norm + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + +include hτ hnormal hfaith hone in +theorem exists_matrix_approximation (hfac : FactorCorner.IsFactor M) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) (y : M) (hy : IsSelfAdjoint y) + {ε : ℝ} (hε : 0<ε) : + ∃ (I : Type) (_ : Fintype I) (_ : DecidableEq I) (_ : Nonempty I) + (φ : Matrix I I ℂ →⋆ₐ[ℂ] M) (x : Matrix I I ℂ), + Function.Injective φ ∧ 2≤Fintype.card I ∧ ‖algebraVector τ (y-φ x)‖<ε := by + classical + obtain ⟨J,hJ,p,c,hp,ho,hpsum,he⟩ := + SpectralPartition.exists_spectral_step_subtype M y hy (half_pos hε) + let : Fintype J := hJ + let C : ℝ := ∑ j,‖c j‖ + let d : ℝ := ε/(2*(C+1)) + have hC : 0≤C := Finset.sum_nonneg (fun j _ => norm_nonneg _) + have hd : 0 (τ a).re) hqs + rw [map_sum,hone,Complex.one_re] at hh + change Complex.reAddGroupHom (∑ i,τ (q i))=1 at hh + rw [map_sum] at hh + change (∑ i,(τ (q i)).re)=1 at hh + simpa only [hq,Finset.sum_const,Finset.card_univ,nsmul_eq_mul,mul_one_div] using hh + have hcardNat : Fintype.card I=b := by + have hh := (div_eq_one_iff_eq (ne_of_gt hbR)).mp hcard + exact_mod_cast hh + have hcard0 : 0 (hq i).1) heq hqo hqs + have hadj : StarAlgebra.adjoin ℂ (Set.range q)≤φ.range := by + apply StarAlgebra.adjoin_le + rintro a ⟨i,rfl⟩ + exact ⟨Matrix.single i i 1,hφ i⟩ + have hmem : (∑ j,(c j:ℂ) • s j)∈φ.range := by + apply φ.range.sum_mem + intro j hj + exact φ.range.smul_mem (hadj (hs j).2.2.2) _ + obtain ⟨x,hx⟩ := hmem + change φ x=(∑ j,(c j:ℂ) • s j) at hx + have hneq : (0:M)≠1 := by + intro hz + have ht := congrArg τ hz + rw [map_zero,hone] at ht + exact zero_ne_one ht + let : Nontrivial M := ⟨⟨0,1,hneq⟩⟩ + refine ⟨I,hI,inferInstance,inferInstance,φ,x,φ.toAlgHom.toRingHom.injective,?_,?_⟩ + · rw [hcardNat]; omega + · rw [hx] + have herr := step_error τ p s c hp (fun j => (hs j).1) (fun j => (hs j).2.1) + hd.le (fun j => ((hs j).2.2.1.trans hbd).le) + have hCd : C*d<ε/2 := by + have hh : d*(2*(C+1))=ε := div_mul_cancel₀ _ (by positivity) + nlinarith + calc + _≤‖algebraVector τ (y-∑ j,(c j:ℂ) • p j)‖+ + ‖algebraVector τ ((∑ j,(c j:ℂ) • p j)-(∑ j,(c j:ℂ) • s j))‖ := by + rw [map_sub,map_sub,map_sub] + exact norm_sub_le_norm_sub_add_norm_sub _ _ _ + _≤‖y-∑ j,(c j:ℂ) • p j‖+C*d := add_le_add (vector_norm_le τ hone _) herr + _<ε := by linarith + +end Kadison.MatrixApproximation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixClassification.lean b/lean/OAI/Analysis/Commutator/MatrixClassification.lean new file mode 100644 index 0000000000000000000000000000000000000000..58aa48737a22f1b9cacdb0b025fb5087a79bb922 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixClassification.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixModules + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.MatrixModules + +open Matrix + +variable {𝕜 I K R : Type*} [Field 𝕜] + [Fintype I] [DecidableEq I] [Fintype K] [DecidableEq K] + [Fintype R] [DecidableEq R] + +variable (φ : Matrix I I 𝕜 →ₐ[𝕜] Matrix K K 𝕜) (o : I) + +abbrev matrixRepresentation : Matrix I I 𝕜 →ₐ[𝕜] Module.End 𝕜 (K → 𝕜) := + Matrix.toLinAlgEquiv'.toAlgHom.comp φ + +noncomputable def coordinateEquiv + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : + (I × R → 𝕜) ≃ₗ[𝕜] (K → 𝕜) := representationEquiv (matrixRepresentation φ) o b + +noncomputable def forwardMatrix + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : Matrix K (I × R) 𝕜 := + LinearMap.toMatrix' (coordinateEquiv φ o b).toLinearMap + +noncomputable def backwardMatrix + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : Matrix (I × R) K 𝕜 := + LinearMap.toMatrix' (coordinateEquiv φ o b).symm.toLinearMap + +lemma backward_forward + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : + backwardMatrix φ o b * forwardMatrix φ o b = 1 := by + unfold backwardMatrix forwardMatrix + rw [← LinearMap.toMatrix'_comp] + have h : (coordinateEquiv φ o b).symm.toLinearMap.comp + (coordinateEquiv φ o b).toLinearMap = LinearMap.id := by ext x; simp + rw [h, LinearMap.toMatrix'_id] + +lemma forward_backward + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : + forwardMatrix φ o b * backwardMatrix φ o b = 1 := by + unfold backwardMatrix forwardMatrix + rw [← LinearMap.toMatrix'_comp] + have h : (coordinateEquiv φ o b).toLinearMap.comp + (coordinateEquiv φ o b).symm.toLinearMap = LinearMap.id := by ext x; simp + rw [h, LinearMap.toMatrix'_id] + +lemma classification + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) (a : Matrix I I 𝕜) : + φ a = (HMul.hMul (self := Matrix.instHMulOfFintypeOfMulOfAddCommMonoid) + (forwardMatrix φ o b) (inflate (R := R) a) : Matrix K (I × R) 𝕜) * backwardMatrix φ o b := by + apply Matrix.toLin'.injective + rw [Matrix.toLin'_mul, Matrix.toLin'_mul] + apply LinearMap.ext + intro x + simp only [LinearMap.comp_apply, forwardMatrix, backwardMatrix, + Matrix.toLin'_toMatrix', LinearEquiv.coe_coe] + change (matrixRepresentation φ a) x = _ + have h := representationEquiv_intertwines (matrixRepresentation φ) o b a + ((coordinateEquiv φ o b).symm x) + simpa only [coordinateEquiv, LinearEquiv.apply_symm_apply, Matrix.toLin'_apply] using h + +omit [DecidableEq R] in +lemma dimensions + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : + Fintype.card I * Fintype.card R = Fintype.card K := by + simpa only [Module.finrank_fintype_fun_eq_card, Fintype.card_prod] using + (coordinateEquiv φ o b).finrank_eq + +omit [DecidableEq R] in +lemma multiplicity_nonempty [Nonempty K] + (b : Module.Basis R 𝕜 (corner (matrixRepresentation φ) o)) : Nonempty R := by + apply Fintype.card_pos_iff.mp + have h := dimensions φ o b + have hK := Fintype.card_pos (α := K) + nlinarith + +end Kadison.MatrixModules +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixColumnCorner.lean b/lean/OAI/Analysis/Commutator/MatrixColumnCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8904fd1e912b93b5bc5cf97d2e26b9dad35914c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixColumnCorner.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.MatrixDiffuse + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.MatrixColumnCorner + +variable {I D : Type*} [Fintype I] [DecidableEq I] [Nonempty I] [CStarAlgebra D] + +omit [Nonempty I] in +lemma minimal_projection (i : I) : IsStarProjection (Matrix.single i i (1:ℂ)) := by + constructor <;> simp [IsIdempotentElem,IsSelfAdjoint,Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single] + +omit [Nonempty I] in +lemma full_column (φ : Matrix I I ℂ →⋆ₐ[ℂ] D) (i0 : I) : + (∀ i j, star (φ (Matrix.single i i0 1))*φ (Matrix.single j i0 1)= + if i=j then φ (Matrix.single i0 i0 1) else 0) ∧ + (∀ i, φ (Matrix.single i0 i0 1)*star (φ (Matrix.single i i0 1))= + star (φ (Matrix.single i i0 1))) ∧ + ∑ i,φ (Matrix.single i i0 1)*star (φ (Matrix.single i i0 1))=1 := by + constructor + · intro i j + rw [←map_star,←map_mul] + by_cases hij : i=j + · subst j; simp [Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single] + · simp [Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single,hij] + constructor + · intro i + rw [←map_star,←map_mul] + simp [Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single] + · simp only [←map_star,←map_mul,Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single,star_one, + Matrix.single_mul_single_same,one_mul,←map_sum,Matrix.sum_single_one,map_one] + +lemma trace_minimal [PartialOrder D] [StarOrderedRing D] + (τ : D →ₚ[ℂ] ℂ) (hτ : ∀ a b, τ (a*b)=τ (b*a)) (h1 : τ 1=1) + (φ : Matrix I I ℂ →⋆ₐ[ℂ] D) (i : I) : + τ (φ (Matrix.single i i 1))=(Fintype.card I : ℂ)⁻¹ := + MatrixDiffuse.diagonal_trace (τ.toLinearMap.comp φ.toLinearMap) + (fun x y => by change τ (φ (x*y))=τ (φ (y*x)); simpa only [map_mul] using hτ (φ x) (φ y)) + (by change τ (φ 1)=1; simpa only [map_one] using h1) i + +lemma exists_small_stage (J : ℕ → Type*) [∀ n, Fintype (J n)] [∀ n, Nonempty (J n)] + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (J m)) {β : ℝ} (hβ : 0<β) : + ∃ n, (Fintype.card (J n) : ℝ)⁻¹ ≤ β := by + obtain ⟨q,hq⟩ := exists_nat_gt β⁻¹ + obtain ⟨n,_,hn⟩ := hsize 0 q + refine ⟨n,?_⟩ + have hcard : (0:ℝ) rw [projection_symmetry_selfadjoint hp,projection_symmetry_square hp]⟩ + +@[simp] lemma projectionSymmetry_coe : (projectionSymmetry hp : A)=p+p-1 := rfl + +lemma projectionSymmetry_half : p=(1/2:ℂ) • (1+(projectionSymmetry hp:A)) := by + rw [projectionSymmetry_coe,show (1:A)+(p+p-1)=p+p by abel,←two_smul ℂ p,smul_smul] + norm_num + +lemma projectionSymmetry_left : p*(projectionSymmetry hp:A)=p := by + rw [projectionSymmetry_coe,mul_sub,mul_add,hp.isIdempotentElem.eq,mul_one] + abel + +lemma projectionSymmetry_right : (projectionSymmetry hp:A)*p=p := by + rw [projectionSymmetry_coe,sub_mul,add_mul,hp.isIdempotentElem.eq,one_mul] + abel + +omit hp in +lemma unitary_dihedral {d s : unitary A} (hd : (d:A)*(d:A)=1) (hs : (s:A)*(s:A)=1) : + MulAut.conj d (d*s)=(d*s)⁻¹ := by + have hd' : d*d=1 := Subtype.ext hd + have hs' : s*s=1 := Subtype.ext hs + have hdi : d⁻¹=d := inv_eq_of_mul_eq_one_right hd' + have hsi : s⁻¹=s := inv_eq_of_mul_eq_one_right hs' + simp only [MulAut.conj_apply,mul_inv_rev,hdi,hsi] + rw [←mul_assoc,hd',one_mul] + +lemma isStarProjection_corner {e : Corner hp} (he : IsStarProjection (e:A)) : + IsStarProjection e := by + constructor + · exact Subtype.ext he.isIdempotentElem.eq + · exact Subtype.ext he.isSelfAdjoint.star_eq + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCommute.lean b/lean/OAI/Analysis/Commutator/MatrixCommute.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d35a2d24e8e8cde3dc5f49a95d216f780a1d4cd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCommute.lean @@ -0,0 +1,40 @@ +import Mathlib +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A ι H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype ι] [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +local instance : DecidableEq ι := Classical.decEq ι + +lemma diagonal_commutes_matrixRepresentation (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (T : H →L[ℂ] H) (X : CStarMatrix ι ι A) + (hT : ∀ i j,T*σ (X i j)=σ (X i j)*T) : + OperatorAmplification.diagonal (H:=H) ι T*matrixRepresentation σ X= + matrixRepresentation σ X*OperatorAmplification.diagonal (H:=H) ι T := by + ext v i + simp only [mul_apply_eq_comp,OperatorAmplification.diagonal_apply,matrixRepresentation, + StarAlgHom.coe_mk,matrixAction_apply,map_sum] + apply Finset.sum_congr rfl + intro j _ + exact congrArg (fun R : H →L[ℂ] H => R (v j)) (hT i j) + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCompactGroup.lean b/lean/OAI/Analysis/Commutator/MatrixCompactGroup.lean new file mode 100644 index 0000000000000000000000000000000000000000..4b72a486581bb2839f827c6af66a88767b5a356f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCompactGroup.lean @@ -0,0 +1,55 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Matrix.Norms.L2Operator + +open MeasureTheory MeasureTheory.Measure TopologicalSpace + +namespace Kadison + +variable {ι : Type*} [Fintype ι] [DecidableEq ι] + +lemma matrix_unitary_compact : IsCompact (unitary (Matrix ι ι ℂ) : Set (Matrix ι ι ℂ)) := by + have hb : Bornology.IsBounded (unitary (Matrix ι ι ℂ) : Set (Matrix ι ι ℂ)) := by + apply (Metric.isBounded_closedBall (x := (0 : Matrix ι ι ℂ)) (r := 1)).subset + intro a ha + rw [Metric.mem_closedBall,dist_zero_right] + by_cases hι : Nonempty ι + · let _ := hι + exact (CStarRing.norm_coe_unitary (⟨a,ha⟩ : unitary (Matrix ι ι ℂ))).le + · have : IsEmpty ι := not_nonempty_iff.mp hι + have h : a=0 := Subsingleton.elim _ _ + rw [h,norm_zero] + exact zero_le_one + exact Metric.isCompact_of_isClosed_isBounded isClosed_unitary hb + +instance matrixUnitaryCompactSpace : CompactSpace (unitary (Matrix ι ι ℂ)) := + isCompact_iff_compactSpace.mp matrix_unitary_compact + +variable (G : Type*) [Group G] [TopologicalSpace G] [IsTopologicalGroup G] + [CompactSpace G] [MeasurableSpace G] [BorelSpace G] + +def compactHaarProbability : Measure G := + haarMeasure (⟨⟨Set.univ,isCompact_univ⟩,by simp⟩ : PositiveCompacts G) + +instance compactHaarProbability_isProbability : IsProbabilityMeasure (compactHaarProbability G) where + measure_univ := haarMeasure_self + +instance compactHaarProbability_isLeftInvariant : IsMulLeftInvariant (compactHaarProbability G) := + inferInstanceAs (IsMulLeftInvariant (haarMeasure _)) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCornerExtension.lean b/lean/OAI/Analysis/Commutator/MatrixCornerExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..6e511a957452b2c1f081518ac88a4b34e65b063d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCornerExtension.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertModuleExtension +import OAI.Analysis.Commutator.ReducingRepresentation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixCornerExtension + +open MatrixCornerHilbert + +variable {A K H ι : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] [DecidableEq ι] + +variable (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + +variable {p : A} (hp : IsStarProjection p) (v : ι → A) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + +include hcol in +omit [Fintype ι] in +lemma mapped_col (i j : ι) : star (σ (v i))*σ (v j)=if i=j then σ p else 0 := by + simpa only [map_mul,map_star,apply_ite,map_zero] using congrArg σ (hcol i j) + +include hinit in +omit [Fintype ι] [DecidableEq ι] in +lemma mapped_init (i : ι) : σ p*star (σ (v i))=star (σ (v i)) := by + simpa only [map_mul,map_star] using congrArg σ (hinit i) + +include htotal in +omit [DecidableEq ι] in +lemma mapped_total : ∑ i, σ (v i)*star (σ (v i))=1 := by + simpa only [map_sum,map_mul,map_star,map_one] using congrArg σ htotal + +def columns (i : ι) : fixedSpace (σ p) →ₗᵢ[ℂ] K := + matrixInsert (σ p) (fun i => σ (v i)) (mapped_col σ v hcol) i + +include hinit htotal in +lemma columns_total : IsHilbertSum ℂ (fun _ : ι => fixedSpace (σ p)) (columns σ v hcol) := + matrixInsert_isHilbertSum (σ p) (fun i => σ (v i)) (mapped_col σ v hcol) + (mapped_init σ v hinit) (mapped_total σ v htotal) + +include hinit in +omit [Fintype ι] in +lemma columns_project (i : ι) (x : K) : + (ActualHilbertSum.project (fun _ : ι => fixedSpace (σ p)) (columns σ v hcol) i x : K)= + (star (σ (v i))) x := + matrixInsert_adjoint (σ p) (fun i => σ (v i)) (mapped_col σ v hcol) + (mapped_init σ v hinit) i x + +include hp hinit in +omit [Fintype ι] [DecidableEq ι] in +lemma final_support (i : ι) : v i*p=v i := by + simpa only [star_mul,star_star,hp.isSelfAdjoint.star_eq] using congrArg star (hinit i) + +def entry (i j : ι) (a : A) : Corner hp := + ⟨star (v i)*a*v j,by rw [←mul_assoc,←mul_assoc,hinit i], + by rw [mul_assoc,final_support hp v hinit j]⟩ + +omit [Fintype ι] in +lemma columns_block (i j : ι) (a : A) (x : fixedSpace (σ p)) : + ActualHilbertSum.project (fun _ : ι => fixedSpace (σ p)) (columns σ v hcol) i + (σ a (columns σ v hcol j x)) = + ReducingRepresentation.corner σ hp (entry hp v hinit i j a) x := by + apply Subtype.ext + rw [columns_project σ v hcol hinit] + change star (σ (v i)) (σ a (σ (v j) x))=σ (star (v i)*a*v j) x + simp only [map_mul,map_star,mul_apply_eq_comp] + +def extend (T : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p)) : K →L[ℂ] H := + HilbertModuleExtension.extend (columns σ v hcol) (columns ρ v hcol) + (columns_total σ v hcol hinit htotal) (columns_total ρ v hcol hinit htotal) T + +lemma extend_norm_le (T : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p)) : + ‖extend σ ρ v hcol hinit htotal T‖≤‖T‖ := + HilbertModuleExtension.extend_norm_le _ _ _ _ T + +lemma extend_intertwines (T : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p)) + (hT : ∀ a : Corner hp, T.comp (ReducingRepresentation.corner σ hp a)= + (ReducingRepresentation.corner ρ hp a).comp T) (a : A) : + (extend σ ρ v hcol hinit htotal T).comp (σ a)= + (ρ a).comp (extend σ ρ v hcol hinit htotal T) := by + apply HilbertModuleExtension.extend_intertwines + intro i j x + rw [columns_block σ hp v hcol hinit,columns_block ρ hp v hcol hinit] + exact congrArg (fun R : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p) => R x) + (hT (entry hp v hinit i j a)) + +variable (G : K →L[ℂ] H) (hGp : ∀ x, G (σ p x)=ρ p (G x)) + +def cornerMap : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p) := + G.restrict (by + intro x hx + rw [mem_fixedSpace] at hx ⊢ + rw [←hGp x,hx]) + +lemma norm_sub_extend_le (T : fixedSpace (σ p) →L[ℂ] fixedSpace (ρ p)) + (hGv : ∀ i x, G (σ (v i) x)=ρ (v i) (G x)) : + ‖G-extend σ ρ v hcol hinit htotal T‖≤‖cornerMap σ ρ G hGp-T‖ := by + apply HilbertModuleExtension.norm_sub_extend_le + intro i x + exact hGv i x + +end Kadison.MatrixCornerExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCornerHilbert.lean b/lean/OAI/Analysis/Commutator/MatrixCornerHilbert.lean new file mode 100644 index 0000000000000000000000000000000000000000..9f8b280315344bbc2527c2d431edf01fc775bca7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCornerHilbert.lean @@ -0,0 +1,111 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixCornerHilbert + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def fixedSpace (p : H →L[ℂ] H) : Submodule ℂ H := (p-1).ker + +omit [CompleteSpace H] in +@[simp] lemma mem_fixedSpace (p : H →L[ℂ] H) (x : H) : x∈fixedSpace p ↔ p x=x := by + change p x-x=0 ↔ p x=x + exact sub_eq_zero + +instance (p : H →L[ℂ] H) : IsClosed ((fixedSpace p : Submodule ℂ H) : Set H) := + (p-1).isClosed_ker + +instance (p : H →L[ℂ] H) : CompleteSpace (fixedSpace p) := + (p-1).isClosed_ker.completeSpace_coe + +omit [CompleteSpace H] in +lemma fixed_apply (p : H →L[ℂ] H) (x : fixedSpace p) : p x=x := + (mem_fixedSpace p x).mp x.property + +def insert (p v : H →L[ℂ] H) (hv : star v*v=p) : fixedSpace p →ₗᵢ[ℂ] H where + toLinearMap := v.toLinearMap.comp (fixedSpace p).subtype + norm_map' x := by + have he : ‖v x‖^2=‖(x:H)‖^2 := by + rw [@norm_sq_eq_re_inner ℂ H _ _, @norm_sq_eq_re_inner ℂ H _ _,←adjoint_inner_right] + have hx : v.adjoint (v x)=p x := congrArg (fun T : H →L[ℂ] H => T x) hv + rw [hx,fixed_apply] + exact (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp he + +@[simp] lemma insert_apply (p v : H →L[ℂ] H) (hv : star v*v=p) (x : fixedSpace p) : + insert p v hv x=v x := rfl + +variable {ι : Type*} [Fintype ι] [DecidableEq ι] + +variable (p : H →L[ℂ] H) (v : ι → H →L[ℂ] H) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + +def matrixInsert (i : ι) : fixedSpace p →ₗᵢ[ℂ] H := + insert p (v i) (by simpa using hcol i i) + +include hinit in +omit [Fintype ι] [DecidableEq ι] in +lemma adjoint_mem_fixed (i : ι) (x : H) : (star (v i)) x∈fixedSpace p := by + rw [mem_fixedSpace] + exact congrArg (fun T : H →L[ℂ] H => T x) (hinit i) + +include hcol in +omit [Fintype ι] in +lemma matrixInsert_orthogonal : OrthogonalFamily ℂ (fun _ : ι => fixedSpace p) + (matrixInsert p v hcol) := by + intro i j hij x y + change inner ℂ (v i x) (v j y)=0 + rw [←adjoint_inner_right] + have he : (v i).adjoint (v j y)=0 := by + simpa only [ite_eq_right hij,zero_apply,mul_apply_eq_comp,star_eq_adjoint] using congrArg (fun T : H →L[ℂ] H => T y) (hcol i j) + rw [he,inner_zero_right] + +include hinit in +omit [Fintype ι] in +lemma matrixInsert_adjoint (i : ι) (x : H) : + (((matrixInsert p v hcol i).toContinuousLinearMap.adjoint x : fixedSpace p) : H)= + (star (v i)) x := by + have he : (matrixInsert p v hcol i).toContinuousLinearMap.adjoint x= + (⟨(star (v i)) x,adjoint_mem_fixed p v hinit i x⟩ : fixedSpace p) := by + apply ext_inner_left ℂ + intro y + rw [adjoint_inner_right] + change inner ℂ (v i (y:H)) x=inner ℂ (y:H) ((v i).adjoint x) + rw [adjoint_inner_right] + exact congrArg (fun y : fixedSpace p => (y:H)) he + +include hinit htotal in +lemma matrixInsert_isHilbertSum : IsHilbertSum ℂ (fun _ : ι => fixedSpace p) + (matrixInsert p v hcol) := by + apply IsHilbertSum.mk (matrixInsert_orthogonal p v hcol) + intro x _ + have hx : ∑ i, v i ((star (v i)) x)=x := by + simpa only [sum_apply,mul_apply_eq_comp,one_apply_eq_self] using + congrArg (fun T : H →L[ℂ] H => T x) htotal + rw [←hx] + apply Submodule.sum_mem + intro i _ + apply Submodule.le_topologicalClosure + apply Submodule.mem_iSup_of_mem i + exact ⟨⟨(star (v i)) x,adjoint_mem_fixed p v hinit i x⟩,rfl⟩ + +end Kadison.MatrixCornerHilbert + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCornerInclusion.lean b/lean/OAI/Analysis/Commutator/MatrixCornerInclusion.lean new file mode 100644 index 0000000000000000000000000000000000000000..bb68fb4f92be375fa5b2bbdac69ae19c98093f10 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCornerInclusion.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixInclusion +import OAI.Analysis.Commutator.MatrixNormalTrace +import OAI.Analysis.Commutator.MatrixRowCorner +import OAI.Analysis.Commutator.NormalSubalgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] (i₀ : ι) (M Q : VonNeumannAlgebra H) (hQM : Q≤M) + +local instance matrixCornerInclusionDecidableEq : DecidableEq ι := Classical.decEq ι + +def matrixInclusion : matrixVonNeumann ι i₀ Q →⋆ₐ[ℂ] CStarMatrix ι ι M := + (matrixEquiv ι i₀ M).symm.toStarAlgHom.comp + (NormalSubalgebra.inclusion (matrixVonNeumann ι i₀ M) (matrixVonNeumann ι i₀ Q) + (matrixVonNeumann_mono ι i₀ hQM)) + +lemma matrixInclusion_entry (X : matrixVonNeumann ι i₀ Q) (i j : ι) : + (matrixInclusion ι i₀ M Q hQM X i j:H →L[ℂ] H)= + entry ι (X:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i j := by + exact matrixEquiv_symm_entry ι i₀ M _ i j + +lemma matrixInclusion_row (i : ι) : + matrixInclusion ι i₀ M Q hQM (matrixEquiv ι i₀ Q (MatrixGNS.rowMatrix i (1:Q)))= + MatrixGNS.rowMatrix i (1:M) := by + apply CStarMatrix.ext + intro j k + apply Subtype.ext + rw [matrixInclusion_entry] + change entry ι (CyclicColumns.matrixRepresentation (A:=Q) (H:=H) Q.toStarSubalgebra.subtype + (MatrixGNS.rowMatrix i (1:Q))) j k=_ + rw [entry_matrixRepresentation] + simp only [MatrixGNS.rowMatrix_apply] + split_ifs <;> rfl + +lemma matrixTrace_restrict (τ : M →ₚ[ℂ] ℂ) (X : matrixVonNeumann ι i₀ Q) : + MatrixGNS.trace (ι:=ι) τ (matrixInclusion ι i₀ M Q hQM X)= + matrixTrace ι i₀ Q (NormalSubalgebra.trace M Q hQM τ) X := by + rw [MatrixGNS.trace_apply,matrixTrace_apply] + congr 1 + apply Finset.sum_congr rfl + intro i _ + rw [NormalSubalgebra.trace_apply] + congr 1 + apply Subtype.ext + exact matrixInclusion_entry ι i₀ M Q hQM X i i + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixCutEmbedding.lean b/lean/OAI/Analysis/Commutator/MatrixCutEmbedding.lean new file mode 100644 index 0000000000000000000000000000000000000000..a629ab01e804bb9d2873873f22d6fbfaa6604dd7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixCutEmbedding.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixProjectionDiagonal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder Matrix + +namespace Kadison.MatrixCorners + +variable {I J K : Type*} [Fintype I] [DecidableEq I] + [Fintype J] [DecidableEq J] [Fintype K] [DecidableEq K] + +attribute [local instance] Classical.propDecidable + +omit [DecidableEq I] [DecidableEq J] in +lemma trace_reindex (e : J ≃ I) (a : Matrix J J ℂ) : + (Matrix.reindex e e a).trace=a.trace := by + exact e.symm.sum_comp (fun j => a j j) + +omit [DecidableEq J] [DecidableEq K] in +lemma trace_cutBlock (a : Matrix J J ℂ) : + (Matrix.fromBlocks a (0:Matrix J K ℂ) 0 0).trace=a.trace := by + simp [Matrix.trace,Fintype.sum_sum_type] + +def cutBlock : Matrix J J ℂ →⋆ₙₐ[ℂ] Matrix (J⊕K) (J⊕K) ℂ where + toFun a := Matrix.fromBlocks a 0 0 0 + map_zero' := by ext i j; cases i <;> cases j <;> rfl + map_add' a b := by ext i j; cases i <;> cases j <;> simp + map_smul' c a := by ext i j; cases i <;> cases j <;> simp + map_mul' a b := by simp [Matrix.fromBlocks_multiply] + map_star' a := by + change _= (Matrix.fromBlocks a (0:Matrix J K ℂ) 0 0).conjTranspose + simp only [Matrix.fromBlocks_conjTranspose, Matrix.conjTranspose_zero] + rfl + +def reindexStarAlgEquiv (e : J ≃ I) : Matrix J J ℂ ≃⋆ₐ[ℂ] Matrix I I ℂ := + { Matrix.reindexAlgEquiv ℂ ℂ e with + map_smul' := fun c a => by ext i j; rfl + map_star' := fun a => by exact (Matrix.conjTranspose_reindex e e a).symm } + +def cutEmbedding (s : Set I) : Matrix s s ℂ →⋆ₙₐ[ℂ] Matrix I I ℂ := + (reindexStarAlgEquiv (Equiv.Set.sumCompl s)).toNonUnitalStarAlgHom.comp + (cutBlock (K := (sᶜ:Set I))) + +lemma cutEmbedding_trace (s : Set I) (a : Matrix s s ℂ) : + (cutEmbedding s a).trace=a.trace := by + change (Matrix.reindex (Equiv.Set.sumCompl s) (Equiv.Set.sumCompl s) + (Matrix.fromBlocks a (0:Matrix s (sᶜ:Set I) ℂ) 0 0)).trace=a.trace + rw [trace_reindex,trace_cutBlock] + +lemma cutEmbedding_one (s : Set I) : + cutEmbedding s 1=Matrix.diagonal (fun i => if i∈s then (1:ℂ) else 0) := by + ext i j + by_cases hi : i∈s <;> by_cases hj : j∈s + · change Matrix.fromBlocks (1:Matrix s s ℂ) 0 0 0 + ((Equiv.Set.sumCompl s).symm i) ((Equiv.Set.sumCompl s).symm j)=_ + rw [Equiv.Set.sumCompl_symm_apply_of_mem hi,Equiv.Set.sumCompl_symm_apply_of_mem hj] + simp [Matrix.one_apply,Matrix.diagonal_apply,hi] + · change Matrix.fromBlocks (1:Matrix s s ℂ) 0 0 0 + ((Equiv.Set.sumCompl s).symm i) ((Equiv.Set.sumCompl s).symm j)=_ + rw [Equiv.Set.sumCompl_symm_apply_of_mem hi,Equiv.Set.sumCompl_symm_apply_of_notMem hj] + simp [show i≠j from fun h=>hj (h ▸ hi)] + · change Matrix.fromBlocks (1:Matrix s s ℂ) 0 0 0 + ((Equiv.Set.sumCompl s).symm i) ((Equiv.Set.sumCompl s).symm j)=_ + rw [Equiv.Set.sumCompl_symm_apply_of_notMem hi,Equiv.Set.sumCompl_symm_apply_of_mem hj] + simp [Matrix.diagonal_apply,hi] + · change Matrix.fromBlocks (1:Matrix s s ℂ) 0 0 0 + ((Equiv.Set.sumCompl s).symm i) ((Equiv.Set.sumCompl s).symm j)=_ + rw [Equiv.Set.sumCompl_symm_apply_of_notMem hi,Equiv.Set.sumCompl_symm_apply_of_notMem hj] + simp [Matrix.diagonal_apply,hi] + +def projectionEmbedding (p : Matrix I I ℂ) (hp : IsStarProjection p) : + Matrix (projectionIndices p hp) (projectionIndices p hp) ℂ →⋆ₙₐ[ℂ] Matrix I I ℂ := + (Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) + (projection_hermitian p hp).eigenvectorUnitary).toNonUnitalStarAlgHom.comp + (cutEmbedding (projectionIndices p hp)) + +lemma projectionEmbedding_one (p : Matrix I I ℂ) (hp : IsStarProjection p) : + projectionEmbedding p hp 1=p := by + change Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) _ (cutEmbedding _ 1)=p + rw [cutEmbedding_one] + exact (projection_diagonal_form p hp).symm + +lemma projectionEmbedding_trace (p : Matrix I I ℂ) (hp : IsStarProjection p) + (a : Matrix (projectionIndices p hp) (projectionIndices p hp) ℂ) : + (projectionEmbedding p hp a).trace=a.trace := by + change (Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) _ (cutEmbedding _ a)).trace=a.trace + rw [trace_conjugation,cutEmbedding_trace] + +end Kadison.MatrixCorners + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixDiagonal.lean b/lean/OAI/Analysis/Commutator/MatrixDiagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..28b0583e42dd3536521b53c9765ac53ee7e9488a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixDiagonal.lean @@ -0,0 +1,134 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.MatrixDiagonal + +open Matrix + +variable {A I : Type*} [CStarAlgebra A] [Fintype I] [DecidableEq I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (o : I) + +def diagonal : A →ₗ[ℂ] A := + ∑ i,(LinearMap.mulLeft ℂ (φ (single i o 1))).comp (LinearMap.mulRight ℂ (φ (single o i 1))) + +lemma diagonal_apply (a : A) : diagonal φ o a=∑ i,φ (single i o 1)*a*φ (single o i 1) := by + simp only [diagonal,LinearMap.sum_apply,LinearMap.comp_apply, + LinearMap.mulLeft_apply,LinearMap.mulRight_apply,mul_assoc] + +lemma single_left (a : A) (k l : I) : + φ (single k l 1)*diagonal φ o a=φ (single k o 1)*a*φ (single o l 1) := by + rw [diagonal_apply,Finset.mul_sum,Finset.sum_eq_single l] + · rw [←mul_assoc,←mul_assoc,←map_mul,single_mul_single_same,one_mul] + · intro i hi hil + rw [←mul_assoc,←mul_assoc,←map_mul,single_mul_single_of_ne 1 k l i hil.symm 1, + map_zero,zero_mul,zero_mul] + · simp + +lemma single_right (a : A) (k l : I) : + diagonal φ o a*φ (single k l 1)=φ (single k o 1)*a*φ (single o l 1) := by + rw [diagonal_apply,Finset.sum_mul,Finset.sum_eq_single k] + · rw [mul_assoc,mul_assoc,←map_mul,single_mul_single_same,one_mul,mul_assoc] + · intro i hi hik + rw [mul_assoc,mul_assoc,←map_mul,single_mul_single_of_ne 1 o i k hik 1, + map_zero,mul_zero,mul_zero] + · simp + +lemma commutes (a : A) (x : Matrix I I ℂ) : + φ x*diagonal φ o a=diagonal φ o a*φ x := by + conv_lhs => rw [Matrix.matrix_eq_sum_single x] + conv_rhs => rw [Matrix.matrix_eq_sum_single x] + simp only [map_sum,Finset.sum_mul,Finset.mul_sum] + apply Finset.sum_congr rfl + intro k hk + apply Finset.sum_congr rfl + intro l hl + have hs : single k l (x k l)=(x k l) • single k l (1:ℂ) := by simp + rw [hs,map_smul,smul_mul_assoc,mul_smul_comm,single_left,single_right] + +lemma cut (a : A) : + φ (single o o 1)*diagonal φ o a*φ (single o o 1)= + φ (single o o 1)*a*φ (single o o 1) := by + rw [single_left,mul_assoc,←map_mul,single_mul_single_same,one_mul] + +lemma star_diagonal (a : A) : star (diagonal φ o a)=diagonal φ o (star a) := by + simp only [diagonal_apply,star_sum,star_mul,←map_star,Matrix.star_eq_conjTranspose, + conjTranspose_single,star_one,mul_assoc] + +lemma mul_diagonal (a b : A) (ha : a*φ (single o o 1)=a) : + diagonal φ o a*diagonal φ o b=diagonal φ o (a*b) := by + conv_lhs => lhs; rw [diagonal_apply] + rw [Finset.sum_mul] + conv_rhs => rw [diagonal_apply] + apply Finset.sum_congr rfl + intro i hi + rw [mul_assoc,single_left] + simp only [mul_assoc] + rw [←mul_assoc a,ha] + +lemma projection {p : A} (hp : IsStarProjection p) (hpr : p*φ (single o o 1)=p) : + IsStarProjection (diagonal φ o p) := by + constructor + · change diagonal φ o p*diagonal φ o p=diagonal φ o p + rw [mul_diagonal φ o p p hpr,hp.isIdempotentElem.eq] + · change star (diagonal φ o p)=diagonal φ o p + rw [star_diagonal,hp.isSelfAdjoint.star_eq] + +lemma at_unit : diagonal φ o (φ (single o o 1))=1 := by + rw [diagonal_apply] + simp only [←map_mul,single_mul_single_same,one_mul,←map_sum,sum_single_one,map_one] + +lemma fixed (a : A) (ha : ∀ x : Matrix I I ℂ,φ x*a=a*φ x) : + diagonal φ o (φ (single o o 1)*a*φ (single o o 1))=a := by + rw [diagonal_apply] + have hpoint (i : I) : + φ (single i o 1)*(φ (single o o 1)*a*φ (single o o 1))*φ (single o i 1)= + φ (single i i 1)*a := by + calc + _=(φ (single i o 1)*φ (single o o 1))*a*(φ (single o o 1)*φ (single o i 1)) := by simp only [mul_assoc] + _=φ (single i o 1)*a*φ (single o i 1) := by simp only [←map_mul,single_mul_single_same,one_mul] + _=a*φ (single i i 1) := by rw [ha,mul_assoc,←map_mul,single_mul_single_same,one_mul] + _=φ (single i i 1)*a := (ha _).symm + simp only [hpoint,←Finset.sum_mul,←map_sum,sum_single_one,map_one,one_mul] + +lemma matrix_block (a : A) (i j : I) : + φ (single i o 1)*(φ (single o o 1)*(φ (single o i 1)*a*φ (single j o 1))* + φ (single o o 1))*φ (single o j 1)=φ (single i i 1)*a*φ (single j j 1) := by + calc + _=(φ (single i o 1)*φ (single o o 1)*φ (single o i 1))*a* + (φ (single j o 1)*φ (single o o 1)*φ (single o j 1)) := by simp only [mul_assoc] + _=_ := by simp only [←map_mul,single_mul_single_same,one_mul] + +lemma central_of_commutes_diagonal (c : A) + (hc : ∀ x : Matrix I I ℂ,Commute (φ x) c) + (hd : ∀ a : A,Commute (diagonal φ o a) c) (a : A) : Commute a c := by + have hcorner (b : A) : Commute (φ (single o o 1)*b*φ (single o o 1)) c := by + have he := ((hc (single o o 1)).mul_left (hd b)).mul_left (hc (single o o 1)) + rwa [cut] at he + have hblock (i j : I) : Commute (φ (single i i 1)*a*φ (single j j 1)) c := by + have he := ((hc (single i o 1)).mul_left + (hcorner (φ (single o i 1)*a*φ (single j o 1)))).mul_left (hc (single o j 1)) + rwa [matrix_block] at he + have hs := Commute.sum_left Finset.univ + (fun i => ∑ j,φ (single i i 1)*a*φ (single j j 1)) c + (fun i _ => Commute.sum_left Finset.univ _ c (fun j _ => hblock i j)) + simpa only [←Finset.mul_sum,←Finset.sum_mul,←map_sum,sum_single_one,map_one, + mul_one,one_mul] using hs + +end Kadison.MatrixDiagonal + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixDiffuse.lean b/lean/OAI/Analysis/Commutator/MatrixDiffuse.lean new file mode 100644 index 0000000000000000000000000000000000000000..48e4dd95d5441dcecb9ec6b4a44739fb38ce6250 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixDiffuse.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.MatrixDiffuse + +open Matrix + +lemma diagonal_trace {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + (φ : Matrix I I ℂ →ₗ[ℂ] ℂ) (htr : ∀ x y, φ (x*y)=φ (y*x)) (hunit : φ 1=1) + (i : I) : φ (single i i 1)=(Fintype.card I : ℂ)⁻¹ := by + have hdiag : ∀ j : I, φ (single i i 1)=φ (single j j 1) := by + intro j + simpa using htr (single i j 1) (single j i 1) + have hcard : (Fintype.card I : ℂ)≠0 := by exact_mod_cast Fintype.card_ne_zero + have h : (Fintype.card I : ℂ)*φ (single i i 1)=1 := by + calc + _=∑ j : I, φ (single j j 1) := by + simp only [←hdiag,Finset.sum_const,Finset.card_univ,nsmul_eq_mul] + _=φ 1 := by rw [←map_sum,Matrix.sum_single_one] + _=1 := hunit + apply mul_left_cancel₀ hcard + rw [h,mul_inv_cancel₀ hcard] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : (H →L[ℂ] H) →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a∈M, ∀ b∈M, τ (a*b)=τ (b*a)) (h1 : τ 1=1) + +include hτ h1 + +lemma exists_matrix_projection {n : ℕ} (hn : 0 by + change τ (ψ (x*y))=τ (ψ (y*x)) + simp only [map_mul] + exact hτ _ (φ x).property _ (φ y).property) + (by change τ (ψ 1)=1; simpa only [map_one] using h1) i + change τ (ψ (single i i 1))=(Fintype.card (Fin n) : ℂ)⁻¹ at hd + simpa only [Fintype.card_fin] using hd + have hp : IsStarProjection (single i i (1 : ℂ)) := by + constructor + · change single i i (1 : ℂ)*single i i 1=single i i 1 + simp + · change star (single i i (1 : ℂ))=single i i 1 + simp only [Matrix.star_eq_conjTranspose,Matrix.conjTranspose_single,star_one] + refine ⟨ψ (single i i 1),(φ (single i i 1)).property,hp.map ψ,?_,?_⟩ + · intro hz + have h := hdiag + rw [hz,map_zero] at h + have hnn : (n : ℂ)≠0 := by exact_mod_cast Nat.ne_of_gt hn + exact (inv_ne_zero hnn) h.symm + · rw [hdiag] + have hcast : (n : ℂ)=(n : ℝ) := by simp + rw [hcast,←Complex.ofReal_inv,Complex.ofReal_re] + +theorem exists_small_of_matrix_stages (n : ℕ → ℕ) + (φ : ∀ j, Matrix (Fin (n j)) (Fin (n j)) ℂ →⋆ₐ[ℂ] M) + (hsize : ∀ N : ℕ, ∃ j, N diagonal_mem_matrixVonNeumann ι i₀ M a.property) + +lemma coe_diagonalHom (a : M) : + (diagonalHom ι i₀ M a:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι)= + diagonal (H:=H) ι (a:H →L[ℂ] H) := rfl + +lemma diagonalHom_injective : Function.Injective (diagonalHom ι i₀ M) := by + intro a b h + apply Subtype.ext + have he := congrArg (fun T : matrixVonNeumann ι i₀ M => + entry ι (T:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i₀ i₀) h + simpa only [coe_diagonalHom,entry_diagonal] using he + +lemma matrixTrace_diagonal (τ : M →ₚ[ℂ] ℂ) (a : M) : + matrixTrace ι i₀ M τ (diagonalHom ι i₀ M a)=τ a := by + rw [matrixTrace_apply] + have he (i : ι) : (⟨entry ι ((diagonalHom ι i₀ M a):SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i i, + (mem_matrixVonNeumann ι i₀ M _).mp (diagonalHom ι i₀ M a).property i i⟩:M)=a := by + apply Subtype.ext + exact entry_diagonal ι (a:H →L[ℂ] H) i + simp only [he,Finset.sum_const,Finset.card_univ,nsmul_eq_mul] + let : Nonempty ι := ⟨i₀⟩ + rw [←mul_assoc,inv_mul_cancel₀ (by exact_mod_cast Fintype.card_ne_zero (α:=ι)),one_mul] + +theorem matrix_diffuse_of_stages (hM : FactorCorner.IsFactor M) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (F : ℕ → MatrixTower.Stage M) (hsize : ∀ N : ℕ,∃ n,N + ofCLM (entry ι T.toCLM i j)) := by + change Continuous (fun T : SumSpace (H:=H) ι →WOT[ℂ] SumSpace (H:=H) ι => + (ofCLM (PiLp.proj 2 (fun _ : ι => H) i)).comp ((T).comp (ofCLM (single ι j)))) + exact (continuous_postcomp _).comp (continuous_precomp _) + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixExpectation.lean b/lean/OAI/Analysis/Commutator/MatrixExpectation.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd78f24227a9c0f920d556b0fea68fe0bd19a9ab --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixExpectation.lean @@ -0,0 +1,170 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.MatrixExpectation + +open Matrix TracialGNS + +variable {A I : Type*} [CStarAlgebra A] [Fintype I] [DecidableEq I] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + +def expectation : A →ₗ[ℂ] A := + (Fintype.card I:ℂ)⁻¹ • ∑ i,∑ j, + (LinearMap.mulLeft ℂ (φ (single i j 1))).comp (LinearMap.mulRight ℂ (φ (single j i 1))) + +lemma expectation_apply (a : A) : expectation φ a= + (Fintype.card I:ℂ)⁻¹ • ∑ i,∑ j,φ (single i j 1)*a*φ (single j i 1) := by + simp only [expectation,LinearMap.smul_apply,LinearMap.sum_apply,LinearMap.comp_apply, + LinearMap.mulLeft_apply,LinearMap.mulRight_apply,mul_assoc] + +lemma star_expectation (a : A) : star (expectation φ a)=expectation φ (star a) := by + rw [expectation_apply,expectation_apply] + simp only [star_smul,star_sum,star_mul,←map_star,Matrix.star_eq_conjTranspose, + Matrix.conjTranspose_single,star_one,star_inv₀,star_natCast,mul_assoc] + +lemma selfAdjoint {a : A} (ha : IsSelfAdjoint a) : IsSelfAdjoint (expectation φ a) := by + change star (expectation φ a)=expectation φ a + rw [star_expectation,ha.star_eq] + +lemma single_left (a : A) (k l : I) : + φ (single k l 1)*expectation φ a= + (Fintype.card I:ℂ)⁻¹ • ∑ j,φ (single k j 1)*a*φ (single j l 1) := by + rw [expectation_apply,mul_smul_comm,Finset.mul_sum] + simp only [Finset.mul_sum,←mul_assoc,←map_mul] + rw [Finset.sum_eq_single l] + · simp only [single_mul_single_same,one_mul] + · intro i hi hil + apply Finset.sum_eq_zero + intro j hj + rw [single_mul_single_of_ne 1 k l i hil.symm 1,map_zero,zero_mul,zero_mul] + · simp + +lemma single_right (a : A) (k l : I) : + expectation φ a*φ (single k l 1)= + (Fintype.card I:ℂ)⁻¹ • ∑ j,φ (single k j 1)*a*φ (single j l 1) := by + rw [expectation_apply,smul_mul_assoc,Finset.sum_mul] + simp only [Finset.sum_mul,mul_assoc,←map_mul] + rw [Finset.sum_eq_single k] + · simp only [single_mul_single_same,one_mul] + · intro i hi hik + apply Finset.sum_eq_zero + intro j hj + rw [single_mul_single_of_ne 1 j i k hik 1,map_zero,mul_zero,mul_zero] + · simp + +lemma commutes (a : A) (x : Matrix I I ℂ) : φ x*expectation φ a=expectation φ a*φ x := by + conv_lhs => rw [Matrix.matrix_eq_sum_single x] + conv_rhs => rw [Matrix.matrix_eq_sum_single x] + simp only [map_sum,Finset.sum_mul,Finset.mul_sum] + apply Finset.sum_congr rfl + intro k hk + apply Finset.sum_congr rfl + intro l hl + have hs : single k l (x k l)=(x k l) • single k l (1:ℂ) := by simp + rw [hs,map_smul,smul_mul_assoc,mul_smul_comm,single_left,single_right] + +lemma matrixSandwich (x : Matrix I I ℂ) (i j : I) : + single i j 1*x*single j i 1=x j j • single i i 1 := by + ext k l + by_cases hik : i=k + · subst k + by_cases hil : i=l + · subst l; simp [Matrix.mul_apply,Matrix.single,smul_eq_mul] + · simp [Matrix.mul_apply,Matrix.single,smul_eq_mul,hil] + · simp [Matrix.mul_apply,Matrix.single,smul_eq_mul,hik] + +lemma matrixSum (x : Matrix I I ℂ) : + (∑ i,∑ j,single i j 1*x*single j i 1)=x.trace • (1:Matrix I I ℂ) := by + simp only [matrixSandwich,←Finset.sum_smul] + simp only [Matrix.trace,Matrix.diag,←Finset.smul_sum,Matrix.sum_single_one] + +lemma on_matrix (x : Matrix I I ℂ) : + expectation φ (φ x)=((Fintype.card I:ℂ)⁻¹*x.trace) • (1:A) := by + rw [expectation_apply] + simp only [←map_mul,←map_sum] + rw [matrixSum,map_smul,map_one,smul_smul] + +variable [Nonempty I] + +omit [DecidableEq I] in +lemma card_ne : (Fintype.card I:ℂ)≠0 := by exact_mod_cast Fintype.card_ne_zero + +lemma fixes (a : A) (ha : ∀ x : Matrix I I ℂ,φ x*a=a*φ x) : expectation φ a=a := by + rw [expectation_apply] + have he (i j : I) : φ (single i j 1)*a*φ (single j i 1)=a*φ (single i i 1) := by + rw [ha,mul_assoc,←map_mul,single_mul_single_same,one_mul] + have hsum : (∑ i,a*φ (single i i 1))=a := by + rw [←Finset.mul_sum,←map_sum,Matrix.sum_single_one,map_one,mul_one] + simp only [he,Finset.sum_const,Finset.card_univ] + rw [←Finset.smul_sum,hsum,←Nat.cast_smul_eq_nsmul ℂ,smul_smul, + inv_mul_cancel₀ (card_ne (I:=I)),one_smul] + +lemma idempotent (a : A) : expectation φ (expectation φ a)=expectation φ a := + fixes φ _ (commutes φ a) + +variable [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +omit [Nonempty I] in +include hτ in +lemma inner_symm (a b : A) : + inner ℂ (algebraVector τ (expectation φ a)) (algebraVector τ b)= + inner ℂ (algebraVector τ a) (algebraVector τ (expectation φ b)) := by + rw [inner_algebraVector,inner_algebraVector,expectation_apply,expectation_apply] + simp only [star_smul,star_sum,star_mul,←map_star,Matrix.star_eq_conjTranspose, + Matrix.conjTranspose_single,star_one,smul_mul_assoc,mul_smul_comm, + Finset.sum_mul,Finset.mul_sum,map_smul,map_sum] + congr 1 + · simp + · rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro i hi + apply Finset.sum_congr rfl + intro j hj + simpa only [mul_assoc] using + hτ (φ (single j i 1)) (star a*φ (single i j 1)*b) + +include hτ in +lemma norm_vector_le (a : A) : ‖algebraVector τ (expectation φ a)‖≤‖algebraVector τ a‖ := by + have hi := inner_symm φ τ hτ a (expectation φ a) + rw [idempotent] at hi + have hr := congrArg (RCLike.re : ℂ → ℝ) hi + rw [←norm_sq_eq_re_inner (𝕜:=ℂ)] at hr + have hb := re_inner_le_norm (𝕜:=ℂ) (algebraVector τ a) (algebraVector τ (expectation φ a)) + have h0 := norm_nonneg (algebraVector τ (expectation φ a)) + nlinarith [norm_nonneg (algebraVector τ a)] + +include hτ in +lemma trace_preserving (a : A) : τ (expectation φ a)=τ a := by + have he := fixes φ (1:A) (fun x => by rw [mul_one,one_mul]) + have hi := inner_symm φ τ hτ 1 a + rw [he] at hi + simpa only [inner_algebraVector,star_one,one_mul] using hi.symm + +include hτ in +lemma on_matrix_trace (hone : τ 1=1) (x : Matrix I I ℂ) : + expectation φ (φ x)=τ (φ x) • (1:A) := by + have ht := trace_preserving φ τ hτ (φ x) + rw [on_matrix,map_smul,hone,smul_eq_mul,mul_one] at ht + rw [on_matrix,ht] + +end Kadison.MatrixExpectation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixExpectationNested.lean b/lean/OAI/Analysis/Commutator/MatrixExpectationNested.lean new file mode 100644 index 0000000000000000000000000000000000000000..facebe2265b6c958625c8ae5cf1095a0dbe75208 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixExpectationNested.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixExpectation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.MatrixExpectation + +open TracialGNS + +variable {A I J : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype I] [DecidableEq I] [Nonempty I] [Fintype J] [DecidableEq J] [Nonempty J] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (ψ : Matrix J J ℂ →⋆ₐ[ℂ] A) + (hsub : φ.range≤ψ.range) + +omit [PartialOrder A] [StarOrderedRing A] [Nonempty J] in +include hsub in +lemma nested_fixed (a : A) : expectation φ (expectation ψ a)=expectation ψ a := by + apply fixes + intro x + obtain ⟨y,hy⟩ := hsub (show φ x∈φ.range from ⟨x,rfl⟩) + change ψ y=φ x at hy + rw [←hy] + exact commutes ψ a y + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +omit [Nonempty J] in +include hsub hτ in +lemma nested_vector (a : A) : + algebraVector τ (expectation ψ (expectation φ a))=algebraVector τ (expectation ψ a) := by + apply (algebraVector_dense τ).eq_of_inner_left ℂ + intro b + rw [inner_symm ψ τ hτ,inner_symm φ τ hτ,nested_fixed φ ψ hsub,inner_symm ψ τ hτ] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma fixes_scalar (z : ℂ) : expectation φ (z • (1:A))=z • (1:A) := by + rw [map_smul,fixes φ 1 (fun x => by rw [mul_one,one_mul])] + +include hsub hτ in +lemma nested_norm_le (a : A) (z : ℂ) : + ‖algebraVector τ (expectation ψ a-z • (1:A))‖≤ + ‖algebraVector τ (expectation φ a-z • (1:A))‖ := by + have he : algebraVector τ (expectation ψ (expectation φ a-z • (1:A)))= + algebraVector τ (expectation ψ a-z • (1:A)) := by + rw [map_sub,fixes_scalar,map_sub,map_sub,nested_vector φ ψ hsub τ hτ] + rw [←he] + exact norm_vector_le ψ τ hτ _ + +end Kadison.MatrixExpectation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixField.lean b/lean/OAI/Analysis/Commutator/MatrixField.lean new file mode 100644 index 0000000000000000000000000000000000000000..4d4697096e8533a1ed0fb725774865574d4b27e5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixField.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.L2FiniteSum +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +lemma vector_norm_le_sum {ι : Type*} [Fintype ι] (v : PiLp 2 (fun _ : ι => H)) : + ‖v‖≤∑ i,‖v i‖ := by + classical + have he : ∑ i,PiLp.single 2 i (v i)=v := by ext i; simp + rw [←he] + convert norm_sum_le (Finset.univ) (fun i => PiLp.single 2 i (v i)) using 1 + simp only [PiLp.norm_single] + rw [he] + +omit [CompleteSpace H] in +lemma matrix_norm_le_sum (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) : + ‖matrixOperator h X‖≤∑ i,∑ j,‖X i j‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro x + calc + ‖matrixOperator h X x‖≤∑ i,‖matrixOperator h X x i‖ := vector_norm_le_sum _ + _≤∑ i,∑ j,‖X i j‖*‖x‖ := by + apply Finset.sum_le_sum + intro i _ + rw [matrixOperator_apply] + apply (norm_sum_le _ _).trans + apply Finset.sum_le_sum + intro j _ + exact ((X i j).le_opNorm (x j)).trans + (mul_le_mul_of_nonneg_left (PiLp.norm_apply_le x j) (norm_nonneg _)) + _=(∑ i,∑ j,‖X i j‖)*‖x‖ := by simp only [Finset.sum_mul] + +omit [CompleteSpace H] in +lemma matrix_field_measurable (h : ℕ) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hm : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + (ξ : PiLp 2 (fun _ : Fin h => H)) : + AEStronglyMeasurable (fun a => matrixOperator h (fun i j => X i j a) ξ) μ := by + classical + have eqn (a) : matrixOperator h (fun i j => X i j a) ξ= + ∑ i,OperatorAmplification.single (Fin h) i (∑ j,X i j a (ξ j)) := by + ext i + erw [matrixOperator_apply] + simp [OperatorAmplification.single_apply] + simp_rw [eqn] + apply Finset.aestronglyMeasurable_fun_sum + intro i _ + exact (OperatorAmplification.single (Fin h) i).continuous.comp_aestronglyMeasurable + (Finset.aestronglyMeasurable_fun_sum _ (fun j _ => hm i j (ξ j))) + +omit [CompleteSpace H] in +lemma matrix_field_bound (h : ℕ) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + {b : Fin h → Fin h → ℝ} (hb : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤b i j) : + ∀ᵐ a ∂μ,‖matrixOperator h (fun i j => X i j a)‖≤∑ i,∑ j,b i j := by + filter_upwards [ae_all_iff.mpr (fun i => ae_all_iff.mpr (hb i))] with a ha + exact (matrix_norm_le_sum h _).trans (Finset.sum_le_sum (fun i _ => + Finset.sum_le_sum (fun j _ => ha i j))) + +omit [CompleteSpace H] in +lemma assemble_matrix_ae (h : ℕ) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hm : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + {b : Fin h → Fin h → ℝ} (hb : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤b i j) + (f : PiLp 2 (fun _ : Fin h => Lp H 2 μ)) : + assemble μ (matrixOperator h (fun i j => operator μ (X i j) (hm i j) (hb i j)) f)=ᵐ[μ] + fun a => matrixOperator h (fun i j => X i j a) (assemble μ f a) := by + have he : ∀ᵐ a ∂μ,∀ i j,operator μ (X i j) (hm i j) (hb i j) (f j) a=X i j a (f j a) := + ae_all_iff.mpr (fun i => ae_all_iff.mpr (fun j => operator_ae μ _ _ _ (f j))) + have hs : ∀ᵐ a ∂μ,∀ i,(∑ j,operator μ (X i j) (hm i j) (hb i j) (f j)) a= + ∑ j,operator μ (X i j) (hm i j) (hb i j) (f j) a := + ae_all_iff.mpr (fun i => Lp.coeFn_fun_finsetSum _ _) + filter_upwards [assemble_ae μ (matrixOperator h (fun i j => operator μ (X i j) (hm i j) (hb i j)) f), + assemble_ae μ f,he,hs] with a ha hf he hs + rw [ha,hf] + ext i + change (matrixOperator h (fun i j => operator μ (X i j) (hm i j) (hb i j)) f i) a= + matrixOperator h (fun i j => X i j a) (WithLp.toLp 2 (fun i => f i a)) i + erw [matrixOperator_apply,matrixOperator_apply] + rw [hs i] + exact Finset.sum_congr rfl (fun j _ => he i j) + +lemma matrix_conjugate (h : ℕ) (X : Fin h → Fin h → Ω → H →L[ℂ] H) + (hm : ∀ i j ξ,AEStronglyMeasurable (fun a => X i j a ξ) μ) + {b : Fin h → Fin h → ℝ} (hb : ∀ i j,∀ᵐ a ∂μ,‖X i j a‖≤b i j) : + (finiteSumEquiv μ).conjStarAlgEquiv + (matrixOperator h (fun i j => operator μ (X i j) (hm i j) (hb i j)))= + operator μ (fun a => matrixOperator h (fun i j => X i j a)) + (matrix_field_measurable μ h X hm) (matrix_field_bound μ h X hb) := by + apply operator_eq_of_ae_apply + intro f + have hh := assemble_matrix_ae μ h X hm hb ((finiteSumEquiv μ).symm f) + change (assemble μ (matrixOperator h (fun i j => operator μ (X i j) (hm i j) (hb i j)) + ((finiteSumEquiv μ).symm f))) =ᵐ[μ] _ + convert hh using 1 + rw [show assemble μ ((finiteSumEquiv μ).symm f)=f from (finiteSumEquiv μ).apply_symm_apply f] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixFlatten.lean b/lean/OAI/Analysis/Commutator/MatrixFlatten.lean new file mode 100644 index 0000000000000000000000000000000000000000..7eb5a54b81420614e913b0331fed7d0721ebcdbe --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixFlatten.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTraceFaithful + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.MatrixGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +local instance : DecidableEq ι := Classical.decEq ι + +local instance : DecidableEq κ := Classical.decEq κ + +local instance : DecidableEq (κ×ι) := Classical.decEq (κ×ι) + +def flattenHom : CStarMatrix κ κ (CStarMatrix ι ι A) →⋆ₐ[ℂ] CStarMatrix (κ×ι) (κ×ι) A where + toFun X := CStarMatrix.ofMatrix (fun p q => X p.1 q.1 p.2 q.2) + map_zero' := rfl + map_add' X Y := rfl + map_mul' X Y := by + ext p q + change (X*Y) p.1 q.1 p.2 q.2=∑ r : κ×ι,X p.1 r.1 p.2 r.2*Y r.1 q.1 r.2 q.2 + rw [CStarMatrix.mul_apply] + change (∑ j, (X p.1 j * Y j q.1 : CStarMatrix ι ι A)) p.2 q.2=_ + have heval (Z : κ → CStarMatrix ι ι A) : + (∑ j,Z j) p.2 q.2=∑ j,Z j p.2 q.2 := by + suffices ∀ s : Finset κ,(∑ j ∈ s,Z j) p.2 q.2=∑ j∈s,Z j p.2 q.2 from + this Finset.univ + intro s + induction s using Finset.induction_on with + | empty => rfl + | @insert a s ha ih => + rw [Finset.sum_insert ha,Finset.sum_insert ha] + change Z a p.2 q.2+(∑ j∈s,Z j) p.2 q.2=Z a p.2 q.2+_ + rw [ih] + rw [heval] + simp only [CStarMatrix.mul_apply,Fintype.sum_prod_type] + map_one' := by + ext p q + change (1:CStarMatrix κ κ (CStarMatrix ι ι A)) p.1 q.1 p.2 q.2= + (1:CStarMatrix (κ×ι) (κ×ι) A) p q + by_cases hp : p.1=q.1 <;> by_cases hq : p.2=q.2 <;> + simp [CStarMatrix.one_apply,hp,hq,Prod.ext_iff] + commutes' z := by + ext p q + change (algebraMap ℂ (CStarMatrix κ κ (CStarMatrix ι ι A)) z) p.1 q.1 p.2 q.2= + (algebraMap ℂ (CStarMatrix (κ×ι) (κ×ι) A) z) p q + by_cases hp : p.1=q.1 <;> by_cases hq : p.2=q.2 <;> + simp [CStarMatrix.algebraMap_apply,hp,hq,Prod.ext_iff] + map_star' X := rfl + +omit [PartialOrder A] [StarOrderedRing A] in +lemma flattenHom_bijective : Function.Bijective (flattenHom (A:=A) ι κ) := by + constructor + · intro X Y h + ext i j k l + exact congrArg (fun Z : CStarMatrix (κ×ι) (κ×ι) A => Z (i,k) (j,l)) h + · intro X + refine ⟨CStarMatrix.ofMatrix (fun i j => CStarMatrix.ofMatrix (fun k l => X (i,k) (j,l))),?_⟩ + rfl + +def flatten : CStarMatrix κ κ (CStarMatrix ι ι A) ≃⋆ₐ[ℂ] CStarMatrix (κ×ι) (κ×ι) A := + StarAlgEquiv.ofBijective (flattenHom ι κ) (flattenHom_bijective ι κ) + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma flatten_apply (X : CStarMatrix κ κ (CStarMatrix ι ι A)) (p q : κ×ι) : + flatten ι κ X p q=X p.1 q.1 p.2 q.2 := rfl + +lemma trace_flatten (τ : A →ₚ[ℂ] ℂ) (X : CStarMatrix κ κ (CStarMatrix ι ι A)) : + trace (ι:=κ×ι) τ (flatten ι κ X)=trace (ι:=κ) (trace (ι:=ι) τ) X := by + simp only [trace_apply,flatten_apply,Fintype.sum_prod_type,Fintype.card_prod, + Nat.cast_mul,mul_inv_rev] + rw [←Finset.mul_sum] + ring + +def flatBalancedUnitary (X : CStarMatrix ι ι A) (hX : ‖X‖≤1) : + _root_.unitary (CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A) := + ⟨flatten ι (Fin 2) (BalancedDilation.symmetry X), + by + rw [Unitary.mem_iff] + have h := (Unitary.mem_iff.mp (BalancedDilation.symmetry_unitary X hX)) + constructor + · rw [←map_star,←map_mul,h.1,map_one] + · rw [←map_star,←map_mul,h.2,map_one]⟩ + +lemma flatBalancedUnitary_sq (X : CStarMatrix ι ι A) (hX : ‖X‖≤1) : + (flatBalancedUnitary ι X hX:CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A)* + (flatBalancedUnitary ι X hX:CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A)=1 := by + change flatten ι (Fin 2) (BalancedDilation.symmetry X)* + flatten ι (Fin 2) (BalancedDilation.symmetry X)=1 + rw [←map_mul,BalancedDilation.symmetry_mul_self X hX,map_one] + +lemma flatBalancedUnitary_trace (τ : A →ₚ[ℂ] ℂ) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (X : CStarMatrix ι ι A) (hX : ‖X‖≤1) : + trace (ι:=(Fin 2)×ι) τ (flatBalancedUnitary ι X hX: + CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A)=0 := by + change trace (ι:=(Fin 2)×ι) τ (flatten ι (Fin 2) (BalancedDilation.symmetry X))=0 + rw [trace_flatten] + exact balanced_symmetry_trace_zero (trace (ι:=ι) τ) (trace_mul τ hτ) X hX + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixFlattenRepresentation.lean b/lean/OAI/Analysis/Commutator/MatrixFlattenRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..2facbde47c7fac01e74c27d5c7b38f56efacd1c6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixFlattenRepresentation.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixFlatten +import OAI.Analysis.Commutator.BlockDilationBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixGNS + +open OperatorAmplification CyclicColumns + +lemma norm_conjugation {K L : Type*} + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup L] [InnerProductSpace ℂ L] [CompleteSpace L] + (U : K ≃ₗᵢ[ℂ] L) (T : K →L[ℂ] K) : ‖U.conjStarAlgEquiv T‖=‖T‖ := + StarAlgEquiv.norm_map U.conjStarAlgEquiv T + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +local instance matrixFlattenRepresentationIndexDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance matrixFlattenRepresentationCopiesDecidableEq : DecidableEq κ := Classical.decEq κ + +def flattenCopies : SumSpace (H:=SumSpace (H:=H) ι) κ ≃ₗᵢ[ℂ] SumSpace (H:=H) (κ×ι) where + toFun v := WithLp.toLp 2 (fun p => v p.1 p.2) + invFun v := WithLp.toLp 2 (fun i => WithLp.toLp 2 (fun j => v (i,j))) + left_inv v := rfl + right_inv v := rfl + map_add' v w := by ext p; rfl + map_smul' z v := by ext p; rfl + norm_map' v := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + simp [PiLp.norm_sq_eq_of_L2,Fintype.sum_prod_type] + +omit [CompleteSpace H] in +@[simp] lemma flattenCopies_apply (v : SumSpace (H:=SumSpace (H:=H) ι) κ) (p : κ×ι) : + flattenCopies ι κ v p=v p.1 p.2 := rfl + +omit [CompleteSpace H] in +@[simp] lemma flattenCopies_symm_apply (v : SumSpace (H:=H) (κ×ι)) (i : κ) (j : ι) : + (flattenCopies (H:=H) ι κ).symm v i j=v (i,j) := rfl + +lemma flattenCopies_diagonal (Y : H →L[ℂ] H) : + (flattenCopies (H:=H) ι κ).conjStarAlgEquiv + (diagonal (H:=SumSpace (H:=H) ι) κ (diagonal (H:=H) ι Y))=diagonal (H:=H) (κ×ι) Y := by + ext v p + rfl + +lemma flattenCopies_matrix (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (X : CStarMatrix κ κ (CStarMatrix ι ι A)) : + (flattenCopies (H:=H) ι κ).conjStarAlgEquiv + (matrixRepresentation (ι:=κ) (H:=SumSpace (H:=H) ι) (matrixRepresentation (ι:=ι) ρ) X)=matrixRepresentation ρ (flatten ι κ X) := by + ext v p + change matrixAction (fun i j => matrixRepresentation ρ (X i j)) + ((flattenCopies (H:=H) ι κ).symm v) p.1 p.2= + matrixAction (fun i j => ρ (flatten ι κ X i j)) v p + simp only [matrixAction_apply,WithLp.ofLp_sum,Finset.sum_apply, + Fintype.sum_prod_type,flatten_apply] + apply Finset.sum_congr rfl + intro j _ + change matrixAction (fun i k => ρ (X p.1 j i k)) + ((flattenCopies (H:=H) ι κ).symm v j) p.2=_ + simp only [matrixAction_apply,flattenCopies_symm_apply] + +lemma flattenCopies_commutator_norm (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (X : CStarMatrix κ κ (CStarMatrix ι ι A)) : + ‖diagonal (H:=SumSpace (H:=H) ι) κ (diagonal (H:=H) ι Y)* + matrixRepresentation (ι:=κ) (H:=SumSpace (H:=H) ι) (matrixRepresentation (ι:=ι) ρ) X- + matrixRepresentation (ι:=κ) (H:=SumSpace (H:=H) ι) (matrixRepresentation (ι:=ι) ρ) X* + diagonal (H:=SumSpace (H:=H) ι) κ (diagonal (H:=H) ι Y)‖= + ‖diagonal (H:=H) (κ×ι) Y*matrixRepresentation ρ (flatten ι κ X)- + matrixRepresentation ρ (flatten ι κ X)*diagonal (H:=H) (κ×ι) Y‖ := by + have hn := norm_conjugation (flattenCopies (H:=H) ι κ) + (diagonal (H:=SumSpace (H:=H) ι) κ (diagonal (H:=H) ι Y)* + matrixRepresentation (ι:=κ) (H:=SumSpace (H:=H) ι) (matrixRepresentation (ι:=ι) ρ) X- + matrixRepresentation (ι:=κ) (H:=SumSpace (H:=H) ι) (matrixRepresentation (ι:=ι) ρ) X* + diagonal (H:=SumSpace (H:=H) ι) κ (diagonal (H:=H) ι Y)) + simpa only [map_sub,map_mul,flattenCopies_diagonal,flattenCopies_matrix] using hn.symm + +theorem flatBalanced_commutator_dominates (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (X : CStarMatrix ι ι A) (hX : ‖X‖≤1) : + ‖diagonal (H:=H) ι Y*matrixRepresentation ρ X- + matrixRepresentation ρ X*diagonal (H:=H) ι Y‖ ≤ + ‖diagonal (H:=H) ((Fin 2)×ι) Y* + matrixRepresentation ρ (flatBalancedUnitary ι X hX:CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A)- + matrixRepresentation ρ (flatBalancedUnitary ι X hX:CStarMatrix ((Fin 2)×ι) ((Fin 2)×ι) A)* + diagonal (H:=H) ((Fin 2)×ι) Y‖ := by + have h := balanced_symmetry_commutator_dominates (matrixRepresentation ρ) (diagonal (H:=H) ι Y) X + rw [flattenCopies_commutator_norm] at h + exact h + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixFreePositionProducer.lean b/lean/OAI/Analysis/Commutator/MatrixFreePositionProducer.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1ef456894ff658b5681eb68f642fc0d3167f42d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixFreePositionProducer.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.AmplifiedTowerGeometry +import OAI.Analysis.Commutator.IrreducibleMatrixTower +import OAI.Analysis.Commutator.MatrixCornerInclusion +import OAI.Analysis.Commutator.MatrixStandardForm +import OAI.Analysis.Commutator.MatrixVectorTrace +import OAI.Analysis.Commutator.NormalizedTowerFreePosition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.MatrixTower + +open OperatorAmplification TracialSequence + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] (i₀ : ι) (M : VonNeumannAlgebra H) [Nontrivial M] + +local instance matrixFreePositionProducerDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (E : ℕ → Stage M) (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +theorem exists_matrix_freeCornerPosition [TopologicalSpace.SeparableSpace τ.GNS] + (hE : Monotone (fun n => (E n).hom.range)) + (hsize : ∀ n,n+1 ≤ Fintype.card (E n).I) + (hirr : ∀ a : M,(∀ n b,(E n).hom b*a=a*(E n).hom b) → ∃ z : ℂ,a=z • (1:M)) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (hω : (ω : Filter ℕ) ≤ atTop) : + Nonempty (FreeCornerPosition (MatrixGNS.trace (ι:=ι) τ) ω + (matrixVonNeumann ι i₀ (generated M E)) + (matrixInclusion ι i₀ M (generated M E) (generated_le M E))) := by + let : Nonempty ι := ⟨i₀⟩ + let P := matrixVonNeumann ι i₀ M + let R := generated M E + let Q := matrixVonNeumann ι i₀ R + let σ := matrixTrace ι i₀ M τ + let F := fun n => amplifiedStage ι i₀ M (E n) + let : Nontrivial P := (diagonalHom_injective ι i₀ M).nontrivial + let U := standardMatrixUnitary ι i₀ M τ + let : TopologicalSpace.SeparableSpace σ.GNS := + U.symm.surjective.denseRange.separableSpace U.symm.continuous + have hQP : Q ≤ P := matrixVonNeumann_mono ι i₀ (generated_le M E) + have hj (q : Q) : matrixEquiv ι i₀ M + (matrixInclusion ι i₀ M R (generated_le M E) q)=NormalSubalgebra.inclusion P Q hQP q := by + change matrixEquiv ι i₀ M ((matrixEquiv ι i₀ M).symm _)=_ + rw [StarAlgEquiv.apply_symm_apply] + rfl + have hQdiff : DiffuseProjection.HasNoMinimalProjections Q := by + let ρ := NormalSubalgebra.trace M R (generated_le M E) τ + apply matrix_diffuse_of_stages ι i₀ R (generated_factor M E hirr) ρ + (NormalSubalgebra.tracial M R (generated_le M E) τ hτ) + (NormalSubalgebra.faithful M R (generated_le M E) τ hfaith) + (NormalSubalgebra.one M R (generated_le M E) τ h1) (generatedStage M E) + intro N + exact ⟨N,lt_of_lt_of_le (Nat.lt_succ_self N) (hsize N)⟩ + apply exists_freeCornerPosition_of_equiv_stages P Q hQP (matrixEquiv ι i₀ M) + (matrixInclusion ι i₀ M R (generated_le M E)) hj (MatrixGNS.trace (ι:=ι) τ) σ ω F + (amplifiedStage_monotone ι i₀ M E hE) + (matrixTrace_equiv ι i₀ M τ) (MatrixGNS.trace_mul τ hτ) + (matrixTrace_tracial ι i₀ M τ hτ) hω (matrixTrace_normal ι i₀ M τ hnormal) + (matrixTrace_faithful ι i₀ M τ hfaith) (MatrixGNS.trace_one τ h1) + (amplifiedStage_irreducible ι i₀ M E hirr) _ _ hQdiff + · intro n a + apply amplifiedStage_in_relative ι i₀ M E R _ n a + intro k b + exact stage_mem M E k b + · apply tendsto_atTop_mono (f := fun n : ℕ => (n:ℝ)) _ tendsto_natCast_atTop_atTop + intro n + have hc : 1 ≤ Fintype.card ι := Fintype.card_pos + have hcard : n ≤ Fintype.card (F n).I := by + rw [amplifiedStage_size] + exact (Nat.le_succ n).trans ((hsize n).trans (Nat.le_mul_of_pos_left _ hc)) + exact_mod_cast hcard + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixFreeSymmetry.lean b/lean/OAI/Analysis/Commutator/MatrixFreeSymmetry.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0bbea07afded8fa9bb487973b05848a8d5948cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixFreeSymmetry.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixGNSRealCorner +import OAI.Analysis.Commutator.TracialFreePositionCriterion + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.OperatorAmplification + +open TracialSequence FreeMoments + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type) [Fintype ι] [Nonempty ι] (i₀ : ι) (M Q : VonNeumannAlgebra H) (hQM : Q≤M) + +local instance matrixFreeSymmetryDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (τ : M →ₚ[ℂ] ℂ) + +variable (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ)≤atTop) + +variable (F : FreeCornerPosition (MatrixGNS.trace (ι:=ι) τ) ω (matrixVonNeumann ι i₀ Q) (matrixInclusion ι i₀ M Q hQM)) + +include hω F in +theorem matrix_free_symmetry_bound (hQ : FactorCorner.IsFactor Q) + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (T : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι) + (hTQ : ∀ q : Q,T*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom (NormalSubalgebra.inclusion M Q hQM q))= + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom (NormalSubalgebra.inclusion M Q hQM q))*T) + {c : ℝ} (hc : 0≤c) + (hbound : ∀ a : M,‖T*diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*T‖≤c*‖a‖) + (s : unitary (CStarMatrix ι ι M)) (hs0 : (MatrixGNS.trace (ι:=ι) τ) (s:CStarMatrix ι ι M)=0) + (hs2 : (s:CStarMatrix ι ι M)*(s:CStarMatrix ι ι M)=1) : + ‖diagonal (H:=SumSpace (H:=τ.GNS) ι) ι T*MatrixGNS.representation τ (s:CStarMatrix ι ι M)- + MatrixGNS.representation τ (s:CStarMatrix ι ι M)*diagonal (H:=SumSpace (H:=τ.GNS) ι) ι T‖≤1040*c := by + let b : ℝ := (Fintype.card ι : ℝ)⁻¹ + have hn : (1:ℝ)≤Fintype.card ι := by exact_mod_cast Fintype.card_pos + have hb : 0 + WithLp.toLp 2 (fun i => TracialGNS.algebraVector τ (a i))) := by + let e := (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => τ.GNS)).symm + exact e.surjective.denseRange.comp + (DenseRange.piMap (fun _ : ι => TracialGNS.algebraVector_dense τ)) e.continuous + have hd₂ : DenseRange (fun a : ι → ι → A => + WithLp.toLp 2 (fun i => WithLp.toLp 2 + (fun j => TracialGNS.algebraVector τ (a i j)))) := by + let e := (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => PiLp 2 (fun _ : ι => τ.GNS))).symm + exact e.surjective.denseRange.comp (DenseRange.piMap (fun _ : ι => hd₁)) e.continuous + apply hd₂.mono + rintro y ⟨a,rfl⟩ + exact ⟨CStarMatrix.ofMatrix a,rfl⟩ + +lemma dense_vacuumOrbit [Nonempty ι] : + DenseRange (fun X : CStarMatrix ι ι A => representation (ι:=ι) τ X (vacuum (ι:=ι) τ)) := by + have hs : Function.Surjective (fun v : ArraySpace (ι:=ι) τ => scale ι • v) := by + intro v + exact ⟨(scale ι)⁻¹ • v,by simp only [smul_smul,mul_inv_cancel₀ (scale_ne_zero (ι:=ι)),one_smul]⟩ + have hd := hs.denseRange.comp (dense_algebraArray (ι:=ι) τ) + (continuous_const_smul (scale ι)) + apply hd.mono + rintro y ⟨X,rfl⟩ + exact ⟨X,representation_vacuum τ X⟩ + +noncomputable def unitary [Nonempty ι] := + VectorGNS.equivalence (A:=CStarMatrix ι ι A) (H:=ArraySpace (ι:=ι) τ) + (trace (ι:=ι) τ) (representation (ι:=ι) τ) (vacuum (ι:=ι) τ) + (trace_vector (ι:=ι) τ) (dense_vacuumOrbit (ι:=ι) τ) + +lemma unitary_algebraVector [Nonempty ι] (X : CStarMatrix ι ι A) : + unitary (ι:=ι) τ (TracialGNS.algebraVector (trace (ι:=ι) τ) X)=scale ι • algebraArray τ X := by + rw [unitary,VectorGNS.equivalence_algebraVector,representation_vacuum] + +lemma unitary_intertwines [Nonempty ι] (X : CStarMatrix ι ι A) + (v : (trace (ι:=ι) τ).GNS) : + unitary (ι:=ι) τ ((trace (ι:=ι) τ).gnsStarAlgHom X v)= + representation τ X (unitary (ι:=ι) τ v) := + VectorGNS.equivalence_intertwines _ _ _ _ _ _ _ + +lemma unitary_conjugates [Nonempty ι] (X : CStarMatrix ι ι A) : + (unitary (ι:=ι) τ).conjStarAlgEquiv ((trace (ι:=ι) τ).gnsStarAlgHom X)=representation τ X := + VectorGNS.equivalence_conjugates _ _ _ _ _ _ + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixInclusion.lean b/lean/OAI/Analysis/Commutator/MatrixInclusion.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae6ab4379394a1989e798d3f7f56aaa8e2607a44 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixInclusion.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixVonNeumann + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] (i₀ : ι) + +lemma matrixVonNeumann_mono {Q M : VonNeumannAlgebra H} (hQM : Q≤M) : + matrixVonNeumann ι i₀ Q ≤ matrixVonNeumann ι i₀ M := by + intro X hX + rw [mem_matrixVonNeumann] at hX ⊢ + exact fun i j => hQM (hX i j) + +lemma matrixVonNeumann_irreducible (Q M : VonNeumannAlgebra H) + (hirred : ∀ z∈M, z∈Set.centralizer (Q:Set (H →L[ℂ] H)) → + ∃ c : ℂ,z=c • (1 : H →L[ℂ] H)) + (Z : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (hZ : Z∈matrixVonNeumann ι i₀ M) + (hc : Z∈Set.centralizer (matrixVonNeumann ι i₀ Q:Set _)) : + ∃ c : ℂ,Z=c • (1 : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) := by + have he : Z=diagonal (H:=H) ι (entry ι Z i₀ i₀) := + diagonal_of_matrixUnits ι i₀ Z (fun i j => hc _ (matrixUnit_mem ι i₀ Q i j)) + have ha := (mem_matrixVonNeumann ι i₀ M Z).mp hZ i₀ i₀ + have hca : entry ι Z i₀ i₀∈Set.centralizer (Q:Set (H →L[ℂ] H)) := by + intro a ha + exact entry_commutes ι Z a (hc _ (diagonal_mem_matrixVonNeumann ι i₀ Q ha)) i₀ i₀ + obtain ⟨c,hc⟩ := hirred _ ha hca + refine ⟨c,?_⟩ + rw [he,hc,map_smul,map_one] + +lemma diagonal_commutes_matrixVonNeumann (Q : VonNeumannAlgebra H) + (Y : H →L[ℂ] H) (hY : Y∈Set.centralizer (Q:Set (H →L[ℂ] H))) + (X : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (hX : X∈matrixVonNeumann ι i₀ Q) : + diagonal (H:=H) ι Y*X=X*diagonal (H:=H) ι Y := by + apply commutes_of_entries + intro i j + exact (hY _ ((mem_matrixVonNeumann ι i₀ Q X).mp hX i j)).symm + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixIndexEquiv.lean b/lean/OAI/Analysis/Commutator/MatrixIndexEquiv.lean new file mode 100644 index 0000000000000000000000000000000000000000..b0981864eecf69ba28ededc1e10b406d7b4710bf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixIndexEquiv.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTowerInclusion + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Matrix.Norms.L2Operator + +namespace Kadison.MatrixTower + +def matrixIndexEquiv {I J : Type*} [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] + (e : I ≃ J) : Matrix I I ℂ ≃⋆ₐ[ℂ] Matrix J J ℂ where + __ := (Matrix.reindexAlgEquiv ℂ ℂ e).toRingEquiv + map_smul' c a := by ext i j; rfl + map_star' a := by + change Matrix.reindex e e a.conjTranspose=(Matrix.reindex e e a).conjTranspose + exact (Matrix.conjTranspose_reindex e e a).symm + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +def normalizedSize (n : ℕ) : ℕ := Fintype.card (F n).I-1 + +lemma normalizedSize_succ (n : ℕ) : normalizedSize M F n+1=Fintype.card (F n).I := by + have h := Fintype.card_pos (α := (F n).I) + unfold normalizedSize + omega + +def normalizedIndex (n : ℕ) : Fin (normalizedSize M F n+1) ≃ (F n).I := + (finCongr (normalizedSize_succ M F n)).trans (Fintype.equivFin (F n).I).symm + +def normalizedStage (n : ℕ) : Matrix (Fin (normalizedSize M F n+1)) (Fin (normalizedSize M F n+1)) ℂ →⋆ₐ[ℂ] M := + (F n).hom.comp (matrixIndexEquiv (normalizedIndex M F n)).toStarAlgHom + +lemma normalizedStage_range (n : ℕ) : (normalizedStage M F n).range=(F n).hom.range := by + ext a + constructor + · rintro ⟨b,rfl⟩ + exact ⟨matrixIndexEquiv (normalizedIndex M F n) b,rfl⟩ + · rintro ⟨b,rfl⟩ + refine ⟨(matrixIndexEquiv (normalizedIndex M F n)).symm b,?_⟩ + change (F n).hom (matrixIndexEquiv (normalizedIndex M F n) ((matrixIndexEquiv (normalizedIndex M F n)).symm b))=_ + rw [StarAlgEquiv.apply_symm_apply] + rfl + +variable [Nontrivial M] (hF : Monotone (fun n => (F n).hom.range)) + +def normalizedInclusion {n m : ℕ} (h : n ≤ m) : + Matrix (Fin (normalizedSize M F n+1)) (Fin (normalizedSize M F n+1)) ℂ →⋆ₐ[ℂ] + Matrix (Fin (normalizedSize M F m+1)) (Fin (normalizedSize M F m+1)) ℂ := + (matrixIndexEquiv (normalizedIndex M F m)).symm.toStarAlgHom.comp + ((stageInclusion M F hF h).comp (matrixIndexEquiv (normalizedIndex M F n)).toStarAlgHom) + +lemma normalizedInclusion_commutes {n m : ℕ} (h : n ≤ m) (a) : + normalizedStage M F m (normalizedInclusion M F hF h a)=normalizedStage M F n a := by + change (F m).hom (matrixIndexEquiv (normalizedIndex M F m) + ((matrixIndexEquiv (normalizedIndex M F m)).symm + (stageInclusion M F hF h (matrixIndexEquiv (normalizedIndex M F n) a))))=_ + rw [StarAlgEquiv.apply_symm_apply,stageInclusion_commutes] + rfl + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixModules.lean b/lean/OAI/Analysis/Commutator/MatrixModules.lean new file mode 100644 index 0000000000000000000000000000000000000000..45e866efbf7b6a31585e3fd574808a92bac7c12a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixModules.lean @@ -0,0 +1,146 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.MatrixModules + +open Matrix + +variable {𝕜 I E : Type*} [Field 𝕜] [Fintype I] [DecidableEq I] + [AddCommGroup E] [Module 𝕜 E] + +variable (ρ : Matrix I I 𝕜 →ₐ[𝕜] Module.End 𝕜 E) (o : I) + +abbrev corner : Submodule 𝕜 E := LinearMap.range (ρ (single o o 1)) + +lemma corner_fixed (x : corner ρ o) : ρ (single o o 1) (x : E) = x := by + obtain ⟨y, hy⟩ := x.property + rw [← hy] + change (ρ (single o o 1) * ρ (single o o 1)) y = _ + rw [← map_mul, Matrix.single_mul_single_same, one_mul] + +noncomputable def coordinates (i : I) : E →ₗ[𝕜] corner ρ o := + (ρ (single o i 1)).codRestrict _ (fun x => by + refine ⟨ρ (single o i 1) x, ?_⟩ + change (ρ (single o o 1) * ρ (single o i 1)) x = _ + rw [← map_mul, Matrix.single_mul_single_same, one_mul]) + +noncomputable def recombine : (I → corner ρ o) →ₗ[𝕜] E := + ∑ i : I, (ρ (single i o 1)).comp + ((corner ρ o).subtype.comp (LinearMap.proj i)) + +@[simp] lemma coordinates_apply (i : I) (x : E) : + (coordinates ρ o i x : E) = ρ (single o i 1) x := rfl + +@[simp] lemma recombine_apply (x : I → corner ρ o) : + recombine ρ o x = ∑ i : I, ρ (single i o 1) (x i : E) := by + simp [recombine] + +lemma coordinates_recombine (x : I → corner ρ o) (i : I) : + coordinates ρ o i (recombine ρ o x) = x i := by + apply Subtype.ext + rw [coordinates_apply, recombine_apply, map_sum] + have hdiag : ρ (single o i 1) (ρ (single i o 1) (x i : E)) = x i := by + change (ρ (single o i 1) * ρ (single i o 1)) (x i : E) = _ + rw [← map_mul, Matrix.single_mul_single_same, one_mul] + exact corner_fixed ρ o _ + rw [Finset.sum_eq_single i] + · exact hdiag + · intro j _ hji + change (ρ (single o i 1) * ρ (single j o 1)) (x j : E) = 0 + rw [← map_mul, Matrix.single_mul_single_of_ne 1 o i j hji.symm 1, + map_zero, LinearMap.zero_apply] + · simp + +lemma recombine_coordinates (x : E) : + recombine ρ o (fun i => coordinates ρ o i x) = x := by + rw [recombine_apply] + simp only [coordinates_apply] + have h (i : I) : ρ (single i o 1) (ρ (single o i 1) x) = ρ (single i i 1) x := by + change (ρ (single i o 1) * ρ (single o i 1)) x = _ + rw [← map_mul, Matrix.single_mul_single_same, one_mul] + simp only [h] + rw [← LinearMap.sum_apply, ← map_sum, Matrix.sum_single_one, map_one] + rfl + +noncomputable def moduleEquiv : (I → corner ρ o) ≃ₗ[𝕜] E where + __ := recombine ρ o + invFun x i := coordinates ρ o i x + left_inv x := funext (coordinates_recombine ρ o x) + right_inv := recombine_coordinates ρ o + +lemma moduleEquiv_intertwines (a : Matrix I I 𝕜) (x : I → corner ρ o) : + ρ a (moduleEquiv ρ o x) = moduleEquiv ρ o (fun i => ∑ j, a i j • x j) := by + change ρ a (recombine ρ o x) = recombine ρ o _ + simp only [recombine_apply, Submodule.coe_sum, Submodule.coe_smul, map_sum, + map_smul] + have hm (j : I) : a * single j o 1 = ∑ i, a i j • single i o 1 := by + ext i k + simp only [Matrix.sum_apply, Matrix.smul_apply, smul_eq_mul, Matrix.mul_apply, + Matrix.single, Matrix.of_apply] + by_cases h : o = k <;> simp [h] + calc + (∑ j, ρ a (ρ (single j o 1) (x j : E))) = + ∑ j, ∑ i, a i j • ρ (single i o 1) (x j : E) := by + apply Finset.sum_congr rfl + intro j _ + change (ρ a * ρ (single j o 1)) (x j : E) = _ + rw [← map_mul, hm, map_sum, LinearMap.sum_apply] + simp only [map_smul, LinearMap.smul_apply] + _ = _ := Finset.sum_comm + +section Coordinates + +variable {R : Type*} [Fintype R] + +noncomputable def basisCopies (b : Module.Basis R 𝕜 (corner ρ o)) : + (I × R → 𝕜) ≃ₗ[𝕜] (I → corner ρ o) := + (LinearEquiv.curry 𝕜 𝕜 I R).trans + (LinearEquiv.piCongrRight fun _ => b.equivFun.symm) + +@[simp] lemma basisCopies_apply (b : Module.Basis R 𝕜 (corner ρ o)) (v : I × R → 𝕜) + (i : I) : basisCopies ρ o b v i = b.equivFun.symm (fun r => v (i, r)) := rfl + +def inflate [DecidableEq R] (a : Matrix I I 𝕜) : Matrix (I × R) (I × R) 𝕜 := + fun x y => if x.2 = y.2 then a x.1 y.1 else 0 + +omit [DecidableEq I] in +lemma inflate_mulVec [DecidableEq R] (a : Matrix I I 𝕜) (v : I × R → 𝕜) + (i : I) (r : R) : (inflate (R := R) a *ᵥ v) (i, r) = ∑ j, a i j * v (j, r) := by + classical + simp [Matrix.mulVec, dotProduct, inflate, Fintype.sum_prod_type] + +lemma basisCopies_intertwines [DecidableEq R] (b : Module.Basis R 𝕜 (corner ρ o)) + (a : Matrix I I 𝕜) (v : I × R → 𝕜) : + basisCopies ρ o b (inflate a *ᵥ v) = + fun i => ∑ j, a i j • basisCopies ρ o b v j := by + funext i + simp only [basisCopies_apply, inflate_mulVec] + apply b.equivFun.injective + rw [LinearEquiv.apply_symm_apply, map_sum] + simp only [map_smul, LinearEquiv.apply_symm_apply] + ext r + simp only [Finset.sum_apply, Pi.smul_apply, smul_eq_mul] + +noncomputable def representationEquiv (b : Module.Basis R 𝕜 (corner ρ o)) : + (I × R → 𝕜) ≃ₗ[𝕜] E := (basisCopies ρ o b).trans (moduleEquiv ρ o) + +lemma representationEquiv_intertwines [DecidableEq R] + (b : Module.Basis R 𝕜 (corner ρ o)) (a : Matrix I I 𝕜) (v : I × R → 𝕜) : + ρ a (representationEquiv ρ o b v) = representationEquiv ρ o b (inflate a *ᵥ v) := by + change ρ a (moduleEquiv ρ o (basisCopies ρ o b v)) = + moduleEquiv ρ o (basisCopies ρ o b (inflate a *ᵥ v)) + rw [moduleEquiv_intertwines, basisCopies_intertwines] + +end Coordinates + +end Kadison.MatrixModules +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixNormalTrace.lean b/lean/OAI/Analysis/Commutator/MatrixNormalTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..7314cb788121b26705d4e911ee600cc62c7d731b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixNormalTrace.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixAlgebraEquiv +import OAI.Analysis.Commutator.MatrixEntryWOT +import OAI.Analysis.Commutator.MatrixTraceFaithful +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace ComplexOrder Topology + +open ContinuousLinearMapWOT + +namespace Kadison.OperatorAmplification + +lemma equiv_star_mul {B C : Type*} [CStarAlgebra B] [CStarAlgebra C] + (e : B ≃⋆ₐ[ℂ] C) (x : B) : e (star x*x)=star (e x)*e x := by + rw [map_mul,map_star] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] (i₀ : ι) (M : VonNeumannAlgebra H) + +local instance : DecidableEq ι := Classical.decEq ι + +variable (τ : M →ₚ[ℂ] ℂ) + +def matrixTrace : matrixVonNeumann ι i₀ M →ₚ[ℂ] ℂ where + toLinearMap := (MatrixGNS.trace (ι:=ι) τ).toLinearMap.comp + (matrixEquiv ι i₀ M).symm.toStarAlgHom.toLinearMap + monotone' := (MatrixGNS.trace (ι:=ι) τ).monotone.comp + (OrderHomClass.monotone (matrixEquiv ι i₀ M).symm.toStarAlgHom) + +lemma matrixTrace_equiv (X : CStarMatrix ι ι M) : + matrixTrace ι i₀ M τ (matrixEquiv ι i₀ M X)=MatrixGNS.trace (ι:=ι) τ X := by + change MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm (matrixEquiv ι i₀ M X))=_ + rw [StarAlgEquiv.symm_apply_apply] + +lemma matrixTrace_apply (T : matrixVonNeumann ι i₀ M) : + matrixTrace ι i₀ M τ T=(Fintype.card ι : ℂ)⁻¹ * ∑ i, + τ ⟨entry ι (T:SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) i i, + (mem_matrixVonNeumann ι i₀ M T).mp T.property i i⟩ := by + change MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm T)=_ + rw [MatrixGNS.trace_apply] + congr 1 + apply Finset.sum_congr rfl + intro i _ + congr 1 + apply Subtype.ext + exact matrixEquiv_symm_entry ι i₀ M T i i + +lemma matrixTrace_one (h1 : τ 1=1) : matrixTrace ι i₀ M τ 1=1 := by + let : Nonempty ι := ⟨i₀⟩ + change MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm 1)=1 + rw [map_one,MatrixGNS.trace_one τ h1] + +lemma matrixTrace_tracial (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (X Y : matrixVonNeumann ι i₀ M) : + matrixTrace ι i₀ M τ (X*Y)=matrixTrace ι i₀ M τ (Y*X) := by + change MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm (X*Y))= + MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm (Y*X)) + simp only [map_mul] + exact MatrixGNS.trace_mul (ι:=ι) τ hτ _ _ + +lemma matrixTrace_faithful (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + (X : matrixVonNeumann ι i₀ M) (hX : matrixTrace ι i₀ M τ (star X*X)=0) : X=0 := by + let : Nonempty ι := ⟨i₀⟩ + apply (matrixEquiv ι i₀ M).symm.injective + rw [map_zero] + apply MatrixGNS.trace_faithful (ι:=ι) τ hfaith + change MatrixGNS.trace (ι:=ι) τ ((matrixEquiv ι i₀ M).symm (star X*X))=0 at hX + rw [equiv_star_mul] at hX + exact hX + +lemma matrixTrace_normal (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + NormalGNS.BoundedWOTContinuous (matrixVonNeumann ι i₀ M) (matrixTrace ι i₀ M τ) := by + intro C + let F := {T : SumSpace (H:=H) ι →WOT[ℂ] SumSpace (H:=H) ι // + T.toCLM∈matrixVonNeumann ι i₀ M ∧ ‖T.toCLM‖≤C} + let f (i : ι) : F → {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} := + fun a => ⟨ofCLM (entry ι a.val.toCLM i i), + (mem_matrixVonNeumann ι i₀ M a.val.toCLM).mp a.property.1 i i, + (norm_entry_le ι a.val.toCLM i i).trans a.property.2⟩ + have hf (i : ι) : Continuous (f i) := + ((continuous_entryWOT ι i i).comp continuous_subtype_val).subtype_mk _ + have ht (i : ι) : Continuous (fun a : F => τ ⟨(f i a).val.toCLM,(f i a).property.1⟩) := + (hnormal C).comp (hf i) + convert continuous_const.mul (continuous_finsetSum Finset.univ (fun i _ => ht i)) using 1 + ext a + exact matrixTrace_apply ι i₀ M τ _ + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixPadding.lean b/lean/OAI/Analysis/Commutator/MatrixPadding.lean new file mode 100644 index 0000000000000000000000000000000000000000..01beddba4ef3fdc0f624359f360c7281fbd9cda3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixPadding.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertPadding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.HilbertPadding + +open OperatorAmplification CyclicColumns + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +local instance matrixPaddingSourceDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance matrixPaddingComplementDecidableEq : DecidableEq κ := Classical.decEq κ + +lemma leftCopies_adjoint_apply (v : SumSpace (H:=H) (ι⊕κ)) : + (leftCopies (H:=H) ι κ).toContinuousLinearMap.adjoint v= + WithLp.toLp 2 (fun i => v (Sum.inl i)) := by + apply ext_inner_left ℂ + intro w + rw [adjoint_inner_right] + simp [PiLp.inner_apply,Fintype.sum_sum_type] + +def padMatrix : CStarMatrix ι ι A →⋆ₙₐ[ℂ] CStarMatrix (ι⊕κ) (ι⊕κ) A where + toFun X := CStarMatrix.ofMatrix (Matrix.fromBlocks (fun i j => X i j) 0 0 0) + map_zero' := by ext i j; cases i <;> cases j <;> simp [Matrix.fromBlocks] + map_add' X Y := by ext i j; cases i <;> cases j <;> simp [Matrix.fromBlocks] + map_smul' z X := by ext i j; cases i <;> cases j <;> simp [Matrix.fromBlocks] + map_mul' X Y := by + ext i j + cases i <;> cases j <;> + simp [CStarMatrix.mul_apply,Fintype.sum_sum_type,Matrix.fromBlocks] + map_star' X := by + ext i j + cases i <;> cases j <;> simp [CStarMatrix.star_apply,Matrix.fromBlocks] + +lemma norm_padMatrix_le (X : CStarMatrix ι ι A) : ‖padMatrix ι κ X‖ ≤ ‖X‖ := + NonUnitalStarAlgHom.norm_apply_le (padMatrix ι κ) X + +lemma representation_padMatrix (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (X : CStarMatrix ι ι A) : + matrixRepresentation ρ (padMatrix ι κ X)= + extend (leftCopies (H:=H) ι κ) (matrixRepresentation ρ X) := by + ext v i + change matrixAction (fun i j => ρ (padMatrix ι κ X i j)) v i= + leftCopies (H:=H) ι κ + (matrixRepresentation ρ X ((leftCopies (H:=H) ι κ).toContinuousLinearMap.adjoint v)) i + rw [leftCopies_adjoint_apply] + cases i <;> simp [padMatrix,Fintype.sum_sum_type,matrixRepresentation,matrixAction_apply,Matrix.fromBlocks] + +lemma diagonal_commutator_extend (Y : H →L[ℂ] H) + (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) : + diagonal (H:=H) (ι⊕κ) Y*extend (leftCopies ι κ) T- + extend (leftCopies ι κ) T*diagonal (H:=H) (ι⊕κ) Y= + extend (leftCopies ι κ) (diagonal (H:=H) ι Y*T-T*diagonal (H:=H) ι Y) := by + have h := extend_commutator (leftCopies (H:=H) ι κ) T (diagonal (H:=H) ι Y) + (diagonal (H:=H) (ι⊕κ) Y) (leftCopies_diagonal ι κ Y) (adjoint_leftCopies_diagonal ι κ Y) + have hn := congrArg Neg.neg h + simpa only [neg_sub,extend,comp_sub,sub_comp] using hn + +theorem matrix_padding_commutator_norm (ρ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (Y : H →L[ℂ] H) (X : CStarMatrix ι ι A) : + ‖diagonal (H:=H) (ι⊕κ) Y*matrixRepresentation ρ (padMatrix ι κ X)- + matrixRepresentation ρ (padMatrix ι κ X)*diagonal (H:=H) (ι⊕κ) Y‖= + ‖diagonal (H:=H) ι Y*matrixRepresentation ρ X- + matrixRepresentation ρ X*diagonal (H:=H) ι Y‖ := by + rw [representation_padMatrix,diagonal_commutator_extend,norm_extend] + +end Kadison.HilbertPadding + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixProjectionDiagonal.lean b/lean/OAI/Analysis/Commutator/MatrixProjectionDiagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..7146bec89c3990d7234d0ca36d7629f951588cb9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixProjectionDiagonal.lean @@ -0,0 +1,78 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder Matrix + +namespace Kadison.MatrixCorners + +variable {I : Type*} [Fintype I] [DecidableEq I] + +attribute [local instance] Classical.propDecidable + +omit [DecidableEq I] in +lemma projection_hermitian (p : Matrix I I ℂ) (hp : IsStarProjection p) : p.IsHermitian := hp.isSelfAdjoint + +def projectionIndices (p : Matrix I I ℂ) (hp : IsStarProjection p) : Set I := + {i | (projection_hermitian p hp).eigenvalues i = 1} + +lemma projection_eigenvalue (p : Matrix I I ℂ) (hp : IsStarProjection p) (i : I) : + (projection_hermitian p hp).eigenvalues i=0 ∨ (projection_hermitian p hp).eigenvalues i=1 := by + let U := (projection_hermitian p hp).eigenvectorUnitary + have hid := congrArg (Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) (star U)) hp.isIdempotentElem.eq + rw [map_mul] at hid + have hd := (projection_hermitian p hp).conjStarAlgAut_star_eigenvectorUnitary + change Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) (star U) p = _ at hd + rw [hd] at hid + have h := congrArg (fun M : Matrix I I ℂ => (M i i).re) hid + simp only [Matrix.diagonal_mul_diagonal,Matrix.diagonal_apply_eq,Function.comp_apply, + ] at h + change ((projection_hermitian p hp).eigenvalues i : ℂ).re * + ((projection_hermitian p hp).eigenvalues i : ℂ).re - + ((projection_hermitian p hp).eigenvalues i : ℂ).im * + ((projection_hermitian p hp).eigenvalues i : ℂ).im = + ((projection_hermitian p hp).eigenvalues i : ℂ).re at h + simp only [Complex.ofReal_re,Complex.ofReal_im,mul_zero,sub_zero] at h + have hz : (projection_hermitian p hp).eigenvalues i * + ((projection_hermitian p hp).eigenvalues i-1)=0 := by nlinarith + exact (mul_eq_zero.mp hz).imp id sub_eq_zero.mp + +lemma projection_diagonal_form (p : Matrix I I ℂ) (hp : IsStarProjection p) : + p=Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) (projection_hermitian p hp).eigenvectorUnitary + (Matrix.diagonal (fun i => if i∈projectionIndices p hp then (1:ℂ) else 0)) := by + apply (projection_hermitian p hp).spectral_theorem.trans + congr 1 + ext i j + by_cases h : i=j + · subst j + simp only [Matrix.diagonal_apply_eq,Function.comp_apply,projectionIndices,Set.mem_ofPred_eq] + rcases projection_eigenvalue p hp i with he|he <;> simp [he] + · simp [Matrix.diagonal_apply_ne _ h] + +lemma trace_conjugation (U : unitary (Matrix I I ℂ)) (a : Matrix I I ℂ) : + (Unitary.conjStarAlgAut ℂ (Matrix I I ℂ) U a).trace=a.trace := by + rw [Unitary.conjStarAlgAut_apply,Matrix.trace_mul_comm,←mul_assoc,Unitary.coe_star_mul_self,one_mul] + +lemma projection_trace (p : Matrix I I ℂ) (hp : IsStarProjection p) : + p.trace=(Fintype.card (projectionIndices p hp):ℂ) := by + classical + calc + _ = _ := congrArg Matrix.trace (projection_diagonal_form p hp) + _ = _ := by + rw [trace_conjugation,Matrix.trace_diagonal] + simp [Fintype.card_subtype] + +end Kadison.MatrixCorners + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixReindexBound.lean b/lean/OAI/Analysis/Commutator/MatrixReindexBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..b64f5c3feac0ed4390f66b1614dea4db0e8fef5a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixReindexBound.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.CyclicColumns + +variable {A H ι κ : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] [Fintype κ] + +def reindexHilbert (e : ι ≃ κ) : PiLp 2 (fun _ : ι => H) ≃ₗᵢ[ℂ] PiLp 2 (fun _ : κ => H) where + toFun x := WithLp.toLp 2 (fun j => x (e.symm j)) + invFun x := WithLp.toLp 2 (fun i => x (e i)) + left_inv x := by ext i; simp + right_inv x := by ext i; simp + map_add' x y := by ext i; rfl + map_smul' c x := by ext i; rfl + norm_map' x := by + rw [PiLp.norm_eq_of_L2,PiLp.norm_eq_of_L2] + congr 1 + exact Fintype.sum_equiv e.symm _ _ (fun j => rfl) + +lemma matrixAction_reindex (e : ι ≃ κ) (X : ι → ι → H →L[ℂ] H) : + matrixAction (fun i j => X (e.symm i) (e.symm j))= + (reindexHilbert (H:=H) e).conjStarAlgEquiv (matrixAction X) := by + ext x i + rw [matrixAction_apply,LinearIsometryEquiv.conjStarAlgEquiv_apply_apply] + change ∑ j : κ,X (e.symm i) (e.symm j) (x j)= + matrixAction X (WithLp.toLp 2 (fun j => x (e j))) (e.symm i) + rw [matrixAction_apply] + exact Fintype.sum_equiv e.symm _ _ (fun j => by simp) + +lemma matrixAction_reindex_norm (e : ι ≃ κ) (X : ι → ι → H →L[ℂ] H) : + ‖matrixAction (fun i j => X (e.symm i) (e.symm j))‖=‖matrixAction X‖ := by + rw [matrixAction_reindex] + rw [LinearIsometryEquiv.conjStarAlgEquiv_apply, + ContinuousLinearMap.opNorm_linearIsometryEquiv_comp, + ContinuousLinearMap.opNorm_comp_linearIsometryEquiv] + +lemma matrix_bound_of_fin (D : A → H →L[ℂ] H) {c : ℝ} (hc : 0≤c) + (hfin : ∀ h : ℕ,1≤h → ∀ X : CStarMatrix (Fin h) (Fin h) A, + ‖matrixAction (fun i j => D (X i j))‖≤c*‖X‖) + (X : CStarMatrix ι ι A) : ‖matrixAction (fun i j => D (X i j))‖≤c*‖X‖ := by + classical + cases isEmpty_or_nonempty ι with + | inl hi => + have hz : matrixAction (fun i j => D (X i j))=0 := by ext x i; exact isEmptyElim i + rw [hz,norm_zero] + exact mul_nonneg hc (norm_nonneg X) + | inr hi => + let e := Fintype.equivFin ι + have hn := hfin (Fintype.card ι) (Fintype.card_pos_iff.mpr hi) + (CStarMatrix.reindexₐ ℂ A e X) + have he : matrixAction (fun i j => D ((CStarMatrix.reindexₐ ℂ A e X) i j))= + matrixAction (fun i j => D (X (e.symm i) (e.symm j))) := rfl + rw [he,matrixAction_reindex_norm e (fun i j => D (X i j)), + StarAlgEquiv.norm_map (CStarMatrix.reindexₐ ℂ A e) X] at hn + exact hn + +end Kadison.CyclicColumns + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixRowCorner.lean b/lean/OAI/Analysis/Commutator/MatrixRowCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..58e33d72ab8bcc5a4adc83e692d801193cffce11 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixRowCorner.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixVectorTrace +import OAI.Analysis.Commutator.RowOperator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.MatrixGNS + +variable {A ι : Type*} [CStarAlgebra A] [Fintype ι] + +local instance matrixRowCornerDecidableEq : DecidableEq ι := Classical.decEq ι + +def rowMatrix (i : ι) (a : A) : CStarMatrix ι ι A := + CStarMatrix.ofMatrix (fun j k => if j=i ∧ k=i then a else 0) + +omit [Fintype ι] in +@[simp] lemma rowMatrix_apply (i : ι) (a : A) (j k : ι) : + rowMatrix i a j k=if j=i ∧ k=i then a else 0 := rfl + +lemma rowMatrix_corner (i : ι) (X : CStarMatrix ι ι A) : + rowMatrix i (1:A)*X*rowMatrix i (1:A)=rowMatrix i (X i i) := by + ext j k + simp only [CStarMatrix.mul_apply,rowMatrix_apply] + by_cases hj : j=i <;> by_cases hk : k=i <;> simp [hj,hk] + +lemma rowMatrix_mul (i : ι) (a b : A) : rowMatrix i a*rowMatrix i b=rowMatrix i (a*b) := by + ext j k + simp only [CStarMatrix.mul_apply,rowMatrix_apply] + by_cases hj : j=i <;> by_cases hk : k=i <;> simp [hj,hk] + +omit [Fintype ι] in +lemma rowMatrix_star (i : ι) (a : A) : star (rowMatrix i a)=rowMatrix i (star a) := by + ext j k + simp only [CStarMatrix.star_apply,rowMatrix_apply] + by_cases hj : j=i <;> by_cases hk : k=i <;> simp [hj,hk] + +lemma rowMatrix_projection (i : ι) : IsStarProjection (rowMatrix i (1:A)) := by + constructor + · change rowMatrix i (1:A)*rowMatrix i (1:A)=rowMatrix i 1 + rw [rowMatrix_mul,one_mul] + · change star (rowMatrix i (1:A))=rowMatrix i 1 + rw [rowMatrix_star,star_one] + +variable [PartialOrder A] [StarOrderedRing A] + +lemma rowMatrix_trace (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1=1) (i : ι) : + trace (ι:=ι) τ (rowMatrix i (1:A))=(Fintype.card ι : ℂ)⁻¹ := by + rw [trace_apply] + simp [rowMatrix_apply,apply_ite,h1] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma rowMatrix_representation (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (i : ι) (a : A) : + CyclicColumns.matrixRepresentation σ (rowMatrix i a)= + OperatorAmplification.position ι i i (σ a) := by + ext v j + simp only [CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply, + StarAlgHom.coe_mk,rowMatrix_apply,OperatorAmplification.position_apply, + OperatorAmplification.single_apply] + by_cases hj : j=i <;> simp [hj,apply_ite,ite_apply] + +lemma row_corner_commutator_bound (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (T : H →L[ℂ] H) {c : ℝ} (hc : 0≤c) + (hT : ∀ a : A,‖T*σ a-σ a*T‖≤c*‖a‖) (i : ι) + (X : CStarMatrix ι ι A) (hX : rowMatrix i (1:A)*X*rowMatrix i (1:A)=X) : + ‖OperatorAmplification.diagonal (H:=H) ι T*CyclicColumns.matrixRepresentation σ X- + CyclicColumns.matrixRepresentation σ X*OperatorAmplification.diagonal (H:=H) ι T‖≤c*‖X‖ := by + have he : X=rowMatrix i (X i i) := hX.symm.trans (rowMatrix_corner i X) + calc + _ = ‖T*σ (X i i)-σ (X i i)*T‖ := by + conv_lhs => rw [he,rowMatrix_representation, + OperatorAmplification.norm_diagonal_commutator_position] + _ ≤ c*‖X i i‖ := hT _ + _ ≤ c*‖X‖ := mul_le_mul_of_nonneg_left CStarMatrix.norm_entry_le_norm hc + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixScalar.lean b/lean/OAI/Analysis/Commutator/MatrixScalar.lean new file mode 100644 index 0000000000000000000000000000000000000000..57199f1c3e2c3d1cde5a685ba36fa540c67bd1d6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixScalar.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixFlatten + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.MatrixScalar + +variable {A B : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable {ι : Type*} [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +def scalarHom : ℂ →⋆ₐ[ℂ] A where + __ := Algebra.ofId ℂ A + map_star' c := by simp [Algebra.algebraMap_eq_smul_one] + +def amplify (φ : A →⋆ₐ[ℂ] B) : CStarMatrix ι ι A →⋆ₐ[ℂ] CStarMatrix ι ι B where + __ := CStarMatrix.mapₙₐ φ.toNonUnitalStarAlgHom + map_one' := by + ext i j + change φ (if i=j then 1 else 0)=(if i=j then 1 else 0) + by_cases h : i=j <;> simp [h] + commutes' c := by + ext i j + change φ (if i=j then algebraMap ℂ A c else 0)=(if i=j then algebraMap ℂ B c else 0) + by_cases h : i=j <;> simp [h,Algebra.algebraMap_eq_smul_one] + +@[simp] lemma amplify_apply (φ : A →⋆ₐ[ℂ] B) (X : CStarMatrix ι ι A) (i j : ι) : + amplify φ X i j=φ (X i j) := rfl + +def scalarMatrix : CStarMatrix ι ι ℂ →⋆ₐ[ℂ] CStarMatrix ι ι A := amplify scalarHom + +@[simp] lemma scalarMatrix_apply (X : CStarMatrix ι ι ℂ) (i j : ι) : + scalarMatrix (A:=A) X i j=algebraMap ℂ A (X i j) := rfl + +lemma scalarMatrix_injective [Nontrivial A] : Function.Injective (scalarMatrix (ι:=ι) (A:=A)) := by + intro X Y h + ext i j + apply (algebraMap ℂ A).injective + exact congrArg (fun Z : CStarMatrix ι ι A => Z i j) h + +lemma map_scalar_left (f : A →ₗ[ℂ] B) (p : CStarMatrix ι ι ℂ) (X : CStarMatrix ι ι A) : + CStarMatrix.mapₗ f (scalarMatrix p*X)=scalarMatrix p*CStarMatrix.mapₗ f X := by + ext i j + change f (∑ k,algebraMap ℂ A (p i k)*X k j)=∑ k,algebraMap ℂ B (p i k)*f (X k j) + simp only [Algebra.algebraMap_eq_smul_one,smul_mul_assoc,one_mul,map_sum,map_smul] + +lemma map_scalar_right (f : A →ₗ[ℂ] B) (p : CStarMatrix ι ι ℂ) (X : CStarMatrix ι ι A) : + CStarMatrix.mapₗ f (X*scalarMatrix p)=CStarMatrix.mapₗ f X*scalarMatrix p := by + ext i j + change f (∑ k,X i k*algebraMap ℂ A (p k j))=∑ k,f (X i k)*algebraMap ℂ B (p k j) + simp only [Algebra.algebraMap_eq_smul_one,mul_smul_comm,mul_one,map_sum,map_smul] + +lemma map_scalar_bimodule (f : A →ₗ[ℂ] B) (p q : CStarMatrix ι ι ℂ) (X : CStarMatrix ι ι A) : + CStarMatrix.mapₗ f (scalarMatrix p*X*scalarMatrix q)= + scalarMatrix p*CStarMatrix.mapₗ f X*scalarMatrix q := by + rw [map_scalar_right,map_scalar_left] + +end Kadison.MatrixScalar + +namespace Kadison.MatrixGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +local instance : DecidableEq ι := Classical.decEq ι + +local instance : DecidableEq κ := Classical.decEq κ + +local instance : DecidableEq (κ×ι) := Classical.decEq (κ×ι) + +local instance : DecidableEq (ι×κ) := Classical.decEq (ι×κ) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma flatten_symm_apply (X : CStarMatrix (κ×ι) (κ×ι) A) (i j : κ) (k l : ι) : + (flatten ι κ).symm X i j k l=X (i,k) (j,l) := by + exact congrArg (fun Z : CStarMatrix (κ×ι) (κ×ι) A => Z (i,k) (j,l)) + ((flatten ι κ).apply_symm_apply X) + +def shuffle : CStarMatrix ι ι (CStarMatrix κ κ A) ≃⋆ₐ[ℂ] CStarMatrix κ κ (CStarMatrix ι ι A) := + ((flatten κ ι).trans (CStarMatrix.reindexₐ ℂ A (Equiv.prodComm ι κ))).trans (flatten ι κ).symm + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma shuffle_apply (X : CStarMatrix ι ι (CStarMatrix κ κ A)) (i j : κ) (k l : ι) : + shuffle ι κ X i j k l=X k l i j := by + simp only [shuffle,StarAlgEquiv.trans_apply,flatten_symm_apply] + rfl + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixScalarApproximation.lean b/lean/OAI/Analysis/Commutator/MatrixScalarApproximation.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0446913a9681a8cfd1818a698ef5ed5aac1bda4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixScalarApproximation.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixApproximation +import OAI.Analysis.Commutator.MatrixExpectation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.MatrixApproximation + +open TracialGNS + +section Norm + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) + +lemma trace_norm_le_vector (hone : τ 1=1) (a : A) : ‖τ a‖≤‖algebraVector τ a‖ := by + have hi : inner ℂ (algebraVector τ 1) (algebraVector τ a)=τ a := by + simp only [inner_algebraVector,star_one,one_mul] + rw [←hi] + have h1 : ‖algebraVector τ 1‖=1 := by + exact vacuum_norm τ hone + simpa only [h1,one_mul] using norm_inner_le_norm (𝕜:=ℂ) (algebraVector τ 1) (algebraVector τ a) + +end Norm + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + +include hτ hnormal hfaith hone in +theorem exists_scalar_expectation (hfac : FactorCorner.IsFactor M) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) (y : M) (hy : IsSelfAdjoint y) + {ε : ℝ} (hε : 0<ε) : + ∃ (I : Type) (_ : Fintype I) (_ : DecidableEq I) (_ : Nonempty I) + (φ : Matrix I I ℂ →⋆ₐ[ℂ] M), + Function.Injective φ ∧ 2≤Fintype.card I ∧ + ‖algebraVector τ (MatrixExpectation.expectation φ y-τ y • (1:M))‖<ε := by + obtain ⟨I,hI,hdec,hne,φ,x,hφ,hcard,he⟩ := + exists_matrix_approximation M τ hτ hnormal hfaith hone hfac hdiffuse y hy (half_pos hε) + let : Fintype I := hI + let : DecidableEq I := hdec + let : Nonempty I := hne + refine ⟨I,hI,hdec,hne,φ,hφ,hcard,?_⟩ + have heq : MatrixExpectation.expectation φ y-τ y • (1:M)= + MatrixExpectation.expectation φ (y-φ x)-τ (y-φ x) • (1:M) := by + rw [map_sub,MatrixExpectation.on_matrix_trace φ τ hτ hone,map_sub,sub_smul] + abel + have hn : ‖algebraVector τ (τ (y-φ x) • (1:M))‖≤‖algebraVector τ (y-φ x)‖ := by + rw [map_smul,norm_smul] + have h1 : ‖algebraVector τ (1:M)‖=1 := by + exact vacuum_norm τ hone + rw [h1,mul_one] + exact trace_norm_le_vector τ hone _ + rw [heq,map_sub] + calc + _≤‖algebraVector τ (MatrixExpectation.expectation φ (y-φ x))‖+ + ‖algebraVector τ (τ (y-φ x) • (1:M))‖ := norm_sub_le _ _ + _≤2*‖algebraVector τ (y-φ x)‖ := by + linarith [MatrixExpectation.norm_vector_le φ τ hτ (y-φ x)] + _<ε := by linarith + +end Kadison.MatrixApproximation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixStageExtension.lean b/lean/OAI/Analysis/Commutator/MatrixStageExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..1163be827858ddabe43e901607f783be4fcf6a85 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixStageExtension.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixExpectationNested +import OAI.Analysis.Commutator.MatrixScalarApproximation +import OAI.Analysis.Commutator.MatrixTensor +import OAI.Analysis.Commutator.NormalSubalgebra +import OAI.Analysis.Commutator.RelativeMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.MatrixStageExtension + +open TracialGNS MatrixExpectation + +lemma expectation_map {A B I : Type*} [CStarAlgebra A] [CStarAlgebra B] + [Fintype I] [DecidableEq I] (f : A →⋆ₐ[ℂ] B) + (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (a : A) : + f (expectation φ a)=expectation (f.comp φ) (f a) := by + rw [expectation_apply,expectation_apply] + simp only [map_smul,map_sum,map_mul,StarAlgHom.comp_apply] + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + +include hτ hnormal hfaith hone in +theorem exists_extension (hfac : FactorCorner.IsFactor M) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + {I : Type} [Fintype I] [DecidableEq I] [Nonempty I] + (φ : Matrix I I ℂ →⋆ₐ[ℂ] M) (x : M) (hx : IsSelfAdjoint x) + {ε : ℝ} (hε : 0<ε) : + ∃ (J : Type) (_ : Fintype J) (_ : DecidableEq J) (_ : Nonempty J) + (θ : Matrix J J ℂ →⋆ₐ[ℂ] M), + Function.Injective θ ∧ 2*Fintype.card I≤Fintype.card J ∧ φ.range≤θ.range ∧ + ‖algebraVector τ (expectation θ x-τ x • (1:M))‖<ε := by + classical + let N := RelativeMatrix.relative M φ + have hNM : N≤M := RelativeMatrix.le_original M φ + let inc := NormalSubalgebra.inclusion M N hNM + let σ := NormalSubalgebra.trace M N hNM τ + have hσ : ∀ a b : N,σ (a*b)=σ (b*a) := NormalSubalgebra.tracial M N hNM τ hτ + have hσone : σ 1=1 := NormalSubalgebra.one M N hNM τ hone + let y : N := ⟨(expectation φ x : H →L[ℂ] H), + (RelativeMatrix.mem_relative M φ _).mpr ⟨(expectation φ x).property, + fun a => congrArg Subtype.val (commutes φ x a)⟩⟩ + have hy : IsSelfAdjoint y := by + change star y=y + apply Subtype.ext + exact congrArg (fun a : M => (a : H →L[ℂ] H)) (selfAdjoint φ hx).star_eq + let o : I := Classical.choice inferInstance + obtain ⟨J,hJ,hdec,hne,ψ,hψ,hcard,happrox⟩ := + MatrixApproximation.exists_scalar_expectation N σ hσ + (NormalSubalgebra.normal M N hNM τ hnormal) + (NormalSubalgebra.faithful M N hNM τ hfaith) hσone + (RelativeMatrix.isFactor M φ hfac o) (RelativeMatrix.noMinimal M φ hdiffuse o) y hy hε + let : Fintype J := hJ + let : DecidableEq J := hdec + let : Nonempty J := hne + let χ := inc.comp ψ + have hc : ∀ a b,Commute (φ a) (χ b) := by + intro a b + exact Subtype.ext (((RelativeMatrix.mem_relative M φ _).mp (ψ b).property).2 a) + let θ := MatrixTensor.representation φ χ hc + have hleft : φ.range≤θ.range := by + rintro a ⟨b,rfl⟩ + exact MatrixTensor.left_mem φ χ hc b + have hright : χ.range≤θ.range := by + rintro a ⟨b,rfl⟩ + exact MatrixTensor.right_mem φ χ hc b + have hty : σ y=τ x := trace_preserving φ τ hτ x + have hi : inc y=expectation φ x := rfl + have hsmall : ‖algebraVector τ (expectation χ (expectation φ x)-τ x • (1:M))‖<ε := by + rw [NormalSubalgebra.vector_norm] at happrox + change ‖algebraVector τ (inc (expectation ψ y-σ y • (1:N)))‖<ε at happrox + have he : inc (expectation ψ y-σ y • (1:N))= + expectation χ (expectation φ x)-τ x • (1:M) := by + rw [map_sub,map_smul,map_one,expectation_map,hi,hty] + rwa [he] at happrox + have hcenter : algebraVector τ (expectation θ (expectation φ x)-τ x • (1:M))= + algebraVector τ (expectation θ x-τ x • (1:M)) := by + rw [map_sub,map_sub,nested_vector φ θ hleft τ hτ] + have : Nontrivial M := nontrivial_of_ne (1:M) 0 (by + intro h + have he := congrArg τ h + rw [hone,map_zero] at he + exact one_ne_zero he) + refine ⟨I×J,inferInstance,inferInstance,inferInstance,θ, + θ.toAlgHom.toRingHom.injective,?_,hleft,?_⟩ + · rw [Fintype.card_prod] + nlinarith [Fintype.card_pos (α:=I)] + · rw [←hcenter] + exact (nested_norm_le χ θ hright τ hτ (expectation φ x) (τ x)).trans_lt hsmall + +end Kadison.MatrixStageExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixStageGNSGeneration.lean b/lean/OAI/Analysis/Commutator/MatrixStageGNSGeneration.lean new file mode 100644 index 0000000000000000000000000000000000000000..490d6d892e9d7f8d9a1173ac0ab79329aa7030d3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixStageGNSGeneration.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTowerGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.NormalGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hnormal : BoundedWOTContinuous M τ) + (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] + (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] M) + +def representedStages : StarSubalgebra ℂ (H →L[ℂ] H) := + iSup fun n => (M.toStarSubalgebra.subtype.comp (φ n)).range + +lemma representedStages_le : representedStages M I φ≤M.toStarSubalgebra := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + exact (φ n b).property + +include hnormal in +theorem matrix_stages_gns (a : M) + (ha : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer + (representedStages M I φ : Set (H →L[ℂ] H)))) : + τ.gnsStarAlgHom a∈Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra τ I φ : Set _)) := by + let S := TracialGNS.stageAlgebra τ I φ + let N := bicommutant S + let T := (N.toStarSubalgebra.comap τ.gnsStarAlgHom).map M.toStarSubalgebra.subtype + have hST : representedStages M I φ≤T := by + apply iSup_le + intro n + rintro x ⟨b,rfl⟩ + refine ⟨φ n b,?_,rfl⟩ + exact subset_bicommutant S + ((le_iSup (TracialGNS.operatorStage τ I φ) n) ⟨b,rfl⟩) + have hSN (b : M) (hb : (b:H →L[ℂ] H)∈representedStages M I φ) : + τ.gnsStarAlgHom b∈N := by + obtain ⟨c,hc,hcb⟩ := hST hb + have he : c=b := Subtype.ext hcb + change τ.gnsStarAlgHom c∈N at hc + simpa only [he] using hc + exact (mem_bicommutant S _).mp + (image_bicommutant_general M τ hnormal (representedStages M I φ) + (representedStages_le M I φ) N hSN a ha) + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixStandardForm.lean b/lean/OAI/Analysis/Commutator/MatrixStandardForm.lean new file mode 100644 index 0000000000000000000000000000000000000000..d1c62aa8f6377397336c738d3d7a10d762df32f1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixStandardForm.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixGNSUnitary +import OAI.Analysis.Commutator.MatrixNormalTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] (i₀ : ι) (M : VonNeumannAlgebra H) + +local instance matrixStandardFormDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (τ : M →ₚ[ℂ] ℂ) + +def standardMatrixRepresentation : matrixVonNeumann ι i₀ M →⋆ₐ[ℂ] + (MatrixGNS.ArraySpace (ι:=ι) τ →L[ℂ] MatrixGNS.ArraySpace (ι:=ι) τ) := + (MatrixGNS.representation (ι:=ι) τ).comp (matrixEquiv ι i₀ M).symm.toStarAlgHom + +lemma standardMatrixRepresentation_equiv (X : CStarMatrix ι ι M) : + standardMatrixRepresentation ι i₀ M τ (matrixEquiv ι i₀ M X)= + MatrixGNS.representation (ι:=ι) τ X := by + change MatrixGNS.representation (ι:=ι) τ + ((matrixEquiv ι i₀ M).symm (matrixEquiv ι i₀ M X))=_ + exact congrArg (MatrixGNS.representation (ι:=ι) τ) ((matrixEquiv ι i₀ M).symm_apply_apply X) + +lemma standardMatrixTrace_vector (X : matrixVonNeumann ι i₀ M) : + matrixTrace ι i₀ M τ X=inner ℂ (MatrixGNS.vacuum (ι:=ι) τ) + (standardMatrixRepresentation ι i₀ M τ X (MatrixGNS.vacuum (ι:=ι) τ)) := rfl + +lemma standardMatrix_vacuum_cyclic : DenseRange (fun X : matrixVonNeumann ι i₀ M => + standardMatrixRepresentation ι i₀ M τ X (MatrixGNS.vacuum (ι:=ι) τ)) := by + let : Nonempty ι := ⟨i₀⟩ + apply (MatrixGNS.dense_vacuumOrbit (ι:=ι) τ).mono + rintro y ⟨X,rfl⟩ + exact ⟨matrixEquiv ι i₀ M X,congrArg (fun T => T (MatrixGNS.vacuum (ι:=ι) τ)) + (standardMatrixRepresentation_equiv ι i₀ M τ X)⟩ + +def standardMatrixUnitary := + VectorGNS.equivalence (matrixTrace ι i₀ M τ) (standardMatrixRepresentation ι i₀ M τ) + (MatrixGNS.vacuum (ι:=ι) τ) (standardMatrixTrace_vector ι i₀ M τ) + (standardMatrix_vacuum_cyclic ι i₀ M τ) + +lemma standardMatrixUnitary_intertwines (X : matrixVonNeumann ι i₀ M) + (v : (matrixTrace ι i₀ M τ).GNS) : + standardMatrixUnitary ι i₀ M τ ((matrixTrace ι i₀ M τ).gnsStarAlgHom X v)= + standardMatrixRepresentation ι i₀ M τ X (standardMatrixUnitary ι i₀ M τ v) := + VectorGNS.equivalence_intertwines _ _ _ _ _ _ _ + +lemma standardMatrixUnitary_algebraVector (X : CStarMatrix ι ι M) : + standardMatrixUnitary ι i₀ M τ + (TracialGNS.algebraVector (matrixTrace ι i₀ M τ) (matrixEquiv ι i₀ M X))= + MatrixGNS.scale ι • MatrixGNS.algebraArray τ X := by + rw [standardMatrixUnitary,VectorGNS.equivalence_algebraVector, + standardMatrixRepresentation_equiv,MatrixGNS.representation_vacuum] + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTensor.lean b/lean/OAI/Analysis/Commutator/MatrixTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..f71c2a7aa6101a97592646385fbd52660f9abf3b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTensor.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixUnits + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.MatrixTensor + +open Matrix + +variable {A I J : Type*} [Ring A] [StarRing A] [Algebra ℂ A] [StarModule ℂ A] + [Fintype I] [DecidableEq I] [Fintype J] [DecidableEq J] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (ψ : Matrix J J ℂ →⋆ₐ[ℂ] A) + (hc : ∀ x y,Commute (φ x) (ψ y)) + +omit [StarModule ℂ A] in +include hc in +lemma units_mul (i j k l : I×J) : + (φ (single i.1 j.1 1)*ψ (single i.2 j.2 1))*(φ (single k.1 l.1 1)*ψ (single k.2 l.2 1))= + if j=k then φ (single i.1 l.1 1)*ψ (single i.2 l.2 1) else 0 := by + have he : (φ (single i.1 j.1 1)*ψ (single i.2 j.2 1))*(φ (single k.1 l.1 1)*ψ (single k.2 l.2 1))= + (φ (single i.1 j.1 1)*φ (single k.1 l.1 1))*(ψ (single i.2 j.2 1)*ψ (single k.2 l.2 1)) := by + simp only [mul_assoc] + rw [←mul_assoc (ψ (single i.2 j.2 1)),(hc (single k.1 l.1 1) (single i.2 j.2 1)).eq.symm] + simp only [mul_assoc] + rw [he,←map_mul,←map_mul] + by_cases h1 : j.1=k.1 <;> by_cases h2 : j.2=k.2 + · have hjk : j=k := Prod.ext h1 h2 + subst k + simp only [single_mul_single_same,one_mul,ite_true] + · have hjk : j≠k := fun h => h2 (congrArg Prod.snd h) + rw [single_mul_single_of_ne 1 i.2 j.2 k.2 h2 1,map_zero,mul_zero,ite_eq_right hjk] + · have hjk : j≠k := fun h => h1 (congrArg Prod.fst h) + rw [single_mul_single_of_ne 1 i.1 j.1 k.1 h1 1,map_zero,zero_mul,ite_eq_right hjk] + · have hjk : j≠k := fun h => h1 (congrArg Prod.fst h) + rw [single_mul_single_of_ne 1 i.1 j.1 k.1 h1 1,map_zero,zero_mul,ite_eq_right hjk] + +omit [StarModule ℂ A] in +include hc in +lemma units_star (i j : I×J) : + star (φ (single i.1 j.1 1)*ψ (single i.2 j.2 1))= + φ (single j.1 i.1 1)*ψ (single j.2 i.2 1) := by + simp only [star_mul,←map_star,Matrix.star_eq_conjTranspose,conjTranspose_single,star_one] + exact (hc _ _).eq.symm + +omit [StarModule ℂ A] in +lemma units_one : (∑ i : I×J,φ (single i.1 i.1 1)*ψ (single i.2 i.2 1))=1 := by + rw [Fintype.sum_prod_type] + simp only [←Finset.mul_sum,←map_sum,sum_single_one,map_one,mul_one] + +def representation : Matrix (I×J) (I×J) ℂ →⋆ₐ[ℂ] A := + MatrixUnits.representation (fun i j => φ (single i.1 j.1 1)*ψ (single i.2 j.2 1)) + (units_mul φ ψ hc) (units_star φ ψ hc) (units_one φ ψ) + +@[simp] lemma representation_single (i j : I×J) : + representation φ ψ hc (single i j 1)=φ (single i.1 j.1 1)*ψ (single i.2 j.2 1) := by + simp [representation,MatrixUnits.representation,Matrix.single_apply,ite_and] + +lemma left_mem (x : Matrix I I ℂ) : φ x∈(representation φ ψ hc).range := by + have hu (i j : I) : φ (single i j 1)∈(representation φ ψ hc).range := by + have he : φ (single i j 1)=∑ k : J,representation φ ψ hc (single (i,k) (j,k) 1) := by + simp only [representation_single,←Finset.mul_sum,←map_sum,sum_single_one,map_one,mul_one] + rw [he] + exact (representation φ ψ hc).range.sum_mem (fun k _ => ⟨single (i,k) (j,k) 1,rfl⟩) + rw [Matrix.matrix_eq_sum_single x,map_sum] + apply (representation φ ψ hc).range.sum_mem + intro i hi + rw [map_sum] + apply (representation φ ψ hc).range.sum_mem + intro j hj + have he : single i j (x i j)=x i j • single i j 1 := by simp + rw [he,map_smul] + exact (representation φ ψ hc).range.smul_mem (hu i j) _ + +lemma right_mem (x : Matrix J J ℂ) : ψ x∈(representation φ ψ hc).range := by + have hu (i j : J) : ψ (single i j 1)∈(representation φ ψ hc).range := by + have he : ψ (single i j 1)=∑ k : I,representation φ ψ hc (single (k,i) (k,j) 1) := by + simp only [representation_single,←Finset.sum_mul,←map_sum,sum_single_one,map_one,one_mul] + rw [he] + exact (representation φ ψ hc).range.sum_mem (fun k _ => ⟨single (k,i) (k,j) 1,rfl⟩) + rw [Matrix.matrix_eq_sum_single x,map_sum] + apply (representation φ ψ hc).range.sum_mem + intro i hi + rw [map_sum] + apply (representation φ ψ hc).range.sum_mem + intro j hj + have he : single i j (x i j)=x i j • single i j 1 := by simp + rw [he,map_smul] + exact (representation φ ψ hc).range.smul_mem (hu i j) _ + +end Kadison.MatrixTensor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTensorRange.lean b/lean/OAI/Analysis/Commutator/MatrixTensorRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..b5f8690a16839b79d8fe14d462ae1d09dc7a5416 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTensorRange.lean @@ -0,0 +1,39 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTensor + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.MatrixTensor + +variable {A I J : Type*} [Ring A] [StarRing A] [Algebra ℂ A] [StarModule ℂ A] + [Fintype I] [DecidableEq I] [Fintype J] [DecidableEq J] + +variable (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) (ψ : Matrix J J ℂ →⋆ₐ[ℂ] A) + (hc : ∀ x y,Commute (φ x) (ψ y)) + +lemma range_le (S : StarSubalgebra ℂ A) (hφ : φ.range≤S) (hψ : ψ.range≤S) : + (representation φ ψ hc).range≤S := by + rintro a ⟨x,rfl⟩ + change (∑ i,∑ j,x i j • (φ (Matrix.single i.1 j.1 1)*ψ (Matrix.single i.2 j.2 1)))∈S + apply S.sum_mem + intro i _ + apply S.sum_mem + intro j _ + exact S.smul_mem (S.mul_mem (hφ ⟨_,rfl⟩) (hψ ⟨_,rfl⟩)) _ + +end Kadison.MatrixTensor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTower.lean b/lean/OAI/Analysis/Commutator/MatrixTower.lean new file mode 100644 index 0000000000000000000000000000000000000000..4268fe73c40030dcf978cc0540142af51a09b89b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTower.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixStageExtension + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.MatrixTower + +open TracialGNS MatrixExpectation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure Stage (M : VonNeumannAlgebra H) where + I : Type + finite : Fintype I + dec : DecidableEq I + nonempty : Nonempty I + hom : Matrix I I ℂ →⋆ₐ[ℂ] M + +attribute [instance] Stage.finite Stage.dec Stage.nonempty + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + +include hτ hnormal hfaith hone hfac hdiffuse in +lemma exists_stage_extension (F : Stage M) (x : M) (hx : IsSelfAdjoint x) + {ε : ℝ} (hε : 0<ε) : + ∃ G : Stage M, 2*Fintype.card F.I≤Fintype.card G.I ∧ F.hom.range≤G.hom.range ∧ + ‖algebraVector τ (expectation G.hom x-τ x • (1:M))‖<ε := by + obtain ⟨I,hI,hd,hn,φ,_,hc,hi,he⟩ := + MatrixStageExtension.exists_extension M τ hτ hnormal hfaith hone hfac hdiffuse F.hom x hx hε + exact ⟨⟨I,hI,hd,hn,φ⟩,hc,hi,he⟩ + +def scalarStage : Stage M where + I := Unit + finite := inferInstance + dec := inferInstance + nonempty := inferInstance + hom := MatrixUnits.representation (fun _ _ => (1:M)) (by intros; simp) + (by intros; simp) (by simp) + +variable (x : ℕ → M) (hx : ∀ j,IsSelfAdjoint (x j)) + +def next (n : ℕ) (F : Stage M) : Stage M := + Classical.choose (exists_stage_extension M τ hτ hnormal hfaith hone hfac hdiffuse F + (x (Nat.unpair n).1) (hx _) (show 0<((Nat.unpair n).2+1:ℝ)⁻¹ by positivity)) + +lemma next_spec (n : ℕ) (F : Stage M) : + 2*Fintype.card F.I≤Fintype.card (next M τ hτ hnormal hfaith hone hfac hdiffuse x hx n F).I ∧ + F.hom.range≤(next M τ hτ hnormal hfaith hone hfac hdiffuse x hx n F).hom.range ∧ + ‖algebraVector τ (expectation (next M τ hτ hnormal hfaith hone hfac hdiffuse x hx n F).hom + (x (Nat.unpair n).1)-τ (x (Nat.unpair n).1) • (1:M))‖<((Nat.unpair n).2+1:ℝ)⁻¹ := + Classical.choose_spec (exists_stage_extension M τ hτ hnormal hfaith hone hfac hdiffuse F + (x (Nat.unpair n).1) (hx _) (show 0<((Nat.unpair n).2+1:ℝ)⁻¹ by positivity)) + +def tower : ℕ → Stage M + | 0 => scalarStage M + | n+1 => next M τ hτ hnormal hfaith hone hfac hdiffuse x hx n + (tower n) + +lemma tower_increasing : Monotone (fun n => + (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx n).hom.range) := by + apply monotone_nat_of_le_succ + intro n + exact (next_spec M τ hτ hnormal hfaith hone hfac hdiffuse x hx n _).2.1 + +lemma tower_size (n : ℕ) : n+1≤ + Fintype.card (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx n).I := by + induction n with + | zero => exact Fintype.card_pos (α:=Unit) + | succ n ih => + have he := (next_spec M τ hτ hnormal hfaith hone hfac hdiffuse x hx n + (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx n)).1 + change 2*Fintype.card (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx n).I≤ + Fintype.card (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx (n+1)).I at he + omega + +lemma tower_requirement (j : ℕ) {ε : ℝ} (hε : 0<ε) : ∃ n, + ‖algebraVector τ (expectation (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx n).hom + (x j)-τ (x j) • (1:M))‖<ε := by + obtain ⟨k,hk⟩ := exists_nat_one_div_lt hε + refine ⟨Nat.pair j k+1,?_⟩ + have he := (next_spec M τ hτ hnormal hfaith hone hfac hdiffuse x hx (Nat.pair j k) + (tower M τ hτ hnormal hfaith hone hfac hdiffuse x hx (Nat.pair j k))).2.2 + simp only [Nat.unpair_pair] at he + exact he.trans (by simpa only [one_div] using hk) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerAverage.lean b/lean/OAI/Analysis/Commutator/MatrixTowerAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..3cf0bb8e7dedab1c6faa2f4afb29377aadc73333 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerAverage.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteDimensionalAverage +import OAI.Analysis.Commutator.MatrixGNS +import OAI.Analysis.Commutator.MatrixTowerClosure +import OAI.Analysis.Commutator.WeakConvergence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Matrix.Norms.L2Operator Topology + +open MeasureTheory Filter + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +def unitaryMap (n : ℕ) : unitary (Matrix (F n).I (F n).I ℂ) →* unitary M where + toFun u := TracialGNS.stageUnitary (F n).hom u + map_one' := Subtype.ext (map_one (F n).hom) + map_mul' u v := Subtype.ext (map_mul (F n).hom (u:Matrix (F n).I (F n).I ℂ) (v:Matrix (F n).I (F n).I ℂ)) + +def unitaryRepresentation (n : ℕ) : unitary (Matrix (F n).I (F n).I ℂ) →* (H ≃ₗᵢ[ℂ] H) := + (algebraUnitaryRepresentation M).comp (unitaryMap M F n) + +lemma unitaryRepresentation_continuous (n : ℕ) (x : H) : + Continuous fun u => unitaryRepresentation M F n u x := by + change Continuous fun u : unitary (Matrix (F n).I (F n).I ℂ) => ((F n).hom (u:_):H →L[ℂ] H) x + have hf : Continuous ((F n).hom : Matrix (F n).I (F n).I ℂ → M) := (F n).hom.toLinearMap.continuous_of_finiteDimensional + exact (continuous_subtype_val.comp (hf.comp continuous_subtype_val)).clm_apply continuous_const + +lemma exists_stage_approximation (Y : H →L[ℂ] H) (n : ℕ) : + ∃ Z : H →L[ℂ] H, ‖Z‖ ≤ ‖Y‖ ∧ ‖Z-Y‖ ≤ commutatorSeminorm M Y ∧ + ∀ a, Z*concreteStage M F n a=concreteStage M F n a*Z := by + classical + let := UnitaryHaar.compactUnitary (Matrix (F n).I (F n).I ℂ) + let : MeasurableSpace (unitary (Matrix (F n).I (F n).I ℂ)) := borel _ + let : BorelSpace (unitary (Matrix (F n).I (F n).I ℂ)) := ⟨rfl⟩ + let U := unitaryRepresentation M F n + let μ := UnitaryHaar.probability (unitary (Matrix (F n).I (F n).I ℂ)) + obtain ⟨Z,hZ,hcomm,hcoeff⟩ := CompactAverage.exists_average U (unitaryRepresentation_continuous M F n) Y μ + refine ⟨Z,hZ,?_,?_⟩ + · apply WeakOperatorIntegral.difference_norm μ (CompactAverage.conjugate U Y) _ Z hcoeff Y + (commutatorSeminorm_nonneg M Y) + · intro u + exact unitary_conjugate_distance M Y (unitaryMap M F n u) + · intro x y + exact ((CompactAverage.conjugate_continuous U (unitaryRepresentation_continuous M F n) Y x).inner + continuous_const).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _) + · let D : Matrix (F n).I (F n).I ℂ →ₗ[ℂ] (H →L[ℂ] H) := + { toFun := fun a => Z*concreteStage M F n a-concreteStage M F n a*Z + map_add' := by intro a b; simp only [map_add,mul_add,add_mul]; abel + map_smul' := by intro z a; simp only [map_smul,mul_smul_comm,smul_mul_assoc,smul_sub]; rfl } + have hD : D=0 := by + apply LinearMap.ext_on (CStarAlgebra.span_unitary (Matrix (F n).I (F n).I ℂ)) + intro u hu + exact sub_eq_zero.mpr (hcomm ⟨u,hu⟩) + intro a + exact sub_eq_zero.mp (congrArg (fun D => (D : Matrix (F n).I (F n).I ℂ →ₗ[ℂ] (H →L[ℂ] H)) a) hD) + +theorem exists_tower_approximation (hF : Monotone (fun n => (F n).hom.range)) + (Y : H →L[ℂ] H) : + ∃ Z : H →L[ℂ] H, ‖Z‖ ≤ ‖Y‖ ∧ ‖Z-Y‖ ≤ commutatorSeminorm M Y ∧ + ∀ a : generated M F,Z*(a:H →L[ℂ] H)=(a:H →L[ℂ] H)*Z := by + choose T hn hd hc using exists_stage_approximation M F Y + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + obtain ⟨Z,hZ,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω T ‖Y‖ (norm_nonneg Y) hn + have hconv : WeakOperatorLimit.Converges T Z (ω:Filter ℕ) := hlim + refine ⟨Z,hZ,hconv.dist Y (commutatorSeminorm_nonneg M Y) (Eventually.of_forall hd),?_⟩ + have hstage (n : ℕ) (a : Matrix (F n).I (F n).I ℂ) : + Z*concreteStage M F n a=concreteStage M F n a*Z := by + apply hconv.commutes + apply (Ultrafilter.of_le atTop) + filter_upwards [eventually_ge_atTop n] with m hm + obtain ⟨b,hb⟩ := hF hm (show (F n).hom a∈(F n).hom.range from ⟨a,rfl⟩) + have he : concreteStage M F m b=concreteStage M F n a := congrArg (fun c : M => (c:H →L[ℂ] H)) hb + rw [←he] + exact hc m b + have hcent : Z∈Set.centralizer (stageAlgebra M F : Set (H →L[ℂ] H)) := by + have hcomm : stageAlgebra M F≤StarSubalgebra.centralizer ℂ ({Z} : Set (H →L[ℂ] H)) := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + rw [StarSubalgebra.mem_centralizer_iff] + intro z hz + have he : z=Z := Set.mem_singleton_iff.mp hz + subst z + constructor + · exact hstage n b + · have hh := congrArg star (hstage n (star b)) + simpa only [star_mul,←map_star,star_star] using! hh.symm + + intro a ha + exact (((StarSubalgebra.mem_centralizer_iff ℂ).mp (hcomm ha)) Z (Set.mem_singleton Z)).1.symm + intro a + exact ((mem_generated M F a).mp a.property Z hcent) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerClosure.lean b/lean/OAI/Analysis/Commutator/MatrixTowerClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..77cfdcec1cc376c9a31cc68ff6e0766833fcf5e0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerClosure.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTower + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +abbrev concreteStage (n : ℕ) : Matrix (F n).I (F n).I ℂ →⋆ₐ[ℂ] (H →L[ℂ] H) := + M.toStarSubalgebra.subtype.comp (F n).hom + +def stageAlgebra : StarSubalgebra ℂ (H →L[ℂ] H) := ⨆ n,(concreteStage M F n).range + +def generated : VonNeumannAlgebra H where + toStarSubalgebra := StarSubalgebra.centralizer ℂ + (StarSubalgebra.centralizer ℂ (stageAlgebra M F : Set (H →L[ℂ] H))) + centralizer_centralizer' := by + have h : ((StarSubalgebra.centralizer ℂ + (StarSubalgebra.centralizer ℂ (stageAlgebra M F : Set (H →L[ℂ] H)))) : + StarSubalgebra ℂ (H →L[ℂ] H)).carrier = + Set.centralizer (Set.centralizer (stageAlgebra M F : Set (H →L[ℂ] H))) := by + exact (StarSubalgebra.coe_centralizer_centralizer ℂ _).trans (by + rw [StarMemClass.star_coe_eq,Set.union_self]) + change _ = ((StarSubalgebra.centralizer ℂ + (StarSubalgebra.centralizer ℂ (stageAlgebra M F : Set (H →L[ℂ] H)))) : + StarSubalgebra ℂ (H →L[ℂ] H)).carrier + rw [h] + simp only [Set.centralizer_centralizer_centralizer] + +lemma mem_generated (a : H →L[ℂ] H) : a∈generated M F ↔ + a∈Set.centralizer (Set.centralizer (stageAlgebra M F : Set (H →L[ℂ] H))) := by + change a∈(StarSubalgebra.centralizer ℂ + (StarSubalgebra.centralizer ℂ (stageAlgebra M F : Set (H →L[ℂ] H)))) ↔ _ + rw [←SetLike.mem_coe,StarSubalgebra.coe_centralizer_centralizer, + StarMemClass.star_coe_eq,Set.union_self] + +lemma stageAlgebra_le : stageAlgebra M F≤M.toStarSubalgebra := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + exact ((F n).hom b).property + +lemma generated_le : generated M F≤M := by + intro a ha + change a∈(M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + intro c hc + apply (mem_generated M F a).mp ha c + intro b hb + exact hc b (stageAlgebra_le M F hb) + +lemma stage_mem (n : ℕ) (a : Matrix (F n).I (F n).I ℂ) : concreteStage M F n a∈generated M F := by + apply (mem_generated M F _).mpr + apply Set.subset_centralizer_centralizer + exact (le_iSup (fun n => (concreteStage M F n).range) n) ⟨a,rfl⟩ + +def stageHom (n : ℕ) : Matrix (F n).I (F n).I ℂ →⋆ₐ[ℂ] generated M F := + (concreteStage M F n).codRestrict (generated M F).toStarSubalgebra (stage_mem M F n) + +variable (hirr : ∀ a : M,(∀ n b,(F n).hom b*a=a*(F n).hom b) → ∃ z : ℂ,a=z • (1:M)) + +include hirr in +lemma generated_irreducible (a : H →L[ℂ] H) (ha : a∈M) + (hc : a∈Set.centralizer (generated M F : Set (H →L[ℂ] H))) : + ∃ z : ℂ,a=z • (1:H →L[ℂ] H) := by + obtain ⟨z,hz⟩ := hirr ⟨a,ha⟩ (fun n b => Subtype.ext (hc _ (stage_mem M F n b))) + exact ⟨z,congrArg Subtype.val hz⟩ + +include hirr in +lemma generated_factor : FactorCorner.IsFactor (generated M F) := by + intro a ha hc + exact generated_irreducible M F hirr a (generated_le M F ha) hc + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerDiffuse.lean b/lean/OAI/Analysis/Commutator/MatrixTowerDiffuse.lean new file mode 100644 index 0000000000000000000000000000000000000000..53d0f56db21addcd55f0015a0ec3cc87b66d4960 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerDiffuse.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixColumnCorner +import OAI.Analysis.Commutator.MatrixTower + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + +include hfaith in +lemma projection_trace_positive {p : M} (hp : IsStarProjection p) (hpn : p≠0) : + 0<(τ p).re := by + have hn := τ.map_nonneg hp.nonneg + apply lt_of_le_of_ne hn.1 + intro heq + apply hpn + apply hfaith + rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + exact Complex.ext heq.symm hn.2.symm + +include hτ hfaith in +lemma diffuse_of_small (hfac : FactorCorner.IsFactor M) + (hsmall : ∀ ε : ℝ,0<ε → ∃ q : M,IsStarProjection q ∧ q≠0 ∧ (τ q).re<ε) : + DiffuseProjection.HasNoMinimalProjections M := by + intro p hpM hp hpn + let p' : M := ⟨p,hpM⟩ + have hp' : IsStarProjection p' := ⟨Subtype.ext hp.isIdempotentElem.eq,Subtype.ext hp.isSelfAdjoint.star_eq⟩ + have hpn' : p'≠0 := fun h => hpn (congrArg Subtype.val h) + obtain ⟨q,hq,hqn,hqt⟩ := hsmall (τ p').re (projection_trace_positive M τ hfaith hp' hpn') + have hle : τ q≤τ p' := ⟨hqt.le,(τ.map_nonneg hq.nonneg).2.symm.trans (τ.map_nonneg hp'.nonneg).2⟩ + have hq' : IsStarProjection (q : H →L[ℂ] H) := hq.map M.toStarSubalgebra.subtype + obtain ⟨v,hvi⟩ := PartialIsometryOrder.finite_factor_comparison M hfac τ hτ hfaith + q.property hpM hq' hp hle + have htrace : τ ⟨v.final,v.final_mem⟩=τ q := by + rw [←v.trace_initial_final τ hτ] + exact congrArg τ (Subtype.ext hvi) + have hpos : 0<(τ ⟨v.final,v.final_mem⟩).re := by + rw [htrace]; exact projection_trace_positive M τ hfaith hq hqn + refine ⟨v.final,v.final_mem,v.final_projection,?_,?_,v.target_le⟩ + · intro hz + have hz' : (⟨v.final,v.final_mem⟩:M)=0 := Subtype.ext hz + rw [hz',map_zero] at hpos + exact lt_irrefl _ hpos + · intro heq + have heq' : (⟨v.final,v.final_mem⟩:M)=p' := Subtype.ext heq + rw [heq'] at htrace + exact (ne_of_lt hqt) (congrArg Complex.re htrace.symm) + +include hτ hone in +lemma small_of_stages (F : ℕ → Stage M) + (hsize : ∀ N : ℕ,∃ n,N small_of_stages M τ hτ hone F hsize hε) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerGNS.lean b/lean/OAI/Analysis/Commutator/MatrixTowerGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..3907021640436cacfa676866a0a27dccff7686ad --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerGNS.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTowerClosure +import OAI.Analysis.Commutator.NormalGNSClosure +import OAI.Analysis.Commutator.StageGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.NormalGNS + +variable {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def bicommutant (S : StarSubalgebra ℂ (K →L[ℂ] K)) : VonNeumannAlgebra K where + toStarSubalgebra := StarSubalgebra.centralizer ℂ (StarSubalgebra.centralizer ℂ (S : Set (K →L[ℂ] K))) + centralizer_centralizer' := by + have h : ((StarSubalgebra.centralizer ℂ (StarSubalgebra.centralizer ℂ (S : Set (K →L[ℂ] K)))) : + StarSubalgebra ℂ (K →L[ℂ] K)).carrier = + Set.centralizer (Set.centralizer (S : Set (K →L[ℂ] K))) := by + exact (StarSubalgebra.coe_centralizer_centralizer ℂ _).trans (by + rw [StarMemClass.star_coe_eq,Set.union_self]) + change _ = ((StarSubalgebra.centralizer ℂ + (StarSubalgebra.centralizer ℂ (S : Set (K →L[ℂ] K)))) : StarSubalgebra ℂ (K →L[ℂ] K)).carrier + rw [h] + simp only [Set.centralizer_centralizer_centralizer] + +lemma mem_bicommutant (S : StarSubalgebra ℂ (K →L[ℂ] K)) (a : K →L[ℂ] K) : + a∈bicommutant S ↔ a∈Set.centralizer (Set.centralizer (S : Set (K →L[ℂ] K))) := by + change a∈(StarSubalgebra.centralizer ℂ (StarSubalgebra.centralizer ℂ (S : Set (K →L[ℂ] K)))) ↔ _ + rw [←SetLike.mem_coe,StarSubalgebra.coe_centralizer_centralizer,StarMemClass.star_coe_eq,Set.union_self] + +lemma subset_bicommutant (S : StarSubalgebra ℂ (K →L[ℂ] K)) : S≤(bicommutant S).toStarSubalgebra := by + intro a ha + exact (mem_bicommutant S a).mpr (Set.subset_centralizer_centralizer ha) + +end Kadison.NormalGNS + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +variable (τ : generated M F →ₚ[ℂ] ℂ) + +variable (hnormal : NormalGNS.BoundedWOTContinuous (generated M F) τ) + +include hnormal in +theorem generated_gns_dense (a : generated M F) : + τ.gnsStarAlgHom a∈Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra τ (fun n => (F n).I) (stageHom M F) : Set _)) := by + let S := TracialGNS.stageAlgebra τ (fun n => (F n).I) (stageHom M F) + let N := NormalGNS.bicommutant S + let T := (N.toStarSubalgebra.comap τ.gnsStarAlgHom).map (generated M F).toStarSubalgebra.subtype + have hST : stageAlgebra M F≤T := by + apply iSup_le + intro n + rintro x ⟨b,rfl⟩ + refine ⟨stageHom M F n b,?_,rfl⟩ + exact NormalGNS.subset_bicommutant S + ((le_iSup (TracialGNS.operatorStage τ (fun n => (F n).I) (stageHom M F)) n) ⟨b,rfl⟩) + have hSN (b : generated M F) (hb : (b:H →L[ℂ] H)∈stageAlgebra M F) : τ.gnsStarAlgHom b∈N := by + obtain ⟨c,hc,hcb⟩ := hST hb + have he : c=b := Subtype.ext hcb + change τ.gnsStarAlgHom c∈N at hc + simpa only [he] using hc + have hSM : stageAlgebra M F≤(generated M F).toStarSubalgebra := by + intro b hb + exact (mem_generated M F b).mpr (Set.subset_centralizer_centralizer hb) + exact (NormalGNS.mem_bicommutant S _).mp + (NormalGNS.image_bicommutant_general (generated M F) τ hnormal (stageAlgebra M F) + hSM N hSN a ((mem_generated M F a).mp a.property)) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerInclusion.lean b/lean/OAI/Analysis/Commutator/MatrixTowerInclusion.lean new file mode 100644 index 0000000000000000000000000000000000000000..c4f7d7096e9578aad004d77b91ea5514f5c31c73 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerInclusion.lean @@ -0,0 +1,49 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTower + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +variable [Nontrivial M] (hF : Monotone (fun n => (F n).hom.range)) + +lemma stage_injective (n : ℕ) : Function.Injective (F n).hom := + (F n).hom.toAlgHom.toRingHom.injective + +def stageInclusion {n m : ℕ} (h : n ≤ m) : + Matrix (F n).I (F n).I ℂ →⋆ₐ[ℂ] Matrix (F m).I (F m).I ℂ := + (StarAlgEquiv.ofInjective (F m).hom (stage_injective M F m)).symm.toStarAlgHom.comp + ((StarSubalgebra.inclusion (hF h)).comp (F n).hom.rangeRestrict) + +lemma stageInclusion_commutes {n m : ℕ} (h : n ≤ m) (a : Matrix (F n).I (F n).I ℂ) : + (F m).hom (stageInclusion M F hF h a)=(F n).hom a := by + let e := StarAlgEquiv.ofInjective (F m).hom (stage_injective M F m) + let b : (F m).hom.range := ⟨(F n).hom a,hF h ⟨a,rfl⟩⟩ + exact congrArg Subtype.val (e.apply_symm_apply b) + +omit [Nontrivial M] in +lemma unbounded_above_of_sizes (hsize : ∀ n,n+1 ≤ Fintype.card (F n).I) (n q : ℕ) : + ∃ m,n ≤ m ∧ q ≤ Fintype.card (F m).I := by + refine ⟨max n q,le_max_left _ _,?_⟩ + exact (le_max_right n q).trans ((Nat.le_succ _).trans (hsize _)) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTowerIrreducible.lean b/lean/OAI/Analysis/Commutator/MatrixTowerIrreducible.lean new file mode 100644 index 0000000000000000000000000000000000000000..36120d78e02022cf39494f6bbd179f5314d88795 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTowerIrreducible.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTower + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace ComplexStarModule + +namespace Kadison.MatrixTower + +open TracialGNS MatrixExpectation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma exists_selfAdjoint_dense_sequence [TopologicalSpace.SeparableSpace τ.GNS] : + ∃ x : ℕ → M, (∀ j,IsSelfAdjoint (x j)) ∧ + ∀ a : M,IsSelfAdjoint a → ∀ ε : ℝ,0<ε → ∃ j,‖algebraVector τ (a-x j)‖<ε := by + classical + let S : Set τ.GNS := Set.range (fun a : selfAdjoint M => algebraVector τ (a:M)) + have : Nonempty S := ⟨⟨algebraVector τ 0,⟨⟨0,IsSelfAdjoint.zero M⟩,rfl⟩⟩⟩ + obtain ⟨u,hu⟩ := TopologicalSpace.exists_dense_seq S + choose x hx using (fun n => (u n).property) + refine ⟨fun n => (x n:M),fun n => (x n).property,?_⟩ + intro a ha ε hε + obtain ⟨j,hj⟩ := hu.exists_dist_lt ⟨algebraVector τ a,⟨⟨a,ha⟩,rfl⟩⟩ hε + refine ⟨j,?_⟩ + change dist (algebraVector τ a) (u j).val<ε at hj + rwa [←hx j,dist_eq_norm,←map_sub] at hj + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hone : τ 1=1) + +include hτ hone in +lemma centered_approximation (F : Stage M) (a b : M) : + ‖algebraVector τ (expectation F.hom a-τ a • (1:M))‖≤ + 2*‖algebraVector τ (a-b)‖+‖algebraVector τ (expectation F.hom b-τ b • (1:M))‖ := by + have he : expectation F.hom a-τ a • (1:M)= + (expectation F.hom (a-b)-τ (a-b) • (1:M))+ + (expectation F.hom b-τ b • (1:M)) := by + rw [map_sub,map_sub,sub_smul] + abel + have ht : ‖algebraVector τ (τ (a-b) • (1:M))‖≤‖algebraVector τ (a-b)‖ := by + rw [map_smul,norm_smul] + have h1 : ‖algebraVector τ (1:M)‖=1 := vacuum_norm τ hone + rw [h1,mul_one] + exact MatrixApproximation.trace_norm_le_vector τ hone _ + rw [he,map_add] + apply (norm_add_le _ _).trans + apply add_le_add _ le_rfl + rw [map_sub] + exact (norm_sub_le _ _).trans (by linarith [norm_vector_le F.hom τ hτ (a-b)]) + +variable (x : ℕ → M) + (hxden : ∀ a : M,IsSelfAdjoint a → ∀ ε : ℝ,0<ε → ∃ j,‖algebraVector τ (a-x j)‖<ε) + (F : ℕ → Stage M) + (hreq : ∀ j : ℕ,∀ ε : ℝ,0<ε → ∃ n, + ‖algebraVector τ (expectation (F n).hom (x j)-τ (x j) • (1:M))‖<ε) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + +include hτ hone hxden hreq hfaith in +lemma scalar_of_selfAdjoint_commutes (a : M) (ha : IsSelfAdjoint a) + (hc : ∀ n b,(F n).hom b*a=a*(F n).hom b) : a=τ a • (1:M) := by + have hz : algebraVector τ (a-τ a • (1:M))=0 := by + apply norm_eq_zero.mp + apply le_antisymm + · apply le_of_forall_pos_le_add + intro ε hε + obtain ⟨j,hj⟩ := hxden a ha (ε/4) (by positivity) + obtain ⟨n,hn⟩ := hreq j (ε/2) (half_pos hε) + have he := centered_approximation M τ hτ hone (F n) a (x j) + rw [fixes (F n).hom a (hc n)] at he + linarith + · exact norm_nonneg _ + apply sub_eq_zero.mp + apply hfaith + rw [←inner_algebraVector,hz,inner_zero_left] + +include hτ hone hxden hreq hfaith in +theorem scalar_of_commutes (a : M) + (hc : ∀ n b,(F n).hom b*a=a*(F n).hom b) : a=τ a • (1:M) := by + have hcs : ∀ n b,(F n).hom b*star a=star a*(F n).hom b := by + intro n b + have he := congrArg star (hc n (star b)) + simpa only [star_mul,←map_star,star_star] using he.symm + have hr : (ℜ a:M)=τ (ℜ a:M) • (1:M) := by + apply scalar_of_selfAdjoint_commutes M τ hτ hone x hxden F hreq hfaith _ (ℜ a).property + intro n b + simp only [realPart_apply_coe,mul_smul_comm,smul_mul_assoc,mul_add,add_mul,hc,hcs] + have hi : (ℑ a:M)=τ (ℑ a:M) • (1:M) := by + apply scalar_of_selfAdjoint_commutes M τ hτ hone x hxden F hreq hfaith _ (ℑ a).property + intro n b + simp only [imaginaryPart_apply_coe,mul_smul_comm,smul_mul_assoc,mul_sub,sub_mul,hc,hcs] + have ht : τ a=τ (ℜ a:M)+Complex.I*τ (ℑ a:M) := by + conv_lhs => rw [←realPart_add_I_smul_imaginaryPart a] + rw [map_add,map_smul,smul_eq_mul] + calc + a=(ℜ a:M)+Complex.I • (ℑ a:M) := (realPart_add_I_smul_imaginaryPart a).symm + _=τ (ℜ a:M) • (1:M)+Complex.I • (τ (ℑ a:M) • (1:M)) := + congrArg₂ (·+·) hr (congrArg (fun z : M => Complex.I • z) hi) + _=(τ (ℜ a:M)+Complex.I*τ (ℑ a:M)) • (1:M) := by rw [smul_smul,add_smul] + _=τ a • (1:M) := by rw [←ht] + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTrace.lean b/lean/OAI/Analysis/Commutator/MatrixTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..176ece3b3f4770b7e848d28dbbd9b694dbc8c59b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTrace.lean @@ -0,0 +1,69 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace + +namespace Kadison.MatrixTrace + +open Matrix + +variable {I : Type*} [Fintype I] [DecidableEq I] + +variable (φ : Matrix I I ℂ →ₗ[ℂ] ℂ) + +variable (htr : ∀ x y, φ (x * y) = φ (y * x)) (hunit : φ 1 = 1) + +include htr + +lemma off_diagonal (i j : I) (hij : i ≠ j) : φ (single i j 1) = 0 := by + have h := htr (single i i 1) (single i j 1) + have hz : (single i j (1 : ℂ)) * single i i 1 = 0 := + Matrix.single_mul_single_of_ne 1 i j i hij.symm 1 + simpa [hz] using h + +lemma diagonal_eq (i j : I) : φ (single i i 1) = φ (single j j 1) := by + simpa using htr (single i j 1) (single j i 1) + +variable [Nonempty I] + +include hunit + +lemma diagonal (i : I) : φ (single i i 1) = (Fintype.card I : ℂ)⁻¹ := by + have hcard : (Fintype.card I : ℂ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + have h : (Fintype.card I : ℂ) * φ (single i i 1) = 1 := by + calc + _ = ∑ j : I, φ (single j j 1) := by + simp only [← diagonal_eq φ htr i, Finset.sum_const, Finset.card_univ, + nsmul_eq_mul] + _ = φ 1 := by rw [← map_sum, Matrix.sum_single_one] + _ = 1 := hunit + apply (mul_left_cancel₀ hcard) + rw [h, mul_inv_cancel₀ hcard] + +lemma unique (a : Matrix I I ℂ) : φ a = (Fintype.card I : ℂ)⁻¹ * a.trace := by + have hsingle (i j : I) : φ (single i j (a i j)) = + if i = j then (Fintype.card I : ℂ)⁻¹ * a i j else 0 := by + have hs : single i j (a i j) = a i j • (single i j (1 : ℂ)) := by + ext k l + simp [Matrix.single] + rw [hs, map_smul] + by_cases hij : i = j + · subst j + rw [diagonal φ htr hunit, ite_eq_left rfl] + exact mul_comm _ _ + · rw [off_diagonal φ htr i j hij, ite_eq_right hij, smul_zero] + calc + φ a = ∑ i : I, ∑ j : I, φ (single i j (a i j)) := by + nth_rw 1 [Matrix.matrix_eq_sum_single a] + simp only [map_sum] + _ = (Fintype.card I : ℂ)⁻¹ * a.trace := by + simp [hsingle, Matrix.trace, ← Finset.mul_sum] + +end Kadison.MatrixTrace +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixTraceFaithful.lean b/lean/OAI/Analysis/Commutator/MatrixTraceFaithful.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c983bbb64a1d69a72e7e175acc5be63ca076fe2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixTraceFaithful.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.BalancedSymmetry +import OAI.Analysis.Commutator.MatrixVectorTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +namespace Kadison.MatrixGNS + +variable {A ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +variable (τ : A →ₚ[ℂ] ℂ) + +omit [Fintype ι] in +lemma algebraArray_eq_zero_iff + (hfaith : ∀ a : A, τ (star a*a)=0 → a=0) (X : CStarMatrix ι ι A) : + algebraArray τ X=0 ↔ X=0 := by + constructor + · intro h + apply CStarMatrix.ext + intro i j + have hv := congrArg (fun v : ArraySpace (ι:=ι) τ => v i j) h + exact (TracialGNS.coe_preGNS_eq_zero_iff τ hfaith (X i j)).mp hv + · rintro rfl + ext i j + change (τ.toPreGNS 0 : τ.GNS)=0 + exact (TracialGNS.coe_preGNS_eq_zero_iff τ hfaith 0).mpr rfl + +lemma trace_faithful [Nonempty ι] + (hfaith : ∀ a : A, τ (star a*a)=0 → a=0) (X : CStarMatrix ι ι A) + (hz : trace (ι:=ι) τ (star X*X)=0) : X=0 := by + have hv : representation τ X (vacuum (ι:=ι) τ)=0 := by + change VectorFunctional.functional (vacuum (ι:=ι) τ) + (representation τ (star X*X))=0 at hz + rw [map_mul,map_star,VectorFunctional.functional_star_mul] at hz + exact inner_self_eq_zero.mp hz + rw [representation_vacuum] at hv + apply (algebraArray_eq_zero_iff τ hfaith X).mp + exact (smul_eq_zero.mp hv).resolve_left (scale_ne_zero (ι:=ι)) + +omit [Fintype ι] in +lemma balanced_symmetry_trace_zero + (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) (x : A) (hx : ‖x‖≤1) : + trace (ι:=Fin 2) τ (BalancedDilation.symmetry x)=0 := by + rw [trace_apply] + rw [BalancedDilation.symmetry_diagonal_trace τ hτ x hx,mul_zero] + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixUnitaryAlphabet.lean b/lean/OAI/Analysis/Commutator/MatrixUnitaryAlphabet.lean new file mode 100644 index 0000000000000000000000000000000000000000..b71076e7b431c88c433e3fa74a643ed9b3227252 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixUnitaryAlphabet.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixCutEmbedding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder Matrix + +namespace Kadison.MatrixCorners + +attribute [local instance] Classical.propDecidable + +variable {I J : Type*} [Fintype I] [DecidableEq I] [Fintype J] [DecidableEq J] + {G : Type*} [Fintype G] [DecidableEq G] [AddCommGroup G] + +def shiftMatrix (g : G) : Matrix G G ℂ := (Equiv.addLeft g).permMatrix ℂ + +lemma shift_trace (g : G) : (shiftMatrix g).trace=if g=0 then (Fintype.card G:ℂ) else 0 := by + rw [shiftMatrix,Matrix.trace_permutation] + by_cases hg : g=0 + · subst g + simp + · have he : Function.fixedPoints (Equiv.addLeft g)=∅ := by + ext x + simp [Function.fixedPoints,Function.IsFixedPt,hg] + simp only [he,Set.ncard_empty,Nat.cast_zero,ite_eq_right hg] + +lemma shift_star_mul (g h : G) : star (shiftMatrix g)*shiftMatrix h=shiftMatrix (h-g) := by + change (shiftMatrix g).conjTranspose*shiftMatrix h=_ + simp only [shiftMatrix,Matrix.conjTranspose_permMatrix,←Matrix.permMatrix_mul] + congr 1 + ext x + simp [sub_eq_add_neg] + +lemma shift_mul_star (g h : G) : shiftMatrix g*star (shiftMatrix h)=shiftMatrix (g-h) := by + change shiftMatrix g*(shiftMatrix h).conjTranspose=_ + simp only [shiftMatrix,Matrix.conjTranspose_permMatrix,←Matrix.permMatrix_mul] + congr 1 + ext x + simp [sub_eq_add_neg,add_comm,add_assoc] + +omit [Fintype G] in +lemma shift_zero : shiftMatrix (0:G)=1 := by + change (Equiv.addLeft (0:G)).permMatrix ℂ=1 + have he : Equiv.addLeft (0:G)=Equiv.refl G := by ext x; simp + rw [he,Matrix.permMatrix_refl] + +lemma shift_unitary (g : G) : shiftMatrix g ∈ unitary (Matrix G G ℂ) := by + apply Unitary.mem_iff.mpr + constructor + · rw [shift_star_mul,sub_self,shift_zero] + · rw [shift_mul_star,sub_self,shift_zero] + +lemma shift_gram (g h : G) : (star (shiftMatrix g)*shiftMatrix h).trace= + if g=h then (Fintype.card G:ℂ) else 0 := by + rw [shift_star_mul,shift_trace] + simp [sub_eq_zero,eq_comm] + +def projectionAlphabet (p : Matrix I I ℂ) (hp : IsStarProjection p) + (e : G ≃ projectionIndices p hp) (g : G) : Matrix I I ℂ := + projectionEmbedding p hp (reindexStarAlgEquiv e (shiftMatrix g)) + +lemma projectionAlphabet_trace (p : Matrix I I ℂ) (hp : IsStarProjection p) + (e : G ≃ projectionIndices p hp) (g : G) : + (projectionAlphabet p hp e g).trace=if g=0 then (Fintype.card G:ℂ) else 0 := by + rw [projectionAlphabet,projectionEmbedding_trace] + change (Matrix.reindex e e (shiftMatrix g)).trace=_ + rw [trace_reindex,shift_trace] + +lemma projectionAlphabet_star_mul (p : Matrix I I ℂ) (hp : IsStarProjection p) + (e : G ≃ projectionIndices p hp) (g : G) : + star (projectionAlphabet p hp e g)*projectionAlphabet p hp e g=p := by + unfold projectionAlphabet + rw [←map_star,←map_mul,←map_star,←map_mul,shift_star_mul,sub_self,shift_zero, + map_one,projectionEmbedding_one] + +lemma projectionAlphabet_support (p : Matrix I I ℂ) (hp : IsStarProjection p) + (e : G ≃ projectionIndices p hp) (g : G) : projectionAlphabet p hp e g*p= + projectionAlphabet p hp e g := by + change projectionEmbedding p hp _ * p=projectionEmbedding p hp _ + conv_lhs => rhs; rw [←projectionEmbedding_one p hp] + rw [←map_mul,mul_one] + +lemma projectionAlphabet_gram (p : Matrix I I ℂ) (hp : IsStarProjection p) + (e : G ≃ projectionIndices p hp) (g h : G) : + (star (projectionAlphabet p hp e g)*projectionAlphabet p hp e h).trace= + if g=h then (Fintype.card G:ℂ) else 0 := by + unfold projectionAlphabet + rw [←map_star,←map_mul,projectionEmbedding_trace,←map_star,←map_mul] + change (Matrix.reindex e e (star (shiftMatrix g)*shiftMatrix h)).trace=_ + rw [trace_reindex,shift_gram] + +end Kadison.MatrixCorners + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixUnits.lean b/lean/OAI/Analysis/Commutator/MatrixUnits.lean new file mode 100644 index 0000000000000000000000000000000000000000..03c582d10de4b98673686eec30918957fdf38e29 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixUnits.lean @@ -0,0 +1,98 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.MatrixUnits + +variable {ι A : Type*} [Fintype ι] [DecidableEq ι] [Ring A] [StarRing A] + [Algebra ℂ A] [StarModule ℂ A] + +def representation (e : ι → ι → A) + (hmul : ∀ i j k l, e i j * e k l = if j=k then e i l else 0) + (hstar : ∀ i j, star (e i j)=e j i) + (hone : ∑ i,e i i=1) : Matrix ι ι ℂ →⋆ₐ[ℂ] A where + toFun x := ∑ i,∑ j,x i j • e i j + map_zero' := by simp + map_one' := by simpa [Matrix.one_apply] using hone + map_add' x y := by simp [add_smul,Finset.sum_add_distrib] + map_mul' x y := by + simp only [Matrix.mul_apply,Finset.sum_smul,Finset.sum_mul,Finset.mul_sum, + smul_mul_smul_comm,hmul,smul_ite,smul_zero] + simp only [Finset.sum_ite_eq',Finset.mem_univ,ite_true] + conv_rhs => + rw [Finset.sum_comm] + arg 2 + ext j + rw [Finset.sum_comm] + exact Finset.sum_comm + commutes' c := by + change (∑ i,∑ j,(algebraMap ℂ (Matrix ι ι ℂ) c) i j • e i j)=_ + simp [Matrix.algebraMap_matrix_apply,←Finset.smul_sum,hone,Algebra.algebraMap_eq_smul_one] + map_star' x := by + simp only [Matrix.star_apply,star_sum,star_smul,hstar] + exact Finset.sum_comm + +@[simp] lemma representation_apply (e : ι → ι → A) (hmul) (hstar) (hone) + (x : Matrix ι ι ℂ) : representation e hmul hstar hone x=∑ i,∑ j,x i j • e i j := rfl + +omit [Fintype ι] [Algebra ℂ A] [StarModule ℂ A] in +lemma partialIsometry_cross (q : A) (p v : ι → A) + (hsource : ∀ i, star (v i)*v i=q) + (htarget : ∀ i, p i*v i=v i) + (hself : ∀ i, star (p i)=p i) + (horth : ∀ i j, i≠j → p i*p j=0) (i j : ι) : + star (v i)*v j=if i=j then q else 0 := by + split_ifs with h + · subst j + exact hsource i + · have hleft : star (v i)*p i=star (v i) := by + simpa only [star_mul,hself] using congrArg star (htarget i) + calc + _=(star (v i)*p i)*(p j*v j) := by rw [hleft,htarget] + _=star (v i)*(p i*p j)*v j := by noncomm_ring + _=0 := by rw [horth i j h,mul_zero,zero_mul] + +def ofPartialIsometries (q : A) (p v : ι → A) + (hsource : ∀ i, star (v i)*v i=q) + (hfinal : ∀ i, v i*star (v i)=p i) + (hfix : ∀ i, v i*q=v i) + (htarget : ∀ i, p i*v i=v i) + (hself : ∀ i, star (p i)=p i) + (horth : ∀ i j, i≠j → p i*p j=0) + (hone : ∑ i,p i=1) : Matrix ι ι ℂ →⋆ₐ[ℂ] A := + representation (fun i j => v i*star (v j)) (by + intro i j k l + calc + _=v i*(star (v j)*v k)*star (v l) := by noncomm_ring + _=if j=k then v i*star (v l) else 0 := by + rw [partialIsometry_cross q p v hsource htarget hself horth] + split_ifs + · rw [hfix] + · rw [mul_zero,zero_mul]) + (by intro i j; simp only [star_mul,star_star]) + (by simpa only [hfinal] using hone) + +@[simp] lemma ofPartialIsometries_single (q : A) (p v : ι → A) + (hsource) (hfinal) (hfix) (htarget) (hself) (horth) (hone) + (i j : ι) : + ofPartialIsometries q p v hsource hfinal hfix htarget hself horth hone + (Matrix.single i j (1:ℂ))=v i*star (v j) := by + classical + simp [ofPartialIsometries,representation,Matrix.single_apply,ite_and] + +end Kadison.MatrixUnits + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixVectorTrace.lean b/lean/OAI/Analysis/Commutator/MatrixVectorTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..8ab1a53654c91b104333b975d91393159221e11e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixVectorTrace.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.Commutator.OperatorAmplification +import OAI.Analysis.Commutator.TracialConjugation +import OAI.Analysis.Commutator.TracialSequenceTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder + +open ContinuousLinearMap + +namespace Kadison.MatrixGNS + +variable {A ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [Fintype ι] + +local instance matrixVectorTraceDecidableEq : DecidableEq ι := Classical.decEq ι + +variable (τ : A →ₚ[ℂ] ℂ) + +abbrev ArraySpace := PiLp 2 (fun _ : ι => PiLp 2 (fun _ : ι => τ.GNS)) + +def representation : CStarMatrix ι ι A →⋆ₐ[ℂ] (ArraySpace (ι:=ι) τ →L[ℂ] ArraySpace (ι:=ι) τ) := + CyclicColumns.matrixRepresentation ((OperatorAmplification.diagonal ι).comp τ.gnsStarAlgHom) + +@[simp] lemma representation_apply (X : CStarMatrix ι ι A) (v : ArraySpace (ι:=ι) τ) (i j : ι) : + representation τ X v i j=∑ k, τ.gnsStarAlgHom (X i k) (v k j) := by + simp [representation,CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply] + +def algebraArray (X : CStarMatrix ι ι A) : ArraySpace (ι:=ι) τ := + WithLp.toLp 2 (fun i => WithLp.toLp 2 (fun j => TracialGNS.algebraVector τ (X i j))) + +omit [Fintype ι] in +@[simp] lemma algebraArray_apply (X : CStarMatrix ι ι A) (i j : ι) : + algebraArray τ X i j=TracialGNS.algebraVector τ (X i j) := rfl + +lemma representation_oneArray (X : CStarMatrix ι ι A) : + representation τ X (algebraArray τ 1)=algebraArray τ X := by + ext i j + simp only [representation_apply,algebraArray_apply,CStarMatrix.one_apply] + classical + simp [apply_ite,TracialGNS.algebraVector,map_zero] + +def scale (ι : Type*) [Fintype ι] : ℂ := ((Real.sqrt (Fintype.card ι : ℝ))⁻¹ : ℝ) + +lemma scale_ne_zero [Nonempty ι] : scale ι≠0 := by + simp only [scale,ne_eq,Complex.ofReal_eq_zero,inv_eq_zero] + exact Real.sqrt_ne_zero'.mpr (by exact_mod_cast (Fintype.card_pos (α:=ι))) + +def vacuum : ArraySpace (ι:=ι) τ := scale ι • algebraArray τ 1 + +lemma representation_vacuum (X : CStarMatrix ι ι A) : + representation τ X (vacuum (ι:=ι) τ)=scale ι • algebraArray τ X := by + rw [vacuum,map_smul,representation_oneArray] + +def trace : CStarMatrix ι ι A →ₚ[ℂ] ℂ where + toLinearMap := (VectorFunctional.functional (vacuum (ι:=ι) τ)).toLinearMap.comp + (representation τ).toLinearMap + monotone' := by + have hmono : Monotone (representation (ι:=ι) τ) := by + intro first second hle + exact (NonUnitalStarRingHom.ofClass (representation τ)).map_le_map_of_map_star hle + exact (VectorFunctional.functional (vacuum (ι:=ι) τ)).monotone.comp hmono + +lemma trace_vector (X : CStarMatrix ι ι A) : + trace (ι:=ι) τ X=inner ℂ (vacuum τ) (representation τ X (vacuum τ)) := rfl + +lemma diagonal_inner (X : CStarMatrix ι ι A) : + inner ℂ (algebraArray τ (1:CStarMatrix ι ι A)) (algebraArray τ X)=∑ i,τ (X i i) := by + simp only [PiLp.inner_apply,algebraArray_apply,TracialGNS.inner_algebraVector,CStarMatrix.one_apply] + simp [apply_ite] + +lemma trace_apply (X : CStarMatrix ι ι A) : + trace (ι:=ι) τ X=(Fintype.card ι : ℂ)⁻¹ * ∑ i,τ (X i i) := by + rw [trace_vector,representation_vacuum,vacuum,inner_smul_left,inner_smul_right,diagonal_inner] + have hs : starRingEnd ℂ (scale ι)*scale ι=(Fintype.card ι : ℂ)⁻¹ := by + change star (((Real.sqrt (Fintype.card ι : ℝ))⁻¹ : ℝ) : ℂ) * + (((Real.sqrt (Fintype.card ι : ℝ))⁻¹ : ℝ) : ℂ)=_ + rw [Complex.star_def,Complex.conj_ofReal,←Complex.ofReal_mul,←mul_inv_rev, + Real.mul_self_sqrt (Nat.cast_nonneg _),Complex.ofReal_inv,Complex.ofReal_natCast] + rw [←mul_assoc,hs] + +lemma trace_one [Nonempty ι] (h1 : τ 1=1) : trace (ι:=ι) τ 1=1 := by + rw [trace_apply] + simp only [CStarMatrix.one_apply,ite_true,h1,Finset.sum_const,Finset.card_univ,nsmul_eq_mul,mul_one] + exact inv_mul_cancel₀ (by exact_mod_cast Fintype.card_ne_zero) + +lemma trace_mul (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (X Y : CStarMatrix ι ι A) : + trace (ι:=ι) τ (X*Y)=trace (ι:=ι) τ (Y*X) := by + simp only [trace_apply,CStarMatrix.mul_apply,map_sum] + congr 1 + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro i _ + apply Finset.sum_congr rfl + intro j _ + exact hτ _ _ + +end Kadison.MatrixGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MatrixVonNeumann.lean b/lean/OAI/Analysis/Commutator/MatrixVonNeumann.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ba3c2b902244b843fd2fb1fa6d7cf680566e4dc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MatrixVonNeumann.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.DiagonalVonNeumann +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] (i₀ : ι) + +def matrixVonNeumann (M : VonNeumannAlgebra H) : VonNeumannAlgebra (SumSpace (H:=H) ι) := + (diagonalVonNeumann ι i₀ M.commutant).commutant + +lemma mem_matrixVonNeumann (M : VonNeumannAlgebra H) + (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) : + T∈matrixVonNeumann ι i₀ M ↔ ∀ i j,entry ι T i j∈M := by + change T∈(diagonalVonNeumann ι i₀ M.commutant).commutant ↔ _ + rw [VonNeumannAlgebra.mem_commutant_iff] + constructor + · intro h i j + rw [←SetLike.mem_coe,←M.centralizer_centralizer] + intro b hb + exact entry_commutes ι T b (h (diagonal (H:=H) ι b) ⟨b,VonNeumannAlgebra.mem_commutant_iff.mpr hb,rfl⟩) i j + · intro h + rintro _ ⟨b,hb,rfl⟩ + apply commutes_of_entries ι T b + intro i j + exact ((VonNeumannAlgebra.mem_commutant_iff.mp hb) _ (h i j)).symm + +lemma matrixUnit_mem (M : VonNeumannAlgebra H) (i j : ι) : + matrixUnit (H:=H) ι i j∈matrixVonNeumann ι i₀ M := by + apply VonNeumannAlgebra.mem_commutant_iff.mpr + rintro _ ⟨b,_,rfl⟩ + exact (matrixUnit_commutes ι i j b).symm + +lemma diagonal_mem_matrixVonNeumann (M : VonNeumannAlgebra H) {a : H →L[ℂ] H} (ha : a∈M) : + diagonal (H:=H) ι a∈matrixVonNeumann ι i₀ M := by + apply VonNeumannAlgebra.mem_commutant_iff.mpr + rintro _ ⟨b,hb,rfl⟩ + exact (map_mul (diagonal (H:=H) ι) b a).symm.trans + ((congrArg (diagonal (H:=H) ι) ((VonNeumannAlgebra.mem_commutant_iff.mp hb) a ha).symm).trans (map_mul (diagonal (H:=H) ι) a b)) + +lemma matrix_representation_mem (M : VonNeumannAlgebra H) (X : CStarMatrix ι ι M) : + CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype X∈matrixVonNeumann ι i₀ M := by + rw [mem_matrixVonNeumann] + intro i j + have he : entry ι (CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype X) i j= + (X i j:H →L[ℂ] H) := by + ext x + simp only [entry_apply,CyclicColumns.matrixRepresentation,CyclicColumns.matrixAction_apply, + StarAlgHom.coe_mk] + simp [apply_ite] + rfl + rw [he] + exact (X i j).property + +lemma matrixVonNeumann_is_range (M : VonNeumannAlgebra H) + (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (hT : T∈matrixVonNeumann ι i₀ M) : + ∃ X : CStarMatrix ι ι M,CyclicColumns.matrixRepresentation (A:=M) (H:=H) M.toStarSubalgebra.subtype X=T := by + have h := (mem_matrixVonNeumann ι i₀ M T).mp hT + let X : CStarMatrix ι ι M := CStarMatrix.ofMatrix (fun i j => ⟨entry ι T i j,h i j⟩) + exact ⟨X,reconstruct ι T⟩ + +lemma factor_matrixVonNeumann (M : VonNeumannAlgebra H) (hM : FactorCorner.IsFactor M) : + FactorCorner.IsFactor (matrixVonNeumann ι i₀ M) := by + intro Z hZ hc + have he : Z=diagonal (H:=H) ι (entry ι Z i₀ i₀) := + diagonal_of_matrixUnits ι i₀ Z (fun i j => hc _ (matrixUnit_mem ι i₀ M i j)) + have ha := (mem_matrixVonNeumann ι i₀ M Z).mp hZ i₀ i₀ + have hca : entry ι Z i₀ i₀∈Set.centralizer (M:Set (H →L[ℂ] H)) := by + intro a ha + exact entry_commutes ι Z a (hc _ (diagonal_mem_matrixVonNeumann ι i₀ M ha)) i₀ i₀ + obtain ⟨c,hc⟩ := hM _ ha hca + refine ⟨c,?_⟩ + rw [he,hc,map_smul,map_one] + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MaximalAbelianTransport.lean b/lean/OAI/Analysis/Commutator/MaximalAbelianTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..9891de3c6f281c7c0627fcca3ff00e7e7d1aa88f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MaximalAbelianTransport.lean @@ -0,0 +1,35 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {A H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +lemma range_of_maximal_conjugate (U : H ≃ₗᵢ[ℂ] G) (σ : A → (H →L[ℂ] H)) (ρ : A → (G →L[ℂ] G)) + (hρ : Set.centralizer (Set.range ρ)=Set.range ρ) + (hU : ∀ a,U.conjStarAlgEquiv (σ a)=ρ a) + (T : H →L[ℂ] H) (hT : ∀ a,Commute (σ a) T) : ∃ a,σ a=T := by + have ht : U.conjStarAlgEquiv T∈Set.centralizer (Set.range ρ) := by + rintro _ ⟨a,rfl⟩ + rw [←hU,←map_mul,←map_mul] + exact congrArg U.conjStarAlgEquiv (hT a).eq + rw [hρ] at ht + obtain ⟨a,ha⟩ := ht + exact ⟨a,U.conjStarAlgEquiv.injective ((hU a).trans ha)⟩ + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MetricSimilarity.lean b/lean/OAI/Analysis/Commutator/MetricSimilarity.lean new file mode 100644 index 0000000000000000000000000000000000000000..0c10eb1a216961cda8f23cc6e3535dd490d0f5e9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MetricSimilarity.lean @@ -0,0 +1,39 @@ +import Mathlib + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped CStarAlgebra + +namespace Kadison.CbFactor + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +lemma similarity_of_metric (π : A →ₐ[ℂ] B) (Q : B) (hQ : IsStrictlyPositive Q) + (hcov : ∀ a : A,π a*Q=Q*star (π (star a))) : + ∃ S : Bˣ,∀ a : A, + (S : B)*π (star a)*(↑(S⁻¹) : B)=star ((S : B)*π a*(↑(S⁻¹) : B)) := by + let u : Bˣ := hQ.sqrt.isUnit.unit + have hu : (u : B)=CFC.sqrt Q := hQ.sqrt.isUnit.unit_spec + have hsa : IsSelfAdjoint (u : B) := hu ▸ hQ.sqrt.isSelfAdjoint + have hsaInv : IsSelfAdjoint (↑(u⁻¹) : B) := by + simpa only [Ring.inverse_unit] using hsa.ringInverse + have hsq : (u : B)*(u : B)=Q := by rw [hu,CFC.sqrt_mul_sqrt_self Q hQ.nonneg] + refine ⟨u⁻¹,?_⟩ + intro a + simp only [inv_inv,star_mul,hsa.star_eq,hsaInv.star_eq] + apply (u.mul_right_inj).mp + apply (u.mul_left_inj).mp + have h := hcov (star a) + simp only [star_star,←hsq] at h + simpa only [mul_assoc,Units.mul_inv_cancel_left,Units.inv_mul_cancel_right, + Units.inv_mul,Units.mul_inv,one_mul,mul_one] using h + +end Kadison.CbFactor +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MinimalCorner.lean b/lean/OAI/Analysis/Commutator/MinimalCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..894788d8b728170d20122baa085d1a0daeb2f610 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MinimalCorner.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Commutator.MinimalProjection + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.AtomicFactor + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma corner_scalar (M : VonNeumannAlgebra H) {p : H →L[ℂ] H} + (hp : IsMinimalProjection M p) {a : H →L[ℂ] H} (haM : a∈M) + (hpa : p*a=a) (hap : a*p=a) : ∃ z : ℂ,a=z • p := by + have hps : p*star a=star a := by + simpa only [star_mul,hp.2.1.isSelfAdjoint.star_eq] using congrArg star hap + have hsp : star a*p=star a := by + simpa only [star_mul,hp.2.1.isSelfAdjoint.star_eq] using congrArg star hpa + let ar : H →L[ℂ] H := realPart a + let ai : H →L[ℂ] H := imaginaryPart a + have hrM : ar∈M := by + rw [show ar=(2:ℝ)⁻¹ • (a+star a) from realPart_apply_coe a] + exact (M.toSubalgebra.restrictScalars ℝ).smul_mem (M.add_mem haM (M.star_mem' haM)) _ + have hiM : ai∈M := by + rw [show ai= -Complex.I • (2:ℝ)⁻¹ • (a-star a) from imaginaryPart_apply_coe a] + exact M.smul_mem ((M.toSubalgebra.restrictScalars ℝ).smul_mem (M.sub_mem haM (M.star_mem' haM)) _) _ + have hpr : p*ar=ar := by + simp only [ar,realPart_apply_coe,mul_smul_comm,mul_add,hpa,hps] + have hrp : ar*p=ar := by + simp only [ar,realPart_apply_coe,smul_mul_assoc,add_mul,hap,hsp] + have hpi : p*ai=ai := by + simp only [ai,imaginaryPart_apply_coe,mul_smul_comm,mul_sub,hpa,hps] + have hip : ai*p=ai := by + simp only [ai,imaginaryPart_apply_coe,smul_mul_assoc,sub_mul,hap,hsp] + obtain ⟨r,hr⟩ := selfadjoint_corner_scalar M hp hrM (realPart a).property hpr hrp + obtain ⟨s,hs⟩ := selfadjoint_corner_scalar M hp hiM (imaginaryPart a).property hpi hip + refine ⟨r+Complex.I*s,?_⟩ + calc + a=ar+Complex.I • ai := (realPart_add_I_smul_imaginaryPart a).symm + _=(r+Complex.I*s) • p := by rw [hr,hs,smul_smul,add_smul] + +end Kadison.AtomicFactor + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MinimalNormCompact.lean b/lean/OAI/Analysis/Commutator/MinimalNormCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..70c9ebb3d01c182f5a4a26e4af3b35e87a5f471c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MinimalNormCompact.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.Commutator.BaireSmallPiece +import OAI.Analysis.Commutator.MinimalOrbit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Set TopologicalSpace + +namespace Kadison.CompactInvariant + +variable {G X E : Type*} [Group G] [TopologicalSpace X] [T2Space X] + [MulAction G X] [ContinuousConstSMul G X] [MetricSpace E] [CompleteSpace E] + +theorem minimal_norm_compact (j : X ≃ E) (hj : Continuous j.symm) + (hball : ∀ y : E,∀ r : ℝ,IsClosed {x : X | dist (j x) y≤r}) + (hiso : ∀ g : G,∀ x y : X,dist (j (g • x)) (j (g • y))=dist (j x) (j y)) + {C K : Set X} (hcomp : IsCompact K) + (hK : Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ Invariant (G:=G) S) K) + (hsep : IsSeparable (j '' K)) : IsCompact (j '' K) := by + classical + have hclosed : IsClosed (j '' K) := by + have he : j '' K=j.symm ⁻¹' K := by + ext y + simp only [mem_image,mem_preimage] + constructor + · rintro ⟨x,hx,rfl⟩; simpa only [j.symm_apply_apply] using hx + · intro hy; exact ⟨j.symm y,hy,j.apply_symm_apply y⟩ + rw [he] + exact hK.prop.2.2.1.preimage hj + apply isCompact_iff_totallyBounded_isComplete.mpr + refine ⟨?_,hclosed.isComplete⟩ + apply Metric.totallyBounded_iff.mpr + intro ε hε + obtain ⟨U,hU,hUn,hd⟩ := BaireSmallPiece.exists_open_piece j hcomp hK.prop.2.1 hsep hball ε hε + obtain ⟨u,huK,huU⟩ := hUn + obtain ⟨t,ht⟩ := minimal_finite_open_cover hcomp hK hU ⟨u,huK,huU⟩ + let T : Set E := (fun g : G => j (g⁻¹ • u)) '' (t : Set G) + refine ⟨T,t.finite_toSet.image _,?_⟩ + rintro y ⟨x,hx,rfl⟩ + obtain ⟨g,hg,hgx⟩ := mem_iUnion₂.mp (ht hx) + refine mem_iUnion₂.mpr ⟨j (g⁻¹ • u),⟨g,hg,rfl⟩,?_⟩ + change dist (j x) (j (g⁻¹ • u))<ε + rw [←hiso g x (g⁻¹ • u)] + simp only [smul_inv_smul] + exact hd (g • x) ⟨hK.prop.2.2.2 g x hx,hgx⟩ u ⟨huK,huU⟩ + +end Kadison.CompactInvariant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MinimalOrbit.lean b/lean/OAI/Analysis/Commutator/MinimalOrbit.lean new file mode 100644 index 0000000000000000000000000000000000000000..4489fd159550542bcf4bf8848790b652ef1f317d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MinimalOrbit.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.CompactInvariant + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Set + +namespace Kadison.CompactInvariant + +variable {G X : Type*} [Group G] [TopologicalSpace X] [T2Space X] + [MulAction G X] [ContinuousConstSMul G X] + +omit [T2Space X] in +lemma invariant_closure {S : Set X} (hS : Invariant (G:=G) S) : + Invariant (G:=G) (closure S) := by + intro g x hx + apply closure_mono (show (fun y : X => g • y) '' S⊆S from by + rintro _ ⟨y,hy,rfl⟩; exact hS g y hy) + exact mem_closure_image (continuous_const_smul g).continuousAt hx + +omit [TopologicalSpace X] [T2Space X] [ContinuousConstSMul G X] in +lemma invariant_orbit (x : X) : Invariant (G:=G) (MulAction.orbit G x) := by + intro g y hy + obtain ⟨h,rfl⟩ := hy + exact ⟨g*h,mul_smul g h x⟩ + +omit [T2Space X] in +lemma minimal_orbit_closure {C K : Set X} + (hK : Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ Invariant (G:=G) S) K) + {x : X} (hx : x∈K) : closure (MulAction.orbit G x)=K := by + have ho : MulAction.orbit G x⊆K := by + rintro y ⟨g,rfl⟩ + exact hK.prop.2.2.2 g x hx + have hs : closure (MulAction.orbit G x)⊆K := closure_minimal ho hK.prop.2.2.1 + apply hs.antisymm + apply hK.le_of_le _ hs + exact ⟨hs.trans hK.prop.1,⟨x,subset_closure ⟨1,one_smul G x⟩⟩,isClosed_closure, + invariant_closure (invariant_orbit x)⟩ + +omit [T2Space X] in +lemma minimal_finite_open_cover {C K : Set X} (hcomp : IsCompact K) + (hK : Minimal (fun S => S⊆C ∧ S.Nonempty ∧ IsClosed S ∧ Invariant (G:=G) S) K) + {U : Set X} (hU : IsOpen U) (hne : (K∩U).Nonempty) : + ∃ t : Finset G,K⊆⋃ g∈t,(fun x : X => g • x) ⁻¹' U := by + apply hcomp.elim_finite_subcover (fun g : G => (fun x : X => g • x) ⁻¹' U) + (fun g => hU.preimage (continuous_const_smul g)) + intro x hx + obtain ⟨y,hyK,hyU⟩ := hne + have hycl : y∈closure (MulAction.orbit G x) := by + rw [minimal_orbit_closure hK hx] + exact hyK + obtain ⟨z,hzU,hzorbit⟩ := mem_closure_iff.mp hycl U hU hyU + obtain ⟨g,rfl⟩ := hzorbit + exact mem_iUnion.mpr ⟨g,hzU⟩ + +end Kadison.CompactInvariant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MinimalProjection.lean b/lean/OAI/Analysis/Commutator/MinimalProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..194dfaa298925c2514cf1ab17a7d708d040ba924 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MinimalProjection.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.ProjectionCommutant + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def vonNeumannCentralizer (s : Set (H →L[ℂ] H)) : VonNeumannAlgebra H where + toStarSubalgebra := StarSubalgebra.centralizer ℂ s + centralizer_centralizer' := by + change Set.centralizer (Set.centralizer (↑(StarSubalgebra.centralizer ℂ s) : Set (H →L[ℂ] H))) = (↑(StarSubalgebra.centralizer ℂ s) : Set (H →L[ℂ] H)) + rw [StarSubalgebra.coe_centralizer,Set.centralizer_centralizer_centralizer] + +namespace AtomicFactor + +def IsMinimalProjection (M : VonNeumannAlgebra H) (p : H →L[ℂ] H) : Prop := + p∈M ∧ IsStarProjection p ∧ p≠0 ∧ + ∀ q∈M,IsStarProjection q → q≤p → q=0 ∨ q=p + +lemma exists_minimal_of_not_diffuse (M : VonNeumannAlgebra H) + (h : ¬DiffuseProjection.HasNoMinimalProjections M) : + ∃ p,IsMinimalProjection M p := by + simp only [DiffuseProjection.HasNoMinimalProjections,not_forall] at h + obtain ⟨p,hpM,hp,hpn,h⟩ := h + refine ⟨p,hpM,hp,hpn,?_⟩ + intro q hqM hq hqp + by_cases hq0 : q=0 + · exact Or.inl hq0 + · right + by_contra hqne + exact h ⟨q,hqM,hq,hq0,hqne,hqp⟩ + +lemma selfadjoint_corner_scalar (M : VonNeumannAlgebra H) {p : H →L[ℂ] H} + (hp : IsMinimalProjection M p) {a : H →L[ℂ] H} (haM : a∈M) + (ha : IsSelfAdjoint a) (hpa : p*a=a) (hap : a*p=a) : + ∃ z : ℂ,a=z • p := by + let N := vonNeumannIntersection M (vonNeumannCentralizer {p}) + have haN : a∈N := by + refine ⟨haM,?_⟩ + change a∈((StarSubalgebra.centralizer ℂ {p} : StarSubalgebra ℂ (H →L[ℂ] H)) : Set _) + rw [StarSubalgebra.coe_centralizer] + intro q hq + rcases hq with hq|hq + · have he : q=p := Set.mem_singleton_iff.mp hq + subst q + exact hpa.trans hap.symm + · have he : q=star p := by simpa only [Set.star_singleton,Set.mem_singleton_iff] using hq + rw [he,hp.2.1.isSelfAdjoint.star_eq] + exact hpa.trans hap.symm + let K : Submodule ℂ (H →L[ℂ] H) := Submodule.span ℂ {p} + have hc : IsClosed (K : Set (H →L[ℂ] H)) := K.closed_of_finiteDimensional + have haK : a∈K := by + apply hc.closure_subset + rw [Metric.mem_closure_iff] + intro ε hε + obtain ⟨n,q,c,hq,_,he⟩ := Polar.exists_selfadjoint_spectral_sum N haN ha hε + have hpq (i : Fin n) : p*q i=q i*p := by + have hh := (hq i).1 + change q i∈M ∧ q i∈vonNeumannCentralizer {p} at hh + have hh' := hh.2 + change q i∈((StarSubalgebra.centralizer ℂ {p} : StarSubalgebra ℂ (H →L[ℂ] H)) : Set _) at hh' + rw [StarSubalgebra.coe_centralizer] at hh' + exact hh' p (Or.inl (Set.mem_singleton p)) + have hmem (i : Fin n) : p*q i∈K := by + have hproj : IsStarProjection (p*q i) := hp.2.1.mul (hq i).2 (hpq i) + have hle : p*q i≤p := by + apply (hproj.le_iff_mul_eq_right hp.2.1).mpr + rw [←mul_assoc,hp.2.1.isIdempotentElem.eq] + rcases hp.2.2.2 (p*q i) (M.mul_mem hp.1 (hq i).1.1) hproj hle with hz|hz + · rw [hz]; exact K.zero_mem + · rw [hz]; exact Submodule.subset_span (Set.mem_singleton p) + refine ⟨p*(∑ i,c i • q i),?_,?_⟩ + · rw [Finset.mul_sum] + apply K.sum_mem + intro i _ + rw [mul_smul_comm] + exact K.smul_mem (c i : ℂ) (hmem i) + · rw [dist_eq_norm,←hpa,←mul_sub] + have hnorm : ‖p‖≤1 := hp.2.1.norm_le + exact (norm_mul_le _ _).trans_lt ((mul_le_mul_of_nonneg_right hnorm (norm_nonneg _)).trans_lt + (by simpa only [one_mul] using he)) + obtain ⟨z,hz⟩ := Submodule.mem_span_singleton.mp haK + exact ⟨z,hz.symm⟩ + +end AtomicFactor + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ModuleZeroExtension.lean b/lean/OAI/Analysis/Commutator/ModuleZeroExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..9bdd127db86033d750f177e1e8fb79af2f38a562 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ModuleZeroExtension.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.ReducingRepresentation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.ReducingRepresentation + +variable {A H F : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ρ : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + +variable (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → σ a x∈K) + +lemma project_intertwines (a : A) (x : H) : + K.orthogonalProjectionOnto (σ a x)=restrict σ K hinv a (K.orthogonalProjectionOnto x) := by + apply Subtype.ext + have hm : K.starProjection*σ a=σ a*K.starProjection := + projection_commutes_of_invariant K (σ a) (hinv a) + (by simpa only [←map_star] using hinv (star a)) + exact congrArg (fun T : H →L[ℂ] H => T x) hm + +def extendZero (T : K →L[ℂ] F) : H →L[ℂ] F := T.comp K.orthogonalProjectionOnto + +omit [CompleteSpace H] [CompleteSpace F] in +@[simp] lemma extendZero_subtype (T : K →L[ℂ] F) (x : K) : + extendZero (K := K) T (x:H)=T x := by simp [extendZero] + +include hinv in +lemma extendZero_intertwines (T : K →L[ℂ] F) + (hT : ∀ a : A, T.comp (restrict σ K hinv a)=(ρ a).comp T) (a : A) : + (extendZero (K := K) T).comp (σ a)=(ρ a).comp (extendZero (K := K) T) := by + ext x + change T (K.orthogonalProjectionOnto (σ a x))=ρ a (T (K.orthogonalProjectionOnto x)) + rw [project_intertwines σ K hinv] + exact congrArg (fun L : K →L[ℂ] F => L (K.orthogonalProjectionOnto x)) (hT a) + +omit [CompleteSpace H] [CompleteSpace F] in +lemma norm_sub_extendZero_apply_le (G : H →L[ℂ] F) (T : K →L[ℂ] F) + (δ : ℝ) (hδ : ‖G.comp K.subtypeL-T‖≤δ) (x : K) : + ‖G (x:H)-extendZero (K := K) T (x:H)‖≤δ*‖(x:H)‖ := by + rw [extendZero_subtype] + exact ((G.comp K.subtypeL-T).le_opNorm x).trans + (mul_le_mul_of_nonneg_right hδ (norm_nonneg x)) + +end Kadison.ReducingRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/MultilinearTensors.lean b/lean/OAI/Analysis/Commutator/MultilinearTensors.lean new file mode 100644 index 0000000000000000000000000000000000000000..06e7287966cda938d507c6a576aedb93ca6668f2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/MultilinearTensors.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.PreHilbert + +open Function + +lemma pure_update_add (E : PreHilbert) (n : ℕ) (v : Fin n → E) (i : Fin n) (x y : E) : + pure E n (update v i (x + y)) = + pure E n (update v i x) + pure E n (update v i y) := by + induction n with + | zero => exact Fin.elim0 i + | succ n ih => + cases i using Fin.cases with + | zero => simp [pure_succ, Fin.tail_update_zero, TensorProduct.add_tmul] + | succ i => + simp only [pure_succ, Fin.tail_update_succ, update_of_ne (Fin.succ_ne_zero i).symm] + rw [ih, TensorProduct.tmul_add] + +lemma pure_update_smul (E : PreHilbert) (n : ℕ) (v : Fin n → E) (i : Fin n) (c : ℂ) (x : E) : + pure E n (update v i (c • x)) = c • pure E n (update v i x) := by + induction n with + | zero => exact Fin.elim0 i + | succ n ih => + cases i using Fin.cases with + | zero => simp [pure_succ, Fin.tail_update_zero, TensorProduct.smul_tmul'] + | succ i => + simp only [pure_succ, Fin.tail_update_succ, update_of_ne (Fin.succ_ne_zero i).symm] + rw [ih, TensorProduct.tmul_smul] + +def pureMultilinear (E : PreHilbert) (n : ℕ) : + MultilinearMap ℂ (fun _ : Fin n => E) (power E n) where + toFun := pure E n + map_update_add' := by + intro inst v i x y + have hi : inst = instDecidableEqFin n := Subsingleton.elim _ _ + subst inst + exact pure_update_add E n v i x y + map_update_smul' := by + intro inst v i c x + have hi : inst = instDecidableEqFin n := Subsingleton.elim _ _ + subst inst + exact pure_update_smul E n v i c x + +def hilbertPureMultilinear (E : PreHilbert) (n : ℕ) : + MultilinearMap ℂ (fun _ : Fin n => E) (hilbertPower E n) := + (UniformSpace.Completion.toComplL : power E n →L[ℂ] hilbertPower E n).toLinearMap.compMultilinearMap + (pureMultilinear E n) + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NonfiniteFactor.lean b/lean/OAI/Analysis/Commutator/NonfiniteFactor.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f2e4bd710a2c9b721b9319648f097872f86c46c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NonfiniteFactor.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialDecomposition +import OAI.Analysis.Commutator.ProperIsometryReplicas +import OAI.Analysis.Commutator.ProperlyInfiniteMain +import OAI.Analysis.Commutator.PartialDecompositionCountable +import OAI.Analysis.Commutator.ReplicaPacking + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +theorem nonfinite_two_isometries (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) (hfin : ¬IsFiniteAlgebra M) : + ∃ s t : M,star s*s=1 ∧ star t*t=1 ∧ star s*t=0 := by + classical + obtain ⟨r,hrM,hr,hrn,⟨R⟩⟩ := nonfinite_replicas M hfin + obtain ⟨D⟩ := exists_partialDecomposition M hfac hrM hr hrn + let := D.countable + obtain ⟨e,he⟩ := Countable.exists_injective_nat (D.I × Bool) + let f : D.I → ℕ := fun i => e (i,false) + let g : D.I → ℕ := fun i => e (i,true) + have hf : Function.Injective f := fun i j h => (Prod.mk.inj (he h)).1 + have hg : Function.Injective g := fun i j h => (Prod.mk.inj (he h)).1 + have hfg : ∀ i j,f i≠g j := by + intro i j hij + have := (Prod.mk.inj (he hij)).2 + contradiction + obtain ⟨s,hs,hsv⟩ := D.exists_packing R hr f hf + obtain ⟨t,ht,htv⟩ := D.exists_packing R hr g hg + refine ⟨⟨s,hs⟩,⟨t,ht⟩,?_,?_,?_⟩ + · apply Subtype.ext + exact D.packing_isometry R hr f hf hsv + · apply Subtype.ext + exact D.packing_isometry R hr g hg htv + · apply Subtype.ext + exact D.packings_orthogonal R f g hfg hsv htv + +end Kadison.PartialIsometryOrder + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +theorem uniform_commutator_nonfinite_factor (P : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor P) (hfin : ¬PartialIsometryOrder.IsFiniteAlgebra P) + (Y : H →L[ℂ] H) (h : ℕ) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖ ≤ + 9*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + obtain ⟨s,t,hs,ht,hst⟩ := PartialIsometryOrder.nonfinite_two_isometries P hfac hfin + exact uniform_commutator_of_two_isometries P s t hs ht hst Y h X hX + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NonseparableReduction.lean b/lean/OAI/Analysis/Commutator/NonseparableReduction.lean new file mode 100644 index 0000000000000000000000000000000000000000..050830d28696fce808a0fd6f617a1101b69541e7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NonseparableReduction.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.Commutator.CommutatorBicommutant +import OAI.Analysis.Commutator.ReducingMatrix +import OAI.Analysis.Commutator.SeparableReducingHull + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +open ContinuousLinearMap + +universe u + +namespace Kadison + +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma image_mem_bicommutant {A : Type*} [CStarAlgebra A] + (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (a : A) : + σ a∈NormalGNS.bicommutant σ.range := + NormalGNS.subset_bicommutant σ.range ⟨a,rfl⟩ + +lemma reducing_commutator_bound (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (S : StarSubalgebra ℂ (H →L[ℂ] H)) [IsClosed (S : Set (H →L[ℂ] H))] + (hSP : S≤P.toStarSubalgebra) (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : S) (x : H),x∈K → S.subtype a x∈K) + (hY : ∀ x∈K,Y x∈K) : + commutatorSeminorm (NormalGNS.bicommutant (ReducingRepresentation.restrict S.subtype K hinv).range) + (Y.restrict hY)≤commutatorSeminorm P Y := by + apply commutatorSeminorm_image_bicommutant_le _ _ _ (commutatorSeminorm_nonneg P Y) + intro a + rw [←ReducingRepresentation.compression_eq_restrict K Y hY] + exact (ReducingRepresentation.norm_commutator_compression_le S.subtype K hinv Y a).trans + (commutator_bound P Y (hSP a.property)) + +lemma reducing_matrix_vector_bound + (S : StarSubalgebra ℂ (H →L[ℂ] H)) [IsClosed (S : Set (H →L[ℂ] H))] + (Y : H →L[ℂ] H) (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : S) (x : H),x∈K → S.subtype a x∈K) + (hY : ∀ x∈K,Y x∈K) (h : ℕ) (X : Matrix (Fin h) (Fin h) S) + (v : PiLp 2 (fun _ : Fin h => H)) (hv : ∀ i,v i∈K) (b : ℝ) + (hb : ‖diagonalAmplification h (Y.restrict hY)* + matrixOperator h (fun i j => ReducingRepresentation.restrict S.subtype K hinv (X i j))- + matrixOperator h (fun i j => ReducingRepresentation.restrict S.subtype K hinv (X i j))* + diagonalAmplification h (Y.restrict hY)‖≤b) : + ‖(diagonalAmplification h Y*matrixOperator h (fun i j => (X i j:H →L[ℂ] H))- + matrixOperator h (fun i j => (X i j:H →L[ℂ] H))*diagonalAmplification h Y) v‖≤b*‖v‖ := by + let v₀ : PiLp 2 (fun _ : Fin h => K) := WithLp.toLp 2 (fun i => ⟨v i,hv i⟩) + have heq : ReducingRepresentation.matrixInclusion K h v₀=v := by ext i; rfl + have hvnorm : ‖v₀‖=‖v‖ := by rw [←heq,LinearIsometry.norm_map] + have he := congrArg (fun A => A v₀) + (ReducingRepresentation.matrix_commutator_intertwines S.subtype K hinv Y hY h X) + change (diagonalAmplification h Y*matrixOperator h (fun i j => (X i j:H →L[ℂ] H))- + matrixOperator h (fun i j => (X i j:H →L[ℂ] H))*diagonalAmplification h Y) + (ReducingRepresentation.matrixInclusion K h v₀)= + ReducingRepresentation.matrixInclusion K h + ((diagonalAmplification h (Y.restrict hY)* + matrixOperator h (fun i j => ReducingRepresentation.restrict S.subtype K hinv (X i j))- + matrixOperator h (fun i j => ReducingRepresentation.restrict S.subtype K hinv (X i j))* + diagonalAmplification h (Y.restrict hY)) v₀) at he + rw [heq] at he + rw [he,LinearIsometry.norm_map] + exact (ContinuousLinearMap.le_opNorm _ v₀).trans + (by simpa only [hvnorm] using mul_le_mul_of_nonneg_right hb (norm_nonneg v₀)) + +lemma separable_reducing_bound {C : ℝ} (hC : 0≤C) + (hsep : ∀ (H : Type u) [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] [TopologicalSpace.SeparableSpace H] + (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (h : ℕ), 1≤h → ∀ X : Matrix (Fin h) (Fin h) (H →L[ℂ] H), + (∀ i j,X i j∈P) → + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + C*commutatorSeminorm P Y*‖matrixOperator h X‖) + (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (S : StarSubalgebra ℂ (H →L[ℂ] H)) [IsClosed (S : Set (H →L[ℂ] H))] + (hSP : S≤P.toStarSubalgebra) (K : Submodule ℂ H) [CompleteSpace K] + [TopologicalSpace.SeparableSpace K] + (hinv : ∀ (a : S) (x : H),x∈K → S.subtype a x∈K) + (hY : ∀ x∈K,Y x∈K) (h : ℕ) (hh : 1≤h) (X : Matrix (Fin h) (Fin h) S) + (v : PiLp 2 (fun _ : Fin h => H)) (hv : ∀ i,v i∈K) : + ‖(diagonalAmplification h Y*matrixOperator h (fun i j => (X i j:H →L[ℂ] H))- + matrixOperator h (fun i j => (X i j:H →L[ℂ] H))*diagonalAmplification h Y) v‖≤ + C*commutatorSeminorm P Y*‖matrixOperator h (fun i j => (X i j:H →L[ℂ] H))‖*‖v‖ := by + let σ := ReducingRepresentation.restrict S.subtype K hinv + let P₀ := NormalGNS.bicommutant σ.range + have hcomm := reducing_commutator_bound P Y S hSP K hinv hY + have hn := ReducingRepresentation.restricted_matrix_norm_le S.subtype K hinv h X + apply reducing_matrix_vector_bound S Y K hinv hY h X v hv + have hm (i j : Fin h) : σ (X i j)∈P₀ := + image_mem_bicommutant σ (X i j) + have hb := hsep K P₀ (Y.restrict hY) h hh (fun i j => σ (X i j)) hm + exact hb.trans (mul_le_mul (mul_le_mul_of_nonneg_left hcomm hC) hn (norm_nonneg (matrixOperator h (fun i j => σ (X i j)))) + (mul_nonneg hC (commutatorSeminorm_nonneg P Y))) + +theorem remove_separability {C : ℝ} (hC : 0≤C) + (hsep : ∀ (H : Type u) [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] [TopologicalSpace.SeparableSpace H] + (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (h : ℕ), 1≤h → ∀ X : Matrix (Fin h) (Fin h) (H →L[ℂ] H), + (∀ i j,X i j∈P) → + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + C*commutatorSeminorm P Y*‖matrixOperator h X‖) + (H : Type u) [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + C*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + classical + apply ContinuousLinearMap.opNorm_le_bound _ + (mul_nonneg (mul_nonneg hC (commutatorSeminorm_nonneg P Y)) (norm_nonneg _)) + intro v + let T : Option (Fin h × Fin h) → H →L[ℂ] H := fun i => + match i with | none => Y | some p => X p.1 p.2 + let K := SeparableReducingHull.hull T (fun i => v i) + let S := (StarAlgebra.adjoin ℂ (Set.range (fun p : Fin h × Fin h => X p.1 p.2))).topologicalClosure + let : IsClosed (S : Set (H →L[ℂ] H)) := StarSubalgebra.isClosed_topologicalClosure _ + have hSP : S≤P.toStarSubalgebra := by + apply StarSubalgebra.topologicalClosure_minimal + · apply StarAlgebra.adjoin_le + rintro _ ⟨⟨i,j⟩,rfl⟩ + exact hX i j + · exact VonNeumannCStar.isClosed P + have hSK : S≤SeparableReducingHull.reducingAlgebra K := by + apply StarSubalgebra.topologicalClosure_minimal + · apply StarAlgebra.adjoin_le + rintro _ ⟨⟨i,j⟩,rfl⟩ + exact SeparableReducingHull.generator_mem_reducingAlgebra T (fun i => v i) (some (i,j)) + · exact SeparableReducingHull.reducingAlgebra_closed K (SeparableReducingHull.hull_closed T _) + have hY : ∀ x∈K,Y x∈K := SeparableReducingHull.invariant T (fun i => v i) none + have hinv : ∀ (a : S) (x : H),x∈K → S.subtype a x∈K := fun a => (hSK a.property).1 + have hXS (i j : Fin h) : X i j∈S := + StarSubalgebra.le_topologicalClosure _ (StarAlgebra.subset_adjoin ℂ _ ⟨(i,j),rfl⟩) + exact separable_reducing_bound hC hsep P Y S hSP K hinv hY h hh + (fun i j => ⟨X i j,hXS i j⟩) v (SeparableReducingHull.vector_mem T (fun i => v i)) + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormSeparableFixedPoint.lean b/lean/OAI/Analysis/Commutator/NormSeparableFixedPoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..19eb707ad5db9a75511fc124dc62a5771b41ceab --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormSeparableFixedPoint.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.DeMarrCenter +import OAI.Analysis.Commutator.MinimalNormCompact + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Set TopologicalSpace + +namespace Kadison.CompactInvariant + +variable {G X E : Type*} [Group G] [TopologicalSpace X] [T2Space X] + [AddCommGroup X] [Module ℝ X] [MulAction G X] [ContinuousConstSMul G X] + [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +theorem exists_fixed_point (j : X ≃ₗ[ℝ] E) (hj : Continuous j.symm) + (hball : ∀ y : E,∀ r : ℝ,IsClosed {x : X | dist (j x) y≤r}) + (hiso : ∀ g : G,∀ x y : X,dist (j (g • x)) (j (g • y))=dist (j x) (j y)) + {C : Set X} (hcomp : IsCompact C) (hne : C.Nonempty) (hconv : Convex ℝ C) + (hinv : Invariant (G:=G) C) (hsep : IsSeparable (j '' C)) : + ∃ x∈C,∀ g : G,g • x=x := by + classical + obtain ⟨C₀,hC₀⟩ := exists_minimal_convex hcomp hne hinv hconv + have hCcomp : IsCompact C₀ := hcomp.of_isClosed_subset hC₀.prop.2.2.1 hC₀.prop.1 + obtain ⟨K,hK⟩ := exists_minimal_compact hCcomp hC₀.prop.2.1 hC₀.prop.2.2.2.1 + have hKcomp : IsCompact K := hCcomp.of_isClosed_subset hK.prop.2.2.1 hK.prop.1 + have hnormcomp : IsCompact (j '' K) := minimal_norm_compact j.toEquiv hj hball hiso + hKcomp hK (hsep.mono (image_mono (hK.prop.1.trans hC₀.prop.1))) + have hsubsingleton : (j '' K).Subsingleton := by + by_contra hnot + have hnontriv : (j '' K).Nontrivial := Set.not_subsingleton_iff.mp hnot + let D := Metric.diam (j '' K) + have hD : 0 Metric.dist_le_diam_of_mem hnormcomp.isBounded hx hy + obtain ⟨c,hc,r,hr,hrD,hcr⟩ := DeMarrCenter.exists_center hnormcomp + (hK.prop.2.1.image j) D hD hdiam + have hcin : j.symm c∈C₀ := by + change c∈convexHull ℝ (j.toLinearMap '' K) at hc + rw [←j.toLinearMap.image_convexHull] at hc + obtain ⟨z,hz,rfl⟩ := hc + change j.symm (j z)∈C₀ + rw [j.symm_apply_apply] + exact convexHull_min hK.prop.1 hC₀.prop.2.2.2.2 hz + let L : Set X := C₀∩⋂ x∈K,j ⁻¹' Metric.closedBall (j x) r + have hLc : IsClosed L := hC₀.prop.2.2.1.inter (isClosed_iInter fun x => + isClosed_iInter fun _ => hball (j x) r) + have hLconv : Convex ℝ L := hC₀.prop.2.2.2.2.inter (convex_iInter fun x => + convex_iInter fun _ => (convex_closedBall (j x) r).linear_preimage j.toLinearMap) + have hLne : L.Nonempty := by + refine ⟨j.symm c,hcin,?_⟩ + apply mem_iInter₂.mpr + intro x hx + change dist (j (j.symm c)) (j x)≤r + rw [j.apply_symm_apply] + exact hcr _ ⟨x,hx,rfl⟩ + have hLinv : Invariant (G:=G) L := by + intro g z hz + refine ⟨hC₀.prop.2.2.2.1 g z hz.1,mem_iInter₂.mpr ?_⟩ + intro x hx + have hgi : g⁻¹ • x∈K := hK.prop.2.2.2 g⁻¹ x hx + have hb : dist (j z) (j (g⁻¹ • x))≤r := mem_iInter₂.mp hz.2 _ hgi + change dist (j (g • z)) (j x)≤r + rw [←hiso g z (g⁻¹ • x),smul_inv_smul] at hb + exact hb + have hCL : C₀⊆L := hC₀.le_of_le + ⟨(inter_subset_left.trans hC₀.prop.1),hLne,hLc,hLinv,hLconv⟩ inter_subset_left + have hDle : D≤r := by + apply Metric.diam_le_of_forall_dist_le hr + rintro _ ⟨x,hx,rfl⟩ _ ⟨y,hy,rfl⟩ + exact mem_iInter₂.mp (hCL (hK.prop.1 hx)).2 y hy + linarith + obtain ⟨x,hx⟩ := hK.prop.2.1 + refine ⟨x,hC₀.prop.1 (hK.prop.1 hx),?_⟩ + intro g + apply j.injective + exact hsubsingleton ⟨g • x,hK.prop.2.2.2 g x hx,rfl⟩ ⟨x,hx,rfl⟩ + +end Kadison.CompactInvariant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalBiprodGNS.lean b/lean/OAI/Analysis/Commutator/NormalBiprodGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..36bc2d7d41caec6125125c3816049ec33caf31de --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalBiprodGNS.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertBiprod +import OAI.Analysis.Commutator.NormalGNSContinuity +import OAI.Analysis.Commutator.NormalOperatorHom + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology ComplexOrder NNReal + +open Filter ContinuousLinearMapWOT + +namespace Kadison.NormalOperatorHom + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable (M : VonNeumannAlgebra H) + +lemma gns_normal (τ : M →ₚ[ℂ] ℂ) (hτ : NormalGNS.BoundedWOTContinuous M τ) : + BoundedNormal M τ.gnsStarAlgHom := by + intro C x y + apply continuous_iff_continuousAt.mpr + intro a + let C' : ℝ≥0 := ⟨max C 0,le_max_right _ _⟩ + let f : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} → M := + fun b => ⟨b.val.toCLM,b.property.1⟩ + have hf : ∀ b,‖f b‖≤C' := fun b => b.property.2.trans (le_max_left _ _) + apply NormalGNS.tendsto_gns M τ hτ f (f a) C' hf (hf a) + intro u v + have hc := (ContinuousLinearMapWOT.continuous_inner_apply continuous_subtype_val u v).tendsto a + simpa only [f,RCLike.star_def,inner_conj_symm,coe_toCLM] using hc.star + +lemma subtype_normal : BoundedNormal M M.toStarSubalgebra.subtype := by + intro C x y + exact ContinuousLinearMapWOT.continuous_inner_apply continuous_subtype_val y x + +lemma diag_normal {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (φ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) (ψ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (hφ : BoundedNormal M φ) (hψ : BoundedNormal M ψ) : + BoundedNormal M (HilbertBiprod.diagHom φ ψ) := by + intro C x y + have hc := (hφ C x.ofLp.1 y.ofLp.1).add (hψ C x.ofLp.2 y.ofLp.2) + change Continuous (fun a : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} => inner ℂ x.ofLp.1 (φ ⟨a.val.toCLM,a.property.1⟩ y.ofLp.1) + + inner ℂ x.ofLp.2 (ψ ⟨a.val.toCLM,a.property.1⟩ y.ofLp.2)) at hc + simpa only [HilbertBiprod.diagHom_apply,HilbertBiprod.block_apply,WithLp.prod_inner_apply] + using hc + +lemma diagonal_gns_range (τ : M →ₚ[ℂ] ℂ) (hτ : NormalGNS.BoundedWOTContinuous M τ) : + Set.centralizer (Set.centralizer + (Set.range (HilbertBiprod.diagHom (A:=M) (H:=H) (G:=τ.GNS) M.toStarSubalgebra.subtype τ.gnsStarAlgHom)))= + Set.range (HilbertBiprod.diagHom (A:=M) (H:=H) (G:=τ.GNS) M.toStarSubalgebra.subtype τ.gnsStarAlgHom) := + range_bicommutant M _ (diag_normal M _ _ (subtype_normal M) (gns_normal M τ hτ)) + +end Kadison.NormalOperatorHom + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalCopiesAverage.lean b/lean/OAI/Analysis/Commutator/NormalCopiesAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..6acbbec63bc2b35dc54c76d0bcb84a8d643ed108 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalCopiesAverage.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Commutator.MainCommutantDistance +import OAI.Analysis.Commutator.NormalOriginalTower +import OAI.Analysis.Commutator.RepresentedTowerAverage + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison + +namespace RepresentedTower + +variable {A K : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma perturbation_bound (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (Y Z : K →L[ℂ] K) + {δ : ℝ} (hδ : 0≤δ) (hd : ‖Z-Y‖≤δ) + (hY : ∀ a : A,‖Y*ρ a-ρ a*Y‖≤δ*‖a‖) (a : A) : + ‖Z*ρ a-ρ a*Z‖≤(3*δ)*‖a‖ := by + have he : Z*ρ a-ρ a*Z=(Z-Y)*ρ a-ρ a*(Z-Y)+(Y*ρ a-ρ a*Y) := by + simp only [sub_mul,mul_sub]; abel + calc + _ ≤ ‖(Z-Y)*ρ a-ρ a*(Z-Y)‖+‖Y*ρ a-ρ a*Y‖ := by rw [he]; exact norm_add_le _ _ + _ ≤ 2*‖Z-Y‖*‖ρ a‖+δ*‖a‖ := add_le_add (operator_commutator_norm_le _ _) (hY a) + _ ≤ 2*δ*‖a‖+δ*‖a‖ := by + gcongr + exact NonUnitalStarAlgHom.norm_apply_le ρ a + _ = _ := by ring + +end RepresentedTower + +namespace MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (F : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +include hnormal in +theorem original_copies_average (hF : Monotone (fun n => (F n).hom.range)) + (Y : OperatorAmplification.SumSpace (H:=τ.GNS) ι →L[ℂ] + OperatorAmplification.SumSpace (H:=τ.GNS) ι) {δ : ℝ} (hδ : 0≤δ) + (hY : ∀ a : M,‖Y*OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Y‖≤δ*‖a‖) : + ∃ Z : OperatorAmplification.SumSpace (H:=τ.GNS) ι →L[ℂ] + OperatorAmplification.SumSpace (H:=τ.GNS) ι, + ‖Z‖≤‖Y‖ ∧ ‖Z-Y‖≤δ ∧ + (∀ a : M,(a:H →L[ℂ] H)∈generated M F → + Z*OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)= + OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Z) ∧ + (∀ a : M,‖Z*OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)- + OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)*Z‖≤(3*δ)*‖a‖) := by + let ρ := (OperatorAmplification.diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom + have hb (u : unitary M) : ‖Y*ρ (u:M)-ρ (u:M)*Y‖≤δ := by + simpa only [ρ,StarAlgHom.comp_apply,CStarRing.norm_of_mem_unitary u.property,mul_one] using hY (u:M) + have havg := RepresentedTower.exists_tower_average ρ (fun n => (F n).I) + (fun n => (F n).hom) hF Y hδ hb + obtain ⟨Z,hZ,hd,hc⟩ := havg + refine ⟨Z,hZ,hd,?_,?_⟩ + · intro a ha + exact hc _ (original_copies_generated M F τ hnormal ι a ha) + · exact RepresentedTower.perturbation_bound ρ Y Z hδ hd hY + +end MatrixTower + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalCornerExtension.lean b/lean/OAI/Analysis/Commutator/NormalCornerExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..7119b3e96cfdf09e0ebb5ed1b12896896b8534cf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalCornerExtension.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerSymmetrization +import OAI.Analysis.Commutator.NormalTraceProjection + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.NormalGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem extend_projection_trace (M : VonNeumannAlgebra H) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hone : τ 1=1) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (q : M) (hq : IsStarProjection q) {β : ℝ} + (hβq : (τ q).re≤β) (hβ : β≤1) : + ∃ e : M, IsStarProjection e ∧ q≤e ∧ τ e=(β:ℂ) := by + have htr : β-(τ q).re≤(τ (1-q)).re := by + rw [map_sub,hone,Complex.sub_re,Complex.one_re] + linarith + obtain ⟨r,hr,hrle,hrt⟩ := exists_prescribed_projection_trace M τ hτ hnormal hfaith + hdiffuse (1-q) hq.one_sub (sub_nonneg.mpr hβq) htr + have hqr : q*r=0 := by + have hfix := (hr.le_iff_mul_eq_right hq.one_sub).mp hrle + calc + q*r=q*((1-q)*r) := by rw [hfix] + _=0 := by rw [←mul_assoc,hq.mul_one_sub_self,zero_mul] + have he := hq.add hr hqr + refine ⟨q+r,he,le_add_of_nonneg_right hr.nonneg,?_⟩ + apply Complex.ext + · simp only [map_add,Complex.add_re,Complex.ofReal_re,hrt]; ring + · exact (τ.map_nonneg he.nonneg).2.symm + +end Kadison.NormalGNS + +namespace Kadison.CornerSymmetrization + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem bound_small_projection (M : VonNeumannAlgebra H) + (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hone : τ 1=1) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (P : StarSubalgebra ℂ (K →L[ℂ] K)) + (Ω : K) (hΩ : ∀ a : M, vectorState Ω (π a)=τ a) + (G : K →L[ℂ] K) (ε β : ℝ) (hβ : β≤1) + (hbound : ∀ x, CornerElement π.range P Ω (β:ℂ) x → ‖G*x-x*G‖≤ε*‖x‖) + (q : M) (hq : IsStarProjection q) (hqt : (τ q).re≤β) + (x : K →L[ℂ] K) (hx : x∈P) (hl : π q*x=x) (hr : x*π q=x) : + ‖G*x-x*G‖≤ε*‖x‖ := by + obtain ⟨e,he,hqe,het⟩ := NormalGNS.extend_projection_trace M τ hτ hnormal hfaith + hone hdiffuse q hq hqt hβ + have hleft : π e*π q=π q := by + rw [←map_mul,(hq.le_iff_mul_eq_right he).mp hqe] + have hright : π q*π e=π q := by + rw [←map_mul,(hq.le_iff_mul_eq_left he).mp hqe] + apply hbound x + refine ⟨hx,π e,⟨e,rfl⟩,he.map π,(hΩ e).trans het,?_,?_⟩ + · calc + π e*x=π e*(π q*x) := by rw [hl] + _=x := by rw [←mul_assoc,hleft,hl] + · calc + x*π e=(x*π q)*π e := by rw [hr] + _=x := by rw [mul_assoc,hright,hr] + +end Kadison.CornerSymmetrization + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalFreeCorner.lean b/lean/OAI/Analysis/Commutator/NormalFreeCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..5d4a65323a86c3fc4c70394d84b2ca110cf0bce3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalFreeCorner.lean @@ -0,0 +1,188 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeStageAverage +import OAI.Analysis.Commutator.FreeStageHankel +import OAI.Analysis.Commutator.MatrixColumnCorner +import OAI.Analysis.Commutator.NormalCornerExtension + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Matrix.Norms.L2Operator + +open UniformSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeWordAction + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def ambientVonNeumann (t : FaithfulState A) (S : Bool → StarSubalgebra ℂ A) : + VonNeumannAlgebra t.functional.GNS where + toStarSubalgebra := ambientOperators t S + centralizer_centralizer' := by + have he : (ambientOperators t S).carrier = + Set.centralizer (Set.centralizer (generatedOperators t S : Set (t.functional.GNS →L[ℂ] t.functional.GNS))) := + by ext x; exact mem_ambientOperators t S + change Set.centralizer (Set.centralizer (ambientOperators t S).carrier)=(ambientOperators t S).carrier + rw [he] + simp only [Set.centralizer_centralizer_centralizer] + +lemma gns_vectorState (τ : A →ₚ[ℂ] ℂ) (a : A) : + CornerSymmetrization.vectorState (TracialGNS.vacuum τ) (τ.gnsStarAlgHom a)=τ a := by + change inner ℂ (TracialGNS.vacuum τ) (τ.gnsStarAlgHom a (TracialGNS.vacuum τ))=τ a + rw [TracialGNS.left_vacuum] + exact TracialGNS.inner_vacuum_algebraVector τ a + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (D : VonNeumannAlgebra H) + (t : FaithfulState A) (htr : ∀ a b : A, t.functional (a*b)=t.functional (b*a)) + (f : D →⋆ₐ[ℂ] A) (hf : Function.Injective f) + (S : Bool → StarSubalgebra ℂ A) (hS : S false=f.range) + (hfree : Free S t.functional.toLinearMap) + (hgen : ∀ a : A, t.functional.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer (generatedOperators t S : Set _))) + (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] [∀ n, Nonempty (I n)] + (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a, φ m (inc h a)=φ n a) + (hsize : ∀ n q : ℕ, ∃ m, n ≤ m ∧ q ≤ Fintype.card (I m)) + (hDgen : ∀ a : D, (factorTrace t f hf).gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra (factorTrace t f hf) I φ : Set _))) + +include hS htr hinc hsize hDgen hgen in +theorem normal_free_corner_bound + (hnormal : NormalGNS.BoundedWOTContinuous D (factorTrace t f hf)) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections D) + (G : t.functional.GNS →L[ℂ] t.functional.GNS) + (hGD : ∀ a : D, G*t.functional.gnsStarAlgHom (f a)=t.functional.gnsStarAlgHom (f a)*G) + (s : unitary A) (hs : (s:A)∈S true) (hs0 : t.functional (s:A)=0) + (hs2 : (s:A)*(s:A)=1) + (ε β : ℝ) (hε : 0 ≤ ε) (hβ : 0 < β) (hβ1 : β ≤ 1) + (hC : ∀ x, CornerSymmetrization.CornerElement (factorOperators t f) (ambientOperators t S) + (TracialGNS.vacuum t.functional) (β:ℂ) x → ‖G*x-x*G‖ ≤ ε*‖x‖) : + ‖(ContinuousLinearMap.adjoint (𝕜:=ℂ) (E:=multiplicityLevel t S true 0) (F:=t.functional.GNS) + (baseEmbedding t S hfree).toContinuousLinearMap).comp + ((G*t.functional.gnsStarAlgHom (s:A)-t.functional.gnsStarAlgHom (s:A)*G).comp + (baseEmbedding t S hfree).toContinuousLinearMap)‖ ≤ 1040*ε := by + classical + let τ := factorTrace t f hf + have hτ : ∀ a b : D, τ (a*b)=τ (b*a) := factorTrace_tracial t f hf htr + have hone : τ 1=1 := (pullbackState t f hf).normalized + have hfaith : ∀ a : D, τ (star a*a)=0 → a=0 := (pullbackState t f hf).faithful + obtain ⟨V,_,hVW,hVD,hVC,hVe⟩ := free_stage_symmetrization t htr S f hS hfree hgen + I φ inc hinc G ε hε β (s:A) hs hGD hC + have hsmall (q : D) (hq : IsStarProjection q) (hqt : (τ q).re ≤ β) + (x : t.functional.GNS →L[ℂ] t.functional.GNS) (hx : x∈ambientOperators t S) + (hl : t.functional.gnsStarAlgHom (f q)*x=x) + (hr : x*t.functional.gnsStarAlgHom (f q)=x) : ‖V*x-x*V‖ ≤ ε*‖x‖ := + CornerSymmetrization.bound_small_projection D τ hτ hnormal hfaith hone hdiffuse + (t.functional.gnsStarAlgHom.comp f) (ambientOperators t S) (TracialGNS.vacuum t.functional) + (fun a => gns_vectorState t.functional (f a)) V ε β hβ1 hVC q hq hqt x hx hl hr + obtain ⟨n,hn⟩ := MatrixColumnCorner.exists_small_stage I hsize hβ + let i0 : I n := Classical.choice inferInstance + let q : Matrix (I n) (I n) ℂ := Matrix.single i0 i0 1 + have hq : IsStarProjection q := MatrixColumnCorner.minimal_projection i0 + have hqτ : τ (φ n q)=(Fintype.card (I n):ℂ)⁻¹ := + MatrixColumnCorner.trace_minimal τ hτ hone (φ n) i0 + have hqreal : (τ (φ n q)).re=(Fintype.card (I n):ℝ)⁻¹ := by + rw [hqτ,←Complex.ofReal_natCast,←Complex.ofReal_inv,Complex.ofReal_re] + have hqsmall := hsmall (φ n q) (hq.map (φ n)) (by rw [hqreal]; exact hn) + obtain ⟨p0,hp0,_,hp0τ⟩ := NormalGNS.exists_prescribed_projection_trace D τ hτ hnormal + hfaith hdiffuse 1 (IsStarProjection.one D) (show (0:ℝ) ≤ 1/2 by norm_num) + (show (1/2:ℝ) ≤ (τ 1).re by rw [hone]; norm_num) + have hp := hp0.map f + let d0 := projectionSymmetry hp0 + let d : unitary A := ⟨f (d0:D),by + constructor + · rw [←map_star,←map_mul,d0.property.1,map_one] + · rw [←map_star,←map_mul,d0.property.2,map_one]⟩ + have hdval : (d:A)=f (p0+p0-1) := rfl + have hd2 : (d:A)*(d:A)=1 := by rw [hdval,←map_mul,projection_symmetry_square hp0,map_one] + have hd : (d:A)∈S false := by rw [hS]; exact ⟨d0,rfl⟩ + have hpD : f p0∈S false := by rw [hS]; exact ⟨p0,rfl⟩ + have hτp : τ p0=(1/2:ℂ) := by + apply Complex.ext + · simpa using hp0τ + · simpa using (τ.map_nonneg hp0.nonneg).2.symm + have hd0 : t.functional (d:A)=0 := by + change τ (p0+p0-1)=0 + rw [map_sub,map_add,hτp,hone] + norm_num + have hpform : f p0=(1/2:ℂ) • (1+(d:A)) := by + have hh := congrArg f (projectionSymmetry_half hp0) + simpa only [map_smul,map_add,map_one] using hh + have hpd : f p0*(d:A)=f p0 := by + change f p0*f (d0:D)=f p0 + rw [←map_mul,projectionSymmetry_left] + have hdp : (d:A)*f p0=f p0 := by + change f (d0:D)*f p0=f p0 + rw [←map_mul,projectionSymmetry_right] + let γ : ℝ := min (β/2) (1/4) + have hγ : 0<γ := lt_min (by positivity) (by norm_num) + have hγβ : γ ≤ β := (min_le_left _ _).trans (by linarith) + have hγp : γ ≤ (τ p0).re := by rw [hp0τ]; exact (min_le_right _ _).trans (by norm_num) + obtain ⟨e0,he0,he0p,he0τ⟩ := NormalGNS.exists_prescribed_projection_trace D τ hτ hnormal + hfaith hdiffuse p0 hp0 hγ.le hγp + let e : Corner hp := ⟨f e0,by + constructor + · rw [←map_mul,(he0.le_iff_mul_eq_right hp0).mp he0p] + · rw [←map_mul,(he0.le_iff_mul_eq_left hp0).mp he0p]⟩ + have heproj : IsStarProjection e := isStarProjection_corner hp (he0.map f) + have he : e∈cornerFactor hp (S false) hpD := by + change f e0∈S false + rw [hS]; exact ⟨e0,rfl⟩ + have hr : 0<‖TracialGNS.algebraVector τ e0‖ := by + apply norm_pos_iff.mpr + intro hz + have hzτ : τ e0=0 := by + rw [←he0.isIdempotentElem.eq,←he0.isSelfAdjoint.star_eq, + ←TracialGNS.inner_algebraVector,hz,inner_zero_left] + have hzr := congrArg Complex.re hzτ + rw [he0τ,Complex.zero_re] at hzr + exact (ne_of_gt hγ) hzr + have heqt : (τ e0).re ≤ β := by rw [he0τ]; exact hγβ + have hsmalle (a : A) (ha : (e:A)*a*(e:A)=a) : + ‖V*t.functional.gnsStarAlgHom a-t.functional.gnsStarAlgHom a*V‖ ≤ ε*‖a‖ := by + have hl : f e0*a=a := by + change f e0*a*f e0=a at ha + calc + _=f e0*(f e0*a*f e0) := by rw [ha] + _=f e0*a*f e0 := by rw [←mul_assoc,←mul_assoc,←map_mul,he0.isIdempotentElem.eq] + _=a := ha + have hr' : a*f e0=a := by + change f e0*a*f e0=a at ha + calc + _=(f e0*a*f e0)*f e0 := by rw [ha] + _=f e0*a*f e0 := by rw [mul_assoc,←map_mul,he0.isIdempotentElem.eq] + _=a := ha + exact (hsmall e0 he0 heqt (t.functional.gnsStarAlgHom a) + ((mem_ambientOperators t S).mpr (hgen a)) + (by rw [←map_mul,hl]) (by rw [←map_mul,hr'])).trans + (mul_le_mul_of_nonneg_left (NonUnitalStarAlgHom.norm_apply_le t.functional.gnsStarAlgHom a) hε) + have hα : (0:ℝ)<(Fintype.card (I n):ℝ)⁻¹ := inv_pos.mpr (by exact_mod_cast Fintype.card_pos) + obtain ⟨hcol,hinit,htotal⟩ := MatrixColumnCorner.full_column (φ n) i0 + have hbound := stage_hankel_bound t htr S f hf hS hfree I φ inc hinc hsize hDgen hgen + V hVD hVW (ambientVonNeumann t S) (fun a => (mem_ambientOperators t S).mpr (hgen a)) + d s hd hs hd0 hs0 (unitary_dihedral hd2 hs2) hd2 hs2 hp hpform hpd hdp hpD + n q hq (Fintype.card (I n):ℝ)⁻¹ hα + (by change τ (φ n q)=_; rw [hqτ,Complex.ofReal_inv,Complex.ofReal_natCast]) + (fun i => φ n (Matrix.single i i0 1)) hcol hinit htotal e0 e rfl heproj he hr + ε hε hqsmall hsmalle + rw [hVe] at hbound + exact hbound + +end Kadison.FreeBlocks + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalGNS.lean b/lean/OAI/Analysis/Commutator/NormalGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..a4ee2c23e36967c885085a099475c72774a439bf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalGNS.lean @@ -0,0 +1,129 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.KaplanskyRange +import OAI.Analysis.Commutator.TracialRightClosure +import OAI.Analysis.Commutator.VonNeumannCStar +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology ComplexOrder + +open Filter ContinuousLinearMapWOT + +namespace Kadison.NormalGNS + +open TracialGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +def BoundedWOTContinuous : Prop := + ∀ C : ℝ, Continuous (fun a : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} => + τ ⟨a.val.toCLM,a.property.1⟩) + +lemma tendsto_trace (hnormal : BoundedWOTContinuous M τ) + {ι : Type*} {l : Filter ι} (a : ι → M) (b : M) (C : ℝ) + (ha : ∀ i, ‖a i‖≤C) (hb : ‖b‖≤C) + (hlim : ∀ x y, Tendsto (fun i => inner ℂ ((a i : H →L[ℂ] H) x) y) l + (𝓝 (inner ℂ ((b : H →L[ℂ] H) x) y))) : + Tendsto (fun i => τ (a i)) l (𝓝 (τ b)) := by + let f : ι → {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} := + fun i => ⟨ofCLM (a i), (a i).property, ha i⟩ + let z : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} := + ⟨ofCLM b,b.property,hb⟩ + have hf : Tendsto f l (𝓝 z) := by + apply tendsto_subtype_rng.mpr + apply tendsto_iff_forall_inner_apply_tendsto.mpr + intro x y + simpa only [f,z,RCLike.star_def,inner_conj_symm,ofCLM_apply] using (hlim x y).star + exact ((hnormal C).tendsto z).comp hf + +theorem vector_unitball_isClosed (hnormal : BoundedWOTContinuous M τ) : + IsClosed {x : τ.GNS | ∃ a : M, ‖a‖≤1 ∧ algebraVector τ a=x} := by + apply IsSeqClosed.isClosed + intro v x hv hx + choose a ha hav using hv + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ)≤atTop := Ultrafilter.of_le _ + obtain ⟨W,hW,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω + (fun i => (a i : H →L[ℂ] H)) 1 (by norm_num) ha + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hlim M + (Eventually.of_forall fun i => (a i).property) + let b : M := ⟨W,hWM⟩ + refine ⟨b,hW,?_⟩ + apply (algebraVector_dense τ).eq_of_inner_right ℂ + intro c + have htr : Tendsto (fun i => τ (star c*a i)) (ω : Filter ℕ) (𝓝 (τ (star c*b))) := by + apply tendsto_trace M τ hnormal (fun i => star c*a i) (star c*b) ‖c‖ + · intro i + exact (norm_mul_le _ _).trans (by simpa only [norm_star,mul_one] using mul_le_mul_of_nonneg_left (ha i) (norm_nonneg (star c))) + · exact (norm_mul_le _ _).trans (by simpa only [norm_star,mul_one] using mul_le_mul_of_nonneg_left (show ‖b‖≤1 from hW) (norm_nonneg (star c))) + · intro ξ η + change Tendsto (fun i => inner ℂ ((star (c : H →L[ℂ] H)) ((a i : H →L[ℂ] H) ξ)) η) + (ω : Filter ℕ) (𝓝 (inner ℂ ((star (c : H →L[ℂ] H)) (W ξ)) η)) + simpa only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left] using hlim ξ ((c : H →L[ℂ] H) η) + have hvec : Tendsto (fun i => inner ℂ (algebraVector τ c) (algebraVector τ (a i))) + (ω : Filter ℕ) (𝓝 (inner ℂ (algebraVector τ c) x)) := by + have ht : Tendsto (fun z : τ.GNS => inner ℂ (algebraVector τ c) z) + (𝓝 x) (𝓝 (inner ℂ (algebraVector τ c) x)) := + (continuous_const.inner continuous_id).tendsto x + exact ht.comp ((hx.mono_left hω).congr' (Eventually.of_forall fun i => (hav i).symm)) + rw [inner_algebraVector] + simp only [inner_algebraVector] at hvec + exact tendsto_nhds_unique htr hvec + +variable (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +include hτ + +lemma eq_of_vacuum {S T : τ.GNS →L[ℂ] τ.GNS} + (hS : S∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) + (he : S (vacuum τ)=T (vacuum τ)) : S=T := by + apply sub_eq_zero.mp + apply bicommutant_vacuum_separating τ hτ + · intro a ha + simp only [mul_sub,sub_mul,hS a ha,hT a ha] + · exact sub_eq_zero.mpr he + +theorem bicommutant_selfAdjoint_contraction (hnormal : BoundedWOTContinuous M τ) + {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) : + ∃ a : M, ‖a‖≤1 ∧ τ.gnsStarAlgHom a=T := by + have hx : T (vacuum τ)∈closure {x : τ.GNS | ∃ a : M, ‖a‖≤1 ∧ algebraVector τ a=x} := by + apply Metric.mem_closure_iff.mpr + intro ε hε + obtain ⟨a,_,hna,he⟩ := Kaplansky.range_selfAdjoint_contraction_finite_approx + Unit τ.gnsStarAlgHom hT hsT hnT (fun _ => vacuum τ) ε hε + refine ⟨algebraVector τ a,⟨a,hna,rfl⟩,?_⟩ + simpa only [dist_eq_norm,norm_sub_rev,left_vacuum,algebraVector_apply] using he () + rw [(vector_unitball_isClosed M τ hnormal).closure_eq] at hx + obtain ⟨a,ha,he⟩ := hx + refine ⟨a,ha,eq_of_vacuum M τ hτ (Set.subset_centralizer_centralizer (Set.mem_range_self a)) hT ?_⟩ + simpa only [left_vacuum,algebraVector_apply] using he + +theorem range_bicommutant (hnormal : BoundedWOTContinuous M τ) : + Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))=Set.range τ.gnsStarAlgHom := by + apply BicommutantRange.operatorHom_range + intro T hT hsT hnT + obtain ⟨a,_,ha⟩ := bicommutant_selfAdjoint_contraction M τ hτ hnormal hT hsT hnT + exact ⟨a,ha⟩ + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalGNSClosure.lean b/lean/OAI/Analysis/Commutator/NormalGNSClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..81be396350d4f7a839aac8d112daef03cacb1acd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalGNSClosure.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.KaplanskyNet +import OAI.Analysis.Commutator.NormalGNSContinuity +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology ComplexOrder + +open Filter + +namespace Kadison.NormalGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hnormal : BoundedWOTContinuous M τ) + (S : StarSubalgebra ℂ (H →L[ℂ] H)) (hS : IsClosed (S : Set (H →L[ℂ] H))) + (hSM : S≤M.toStarSubalgebra) + (N : VonNeumannAlgebra τ.GNS) + (hSN : ∀ a : M,(a:H →L[ℂ] H)∈S → τ.gnsStarAlgHom a∈N) + +include hnormal hS hSM hSN in +lemma contraction_image_bicommutant (a : M) + (ha : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (hna : ‖a‖≤1) : τ.gnsStarAlgHom a∈N := by + classical + let net := Kaplansky.approximationNet S hS (a:H →L[ℂ] H) ha hna + have hnet (j : Finset H × ℕ) := Kaplansky.approximationNet_spec S hS (a:H →L[ℂ] H) ha hna j + let u : Finset H × ℕ → M := fun j => ⟨net j,hSM (hnet j).1⟩ + have hu : ∀ j,‖u j‖≤1 := fun j => (hnet j).2.1 + have hlim (x y : H) : Tendsto (fun j => inner ℂ ((u j:H →L[ℂ] H) x) y) atTop + (𝓝 (inner ℂ ((a:H →L[ℂ] H) x) y)) := + (Kaplansky.approximationNet_tendsto S hS (a:H →L[ℂ] H) ha hna x).inner tendsto_const_nhds + have hgns (x y : τ.GNS) : Tendsto (fun j => inner ℂ (τ.gnsStarAlgHom (u j) x) y) atTop + (𝓝 (inner ℂ (τ.gnsStarAlgHom a x) y)) := by + simpa only [RCLike.star_def,inner_conj_symm] using + (tendsto_gns M τ hnormal u a 1 hu hna hlim y x).star + exact WeakOperatorLimit.mem_vonNeumann hgns N (Eventually.of_forall fun j => hSN (u j) (hnet j).1) + +include hnormal hS hSM hSN in +lemma image_bicommutant (a : M) + (ha : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + τ.gnsStarAlgHom a∈N := by + by_cases hz : a=0 + · subst a + exact hSN 0 S.zero_mem + let c : ℂ := (‖a‖:ℂ) + have hc : c≠0 := by + dsimp [c] + exact_mod_cast (norm_ne_zero_iff.mpr hz) + let b : M := c⁻¹ • a + have hb : (b:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H))) := by + intro x hx + change x*(c⁻¹ • (a:H →L[ℂ] H))=(c⁻¹ • (a:H →L[ℂ] H))*x + rw [mul_smul_comm,smul_mul_assoc,ha x hx] + have hnb : ‖b‖≤1 := by + change ‖c⁻¹ • a‖≤1 + rw [norm_smul,norm_inv] + change ‖(‖a‖:ℂ)‖⁻¹ * ‖a‖≤1 + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_nonneg (norm_nonneg a), + inv_mul_cancel₀ (norm_ne_zero_iff.mpr hz)] + have hN := contraction_image_bicommutant M τ hnormal S hS hSM N hSN b hb hnb + have hab : c • b=a := by dsimp [b]; rw [smul_smul,mul_inv_cancel₀ hc,one_smul] + rw [←hab] + exact (N.toStarSubalgebra.comap τ.gnsStarAlgHom).smul_mem hN c + +include hnormal hSM hSN in +lemma image_bicommutant_general (a : M) + (ha : (a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + τ.gnsStarAlgHom a∈N := by + let C : Set M := {a | τ.gnsStarAlgHom a∈N} + have hC : IsClosed C := (VonNeumannCStar.isClosed N).preimage (map_continuous τ.gnsStarAlgHom) + have hvalC : IsClosed ((Subtype.val : M → (H →L[ℂ] H)) '' C) := + (VonNeumannCStar.isClosed M).isClosedMap_subtype_val C hC + have hSC : (S : Set (H →L[ℂ] H)) ⊆ (Subtype.val : M → (H →L[ℂ] H)) '' C := by + intro a ha + exact ⟨⟨a,hSM ha⟩,hSN ⟨a,hSM ha⟩ ha,rfl⟩ + have hcl := closure_minimal hSC hvalC + have hSM' : S.topologicalClosure≤M.toStarSubalgebra := + S.topologicalClosure_minimal hSM (VonNeumannCStar.isClosed M) + have hSN' (b : M) (hb : (b:H →L[ℂ] H)∈S.topologicalClosure) : τ.gnsStarAlgHom b∈N := by + have hbcl : (b:H →L[ℂ] H)∈closure (S : Set (H →L[ℂ] H)) := hb + obtain ⟨c,hc,hcb⟩ := hcl hbcl + have he : c=b := Subtype.ext hcb + change τ.gnsStarAlgHom c∈N at hc + simpa only [he] using hc + apply image_bicommutant M τ hnormal S.topologicalClosure S.isClosed_topologicalClosure hSM' N hSN' a + intro T hT + apply ha T + intro b hb + exact hT b (S.le_topologicalClosure hb) + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalGNSContinuity.lean b/lean/OAI/Analysis/Commutator/NormalGNSContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..1468ac70528b0d121f18191e74f34e829977632f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalGNSContinuity.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology ComplexOrder NNReal + +open Filter + +namespace Kadison.NormalGNS + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +lemma wot_tendsto_of_dense {ι B : Type*} {l : Filter ι} (v : B → E) (hv : DenseRange v) + (T : ι → E →L[ℂ] E) (S : E →L[ℂ] E) (C : ℝ≥0) (hT : ∀ i,‖T i‖≤C) + (hlim : ∀ a b,Tendsto (fun i => inner ℂ (v a) (T i (v b))) l + (𝓝 (inner ℂ (v a) (S (v b))))) (x y : E) : + Tendsto (fun i => inner ℂ x (T i y)) l (𝓝 (inner ℂ x (S y))) := by + have hfirst (b : B) (x : E) : Tendsto (fun i => inner ℂ x (T i (v b))) l + (𝓝 (inner ℂ x (S (v b)))) := by + have hequi : Equicontinuous (fun i x => inner ℂ x (T i (v b))) := by + apply (LipschitzWith.uniformEquicontinuous _ (C*‖v b‖₊) ?_).equicontinuous + intro i + apply LipschitzWith.of_dist_le_mul + intro x y + rw [dist_eq_norm,←inner_sub_left] + apply (norm_inner_le_norm _ _).trans + have hn : ‖T i (v b)‖≤C*‖v b‖ := + (T i).le_opNorm (v b) |>.trans (mul_le_mul_of_nonneg_right (hT i) (norm_nonneg _)) + simpa only [NNReal.coe_mul,coe_nnnorm,dist_eq_norm,mul_comm] using + mul_le_mul_of_nonneg_left hn (norm_nonneg (x-y)) + exact (hequi x).tendsto_of_mem_closure + ((continuous_id.inner continuous_const).continuousAt.mono_left inf_le_left) + (by rintro _ ⟨a,rfl⟩; exact hlim a b) (hv x) + have hequi : Equicontinuous (fun i y => inner ℂ x (T i y)) := by + apply (LipschitzWith.uniformEquicontinuous _ (‖x‖₊*C) ?_).equicontinuous + intro i + apply LipschitzWith.of_dist_le_mul + intro y z + rw [dist_eq_norm,←inner_sub_right,←map_sub] + apply (norm_inner_le_norm _ _).trans + have hn : ‖T i (y-z)‖≤C*‖y-z‖ := + (T i).le_opNorm (y-z) |>.trans (mul_le_mul_of_nonneg_right (hT i) (norm_nonneg _)) + simpa only [NNReal.coe_mul,coe_nnnorm,dist_eq_norm,mul_assoc] using + mul_le_mul_of_nonneg_left hn (norm_nonneg x) + exact (hequi y).tendsto_of_mem_closure + ((continuous_const.inner S.continuous).continuousAt.mono_left inf_le_left) + (by rintro _ ⟨b,rfl⟩; exact hfirst b x) (hv y) + +open TracialGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma tendsto_gns (hnormal : BoundedWOTContinuous M τ) + {ι : Type*} {l : Filter ι} (a : ι → M) (b : M) (C : ℝ≥0) + (ha : ∀ i,‖a i‖≤C) (hb : ‖b‖≤C) + (hlim : ∀ x y,Tendsto (fun i => inner ℂ ((a i:H →L[ℂ] H) x) y) l + (𝓝 (inner ℂ ((b:H →L[ℂ] H) x) y))) (x y : τ.GNS) : + Tendsto (fun i => inner ℂ x (τ.gnsStarAlgHom (a i) y)) l + (𝓝 (inner ℂ x (τ.gnsStarAlgHom b y))) := by + apply wot_tendsto_of_dense (algebraVector τ) (algebraVector_dense τ) + (fun i => τ.gnsStarAlgHom (a i)) (τ.gnsStarAlgHom b) C + (fun i => (NonUnitalStarAlgHom.norm_apply_le τ.gnsStarAlgHom (a i)).trans (ha i)) + intro c d + have he : ∀ z : M, inner ℂ (algebraVector τ c) (τ.gnsStarAlgHom z (algebraVector τ d))= + τ (star c*z*d) := by + intro z + have hz : τ.gnsStarAlgHom z (algebraVector τ d)=algebraVector τ (z*d) := left_coe τ z d + rw [hz,inner_algebraVector,mul_assoc] + simp_rw [he] + apply tendsto_trace M τ hnormal (fun i => star c*a i*d) (star c*b*d) (‖c‖*C*‖d‖) + · intro i + have hn : ‖star c*a i‖≤‖c‖*C := (norm_mul_le _ _).trans + (by simpa only [norm_star] using mul_le_mul_of_nonneg_left (ha i) (norm_nonneg (star c))) + exact (norm_mul_le _ _).trans (mul_le_mul_of_nonneg_right hn (norm_nonneg d)) + · have hn : ‖star c*b‖≤‖c‖*C := (norm_mul_le _ _).trans + (by simpa only [norm_star] using mul_le_mul_of_nonneg_left hb (norm_nonneg (star c))) + exact (norm_mul_le _ _).trans (mul_le_mul_of_nonneg_right hn (norm_nonneg d)) + · intro ξ η + change Tendsto (fun i => inner ℂ ((star (c:H →L[ℂ] H)) ((a i:H →L[ℂ] H) ((d:H →L[ℂ] H) ξ))) η) + l (𝓝 (inner ℂ ((star (c:H →L[ℂ] H)) ((b:H →L[ℂ] H) ((d:H →L[ℂ] H) ξ))) η)) + simpa only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left] using + hlim ((d:H →L[ℂ] H) ξ) ((c:H →L[ℂ] H) η) + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalGNSSeparable.lean b/lean/OAI/Analysis/Commutator/NormalGNSSeparable.lean new file mode 100644 index 0000000000000000000000000000000000000000..767db8f7d8c7ead2e55767c17e7d84250d286a42 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalGNSSeparable.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalGNSContinuity +import OAI.Analysis.Commutator.WOTBallSeparable + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open Filter + +open scoped InnerProductSpace Topology NNReal ComplexOrder + +namespace Kadison.NormalGNS + +open TracialGNS WOTDistance + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma continuous_ball_coefficient (hnormal : BoundedWOTContinuous M τ) (x : τ.GNS) : + Continuous (fun a : AlgebraBall M 1 => inner ℂ x (algebraVector τ ⟨a.val.toCLM,a.property.1⟩)) := by + rw [continuous_iff_continuousAt] + intro b + have ht := tendsto_gns M τ hnormal + (fun a : AlgebraBall M 1 => (⟨a.val.toCLM,a.property.1⟩ : M)) + (⟨b.val.toCLM,b.property.1⟩ : M) 1 (fun a => a.property.2) b.property.2 + (l := 𝓝 b) (fun ξ η => ?_) x (vacuum τ) + · simp only [left_vacuum] at ht + convert ht using 1 + rfl + · have hc := ContinuousLinearMapWOT.continuous_inner_apply + (continuous_subtype_val : Continuous (fun a : AlgebraBall M 1 => a.val)) ξ η + have hh := (hc.tendsto b).star + simp only [RCLike.star_def,inner_conj_symm] at hh + exact hh + +theorem separable_gns [TopologicalSpace.SeparableSpace H] + (hnormal : BoundedWOTContinuous M τ) : TopologicalSpace.SeparableSpace τ.GNS := by + classical + let : SecondCountableTopology (AlgebraBall M 1) := secondCountable_algebraBall M zero_le_one + let : Nonempty (AlgebraBall M 1) := ⟨⟨0,M.zero_mem,by simp⟩⟩ + obtain ⟨a,ha⟩ := TopologicalSpace.exists_dense_seq (AlgebraBall M 1) + let v : ℕ → τ.GNS := fun n => algebraVector τ ⟨(a n).val.toCLM,(a n).property.1⟩ + let K : Submodule ℂ τ.GNS := Submodule.span ℂ (Set.range v) + have hK : K.topologicalClosure=⊤ := by + apply Submodule.topologicalClosure_eq_top_iff.mpr + apply le_antisymm ?_ bot_le + intro x hx + have hv (n : ℕ) : inner ℂ x (v n)=0 := (K.mem_orthogonal' x).mp hx _ + (Submodule.subset_span (Set.mem_range_self n)) + have hball (b : AlgebraBall M 1) : inner ℂ x (algebraVector τ ⟨b.val.toCLM,b.property.1⟩)=0 := by + exact ha.induction_on b (isClosed_eq (continuous_ball_coefficient M τ hnormal x) continuous_const) hv + have hall (b : M) : inner ℂ x (algebraVector τ b)=0 := by + by_cases hb : b=0 + · simp only [hb,map_zero,inner_zero_right] + have hb' : (‖b‖ : ℂ)≠0 := Complex.ofReal_ne_zero.mpr (norm_ne_zero_iff.mpr hb) + let c : M := (‖b‖ : ℂ)⁻¹ • b + have hn : ‖c‖≤1 := by + dsimp only [c] + rw [norm_smul,norm_inv,Complex.norm_real,Real.norm_of_nonneg (norm_nonneg b)] + exact le_of_eq (inv_mul_cancel₀ (norm_ne_zero_iff.mpr hb)) + have hc := hball ⟨ContinuousLinearMapWOT.ofCLM c,c.property,hn⟩ + have hbc : b=(‖b‖ : ℂ) • c := by + dsimp only [c] + rw [smul_smul,mul_inv_cancel₀ hb',one_smul] + rw [hbc,map_smul,inner_smul_right,hc,mul_zero] + have hx0 : x=0 := (algebraVector_dense τ).eq_of_inner_left ℂ + (fun b => by simpa only [inner_zero_left] using hall b) + simpa only [Submodule.mem_bot] using hx0 + have hs : TopologicalSpace.IsSeparable (K.topologicalClosure : Set τ.GNS) := + ((Set.countable_range v).isSeparable.span (R := ℂ)).closure + rw [hK] at hs + exact TopologicalSpace.isSeparable_univ_iff.mp hs + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalOperatorHom.lean b/lean/OAI/Analysis/Commutator/NormalOperatorHom.lean new file mode 100644 index 0000000000000000000000000000000000000000..ee640bd79ff2bfd05cd530b14496ee03763c45e6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalOperatorHom.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.KaplanskyStarHomNet +import OAI.Analysis.Commutator.VonNeumannCStar +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology + +open Filter ContinuousLinearMapWOT + +namespace Kadison.NormalOperatorHom + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable (M : VonNeumannAlgebra H) (φ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) + +def BoundedNormal : Prop := + ∀ (C : ℝ) (x y : G), Continuous + (fun a : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} => + inner ℂ x (φ ⟨a.val.toCLM,a.property.1⟩ y)) + +lemma sourceBall_tendsto + {ι : Type*} {l : Filter ι} (a : ι → M) (b : M) (C : ℝ) + (ha : ∀ i,‖a i‖≤C) (hb : ‖b‖≤C) + (hlim : ∀ x y,Tendsto (fun i => inner ℂ ((a i:H →L[ℂ] H) x) y) l + (𝓝 (inner ℂ ((b:H →L[ℂ] H) x) y))) : + Tendsto (fun i => (⟨ofCLM (a i),(a i).property,ha i⟩ : + {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C})) l + (𝓝 ⟨ofCLM b,b.property,hb⟩) := by + apply tendsto_subtype_rng.mpr + apply tendsto_iff_forall_inner_apply_tendsto.mpr + intro u v + simpa only [RCLike.star_def,inner_conj_symm,ofCLM_apply] using (hlim u v).star + +lemma tendsto (hφ : BoundedNormal M φ) + {ι : Type*} {l : Filter ι} (a : ι → M) (b : M) (C : ℝ) + (ha : ∀ i,‖a i‖≤C) (hb : ‖b‖≤C) + (hlim : ∀ x y,Tendsto (fun i => inner ℂ ((a i:H →L[ℂ] H) x) y) l + (𝓝 (inner ℂ ((b:H →L[ℂ] H) x) y))) (x y : G) : + Tendsto (fun i => inner ℂ x (φ (a i) y)) l (𝓝 (inner ℂ x (φ b y))) := by + let F : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} → ℂ := + fun z => inner ℂ x (φ ⟨z.val.toCLM,z.property.1⟩ y) + have hF : Continuous F := hφ C x y + have hf := sourceBall_tendsto (H:=H) M a b C ha hb hlim + have ht := (hF.tendsto ⟨ofCLM (b:H →L[ℂ] H),b.property,hb⟩).comp hf + exact ht + +theorem range_bicommutant (hφ : BoundedNormal M φ) : + Set.centralizer (Set.centralizer (Set.range φ))=Set.range φ := by + classical + apply BicommutantRange.operatorHom_range + intro T hT hsT hnT + let a := Kaplansky.starHomNet φ T hT hsT hnT + let ω : Ultrafilter (Finset G × ℕ) := Ultrafilter.of atTop + have hω : (ω : Filter (Finset G × ℕ))≤atTop := Ultrafilter.of_le _ + have ha : ∀ i,‖a i‖≤1 := fun i => (Kaplansky.starHomNet_spec φ T hT hsT hnT i).1 + obtain ⟨W,hW,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω + (fun i => (a i:H →L[ℂ] H)) 1 (by norm_num) ha + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hlim M + (Eventually.of_forall fun i => (a i).property) + let b : M := ⟨W,hWM⟩ + refine ⟨b,?_⟩ + ext y + apply ext_inner_left ℂ + intro x + have hb := tendsto M φ hφ a b 1 ha hW hlim x y + have hc : Continuous (fun z : G => inner ℂ x z) := continuous_const.inner continuous_id + have ht := (hc.tendsto (T y)).comp + ((Kaplansky.starHomNet_tendsto φ T hT hsT hnT y).mono_left hω) + exact tendsto_nhds_unique hb ht + +end Kadison.NormalOperatorHom + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalOriginalTower.lean b/lean/OAI/Analysis/Commutator/NormalOriginalTower.lean new file mode 100644 index 0000000000000000000000000000000000000000..b86b9ee5c5b2833c809cd8ed65fccb705ea5781d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalOriginalTower.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixTowerGNS +import OAI.Analysis.Commutator.OperatorAmplification + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.MatrixTower + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (F : ℕ → Stage M) + +variable (τ : M →ₚ[ℂ] ℂ) (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +include hnormal in +theorem original_gns_generated (a : M) (ha : (a:H →L[ℂ] H)∈generated M F) : + τ.gnsStarAlgHom a∈Set.centralizer (Set.centralizer + ((⨆ n,(τ.gnsStarAlgHom.comp (F n).hom).range : StarSubalgebra ℂ (τ.GNS →L[ℂ] τ.GNS)) : Set _)) := by + let S : StarSubalgebra ℂ (τ.GNS →L[ℂ] τ.GNS) := ⨆ n,(τ.gnsStarAlgHom.comp (F n).hom).range + let N := NormalGNS.bicommutant S + let T := (N.toStarSubalgebra.comap τ.gnsStarAlgHom).map M.toStarSubalgebra.subtype + have hST : stageAlgebra M F≤T := by + apply iSup_le + intro n + rintro x ⟨b,rfl⟩ + refine ⟨(F n).hom b,?_,rfl⟩ + exact NormalGNS.subset_bicommutant S + ((le_iSup (fun n => (τ.gnsStarAlgHom.comp (F n).hom).range) n) ⟨b,rfl⟩) + have hSN (b : M) (hb : (b:H →L[ℂ] H)∈stageAlgebra M F) : τ.gnsStarAlgHom b∈N := by + have hbT := hST hb + obtain ⟨c,hc,hcb⟩ := hbT + have he : c=b := Subtype.ext hcb + change τ.gnsStarAlgHom c∈N at hc + simpa only [he] using hc + exact (NormalGNS.mem_bicommutant S _).mp + (NormalGNS.image_bicommutant_general M τ hnormal (stageAlgebra M F) + (stageAlgebra_le M F) N hSN a ((mem_generated M F a).mp ha)) + +private lemma map_stage_range_le {A B : Type*} + [Semiring A] [StarRing A] [Algebra ℂ A] [StarModule ℂ A] + [Semiring B] [StarRing B] [Algebra ℂ B] [StarModule ℂ B] + (φ : M →⋆ₐ[ℂ] A) (ψ : A →⋆ₐ[ℂ] B) : + (⨆ n,(φ.comp (F n).hom).range).map ψ≤ + ⨆ n,(ψ.comp (φ.comp (F n).hom)).range := by + rw [StarSubalgebra.map_le_iff_le_comap] + apply iSup_le + intro n + rintro x ⟨b,rfl⟩ + exact (le_iSup (fun n => (ψ.comp (φ.comp (F n).hom)).range) n) ⟨b,rfl⟩ + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +private lemma copies_generated_of {K : Type*} + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (φ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (a : M) + (ha : φ a∈Set.centralizer (Set.centralizer + ((⨆ n,(φ.comp (F n).hom).range : StarSubalgebra ℂ (K →L[ℂ] K)) : Set _))) : + OperatorAmplification.diagonal (H:=K) ι (φ a)∈Set.centralizer (Set.centralizer + ((⨆ n,((OperatorAmplification.diagonal (H:=K) ι).comp (φ.comp (F n).hom)).range : + StarSubalgebra ℂ (OperatorAmplification.SumSpace (H:=K) ι →L[ℂ] + OperatorAmplification.SumSpace (H:=K) ι)) : Set _)) := by + let S : StarSubalgebra ℂ (K →L[ℂ] K) := ⨆ n,(φ.comp (F n).hom).range + let ρ := OperatorAmplification.diagonal (H:=K) ι + have hSR := map_stage_range_le M F φ ρ + have h := OperatorAmplification.diagonal_bicommutant ι S ha + intro T hT + exact h T (fun x hx => hT x (hSR hx)) + +include hnormal in +theorem original_copies_generated (a : M) (ha : (a:H →L[ℂ] H)∈generated M F) : + OperatorAmplification.diagonal (H:=τ.GNS) ι (τ.gnsStarAlgHom a)∈ + Set.centralizer (Set.centralizer + ((⨆ n,((OperatorAmplification.diagonal (H:=τ.GNS) ι).comp + (τ.gnsStarAlgHom.comp (F n).hom)).range : + StarSubalgebra ℂ (OperatorAmplification.SumSpace (H:=τ.GNS) ι →L[ℂ] + OperatorAmplification.SumSpace (H:=τ.GNS) ι)) : Set _)) := by + exact copies_generated_of M F ι (K:=τ.GNS) τ.gnsStarAlgHom a + (original_gns_generated M F τ hnormal a ha) + +end Kadison.MatrixTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalPredual.lean b/lean/OAI/Analysis/Commutator/NormalPredual.lean new file mode 100644 index 0000000000000000000000000000000000000000..45bbaefd3c4407505ac7663177a232539910dbb9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalPredual.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.Commutator.CoefficientForm2 +import OAI.Analysis.Commutator.FiniteStrongTest +import OAI.Analysis.Commutator.FiniteTestHahnBanach + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter ContinuousLinearMapWOT + +open scoped Topology InnerProductSpace + +namespace Kadison.NormalPredual + +open FiniteStrongTest + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def coefficient (M : VonNeumannAlgebra H) (v : ℕ → H) (N : ℕ) + (y : PiLp 2 (fun _ : Fin N => H)) : StrongDual ℂ M := + (innerSL ℂ y).comp (testMap M v N) + +def finiteTests (M : VonNeumannAlgebra H) (v : ℕ → H) : Set (StrongDual ℂ M) := + ⋃ N : ℕ,Set.range (coefficient M v N) + +lemma finiteTests_separable [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (v : ℕ → H) : TopologicalSpace.IsSeparable (finiteTests M v) := by + apply TopologicalSpace.IsSeparable.iUnion + intro N + apply TopologicalSpace.isSeparable_range + exact (innerSL ℂ).continuous.clm_comp_const (testMap M v N) + +theorem mem_closure_of_strong_null (M : VonNeumannAlgebra H) (v : ℕ → H) + (hv : DenseRange v) (f : StrongDual ℂ M) + (hf : ∀ T : ℕ → M,(∀ n,‖T n‖≤1) → + (∀ x,Tendsto (fun n => (T n : H →L[ℂ] H) x) atTop (𝓝 0)) → + Tendsto (fun n => f (T n)) atTop (𝓝 0)) : + f∈closure (finiteTests M v) := by + apply Metric.mem_closure_iff.mpr + intro ε hε + obtain ⟨N,hN⟩ := exists_test M v hv f hf (ε/2) (by positivity) + obtain ⟨ψ,hψ⟩ := FiniteTestHahnBanach.exists_approx_comp f (testMap M v N) + (by positivity : (0:ℝ)<ε/2) (by positivity : (0:ℝ)<1/((N:ℝ)+1)) (by + intro a ha htest + apply hN a ha + intro j + exact (PiLp.norm_apply_le (testMap M v N a) j).trans htest) + let y := (InnerProductSpace.toDual ℂ (PiLp 2 (fun _ : Fin N => H))).symm ψ + have he : coefficient M v N y=ψ.comp (testMap M v N) := by + apply ContinuousLinearMap.ext + intro a + change inner ℂ ((InnerProductSpace.toDual ℂ (PiLp 2 (fun _ : Fin N => H))).symm ψ) + (testMap M v N a)=ψ (testMap M v N a) + exact InnerProductSpace.toDual_symm_apply + refine ⟨coefficient M v N y,Set.mem_iUnion.mpr ⟨N,Set.mem_range_self y⟩,?_⟩ + rw [he,dist_eq_norm] + exact hψ.trans_lt (by linarith) + +def BoundedWOTContinuous (M : VonNeumannAlgebra H) (f : StrongDual ℂ M) : Prop := + ∀ C : ℝ,Continuous (fun a : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} => + f ⟨a.val.toCLM,a.property.1⟩) + +lemma coefficient_normal (M : VonNeumannAlgebra H) (v : ℕ → H) (N : ℕ) + (y : PiLp 2 (fun _ : Fin N => H)) : BoundedWOTContinuous M (coefficient M v N y) := by + intro C + change Continuous (fun a : {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} => + inner ℂ y (testMap M v N ⟨a.val.toCLM,a.property.1⟩)) + simp_rw [PiLp.inner_apply,testMap_apply] + apply continuous_finsetSum + intro j _ + exact ContinuousLinearMapWOT.continuous_inner_apply continuous_subtype_val (v j) (y j) + +theorem normal_of_mem_closure (M : VonNeumannAlgebra H) (v : ℕ → H) + {f : StrongDual ℂ M} (hf : f∈closure (finiteTests M v)) : BoundedWOTContinuous M f := by + obtain ⟨g,hg,hlim⟩ := mem_closure_iff_seq_limit.mp hf + intro C + let D := {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} + let a (T : D) : M := ⟨T.val.toCLM,T.property.1⟩ + have hn : Tendsto (fun n => ‖g n-f‖) atTop (𝓝 0) := by + simpa only [sub_self,norm_zero] using (hlim.sub (tendsto_const_nhds (x:=f))).norm + have hu : TendstoUniformly (fun n (T:D) => g n (a T)) (fun T => f (a T)) atTop := by + apply Metric.tendstoUniformly_iff.mpr + intro ε hε + have hev := hn.eventually_lt_const (by positivity : (0:ℝ)<ε/(|C|+1)) + filter_upwards [hev] with n hn + intro T + have ha : ‖a T‖≤|C|+1 := (show ‖a T‖≤C from T.property.2).trans + (by linarith [le_abs_self C]) + have hb : ‖(g n-f) (a T)‖≤‖g n-f‖*(|C|+1) := + ((g n-f).le_opNorm (a T)).trans (mul_le_mul_of_nonneg_left ha (norm_nonneg _)) + have hh : ‖g n-f‖*(|C|+1)<ε := (lt_div_iff₀ (by positivity : (0:ℝ)< |C|+1)).mp hn + rw [dist_eq_norm,norm_sub_rev] + exact hb.trans_lt hh + apply hu.continuous + apply Filter.Eventually.frequently + apply Filter.Eventually.of_forall + intro n + obtain ⟨N,y,hy⟩ := Set.mem_iUnion.mp (hg n) + rw [←hy] + exact coefficient_normal M v N y C + +end Kadison.NormalPredual + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalRelativeCommutant.lean b/lean/OAI/Analysis/Commutator/NormalRelativeCommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..f6b08f69e3b7e11906b2af079a940952731944d0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalRelativeCommutant.lean @@ -0,0 +1,169 @@ +import Mathlib +import OAI.Analysis.Commutator.ConvexIsometryFix +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.NormalRelativeCommutant + +open TracialGNS NormalGNS + +variable {H D : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [CStarAlgebra D] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (π : D →⋆ₐ[ℂ] M) + +def liftedUnitary (u : unitary D) : unitary M := ⟨π (u:D), Unitary.map_mem π u.property⟩ + +def orbit (a : M) : Set τ.GNS := + Set.range (fun u : unitary D => algebraVector τ (π (u:D)*a*star (π (u:D)))) + +lemma orbit_self (a : M) : algebraVector τ a∈orbit M τ π a := by + refine ⟨1,?_⟩ + simp + +lemma conjugation_orbit (a : M) (u : unitary D) : + ∀ x∈orbit M τ π a, conjugation τ hτ (liftedUnitary M π u) x∈orbit M τ π a := by + rintro x ⟨v,rfl⟩ + refine ⟨u*v,?_⟩ + simp only [algebraVector_apply,conjugation_coe,liftedUnitary,Submonoid.coe_mul, + map_mul,star_mul,mul_assoc] + +lemma vector_injective (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) : + Function.Injective (algebraVector τ) := by + intro a b hab + apply sub_eq_zero.mp + apply hfaith + have hv : algebraVector τ (a-b)=0 := by rw [map_sub,hab,sub_self] + rw [←inner_algebraVector,hv,inner_zero_left] + +lemma vector_unitball_convex : + Convex ℝ {x : τ.GNS | ∃ a : M, ‖a‖≤1 ∧ algebraVector τ a=x} := by + have hh := (convex_closedBall (0:M) 1).linear_image ((algebraVector τ).restrictScalars ℝ) + simpa only [Metric.closedBall,dist_zero_right,LinearMap.coe_restrictScalars,Set.mem_ofPred_eq, + Set.image,exists_prop] using hh + +lemma hull_bounded (hnormal : BoundedWOTContinuous M τ) (a : M) (ha : ‖a‖≤1) : + closedConvexHull ℝ (orbit M τ π a) ⊆ + {x : τ.GNS | ∃ b : M, ‖b‖≤1 ∧ algebraVector τ b=x} := by + apply closedConvexHull_min _ (vector_unitball_convex M τ) (vector_unitball_isClosed M τ hnormal) + rintro x ⟨u,rfl⟩ + refine ⟨π (u:D)*a*star (π (u:D)),?_,rfl⟩ + have hn : ‖π (u:D)*a*star (π (u:D))‖=‖a‖ := by + exact (CStarRing.norm_mul_coe_unitary _ (star (liftedUnitary M π u))).trans + (CStarRing.norm_coe_unitary_mul (liftedUnitary M π u) a) + rwa [hn] + +include hτ in +lemma hull_trace (a : M) : + ∀ x∈closedConvexHull ℝ (orbit M τ π a), inner ℂ (vacuum τ) x=τ a := by + apply closedConvexHull_min + · rintro x ⟨u,rfl⟩ + change inner ℂ (vacuum τ) (algebraVector τ (π (u:D)*a*star (π (u:D))))=τ a + rw [inner_vacuum_algebraVector,hτ,←mul_assoc] + have hu : star (π (u:D))*π (u:D)=1 := (liftedUnitary M π u).property.1 + rw [hu,one_mul] + · exact (convex_singleton (τ a)).linear_preimage ((innerSL ℂ (vacuum τ)).toLinearMap.restrictScalars ℝ) + · exact isClosed_eq (continuous_const.inner continuous_id) continuous_const + +lemma commutes_of_fixed (b : M) (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfix : ∀ u : unitary D, + conjugation τ hτ (liftedUnitary M π u) (algebraVector τ b)=algebraVector τ b) : + ∀ a : D, π a*b=b*π a := by + have hu (u : unitary D) : π (u:D)*b=b*π (u:D) := by + have hh0 := hfix u + rw [algebraVector_apply,conjugation_coe] at hh0 + have he : π (u:D)*b*star (π (u:D))=b := vector_injective M τ hfaith hh0 + have hh := congrArg (fun x : M => x*π (u:D)) he + have hut : star (π (u:D))*π (u:D)=1 := (liftedUnitary M π u).property.1 + simpa only [mul_assoc,hut,mul_one] using hh + intro a + have ha : a∈Submodule.span ℂ (unitary D:Set D) := by rw [CStarAlgebra.span_unitary]; trivial + induction ha using Submodule.span_induction with + | mem a ha => exact hu ⟨a,ha⟩ + | zero => simp + | add a b ha hb h1 h2 => simp only [map_add,add_mul,mul_add,h1,h2] + | smul c a ha h1 => simp only [map_smul,smul_mul_assoc,mul_smul_comm,h1] + +include hτ in +theorem scalar_mem_hull_contraction + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) (ha : ‖a‖≤1) : + (τ a) • vacuum τ∈closedConvexHull ℝ (orbit M τ π a) := by + obtain ⟨z,hz,hfix⟩ := ConvexIsometry.exists_fixed (closedConvexHull ℝ (orbit M τ π a)) + ⟨algebraVector τ a,subset_closedConvexHull (orbit_self M τ π a)⟩ + isClosed_closedConvexHull convex_closedConvexHull + obtain ⟨b,_,hb⟩ := hull_bounded M τ π hnormal a ha hz + have hf : ∀ u : unitary D, + conjugation τ hτ (liftedUnitary M π u) (algebraVector τ b)=algebraVector τ b := by + intro u + rw [hb] + exact hfix _ (ConvexIsometry.maps_closedConvexHull _ _ (conjugation_orbit M τ hτ π a u)) + obtain ⟨c,hc⟩ := hirr b (commutes_of_fixed M τ hτ π b hfaith hf) + have htc : τ b=c := by rw [hc,Algebra.algebraMap_eq_smul_one,map_smul,hone,smul_eq_mul,mul_one] + have hta : τ b=τ a := by rw [←inner_vacuum_algebraVector,hb]; exact hull_trace M τ hτ π a z hz + have hz' : z=(τ a) • vacuum τ := by + rw [←hb,hc,Algebra.algebraMap_eq_smul_one,map_smul,←hta,htc] + rfl + rwa [hz'] at hz + +include hτ in +theorem scalar_distance_le + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) (ha : ‖a‖≤1) (c : ℝ) + (hc : ∀ u : unitary D, + ‖algebraVector τ (π (u:D)*a*star (π (u:D))-a)‖≤c) : + ‖algebraVector τ (a-algebraMap ℂ M (τ a))‖≤c := by + have hh : closedConvexHull ℝ (orbit M τ π a) ⊆ + Metric.closedBall (algebraVector τ a) c := by + apply closedConvexHull_min _ (convex_closedBall _ _) Metric.isClosed_closedBall + rintro x ⟨u,rfl⟩ + simpa only [Metric.mem_closedBall,dist_eq_norm,map_sub] using hc u + have hm := hh (scalar_mem_hull_contraction M τ hτ π hnormal hfaith hone hirr a ha) + rw [Metric.mem_closedBall,dist_comm,dist_eq_norm] at hm + simpa only [map_sub,Algebra.algebraMap_eq_smul_one,map_smul,algebraVector_apply,vacuum] using hm + +include hτ in +theorem exists_unitary_witness + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (a : M) (ha : ‖a‖≤1) : + ∃ u : unitary D, + ‖algebraVector τ (a-algebraMap ℂ M (τ a))‖≤ + 2*‖algebraVector τ (π (u:D)*a*star (π (u:D))-a)‖ := by + by_cases hz : ‖algebraVector τ (a-algebraMap ℂ M (τ a))‖=0 + · exact ⟨1,by rw [hz]; positivity⟩ + by_contra hn + push Not at hn + have hb : ∀ u : unitary D, + ‖algebraVector τ (π (u:D)*a*star (π (u:D))-a)‖≤ + ‖algebraVector τ (a-algebraMap ℂ M (τ a))‖/2 := by + intro u + have hi := hn u + linarith + have hh := scalar_distance_le M τ hτ π hnormal hfaith hone hirr a ha _ hb + have hp := (norm_nonneg (algebraVector τ (a-algebraMap ℂ M (τ a)))).lt_of_ne' hz + linarith + +end Kadison.NormalRelativeCommutant + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalRepresentationColumns.lean b/lean/OAI/Analysis/Commutator/NormalRepresentationColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..1c34e82e881e93356be173af594e33892f80a995 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalRepresentationColumns.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.BiprodLinkColumn +import OAI.Analysis.Commutator.NormalRepresentationLinks +import OAI.Analysis.Commutator.OperatorAmplification +import OAI.Analysis.Commutator.StandardTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.NormalRepresentation + +open HilbertBiprod PartialIsometryOrder BiprodLinkColumn OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hnormal : NormalGNS.BoundedWOTContinuous M τ) + +lemma link_intertwines (v : Intertwiner (diagonalAlgebra M τ hnormal).commutant) (a : M) : + (component _ v).comp (a:H →L[ℂ] H)=(τ.gnsStarAlgHom a).comp (component _ v) := by + apply component_intertwines _ M.toStarSubalgebra.subtype τ.gnsStarAlgHom v a + have hv : star v.val ∈ (diagonalAlgebra M τ hnormal).commutant := + (diagonalAlgebra M τ hnormal).commutant.star_mem' v.mem + have ha : block (a:H →L[ℂ] H) (τ.gnsStarAlgHom a)∈diagonalAlgebra M τ hnormal := by + exact ⟨a,rfl⟩ + rw [←SetLike.mem_coe,VonNeumannAlgebra.coe_commutant] at hv + exact hv _ ha + +variable (S : Set (Intertwiner (diagonalAlgebra M τ hnormal).commutant)) + +lemma finiteColumn_intertwines (s : Finset S) (a : M) : + (finiteColumn _ S s).comp (a:H →L[ℂ] H)= + (diagonal (H:=τ.GNS) s (τ.gnsStarAlgHom a)).comp (finiteColumn _ S s) := by + classical + ext x i + exact congrArg (fun T : H →L[ℂ] τ.GNS => T x) (link_intertwines M τ hnormal i.val.val a) + +lemma diagonal_representation_injective (ι : Type*) [Fintype ι] [Nonempty ι] + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) : + Function.Injective ((diagonal (H:=τ.GNS) ι).comp τ.gnsStarAlgHom) := by + classical + intro a b hab + apply NormalGNS.gns_injective M τ hfaith + let i : ι := Classical.choice (inferInstance : Nonempty ι) + ext x + have h := congrArg (fun T : SumSpace (H:=τ.GNS) ι →L[ℂ] SumSpace (H:=τ.GNS) ι => + T (single ι i x) i) hab + simpa only [StarAlgHom.comp_apply,diagonal_apply,single_apply,ite_true] using h + +end Kadison.NormalRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalRepresentationLinks.lean b/lean/OAI/Analysis/Commutator/NormalRepresentationLinks.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d9161ba104390232bacdcb7e5d37843a92492ce --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalRepresentationLinks.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Commutator.DiagonalBlockCommutant +import OAI.Analysis.Commutator.NormalBiprodGNS +import OAI.Analysis.Commutator.OrthogonalLinkFamily +import OAI.Analysis.Commutator.RepresentedFactorTransport +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.NormalRepresentation + +open HilbertBiprod PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma gns_nontrivial (h1 : τ 1=1) : Nontrivial τ.GNS := by + let v := TracialGNS.algebraVector τ (1:M) + have hv : inner ℂ v v=1 := by + rw [TracialGNS.inner_algebraVector] + simpa using h1 + have hne : v≠0 := by + intro h + rw [h,inner_zero_left] at hv + exact zero_ne_one hv + exact ⟨⟨v,0,hne⟩⟩ + +def diagonalAlgebra (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + VonNeumannAlgebra (Space H τ.GNS) := + BicommutantRange.ofStarHom (A:=M) (H:=Space H τ.GNS) + (diagHom (A:=M) (H:=H) (G:=τ.GNS) M.toStarSubalgebra.subtype τ.gnsStarAlgHom) + (NormalOperatorHom.diagonal_gns_range M τ hnormal) + +lemma diagonal_factor (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hM : FactorCorner.IsFactor M) : FactorCorner.IsFactor (diagonalAlgebra M τ hnormal) := + FactorCorner.image_factor M hM _ + (diagHom_injective M.toStarSubalgebra.subtype τ.gnsStarAlgHom Subtype.val_injective) + (NormalOperatorHom.diagonal_gns_range M τ hnormal) + +lemma left_mem_commutant (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + left (H:=H) (G:=τ.GNS)∈(diagonalAlgebra M τ hnormal).commutant := + left_mem_diagonal_commutant (A:=M) (H:=H) (G:=τ.GNS) + M.toStarSubalgebra.subtype τ.gnsStarAlgHom (NormalOperatorHom.diagonal_gns_range M τ hnormal) + +lemma right_mem_commutant (hnormal : NormalGNS.BoundedWOTContinuous M τ) : + right (H:=H) (G:=τ.GNS)∈(diagonalAlgebra M τ hnormal).commutant := + right_mem_diagonal_commutant (A:=M) (H:=H) (G:=τ.GNS) + M.toStarSubalgebra.subtype τ.gnsStarAlgHom (NormalOperatorHom.diagonal_gns_range M τ hnormal) + +theorem exists_orthogonal_links (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hM : FactorCorner.IsFactor M) (h1 : τ 1=1) : + ∃ S : Set (Link (diagonalAlgebra M τ hnormal).commutant + (right (H:=H) (G:=τ.GNS)) left), + OrthogonalLinks _ _ _ S ∧ (familySpace _ _ _ S).starProjection=left := by + let : Nontrivial τ.GNS := gns_nontrivial M τ h1 + obtain ⟨S,hS⟩ := exists_maximal_orthogonalLinks (diagonalAlgebra M τ hnormal).commutant + (right (H:=H) (G:=τ.GNS)) left + refine ⟨S,hS.1,?_⟩ + exact maximal_family_spans _ _ _ + (FactorCorner.commutant_factor _ (diagonal_factor M τ hnormal hM)) + (right_mem_commutant M τ hnormal) (left_mem_commutant M τ hnormal) + right_projection left_projection right_ne_zero S hS + +end Kadison.NormalRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalSubalgebra.lean b/lean/OAI/Analysis/Commutator/NormalSubalgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..b03d123197670b40ca3fa6d4eb5aebf00d5787e7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalSubalgebra.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology InnerProductSpace + +namespace Kadison.NormalSubalgebra + +open TracialGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M N : VonNeumannAlgebra H) (hNM : N≤M) + +def inclusion : N →⋆ₐ[ℂ] M := StarSubalgebra.inclusion hNM + +@[simp] lemma inclusion_apply (a : N) : (inclusion M N hNM a:H →L[ℂ] H)=(a:H →L[ℂ] H) := rfl + +variable (τ : M →ₚ[ℂ] ℂ) + +def trace : N →ₚ[ℂ] ℂ where + toLinearMap := τ.toLinearMap.comp (inclusion M N hNM).toLinearMap + monotone' := fun _ _ h => τ.monotone h + +@[simp] lemma trace_apply (a : N) : trace M N hNM τ a=τ (inclusion M N hNM a) := rfl + +lemma normal (hτ : NormalGNS.BoundedWOTContinuous M τ) : + NormalGNS.BoundedWOTContinuous N (trace M N hNM τ) := by + intro C + let f : {T : H →WOT[ℂ] H // T.toCLM∈N ∧ ‖T.toCLM‖≤C} → + {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} := + fun a => ⟨a.val,hNM a.property.1,a.property.2⟩ + have hf : Continuous f := continuous_subtype_val.subtype_mk _ + exact (hτ C).comp hf + +lemma tracial (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (a b : N) : + trace M N hNM τ (a*b)=trace M N hNM τ (b*a) := by + simpa only [trace_apply,map_mul] using hτ (inclusion M N hNM a) (inclusion M N hNM b) + +lemma one (hone : τ 1=1) : trace M N hNM τ 1=1 := by rw [trace_apply,map_one,hone] + +lemma faithful (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (a : N) + (ha : trace M N hNM τ (star a*a)=0) : a=0 := by + have he := hfaith (inclusion M N hNM a) (by simpa only [trace_apply,map_mul,map_star] using ha) + apply Subtype.ext + exact congrArg (fun x : M => (x : H →L[ℂ] H)) he + +lemma vector_norm (a : N) : + ‖algebraVector (trace M N hNM τ) a‖=‖algebraVector τ (inclusion M N hNM a)‖ := by + have hi : inner ℂ (algebraVector (trace M N hNM τ) a) (algebraVector (trace M N hNM τ) a)= + inner ℂ (algebraVector τ (inclusion M N hNM a)) (algebraVector τ (inclusion M N hNM a)) := by + exact (inner_algebraVector (trace M N hNM τ) a a).trans + (inner_algebraVector τ (inclusion M N hNM a) (inclusion M N hNM a)).symm + have hr := congrArg (RCLike.re : ℂ → ℝ) hi + have hs := (norm_sq_eq_re_inner (𝕜:=ℂ) (algebraVector (trace M N hNM τ) a)).trans + (hr.trans (norm_sq_eq_re_inner (𝕜:=ℂ) (algebraVector τ (inclusion M N hNM a))).symm) + exact (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp hs + +end Kadison.NormalSubalgebra + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalTraceProjection.lean b/lean/OAI/Analysis/Commutator/NormalTraceProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..07f3970a0f6746e742858720094343f4470c93bf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalTraceProjection.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.StandardTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.NormalGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (hnormal : BoundedWOTContinuous M τ) + +variable (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma projection_subtype {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) : + IsStarProjection (⟨p,hpM⟩ : M) := by + constructor + · exact Subtype.ext hp.isIdempotentElem.eq + · exact Subtype.ext hp.isSelfAdjoint.star_eq + +include hfaith in +lemma gns_projection_iff (a : M) : + IsStarProjection (τ.gnsStarAlgHom a) ↔ IsStarProjection a := by + constructor + · intro h + constructor + · apply gns_injective M τ hfaith + simpa only [map_mul τ.gnsStarAlgHom a a] using h.isIdempotentElem.eq + · apply gns_injective M τ hfaith + simpa only [map_star τ.gnsStarAlgHom a] using h.isSelfAdjoint.star_eq + · exact fun h => h.map τ.gnsStarAlgHom + +include hfaith in +lemma gns_projection_le_iff {a b : M} (ha : IsStarProjection a) (hb : IsStarProjection b) : + τ.gnsStarAlgHom a ≤ τ.gnsStarAlgHom b ↔ a≤b := by + have hsource : a≤b ↔ a*b=a := ha.le_iff_mul_eq_left hb + have htarget : τ.gnsStarAlgHom a ≤ τ.gnsStarAlgHom b ↔ + τ.gnsStarAlgHom a * τ.gnsStarAlgHom b = τ.gnsStarAlgHom a := + (ha.map τ.gnsStarAlgHom).le_iff_mul_eq_left (hb.map τ.gnsStarAlgHom) + constructor + · intro hab + exact hsource.mpr ((gns_injective M τ hfaith) + ((map_mul τ.gnsStarAlgHom a b).trans (htarget.mp hab))) + · intro hab + exact htarget.mpr ((map_mul τ.gnsStarAlgHom a b).symm.trans + (congrArg τ.gnsStarAlgHom (hsource.mp hab))) + +include hfaith in +theorem gns_noMinimal (hM : DiffuseProjection.HasNoMinimalProjections M) : + DiffuseProjection.HasNoMinimalProjections (algebra M τ hτ hnormal) := by + let representation := τ.gnsStarAlgHom + intro p hpM hp hpn + obtain ⟨a,rfl⟩ := hpM + have ha := (gns_projection_iff M τ hfaith a).mp hp + have han : (a : H →L[ℂ] H)≠0 := by + intro hz + have haz : a=0 := Subtype.ext hz + exact hpn (by rw [haz,map_zero]) + have hap : IsStarProjection (a : H →L[ℂ] H) := ha.map M.toStarSubalgebra.subtype + obtain ⟨q,hqM,hq,hqn,hqa,hqle⟩ := hM a a.property hap han + let b : M := ⟨q,hqM⟩ + have hb : IsStarProjection b := projection_subtype M hqM hq + have hble : representation b ≤ representation a := + (gns_projection_le_iff M τ hfaith hb ha).mpr hqle + refine ⟨representation b,⟨b,rfl⟩,hb.map representation,?_,?_,hble⟩ + · intro hz + have hbz : b=0 := (gns_injective M τ hfaith) + (hz.trans (map_zero representation).symm) + exact hqn (congrArg Subtype.val hbz) + · intro he + exact hqa (congrArg Subtype.val ((gns_injective M τ hfaith) he)) + +include hτ hnormal hfaith in +theorem exists_prescribed_projection_trace + (hM : DiffuseProjection.HasNoMinimalProjections M) + (e : M) (he : IsStarProjection e) {t : ℝ} (ht : 0≤t) (hte : t≤(τ e).re) : + ∃ p : M, IsStarProjection p ∧ p≤e ∧ (τ p).re=t := by + have htG : t≤(trace M τ (τ.gnsStarAlgHom e)).re := by rwa [trace_gns] + obtain ⟨p,⟨a,ha⟩,hp,hpe,hpt⟩ := DiffuseProjection.exists_prescribed_trace + (algebra M τ hτ hnormal) (trace M τ) + (gns_noMinimal M τ hτ hnormal hfaith hM) + (Complex.continuous_re.comp (trace_continuous M τ)) + (show τ.gnsStarAlgHom e ∈ algebra M τ hτ hnormal from ⟨e,rfl⟩) + (he.map τ.gnsStarAlgHom) ht htG + subst p + have hpa := (gns_projection_iff M τ hfaith a).mp hp + refine ⟨a,hpa,(gns_projection_le_iff M τ hfaith hpa he).mp hpe,?_⟩ + change (trace M τ (τ.gnsStarAlgHom a)).re=t at hpt + simpa only [trace_gns] using hpt + +include hfaith in +lemma projection_zero_of_trace_re_zero (e : M) (he : IsStarProjection e) + (ht : (τ e).re=0) : e=0 := by + apply hfaith + rw [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq] + have hn := τ.map_nonneg he.nonneg + exact Complex.ext ht hn.2.symm + +include hτ hnormal hfaith in +theorem exists_projection_partition (hM : DiffuseProjection.HasNoMinimalProjections M) + (n : ℕ) (e : M) (he : IsStarProjection e) {t : ℝ} (ht : 0≤t) + (htrace : (τ e).re=(n:ℝ)*t) : + ∃ p : Fin n → M, (∀ i, IsStarProjection (p i) ∧ p i≤e ∧ (τ (p i)).re=t) ∧ + (∀ i j, i≠j → p i*p j=0) ∧ ∑ i,p i=e := by + induction n generalizing e with + | zero => + have hez : e=0 := projection_zero_of_trace_re_zero M τ hfaith e he (by simpa using htrace) + subst e + refine ⟨Fin.elim0,?_,?_,?_⟩ + · exact fun i => Fin.elim0 i + · exact fun i => Fin.elim0 i + · simp + | succ n ih => + have hte : t≤(τ e).re := by rw [htrace,Nat.cast_succ]; nlinarith [Nat.cast_nonneg (α:=ℝ) n] + obtain ⟨p,hp,hple,hpt⟩ := exists_prescribed_projection_trace M τ hτ hnormal hfaith hM e he ht hte + have her : IsStarProjection (e-p) := (hp.le_iff_sub he).mp hple + have htr : (τ (e-p)).re=(n:ℝ)*t := by + rw [map_sub,Complex.sub_re,htrace,hpt,Nat.cast_succ] + ring + obtain ⟨q,hq,hqq,hqsum⟩ := ih (e-p) her htr + have hpq : ∀ i, p*q i=0 := by + intro i + have hfix := ((hq i).1.le_iff_mul_eq_right her).mp (hq i).2.1 + calc + _=p*((e-p)*q i) := by rw [hfix] + _=0 := by rw [←mul_assoc,mul_sub,(hp.le_iff_mul_eq_left he).mp hple,hp.isIdempotentElem.eq,sub_self,zero_mul] + have hqp : ∀ i, q i*p=0 := by + intro i + simpa only [star_mul,hp.isSelfAdjoint.star_eq,(hq i).1.isSelfAdjoint.star_eq,star_zero] using congrArg star (hpq i) + refine ⟨Fin.cons p q,?_,?_,?_⟩ + · intro i + refine Fin.cases ?_ (fun j => ?_) i + · exact ⟨hp,hple,hpt⟩ + · exact ⟨(hq j).1,(hq j).2.1.trans (sub_le_self e hp.nonneg),(hq j).2.2⟩ + · intro i j hij + revert hij + refine Fin.cases ?_ (fun i => ?_) i + · refine Fin.cases ?_ (fun j _ => hpq j) j + exact fun h => (h rfl).elim + · refine Fin.cases (fun _ => hqp i) (fun j h => hqq i j (by simpa using h)) j + · rw [Fin.sum_univ_succ] + simp only [Fin.cons_zero,Fin.cons_succ,hqsum] + abel + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalTracedFactorMain.lean b/lean/OAI/Analysis/Commutator/NormalTracedFactorMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ab8f48ecb9a702ba2a279fcb26377b534c77282 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalTracedFactorMain.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Commutator.AmplifiedStrongLimit +import OAI.Analysis.Commutator.BiprodLinkEmpty +import OAI.Analysis.Commutator.FiniteStandardCompression +import OAI.Analysis.Commutator.NormalRepresentationColumns + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.NormalRepresentation + +open HilbertBiprod PartialIsometryOrder BiprodLinkColumn IntertwinerCompression + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (τ : M →ₚ[ℂ] ℂ) + +theorem traced_factor_bound [TopologicalSpace.SeparableSpace τ.GNS] + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (h : ℕ) (hh : 1≤h) (Y : H →L[ℂ] H) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈M) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + (3122*commutatorSeminorm M Y)*‖matrixOperator h X‖ := by + classical + let N := (diagonalAlgebra M τ hnormal).commutant + obtain ⟨S,hS,hspan⟩ := exists_orthogonal_links M τ hnormal hfac hone + let P : Finset S → H →L[ℂ] H := compression N S + have hP (s : Finset S) : ‖P s‖≤1 := compression_norm_le N S hS s + have hstrong (x : H) : Tendsto (fun s : Finset S => P s x) atTop (𝓝 x) := + compression_tendsto N S hS hspan x + have hbound (s : Finset S) : + ‖diagonalAmplification h (P s*Y*P s)*matrixOperator h X- + matrixOperator h X*diagonalAmplification h (P s*Y*P s)‖≤ + (3122*commutatorSeminorm M Y)*‖matrixOperator h X‖ := by + rcases s.eq_empty_or_nonempty with hs|hs + · subst s + have hz : P ∅=0 := compression_empty N S + rw [hz,zero_mul,mul_zero] + have hd : diagonalAmplification h (0:H →L[ℂ] H)=0 := by ext x i; rfl + rw [hd,zero_mul,mul_zero,sub_zero,norm_zero] + exact mul_nonneg (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg M Y)) (norm_nonneg _) + · let : Nonempty s := ⟨⟨hs.choose,hs.choose_spec⟩⟩ + have hc := column_norm_le N S hS s + have hi := finiteColumn_intertwines M τ hnormal S s + have hb := finite_standard_compression_bound M τ s hτ hnormal hfaith hone hfac hdiffuse + (finiteColumn N S s) hc hi h hh Y X hX + have hsq : (finiteColumn N S s).adjoint.comp (finiteColumn N S s)=P s := + column_square N S s + exact (congrArg (fun Q : H →L[ℂ] H => + ‖diagonalAmplification h (Q*Y*Q)*matrixOperator h X- + matrixOperator h X*diagonalAmplification h (Q*Y*Q)‖ ≤ + (3122*commutatorSeminorm M Y)*‖matrixOperator h X‖) hsq).mp hb + exact StrongContractionLimit.commutator_bound_limit + (fun s : Finset S => P s*Y*P s) Y + (StrongContractionLimit.sandwich_tendsto P hP hstrong Y) h X + ((3122*commutatorSeminorm M Y)*‖matrixOperator h X‖) + (mul_nonneg (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg M Y)) (norm_nonneg _)) + (Filter.Eventually.of_forall hbound) + +end Kadison.NormalRepresentation + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalizedTowerFreePosition.lean b/lean/OAI/Analysis/Commutator/NormalizedTowerFreePosition.lean new file mode 100644 index 0000000000000000000000000000000000000000..dac312e15ef05ea07b4f6a2e9870d8eaf028d4cf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalizedTowerFreePosition.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixIndexEquiv +import OAI.Analysis.Commutator.RelativeEquivFreePosition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.TracialSequence + +open MatrixTower + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (M R : VonNeumannAlgebra H) [Nontrivial M] (hRM : R ≤ M) + (e : A ≃⋆ₐ[ℂ] M) (j : R →⋆ₐ[ℂ] A) + (hj : ∀ q,e (j q)=NormalSubalgebra.inclusion M R hRM q) + +variable (τ : A →ₚ[ℂ] ℂ) (σ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (E : ℕ → Stage M) (hE : Monotone (fun n => (E n).hom.range)) + +include hRM hj hE in +theorem exists_freeCornerPosition_of_equiv_stages [TopologicalSpace.SeparableSpace σ.GNS] + (htrace : ∀ a,σ (e a)=τ a) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hσ : ∀ a b : M,σ (a*b)=σ (b*a)) + (hω : (ω : Filter ℕ) ≤ atTop) + (hnormal : NormalGNS.BoundedWOTContinuous M σ) + (hfaith : ∀ a : M,σ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n a,(E n).hom a*b=b*(E n).hom a) → + ∃ c : ℂ,b=algebraMap ℂ M c) + (hstage : ∀ n a,((E n).hom a : H →L[ℂ] H)∈R) + (hgrow : Tendsto (fun n => (Fintype.card (E n).I:ℝ)) atTop atTop) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) : + Nonempty (FreeCornerPosition τ ω R j) := by + apply exists_freeCornerPosition_of_equiv_tower M R hRM e j hj τ σ ω + (normalizedSize M E) (normalizedStage M E) (normalizedInclusion M E hE) + htrace hτ hσ hω hnormal hfaith hone _ _ + (fun n m h a => normalizedInclusion_commutes M E hE h a) _ hdiffuse + · intro b hb + apply hirr b + intro n a + have hh := hb n ((matrixIndexEquiv (normalizedIndex M E n)).symm a) + change (E n).hom ((matrixIndexEquiv (normalizedIndex M E n)) + ((matrixIndexEquiv (normalizedIndex M E n)).symm a))*b= + b*(E n).hom ((matrixIndexEquiv (normalizedIndex M E n)) + ((matrixIndexEquiv (normalizedIndex M E n)).symm a)) at hh + simpa only [StarAlgEquiv.apply_symm_apply] using hh + · intro n a + exact hstage n (matrixIndexEquiv (normalizedIndex M E n) a) + · convert hgrow using 1 + ext n + exact_mod_cast normalizedSize_succ M E n + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/NormalizedTrace.lean b/lean/OAI/Analysis/Commutator/NormalizedTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..f6659ec238bc0199398c81ed67f171b7d1ce1a27 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/NormalizedTrace.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionFaithfulFunctional +import OAI.Analysis.Commutator.TraceDimension +import OAI.Analysis.Commutator.DyadicDimensionNormal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.TraceDimension + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +variable (hfac : FactorCorner.IsFactor M) (hd : DiffuseProjection.HasNoMinimalProjections M) + +variable (hfin : IsFiniteAlgebra M) (hone : τ 1=1) + +include hτ hfac hd hfin hone + +theorem positive_faithful (a : M) (ha : 0≤a) (hzero : τ a=0) : a=0 := by + apply ProjectionFaithfulFunctional.positive_eq_zero_of_projection_faithful M τ _ a ha hzero + intro p hp hτp + have he := trace_projection_dimension M τ hτ hfac hd hfin hone p.property hp + rw [hτp,Complex.zero_re] at he + apply Subtype.ext + exact (dimension_eq_zero_iff M hfac hd hfin p.property hp).mp he.symm + +theorem faithful (a : M) (hzero : τ (star a*a)=0) : a=0 := by + have he := positive_faithful M τ hτ hfac hd hfin hone (star a*a) (star_mul_self_nonneg a) hzero + apply norm_eq_zero.mp + have hn := congrArg norm he + rw [CStarRing.norm_star_mul_self,norm_zero] at hn + nlinarith [norm_nonneg a] + +omit [TopologicalSpace.SeparableSpace H] in +lemma projection_value {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) : + τ ⟨p,hpM⟩=(dimension M hfac hd p:ℝ) := by + apply Complex.ext + · exact trace_projection_dimension M τ hτ hfac hd hfin hone hpM hp + · exact (τ.map_nonneg hp.nonneg).2.symm + +theorem projection_tendsto + (p : M) (hp : IsStarProjection (p:H →L[ℂ] H)) (P : ℕ → M) + (hP : ∀ n,IsStarProjection (P n:H →L[ℂ] H)) + (hmono : Monotone (fun n => (P n:H →L[ℂ] H))) + (hPp : ∀ n,(P n:H →L[ℂ] H)≤(p:H →L[ℂ] H)) + (hlim : ∀ x,Tendsto (fun n => (P n:H →L[ℂ] H) x) atTop (𝓝 ((p:H →L[ℂ] H) x))) : + Tendsto (fun n => τ (P n)) atTop (𝓝 (τ p)) := by + have he : ∀ n,τ (P n)=(dimension M hfac hd (P n):ℝ) := fun n => + projection_value M τ hτ hfac hd hfin hone (P n).property (hP n) + simp_rw [he] + rw [projection_value M τ hτ hfac hd hfin hone p.property hp] + exact Complex.continuous_ofReal.continuousAt.tendsto.comp + (dimension_tendsto_of_strong_increasing M hfac hd hfin p.property hp + (fun n => (P n:H →L[ℂ] H)) (fun n => (P n).property) hP hmono hPp hlim) + +end Kadison.TraceDimension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OperatorAmplification.lean b/lean/OAI/Analysis/Commutator/OperatorAmplification.lean new file mode 100644 index 0000000000000000000000000000000000000000..d6ebcf8bc834429fb91e45f3913cc2de11a9844b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OperatorAmplification.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.CyclicMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +abbrev SumSpace := PiLp 2 (fun _ : ι => H) + +def single (i : ι) : H →L[ℂ] SumSpace (H:=H) ι := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => H)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.single ℂ (fun _ : ι => H) i) + +omit [CompleteSpace H] [Fintype ι] in +@[simp] lemma single_apply (i : ι) (x : H) (j : ι) : + single ι i x j=if j=i then x else 0 := by + simp [single] + +def diagonal : (H →L[ℂ] H) →⋆ₐ[ℂ] (SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) where + toFun T := (PiLp.continuousLinearEquiv 2 ℂ (fun _ : ι => H)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun i => T.comp (PiLp.proj 2 (fun _ : ι => H) i))) + map_zero' := by ext x i; simp + map_one' := by ext x i; simp + map_add' _ _ := by ext x i; simp + map_mul' _ _ := by ext x i; simp + commutes' _ := by ext x i; simp [Algebra.algebraMap_eq_smul_one] + map_star' T := by + rw [ContinuousLinearMap.star_eq_adjoint] + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp [PiLp.inner_apply, + ContinuousLinearMap.adjoint_inner_left] + +omit [DecidableEq ι] in +@[simp] lemma diagonal_apply (T : H →L[ℂ] H) (x : SumSpace (H:=H) ι) (i : ι) : + diagonal (H:=H) ι T x i=T (x i) := by simp [diagonal] + +lemma diagonal_single (T : H →L[ℂ] H) (i : ι) (x : H) : + diagonal (H:=H) ι T (single ι i x)=single ι i (T x) := by + ext j + by_cases h : j=i <;> simp [h] + +omit [CompleteSpace H] in +lemma sum_single (x : SumSpace (H:=H) ι) : ∑ i, single ι i (x i)=x := by + ext j + simp + +def entry (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (i j : ι) : H →L[ℂ] H := + (PiLp.proj 2 (fun _ : ι => H) i).comp (T.comp (single ι j)) + +omit [CompleteSpace H] [Fintype ι] in +@[simp] lemma entry_apply (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (i j : ι) (x : H) : entry ι T i j x=T (single ι j x) i := rfl + +omit [CompleteSpace H] in +lemma apply_eq_sum_entries (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (x : SumSpace (H:=H) ι) (i : ι) : T x i=∑ j, entry ι T i j (x j) := by + conv_lhs => rw [←sum_single ι x] + simp + +omit [CompleteSpace H] in +lemma reconstruct (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) : + CyclicColumns.matrixAction (entry ι T)=T := by + ext x i + simpa only [CyclicColumns.matrixAction_apply] using (apply_eq_sum_entries ι T x i).symm + +lemma entry_commutes (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (a : H →L[ℂ] H) (h : diagonal (H:=H) ι a*T=T*diagonal (H:=H) ι a) (i j : ι) : + a*entry ι T i j=entry ι T i j*a := by + ext x + have he := congrArg (fun R : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι => R (single ι j x) i) h + simpa only [mul_apply_eq_comp,diagonal_apply,diagonal_single,entry_apply] using he + +lemma commutes_of_entries (T : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) + (a : H →L[ℂ] H) (h : ∀ i j, a*entry ι T i j=entry ι T i j*a) : + diagonal (H:=H) ι a*T=T*diagonal (H:=H) ι a := by + ext x i + change a (T x i)=T (diagonal (H:=H) ι a x) i + rw [apply_eq_sum_entries ι T x,apply_eq_sum_entries ι T] + simp only [map_sum,diagonal_apply] + apply Finset.sum_congr rfl + intro j _ + exact congrArg (fun R : H →L[ℂ] H => R (x j)) (h i j) + +lemma diagonal_bicommutant (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {T : H →L[ℂ] H} (hT : T ∈ Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) : + diagonal (H:=H) ι T ∈ Set.centralizer (Set.centralizer ((S.map (diagonal (H:=H) ι)) : Set (SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι))) := by + intro R hR + apply (commutes_of_entries ι R T ?_).symm + intro i j + apply (hT _ ?_).symm + intro a ha + exact entry_commutes ι R a (hR (diagonal (H:=H) ι a) ⟨a,ha,rfl⟩) i j + +theorem bicommutant_finite_approx (S : StarSubalgebra ℂ (H →L[ℂ] H)) + {T : H →L[ℂ] H} (hT : T ∈ Set.centralizer (Set.centralizer (S : Set (H →L[ℂ] H)))) + (x : SumSpace (H:=H) ι) (ε : ℝ) (hε : 0<ε) : + ∃ a : H →L[ℂ] H, a∈S ∧ ‖diagonal (H:=H) ι a x-diagonal (H:=H) ι T x‖<ε := by + have h := bicommutant_mem_cyclicSubspace (S.map (diagonal (H:=H) ι)) + (diagonal_bicommutant ι S hT) x + change diagonal (H:=H) ι T x ∈ closure + (orbitSubmodule (S.map (diagonal (H:=H) ι)) x : Set (SumSpace (H:=H) ι)) at h + obtain ⟨y,⟨a,⟨b,hb,hba⟩,hay⟩,hy⟩ := Metric.mem_closure_iff.mp h ε hε + subst a + subst y + refine ⟨b,hb,?_⟩ + rw [dist_eq_norm,norm_sub_rev] at hy + exact hy + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OperatorSystem.lean b/lean/OAI/Analysis/Commutator/OperatorSystem.lean new file mode 100644 index 0000000000000000000000000000000000000000..b6970568fa903b3ff72790ed57cb7dfd0dc24dab --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OperatorSystem.lean @@ -0,0 +1,69 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.OperatorSystem + +variable {A B : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +local instance operatorSystemDecidableEq (ι : Type*) : DecidableEq ι := Classical.decEq ι + +def matrices (S : Submodule ℂ A) (ι : Type*) [Fintype ι] : Submodule ℂ (CStarMatrix ι ι A) where + carrier := {X | ∀ i j,X i j∈S} + zero_mem' := by simp + add_mem' hx hy i j := S.add_mem (hx i j) (hy i j) + smul_mem' c X hX i j := S.smul_mem c (hX i j) + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma matrices_mem (S : Submodule ℂ A) {ι : Type*} [Fintype ι] (X) : + X∈matrices S ι ↔ ∀ i j,X i j∈S := Iff.rfl + +omit [PartialOrder A] [StarOrderedRing A] in +lemma matrices_one (S : Submodule ℂ A) (h1 : (1 : A)∈S) {ι : Type*} [Fintype ι] : + (1 : CStarMatrix ι ι A)∈matrices S ι := by + classical + intro i j + by_cases h : i=j <;> simp [CStarMatrix.one_apply,h,h1] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma matrices_star (S : Submodule ℂ A) (hs : ∀ a∈S,star a∈S) + {ι : Type*} [Fintype ι] (X : CStarMatrix ι ι A) (hX : X∈matrices S ι) : + star X∈matrices S ι := fun i j => hs _ (hX j i) + +def mapMatrix (S : Submodule ℂ A) (f : S →ₗ[ℂ] B) {ι : Type*} [Fintype ι] : + matrices S ι →ₗ[ℂ] CStarMatrix ι ι B where + toFun X := CStarMatrix.ofMatrix (fun i j => f ⟨X.val i j,X.property i j⟩) + map_add' X Y := by + ext i j + change f (⟨X.val i j,X.property i j⟩+⟨Y.val i j,Y.property i j⟩)=_ + exact f.map_add _ _ + map_smul' c X := by + ext i j + change f (c • (⟨X.val i j,X.property i j⟩ : S))=_ + exact f.map_smul c _ + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +@[simp] lemma mapMatrix_apply (S : Submodule ℂ A) (f : S →ₗ[ℂ] B) + {ι : Type*} [Fintype ι] (X : matrices S ι) (i j : ι) : + mapMatrix S f X i j=f ⟨X.val i j,X.property i j⟩ := rfl + +def IsCompletelyPositive (S : Submodule ℂ A) (f : S →ₗ[ℂ] B) : Prop := + ∀ (ι : Type) [Fintype ι] (X : matrices S ι),0 ≤ X.val → 0 ≤ mapMatrix S f X + +end Kadison.OperatorSystem + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrbitFixedTrace.lean b/lean/OAI/Analysis/Commutator/OrbitFixedTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..37d56e4378ada00369023915a0536e7a1e1ef56c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrbitFixedTrace.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Commutator.NormSeparableFixedPoint +import OAI.Analysis.Commutator.OrbitStateHull +import OAI.Analysis.Commutator.UnitaryDualAction + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.OrbitStateHull + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +lemma act_vector (u : unitary M) (x : H) : + u • (vector M x).toWeakDual=(vector M (((u:M):H →L[ℂ] H) x)).toWeakDual := by + apply UnitaryDualAction.weak_ext + intro a + change inner ℂ x ((star ((u:M):H →L[ℂ] H)) (((a:M):H →L[ℂ] H) (((u:M):H →L[ℂ] H) x))) = + inner ℂ (((u:M):H →L[ℂ] H) x) (((a:M):H →L[ℂ] H) (((u:M):H →L[ℂ] H) x)) + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + +lemma orbit_invariant (x : H) : CompactInvariant.Invariant (G:=unitary M) (orbit M x) := by + intro u f hf + obtain ⟨v,hv,rfl⟩ := hf + let w : unitary (H →L[ℂ] H) := ⟨((u:M):H →L[ℂ] H),by + constructor + · exact congrArg (fun a : M => (a:H →L[ℂ] H)) u.property.1 + · exact congrArg (fun a : M => (a:H →L[ℂ] H)) u.property.2⟩ + refine ⟨w*v,M.mul_mem (u:M).property hv,?_⟩ + exact act_vector M u ((v:H →L[ℂ] H) x) + +lemma hull_invariant (x : H) : CompactInvariant.Invariant (G:=unitary M) (hull M x) := by + intro u f hf + obtain ⟨L,hL⟩ := UnitaryDualAction.act_linear u + have hLcont : Continuous L := by + have he : (L : WeakDual ℂ M → WeakDual ℂ M)=(fun f => u • f) := funext hL + rw [he] + exact continuous_const_smul u + have hmap : L '' convexHull ℝ (orbit M x) ⊆ convexHull ℝ (orbit M x) := by + rw [L.image_convexHull] + apply convexHull_mono + rintro _ ⟨g,hg,rfl⟩ + rw [hL] + exact orbit_invariant M x u g hg + have hpre : closure (convexHull ℝ (orbit M x)) ⊆ L ⁻¹' closure (convexHull ℝ (orbit M x)) := + closure_minimal (fun g hg => subset_closure (hmap ⟨g,hg,rfl⟩)) + (isClosed_closure.preimage hLcont) + have he := hpre hf + change L f∈hull M x at he + rwa [hL] at he + +theorem exists_tracial_hull_of_norm_separable (x : H) + (hsep : TopologicalSpace.IsSeparable (WeakDual.toStrongDual '' hull M x)) : + ∃ f : WeakDual ℂ M, f∈hull M x ∧ ∀ a b : M,f (a*b)=f (b*a) := by + let j : WeakDual ℂ M ≃ₗ[ℝ] StrongDual ℂ M := + { toFun := WeakDual.toStrongDual + invFun := StrongDual.toWeakDual + left_inv := fun _ => rfl + right_inv := fun _ => rfl + map_add' := fun _ _ => rfl + map_smul' := fun _ _ => rfl } + have hj : Continuous j.symm := by + apply WeakDual.continuous_of_continuous_eval + intro a + change Continuous (fun f : StrongDual ℂ M => f a) + exact (ContinuousLinearMap.apply ℂ ℂ a).continuous + have hb : ∀ y : StrongDual ℂ M,∀ r : ℝ,IsClosed {f : WeakDual ℂ M | dist (j f) y≤r} := by + intro y r + change IsClosed (WeakDual.toStrongDual ⁻¹' Metric.closedBall y r) + exact WeakDual.isClosed_closedBall y r + obtain ⟨f,hf,hfix⟩ := CompactInvariant.exists_fixed_point j hj hb + (fun u f g => UnitaryDualAction.act_dist u f g) (hull_compact M x) + (hull_nonempty M x) (WeakDualHull.convex_hull (orbit M x)) (hull_invariant M x) hsep + exact ⟨f,hf,UnitaryDualAction.trace_of_fixed f hfix⟩ + +end Kadison.OrbitStateHull + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrbitStateHull.lean b/lean/OAI/Analysis/Commutator/OrbitStateHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..2fab3aad9f80ad75920d0653e142e798531d11da --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrbitStateHull.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.WeakDualHull +import OAI.Analysis.Commutator.VonNeumannCStar +import OAI.Analysis.Commutator.ProjectionDimensionUnitary +import OAI.Analysis.Commutator.DyadicDimensionNormal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.OrbitStateHull + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def vector (x : H) : StrongDual ℂ M := + LinearMap.mkContinuous + { toFun := fun a => inner ℂ x ((a : H →L[ℂ] H) x) + map_add' := by + intro a b + change inner ℂ x ((a : H →L[ℂ] H) x+(b : H →L[ℂ] H) x)=_ + exact inner_add_right _ _ _ + map_smul' := by + intro c a + change inner ℂ x (c • (a : H →L[ℂ] H) x)=c*inner ℂ x ((a : H →L[ℂ] H) x) + exact inner_smul_right _ _ _ } + (‖x‖*‖x‖) (by + intro a + calc + _ ≤ ‖x‖*‖(a : H →L[ℂ] H) x‖ := norm_inner_le_norm _ _ + _ ≤ ‖x‖*(‖a‖*‖x‖) := mul_le_mul_of_nonneg_left ((a : H →L[ℂ] H).le_opNorm x) (norm_nonneg x) + _ = ‖x‖*‖x‖*‖a‖ := by ring) + +@[simp] lemma vector_apply (x : H) (a : M) : + vector M x a=inner ℂ x ((a : H →L[ℂ] H) x) := rfl + +lemma vector_norm (x : H) : ‖vector M x‖≤‖x‖*‖x‖ := + LinearMap.mkContinuous_norm_le _ (mul_self_nonneg _) _ + +lemma vector_nonneg (x : H) {a : M} (ha : 0≤a) : 0≤vector M x a := + (ContinuousLinearMap.nonneg_iff_isPositive.mp ha).inner_nonneg_right x + +def orbit (x : H) : Set (WeakDual ℂ M) := + {f | ∃ u : unitary (H →L[ℂ] H), (u : H →L[ℂ] H)∈M ∧ + f=(vector M ((u : H →L[ℂ] H) x)).toWeakDual} + +def hull (x : H) : Set (WeakDual ℂ M) := WeakDualHull.hull (orbit M x) + +lemma vector_mem_hull (x : H) : (vector M x).toWeakDual∈hull M x := by + apply WeakDualHull.subset_hull + exact ⟨1,M.one_mem,rfl⟩ + +lemma hull_nonempty (x : H) : (hull M x).Nonempty := ⟨_,vector_mem_hull M x⟩ + +lemma hull_compact (x : H) : IsCompact (hull M x) := by + apply WeakDualHull.compact_hull (‖x‖*‖x‖) (mul_self_nonneg _) + rintro f ⟨u,_,rfl⟩ + simpa only [StrongDual.toStrongDual_toWeakDual,Unitary.norm_map] using vector_norm M ((u : H →L[ℂ] H) x) + +lemma hull_norm (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) : + ‖f.toStrongDual‖≤‖x‖*‖x‖ := by + apply WeakDualHull.norm_le (‖x‖*‖x‖) (mul_self_nonneg _) _ hf + rintro g ⟨u,_,rfl⟩ + simpa only [StrongDual.toStrongDual_toWeakDual,Unitary.norm_map] using vector_norm M ((u : H →L[ℂ] H) x) + +lemma hull_one (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) : + f 1=(‖x‖^2 : ℝ) := by + apply WeakDualHull.eval_eq (1 : M) ((‖x‖^2 : ℝ) : ℂ) _ hf + rintro g ⟨u,_,rfl⟩ + change inner ℂ ((u : H →L[ℂ] H) x) ((u : H →L[ℂ] H) x)=_ + rw [inner_self_eq_norm_sq_to_K,Unitary.norm_map,Complex.ofReal_pow] + rfl + +lemma hull_nonneg (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) + {a : M} (ha : 0≤a) : 0≤f a := by + apply WeakDualHull.eval_nonneg a _ hf + rintro g ⟨u,_,rfl⟩ + exact vector_nonneg M _ ha + +def positive (x : H) (f : WeakDual ℂ M) (hf : f∈hull M x) : M →ₚ[ℂ] ℂ where + toLinearMap := f.toStrongDual.toLinearMap + monotone' := by + intro a b hab + apply sub_nonneg.mp + change 0≤f.toStrongDual b-f.toStrongDual a + rw [←map_sub] + exact hull_nonneg M x hf (sub_nonneg.mpr hab) + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (hfac : FactorCorner.IsFactor M) (hd : DiffuseProjection.HasNoMinimalProjections M) + +variable (hfin : IsFiniteAlgebra M) + +include hfac hd hfin + +theorem hull_projection_absolute_continuity (x : H) (ε : ℝ) (hε : 0<ε) : + ∃ δ : ℝ,0<δ ∧ ∀ p : M,IsStarProjection (p : H →L[ℂ] H) → + dimension M hfac hd p<δ → ∀ f∈hull M x,‖f p‖≤ε := by + obtain ⟨δ,hδ,hp⟩ := orbit_vector_uniform_absolute_continuity M hfac hd hfin x + (ε/(‖x‖+1)) (div_pos hε (by positivity)) + refine ⟨δ,hδ,?_⟩ + intro p hproj hdim f hf + apply WeakDualHull.eval_norm_le p ε _ hf + rintro g ⟨u,hu,rfl⟩ + have hv := hp p p.property hproj hdim u hu + calc + _ ≤ ‖(u : H →L[ℂ] H) x‖*‖(p : H →L[ℂ] H) ((u : H →L[ℂ] H) x)‖ := norm_inner_le_norm _ _ + _ ≤ ‖x‖*(ε/(‖x‖+1)) := by + rw [Unitary.norm_map] + exact mul_le_mul_of_nonneg_left hv.le (norm_nonneg x) + _ ≤ (‖x‖+1)*(ε/(‖x‖+1)) := mul_le_mul_of_nonneg_right (by linarith) (by positivity) + _ = ε := mul_div_cancel₀ ε (by positivity) + +theorem hull_projection_tendsto (x : H) {f : WeakDual ℂ M} (hf : f∈hull M x) + (p : M) (hp : IsStarProjection (p : H →L[ℂ] H)) (P : ℕ → M) + (hP : ∀ n,IsStarProjection ((P n : M) : H →L[ℂ] H)) + (hmono : Monotone (fun n => ((P n : M) : H →L[ℂ] H))) + (hPp : ∀ n,(P n : H →L[ℂ] H)≤(p : H →L[ℂ] H)) + (hlim : ∀ y,Tendsto (fun n => (P n : H →L[ℂ] H) y) atTop (𝓝 ((p : H →L[ℂ] H) y))) : + Tendsto (fun n => f (P n)) atTop (𝓝 (f p)) := by + have hdlim := dimension_tendsto_of_strong_increasing M hfac hd hfin p.property hp + (fun n => (P n : H →L[ℂ] H)) (fun n => (P n).property) hP hmono hPp hlim + have hdiff : Tendsto (fun n => dimension M hfac hd ((p-P n : M) : H →L[ℂ] H)) atTop (𝓝 0) := by + have he (n : ℕ) : dimension M hfac hd ((p-P n : M) : H →L[ℂ] H)= + dimension M hfac hd p-dimension M hfac hd (P n) := + dimension_difference M hfac hd hfin p.property (P n).property hp (hP n) (hPp n) + simp_rw [he] + simpa only [sub_self] using (tendsto_const_nhds (x := dimension M hfac hd p)).sub hdlim + apply tendsto_iff_norm_sub_tendsto_zero.mpr + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨δ,hδ,hδp⟩ := hull_projection_absolute_continuity M hfac hd hfin x (ε/2) (by positivity) + obtain ⟨N,hN⟩ := Filter.eventually_atTop.mp (hdiff.eventually_lt_const hδ) + refine ⟨N,?_⟩ + intro n hn + have hb := hδp (p-P n) ((hP n).le_iff_sub hp |>.mp (hPp n)) (hN n hn) f hf + rw [map_sub,norm_sub_rev] at hb + simpa only [dist_zero_right,Real.norm_eq_abs,abs_norm] using lt_of_le_of_lt hb (by linarith : ε/2<ε) + +end Kadison.OrbitStateHull + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrthogonalCountability.lean b/lean/OAI/Analysis/Commutator/OrthogonalCountability.lean new file mode 100644 index 0000000000000000000000000000000000000000..11447d366b37c33cd37a4da1a48b967d571fdb2e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrthogonalCountability.lean @@ -0,0 +1,49 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [TopologicalSpace.SeparableSpace H] + +theorem countable_orthogonal_family {I : Type*} (v : I → H) + (hne : ∀ i,v i≠0) (hortho : ∀ i j,i≠j → inner ℂ (v i) (v j)=0) : Countable I := by + let B : I → Set H := fun i => Metric.ball (v i) (‖v i‖/2) + have hdis : Pairwise (fun i j => Disjoint (B i) (B j)) := by + intro i j hij + apply Set.disjoint_left.mpr + intro x hxi hxj + have hi : dist x (v i)<‖v i‖/2 := hxi + have hj : dist x (v j)<‖v j‖/2 := hxj + have hd := dist_triangle (v i) x (v j) + rw [dist_comm (v i) x] at hd + have hd' : ‖v i-v j‖ < (‖v i‖+‖v j‖)/2 := by + rw [←dist_eq_norm] + linarith + have hs : ‖v i-v j‖^2=‖v i‖^2+‖v j‖^2 := by + rw [@norm_sub_sq ℂ,hortho i j hij] + simp + have hs' := sq_nonneg (‖v i‖-‖v j‖) + have hn := norm_pos_iff.mpr (hne i) + have hn' := norm_pos_iff.mpr (hne j) + nlinarith [norm_nonneg (v i-v j)] + exact hdis.countable_of_isOpen_disjoint (fun _ => Metric.isOpen_ball) + (fun i => ⟨v i, Metric.mem_ball_self (by exact div_pos (norm_pos_iff.mpr (hne i)) (by norm_num))⟩) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrthogonalLinkFamily.lean b/lean/OAI/Analysis/Commutator/OrthogonalLinkFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb98646fb97d6b2f4d1da095e3b65b0168630822 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrthogonalLinkFamily.lean @@ -0,0 +1,147 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.PartialIsometryOrder + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) + +def OrthogonalLinks (S : Set (Link M e f)) : Prop := + S.Pairwise (fun v w => star v.val*w.val=0) + +lemma exists_maximal_orthogonalLinks : + ∃ S : Set (Link M e f),Maximal (OrthogonalLinks M e f) S := by + apply zorn_subset + intro c hc hchain + refine ⟨⋃₀ c,?_,fun s hs => Set.subset_sUnion_of_mem hs⟩ + intro v hv w hw hne + obtain ⟨s,hs,hvs⟩ := hv + obtain ⟨t,ht,hwt⟩ := hw + rcases hchain.total hs ht with hst|hts + · exact hc ht (hst hvs) hwt hne + · exact hc hs hvs (hts hwt) hne + +def familySpace (S : Set (Link M e f)) : Submodule ℂ H := + (Submodule.span ℂ {x : H | ∃ v∈S,∃ ξ : H,v.val ξ=x}).topologicalClosure + +instance (S : Set (Link M e f)) : CompleteSpace (familySpace M e f S) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +lemma familySpace_generator (S : Set (Link M e f)) {v : Link M e f} (hv : v∈S) (ξ : H) : + v.val ξ∈familySpace M e f S := + Submodule.le_topologicalClosure _ (Submodule.subset_span ⟨v,hv,ξ,rfl⟩) + +lemma familySpace_invariant (S : Set (Link M e f)) {a : H →L[ℂ] H} + (ha : a∈Set.centralizer (M : Set (H →L[ℂ] H))) : + ∀ x∈familySpace M e f S,a x∈familySpace M e f S := by + intro x hx + apply closure_minimal (t:={x | a x∈familySpace M e f S}) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage a.continuous) hx + change Submodule.span ℂ {x : H | ∃ v∈S,∃ ξ : H,v.val ξ=x} ≤ + (familySpace M e f S).comap a.toLinearMap + apply Submodule.span_le.mpr + rintro y ⟨v,hv,ξ,rfl⟩ + have he : a (v.val ξ)=v.val (a ξ) := + congrArg (fun T : H →L[ℂ] H => T ξ) (ha v.val v.mem).symm + change a (v.val ξ)∈familySpace M e f S + rw [he] + exact familySpace_generator M e f S hv _ + +lemma familySpace_projection_mem (S : Set (Link M e f)) : + (familySpace M e f S).starProjection∈M := by + change (familySpace M e f S).starProjection∈M.carrier + rw [←M.centralizer_centralizer'] + intro a ha + have hsa : star a∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + intro b hb + simpa only [star_mul,star_star] using congrArg star (ha (star b) (M.star_mem' hb)).symm + exact (projection_commutes_of_invariant _ a (familySpace_invariant M e f S ha) + (familySpace_invariant M e f S hsa)).symm + +lemma familySpace_projection_mul (S : Set (Link M e f)) {v : Link M e f} (hv : v∈S) : + (familySpace M e f S).starProjection*v.val=v.val := by + ext ξ + exact Submodule.starProjection_eq_self_iff.mpr (familySpace_generator M e f S hv ξ) + +lemma familySpace_target_mul (S : Set (Link M e f)) (hf : IsStarProjection f) : + f*(familySpace M e f S).starProjection=(familySpace M e f S).starProjection := by + have hfix : ∀ x∈familySpace M e f S,f x=x := by + intro x hx + apply closure_minimal (t:={x | f x=x}) ?_ + (isClosed_eq f.continuous continuous_id) hx + have hspan : Submodule.span ℂ {x : H | ∃ v∈S,∃ ξ : H,v.val ξ=x} ≤ + LinearMap.ker (f-1).toLinearMap := by + apply Submodule.span_le.mpr + rintro y ⟨v,hv,ξ,rfl⟩ + change f (v.val ξ)-v.val ξ=0 + rw [show f (v.val ξ)=v.val ξ from congrArg (fun T : H →L[ℂ] H => T ξ) (v.target_mul hf),sub_self] + intro y hy + have he := hspan hy + exact sub_eq_zero.mp he + ext x + exact hfix _ ((familySpace M e f S).starProjection_apply_mem x) + +theorem maximal_family_spans (hM : FactorCorner.IsFactor M) + (heM : e∈M) (hfM : f∈M) (he : IsStarProjection e) (hf : IsStarProjection f) (hne : e≠0) + (S : Set (Link M e f)) (hS : Maximal (OrthogonalLinks M e f) S) : + (familySpace M e f S).starProjection=f := by + let q := (familySpace M e f S).starProjection + have hq : IsStarProjection q := isStarProjection_starProjection + have hqM : q∈M := familySpace_projection_mem M e f S + have hfq : f*q=q := familySpace_target_mul M e f S hf + have hqf : q*f=q := by simpa only [star_mul,hq.isSelfAdjoint.star_eq,hf.isSelfAdjoint.star_eq] using congrArg star hfq + have hr : IsStarProjection (f-q) := hq.sub_of_mul_eq_left hf hqf + by_contra hqne + have hrne : f-q≠0 := by + intro hz + exact hqne (sub_eq_zero.mp hz).symm + obtain ⟨w,hwM,hwne,hwtr,hwsrc,hwtgt⟩ := + FactorCorner.exists_linking_partialIsometry M hM heM (M.sub_mem hfM hqM) he hr hne hrne + let w' : Link M e (f-q) := ⟨w,hwM,hwtr,hwsrc,hwtgt⟩ + have hrw : (f-q)*w=w := w'.target_mul hr + have hwf : w*star w≤f := hwtgt.trans (sub_le_self _ hq.nonneg) + let v : Link M e f := ⟨w,hwM,hwtr,hwsrc,hwf⟩ + have hvorth (u : Link M e f) (hu : u∈S) : star u.val*w=0 := by + have hqu : q*u.val=u.val := familySpace_projection_mul M e f S hu + have hsuq : star u.val*q=star u.val := by + simpa only [star_mul,hq.isSelfAdjoint.star_eq] using congrArg star hqu + have huf : star u.val*f=star u.val := by + simpa only [star_mul,hf.isSelfAdjoint.star_eq] using congrArg star (u.target_mul hf) + calc + _=star u.val*((f-q)*w) := by rw [hrw] + _=0 := by rw [←mul_assoc,mul_sub,huf,hsuq,sub_self,zero_mul] + have hins : OrthogonalLinks M e f (insert v S) := by + intro a ha b hb hne' + rcases ha with rfl|ha <;> rcases hb with rfl|hb + · exact (hne' rfl).elim + · simpa only [star_mul,star_star,star_zero] using congrArg star (hvorth b hb) + · exact hvorth a ha + · exact hS.1 ha hb hne' + have hvS : v∈S := hS.2 hins (Set.subset_insert v S) (Set.mem_insert v S) + have hqw : q*w=w := familySpace_projection_mul M e f S hvS + have hqr : q*(f-q)=0 := by rw [mul_sub,hqf,hq.isIdempotentElem.eq,sub_self] + have : q*w=0 := by calc + _=q*((f-q)*w) := by rw [hrw] + _=0 := by rw [←mul_assoc,hqr,zero_mul] + exact hwne (hqw.symm.trans this) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrthogonalLinkSums.lean b/lean/OAI/Analysis/Commutator/OrthogonalLinkSums.lean new file mode 100644 index 0000000000000000000000000000000000000000..d420933a8db8265c90f70123cb36060f19788c84 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrthogonalLinkSums.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Commutator.OrthogonalLinkFamily + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) + +variable (S : Set (Link M e f)) (hS : OrthogonalLinks M e f S) + +def finiteProjection (s : Finset S) : H →L[ℂ] H := ∑ v∈s,v.val.final + +include hS + +lemma family_cross {v w : S} (hne : v≠w) : star v.val.val*w.val.val=0 := + hS v.property w.property (fun h => hne (Subtype.ext h)) + +lemma family_final_cross {v w : S} (hne : v≠w) : v.val.final*w.val.final=0 := by + change (v.val.val*star v.val.val)*(w.val.val*star w.val.val)=0 + calc + _=v.val.val*(star v.val.val*w.val.val)*star w.val.val := by noncomm_ring + _=0 := by rw [family_cross M e f S hS hne,mul_zero,zero_mul] + +lemma finiteProjection_projection (s : Finset S) : IsStarProjection (finiteProjection M e f S s) := by + classical + constructor + · change (∑ v∈s,v.val.final)*(∑ v∈s,v.val.final)=∑ v∈s,v.val.final + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro v hv + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem v hv] + · exact v.val.final_projection.isIdempotentElem.eq + · intro w hw hne + exact family_final_cross M e f S hS hne.symm + · change star (∑ v∈s,v.val.final)=∑ v∈s,v.val.final + rw [star_sum] + exact Finset.sum_congr rfl (fun v hv => v.val.final_projection.isSelfAdjoint.star_eq) + +lemma finiteProjection_norm_le (s : Finset S) : ‖finiteProjection M e f S s‖≤1 := + (finiteProjection_projection M e f S hS s).norm_le _ + +omit hS in +lemma finiteProjection_mem (s : Finset S) : finiteProjection M e f S s∈M := + M.sum_mem (fun v _ => M.mul_mem v.val.mem (M.star_mem' v.val.mem)) + +lemma finiteProjection_mul_val (s : Finset S) {v : S} (hv : v∈s) : + finiteProjection M e f S s*v.val.val=v.val.val := by + classical + rw [finiteProjection,Finset.sum_mul,Finset.sum_eq_single_of_mem v hv] + · exact v.val.final_mul + · intro w hw hne + change (w.val.val*star w.val.val)*v.val.val=0 + rw [mul_assoc,family_cross M e f S hS hne,mul_zero] + +omit hS in +lemma finiteProjection_target (s : Finset S) (hf : IsStarProjection f) : + finiteProjection M e f S s*f=finiteProjection M e f S s := by + rw [finiteProjection,Finset.sum_mul] + apply Finset.sum_congr rfl + intro v hv + exact (v.val.final_projection.le_iff_mul_eq_left hf).mp v.val.target_le + +lemma finiteProjection_tendsto_generator (v : S) (x : H) : + Tendsto (fun s : Finset S => finiteProjection M e f S s (v.val.val x)) atTop + (𝓝 (v.val.val x)) := by + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop ({v}:Finset S)] with s hs + exact (congrArg (fun T : H →L[ℂ] H => T x) + (finiteProjection_mul_val M e f S hS s (hs (by simp)))).symm + +lemma finiteProjection_tendsto_space {x : H} (hx : x∈familySpace M e f S) : + Tendsto (fun s : Finset S => finiteProjection M e f S s x) atTop (𝓝 x) := by + have hspan : ∀ y∈Submodule.span ℂ {x : H | ∃ v∈S,∃ ξ : H,v.val ξ=x}, + Tendsto (fun s : Finset S => finiteProjection M e f S s y) atTop (𝓝 y) := by + intro y hy + induction hy using Submodule.span_induction with + | mem y hy => + obtain ⟨v,hv,ξ,rfl⟩ := hy + exact finiteProjection_tendsto_generator M e f S hS ⟨v,hv⟩ ξ + | zero => simpa only [map_zero] using (tendsto_const_nhds (x:=(0:H)) (f:=atTop (α:=Finset S))) + | add x y hx hy hxlim hylim => + simpa only [map_add] using hxlim.add hylim + | smul c x hx hxlim => + simpa only [map_smul] using hxlim.const_smul c + have hequi : Equicontinuous (fun s : Finset S => fun x : H => finiteProjection M e f S s x) := + (LipschitzWith.uniformEquicontinuous _ 1 (fun s => + ContinuousLinearMap.lipschitzWith_of_opNorm_le (finiteProjection_norm_le M e f S hS s))).equicontinuous + exact (hequi x).tendsto_of_mem_closure + (continuous_id.continuousAt.mono_left inf_le_left) hspan hx + +theorem finiteProjection_tendsto (hf : IsStarProjection f) + (hspan : (familySpace M e f S).starProjection=f) (x : H) : + Tendsto (fun s : Finset S => finiteProjection M e f S s x) atTop (𝓝 (f x)) := by + have hx : f x∈familySpace M e f S := by + simpa only [hspan] using (familySpace M e f S).starProjection_apply_mem x + have ht := finiteProjection_tendsto_space M e f S hS hx + have he (s : Finset S) : finiteProjection M e f S s (f x)=finiteProjection M e f S s x := + congrArg (fun T : H →L[ℂ] H => T x) (finiteProjection_target M e f S s hf) + simpa only [he] using ht + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/OrthogonalRank.lean b/lean/OAI/Analysis/Commutator/OrthogonalRank.lean new file mode 100644 index 0000000000000000000000000000000000000000..d781f8a824fe4dfdbc6bf97a9a47ad8c1747297b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/OrthogonalRank.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.Commutator.EqualProjectionPartition +import OAI.Analysis.Commutator.EqualPartitionSums +import OAI.Analysis.Commutator.PartitionRank +import OAI.Analysis.Commutator.ProjectionComplements + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance orthogonalRankDecidableEq : DecidableEq ι := Classical.decEq ι + +lemma part_union {s t : Finset ι} (hst : Disjoint s t) : D.part (s∪t)=D.part s+D.part t := + Finset.sum_union hst + +lemma part_compl (s : Finset ι) : D.part sᶜ=1-D.part s := by + have h : D.part s+D.part sᶜ=1 := by + have hh := Finset.sum_add_sum_compl s D.piece + change D.part s+D.part sᶜ=D.part Finset.univ at hh + rwa [D.part_univ] at hh + exact eq_sub_of_add_eq' h + +variable [Nontrivial H] + +lemma rank_add_le_card (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) (hef : e*f=0) : + D.rank e+D.rank f ≤ Fintype.card ι := by + obtain ⟨s,hs,hse⟩ := D.exists_rank e he + have hscomp := subEquivalent_complement M hfac hfin (D.part_mem s) heM + (D.part_projection s) he hse + have hfle : f ≤ 1-e := by + apply le_sub_iff_add_le.mpr + simpa only [add_comm f e] using (he.add hf hef).le_one + have hfs : SubEquivalent M f (D.part sᶜ) := by + rw [D.part_compl] + exact (subEquivalent_of_le hfM hf hfle).trans hf he.one_sub hscomp + have hr := D.rank_mono_subEquivalent hf hfs + rw [D.rank_part hfin,Finset.card_compl] at hr + have hsc := Finset.card_le_univ s + omega + +lemma orthogonal_rank_lower (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) (hef : e*f=0) : + D.rank e+D.rank f ≤ D.rank (e+f) := by + have hc := D.rank_add_le_card hfac hfin heM hfM he hf hef + obtain ⟨s,hs,hse⟩ := D.exists_rank e he + have hfc : D.rank f ≤ sᶜ.card := by rw [Finset.card_compl,hs]; omega + obtain ⟨t,hts,ht⟩ := Finset.exists_subset_card_eq hfc + have hst : Disjoint s t := by + apply Finset.disjoint_left.mpr + intro i hi hit + exact (Finset.mem_compl.mp (hts hit)) hi + have htf := D.part_subEquivalent_of_card_le_rank hf t ht.le + have hsub := hse.orthogonal_add (D.part_projection s) he (D.part_projection t) hf + (D.part_cross hst) hef htf + have hh : (s∪t).card ≤ D.rank (e+f) := D.card_le_rank_of_subEquivalent (s∪t) + (by rwa [D.part_union hst]) + simpa only [Finset.card_union_of_disjoint hst,hs,ht] using hh + +omit [Nontrivial H] in +lemma subEquivalent_part_of_rank_lt (hfac : FactorCorner.IsFactor M) + {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) (s : Finset ι) + (hs : D.rank e if rb.2 then σ rb.1.1 else rb.1.1) (by + constructor + · rintro ⟨r, b⟩ ⟨s, c⟩ he + have hr : r = s := by + apply Subtype.ext + have hh := congrArg (repr σ) he + cases b <;> cases c <;> simpa only [Bool.false_eq_true, ↓reduceIte, + repr_apply, repr_representative] using hh + subst s + congr 1 + cases b <;> cases c <;> simp_all only [Bool.false_eq_true, ↓reduceIte] + · exact (σ.apply_ne r he.symm).elim + · exact (σ.apply_ne r he).elim + · intro j + by_cases hj : j < σ j + · exact ⟨(⟨j, hj⟩, false), rfl⟩ + · have hj' : σ j < j := lt_of_le_of_ne (le_of_not_gt hj) (σ.apply_ne j) + refine ⟨(⟨σ j, ?_⟩, true), ?_⟩ + · simpa only [apply_apply] using hj' + · exact σ.apply_apply j) + +@[simp] theorem pairEquiv_false (σ : Pairing J) (r : Representatives σ) : + pairEquiv σ (r, false) = r := rfl + +@[simp] theorem pairEquiv_true (σ : Pairing J) (r : Representatives σ) : + pairEquiv σ (r, true) = σ r := rfl + +theorem prod_pairs [Fintype J] {R : Type*} [CommMonoid R] + (σ : Pairing J) (f : J → R) : + (∏ j, f j) = ∏ r : Representatives σ, f r * f (σ r) := by + classical + rw [← (pairEquiv σ).prod_comp f, Fintype.prod_prod_type] + apply Finset.prod_congr rfl + intro r _ + rw [Fintype.prod_bool] + simp only [pairEquiv_true, pairEquiv_false, mul_comm] + +def pairFunctionEquiv (σ : Pairing J) (I : Type*) : + (J → I) ≃ (Representatives σ → Bool → I) := + (Equiv.arrowCongr (pairEquiv σ).symm (Equiv.refl I)).trans + (Equiv.curry (Representatives σ) Bool I) + +@[simp] theorem pairFunctionEquiv_apply (σ : Pairing J) {I : Type*} + (b : J → I) (r : Representatives σ) (v : Bool) : + pairFunctionEquiv σ I b r v = b (pairEquiv σ (r, v)) := rfl + +theorem sum_prod_pairs [Fintype J] {I R : Type*} [Fintype I] [CommSemiring R] + (σ : Pairing J) (A : J → I → I → R) : + (∑ b : J → I, ∏ j, A j (b (σ j)) (b j)) = + ∏ r : Representatives σ, ∑ i : I, ∑ j : I, A r j i * A (σ r) i j := by + classical + calc + _ = ∑ b : J → I, ∏ r : Representatives σ, + A r (b (σ r)) (b r) * A (σ r) (b r) (b (σ r)) := by + apply Finset.sum_congr rfl + intro b _ + simpa only [apply_apply] using prod_pairs σ (fun j => A j (b (σ j)) (b j)) + _ = ∑ b : Representatives σ → Bool → I, ∏ r : Representatives σ, + A r (b r true) (b r false) * A (σ r) (b r false) (b r true) := by + apply Fintype.sum_equiv (pairFunctionEquiv σ I) + intro b + simp only [pairFunctionEquiv_apply, pairEquiv_true, pairEquiv_false] + _ = ∏ r : Representatives σ, ∑ b : Bool → I, + A r (b true) (b false) * A (σ r) (b false) (b true) := by + exact (Fintype.prod_sum (fun (r : Representatives σ) (b : Bool → I) => + A r (b true) (b false) * A (σ r) (b false) (b true))).symm + _ = _ := by + apply Finset.prod_congr rfl + intro r _ + have he := Fintype.sum_equiv (Equiv.boolArrowEquivProd I) + (fun b : Bool → I => A r (b true) (b false) * A (σ r) (b false) (b true)) + (fun b : I × I => A r b.2 b.1 * A (σ r) b.1 b.2) (fun b => rfl) + rw [Fintype.sum_prod_type] at he + exact he + +end Kadison.Pairing +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PairTrace2.lean b/lean/OAI/Analysis/Commutator/PairTrace2.lean new file mode 100644 index 0000000000000000000000000000000000000000..6869375489a1696b9e99f316e7fc5a60ae9e0df9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PairTrace2.lean @@ -0,0 +1,29 @@ +import Mathlib +import OAI.Analysis.Commutator.Pairings + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.Pairing + +variable {J : Type*} [LinearOrder J] + +lemma repr_lt_apply (σ : Pairing J) (j : J) : repr σ j < σ (repr σ j) := by + rcases lt_or_gt_of_ne (σ.apply_ne j).symm with hj | hj + · simpa only [repr, min_eq_left (le_of_lt hj)] using hj + · simpa only [repr, min_eq_right (le_of_lt hj), apply_apply] using hj + +end Kadison.Pairing +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PairingElimination.lean b/lean/OAI/Analysis/Commutator/PairingElimination.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9c4fa4bb62bc9d26cdf520150c11b08be412cef --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PairingElimination.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.Commutator.FinitePairings3 +import OAI.Analysis.Commutator.HilbertTensors3 +import OAI.Analysis.Commutator.HilbertTensors5 + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped TensorProduct + +namespace Kadison + +attribute [instance] PreHilbert.normed PreHilbert.ipSpace + +namespace PreHilbert + +end PreHilbert + +end Kadison + +namespace Kadison.PreHilbert + +end Kadison.PreHilbert + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +end Kadison + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +noncomputable section + +namespace Kadison + +namespace Pairing + +variable {J : Type*} + +variable [LinearOrder J] + +variable [Fintype J] + +end Pairing + +end Kadison + +namespace Kadison + +open PreHilbert + +theorem pairing_coefficient_zero_source (E : PreHilbert) (k l : ℕ) + (T : hilbertPower E k →L[ℂ] hilbertPower E l) + (Jmap : E → E) (B : E → E → ℂ) (c : Pairing (TailSlots k l) → ℂ) + (h : TailSlots k l × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hB : ∀ a b, B (h a) (h b) = if a = b then 1 else 0) + (hexp : ∀ v : TailSlots k l → E, + inner ℂ (hilbertPure E l (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E k (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) + (τ : Pairing (TailSlots k l)) (a b : Fin k) (hab : τ (.inl a) = .inl b) : + c τ = 0 := by + classical + let labels := fun n => Pairing.labels τ (.inl a) n + let source := fun n (i : Fin k) => labels n (.inl i) + let test := fun (j : Fin l) => labels 0 (.inr j) + have htest (n : ℕ) (j : Fin l) : labels n (.inr j) = test j := by + have hne : Pairing.repr τ (.inr j) ≠ Pairing.repr τ (.inl a) := by + intro hh + rcases (Pairing.repr_eq_iff τ (.inl a) (.inr j)).mp hh.symm with hh | hh + · cases hh + · rw [hab] at hh + cases hh + simp only [labels, test, Pairing.labels, ite_eq_right hne] + have hinj : Function.Injective source := by + intro n m he + have hh := congrArg Prod.snd (congrFun he a) + simpa only [source, labels, Pairing.labels, ite_true] using hh + have hsource : Orthonormal ℂ + (fun n => hilbertPure E k (fun i => h (source n i))) := + (hilbertPure_orthonormal E h horth k).comp source hinj + apply constant_operator_right_coefficient_zero T _ hsource + (hilbertPure E l (fun j => h (test j))) (c τ) + intro n + have hh := hexp (fun j => h (labels n j)) + have hsum : (∑ σ, c σ * Pairing.contraction σ B (fun j => h (labels n j))) = c τ := by + simp only [labels, Pairing.contraction_isolation τ _ (.inl a) n h B hB, + mul_ite, mul_one, mul_zero, Finset.sum_ite_eq', Finset.mem_univ, ite_true] + rw [hsum] at hh + simpa only [source, hself, htest] using hh + +end Kadison + +namespace Kadison + +open PreHilbert + +theorem pairing_coefficient_zero_test (E : PreHilbert) (k l : ℕ) + (T : hilbertPower E k →L[ℂ] hilbertPower E l) + (Jmap : E → E) (B : E → E → ℂ) (c : Pairing (TailSlots k l) → ℂ) + (h : TailSlots k l × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hB : ∀ a b, B (h a) (h b) = if a = b then 1 else 0) + (hexp : ∀ v : TailSlots k l → E, + inner ℂ (hilbertPure E l (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E k (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) + (τ : Pairing (TailSlots k l)) (a b : Fin l) (hab : τ (.inr a) = .inr b) : + c τ = 0 := by + classical + let labels := fun n => Pairing.labels τ (.inr a) n + let source := fun (i : Fin k) => labels 0 (.inl i) + let test := fun n (j : Fin l) => labels n (.inr j) + have hsource (n : ℕ) (i : Fin k) : labels n (.inl i) = source i := by + have hne : Pairing.repr τ (.inl i) ≠ Pairing.repr τ (.inr a) := by + intro hh + rcases (Pairing.repr_eq_iff τ (.inr a) (.inl i)).mp hh.symm with hh | hh + · cases hh + · rw [hab] at hh + cases hh + simp only [labels, source, Pairing.labels, ite_eq_right hne] + have hinj : Function.Injective test := by + intro n m he + have hh := congrArg Prod.snd (congrFun he a) + simpa only [test, labels, Pairing.labels, ite_true] using hh + have htest : Orthonormal ℂ + (fun n => hilbertPure E l (fun j => h (test n j))) := + (hilbertPure_orthonormal E h horth l).comp test hinj + apply constant_orthonormal_coefficient_zero _ htest + (T (hilbertPure E k (fun i => h (source i)))) (c τ) + intro n + have hh := hexp (fun j => h (labels n j)) + have hsum : (∑ σ, c σ * Pairing.contraction σ B (fun j => h (labels n j))) = c τ := by + simp only [labels, Pairing.contraction_isolation τ _ (.inr a) n h B hB, + mul_ite, mul_one, mul_zero, Finset.sum_ite_eq', Finset.mem_univ, ite_true] + rw [hsum] at hh + simpa only [test, hself, hsource] using hh + +theorem pairing_crossing_card_eq (k l : ℕ) (τ : Pairing (TailSlots k l)) + (hs : ∀ a : Fin k, ∃ b : Fin l, τ (.inl a) = .inr b) + (ht : ∀ b : Fin l, ∃ a : Fin k, τ (.inr b) = .inl a) : k = l := by + classical + let f : Fin k → Fin l := fun a => (hs a).choose + have hf (a : Fin k) : τ (.inl a) = .inr (f a) := (hs a).choose_spec + have hinj : Function.Injective f := by + intro a b hab + apply Sum.inl_injective + apply τ.injective + rw [hf, hf, hab] + have hsurj : Function.Surjective f := by + intro b + obtain ⟨a, ha⟩ := ht b + refine ⟨a, ?_⟩ + have hh := τ.apply_apply (.inr b) + rw [ha, hf] at hh + exact Sum.inr_injective hh + have hh := Fintype.card_congr (Equiv.ofBijective f ⟨hinj, hsurj⟩) + simpa only [Fintype.card_fin] using hh + +theorem pairing_coefficients_zero_of_ne (E : PreHilbert) (k l : ℕ) + (T : hilbertPower E k →L[ℂ] hilbertPower E l) + (Jmap : E → E) (B : E → E → ℂ) (c : Pairing (TailSlots k l) → ℂ) + (h : TailSlots k l × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hB : ∀ a b, B (h a) (h b) = if a = b then 1 else 0) + (hexp : ∀ v : TailSlots k l → E, + inner ℂ (hilbertPure E l (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E k (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) + (hkl : k ≠ l) : ∀ τ, c τ = 0 := by + intro τ + by_contra hc + apply hkl + apply pairing_crossing_card_eq k l τ + · intro a + cases he : τ (.inl a) with + | inl b => exact (hc (pairing_coefficient_zero_source E k l T Jmap B c h horth hself hB hexp τ a b he)).elim + | inr b => exact ⟨b, rfl⟩ + · intro a + cases he : τ (.inr a) with + | inl b => exact ⟨b, rfl⟩ + | inr b => exact (hc (pairing_coefficient_zero_test E k l T Jmap B c h horth hself hB hexp τ a b he)).elim + +end Kadison +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PairingOperators.lean b/lean/OAI/Analysis/Commutator/PairingOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..716db80fbeeebf02bc6b0769c47bb3a648b8d153 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PairingOperators.lean @@ -0,0 +1,226 @@ +import Mathlib +import OAI.Analysis.Commutator.CrossingPairings +import OAI.Analysis.Commutator.PairingElimination +import OAI.Analysis.Commutator.TensorPermutations3 + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped TensorProduct + +namespace Kadison + +attribute [instance] PreHilbert.normed PreHilbert.ipSpace + +namespace PreHilbert + +end PreHilbert + +end Kadison + +namespace Kadison.PreHilbert + +end Kadison.PreHilbert + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +end Kadison + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +namespace Kadison + +section Gram + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Gram + +end Kadison + +namespace Kadison + +section GramEquiv + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end GramEquiv + +namespace PreHilbert + +end PreHilbert + +end Kadison + +noncomputable section + +namespace Kadison + +namespace Pairing + +variable {J : Type*} + +variable [LinearOrder J] + +variable [Fintype J] + +end Pairing + +end Kadison + +namespace Kadison + +open PreHilbert + +end Kadison + +namespace Kadison + +open PreHilbert + +end Kadison + +namespace Kadison + +namespace Pairing + +end Pairing + +end Kadison + +namespace Kadison + +open PreHilbert + +def tailVector {k l : ℕ} {E : Type*} (x : Fin k → E) (y : Fin l → E) : + TailSlots k l → E := fun j => Sum.elim x y (ofLex j) + +@[simp] theorem tailVector_inl {k l : ℕ} {E : Type*} (x : Fin k → E) + (y : Fin l → E) (a : Fin k) : tailVector x y (Sum.inl a) = x a := rfl + +@[simp] theorem tailVector_inr {k l : ℕ} {E : Type*} (x : Fin k → E) + (y : Fin l → E) (b : Fin l) : tailVector x y (Sum.inr b) = y b := rfl + +theorem pairing_coefficient_zero_noncrossing (E : PreHilbert) (k l : ℕ) + (T : hilbertPower E k →L[ℂ] hilbertPower E l) + (Jmap : E → E) (B : E → E → ℂ) (c : Pairing (TailSlots k l) → ℂ) + (h : TailSlots k l × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hB : ∀ a b, B (h a) (h b) = if a = b then 1 else 0) + (hexp : ∀ v : TailSlots k l → E, + inner ℂ (hilbertPure E l (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E k (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) + (τ : Pairing (TailSlots k l)) (hτ : ¬ τ.Crosses) : c τ = 0 := by + by_contra hc + apply hτ + constructor + · intro a + cases he : τ (.inl a) with + | inl b => exact (hc (pairing_coefficient_zero_source E k l T Jmap B c h horth hself hB hexp τ a b he)).elim + | inr b => exact ⟨b, rfl⟩ + · intro a + cases he : τ (.inr a) with + | inl b => exact ⟨b, rfl⟩ + | inr b => exact (hc (pairing_coefficient_zero_test E k l T Jmap B c h horth hself hB hexp τ a b he)).elim + +theorem pairing_operator_eq_zero (E : PreHilbert) (k l : ℕ) + (T : hilbertPower E k →L[ℂ] hilbertPower E l) + (Jmap : E → E) (hJ : Function.Involutive Jmap) + (B : E → E → ℂ) (c : Pairing (TailSlots k l) → ℂ) + (h : TailSlots k l × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hB : ∀ a b, B (h a) (h b) = if a = b then 1 else 0) + (hexp : ∀ v : TailSlots k l → E, + inner ℂ (hilbertPure E l (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E k (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) + (hkl : k ≠ l) : T = 0 := by + have hJJ (z : E) : Jmap (Jmap z) = z := hJ z + have hz := pairing_coefficients_zero_of_ne E k l T Jmap B c h horth hself hB hexp hkl + apply continuousLinearMap_ext_pure E k + intro x + change T (hilbertPure E k x) = 0 + apply eq_zero_of_hilbertPure_inner E l + intro y + have hh := hexp (tailVector x (Jmap ∘ y)) + simpa only [tailVector_inl, tailVector_inr, Function.comp_apply, hJJ, + hz, zero_mul, Finset.sum_const_zero] using hh + +theorem crossing_contraction_inner (E : PreHilbert) (n : ℕ) + (Jmap : E → E) (hJ : Function.Involutive Jmap) + (B : E → E → ℂ) (hB : ∀ x y, B x y = inner ℂ (Jmap y) x) + (e : Equiv.Perm (Fin n)) (x y : Fin n → E) : + Pairing.contraction (Pairing.crossPairing e) B (tailVector x (Jmap ∘ y)) = + inner ℂ (hilbertPure E n y) + (hilbertPermute E n e.symm (hilbertPure E n x)) := by + classical + have hJJ (z : E) : Jmap (Jmap z) = z := hJ z + rw [Pairing.contraction_crossPairing, hilbertPermute_pure, inner_hilbertPure] + simp only [tailVector_inl, tailVector_inr, Function.comp_apply, hB, hJJ] + simpa only [Equiv.symm_apply_apply] using + (Equiv.prod_comp e (fun j => inner ℂ (y j) (x (e.symm j)))) + +theorem pairing_operator_eq_permutation_sum (E : PreHilbert) (n : ℕ) + (T : hilbertPower E n →L[ℂ] hilbertPower E n) + (Jmap : E → E) (hJ : Function.Involutive Jmap) + (B : E → E → ℂ) (hB : ∀ x y, B x y = inner ℂ (Jmap y) x) + (c : Pairing (TailSlots n n) → ℂ) + (h : TailSlots n n × ℕ → E) (horth : Orthonormal ℂ h) + (hself : ∀ a, Jmap (h a) = h a) + (hexp : ∀ v : TailSlots n n → E, + inner ℂ (hilbertPure E n (fun j => Jmap (v (.inr j)))) + (T (hilbertPure E n (fun i => v (.inl i)))) = + ∑ σ, c σ * Pairing.contraction σ B v) : + T = ∑ e : Equiv.Perm (Fin n), c (Pairing.crossPairing e) • + (hilbertPermute E n e.symm).toContinuousLinearEquiv.toContinuousLinearMap := by + classical + have hJJ (z : E) : Jmap (Jmap z) = z := hJ z + have hBorth (a b) : B (h a) (h b) = if a = b then 1 else 0 := by + rw [hB, hself] + rw [orthonormal_iff_ite.mp horth] + simp only [eq_comm] + have hz := pairing_coefficient_zero_noncrossing E n n T Jmap B c h horth hself hBorth hexp + apply continuousLinearMap_ext_pure E n + intro x + apply sub_eq_zero.mp + apply eq_zero_of_hilbertPure_inner E n + intro y + rw [inner_sub_right] + apply sub_eq_zero.mpr + have hh := hexp (tailVector x (Jmap ∘ y)) + simp only [tailVector_inl, tailVector_inr, Function.comp_apply, hJJ] at hh + rw [hh, Pairing.sum_contraction_crossing B _ c hz] + simp only [sum_apply, smul_apply, + inner_sum, inner_smul_right] + apply Finset.sum_congr rfl + intro e _ + exact congrArg (fun z => c (Pairing.crossPairing e) * z) + ((Pairing.contraction_crossPairing e B (tailVector x (Jmap ∘ y))).symm.trans + (crossing_contraction_inner E n Jmap hJ B hB e x y)) + +end Kadison +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/Pairings.lean b/lean/OAI/Analysis/Commutator/Pairings.lean new file mode 100644 index 0000000000000000000000000000000000000000..1e43e9f89ef22cd7667a1d72bd95a3dee0bc4a2d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/Pairings.lean @@ -0,0 +1,123 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +abbrev Pairing (J : Type*) := {σ : Equiv.Perm J // Function.Involutive σ ∧ ∀ j, σ j ≠ j} + +namespace Pairing + +variable {J : Type*} + +instance : CoeFun (Pairing J) (fun _ => J → J) := ⟨fun σ => σ.val⟩ + +@[simp] theorem apply_apply (σ : Pairing J) (j : J) : σ (σ j) = j := σ.property.1 j + +theorem apply_ne (σ : Pairing J) (j : J) : σ j ≠ j := σ.property.2 j + +theorem injective (σ : Pairing J) : Function.Injective σ := σ.val.injective + +@[ext] theorem ext (σ τ : Pairing J) (h : ∀ j, σ j = τ j) : σ = τ := by + apply Subtype.ext + exact Equiv.ext h + +instance [Fintype J] : Fintype (Pairing J) := Fintype.ofFinite _ + +instance : DecidableEq (Pairing J) := Classical.decEq _ + +variable [LinearOrder J] + +def repr (σ : Pairing J) (j : J) : J := min j (σ j) + +@[simp] theorem repr_apply (σ : Pairing J) (j : J) : repr σ (σ j) = repr σ j := by + simp only [repr, apply_apply, min_comm] + +theorem repr_eq_iff (σ : Pairing J) (i j : J) : + repr σ i = repr σ j ↔ j = i ∨ j = σ i := by + constructor + · intro h + unfold repr at h + rcases le_total i (σ i) with hi | hi <;> + rcases le_total j (σ j) with hj | hj + · rw [min_eq_left hi, min_eq_left hj] at h + exact Or.inl h.symm + · rw [min_eq_left hi, min_eq_right hj] at h + exact Or.inr (by simpa only [apply_apply] using congrArg σ h.symm) + · rw [min_eq_right hi, min_eq_left hj] at h + exact Or.inr h.symm + · rw [min_eq_right hi, min_eq_right hj] at h + exact Or.inl (σ.injective h).symm + · rintro (rfl | rfl) + · rfl + · exact (repr_apply σ i).symm + +def labels (σ : Pairing J) (p : J) (n : ℕ) (j : J) : J × ℕ := + (repr σ j, if repr σ j = repr σ p then n else 0) + +@[simp] theorem labels_eq_iff (σ : Pairing J) (p : J) (n : ℕ) (i j : J) : + labels σ p n i = labels σ p n j ↔ j = i ∨ j = σ i := by + constructor + · intro h + exact (repr_eq_iff σ i j).mp (congrArg Prod.fst h) + · intro h + have hh := (repr_eq_iff σ i j).mpr h + simp only [labels, hh] + +variable [Fintype J] + +def contraction {E : Type*} (σ : Pairing J) (B : E → E → ℂ) (v : J → E) : ℂ := + ∏ j ∈ Finset.univ.filter (fun j => j < σ j), B (v j) (v (σ j)) + +omit [Fintype J] in +theorem pair_tests_iff {L : Type*} (σ : Pairing J) (f : J → L) : + (∀ j, j < σ j → f j = f (σ j)) ↔ ∀ j, f j = f (σ j) := by + constructor + · intro h j + rcases lt_or_gt_of_ne (σ.apply_ne j).symm with hj | hj + · exact h j hj + · have hh := h (σ j) (by simpa only [apply_apply] using hj) + simpa only [apply_apply] using hh.symm + · intro h j _ + exact h j + +theorem contraction_isolation {E : Type*} (τ σ : Pairing J) (p : J) (n : ℕ) + (v : J × ℕ → E) (B : E → E → ℂ) + (hv : ∀ a b, B (v a) (v b) = if a = b then 1 else 0) : + contraction σ B (fun j => v (labels τ p n j)) = if σ = τ then 1 else 0 := by + classical + unfold contraction + simp_rw [hv] + rw [Finset.prod_ite_zero] + simp only [Finset.mem_filter, Finset.mem_univ, true_and, Finset.prod_const_one] + have he : (∀ j, j < σ j → labels τ p n j = labels τ p n (σ j)) ↔ σ = τ := by + rw [pair_tests_iff] + constructor + · intro h + apply ext + intro j + rcases (labels_eq_iff τ p n j (σ j)).mp (h j) with hh | hh + · exact (σ.apply_ne j hh).elim + · exact hh + · rintro rfl + intro j + exact (labels_eq_iff σ p n j (σ j)).mpr (Or.inr rfl) + simp only [he] + +end Pairing + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialDecomposition.lean b/lean/OAI/Analysis/Commutator/PartialDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..363ee2e64261f07cb0aaa80cad3f5b2b8c273664 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialDecomposition.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Commutator.OrthogonalLinkSums + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +open Filter + +universe u + +namespace Kadison.PartialIsometryOrder + +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure PartialDecomposition (M : VonNeumannAlgebra H) (p : H →L[ℂ] H) where + I : Type u + v : I → Link M p 1 + nonzero : ∀ i,(v i).val≠0 + cross : ∀ i j,i≠j → star (v i).val*(v j).val=0 + strong : ∀ x : H,Tendsto (fun s : Finset I => (∑ i∈s,(v i).final) x) atTop (𝓝 x) + +theorem exists_partialDecomposition (M : VonNeumannAlgebra H) + (hM : FactorCorner.IsFactor M) {p : H →L[ℂ] H} + (hpM : p∈M) (hp : IsStarProjection p) (hpn : p≠0) : + Nonempty (PartialDecomposition M p) := by + classical + obtain ⟨S,hS⟩ := exists_maximal_orthogonalLinks M p 1 + let T : Set (Link M p 1) := {v | v∈S ∧ v.val≠0} + have hTS : T⊆S := fun _ h => h.1 + have hT : OrthogonalLinks M p 1 T := fun _ hv _ hw hne => hS.1 (hTS hv) (hTS hw) hne + have hspaces : familySpace M p 1 T=familySpace M p 1 S := by + apply le_antisymm + · apply Submodule.topologicalClosure_mono + apply Submodule.span_mono + rintro x ⟨v,hv,ξ,rfl⟩ + exact ⟨v,hTS hv,ξ,rfl⟩ + · apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro x ⟨v,hv,ξ,rfl⟩ + change v.val ξ∈familySpace M p 1 T + by_cases hz : v.val=0 + · rw [hz] + exact (familySpace M p 1 T).zero_mem + · exact familySpace_generator M p 1 T ⟨hv,hz⟩ ξ + · exact Submodule.isClosed_topologicalClosure _ + have hspan : (familySpace M p 1 T).starProjection=1 := by + have he : (familySpace M p 1 T).starProjection=(familySpace M p 1 S).starProjection := by + congr 1 + rw [he] + exact maximal_family_spans M p 1 hM hpM M.one_mem hp (IsStarProjection.one _) hpn S hS + refine ⟨⟨T,fun i => i.val,fun i => i.property.2,?_,?_⟩⟩ + · intro i j hij + exact family_cross M p 1 T hT hij + · intro x + simpa only [finiteProjection,one_apply_eq_self] using + finiteProjection_tendsto M p 1 T hT (IsStarProjection.one _) hspan x + +namespace PartialDecomposition + +variable {M : VonNeumannAlgebra H} {p : H →L[ℂ] H} (D : PartialDecomposition M p) + +def support (s : Finset D.I) : H →L[ℂ] H := ∑ i∈s,(D.v i).final + +lemma support_projection (s : Finset D.I) : IsStarProjection (D.support s) := by + classical + constructor + · change D.support s*D.support s=D.support s + rw [support,Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · exact (D.v i).final_projection.isIdempotentElem.eq + · intro j hj hne + change ((D.v i).val*star (D.v i).val)*((D.v j).val*star (D.v j).val)=0 + calc + _=((D.v i).val*(star (D.v i).val*(D.v j).val))*star (D.v j).val := by noncomm_ring + _=0 := by rw [D.cross i j hne.symm,mul_zero,zero_mul] + · change star (D.support s)=D.support s + rw [support,star_sum] + exact Finset.sum_congr rfl (fun i _ => (D.v i).final_projection.isSelfAdjoint.star_eq) + +lemma support_norm_le (s : Finset D.I) : ‖D.support s‖≤1 := + (D.support_projection s).norm_le _ + +lemma support_tendsto (x : H) : Tendsto (fun s : Finset D.I => D.support s x) atTop (𝓝 x) := + D.strong x + +lemma eq_zero_of_coefficients_zero {a : H →L[ℂ] H} + (ha : ∀ i j,star (D.v i).val*a*(D.v j).val=0) : a=0 := by + have hleft (i : D.I) : star (D.v i).val*a=0 := by + ext x + have he (s : Finset D.I) : (star (D.v i).val*a) (D.support s x)=0 := by + have ht : (star (D.v i).val*a)*D.support s=0 := by + rw [support,Finset.mul_sum] + apply Finset.sum_eq_zero + intro j hj + change (star (D.v i).val*a)*((D.v j).val*star (D.v j).val)=0 + rw [←mul_assoc,ha i j,zero_mul] + exact congrArg (fun T : H →L[ℂ] H => T x) ht + exact tendsto_nhds_unique + (((star (D.v i).val*a).continuous.tendsto x).comp (D.support_tendsto x)) + (by simpa only [Function.comp_def,he,zero_apply] using + (tendsto_const_nhds : Tendsto (fun _ : Finset D.I => (0:H)) atTop (𝓝 0))) + ext x + have he (s : Finset D.I) : D.support s (a x)=0 := by + have ht : D.support s*a=0 := by + rw [support,Finset.sum_mul] + apply Finset.sum_eq_zero + intro i hi + change ((D.v i).val*star (D.v i).val)*a=0 + rw [mul_assoc,hleft i,mul_zero] + exact congrArg (fun T : H →L[ℂ] H => T x) ht + exact tendsto_nhds_unique (D.support_tendsto (a x)) + (by simpa only [Function.comp_def,he,zero_apply] using + (tendsto_const_nhds : Tendsto (fun _ : Finset D.I => (0:H)) atTop (𝓝 0))) + +lemma eq_of_coefficients_eq {a b : H →L[ℂ] H} + (h : ∀ i j,star (D.v i).val*a*(D.v j).val=star (D.v i).val*b*(D.v j).val) : a=b := by + apply sub_eq_zero.mp + apply D.eq_zero_of_coefficients_zero + intro i j + rw [mul_sub,sub_mul,h i j,sub_self] + +end PartialDecomposition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialDecompositionCountable.lean b/lean/OAI/Analysis/Commutator/PartialDecompositionCountable.lean new file mode 100644 index 0000000000000000000000000000000000000000..99fa2bc8939e7dd410abb4caa0f1d32b96a4b6c6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialDecompositionCountable.lean @@ -0,0 +1,42 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialDecomposition +import OAI.Analysis.Commutator.OrthogonalCountability + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.PartialIsometryOrder.PartialDecomposition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +variable {M : VonNeumannAlgebra H} {p : H →L[ℂ] H} (D : PartialDecomposition M p) + +theorem countable : Countable D.I := by + have hx (i : D.I) : ∃ x : H,(D.v i).val x≠0 := by + by_contra hn + push Not at hn + exact D.nonzero i (ContinuousLinearMap.ext hn) + choose x hx using hx + apply Kadison.countable_orthogonal_family (fun i => (D.v i).val (x i)) hx + intro i j hij + rw [←ContinuousLinearMap.adjoint_inner_right] + change inner ℂ (x i) ((star (D.v i).val*(D.v j).val) (x j))=0 + rw [D.cross i j hij] + simp + +end Kadison.PartialIsometryOrder.PartialDecomposition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialIsometryMaximal.lean b/lean/OAI/Analysis/Commutator/PartialIsometryMaximal.lean new file mode 100644 index 0000000000000000000000000000000000000000..7a25df85a946063a6d8b6be7e62cdc978e061488 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialIsometryMaximal.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialIsometryOrder +import OAI.Analysis.Commutator.PolarExtension +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) {e f : H →L[ℂ] H} + +variable (he : IsStarProjection e) (hf : IsStarProjection f) + +include he hf + +theorem chain_has_upper (c : Set (Link M e f)) (hc : IsChain (·≤·) c) (hne : c.Nonempty) : + BddAbove c := by + let : Nonempty c := hne.to_subtype + let : IsDirectedOrder c := hc.directedOn.isDirectedOrder + let ω : Ultrafilter c := Ultrafilter.of atTop + have hω : (ω : Filter c)≤atTop := Ultrafilter.of_le atTop + obtain ⟨W,hnW,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω (fun v : c => v.val.val) + 1 zero_le_one (fun v => v.val.norm_le_one) + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hlim M + (Filter.Eventually.of_forall fun v => v.val.mem) + have hWe : W*e=W := by + have h := WeakOperatorLimit.intertwine hlim e 1 (Filter.Eventually.of_forall + fun v => by simpa only [one_mul] using v.val.mul_source he) + simpa only [one_mul] using h + have hfW : f*W=W := by + have h := WeakOperatorLimit.intertwine hlim 1 f (Filter.Eventually.of_forall + fun v => by simpa only [mul_one] using (v.val.target_mul hf).symm) + simpa only [mul_one] using h.symm + let u : Link M e f := + { val := Polar.partialIsometry W + mem := Polar.partialIsometry_mem_vonNeumann M hWM + triple := Polar.partialIsometry_triple W + source_le := by rw [Polar.partialIsometry_initial]; exact Polar.rightSupport_le W e he hWe + target_le := Polar.leftSupport_le W f hf hfW } + refine ⟨u,?_⟩ + intro v hv + have hev : ∀ᶠ w : c in (ω : Filter c), v≤w.val := + (Filter.eventually_ge_atTop (⟨v,hv⟩ : c)).filter_mono hω + have hWv : W*v.initial=v.val := WeakOperatorLimit.right_eq hlim v.initial v.val + (hev.mono fun w hw => (Link.le_def v w.val).mp hw |>.2) + have hExt := Polar.partialIsometry_extends hnW v.triple hWv + apply (Link.le_def v u).mpr + constructor + · change v.initial ≤ star (Polar.partialIsometry W)*Polar.partialIsometry W + rw [Polar.partialIsometry_initial] + exact hExt.2 + · exact hExt.1 + +theorem exists_maximal : ∃ v : Link M e f, IsMax v := by + let v0 : Link M e f := + { val := 0 + mem := M.zero_mem + triple := by simp + source_le := by simpa using he.nonneg + target_le := by simpa using hf.nonneg } + let : Nonempty (Link M e f) := ⟨v0⟩ + exact zorn_le_nonempty (fun c hc hn => chain_has_upper M he hf c hc hn) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialIsometryOrder.lean b/lean/OAI/Analysis/Commutator/PartialIsometryOrder.lean new file mode 100644 index 0000000000000000000000000000000000000000..cdb29660be754605c29724375348c409104b06d2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialIsometryOrder.lean @@ -0,0 +1,103 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure Link (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) where + val : H →L[ℂ] H + mem : val∈M + triple : val*star val*val=val + source_le : star val*val≤e + target_le : val*star val≤f + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + +@[ext] lemma ext {v w : Link M e f} (h : v.val=w.val) : v=w := by + cases v; cases w; cases h; rfl + +def initial (v : Link M e f) : H →L[ℂ] H := star v.val*v.val + +def final (v : Link M e f) : H →L[ℂ] H := v.val*star v.val + +lemma initial_projection (v : Link M e f) : IsStarProjection v.initial := by + constructor + · change (star v.val*v.val)*(star v.val*v.val)=star v.val*v.val + calc + _=star v.val*(v.val*star v.val*v.val) := by noncomm_ring + _=star v.val*v.val := by rw [v.triple] + · exact IsSelfAdjoint.star_mul_self v.val + +lemma final_projection (v : Link M e f) : IsStarProjection v.final := by + constructor + · change (v.val*star v.val)*(v.val*star v.val)=v.val*star v.val + calc + _=(v.val*star v.val*v.val)*star v.val := by noncomm_ring + _=v.val*star v.val := by rw [v.triple] + · exact IsSelfAdjoint.mul_star_self v.val + +lemma mul_initial (v : Link M e f) : v.val*v.initial=v.val := by + rw [initial,←mul_assoc,v.triple] + +lemma final_mul (v : Link M e f) : v.final*v.val=v.val := v.triple + +lemma norm_le_one (v : Link M e f) : ‖v.val‖≤1 := by + have h := (v.initial_projection).norm_le v.initial + change ‖star v.val*v.val‖≤1 at h + rw [CStarRing.norm_star_mul_self] at h + nlinarith [norm_nonneg v.val] + +lemma mul_source (v : Link M e f) (he : IsStarProjection e) : v.val*e=v.val := by + have h := (v.initial_projection.le_iff_mul_eq_left he).mp v.source_le + calc + _=(v.val*v.initial)*e := by rw [v.mul_initial] + _=v.val := by rw [mul_assoc,h,v.mul_initial] + +lemma target_mul (v : Link M e f) (hf : IsStarProjection f) : f*v.val=v.val := by + have h := (v.final_projection.le_iff_mul_eq_right hf).mp v.target_le + calc + _=f*(v.final*v.val) := by rw [v.final_mul] + _=v.val := by rw [←mul_assoc,h,v.final_mul] + +instance : PartialOrder (Link M e f) where + le v w := v.initial≤w.initial ∧ w.val*v.initial=v.val + le_refl v := ⟨le_rfl,v.mul_initial⟩ + le_trans v w u hvw hwu := by + refine ⟨hvw.1.trans hwu.1,?_⟩ + have h := (v.initial_projection.le_iff_mul_eq_right w.initial_projection).mp hvw.1 + calc + _=u.val*(w.initial*v.initial) := by rw [h] + _=v.val := by rw [←mul_assoc,hwu.2,hvw.2] + le_antisymm v w hvw hwv := by + apply ext + have h := le_antisymm hvw.1 hwv.1 + calc + v.val=w.val*v.initial := hvw.2.symm + _=w.val := by rw [h,w.mul_initial] + +lemma le_def (v w : Link M e f) : v≤w ↔ v.initial≤w.initial ∧ w.val*v.initial=v.val := Iff.rfl + +end Link + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialMomentBudget.lean b/lean/OAI/Analysis/Commutator/PartialMomentBudget.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ace2698ee1a2e6ab1be1df16dc4f6fe7c55d0c5 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialMomentBudget.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.ExponentialMomentBudget +import OAI.Analysis.Commutator.PartialWordPerturbation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.Words + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +variable (x : J → A) (k : K → ℤ) + +omit [StarOrderedRing A] in +lemma zero_word_trace (hcenter : ∀ j,τ (x j)=0) (l : List (Letter J K)) + (hne : l≠[]) (hv : Valid l) : τ (word x k PartialUnitary.zero l)=0 := by + cases l with + | nil => exact (hne rfl).elim + | cons i l => + cases l with + | nil => + rcases i with ⟨j,s⟩ + cases s with + | none => simpa [letter,slotPower] using hcenter j + | some s => + cases s <;> simp only [word_cons,word_nil,letter,slotPower,PartialUnitary.zero_power, + mul_zero,mul_one,map_zero] + simp [PartialUnitary.zero] + | cons j l => + obtain ⟨a,ha⟩ := hv [] i (j::l) rfl (by simp) + simp [word_cons,letter,ha,slotPower] + +omit [StarOrderedRing A] in +lemma zero_momentBound (hcenter : ∀ j,τ (x j)=0) (N : ℕ) {B : ℝ} (hB : 0 ≤ B) : + MomentBound τ x k PartialUnitary.zero N B := by + constructor + · intro i; simpa using hB + · intro l hl hlen hv + simpa only [zero_word_trace τ x k hcenter l hl hv,norm_zero] using hB + +include hτ in +theorem momentBound_add (hx : ∀ j,‖x j‖ ≤ 1) + (v w : PartialUnitary A) (horth : v.support*w.support=0) + (hqp : w.support ≤ 1-v.support) {N : ℕ} {ε η : ℝ} + (hε : 0 ≤ ε) (hη : 0<η) (hrest : η ≤ (τ (1-v.support)).re) + (hbound : MomentBound τ x k v N (momentBudget ε (budgetSlope N η) (τ v.support).re)) + (hpure : ∀ i,‖τ (w.power (k i))‖ ≤ ε*(τ w.support).re) + (hsmall : ∀ (s : List (Letter J K)) (j : J),s.length ≤ N → + TracialL2.norm τ (w.support*cornerCenter τ (1-v.support) (word x k v s*x j)*w.support)^2 ≤ + ε^2*(τ w.support).re) + (hphase : ∀ (s t : List (Letter J K)) (j : J) (i : K),s.length ≤ N → t.length ≤ N → + ‖τ (w.power (k i)*(word x k v t*word x k v s*x j))‖ ≤ ε*(τ w.support).re) : + MomentBound τ x k (v.add w horth) N + (momentBudget ε (budgetSlope N η) (τ (v.add w horth).support).re) := by + have ht : 0 ≤ (τ v.support).re := (τ.map_nonneg v.projection.nonneg).1 + have hq : 0 ≤ (τ w.support).re := (τ.map_nonneg w.projection.nonneg).1 + have he : (τ (v.add w horth).support).re=(τ v.support).re+(τ w.support).re := by + change (τ (v.support+w.support)).re=_ + rw [map_add,Complex.add_re] + constructor + · intro i + rw [v.add_power w horth,map_add] + exact (norm_add_le _ _).trans ((add_le_add (hbound.1 i) (hpure i)).trans + (by rw [he]; exact pure_momentBudget_step hε hη ht hq N)) + · intro l hl hlen hv + have hh := word_perturbation_bound τ hτ x k hx v w horth hqp + (momentBudget_nonneg hε _ _) hε hη hrest hbound hsmall hphase l hlen hv + calc + _ ≤ ‖τ (word x k v l)‖+‖τ (word x k (v.add w horth) l)-τ (word x k v l)‖ := by + simpa only [norm_sub_rev] using norm_le_insert (τ (word x k v l)) + (τ (word x k (v.add w horth) l)) + _ ≤ momentBudget ε (budgetSlope N η) (τ v.support).re+ + ((l.length:ℝ)+(l.length:ℝ)^2)* + (ε+2*momentBudget ε (budgetSlope N η) (τ v.support).re/η)*(τ w.support).re := + add_le_add (hbound.2 l hl hlen hv) hh + _ ≤ _ := by rw [he]; exact word_momentBudget_step hε hη ht hq hlen + +end Kadison.FinitePatching.Words + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryAlgebra.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..22c8e97ea4bc118616b0b2805cb59997fa6a0ff1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryAlgebra.lean @@ -0,0 +1,190 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching + +variable (A : Type*) [CStarAlgebra A] + +structure PartialUnitary where + val : A + support : A + projection : IsStarProjection support + star_mul : star val*val=support + mul_star : val*star val=support + mul_support : val*support=val + support_mul : support*val=val + +namespace PartialUnitary + +variable {A} + +lemma norm_le_one (v : PartialUnitary A) : ‖v.val‖ ≤ 1 := by + have h := v.projection.norm_le v.support + rw [←v.star_mul,CStarRing.norm_star_mul_self] at h + nlinarith [_root_.norm_nonneg v.val] + +@[simp] lemma star_mul_support (v : PartialUnitary A) : star v.val*v.support=star v.val := by + simpa only [StarMul.star_mul,v.projection.isSelfAdjoint.star_eq,star_star] using + congrArg star v.support_mul + +@[simp] lemma support_mul_star (v : PartialUnitary A) : v.support*star v.val=star v.val := by + simpa only [StarMul.star_mul,v.projection.isSelfAdjoint.star_eq,star_star] using + congrArg star v.mul_support + +def power (v : PartialUnitary A) : ℤ → A + | .ofNat 0 => v.support + | .ofNat (n+1) => v.val^(n+1) + | .negSucc n => (star v.val)^(n+1) + +@[simp] lemma power_zero (v : PartialUnitary A) : v.power 0=v.support := rfl + +@[simp] lemma power_nat_succ (v : PartialUnitary A) (n : ℕ) : + v.power (n+1 : ℕ)=v.val^(n+1) := rfl + +@[simp] lemma power_negSucc (v : PartialUnitary A) (n : ℕ) : + v.power (.negSucc n)=(star v.val)^(n+1) := rfl + +lemma power_support (v : PartialUnitary A) (k : ℤ) : v.power k*v.support=v.power k := by + cases k with + | ofNat n => + cases n with + | zero => exact v.projection.isIdempotentElem.eq + | succ n => + simp only [power,pow_succ,mul_assoc,v.mul_support] + | negSucc n => simp only [power,pow_succ,mul_assoc,v.star_mul_support] + +lemma support_power (v : PartialUnitary A) (k : ℤ) : v.support*v.power k=v.power k := by + cases k with + | ofNat n => + cases n with + | zero => exact v.projection.isIdempotentElem.eq + | succ n => simp only [power,pow_succ',←mul_assoc,v.support_mul] + | negSucc n => simp only [power,pow_succ',←mul_assoc,v.support_mul_star] + +lemma power_norm (v : PartialUnitary A) (k : ℤ) : ‖v.power k‖ ≤ 1 := by + have hp (a : A) (ha : ‖a‖ ≤ 1) (n : ℕ) : ‖a^(n+1)‖ ≤ 1 := + (norm_pow_le' a (Nat.succ_pos n)).trans (pow_le_one₀ (_root_.norm_nonneg _) ha) + cases k with + | ofNat n => + cases n with + | zero => exact v.projection.norm_le _ + | succ n => exact hp _ v.norm_le_one _ + | negSucc n => exact hp _ (by simpa using v.norm_le_one) _ + +lemma star_power (v : PartialUnitary A) (k : ℤ) : star (v.power k)=v.power (-k) := by + cases k with + | ofNat n => + cases n with + | zero => exact v.projection.isSelfAdjoint.star_eq + | succ n => simp only [power,star_pow]; rfl + | negSucc n => simp only [power,star_pow,star_star]; rfl + +lemma orthogonal_support_symm {v w : PartialUnitary A} + (h : v.support*w.support=0) : w.support*v.support=0 := by + simpa only [StarMul.star_mul,v.projection.isSelfAdjoint.star_eq,w.projection.isSelfAdjoint.star_eq, + star_zero] using congrArg star h + +lemma power_mul_power_zero {v w : PartialUnitary A} (h : v.support*w.support=0) + (k l : ℤ) : v.power k*w.power l=0 := by + calc + _=(v.power k*v.support)*(w.support*w.power l) := by rw [power_support,support_power] + _=0 := by rw [mul_assoc,←mul_assoc v.support,h,zero_mul,mul_zero] + +lemma val_mul_zero {v w : PartialUnitary A} (h : v.support*w.support=0) : v.val*w.val=0 := + by simpa [power] using power_mul_power_zero h 1 1 + +lemma star_val_mul_zero {v w : PartialUnitary A} (h : v.support*w.support=0) : + star v.val*w.val=0 := by simpa [power] using power_mul_power_zero h (Int.negSucc 0) 1 + +lemma val_mul_star_zero {v w : PartialUnitary A} (h : v.support*w.support=0) : + v.val*star w.val=0 := by simpa [power] using power_mul_power_zero h 1 (Int.negSucc 0) + +def add (v w : PartialUnitary A) (h : v.support*w.support=0) : PartialUnitary A where + val := v.val+w.val + support := v.support+w.support + projection := by + constructor + · dsimp [IsIdempotentElem] + rw [add_mul,mul_add,mul_add,v.projection.isIdempotentElem.eq, + w.projection.isIdempotentElem.eq,h,orthogonal_support_symm h] + simp + · exact v.projection.isSelfAdjoint.add w.projection.isSelfAdjoint + star_mul := by + rw [star_add,add_mul,mul_add,mul_add,v.star_mul,w.star_mul, + star_val_mul_zero h,star_val_mul_zero (orthogonal_support_symm h)] + simp + mul_star := by + rw [star_add,add_mul,mul_add,mul_add,v.mul_star,w.mul_star, + val_mul_star_zero h,val_mul_star_zero (orthogonal_support_symm h)] + simp + mul_support := by + have h1 := power_mul_power_zero h 1 0 + have h2 := power_mul_power_zero (orthogonal_support_symm h) 1 0 + simp [power] at h1 h2 + rw [add_mul,mul_add,mul_add,v.mul_support,w.mul_support,h1,h2] + simp + support_mul := by + have h1 := power_mul_power_zero h 0 1 + have h2 := power_mul_power_zero (orthogonal_support_symm h) 0 1 + simp [power] at h1 h2 + rw [add_mul,mul_add,mul_add,v.support_mul,w.support_mul,h1,h2] + simp + +lemma pow_add_of_mul_zero {a b : A} (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 => + have h1 : a^(n+1)*b=0 := by rw [pow_succ,mul_assoc,hab,mul_zero] + have h2 : b^(n+1)*a=0 := by rw [pow_succ,mul_assoc,hba,mul_zero] + rw [pow_succ,ih,add_mul,mul_add,mul_add,h1,h2] + simp only [add_zero,zero_add,←pow_succ] + +lemma add_power (v w : PartialUnitary A) (h : v.support*w.support=0) (k : ℤ) : + (v.add w h).power k=v.power k+w.power k := by + cases k with + | ofNat n => + cases n with + | zero => rfl + | succ n => + exact pow_add_of_mul_zero (val_mul_zero h) (val_mul_zero (orthogonal_support_symm h)) n + | negSucc n => + change (star (v.val+w.val))^(n+1)=(star v.val)^(n+1)+(star w.val)^(n+1) + rw [star_add] + apply pow_add_of_mul_zero + · simpa only [StarMul.star_mul,star_zero] using congrArg star (val_mul_zero (orthogonal_support_symm h)) + · simpa only [StarMul.star_mul,star_zero] using congrArg star (val_mul_zero h) + +def zero : PartialUnitary A where + val := 0 + support := 0 + projection := IsStarProjection.zero A + star_mul := by simp + mul_star := by simp + mul_support := by simp + support_mul := by simp + +@[simp] lemma zero_power (k : ℤ) : (zero : PartialUnitary A).power k=0 := by + cases k with + | ofNat n => cases n <;> simp [power,zero] + | negSucc n => simp [power,zero] + +end PartialUnitary + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryChain.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryChain.lean new file mode 100644 index 0000000000000000000000000000000000000000..15114042a9f5b27ac2f91bc17bf68964003995db --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryChain.lean @@ -0,0 +1,199 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryOrder +import OAI.Analysis.Commutator.PartialIsometryMaximal +import OAI.Analysis.Commutator.NormalGNS +import OAI.Analysis.Commutator.ProjectionChains +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter ContinuousLinearMapWOT + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +namespace Kadison.FinitePatching + +namespace PartialUnitary + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def toLink (v : PartialUnitary M) : PartialIsometryOrder.Link M 1 1 where + val := v.val + mem := v.val.property + triple := congrArg Subtype.val (show v.val*star v.val*v.val=v.val by + rw [v.mul_star,v.support_mul]) + source_le := by + have he : star (v.val : H →L[ℂ] H)*(v.val : H →L[ℂ] H)=v.support := + congrArg Subtype.val v.star_mul + rw [he] + exact (v.projection.map M.toStarSubalgebra.subtype).le_one + target_le := by + have he : (v.val : H →L[ℂ] H)*star (v.val : H →L[ℂ] H)=v.support := + congrArg Subtype.val v.mul_star + rw [he] + exact (v.projection.map M.toStarSubalgebra.subtype).le_one + +lemma toLink_initial (v : PartialUnitary M) : + (toLink M v).initial=(v.support : H →L[ℂ] H) := by + change (star v.val*v.val : M).val=v.support.val + exact congrArg Subtype.val v.star_mul + +lemma toLink_mono : Monotone (toLink M) := by + intro v w h + apply (PartialIsometryOrder.Link.le_def _ _).mpr + rw [toLink_initial,toLink_initial] + constructor + · exact h.1 + · change (w.val*v.support : M).val=v.val.val + exact congrArg Subtype.val h.2 + +theorem chain_upper_with_L2_and_membership (τ : M →ₚ[ℂ] ℂ) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (c : Set (PartialUnitary M)) (hc : IsChain (·≤·) c) (hne : c.Nonempty) : + ∃ v : PartialUnitary M, (∀ w∈c,w ≤ v) ∧ + (∀ R : VonNeumannAlgebra H, (∀ w∈c,(w.val : H →L[ℂ] H)∈R) → + (v.val : H →L[ℂ] H)∈R) ∧ + ∃ ω : Ultrafilter c, (ω : Filter c) ≤ atTop ∧ + Tendsto (fun w : c => (τ w.val.support).re) (ω : Filter c) (𝓝 (τ v.support).re) ∧ + Tendsto (fun w : c => TracialL2.norm τ (v.val-w.val.val)) (ω : Filter c) (𝓝 0) := by + classical + let : Nonempty c := hne.to_subtype + let : IsDirectedOrder c := hc.directedOn.isDirectedOrder + let ω : Ultrafilter c := Ultrafilter.of atTop + have hω : (ω : Filter c) ≤ atTop := Ultrafilter.of_le _ + let P : c → H →L[ℂ] H := fun w => w.val.support + obtain ⟨p,hp,hPp,hlim,hLeast⟩ := ProjectionChains.monotone_ultralimit ω hω P + (fun w => w.val.projection.map M.toStarSubalgebra.subtype) + (fun _ _ h => h.1) + have hscalar : ∀ x y, Tendsto (fun w : c => inner ℂ (P w x) y) (ω : Filter c) + (𝓝 (inner ℂ (p x) y)) := by + intro x y + have hh := tendsto_iff_forall_inner_apply_tendsto.mp hlim x y + simpa only [RCLike.star_def,inner_conj_symm,ofCLM_apply] using hh.star + have hpM : p∈M := WeakOperatorLimit.mem_vonNeumann hscalar M + (Eventually.of_forall fun w => w.val.support.property) + let ps : M := ⟨p,hpM⟩ + have hps : IsStarProjection ps := by + constructor + · exact Subtype.ext hp.isIdempotentElem.eq + · exact Subtype.ext hp.isSelfAdjoint.star_eq + have hcl : IsChain (·≤·) (toLink M '' c) := + hc.image_of_map_rel (·≤·) (·≤·) (toLink M) (fun _ _ h => toLink_mono M h) + obtain ⟨U,hU⟩ := PartialIsometryOrder.chain_has_upper M + (IsStarProjection.one _) (IsStarProjection.one _) (toLink M '' c) hcl + (hne.image (toLink M)) + have hUw (w : c) : toLink M w.val ≤ U := hU ⟨w.val,w.property,rfl⟩ + have hUP (w : c) : U.val*P w=(w.val.val : H →L[ℂ] H) := by + have hh := (PartialIsometryOrder.Link.le_def _ _).mp (hUw w) |>.2 + rw [toLink_initial] at hh + exact hh + have hpU : p ≤ U.initial := hLeast U.initial U.initial_projection (fun w => by + have hh := (PartialIsometryOrder.Link.le_def _ _).mp (hUw w) |>.1 + simpa only [toLink_initial] using hh) + have htarget (w : c) : U.val*P w*star U.val=P w := by + have hleft : U.val*star (w.val.val : H →L[ℂ] H)=P w := by + calc + _=U.val*((P w)*star (w.val.val : H →L[ℂ] H)) := by + rw [show P w*star (w.val.val : H →L[ℂ] H)=star (w.val.val : H →L[ℂ] H) from + congrArg Subtype.val w.val.support_mul_star] + _=P w := by + rw [←mul_assoc,hUP] + exact congrArg Subtype.val w.val.mul_star + have hright : (w.val.val : H →L[ℂ] H)*star U.val=P w := by + have hh := congrArg star hleft + have hpw : star (P w)=P w := + (w.val.projection.map M.toStarSubalgebra.subtype).isSelfAdjoint.star_eq + simpa only [StarMul.star_mul,star_star,hpw] using hh + rw [hUP,hright] + have hUpU : U.val*p*star U.val=p := by + ext x + apply ext_inner_right ℂ + intro y + have hl := hscalar (star U.val x) (star U.val y) + simp only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] at hl + have he : ∀ᶠ w : c in (ω : Filter c), + inner ℂ (U.val (P w (star U.val x))) y=inner ℂ (P w x) y := + Eventually.of_forall fun w => congrArg (fun T : H →L[ℂ] H => inner ℂ (T x) y) (htarget w) + exact tendsto_nhds_unique (hl.congr' he) (hscalar x y) + let a : M := ⟨U.val*p,M.mul_mem U.mem hpM⟩ + have hpa : star a*a=ps := by + apply Subtype.ext + change star (U.val*p)*(U.val*p)=p + rw [StarMul.star_mul,hp.isSelfAdjoint.star_eq] + have he := (hp.le_iff_mul_eq_left U.initial_projection).mp hpU + change p*(star U.val*U.val)=p at he + calc + _=(p*(star U.val*U.val))*p := by noncomm_ring + _=p := by rw [he,hp.isIdempotentElem.eq] + have hap : a*star a=ps := by + apply Subtype.ext + change (U.val*p)*star (U.val*p)=p + rw [StarMul.star_mul,hp.isSelfAdjoint.star_eq] + calc + _=U.val*(p*p)*star U.val := by noncomm_ring + _=p := by rw [hp.isIdempotentElem.eq,hUpU] + have haP : a*ps=a := by + apply Subtype.ext + change (U.val*p)*p=U.val*p + rw [mul_assoc,hp.isIdempotentElem.eq] + have hPa : ps*a=a := by rw [←hap,mul_assoc,hpa,haP] + let v : PartialUnitary M := ⟨a,ps,hps,hpa,hap,haP,hPa⟩ + have hupper (w : c) : w.val ≤ v := by + refine ⟨hPp w,?_⟩ + apply Subtype.ext + change (U.val*p)*P w=(w.val.val : H →L[ℂ] H) + have hm : p*P w=P w := + ((w.val.projection.map M.toStarSubalgebra.subtype).le_iff_mul_eq_right hp).mp (hPp w) + rw [mul_assoc,hm,hUP] + have htrace : Tendsto (fun w : c => (τ w.val.support).re) (ω : Filter c) (𝓝 (τ v.support).re) := by + exact (Complex.continuous_re.tendsto _).comp + (NormalGNS.tendsto_trace M τ hnormal (fun w : c => w.val.support) ps 1 + (fun w => w.val.projection.norm_le _) (hps.norm_le _) hscalar) + have hmember (R : VonNeumannAlgebra H) (hR : ∀ w∈c,(w.val : H →L[ℂ] H)∈R) : + (v.val : H →L[ℂ] H)∈R := by + apply WeakOperatorLimit.mem_vonNeumann (l:=(ω : Filter c)) + (T:=fun w : c => (w.val.val : H →L[ℂ] H)) _ R + (Eventually.of_forall fun w => hR w.val w.property) + intro x y + have hl := hscalar x (star U.val y) + simp only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] at hl + simpa only [←mul_apply_eq_comp,hUP] using hl + refine ⟨v,fun w hw => hupper ⟨w,hw⟩,hmember,ω,hω,htrace,?_⟩ + have hs : Tendsto (fun w : c => TracialL2.norm τ (v.val-w.val.val)^2) + (ω : Filter c) (𝓝 0) := by + have hh := (tendsto_const_nhds (x:=(τ v.support).re)).sub htrace + simp only [sub_self] at hh + exact hh.congr' (Eventually.of_forall fun w => (norm_sub_sq τ (hupper w)).symm) + have hh := hs.sqrt + simpa only [Real.sqrt_sq (TracialL2.norm_nonneg τ _),Real.sqrt_zero] using hh + +theorem chain_upper_with_L2 (τ : M →ₚ[ℂ] ℂ) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (c : Set (PartialUnitary M)) (hc : IsChain (·≤·) c) (hne : c.Nonempty) : + ∃ v : PartialUnitary M, (∀ w∈c,w ≤ v) ∧ + ∃ ω : Ultrafilter c, (ω : Filter c) ≤ atTop ∧ + Tendsto (fun w : c => (τ w.val.support).re) (ω : Filter c) (𝓝 (τ v.support).re) ∧ + Tendsto (fun w : c => TracialL2.norm τ (v.val-w.val.val)) (ω : Filter c) (𝓝 0) := by + obtain ⟨v,hv,_,hlim⟩ := chain_upper_with_L2_and_membership M τ hnormal c hc hne + exact ⟨v,hv,hlim⟩ + +end PartialUnitary + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryCompletion.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..cf4c922188dd7d4fe64498379a318f02be686d28 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryCompletion.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryOrder +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.PartialUnitary + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def ofUnitary (u : unitary A) : PartialUnitary A where + val := u + support := 1 + projection := IsStarProjection.one A + star_mul := u.property.1 + mul_star := u.property.2 + mul_support := mul_one _ + support_mul := one_mul _ + +def complement (v : PartialUnitary A) : PartialUnitary A where + val := 1-v.support + support := 1-v.support + projection := v.projection.one_sub + star_mul := by rw [v.projection.one_sub.isSelfAdjoint.star_eq]; exact v.projection.one_sub.isIdempotentElem.eq + mul_star := by rw [v.projection.one_sub.isSelfAdjoint.star_eq]; exact v.projection.one_sub.isIdempotentElem.eq + mul_support := v.projection.one_sub.isIdempotentElem.eq + support_mul := v.projection.one_sub.isIdempotentElem.eq + +omit [PartialOrder A] [StarOrderedRing A] in +lemma support_complement_zero (v : PartialUnitary A) : v.support*v.complement.support=0 := by + change v.support*(1-v.support)=0 + rw [mul_sub,mul_one,v.projection.isIdempotentElem.eq,sub_self] + +def completed (v : PartialUnitary A) : PartialUnitary A := v.add v.complement v.support_complement_zero + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma completed_val (v : PartialUnitary A) : v.completed.val=v.val+(1-v.support) := rfl + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma completed_support (v : PartialUnitary A) : v.completed.support=1 := by + change v.support+(1-v.support)=1 + abel + +lemma le_completed (v : PartialUnitary A) : v ≤ v.completed := v.le_add _ _ + +def completion (v : PartialUnitary A) : unitary A := + ⟨v.completed.val,by constructor <;> simp only [v.completed.star_mul,v.completed.mul_star,completed_support]⟩ + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma completion_val (v : PartialUnitary A) : (v.completion:A)=v.val+(1-v.support) := rfl + +omit [PartialOrder A] [StarOrderedRing A] in +lemma ofUnitary_completion (v : PartialUnitary A) : ofUnitary v.completion=v.completed := by + apply ext + rfl + +lemma completion_norm_sub (τ : A →ₚ[ℂ] ℂ) (hone : τ 1=1) (v : PartialUnitary A) : + TracialL2.norm τ (v.completed.val-v.val)=Real.sqrt (1-(τ v.support).re) := by + have hh := norm_sub_sq τ v.le_completed + rw [completed_support,hone,Complex.one_re] at hh + rw [←hh,Real.sqrt_sq (TracialL2.norm_nonneg τ _)] + +lemma completed_mem {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (M R : VonNeumannAlgebra H) (v : PartialUnitary M) (hv : (v.val : H →L[ℂ] H)∈R) : + (v.completed.val : H →L[ℂ] H)∈R := by + have hs : (v.support : H →L[ℂ] H)∈R := by + rw [←v.star_mul] + exact R.mul_mem (R.star_mem' hv) hv + exact R.add_mem hv (R.sub_mem R.one_mem hs) + +end Kadison.FinitePatching.PartialUnitary + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryHom.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryHom.lean new file mode 100644 index 0000000000000000000000000000000000000000..4057f3f475f13e0916b0c28f71eadd583197a938 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryHom.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryCompletion +import OAI.Analysis.Commutator.PartialUnitaryWords + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching + +variable {A B J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +namespace PartialUnitary + +def map (φ : A →⋆ₐ[ℂ] B) (v : PartialUnitary A) : PartialUnitary B where + val := φ v.val + support := φ v.support + projection := v.projection.map φ + star_mul := by rw [←map_star,←map_mul,v.star_mul] + mul_star := by rw [←map_star,←map_mul,v.mul_star] + mul_support := by rw [←map_mul,v.mul_support] + support_mul := by rw [←map_mul,v.support_mul] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +lemma map_power (φ : A →⋆ₐ[ℂ] B) (v : PartialUnitary A) (k : ℤ) : + φ (v.power k)=(v.map φ).power k := by + cases k with + | ofNat n => cases n <;> simp [power,map] + | negSucc n => simp [power,map,map_star] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +lemma map_ofUnitary (φ : A →⋆ₐ[ℂ] B) (u : unitary A) : + (ofUnitary u).map φ=ofUnitary ⟨φ u,Unitary.map_mem φ u.property⟩ := by + apply ext + rfl + +omit [PartialOrder A] [StarOrderedRing A] in +lemma ofUnitary_power_one (u : unitary A) : (ofUnitary u).power 1=(u:A) := by + simp [power,ofUnitary] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma ofUnitary_power_neg_one (u : unitary A) : (ofUnitary u).power (-1)=star (u:A) := by + change star (u:A)^1=star (u:A) + simp + +end PartialUnitary + +namespace Words + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +lemma map_slotPower (φ : A →⋆ₐ[ℂ] B) (k : K → ℤ) (v : PartialUnitary A) (s : Slot K) : + φ (slotPower k v s)=slotPower k (v.map φ) s := by + cases s with + | none => exact map_one φ + | some s => + cases s with + | none => rfl + | some i => exact v.map_power φ (k i) + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +lemma map_letter (φ : A →⋆ₐ[ℂ] B) (x : J → A) (k : K → ℤ) (v : PartialUnitary A) (i : Letter J K) : + φ (letter x k v i)=letter (φ ∘ x) k (v.map φ) i := by + simp only [letter,map_mul,map_slotPower,Function.comp_apply] + +omit [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] in +lemma map_word (φ : A →⋆ₐ[ℂ] B) (x : J → A) (k : K → ℤ) (v : PartialUnitary A) (l : List (Letter J K)) : + φ (word x k v l)=word (φ ∘ x) k (v.map φ) l := by + induction l with + | nil => exact map_one φ + | cons i l ih => simp only [word_cons,map_mul,map_letter,ih] + +end Words + +end Kadison.FinitePatching + +namespace Kadison.FinitePatching + +variable {A B J K : Type*} [CStarAlgebra A] [CStarAlgebra B] + +namespace PartialUnitary + +lemma map_power_algebra (φ : A →⋆ₐ[ℂ] B) (v : PartialUnitary A) (k : ℤ) : + φ (v.power k)=(v.map φ).power k := by + cases k with + | ofNat n => cases n <;> simp [power,map] + | negSucc n => simp [power,map,map_star] + +lemma map_ofUnitary_algebra (φ : A →⋆ₐ[ℂ] B) (u : unitary A) : + (ofUnitary u).map φ=ofUnitary ⟨φ u,Unitary.map_mem φ u.property⟩ := by + let : PartialOrder B := CStarAlgebra.spectralOrder B + let : StarOrderedRing B := CStarAlgebra.spectralOrderedRing B + apply ext + rfl + +end PartialUnitary + +namespace Words + +lemma map_word_algebra (φ : A →⋆ₐ[ℂ] B) (x : J → A) (k : K → ℤ) (v : PartialUnitary A) + (l : List (Letter J K)) : φ (word x k v l)=word (φ ∘ x) k (v.map φ) l := by + let : PartialOrder A := CStarAlgebra.spectralOrder A + let : StarOrderedRing A := CStarAlgebra.spectralOrderedRing A + let : PartialOrder B := CStarAlgebra.spectralOrder B + let : StarOrderedRing B := CStarAlgebra.spectralOrderedRing B + exact map_word φ x k v l + +end Words + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryOrder.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryOrder.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd2a41dfd8e04a550767aea787283e4c69ec620e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryOrder.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryAlgebra +import OAI.Analysis.Commutator.TracialL2Tools + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.PartialUnitary + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +omit [PartialOrder A] [StarOrderedRing A] in +@[ext] lemma ext {v w : PartialUnitary A} (h : v.val=w.val) : v=w := by + have hp : v.support=w.support := by rw [←v.star_mul,←w.star_mul,h] + cases v + cases w + cases h + cases hp + rfl + +instance : PartialOrder (PartialUnitary A) where + le v w := v.support ≤ w.support ∧ w.val*v.support=v.val + le_refl v := ⟨le_rfl,v.mul_support⟩ + le_trans v w u hvw hwu := by + refine ⟨hvw.1.trans hwu.1,?_⟩ + have h := (v.projection.le_iff_mul_eq_right w.projection).mp hvw.1 + calc + _=u.val*(w.support*v.support) := by rw [h] + _=v.val := by rw [←mul_assoc,hwu.2,hvw.2] + le_antisymm v w hvw hwv := by + apply ext + have h := le_antisymm hvw.1 hwv.1 + calc + v.val=w.val*v.support := hvw.2.symm + _=w.val := by rw [h,w.mul_support] + +lemma le_def (v w : PartialUnitary A) : v ≤ w ↔ + v.support ≤ w.support ∧ w.val*v.support=v.val := Iff.rfl + +lemma star_mul_of_le {v w : PartialUnitary A} (h : v ≤ w) : + star v.val*w.val=v.support := by + calc + _=star (w.val*v.support)*w.val := by rw [h.2] + _=v.support*w.support := by + rw [StarMul.star_mul,v.projection.isSelfAdjoint.star_eq,mul_assoc,w.star_mul] + _=v.support := (v.projection.le_iff_mul_eq_left w.projection).mp h.1 + +lemma mul_star_of_le {v w : PartialUnitary A} (h : v ≤ w) : + w.val*star v.val=v.support := by + calc + _=w.val*(v.support*star v.val) := by rw [v.support_mul_star] + _=v.support := by rw [←mul_assoc,h.2,v.mul_star] + +lemma support_mul_of_le {v w : PartialUnitary A} (h : v ≤ w) : + v.support*w.val=v.val := by + rw [←v.mul_star,mul_assoc,star_mul_of_le h,v.mul_support] + +lemma star_sub_mul_sub {v w : PartialUnitary A} (h : v ≤ w) : + star (w.val-v.val)*(w.val-v.val)=w.support-v.support := by + have h' : star w.val*v.val=v.support := by + simpa only [StarMul.star_mul,star_star,v.projection.isSelfAdjoint.star_eq] using + congrArg star (star_mul_of_le h) + rw [star_sub,sub_mul,mul_sub,mul_sub,w.star_mul,v.star_mul,star_mul_of_le h,h'] + noncomm_ring + +lemma norm_sub_sq (τ : A →ₚ[ℂ] ℂ) {v w : PartialUnitary A} (h : v ≤ w) : + TracialL2.norm τ (w.val-v.val)^2=(τ w.support).re-(τ v.support).re := by + rw [TracialL2.norm_sq,star_sub_mul_sub h,map_sub,Complex.sub_re] + +lemma le_add (v w : PartialUnitary A) (h : v.support*w.support=0) : v ≤ v.add w h := by + refine ⟨le_add_of_nonneg_right w.projection.nonneg,?_⟩ + change (v.val+w.val)*v.support=v.val + have hz := power_mul_power_zero (orthogonal_support_symm h) 1 0 + simp [power] at hz + rw [add_mul,v.mul_support,hz,add_zero] + +lemma zero_le (v : PartialUnitary A) : PartialUnitary.zero ≤ v := by + exact ⟨v.projection.nonneg,by simp [PartialUnitary.zero]⟩ + +end Kadison.FinitePatching.PartialUnitary + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialUnitaryWords.lean b/lean/OAI/Analysis/Commutator/PartialUnitaryWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..be902e3cf216bb32bd2eed1a2a864b82e5af6ee4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialUnitaryWords.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteWordTelescoping +import OAI.Analysis.Commutator.PartialUnitaryAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.FinitePatching + +namespace Words + +variable {A J K : Type*} [CStarAlgebra A] + +abbrev Slot (K : Type*) := Option (Option K) + +abbrev Letter (J K : Type*) := J × Slot K + +def NonzeroSlot (s : Slot K) : Prop := ∃ k,s=some (some k) + +def Valid (l : List (Letter J K)) : Prop := + ∀ s i t,l=s++i::t → t≠[] → NonzeroSlot i.2 + +lemma valid_of_internal (s : List (Letter J K)) (i : Letter J K) + (hs : ∀ j∈s,NonzeroSlot j.2) : Valid (s++[i]) := by + revert hs + induction s with + | nil => + intro hs a b c he hc + have hlen := congrArg List.length he + simp only [List.nil_append,List.length_cons,List.length_nil,List.length_append] at hlen + have hcl : 0 + intro hs a b c he hc + cases a with + | nil => + have hh := List.cons.inj he + have hb : j=b := hh.1 + subst b + exact hs j (by simp) + | cons a t => + have hh := List.cons.inj he + exact ih (fun z hz => hs z (by simp [hz])) t b c hh.2 hc + +lemma internal_prefix {l s t : List (Letter J K)} {i : Letter J K} + (hv : Valid l) (he : l=s++i::t) : ∀ j∈s,NonzeroSlot j.2 := by + intro j hj + obtain ⟨a,b,rfl⟩ := List.mem_iff_append.mp hj + apply hv a j (b++i::t) + · simpa only [List.append_assoc,List.cons_append] using he + · simp + +lemma internal_middle {l s t r : List (Letter J K)} {i j : Letter J K} + (hv : Valid l) (he : l=s++i::(t++j::r)) : ∀ b∈t,NonzeroSlot b.2 := by + intro b hb + have hp := internal_prefix hv (show l=(s++[i]++t)++j::r by + simpa only [List.append_assoc,List.singleton_append,List.cons_append,List.nil_append] using he) + exact hp b (by simp [hb]) + +lemma tail_nil_of_not_nonzero {l s t : List (Letter J K)} {i : Letter J K} + (hv : Valid l) (he : l=s++i::t) (hi : ¬NonzeroSlot i.2) : t=[] := by + by_contra ht + exact hi (hv s i t he ht) + +variable (x : J → A) (k : K → ℤ) + +def slotPower (v : PartialUnitary A) : Slot K → A + | none => 1 + | some none => v.support + | some (some i) => v.power (k i) + +def slotIncrement (w : PartialUnitary A) : Slot K → A + | none => 0 + | some none => w.support + | some (some i) => w.power (k i) + +def letter (v : PartialUnitary A) (i : Letter J K) : A := x i.1*slotPower k v i.2 + +def newLetter (w : PartialUnitary A) (i : Letter J K) : A := x i.1*slotIncrement k w i.2 + +def word (v : PartialUnitary A) (l : List (Letter J K)) : A := wordProduct (letter x k v) l + +@[simp] lemma word_nil (v : PartialUnitary A) : word x k v []=1 := rfl + +@[simp] lemma word_cons (v : PartialUnitary A) (i : Letter J K) (l : List (Letter J K)) : + word x k v (i::l)=letter x k v i*word x k v l := rfl + +lemma word_append (v : PartialUnitary A) (s t : List (Letter J K)) : + word x k v (s++t)=word x k v s*word x k v t := wordProduct_append _ _ _ + +@[simp] lemma word_open_last (v : PartialUnitary A) (s : List (Letter J K)) (j : J) : + word x k v (s++[(j,none)])=word x k v s*x j := by + simp [word_append,letter,slotPower] + +@[simp] lemma word_support_last (v : PartialUnitary A) (s : List (Letter J K)) (j : J) : + word x k v (s++[(j,some none)])=word x k v s*x j*v.support := by + simp [word_append,letter,slotPower,mul_assoc] + +lemma slotPower_norm (v : PartialUnitary A) (s : Slot K) : ‖slotPower k v s‖ ≤ 1 := by + cases s with + | none => exact (IsStarProjection.one A).norm_le _ + | some s => + cases s with + | none => exact v.projection.norm_le _ + | some i => exact v.power_norm _ + +lemma letter_norm (hx : ∀ j,‖x j‖ ≤ 1) (v : PartialUnitary A) (i : Letter J K) : + ‖letter x k v i‖ ≤ 1 := + (_root_.norm_mul_le _ _).trans ((mul_le_mul (hx _) (slotPower_norm k v _) + (_root_.norm_nonneg _) (by norm_num)).trans_eq (one_mul (1:ℝ))) + +lemma word_norm (hx : ∀ j,‖x j‖ ≤ 1) (v : PartialUnitary A) (l : List (Letter J K)) : + ‖word x k v l‖ ≤ 1 := by + induction l with + | nil => exact (IsStarProjection.one A).norm_le _ + | cons i l ih => + rw [word_cons] + exact (_root_.norm_mul_le _ _).trans ((mul_le_mul (letter_norm x k hx v i) ih + (_root_.norm_nonneg _) (by norm_num)).trans_eq (one_mul (1:ℝ))) + +lemma slotPower_add (v w : PartialUnitary A) (h : v.support*w.support=0) (s : Slot K) : + slotPower k (v.add w h) s=slotPower k v s+slotIncrement k w s := by + cases s with + | none => simp [slotPower,slotIncrement] + | some s => + cases s with + | none => rfl + | some i => exact v.add_power w h _ + +lemma letter_add (v w : PartialUnitary A) (h : v.support*w.support=0) (i : Letter J K) : + letter x k (v.add w h) i=letter x k v i+newLetter x k w i := by + simp only [letter,newLetter,slotPower_add,mul_add] + +lemma word_add (v w : PartialUnitary A) (h : v.support*w.support=0) (l : List (Letter J K)) : + word x k (v.add w h) l=wordProduct (fun i => letter x k v i+newLetter x k w i) l := by + unfold word + congr 1 + funext i + exact letter_add x k v w h i + +end Words + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialWordContinuity.lean b/lean/OAI/Analysis/Commutator/PartialWordContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0ec341e5ef045ca88b133d1fd03782bf14e77cb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialWordContinuity.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialWordPerturbation +import OAI.Analysis.Commutator.TracialL2Continuity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +include hτ in +lemma PartialUnitary.support_norm_sub (v w : PartialUnitary A) : + TracialL2.norm τ (v.support-w.support) ≤ 2*TracialL2.norm τ (v.val-w.val) := by + rw [←v.star_mul,←w.star_mul] + have hh := TracialL2.norm_mul_sub_mul τ hτ (star v.val) v.val (star w.val) w.val + rw [←star_sub,TracialL2.norm_star τ hτ,_root_.norm_star] at hh + exact hh.trans (by + have h1 := mul_le_of_le_one_right (TracialL2.norm_nonneg τ (v.val-w.val)) v.norm_le_one + have h2 := mul_le_of_le_one_left (TracialL2.norm_nonneg τ (v.val-w.val)) w.norm_le_one + linarith) + +include hτ in +lemma PartialUnitary.power_norm_sub (v w : PartialUnitary A) (k : ℤ) : + TracialL2.norm τ (v.power k-w.power k) ≤ ((k.natAbs:ℝ)+2)*TracialL2.norm τ (v.val-w.val) := by + cases k with + | ofNat n => + cases n with + | zero => simpa only [PartialUnitary.power,Int.natAbs_ofNat',Nat.cast_zero,zero_add] using + support_norm_sub τ hτ v w + | succ n => + have hh := TracialL2.norm_pow_sub_pow τ hτ v.val w.val v.norm_le_one w.norm_le_one (n+1) + change TracialL2.norm τ (v.val^(n+1)-w.val^(n+1)) ≤ _ + simp only [Int.natAbs_ofNat'] + exact hh.trans (mul_le_mul_of_nonneg_right (by linarith) (TracialL2.norm_nonneg τ _)) + | negSucc n => + have hh := TracialL2.norm_pow_sub_pow τ hτ (star v.val) (star w.val) + (by simpa using v.norm_le_one) (by simpa using w.norm_le_one) (n+1) + rw [←star_sub,TracialL2.norm_star τ hτ] at hh + change TracialL2.norm τ ((star v.val)^(n+1)-(star w.val)^(n+1)) ≤ _ + simp only [Int.natAbs_negSucc] + exact hh.trans (mul_le_mul_of_nonneg_right (by linarith) (TracialL2.norm_nonneg τ _)) + +namespace Words + +variable (x : J → A) (k : K → ℤ) + +def slotCost : Slot K → ℕ + | none => 0 + | some none => 2 + | some (some i) => (k i).natAbs+2 + +def wordCost (l : List (Letter J K)) : ℕ := (l.map (fun i => slotCost k i.2)).sum + +include hτ in +lemma slotPower_norm_sub (v w : PartialUnitary A) (s : Slot K) : + TracialL2.norm τ (slotPower k v s-slotPower k w s) ≤ + (slotCost k s:ℝ)*TracialL2.norm τ (v.val-w.val) := by + cases s with + | none => simp [slotPower,slotCost,TracialL2.norm] + | some s => + cases s with + | none => exact v.support_norm_sub τ hτ w + | some i => simpa only [slotPower,slotCost,Nat.cast_add,Nat.cast_ofNat] using + v.power_norm_sub τ hτ w (k i) + +include hτ in +lemma letter_norm_sub (hx : ∀ j,‖x j‖ ≤ 1) (v w : PartialUnitary A) (i : Letter J K) : + TracialL2.norm τ (letter x k v i-letter x k w i) ≤ + (slotCost k i.2:ℝ)*TracialL2.norm τ (v.val-w.val) := by + simp only [letter,←mul_sub] + exact (TracialL2.norm_mul_left τ _ _).trans + ((mul_le_of_le_one_left (TracialL2.norm_nonneg τ _) (hx i.1)).trans + (slotPower_norm_sub τ hτ k v w i.2)) + +include hτ in +lemma word_norm_sub (hx : ∀ j,‖x j‖ ≤ 1) (v w : PartialUnitary A) (l : List (Letter J K)) : + TracialL2.norm τ (word x k v l-word x k w l) ≤ + (wordCost k l:ℝ)*TracialL2.norm τ (v.val-w.val) := by + induction l with + | nil => simp [wordCost,TracialL2.norm] + | cons i l ih => + rw [word_cons,word_cons] + have hh := TracialL2.norm_mul_sub_mul τ hτ (letter x k v i) (word x k v l) + (letter x k w i) (word x k w l) + have h1 := (mul_le_of_le_one_right (TracialL2.norm_nonneg τ _) + (word_norm x k hx v l)).trans (letter_norm_sub τ hτ x k hx v w i) + have h2 := (mul_le_of_le_one_left (TracialL2.norm_nonneg τ _) + (letter_norm x k hx w i)).trans ih + exact hh.trans ((add_le_add h1 h2).trans_eq (by + simp only [wordCost,List.map_cons,List.sum_cons,Nat.cast_add]; ring)) + +include hτ in +lemma trace_word_norm_sub (hone : τ 1=1) (hx : ∀ j,‖x j‖ ≤ 1) + (v w : PartialUnitary A) (l : List (Letter J K)) : + ‖τ (word x k v l)-τ (word x k w l)‖ ≤ + (wordCost k l:ℝ)*TracialL2.norm τ (v.val-w.val) := by + rw [←map_sub] + exact (TracialL2.norm_trace_le τ hτ hone _).trans (word_norm_sub τ hτ x k hx v w l) + +include hτ in +lemma momentBound_limit {I : Type*} {f : Filter I} [NeBot f] + (hone : τ 1=1) (hx : ∀ j,‖x j‖ ≤ 1) + (v : I → PartialUnitary A) (w : PartialUnitary A) (B : I → ℝ) (b : ℝ) (N : ℕ) + (hv : Tendsto (fun i => TracialL2.norm τ ((v i).val-w.val)) f (𝓝 0)) + (hB : Tendsto B f (𝓝 b)) (hb : ∀ i,MomentBound τ x k (v i) N (B i)) : + MomentBound τ x k w N b := by + have hpow (i : K) : Tendsto (fun j => τ ((v j).power (k i))) f (𝓝 (τ (w.power (k i)))) := by + apply TracialL2.tendsto_trace τ hτ hone + have hh := hv.const_mul ((k i).natAbs+2:ℝ) + rw [mul_zero] at hh + exact squeeze_zero (fun _ => TracialL2.norm_nonneg τ _) (fun j => + (v j).power_norm_sub τ hτ w (k i)) hh + refine ⟨fun i => le_of_tendsto_of_tendsto (hpow i |>.norm) hB + (Eventually.of_forall fun j => (hb j).1 i),?_⟩ + intro l hl hlen hvalid + have hw : Tendsto (fun j => τ (word x k (v j) l)) f (𝓝 (τ (word x k w l))) := by + apply TracialL2.tendsto_trace τ hτ hone + have hh := hv.const_mul (wordCost k l:ℝ) + rw [mul_zero] at hh + exact squeeze_zero (fun _ => TracialL2.norm_nonneg τ _) (fun j => word_norm_sub τ hτ x k hx + (v j) w l) hh + exact le_of_tendsto_of_tendsto hw.norm hB (Eventually.of_forall fun j => (hb j).2 l hl hlen hvalid) + +end Words + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialWordPerturbation.lean b/lean/OAI/Analysis/Commutator/PartialWordPerturbation.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ff7c49aa1db40b4e13780924a40ead4581d773b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialWordPerturbation.lean @@ -0,0 +1,178 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerCenteredEstimates +import OAI.Analysis.Commutator.PartialUnitaryWords + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching + +namespace Words + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +variable (x : J → A) (k : K → ℤ) + +def MomentBound (v : PartialUnitary A) (N : ℕ) (B : ℝ) : Prop := + (∀ i,‖τ (v.power (k i))‖ ≤ B) ∧ + ∀ l : List (Letter J K), l≠[] → l.length ≤ N → Valid l → ‖τ (word x k v l)‖ ≤ B + +include hτ in +lemma open_scalar_bound {v : PartialUnitary A} {N : ℕ} {B η : ℝ} + (hbound : MomentBound τ x k v N B) (hη : 0<η) (hrest : η ≤ (τ (1-v.support)).re) + (s : List (Letter J K)) (j : J) (hlen : s.length+1 ≤ N) + (hs : ∀ i∈s,NonzeroSlot i.2) : + ‖cornerScalar τ (1-v.support) (word x k v s*x j)‖ ≤ 2*B/η := by + apply cornerScalar_complement_bound τ v.projection _ hη hrest + · have hh := hbound.2 (s++[(j,none)]) (by simp) + (by simpa only [List.length_append,List.length_singleton] using hlen) + (valid_of_internal s _ hs) + simpa only [word_open_last] using hh + · have hh := hbound.2 (s++[(j,some none)]) (by simp) + (by simpa only [List.length_append,List.length_singleton] using hlen) + (valid_of_internal s _ hs) + rw [word_support_last,hτ] at hh + exact hh + +omit [PartialOrder A] [StarOrderedRing A] in +lemma slotIncrement_left (w : PartialUnitary A) (s : Slot K) : + w.support*slotIncrement k w s=slotIncrement k w s := by + cases s with + | none => simp [slotIncrement] + | some s => + cases s with + | none => exact w.projection.isIdempotentElem.eq + | some i => exact w.support_power _ + +omit [PartialOrder A] [StarOrderedRing A] in +lemma slotIncrement_right (w : PartialUnitary A) (s : Slot K) : + slotIncrement k w s*w.support=slotIncrement k w s := by + cases s with + | none => simp [slotIncrement] + | some s => + cases s with + | none => exact w.projection.isIdempotentElem.eq + | some i => exact w.power_support _ + +omit [PartialOrder A] [StarOrderedRing A] in +lemma slotIncrement_norm (w : PartialUnitary A) (s : Slot K) : + ‖slotIncrement k w s‖ ≤ 1 := by + cases s with + | none => simp [slotIncrement] + | some s => + cases s with + | none => exact w.projection.norm_le _ + | some i => exact w.power_norm _ + +include hτ in +theorem word_perturbation_bound (hx : ∀ j,‖x j‖ ≤ 1) + (v w : PartialUnitary A) (horth : v.support*w.support=0) + (hqp : w.support ≤ 1-v.support) {N : ℕ} {B δ η : ℝ} + (hB : 0 ≤ B) (hδ : 0 ≤ δ) (hη : 0<η) (hrest : η ≤ (τ (1-v.support)).re) + (hbound : MomentBound τ x k v N B) + (hsmall : ∀ (s : List (Letter J K)) (j : J), s.length ≤ N → + TracialL2.norm τ (w.support*cornerCenter τ (1-v.support) (word x k v s*x j)*w.support)^2 ≤ + δ^2*(τ w.support).re) + (hphase : ∀ (s t : List (Letter J K)) (j : J) (i : K), + s.length ≤ N → t.length ≤ N → + ‖τ (w.power (k i)*(word x k v t*word x k v s*x j))‖ ≤ δ*(τ w.support).re) + (l : List (Letter J K)) (hlen : l.length ≤ N) (hv : Valid l) : + ‖τ (word x k (v.add w horth) l)-τ (word x k v l)‖ ≤ + ((l.length:ℝ)+(l.length:ℝ)^2)*(δ+2*B/η)*(τ w.support).re := by + have hqt : 0 ≤ (τ w.support).re := (τ.map_nonneg w.projection.nonneg).1 + have hc : 0 ≤ δ+2*B/η := by positivity + have hS : 0 ≤ (δ+2*B/η)*(τ w.support).re := mul_nonneg hc hqt + have hlen1 : ∀ s i t,l=s++i::t → s.length+1 ≤ N ∧ t.length ≤ N := by + intro s i t he + have hh : s.length+1+t.length ≤ N := by + simpa only [he,List.length_append,List.length_cons,Nat.add_assoc,Nat.add_left_comm,Nat.add_comm] using hlen + omega + have hsingle : ∀ s i t,l=s++i::t → + ‖τ (wordProduct (letter x k v) s*newLetter x k w i*wordProduct (letter x k v) t)‖ ≤ + (δ+2*B/η)*(τ w.support).re := by + intro s i t he + rcases i with ⟨j,i⟩ + cases i with + | none => simp [newLetter,slotIncrement,hS] + | some i => + cases i with + | none => + have ht : t=[] := tail_nil_of_not_nonzero hv he (by simp [NonzeroSlot]) + subst t + have hs := internal_prefix hv he + have hsc := open_scalar_bound τ hτ x k hbound hη hrest s j (hlen1 s _ [] he).1 hs + have hh := trace_single_support_bound τ hτ v.projection.one_sub w.projection hqp + (word x k v s*x j) hδ (hsmall s j (by have hh := (hlen1 s _ [] he).1; omega)) + have hcq := mul_le_mul_of_nonneg_right (add_le_add (le_refl δ) hsc) hqt + calc + _=‖τ (w.support*(word x k v s*x j))‖ := by + simp only [wordProduct_nil,mul_one,newLetter,slotIncrement,←mul_assoc] + rw [hτ] + simp only [word,mul_assoc] + _ ≤ (δ+‖cornerScalar τ (1-v.support) (word x k v s*x j)‖)*(τ w.support).re := hh + _ ≤ _ := hcq + | some i => + have hp := hphase s t j i (by have hh := (hlen1 s _ t he).1; omega) + (hlen1 s _ t he).2 + have heq : τ (wordProduct (letter x k v) s*newLetter x k w (j,some (some i))* + wordProduct (letter x k v) t)= + τ (w.power (k i)*(word x k v t*word x k v s*x j)) := by + change τ (word x k v s*(x j*w.power (k i))*word x k v t)=_ + calc + _=τ ((word x k v s*x j)*(w.power (k i)*word x k v t)) := by congr 1; noncomm_ring + _=τ ((w.power (k i)*word x k v t)*(word x k v s*x j)) := hτ _ _ + _=_ := by congr 1; noncomm_ring + rw [heq] + exact hp.trans (mul_le_mul_of_nonneg_right (le_add_of_nonneg_right (by positivity)) hqt) + have hdouble : ∀ s i t j r,l=s++i::(t++j::r) → + ‖τ (wordProduct (letter x k v) s*newLetter x k w i* + wordProduct (letter x k v) t*newLetter x k w j* + wordProduct (fun b => letter x k v b+newLetter x k w b) r)‖ ≤ + (δ+2*B/η)*(τ w.support).re := by + intro s i t j r he + have htlen : t.length+1 ≤ N := by + have hh := hlen + rw [he,List.length_append,List.length_cons,List.length_append,List.length_cons] at hh + omega + have hts := internal_middle hv he + have hsc := open_scalar_bound τ hτ x k hbound hη hrest t j.1 htlen hts + have han : ‖word x k v s*x i.1‖ ≤ 1 := + (_root_.norm_mul_le _ _).trans ((mul_le_mul (word_norm x k hx v s) (hx _) + (_root_.norm_nonneg _) (by norm_num)).trans_eq (one_mul (1:ℝ))) + have hh := trace_centered_compression_bound τ hτ v.projection.one_sub w.projection hqp + (slotIncrement_right k w i.2) (slotIncrement_left k w j.2) + han (word_norm x k hx (v.add w horth) r) + (slotIncrement_norm k w i.2) (slotIncrement_norm k w j.2) + hδ (hsmall t j.1 (by omega)) + have heq : wordProduct (letter x k v) s*newLetter x k w i* + wordProduct (letter x k v) t*newLetter x k w j* + wordProduct (fun b => letter x k v b+newLetter x k w b) r= + (word x k v s*x i.1)*slotIncrement k w i.2*(word x k v t*x j.1)* + slotIncrement k w j.2*word x k (v.add w horth) r := by + rw [word_add] + simp only [newLetter,word,mul_assoc] + rw [heq] + exact hh.trans (mul_le_mul_of_nonneg_right (add_le_add (le_refl δ) hsc) hqt) + rw [word_add] + exact (trace_word_second_order_bound τ.toLinearMap (letter x k v) (newLetter x k w) + l hS hS hsingle hdouble).trans_eq (by ring) + +end Words + +end Kadison.FinitePatching + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartialWordReindex.lean b/lean/OAI/Analysis/Commutator/PartialWordReindex.lean new file mode 100644 index 0000000000000000000000000000000000000000..9013f163f61d1c828ca1e94c5f54f764bf051ad3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartialWordReindex.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialWordPerturbation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.FinitePatching.Words + +variable {A J K J' K' : Type*} [CStarAlgebra A] + +def mapLetter (f : J' → J) (g : K' → K) (i : Letter J' K') : Letter J K := + (f i.1,i.2.map (Option.map g)) + +lemma valid_cons_iff (i : Letter J K) (l : List (Letter J K)) : + Valid (i::l) ↔ Valid l ∧ (l≠[] → NonzeroSlot i.2) := by + constructor + · intro h + constructor + · intro s j t he ht + exact h (i::s) j t (by simpa only [List.cons_append] using congrArg (List.cons i) he) ht + · intro hl + exact h [] i l rfl hl + · rintro ⟨hl,hi⟩ s j t he ht + cases s with + | nil => + have hh := List.cons.inj he + obtain ⟨rfl,rfl⟩ := hh + exact hi ht + | cons a s => + have hh := List.cons.inj he + exact hl s j t hh.2 ht + +lemma valid_map (f : J' → J) (g : K' → K) {l : List (Letter J' K')} (h : Valid l) : + Valid (l.map (mapLetter f g)) := by + induction l with + | nil => + intro s i t he ht + have hh := congrArg List.length he + simp only [List.map_nil,List.length_nil,List.length_append,List.length_cons] at hh + omega + | cons i l ih => + rw [List.map_cons,valid_cons_iff] + have hh := (valid_cons_iff i l).mp h + refine ⟨ih hh.1,?_⟩ + intro hn + have hl : l≠[] := by intro he; subst l; exact hn rfl + obtain ⟨k,hk⟩ := hh.2 hl + refine ⟨g k,?_⟩ + simp [mapLetter,hk] + +lemma slotPower_reindex (k : K → ℤ) (g : K' → K) (v : PartialUnitary A) (s : Slot K') : + slotPower k v (s.map (Option.map g))=slotPower (k ∘ g) v s := by + cases s with + | none => rfl + | some s => cases s <;> rfl + +lemma letter_reindex (x : J → A) (k : K → ℤ) (f : J' → J) (g : K' → K) + (v : PartialUnitary A) (i : Letter J' K') : + letter x k v (mapLetter f g i)=letter (x ∘ f) (k ∘ g) v i := by + exact congrArg (x (f i.1)*·) (slotPower_reindex k g v i.2) + +lemma word_reindex (x : J → A) (k : K → ℤ) (f : J' → J) (g : K' → K) + (v : PartialUnitary A) (l : List (Letter J' K')) : + word x k v (l.map (mapLetter f g))=word (x ∘ f) (k ∘ g) v l := by + induction l with + | nil => rfl + | cons i l ih => simp only [List.map_cons,word_cons,letter_reindex,ih] + +variable [PartialOrder A] + +lemma momentBound_reindex (τ : A →ₚ[ℂ] ℂ) (x : J → A) (k : K → ℤ) + (f : J' → J) (g : K' → K) (v : PartialUnitary A) {N : ℕ} {B : ℝ} + (h : MomentBound τ x k v N B) : MomentBound τ (x ∘ f) (k ∘ g) v N B := by + refine ⟨fun i => h.1 (g i),?_⟩ + intro l hn hl hv + rw [←word_reindex] + exact h.2 _ (by intro he; apply hn; exact List.length_eq_zero_iff.mp (by simpa only [List.length_map,List.length_nil] using congrArg List.length he)) (by simpa only [List.length_map] using hl) + (valid_map f g hv) + +end Kadison.FinitePatching.Words + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartitionRank.lean b/lean/OAI/Analysis/Commutator/PartitionRank.lean new file mode 100644 index 0000000000000000000000000000000000000000..2ac59334eaacd50aa049b20f9e8ac68e4debb23b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartitionRank.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Commutator.EqualProjectionPartition +import OAI.Analysis.Commutator.PartitionRankComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance partitionRankDecidableEq : DecidableEq ι := Classical.decEq ι + +def rank (e : H →L[ℂ] H) : ℕ := by + classical + exact Nat.findGreatest (fun k => ∃ s : Finset ι,s.card=k ∧ SubEquivalent M (D.part s) e) + (Fintype.card ι) + +lemma rank_le_card (e : H →L[ℂ] H) : D.rank e≤Fintype.card ι := by + classical + exact Nat.findGreatest_le _ + +lemma exists_rank (e : H →L[ℂ] H) (he : IsStarProjection e) : + ∃ s : Finset ι,s.card=D.rank e ∧ SubEquivalent M (D.part s) e := by + classical + apply Nat.findGreatest_spec (P := fun k => ∃ s : Finset ι, s.card=k ∧ SubEquivalent M (D.part s) e) + (Nat.zero_le (Fintype.card ι)) + exact ⟨∅,by simp,by simpa only [D.part_empty] using + subEquivalent_of_le M.zero_mem (IsStarProjection.zero _) he.nonneg⟩ + +lemma card_le_rank_of_subEquivalent {e : H →L[ℂ] H} (s : Finset ι) + (h : SubEquivalent M (D.part s) e) : s.card≤D.rank e := by + classical + exact Nat.le_findGreatest (Finset.card_le_univ s) ⟨s,rfl,h⟩ + +lemma part_subEquivalent_of_card_le_rank {e : H →L[ℂ] H} (he : IsStarProjection e) + (s : Finset ι) (hs : s.card≤D.rank e) : SubEquivalent M (D.part s) e := by + obtain ⟨t,ht,hte⟩ := D.exists_rank e he + exact (D.part_subEquivalent_of_card_le s t (ht ▸ hs)).trans + (D.part_projection s) (D.part_projection t) hte + +lemma part_subEquivalent_iff_card_le_rank {e : H →L[ℂ] H} (he : IsStarProjection e) + (s : Finset ι) : SubEquivalent M (D.part s) e ↔ s.card≤D.rank e := + ⟨D.card_le_rank_of_subEquivalent s,D.part_subEquivalent_of_card_le_rank he s⟩ + +lemma rank_mono_subEquivalent {e f : H →L[ℂ] H} + (he : IsStarProjection e) (h : SubEquivalent M e f) : D.rank e≤D.rank f := by + obtain ⟨s,hs,hse⟩ := D.exists_rank e he + rw [←hs] + exact D.card_le_rank_of_subEquivalent s (hse.trans (D.part_projection s) he h) + +lemma rank_congr_equivalent {e f : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) (h : Equivalent M e f) : D.rank e=D.rank f := + Nat.le_antisymm (D.rank_mono_subEquivalent he h.subEquivalent) + (D.rank_mono_subEquivalent hf h.symm.subEquivalent) + +lemma rank_mono {e f : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) (hef : e≤f) : + D.rank e≤D.rank f := D.rank_mono_subEquivalent he (subEquivalent_of_le heM he hef) + +lemma rank_part [Nontrivial H] (hfin : IsFiniteAlgebra M) (s : Finset ι) : D.rank (D.part s)=s.card := by + obtain ⟨t,ht,hts⟩ := D.exists_rank (D.part s) (D.part_projection s) + apply Nat.le_antisymm + · rw [←ht] + exact D.card_le_of_part_subEquivalent hfin t s hts + · exact D.card_le_rank_of_subEquivalent s + (subEquivalent_of_le (D.part_mem s) (D.part_projection s) le_rfl) + +lemma rank_one : D.rank 1=Fintype.card ι := by + apply Nat.le_antisymm (D.rank_le_card 1) + simpa only [Finset.card_univ] using D.card_le_rank_of_subEquivalent Finset.univ + (subEquivalent_of_le (D.part_mem Finset.univ) (D.part_projection Finset.univ) + (D.part_univ.le)) + +lemma rank_zero [Nontrivial H] (hfin : IsFiniteAlgebra M) : D.rank 0=0 := by + simpa only [D.part_empty,Finset.card_empty] using D.rank_part hfin ∅ + +end EqualPartition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PartitionRankComparison.lean b/lean/OAI/Analysis/Commutator/PartitionRankComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca5af675f56a2b6abca0338976c25aee2a4ae9ad --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PartitionRankComparison.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.EqualPartitionSums + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace EqualPartition + +variable {M : VonNeumannAlgebra H} {ι : Type*} [Fintype ι] + +variable (D : EqualPartition M ι) + +local instance : DecidableEq ι := Classical.decEq ι + +lemma piece_mul_part_of_mem (s : Finset ι) {i : ι} (hi : i∈s) : + D.piece i*D.part s=D.piece i := by + rw [part,Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · exact (D.piece_projection i).isIdempotentElem.eq + · intro j hj hne + exact D.piece_cross i j hne.symm + +lemma piece_mul_part_of_not_mem (s : Finset ι) {i : ι} (hi : i∉s) : + D.piece i*D.part s=0 := orthogonal_mul_sum_eq_zero D.piece D.piece_cross s hi + +lemma part_injective [Nontrivial H] : Function.Injective D.part := by + intro s t hst + apply Finset.ext + intro i + constructor + · intro hi + by_contra ht + have h := D.piece_mul_part_of_mem s hi + rw [hst,D.piece_mul_part_of_not_mem t ht] at h + exact D.piece_ne_zero i h.symm + · intro hi + by_contra hs + have h := D.piece_mul_part_of_mem t hi + rw [←hst,D.piece_mul_part_of_not_mem s hs] at h + exact D.piece_ne_zero i h.symm + +lemma card_le_of_part_subEquivalent [Nontrivial H] (hfin : IsFiniteAlgebra M) + (s t : Finset ι) (h : SubEquivalent M (D.part s) (D.part t)) : s.card≤t.card := by + by_contra hle + have hlt : t.card scalarExtract (X.val i j 0 0)) + +def rightDiagonal (X : matrices (system A) ι) : CStarMatrix ι ι ℂ := + CStarMatrix.ofMatrix (fun i j => scalarExtract (X.val i j 1 1)) + +def offDiagonal (X : matrices (system A) ι) : CStarMatrix ι ι A := + CStarMatrix.ofMatrix (fun i j => X.val i j 0 1) + +omit [Nontrivial A] in +lemma lower_entry (X : matrices (system A) ι) (hX : 0≤X.val) (i j : ι) : + X.val i j 1 0=star (X.val j i 0 1) := by + exact (congrArg (fun Z : CStarMatrix ι ι (CStarMatrix (Fin 2) (Fin 2) A) => Z i j 1 0) + (IsSelfAdjoint.of_nonneg hX).star_eq).symm + +lemma source_block (X : matrices (system A) ι) (hX : 0≤X.val) : + MatrixGNS.shuffle ι (Fin 2) X.val= + block (scalarMatrix (leftDiagonal X)) (offDiagonal X) (star (offDiagonal X)) + (scalarMatrix (rightDiagonal X)) := by + ext i j k l + rw [MatrixGNS.shuffle_apply] + fin_cases i <;> fin_cases j + · exact (scalar_reconstruct00 ⟨X.val k l,X.property k l⟩).symm + · rfl + · exact lower_entry X hX k l + · exact (scalar_reconstruct11 ⟨X.val k l,X.property k l⟩).symm + +omit [Nontrivial A] in +lemma output_block (f : A →ₗ[ℂ] B) (X : matrices (system A) ι) (hX : 0≤X.val) : + MatrixGNS.shuffle ι (Fin 2) (mapMatrix (system A) (systemMap f) X)= + block (scalarMatrix (leftDiagonal X)) (CStarMatrix.mapₗ f (offDiagonal X)) + (star (CStarMatrix.mapₗ f (offDiagonal X))) (scalarMatrix (rightDiagonal X)) := by + ext i j k l + rw [MatrixGNS.shuffle_apply] + fin_cases i <;> fin_cases j + · rfl + · rfl + · change star (f (star (X.val k l 1 0)))=star (f (X.val l k 0 1)) + rw [lower_entry X hX,star_star] + · rfl + +lemma source_nonneg (X : matrices (system A) ι) (hX : 0≤X.val) : + 0 ≤ block (scalarMatrix (A:=A) (leftDiagonal X)) (offDiagonal X) + (star (offDiagonal X)) (scalarMatrix (rightDiagonal X)) := by + rw [←source_block X hX] + exact map_nonneg (MatrixGNS.shuffle ι (Fin 2)) hX + +lemma diagonal_nonneg_pair (X : matrices (system A) ι) (hX : 0≤X.val) : + 0≤leftDiagonal X ∧ 0≤rightDiagonal X := by + have hblock := source_nonneg X hX + have hpA : 0 ≤ scalarMatrix (A:=A) (leftDiagonal X) := by + simpa only [block00] using diagonal_nonneg _ hblock 0 + have hqA : 0 ≤ scalarMatrix (A:=A) (rightDiagonal X) := by + simpa only [block11] using diagonal_nonneg _ hblock 1 + exact ⟨(@faithfulStar_nonneg_iff + (CStarMatrix ι ι ℂ) (CStarMatrix ι ι A) + inferInstance inferInstance inferInstance inferInstance inferInstance inferInstance + (scalarMatrix (A:=A)) scalarMatrix_injective _).mp hpA, + (@faithfulStar_nonneg_iff + (CStarMatrix ι ι ℂ) (CStarMatrix ι ι A) + inferInstance inferInstance inferInstance inferInstance inferInstance inferInstance + (scalarMatrix (A:=A)) scalarMatrix_injective _).mp hqA⟩ + +lemma target_nonneg (f : A →ₗ[ℂ] B) (hf : IsCompletelyContractive f) + (X : matrices (system A) ι) (hX : 0≤X.val) : + 0 ≤ block (scalarMatrix (A:=B) (leftDiagonal X)) (CStarMatrix.mapₗ f (offDiagonal X)) + (star (CStarMatrix.mapₗ f (offDiagonal X))) (scalarMatrix (rightDiagonal X)) := by + obtain ⟨hp,hq⟩ := diagonal_nonneg_pair X hX + exact @transfer_nonneg + (CStarMatrix ι ι A) (CStarMatrix ι ι B) (CStarMatrix ι ι ℂ) + inferInstance inferInstance inferInstance inferInstance inferInstance inferInstance + inferInstance inferInstance inferInstance + (scalarMatrix (A:=A)) (scalarMatrix (A:=B)) + (CStarMatrix.mapₗ f) (hf ι) (fun c a d => map_scalar_bimodule f c d a) + (leftDiagonal X) (rightDiagonal X) hp hq (offDiagonal X) (source_nonneg X hX) + +lemma output_nonneg (f : A →ₗ[ℂ] B) (hf : IsCompletelyContractive f) + (X : matrices (system A) ι) (hX : 0≤X.val) : + 0 ≤ mapMatrix (system A) (systemMap f) X := by + have ho := target_nonneg f hf X hX + rw [←output_block f X hX] at ho + simpa only [StarAlgEquiv.symm_apply_apply] using map_nonneg (MatrixGNS.shuffle ι (Fin 2)).symm ho + +end MatrixTest + +theorem systemMap_completelyPositive [Nontrivial A] (f : A →ₗ[ℂ] B) + (hf : IsCompletelyContractive f) : IsCompletelyPositive (system A) (systemMap f) := by + intro ι _ X hX + exact MatrixTest.output_nonneg f hf X hX + +end Kadison.Paulsen + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PaulsenSystem.lean b/lean/OAI/Analysis/Commutator/PaulsenSystem.lean new file mode 100644 index 0000000000000000000000000000000000000000..fa9490d814dc78ec536839a1587da14f576458ef --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PaulsenSystem.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.TwoByTwoPositive +import OAI.Analysis.Commutator.MatrixScalar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.Paulsen + +open CStarBlock MatrixScalar + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +local instance paulsenSystemDecidableEqFinTwo : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +def system (A : Type*) [CStarAlgebra A] : Submodule ℂ (CStarMatrix (Fin 2) (Fin 2) A) where + carrier := {X | ∃ a b : ℂ,X 0 0=algebraMap ℂ A a ∧ X 1 1=algebraMap ℂ A b} + zero_mem' := ⟨0,0,by simp,by simp⟩ + add_mem' := by + rintro X Y ⟨a,b,ha,hb⟩ ⟨c,d,hc,hd⟩ + exact ⟨a+c,b+d,by simpa only [map_add,CStarMatrix.add_apply] using congrArg₂ (·+·) ha hc, + by simpa only [map_add,CStarMatrix.add_apply] using congrArg₂ (·+·) hb hd⟩ + smul_mem' := by + rintro c X ⟨a,b,ha,hb⟩ + refine ⟨c*a,c*b,?_,?_⟩ + · change c • X 0 0=algebraMap ℂ A (c*a) + rw [ha,map_mul,Algebra.smul_def] + · change c • X 1 1=algebraMap ℂ A (c*b) + rw [hb,map_mul,Algebra.smul_def] + +lemma one_mem : (1 : CStarMatrix (Fin 2) (Fin 2) A)∈system A := + ⟨1,1,by simp,by simp⟩ + +lemma star_mem (X : CStarMatrix (Fin 2) (Fin 2) A) (hX : X∈system A) : star X∈system A := by + obtain ⟨a,b,ha,hb⟩ := hX + refine ⟨star a,star b,?_,?_⟩ + · change star (X 0 0)=_ + rw [ha]; simp [Algebra.algebraMap_eq_smul_one] + · change star (X 1 1)=_ + rw [hb]; simp [Algebra.algebraMap_eq_smul_one] + +def scalarExtract : A →ₗ[ℂ] ℂ := (Algebra.linearMap ℂ A).leftInverse + +lemma scalarExtract_scalar [Nontrivial A] (c : ℂ) : scalarExtract (algebraMap ℂ A c)=c := + LinearMap.leftInverse_apply_of_inj (LinearMap.ker_eq_bot.mpr (algebraMap ℂ A).injective) c + +lemma scalar_reconstruct00 [Nontrivial A] (X : system A) : + algebraMap ℂ A (scalarExtract (X.val 0 0))=X.val 0 0 := by + obtain ⟨a,b,ha,hb⟩ := X.property + rw [ha,scalarExtract_scalar] + +lemma scalar_reconstruct11 [Nontrivial A] (X : system A) : + algebraMap ℂ A (scalarExtract (X.val 1 1))=X.val 1 1 := by + obtain ⟨a,b,ha,hb⟩ := X.property + rw [hb,scalarExtract_scalar] + +def sharp (f : A →ₗ[ℂ] B) : A →ₗ[ℂ] B where + toFun a := star (f (star a)) + map_add' a b := by simp only [star_add,map_add] + map_smul' c a := by simp only [star_smul,map_smul,star_star,RingHom.id_apply] + +def systemMap (f : A →ₗ[ℂ] B) : system A →ₗ[ℂ] CStarMatrix (Fin 2) (Fin 2) B where + toFun X := block (algebraMap ℂ B (scalarExtract (X.val 0 0))) (f (X.val 0 1)) + (sharp f (X.val 1 0)) (algebraMap ℂ B (scalarExtract (X.val 1 1))) + map_add' X Y := by + ext i j + fin_cases i <;> fin_cases j <;> + simp [block,Submodule.coe_add,CStarMatrix.add_apply,map_add] + map_smul' c X := by + ext i j + fin_cases i <;> fin_cases j <;> + simp [block,CStarMatrix.smul_apply,map_smul, + RingHom.id_apply,Algebra.algebraMap_eq_smul_one,smul_smul] + +@[simp] lemma systemMap00 (f : A →ₗ[ℂ] B) (X : system A) : + systemMap f X 0 0=algebraMap ℂ B (scalarExtract (X.val 0 0)) := rfl + +@[simp] lemma systemMap01 (f : A →ₗ[ℂ] B) (X : system A) : systemMap f X 0 1=f (X.val 0 1) := rfl + +@[simp] lemma systemMap10 (f : A →ₗ[ℂ] B) (X : system A) : + systemMap f X 1 0=star (f (star (X.val 1 0))) := rfl + +@[simp] lemma systemMap11 (f : A →ₗ[ℂ] B) (X : system A) : + systemMap f X 1 1=algebraMap ℂ B (scalarExtract (X.val 1 1)) := rfl + +lemma systemMap_one [Nontrivial A] (f : A →ₗ[ℂ] B) : systemMap f ⟨1,one_mem⟩=1 := by + have he : scalarExtract (1:A)=1 := by simpa only [map_one] using scalarExtract_scalar (A:=A) 1 + ext i j + fin_cases i <;> fin_cases j <;> simp [systemMap,he,sharp] + +end Kadison.Paulsen + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PointwiseLinearLift.lean b/lean/OAI/Analysis/Commutator/PointwiseLinearLift.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d30580743c2d5f1a88c78fe36c2cd073f94ecbf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PointwiseLinearLift.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.RationalDense + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.PointwiseLift + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +local instance : NormedSpace ℚ H := NormedSpace.restrictScalars ℚ ℂ H + +variable (A : H →L[ℂ] Lp H 2 μ) (b : ℝ) + +def Good (a : Ω) : Prop := + (∀ x y : RationalDense.subspace H,A ((x+y:H)) a=A (x:H) a+A (y:H) a) ∧ + (∀ (r : ℚ) (x : RationalDense.subspace H),A (r • (x:H)) a=r • A (x:H) a) ∧ + (∀ x : RationalDense.subspace H,‖A (x:H) a‖≤b*‖(x:H)‖) + +omit [CompleteSpace H] in +lemma good_ae (hbound : ∀ x : H,∀ᵐ a ∂μ,‖A x a‖≤b*‖x‖) : ∀ᵐ a ∂μ,Good μ A b a := by + have ha (x y : RationalDense.subspace H) : + ∀ᵐ a ∂μ,A ((x+y:H)) a=A (x:H) a+A (y:H) a := by + rw [map_add] + exact Lp.coeFn_add _ _ + have hs (r : ℚ) (x : RationalDense.subspace H) : + ∀ᵐ a ∂μ,A (r • (x:H)) a=r • A (x:H) a := by + rw [map_rat_smul] + exact Lp.coeFn_smul _ _ + filter_upwards [ae_all_iff.mpr (fun x => ae_all_iff.mpr (ha x)), + ae_all_iff.mpr (fun r => ae_all_iff.mpr (hs r)), + ae_all_iff.mpr (fun x : RationalDense.subspace H => hbound (x:H))] with a ha hs hn + exact ⟨ha,hs,hn⟩ + +def raw (a : Ω) (ha : Good μ A b a) : RationalDense.subspace H →L[ℚ] H := + ({toFun := fun x => A (x:H) a + map_add' := ha.1 + map_smul' := ha.2.1} : RationalDense.subspace H →ₗ[ℚ] H).mkContinuous b ha.2.2 + +def rationalField (a : Ω) : H →L[ℚ] H := by + classical + exact if ha : Good μ A b a then (raw μ A b a ha).extend (RationalDense.subspace H).subtypeL else 0 + +lemma rationalField_subtype (a : Ω) (ha : Good μ A b a) (x : RationalDense.subspace H) : + rationalField μ A b a (x:H)=A (x:H) a := by + rw [rationalField,dite_eq_left ha] + exact ContinuousLinearMap.extend_eq _ (RationalDense.dense H) + isUniformEmbedding_subtype_val.isUniformInducing x + +lemma rationalField_norm_le (hb : 0≤b) (a : Ω) : ‖rationalField μ A b a‖≤b := by + by_cases ha : Good μ A b a + · apply ContinuousLinearMap.opNorm_le_bound _ hb + intro x + exact (RationalDense.dense H).induction_on x + (isClosed_le (rationalField μ A b a).continuous.norm (continuous_const.mul continuous_norm)) + (fun y => by + change ‖rationalField μ A b a (y:H)‖≤b*‖(y:H)‖ + rw [rationalField_subtype μ A b a ha y] + exact ha.2.2 y) + · simp [rationalField,ha,hb] + +lemma rationalField_ae (hb : 0≤b) + (hbound : ∀ x : H,∀ᵐ a ∂μ,‖A x a‖≤b*‖x‖) (x : H) : + (fun a => rationalField μ A b a x)=ᵐ[μ] A x := by + obtain ⟨f,hf⟩ := RationalDense.exists_seq H x + have hA : Tendsto (fun n => A (f n:H)) atTop (𝓝 (A x)) := A.continuous.tendsto x |>.comp hf + obtain ⟨k,hk,hka⟩ := (tendstoInMeasure_of_tendsto_Lp hA).exists_seq_tendsto_ae + filter_upwards [good_ae μ A b hbound,hka] with a ha hka + have hcont := (ContinuousLinearMap.lipschitzWith_of_opNorm_le (K := ⟨b,hb⟩) + (rationalField_norm_le μ A b hb a)).continuous + have hf' := hcont.tendsto x |>.comp (hf.comp hk.tendsto_atTop) + have he : (fun n => rationalField μ A b a (f (k n):H))=(fun n => A (f (k n):H) a) := + funext (fun n => rationalField_subtype μ A b a ha (f (k n))) + change Tendsto (fun n => rationalField μ A b a (f (k n):H)) atTop + (𝓝 (rationalField μ A b a x)) at hf' + rw [he] at hf' + exact tendsto_nhds_unique hf' hka + +lemma rationalField_measurable (hb : 0≤b) + (hbound : ∀ x : H,∀ᵐ a ∂μ,‖A x a‖≤b*‖x‖) (x : H) : + AEStronglyMeasurable (fun a => rationalField μ A b a x) μ := + (Lp.aestronglyMeasurable (A x)).congr (rationalField_ae μ A b hb hbound x).symm + +def realField (a : Ω) : H →L[ℝ] H := + (rationalField μ A b a).toLinearMap.toAddMonoidHom.toRealLinearMap (rationalField μ A b a).continuous + +lemma realField_norm_le (hb : 0≤b) (a : Ω) : ‖realField μ A b a‖≤b := by + apply ContinuousLinearMap.opNorm_le_bound _ hb + intro x + exact ((rationalField μ A b a).le_opNorm x).trans + (mul_le_mul_of_nonneg_right (rationalField_norm_le μ A b hb a) (norm_nonneg x)) + +def field (a : Ω) : H →L[ℂ] H := ComplexLinearization.operator (realField μ A b a) + +lemma field_norm_le (hb : 0≤b) (a : Ω) : ‖field μ A b a‖≤b := + (ComplexLinearization.norm_le _).trans (realField_norm_le μ A b hb a) + +lemma field_ae (hb : 0≤b) (hbound : ∀ x : H,∀ᵐ a ∂μ,‖A x a‖≤b*‖x‖) (x : H) : + (fun a => field μ A b a x)=ᵐ[μ] A x := by + have hs : A (Complex.I • x)=Complex.I • A x := map_smul A _ _ + filter_upwards [rationalField_ae μ A b hb hbound x, + rationalField_ae μ A b hb hbound (Complex.I • x),Lp.coeFn_smul Complex.I (A x)] with a hx hi hs' + change (1/2:ℝ) • (rationalField μ A b a x-Complex.I • rationalField μ A b a (Complex.I • x))=_ + rw [hx,hi,hs,hs'] + dsimp only [Pi.smul_apply] + simp only [smul_smul,Complex.I_mul_I,neg_one_smul,sub_neg_eq_add,smul_add] + module + +lemma field_measurable (hb : 0≤b) + (hbound : ∀ x : H,∀ᵐ a ∂μ,‖A x a‖≤b*‖x‖) (x : H) : + AEStronglyMeasurable (fun a => field μ A b a x) μ := + (Lp.aestronglyMeasurable (A x)).congr (field_ae μ A b hb hbound x).symm + +end Kadison.PointwiseLift + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PointwiseStarHom.lean b/lean/OAI/Analysis/Commutator/PointwiseStarHom.lean new file mode 100644 index 0000000000000000000000000000000000000000..db72cedd4827dd607720ab0c311aafa1b791be9f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PointwiseStarHom.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.CountableFieldHom +import OAI.Analysis.Commutator.DenseRationalStar +import OAI.Analysis.Commutator.StarHomFieldLip +import OAI.Analysis.Commutator.StarHomFieldRaw + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology CStarAlgebra + +namespace Kadison.Decomposable + +variable {Ω H A : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] [NeZero μ] + [CStarAlgebra A] [TopologicalSpace.SeparableSpace A] + +local instance pointwiseStarHomNormedAlgebra : NormedAlgebra ℚ A := + NormedAlgebra.restrictScalars ℚ ℂ A + +local instance pointwiseStarHomStarModule : StarModule ℚ A where + star_smul r a := by + change star ((r:ℂ) • a)=((star r:ℚ):ℂ) • star a + simp + +theorem exists_pointwise_starHom + (ρ : A →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (hcomm : ∀ a (s : Set Ω) (hs : MeasurableSet s), + Commute (ρ a) (indicatorOperator (H:=H) μ s hs)) : + ∃ σ : Ω → A →⋆ₐ[ℂ] (H →L[ℂ] H), + (∀ a ξ,AEStronglyMeasurable (fun x => σ x a ξ) μ) ∧ + (∀ a (f : Lp H 2 μ),ρ a f =ᵐ[μ] fun x => σ x a (f x)) := by + classical + obtain ⟨T,hm,hb,he,ha,hmu,hst,hsc⟩ := exists_starHom_fields μ ρ hcomm + obtain ⟨S,hcount,hd,hI⟩ := DenseRationalStar.exists_dense_countable A + let : Countable S := hcount + have hg := homomorphisms_ae_of_countable_relations μ S hd hI T hb ha hmu hst hsc + obtain ⟨x₀,hx₀⟩ := hg.exists + obtain ⟨Φ₀,hΦ₀⟩ := hx₀ + have hex (x : Ω) : ∃ Φ : A →⋆ₐ[ℂ] (H →L[ℂ] H), + (∃ Ψ : A →⋆ₐ[ℂ] (H →L[ℂ] H),∀ a : S,Ψ (a:A)=T (a:A) x) → + ∀ a : S,Φ (a:A)=T (a:A) x := by + by_cases hx : ∃ Ψ : A →⋆ₐ[ℂ] (H →L[ℂ] H),∀ a : S,Ψ (a:A)=T (a:A) x + · obtain ⟨Ψ,hΨ⟩ := hx + exact ⟨Ψ,fun _ => hΨ⟩ + · exact ⟨Φ₀,fun h => (hx h).elim⟩ + choose σ hσ using hex + have hσg : ∀ᵐ x ∂μ,∀ a : S,σ x (a:A)=T (a:A) x := + hg.mono (fun x hx => hσ x hx) + have hσae (a : A) : (fun x => σ x a)=ᵐ[μ]T a := by + obtain ⟨s,hs,hl⟩ := mem_closure_iff_seq_limit.mp (hd a) + choose b hbs using hs + have hbl : Tendsto (fun n => (b n:A)) atTop (𝓝 a) := by + have heq : (fun n => (b n:A))=s := funext hbs + rwa [heq] + filter_upwards [hσg,ae_all_iff.mpr (fun n => + representation_field_diff_bound μ ρ T hm hb he (b n:A) a)] with x hx hxb + have ht : Tendsto (fun n => T (b n:A) x) atTop (𝓝 (T a x)) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + exact squeeze_zero (fun _ => norm_nonneg _) hxb + (by simpa using (hbl.sub_const a).norm) + have hc : Continuous (σ x : A → (H →L[ℂ] H)) := + map_continuous (σ x) + have hlim := (hc.tendsto a).comp hbl + have heq : (fun n => σ x (b n:A))=(fun n => T (b n:A) x) := funext (fun n => hx (b n)) + change Tendsto (fun n => σ x (b n:A)) atTop (𝓝 (σ x a)) at hlim + rw [heq] at hlim + exact tendsto_nhds_unique hlim ht + refine ⟨σ,?_,?_⟩ + · intro a ξ + apply (hm a ξ).congr + filter_upwards [hσae a] with x hx + exact congrArg (fun U : H →L[ℂ] H => U ξ) hx.symm + · intro a f + rw [he a] + filter_upwards [operator_ae μ (T a) (hm a) (hb a) f,hσae a] with x hx hs + rw [hx,hs] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PolarDecomposition.lean b/lean/OAI/Analysis/Commutator/PolarDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..3eacf9a66853046426ef37b629d01ca5bd36e8dd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PolarDecomposition.lean @@ -0,0 +1,178 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma norm_abs_apply (T : H →L[ℂ] H) (x : H) : ‖CFC.abs T x‖=‖T x‖ := by + have hs : star (CFC.abs T)=CFC.abs T := (IsSelfAdjoint.of_nonneg (CFC.abs_nonneg T)).star_eq + have he : inner ℂ (CFC.abs T x) (CFC.abs T x)=inner ℂ (T x) (T x) := by + rw [←ContinuousLinearMap.adjoint_inner_right,←ContinuousLinearMap.star_eq_adjoint,hs] + change inner ℂ x ((CFC.abs T*CFC.abs T) x)=_ + rw [CFC.abs_mul_abs,mul_apply_eq_comp,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_right] + have hn : ‖CFC.abs T x‖^2=‖T x‖^2 := by + rw [@norm_sq_eq_re_inner ℂ H _ _,@norm_sq_eq_re_inner ℂ H _ _] + exact congrArg RCLike.re he + nlinarith [norm_nonneg (CFC.abs T x),norm_nonneg (T x)] + +def initial (T : H →L[ℂ] H) : Submodule ℂ H := + (LinearMap.range (CFC.abs T).toLinearMap).topologicalClosure + +instance (T : H →L[ℂ] H) : CompleteSpace (initial T) := + (LinearMap.range (CFC.abs T).toLinearMap).isClosed_topologicalClosure.completeSpace_coe + +def absToInitial (T : H →L[ℂ] H) : H →ₗ[ℂ] initial T := + (CFC.abs T).toLinearMap.codRestrict (initial T) (fun x => + Submodule.le_topologicalClosure _ (LinearMap.mem_range_self _ x)) + +lemma absToInitial_dense (T : H →L[ℂ] H) : DenseRange (absToInitial T) := by + let inc : LinearMap.range (CFC.abs T).toLinearMap → initial T := + fun x => ⟨x.val,Submodule.le_topologicalClosure _ x.property⟩ + have hi : DenseRange inc := by + change DenseRange (Set.inclusion (Submodule.le_topologicalClosure _)) + apply (denseRange_inclusion_iff _).2 + exact fun _ h => h + have hs : Function.Surjective (CFC.abs T).toLinearMap.rangeRestrict := by + rintro ⟨y,x,rfl⟩ + exact ⟨x,rfl⟩ + exact hi.comp hs.denseRange (continuous_inclusion (Submodule.le_topologicalClosure _)) + +def initialMap (T : H →L[ℂ] H) : initial T →L[ℂ] H := + T.toLinearMap.extendOfNorm (absToInitial T) + +lemma initialMap_abs (T : H →L[ℂ] H) (x : H) : + initialMap T (absToInitial T x)=T x := by + apply LinearMap.extendOfNorm_eq (absToInitial_dense T) + refine ⟨1,fun x => ?_⟩ + change ‖T x‖≤1*‖CFC.abs T x‖ + rw [one_mul,norm_abs_apply] + +lemma initialMap_norm (T : H →L[ℂ] H) (x : initial T) : ‖initialMap T x‖=‖x‖ := by + refine (absToInitial_dense T).induction_on x + (isClosed_eq (initialMap T).continuous.norm continuous_norm) ?_ + intro y + rw [initialMap_abs] + exact (norm_abs_apply T y).symm + +def partialIsometry (T : H →L[ℂ] H) : H →L[ℂ] H := + (initialMap T).comp (initial T).orthogonalProjectionOnto + +lemma partialIsometry_mem (T : H →L[ℂ] H) (x : initial T) : + partialIsometry T x=initialMap T x := by + exact congrArg (initialMap T) + (Submodule.orthogonalProjectionOnto_mem_subspace_eq_self x) + +lemma factorization (T : H →L[ℂ] H) : partialIsometry T*CFC.abs T=T := by + ext x + change partialIsometry T (absToInitial T x)=T x + rw [partialIsometry_mem,initialMap_abs] + +lemma initialMap_adjoint_comp (T : H →L[ℂ] H) : + (initialMap T).adjoint.comp (initialMap T)=1 := + (ContinuousLinearMap.norm_map_iff_adjoint_comp_self _).mp (initialMap_norm T) + +lemma partialIsometry_initial (T : H →L[ℂ] H) : + star (partialIsometry T)*partialIsometry T=(initial T).starProjection := by + change (partialIsometry T).adjoint.comp (partialIsometry T)=_ + rw [partialIsometry,ContinuousLinearMap.adjoint_comp,Submodule.adjoint_orthogonalProjectionOnto, + ContinuousLinearMap.comp_assoc,←ContinuousLinearMap.comp_assoc (initialMap T).adjoint, + initialMap_adjoint_comp] + simp only [ContinuousLinearMap.one_def,ContinuousLinearMap.id_comp] + rfl + +lemma partialIsometry_mul_initial (T : H →L[ℂ] H) : + partialIsometry T*(initial T).starProjection=partialIsometry T := by + ext x + change initialMap T ((initial T).orthogonalProjectionOnto ((initial T).starProjection x))=_ + rw [Submodule.starProjection_apply,Submodule.orthogonalProjectionOnto_mem_subspace_eq_self] + rfl + +lemma partialIsometry_final_projection (T : H →L[ℂ] H) : + IsStarProjection (partialIsometry T*star (partialIsometry T)) := by + constructor + · change (partialIsometry T*star (partialIsometry T))*(partialIsometry T*star (partialIsometry T))=_ + calc + _=(partialIsometry T*(star (partialIsometry T)*partialIsometry T))*star (partialIsometry T) := by noncomm_ring + _=partialIsometry T*star (partialIsometry T) := by rw [partialIsometry_initial,partialIsometry_mul_initial] + · exact IsSelfAdjoint.mul_star_self _ + +lemma initial_invariant (T B : H →L[ℂ] H) (hB : Commute (CFC.abs T) B) : + ∀ x∈initial T, B x∈initial T := by + intro x hx + apply closure_minimal (t := {x : H | B x∈initial T}) ?_ ?_ hx + · rintro y ⟨z,rfl⟩ + apply Submodule.le_topologicalClosure + exact ⟨B z,congrArg (fun R : H →L[ℂ] H => R z) hB.eq⟩ + · exact (LinearMap.range (CFC.abs T).toLinearMap).isClosed_topologicalClosure.preimage B.continuous + +lemma projection_commutes (P : Submodule ℂ H) [P.HasOrthogonalProjection] + (B : H →L[ℂ] H) (hB : ∀ x∈P, B x∈P) (hsB : ∀ x∈P, star B x∈P) : + P.starProjection*B=B*P.starProjection := by + ext x + change P.starProjection (B x)=B (P.starProjection x) + apply Submodule.eq_starProjection_of_mem_of_inner_eq_zero + · exact hB _ (P.starProjection_apply_mem x) + · intro w hw + rw [←map_sub,←ContinuousLinearMap.adjoint_inner_right] + exact Submodule.starProjection_inner_eq_zero x _ (hsB w hw) + +lemma partialIsometry_commutes (T B : H →L[ℂ] H) + (hB : Commute T B) (hsB : Commute T (star B)) : + Commute (partialIsometry T) B := by + have hab : Commute (CFC.abs T) B := hB.cfcAbs_left hsB + have habs : Commute (CFC.abs T) (star B) := hsB.cfcAbs_left (by simpa using hB) + have hp := projection_commutes (initial T) B (initial_invariant T B hab) + (initial_invariant T (star B) habs) + have hgen : ∀ x : initial T, partialIsometry T (B x)=B (partialIsometry T x) := by + intro x + refine (absToInitial_dense T).induction_on x + (isClosed_eq (by fun_prop) (by fun_prop)) ?_ + · intro y + have haby := congrArg (fun R : H →L[ℂ] H => R y) hab.eq + change CFC.abs T (B y)=B (CFC.abs T y) at haby + have ht := congrArg (fun R : H →L[ℂ] H => R y) hB.eq + change T (B y)=B (T y) at ht + have hf : ∀ z, partialIsometry T (CFC.abs T z)=T z := fun z => + congrArg (fun R : H →L[ℂ] H => R z) (factorization T) + change partialIsometry T (B (CFC.abs T y))=B (partialIsometry T (CFC.abs T y)) + rw [←haby,hf,hf] + exact ht + have hvp : ∀ x : H, partialIsometry T ((initial T).starProjection x)=partialIsometry T x := + fun x => congrArg (fun R : H →L[ℂ] H => R x) (partialIsometry_mul_initial T) + change partialIsometry T*B=B*partialIsometry T + ext x + change partialIsometry T (B x)=B (partialIsometry T x) + rw [←hvp (B x)] + rw [show (initial T).starProjection (B x)=B ((initial T).starProjection x) from + congrArg (fun R : H →L[ℂ] H => R x) hp] + rw [hgen ⟨(initial T).starProjection x,(initial T).starProjection_apply_mem x⟩,hvp] + +theorem partialIsometry_mem_vonNeumann (M : VonNeumannAlgebra H) + {T : H →L[ℂ] H} (hT : T∈M) : partialIsometry T∈M := by + change partialIsometry T∈M.carrier + rw [←M.centralizer_centralizer'] + intro B hB + have hb : Commute T B := hB T hT + have hs : Commute T (star B) := by + simpa only [star_star] using (show Commute (star T) B from hB (star T) (star_mem hT)).star_star + exact (partialIsometry_commutes T B hb hs).eq.symm + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PolarExtension.lean b/lean/OAI/Analysis/Commutator/PolarExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..04393570c186fe5ab71121caf6567ab9cfd9e1c3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PolarExtension.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.PolarSupport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma positive_kills_of_compression {D P : H →L[ℂ] H} (hD : 0≤D) + (hP : IsSelfAdjoint P) (h : P*D*P=0) : D*P=0 := by + have hs : star (CFC.sqrt D*P)*(CFC.sqrt D*P)=0 := by + rw [star_mul,hP.star_eq,(CFC.sqrt_nonneg D).star_eq] + calc + _=P*(CFC.sqrt D*CFC.sqrt D)*P := by noncomm_ring + _=0 := by rw [CFC.sqrt_mul_sqrt_self D hD,h] + have hz := (CStarRing.star_mul_self_eq_zero_iff _).mp hs + calc + _=(CFC.sqrt D*CFC.sqrt D)*P := by rw [CFC.sqrt_mul_sqrt_self D hD] + _=0 := by rw [mul_assoc,hz,mul_zero] + +lemma abs_fixes_of_square_fixes {W P : H →L[ℂ] H} + (h : (star W*W)*P=P) : CFC.abs W*P=P := by + let A := CFC.abs W + have hA : 0≤A := CFC.abs_nonneg W + have hu : IsUnit (A+1) := (IsStrictlyPositive.nonneg_add hA isStrictlyPositive_one).isUnit + have hsq : A*A=star W*W := CFC.abs_mul_abs W + have he : (A+1)*(A*P-P)=0 := by + calc + _=(A*A)*P-P := by noncomm_ring + _=0 := by rw [hsq,h,sub_self] + have hz : A*P-P=0 := by + exact hu.mul_left_cancel (by simpa using he : (A+1)*(A*P-P)=(A+1)*0) + exact sub_eq_zero.mp hz + +lemma partialIsometry_extends {W V : H →L[ℂ] H} (hW : ‖W‖≤1) + (hV : V*star V*V=V) (hext : W*(star V*V)=V) : + partialIsometry W*(star V*V)=V ∧ star V*V≤rightSupport W := by + let P := star V*V + have hP : IsStarProjection P := by + constructor + · change (star V*V)*(star V*V)=star V*V + calc + _=star V*(V*star V*V) := by noncomm_ring + _=star V*V := by rw [hV] + · exact IsSelfAdjoint.star_mul_self V + have hwpos : 0≤1-star W*W := by + apply sub_nonneg.mpr + apply (CStarAlgebra.norm_le_one_iff_of_nonneg _ (star_mul_self_nonneg W)).mp + rw [CStarRing.norm_star_mul_self] + nlinarith [norm_nonneg W] + have hcomp : P*(1-star W*W)*P=0 := by + have hextstar : P*star W=star V := by + simpa only [star_mul,star_star] using congrArg star hext + calc + _=P*P-(P*star W)*(W*P) := by noncomm_ring + _=0 := by rw [hP.isIdempotentElem.eq,hextstar,hext]; exact sub_self P + have hz := positive_kills_of_compression hwpos hP.isSelfAdjoint hcomp + have hsq : (star W*W)*P=P := by + rw [sub_mul,one_mul,sub_eq_zero] at hz + exact hz.symm + have hAP : CFC.abs W*P=P := abs_fixes_of_square_fixes hsq + constructor + · change partialIsometry W*P=V + calc + _=partialIsometry W*(CFC.abs W*P) := by rw [hAP] + _=V := by rw [←mul_assoc,factorization,hext] + · apply (hP.le_iff_mul_eq_right (isProjection_rightSupport W)).mpr + change rightSupport W*P=P + calc + _=rightSupport W*(CFC.abs W*P) := by rw [hAP] + _=P := by rw [←mul_assoc,initial_mul_abs,hAP] + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PolarSupport.lean b/lean/OAI/Analysis/Commutator/PolarSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..e81f213d266172c32decaef1bf9fb55d4964f0f3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PolarSupport.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Commutator.PolarDecomposition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def leftSupport (T : H →L[ℂ] H) : H →L[ℂ] H := + partialIsometry T*star (partialIsometry T) + +def rightSupport (T : H →L[ℂ] H) : H →L[ℂ] H := (initial T).starProjection + +lemma isProjection_leftSupport (T : H →L[ℂ] H) : IsStarProjection (leftSupport T) := + partialIsometry_final_projection T + +lemma isProjection_rightSupport (T : H →L[ℂ] H) : IsStarProjection (rightSupport T) := + isStarProjection_starProjection + +lemma initial_mul_abs (T : H →L[ℂ] H) : rightSupport T*CFC.abs T=CFC.abs T := by + ext x + apply Submodule.starProjection_eq_self_iff.mpr + exact (absToInitial T x).property + +lemma abs_mul_initial (T : H →L[ℂ] H) : CFC.abs T*rightSupport T=CFC.abs T := by + have hs : star (CFC.abs T)=CFC.abs T := (IsSelfAdjoint.of_nonneg (CFC.abs_nonneg T)).star_eq + simpa only [star_mul,hs,(isProjection_rightSupport T).isSelfAdjoint.star_eq] using + congrArg star (initial_mul_abs T) + +lemma mul_rightSupport (T : H →L[ℂ] H) : T*rightSupport T=T := by + calc + _=(partialIsometry T*CFC.abs T)*rightSupport T := by rw [factorization] + _=partialIsometry T*CFC.abs T := by rw [mul_assoc,abs_mul_initial] + _=T := factorization T + +lemma partialIsometry_triple (T : H →L[ℂ] H) : + partialIsometry T*star (partialIsometry T)*partialIsometry T=partialIsometry T := by + rw [mul_assoc,partialIsometry_initial,partialIsometry_mul_initial] + +lemma leftSupport_mul (T : H →L[ℂ] H) : leftSupport T*T=T := by + calc + _=(partialIsometry T*star (partialIsometry T))*(partialIsometry T*CFC.abs T) := by + rw [factorization]; rfl + _=partialIsometry T*CFC.abs T := by rw [←mul_assoc,partialIsometry_triple] + _=T := factorization T + +lemma mul_partialIsometry_of_mul (T e : H →L[ℂ] H) (he : e*T=T) : + e*partialIsometry T=partialIsometry T := by + have h : ∀ x : initial T, e (initialMap T x)=initialMap T x := by + intro x + refine (absToInitial_dense T).induction_on x + (isClosed_eq (by fun_prop) (by fun_prop)) ?_ + intro y + rw [initialMap_abs] + exact congrArg (fun R : H →L[ℂ] H => R y) he + ext x + exact h ((initial T).orthogonalProjectionOnto x) + +lemma leftSupport_le (T e : H →L[ℂ] H) (he : IsStarProjection e) (hT : e*T=T) : + leftSupport T≤e := by + apply ((isProjection_leftSupport T).le_iff_mul_eq_right he).mpr + change e*(partialIsometry T*star (partialIsometry T))=_ + rw [←mul_assoc,mul_partialIsometry_of_mul T e hT] + rfl + +lemma abs_mul_of_mul (T e : H →L[ℂ] H) (hT : T*e=T) : CFC.abs T*e=CFC.abs T := by + ext x + have ht : T (e x-x)=0 := by + rw [map_sub] + exact sub_eq_zero.mpr (congrArg (fun R : H →L[ℂ] H => R x) hT) + have ha : CFC.abs T (e x-x)=0 := by + apply norm_eq_zero.mp + rw [norm_abs_apply,ht,norm_zero] + change CFC.abs T (e x)=CFC.abs T x + exact sub_eq_zero.mp (by simpa only [map_sub] using ha) + +lemma rightSupport_le (T e : H →L[ℂ] H) (he : IsStarProjection e) (hT : T*e=T) : + rightSupport T≤e := by + have hs : star (CFC.abs T)=CFC.abs T := (IsSelfAdjoint.of_nonneg (CFC.abs_nonneg T)).star_eq + have hea : e*CFC.abs T=CFC.abs T := by + simpa only [star_mul,hs,he.isSelfAdjoint.star_eq] using congrArg star (abs_mul_of_mul T e hT) + have hfix : ∀ x : initial T, e x=x := by + intro x + refine (absToInitial_dense T).induction_on x + (isClosed_eq (e.continuous.comp continuous_subtype_val) continuous_subtype_val) ?_ + intro y + exact congrArg (fun R : H →L[ℂ] H => R y) hea + apply ((isProjection_rightSupport T).le_iff_mul_eq_right he).mpr + ext x + exact hfix ⟨(initial T).starProjection x,(initial T).starProjection_apply_mem x⟩ + +lemma leftSupport_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) : + leftSupport T∈M := + M.mul_mem (partialIsometry_mem_vonNeumann M hT) (M.star_mem' (partialIsometry_mem_vonNeumann M hT)) + +lemma rightSupport_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) : + rightSupport T∈M := by + rw [rightSupport,←partialIsometry_initial] + exact M.mul_mem (M.star_mem' (partialIsometry_mem_vonNeumann M hT)) (partialIsometry_mem_vonNeumann M hT) + +lemma trace_supports (τ : (H →L[ℂ] H) →ₗ[ℂ] ℂ) (M : VonNeumannAlgebra H) + (hτ : ∀ a∈M, ∀ b∈M, τ (a*b)=τ (b*a)) {T : H →L[ℂ] H} (hT : T∈M) : + τ (rightSupport T)=τ (leftSupport T) := by + rw [rightSupport,←partialIsometry_initial,leftSupport] + exact hτ _ (M.star_mem' (partialIsometry_mem_vonNeumann M hT)) _ (partialIsometry_mem_vonNeumann M hT) + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PositiveCauchySchwarz.lean b/lean/OAI/Analysis/Commutator/PositiveCauchySchwarz.lean new file mode 100644 index 0000000000000000000000000000000000000000..02251c7bcc2043ce2b37000f55bc41aa021e3d1f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PositiveCauchySchwarz.lean @@ -0,0 +1,58 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma sqrt_inner (A : H →L[ℂ] H) (ha : 0≤A) (x y : H) : + inner ℂ (CFC.sqrt A x) (CFC.sqrt A y)=inner ℂ (A x) y := by + have hs := ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mp + (IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg A)) + have he := hs (CFC.sqrt A x) y + have hh : CFC.sqrt A*CFC.sqrt A=A := by simpa only [pow_two] using CFC.sq_sqrt A ha + change inner ℂ ((CFC.sqrt A*CFC.sqrt A) x) y= + inner ℂ (CFC.sqrt A x) (CFC.sqrt A y) at he + exact he.symm.trans (congrArg (fun T : H →L[ℂ] H => inner ℂ (T x) y) hh) + +lemma sqrt_norm_sq (A : H →L[ℂ] H) (ha : 0≤A) (x : H) : + ‖CFC.sqrt A x‖^2=(inner ℂ (A x) x).re := by + rw [norm_sq_eq_re_inner (𝕜:=ℂ),sqrt_inner A ha x x] + rfl + +lemma positive_cauchySchwarz (A : H →L[ℂ] H) (ha : 0≤A) (x y : H) : + ‖inner ℂ (A x) y‖^2≤(inner ℂ (A x) x).re*(inner ℂ (A y) y).re := by + have hh := norm_inner_le_norm (𝕜:=ℂ) (CFC.sqrt A x) (CFC.sqrt A y) + have hs := sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg _) (norm_nonneg _)) |>.mpr hh + rw [mul_pow,sqrt_norm_sq A ha x,sqrt_norm_sq A ha y,sqrt_inner A ha x y] at hs + exact hs + +lemma inverse_cauchySchwarz (A : (H →L[ℂ] H)ˣ) (ha : 0≤(A:H →L[ℂ] H)) (x y : H) : + ‖inner ℂ x y‖^2≤(inner ℂ ((↑A⁻¹:H →L[ℂ] H) x) x).re*(inner ℂ ((A:H →L[ℂ] H) y) y).re := by + have hh := positive_cauchySchwarz (A:H →L[ℂ] H) ha ((↑A⁻¹:H →L[ℂ] H) x) y + have he : (A:H →L[ℂ] H) ((↑A⁻¹:H →L[ℂ] H) x)=x := by + change ((A:H →L[ℂ] H)*(↑A⁻¹:H →L[ℂ] H)) x=x + rw [Units.mul_inv,one_apply_eq_self] + rw [he] at hh + have hre : (inner ℂ x ((↑A⁻¹:H →L[ℂ] H) x)).re= + (inner ℂ ((↑A⁻¹:H →L[ℂ] H) x) x).re := inner_re_symm (𝕜:=ℂ) _ _ + rw [hre] at hh + exact hh + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PositiveExtensionComplex.lean b/lean/OAI/Analysis/Commutator/PositiveExtensionComplex.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a1ac39adde832d3438f85e5a617554cac305158 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PositiveExtensionComplex.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.PositiveExtensionReal + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.PositiveExtension + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def saInclusion (S : Submodule ℂ A) : saSubmodule S →ₗ[ℝ] S where + toFun x := ⟨((x : selfAdjoint A) : A),x.property⟩ + map_add' _ _ := rfl + map_smul' _ _ := rfl + +lemma positive_selfAdjoint_im (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : S →ₗ[ℂ] ℂ) (hf : ∀ x : S, 0 ≤ (x : A) → 0 ≤ f x) + (x : saSubmodule S) : (f (saInclusion S x)).im=0 := by + let u : S := ⟨1,h1⟩ + have hu : (f u).im=0 := (hf u zero_le_one).2.symm + have hb : 0 ≤ ((‖x‖ • u-saInclusion S x : S) : A) := by + change 0 ≤ ‖x‖ • (1 : A) - ((x : selfAdjoint A) : A) + rw [sub_nonneg,←Algebra.algebraMap_eq_smul_one] + exact (x : selfAdjoint A).property.le_algebraMap_norm_self + have hi := (hf (‖x‖ • u-saInclusion S x) hb).2 + rw [map_sub,← Complex.coe_smul,map_smul] at hi + simpa [smul_eq_mul,hu] using hi + +def realRestriction (S : Submodule ℂ A) (f : S →ₗ[ℂ] ℂ) : saSubmodule S →ₗ[ℝ] ℝ := + Complex.reCLM.toLinearMap.comp ((f.restrictScalars ℝ).comp (saInclusion S)) + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma realRestriction_apply (S : Submodule ℂ A) (f : S →ₗ[ℂ] ℂ) (x) : + realRestriction S f x=(f (saInclusion S x)).re := rfl + +def complexify (g : selfAdjoint A →ₗ[ℝ] ℝ) : A →ₗ[ℂ] ℂ := + Module.Dual.extendRCLike (g.comp realPart) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma complexify_apply (g : selfAdjoint A →ₗ[ℝ] ℝ) (x : A) : + complexify g x=(g (realPart x) : ℂ)+Complex.I*(g (imaginaryPart x) : ℂ) := by + simp [complexify,Module.Dual.extendRCLike_apply,sub_eq_add_neg] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma complexify_selfAdjoint (g : selfAdjoint A →ₗ[ℝ] ℝ) (x : selfAdjoint A) : + complexify g (x : A)=(g x : ℂ) := by simp [complexify_apply] + +lemma complexify_nonneg (g : selfAdjoint A →ₗ[ℝ] ℝ) + (hg : ∀ x : selfAdjoint A, 0 ≤ (x : A) → 0 ≤ g x) (a : A) (ha : 0 ≤ a) : + 0 ≤ complexify g a := by + let x : selfAdjoint A := ⟨a,IsSelfAdjoint.of_nonneg ha⟩ + change 0 ≤ complexify g (x : A) + rw [complexify_selfAdjoint] + exact_mod_cast hg x ha + +def complexifyPositive (g : selfAdjoint A →ₗ[ℝ] ℝ) + (hg : ∀ x : selfAdjoint A, 0 ≤ (x : A) → 0 ≤ g x) : A →ₚ[ℂ] ℂ where + toLinearMap := complexify g + monotone' := by + intro a b hab + change complexify g a ≤ complexify g b + have hh := complexify_nonneg g hg (b-a) (sub_nonneg.mpr hab) + rw [map_sub] at hh + exact sub_nonneg.mp hh + +omit [PartialOrder A] [StarOrderedRing A] in +lemma realPart_mem (S : Submodule ℂ A) (hs : ∀ a ∈ S, star a ∈ S) (a : S) : + (realPart (a : A) : A) ∈ S := by + rw [realPart_apply_coe,←Complex.coe_smul] + exact S.smul_mem _ (S.add_mem a.property (hs a a.property)) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma imaginaryPart_mem (S : Submodule ℂ A) (hs : ∀ a ∈ S, star a ∈ S) (a : S) : + (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 (hs a a.property))) + +theorem exists_positive_extension (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (hs : ∀ a ∈ S, star a ∈ S) (f : S →ₗ[ℂ] ℂ) + (hf : ∀ x : S, 0 ≤ (x : A) → 0 ≤ f x) : + ∃ g : A →ₚ[ℂ] ℂ, ∀ x : S, g x=f x := by + obtain ⟨g,hg,hgp⟩ := exists_real_extension S h1 (realRestriction S f) (by + intro x hx + exact (hf (saInclusion S x) hx).1) + refine ⟨complexifyPositive g.toLinearMap hgp,?_⟩ + intro x + let xr : saSubmodule S := ⟨realPart (x : A),realPart_mem S hs x⟩ + let xi : saSubmodule S := ⟨imaginaryPart (x : A),imaginaryPart_mem S hs x⟩ + have hxr : ((f (saInclusion S xr)).re : ℂ)=f (saInclusion S xr) := by + exact Complex.ext (by simp) (by simp [positive_selfAdjoint_im S h1 f hf xr]) + have hxi : ((f (saInclusion S xi)).re : ℂ)=f (saInclusion S xi) := by + exact Complex.ext (by simp) (by simp [positive_selfAdjoint_im S h1 f hf xi]) + have hd : saInclusion S xr+Complex.I • saInclusion S xi=x := by + apply Subtype.ext + exact realPart_add_I_smul_imaginaryPart (x : A) + change complexify g.toLinearMap (x : A)=f x + rw [complexify_apply] + change (g (xr : selfAdjoint A) : ℂ)+Complex.I*(g (xi : selfAdjoint A) : ℂ)=f x + rw [hg xr,hg xi,realRestriction_apply,realRestriction_apply,hxr,hxi,←smul_eq_mul, + ←map_smul,←map_add,hd] + +end Kadison.PositiveExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PositiveExtensionReal.lean b/lean/OAI/Analysis/Commutator/PositiveExtensionReal.lean new file mode 100644 index 0000000000000000000000000000000000000000..db3f4d4c956192bded3ae2f33d6c0d4dad24b96c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PositiveExtensionReal.lean @@ -0,0 +1,94 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder + +namespace Kadison.PositiveExtension + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def saSubmodule (S : Submodule ℂ A) : Submodule ℝ (selfAdjoint A) where + carrier := {x | (x : A) ∈ S} + zero_mem' := S.zero_mem + add_mem' hx hy := S.add_mem hx hy + smul_mem' r x hx := by + change r • (x : A) ∈ S + rw [← Complex.coe_smul] + exact S.smul_mem (r : ℂ) hx + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma saSubmodule_mem (S : Submodule ℂ A) (x : selfAdjoint A) : + x ∈ saSubmodule S ↔ (x : A) ∈ S := Iff.rfl + +def saUnit (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) : saSubmodule S := ⟨1,h1⟩ + +lemma positive_real_bound (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : saSubmodule S →ₗ[ℝ] ℝ) + (hf : ∀ x : saSubmodule S, 0 ≤ ((x : selfAdjoint A) : A) → 0 ≤ f x) + (x : saSubmodule S) : ‖f x‖ ≤ f (saUnit S h1) * ‖x‖ := by + have upper (y : saSubmodule S) : f y ≤ ‖y‖ * f (saUnit S h1) := by + have hy : 0 ≤ (((‖y‖ • saUnit S h1 - y : saSubmodule S) : selfAdjoint A) : A) := by + change 0 ≤ ‖y‖ • (1 : A) - (y : selfAdjoint A) + rw [sub_nonneg,← Algebra.algebraMap_eq_smul_one] + exact (y : selfAdjoint A).property.le_algebraMap_norm_self + have hh := hf (‖y‖ • saUnit S h1-y) hy + simp only [map_sub,map_smul,smul_eq_mul] at hh + linarith + rw [Real.norm_eq_abs,abs_le] + constructor + · have hh := upper (-x) + rw [map_neg] at hh + change -f x ≤ ‖-((x : selfAdjoint A) : A)‖ * f (saUnit S h1) at hh + rw [norm_neg] at hh + change -(f (saUnit S h1)*‖((x : selfAdjoint A) : A)‖) ≤ f x + nlinarith + · simpa [mul_comm] using upper x + +theorem exists_real_extension (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : saSubmodule S →ₗ[ℝ] ℝ) + (hf : ∀ x : saSubmodule S, 0 ≤ ((x : selfAdjoint A) : A) → 0 ≤ f x) : + ∃ g : selfAdjoint A →L[ℝ] ℝ, + (∀ x : saSubmodule S, g x=f x) ∧ + (∀ x : selfAdjoint A, 0 ≤ (x : A) → 0 ≤ g x) := by + let c := f (saUnit S h1) + have hc : 0 ≤ c := hf _ zero_le_one + let fc : saSubmodule S →L[ℝ] ℝ := f.mkContinuous c (positive_real_bound S h1 f hf) + obtain ⟨g,hg,hgn⟩ := exists_extension_norm_eq (saSubmodule S) fc + have hgc : ‖g‖ ≤ c := by + rw [hgn] + exact LinearMap.mkContinuous_norm_le _ hc _ + have hg1 : g 1=c := hg (saUnit S h1) + refine ⟨g,hg,?_⟩ + intro x hx + let b : selfAdjoint A := ‖x‖ • 1-x + have hb : 0 ≤ (b : A) := by + change 0 ≤ ‖x‖ • (1 : A) - (x : A) + rw [sub_nonneg,← Algebra.algebraMap_eq_smul_one] + exact x.property.le_algebraMap_norm_self + have hbn : ‖b‖ ≤ ‖x‖ := by + apply (CStarAlgebra.norm_le_iff_le_algebraMap (b : A) (norm_nonneg _) hb).mpr + change ‖x‖ • (1 : A) - (x : A) ≤ algebraMap ℝ A ‖x‖ + rw [Algebra.algebraMap_eq_smul_one] + exact sub_le_self _ hx + have hgub : g b ≤ c*‖x‖ := calc + g b ≤ ‖g b‖ := Real.le_norm_self _ + _ ≤ ‖g‖*‖b‖ := g.le_opNorm b + _ ≤ c*‖x‖ := mul_le_mul hgc hbn (norm_nonneg _) hc + simp only [b,map_sub,map_smul,hg1,smul_eq_mul] at hgub + nlinarith + +end Kadison.PositiveExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/PositiveWOT.lean b/lean/OAI/Analysis/Commutator/PositiveWOT.lean new file mode 100644 index 0000000000000000000000000000000000000000..f77718b6923ddb56cfc80001557ff954d663f095 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/PositiveWOT.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H I : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma inner_mono {A B : H →L[ℂ] H} (h : A≤B) (x : H) : + (inner ℂ (A x) x).re≤(inner ℂ (B x) x).re := by + have hp := ContinuousLinearMap.nonneg_iff_isPositive.mp (sub_nonneg.mpr h) + have hh : 0≤(inner ℂ ((B-A) x) x).re := hp.re_inner_nonneg_left x + simpa only [sub_apply,inner_sub_left,Complex.sub_re,sub_nonneg] using hh + +omit [CompleteSpace H] in +lemma nonneg_limit {l : Filter I} [l.NeBot] {T : I → H →L[ℂ] H} {W : H →L[ℂ] H} + (ht : ∀ x y,Tendsto (fun i => inner ℂ (T i x) y) l (𝓝 (inner ℂ (W x) y))) + (hp : ∀ᶠ i in l,0≤T i) : 0≤W := by + apply ContinuousLinearMap.nonneg_iff_isPositive.mpr + apply (ContinuousLinearMap.isPositive_iff_complex _).mpr + intro x + have hh : 0 ≤ inner ℂ (W x) x := ge_of_tendsto (ht x x) (hp.mono fun i hi => + (ContinuousLinearMap.nonneg_iff_isPositive.mp hi).inner_nonneg_left x) + exact ⟨Complex.ext (by simp) (by simpa using hh.2),hh.1⟩ + +omit [CompleteSpace H] in +lemma le_limit {l : Filter I} [l.NeBot] {T : I → H →L[ℂ] H} {W A : H →L[ℂ] H} + (ht : ∀ x y,Tendsto (fun i => inner ℂ (T i x) y) l (𝓝 (inner ℂ (W x) y))) + (hp : ∀ᶠ i in l,A≤T i) : A≤W := by + apply sub_nonneg.mp + refine nonneg_limit (T:=fun i => T i-A) ?_ (hp.mono fun _ hi => sub_nonneg.mpr hi) + intro x y + simpa only [sub_apply,inner_sub_left] using + ((ht x y).sub (tendsto_const_nhds (x:=inner ℂ (A x) y))) + +omit [CompleteSpace H] in +lemma limit_le {l : Filter I} [l.NeBot] {T : I → H →L[ℂ] H} {W A : H →L[ℂ] H} + (ht : ∀ x y,Tendsto (fun i => inner ℂ (T i x) y) l (𝓝 (inner ℂ (W x) y))) + (hp : ∀ᶠ i in l,T i≤A) : W≤A := by + apply sub_nonneg.mp + refine nonneg_limit (T:=fun i => A-T i) ?_ (hp.mono fun _ hi => sub_nonneg.mpr hi) + intro x y + simpa only [sub_apply,inner_sub_left] using + ((tendsto_const_nhds (x:=inner ℂ (A x) y)).sub (ht x y)) + +lemma contraction_square_le {A : H →L[ℂ] H} (ha : 0≤A) (h1 : A≤1) : A*A≤A := by + have hc : Commute A (1-A) := (Commute.one_right A).sub_right (Commute.refl A) + have hh := hc.mul_nonneg ha (sub_nonneg.mpr h1) + have he : A*(1-A)=A-A*A := by noncomm_ring + rw [he] at hh + exact sub_nonneg.mp hh + +lemma contraction_norm_sq_le {A : H →L[ℂ] H} (ha : 0≤A) (h1 : A≤1) (x : H) : + ‖A x‖^2≤(inner ℂ (A x) x).re := by + have hh := inner_mono (contraction_square_le ha h1) x + have hs := ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mp (IsSelfAdjoint.of_nonneg ha) + have he : inner ℂ ((A*A) x) x=inner ℂ (A x) (A x) := hs (A x) x + rw [he] at hh + rw [norm_sq_eq_re_inner (𝕜:=ℂ)] + exact hh + +theorem exists_strong_inf (M : VonNeumannAlgebra H) (P : ℕ → H →L[ℂ] H) + (hPM : ∀ n,P n∈M) (hpos : ∀ n,0≤P n) (hone : ∀ n,P n≤1) (hmono : Antitone P) : + ∃ B : H →L[ℂ] H,B∈M ∧ 0≤B ∧ B≤1 ∧ (∀ n,B≤P n) ∧ + (∀ x,Tendsto (fun n => P n x) atTop (𝓝 (B x))) := by + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ)≤atTop := Ultrafilter.of_le atTop + obtain ⟨B,hBn,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω P 1 zero_le_one + (fun n => (CStarAlgebra.norm_le_one_iff_of_nonneg _ (hpos n)).mpr (hone n)) + have hBpos : 0≤B := nonneg_limit hlim (Eventually.of_forall hpos) + have hB1 : B≤1 := limit_le hlim (Eventually.of_forall hone) + have hBP (n : ℕ) : B≤P n := limit_le hlim + (((eventually_ge_atTop n).filter_mono hω).mono fun m hnm => hmono hnm) + refine ⟨B,WeakOperatorLimit.mem_vonNeumann hlim M (Eventually.of_forall hPM),hBpos,hB1,hBP,?_⟩ + intro x + have hscalar : Tendsto (fun n => (inner ℂ ((P n-B) x) x).re) (ω : Filter ℕ) (𝓝 0) := by + simpa only [sub_apply,inner_sub_left,Complex.sub_re,Function.comp_apply,sub_self] + using (Complex.continuous_re.tendsto _ |>.comp (hlim x x)).sub (tendsto_const_nhds (x:=(inner ℂ (B x) x).re)) + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨N,hN⟩ := (hscalar.eventually_lt_const (sq_pos_of_pos hε)).exists + refine ⟨N,?_⟩ + intro n hn + have hDpos : 0≤P n-B := sub_nonneg.mpr (hBP n) + have hD1 : P n-B≤1 := (sub_le_self _ hBpos).trans (hone n) + have hsq := contraction_norm_sq_le hDpos hD1 x + have hle := inner_mono (sub_le_sub_right (hmono hn) B) x + have hlt : ‖(P n-B) x‖<ε := by nlinarith [norm_nonneg ((P n-B) x)] + simpa only [dist_eq_norm,sub_apply] using hlt + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionAddition.lean b/lean/OAI/Analysis/Commutator/ProjectionAddition.lean new file mode 100644 index 0000000000000000000000000000000000000000..97a820b4aa391568cd5f7a8ff99f9db500ac6875 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionAddition.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionEquivalence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f e' f' : H →L[ℂ] H} + +def orthogonalSum (v : Link M e f) (w : Link M e' f') + (he : IsStarProjection e) (hf : IsStarProjection f) + (he' : IsStarProjection e') (hf' : IsStarProjection f') + (hes : e*e'=0) (hfs : f*f'=0) (hvi : v.initial=e) : Link M (e+e') (f+f') := by + let b : Link M (e+e') (f+f') := + ⟨v.val,v.mem,v.triple,v.source_le.trans (le_add_of_nonneg_right he'.nonneg), + v.target_le.trans (le_add_of_nonneg_right hf'.nonneg)⟩ + have hbi : b.initial=e := hvi + let c : Link M ((e+e')-b.initial) ((f+f')-b.final) := + ⟨w.val,w.mem,w.triple,by simpa only [hbi,add_sub_cancel_left] using w.source_le, + w.target_le.trans (by + apply le_sub_iff_add_le.mpr + change f' + v.final ≤ f + f' + have hv : v.final ≤ f := v.target_le + calc + f' + v.final = v.final + f' := add_comm _ _ + _ ≤ f+f' := add_le_add hv le_rfl)⟩ + exact b.extend (he.add he' hes) (hf.add hf' hfs) c + +lemma orthogonalSum_initial (v : Link M e f) (w : Link M e' f') + (he : IsStarProjection e) (hf : IsStarProjection f) + (he' : IsStarProjection e') (hf' : IsStarProjection f') + (hes : e*e'=0) (hfs : f*f'=0) (hvi : v.initial=e) : + (v.orthogonalSum w he hf he' hf' hes hfs hvi).initial=v.initial+w.initial := by + apply Link.extend_initial + · exact he.add he' hes + · exact hf.add hf' hfs + +lemma orthogonalSum_final (v : Link M e f) (w : Link M e' f') + (he : IsStarProjection e) (hf : IsStarProjection f) + (he' : IsStarProjection e') (hf' : IsStarProjection f') + (hes : e*e'=0) (hfs : f*f'=0) (hvi : v.initial=e) : + (v.orthogonalSum w he hf he' hf' hes hfs hvi).final=v.final+w.final := by + apply Link.extend_final + · exact he.add he' hes + · exact hf.add hf' hfs + +end Link + +lemma SubEquivalent.orthogonal_add {M : VonNeumannAlgebra H} {e f e' f' : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) + (he' : IsStarProjection e') (hf' : IsStarProjection f') + (hes : e*e'=0) (hfs : f*f'=0) + (h : SubEquivalent M e f) (k : SubEquivalent M e' f') : + SubEquivalent M (e+e') (f+f') := by + obtain ⟨v,hv⟩ := h + obtain ⟨w,hw⟩ := k + exact ⟨v.orthogonalSum w he hf he' hf' hes hfs hv, + (v.orthogonalSum_initial w he hf he' hf' hes hfs hv).trans (by rw [hv,hw])⟩ + +lemma Equivalent.orthogonal_add {M : VonNeumannAlgebra H} {e f e' f' : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) + (he' : IsStarProjection e') (hf' : IsStarProjection f') + (hes : e*e'=0) (hfs : f*f'=0) + (h : Equivalent M e f) (k : Equivalent M e' f') : + Equivalent M (e+e') (f+f') := by + obtain ⟨v,hvi,hvf⟩ := h + obtain ⟨w,hwi,hwf⟩ := k + exact ⟨v.orthogonalSum w he hf he' hf' hes hfs hvi, + (v.orthogonalSum_initial w he hf he' hf' hes hfs hvi).trans (by rw [hvi,hwi]), + (v.orthogonalSum_final w he hf he' hf' hes hfs hvi).trans (by rw [hvf,hwf])⟩ + +theorem subEquivalent_unitary (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {e f : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) + (h : SubEquivalent M e f) : + ∃ u∈M,star u*u=1 ∧ u*star u=1 ∧ u*e*star u≤f := by + obtain ⟨v,hvi⟩ := h + obtain ⟨u,hu,hui,huf,huv⟩ := finite_unitary_extension M hfac hfin + heM (M.mul_mem v.mem (M.star_mem' v.mem)) he v.final_projection + (⟨v.val,v.mem,v.triple,v.source_le,le_rfl⟩ : Link M e v.final) hvi rfl + have heq : u*e*star u=v.final := by + calc + _=(u*e)*star (u*e) := by rw [star_mul,he.isSelfAdjoint.star_eq,←mul_assoc, + mul_assoc u e e,he.isIdempotentElem.eq] + _=v.final := by rw [huv]; rfl + exact ⟨u,hu,hui,huf,heq ▸ v.target_le⟩ + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionBlocks.lean b/lean/OAI/Analysis/Commutator/ProjectionBlocks.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd0b8d2237907ce2ce70c50463dec476d757bf9d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionBlocks.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit + +namespace OAI + +noncomputable section + +noncomputable section + +open Filter + +open scoped InnerProductSpace ComplexOrder Topology BigOperators + +namespace Kadison.ProjectionBlocks + +variable {H ι : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (P : ι → H →L[ℂ] H) (hp : ∀ i,IsStarProjection (P i)) + (ho : ∀ i j,i≠j → P i*P j=0) + +def space : Submodule ℂ H := + (Submodule.span ℂ {x | ∃ i : ι,∃ ξ : H,P i ξ=x}).topologicalClosure + +instance space_complete : CompleteSpace (space P) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +def finiteSum (s : Finset ι) : H →L[ℂ] H := ∑ i∈s,P i + +omit [CompleteSpace H] in +lemma generator_mem (i : ι) (x : H) : P i x∈space P := + Submodule.le_topologicalClosure _ (Submodule.subset_span ⟨i,x,rfl⟩) + +include hp ho in +lemma finiteSum_projection (s : Finset ι) : IsStarProjection (finiteSum P s) := by + classical + constructor + · change (∑ i∈s,P i)*(∑ i∈s,P i)=∑ i∈s,P i + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · exact (hp i).isIdempotentElem.eq + · intro j hj hji + exact ho i j hji.symm + · change star (∑ i∈s,P i)=∑ i∈s,P i + rw [star_sum] + exact Finset.sum_congr rfl (fun i _ => (hp i).isSelfAdjoint.star_eq) + +include hp ho in +lemma finiteSum_mul (s : Finset ι) {i : ι} (hi : i∈s) : finiteSum P s*P i=P i := by + classical + rw [finiteSum,Finset.sum_mul,Finset.sum_eq_single_of_mem i hi] + · exact (hp i).isIdempotentElem.eq + · intro j hj hji + exact ho j i hji + +include hp ho in +lemma finiteSum_tendsto_space {x : H} (hx : x∈space P) : + Tendsto (fun s : Finset ι => finiteSum P s x) atTop (𝓝 x) := by + classical + have hg (i : ι) (x : H) : Tendsto (fun s : Finset ι => finiteSum P s (P i x)) atTop (𝓝 (P i x)) := by + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop ({i}:Finset ι)] with s hs + exact (congrArg (fun T : H →L[ℂ] H => T x) + (finiteSum_mul P hp ho s (hs (by simp)))).symm + have hspan : ∀ y∈Submodule.span ℂ {x | ∃ i : ι,∃ ξ : H,P i ξ=x}, + Tendsto (fun s : Finset ι => finiteSum P s y) atTop (𝓝 y) := by + intro y hy + induction hy using Submodule.span_induction with + | mem y hy => obtain ⟨i,ξ,rfl⟩ := hy; exact hg i ξ + | zero => simpa only [map_zero] using (tendsto_const_nhds (x:=(0:H)) (f:=atTop (α:=Finset ι))) + | add x y hx hy hxlim hylim => simpa only [map_add] using hxlim.add hylim + | smul c x hx hxlim => simpa only [map_smul] using hxlim.const_smul c + have hnorm (s : Finset ι) : ‖finiteSum P s‖≤1 := (finiteSum_projection P hp ho s).norm_le _ + have hequi : Equicontinuous (fun s : Finset ι => fun x : H => finiteSum P s x) := + (LipschitzWith.uniformEquicontinuous _ 1 (fun s => + ContinuousLinearMap.lipschitzWith_of_opNorm_le (hnorm s))).equicontinuous + exact (hequi x).tendsto_of_mem_closure + (continuous_id.continuousAt.mono_left inf_le_left) hspan hx + +lemma projection_left (i : ι) : (space P).starProjection*P i=P i := by + ext x + exact Submodule.starProjection_eq_self_iff.mpr (generator_mem P i x) + +include hp in +lemma projection_right (i : ι) : P i*(space P).starProjection=P i := by + have he := congrArg star (projection_left P i) + simpa only [star_mul,(hp i).isSelfAdjoint.star_eq, + (isSelfAdjoint_starProjection (space P)).star_eq] using he + +include hp ho in +lemma finiteSum_tendsto (x : H) : + Tendsto (fun s : Finset ι => finiteSum P s x) atTop (𝓝 ((space P).starProjection x)) := by + have hh := finiteSum_tendsto_space P hp ho ((space P).starProjection_apply_mem x) + have he (s : Finset ι) : finiteSum P s*((space P).starProjection)=finiteSum P s := by + rw [finiteSum,Finset.sum_mul] + exact Finset.sum_congr rfl (fun i _ => projection_right P hp i) + have hev (s : Finset ι) : finiteSum P s ((space P).starProjection x)=finiteSum P s x := + congrArg (fun T : H →L[ℂ] H => T x) (he s) + simpa only [hev] using hh + +omit [CompleteSpace H] in +lemma invariant (T : H →L[ℂ] H) (ht : ∀ i,T*P i=P i*T) : + ∀ x∈space P,T x∈space P := by + intro x hx + apply closure_minimal (t := {x | T x∈space P}) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage T.continuous) hx + apply (Submodule.span_le.mpr ?_ : Submodule.span ℂ _≤(space P).comap T.toLinearMap) + rintro y ⟨i,ξ,rfl⟩ + change T (P i ξ)∈space P + rw [show T (P i ξ)=P i (T ξ) from congrArg (fun S : H →L[ℂ] H => S ξ) (ht i)] + exact generator_mem P i (T ξ) + +include hp in +lemma projection_commutes (T : H →L[ℂ] H) (ht : ∀ i,T*P i=P i*T) : + (space P).starProjection*T=T*(space P).starProjection := by + apply projection_commutes_of_invariant (space P) T (invariant P T ht) + apply invariant P (star T) + intro i + have he := congrArg star (ht i) + simpa only [star_mul,(hp i).isSelfAdjoint.star_eq] using he.symm + +include hp ho in +lemma inner_blocks (i j : ι) (hij : i≠j) (x y : H) : inner ℂ (P i x) (P j y)=0 := by + rw [←ContinuousLinearMap.adjoint_inner_right] + change inner ℂ x ((star (P i)*P j) y)=0 + rw [(hp i).isSelfAdjoint.star_eq,ho i j hij] + simp + +omit [CompleteSpace H] in +lemma norm_sum_sq (v : ι → H) (hv : ∀ i j,i≠j → inner ℂ (v i) (v j)=0) (s : Finset ι) : + ‖∑ i∈s,v i‖^2=∑ i∈s,‖v i‖^2 := by + classical + have hh : inner ℂ (∑ i∈s,v i) (∑ i∈s,v i)=∑ i∈s,inner ℂ (v i) (v i) := by + rw [sum_inner] + apply Finset.sum_congr rfl + intro i hi + rw [inner_sum,Finset.sum_eq_single_of_mem i hi] + intro j hj hji + exact hv i j hji.symm + simp_rw [@norm_sq_eq_re_inner ℂ] + change Complex.re (inner ℂ (∑ i∈s,v i) (∑ i∈s,v i))=∑ i∈s,Complex.re (inner ℂ (v i) (v i)) + rw [hh] + simp + +include hp ho in +theorem norm_le_of_blocks (T : H →L[ℂ] H) {c : ℝ} (hc : 0≤c) + (ht : ∀ i,T*P i=P i*T) + (hb : ∀ i x,‖T (P i x)‖≤c*‖P i x‖) + (hfull : (space P).starProjection=1) : ‖T‖≤c := by + apply ContinuousLinearMap.opNorm_le_bound _ hc + intro x + have hT (i j : ι) (hij : i≠j) : inner ℂ (T (P i x)) (T (P j x))=0 := by + have he (i : ι) : T (P i x)=P i (T x) := congrArg (fun S : H →L[ℂ] H => S x) (ht i) + rw [he,he] + exact inner_blocks P hp ho i j hij _ _ + have hs (s : Finset ι) : ‖T (finiteSum P s x)‖≤c*‖finiteSum P s x‖ := by + have he : finiteSum P s x=∑ i∈s,P i x := by simp [finiteSum] + rw [he,map_sum] + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hc (norm_nonneg _))).mp + rw [norm_sum_sq _ hT,mul_pow,norm_sum_sq _ (fun i j hij => inner_blocks P hp ho i j hij x x),Finset.mul_sum] + apply Finset.sum_le_sum + intro i hi + simpa only [mul_pow] using (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hc (norm_nonneg _))).mpr (hb i x) + have hlim : Tendsto (fun s : Finset ι => finiteSum P s x) atTop (𝓝 x) := by + simpa only [hfull,one_apply_eq_self] using finiteSum_tendsto P hp ho x + exact le_of_tendsto_of_tendsto ((T.continuous.tendsto x).comp hlim).norm + (hlim.norm.const_mul c) (Filter.Eventually.of_forall hs) + +end Kadison.ProjectionBlocks +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionChains.lean b/lean/OAI/Analysis/Commutator/ProjectionChains.lean new file mode 100644 index 0000000000000000000000000000000000000000..0212be8c4c16d02e7b4662c2fe54518e4204f9f3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionChains.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorAlgebra +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter ContinuousLinearMapWOT + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.ProjectionChains + +variable {H ι : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem monotone_ultralimit [Preorder ι] [IsDirectedOrder ι] [Nonempty ι] + (ω : Ultrafilter ι) (hω : (ω : Filter ι)≤atTop) + (P : ι → H →L[ℂ] H) (hp : ∀ i, IsStarProjection (P i)) (hmono : Monotone P) : + ∃ W : H →L[ℂ] H, IsStarProjection W ∧ (∀ i, P i≤W) ∧ + Tendsto (fun i => ofCLM (P i)) (ω : Filter ι) (𝓝 (ofCLM W)) ∧ + ∀ Q : H →L[ℂ] H, IsStarProjection Q → (∀ i, P i≤Q) → W≤Q := by + obtain ⟨W,_,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω P 1 zero_le_one + (fun i => (hp i).norm_le (P i)) + have hWot : Tendsto (fun i => ofCLM (P i)) (ω : Filter ι) (𝓝 (ofCLM W)) := by + apply tendsto_iff_forall_inner_apply_tendsto.mpr + intro x y + simpa only [RCLike.star_def,inner_conj_symm,ofCLM_apply] using (hlim x y).star + have hself : IsSelfAdjoint W := by + have heq : star (ofCLM W)=ofCLM W := tendsto_nhds_unique hWot.star + (hWot.congr' (Filter.Eventually.of_forall fun i => by + change ofCLM (P i)=star (ofCLM (P i)) + apply toCLM_injective + exact (hp i).isSelfAdjoint.star_eq.symm)) + exact congrArg toCLM heq + have hWP : ∀ i, W*P i=P i := by + intro i + apply WeakOperatorLimit.right_eq hlim + apply ((eventually_ge_atTop i).filter_mono hω).mono + intro j hij + exact ((hp i).le_iff_mul_eq_right (hp j)).mp (hmono hij) + have hWsq : W*W=W := by + have hh := WeakOperatorLimit.intertwine hlim 1 W (Filter.Eventually.of_forall + fun i => by simpa only [mul_one] using (hWP i).symm) + simpa only [mul_one] using hh.symm + have hproj : IsStarProjection W := ⟨hWsq,hself⟩ + refine ⟨W,hproj,fun i => ((hp i).le_iff_mul_eq_right hproj).mpr (hWP i),hWot,?_⟩ + intro Q hQ hPQ + have hh := WeakOperatorLimit.intertwine hlim Q 1 (Filter.Eventually.of_forall + fun i => by simpa only [one_mul] using ((hp i).le_iff_mul_eq_left hQ).mp (hPQ i)) + apply (hproj.le_iff_mul_eq_left hQ).mpr + simpa only [one_mul] using hh + +variable (M : VonNeumannAlgebra H) (τ : (H →L[ℂ] H) →ₚ[ℂ] ℂ) + +variable (e : H →L[ℂ] H) (t : ℝ) + +abbrev TraceCut := {p : H →L[ℂ] H // p∈M ∧ IsStarProjection p ∧ p≤e ∧ (τ p).re≤t} + +theorem cut_chain_upper (he : IsStarProjection e) + (hτ : Continuous (fun T : H →WOT[ℂ] H => (τ T.toCLM).re)) + (c : Set (TraceCut M τ e t)) (hc : IsChain (·≤·) c) (hne : c.Nonempty) : BddAbove c := by + let : Nonempty c := hne.to_subtype + let : IsDirectedOrder c := hc.directedOn.isDirectedOrder + let ω : Ultrafilter c := Ultrafilter.of atTop + have hω : (ω : Filter c)≤atTop := Ultrafilter.of_le atTop + let P : c → H →L[ℂ] H := fun v => v.val.val + obtain ⟨W,hW,hPW,hlim,hLeast⟩ := monotone_ultralimit ω hω P (fun i => i.val.property.2.1) + (fun _ _ h => h) + have hscalar : ∀ x y, Tendsto (fun i => inner ℂ (P i x) y) (ω : Filter c) + (𝓝 (inner ℂ (W x) y)) := by + intro x y + have h := tendsto_iff_forall_inner_apply_tendsto.mp hlim x y + simpa only [RCLike.star_def,inner_conj_symm,ofCLM_apply] using h.star + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hscalar M + (Filter.Eventually.of_forall fun i => i.val.property.1) + have hWe : W≤e := hLeast e he (fun i => i.val.property.2.2.1) + have htrace : (τ W).re≤t := le_of_tendsto ((hτ.tendsto (ofCLM W)).comp hlim) + (Filter.Eventually.of_forall fun i : c => i.val.property.2.2.2) + refine ⟨⟨W,hWM,hW,hWe,htrace⟩,?_⟩ + intro p hp + exact hPW ⟨p,hp⟩ + +end Kadison.ProjectionChains + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionCommutant.lean b/lean/OAI/Analysis/Commutator/ProjectionCommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6cecaeb9c0a424d15378f01b66a8318c1f8ecb2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionCommutant.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.SelfAdjointSpectral +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def vonNeumannIntersection (M N : VonNeumannAlgebra H) : VonNeumannAlgebra H where + toStarSubalgebra := M.toStarSubalgebra ⊓ N.toStarSubalgebra + centralizer_centralizer' := by + apply Set.Subset.antisymm + · intro a ha + constructor + · have hh := Set.centralizer_subset (Set.centralizer_subset + (show ((M.toStarSubalgebra ⊓ N.toStarSubalgebra : StarSubalgebra ℂ (H →L[ℂ] H)) : Set (H →L[ℂ] H)) ⊆ (M : Set (H →L[ℂ] H)) from fun _ h => h.1)) ha + simpa only [VonNeumannAlgebra.centralizer_centralizer,VonNeumannAlgebra.coe_toStarSubalgebra] using hh + · have hh := Set.centralizer_subset (Set.centralizer_subset + (show ((M.toStarSubalgebra ⊓ N.toStarSubalgebra : StarSubalgebra ℂ (H →L[ℂ] H)) : Set (H →L[ℂ] H)) ⊆ (N : Set (H →L[ℂ] H)) from fun _ h => h.2)) ha + simpa only [VonNeumannAlgebra.centralizer_centralizer,VonNeumannAlgebra.coe_toStarSubalgebra] using hh + · exact Set.subset_centralizer_centralizer + +@[simp] lemma mem_vonNeumannIntersection (M N : VonNeumannAlgebra H) (a : H →L[ℂ] H) : + a∈vonNeumannIntersection M N ↔ a∈M ∧ a∈N := Iff.rfl + +theorem commutes_algebra_of_commutes_projections (M : VonNeumannAlgebra H) (T : H →L[ℂ] H) + (hT : ∀ p∈M,IsStarProjection p → T*p=p*T) : + ∀ a∈M,T*a=a*T := by + have hself : ∀ a∈M,IsSelfAdjoint a → T*a=a*T := by + intro a ha hsa + have hclosed : IsClosed {b : H →L[ℂ] H | T*b=b*T} := isClosed_eq + (continuous_const.mul continuous_id) (continuous_id.mul continuous_const) + apply hclosed.closure_subset + rw [Metric.mem_closure_iff] + intro ε hε + obtain ⟨n,p,c,hp,_,he⟩ := Polar.exists_selfadjoint_spectral_sum M ha hsa hε + refine ⟨∑ i,c i • p i,?_,?_⟩ + · change T*(∑ i,c i • p i)=(∑ i,c i • p i)*T + simp only [Finset.mul_sum,Finset.sum_mul,mul_smul_comm,smul_mul_assoc] + exact Finset.sum_congr rfl (fun i _ => congrArg (fun z : H →L[ℂ] H => c i • z) + (hT (p i) (hp i).1 (hp i).2)) + · simpa only [dist_eq_norm] using he + intro a ha + let b : M := ⟨a,ha⟩ + have hR := hself (((realPart b):M):H →L[ℂ] H) ((realPart b):M).property + ((realPart b).property.map M.toStarSubalgebra.subtype) + have hI := hself (((imaginaryPart b):M):H →L[ℂ] H) ((imaginaryPart b):M).property + ((imaginaryPart b).property.map M.toStarSubalgebra.subtype) + have hid : (((realPart b):M):H →L[ℂ] H)+ + Complex.I • (((imaginaryPart b):M):H →L[ℂ] H)=a := + congrArg (fun x : M => (x:H →L[ℂ] H)) (realPart_add_I_smul_imaginaryPart b) + rw [←hid,mul_add,add_mul,mul_smul_comm,smul_mul_assoc,hR,hI] + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionComplements.lean b/lean/OAI/Analysis/Commutator/ProjectionComplements.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc5880c34436bb5fa286775362bb67096a90aa04 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionComplements.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionAddition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma conjugate_projection {e u : H →L[ℂ] H} (he : IsStarProjection e) + (hui : star u*u=1) : IsStarProjection (u*e*star u) := by + constructor + · change (u*e*star u)*(u*e*star u)=u*e*star u + calc + _=u*e*(star u*u)*e*star u := by noncomm_ring + _=u*e*star u := by rw [hui,mul_one,mul_assoc u e e,he.isIdempotentElem.eq] + · change star (u*e*star u)=u*e*star u + simp only [star_mul,star_star,he.isSelfAdjoint.star_eq,mul_assoc] + +lemma equivalent_conjugate {M : VonNeumannAlgebra H} {e u : H →L[ℂ] H} + (heM : e∈M) (huM : u∈M) (he : IsStarProjection e) (hui : star u*u=1) : + Equivalent M e (u*e*star u) := by + have hi : star (u*e)*(u*e)=e := by + rw [star_mul,he.isSelfAdjoint.star_eq,mul_assoc,←mul_assoc (star u),hui,one_mul, + he.isIdempotentElem.eq] + have hf : (u*e)*star (u*e)=u*e*star u := by + rw [star_mul,he.isSelfAdjoint.star_eq,←mul_assoc,mul_assoc u e e,he.isIdempotentElem.eq] + have ht : (u*e)*star (u*e)*(u*e)=u*e := by + rw [mul_assoc,hi,mul_assoc,he.isIdempotentElem.eq] + exact ⟨⟨u*e,M.mul_mem huM heM,ht,hi.le,hf.le⟩,hi,hf⟩ + +lemma subEquivalent_complement (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) (hfin : IsFiniteAlgebra M) + {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (he : IsStarProjection e) (hf : IsStarProjection f) (hef : SubEquivalent M e f) : + SubEquivalent M (1-f) (1-e) := by + obtain ⟨u,hu,hui,huf,hle⟩ := subEquivalent_unitary M hfac hfin heM he hef + have hconj : star u*(u*e*star u)*u=e := by + calc + _=(star u*u)*e*(star u*u) := by noncomm_ring + _=e := by rw [hui,one_mul,mul_one] + have he_le : e ≤ star u*f*u := by + simpa only [hconj] using star_left_conjugate_le_conjugate hle u + have hcomp : star u*(1-f)*u≤1-e := by + calc + _=1-star u*f*u := by rw [mul_sub,sub_mul,mul_one,hui] + _≤1-e := sub_le_sub_left he_le 1 + have hsu : star (star u)*star u=1 := by simpa only [star_star] using huf + have hg : IsStarProjection (star u*(1-f)*u) := by + simpa only [star_star] using (conjugate_projection (u := star u) hf.one_sub hsu) + have hgM : star u*(1-f)*u∈M := + M.mul_mem (M.mul_mem (M.star_mem' hu) (M.sub_mem M.one_mem hfM)) hu + have heq : Equivalent M (1-f) (star u*(1-f)*u) := by + simpa only [star_star] using + (equivalent_conjugate (M.sub_mem M.one_mem hfM) (M.star_mem' hu) hf.one_sub hsu) + exact heq.subEquivalent.trans hf.one_sub hg (subEquivalent_of_le hgM hg hcomp) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionDimensionTopology.lean b/lean/OAI/Analysis/Commutator/ProjectionDimensionTopology.lean new file mode 100644 index 0000000000000000000000000000000000000000..35d6cffbe0f90c072acae56760eeb53b3817a493 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionDimensionTopology.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Commutator.CountableProjectionJoin +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.DyadicDimensionComparison +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.ProjectionStrong + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.ProjectionDimensionTopology + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition ProjectionJoin + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin + +theorem strong_zero_of_geometric_dimension (P : ℕ → H →L[ℂ] H) + (hPM : ∀ n,P n∈M) (hP : ∀ n,IsStarProjection (P n)) + (hbound : ∀ n,dimension M hfac hd (P n)≤(1/2:ℝ)^n) (x : H) : + Tendsto (fun n => P n x) atTop (𝓝 0) := by + let T (n : ℕ) := sup M (fun k => P (n+k)) (fun k => hP (n+k)) (fun k => hPM (n+k)) + have hTM (n : ℕ) : T n∈M := sup_mem M _ _ _ + have hTP (n : ℕ) : IsStarProjection (T n) := sup_projection M _ _ _ + have hPT (n : ℕ) : P n≤T n := by + simpa only [Nat.add_zero] using le_sup M (fun k => P (n+k)) + (fun k => hP (n+k)) (fun k => hPM (n+k)) 0 + have hmono : Antitone T := by + apply antitone_nat_of_succ_le + intro n + apply sup_le M _ _ _ (hTP n) + intro k + have hh := le_sup M (fun k => P (n+k)) (fun k => hP (n+k)) (fun k => hPM (n+k)) (k+1) + simpa only [Nat.add_assoc,Nat.add_comm 1 k] using hh + have hdim (n : ℕ) : dimension M hfac hd (T n)≤2*(1/2:ℝ)^n := by + have hs : Summable (fun k : ℕ => (1/2:ℝ)^(n+k)) := by + simpa only [pow_add] using (summable_geometric_of_lt_one + (by norm_num : 0≤(1/2:ℝ)) (by norm_num : (1/2:ℝ)<1)).mul_left ((1/2:ℝ)^n) + have hh := dimension_sup_le M hfac hd hfin (fun k => P (n+k)) + (fun k => hP (n+k)) (fun k => hPM (n+k)) (fun k => (1/2:ℝ)^(n+k)) hs + (fun k => hbound (n+k)) + have he : (∑' k : ℕ,(1/2:ℝ)^(n+k))=2*(1/2:ℝ)^n := by + simp only [pow_add,tsum_mul_left] + rw [tsum_geometric_of_abs_lt_one (by norm_num : |(1/2:ℝ)|<1)] + ring + exact he ▸ hh + let Q (n : ℕ) := 1-T n + have hQM (n : ℕ) : Q n∈M := M.sub_mem M.one_mem (hTM n) + have hQP (n : ℕ) : IsStarProjection (Q n) := (hTP n).one_sub + have hQmono : Monotone Q := fun n m h => sub_le_sub_left (hmono h) 1 + obtain ⟨W,hWM,hWP,hQW,hlim,_⟩ := ProjectionChains.exists_strong_sup M Q hQP hQM hQmono + have hc : Tendsto (fun n : ℕ => (1/2:ℝ)^n) atTop (𝓝 0) := + tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num) (by norm_num) + have hdW : 1≤dimension M hfac hd W := by + have ht : Tendsto (fun n : ℕ => 1-2*(1/2:ℝ)^n) atTop (𝓝 1) := by + simpa only [mul_zero,sub_zero] using tendsto_const_nhds.sub (tendsto_const_nhds.mul hc) + apply le_of_tendsto ht + apply Filter.Eventually.of_forall + intro n + have hh := dimension_mono M hfac hd (hQM n) (hQP n) (hQW n) + change dimension M hfac hd (1-T n)≤_ at hh + rw [dimension_complement M hfac hd hfin (hTM n) (hTP n)] at hh + linarith [hdim n] + have hW : W=1 := by + have hdz : dimension M hfac hd (1-W)=0 := by + rw [dimension_complement M hfac hd hfin hWM hWP] + linarith [dimension_le_one M hfac hd W] + have he := (dimension_eq_zero_iff M hfac hd hfin (M.sub_mem M.one_mem hWM) + hWP.one_sub).mp hdz + exact (sub_eq_zero.mp he).symm + have hTlim : Tendsto (fun n => T n x) atTop (𝓝 0) := by + have hh := (tendsto_const_nhds (x := x)).sub (hlim x) + rw [hW] at hh + simpa only [Q,sub_apply,one_apply_eq_self,sub_sub_cancel,sub_self] using hh + apply tendsto_zero_iff_norm_tendsto_zero.mpr + exact squeeze_zero (fun n => norm_nonneg _) (fun n => + ProjectionChains.projection_norm_mono (hP n) (hTP n) (hPT n) x) (by + simpa only [norm_zero] using hTlim.norm) + +theorem vector_uniform_absolute_continuity (x : H) (ε : ℝ) (hε : 0<ε) : + ∃ δ : ℝ,0<δ ∧ ∀ p : H →L[ℂ] H,p∈M → IsStarProjection p → + dimension M hfac hd p<δ → ‖p x‖<ε := by + classical + by_contra hn + push Not at hn + have hex (n : ℕ) : ∃ p : H →L[ℂ] H,p∈M ∧ IsStarProjection p ∧ + dimension M hfac hd p<(1/2:ℝ)^n ∧ ε≤‖p x‖ := hn ((1/2:ℝ)^n) (by positivity) + choose P hPM hP hdP hnorm using hex + have ht := strong_zero_of_geometric_dimension M hfac hd hfin P hPM hP (fun n => (hdP n).le) x + have he := (show Tendsto (fun n => ‖P n x‖) atTop (𝓝 0) by + simpa only [norm_zero] using ht.norm).eventually_lt_const hε + obtain ⟨n,hn⟩ := he.exists + exact (not_lt_of_ge (hnorm n)) hn + +end Kadison.ProjectionDimensionTopology + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionDimensionUnitary.lean b/lean/OAI/Analysis/Commutator/ProjectionDimensionUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..ab9dfb0da12eefffdd13dfe221efab74ac14a479 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionDimensionUnitary.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicDimension +import OAI.Analysis.Commutator.ProjectionDimensionTopology + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) + +lemma projection_unitary_equivalent {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) + (u : unitary (H →L[ℂ] H)) (hu : (u : H →L[ℂ] H)∈M) : + Equivalent M p ((u : H →L[ℂ] H)*p*star (u : H →L[ℂ] H)) := by + have hi : star ((u : H →L[ℂ] H)*p)*((u : H →L[ℂ] H)*p)=p := by + simp only [star_mul,hp.isSelfAdjoint.star_eq,mul_assoc, + ←mul_assoc (star (u : H →L[ℂ] H)),u.property.1,one_mul,hp.isIdempotentElem.eq] + have hf : ((u : H →L[ℂ] H)*p)*star ((u : H →L[ℂ] H)*p)= + (u : H →L[ℂ] H)*p*star (u : H →L[ℂ] H) := by + rw [star_mul,hp.isSelfAdjoint.star_eq,←mul_assoc, mul_assoc (u : H →L[ℂ] H) p p, + hp.isIdempotentElem.eq] + refine ⟨⟨(u : H →L[ℂ] H)*p,M.mul_mem hu hpM,?_,hi.le,hf.le⟩,hi,hf⟩ + rw [mul_assoc,hi,mul_assoc,hp.isIdempotentElem.eq] + +lemma unitary_projection {p : H →L[ℂ] H} (hp : IsStarProjection p) + (u : unitary (H →L[ℂ] H)) : + IsStarProjection ((u : H →L[ℂ] H)*p*star (u : H →L[ℂ] H)) := by + exact hp.map (Unitary.conjStarAlgAut ℂ (H →L[ℂ] H) u) + +lemma dimension_unitary {p : H →L[ℂ] H} (hpM : p∈M) (hp : IsStarProjection p) + (u : unitary (H →L[ℂ] H)) (hu : (u : H →L[ℂ] H)∈M) : + dimension M hfac hd ((u : H →L[ℂ] H)*p*star (u : H →L[ℂ] H))= + dimension M hfac hd p := + (dimension_congr_equivalent M hfac hd hp (unitary_projection hp u) + (projection_unitary_equivalent M hpM hp u hu)).symm + +variable [Nontrivial H] [TopologicalSpace.SeparableSpace H] + +variable (hfin : IsFiniteAlgebra M) + +include hfin in +theorem orbit_vector_uniform_absolute_continuity (x : H) (ε : ℝ) (hε : 0<ε) : + ∃ δ : ℝ,0<δ ∧ ∀ p : H →L[ℂ] H,p∈M → IsStarProjection p → + dimension M hfac hd p<δ → ∀ u : unitary (H →L[ℂ] H), + (u : H →L[ℂ] H)∈M → ‖p ((u : H →L[ℂ] H) x)‖<ε := by + obtain ⟨δ,hδ,h⟩ := ProjectionDimensionTopology.vector_uniform_absolute_continuity + M hfac hd hfin x ε hε + refine ⟨δ,hδ,?_⟩ + intro p hpM hp hdp u hu + have hqM : ((star u : unitary (H →L[ℂ] H)) : H →L[ℂ] H)*p* + star ((star u : unitary (H →L[ℂ] H)) : H →L[ℂ] H)∈M := + M.mul_mem (M.mul_mem (M.star_mem' hu) hpM) (by simpa using hu) + have hq := h _ hqM (unitary_projection hp (star u)) (by + rw [dimension_unitary M hfac hd hpM hp (star u) (M.star_mem' hu)] + exact hdp) + simpa only [Unitary.coe_star,star_star,mul_apply_eq_comp, + ←Unitary.coe_star,Unitary.norm_map] using hq + +end Kadison.PartialIsometryOrder.DyadicPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionEquivalence.lean b/lean/OAI/Analysis/Commutator/ProjectionEquivalence.lean new file mode 100644 index 0000000000000000000000000000000000000000..03ef0fed4cc4043fed5088517a2f8229488711cd --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionEquivalence.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteCancellation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def SubEquivalent (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) : Prop := + ∃ v : Link M e f, v.initial=e + +def Equivalent (M : VonNeumannAlgebra H) (e f : H →L[ℂ] H) : Prop := + ∃ v : Link M e f, v.initial=e ∧ v.final=f + +namespace Link + +variable {M : VonNeumannAlgebra H} {e f g : H →L[ℂ] H} + +def adjoint (v : Link M e f) : Link M f e := + ⟨star v.val,M.star_mem' v.mem,by + simpa only [star_mul,star_star,←mul_assoc] using congrArg star v.triple, + by simpa only [star_star] using v.target_le, + by simpa only [star_star] using v.source_le⟩ + +@[simp] lemma adjoint_initial (v : Link M e f) : v.adjoint.initial=v.final := by + simp only [initial,final,adjoint,star_star] + +@[simp] lemma adjoint_final (v : Link M e f) : v.adjoint.final=v.initial := by + simp only [initial,final,adjoint,star_star] + +def compFull (w : Link M f g) (v : Link M e f) + (he : IsStarProjection e) (hf : IsStarProjection f) + (hvi : v.initial=e) (hwi : w.initial=f) : Link M e g := by + have hi : star (w.val*v.val)*(w.val*v.val)=e := by + rw [star_mul,mul_assoc,←mul_assoc (star w.val),←Link.initial,hwi,v.target_mul hf,←Link.initial,hvi] + have ht : (w.val*v.val)*star (w.val*v.val)*(w.val*v.val)=w.val*v.val := by + rw [mul_assoc,hi,mul_assoc,v.mul_source he] + have hfin : IsStarProjection ((w.val*v.val)*star (w.val*v.val)) := by + refine ⟨?_,IsSelfAdjoint.mul_star_self _⟩ + change ((w.val*v.val)*star (w.val*v.val))*((w.val*v.val)*star (w.val*v.val))=_ + rw [←mul_assoc,ht] + have hle : (w.val*v.val)*star (w.val*v.val)≤w.final := by + apply (hfin.le_iff_mul_eq_right w.final_projection).mpr + change (w.val*star w.val)*((w.val*v.val)*star (w.val*v.val))=_ + rw [←mul_assoc,←mul_assoc,w.triple] + exact ⟨w.val*v.val,M.mul_mem w.mem v.mem,ht,hi.le,hle.trans w.target_le⟩ + +@[simp] lemma compFull_initial (w : Link M f g) (v : Link M e f) + (he : IsStarProjection e) (hf : IsStarProjection f) + (hvi : v.initial=e) (hwi : w.initial=f) : + (w.compFull v he hf hvi hwi).initial=e := by + change star (w.val*v.val)*(w.val*v.val)=e + rw [star_mul,mul_assoc,←mul_assoc (star w.val),←Link.initial,hwi,v.target_mul hf,←Link.initial,hvi] + +lemma compFull_final (w : Link M f g) (v : Link M e f) + (he : IsStarProjection e) (hf : IsStarProjection f) + (hvi : v.initial=e) (hwi : w.initial=f) (hvf : v.final=f) : + (w.compFull v he hf hvi hwi).final=w.final := by + change (w.val*v.val)*star (w.val*v.val)=w.val*star w.val + rw [star_mul,mul_assoc,←mul_assoc v.val,←Link.final,hvf,←mul_assoc,w.mul_source hf] + +end Link + +lemma subEquivalent_of_le {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) (hef : e≤f) : SubEquivalent M e f := by + have hi : star e*e=e := by rw [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq] + refine ⟨⟨e,heM,?_,by rw [hi],?_⟩,hi⟩ + · rw [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq,he.isIdempotentElem.eq] + · rwa [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq] + +lemma equivalent_refl {M : VonNeumannAlgebra H} {e : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) : Equivalent M e e := by + + have hi : star e*e=e := by rw [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq] + exact ⟨⟨e,heM,by rw [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq,he.isIdempotentElem.eq], + hi.le,by simp only [he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq,le_refl]⟩, + hi,by simp only [Link.final,he.isSelfAdjoint.star_eq,he.isIdempotentElem.eq]⟩ + +lemma Equivalent.symm {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + (h : Equivalent M e f) : Equivalent M f e := by + obtain ⟨v,hi,hf⟩ := h + exact ⟨v.adjoint,by simpa using hf,by simpa using hi⟩ + +lemma Equivalent.subEquivalent {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + (h : Equivalent M e f) : SubEquivalent M e f := by + obtain ⟨v,hi,_⟩ := h + exact ⟨v,hi⟩ + +lemma SubEquivalent.trans {M : VonNeumannAlgebra H} {e f g : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) + (h : SubEquivalent M e f) (k : SubEquivalent M f g) : SubEquivalent M e g := by + obtain ⟨v,hv⟩ := h + obtain ⟨w,hw⟩ := k + exact ⟨w.compFull v he hf hv hw,w.compFull_initial v he hf hv hw⟩ + +lemma Equivalent.trans {M : VonNeumannAlgebra H} {e f g : H →L[ℂ] H} + (he : IsStarProjection e) (hf : IsStarProjection f) + (h : Equivalent M e f) (k : Equivalent M f g) : Equivalent M e g := by + obtain ⟨v,hvi,hvf⟩ := h + obtain ⟨w,hwi,hwf⟩ := k + exact ⟨w.compFull v he hf hvi hwi,w.compFull_initial v he hf hvi hwi, + (w.compFull_final v he hf hvi hwi hvf).trans hwf⟩ + +lemma factor_subEquivalent_total (M : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor M) {e f : H →L[ℂ] H} + (heM : e∈M) (hfM : f∈M) (he : IsStarProjection e) (hf : IsStarProjection f) : + SubEquivalent M e f ∨ SubEquivalent M f e := by + obtain ⟨v,hv⟩ := factor_comparison M hfac heM hfM he hf + rcases hv with hv|hv + · exact Or.inl ⟨v,hv⟩ + · exact Or.inr ⟨v.adjoint,by simpa using hv⟩ + +lemma finite_subEquivalent_antisymm_of_le {M : VonNeumannAlgebra H} + (hfin : IsFiniteAlgebra M) {e f : H →L[ℂ] H} + (hfM : f∈M) (hf : IsStarProjection f) (hef : e≤f) + (hfe : SubEquivalent M f e) : e=f := by + obtain ⟨v,hvi⟩ := hfe + let w : Link M f f := ⟨v.val,v.mem,v.triple,v.source_le,v.target_le.trans hef⟩ + have hwf : w.final=f := finite_corner_cancel hfin hfM hf w hvi + apply le_antisymm hef + exact hwf ▸ v.target_le + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionFaithfulFunctional.lean b/lean/OAI/Analysis/Commutator/ProjectionFaithfulFunctional.lean new file mode 100644 index 0000000000000000000000000000000000000000..924018fd993a67872921be3f6448a8e92ded43c9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionFaithfulFunctional.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicSpectral +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.ProjectionFaithfulFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +theorem positive_eq_zero_of_projection_faithful + (hfaith : ∀ p : M,IsStarProjection (p : H →L[ℂ] H) → τ p=0 → p=0) + (a : M) (ha : 0≤a) (hτa : τ a=0) : a=0 := by + let c : ℝ := ‖a‖+1 + have hc : 0 + have hz : τ (B 0)=0 := hτb + have hsmall : τ (P 0)≤0 := by + have h : τ (P 0)≤τ (B 0+B 0) := τ.monotone + (show P 0≤B 0+B 0 from sub_nonneg.mp (hnext 0 ▸ hBpos 1)) + simpa only [map_add,hz,zero_add] using h + exact ⟨hz,hfaith (P 0) (hPproj 0) (le_antisymm hsmall (τ.map_nonneg (hPpos 0)))⟩ + | succ n ih => + have hz : τ (B (n+1))=0 := by rw [hnext,ih.2,sub_zero,map_add,ih.1,zero_add] + have hsmall : τ (P (n+1))≤0 := by + have h : τ (P (n+1))≤τ (B (n+1)+B (n+1)) := τ.monotone + (show P (n+1)≤B (n+1)+B (n+1) from + sub_nonneg.mp (hnext (n+1) ▸ hBpos (n+2))) + simpa only [map_add,hz,zero_add] using h + exact ⟨hz,hfaith (P (n+1)) (hPproj (n+1)) + (le_antisymm hsmall (τ.map_nonneg (hPpos (n+1))))⟩ + have hstep (n : ℕ) : Polar.dyadicStep (b:H →L[ℂ] H) n=0 := by + apply Finset.sum_eq_zero + intro i hi + have he : Polar.halfCut (Polar.dyadicRemainder (b:H →L[ℂ] H) i)=0 := + congrArg (fun a : M => (a:H →L[ℂ] H)) (hPτ i).2 + rw [he,smul_zero] + have hnorm : ‖b‖≤0 := by + apply le_of_tendsto_of_tendsto (tendsto_const_nhds (x:=‖b‖)) + (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : (0:ℝ)≤2⁻¹) (by norm_num)) + apply Eventually.of_forall + intro n + have h := Polar.dyadicStep_norm_error hb hb1 n + change ‖(b:H →L[ℂ] H)‖≤2⁻¹^n + simpa only [hstep,sub_zero] using h + have hzero : b=0 := norm_le_zero_iff.mp hnorm + have hc0 : ((c⁻¹:ℝ):ℂ)≠0 := by exact_mod_cast inv_ne_zero hc.ne' + exact (smul_eq_zero.mp hzero).resolve_left hc0 + +end Kadison.ProjectionFaithfulFunctional + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionJoin.lean b/lean/OAI/Analysis/Commutator/ProjectionJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b586994bad7c9c8452513eedb42a2989922f41c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionJoin.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.DyadicDimensionAdd +import OAI.Analysis.Commutator.DyadicDimensionComparison + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.ProjectionJoin + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def remainder (p q : H →L[ℂ] H) : H →L[ℂ] H := Polar.leftSupport ((1-p)*q) + +def join (p q : H →L[ℂ] H) : H →L[ℂ] H := p+remainder p q + +lemma remainder_projection (p q : H →L[ℂ] H) : IsStarProjection (remainder p q) := + Polar.isProjection_leftSupport _ + +lemma remainder_le {p : H →L[ℂ] H} (hp : IsStarProjection p) (q : H →L[ℂ] H) : + remainder p q≤1-p := by + apply Polar.leftSupport_le _ _ hp.one_sub + rw [←mul_assoc,hp.one_sub.isIdempotentElem.eq] + +lemma remainder_mul {p : H →L[ℂ] H} (hp : IsStarProjection p) (q : H →L[ℂ] H) : + remainder p q*p=0 := by + have h := ((remainder_projection p q).le_iff_mul_eq_left hp.one_sub).mp (remainder_le hp q) + rw [mul_sub,mul_one] at h + exact sub_eq_self.mp h + +lemma mul_remainder {p : H →L[ℂ] H} (hp : IsStarProjection p) (q : H →L[ℂ] H) : + p*remainder p q=0 := by + simpa only [star_mul,hp.isSelfAdjoint.star_eq,(remainder_projection p q).isSelfAdjoint.star_eq, + star_zero] using congrArg star (remainder_mul hp q) + +lemma join_projection {p : H →L[ℂ] H} (hp : IsStarProjection p) (q : H →L[ℂ] H) : + IsStarProjection (join p q) := by + refine ⟨?_,hp.isSelfAdjoint.add (remainder_projection p q).isSelfAdjoint⟩ + change (p+remainder p q)*(p+remainder p q)=p+remainder p q + rw [add_mul,mul_add,mul_add,hp.isIdempotentElem.eq,(remainder_projection p q).isIdempotentElem.eq, + mul_remainder hp q,remainder_mul hp q,add_zero,zero_add] + +lemma left_le {p : H →L[ℂ] H} (hp : IsStarProjection p) (q : H →L[ℂ] H) : p≤join p q := by + apply (hp.le_iff_mul_eq_left (join_projection hp q)).mpr + change p*(p+remainder p q)=p + rw [mul_add,hp.isIdempotentElem.eq,mul_remainder hp q,add_zero] + +lemma right_le {p q : H →L[ℂ] H} (hp : IsStarProjection p) (hq : IsStarProjection q) : q≤join p q := by + apply (hq.le_iff_mul_eq_right (join_projection hp q)).mpr + have hs : remainder p q*((1-p)*q)=(1-p)*q := Polar.leftSupport_mul _ + have hsp : remainder p q*(1-p)=remainder p q := by + rw [mul_sub,mul_one,remainder_mul hp q,sub_zero] + rw [←mul_assoc,hsp] at hs + change (p+remainder p q)*q=q + rw [add_mul,hs,sub_mul,one_mul] + abel + +lemma join_le {p q r : H →L[ℂ] H} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hr : IsStarProjection r) (hpr : p≤r) (hqr : q≤r) : join p q≤r := by + have hrp := (hp.le_iff_mul_eq_right hr).mp hpr + have hrq := (hq.le_iff_mul_eq_right hr).mp hqr + have hs : remainder p q≤r := by + apply Polar.leftSupport_le _ _ hr + rw [←mul_assoc,mul_sub,mul_one,hrp,sub_mul,hrq,sub_mul,one_mul] + apply ((join_projection hp q).le_iff_mul_eq_right hr).mpr + change r*(p+remainder p q)=p+remainder p q + rw [mul_add,hrp,((remainder_projection p q).le_iff_mul_eq_right hr).mp hs] + +lemma remainder_mem (M : VonNeumannAlgebra H) {p q : H →L[ℂ] H} (hp : p∈M) (hq : q∈M) : + remainder p q∈M := Polar.leftSupport_mem M (M.mul_mem (M.sub_mem M.one_mem hp) hq) + +lemma join_mem (M : VonNeumannAlgebra H) {p q : H →L[ℂ] H} (hp : p∈M) (hq : q∈M) : + join p q∈M := M.add_mem hp (remainder_mem M hp hq) + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition + +variable [Nontrivial H] (M : VonNeumannAlgebra H) (hfac : FactorCorner.IsFactor M) + (hd : DiffuseProjection.HasNoMinimalProjections M) (hfin : IsFiniteAlgebra M) + +include hfin in +theorem dimension_join_le {p q : H →L[ℂ] H} (hpM : p∈M) (hqM : q∈M) + (hp : IsStarProjection p) (hq : IsStarProjection q) : + dimension M hfac hd (join p q)≤dimension M hfac hd p+dimension M hfac hd q := by + let T := (1-p)*q + have hTM : T∈M := M.mul_mem (M.sub_mem M.one_mem hpM) hqM + have heq : Equivalent M (Polar.rightSupport T) (Polar.leftSupport T) := by + let v := Polar.partialIsometry T + refine ⟨⟨v,Polar.partialIsometry_mem_vonNeumann M hTM,Polar.partialIsometry_triple T,?_,le_rfl⟩,?_,rfl⟩ + · rw [Polar.rightSupport,Polar.partialIsometry_initial] + · exact Polar.partialIsometry_initial T + have hdim := dimension_congr_equivalent M hfac hd (Polar.isProjection_rightSupport T) + (Polar.isProjection_leftSupport T) heq + have hle : Polar.rightSupport T≤q := by + apply Polar.rightSupport_le T q hq + dsimp [T] + rw [mul_assoc,hq.isIdempotentElem.eq] + have hdle := dimension_mono M hfac hd (Polar.rightSupport_mem M hTM) + (Polar.isProjection_rightSupport T) hle + rw [join,dimension_orthogonal_add M hfac hd hfin hpM (remainder_mem M hpM hqM) + hp (remainder_projection p q) (mul_remainder hp q)] + apply add_le_add le_rfl + change dimension M hfac hd (Polar.leftSupport T)≤_ + rw [←hdim] + exact hdle + +end Kadison.ProjectionJoin + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionLifts.lean b/lean/OAI/Analysis/Commutator/ProjectionLifts.lean new file mode 100644 index 0000000000000000000000000000000000000000..70c67b3350acca42e1e2418080321b609429e43c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionLifts.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.Commutator.BoundedPositiveSequence +import OAI.Analysis.Commutator.CStarContractiveLifts +import OAI.Analysis.Commutator.SpectralCutoff +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped BoundedContinuousFunction ComplexOrder + +namespace Kadison.ProjectionLifts + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def halfCut (a : M) : M := ⟨Polar.halfCut (a : H →L[ℂ] H),Polar.halfCut_mem M a.property⟩ + +lemma isProjection_halfCut (a : M) : IsStarProjection (halfCut M a) := by + constructor + · apply Subtype.ext + exact (Polar.isProjection_halfCut (a : H →L[ℂ] H)).isIdempotentElem.eq + · apply Subtype.ext + exact (Polar.isProjection_halfCut (a : H →L[ℂ] H)).isSelfAdjoint.star_eq + +lemma rounding (a : M) (h0 : 0≤a) (h1 : a≤1) : + star (halfCut M a-a)*(halfCut M a-a)≤a-a*a := + Polar.halfCut_rounding h0 h1 + +variable {ι : Type*} [TopologicalSpace ι] [DiscreteTopology ι] + +def roundedSequence (c : ι →ᵇ M) : ι →ᵇ M := + BoundedContinuousFunction.ofNormedAddCommGroupDiscrete (fun i => halfCut M (c i)) 1 + (fun i => (isProjection_halfCut M (c i)).norm_le _) + +@[simp] lemma roundedSequence_apply (c : ι →ᵇ M) (i : ι) : + roundedSequence M c i=halfCut M (c i) := rfl + +lemma roundedSequence_projection (c : ι →ᵇ M) : IsStarProjection (roundedSequence M c) := by + constructor + · apply BoundedContinuousFunction.ext + intro i + exact (isProjection_halfCut M (c i)).isIdempotentElem.eq + · apply BoundedContinuousFunction.ext + intro i + exact (isProjection_halfCut M (c i)).isSelfAdjoint.star_eq + +variable {B : Type*} [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +theorem projection_lift (φ : (ι →ᵇ M) →⋆ₐ[ℂ] B) {p : B} (hp : IsStarProjection p) + (hr : p∈Set.range φ) : ∃ q : ι →ᵇ M, (∀ i, IsStarProjection (q i)) ∧ φ q=p := by + obtain ⟨b,hb,hbp⟩ := CStarContractiveLifts.contraction φ (hp.norm_le p) hr + let c : ι →ᵇ M := star b*b + have hc (i : ι) : 0≤c i := star_mul_self_nonneg (b i) + have hc1 (i : ι) : c i≤1 := by + apply (CStarAlgebra.norm_le_one_iff_of_nonneg _ (hc i)).mp + change ‖star (b i)*b i‖≤1 + rw [CStarRing.norm_star_mul_self] + have hbi : ‖b i‖≤1 := (b.norm_coe_le_norm i).trans hb + nlinarith [norm_nonneg (b i)] + have hcp : φ c=p := by + dsimp only [c] + rw [map_mul,map_star,hbp,hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + let q := roundedSequence M c + let d := c-c*c-star (q-c)*(q-c) + have hd (i : ι) : 0≤d i := by + change 0≤c i-c i*c i-star (halfCut M (c i)-c i)*(halfCut M (c i)-c i) + exact sub_nonneg.mpr (rounding M (c i) (hc i) (hc1 i)) + have hφd := BoundedPositiveSequence.map_nonneg φ d hd + have hneg : star (φ q-p)*(φ q-p)≤0 := by + dsimp only [d] at hφd + simpa only [map_sub,map_mul,map_star,hcp,hp.isIdempotentElem.eq,sub_self, + zero_sub,neg_nonneg] using hφd + have he : φ q-p=0 := (CStarRing.star_mul_self_eq_zero_iff _).mp + (le_antisymm hneg (star_mul_self_nonneg _)) + exact ⟨q,fun i => isProjection_halfCut M (c i),sub_eq_zero.mp he⟩ + +end Kadison.ProjectionLifts + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionNormalBridge.lean b/lean/OAI/Analysis/Commutator/ProjectionNormalBridge.lean new file mode 100644 index 0000000000000000000000000000000000000000..debeca892353d3af55eeb59d0b26c3414c307ed4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionNormalBridge.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalPredual +import OAI.Analysis.Commutator.ProjectionNormalStrong + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def strongFunctional (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) : StrongDual ℂ M where + toLinearMap := f.toLinearMap + cont := map_continuous f + +theorem mem_predual [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (hf : ProjectionContinuousAtOne M f) : + strongFunctional M f∈closure (NormalPredual.finiteTests M (TopologicalSpace.denseSeq H)) := by + apply NormalPredual.mem_closure_of_strong_null M (TopologicalSpace.denseSeq H) + (TopologicalSpace.denseRange_denseSeq H) + intro T hT ht + exact contraction_strong_null M f hf T hT ht + +theorem boundedWOTContinuous [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (hf : ProjectionContinuousAtOne M f) : + NormalPredual.BoundedWOTContinuous M (strongFunctional M f) := + NormalPredual.normal_of_mem_closure M (TopologicalSpace.denseSeq H) (mem_predual M f hf) + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionNormalPositive.lean b/lean/OAI/Analysis/Commutator/ProjectionNormalPositive.lean new file mode 100644 index 0000000000000000000000000000000000000000..54f36519b25c27487eed54dc8490d5fc0e173752 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionNormalPositive.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Commutator.SpectralCompression +import OAI.Analysis.Commutator.SpectralExhaustion +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def ProjectionContinuousAtOne (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) : Prop := + ∀ P : ℕ → M,(∀ n,IsStarProjection (P n : H →L[ℂ] H)) → + Monotone (fun n => (P n : H →L[ℂ] H)) → + (∀ x,Tendsto (fun n => (P n : H →L[ℂ] H) x) atTop (𝓝 x)) → + Tendsto (fun n => f (P n)) atTop (𝓝 (f 1)) + +lemma functional_compression_bound (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) + (A E : M) (hA : 0≤A) (h1 : A≤1) (hE : IsStarProjection (E : H →L[ℂ] H)) : + ‖f A‖≤2*‖f (E*A*E)‖+2*‖f (1-E)‖ := by + have hl : A≤(E*A*E+E*A*E)+((1-E)+(1-E)) := by + have hh := positive_compression_bound (show 0≤(A:H →L[ℂ] H) from hA) + (show (A:H →L[ℂ] H)≤1 from h1) hE + change (A:H →L[ℂ] H)≤(E:H →L[ℂ] H)*(A:H →L[ℂ] H)*(E:H →L[ℂ] H)+ + (E:H →L[ℂ] H)*(A:H →L[ℂ] H)*(E:H →L[ℂ] H)+ + ((1:H →L[ℂ] H)-(E:H →L[ℂ] H)+((1:H →L[ℂ] H)-(E:H →L[ℂ] H))) + simpa only [two_smul ℝ] using hh + have hn := CStarAlgebra.norm_le_norm_of_le_of_nonneg (f.monotone hl) (f.map_nonneg hA) + change ‖f A‖≤‖f ((E*A*E+E*A*E)+((1-E)+(1-E)))‖ at hn + simp only [map_add] at hn + have ht := norm_add_le (f (E*A*E)+f (E*A*E)) (f (1-E)+f (1-E)) + have ht1 := norm_add_le (f (E*A*E)) (f (E*A*E)) + have ht2 := norm_add_le (f (1-E)) (f (1-E)) + linarith + +theorem positive_subsequence_null [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (hf : ProjectionContinuousAtOne M f) + (A : ℕ → M) (hA : ∀ n,0≤A n) (h1 : ∀ n,A n≤1) + (ht : ∀ x,Tendsto (fun n => (A n : H →L[ℂ] H) x) atTop (𝓝 0)) : + ∃ u : ℕ → ℕ,StrictMono u ∧ Tendsto (fun n => f (A (u n))) atTop (𝓝 0) := by + obtain ⟨u,hu,B,hBM,hB,hB1,hi,hdecay⟩ := exists_smoothing_subsequence M + (fun n => (A n : H →L[ℂ] H)) (fun n => (A n).property) hA ht + let P (n : ℕ) : M := ⟨threshold B (1/((n:ℝ)+1)),threshold_mem M hBM _⟩ + have hp (n : ℕ) : IsStarProjection (P n : H →L[ℂ] H) := threshold_projection B _ + obtain ⟨hmono,hstrong⟩ := threshold_exhaustion M hBM hB hi + have hfp : Tendsto (fun n => f (P n)) atTop (𝓝 (f 1)) := hf P hp hmono hstrong + have hfq : Tendsto (fun n => ‖f (1-P n)‖) atTop (𝓝 0) := by + simp only [map_sub] + simpa only [sub_self,norm_zero] using ((tendsto_const_nhds (x:=f 1)).sub hfp).norm + have hbab : Tendsto (fun k => B*(A (u k) : H →L[ℂ] H)*B) atTop (𝓝 0) := + tendsto_zero_iff_norm_tendsto_zero.mpr + (squeeze_zero (fun _ => norm_nonneg _) hdecay tendsto_one_div_add_atTop_nhds_zero_nat) + have hcompress (n : ℕ) : Tendsto (fun k => ‖f (P n*A (u k)*P n)‖) atTop (𝓝 0) := by + have hh := threshold_compression_tendsto hB (by positivity : (0:ℝ)<1/((n:ℝ)+1)) + (fun k => (A (u k) : H →L[ℂ] H)) hbab + have hs : Tendsto (fun k => P n*A (u k)*P n) atTop (𝓝 (0:M)) := tendsto_subtype_rng.mpr hh + have hfc : Continuous f := map_continuous f + simpa only [Function.comp_def,map_zero,norm_zero] using (hfc.tendsto 0 |>.comp hs).norm + refine ⟨u,hu,tendsto_zero_iff_norm_tendsto_zero.mpr ?_⟩ + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨n,hn⟩ := (hfq.eventually_lt_const (show (0:ℝ)<ε/8 by positivity)).exists + obtain ⟨K,hK⟩ := eventually_atTop.mp ((hcompress n).eventually_lt_const (show (0:ℝ)<ε/8 by positivity)) + refine ⟨K,?_⟩ + intro k hk + have hb := functional_compression_bound M f (A (u k)) (P n) (hA _) (h1 _) (hp n) + have hsmall := hK k hk + simpa only [dist_zero_right,Real.norm_eq_abs,abs_norm] using (show ‖f (A (u k))‖<ε by linarith) + +theorem positive_strong_null [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (hf : ProjectionContinuousAtOne M f) + (A : ℕ → M) (hA : ∀ n,0≤A n) (h1 : ∀ n,A n≤1) + (ht : ∀ x,Tendsto (fun n => (A n : H →L[ℂ] H) x) atTop (𝓝 0)) : + Tendsto (fun n => f (A n)) atTop (𝓝 0) := by + apply tendsto_of_subseq_tendsto + intro v hv + obtain ⟨u,hu,hlim⟩ := positive_subsequence_null M f hf (fun n => A (v n)) + (fun n => hA (v n)) (fun n => h1 (v n)) (fun x => (ht x).comp hv) + exact ⟨u,hlim⟩ + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionNormalStrong.lean b/lean/OAI/Analysis/Commutator/ProjectionNormalStrong.lean new file mode 100644 index 0000000000000000000000000000000000000000..df8b8ed9197353ff1aa0841b6886ec0ac5c993de --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionNormalStrong.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionNormalPositive + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma functional_cauchySchwarz (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (a : M) : + ‖f a‖^2≤(f 1).re*(f (star a*a)).re := by + have hi := norm_inner_le_norm (𝕜:=ℂ) (f.toPreGNS 1) (f.toPreGNS a) + have hs := (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg _) (norm_nonneg _))).mpr hi + have he (b : M) : ‖f.toPreGNS b‖^2=(f (star b*b)).re := by + rw [norm_sq_eq_re_inner (𝕜:=ℂ)] + rfl + rw [mul_pow,he 1,he a] at hs + simpa only [f.preGNS_inner_def,f.ofPreGNS_toPreGNS,star_one,one_mul] using hs + +theorem contraction_strong_null [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (f : M →ₚ[ℂ] ℂ) (hf : ProjectionContinuousAtOne M f) + (T : ℕ → M) (hT : ∀ n,‖T n‖≤1) + (ht : ∀ x,Tendsto (fun n => (T n : H →L[ℂ] H) x) atTop (𝓝 0)) : + Tendsto (fun n => f (T n)) atTop (𝓝 0) := by + have hpos (n : ℕ) : (0:M)≤ star (T n)*T n := star_mul_self_nonneg _ + have hnorm (n : ℕ) : ‖star (T n)*T n‖≤1 := by + rw [CStarRing.norm_star_mul_self] + nlinarith [norm_nonneg (T n),hT n] + have hone (n : ℕ) : star (T n)*T n≤1 := + (CStarAlgebra.norm_le_one_iff_of_nonneg _ (hpos n)).mp (hnorm n) + have hs (x : H) : Tendsto (fun n => ((star (T n)*T n : M) : H →L[ℂ] H) x) atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply squeeze_zero (fun _ => norm_nonneg _) _ ((ht x).norm.trans (by simp)) + intro n + change ‖(star (T n) : H →L[ℂ] H) ((T n : H →L[ℂ] H) x)‖≤_ + calc + _ ≤ ‖(star (T n) : H →L[ℂ] H)‖*‖(T n : H →L[ℂ] H) x‖ := + ContinuousLinearMap.le_opNorm _ _ + _ ≤ 1*‖(T n : H →L[ℂ] H) x‖ := mul_le_mul_of_nonneg_right + (by simpa using hT n) (norm_nonneg _) + _ = _ := one_mul _ + have hlim := positive_strong_null M f hf (fun n => star (T n)*T n) hpos hone hs + have hre : Tendsto (fun n => (f 1).re*(f (star (T n)*T n)).re) atTop (𝓝 0) := by + simpa only [Function.comp_def,Complex.zero_re,mul_zero] using + (Complex.continuous_re.tendsto 0 |>.comp hlim).const_mul (f 1).re + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨N,hN⟩ := eventually_atTop.mp (hre.eventually_lt_const (sq_pos_of_pos hε)) + refine ⟨N,?_⟩ + intro n hn + have hc := functional_cauchySchwarz M f (T n) + have hh := hN n hn + have hl : ‖f (T n)‖<ε := by nlinarith [norm_nonneg (f (T n))] + simpa only [dist_zero_right,Real.norm_eq_abs,abs_norm] using hl + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionPartition.lean b/lean/OAI/Analysis/Commutator/ProjectionPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..be0c357edd217d96603e976745e7b6c2fba97426 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionPartition.lean @@ -0,0 +1,116 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.SpectralPartition + +variable {R : Type*} [Ring R] [StarRing R] + +omit [StarRing R] in +lemma swap_middle (a b c d : R) (hc : Commute b c) : + (a*b)*(c*d)=(a*c)*(b*d) := by + calc + (a*b)*(c*d)=a*((b*c)*d) := by simp only [mul_assoc] + _=a*((c*b)*d) := by rw [hc.eq] + _=(a*c)*(b*d) := by simp only [mul_assoc] + +def splitPiece (p : R) (b : Bool) : R := if b then p else 1-p + +lemma splitPiece_projection {p : R} (hp : IsStarProjection p) (b : Bool) : + IsStarProjection (splitPiece p b) := by + cases b + · exact hp.one_sub + · exact hp + +omit [StarRing R] in +lemma splitPiece_commute {p a : R} (h : Commute a p) (b : Bool) : + Commute a (splitPiece p b) := by + cases b + · exact (Commute.one_right a).sub_right h + · exact h + +lemma splitPiece_orthogonal {p : R} (hp : IsStarProjection p) {b c : Bool} (h : b≠c) : + splitPiece p b*splitPiece p c=0 := by + cases b <;> cases c <;> simp_all [splitPiece,mul_sub,sub_mul,hp.isIdempotentElem.eq] + +omit [StarRing R] in +lemma splitPiece_sum (p : R) : (∑ b : Bool,splitPiece p b)=1 := by + simp [splitPiece] + +theorem exists_partition (n : ℕ) (p : Fin n → R) + (hp : ∀ i,IsStarProjection (p i)) (hc : ∀ i j,Commute (p i) (p j)) : + ∃ (J : Type) (_ : Fintype J) (e : J → R), + (∀ j,IsStarProjection (e j)) ∧ + (∀ j k,j≠k → e j*e k=0) ∧ + (∑ j,e j)=1 ∧ + (∀ i,∃ χ : J → Bool,p i=∑ j,if χ j then e j else 0) ∧ + (∀ a : R,(∀ i,Commute a (p i)) → ∀ j,Commute a (e j)) := by + classical + induction n with + | zero => + refine ⟨Unit,inferInstance,fun _ => 1,fun _ => IsStarProjection.one R,?_,?_,?_,?_⟩ + · intro j k h; exact (h (Subsingleton.elim _ _)).elim + · simp + · intro i; exact Fin.elim0 i + · intro a h j; exact Commute.one_right a + | succ n ih => + obtain ⟨J,hJ,e,he,ho,hs,hr,ha⟩ := ih (fun i => p i.succ) + (fun i => hp i.succ) (fun i j => hc i.succ j.succ) + let : Fintype J := hJ + have hpe (j : J) : Commute (p 0) (e j) := ha (p 0) (fun i => hc 0 i.succ) j + let f : Bool × J → R := fun j => splitPiece (p 0) j.1*e j.2 + refine ⟨Bool×J,inferInstance,f,?_,?_,?_,?_,?_⟩ + · intro j + exact (splitPiece_projection (hp 0) j.1).mul (he j.2) + (splitPiece_commute (hpe j.2).symm j.1).symm + · rintro ⟨b,j⟩ ⟨c,k⟩ h + change (splitPiece (p 0) b*e j)*(splitPiece (p 0) c*e k)=0 + rw [swap_middle _ _ _ _ (splitPiece_commute (hpe j).symm c)] + by_cases hj : j=k + · have hbc : b≠c := fun hb => h (Prod.ext hb hj) + rw [splitPiece_orthogonal (hp 0) hbc,zero_mul] + · rw [ho j k hj,mul_zero] + · change (∑ j : Bool×J,splitPiece (p 0) j.1*e j.2)=1 + rw [Fintype.sum_prod_type] + simp only [←Finset.mul_sum,hs,mul_one] + exact splitPiece_sum _ + · intro i + refine Fin.cases ?_ (fun i => ?_) i + · refine ⟨fun j => j.1,?_⟩ + change p 0=∑ j : Bool×J,if j.1 then splitPiece (p 0) j.1*e j.2 else 0 + rw [Fintype.sum_prod_type,Fintype.sum_bool] + simp only [Bool.false_eq_true,↓reduceIte,Finset.sum_const_zero,add_zero,splitPiece] + rw [←Finset.mul_sum,hs,mul_one] + · obtain ⟨χ,hχ⟩ := hr i + refine ⟨fun j => χ j.2,?_⟩ + change p i.succ=∑ j : Bool×J,if χ j.2 then splitPiece (p 0) j.1*e j.2 else 0 + rw [Fintype.sum_prod_type,Fintype.sum_bool] + simp only [splitPiece,↓reduceIte] + rw [←Finset.sum_add_distrib,hχ] + apply Finset.sum_congr rfl + intro j hj + by_cases hh : χ j=true + · simp only [hh,Bool.false_eq_true,↓reduceIte,←add_mul] + have hz : p 0+(1-p 0)=1 := by abel + rw [hz,one_mul] + · simp [hh] + · intro a h j + exact (splitPiece_commute (h 0) j.1).mul_right + (ha a (fun i => h i.succ) j.2) + +end Kadison.SpectralPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionRounding.lean b/lean/OAI/Analysis/Commutator/ProjectionRounding.lean new file mode 100644 index 0000000000000000000000000000000000000000..bd484d9d700f1ceb5188d09adec4bc9919ab2884 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionRounding.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalTraceProjection +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.NormalGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (hnormal : BoundedWOTContinuous M τ) + +variable (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include hτ hnormal hfaith in +theorem exists_rational_subprojection (hM : DiffuseProjection.HasNoMinimalProjections M) + (e : M) (he : IsStarProjection e) (b : ℕ) (hb : 0 (hp i).isSelfAdjoint.star_eq) + +lemma subprojections_orthogonal {p q e f : A} + (hp : IsStarProjection p) (hq : IsStarProjection q) + (he : IsStarProjection e) (hf : IsStarProjection f) + (hpe : p≤e) (hqf : q≤f) (hef : e*f=0) : p*q=0 := by + have hb := (hp.le_iff_mul_eq_left he).mp hpe + have hc := (hq.le_iff_mul_eq_right hf).mp hqf + calc + p*q=(p*e)*(f*q) := by rw [hb,hc] + _=p*(e*f)*q := by simp only [mul_assoc] + _=0 := by rw [hef,mul_zero,zero_mul] + +lemma projection_sum_le (p q : I → A) (h : ∀ i,p i≤q i) : ∑ i,p i≤∑ i,q i := + Finset.sum_le_sum (fun i _ => h i) + +lemma vector_projection_norm_sq (τ : A →ₚ[ℂ] ℂ) {p : A} (hp : IsStarProjection p) : + ‖TracialGNS.algebraVector τ p‖^2=(τ p).re := by + rw [norm_sq_eq_re_inner (𝕜:=ℂ),TracialGNS.inner_algebraVector, + hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + rfl + +end Kadison.ProjectionSum + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionSchroederBernstein.lean b/lean/OAI/Analysis/Commutator/ProjectionSchroederBernstein.lean new file mode 100644 index 0000000000000000000000000000000000000000..f750d5fe7a4d0333a303394b3bfe428b6e5ac6ff --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionSchroederBernstein.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionEquivalence +import OAI.Analysis.Commutator.ProjectionShift + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem subEquivalent_antisymm (M : VonNeumannAlgebra H) + {e f : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) (hf : IsStarProjection f) + (hef : SubEquivalent M e f) (hfe : SubEquivalent M f e) : Equivalent M e f := by + obtain ⟨u,hu⟩ := hef + obtain ⟨v,hv⟩ := hfe + let a := u.val + let b := v.val + let w := b*a + let p := e-v.final + have hai : star a*a=e := hu + have hbi : star b*b=f := hv + have hea : a*e=a := u.mul_source he + have hfa : f*a=a := u.target_mul hf + have heb : e*b=b := v.target_mul he + have hbf : b*f=b := v.mul_source hf + have hve : v.final*e=v.final := (v.final_projection.le_iff_mul_eq_left he).mp v.target_le + have hp : IsStarProjection p := v.final_projection.sub_of_mul_eq_left he hve + have hw : star w*w=e := by + calc + _=star a*(star b*b)*a := by simp only [w,star_mul]; noncomm_ring + _=e := by rw [hbi,mul_assoc,hfa,hai] + have hwe : w*e=w := by dsimp [w]; rw [mul_assoc,hea] + have hew : e*w=w := by dsimp [w]; rw [←mul_assoc,heb] + have hpw : p*w=0 := by + change (e-v.final)*(b*a)=0 + rw [←mul_assoc,sub_mul,heb] + have hvb : v.final*b=b := v.final_mul + rw [hvb,sub_self,zero_mul] + have hbound : p+w*star w≤e := by + have hh : w*star w≤v.final := by + calc + _=b*u.final*star b := by simp only [w,Link.final,star_mul]; noncomm_ring + _≤b*f*star b := star_right_conjugate_le_conjugate u.target_le b + _=v.final := by rw [hbf]; rfl + exact (add_le_add le_rfl hh).trans_eq (sub_add_cancel e v.final) + obtain ⟨q,hqM,hq,hqe,hfix⟩ := ProjectionShift.exists_fixed_projection M he hp hw hwe hpw hbound + (M.mul_mem v.mem u.mem) (M.sub_mem heM (M.mul_mem v.mem (M.star_mem' v.mem))) + have heq : e*q=q := (hq.le_iff_mul_eq_right he).mp hqe + have hqe' : q*e=q := (hq.le_iff_mul_eq_left he).mp hqe + have hpq : p≤q := by + rw [hfix] + exact le_add_of_nonneg_right (star_right_conjugate_nonneg hq.nonneg w) + have hpq' : p*q=p := (hp.le_iff_mul_eq_left hq).mp hpq + have hqp : q*p=p := (hp.le_iff_mul_eq_right hq).mp hpq + have hqw : q*w=w*q := by + calc + _=(p+w*q*star w)*w := by rw [←hfix] + _=w*q*(star w*w) := by rw [add_mul,hpw,zero_add]; noncomm_ring + _=w*q := by rw [hw,mul_assoc,hqe'] + have hcross : (e-q)*w*q=0 := by + calc + _=w*q-(w*q)*q := by rw [sub_mul,sub_mul,hew,hqw] + _=0 := by rw [mul_assoc w q q,hq.isIdempotentElem.eq,sub_self] + have hcross' : q*star w*(e-q)=0 := by + simpa only [star_mul,star_sub,he.isSelfAdjoint.star_eq,hq.isSelfAdjoint.star_eq,star_zero,mul_assoc] + using congrArg star hcross + have hrem : (e-q)*(b*star b)=e-q := by + have hb : b*star b=e-p := by dsimp [p,Link.final,b]; noncomm_ring + rw [hb] + have hpe : p*e=p := (hp.le_iff_mul_eq_left he).mp (hpq.trans hqe) + have hep : e*p=p := (hp.le_iff_mul_eq_right he).mp (hpq.trans hqe) + calc + _=e*e-e*p-q*e+q*p := by noncomm_ring + _=e-q := by rw [he.isIdempotentElem.eq,hep,hqe',hqp]; abel + let r := a*q+star b*(e-q) + have hri : star r*r=e := by + have hs : star r=q*star a+(e-q)*b := by + dsimp [r] + simp only [star_add,star_mul,star_sub,star_star,hq.isSelfAdjoint.star_eq,he.isSelfAdjoint.star_eq] + calc + _=(q*(star a*a)*q)+(q*star w*(e-q))+((e-q)*w*q)+((e-q)*(b*star b)*(e-q)) := by + rw [hs]; dsimp [r,w]; simp only [star_mul]; noncomm_ring + _=q+(e-q)*(e-q) := by + rw [hai,mul_assoc q e q,heq,hq.isIdempotentElem.eq,hcross',hcross,hrem,add_zero,add_zero] + _=e := by + have hremP := hq.sub_of_mul_eq_left he hqe' + rw [hremP.isIdempotentElem.eq]; abel + have hconj : star b*q*b=a*q*star a := by + calc + _=star b*(p+w*q*star w)*b := by rw [←hfix] + _=star b*e*b-(star b*b)*(star b*b)+(star b*b)*a*q*star a*(star b*b) := by + dsimp [p,w,Link.final,b]; simp only [star_mul]; noncomm_ring + _=a*q*star a := by + have hsa : star a*f=star a := by + simpa only [star_mul,hf.isSelfAdjoint.star_eq] using congrArg star hfa + rw [mul_assoc (star b) e b,heb,hbi,hf.isIdempotentElem.eq,sub_self,zero_add,hfa] + rw [mul_assoc (a*q) (star a) f,hsa] + have hrf : r*star r=f := by + have hqq : q*(e-q)=0 := by rw [mul_sub,hqe',hq.isIdempotentElem.eq,sub_self] + have hqq' : (e-q)*q=0 := by rw [sub_mul,heq,hq.isIdempotentElem.eq,sub_self] + calc + _=a*(q*q)*star a+a*(q*(e-q))*b+star b*((e-q)*q)*star a+star b*((e-q)*(e-q))*b := by + dsimp [r]; simp only [star_add,star_mul,star_sub,star_star,hq.isSelfAdjoint.star_eq,he.isSelfAdjoint.star_eq] + noncomm_ring + _=a*q*star a+star b*(e-q)*b := by + rw [hq.isIdempotentElem.eq,hqq,hqq',mul_zero,zero_mul,mul_zero,zero_mul,add_zero,add_zero, + (hq.sub_of_mul_eq_left he hqe').isIdempotentElem.eq] + _=f := by + rw [mul_sub,sub_mul,hconj,mul_assoc (star b) e b,heb,hbi]; abel + have hre : r*e=r := by + dsimp [r] + have hrq : (e-q)*e=e-q := by rw [sub_mul,he.isIdempotentElem.eq,hqe'] + rw [add_mul,mul_assoc a q e,hqe',mul_assoc (star b) (e-q) e,hrq] + exact ⟨⟨r,M.add_mem (M.mul_mem u.mem hqM) (M.mul_mem (M.star_mem' v.mem) (M.sub_mem heM hqM)), + by rw [mul_assoc,hri,hre],hri.le,hrf.le⟩,hri,hrf⟩ + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionShift.lean b/lean/OAI/Analysis/Commutator/ProjectionShift.lean new file mode 100644 index 0000000000000000000000000000000000000000..dffd40a1b96216592614d2a29faf2d125a6e125b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionShift.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionStrong + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +open Filter + +namespace Kadison.ProjectionShift + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (w p : H →L[ℂ] H) + +def partialSum : ℕ → H →L[ℂ] H + | 0 => 0 + | n+1 => p+w*partialSum n*star w + +variable {w p} {e : H →L[ℂ] H} + +lemma conjugate_projection (he : IsStarProjection e) (hw : star w*w=e) + {q : H →L[ℂ] H} (hq : IsStarProjection q) (hqe : q≤e) : + IsStarProjection (w*q*star w) := by + have heq : e*q=q := (hq.le_iff_mul_eq_right he).mp hqe + constructor + · calc + _=w*q*(star w*w)*q*star w := by noncomm_ring + _=w*q*star w := by rw [hw,mul_assoc (w*q) e q,heq,mul_assoc w q q,hq.isIdempotentElem.eq] + · simp only [star_mul,star_star,hq.isSelfAdjoint.star_eq,IsSelfAdjoint,mul_assoc] + +lemma partial_projection_le (he : IsStarProjection e) (hp : IsStarProjection p) + (hw : star w*w=e) (hwe : w*e=w) (hpw : p*w=0) + (hbound : p+w*star w≤e) (n : ℕ) : + IsStarProjection (partialSum w p n) ∧ partialSum w p n≤e := by + induction n with + | zero => exact ⟨IsStarProjection.zero _,he.nonneg⟩ + | succ n ih => + refine ⟨hp.add (conjugate_projection he hw ih.1 ih.2) ?_,?_⟩ + · rw [←mul_assoc,←mul_assoc,hpw,zero_mul,zero_mul] + · exact (add_le_add le_rfl (star_right_conjugate_le_conjugate ih.2 w)).trans + (by simpa only [hwe] using hbound) + +lemma partial_mono (hp : IsStarProjection p) : Monotone (partialSum w p) := by + apply monotone_nat_of_le_succ + intro n + induction n with + | zero => simpa only [partialSum,mul_zero,zero_mul,add_zero] using hp.nonneg + | succ n ih => exact add_le_add le_rfl (star_right_conjugate_le_conjugate ih w) + +lemma partial_mem (M : VonNeumannAlgebra H) (hw : w∈M) (hp : p∈M) (n : ℕ) : + partialSum w p n∈M := by + induction n with + | zero => exact M.zero_mem + | succ n ih => exact M.add_mem hp (M.mul_mem (M.mul_mem hw ih) (M.star_mem' hw)) + +theorem exists_fixed_projection (M : VonNeumannAlgebra H) + (he : IsStarProjection e) (hp : IsStarProjection p) + (hw : star w*w=e) (hwe : w*e=w) (hpw : p*w=0) + (hbound : p+w*star w≤e) (hwM : w∈M) (hpM : p∈M) : + ∃ q : H →L[ℂ] H,q∈M ∧ IsStarProjection q ∧ q≤e ∧ q=p+w*q*star w := by + obtain ⟨q,hqM,hq,hle,hlim,hleast⟩ := ProjectionChains.exists_strong_sup M (partialSum w p) + (fun n => (partial_projection_le he hp hw hwe hpw hbound n).1) + (partial_mem M hwM hpM) (partial_mono hp) + refine ⟨q,hqM,hq,hleast e he (fun n => (partial_projection_le he hp hw hwe hpw hbound n).2),?_⟩ + ext x + have hs := (hlim x).comp (tendsto_add_atTop_nat 1) + have hr := (tendsto_const_nhds (x:=p x) (f:=atTop (α:=ℕ))).add (w.continuous.tendsto (q (star w x)) |>.comp (hlim (star w x))) + have hh : Tendsto (fun n => partialSum w p (n+1) x) atTop (𝓝 ((p+w*q*star w) x)) := by + simpa only [Function.comp_def,partialSum,add_apply,mul_apply_eq_comp] using hr + exact tendsto_nhds_unique hs hh + +end Kadison.ProjectionShift + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionStrong.lean b/lean/OAI/Analysis/Commutator/ProjectionStrong.lean new file mode 100644 index 0000000000000000000000000000000000000000..c1aa2802a1c5ab20e1001001f25b7bd9c6eda0eb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionStrong.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionChains + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter ContinuousLinearMapWOT + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.ProjectionChains + +variable {H ι : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma projection_norm_sq {P : H →L[ℂ] H} (hP : IsStarProjection P) (x : H) : + ‖P x‖^2=(inner ℂ (P x) x).re := by + rw [norm_sq_eq_re_inner (𝕜:=ℂ)] + have hs := ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mp hP.isSelfAdjoint + have he : inner ℂ (P (P x)) x=inner ℂ (P x) (P x) := hs (P x) x + rw [←he] + have hp := congrArg (fun T : H →L[ℂ] H => T x) hP.isIdempotentElem.eq + change P (P x)=P x at hp + rw [hp] + rfl + +lemma projection_norm_mono {P Q : H →L[ℂ] H} (hP : IsStarProjection P) + (hQ : IsStarProjection Q) (hPQ : P≤Q) (x : H) : ‖P x‖≤‖Q x‖ := by + have h := (hP.le_iff_mul_eq_left hQ).mp hPQ + have hx : P (Q x)=P x := congrArg (fun T : H →L[ℂ] H => T x) h + rw [←hx] + exact (P.le_opNorm (Q x)).trans (by + simpa only [one_mul] using mul_le_mul_of_nonneg_right (hP.norm_le P) (norm_nonneg (Q x))) + +theorem exists_strong_sup (M : VonNeumannAlgebra H) + (P : ℕ → H →L[ℂ] H) (hp : ∀ n,IsStarProjection (P n)) + (hmem : ∀ n,P n∈M) (hmono : Monotone P) : + ∃ W : H →L[ℂ] H,W∈M ∧ IsStarProjection W ∧ (∀ n,P n≤W) ∧ + (∀ x,Tendsto (fun n => P n x) atTop (𝓝 (W x))) ∧ + ∀ Q : H →L[ℂ] H,IsStarProjection Q → (∀ n,P n≤Q) → W≤Q := by + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + have hω : (ω : Filter ℕ)≤atTop := Ultrafilter.of_le atTop + obtain ⟨W,hW,hPW,hlim,hle⟩ := monotone_ultralimit ω hω P hp hmono + have hs (x y : H) : Tendsto (fun n => inner ℂ (P n x) y) (ω : Filter ℕ) + (𝓝 (inner ℂ (W x) y)) := by + have hh := tendsto_iff_forall_inner_apply_tendsto.mp hlim x y + simpa only [RCLike.star_def,inner_conj_symm,ofCLM_apply] using hh.star + refine ⟨W,WeakOperatorLimit.mem_vonNeumann hs M (Filter.Eventually.of_forall hmem),hW,hPW,?_,hle⟩ + intro x + have hdiff (n : ℕ) : IsStarProjection (W-P n) := + (hp n).sub_of_mul_eq_left hW ((hp n).le_iff_mul_eq_left hW |>.mp (hPW n)) + have hnorm : Tendsto (fun n => ‖(W-P n) x‖^2) (ω : Filter ℕ) (𝓝 0) := by + simp_rw [projection_norm_sq (hdiff _)] + simp only [_root_.sub_apply,inner_sub_left,Complex.sub_re] + simpa only [sub_self,Function.comp_apply] using (tendsto_const_nhds (x := (inner ℂ (W x) x).re)).sub (Complex.continuous_re.tendsto _ |>.comp (hs x x)) + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨N,hN⟩ := (hnorm.eventually_lt_const (sq_pos_of_pos hε)).exists + refine ⟨N,?_⟩ + intro n hn + have hle' : W-P n≤W-P N := sub_le_sub_left (hmono hn) W + have hnm := projection_norm_mono (hdiff n) (hdiff N) hle' x + have hlt : ‖(W-P N) x‖<ε := by nlinarith [norm_nonneg ((W-P N) x)] + rw [dist_eq_norm,←norm_neg,neg_sub] + exact hnm.trans_lt hlt + +end Kadison.ProjectionChains + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionSumEquivalence.lean b/lean/OAI/Analysis/Commutator/ProjectionSumEquivalence.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed34b2897966a8d11f28e121cbbeefb32ae152a8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionSumEquivalence.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionEquivalence +import OAI.Analysis.Commutator.ProjectionAddition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace BigOperators + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {ι : Type*} + +lemma orthogonal_sum_projection (e : ι → H →L[ℂ] H) + (he : ∀ i,IsStarProjection (e i)) (hc : ∀ i j,i≠j → e i*e j=0) + (s : Finset ι) : IsStarProjection (∑ i∈s,e i) := by + classical + constructor + · change (∑ i∈s,e i)*(∑ i∈s,e i)=∑ i∈s,e i + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · exact (he i).isIdempotentElem.eq + · intro j hj hne + exact hc i j hne.symm + · change star (∑ i∈s,e i)=∑ i∈s,e i + rw [star_sum] + exact Finset.sum_congr rfl (fun i _ => (he i).isSelfAdjoint.star_eq) + +omit [CompleteSpace H] in +lemma orthogonal_mul_sum_eq_zero (e : ι → H →L[ℂ] H) + (hc : ∀ i j,i≠j → e i*e j=0) (s : Finset ι) {i : ι} (hi : i∉s) : + e i*(∑ j∈s,e j)=0 := by + rw [Finset.mul_sum] + apply Finset.sum_eq_zero + intro j hj + exact hc i j (fun h => hi (h ▸ hj)) + +lemma Equivalent.finset_sum {M : VonNeumannAlgebra H} (e f : ι → H →L[ℂ] H) + (he : ∀ i,IsStarProjection (e i)) (hf : ∀ i,IsStarProjection (f i)) + (hec : ∀ i j,i≠j → e i*e j=0) (hfc : ∀ i j,i≠j → f i*f j=0) + (h : ∀ i,Equivalent M (e i) (f i)) (s : Finset ι) : + Equivalent M (∑ i∈s,e i) (∑ i∈s,f i) := by + classical + induction s using Finset.induction_on with + | empty => simpa only [Finset.sum_empty] using equivalent_refl M.zero_mem (IsStarProjection.zero _) + | @insert i s hi ih => + rw [Finset.sum_insert hi,Finset.sum_insert hi] + exact (h i).orthogonal_add (he i) (hf i) + (orthogonal_sum_projection e he hec s) (orthogonal_sum_projection f hf hfc s) + (orthogonal_mul_sum_eq_zero e hec s hi) (orthogonal_mul_sum_eq_zero f hfc s hi) ih + +lemma SubEquivalent.finset_sum {M : VonNeumannAlgebra H} (e f : ι → H →L[ℂ] H) + (he : ∀ i,IsStarProjection (e i)) (hf : ∀ i,IsStarProjection (f i)) + (hec : ∀ i j,i≠j → e i*e j=0) (hfc : ∀ i j,i≠j → f i*f j=0) + (h : ∀ i,SubEquivalent M (e i) (f i)) (s : Finset ι) : + SubEquivalent M (∑ i∈s,e i) (∑ i∈s,f i) := by + classical + induction s using Finset.induction_on with + | empty => + simpa only [Finset.sum_empty] using + subEquivalent_of_le M.zero_mem (IsStarProjection.zero (H →L[ℂ] H)) (le_refl 0) + | @insert i s hi ih => + rw [Finset.sum_insert hi,Finset.sum_insert hi] + exact (h i).orthogonal_add (he i) (hf i) + (orthogonal_sum_projection e he hec s) (orthogonal_sum_projection f hf hfc s) + (orthogonal_mul_sum_eq_zero e hec s hi) (orthogonal_mul_sum_eq_zero f hfc s hi) ih + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProjectionWeighted.lean b/lean/OAI/Analysis/Commutator/ProjectionWeighted.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb9280eec587fce95c1efe3c316f53cdb2d7ed00 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProjectionWeighted.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionPartition + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators + +namespace Kadison.SpectralPartition + +variable {R : Type*} [Ring R] [StarRing R] [Module ℝ R] + +theorem exists_weighted_partition (n : ℕ) (p : Fin n → R) (c : Fin n → ℝ) + (hp : ∀ i,IsStarProjection (p i)) (hc : ∀ i j,Commute (p i) (p j)) : + ∃ (J : Type) (_ : Fintype J) (e : J → R) (d : J → ℝ), + (∀ j,IsStarProjection (e j)) ∧ + (∀ j k,j≠k → e j*e k=0) ∧ (∑ j,e j)=1 ∧ + (∑ i,c i • p i)=∑ j,d j • e j ∧ + (∀ a : R,(∀ i,Commute a (p i)) → ∀ j,Commute a (e j)) := by + classical + obtain ⟨J,hJ,e,he,ho,hs,hr,ha⟩ := exists_partition n p hp hc + let : Fintype J := hJ + choose χ hχ using hr + refine ⟨J,hJ,e,(fun j => ∑ i,if χ i j then c i else 0),he,ho,hs,?_,ha⟩ + calc + (∑ i,c i • p i)=∑ i,∑ j,if χ i j then c i • e j else 0 := by + apply Finset.sum_congr rfl + intro i hi + rw [hχ i,Finset.smul_sum] + apply Finset.sum_congr rfl + intro j hj + by_cases hh : χ i j=true <;> simp [hh] + _=∑ j,∑ i,if χ i j then c i • e j else 0 := Finset.sum_comm + _=∑ j,(∑ i,if χ i j then c i else 0) • e j := by + apply Finset.sum_congr rfl + intro j hj + rw [Finset.sum_smul] + apply Finset.sum_congr rfl + intro i hi + by_cases hh : χ i j=true <;> simp [hh] + +end Kadison.SpectralPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProperIsometryReplicas.lean b/lean/OAI/Analysis/Commutator/ProperIsometryReplicas.lean new file mode 100644 index 0000000000000000000000000000000000000000..6a94189086d2c5435febcf837089b653c87c6017 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProperIsometryReplicas.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteCancellation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure Replicas (M : VonNeumannAlgebra H) (r : H →L[ℂ] H) where + a : ℕ → H →L[ℂ] H + mem : ∀ n,a n∈M + initial : ∀ n,star (a n)*a n=r + cross : ∀ n m,n≠m → star (a n)*a m=0 + source : ∀ n,a n*r=a n + +theorem nonfinite_replicas (M : VonNeumannAlgebra H) (hfin : ¬IsFiniteAlgebra M) : + ∃ r,r∈M ∧ IsStarProjection r ∧ r≠0 ∧ Nonempty (Replicas M r) := by + classical + simp only [IsFiniteAlgebra,not_forall] at hfin + obtain ⟨v,hvM,hvi,hvn⟩ := hfin + have hq : IsStarProjection (v*star v) := by + constructor + · change (v*star v)*(v*star v)=v*star v + calc + _=v*(star v*v)*star v := by noncomm_ring + _=v*star v := by rw [hvi,mul_one] + · exact IsSelfAdjoint.mul_star_self v + let r : H →L[ℂ] H := 1-v*star v + have hr : IsStarProjection r := hq.one_sub + have hrn : r≠0 := by + intro h + exact hvn (sub_eq_zero.mp h).symm + have hsvr : star v*r=0 := by + change star v*(1-v*star v)=0 + rw [mul_sub,mul_one,←mul_assoc,hvi,one_mul,sub_self] + have hrvs : r*v=0 := by + simpa only [star_mul,hr.isSelfAdjoint.star_eq,star_star,star_zero] using congrArg star hsvr + have hwords (n m : ℕ) : star (v^n*r)*(v^m*r)=if n=m then r else 0 := by + induction n generalizing m with + | zero => + cases m with + | zero => simpa [hr.isSelfAdjoint.star_eq] using hr.isIdempotentElem.eq + | succ m => + simp only [pow_zero,one_mul,pow_succ',Nat.zero_ne_add_one,ite_false,hr.isSelfAdjoint.star_eq] + rw [show r*(v*v^m*r)=(r*v)*(v^m*r) by noncomm_ring,hrvs,zero_mul] + | succ n ih => + cases m with + | zero => + simp only [pow_zero,one_mul,pow_succ',Nat.add_one_ne_zero,ite_false,star_mul] + rw [show star r*(star (v^n)*star v)*r=star r*star (v^n)*(star v*r) by noncomm_ring,hsvr,mul_zero] + | succ m => + rw [pow_succ',pow_succ',star_mul,star_mul] + rw [show star r*(star (v^n)*star v)*(v*v^m*r)=star (v^n*r)*(star v*v)*(v^m*r) by + rw [star_mul]; noncomm_ring,hvi,mul_one,ih] + simp + refine ⟨r,M.sub_mem M.one_mem (M.mul_mem hvM (M.star_mem' hvM)),hr,hrn, + ⟨⟨fun n => v^n*r,?_,?_,?_,?_⟩⟩⟩ + · intro n + exact M.mul_mem (M.pow_mem hvM n) (M.sub_mem M.one_mem (M.mul_mem hvM (M.star_mem' hvM))) + · intro n + simpa using hwords n n + · intro n m hnm + simpa only [ite_eq_right hnm] using hwords n m + · intro n + rw [mul_assoc,hr.isIdempotentElem.eq] + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProperlyInfinite.lean b/lean/OAI/Analysis/Commutator/ProperlyInfinite.lean new file mode 100644 index 0000000000000000000000000000000000000000..d091e1351b400d5860eb100d2285d112e201d2a2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProperlyInfinite.lean @@ -0,0 +1,152 @@ +import Mathlib +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.RectangularColumn +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma commutatorSeminorm_star_le (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + commutatorSeminorm P (star Y) ≤ commutatorSeminorm P Y := by + apply csSup_le + · exact ⟨0,0,zero_mem P,by simp,by simp⟩ + rintro r ⟨a,ha,hn,rfl⟩ + have hb := commutator_bound_unitball P Y (star_mem ha) (by simpa using hn) + calc + ‖star Y*a-a*star Y‖ = ‖star (star Y*a-a*star Y)‖ := (norm_star _).symm + _ = ‖star a*Y-Y*star a‖ := by rw [star_sub,star_mul,star_mul,star_star] + _ = ‖Y*star a-star a*Y‖ := norm_sub_rev _ _ + _ ≤ _ := hb + +@[simp] lemma commutatorSeminorm_star (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) : + commutatorSeminorm P (star Y)=commutatorSeminorm P Y := + le_antisymm (commutatorSeminorm_star_le P Y) + (by simpa using commutatorSeminorm_star_le P (star Y)) + +def operatorColumn (h : ℕ) (a : Fin h → (K →L[ℂ] K)) : + K →L[ℂ] PiLp 2 (fun _ : Fin h => K) := + (PiLp.continuousLinearEquiv 2 ℂ (fun _ : Fin h => K)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi a) + +def operatorRow (h : ℕ) (a : Fin h → (K →L[ℂ] K)) : + PiLp 2 (fun _ : Fin h => K) →L[ℂ] K := + ∑ i, (a i).comp (PiLp.proj 2 (fun _ : Fin h => K) i) + +omit [CompleteSpace K] in +@[simp] lemma operatorColumn_apply (h : ℕ) (a : Fin h → (K →L[ℂ] K)) (x : K) (i : Fin h) : + operatorColumn h a x i=a i x := by simp [operatorColumn] + +omit [CompleteSpace K] in +@[simp] lemma operatorRow_apply (h : ℕ) (a : Fin h → (K →L[ℂ] K)) + (x : PiLp 2 (fun _ : Fin h => K)) : operatorRow h a x=∑ i,a i (x i) := by + simp [operatorRow] + +lemma operatorRow_adjoint (h : ℕ) (a : Fin h → (K →L[ℂ] K)) : + (operatorRow h a).adjoint=operatorColumn h (fun i => (a i).adjoint) := by + symm + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [PiLp.inner_apply,operatorColumn_apply,operatorRow_apply,inner_sum, + ContinuousLinearMap.adjoint_inner_left] + +lemma commutator_column_bound (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) + (h : ℕ) (a : Fin h → P) (ha : CyclicColumns.columnNorm a≤1) : + ‖operatorColumn h (fun i => Y*(a i : K →L[ℂ] K)-(a i : K →L[ℂ] K)*Y)‖ ≤ + 4*commutatorSeminorm P Y := by + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity [commutatorSeminorm_nonneg P Y]) + intro ξ + let : StarOrderedRing P.toStarSubalgebra := VonNeumannCStar.starOrderedRing P + have hb := RectangularColumn.column_bound P.toStarSubalgebra.subtype P.toStarSubalgebra.subtype + (innerDerivation P Y) (innerDerivation_mul P Y) a ξ + have he : operatorColumn h (fun i => Y*(a i : K →L[ℂ] K)-(a i : K →L[ℂ] K)*Y) ξ = + WithLp.toLp 2 (fun i => innerDerivation P Y (a i) ξ) := by ext i; rfl + rw [he] + refine hb.trans ?_ + have hn := innerDerivation_norm_le P Y + have hp := CyclicColumns.columnNorm_nonneg a + have hm := (mul_le_mul hn ha hp (commutatorSeminorm_nonneg P Y)).trans_eq (mul_one _) + calc + (4*‖innerDerivation P Y‖)*CyclicColumns.columnNorm a*‖ξ‖ = + 4*(‖innerDerivation P Y‖*CyclicColumns.columnNorm a)*‖ξ‖ := by ring + _ ≤ _ := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hm (by norm_num)) (norm_nonneg ξ) + +section Isometries + +variable (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (hv : ∀ i j, star (v i)*v j=if i=j then 1 else 0) + +include hv in +lemma isometry_range_sum_projection : IsStarProjection (∑ i,v i*star (v i)) := by + refine ⟨?_,?_⟩ + · change (∑ i,v i*star (v i))*(∑ i,v i*star (v i))=∑ i,v i*star (v i) + have he (i j : Fin h) : v i*star (v i)*(v j*star (v j))= + if i=j then v i*star (v i) else 0 := by + rw [show v i*star (v i)*(v j*star (v j))=v i*(star (v i)*v j)*star (v j) by noncomm_ring,hv] + split_ifs with he + · subst j; simp + · simp + simp only [Finset.sum_mul,Finset.mul_sum,he] + simp + · change star (∑ i,v i*star (v i))=∑ i,v i*star (v i) + simp only [star_sum,star_mul,star_star] + +include hv in +lemma isometry_star_columnNorm_le : CyclicColumns.columnNorm (fun i => star (v i))≤1 := by + have hn := IsStarProjection.norm_le _ (isometry_range_sum_projection P h v hv) + have he := CyclicColumns.columnNorm_sq (fun i => star (v i)) + simp only [star_star] at he + nlinarith [CyclicColumns.columnNorm_nonneg (fun i => star (v i))] + +include hv in +lemma isometry_row_adjoint_comp : + (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint.comp + (operatorRow h (fun i => (v i : K →L[ℂ] K)))=ContinuousLinearMap.id ℂ _ := by + rw [operatorRow_adjoint] + ext x i + change (operatorColumn h (fun j => (v j : K →L[ℂ] K).adjoint) + (operatorRow h (fun j => (v j : K →L[ℂ] K)) x)) i=x i + rw [operatorColumn_apply,operatorRow_apply,map_sum] + have he (j : Fin h) : (v i : K →L[ℂ] K).adjoint ((v j : K →L[ℂ] K) (x j))= + if i=j then x j else 0 := by + by_cases hij : i=j + · subst j + have hh : (v i : K →L[ℂ] K).adjoint.comp (v i : K →L[ℂ] K)=ContinuousLinearMap.id ℂ K := + congrArg (fun a : P => (a:K →L[ℂ] K)) (by simpa using hv i i) + simpa using congrArg (fun T : K →L[ℂ] K => T (x i)) hh + · have hh : (v i : K →L[ℂ] K).adjoint.comp (v j : K →L[ℂ] K)=0 := + congrArg (fun a : P => (a:K →L[ℂ] K)) (by simpa only [ite_eq_right hij] using hv i j) + simpa [hij] using congrArg (fun T : K →L[ℂ] K => T (x j)) hh + simp only [he] + simp + +include hv in +lemma isometry_row_norm_le : ‖operatorRow h (fun i => (v i : K →L[ℂ] K))‖≤1 := by + have he := (ContinuousLinearMap.norm_map_iff_adjoint_comp_self _).mpr + (isometry_row_adjoint_comp P h v hv) + apply ContinuousLinearMap.opNorm_le_bound _ (by norm_num) + intro x + rw [he x,one_mul] + +end Isometries + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProperlyInfiniteBound.lean b/lean/OAI/Analysis/Commutator/ProperlyInfiniteBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..74163f92ca5b0486f0edc79d42e111ff4e367f04 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProperlyInfiniteBound.lean @@ -0,0 +1,155 @@ +import Mathlib +import OAI.Analysis.Commutator.ProperlyInfinite + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +open ContinuousLinearMap + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma isometry_column_error_eq (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (Y : K →L[ℂ] K) : + (diagonalAmplification h Y).comp (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint- + (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint.comp Y = + operatorColumn h (fun i => Y*(star (v i) : K →L[ℂ] K)-(star (v i) : K →L[ℂ] K)*Y) := by + rw [operatorRow_adjoint] + ext x i + change (diagonalAmplification h Y + (operatorColumn h (fun i => (v i : K →L[ℂ] K).adjoint) x)) i- + (operatorColumn h (fun i => (v i : K →L[ℂ] K).adjoint) (Y x)) i = _ + rw [diagonalAmplification_apply,operatorColumn_apply,operatorColumn_apply] + rfl + +lemma isometry_column_error_bound (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (hv : ∀ i j, star (v i)*v j=if i=j then 1 else 0) (Y : K →L[ℂ] K) : + ‖(diagonalAmplification h Y).comp (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint- + (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint.comp Y‖ ≤ + 4*commutatorSeminorm P Y := by + rw [isometry_column_error_eq] + exact commutator_column_bound P Y h (fun i => star (v i)) (isometry_star_columnNorm_le P h v hv) + +lemma isometry_row_error_bound (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (hv : ∀ i j, star (v i)*v j=if i=j then 1 else 0) (Y : K →L[ℂ] K) : + ‖Y.comp (operatorRow h (fun i => (v i : K →L[ℂ] K)))- + (operatorRow h (fun i => (v i : K →L[ℂ] K))).comp (diagonalAmplification h Y)‖ ≤ + 4*commutatorSeminorm P Y := by + rw [←adjoint.norm_map] + simp only [map_sub,adjoint_comp,diagonalAmplification_adjoint] + rw [norm_sub_rev] + have hb := isometry_column_error_bound P h v hv Y.adjoint + simpa only [←star_eq_adjoint,commutatorSeminorm_star] using hb + +lemma row_matrix_row_adjoint (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) : + ((operatorRow h (fun i => (v i : K →L[ℂ] K))).comp (matrixOperator h X)).comp + (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint = + ∑ i, ∑ j, (v i : K →L[ℂ] K)*X i j*star (v j : K →L[ℂ] K) := by + rw [operatorRow_adjoint] + ext ξ + simp only [comp_apply,operatorRow_apply,matrixOperator_apply,operatorColumn_apply,map_sum, + sum_apply] + rfl + +lemma row_matrix_row_adjoint_mem (P : VonNeumannAlgebra K) (h : ℕ) (v : Fin h → P) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) (hX : ∀ i j,X i j∈P) : + ((operatorRow h (fun i => (v i : K →L[ℂ] K))).comp (matrixOperator h X)).comp + (operatorRow h (fun i => (v i : K →L[ℂ] K))).adjoint ∈P := by + rw [row_matrix_row_adjoint] + exact sum_mem (fun i _ => sum_mem (fun j _ => mul_mem (mul_mem (v i).property (hX i j)) + (star_mem (v j).property))) + +omit [CompleteSpace K] in +lemma isometry_commutator_identity + {L : Type*} [NormedAddCommGroup L] [NormedSpace ℂ L] + (V : L →L[ℂ] K) (U : K →L[ℂ] L) (hUV : U.comp V=ContinuousLinearMap.id ℂ L) + (Y : K →L[ℂ] K) (D X : L →L[ℂ] L) : + D*X-X*D = + (U.comp (Y*((V.comp X).comp U)-((V.comp X).comp U)*Y)).comp V- + ((U.comp (Y.comp V-V.comp D)).comp X)- + X.comp ((D.comp U-U.comp Y).comp V) := by + have hc (Z : L →L[ℂ] L) : U.comp (V.comp Z)=Z := by + rw [←comp_assoc,hUV,id_comp] + simp only [mul_def,comp_sub,sub_comp,comp_assoc,hUV,comp_id,hc] + abel + +lemma norm_comp_contractions {E F G : Type*} + [NormedAddCommGroup E] [NormedSpace ℂ E] [NormedAddCommGroup F] [NormedSpace ℂ F] + [NormedAddCommGroup G] [NormedSpace ℂ G] + (A : F →L[ℂ] G) (B : E →L[ℂ] F) (hA : ‖A‖≤1) : ‖A.comp B‖≤‖B‖ := by + exact (opNorm_comp_le A B).trans (by nlinarith [norm_nonneg B]) + +lemma norm_contractive_sandwich {E F G J : Type*} + [NormedAddCommGroup E] [NormedSpace ℂ E] [NormedAddCommGroup F] [NormedSpace ℂ F] + [NormedAddCommGroup G] [NormedSpace ℂ G] [NormedAddCommGroup J] [NormedSpace ℂ J] + (U : G →L[ℂ] J) (A : F →L[ℂ] G) (V : E →L[ℂ] F) (hU : ‖U‖≤1) (hV : ‖V‖≤1) : + ‖(U.comp A).comp V‖≤‖A‖ := by + calc + _ ≤ ‖U.comp A‖*‖V‖ := opNorm_comp_le _ _ + _ ≤ ‖A‖*1 := mul_le_mul (norm_comp_contractions U A hU) hV (norm_nonneg V) (norm_nonneg A) + _ = _ := mul_one _ + +omit [CompleteSpace K] in +lemma isometry_commutator_norm_bound + {L : Type*} [NormedAddCommGroup L] [NormedSpace ℂ L] + (V : L →L[ℂ] K) (U : K →L[ℂ] L) (hUV : U.comp V=ContinuousLinearMap.id ℂ L) + (hV : ‖V‖≤1) (hU : ‖U‖≤1) + (Y : K →L[ℂ] K) (D A : L →L[ℂ] L) {δ : ℝ} (hδ : 0≤δ) + (hBF : ‖Y*((V.comp A).comp U)-((V.comp A).comp U)*Y‖≤δ*‖A‖) + (hR : ‖Y.comp V-V.comp D‖≤4*δ) (hC : ‖D.comp U-U.comp Y‖≤4*δ) : + ‖D*A-A*D‖≤9*δ*‖A‖ := by + let F := (V.comp A).comp U + let R := Y.comp V-V.comp D + let C := D.comp U-U.comp Y + have hleft : ‖(U.comp (Y*F-F*Y)).comp V‖≤δ*‖A‖ := + (norm_contractive_sandwich U _ V hU hV).trans hBF + have hr : ‖(U.comp R).comp A‖≤(4*δ)*‖A‖ := by + exact (opNorm_comp_le _ _).trans (mul_le_mul_of_nonneg_right + ((norm_comp_contractions U R hU).trans hR) (norm_nonneg A)) + have hc : ‖A.comp (C.comp V)‖≤(4*δ)*‖A‖ := by + have hcv : ‖C.comp V‖≤4*δ := + (opNorm_comp_le _ _).trans ((mul_le_mul hC hV (norm_nonneg V) (by positivity)).trans_eq (mul_one _)) + exact (opNorm_comp_le _ _).trans (by nlinarith [norm_nonneg A]) + rw [isometry_commutator_identity V U hUV Y D A] + calc + _ ≤ ‖(U.comp (Y*F-F*Y)).comp V-(U.comp R).comp A‖+‖A.comp (C.comp V)‖ := norm_sub_le _ _ + _ ≤ (‖(U.comp (Y*F-F*Y)).comp V‖+‖(U.comp R).comp A‖)+‖A.comp (C.comp V)‖ := + add_le_add (norm_sub_le _ _) le_rfl + _ ≤ _ := by linarith + +theorem uniform_commutator_of_isometries + (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) (h : ℕ) (v : Fin h → P) + (hv : ∀ i j, star (v i)*v j=if i=j then 1 else 0) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ ≤ + 9*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + let V := operatorRow h (fun i => (v i : K →L[ℂ] K)) + have hV : ‖V‖≤1 := isometry_row_norm_le P h v hv + have hU : ‖V.adjoint‖≤1 := by simpa only [adjoint.norm_map] using hV + apply isometry_commutator_norm_bound V V.adjoint (isometry_row_adjoint_comp P h v hv) hV hU + Y (diagonalAmplification h Y) (matrixOperator h X) (commutatorSeminorm_nonneg P Y) + · exact (commutator_bound P Y (row_matrix_row_adjoint_mem P h v X hX)).trans + (mul_le_mul_of_nonneg_left (norm_contractive_sandwich V (matrixOperator h X) V.adjoint hV hU) + (commutatorSeminorm_nonneg P Y)) + · exact isometry_row_error_bound P h v hv Y + · exact isometry_column_error_bound P h v hv Y + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ProperlyInfiniteMain.lean b/lean/OAI/Analysis/Commutator/ProperlyInfiniteMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..54302bf955430269e1b377a2796424f7d8b34865 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ProperlyInfiniteMain.lean @@ -0,0 +1,38 @@ +import Mathlib +import OAI.Analysis.Commutator.ProperlyInfiniteBound +import OAI.Analysis.Commutator.TwoIsometries + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +universe u + +namespace Kadison + +variable {K : Type u} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem uniform_commutator_of_two_isometries + (P : VonNeumannAlgebra K) (s t : P) + (hs : star s*s=1) (ht : star t*t=1) (hst : star s*t=0) + (Y : K →L[ℂ] K) (h : ℕ) + (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ ≤ + 9*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + obtain ⟨v,hv⟩ := two_isometries_finite_family s t hs ht hst h + exact uniform_commutator_of_isometries P Y h v hv X hX + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RankOneFactor.lean b/lean/OAI/Analysis/Commutator/RankOneFactor.lean new file mode 100644 index 0000000000000000000000000000000000000000..d3d62bedc86b0a93d87c2fd14268478b851bacf1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RankOneFactor.lean @@ -0,0 +1,73 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +namespace Kadison + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma scalar_of_commutes_rankOne (Z : H →L[ℂ] H) + (hz : ∀ x y : H,Commute Z (InnerProductSpace.rankOne ℂ x y)) : + ∃ c : ℂ,Z=c • (1:H →L[ℂ] H) := by + rcases subsingleton_or_nontrivial H with hH|hH + · let := hH + exact ⟨0,Subsingleton.elim _ _⟩ + · let := hH + obtain ⟨e,he⟩ := exists_ne (0:H) + have hee : inner ℂ e e≠0 := inner_self_ne_zero.mpr he + refine ⟨((inner ℂ e e)⁻¹*inner ℂ e (Z e)),?_⟩ + apply ContinuousLinearMap.ext + intro x + have hc := congrArg (fun A : H →L[ℂ] H => A e) (hz x e).eq + change Z (inner ℂ e e • x)=inner ℂ e (Z e) • x at hc + rw [map_smul] at hc + have hc' := congrArg (fun y : H => (inner ℂ e e)⁻¹ • y) hc + simpa only [smul_smul,inv_mul_cancel₀ hee,one_smul, + smul_apply,one_apply_eq_self] using hc' + +omit [CompleteSpace H] in +lemma scalar_of_dense_rankOne_tests (v : ℕ → H) (hv : DenseRange v) + (Z : H →L[ℂ] H) + (hz : ∀ i j,Commute Z (InnerProductSpace.rankOne ℂ (v i) (v j))) : + ∃ c : ℂ,Z=c • (1:H →L[ℂ] H) := by + have ht (i j : ℕ) (e : H) : + inner ℂ (v j) e • Z (v i)=inner ℂ (v j) (Z e) • v i := by + have h := congrArg (fun A : H →L[ℂ] H => A e) (hz i j).eq + change Z (inner ℂ (v j) e • v i)=inner ℂ (v j) (Z e) • v i at h + simpa only [map_smul] using h + have hy (i : ℕ) (y e : H) : + inner ℂ y e • Z (v i)=inner ℂ y (Z e) • v i := by + exact hv.induction_on y + (isClosed_eq ((continuous_id.inner continuous_const).smul continuous_const) + ((continuous_id.inner continuous_const).smul continuous_const)) + (fun j => ht i j e) + have hx (x y e : H) : inner ℂ y e • Z x=inner ℂ y (Z e) • x := by + exact hv.induction_on x + (isClosed_eq (continuous_const.smul Z.continuous) + (continuous_const.smul continuous_id)) (fun i => hy i y e) + apply scalar_of_commutes_rankOne Z + intro x y + change Z*InnerProductSpace.rankOne ℂ x y=InnerProductSpace.rankOne ℂ x y*Z + apply ContinuousLinearMap.ext + intro e + change Z (inner ℂ y e • x)=inner ℂ y (Z e) • x + rw [map_smul] + exact hx x y e + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RationalDense.lean b/lean/OAI/Analysis/Commutator/RationalDense.lean new file mode 100644 index 0000000000000000000000000000000000000000..7bf69de09fcde26cf7e026be50b9d34417ef53e4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RationalDense.lean @@ -0,0 +1,90 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology + +namespace Kadison.RationalDense + +variable (H : Type*) [NormedAddCommGroup H] [NormedSpace ℂ H] + [TopologicalSpace.SeparableSpace H] + +local instance : NormedSpace ℚ H := NormedSpace.restrictScalars ℚ ℂ H + +def subspace : Submodule ℚ H := Submodule.span ℚ (Set.range (TopologicalSpace.denseSeq H)) + +instance : Countable (subspace H) := by unfold subspace; infer_instance + +lemma dense : DenseRange ((subspace H).subtypeL : subspace H →L[ℚ] H) := by + apply denseRange_subtype_val.mpr + exact Dense.mono (Submodule.subset_span) (TopologicalSpace.denseRange_denseSeq H) + +lemma exists_seq (x : H) : ∃ f : ℕ → subspace H,Tendsto (fun n => (f n:H)) atTop (𝓝 x) := by + obtain ⟨f,hf,hl⟩ := mem_closure_iff_seq_limit.mp ((dense H) x) + choose g hg using hf + have he : (fun n => (g n:H))=f := funext hg + exact ⟨g,by rw [he]; exact hl⟩ + +end Kadison.RationalDense + +namespace Kadison.ComplexLinearization + +variable {H : Type*} [NormedAddCommGroup H] [NormedSpace ℂ H] + +def part (U : H →L[ℝ] H) : H →L[ℝ] H := + (1/2:ℝ) • (U-(Complex.I • U).comp ((Complex.I • ContinuousLinearMap.id ℂ H).restrictScalars ℝ)) + +lemma part_apply (U : H →L[ℝ] H) (x : H) : + part U x=(1/2:ℝ) • (U x-Complex.I • U (Complex.I • x)) := rfl + +lemma part_map_I (U : H →L[ℝ] H) (x : H) : part U (Complex.I • x)=Complex.I • part U x := by + simp only [part_apply,smul_sub,smul_comm (1/2:ℝ) Complex.I,smul_smul,Complex.I_mul_I, + neg_one_smul,map_neg,smul_neg,sub_neg_eq_add] + rw [smul_add,smul_comm (1/2:ℝ) Complex.I] + abel + +lemma complex_smul (V : H →L[ℝ] H) (hI : ∀ x,V (Complex.I • x)=Complex.I • V x) + (z : ℂ) (x : H) : V (z • x)=z • V x := by + rw [←Complex.re_add_im z,add_smul,map_add,add_smul,mul_smul,mul_smul] + have hr (r : ℝ) (y : H) : V ((r:ℂ) • y)=(r:ℂ) • V y := by + change V (r • y)=r • V y + exact map_smul V r y + rw [hr,hr,hI] + +def operator (U : H →L[ℝ] H) : H →L[ℂ] H where + toFun := part U + map_add' := map_add _ + map_smul' := complex_smul (part U) (part_map_I U) + cont := (part U).continuous + +lemma operator_apply (U : H →L[ℝ] H) (x : H) : + operator U x=(1/2:ℝ) • (U x-Complex.I • U (Complex.I • x)) := rfl + +lemma norm_le (U : H →L[ℝ] H) : ‖operator U‖≤‖U‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg U) + intro x + rw [operator_apply,norm_smul,Real.norm_eq_abs,abs_of_nonneg (by norm_num : (0:ℝ)≤1/2)] + have hi : ‖Complex.I • x‖=‖x‖ := by simp only [norm_smul,Complex.norm_I,one_mul] + have h := norm_sub_le (U x) (Complex.I • U (Complex.I • x)) + simp only [norm_smul,Complex.norm_I,one_mul] at h + have h1 := U.le_opNorm x + have h2 := U.le_opNorm (Complex.I • x) + rw [hi] at h2 + linarith + +end Kadison.ComplexLinearization + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RationalStarExtension.lean b/lean/OAI/Analysis/Commutator/RationalStarExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..e13674c0eba950a00b7fe5968c76a9d39e5a4152 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RationalStarExtension.lean @@ -0,0 +1,120 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +namespace Kadison.RationalStarExtension + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +local instance : NormedAlgebra ℚ A := NormedAlgebra.restrictScalars ℚ ℂ A + +local instance : NormedAlgebra ℚ B := NormedAlgebra.restrictScalars ℚ ℂ B + +local instance : StarModule ℚ A where + star_smul r a := by + change star ((r:ℂ) • a)=((star r:ℚ):ℂ) • star a + simp + +local instance : StarModule ℚ B where + star_smul r b := by + change star ((r:ℂ) • b)=((star r:ℚ):ℂ) • star b + simp + +variable (S : StarSubalgebra ℚ A) + (hd : DenseRange (fun a : S => (a:A))) + (φ : S →⋆ₐ[ℚ] B) (hb : ∀ a : S,‖φ a‖≤‖(a:A)‖) + +def raw : S →L[ℚ] B := φ.toAlgHom.toLinearMap.mkContinuous 1 (by + intro a + simpa using hb a) + +def lift : A →L[ℚ] B := (raw S φ hb).extend S.toSubalgebra.toSubmodule.subtypeL + +include hd in +lemma lift_subtype (a : S) : lift S φ hb (a:A)=φ a := + ContinuousLinearMap.extend_eq _ hd isUniformEmbedding_subtype_val.isUniformInducing a + +include hd in +lemma lift_norm (a : A) : ‖lift S φ hb a‖≤‖a‖ := by + refine hd.induction_on (p:=fun x => ‖lift S φ hb x‖≤‖x‖) a + (isClosed_le (lift S φ hb).continuous.norm continuous_norm) ?_ + intro b + rw [lift_subtype S hd φ hb] + exact hb b + +def realLift : A →L[ℝ] B := + (lift S φ hb).toLinearMap.toAddMonoidHom.toRealLinearMap (lift S φ hb).continuous + +include hd hb in +theorem exists_complex_extension (hI : Complex.I • (1:A)∈S) + (hφI : φ ⟨Complex.I • (1:A),hI⟩=Complex.I • (1:B)) : + ∃ Φ : A →⋆ₐ[ℂ] B,(∀ a : S,Φ (a:A)=φ a) ∧ (∀ a : A,‖Φ a‖≤‖a‖) := by + let L := realLift S φ hb + have hsub (a : S) : L (a:A)=φ a := lift_subtype S hd φ hb a + have hLI (a : A) : L (Complex.I • a)=Complex.I • L a := by + refine hd.induction_on (p:=fun x => L (Complex.I • x)=Complex.I • L x) a (isClosed_eq + (L.continuous.comp (continuous_const.smul continuous_id)) + (continuous_const.smul L.continuous)) ?_ + intro a + let i : S := ⟨Complex.I • (1:A),hI⟩ + have he : Complex.I • (a:A)=((i*a:S):A) := by simp [i] + rw [he,hsub,map_mul,hsub] + change φ ⟨Complex.I • (1:A),hI⟩*φ a=Complex.I • φ a + rw [hφI] + simp + have hsmul (z : ℂ) (a : A) : L (z • a)=z • L a := by + rw [←Complex.re_add_im z,add_smul,map_add,add_smul,mul_smul,mul_smul] + have hr (r : ℝ) (x : A) : L ((r:ℂ) • x)=(r:ℂ) • L x := by + change L (r • x)=r • L x + exact map_smul L r x + rw [hr,hr,hLI] + have hmul (a b : A) : L (a*b)=L a*L b := by + refine hd.induction_on (p:=fun x => L (x*b)=L x*L b) a + (isClosed_eq (L.continuous.comp (continuous_id.mul continuous_const)) + (L.continuous.mul continuous_const)) ?_ + intro a + refine hd.induction_on (p:=fun x => L ((a:A)*x)=L (a:A)*L x) b + (isClosed_eq (L.continuous.comp (continuous_const.mul continuous_id)) + (continuous_const.mul L.continuous)) ?_ + intro b + change L ((a*b:S):A)=L (a:A)*L (b:A) + rw [hsub,hsub,hsub,map_mul] + have hstar (a : A) : L (star a)=star (L a) := by + refine hd.induction_on (p:=fun x => L (star x)=star (L x)) a + (isClosed_eq (L.continuous.comp continuous_star) L.continuous.star) ?_ + intro a + change L ((star a:S):A)=star (L (a:A)) + rw [hsub,hsub,map_star] + have hone : L (1:A)=1 := by + change L ((1:S):A)=1 + rw [hsub,map_one] + let Φ : A →⋆ₐ[ℂ] B := + { toAlgHom := + { toFun := L + map_one' := hone + map_mul' := hmul + map_zero' := map_zero L + map_add' := map_add L + commutes' := by + intro z + change L (algebraMap ℂ A z)=algebraMap ℂ B z + rw [Algebra.algebraMap_eq_smul_one,Algebra.algebraMap_eq_smul_one,hsmul,hone] } + map_star' := hstar } + exact ⟨Φ,hsub,lift_norm S hd φ hb⟩ + +end Kadison.RationalStarExtension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RectangularColumn.lean b/lean/OAI/Analysis/Commutator/RectangularColumn.lean new file mode 100644 index 0000000000000000000000000000000000000000..7758cdc319211f115a13a5f28075ccaa3ca790e8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RectangularColumn.lean @@ -0,0 +1,184 @@ +import Mathlib +import OAI.Analysis.Commutator.ColumnEstimate +import OAI.Analysis.Commutator.CyclicMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison.RectangularColumn + +variable {A K F : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +local instance : NormedAddCommGroup (K →L[ℂ] F) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] F) := ContinuousLinearMap.toNormedSpace + +abbrev SumHilbert (F K : Type*) := WithLp 2 (F × K) + +def triangularMap (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) (a : A) : + SumHilbert F K →L[ℂ] SumHilbert F K := + let e := WithLp.prodContinuousLinearEquiv 2 ℂ F K + e.symm.toContinuousLinearMap.comp + (((lam a).comp (ContinuousLinearMap.fst ℂ F K)+ + (D a).comp (ContinuousLinearMap.snd ℂ F K)).prod + ((σ a).comp (ContinuousLinearMap.snd ℂ F K)) |>.comp e.toContinuousLinearMap) + +@[simp] lemma triangularMap_apply (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (a : A) (x : SumHilbert F K) : + triangularMap σ lam D a x=WithLp.toLp 2 (lam a x.fst+D a x.snd,σ a x.snd) := rfl + +lemma derivation_one (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) : D 1=0 := by + have h := hD 1 1 + have he : D 1=D 1+D 1 := by + simpa only [one_mul,map_one,ContinuousLinearMap.one_def,ContinuousLinearMap.comp_id, + ContinuousLinearMap.id_comp] using h + exact (add_eq_left.mp he.symm) + +def triangularHom (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) : + A →ₐ[ℂ] (SumHilbert F K →L[ℂ] SumHilbert F K) where + toFun := triangularMap σ lam D + map_one' := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + apply Prod.ext <;> simp [derivation_one σ lam D hD] + map_mul' a b := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + apply Prod.ext + · simp [hD,mul_apply_eq_comp,map_add] + abel + · simp [mul_apply_eq_comp] + map_zero' := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + apply Prod.ext <;> simp + map_add' a b := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + apply Prod.ext <;> simp [add_add_add_comm] + commutes' z := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + apply Prod.ext <;> simp [Algebra.algebraMap_eq_smul_one, + derivation_one σ lam D hD] + +@[simp] lemma triangularHom_apply (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) hD + (a : A) : triangularHom σ lam D hD a=triangularMap σ lam D a := rfl + +lemma triangularMap_norm_le (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a, ‖D a‖≤‖a‖) (a : A) : ‖triangularMap σ lam D a‖≤2*‖a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro x + have hl : ‖lam a x.fst‖≤‖a‖*‖x.fst‖ := + ((lam a).le_opNorm _).trans (mul_le_mul_of_nonneg_right + (NonUnitalStarAlgHom.norm_apply_le lam a) (norm_nonneg _)) + have hs : ‖σ a x.snd‖≤‖a‖*‖x.snd‖ := + ((σ a).le_opNorm _).trans (mul_le_mul_of_nonneg_right + (NonUnitalStarAlgHom.norm_apply_le σ a) (norm_nonneg _)) + have hd : ‖WithLp.toLp 2 (lam a x.fst,σ a x.snd)‖≤‖a‖*‖x‖ := by + apply (sq_le_sq₀ (norm_nonneg _) (by positivity)).mp + rw [WithLp.prod_norm_sq_eq_of_L2,mul_pow,WithLp.prod_norm_sq_eq_of_L2] + change ‖lam a x.fst‖^2+‖σ a x.snd‖^2≤ + ‖a‖^2*(‖x.fst‖^2+‖x.snd‖^2) + nlinarith [pow_le_pow_left₀ (norm_nonneg _) hl 2, + pow_le_pow_left₀ (norm_nonneg _) hs 2] + have ho : ‖WithLp.toLp 2 (D a x.snd,(0:K))‖≤‖a‖*‖x‖ := by + rw [WithLp.norm_toLp_fst] + exact ((D a).le_opNorm _).trans (mul_le_mul (hD a) (WithLp.norm_snd_le F x) + (norm_nonneg _) (norm_nonneg _)) + have he : triangularMap σ lam D a x= + WithLp.toLp 2 (lam a x.fst,σ a x.snd)+WithLp.toLp 2 (D a x.snd,(0:K)) := by + apply (WithLp.equiv 2 (F × K)).injective + exact Prod.ext rfl (by simp) + rw [he] + exact (norm_add_le _ _).trans (by linarith) + +lemma normalized_column_sq {ι : Type*} [Fintype ι] + (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) + (hn : ∀ a, ‖D a‖≤‖a‖) (a : ι → A) (ξ : K) : + ∑ i, ‖D (a i) ξ‖^2 ≤ 16*‖ξ‖^2*‖∑ i,star (a i)*a i‖ := by + have h := ColumnModule.hom_column_sq (triangularHom σ lam D hD) + (M:=2) (by norm_num) (triangularMap_norm_le σ lam D hn) a + (WithLp.toLp 2 ((0:F),ξ)) + simp only [WithLp.norm_toLp_snd] at h + norm_num only [show (2:ℝ)^4=16 by norm_num] at h + refine (Finset.sum_le_sum (fun i _ => ?_)).trans h + apply pow_le_pow_left₀ (norm_nonneg _) _ 2 + have hh := WithLp.norm_fst_le F ((triangularHom σ lam D hD) (a i) + (WithLp.toLp 2 ((0:F),ξ))) + simpa using hh + +theorem column_sq {ι : Type*} [Fintype ι] + (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + (Δ : A →L[ℂ] (K →L[ℂ] F)) + (hΔ : ∀ a b, Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b)) + (a : ι → A) (ξ : K) : + ∑ i, ‖Δ (a i) ξ‖^2 ≤ 16*‖Δ‖^2*‖ξ‖^2*‖∑ i,star (a i)*a i‖ := by + by_cases hz : Δ=0 + · rw [hz] + simp only [zero_apply,norm_zero,zero_pow (by norm_num : 2≠0),Finset.sum_const_zero, + mul_zero,zero_mul] + positivity + have hd : 0<‖Δ‖ := norm_pos_iff.mpr hz + let D : A →L[ℂ] (K →L[ℂ] F) := ‖Δ‖⁻¹ • Δ + have hD (a b : A) : D (a*b)=(D a).comp (σ b)+(lam a).comp (D b) := by + simp only [D,smul_apply,hΔ,smul_add,ContinuousLinearMap.smul_comp, + ContinuousLinearMap.comp_smul] + have hn (a : A) : ‖D a‖≤‖a‖ := by + simp only [D,smul_apply,norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hd)] + calc + _ ≤ ‖Δ‖⁻¹*(‖Δ‖*‖a‖) := mul_le_mul_of_nonneg_left (Δ.le_opNorm a) (by positivity) + _ = ‖a‖ := by rw [←mul_assoc,inv_mul_cancel₀ hd.ne',one_mul] + have h := normalized_column_sq σ lam D hD hn a ξ + have he (i : ι) : Δ (a i) ξ=‖Δ‖ • D (a i) ξ := by + simp only [D,smul_apply,smul_smul,mul_inv_cancel₀ hd.ne',one_smul] + calc + _ = ‖Δ‖^2 * ∑ i, ‖D (a i) ξ‖^2 := by + simp only [he,norm_smul,Real.norm_eq_abs,abs_norm,mul_pow,Finset.mul_sum] + _ ≤ ‖Δ‖^2*(16*‖ξ‖^2*‖∑ i,star (a i)*a i‖) := + mul_le_mul_of_nonneg_left h (sq_nonneg _) + _ = _ := by ring + +theorem column_bound [PartialOrder A] [StarOrderedRing A] {ι : Type*} [Fintype ι] + (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + (Δ : A →L[ℂ] (K →L[ℂ] F)) + (hΔ : ∀ a b, Δ (a*b)=(Δ a).comp (σ b)+(lam a).comp (Δ b)) + (a : ι → A) (ξ : K) : + ‖WithLp.toLp 2 (fun i => Δ (a i) ξ)‖≤ + (4*‖Δ‖)*CyclicColumns.columnNorm a*‖ξ‖ := by + have hn := CyclicColumns.columnNorm_nonneg a + apply (sq_le_sq₀ (norm_nonneg _) (by positivity)).mp + rw [PiLp.norm_sq_eq_of_L2] + have h := column_sq σ lam Δ hΔ a ξ + rw [←CyclicColumns.columnNorm_sq a] at h + calc + _ ≤ 16*‖Δ‖^2*‖ξ‖^2*CyclicColumns.columnNorm a^2 := h + _ = _ := by ring + +end Kadison.RectangularColumn + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RectangularTensors.lean b/lean/OAI/Analysis/Commutator/RectangularTensors.lean new file mode 100644 index 0000000000000000000000000000000000000000..89f411a7eddc6023eb8a08709e1152e0d4436c9a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RectangularTensors.lean @@ -0,0 +1,83 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.RectangularTensors + +open Matrix + +variable {𝕜 : Type*} [CommRing 𝕜] + +variable {I K L J : Type*} [Fintype I] [Fintype K] [Fintype L] [Fintype J] [DecidableEq J] + +def tensor (A : J → Matrix I K 𝕜) : Matrix (J → I) (J → K) 𝕜 := + fun a b => ∏ j, A j (a j) (b j) + +omit [Fintype I] [Fintype L] in +lemma tensor_mul (A : J → Matrix I K 𝕜) (B : J → Matrix K L 𝕜) : + tensor (fun j => A j * B j) = tensor A * tensor B := by + classical + ext a b + simp only [tensor, Matrix.mul_apply] + rw [Fintype.prod_sum] + simp only [← Finset.prod_mul_distrib] + +omit [Fintype I] [DecidableEq J] in +lemma tensor_one [DecidableEq I] : tensor (fun _ : J => (1 : Matrix I I 𝕜)) = 1 := by + classical + ext a b + simp only [tensor, Matrix.one_apply] + by_cases h : a = b + · subst b; simp + · rw [ite_eq_right h] + obtain ⟨j, hj⟩ := Function.ne_iff.mp h + exact Finset.prod_eq_zero (Finset.mem_univ j) (ite_eq_right hj) + +def perm [DecidableEq I] (σ : Equiv.Perm J) : Matrix (J → I) (J → I) 𝕜 := + fun a b => if a = b ∘ σ.symm then 1 else 0 + +lemma tensor_constant_natural [DecidableEq I] [DecidableEq K] + (X : Matrix I K 𝕜) (σ : Equiv.Perm J) : + tensor (fun _ : J => X) * perm (𝕜 := 𝕜) (I := K) σ = perm (𝕜 := 𝕜) (I := I) σ * tensor (fun _ : J => X) := by + classical + ext a b + simp only [Matrix.mul_apply, perm, mul_ite, mul_one, mul_zero] + rw [Finset.sum_eq_single (b ∘ σ.symm)] + · rw [ite_eq_left rfl] + rw [Finset.sum_eq_single (a ∘ σ)] + · have ha : a = (a ∘ σ) ∘ σ.symm := by ext j; simp + rw [ite_eq_left ha, one_mul] + simp only [tensor, Function.comp_apply] + simpa using (Equiv.prod_comp σ.symm (fun j => X (a (σ j)) (b j))) + · intro c _ hc + rw [ite_eq_right (by intro h; apply hc; ext j; simpa using (congrFun h (σ j)).symm), + zero_mul] + · simp + · intro c _ hc + exact ite_eq_right hc + · simp + +lemma trace_transport [DecidableEq I] [DecidableEq K] + (X : Matrix I K 𝕜) (Y : Matrix K I 𝕜) (hYX : Y * X = 1) + (A : J → Matrix K K 𝕜) (σ : Equiv.Perm J) : + Matrix.trace (perm (𝕜 := 𝕜) (I := I) σ * tensor (fun j => X * A j * Y)) = + Matrix.trace (perm (𝕜 := 𝕜) (I := K) σ * tensor A) := by + rw [tensor_mul, tensor_mul] + rw [← Matrix.mul_assoc, ← Matrix.mul_assoc, Matrix.trace_mul_comm] + rw [← Matrix.mul_assoc (tensor (fun _ : J => Y)) + (perm (𝕜 := 𝕜) (I := I) σ * tensor (fun _ : J => X)) (tensor A)] + rw [← Matrix.mul_assoc (tensor (fun _ : J => Y)) (perm (𝕜 := 𝕜) (I := I) σ) + (tensor (fun _ : J => X)), tensor_constant_natural Y σ] + rw [Matrix.mul_assoc (perm (𝕜 := 𝕜) (I := K) σ), ← tensor_mul] + simp only [hYX, tensor_one, Matrix.mul_one] + +end Kadison.RectangularTensors +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ReducingCompression.lean b/lean/OAI/Analysis/Commutator/ReducingCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..3962948b8ecbe34f548d61cb8781d6850aafde37 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ReducingCompression.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteHankel +import OAI.Analysis.Commutator.ReducingRepresentation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.ReducingRepresentation + +variable {A H : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → σ a x∈K) + +lemma inclusion_intertwines (a : A) : (σ a).comp K.subtypeL= + K.subtypeL.comp (restrict σ K hinv a) := rfl + +lemma projection_intertwines (a : A) : K.orthogonalProjectionOnto.comp (σ a)= + (restrict σ K hinv a).comp K.orthogonalProjectionOnto := by + have h := congrArg (fun T : K →L[ℂ] H => T.adjoint) (inclusion_intertwines σ K hinv (star a)) + simpa only [adjoint_comp,Submodule.adjoint_subtypeL,map_star,star_eq_adjoint,adjoint_adjoint] using h + +def compression (S : H →L[ℂ] H) : K →L[ℂ] K := + K.orthogonalProjectionOnto.comp (S.comp K.subtypeL) + +lemma compression_eq (S : H →L[ℂ] H) : compression K S=FreeCorner.compress K.subtypeₗᵢ S := by + change K.orthogonalProjectionOnto.comp (S.comp K.subtypeL)= + (K.subtypeL.adjoint.comp S).comp K.subtypeL + rw [Submodule.adjoint_subtypeL] + rfl + +lemma norm_compression_le (S : H →L[ℂ] H) : ‖compression K S‖≤‖S‖ := by + rw [compression_eq] + exact FreeCorner.norm_compress_le _ S + +lemma compression_left (S : H →L[ℂ] H) (a : A) : + compression K (σ a*S)=restrict σ K hinv a*compression K S := by + simp only [compression,mul_def,←comp_assoc] + rw [projection_intertwines σ K hinv] + +lemma compression_right (S : H →L[ℂ] H) (a : A) : + compression K (S*σ a)=compression K S*restrict σ K hinv a := by + simp only [compression,mul_def,comp_assoc] + rw [inclusion_intertwines σ K hinv] + +omit [CompleteSpace H] in +lemma compression_sub (S T : H →L[ℂ] H) : compression K (S-T)=compression K S-compression K T := by + simp only [compression,comp_sub,sub_comp] + +lemma compression_commutator (S : H →L[ℂ] H) (a : A) : + compression K (S*σ a-σ a*S)= + compression K S*restrict σ K hinv a-restrict σ K hinv a*compression K S := by + rw [compression_sub,compression_left σ K hinv,compression_right σ K hinv] + +lemma norm_commutator_compression_le (S : H →L[ℂ] H) (a : A) : + ‖compression K S*restrict σ K hinv a-restrict σ K hinv a*compression K S‖≤‖S*σ a-σ a*S‖ := by + rw [←compression_commutator σ K hinv] + exact norm_compression_le K _ + +end Kadison.ReducingRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ReducingMatrix.lean b/lean/OAI/Analysis/Commutator/ReducingMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..79f32a9cb51f39fa72fda196cb5a31c6e15a5d0b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ReducingMatrix.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.ReducingCompression + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +open ContinuousLinearMap + +namespace Kadison.ReducingRepresentation + +variable {A H : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def matrixInclusion (K : Submodule ℂ H) (h : ℕ) : + (PiLp 2 fun _ : Fin h => K) →ₗᵢ[ℂ] (PiLp 2 fun _ : Fin h => H) where + toFun x := WithLp.toLp 2 (fun i => (x i:H)) + map_add' x y := by ext i; rfl + map_smul' c x := by ext i; rfl + norm_map' x := by + rw [PiLp.norm_eq_of_L2,PiLp.norm_eq_of_L2] + rfl + +omit [CompleteSpace H] in +@[simp] lemma matrixInclusion_apply (K : Submodule ℂ H) (h : ℕ) + (x : PiLp 2 fun _ : Fin h => K) (i : Fin h) : matrixInclusion K h x i=(x i:H) := rfl + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H),x∈K → σ a x∈K) + +lemma matrix_intertwines (h : ℕ) (X : Matrix (Fin h) (Fin h) A) : + (matrixOperator h (fun i j => σ (X i j))).comp (matrixInclusion K h).toContinuousLinearMap= + (matrixInclusion K h).toContinuousLinearMap.comp + (matrixOperator h (fun i j => restrict σ K hinv (X i j))) := by + ext x i + change (matrixOperator h (fun i j => σ (X i j)) (matrixInclusion K h x)) i= + ((matrixOperator h (fun i j => restrict σ K hinv (X i j)) x) i:H) + erw [matrixOperator_apply,matrixOperator_apply] + exact (map_sum K.subtype (fun j => restrict σ K hinv (X i j) (x j)) Finset.univ).symm + +lemma restricted_matrix_norm_le (h : ℕ) (X : Matrix (Fin h) (Fin h) A) : + ‖matrixOperator h (fun i j => restrict σ K hinv (X i j))‖≤ + ‖matrixOperator h (fun i j => σ (X i j))‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + have he := congrArg (fun T => T x) (matrix_intertwines σ K hinv h X) + change matrixOperator h (fun i j => σ (X i j)) (matrixInclusion K h x)= + matrixInclusion K h (matrixOperator h (fun i j => restrict σ K hinv (X i j)) x) at he + rw [←(matrixInclusion K h).norm_map,←he] + simpa only [LinearIsometry.norm_map] using + (matrixOperator h (fun i j => σ (X i j))).le_opNorm (matrixInclusion K h x) + +omit [CompleteSpace H] [CompleteSpace K] in +lemma diagonal_intertwines (Y : H →L[ℂ] H) (hY : ∀ x∈K,Y x∈K) (h : ℕ) : + (diagonalAmplification h Y).comp (matrixInclusion K h).toContinuousLinearMap= + (matrixInclusion K h).toContinuousLinearMap.comp (diagonalAmplification h (Y.restrict hY)) := by + ext x i + rfl + +lemma matrix_commutator_intertwines (Y : H →L[ℂ] H) (hY : ∀ x∈K,Y x∈K) + (h : ℕ) (X : Matrix (Fin h) (Fin h) A) : + (diagonalAmplification h Y*matrixOperator h (fun i j => σ (X i j))- + matrixOperator h (fun i j => σ (X i j))*diagonalAmplification h Y).comp + (matrixInclusion K h).toContinuousLinearMap= + (matrixInclusion K h).toContinuousLinearMap.comp + (diagonalAmplification h (Y.restrict hY)*matrixOperator h (fun i j => restrict σ K hinv (X i j))- + matrixOperator h (fun i j => restrict σ K hinv (X i j))*diagonalAmplification h (Y.restrict hY)) := by + simp only [sub_comp,comp_sub,mul_def] + congr 1 + · rw [comp_assoc,matrix_intertwines σ K hinv h X,←comp_assoc, + diagonal_intertwines K Y hY h,comp_assoc] + · rw [comp_assoc,diagonal_intertwines K Y hY h,←comp_assoc, + matrix_intertwines σ K hinv h X,comp_assoc] + +omit [CompleteSpace H] in +lemma compression_eq_restrict (Y : H →L[ℂ] H) (hY : ∀ x∈K,Y x∈K) : + compression K Y=Y.restrict hY := by + apply ContinuousLinearMap.ext + intro x + change K.orthogonalProjectionOnto (Y (x:H))=(Y.restrict hY) x + exact K.orthogonalProjectionOnto_mem_subspace_eq_self (Y.restrict hY x) + +end Kadison.ReducingRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ReducingRepresentation.lean b/lean/OAI/Analysis/Commutator/ReducingRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..980807d5ae44ab094c7726a2a21d7dd549f69b6e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ReducingRepresentation.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerAlgebra +import OAI.Analysis.Commutator.MatrixCornerHilbert + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.ReducingRepresentation + +variable {A H : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (σ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (K : Submodule ℂ H) [CompleteSpace K] + (hinv : ∀ (a : A) (x : H), x∈K → σ a x∈K) + +def restrict : A →⋆ₐ[ℂ] (K →L[ℂ] K) where + toFun a := (σ a).restrict (hinv a) + map_one' := by ext x; change σ 1 (x:H)=x; simp + map_mul' a b := by ext x; change σ (a*b) (x:H)=σ a (σ b x); rw [map_mul]; rfl + map_add' a b := by ext x; change σ (a+b) (x:H)=σ a x+σ b x; rw [map_add]; rfl + map_zero' := by ext x; change σ 0 (x:H)=0; simp + commutes' c := by + ext x + change σ (algebraMap ℂ A c) (x:H)=c • (x:H) + simp only [Algebra.algebraMap_eq_smul_one,map_smul,map_one,smul_apply,one_apply_eq_self] + map_star' a := by + apply ContinuousLinearMap.ext + intro x + apply ext_inner_left ℂ + intro y + change inner ℂ (y:H) (σ (star a) (x:H)) = inner ℂ y (((σ a).restrict (hinv a)).adjoint x) + rw [adjoint_inner_right] + change inner ℂ (y:H) (σ (star a) (x:H))=inner ℂ (σ a (y:H)) (x:H) + rw [map_star,star_eq_adjoint,adjoint_inner_right] + +@[simp] lemma restrict_apply (a : A) (x : K) : + (restrict σ K hinv a x:H)=σ a x := rfl + +variable {p : A} (hp : IsStarProjection p) + +def corner : Corner hp →⋆ₐ[ℂ] (MatrixCornerHilbert.fixedSpace (σ p) →L[ℂ] + MatrixCornerHilbert.fixedSpace (σ p)) where + toFun a := (σ (a:A)).restrict (by + intro x hx + rw [MatrixCornerHilbert.mem_fixedSpace] at hx ⊢ + change (σ p*σ (a:A)) x=σ (a:A) x + rw [←map_mul,a.property.1]) + map_one' := by + ext x + exact MatrixCornerHilbert.fixed_apply (σ p) x + map_mul' a b := by ext x; change σ ((a:A)*(b:A)) (x:H)=σ (a:A) (σ (b:A) x); rw [map_mul]; rfl + map_add' a b := by ext x; change σ ((a:A)+(b:A)) (x:H)=σ (a:A) x+σ (b:A) x; rw [map_add]; rfl + map_zero' := by ext x; change σ 0 (x:H)=0; simp + commutes' c := by + ext x + change σ (c • p) (x:H)=c • (x:H) + rw [map_smul,smul_apply,MatrixCornerHilbert.fixed_apply] + map_star' a := by + apply ContinuousLinearMap.ext + intro x + apply ext_inner_left ℂ + intro y + rw [star_eq_adjoint,adjoint_inner_right] + change inner ℂ (y:H) (σ (star (a:A)) (x:H))=inner ℂ (σ (a:A) (y:H)) (x:H) + rw [map_star,star_eq_adjoint,adjoint_inner_right] + +@[simp] lemma corner_apply (a : Corner hp) (x : MatrixCornerHilbert.fixedSpace (σ p)) : + (corner σ hp a x:H)=σ (a:A) x := rfl + +end Kadison.ReducingRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/Regroup.lean b/lean/OAI/Analysis/Commutator/Regroup.lean new file mode 100644 index 0000000000000000000000000000000000000000..8443570a31a75f166997f8d5cd7ea36a96bcd357 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/Regroup.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBlockTensor2 +import OAI.Analysis.Commutator.HilbertTensors +import OAI.Analysis.Commutator.TensorCompletion + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.FreeBlocks + +open FreeMoments FreeWordTensor FreeCreation UniformSpace + +open scoped TensorProduct InnerProductSpace + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (t : FaithfulState A) {ι : Type*} (S : ι → StarSubalgebra ℂ A) + +variable {i j : ι} + +def dLetters (i : ι) : PreHilbert := ⟨letterSpace t S i⟩ + +def aLetters (i : ι) : PreHilbert := ⟨factorSpace t S i⟩ + +@[reducible] def multiplicityTensor (j : ι) : ℕ → Space + | 0 => ⟨factorSpace t S j⟩ + | n+1 => spaceTensor ⟨letterSpace t S j⟩ (multiplicityTensor j n) + +def paramD : ∀ n, BlockParams t S i j n → (Fin n → letterSpace t S i) + | 0, _ => Fin.elim0 + | n+1, x => Fin.cons x.1.2 (paramD n x.2) + +def paramJ : ∀ n, BlockParams t S i j n → multiplicityTensor t S j n + | 0, z => z + | n+1, x => x.1.1 ⊗ₜ[ℂ] paramJ n x.2 + +def blockShuffle : ∀ n, blockTensor t S i j n ≃ₗᵢ[ℂ] + (PreHilbert.power (dLetters t S i) n ⊗[ℂ] multiplicityTensor t S j n) + | 0 => (TensorProduct.lidIsometry ℂ (aLetters t S j)).symm + | n+1 => + (TensorProduct.congrIsometry (.refl ℂ (dLetters t S j)) + (TensorProduct.congrIsometry (.refl ℂ (dLetters t S i)) (blockShuffle n))) |>.trans + (TensorProduct.congrIsometry (.refl ℂ (dLetters t S j)) + (TensorProduct.assocIsometry ℂ (dLetters t S i) + (PreHilbert.power (dLetters t S i) n) (multiplicityTensor t S j n)).symm) |>.trans + HilbertCompletion.leftSwap + +@[simp] lemma blockShuffle_pure : ∀ n (x : BlockParams t S i j n), + blockShuffle t S n (blockPure t S n x) = + PreHilbert.pure (dLetters t S i) n (paramD t S n x) ⊗ₜ[ℂ] paramJ t S n x + | 0, x => by rfl + | n+1, x => by + change HilbertCompletion.leftSwap + ((TensorProduct.congrIsometry (.refl ℂ (dLetters t S j)) + (TensorProduct.assocIsometry ℂ (dLetters t S i) + (PreHilbert.power (dLetters t S i) n) (multiplicityTensor t S j n)).symm) + ((x.1.1 : dLetters t S j) ⊗ₜ[ℂ] + ((x.1.2 : dLetters t S i) ⊗ₜ[ℂ] blockShuffle t S n (blockPure t S n x.2)))) = _ + rw [blockShuffle_pure n x.2] + change HilbertCompletion.leftSwap + ((x.1.1 : dLetters t S j) ⊗ₜ[ℂ] + (((x.1.2 : dLetters t S i) ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x.2)) ⊗ₜ[ℂ] + paramJ t S n x.2)) = _ + rw [HilbertCompletion.leftSwap_tmul] + rfl + +def endpointShuffle (n : ℕ) : endpointTensor t S i j n ≃ₗᵢ[ℂ] + ((aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) ⊗[ℂ] + multiplicityTensor t S j n) := + (TensorProduct.congrIsometry (.refl ℂ (aLetters t S i)) (blockShuffle t S n)) |>.trans + (TensorProduct.assocIsometry ℂ (aLetters t S i) + (PreHilbert.power (dLetters t S i) n) (multiplicityTensor t S j n)).symm + +@[simp] lemma endpointShuffle_pure (n : ℕ) (a : factorSpace t S i) (x : BlockParams t S i j n) : + endpointShuffle t S n (a ⊗ₜ[ℂ] blockPure t S n x) = + (a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x)) ⊗ₜ[ℂ] paramJ t S n x := by + change (TensorProduct.assocIsometry ℂ (aLetters t S i) + (PreHilbert.power (dLetters t S i) n) (multiplicityTensor t S j n)).symm + ((a : aLetters t S i) ⊗ₜ[ℂ] blockShuffle t S n (blockPure t S n x)) = _ + rw [blockShuffle_pure] + rfl + +abbrev scalarLevel (i : ι) (n : ℕ) := Completion + (aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) + +abbrev multiplicityLevel (j : ι) (n : ℕ) := Completion (multiplicityTensor t S j n) + +def levelShuffle (n : ℕ) : Completion (endpointTensor t S i j n) ≃ₗᵢ[ℂ] + Completion (scalarLevel t S i n ⊗[ℂ] multiplicityLevel t S j n) := + (HilbertCompletion.congr (endpointShuffle t S n)).trans HilbertCompletion.tensor + +@[simp] lemma levelShuffle_pure (n : ℕ) (a : aLetters t S i) (x : BlockParams t S i j n) : + levelShuffle t S n ((HilbertCompletion.coeIsometry (endpointTensor t S i j n)) (a ⊗ₜ[ℂ] blockPure t S n x)) = + ((((a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x)) : scalarLevel t S i n) ⊗ₜ[ℂ] + (paramJ t S n x : multiplicityLevel t S j n)) : Completion (scalarLevel t S i n ⊗[ℂ] multiplicityLevel t S j n)) := by + let y : endpointTensor t S i j n := a ⊗ₜ[ℂ] blockPure t S n x + change HilbertCompletion.tensor ((HilbertCompletion.congr (endpointShuffle t S n)) (y : Completion (endpointTensor t S i j n))) = _ + rw [HilbertCompletion.congr_coe] + change HilbertCompletion.tensor ((endpointShuffle t S n (a ⊗ₜ[ℂ] blockPure t S n x)) : Completion ((aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) ⊗[ℂ] multiplicityTensor t S j n)) = _ + have he : endpointShuffle t S n (a ⊗ₜ[ℂ] blockPure t S n x) = + (a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x)) ⊗ₜ[ℂ] paramJ t S n x := + endpointShuffle_pure t S n (a : factorSpace t S i) x + exact (congrArg (fun z : (aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) ⊗[ℂ] + multiplicityTensor t S j n => HilbertCompletion.tensor + (E := aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) + (F := multiplicityTensor t S j n) + (z : Completion ((aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) ⊗[ℂ] + multiplicityTensor t S j n))) he).trans + (HilbertCompletion.tensor_coe_tmul + (E := aLetters t S i ⊗[ℂ] PreHilbert.power (dLetters t S i) n) + (F := multiplicityTensor t S j n) + (a ⊗ₜ[ℂ] PreHilbert.pure (dLetters t S i) n (paramD t S n x)) (paramJ t S n x)) + +end Kadison.FreeBlocks +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeCornerPhase.lean b/lean/OAI/Analysis/Commutator/RelativeCornerPhase.lean new file mode 100644 index 0000000000000000000000000000000000000000..0de3a70e047ee6105bf062512127120c6c9627e4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeCornerPhase.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerPhaseSelectionCore +import OAI.Analysis.Commutator.NormalSubalgebra +import OAI.Analysis.Commutator.NormalTraceProjection +import OAI.Analysis.Commutator.PartialUnitaryAlgebra +import OAI.Analysis.Commutator.TracialL2Continuity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators InnerProductSpace + +namespace Kadison.CornerPhase + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M N : VonNeumannAlgebra H) (hNM : N ≤ M) + +variable (τ : M →ₚ[ℂ] ℂ) (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +include hτ hNM in +theorem exists_relative_corner_phase {J : Type*} [Fintype J] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + (hN : DiffuseProjection.HasNoMinimalProjections N) + (q : M) (hq : IsStarProjection q) (hqN : (q : H →L[ℂ] H)∈N) + (hqt : 0<(τ q).re) + (a : J → M) (k : J → ℕ) (hk : ∀ j,0 (a : H →L[ℂ] H)) hq.isIdempotentElem.eq) + · exact Subtype.ext (congrArg (fun a : M => (a : H →L[ℂ] H)) hq.isSelfAdjoint.star_eq) + obtain ⟨p,hp,ho,hsum⟩ := NormalGNS.exists_projection_partition N σ + (NormalSubalgebra.tracial M N hNM τ hτ) + (NormalSubalgebra.normal M N hNM τ hnormal) + (NormalSubalgebra.faithful M N hNM τ hfaith) hN + n qN hqNproj (t:=(τ q).re/n) (by positivity) (by change (τ q).re=_; field_simp) + let e : ZMod n → M := fun i => ι (p ((ZMod.finEquiv n).symm i)) + have he : ∀ i,IsStarProjection (e i) := fun i => (hp _).1.map ι + have heo : ∀ i j,i≠j → e i*e j=0 := by + intro i j hij + change ι (p _)*ι (p _)=0 + rw [←map_mul,ho _ _ (fun hh => hij ((ZMod.finEquiv n).symm.injective hh)),map_zero] + have hep : ∑ i,e i=q := by + change ∑ i,ι (p ((ZMod.finEquiv n).symm i))=ι qN + rw [←map_sum,←hsum] + congr 1 + exact Fintype.sum_equiv (ZMod.finEquiv n).symm.toEquiv _ _ (fun _ => rfl) + obtain ⟨u,h1,h2,h3,h4,h5,h6,hmem⟩ := exists_phase_finite τ hτ e he heo q hq hep + (fun _ => (hp _).2.2) hqt a k (fun j => ⟨hk j,hkn j⟩) hε hbudget + refine ⟨u,h1,h2,h3,h4,h5,h6,?_⟩ + exact hmem (N.toStarSubalgebra.comap M.toStarSubalgebra.subtype) + (fun i => (p _).property) + +include hτ hNM in +theorem exists_relative_signed_phase {J : Type*} [Fintype J] + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) + (hN : DiffuseProjection.HasNoMinimalProjections N) + (q : M) (hq : IsStarProjection q) (hqN : (q : H →L[ℂ] H)∈N) + (hqt : 0<(τ q).re) + (a : J → M) (k : J → ℤ) (hk : ∀ j,k j≠0) {ε : ℝ} (hε : 0<ε) : + ∃ u : FinitePatching.PartialUnitary M, u.support=q ∧ + (∀ j, ‖τ (u.power (k j)*a j)‖<ε*(τ q).re) ∧ (u.val : H →L[ℂ] H)∈N := by + let b : J → M := fun j => match k j with + | .ofNat _ => a j + | .negSucc _ => star (a j) + obtain ⟨u,h1,h2,h3,h4,_,hu,hmem⟩ := exists_relative_corner_phase M N hNM τ hτ + hnormal hfaith hN q hq hqN hqt b (fun j => (k j).natAbs) + (fun j => Int.natAbs_pos.mpr (hk j)) hε + let v : FinitePatching.PartialUnitary M := ⟨u,q,hq,h1,h2,h3,h4⟩ + refine ⟨v,rfl,?_,hmem⟩ + intro j + have hj := hu j + cases he : k j with + | ofNat n => + cases n with + | zero => exact (hk j he).elim + | succ n => + change ‖τ (u^(n+1)*a j)‖<ε*(τ q).re + simpa only [b,he,Int.natAbs_ofNat',Int.natAbs_negSucc] using hj + | negSucc n => + change ‖τ ((star u)^(n+1)*a j)‖<ε*(τ q).re + rw [←star_pow,TracialL2.norm_trace_star_mul τ hτ] + simpa only [b,he,Int.natAbs_ofNat',Int.natAbs_negSucc] using hj + +end Kadison.CornerPhase + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeCornerQuantization.lean b/lean/OAI/Analysis/Commutator/RelativeCornerQuantization.lean new file mode 100644 index 0000000000000000000000000000000000000000..ba6a743565ff8265fc4059374fa21b8a897c39ee --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeCornerQuantization.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.Commutator.CornerPolarTransfer +import OAI.Analysis.Commutator.LocalQuantization +import OAI.Analysis.Commutator.PolarSupport +import OAI.Analysis.Commutator.TracialConjugation +import OAI.Analysis.Commutator.TracialL2Tools + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +open Filter + +namespace Kadison.RelativeCornerQuantization + +open TracialL2 CornerPolarTransfer + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) + +include hτ in +theorem exists_polar_cut (p q : M) (hp : IsStarProjection p) (hq : IsStarProjection q) + {c t : ℝ} (hc : 0 ≤ c) (hct : c*c*t=1) : + ∃ f : M, IsStarProjection f ∧ f ≤ p ∧ (τ f).re ≤ (τ q).re ∧ + (τ q).re-(τ f).re ≤ (c^2*norm τ (q*(p-t • (1:M))*q))^2 ∧ + (∀ y : M, p*y=y → y*p=y → norm τ (f*y*f) ≤ + c^2*norm τ (q*y*q)+(1+c)*‖y‖*c^2*norm τ (q*(p-t • (1:M))*q)) ∧ + (∀ N : VonNeumannAlgebra H, (p : H →L[ℂ] H)∈N → (q : H →L[ℂ] H)∈N → + (f : H →L[ℂ] H)∈N) := by + let b : M := c • (p*q) + have hpb : p*b=b := by dsimp [b]; rw [mul_smul_comm,←mul_assoc,hp.isIdempotentElem.eq] + have hbq : b*q=b := by dsimp [b]; rw [smul_mul_assoc,mul_assoc,hq.isIdempotentElem.eq] + obtain ⟨v,hva,hr,hf,hra,hvn,hvN,hleft,hright⟩ := exists_polar_data M b + have hrq : star v*v ≤ q := hright q hq hbq + have haq : CFC.abs b*q=CFC.abs b := by + apply Subtype.ext + change ((CFC.abs b : M) : H →L[ℂ] H)*(q : H →L[ℂ] H)=((CFC.abs b : M) : H →L[ℂ] H) + rw [←abs_coe M] + exact Polar.abs_mul_of_mul _ _ (congrArg (fun a : M => (a : H →L[ℂ] H)) hbq) + have hdef : norm τ (v-b) ≤ c^2*norm τ (q*(p-t • (1:M))*q) := by + have h := defect_bound τ hq hr hrq (CFC.abs_nonneg b) hra haq rfl + rw [hva,CFC.abs_mul_abs] at h + exact h.trans_eq (norm_scaled_projection_defect τ hp hq hct) + have hker : (τ q).re-(τ (star v*v)).re ≤ (c^2*norm τ (q*(p-t • (1:M))*q))^2 := by + have h := trace_kernel_bound τ hq hr (CFC.abs_nonneg b) hra haq + rw [CFC.abs_mul_abs,norm_scaled_projection_defect τ hp hq hct] at h + exact h + have htr : τ (star v*v)=τ (v*star v) := hτ _ _ + have hbn : ‖b‖ ≤ c := by + dsimp [b] + rw [_root_.norm_smul,Real.norm_of_nonneg hc] + have hpqn : ‖p*q‖ ≤ 1 := (_root_.norm_mul_le _ _).trans + ((mul_le_mul (hp.norm_le p) (hq.norm_le q) (_root_.norm_nonneg _) (by norm_num)).trans_eq + (one_mul (1:ℝ))) + exact mul_le_of_le_one_right hc hpqn + refine ⟨v*star v,hf,hleft p hp hpb,?_,by simpa only [htr] using hker,?_,?_⟩ + · have h := (τ.monotone hrq).1 + change (τ (star v*v)).re ≤ (τ q).re at h + simpa only [htr] using h + · intro y hpy hyp + calc + _ ≤ c^2*norm τ (q*y*q)+(1+‖b‖)*‖y‖*norm τ (v-b) := + compressed_scalar_polar τ hτ hp hq hpy hyp rfl hvn + _ ≤ c^2*norm τ (q*y*q)+(1+c)*‖y‖*(c^2*norm τ (q*(p-t • (1:M))*q)) := by + apply add_le_add le_rfl + exact mul_le_mul + (mul_le_mul_of_nonneg_right (add_le_add le_rfl hbn) (_root_.norm_nonneg y)) + hdef (norm_nonneg τ _) (mul_nonneg (by positivity) (_root_.norm_nonneg y)) + _=_ := by rw [mul_assoc ((1+c)*‖y‖)] + · intro N hpN hqN + have hbN : (b : H →L[ℂ] H)∈N := by + change ((c:ℂ) • ((p : H →L[ℂ] H)*(q : H →L[ℂ] H)))∈N + exact N.toStarSubalgebra.smul_mem (N.mul_mem hpN hqN) _ + exact N.mul_mem (hvN N hbN) (N.star_mem' (hvN N hbN)) + +section Quantization + +variable {J : Type*} [Fintype J] + +variable {ι : ℕ → Type*} [∀ n, Fintype (ι n)] [∀ n, LinearOrder (ι n)] + [∀ n, Nonempty (ι n)] + +variable (stage : ∀ n, Matrix (ι n) (ι n) ℂ →⋆ₐ[ℂ] M) + +variable (hmono : ∀ {n m : ℕ}, n ≤ m → (stage n).range ≤ (stage m).range) + +include hτ hmono in +theorem exists_relative_centered_compression + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ n (x : Matrix (ι n) (ι n) ℂ), stage n x*b=b*stage n x) → + ∃ c : ℂ, b=algebraMap ℂ M c) + (hgrow : Tendsto (fun n => (Fintype.card (ι n):ℝ)) atTop atTop) + (N : VonNeumannAlgebra H) + (hstage : ∀ n a, (stage n a : H →L[ℂ] H)∈N) + (p : M) (hpN : (p : H →L[ℂ] H)∈N) (hp : IsStarProjection p) + (hpt : 0<(τ p).re) + (x : J → M) (hx : ∀ j, τ (x j)=0) (hpx : ∀ j,p*x j=x j) (hxp : ∀ j,x j*p=x j) + {ε η : ℝ} (hε : 0<ε) (hη : 0<η) : + ∃ f : M, (f : H →L[ℂ] H)∈N ∧ IsStarProjection f ∧ f ≤ p ∧ + 0<(τ f).re ∧ (τ f).re<η ∧ ∀ j, norm τ (f*x j*f)^2<ε^2*(τ f).re := by + classical + let t : ℝ := (τ p).re + have ht : 0 _root_.norm_nonneg (x j)) + have hxB (j : J) : ‖x j‖ ≤ B := + Finset.single_le_sum (fun i _ => _root_.norm_nonneg (x i)) (Finset.mem_univ j) + let K : ℝ := c^2+(1+c)*B*c^2 + have hK : 0 ≤ K := by dsimp [K]; positivity + let δ : ℝ := min (1/(2*(c^2+1))) (ε/(2*(K+1))) + have hδ : 0<δ := by dsimp [δ]; positivity + have hδc : c^2*δ ≤ 1/2 := by + have h := (le_div_iff₀ (by positivity : 0<2*(c^2+1))).mp (min_le_left + (1/(2*(c^2+1))) (ε/(2*(K+1)))) + change δ*(2*(c^2+1)) ≤ 1 at h + nlinarith only [h,hδ] + have hδK : K*δ ≤ ε/2 := by + have h := (le_div_iff₀ (by positivity : 0<2*(K+1))).mp (min_le_right + (1/(2*(c^2+1))) (ε/(2*(K+1)))) + change δ*(2*(K+1)) ≤ ε at h + nlinarith only [h,hδ] + let z : Option J → M := fun j => match j with + | none => p-t • (1:M) + | some j => x j + have htrace : τ p=(t:ℂ) := Complex.ext rfl (τ.map_nonneg hp.nonneg).2.symm + have hz : ∀ j,τ (z j)=0 := by + intro j + cases j with + | none => simp [z,map_sub,PositiveLinearMap.map_smul_of_tower,hone,htrace] + | some j => exact hx j + obtain ⟨n,q,hqstage,hq,hqt,hqη,hsum⟩ := + LocalQuantization.exists_centered_compression M τ hτ stage hmono hnormal hfaith hone hirr + hgrow z hz hδ hη + have hqN : (q : H →L[ℂ] H)∈N := by + obtain ⟨a,rfl⟩ := hqstage + exact hstage n a + have hsum' : (∑ j, norm τ (q*z j*q)^2)<δ^2*(τ q).re := by + simpa only [TracialGNS.algebraVector_apply,UniformSpace.Completion.norm_coe,TracialL2.norm] using hsum + let s : ℝ := Real.sqrt (τ q).re + have hs : 0 sq_nonneg (norm τ (q*z i*q))) (Finset.mem_univ j) + rw [mul_pow,hs2] + exact hj.trans hsum'.le + obtain ⟨f,hf,hfp,hfq,hker,hcomp,hN⟩ := exists_polar_cut M τ hτ p q hp hq hc.le hct + have hd : c^2*norm τ (q*(p-t • (1:M))*q) ≤ s/2 := by + calc + _ ≤ c^2*(δ*s) := mul_le_mul_of_nonneg_left (hsmall none) (sq_nonneg c) + _=(c^2*δ)*s := by ring + _ ≤ (1/2)*s := mul_le_mul_of_nonneg_right hδc hs.le + _=_ := by ring + have hd2 : (c^2*norm τ (q*(p-t • (1:M))*q))^2 ≤ s^2/4 := by + calc + _ ≤ (s/2)^2 := (sq_le_sq₀ (mul_nonneg (sq_nonneg c) (norm_nonneg τ _)) (by positivity)).mpr hd + _=_ := by ring + have hqt4 : (τ q).re/4<(τ f).re := by + rw [hs2] at hd2 + have hh := hker.trans hd2 + linarith only [hh,hqt] + refine ⟨f,hN N hpN hqN,hf,hfp,lt_trans (by positivity) hqt4,hfq.trans_lt hqη,?_⟩ + intro j + have hnorm : norm τ (f*x j*f) ≤ (ε/2)*s := by + calc + _ ≤ c^2*norm τ (q*x j*q)+(1+c)*‖x j‖*c^2*norm τ (q*(p-t • (1:M))*q) := + hcomp (x j) (hpx j) (hxp j) + _ ≤ c^2*(δ*s)+(1+c)*B*c^2*(δ*s) := by + gcongr + · exact hsmall (some j) + · exact norm_nonneg τ _ + · exact hxB j + · exact hsmall none + _=(K*δ)*s := by dsimp [K]; ring + _ ≤ (ε/2)*s := mul_le_mul_of_nonneg_right hδK hs.le + calc + _ ≤ ((ε/2)*s)^2 := (sq_le_sq₀ (norm_nonneg τ _) (by positivity)).mpr hnorm + _=ε^2*((τ q).re/4) := by rw [mul_pow,hs2]; ring + _<ε^2*(τ f).re := mul_lt_mul_of_pos_left hqt4 (sq_pos_of_pos hε) + +end Quantization + +end Kadison.RelativeCornerQuantization + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeEquivFreePosition.lean b/lean/OAI/Analysis/Commutator/RelativeEquivFreePosition.lean new file mode 100644 index 0000000000000000000000000000000000000000..828c105695045ac00c0205eebef2b527246f566c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeEquivFreePosition.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Commutator.AbstractFreeCornerFromUnitary +import OAI.Analysis.Commutator.AllUnitaryTests +import OAI.Analysis.Commutator.ConstantSequenceClosedTransport +import OAI.Analysis.Commutator.UnitaryEquivMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator Topology + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching FinitePatching.ConjugatedWords + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (M R : VonNeumannAlgebra H) (hRM : R ≤ M) (e : A ≃⋆ₐ[ℂ] M) (j : R →⋆ₐ[ℂ] A) + (hj : ∀ q,e (j q)=NormalSubalgebra.inclusion M R hRM q) + +variable (τ : A →ₚ[ℂ] ℂ) (σ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (size : ℕ → ℕ) + +variable (stage : ∀ n,Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] M) + +variable (inc : ∀ {n m : ℕ},n ≤ m → Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] + Matrix (Fin (size m+1)) (Fin (size m+1)) ℂ) + +include hRM hj in +theorem exists_freeCornerPosition_of_equiv_tower [TopologicalSpace.SeparableSpace σ.GNS] + (htrace : ∀ a,σ (e a)=τ a) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hσ : ∀ a b : M,σ (a*b)=σ (b*a)) + (hω : (ω : Filter ℕ) ≤ atTop) + (hnormal : NormalGNS.BoundedWOTContinuous M σ) + (hfaith : ∀ a : M,σ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ), + stage n a*b=b*stage n a) → ∃ c : ℂ,b=algebraMap ℂ M c) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hinc : ∀ n m (h : n ≤ m) a,stage m (inc h a)=stage n a) + (hgrow : Tendsto (fun n => (size n+1:ℝ)) atTop atTop) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) : + Nonempty (FreeCornerPosition τ ω R j) := by + have hσone : σ 1=1 := by rw [←map_one e,htrace,hone] + have hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range ≤ (stage m).range := by + intro n m h a ha + obtain ⟨b,rfl⟩ := ha + exact ⟨inc h b,hinc n m h b⟩ + obtain ⟨u,huR,_,huword⟩ := exists_all_unitary_tests M R hRM σ hσ stage hmono + hnormal hfaith hσone hirr (by simpa only [Fintype.card_fin,Nat.cast_add,Nat.cast_one] using hgrow) + hstage hdiffuse + let v := fun n => pullUnitary e (u n) + have hfree := sequenceUnitary_free τ ω hτ hω v (pullUnitary_moment_limits e τ σ htrace u (by + intro J x hx hxc l hl hv + exact huword J Bool x signPower hx hxc (by intro b; cases b <;> norm_num [signPower]) l hl hv)) + let stageA := fun n => e.symm.toStarAlgHom.comp (stage n) + have hfaithA (a : A) (ha : τ (star a*a)=0) : a=0 := by + apply (show Function.Injective e from e.injective) + rw [map_zero] + apply hfaith + rw [←map_star e,←map_mul e,htrace,ha] + have hirrA (b : A) (hb : ∀ n a,stageA n a*b=b*stageA n a) : + ∃ c : ℂ,b=algebraMap ℂ A c := by + obtain ⟨c,hc⟩ := hirr (e b) (by + intro n a + have hh := congrArg e (hb n a) + have hsa : e (stageA n a)=stage n a := e.apply_symm_apply _ + simpa only [map_mul,hsa] using hh) + refine ⟨c,(show Function.Injective e from e.injective) ?_⟩ + rw [Algebra.algebraMap_eq_smul_one,map_smul,map_one] + exact hc + have hstageA (n : ℕ) (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ) : stageA n a∈Set.range j := by + refine ⟨⟨stage n a,hstage n a⟩,(show Function.Injective e from e.injective) ?_⟩ + rw [hj] + change (stage n a)=e (e.symm (stage n a)) + rw [e.apply_symm_apply] + apply freeCornerPosition_of_unitary_abstract R j τ ω size stageA inc hτ hω + (constant_range_bicommutant_of_equiv τ ω M e σ hτ htrace hnormal) hfaithA hone hirrA hstageA + (fun n m h a => congrArg e.symm (hinc n m h a)) _ (sequenceUnitary τ ω v) + (pullUnitary_in_relative_range M R hRM e j hj τ ω u huR) hfree + intro n q + have he := (tendsto_atTop.1 hgrow) (q:ℝ) + obtain ⟨m,hmq,hmn⟩ := (he.and (eventually_ge_atTop n)).exists + exact ⟨m,hmn,by exact_mod_cast hmq⟩ + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeMatrix.lean b/lean/OAI/Analysis/Commutator/RelativeMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..159e6ec01f454464b96a0dd1f6cc5f368c545b7c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeMatrix.lean @@ -0,0 +1,147 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.MatrixDiagonal +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder + +namespace Kadison.RelativeMatrix + +open Matrix + +variable {H I : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype I] [DecidableEq I] + +variable (M : VonNeumannAlgebra H) (φ : Matrix I I ℂ →⋆ₐ[ℂ] M) + +abbrev concrete : Matrix I I ℂ →⋆ₐ[ℂ] (H →L[ℂ] H) := M.toStarSubalgebra.subtype.comp φ + +def relativeStar : StarSubalgebra ℂ (H →L[ℂ] H) := + M.toStarSubalgebra ⊓ StarSubalgebra.centralizer ℂ (Set.range (concrete M φ)) + +lemma mem_relativeStar (a : H →L[ℂ] H) : a∈relativeStar M φ ↔ + a∈M ∧ ∀ x : Matrix I I ℂ,concrete M φ x*a=a*concrete M φ x := by + constructor + · intro ha + refine ⟨ha.1,fun x => ?_⟩ + exact ((StarSubalgebra.mem_centralizer_iff ℂ).mp ha.2 _ ⟨x,rfl⟩).1 + · rintro ⟨ha,hc⟩ + refine ⟨ha,(StarSubalgebra.mem_centralizer_iff ℂ).mpr ?_⟩ + rintro b ⟨x,rfl⟩ + exact ⟨hc x,by simpa only [map_star] using hc (star x)⟩ + +def relative : VonNeumannAlgebra H where + toStarSubalgebra := relativeStar M φ + centralizer_centralizer' := by + apply Set.Subset.antisymm + · intro a ha + apply (mem_relativeStar M φ a).mpr + constructor + · change a∈(M : Set (H →L[ℂ] H)) + rw [←M.centralizer_centralizer] + intro c hc + apply ha c + intro b hb + exact hc b ((mem_relativeStar M φ b).mp hb).1 + · intro x + apply ha (concrete M φ x) + intro b hb + exact (((mem_relativeStar M φ b).mp hb).2 x).symm + · exact Set.subset_centralizer_centralizer + +lemma mem_relative (a : H →L[ℂ] H) : a∈relative M φ ↔ + a∈M ∧ ∀ x : Matrix I I ℂ,concrete M φ x*a=a*concrete M φ x := + mem_relativeStar M φ a + +lemma le_original : relative M φ≤M := fun a ha => ((mem_relative M φ a).mp ha).1 + +lemma diagonal_mem (o : I) (a : M) : + (MatrixDiagonal.diagonal φ o a:H →L[ℂ] H)∈relative M φ := by + apply (mem_relative M φ _).mpr + exact ⟨(MatrixDiagonal.diagonal φ o a).property,fun x => + congrArg Subtype.val (MatrixDiagonal.commutes φ o a x)⟩ + +lemma isFactor (hM : FactorCorner.IsFactor M) (o : I) : + FactorCorner.IsFactor (relative M φ) := by + intro c hc hcentral + have hcM := (mem_relative M φ c).mp hc + let cM : M := ⟨c,hcM.1⟩ + apply hM c hcM.1 + intro a ha + have hcomm : Commute (⟨a,ha⟩:M) cM := + MatrixDiagonal.central_of_commutes_diagonal φ o cM + (fun x => Subtype.ext (hcM.2 x)) + (fun b => Subtype.ext (hcentral _ (diagonal_mem M φ o b))) ⟨a,ha⟩ + exact congrArg Subtype.val hcomm.eq + +lemma noMinimal (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) (o : I) : + DiffuseProjection.HasNoMinimalProjections (relative M φ) := by + intro p hpN hp hpn + have hpMem := (mem_relative M φ p).mp hpN + let a : M := ⟨p,hpMem.1⟩ + have ha : IsStarProjection a := + ⟨Subtype.ext hp.isIdempotentElem.eq,Subtype.ext hp.isSelfAdjoint.star_eq⟩ + let e : M := φ (single o o 1) + have he : IsStarProjection e := by + apply IsStarProjection.map _ φ + constructor + · simp only [IsIdempotentElem,single_mul_single_same,one_mul] + · change star (single o o (1:ℂ))=single o o 1 + simp only [Matrix.star_eq_conjTranspose,conjTranspose_single,star_one] + have hcomm : Commute e a := Subtype.ext (hpMem.2 (single o o 1)) + have hep : IsStarProjection (e*a) := he.mul ha hcomm + have hcut : e*a*e=e*a := by + rw [hcomm.eq,mul_assoc,he.isIdempotentElem.eq,←hcomm.eq] + have hd : MatrixDiagonal.diagonal φ o (e*a)=a := by + rw [←hcut] + exact MatrixDiagonal.fixed φ o a (fun x => Subtype.ext (hpMem.2 x)) + have hen : (↑(e*a):H →L[ℂ] H)≠0 := by + intro hz + have hzero : e*a=0 := Subtype.ext hz + rw [hzero,map_zero] at hd + exact hpn (congrArg Subtype.val hd.symm) + obtain ⟨q,hqM,hq,hqn,hqp,hqle⟩ := hdiffuse (e*a) (e*a).property + (hep.map M.toStarSubalgebra.subtype) hen + let b : M := ⟨q,hqM⟩ + have hb : IsStarProjection b := + ⟨Subtype.ext hq.isIdempotentElem.eq,Subtype.ext hq.isSelfAdjoint.star_eq⟩ + have hbe : b≤e*a := hqle + have hepe : e*a≤e := (hep.le_iff_mul_eq_left he).mpr hcut + have hbr : b*e=b := (hb.le_iff_mul_eq_left he).mp (hbe.trans hepe) + have hbl : e*b=b := (hb.le_iff_mul_eq_right he).mp (hbe.trans hepe) + let r : M := MatrixDiagonal.diagonal φ o b + have hr : IsStarProjection r := MatrixDiagonal.projection φ o hb hbr + have hcutr : e*r*e=b := by rw [MatrixDiagonal.cut,hbl,hbr] + have hrne : (r:H →L[ℂ] H)≠0 := by + intro hz + have hzero : r=0 := Subtype.ext hz + rw [hzero,mul_zero,zero_mul] at hcutr + exact hqn (congrArg Subtype.val hcutr.symm) + have hrp : (r:H →L[ℂ] H)≠p := by + intro hz + have hzero : r=a := Subtype.ext hz + rw [hzero,hcut] at hcutr + exact hqp (congrArg Subtype.val hcutr.symm) + have hrle : r≤a := by + apply (hr.le_iff_mul_eq_left ha).mpr + rw [←hd,MatrixDiagonal.mul_diagonal φ o b (e*a) hbr, + (hb.le_iff_mul_eq_left hep).mp hbe] + exact ⟨r,diagonal_mem M φ o b,hr.map M.toStarSubalgebra.subtype,hrne,hrp,hrle⟩ + +end Kadison.RelativeMatrix + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeSequenceRange.lean b/lean/OAI/Analysis/Commutator/RelativeSequenceRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..6462d702fd013f8e8b147489c3119215fafee2f8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeSequenceRange.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialSmallCorners + +namespace OAI + +noncomputable section + +open scoped ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open HilbertSequence + +variable {A B : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (j : B →⋆ₐ[ℂ] A) + +def relativeVectorCLM : B →L[ℂ] τ.GNS := + (vectorCLM τ).comp (j.toLinearMap.mkContinuous 1 (fun b => by + change ‖j b‖≤1*‖b‖ + simpa only [one_mul] using NonUnitalStarAlgHom.norm_apply_le j b)) + +lemma relative_vector_unitball_isClosed (hω : (ω : Filter ℕ)≤atTop) : + IsClosed {x : boundedSubspace τ ω | ∃ a : ℕ →ᵇ B, ‖a‖≤1 ∧ + vectorIn τ ω (mapSequence j a)=x} := by + have hc := (bounded_image_isClosed ω (relativeVectorCLM τ j) hω {b : B | ‖b‖≤1} 1 + (fun _ h => h)).preimage (continuous_subtype_val (p := fun x => x∈boundedSubspace τ ω)) + convert hc using 1 + ext x + constructor + · rintro ⟨a,ha,hax⟩ + refine ⟨a,fun i => (a.norm_coe_le_norm i).trans ha,?_⟩ + exact congrArg Subtype.val hax + · rintro ⟨a,ha,hax⟩ + refine ⟨a,(BoundedContinuousFunction.norm_le (by norm_num : (0:ℝ)≤1)).mpr ha,?_⟩ + exact Subtype.ext hax + +lemma relative_bicommutant_natural {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp (mapSequence j))))) : + T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω))) := by + intro c hc + apply hT c + rintro _ ⟨a,rfl⟩ + exact hc _ ⟨mapSequence j a,rfl⟩ + +variable (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +include hτ in +lemma relative_bicommutant_contraction (hω : (ω : Filter ℕ)≤atTop) + {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp (mapSequence j))))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) : + ∃ a : ℕ →ᵇ B, ‖a‖≤1 ∧ leftRestricted τ ω (mapSequence j a)=T := by + let φ := (leftRestricted τ ω).comp (mapSequence j) + have hx : T (sequenceVacuum τ ω)∈closure + {x : boundedSubspace τ ω | ∃ a : ℕ →ᵇ B, ‖a‖≤1 ∧ vectorIn τ ω (mapSequence j a)=x} := by + apply Metric.mem_closure_iff.mpr + intro ε hε + obtain ⟨a,_,hna,ha⟩ := Kaplansky.range_selfAdjoint_contraction_finite_approx + Unit φ hT hsT hnT (fun _ => sequenceVacuum τ ω) ε hε + refine ⟨vectorIn τ ω (mapSequence j a),⟨a,hna,rfl⟩,?_⟩ + simpa only [dist_eq_norm,norm_sub_rev,φ,StarAlgHom.comp_apply,leftRestricted_vacuum] using ha () + rw [(relative_vector_unitball_isClosed τ ω j hω).closure_eq] at hx + obtain ⟨a,hna,ha⟩ := hx + refine ⟨a,hna,bicommutant_eq_of_vacuum τ ω hτ _ _ ?_ + (relative_bicommutant_natural τ ω j hT) ?_⟩ + · exact Set.subset_centralizer_centralizer (Set.mem_range_self (mapSequence j a)) + · simpa only [leftRestricted_vacuum] using ha + +include hτ in +lemma relative_range_bicommutant (hω : (ω : Filter ℕ)≤atTop) : + Set.centralizer (Set.centralizer (Set.range ((leftRestricted τ ω).comp (mapSequence j))))= + Set.range ((leftRestricted τ ω).comp (mapSequence j)) := by + exact BicommutantRange.operatorHom_range + ((leftRestricted τ ω).comp (mapSequence j)) fun T hT hsT hnT => + let h := relative_bicommutant_contraction τ ω j hτ hω hT hsT hnT + ⟨h.choose, h.choose_spec.2⟩ + +def relativeUltrapower (hω : (ω : Filter ℕ)≤atTop) : VonNeumannAlgebra (boundedSubspace τ ω) := + BicommutantRange.ofStarHom ((leftRestricted τ ω).comp (mapSequence j)) + (relative_range_bicommutant τ ω j hτ hω) + +end Kadison.TracialSequence + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RelativeTowerFreePosition.lean b/lean/OAI/Analysis/Commutator/RelativeTowerFreePosition.lean new file mode 100644 index 0000000000000000000000000000000000000000..49ecbe8123b40b24aa30b3614947856b61031eee --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RelativeTowerFreePosition.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Commutator.AllUnitaryTests +import OAI.Analysis.Commutator.FreeCornerFromUnitary +import OAI.Analysis.Commutator.FreeSequenceUnitary + +namespace OAI + +noncomputable section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator Topology + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching FinitePatching.ConjugatedWords + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R≤M) + +variable (τ : M →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (size : ℕ → ℕ) + +variable (stage : ∀ n,Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] M) + +variable (inc : ∀ {n m : ℕ},n ≤ m → Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] + Matrix (Fin (size m+1)) (Fin (size m+1)) ℂ) + +theorem exists_freeCornerPosition_of_relative_tower [TopologicalSpace.SeparableSpace τ.GNS] + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M,(∀ n (a : Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ), + stage n a*b=b*stage n a) → ∃ c : ℂ,b=algebraMap ℂ M c) + (hstage : ∀ n a,(stage n a : H →L[ℂ] H)∈R) + (hinc : ∀ n m (h : n ≤ m) a,stage m (inc h a)=stage n a) + (hgrow : Tendsto (fun n => (size n+1:ℝ)) atTop atTop) + (hdiffuse : DiffuseProjection.HasNoMinimalProjections R) : + Nonempty (FreeCornerPosition τ ω R (NormalSubalgebra.inclusion M R hRM)) := by + have hmono : ∀ {n m : ℕ},n ≤ m → (stage n).range≤(stage m).range := by + intro n m h a ha + obtain ⟨b,rfl⟩ := ha + exact ⟨inc h b,hinc n m h b⟩ + obtain ⟨u,huR,_,huword⟩ := exists_all_unitary_tests M R hRM τ hτ stage hmono + hnormal hfaith hone hirr (by simpa only [Fintype.card_fin,Nat.cast_add,Nat.cast_one] using hgrow) + hstage hdiffuse + refine freeCornerPosition_of_unitary M R hRM τ ω size stage inc hτ hω hnormal hfaith hone hirr + hstage hinc ?_ (sequenceUnitary τ ω u) (sequenceUnitary_in_relative_range M R hRM τ ω u huR) ?_ + · intro n q + have he := (tendsto_atTop.1 hgrow) (q:ℝ) + obtain ⟨m,hmn,hm⟩ := (he.and (eventually_ge_atTop n)).exists + exact ⟨m,hm,by exact_mod_cast hmn⟩ + · apply sequenceUnitary_free τ ω hτ hω u + intro J x hx hxc l hl hv + exact huword J Bool x signPower hx hxc (by intro b; cases b <;> norm_num [signPower]) l hl hv + +end Kadison.TracialSequence +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ReplicaPacking.lean b/lean/OAI/Analysis/Commutator/ReplicaPacking.lean new file mode 100644 index 0000000000000000000000000000000000000000..a38ee25e9b1cea1160174724e139aa96394da4ca --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ReplicaPacking.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialDecomposition +import OAI.Analysis.Commutator.ProperIsometryReplicas +import OAI.Analysis.Commutator.WeakOperatorLimit +import OAI.Analysis.Commutator.WeakOperatorAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +open Filter + +namespace Kadison.PartialIsometryOrder + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +namespace PartialDecomposition + +variable {M : VonNeumannAlgebra H} {r : H →L[ℂ] H} + +variable (D : PartialDecomposition M r) (R : Replicas M r) (hr : IsStarProjection r) + +def finitePacking (f : D.I → ℕ) (s : Finset D.I) : H →L[ℂ] H := + ∑ i∈s,R.a (f i)*star (D.v i).val + +include hr in +lemma finitePacking_star_mul (f : D.I → ℕ) (hf : Function.Injective f) (s : Finset D.I) : + star (D.finitePacking R f s)*D.finitePacking R f s=D.support s := by + classical + rw [finitePacking,star_sum,Finset.sum_mul,support] + apply Finset.sum_congr rfl + intro i hi + rw [Finset.mul_sum,Finset.sum_eq_single_of_mem i hi] + · simp only [star_mul,star_star] + calc + _=((D.v i).val*(star (R.a (f i))*R.a (f i)))*star (D.v i).val := by noncomm_ring + _=(D.v i).final := by rw [R.initial,(D.v i).mul_source hr]; rfl + · intro j hj hne + simp only [star_mul,star_star] + calc + _=((D.v i).val*(star (R.a (f i))*R.a (f j)))*star (D.v j).val := by noncomm_ring + _=0 := by rw [R.cross (f i) (f j) (fun h => hne (hf h).symm),mul_zero,zero_mul] + +include hr in +lemma finitePacking_norm_le (f : D.I → ℕ) (hf : Function.Injective f) (s : Finset D.I) : + ‖D.finitePacking R f s‖≤1 := by + have he := D.support_norm_le s + rw [←D.finitePacking_star_mul R hr f hf s,CStarRing.norm_star_mul_self] at he + nlinarith [norm_nonneg (D.finitePacking R f s)] + +lemma finitePacking_mul_val (f : D.I → ℕ) (s : Finset D.I) {i : D.I} (hi : i∈s) : + D.finitePacking R f s*(D.v i).val=R.a (f i)*(D.v i).initial := by + classical + rw [finitePacking,Finset.sum_mul,Finset.sum_eq_single_of_mem i hi,mul_assoc] + · rfl + · intro j hj hne + rw [mul_assoc,D.cross j i hne,mul_zero] + +include hr in +theorem exists_packing (f : D.I → ℕ) (hf : Function.Injective f) : + ∃ W : H →L[ℂ] H,W∈M ∧ ∀ i,W*(D.v i).val=R.a (f i)*(D.v i).initial := by + classical + let ω : Ultrafilter (Finset D.I) := Ultrafilter.of atTop + have hω : (ω : Filter (Finset D.I))≤atTop := Ultrafilter.of_le _ + obtain ⟨W,hW,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω (D.finitePacking R f) 1 + (by norm_num) (D.finitePacking_norm_le R hr f hf) + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hlim M + (Eventually.of_forall fun s => M.sum_mem (fun i _ => + M.mul_mem (R.mem (f i)) (M.star_mem' (D.v i).mem))) + refine ⟨W,hWM,?_⟩ + intro i + apply WeakOperatorLimit.right_eq hlim (D.v i).val (R.a (f i)*(D.v i).initial) + filter_upwards [hω (eventually_ge_atTop ({i}:Finset D.I))] with s hs + exact D.finitePacking_mul_val R f s (i:=i) (hs (Finset.mem_singleton_self i)) + +include hr in +lemma packing_isometry (f : D.I → ℕ) (hf : Function.Injective f) + {W : H →L[ℂ] H} (hW : ∀ i,W*(D.v i).val=R.a (f i)*(D.v i).initial) : star W*W=1 := by + apply D.eq_of_coefficients_eq + intro i j + calc + star (D.v i).val*(star W*W)*(D.v j).val=star (W*(D.v i).val)*(W*(D.v j).val) := by + rw [star_mul]; noncomm_ring + _=star (R.a (f i)*(D.v i).initial)*(R.a (f j)*(D.v j).initial) := by rw [hW i,hW j] + _=star (D.v i).val*(D.v j).val := by + rw [star_mul,(D.v i).initial_projection.isSelfAdjoint.star_eq] + rw [show (D.v i).initial*star (R.a (f i))*(R.a (f j)*(D.v j).initial)= + (D.v i).initial*(star (R.a (f i))*R.a (f j))*(D.v j).initial by noncomm_ring] + by_cases hij : i=j + · subst j + rw [R.initial,((D.v i).initial_projection.le_iff_mul_eq_left hr).mp (D.v i).source_le, + (D.v i).initial_projection.isIdempotentElem.eq] + rfl + · rw [R.cross (f i) (f j) (fun h => hij (hf h)),mul_zero,zero_mul,D.cross i j hij] + _=star (D.v i).val*1*(D.v j).val := by rw [mul_one] + +lemma packings_orthogonal (f g : D.I → ℕ) (hfg : ∀ i j,f i≠g j) + {W V : H →L[ℂ] H} (hW : ∀ i,W*(D.v i).val=R.a (f i)*(D.v i).initial) + (hV : ∀ i,V*(D.v i).val=R.a (g i)*(D.v i).initial) : star W*V=0 := by + apply D.eq_zero_of_coefficients_zero + intro i j + calc + _=star (W*(D.v i).val)*(V*(D.v j).val) := by rw [star_mul]; noncomm_ring + _=star (R.a (f i)*(D.v i).initial)*(R.a (g j)*(D.v j).initial) := by rw [hW i,hV j] + _=star (D.v i).initial*(star (R.a (f i))*R.a (g j))*(D.v j).initial := by + rw [star_mul]; noncomm_ring + _=0 := by rw [R.cross _ _ (hfg i j),mul_zero,zero_mul] + +end PartialDecomposition + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentationFieldTests.lean b/lean/OAI/Analysis/Commutator/RepresentationFieldTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..47c485dcd1f381157e150609c2f0684b3f1d9ca1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentationFieldTests.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Commutator.CountableStarHomTests +import OAI.Analysis.Commutator.DecomposableOperator +import OAI.Analysis.Commutator.MatrixTowerGNS + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology + +namespace Kadison.Decomposable + +variable {Ω H A : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] + [TopologicalSpace.SeparableSpace (Lp H 2 μ)] + [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [TopologicalSpace.SeparableSpace A] + +omit [IsFiniteMeasure μ] in +theorem exists_common_tests + (ρ : A →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (σ : Ω → A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hm : ∀ a ξ,AEStronglyMeasurable (fun x => σ x a ξ) μ) + (hact : ∀ a (f : Lp H 2 μ),ρ a f =ᵐ[μ] fun x => σ x a (f x)) : + ∃ (test : ℕ → Ω → H →L[ℂ] H) + (ht : ∀ n ξ,AEStronglyMeasurable (fun x => test n x ξ) μ) + (hb : ∀ n,∀ᵐ x ∂μ,‖test n x‖≤1), + (∀ n,operator μ (test n) (ht n) (hb n)∈NormalGNS.bicommutant ρ.range) ∧ + (∀ n,∀ᵐ x ∂μ,test n x∈NormalGNS.bicommutant (σ x).range) ∧ + (∀ᵐ x ∂μ,∀ T : H →L[ℂ] H,T∈NormalGNS.bicommutant (σ x).range → ‖T‖≤1 → + ∃ k : ℕ → ℕ,∀ ξ,Tendsto (fun n => test (k n) x ξ) atTop (𝓝 (T ξ))) ∧ + (∀ T : Lp H 2 μ →L[ℂ] Lp H 2 μ,T∈NormalGNS.bicommutant ρ.range → ‖T‖≤1 → + ∃ k : ℕ → ℕ,∀ f,Tendsto + (fun n => operator μ (test (k n)) (ht (k n)) (hb (k n)) f) atTop (𝓝 (T f))) := by + let test : ℕ → Ω → H →L[ℂ] H := fun n x => σ x (countableContractions (A:=A) n) + have ht : ∀ n ξ,AEStronglyMeasurable (fun x => test n x ξ) μ := + fun n ξ => hm _ ξ + have hb : ∀ n,∀ᵐ x ∂μ,‖test n x‖≤1 := fun n => Eventually.of_forall (fun x => + (NonUnitalStarAlgHom.norm_apply_le (σ x) _).trans (countableContractions_norm n)) + have he (n : ℕ) : operator μ (test n) (ht n) (hb n)=ρ (countableContractions (A:=A) n) := by + apply ContinuousLinearMap.ext + intro f + apply Lp.ext + exact (operator_ae μ (test n) (ht n) (hb n) f).trans (hact _ f).symm + refine ⟨test,ht,hb,?_,?_,?_,?_⟩ + · intro n + rw [he] + exact NormalGNS.subset_bicommutant ρ.range ⟨_,rfl⟩ + · intro n + exact Eventually.of_forall (fun x => NormalGNS.subset_bicommutant (σ x).range ⟨_,rfl⟩) + · apply Eventually.of_forall + intro x T hT hn + exact countableContractions_strong_dense (σ x) T + ((NormalGNS.mem_bicommutant _ _).mp hT) hn + · intro T hT hn + obtain ⟨k,hk⟩ := countableContractions_strong_dense ρ T + ((NormalGNS.mem_bicommutant _ _).mp hT) hn + refine ⟨k,?_⟩ + intro f + simpa only [he] using hk f + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentationMatrixNorm.lean b/lean/OAI/Analysis/Commutator/RepresentationMatrixNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..903ec3439d1395549582e353387c5ba70cbaa203 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentationMatrixNorm.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.Definitions +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +lemma matrixOperator_representation (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (h : ℕ) + (X : Matrix (Fin h) (Fin h) A) : + matrixOperator h (fun i j => φ (X i j))= + CyclicColumns.matrixRepresentation φ (CStarMatrix.ofMatrix X) := rfl + +lemma matrixOperator_representation_norm_le (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hφ : Function.Injective φ) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) (h : ℕ) + (X : Matrix (Fin h) (Fin h) A) : + ‖matrixOperator h (fun i j => ψ (X i j))‖≤‖matrixOperator h (fun i j => φ (X i j))‖ := by + rw [matrixOperator_representation,matrixOperator_representation, + CyclicSpatial.matrixRepresentation_norm_eq φ hφ] + exact CyclicColumns.matrixRepresentation_norm_le ψ _ + +lemma matrixOperator_subtype_norm_le (M : VonNeumannAlgebra H) + (ψ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) (h : ℕ) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈M) : + ‖matrixOperator h (fun i j => ψ ⟨X i j,hX i j⟩)‖≤‖matrixOperator h X‖ := + matrixOperator_representation_norm_le (A:=M) (H:=H) (G:=G) + M.toStarSubalgebra.subtype Subtype.val_injective ψ h (fun i j => ⟨X i j,hX i j⟩) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentedCornerBound.lean b/lean/OAI/Analysis/Commutator/RepresentedCornerBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..f1be4e92ff7907364784149d64b54db7a627c299 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentedCornerBound.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialGNSCorners +import OAI.Analysis.Commutator.VectorFreeGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.VectorGNS + +open FreeWordTensor FreeMoments FreeWordAction FreeBlocks + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (ξ : H) + (htr : ∀ a b : M,subalgebraTrace M ξ (a*b)=subalgebraTrace M ξ (b*a)) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + +variable (D : VonNeumannAlgebra H) (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + (R : Bool → StarSubalgebra ℂ M) + +lemma inclusion_projection (q : D) (hq : IsStarProjection (inclusion M D hDM q)) : + IsStarProjection (q:H →L[ℂ] H) := + hq.map M.toStarSubalgebra.subtype + +def RepresentedCornerBound (U : H →L[ℂ] H) (c : ℝ) (β : ℂ) : Prop := + ∀ q : D,IsStarProjection (q:H →L[ℂ] H) → + subalgebraTrace D ξ q=β → ∀ a : M, + (q:H →L[ℂ] H)*a*q=a → + ‖U*(a:H →L[ℂ] H)-(a:H →L[ℂ] H)*U‖≤c*‖a‖ + +include htr in +lemma represented_corner_bound (U : H →L[ℂ] H) (c : ℝ) (β : ℂ) + (hb : RepresentedCornerBound M ξ D U c β) : + CornerCommutatorBound (D:=D) M ξ hfaith hone (inclusion M D hDM) R U c β := by + apply corner_bound M ξ htr hfaith hone (inclusion M D hDM) R U c β + intro q hq hqt a hl hr + exact hb q (inclusion_projection M D hDM q hq) hqt a + (subtype_corner M (inclusion M D hDM q) a hl hr) + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentedFactorTransport.lean b/lean/OAI/Analysis/Commutator/RepresentedFactorTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..c794cc7ad3be2d56ff737696d1e7257201cd5be4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentedFactorTransport.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +namespace Kadison.FactorCorner + +variable {H G : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +variable (M : VonNeumannAlgebra H) + +lemma commutant_factor (hM : IsFactor M) : IsFactor M.commutant := by + intro z hz hzc + have hzM : z∈M := by + have hc : z∈M.commutant.commutant := by + rw [←SetLike.mem_coe,VonNeumannAlgebra.coe_commutant] + exact hzc + simpa only [VonNeumannAlgebra.commutant_commutant] using hc + apply hM z hzM + simpa only [←SetLike.mem_coe,VonNeumannAlgebra.coe_commutant] using hz + +lemma image_factor (hM : IsFactor M) (φ : M →⋆ₐ[ℂ] (G →L[ℂ] G)) + (hinj : Function.Injective φ) + (hclosed : Set.centralizer (Set.centralizer (Set.range φ))=Set.range φ) : + IsFactor (BicommutantRange.ofStarHom φ hclosed) := by + intro z hz hzc + obtain ⟨a,rfl⟩ := hz + have hac : (a:H →L[ℂ] H)∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + intro b hb + have he : (⟨b,hb⟩:M)*a=a*⟨b,hb⟩ := by + apply hinj + simp only [map_mul] + exact hzc _ (Set.mem_range_self (⟨b,hb⟩:M)) + exact congrArg (fun c : M => (c:H →L[ℂ] H)) he + obtain ⟨c,hc⟩ := hM a a.property hac + have ha : a=c • (1:M) := Subtype.ext hc + refine ⟨c,?_⟩ + change φ a=c • 1 + rw [ha,map_smul,map_one] + +end Kadison.FactorCorner + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentedLocalModule.lean b/lean/OAI/Analysis/Commutator/RepresentedLocalModule.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0e898c7e649f9775c886f551d048b7ea6815992 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentedLocalModule.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicLocalModule + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.MatrixCornerImplementation + +open ConcreteCorner + +variable {A H ι : Type*} [CStarAlgebra A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [Fintype ι] [DecidableEq ι] + +variable (L : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (M : VonNeumannAlgebra H) + (hM : ∀ a : A, L a∈M) + +include hM in +lemma cyclicSubspace_le_ambient (ξ : H) : + cyclicSubspace L.range ξ≤cyclicSubspace M.toStarSubalgebra ξ := by + apply Submodule.topologicalClosure_mono + rintro y ⟨a,⟨b,rfl⟩,rfl⟩ + exact ⟨L b,hM b,rfl⟩ + +include hM in +theorem exists_represented_local_module {p : A} (hp : IsStarProjection p) + (v : ι → A) + (hcol : ∀ i j, star (v i)*v j=if i=j then p else 0) + (hinit : ∀ i, p*star (v i)=star (v i)) + (htotal : ∑ i, v i*star (v i)=1) + (G : H →L[ℂ] H) + (hGp : G.comp (L p)=(L p).comp G) + (hGv : ∀ i, G.comp (L (v i))=(L (v i)).comp G) + (ξ : H) (hpξ : L p ξ=ξ) + {ε : ℝ} (hε : 0≤ε) + (hδ : ∀ a : H →L[ℂ] H, a∈M → L p*a=a → a*L p=a → + ‖G.comp a-a.comp G‖≤ε*‖a‖) : + ∃ T : H →L[ℂ] H, (∀ a : A, T.comp (L a)=(L a).comp T) ∧ + ∀ z∈cyclicSubspace L.range ξ, ‖G z-T z‖≤(16*ε)*‖z‖ := by + let f : A →⋆ₐ[ℂ] Algebra M := L.codRestrict M.toStarSubalgebra hM + have hc (i j : ι) : star (f (v i))*f (v j)=if i=j then f p else 0 := by + simpa only [map_mul,map_star,apply_ite,map_zero] using congrArg f (hcol i j) + have hi (i : ι) : f p*star (f (v i))=star (f (v i)) := by + simpa only [map_mul,map_star] using congrArg f (hinit i) + have ht : ∑ i, f (v i)*star (f (v i))=1 := by + simpa only [map_sum,map_mul,map_star,map_one] using congrArg f htotal + have hb (a : Corner (hp.map f)) : + ‖G.comp (inclusion M (a:Algebra M))-(inclusion M (a:Algebra M)).comp G‖≤ε*‖a‖ := by + exact hδ ((a:Algebra M):H →L[ℂ] H) (a:Algebra M).property + (congrArg (fun b : Algebra M => (b:H →L[ℂ] H)) a.property.1) + (congrArg (fun b : Algebra M => (b:H →L[ℂ] H)) a.property.2) + obtain ⟨T,hT,hn⟩ := exists_local_module M (hp.map f) (fun i => f (v i)) hc hi ht + G hGp hGv ξ hpξ hε hb + exact ⟨T,fun a => hT (f a),fun z hz => hn z (cyclicSubspace_le_ambient L M hM ξ hz)⟩ + +end Kadison.MatrixCornerImplementation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RepresentedTowerAverage.lean b/lean/OAI/Analysis/Commutator/RepresentedTowerAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..84c1dd8823d0145a0ee58b9bc09c2aa409c80d38 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RepresentedTowerAverage.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.Average +import OAI.Analysis.Commutator.CompactAverage +import OAI.Analysis.Commutator.UnitaryHaar +import OAI.Analysis.Commutator.WeakConvergence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Matrix.Norms.L2Operator Topology + +open MeasureTheory Filter + +namespace Kadison.RepresentedTower + +variable {A K : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (ρ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + +def unitaryRepresentation : unitary A →* (K ≃ₗᵢ[ℂ] K) := + Unitary.linearIsometryEquiv.toMonoidHom.comp + { toFun := fun u => ⟨ρ (u:A),Unitary.map_mem ρ u.property⟩ + map_one' := Subtype.ext (map_one ρ) + map_mul' u v := Subtype.ext (map_mul ρ (u:A) (v:A)) } + +lemma conjugate_distance (Y : K →L[ℂ] K) (u : unitary A) : + ‖CompactAverage.conjugate (unitaryRepresentation ρ) Y u-Y‖=‖Y*ρ (u:A)-ρ (u:A)*Y‖ := by + let w : unitary (K →L[ℂ] K) := ⟨ρ (u:A),Unitary.map_mem ρ u.property⟩ + have he : CompactAverage.conjugate (unitaryRepresentation ρ) Y u-Y= + ((w:K →L[ℂ] K)*Y-Y*(w:K →L[ℂ] K))*star (w:K →L[ℂ] K) := by + change (w:K →L[ℂ] K)*Y*star (w:K →L[ℂ] K)-Y=_ + rw [sub_mul,mul_assoc Y (w:K →L[ℂ] K) (star (w:K →L[ℂ] K)),w.property.2,mul_one] + rw [he,CStarRing.norm_mul_mem_unitary _ (Unitary.star_mem w.property),norm_sub_rev] + +variable (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] [∀ n,Nonempty (I n)] + +variable (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + +def stageUnitaryMap (n : ℕ) : unitary (Matrix (I n) (I n) ℂ) →* unitary A where + toFun u := ⟨φ n (u : Matrix (I n) (I n) ℂ),Unitary.map_mem (φ n) u.property⟩ + map_one' := Subtype.ext (map_one (φ n)) + map_mul' u v := Subtype.ext (map_mul (φ n) (u:Matrix (I n) (I n) ℂ) (v:Matrix (I n) (I n) ℂ)) + +def stageUnitaryRepresentation (n : ℕ) : unitary (Matrix (I n) (I n) ℂ) →* (K ≃ₗᵢ[ℂ] K) := + (unitaryRepresentation ρ).comp (stageUnitaryMap I φ n) + +omit [∀ (n : ℕ), Nonempty (I n)] in +lemma stageUnitary_continuous (n : ℕ) (x : K) : + Continuous fun u => stageUnitaryRepresentation ρ I φ n u x := by + change Continuous fun u : unitary (Matrix (I n) (I n) ℂ) => ρ (φ n (u:_)) x + exact (((ρ.comp (φ n)).toLinearMap.continuous_of_finiteDimensional).comp + continuous_subtype_val).clm_apply continuous_const + +lemma exists_stage_average (Y : K →L[ℂ] K) {δ : ℝ} (hδ : 0≤δ) + (hb : ∀ u : unitary A,‖Y*ρ (u:A)-ρ (u:A)*Y‖≤δ) (n : ℕ) : + ∃ Z : K →L[ℂ] K,‖Z‖≤‖Y‖ ∧ ‖Z-Y‖≤δ ∧ + ∀ a,Z*ρ (φ n a)=ρ (φ n a)*Z := by + classical + let := UnitaryHaar.compactUnitary (Matrix (I n) (I n) ℂ) + let : MeasurableSpace (unitary (Matrix (I n) (I n) ℂ)) := borel _ + let : BorelSpace (unitary (Matrix (I n) (I n) ℂ)) := ⟨rfl⟩ + let U := stageUnitaryRepresentation ρ I φ n + let μ := UnitaryHaar.probability (unitary (Matrix (I n) (I n) ℂ)) + obtain ⟨Z,hZ,hcomm,hcoeff⟩ := CompactAverage.exists_average U (stageUnitary_continuous ρ I φ n) Y μ + refine ⟨Z,hZ,?_,?_⟩ + · apply WeakOperatorIntegral.difference_norm μ (CompactAverage.conjugate U Y) _ Z hcoeff Y hδ + · intro u + exact (conjugate_distance ρ Y (stageUnitaryMap I φ n u)).le.trans (hb _) + · intro x y + exact ((CompactAverage.conjugate_continuous U (stageUnitary_continuous ρ I φ n) Y x).inner + continuous_const).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _) + · let D : Matrix (I n) (I n) ℂ →ₗ[ℂ] (K →L[ℂ] K) := + { toFun := fun a => Z*ρ (φ n a)-ρ (φ n a)*Z + map_add' := by intro a b; simp only [map_add,mul_add,add_mul]; abel + map_smul' := by intro z a; simp only [map_smul,mul_smul_comm,smul_mul_assoc,smul_sub]; rfl } + have hD : D=0 := by + apply LinearMap.ext_on (CStarAlgebra.span_unitary (Matrix (I n) (I n) ℂ)) + intro u hu + exact sub_eq_zero.mpr (hcomm ⟨u,hu⟩) + intro a + exact sub_eq_zero.mp (congrArg (fun D : Matrix (I n) (I n) ℂ →ₗ[ℂ] (K →L[ℂ] K) => D a) hD) + +theorem exists_tower_average (hφ : Monotone (fun n => (φ n).range)) + (Y : K →L[ℂ] K) {δ : ℝ} (hδ : 0≤δ) + (hb : ∀ u : unitary A,‖Y*ρ (u:A)-ρ (u:A)*Y‖≤δ) : + ∃ Z : K →L[ℂ] K,‖Z‖≤‖Y‖ ∧ ‖Z-Y‖≤δ ∧ + ∀ a : K →L[ℂ] K,a∈Set.centralizer (Set.centralizer + ((iSup fun n => (ρ.comp (φ n)).range : StarSubalgebra ℂ (K →L[ℂ] K)) : Set (K →L[ℂ] K))) → Z*a=a*Z := by + choose T hn hd hc using exists_stage_average ρ I φ Y hδ hb + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + obtain ⟨Z,hZ,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω T ‖Y‖ (norm_nonneg Y) hn + have hconv : WeakOperatorLimit.Converges T Z (ω:Filter ℕ) := hlim + refine ⟨Z,hZ,hconv.dist Y hδ (Eventually.of_forall hd),?_⟩ + have hstage (n : ℕ) (a : Matrix (I n) (I n) ℂ) : Z*ρ (φ n a)=ρ (φ n a)*Z := by + apply hconv.commutes + apply (Ultrafilter.of_le atTop) + filter_upwards [eventually_ge_atTop n] with m hm + obtain ⟨b,hb⟩ := hφ hm (show φ n a∈(φ n).range from ⟨a,rfl⟩) + rw [←hb] + exact hc m b + have hcent : Z∈Set.centralizer ((iSup fun n => (ρ.comp (φ n)).range : StarSubalgebra ℂ (K →L[ℂ] K)) : Set (K →L[ℂ] K)) := by + have hcomm : (iSup fun n => (ρ.comp (φ n)).range)≤StarSubalgebra.centralizer ℂ ({Z} : Set (K →L[ℂ] K)) := by + apply iSup_le + intro n + rintro a ⟨b,rfl⟩ + rw [StarSubalgebra.mem_centralizer_iff] + intro z hz + have he : z=Z := Set.mem_singleton_iff.mp hz + subst z + constructor + · exact hstage n b + · have hh := congrArg star (hstage n (star b)) + simpa only [star_mul,←map_star,star_star] using! hh.symm + intro a ha + exact (((StarSubalgebra.mem_centralizer_iff ℂ).mp (hcomm ha)) Z (Set.mem_singleton Z)).1.symm + intro a ha + exact ha Z hcent + +end Kadison.RepresentedTower + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RightCopies.lean b/lean/OAI/Analysis/Commutator/RightCopies.lean new file mode 100644 index 0000000000000000000000000000000000000000..275043964da10e78611924c53a0523c53380d306 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RightCopies.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertPadding + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.HilbertPadding + +open OperatorAmplification CyclicColumns + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι κ : Type*) [Fintype ι] [Fintype κ] + +local instance rightCopiesSourceDecidableEq : DecidableEq ι := Classical.decEq ι + +local instance rightCopiesPaddingDecidableEq : DecidableEq κ := Classical.decEq κ + +def rightCopies : SumSpace (H:=H) ι →ₗᵢ[ℂ] SumSpace (H:=H) (κ⊕ι) where + toFun v := WithLp.toLp 2 (Sum.elim (fun _ => 0) (fun i => v i)) + map_add' v w := by ext i; cases i <;> simp + map_smul' z v := by ext i; cases i <;> simp + norm_map' v := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + simp [PiLp.norm_sq_eq_of_L2,Fintype.sum_sum_type] + +omit [CompleteSpace H] in +@[simp] lemma rightCopies_inl (v : SumSpace (H:=H) ι) (k : κ) : + rightCopies ι κ v (Sum.inl k)=0 := rfl + +omit [CompleteSpace H] in +@[simp] lemma rightCopies_inr (v : SumSpace (H:=H) ι) (i : ι) : + rightCopies ι κ v (Sum.inr i)=v i := rfl + +lemma rightCopies_diagonal (a : H →L[ℂ] H) : + (diagonal (H:=H) (κ⊕ι) a).comp (rightCopies (H:=H) ι κ).toContinuousLinearMap= + (rightCopies (H:=H) ι κ).toContinuousLinearMap.comp (diagonal (H:=H) ι a) := by + ext v i + cases i <;> simp + +lemma rightCopies_adjoint_diagonal (a : H →L[ℂ] H) : + (rightCopies (H:=H) ι κ).toContinuousLinearMap.adjoint.comp (diagonal (H:=H) (κ⊕ι) a)= + (diagonal (H:=H) ι a).comp (rightCopies (H:=H) ι κ).toContinuousLinearMap.adjoint := by + have h := congrArg (fun T => T.adjoint) (rightCopies_diagonal ι κ (star a)) + simpa only [adjoint_comp,←star_eq_adjoint,←map_star,star_star] using h + +lemma rightCopies_commutator_norm + (Y : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι) (a : H →L[ℂ] H) : + ‖extend (rightCopies ι κ) Y*diagonal (H:=H) (κ⊕ι) a- + diagonal (H:=H) (κ⊕ι) a*extend (rightCopies ι κ) Y‖= + ‖Y*diagonal (H:=H) ι a-diagonal (H:=H) ι a*Y‖ := + norm_extend_commutator _ _ _ _ (rightCopies_diagonal ι κ a) (rightCopies_adjoint_diagonal ι κ a) + +end Kadison.HilbertPadding + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/RowOperator.lean b/lean/OAI/Analysis/Commutator/RowOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd761cf858572b681e9cab46cd1833123468a025 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/RowOperator.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixEntryWOT + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +namespace Kadison.OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (ι : Type*) [Fintype ι] [DecidableEq ι] + +def position (i j : ι) (a : H →L[ℂ] H) : SumSpace (H:=H) ι →L[ℂ] SumSpace (H:=H) ι := + (single ι i).comp (a.comp (PiLp.proj 2 (fun _ : ι => H) j)) + +omit [CompleteSpace H] [Fintype ι] in +@[simp] lemma position_apply (i j : ι) (a : H →L[ℂ] H) (v : SumSpace (H:=H) ι) : + position ι i j a v=single ι i (a (v j)) := rfl + +omit [CompleteSpace H] in +lemma norm_position_le (i j : ι) (a : H →L[ℂ] H) : ‖position ι i j a‖≤‖a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg a) + intro v + rw [position_apply,norm_single_eq] + exact (a.le_opNorm _).trans (mul_le_mul_of_nonneg_left (PiLp.norm_apply_le v j) (norm_nonneg a)) + +omit [CompleteSpace H] [Fintype ι] in +lemma entry_position (i j : ι) (a : H →L[ℂ] H) : + entry ι (position ι i j a) i j=a := by + ext x + simp + +omit [CompleteSpace H] in +lemma norm_position (i j : ι) (a : H →L[ℂ] H) : ‖position ι i j a‖=‖a‖ := by + apply le_antisymm (norm_position_le ι i j a) + simpa only [entry_position] using norm_entry_le ι (position ι i j a) i j + +lemma diagonal_commutator_position (T a : H →L[ℂ] H) (i j : ι) : + diagonal (H:=H) ι T*position ι i j a-position ι i j a*diagonal (H:=H) ι T= + position ι i j (T*a-a*T) := by + ext v k + simp only [sub_apply,mul_apply_eq_comp,position_apply,diagonal_single, + diagonal_apply] + simp only [single_apply] + by_cases h : k=i <;> simp [h] + +lemma norm_diagonal_commutator_position (T a : H →L[ℂ] H) (i j : ι) : + ‖diagonal (H:=H) ι T*position ι i j a-position ι i j a*diagonal (H:=H) ι T‖=‖T*a-a*T‖ := by + rw [diagonal_commutator_position,norm_position] + +end Kadison.OperatorAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ScalarField.lean b/lean/OAI/Analysis/Commutator/ScalarField.lean new file mode 100644 index 0000000000000000000000000000000000000000..b261f0872f876811c334b7a9eb127398146458ec --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ScalarField.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableOperator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma smul_measurable (z : ℂ) (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) : + ∀ ξ,AEStronglyMeasurable (fun a => (z • T a) ξ) μ := fun ξ => (hm ξ).const_smul z + +lemma smul_field_bound (z : ℂ) (T : Ω → H →L[ℂ] H) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : ∀ᵐ a ∂μ,‖z • T a‖≤‖z‖*b := by + filter_upwards [hb] with a ha + rw [norm_smul] + exact mul_le_mul_of_nonneg_left ha (norm_nonneg z) + +lemma operator_smul (z : ℂ) (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : + operator μ (fun a => z • T a) (smul_measurable μ z T hm) + (smul_field_bound μ z T hb)=z • operator μ T hm hb := by + apply ContinuousLinearMap.ext + intro f + apply Lp.ext + filter_upwards [operator_ae μ (fun a => z • T a) (smul_measurable μ z T hm) + (smul_field_bound μ z T hb) f,operator_ae μ T hm hb f, + Lp.coeFn_smul z (operator μ T hm hb f)] with a h1 h2 h3 + change operator μ (fun a => z • T a) (smul_measurable μ z T hm) + (smul_field_bound μ z T hb) f a=(z • operator μ T hm hb f) a + rw [h1,h3] + change z • T a (f a)=z • operator μ T hm hb f a + rw [h2] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ScalarIndicator.lean b/lean/OAI/Analysis/Commutator/ScalarIndicator.lean new file mode 100644 index 0000000000000000000000000000000000000000..d7ff74291a59cd64923c7add0d04e76e4d8ca53b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ScalarIndicator.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableNorm + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +lemma indicator_measurable (s : Set Ω) (hs : MeasurableSet s) (ξ : H) : + AEStronglyMeasurable (fun a => (s.indicator (fun _ => (1:H →L[ℂ] H)) a) ξ) μ := by + classical + convert (aestronglyMeasurable_const (b:=ξ)).indicator hs using 1 + ext a + by_cases ha : a∈s <;> simp [ha] + +lemma indicator_bound (s : Set Ω) : + ∀ᵐ a ∂μ,‖s.indicator (fun _ => (1:H →L[ℂ] H)) a‖≤1 := by + classical + apply Eventually.of_forall + intro a + by_cases ha : a∈s + · simp only [Set.indicator_of_mem ha] + exact ContinuousLinearMap.norm_id_le + · simp [ha] + +def indicatorOperator (s : Set Ω) (hs : MeasurableSet s) : Lp H 2 μ →L[ℂ] Lp H 2 μ := + operator μ (s.indicator (fun _ => (1:H →L[ℂ] H))) + (indicator_measurable μ s hs) (indicator_bound μ s) + +lemma indicatorOperator_ae (s : Set Ω) (hs : MeasurableSet s) (f : Lp H 2 μ) : + indicatorOperator μ s hs f =ᵐ[μ] s.indicator f := by + classical + filter_upwards [operator_ae μ _ (indicator_measurable μ s hs) (indicator_bound μ s) f] with a ha + change indicatorOperator μ s hs f a=_ at ha ⊢ + rw [ha] + by_cases hx : a∈s <;> simp [hx] + +lemma indicatorOperator_norm_sq (s : Set Ω) (hs : MeasurableSet s) (f : Lp H 2 μ) : + ‖indicatorOperator μ s hs f‖^2=∫ a in s,‖f a‖^2 ∂μ := by + classical + rw [l2_norm_sq,←integral_indicator hs] + apply integral_congr_ae + filter_upwards [indicatorOperator_ae μ s hs f] with a ha + rw [ha] + by_cases hx : a∈s <;> simp [hx] + +variable [IsFiniteMeasure μ] + +lemma indicatorOperator_const (s : Set Ω) (hs : MeasurableSet s) (ξ : H) : + indicatorOperator μ s hs (Lp.const 2 μ ξ)=indicatorConstLp 2 hs (measure_ne_top μ s) ξ := by + classical + apply Lp.ext + filter_upwards [indicatorOperator_ae μ s hs (Lp.const 2 μ ξ),Lp.coeFn_const (p:=2) (μ:=μ) (c:=ξ), + indicatorConstLp_coeFn (p:=2) (hs:=hs) (hμs:=measure_ne_top μ s) (c:=ξ)] with a ha hc hi + rw [ha,hi] + by_cases hx : a∈s + · simp only [Set.indicator_of_mem hx] + exact hc + · simp [hx] + +theorem local_constant_ae_bound (Y : Lp H 2 μ →L[ℂ] Lp H 2 μ) + (hcomm : ∀ (s : Set Ω) (hs : MeasurableSet s),Commute Y (indicatorOperator μ s hs)) + (ξ : H) : ∀ᵐ a ∂μ,‖Y (Lp.const 2 μ ξ) a‖≤‖Y‖*‖ξ‖ := by + have hi := (memLp_two_iff_integrable_sq_norm (Lp.aestronglyMeasurable (Y (Lp.const 2 μ ξ)))).mp + (Lp.memLp (Y (Lp.const 2 μ ξ))) + have hh : (fun a => ‖Y (Lp.const 2 μ ξ) a‖^2) ≤ᵐ[μ] (fun _ => (‖Y‖*‖ξ‖)^2) := by + apply ae_le_of_forall_setIntegral_le hi (integrable_const _) + intro s hs hμs + have he : indicatorOperator μ s hs (Y (Lp.const 2 μ ξ))= + Y (indicatorConstLp 2 hs (measure_ne_top μ s) ξ) := by + rw [←indicatorOperator_const μ s hs ξ] + exact congrArg (fun A : Lp H 2 μ →L[ℂ] Lp H 2 μ => A (Lp.const 2 μ ξ)) (hcomm s hs).eq.symm + calc + (∫ a in s,‖Y (Lp.const 2 μ ξ) a‖^2 ∂μ)= + ‖indicatorOperator μ s hs (Y (Lp.const 2 μ ξ))‖^2 := + (indicatorOperator_norm_sq μ s hs _).symm + _=‖Y (indicatorConstLp 2 hs (measure_ne_top μ s) ξ)‖^2 := by rw [he] + _≤(‖Y‖*‖indicatorConstLp 2 hs (measure_ne_top μ s) ξ‖)^2 := + (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg Y) (norm_nonneg _))).mpr (Y.le_opNorm _) + _=‖Y‖^2*(∫ a in s,‖ξ‖^2 ∂μ) := by rw [mul_pow,indicator_norm_sq μ s hs (measure_ne_top μ s) ξ] + _=(∫ a in s,(‖Y‖*‖ξ‖)^2 ∂μ) := by simp only [mul_pow,integral_const_mul] + filter_upwards [hh] with a ha + exact (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg Y) (norm_nonneg ξ))).mp ha + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ScalarIndicatorAdjoint.lean b/lean/OAI/Analysis/Commutator/ScalarIndicatorAdjoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..7221279db1c253108bfc33802f4418f42eccbdad --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ScalarIndicatorAdjoint.lean @@ -0,0 +1,43 @@ +import Mathlib +import OAI.Analysis.Commutator.ScalarIndicator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma indicatorOperator_selfAdjoint (s : Set Ω) (hs : MeasurableSet s) : + IsSelfAdjoint (indicatorOperator (H:=H) μ s hs) := by + classical + rw [ContinuousLinearMap.isSelfAdjoint_iff'] + apply ContinuousLinearMap.ext + intro f + apply ext_inner_right ℂ + intro g + rw [ContinuousLinearMap.adjoint_inner_left,L2.inner_def,L2.inner_def] + apply integral_congr_ae + filter_upwards [indicatorOperator_ae μ s hs f,indicatorOperator_ae μ s hs g] + with a hf hg + rw [hf,hg] + by_cases ha : a∈s <;> simp [ha] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/ScalarUltralimit.lean b/lean/OAI/Analysis/Commutator/ScalarUltralimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..67860f5de79bbf1f381c4f7a75db61b8f6c0df45 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/ScalarUltralimit.lean @@ -0,0 +1,89 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction + +open Filter + +namespace Kadison.ScalarUltralimit + +variable {ι : Type*} + +lemma exists_limit (ω : Ultrafilter ι) (f : ι → ℂ) (C : ℝ) + (hf : ∀ i, ‖f i‖≤C) : ∃ z : ℂ, ‖z‖≤C ∧ Tendsto f (ω : Filter ι) (𝓝 z) := by + obtain ⟨z,hz,hl⟩ := (isCompact_closedBall (0 : ℂ) C).ultrafilter_le_nhds + (ω.map f) (by + rw [Ultrafilter.coe_map,Filter.map_le_iff_le_comap,Filter.comap_principal] + exact Filter.le_principal_iff.mpr (Filter.Eventually.of_forall (fun i => by + simpa only [Metric.mem_closedBall,dist_zero_right] using hf i))) + exact ⟨z,by simpa only [Metric.mem_closedBall,dist_zero_right] using hz,hl⟩ + +def limit (ω : Ultrafilter ι) (f : ι → ℂ) (hf : ∃ C : ℝ, ∀ i, ‖f i‖≤C) : ℂ := + (exists_limit ω f hf.choose hf.choose_spec).choose + +lemma tendsto_limit (ω : Ultrafilter ι) (f : ι → ℂ) (hf : ∃ C : ℝ, ∀ i, ‖f i‖≤C) : + Tendsto f (ω : Filter ι) (𝓝 (limit ω f hf)) := + (exists_limit ω f hf.choose hf.choose_spec).choose_spec.2 + +lemma norm_limit_le (ω : Ultrafilter ι) (f : ι → ℂ) (hf : ∃ C : ℝ, ∀ i, ‖f i‖≤C) + (C : ℝ) (hC : ∀ᶠ i in (ω : Filter ι), ‖f i‖≤C) : ‖limit ω f hf‖≤C := + le_of_tendsto (tendsto_limit ω f hf).norm hC + +lemma limit_eq_of_tendsto (ω : Ultrafilter ι) (f : ι → ℂ) + (hf : ∃ C : ℝ, ∀ i, ‖f i‖≤C) {z : ℂ} (hz : Tendsto f (ω : Filter ι) (𝓝 z)) : + limit ω f hf=z := tendsto_nhds_unique (tendsto_limit ω f hf) hz + +variable (ω : Ultrafilter ι) + +variable [TopologicalSpace ι] + +def value (f : ι →ᵇ ℂ) : ℂ := limit ω f ⟨‖f‖,fun i => f.norm_coe_le_norm i⟩ + +lemma tendsto_value (f : ι →ᵇ ℂ) : Tendsto f (ω : Filter ι) (𝓝 (value ω f)) := + tendsto_limit ω f _ + +lemma value_add (f g : ι →ᵇ ℂ) : value ω (f+g)=value ω f+value ω g := by + exact tendsto_nhds_unique (tendsto_value ω _) ((tendsto_value ω f).add (tendsto_value ω g)) + +lemma value_mul (f g : ι →ᵇ ℂ) : value ω (f*g)=value ω f*value ω g := by + exact tendsto_nhds_unique (tendsto_value ω _) ((tendsto_value ω f).mul (tendsto_value ω g)) + +lemma value_smul (a : ℂ) (f : ι →ᵇ ℂ) : value ω (a • f)=a • value ω f := by + exact tendsto_nhds_unique (tendsto_value ω _) (tendsto_const_nhds.smul (tendsto_value ω f)) + +lemma value_star (f : ι →ᵇ ℂ) : value ω (star f)=star (value ω f) := by + exact tendsto_nhds_unique (tendsto_value ω _) (tendsto_value ω f).star + +lemma value_const (a : ℂ) : value ω (BoundedContinuousFunction.const ι a)=a := by + exact tendsto_nhds_unique (tendsto_value ω _) tendsto_const_nhds + +lemma value_norm_le (f : ι →ᵇ ℂ) : ‖value ω f‖≤‖f‖ := + norm_limit_le ω _ _ _ (Filter.Eventually.of_forall (fun i => f.norm_coe_le_norm i)) + +def hom : (ι →ᵇ ℂ) →⋆ₐ[ℂ] ℂ where + toFun := value ω + map_one' := value_const ω 1 + map_zero' := value_const ω 0 + map_add' := value_add ω + map_mul' := value_mul ω + commutes' := fun a => value_const ω a + map_star' := value_star ω + +lemma nonneg_value_re (f : ι →ᵇ ℂ) (hf : ∀ᶠ i in (ω : Filter ι), 0≤(f i).re) : + 0≤(value ω f).re := ge_of_tendsto (Complex.continuous_re.tendsto _ |>.comp (tendsto_value ω f)) hf + +end Kadison.ScalarUltralimit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SchurTransfer.lean b/lean/OAI/Analysis/Commutator/SchurTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..73526dd208e9bd3cd7143ab1ddcc27d625ea5946 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SchurTransfer.lean @@ -0,0 +1,136 @@ +import Mathlib +import OAI.Analysis.Commutator.TwoByTwoPositive + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder ContinuousFunctionalCalculus Topology + +open Filter + +namespace Kadison.CStarBlock + +variable {A B C : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + [CStarAlgebra C] [PartialOrder C] [StarOrderedRing C] + +local instance : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma conjugate_diagonal (a b c d u v : A) : + star (block u 0 0 v)*block a b c d*block u 0 0 v= + block (star u*a*u) (star u*b*v) (star v*c*u) (star v*d*v) := by + simp [star_block,block_mul] + +omit [PartialOrder C] [StarOrderedRing C] in +lemma transfer_unit_square (φ : C →⋆ₐ[ℂ] A) (ψ : C →⋆ₐ[ℂ] B) + (f : A →ₗ[ℂ] B) (hf : ∀ a,‖f a‖≤‖a‖) + (hmod : ∀ c a d,f (φ c*a*φ d)=ψ c*f a*ψ d) + (u v : Cˣ) (x : A) + (hx : 0 ≤ block (φ (star (u:C)*u)) x (star x) (φ (star (v:C)*v))) : + 0 ≤ block (ψ (star (u:C)*u)) (f x) (star (f x)) (ψ (star (v:C)*v)) := by + have hcancelφ (w : Cˣ) : star (φ (↑w⁻¹))*star (φ (w:C))=1 := by + rw [←star_mul,←map_mul]; simp + have hcancelψ (w : Cˣ) : star (ψ (w:C))*star (ψ (↑w⁻¹))=1 := by + rw [←star_mul,←map_mul]; simp + let ui : A := φ (↑u⁻¹) + let vi : A := φ (↑v⁻¹) + let y := star ui*x*vi + have he : star (block ui 0 0 vi)*block (φ (star (u:C)*u)) x (star x) + (φ (star (v:C)*v))*block ui 0 0 vi=block 1 y (star y) 1 := by + rw [conjugate_diagonal] + dsimp [ui,vi,y] + simp only [map_mul,map_star,star_mul,star_star] + congr 1 + · simp only [←mul_assoc] + rw [hcancelφ,one_mul,←map_mul]; simp + · simp [mul_assoc] + · simp only [←mul_assoc] + rw [hcancelφ,one_mul,←map_mul]; simp + have hy : 0 ≤ block 1 y (star y) 1 := by + rw [←he] + exact star_left_conjugate_nonneg hx _ + have hfy : ‖f y‖≤1 := (hf y).trans (contraction_of_block_nonneg y hy) + have hp := contraction_block_nonneg (f y) hfy + have hm : f y=star (ψ (↑u⁻¹))*f x*ψ (↑v⁻¹) := by + simpa only [y,ui,vi,←map_star] using hmod (star (↑u⁻¹)) x (↑v⁻¹) + have hr : star (block (ψ (u:C)) 0 0 (ψ (v:C)))*block 1 (f y) (star (f y)) 1* + block (ψ (u:C)) 0 0 (ψ (v:C))= + block (ψ (star (u:C)*u)) (f x) (star (f x)) (ψ (star (v:C)*v)) := by + rw [conjugate_diagonal,hm] + simp only [mul_one,map_mul,map_star,star_mul,star_star] + congr 1 + · simp only [←mul_assoc] + rw [hcancelψ,one_mul,mul_assoc,←map_mul]; simp + · simp only [←mul_assoc] + rw [hcancelψ,one_mul,mul_assoc,←map_mul]; simp + rw [←hr] + exact star_left_conjugate_nonneg hp _ + +lemma transfer_strictlyPositive (φ : C →⋆ₐ[ℂ] A) (ψ : C →⋆ₐ[ℂ] B) + (f : A →ₗ[ℂ] B) (hf : ∀ a,‖f a‖≤‖a‖) + (hmod : ∀ c a d,f (φ c*a*φ d)=ψ c*f a*ψ d) + (p q : C) (hp : IsStrictlyPositive p) (hq : IsStrictlyPositive q) (x : A) + (hx : 0 ≤ block (φ p) x (star x) (φ q)) : + 0 ≤ block (ψ p) (f x) (star (f x)) (ψ q) := by + have hup := (CFC.isUnit_sqrt_iff p hp.nonneg).mpr hp.isUnit + have huq := (CFC.isUnit_sqrt_iff q hq.nonneg).mpr hq.isUnit + have he (r : C) (hr : 0≤r) (hu : IsUnit (CFC.sqrt r)) : star (hu.unit:C)*hu.unit=r := by + rw [hu.unit_spec,(IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg r)).star_eq] + exact CFC.sqrt_mul_sqrt_self r hr + simpa only [he p hp.nonneg hup,he q hq.nonneg huq] using + transfer_unit_square φ ψ f hf hmod hup.unit huq.unit x + (by simpa only [he p hp.nonneg hup,he q hq.nonneg huq] using hx) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma block_add_scalar (a b c d : A) (r : ℝ) : + block (a+r • 1) b c (d+r • 1)=block a b c d+r • 1 := by + ext i j + fin_cases i <;> fin_cases j <;> simp [block] + +lemma transfer_nonneg (φ : C →⋆ₐ[ℂ] A) (ψ : C →⋆ₐ[ℂ] B) + (f : A →ₗ[ℂ] B) (hf : ∀ a,‖f a‖≤‖a‖) + (hmod : ∀ c a d,f (φ c*a*φ d)=ψ c*f a*ψ d) + (p q : C) (hp : 0≤p) (hq : 0≤q) (x : A) + (hx : 0 ≤ block (φ p) x (star x) (φ q)) : + 0 ≤ block (ψ p) (f x) (star (f x)) (ψ q) := by + have hφ (a : C) (r : ℝ) : φ (a+r • 1)=φ a+r • 1 := by + change (φ.restrictScalars ℝ) (a+r • 1)=_ + simp only [map_add,map_smul,map_one] + rfl + have hψ (a : C) (r : ℝ) : ψ (a+r • 1)=ψ a+r • 1 := by + change (ψ.restrictScalars ℝ) (a+r • 1)=_ + simp only [map_add,map_smul,map_one] + rfl + have he (r : ℝ) (hr : 0 block (ψ p) (f x) (star (f x)) (ψ q)+r • 1) := by + fun_prop + have hl := hc.continuousAt.mono_left (show 𝓝[>] (0:ℝ) ≤ 𝓝 0 from nhdsWithin_le_nhds) + have hh := ge_of_tendsto hl (show ∀ᶠ r in 𝓝[>] (0:ℝ), + 0 ≤ block (ψ p) (f x) (star (f x)) (ψ q)+r • 1 from + Filter.Eventually.mono (self_mem_nhdsWithin : ∀ᶠ r in 𝓝[>] (0:ℝ),r∈Set.Ioi 0) (fun r hr => he r hr)) + simpa using hh + +end Kadison.CStarBlock + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SchurWeylDevelopment.lean b/lean/OAI/Analysis/Commutator/SchurWeylDevelopment.lean new file mode 100644 index 0000000000000000000000000000000000000000..b4bb0a9bdb954b04f2842c2f9b31ea3be48b80c8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SchurWeylDevelopment.lean @@ -0,0 +1,304 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison.SchurWeyl + +open Matrix + +variable {𝕜 : Type*} [CommRing 𝕜] + +variable {I J : Type*} [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] + +def tensorPower (A : Matrix I I 𝕜) : Matrix (J → I) (J → I) 𝕜 := + fun a b => ∏ j, A (a j) (b j) + +omit [Fintype I] [DecidableEq I] [DecidableEq J] in +@[simp] lemma tensorPower_apply (A : Matrix I I 𝕜) (a b : J → I) : + tensorPower A a b = ∏ j, A (a j) (b j) := rfl + +omit [Fintype I] [DecidableEq J] in +lemma tensorPower_diagonal (d : I → 𝕜) : + tensorPower (J := J) (Matrix.diagonal d) = + Matrix.diagonal (fun a : J → I => ∏ j, d (a j)) := by + classical + ext a b + by_cases h : a = b + · subst b; simp + · have hex : ∃ j, a j ≠ b j := Function.ne_iff.mp h + obtain ⟨j, hj⟩ := hex + rw [Matrix.diagonal_apply_ne _ h] + change (∏ j, Matrix.diagonal d (a j) (b j)) = 0 + apply Finset.prod_eq_zero (Finset.mem_univ j) + exact Matrix.diagonal_apply_ne _ hj + +omit [Fintype I] [DecidableEq J] in +@[simp] lemma tensorPower_one : tensorPower (J := J) (1 : Matrix I I 𝕜) = 1 := by + rw [← Matrix.diagonal_one, tensorPower_diagonal] + simp + +omit [DecidableEq I] in +lemma tensorPower_mul (A B : Matrix I I 𝕜) : + tensorPower (J := J) (A * B) = tensorPower A * tensorPower B := by + classical + ext a b + simp only [tensorPower_apply, Matrix.mul_apply] + rw [Fintype.prod_sum] + simp only [← Finset.prod_mul_distrib] + +def permutationMatrix (σ : Equiv.Perm J) : Matrix (J → I) (J → I) 𝕜 := + fun a b => if a = b ∘ σ.symm then 1 else 0 + +lemma tensorPower_commute_permutation (A : Matrix I I 𝕜) (σ : Equiv.Perm J) : + tensorPower A * permutationMatrix σ = permutationMatrix σ * tensorPower A := by + classical + ext a b + simp only [Matrix.mul_apply, permutationMatrix, mul_ite, mul_one, mul_zero] + rw [Finset.sum_eq_single (b ∘ σ.symm)] + · rw [ite_eq_left rfl] + rw [Finset.sum_eq_single (a ∘ σ)] + · have ha : a = (a ∘ σ) ∘ σ.symm := by ext j; simp + rw [ite_eq_left ha, one_mul] + dsimp [tensorPower] + simpa using (Equiv.prod_comp σ.symm fun j => A (a (σ j)) (b j)) + · intro c _ hc + have hn : a ≠ c ∘ σ.symm := by + intro he + apply hc + ext j + simpa using congrFun he (σ j) |>.symm + simp [hn] + · simp + · intro c _ hc + simp [hc] + · simp + +def assignmentMatrix (b c : J → I) : Matrix I I 𝕜 := + fun r s => ∑ j, if s = b j ∧ r = c j then 1 else 0 + +omit [Fintype I] [DecidableEq J] in +lemma assignmentMatrix_column (b c : J → I) (hb : Function.Injective b) (r : I) (j : J) : + assignmentMatrix (𝕜 := 𝕜) b c r (b j) = if r = c j then 1 else 0 := by + classical + unfold assignmentMatrix + rw [Finset.sum_eq_single j] + · simp + · intro k _ hk + have hn : b j ≠ b k := fun h => hk (hb h).symm + simp [hn] + · simp + +omit [Fintype I] [DecidableEq J] in +lemma tensorPower_assignment (b c : J → I) (hb : Function.Injective b) (a : J → I) : + tensorPower (assignmentMatrix (𝕜 := 𝕜) b c) a b = if a = c then 1 else 0 := by + classical + simp only [tensorPower_apply, assignmentMatrix_column b c hb] + by_cases h : a = c + · subst c; simp + · rw [ite_eq_right h] + obtain ⟨j, hj⟩ := Function.ne_iff.mp h + exact Finset.prod_eq_zero (Finset.mem_univ j) (ite_eq_right hj) + +lemma eq_zero_of_commute_of_column_zero (b : J → I) (hb : Function.Injective b) + (S : Matrix (J → I) (J → I) 𝕜) + (hS : ∀ A : Matrix I I 𝕜, S * tensorPower A = tensorPower A * S) + (hzero : ∀ a, S a b = 0) : S = 0 := by + classical + ext a c + have he := congrArg (fun X : Matrix (J → I) (J → I) 𝕜 => X a b) + (hS (assignmentMatrix b c)) + simp only [Matrix.mul_apply, tensorPower_assignment b c hb, hzero, mul_zero, + Finset.sum_const_zero, mul_ite, mul_one] at he + simpa using he + +omit [Fintype I] [DecidableEq I] [DecidableEq J] in +lemma exists_permutation_of_range (a b : J → I) (hb : Function.Injective b) + (h : ∀ j, ∃ k, a k = b j) : + ∃ σ : Equiv.Perm J, a = b ∘ σ.symm := by + classical + choose g hg using h + have hgi : Function.Injective g := by + intro j k he + apply hb + rw [← hg j, ← hg k, he] + let σ : Equiv.Perm J := Equiv.ofBijective g ((Fintype.bijective_iff_injective_and_card g).mpr ⟨hgi, rfl⟩) + refine ⟨σ, funext fun j => ?_⟩ + have he := hg (σ.symm j) + change a (σ (σ.symm j)) = b (σ.symm j) at he + simpa using he + +lemma column_support_permutations [Nontrivial 𝕜] + (b : J → I) (hb : Function.Injective b) + (S : Matrix (J → I) (J → I) 𝕜) + (hS : ∀ d : I → 𝕜, S * tensorPower (Matrix.diagonal d) = + tensorPower (Matrix.diagonal d) * S) + (a : J → I) (ha : S a b ≠ 0) : + ∃ σ : Equiv.Perm J, a = b ∘ σ.symm := by + classical + apply exists_permutation_of_range a b hb + intro j + by_contra hn + push Not at hn + let d : I → 𝕜 := fun r => if r = b j then 0 else 1 + have hd₁ : (∏ k, d (a k)) = 1 := by simp [d, hn] + have hd₀ : (∏ k, d (b k)) = 0 := + Finset.prod_eq_zero (Finset.mem_univ j) (by simp [d]) + have he := congrArg (fun X : Matrix (J → I) (J → I) 𝕜 => X a b) (hS d) + rw [tensorPower_diagonal] at he + simp only [Matrix.mul_diagonal, Matrix.diagonal_mul, hd₀, hd₁, mul_zero, one_mul] at he + exact ha he.symm + +omit [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] in +lemma permutation_label_injective (b : J → I) (hb : Function.Injective b) : + Function.Injective (fun σ : Equiv.Perm J => b ∘ σ.symm) := by + intro σ ρ he + have hs : σ.symm = ρ.symm := by + ext j + exact hb (congrFun he j) + exact congrArg Equiv.symm hs + +theorem commutant_tensorPower [Nontrivial 𝕜] + (b : J → I) (hb : Function.Injective b) + (S : Matrix (J → I) (J → I) 𝕜) + (hS : ∀ A : Matrix I I 𝕜, S * tensorPower A = tensorPower A * S) : + S = ∑ σ : Equiv.Perm J, S (b ∘ σ.symm) b • permutationMatrix σ := by + classical + let Q : Matrix (J → I) (J → I) 𝕜 := ∑ σ : Equiv.Perm J, S (b ∘ σ.symm) b • permutationMatrix σ + have hQ : ∀ A : Matrix I I 𝕜, Q * tensorPower A = tensorPower A * Q := by + intro A + dsimp [Q] + simp only [Matrix.sum_mul, Matrix.smul_mul, Matrix.mul_sum, Matrix.mul_smul, + tensorPower_commute_permutation] + have hcol : ∀ a, S a b = Q a b := by + intro a + by_cases ha : S a b = 0 + · dsimp [Q] + simp only [Matrix.sum_apply, Matrix.smul_apply, smul_eq_mul, permutationMatrix] + rw [ha] + symm + apply Finset.sum_eq_zero + intro σ _ + split_ifs with h + · rw [← h, ha, zero_mul] + · exact mul_zero _ + · obtain ⟨σ, rfl⟩ := column_support_permutations b hb S (fun d => hS _) a ha + dsimp [Q] + simp only [Matrix.sum_apply, Matrix.smul_apply, smul_eq_mul, permutationMatrix] + rw [Finset.sum_eq_single σ] + · simp + · intro ρ _ hρ + have hn : b ∘ σ.symm ≠ b ∘ ρ.symm := fun he => + hρ ((permutation_label_injective b hb he).symm) + simp [hn] + · simp + have hz : S - Q = 0 := eq_zero_of_commute_of_column_zero b hb _ + (fun A => by rw [Matrix.sub_mul, Matrix.mul_sub, hS A, hQ A]) + (fun a => by simp [hcol a]) + exact sub_eq_zero.mp hz + +lemma complex_unit_circle_infinite : {z : ℂ | ‖z‖ = 1}.Infinite := by + have hi : Set.InjOn (fun x : ℝ => (Circle.exp x : ℂ)) (Set.Icc 0 1) := + Circle.coe_injective.comp_injOn (Circle.exp_injOn_Icc (by linarith [Real.pi_gt_three])) + exact ((Set.Icc_infinite (by norm_num : (0 : ℝ) < 1)).image hi).mono + (by rintro _ ⟨x, _, rfl⟩; exact Circle.norm_coe _) + +lemma diagonal_unitary (d : I → ℂ) (hd : ∀ i, ‖d i‖ = 1) : + Matrix.diagonal d ∈ unitary (Matrix I I ℂ) := by + apply Matrix.mem_unitaryGroup_iff.mpr + rw [Matrix.star_eq_conjTranspose, Matrix.diagonal_conjTranspose, + Matrix.diagonal_mul_diagonal] + simp [Pi.star_apply, RCLike.star_def, Complex.mul_conj', hd] + +lemma commute_diagonal_of_unitary + (S : Matrix (J → I) (J → I) ℂ) + (hS : ∀ U : unitary (Matrix I I ℂ), S * tensorPower (U : Matrix I I ℂ) = + tensorPower (U : Matrix I I ℂ) * S) (d : I → ℂ) : + S * tensorPower (Matrix.diagonal d) = tensorPower (Matrix.diagonal d) * S := by + classical + rw [tensorPower_diagonal] + ext a b + simp only [Matrix.mul_diagonal, Matrix.diagonal_mul] + let p : MvPolynomial I ℂ := MvPolynomial.C (S a b) * ∏ j, MvPolynomial.X (b j) + let q : MvPolynomial I ℂ := (∏ j, MvPolynomial.X (a j)) * MvPolynomial.C (S a b) + have hpq : p = q := by + apply MvPolynomial.funext_set (fun _ => {z : ℂ | ‖z‖ = 1}) + (fun _ => complex_unit_circle_infinite) + intro z hz + have he := congrArg (fun X : Matrix (J → I) (J → I) ℂ => X a b) + (hS ⟨Matrix.diagonal z, diagonal_unitary z (fun i => hz i (Set.mem_univ _))⟩) + rw [tensorPower_diagonal] at he + simpa [p, q] using he + have he := congrArg (MvPolynomial.eval d) hpq + simpa [p, q] using he + +lemma commute_hermitian_of_unitary + (S : Matrix (J → I) (J → I) ℂ) + (hS : ∀ U : unitary (Matrix I I ℂ), S * tensorPower (U : Matrix I I ℂ) = + tensorPower (U : Matrix I I ℂ) * S) + (A : Matrix I I ℂ) (hA : A.IsHermitian) : + S * tensorPower A = tensorPower A * S := by + have hU : Commute S (tensorPower (hA.eigenvectorUnitary : Matrix I I ℂ)) := + hS hA.eigenvectorUnitary + have hD : Commute S (tensorPower (Matrix.diagonal (RCLike.ofReal ∘ hA.eigenvalues))) := + commute_diagonal_of_unitary S hS _ + have hUs : Commute S (tensorPower ((star hA.eigenvectorUnitary : unitary (Matrix I I ℂ)) : Matrix I I ℂ)) := + hS (star hA.eigenvectorUnitary) + rw [hA.spectral_theorem, Unitary.conjStarAlgAut_apply] + simpa only [tensorPower_mul, Unitary.coe_star] using ((hU.mul_right hD).mul_right hUs).eq + +omit [DecidableEq I] in +lemma commute_complexification + (S : Matrix (J → I) (J → I) ℂ) + (hS : ∀ A : Matrix I I ℂ, A.IsHermitian → S * tensorPower A = tensorPower A * S) + (A B : Matrix I I ℂ) (hA : A.IsHermitian) (hB : B.IsHermitian) (z : ℂ) : + S * tensorPower (A + z • B) = tensorPower (A + z • B) * S := by + classical + ext a b + let P (r s : I) : MvPolynomial Unit ℂ := MvPolynomial.C (A r s) + + MvPolynomial.X () * MvPolynomial.C (B r s) + let p : MvPolynomial Unit ℂ := ∑ c : J → I, + MvPolynomial.C (S a c) * ∏ j, P (c j) (b j) + let q : MvPolynomial Unit ℂ := ∑ c : J → I, + (∏ j, P (a j) (c j)) * MvPolynomial.C (S c b) + have hpq : p = q := by + apply MvPolynomial.funext_set (fun _ => Set.range (Complex.ofReal : ℝ → ℂ)) + (fun _ => Set.infinite_range_of_injective Complex.ofReal_injective) + intro x hx + obtain ⟨t, ht⟩ := hx () (Set.mem_univ _) + have hs : (A + (t : ℂ) • B).IsHermitian := by + exact hA.add (hB.smul (by change star (t : ℂ) = (t : ℂ); simp)) + have he := congrArg (fun X : Matrix (J → I) (J → I) ℂ => X a b) (hS _ hs) + simpa [p, q, P, Matrix.mul_apply, tensorPower, ← ht] using he + have he := congrArg (MvPolynomial.eval (fun _ => z)) hpq + simpa [p, q, P, Matrix.mul_apply, tensorPower] using he + +lemma commute_all_of_unitary + (S : Matrix (J → I) (J → I) ℂ) + (hS : ∀ U : unitary (Matrix I I ℂ), S * tensorPower (U : Matrix I I ℂ) = + tensorPower (U : Matrix I I ℂ) * S) (A : Matrix I I ℂ) : + S * tensorPower A = tensorPower A * S := by + have hre : (realPart A : Matrix I I ℂ).IsHermitian := + Matrix.isHermitian_iff_isSelfAdjoint.mpr (realPart A).property + have him : (imaginaryPart A : Matrix I I ℂ).IsHermitian := + Matrix.isHermitian_iff_isSelfAdjoint.mpr (imaginaryPart A).property + simpa only [realPart_add_I_smul_imaginaryPart] using + commute_complexification S (commute_hermitian_of_unitary S hS) + (realPart A) (imaginaryPart A) hre him Complex.I + +theorem commutant_unitary_tensorPower (b : J → I) (hb : Function.Injective b) + (S : Matrix (J → I) (J → I) ℂ) + (hS : ∀ U : unitary (Matrix I I ℂ), S * tensorPower (U : Matrix I I ℂ) = + tensorPower (U : Matrix I I ℂ) * S) : + S = ∑ σ : Equiv.Perm J, S (b ∘ σ.symm) b • permutationMatrix σ := + commutant_tensorPower b hb S (commute_all_of_unitary S hS) + +end Kadison.SchurWeyl +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SelfAdjointSpectral.lean b/lean/OAI/Analysis/Commutator/SelfAdjointSpectral.lean new file mode 100644 index 0000000000000000000000000000000000000000..0bcbba7b8045f54734fa8c7acc10fee08b5f9880 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SelfAdjointSpectral.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Commutator.DyadicSpectral + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma normalized_positive_general {A : Type*} [CStarAlgebra A] [PartialOrder A] + [StarOrderedRing A] {T : A} (hT : IsSelfAdjoint T) : + 0≤(2*‖T‖+1)⁻¹ • (T+‖T‖ • (1 : A)) ∧ + (2*‖T‖+1)⁻¹ • (T+‖T‖ • (1 : A))≤1 := by + have hn : 0<2*‖T‖+1 := by positivity + have hlo : -(‖T‖ • (1 : A))≤T := by + simpa only [Algebra.algebraMap_eq_smul_one] using hT.neg_algebraMap_norm_le_self + have hhi : T≤‖T‖ • (1 : A) := by + simpa only [Algebra.algebraMap_eq_smul_one] using hT.le_algebraMap_norm_self + have hpos : 0≤T+‖T‖ • (1 : A) := by + simpa only [neg_add_cancel] using _root_.add_le_add_left hlo (‖T‖ • (1 : A)) + refine ⟨smul_nonneg (inv_nonneg.mpr hn.le) hpos,?_⟩ + have hbound : T+‖T‖ • (1 : A)≤(2*‖T‖+1) • (1 : A) := by + calc + T+‖T‖ • (1 : A)≤‖T‖ • (1 : A)+‖T‖ • (1 : A) := _root_.add_le_add_left hhi _ + _=(2*‖T‖) • (1 : A) := by module + _≤(2*‖T‖+1) • (1 : A) := smul_le_smul_of_nonneg_right (by linarith) zero_le_one + have h := smul_le_smul_of_nonneg_left hbound (inv_nonneg.mpr hn.le) + simpa only [smul_smul,inv_mul_cancel₀ hn.ne',one_smul] using h + +theorem exists_selfadjoint_spectral_sum (M : VonNeumannAlgebra H) + {T : H →L[ℂ] H} (hTM : T∈M) (hT : IsSelfAdjoint T) {ε : ℝ} (hε : 0<ε) : + ∃ n : ℕ, ∃ p : Fin n → H →L[ℂ] H, ∃ c : Fin n → ℝ, + (∀ i,p i∈M ∧ IsStarProjection (p i)) ∧ + (∀ i j,Commute (p i) (p j)) ∧ ‖T-∑ i,c i • p i‖<ε := by + classical + let r : ℝ := 2*‖T‖+1 + have hr : 0 r*c i) + refine ⟨n+1,q,d,?_,?_,?_⟩ + · intro i + refine Fin.cases ⟨M.one_mem,IsStarProjection.one _⟩ (fun j => hp j) i + · intro i j + refine Fin.cases (Commute.one_left _) (fun i => ?_) i + exact Fin.cases (Commute.one_right _) (fun j => hc i j) j + · have heq : T-∑ i,d i • q i=r • (S-∑ i,c i • p i) := by + rw [Fin.sum_univ_succ] + simp only [d,q,Fin.cons_zero,Fin.cons_succ,smul_sub,Finset.smul_sum,smul_smul] + have hid : r • S=T+‖T‖ • (1 : H →L[ℂ] H) := by + dsimp [S]; rw [smul_smul,mul_inv_cancel₀ hr.ne',one_smul] + rw [hid] + module + rw [heq,norm_smul,Real.norm_of_nonneg hr.le] + exact (mul_lt_mul_of_pos_left he hr).trans_eq (mul_div_cancel₀ ε hr.ne') + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableBoundTransfer.lean b/lean/OAI/Analysis/Commutator/SeparableBoundTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..c721190739d8ffcf67abfc254472b641288f2938 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableBoundTransfer.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Commutator.SeparableTestGeometry + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +universe u + +namespace Kadison.SeparableTest + +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) (h : ℕ) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈P) + +include hX + +lemma bound_on_vector {c : ℝ} (hc : 0≤c) (ξ : PiLp 2 (fun _ : Fin h => H)) + (hb : ‖diagonalAmplification h (restrictedY h X Y ξ)* + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))- + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))* + diagonalAmplification h (restrictedY h X Y ξ)‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant (representation h X Y ξ).range) + (restrictedY h X Y ξ)* + ‖matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))‖) : + ‖(diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y) ξ‖≤ + (c*commutatorSeminorm P Y*‖matrixOperator h X‖)*‖ξ‖ := by + let σ := representation h X Y ξ + let Z := restrictedY h X Y ξ + let X₀ := fun i j => σ (entries h X i j) + have hb' : ‖diagonalAmplification h Z*matrixOperator h X₀- + matrixOperator h X₀*diagonalAmplification h Z‖≤ + c*commutatorSeminorm P Y*‖matrixOperator h X‖ := + hb.trans (mul_le_mul (mul_le_mul_of_nonneg_left (seminorm_bound h X Y ξ P hX) hc) + (matrix_norm_le h X Y ξ) (norm_nonneg (matrixOperator h X₀)) + (mul_nonneg hc (commutatorSeminorm_nonneg P Y))) + rw [commutator_vector h X Y ξ,LinearIsometry.norm_map] + exact ((diagonalAmplification h Z*matrixOperator h X₀- + matrixOperator h X₀*diagonalAmplification h Z).le_opNorm (vector h X Y ξ)).trans + (by rw [vector_norm]; exact mul_le_mul_of_nonneg_right hb' (norm_nonneg ξ)) + +def SeparableBound (c : ℝ) : Prop := + ∀ (K : Type u) [NormedAddCommGroup K] [InnerProductSpace ℂ K] + [CompleteSpace K] [TopologicalSpace.SeparableSpace K] + (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) (h : ℕ),1≤h → + ∀ X : Matrix (Fin h) (Fin h) (K →L[ℂ] K), (∀ i j,X i j∈P) → + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm P Y*‖matrixOperator h X‖ + +omit hX in +lemma SeparableBound.on_range {c : ℝ} (hsep : SeparableBound.{u} c) + {A K : Type u} [CStarAlgebra A] [NormedAddCommGroup K] [InnerProductSpace ℂ K] + [CompleteSpace K] [TopologicalSpace.SeparableSpace K] + (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (Z : K →L[ℂ] K) (h : ℕ) (hh : 1≤h) + (W : Matrix (Fin h) (Fin h) A) : + ‖diagonalAmplification h Z*matrixOperator h (fun i j => σ (W i j))- + matrixOperator h (fun i j => σ (W i j))*diagonalAmplification h Z‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant σ.range) Z* + ‖matrixOperator h (fun i j => σ (W i j))‖ := by + apply hsep K _ Z h hh + intro i j + exact NormalGNS.subset_bicommutant σ.range ⟨W i j,rfl⟩ + +omit hX in +lemma restricted_bound {c : ℝ} (hsep : SeparableBound.{u} c) (hh : 1≤h) + (ξ : PiLp 2 (fun _ : Fin h => H)) : + ‖diagonalAmplification h (restrictedY h X Y ξ)* + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))- + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))* + diagonalAmplification h (restrictedY h X Y ξ)‖≤ + c*commutatorSeminorm (NormalGNS.bicommutant (representation h X Y ξ).range) + (restrictedY h X Y ξ)* + ‖matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))‖ := by + exact hsep.on_range (representation h X Y ξ) (restrictedY h X Y ξ) h hh (entries h X) + +theorem bound_of_separable_bound {c : ℝ} (hc : 0≤c) + (hsep : SeparableBound.{u} c) (hh : 1≤h) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ + (mul_nonneg (mul_nonneg hc (commutatorSeminorm_nonneg P Y)) (norm_nonneg _)) + intro ξ + exact bound_on_vector P Y h X hX hc ξ (restricted_bound Y h X hsep hh ξ) + +end Kadison.SeparableTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableFactorMain.lean b/lean/OAI/Analysis/Commutator/SeparableFactorMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b89049a9d6e01d9f49546f4ded6db4c7ace8a66 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableFactorMain.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.Commutator.AtomicFactorMain +import OAI.Analysis.Commutator.FiniteFactorTrace +import OAI.Analysis.Commutator.NonfiniteFactor +import OAI.Analysis.Commutator.TracedSeparableFactorMain + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +theorem uniform_commutator_separable_factor (P : VonNeumannAlgebra H) + (hfac : FactorCorner.IsFactor P) (Y : H →L[ℂ] H) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖ ≤ + 3122*commutatorSeminorm P Y*‖matrixOperator h X‖ := by + classical + rcases subsingleton_or_nontrivial H with hH|hH + · let := hH + have hz : diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y=0 := by + ext x i + exact Subsingleton.elim _ _ + rw [hz,norm_zero] + exact mul_nonneg (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg P Y)) (norm_nonneg _) + · let := hH + have hc : 9*commutatorSeminorm P Y*‖matrixOperator h X‖≤ + 3122*commutatorSeminorm P Y*‖matrixOperator h X‖ := + mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_right (by norm_num : (9:ℝ)≤3122) + (commutatorSeminorm_nonneg P Y)) (norm_nonneg _) + by_cases hd : DiffuseProjection.HasNoMinimalProjections P + · by_cases hf : PartialIsometryOrder.IsFiniteAlgebra P + · obtain ⟨τ,htr,hnormal,hfaith,hone⟩ := + OrbitStateHull.exists_faithful_normal_trace P hfac hd hf + exact NormalRepresentation.separable_traced_factor_bound P τ htr hnormal hfaith hone + hfac hd h hh Y X hX + · exact (uniform_commutator_nonfinite_factor P hfac hf Y h X hX).trans hc + · exact (uniform_commutator_atomic_factor P hfac hd Y h X hX).trans hc + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableReducingHull.lean b/lean/OAI/Analysis/Commutator/SeparableReducingHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..b6bdebba23d6ae97e12afe148b02f1f27e358b2b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableReducingHull.lean @@ -0,0 +1,116 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +open ContinuousLinearMap + +namespace Kadison.SeparableReducingHull + +variable {H ι κ : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] + +def generator (T : ι → H →L[ℂ] H) (i : ι × Bool) : H →L[ℂ] H := + if i.2 then star (T i.1) else T i.1 + +def orbit (T : ι → H →L[ℂ] H) (v : κ → H) (p : List (ι × Bool) × κ) : H := + (p.1.map (generator T)).prod (v p.2) + +def hull (T : ι → H →L[ℂ] H) (v : κ → H) : Submodule ℂ H := + (Submodule.span ℂ (Set.range (orbit T v))).topologicalClosure + +lemma hull_closed (T : ι → H →L[ℂ] H) (v : κ → H) : + IsClosed (hull T v : Set H) := Submodule.isClosed_topologicalClosure _ + +instance hull_complete (T : ι → H →L[ℂ] H) (v : κ → H) : CompleteSpace (hull T v) := + (hull_closed T v).completeSpace_coe + +lemma vector_mem (T : ι → H →L[ℂ] H) (v : κ → H) (j : κ) : v j∈hull T v := by + apply Submodule.le_topologicalClosure + apply Submodule.subset_span + exact ⟨([],j),by simp [orbit]⟩ + +lemma generator_invariant (T : ι → H →L[ℂ] H) (v : κ → H) (i : ι × Bool) : + ∀ x∈hull T v, generator T i x∈hull T v := by + change (Submodule.span ℂ (Set.range (orbit T v))).topologicalClosure ≤ + (hull T v).comap (generator T i).toLinearMap + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro _ ⟨⟨w,j⟩,rfl⟩ + change generator T i (orbit T v (w,j))∈hull T v + apply Submodule.le_topologicalClosure + apply Submodule.subset_span + exact ⟨(i::w,j),by simp [orbit,mul_apply_eq_comp]⟩ + · exact (hull_closed T v).preimage (generator T i).continuous + +lemma invariant (T : ι → H →L[ℂ] H) (v : κ → H) (i : ι) : + ∀ x∈hull T v,T i x∈hull T v := by + simpa only [generator,Bool.false_eq_true,ite_false] using generator_invariant T v (i,false) + +lemma star_invariant (T : ι → H →L[ℂ] H) (v : κ → H) (i : ι) : + ∀ x∈hull T v,star (T i) x∈hull T v := by + simpa only [generator,ite_true] using generator_invariant T v (i,true) + +instance hull_separable [Countable ι] [Countable κ] + (T : ι → H →L[ℂ] H) (v : κ → H) : TopologicalSpace.SeparableSpace (hull T v) := by + apply TopologicalSpace.IsSeparable.separableSpace + exact ((Set.countable_range (orbit T v)).isSeparable.span (R := ℂ)).closure + +def reducingAlgebra (K : Submodule ℂ H) : StarSubalgebra ℂ (H →L[ℂ] H) where + carrier := {T | (∀ x∈K,T x∈K) ∧ (∀ x∈K,star T x∈K)} + zero_mem' := by simp + add_mem' := by + rintro S T ⟨hS,hSs⟩ ⟨hT,hTs⟩ + constructor + · intro x hx; exact K.add_mem (hS x hx) (hT x hx) + · intro x hx; simpa only [star_add,add_apply] using K.add_mem (hSs x hx) (hTs x hx) + mul_mem' := by + rintro S T ⟨hS,hSs⟩ ⟨hT,hTs⟩ + constructor + · intro x hx; exact hS _ (hT x hx) + · intro x hx; simpa only [star_mul,mul_apply_eq_comp] using hTs _ (hSs x hx) + algebraMap_mem' := by + intro c + constructor + · intro x hx; simpa only [Algebra.algebraMap_eq_smul_one,smul_apply, + one_apply_eq_self] using K.smul_mem c hx + · intro x hx; simpa only [Algebra.algebraMap_eq_smul_one,star_smul,star_one, + smul_apply,one_apply_eq_self] using K.smul_mem (star c) hx + star_mem' := by rintro T ⟨hT,hTs⟩; exact ⟨hTs,by simpa only [star_star] using hT⟩ + +lemma reducingAlgebra_closed (K : Submodule ℂ H) (hK : IsClosed (K : Set H)) : + IsClosed (reducingAlgebra K : Set (H →L[ℂ] H)) := by + change IsClosed {T : H →L[ℂ] H | (∀ x∈K,T x∈K) ∧ (∀ x∈K,star T x∈K)} + simp only [Set.ofPred_and,Set.ofPred_forall] + apply IsClosed.inter + · exact isClosed_iInter (fun x => isClosed_iInter (fun _ => + hK.preimage (show Continuous (fun T : H →L[ℂ] H => T x) by fun_prop))) + · exact isClosed_iInter (fun x => isClosed_iInter (fun _ => + hK.preimage (show Continuous (fun T : H →L[ℂ] H => star T x) by fun_prop))) + +lemma generator_mem_reducingAlgebra (T : ι → H →L[ℂ] H) (v : κ → H) (i : ι) : + T i∈reducingAlgebra (hull T v) := ⟨invariant T v i,star_invariant T v i⟩ + +lemma generated_reduces (T : ι → H →L[ℂ] H) (v : κ → H) : + (StarAlgebra.adjoin ℂ (Set.range T)).topologicalClosure ≤ reducingAlgebra (hull T v) := by + apply StarSubalgebra.topologicalClosure_minimal + · apply StarAlgebra.adjoin_le + rintro _ ⟨i,rfl⟩ + exact generator_mem_reducingAlgebra T v i + · exact reducingAlgebra_closed _ (hull_closed T v) + +end Kadison.SeparableReducingHull + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableSmall.lean b/lean/OAI/Analysis/Commutator/SeparableSmall.lean new file mode 100644 index 0000000000000000000000000000000000000000..fcf4c9528050151e6e3f167c4ecf0e53662d957d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableSmall.lean @@ -0,0 +1,59 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +universe u + +namespace Kadison.SeparableSmall + +variable (H : Type u) [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] [TopologicalSpace.SeparableSpace H] + +omit [InnerProductSpace ℂ H] [CompleteSpace H] in +theorem small : Small.{0} H := by + obtain ⟨F,hF⟩ := Metric.PiNatEmbed.exists_embedding_to_hilbert_cube (X:=H) + exact small_of_injective hF.injective + +local instance separableSmallSmall : Small.{0} H := small H + +abbrev Model : Type := Shrink H + +instance model_inner : InnerProductSpace ℂ (Model H) where + inner x y := inner ℂ ((equivShrink H).symm x) ((equivShrink H).symm y) + conj_inner_symm x y := inner_conj_symm _ _ + norm_sq_eq_re_inner x := norm_sq_eq_re_inner ((equivShrink H).symm x) + add_left x y z := by + change inner ℂ (Shrink.linearEquiv ℂ H (x+y)) _ = _ + rw [map_add,inner_add_left] + rfl + smul_left x y c := by + change inner ℂ (Shrink.linearEquiv ℂ H (c • x)) _ = _ + rw [map_smul,inner_smul_left] + rfl + +def unitary : Model H ≃ₗᵢ[ℂ] H where + toLinearEquiv := Shrink.linearEquiv ℂ H + norm_map' _ := rfl + +instance model_complete : CompleteSpace (Model H) := + (unitary H).toIsometryEquiv.completeSpace_iff.mpr inferInstance + +instance model_separable : TopologicalSpace.SeparableSpace (Model H) := + (unitary H).symm.surjective.denseRange.separableSpace (unitary H).symm.continuous + +end Kadison.SeparableSmall + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableTestGeometry.lean b/lean/OAI/Analysis/Commutator/SeparableTestGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..f71fa8a5b79a056b4a21a7de878e3bbee4baab84 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableTestGeometry.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.Commutator.DerivationKaplansky +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.ReducingMatrix +import OAI.Analysis.Commutator.SeparableReducingHull + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison.SeparableTest + +open SeparableReducingHull ReducingRepresentation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (Y : H →L[ℂ] H) + +def generators : ((Fin h×Fin h)⊕Unit) → H →L[ℂ] H := + Sum.elim (fun ij => X ij.1 ij.2) (fun _ => Y) + +def space (ξ : PiLp 2 (fun _ : Fin h => H)) : Submodule ℂ H := hull (generators h X Y) (fun i => ξ i) + +instance space_complete (ξ : PiLp 2 (fun _ : Fin h => H)) : CompleteSpace (space h X Y ξ) := + SeparableReducingHull.hull_complete _ _ + +instance space_separable (ξ : PiLp 2 (fun _ : Fin h => H)) : TopologicalSpace.SeparableSpace (space h X Y ξ) := + SeparableReducingHull.hull_separable _ _ + +def algebra : StarSubalgebra ℂ (H →L[ℂ] H) := + (StarAlgebra.adjoin ℂ (Set.range (fun ij : Fin h×Fin h => X ij.1 ij.2))).topologicalClosure + +instance algebra_closed : IsClosed (algebra h X : Set (H →L[ℂ] H)) := + StarSubalgebra.isClosed_topologicalClosure _ + +instance algebra_cstar : CStarAlgebra (algebra h X) := StarSubalgebra.cstarAlgebra _ + +local instance : PartialOrder (algebra h X) := CStarAlgebra.spectralOrder _ + +local instance : StarOrderedRing (algebra h X) := CStarAlgebra.spectralOrderedRing _ + +lemma entry_mem (i j : Fin h) : X i j∈algebra h X := + StarSubalgebra.le_topologicalClosure _ (StarAlgebra.subset_adjoin ℂ _ (Set.mem_range_self (i,j))) + +def entries : Matrix (Fin h) (Fin h) (algebra h X) := fun i j => ⟨X i j,entry_mem h X i j⟩ + +lemma algebra_le (P : VonNeumannAlgebra H) (hX : ∀ i j,X i j∈P) : algebra h X≤P.toStarSubalgebra := by + apply StarSubalgebra.topologicalClosure_minimal + · exact StarAlgebra.adjoin_le (by rintro _ ⟨⟨i,j⟩,rfl⟩; exact hX i j) + · exact VonNeumannCStar.isClosed P + +variable (ξ : PiLp 2 (fun _ : Fin h => H)) + +lemma algebra_reduces : algebra h X≤reducingAlgebra (space h X Y ξ) := by + apply StarSubalgebra.topologicalClosure_minimal + · apply StarAlgebra.adjoin_le + rintro _ ⟨⟨i,j⟩,rfl⟩ + exact generator_mem_reducingAlgebra (generators h X Y) (fun i => ξ i) (Sum.inl (i,j)) + · exact reducingAlgebra_closed _ (hull_closed _ _) + +lemma algebra_invariant (a : algebra h X) (x : H) (hx : x∈space h X Y ξ) : + (a:H →L[ℂ] H) x∈space h X Y ξ := (algebra_reduces h X Y ξ a.property).1 x hx + +lemma Y_invariant : ∀ x∈space h X Y ξ,Y x∈space h X Y ξ := + invariant (generators h X Y) (fun i => ξ i) (Sum.inr Unit.unit) + +def representation : algebra h X →⋆ₐ[ℂ] (space h X Y ξ →L[ℂ] space h X Y ξ) := + restrict (algebra h X).subtype _ (algebra_invariant h X Y ξ) + +def restrictedY : space h X Y ξ →L[ℂ] space h X Y ξ := Y.restrict (Y_invariant h X Y ξ) + +def vector : PiLp 2 (fun _ : Fin h => space h X Y ξ) := + WithLp.toLp 2 (fun i => ⟨ξ i,vector_mem _ _ i⟩) + +lemma include_vector : matrixInclusion (space h X Y ξ) h (vector h X Y ξ)=ξ := by ext i; rfl + +lemma vector_norm : ‖vector h X Y ξ‖=‖ξ‖ := by + rw [←(matrixInclusion (space h X Y ξ) h).norm_map,include_vector] + +lemma scalar_bound (P : VonNeumannAlgebra H) (hX : ∀ i j,X i j∈P) (a : algebra h X) : + ‖restrictedY h X Y ξ*representation h X Y ξ a-representation h X Y ξ a*restrictedY h X Y ξ‖≤ + commutatorSeminorm P Y*‖a‖ := by + have hb := norm_commutator_compression_le (algebra h X).subtype (space h X Y ξ) + (algebra_invariant h X Y ξ) Y a + rw [compression_eq_restrict _ Y (Y_invariant h X Y ξ)] at hb + exact hb.trans (commutator_bound P Y (algebra_le h X P hX a.property)) + +lemma seminorm_bound (P : VonNeumannAlgebra H) (hX : ∀ i j,X i j∈P) : + commutatorSeminorm (NormalGNS.bicommutant (representation h X Y ξ).range) (restrictedY h X Y ξ)≤ + commutatorSeminorm P Y := + DerivationColumns.seminorm_bicommutant_le _ _ (commutatorSeminorm_nonneg P Y) + (scalar_bound h X Y ξ P hX) + +lemma matrix_norm_le : ‖matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))‖≤ + ‖matrixOperator h X‖ := + restricted_matrix_norm_le (algebra h X).subtype (space h X Y ξ) + (algebra_invariant h X Y ξ) h (entries h X) + +lemma commutator_vector : + (diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y) ξ= + matrixInclusion (space h X Y ξ) h + ((diagonalAmplification h (restrictedY h X Y ξ)* + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))- + matrixOperator h (fun i j => representation h X Y ξ (entries h X i j))* + diagonalAmplification h (restrictedY h X Y ξ)) (vector h X Y ξ)) := by + have hh := congrArg (fun L => L (vector h X Y ξ)) + (matrix_commutator_intertwines (algebra h X).subtype (space h X Y ξ) + (algebra_invariant h X Y ξ) Y (Y_invariant h X Y ξ) h (entries h X)) + change (diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y) + (matrixInclusion (space h X Y ξ) h (vector h X Y ξ))=_ at hh + rw [include_vector] at hh + exact hh + +end Kadison.SeparableTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SeparableUniverseTransfer.lean b/lean/OAI/Analysis/Commutator/SeparableUniverseTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..22c839e8786813ca99dc3bd7ae39c994f48e9da2 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SeparableUniverseTransfer.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.SeparableBoundTransfer +import OAI.Analysis.Commutator.SeparableSmall +import OAI.Analysis.Commutator.UnitaryMainTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +universe u + +namespace Kadison.SeparableTest + +theorem SeparableBound.lift {c : ℝ} (hsmall : SeparableBound.{0} c) : + SeparableBound.{u} c := by + intro H _ _ _ _ P Y h hh X hX + let U := (SeparableSmall.unitary H).symm + let Q := UnitaryTransport.algebra U P + have hb := hsmall (SeparableSmall.Model H) Q (U.conjStarAlgEquiv Y) h hh + (fun i j => U.conjStarAlgEquiv (X i j)) + (fun i j => (UnitaryTransport.mem_algebra U P (X i j)).mpr (hX i j)) + change ‖diagonalAmplification h (U.conjStarAlgEquiv Y)* + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))- + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))* + diagonalAmplification h (U.conjStarAlgEquiv Y)‖≤ + c*commutatorSeminorm (UnitaryTransport.algebra U P) (U.conjStarAlgEquiv Y)* + ‖matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))‖ at hb + simpa only [UnitaryTransport.matrix_commutator_norm,UnitaryTransport.seminorm, + UnitaryTransport.matrix_norm] using hb + +theorem bound_of_small_separable_bound {H : Type u} [NormedAddCommGroup H] + [InnerProductSpace ℂ H] [CompleteSpace H] (P : VonNeumannAlgebra H) + (Y : H →L[ℂ] H) (h : ℕ) (hh : 1≤h) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈P) + {c : ℝ} (hc : 0≤c) (hsmall : SeparableBound.{0} c) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm P Y*‖matrixOperator h X‖ := + bound_of_separable_bound P Y h X hX hc hsmall.lift hh + +end Kadison.SeparableTest + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SimilarityMidpointObstruction.lean b/lean/OAI/Analysis/Commutator/SimilarityMidpointObstruction.lean new file mode 100644 index 0000000000000000000000000000000000000000..9395869ae7b0720aa8b5eb59ba8e5fee76124b24 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SimilarityMidpointObstruction.lean @@ -0,0 +1,46 @@ +import Mathlib + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison.SimilarityObstruction + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +lemma midpoint_curvature (π : A →ₐ[ℂ] B) (a b : A) : + 2 • (π (a*b) + star (π (star (a*b)))) - + (π a + star (π (star a))) * (π b + star (π (star b))) = + (π a - star (π (star a))) * (π b - star (π (star b))) := by + simp only [star_mul, map_mul, two_smul] + noncomm_ring + +lemma midpoint_multiplicative_iff_star (π : A →ₐ[ℂ] B) : + (∀ a b : A, 2 • (π (a*b) + star (π (star (a*b)))) = + (π a + star (π (star a))) * (π b + star (π (star b)))) ↔ + ∀ a : A, π (star a) = star (π a) := by + constructor + · intro h a + have hz : (π a - star (π (star a))) * (π (star a) - star (π a)) = 0 := by + have e := midpoint_curvature π a (star a) + rw [h a (star a), sub_self] at e + simpa only [star_star] using e.symm + have hz' : (π a - star (π (star a))) * star (π a - star (π (star a))) = 0 := by + have e : π (star a) - star (π a) = -star (π a - star (π (star a))) := by + simp only [star_sub, star_star, neg_sub] + rw [e, mul_neg, neg_eq_zero] at hz + exact hz + have he := (CStarRing.mul_star_self_eq_zero_iff _).mp hz' + have he' := congrArg star (sub_eq_zero.mp he) + simpa only [star_star] using he'.symm + · intro h a b + simp only [h, star_star, map_mul, two_smul] + noncomm_ring + +end Kadison.SimilarityObstruction +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SmoothingSubsequence.lean b/lean/OAI/Analysis/Commutator/SmoothingSubsequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..c7f3fa158d018b0d748f620210571dc1c58f33f4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SmoothingSubsequence.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Commutator.InverseLimit +import OAI.Analysis.Commutator.WeightedSubsequence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter Finset + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma sandwich_nonneg {A B : H →L[ℂ] H} (hA : 0≤A) (hB : IsSelfAdjoint B) : 0≤B*A*B := by + simpa using hB.conjugate_le_conjugate hA + +lemma inverse_sandwich_le (S : H →L[ℂ] H) (hS : 1≤S) {A : H →L[ℂ] H} (hA : A≤S) : + Ring.inverse S*A*Ring.inverse S≤Ring.inverse S := by + let U := (CStarAlgebra.isUnit_of_le 1 hS).unit + have hu : (U:H →L[ℂ] H)=S := IsUnit.unit_spec _ + have hi : Ring.inverse S=(↑U⁻¹:H →L[ℂ] H) := by rw [←hu,Ring.inverse_unit] + have hpos : 0≤(↑U⁻¹:H →L[ℂ] H) := CFC.inv_nonneg_of_nonneg U (by rw [hu]; exact zero_le_one.trans hS) + rw [hi] + have hh := (IsSelfAdjoint.of_nonneg hpos).conjugate_le_conjugate hA + rw [←hu,Units.inv_mul,one_mul] at hh + exact hh + +lemma sandwich_inner {A B : H →L[ℂ] H} (hb : IsSelfAdjoint B) (x y : H) : + inner ℂ ((B*A*B) x) y=inner ℂ (A (B x)) (B y) := by + have hh := ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mp hb (A (B x)) y + exact hh + +lemma sandwich_strong_limit {P : ℕ → H →L[ℂ] H} {B A : H →L[ℂ] H} + (hP : ∀ n,IsSelfAdjoint (P n)) (hB : IsSelfAdjoint B) + (ht : ∀ x,Tendsto (fun n => P n x) atTop (𝓝 (B x))) (x y : H) : + Tendsto (fun n => inner ℂ ((P n*A*P n) x) y) atTop (𝓝 (inner ℂ ((B*A*B) x) y)) := by + simp only [sandwich_inner (hP _),sandwich_inner hB] + exact (A.continuous.tendsto _ |>.comp (ht x)).inner (ht y) + +theorem exists_smoothing_subsequence [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) (A : ℕ → H →L[ℂ] H) (hAM : ∀ n,A n∈M) + (hA : ∀ n,0≤A n) (ht : ∀ x,Tendsto (fun n => A n x) atTop (𝓝 0)) : + ∃ u : ℕ → ℕ,StrictMono u ∧ ∃ B : H →L[ℂ] H, + B∈M ∧ 0≤B ∧ B≤1 ∧ Function.Injective B ∧ + ∀ k,‖B*A (u k)*B‖≤1/((k:ℝ)+1) := by + obtain ⟨v,hv⟩ := TopologicalSpace.exists_dense_seq H + let q (n j : ℕ) := (inner ℂ (A n (v j)) (v j)).re + have hq (n j : ℕ) : 0≤q n j := + (ContinuousLinearMap.nonneg_iff_isPositive.mp (hA n)).re_inner_nonneg_left _ + have hqt (j : ℕ) : Tendsto (fun n => q n j) atTop (𝓝 0) := by + have hh : Tendsto (fun n => (inner ℂ (A n (v j)) (v j)).re) atTop (𝓝 ((inner ℂ (0:H) (v j)).re)) := + Complex.continuous_re.tendsto _ |>.comp ((ht (v j)).inner (tendsto_const_nhds (x:=v j))) + simpa only [q,Function.comp_apply,inner_zero_left,Complex.zero_re] using hh + obtain ⟨u,hu,hbounded⟩ := exists_weighted_subsequence q hq hqt + let S (N : ℕ) : H →L[ℂ] H := 1+∑ k∈range N,((k:ℝ)+1) • A (u k) + have hp (k : ℕ) : 0≤((k:ℝ)+1) • A (u k) := smul_nonneg (by positivity) (hA _) + have hS1 (N : ℕ) : 1≤S N := le_add_of_nonneg_right (sum_nonneg fun k _ => hp k) + have hSM (N : ℕ) : S N∈M := M.add_mem M.one_mem + (M.sum_mem fun k _ => by + rw [RCLike.real_smul_eq_coe_smul (K:=ℂ)] + change (Complex.ofReal ((k:ℝ)+1)) • A (u k)∈M + exact M.toStarSubalgebra.smul_mem (hAM (u k)) (Complex.ofReal ((k:ℝ)+1))) + have hSmono : Monotone S := by + intro n m hnm + exact add_le_add le_rfl (sum_le_sum_of_subset_of_nonneg (range_mono hnm) (fun k _ _ => hp k)) + have hform (N j : ℕ) : (inner ℂ (S N (v j)) (v j)).re= + (inner ℂ (v j) (v j)).re+∑ k∈range N,((k:ℝ)+1)*q (u k) j := by + have hsm (r : ℝ) (T : H →L[ℂ] H) : + inner ℂ ((r • T) (v j)) (v j)=r • inner ℂ (T (v j)) (v j) := by + rw [smul_apply,RCLike.real_smul_eq_coe_smul (K:=ℂ),inner_smul_real_left] + simp only [S,add_apply,one_apply_eq_self, + _root_.sum_apply,inner_add_left,sum_inner,hsm, + Complex.add_re,Complex.re_sum,Complex.smul_re,smul_eq_mul,q] + have hSb (j : ℕ) : ∃ C : ℝ,∀ N,(inner ℂ (S N (v j)) (v j)).re≤C := by + obtain ⟨C,hC⟩ := hbounded j + exact ⟨(inner ℂ (v j) (v j)).re+C,fun N => by rw [hform]; exact add_le_add le_rfl (hC N)⟩ + obtain ⟨B,hBM,hBp,hB1,hBi,hBSl,hBS⟩ := exists_injective_inverse_limit M S hSM hS1 hSmono v hv hSb + refine ⟨u,hu,B,hBM,hBp,hB1,hBi,?_⟩ + intro k + have hBB : IsSelfAdjoint B := IsSelfAdjoint.of_nonneg hBp + have hSipos (n : ℕ) : 0≤Ring.inverse (S n) := by + let U := (CStarAlgebra.isUnit_of_le 1 (hS1 n)).unit + have hu : (U:H →L[ℂ] H)=S n := IsUnit.unit_spec _ + rw [←hu,Ring.inverse_unit] + exact CFC.inv_nonneg_of_nonneg U (by rw [hu]; exact zero_le_one.trans (hS1 n)) + have hSi1 (n : ℕ) : Ring.inverse (S n)≤1 := by + let U := (CStarAlgebra.isUnit_of_le 1 (hS1 n)).unit + have hu : (U:H →L[ℂ] H)=S n := IsUnit.unit_spec _ + rw [←hu,Ring.inverse_unit] + exact CStarAlgebra.inv_le_one (by change 1≤(U:H →L[ℂ] H); rw [hu]; exact hS1 n) + have hsand : B*(((k:ℝ)+1) • A (u k))*B≤1 := by + apply limit_le (sandwich_strong_limit (fun n => IsSelfAdjoint.of_nonneg (hSipos n)) hBB hBS) + filter_upwards [eventually_ge_atTop (k+1)] with n hn + have hle : ((k:ℝ)+1) • A (u k)≤S n := by + have hh : ((k:ℝ)+1) • A (u k)≤∑ j∈range n,((j:ℝ)+1) • A (u j) := + single_le_sum (fun j _ => hp j) (mem_range.mpr (by omega)) + exact hh.trans (le_add_of_nonneg_left zero_le_one) + exact (inverse_sandwich_le (S n) (hS1 n) hle).trans (hSi1 n) + rw [mul_smul_comm,smul_mul_assoc] at hsand + have hnorm := (CStarAlgebra.norm_le_one_iff_of_nonneg _ + (smul_nonneg (by positivity : (0:ℝ)≤(k:ℝ)+1) (sandwich_nonneg (hA _) hBB))).mpr hsand + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg (by positivity : (0:ℝ)≤(k:ℝ)+1)] at hnorm + exact (le_div_iff₀ (by positivity : (0:ℝ)<(k:ℝ)+1)).mpr (by simpa only [mul_comm] using hnorm) + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralCompression.lean b/lean/OAI/Analysis/Commutator/SpectralCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..6539399113fa90033b306290272a27ca39a2a72e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralCompression.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Commutator.SmoothingSubsequence +import OAI.Analysis.Commutator.SpectralThresholdBounds + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma threshold_factor {B : H →L[ℂ] H} (hB : 0≤B) {r : ℝ} (hr : 0 B*A n*B) atTop (𝓝 0)) : + Tendsto (fun n => threshold B r*A n*threshold B r) atTop (𝓝 0) := by + obtain ⟨C,hCB,hBC⟩ := threshold_factor hB hr + have he (n : ℕ) : threshold B r*A n*threshold B r=C*(B*A n*B)*star C := by + nth_rw 1 [←hCB] + nth_rw 1 [←hBC] + simp only [mul_assoc] + simp_rw [he] + simpa only [mul_zero,zero_mul] using (tendsto_const_nhds (x:=C)).mul ht |>.mul (tendsto_const_nhds (x:=star C)) + +lemma positive_compression_bound {A E : H →L[ℂ] H} (hA : 0≤A) (hA1 : A≤1) + (hE : IsStarProjection E) : A≤(2:ℝ) • (E*A*E)+(2:ℝ) • (1-E) := by + let Q := 1-E + have hQ : IsStarProjection Q := hE.one_sub + have hsa : IsSelfAdjoint (E-Q) := hE.isSelfAdjoint.sub hQ.isSelfAdjoint + have hp : 0≤(E-Q)*A*(E-Q) := sandwich_nonneg hA hsa + have hs : A≤(2:ℝ) • (E*A*E)+(2:ℝ) • (Q*A*Q) := by + apply sub_nonneg.mp + convert hp using 1 + dsimp only [Q] + simp only [two_smul ℝ] + noncomm_ring + have hle : Q*A*Q≤Q := by + have hh := hQ.isSelfAdjoint.conjugate_le_conjugate hA1 + simpa only [mul_one,hQ.isIdempotentElem.eq] using hh + have htwo : (2:ℝ) • (Q*A*Q)≤(2:ℝ) • Q := by + simpa only [two_smul ℝ] using add_le_add hle hle + exact hs.trans (add_le_add le_rfl htwo) + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralCutoff.lean b/lean/OAI/Analysis/Commutator/SpectralCutoff.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a5580be0af99ddd8e76345f6629fd606f2c4765 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralCutoff.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.Commutator.PolarSupport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma partialIsometry_of_nonneg {T : H →L[ℂ] H} (hT : 0≤T) : + partialIsometry T=rightSupport T := by + have h : ∀ x : initial T, initialMap T x=(x : H) := by + intro x + refine (absToInitial_dense T).induction_on x + (isClosed_eq (initialMap T).continuous continuous_subtype_val) ?_ + intro y + rw [initialMap_abs] + change T y=CFC.abs T y + rw [CFC.abs_of_nonneg T hT] + ext x + exact h ((initial T).orthogonalProjectionOnto x) + +lemma mul_rightSupport_eq_zero_of_nonneg {T B : H →L[ℂ] H} (hT : 0≤T) + (hBT : B*T=0) : B*rightSupport T=0 := by + have h : ∀ x : initial T, B x=0 := by + intro x + refine (absToInitial_dense T).induction_on x + (isClosed_eq (B.continuous.comp continuous_subtype_val) continuous_const) ?_ + intro y + change B (CFC.abs T y)=0 + rw [CFC.abs_of_nonneg T hT] + exact congrArg (fun R : H →L[ℂ] H => R y) hBT + ext x + exact h ((initial T).orthogonalProjectionOnto x) + +lemma rightSupport_mul_eq_zero_of_nonneg {T B : H →L[ℂ] H} (hT : 0≤T) + (hTB : T*B=0) : rightSupport T*B=0 := by + have hs : star B*T=0 := by + simpa only [star_mul,(IsSelfAdjoint.of_nonneg hT).star_eq,star_zero] using congrArg star hTB + simpa only [star_mul,star_star,(isProjection_rightSupport T).isSelfAdjoint.star_eq,star_zero] using + congrArg star (mul_rightSupport_eq_zero_of_nonneg hT hs) + +lemma posPart_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) : T⁺∈M := by + change T⁺∈M.carrier + rw [←M.centralizer_centralizer'] + intro B hB + exact ((show Commute T B from hB T hT).cfcₙ_real (·⁺)).eq.symm + +def halfCut (T : H →L[ℂ] H) : H →L[ℂ] H := + rightSupport (T+T-(1 : H →L[ℂ] H))⁺ + +lemma isProjection_halfCut (T : H →L[ℂ] H) : IsStarProjection (halfCut T) := + isProjection_rightSupport _ + +lemma halfCut_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) : halfCut T∈M := by + apply rightSupport_mem M + apply posPart_mem M + exact M.toStarSubalgebra.sub_mem (M.add_mem hT hT) M.one_mem + +lemma halfCut_mul_shift {T : H →L[ℂ] H} (hT : IsSelfAdjoint T) : + halfCut T*(T+T-(1 : H →L[ℂ] H))=(T+T-(1 : H →L[ℂ] H))⁺ := by + let b := T+T-(1 : H →L[ℂ] H) + have hb : IsSelfAdjoint b := (hT.add hT).sub (IsSelfAdjoint.one _) + change rightSupport b⁺*b=b⁺ + have hp : rightSupport b⁺*b⁺=b⁺ := by + simpa only [CFC.abs_of_nonneg _ (CFC.posPart_nonneg b)] using initial_mul_abs b⁺ + have hn : rightSupport b⁺*b⁻=0 := + rightSupport_mul_eq_zero_of_nonneg (CFC.posPart_nonneg b) (CFC.posPart_mul_negPart b) + nth_rw 2 [←CFC.posPart_sub_negPart b hb] + rw [mul_sub,hp,hn,sub_zero] + +lemma halfCut_commute {T : H →L[ℂ] H} (hT : IsSelfAdjoint T) : Commute (halfCut T) T := by + let b := T+T-(1 : H →L[ℂ] H) + have hb : Commute b T := ((Commute.refl T).add_left (Commute.refl T)).sub_left (Commute.one_left T) + have hbp : Commute b⁺ T := hb.cfcₙ_real (·⁺) + have hs : Commute b⁺ (star T) := by rwa [hT.star_eq] + change Commute (rightSupport b⁺) T + simpa only [partialIsometry_of_nonneg (CFC.posPart_nonneg b)] using partialIsometry_commutes b⁺ T hbp hs + +lemma halfCut_rounding {T : H →L[ℂ] H} (hT : 0≤T) (hT1 : T≤1) : + star (halfCut T-T)*(halfCut T-T)≤T-T*T := by + let b := T+T-(1 : H →L[ℂ] H) + let q := halfCut T + have hb : IsSelfAdjoint b := ((IsSelfAdjoint.of_nonneg hT).add (IsSelfAdjoint.of_nonneg hT)).sub (IsSelfAdjoint.one _) + have hc : Commute b T := ((Commute.refl T).add_left (Commute.refl T)).sub_left (Commute.one_left T) + have hp : Commute b⁺ T := hc.cfcₙ_real (·⁺) + have hn : Commute b⁻ T := hc.cfcₙ_real (·⁻) + have hpos : 0≤(1-T)*b⁺+T*b⁻ := add_nonneg + (Commute.mul_nonneg (sub_nonneg.mpr hT1) (CFC.posPart_nonneg b) + ((Commute.one_left b⁺).sub_left hp.symm)) + (Commute.mul_nonneg hT (CFC.negPart_nonneg b) hn.symm) + have hqb : q*b=b⁺ := halfCut_mul_shift (IsSelfAdjoint.of_nonneg hT) + have hq : q*q=q := (isProjection_halfCut T).isIdempotentElem.eq + have hcq : q*T=T*q := (halfCut_commute (IsSelfAdjoint.of_nonneg hT)).eq + have hnb : b⁻=q*b-b := by + rw [hqb] + calc + b⁻=b⁺-(b⁺-b⁻) := by abel + _=b⁺-b := by rw [CFC.posPart_sub_negPart b hb] + have he : T-T*T-(q-T)*(q-T)=(1-T)*b⁺+T*b⁻ := by + rw [hnb,←hqb] + dsimp only [b] + noncomm_ring [hq,hcq] + rw [star_sub,(isProjection_halfCut T).isSelfAdjoint.star_eq,(IsSelfAdjoint.of_nonneg hT).star_eq] + exact sub_nonneg.mp (he.symm ▸ hpos) + +end Kadison.Polar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralExhaustion.lean b/lean/OAI/Analysis/Commutator/SpectralExhaustion.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc878fd5cadafa3790384bd0c35105ff92c6e9cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralExhaustion.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionStrong +import OAI.Analysis.Commutator.SpectralThresholdBounds + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem threshold_exhaustion (M : VonNeumannAlgebra H) {B : H →L[ℂ] H} + (hBM : B∈M) (hB : 0≤B) (hi : Function.Injective B) : + Monotone (fun n : ℕ => threshold B (1/((n:ℝ)+1))) ∧ + ∀ x,Tendsto (fun n : ℕ => threshold B (1/((n:ℝ)+1)) x) atTop (𝓝 x) := by + let P (n : ℕ) := threshold B (1/((n:ℝ)+1)) + have hP (n : ℕ) : IsStarProjection (P n) := threshold_projection B _ + have hPM (n : ℕ) : P n∈M := threshold_mem M hBM _ + have hmono : Monotone P := by + intro n m hnm + apply threshold_antitone (IsSelfAdjoint.of_nonneg hB) + apply one_div_le_one_div_of_le (by positivity : (0:ℝ)<(n:ℝ)+1) + exact_mod_cast Nat.add_le_add_right hnm 1 + obtain ⟨W,hWM,hW,hPW,ht,hleast⟩ := ProjectionChains.exists_strong_sup M P hP hPM hmono + have hnorm (n : ℕ) : ‖B*(1-W)‖≤1/((n:ℝ)+1) := by + have he : P n*W=P n := ((hP n).le_iff_mul_eq_left hW).mp (hPW n) + have hid : B*(1-W)=(B*(1-P n))*(1-W) := by noncomm_ring [he] + rw [hid] + calc + _≤‖B*(1-P n)‖*‖1-W‖ := norm_mul_le _ _ + _≤(1/((n:ℝ)+1))*1 := mul_le_mul + (threshold_remainder_norm hB (by positivity)) (hW.one_sub.norm_le _) + (norm_nonneg _) (by positivity) + _=1/((n:ℝ)+1) := mul_one _ + have hz : B*(1-W)=0 := norm_eq_zero.mp (le_antisymm + (ge_of_tendsto (tendsto_one_div_add_atTop_nhds_zero_nat (𝕜:=ℝ)) (Eventually.of_forall hnorm)) + (norm_nonneg _)) + have he : W=1 := by + ext x + have hh : B ((1-W) x)=B 0 := by + rw [map_zero] + exact congrArg (fun T : H →L[ℂ] H => T x) hz + have hx := hi hh + change x-W x=0 at hx + exact (sub_eq_zero.mp hx).symm + refine ⟨hmono,?_⟩ + intro x + simpa only [he,one_apply_eq_self] using ht x + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralStep.lean b/lean/OAI/Analysis/Commutator/SpectralStep.lean new file mode 100644 index 0000000000000000000000000000000000000000..44dc269f0877cd4a337b5c3797c6fd0c7d2f36e1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralStep.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionWeighted +import OAI.Analysis.Commutator.SelfAdjointSpectral +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace Kadison.SpectralPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_spectral_step (M : VonNeumannAlgebra H) (T : H →L[ℂ] H) + (hTM : T∈M) (hT : IsSelfAdjoint T) {ε : ℝ} (hε : 0<ε) : + ∃ (J : Type) (_ : Fintype J) (p : J → H →L[ℂ] H) (c : J → ℝ), + (∀ j,p j∈M ∧ IsStarProjection (p j)) ∧ + (∀ j k,j≠k → p j*p k=0) ∧ (∑ j,p j)=1 ∧ + ‖T-∑ j,c j • p j‖<ε := by + classical + obtain ⟨n,p,c,hp,hc,he⟩ := Polar.exists_selfadjoint_spectral_sum M hTM hT hε + obtain ⟨J,hJ,e,d,hproj,horth,hsum,heq,hcomm⟩ := exists_weighted_partition n p c + (fun i => (hp i).2) hc + let : Fintype J := hJ + refine ⟨J,hJ,e,d,?_,horth,hsum,?_⟩ + · intro j + refine ⟨?_,hproj j⟩ + change e j∈M.toStarSubalgebra.carrier + rw [←M.centralizer_centralizer'] + intro a ha + exact (hcomm a (fun i => (ha (p i) (hp i).1).symm) j).eq + · rwa [←heq] + +theorem exists_spectral_step_subtype (M : VonNeumannAlgebra H) (T : M) + (hT : IsSelfAdjoint T) {ε : ℝ} (hε : 0<ε) : + ∃ (J : Type) (_ : Fintype J) (p : J → M) (c : J → ℝ), + (∀ j,IsStarProjection (p j)) ∧ + (∀ j k,j≠k → p j*p k=0) ∧ (∑ j,p j)=1 ∧ + ‖T-∑ j,(c j:ℂ) • p j‖<ε := by + classical + obtain ⟨J,hJ,p,c,hp,ho,hs,he⟩ := exists_spectral_step M T T.property + (hT.map M.toStarSubalgebra.subtype) hε + let : Fintype J := hJ + let q : J → M := fun j => ⟨p j,(hp j).1⟩ + refine ⟨J,hJ,q,c,?_,?_,?_,?_⟩ + · intro j + constructor + · exact Subtype.ext (hp j).2.isIdempotentElem.eq + · exact Subtype.ext (hp j).2.isSelfAdjoint.star_eq + · intro j k hjk + exact Subtype.ext (ho j k hjk) + · apply Subtype.ext + change M.toStarSubalgebra.subtype (∑ j,q j)=M.toStarSubalgebra.subtype 1 + rw [map_sum,map_one] + exact hs + · change ‖(T : H →L[ℂ] H)-((∑ j,(c j:ℂ) • q j : M) : H →L[ℂ] H)‖<ε + change ‖(T : H →L[ℂ] H)-M.toStarSubalgebra.subtype (∑ j,(c j:ℂ) • q j)‖<ε + simp only [map_sum,Complex.coe_smul] + exact he + +end Kadison.SpectralPartition + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralThreshold.lean b/lean/OAI/Analysis/Commutator/SpectralThreshold.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d33de8bc1197a3fbc32a4044c114682cdfc4bab --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralThreshold.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.Commutator.PositiveCauchySchwarz +import OAI.Analysis.Commutator.PositiveWOT +import OAI.Analysis.Commutator.SpectralCutoff + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma positive_apply_eq_zero {A : H →L[ℂ] H} (ha : 0≤A) {x : H} + (hx : (inner ℂ (A x) x).re=0) : A x=0 := by + have hh := positive_cauchySchwarz A ha x (A x) + rw [hx,zero_mul] at hh + have hn : inner ℂ (A x) (A x)=0 := norm_eq_zero.mp (by nlinarith [norm_nonneg (inner ℂ (A x) (A x))]) + exact (inner_self_eq_zero (𝕜:=ℂ)).mp hn + +lemma rightSupport_mono {A B : H →L[ℂ] H} (hA : 0≤A) (hB : 0≤B) (hab : A≤B) : + Polar.rightSupport A≤Polar.rightSupport B := by + have hp := Polar.isProjection_rightSupport B + have hfix : B*Polar.rightSupport B=B := by + simpa only [CFC.abs_of_nonneg B hB] using Polar.abs_mul_initial B + have he : B*(1-Polar.rightSupport B)=0 := by rw [mul_sub,mul_one,hfix,sub_self] + have ha : A*(1-Polar.rightSupport B)=0 := by + ext x + change A ((1-Polar.rightSupport B) x)=0 + apply positive_apply_eq_zero hA + have hh := inner_mono hab ((1-Polar.rightSupport B) x) + have hz : B ((1-Polar.rightSupport B) x)=0 := congrArg (fun T : H →L[ℂ] H => T x) he + rw [hz,inner_zero_left,Complex.zero_re] at hh + exact le_antisymm hh ((ContinuousLinearMap.nonneg_iff_isPositive.mp hA).re_inner_nonneg_left _) + apply Polar.rightSupport_le A (Polar.rightSupport B) hp + rw [mul_sub,mul_one,sub_eq_zero] at ha + exact ha.symm + +lemma cfc_shift_posPart (B : H →L[ℂ] H) (hB : IsSelfAdjoint B) (r : ℝ) : + (B-r • (1:H →L[ℂ] H))⁺=cfc (fun t : ℝ => (t-r)⁺) B := by + rw [CFC.posPart_def,cfcₙ_eq_cfc] + have he : cfc (fun t : ℝ => t-r) B=B-r • (1:H →L[ℂ] H) := by + change cfc (fun t : ℝ => id t - (fun _ : ℝ => r) t) B = _ + rw [cfc_sub (id : ℝ → ℝ) (fun _ => r),cfc_id ℝ B hB,cfc_const r B hB] + exact congrArg (B-·) (Algebra.algebraMap_eq_smul_one r) + rw [←he] + exact (cfc_comp (fun t : ℝ => t⁺) (fun t : ℝ => t-r) B).symm + +def threshold (B : H →L[ℂ] H) (r : ℝ) : H →L[ℂ] H := + Polar.rightSupport (B-r • (1:H →L[ℂ] H))⁺ + +lemma threshold_projection (B : H →L[ℂ] H) (r : ℝ) : IsStarProjection (threshold B r) := + Polar.isProjection_rightSupport _ + +lemma threshold_mem (M : VonNeumannAlgebra H) {B : H →L[ℂ] H} (hB : B∈M) (r : ℝ) : + threshold B r∈M := by + apply Polar.rightSupport_mem M + apply Polar.posPart_mem M + apply M.toStarSubalgebra.sub_mem hB + rw [RCLike.real_smul_eq_coe_smul (K:=ℂ)] + change (Complex.ofReal r) • (1:H →L[ℂ] H)∈M + exact M.toStarSubalgebra.smul_mem M.one_mem _ + +lemma threshold_antitone {B : H →L[ℂ] H} (hB : IsSelfAdjoint B) : Antitone (threshold B) := by + intro r s hrs + have hle : (B-s • (1:H →L[ℂ] H))⁺≤(B-r • (1:H →L[ℂ] H))⁺ := by + rw [cfc_shift_posPart B hB,cfc_shift_posPart B hB] + exact cfc_mono (R:=ℝ) (a:=B) (fun t _ => sup_le_sup (sub_le_sub_left hrs t) le_rfl) + (Continuous.continuousOn ((continuous_id.sub continuous_const).max continuous_const)) + (Continuous.continuousOn ((continuous_id.sub continuous_const).max continuous_const)) + exact rightSupport_mono (CFC.posPart_nonneg (B-s • (1:H →L[ℂ] H))) + (CFC.posPart_nonneg (B-r • (1:H →L[ℂ] H))) hle + +lemma threshold_commute {B : H →L[ℂ] H} (hB : IsSelfAdjoint B) (r : ℝ) : + Commute (threshold B r) B := by + let a : H →L[ℂ] H := B-r • (1:H →L[ℂ] H) + have hr : Commute (r • (1:H →L[ℂ] H)) B := (Commute.one_left B).smul_left r + have hc : Commute a B := (Commute.refl B).sub_left hr + have hp : Commute a⁺ B := hc.cfcₙ_real (·⁺) + have hs : Commute a⁺ (star B) := by rwa [hB.star_eq] + have hh : Commute (Polar.partialIsometry a⁺) B := Polar.partialIsometry_commutes a⁺ B hp hs + rw [Polar.partialIsometry_of_nonneg (CFC.posPart_nonneg a)] at hh + exact hh + +lemma threshold_mul_shift {B : H →L[ℂ] H} (hB : IsSelfAdjoint B) (r : ℝ) : + threshold B r*(B-r • (1:H →L[ℂ] H))=(B-r • (1:H →L[ℂ] H))⁺ := by + let a := B-r • (1:H →L[ℂ] H) + have ha : IsSelfAdjoint a := hB.sub ((IsSelfAdjoint.all r).smul (IsSelfAdjoint.one _)) + have hp : Polar.rightSupport a⁺*a⁺=a⁺ := by + simpa only [CFC.abs_of_nonneg _ (CFC.posPart_nonneg a)] using Polar.initial_mul_abs a⁺ + have hn : Polar.rightSupport a⁺*a⁻=0 := + Polar.rightSupport_mul_eq_zero_of_nonneg (CFC.posPart_nonneg a) (CFC.posPart_mul_negPart a) + change Polar.rightSupport a⁺*a=a⁺ + nth_rw 2 [←CFC.posPart_sub_negPart a ha] + rw [mul_sub,hp,hn,sub_zero] + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SpectralThresholdBounds.lean b/lean/OAI/Analysis/Commutator/SpectralThresholdBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0f7ba6ee2ade1880b6acfd49d16d072310582e1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SpectralThresholdBounds.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Commutator.SpectralThreshold + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.PositiveWOT + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma threshold_lower {B : H →L[ℂ] H} (hB : IsSelfAdjoint B) (r : ℝ) : + r • threshold B r≤B*threshold B r := by + have hh := CFC.posPart_nonneg (B-r • (1:H →L[ℂ] H)) + rw [←threshold_mul_shift hB r,mul_sub,mul_smul_comm,mul_one, + (threshold_commute hB r).eq] at hh + exact sub_nonneg.mp hh + +lemma threshold_remainder {B : H →L[ℂ] H} (hB : IsSelfAdjoint B) (r : ℝ) : + B*(1-threshold B r)≤r • (1-threshold B r) := by + let a := B-r • (1:H →L[ℂ] H) + have ha : IsSelfAdjoint a := hB.sub ((IsSelfAdjoint.all r).smul (IsSelfAdjoint.one _)) + have he : (1-threshold B r)*a= -a⁻ := by + rw [sub_mul,one_mul,threshold_mul_shift hB r] + change a-a⁺= -a⁻ + nth_rw 1 [←CFC.posPart_sub_negPart a ha] + abel + have hh : (1-threshold B r)*a≤0 := he ▸ neg_nonpos.mpr (CFC.negPart_nonneg a) + dsimp only [a] at hh + rw [mul_sub,mul_smul_comm,mul_one] at hh + have hc : Commute (1-threshold B r) B := (Commute.one_left B).sub_left (threshold_commute hB r) + rw [hc.eq] at hh + exact sub_nonpos.mp hh + +lemma threshold_remainder_nonneg {B : H →L[ℂ] H} (hB : 0≤B) (r : ℝ) : + 0≤B*(1-threshold B r) := by + exact Commute.mul_nonneg hB (threshold_projection B r).one_sub.nonneg + (((Commute.one_left B).sub_left (threshold_commute (IsSelfAdjoint.of_nonneg hB) r)).symm) + +lemma threshold_lower_whole {B : H →L[ℂ] H} (hB : 0≤B) (r : ℝ) : + r • threshold B r≤B := by + have hh := threshold_lower (IsSelfAdjoint.of_nonneg hB) r + have hl : B*threshold B r≤B := by + have hh := threshold_remainder_nonneg hB r + rw [mul_sub,mul_one] at hh + exact sub_nonneg.mp hh + exact hh.trans hl + +lemma threshold_remainder_norm {B : H →L[ℂ] H} (hB : 0≤B) {r : ℝ} (hr : 0≤r) : + ‖B*(1-threshold B r)‖≤r := by + have hh := CStarAlgebra.norm_le_norm_of_le_of_nonneg + (threshold_remainder (IsSelfAdjoint.of_nonneg hB) r) (threshold_remainder_nonneg hB r) + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg hr] at hh + exact hh.trans (by simpa only [mul_one] using + mul_le_mul_of_nonneg_left ((threshold_projection B r).one_sub.norm_le _) hr) + +lemma threshold_completion_unit {B : H →L[ℂ] H} (hB : 0≤B) {r : ℝ} (hr : 0 v.val.val.val) + 1 zero_le_one (fun v => v.val.val.norm_le_one) + have hWM : W∈M := WeakOperatorLimit.mem_vonNeumann hlim M + (Filter.Eventually.of_forall fun v => v.val.val.mem) + have hWe : W*e=W := by + have h := WeakOperatorLimit.intertwine hlim e 1 (Filter.Eventually.of_forall + fun v => by simpa only [one_mul] using v.val.val.mul_source he) + simpa only [one_mul] using h + have heW : e*W=W := by + have h := WeakOperatorLimit.intertwine hlim 1 e (Filter.Eventually.of_forall + fun v => by simpa only [mul_one] using (v.val.val.target_mul he).symm) + simpa only [mul_one] using h.symm + have hWv (v : c) : W*v.val.val.val=0 := by + have hev : ∀ᶠ w : c in (ω : Filter c), v.val≤w.val := + (Filter.eventually_ge_atTop v).filter_mono hω + apply WeakOperatorLimit.right_eq hlim v.val.val.val 0 + filter_upwards [hev] with w hw + have hfix := (Link.le_def v.val.val w.val.val).mp hw |>.2 + calc + _=w.val.val.val*(w.val.val.val*v.val.val.initial) := by rw [hfix] + _=0 := by rw [←mul_assoc,w.val.property,zero_mul] + have hWW : W*W=0 := by + ext x + apply ext_inner_right ℂ + intro y + have hs : ∀ v : c, inner ℂ (v.val.val.val x) (star W y)=0 := by + intro v + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + simpa only [mul_apply_eq_comp,zero_apply,inner_zero_left] using + congrArg (fun U : H →L[ℂ] H => inner ℂ (U x) y) (hWv v) + have hl := hlim x (star W y) + simp only [hs] at hl + have h := tendsto_nhds_unique hl tendsto_const_nhds + simpa only [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right, + mul_apply_eq_comp,zero_apply,inner_zero_left] using h + let u : Link M e e := + { val := Polar.partialIsometry W + mem := Polar.partialIsometry_mem_vonNeumann M hWM + triple := Polar.partialIsometry_triple W + source_le := by rw [Polar.partialIsometry_initial]; exact Polar.rightSupport_le W e he hWe + target_le := Polar.leftSupport_le W e he heW } + let u' : SquareZeroLink M e := ⟨u,Polar.partialIsometry_square_zero W hWW⟩ + refine ⟨u',?_⟩ + intro v hv + have hev : ∀ᶠ w : c in (ω : Filter c), v≤w.val := + (Filter.eventually_ge_atTop (⟨v,hv⟩ : c)).filter_mono hω + have hWext : W*v.val.initial=v.val.val := WeakOperatorLimit.right_eq hlim v.val.initial v.val.val + (hev.mono fun w hw => (Link.le_def v.val w.val.val).mp hw |>.2) + have hExt := Polar.partialIsometry_extends hnW v.val.triple hWext + change v.val≤u + apply (Link.le_def v.val u).mpr + constructor + · change v.val.initial ≤ star (Polar.partialIsometry W)*Polar.partialIsometry W + rw [Polar.partialIsometry_initial] + exact hExt.2 + · exact hExt.1 + +theorem exists_maximal_squareZero : ∃ v : SquareZeroLink M e, IsMax v := by + let v0 : Link M e e := + { val := 0 + mem := M.zero_mem + triple := by simp + source_le := by simpa using he.nonneg + target_le := by simpa using he.nonneg } + let : Nonempty (SquareZeroLink M e) := ⟨⟨v0,by simp [v0]⟩⟩ + exact zorn_le_nonempty (squareZero_chain_has_upper M he) + +end Kadison.PartialIsometryOrder + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SquareZeroPolar.lean b/lean/OAI/Analysis/Commutator/SquareZeroPolar.lean new file mode 100644 index 0000000000000000000000000000000000000000..82ded7cab956ae3f4ae2efe6620fde0dd98b7fd7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SquareZeroPolar.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialIsometryOrder +import OAI.Analysis.Commutator.PolarSupport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace Topology + +namespace Kadison.Polar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma partialIsometry_square_zero (T : H →L[ℂ] H) (hT : T*T=0) : + partialIsometry T*partialIsometry T=0 := by + let K : Submodule ℂ H := LinearMap.ker T.toLinearMap + let : CompleteSpace K := T.isClosed_ker.completeSpace_coe + let e : H →L[ℂ] H := K.starProjection + have he : IsStarProjection e := isStarProjection_starProjection + have heT : e*T=T := by + ext x + apply Submodule.starProjection_eq_self_iff.mpr + exact congrArg (fun R : H →L[ℂ] H => R x) hT + have hTe : T*e=0 := by + ext x + exact K.starProjection_apply_mem x + have hTcomp : T*(1-e)=T := by rw [mul_sub,mul_one,hTe,sub_zero] + have hsource := rightSupport_le T (1-e) he.one_sub hTcomp + have hes : e*partialIsometry T=partialIsometry T := mul_partialIsometry_of_mul T e heT + have hP : (rightSupport T)*(1-e)=rightSupport T := + ((isProjection_rightSupport T).le_iff_mul_eq_left he.one_sub).mp hsource + have hPe : rightSupport T*e=0 := by + rw [mul_sub,mul_one] at hP + exact sub_eq_self.mp hP + have hse : partialIsometry T*e=0 := by + calc + _=(partialIsometry T*rightSupport T)*e := by rw [rightSupport,partialIsometry_mul_initial] + _=0 := by rw [mul_assoc,hPe,mul_zero] + calc + _=partialIsometry T*(e*partialIsometry T) := by rw [hes] + _=0 := by rw [←mul_assoc,hse,zero_mul] + +end Kadison.Polar + +namespace Kadison.PartialIsometryOrder.Link + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {M : VonNeumannAlgebra H} {e f : H →L[ℂ] H} + +lemma initial_mul_final_eq_zero (v : Link M e f) (hv : v.val*v.val=0) : + v.initial*v.final=0 := by + change (star v.val*v.val)*(v.val*star v.val)=0 + calc + _=star v.val*(v.val*v.val)*star v.val := by noncomm_ring + _=0 := by rw [hv,mul_zero,zero_mul] + +lemma initial_mul_self_eq_zero (v : Link M e f) (hv : v.val*v.val=0) : + v.initial*v.val=0 := by + change (star v.val*v.val)*v.val=0 + rw [mul_assoc,hv,mul_zero] + +lemma self_mul_final_eq_zero (v : Link M e f) (hv : v.val*v.val=0) : + v.val*v.final=0 := by + change v.val*(v.val*star v.val)=0 + rw [←mul_assoc,hv,zero_mul] + +end Kadison.PartialIsometryOrder.Link + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableCenterRange.lean b/lean/OAI/Analysis/Commutator/StableCenterRange.lean new file mode 100644 index 0000000000000000000000000000000000000000..2c6c8b41a1c7f0d038861efa6b3618010719836c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableCenterRange.lean @@ -0,0 +1,34 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteCenter +import OAI.Analysis.Commutator.UnitaryCenterTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +namespace Kadison.InfiniteAmplification + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma stable_center_range (M : VonNeumannAlgebra H) (U : Space ℕ H ≃ₗᵢ[ℂ] K) + (Z : K →L[ℂ] K) (hZ : Z∈CentralCorner.center (UnitaryTransport.algebra U (algebra M))) : + ∃ a : CentralCorner.center M,U.conjStarAlgEquiv (map a.val)=Z := by + obtain ⟨T,hT,hTZ⟩ := UnitaryTransport.center_range U (algebra M) Z hZ + obtain ⟨a,ha⟩ := center_range M T hT + exact ⟨a,by rw [ha]; exact hTZ⟩ + +end Kadison.InfiniteAmplification + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableCentralSpectral.lean b/lean/OAI/Analysis/Commutator/StableCentralSpectral.lean new file mode 100644 index 0000000000000000000000000000000000000000..aab0bdc77ee9508aa73fd557eec5b2d768ced903 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableCentralSpectral.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Commutator.AbelianSpectralIndicators +import OAI.Analysis.Commutator.StableGNSModule +import OAI.Analysis.Commutator.StableSpectralUnitary +import OAI.Analysis.Commutator.InfiniteSeparable + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace ComplexOrder + +namespace Kadison.CentralSpectral + +open CyclicSpectral Decomposable InfiniteAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +theorem exists_stable_center_spectral_model [TopologicalSpace.SeparableSpace H] : + ∃ μ : Measure (Spectrum M), IsFiniteMeasure μ ∧ + ∃ U : Space ℕ H ≃ₗᵢ[ℂ] Lp (Space ℕ ℂ) 2 μ, + (∀ (a : CentralCorner.center M) (v : Space ℕ H), + U (map (a : H →L[ℂ] H) v)= + scalarVectorMultiplier μ (gelfandStarTransform _ a) (U v)) ∧ + (∀ (s : Set (Spectrum M)) (hs : MeasurableSet s), + ∃ a : CentralCorner.center M, + scalarMultiplier μ (gelfandStarTransform _ a)=indicatorOperator μ s hs) ∧ + TopologicalSpace.SeparableSpace (Lp (Space ℕ ℂ) 2 μ) := by + obtain ⟨τ,hn,hf,W,hW⟩ := NormalRepresentation.exists_stable_gns_model (CentralCorner.center M) + obtain ⟨μ,hμ,V,hV⟩ := CyclicSpectral.exists_gelfand_model τ.gnsStarAlgHom + (TracialGNS.vacuum τ) (by + have he : (fun a => τ.gnsStarAlgHom a (TracialGNS.vacuum τ))= + (fun a => TracialGNS.algebraVector τ a) := + funext (fun a => TracialGNS.left_vacuum τ a) + rw [he] + exact TracialGNS.algebraVector_dense τ) + let U := stableUnitary μ W V + refine ⟨μ,hμ,U,?_,?_,?_⟩ + · intro a v + exact stableUnitary_intertwines μ W V a.val (τ.gnsStarAlgHom a) + (gelfandStarTransform _ a) (hW a) (hV a) v + · intro s hs + exact indicator_in_scalar_spectral_range M τ μ V hn hV s hs + · let : TopologicalSpace.SeparableSpace (Space ℕ H) := separable_space + exact U.symm.isometry.isEmbedding.separableSpace + +end Kadison.CentralSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableGNSModule.lean b/lean/OAI/Analysis/Commutator/StableGNSModule.lean new file mode 100644 index 0000000000000000000000000000000000000000..8e26fcd154de48e45056222b0953379413e7f91d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableGNSModule.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.Commutator.CountableGNSColumn +import OAI.Analysis.Commutator.FaithfulVectorGNS +import OAI.Analysis.Commutator.HilbertModuleSchroederBernstein +import OAI.Analysis.Commutator.InfiniteReindex + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped Topology InnerProductSpace ComplexOrder + +namespace Kadison.InfiniteAmplification + +variable {ι H G : Type*} [Countable ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + +def stableEmbedding (V : H →ₗᵢ[ℂ] Space ι G) : Space ℕ H →ₗᵢ[ℂ] Space ℕ G := + letI := Encodable.ofCountable (ℕ×ι) + (reindex (Encodable.encode' (ℕ×ι))).comp (flatten.comp (mapIsometry V)) + +omit [CompleteSpace H] [CompleteSpace G] in +lemma stableEmbedding_intertwines (V : H →ₗᵢ[ℂ] Space ι G) + (S : H →L[ℂ] H) (T : G →L[ℂ] G) (hV : ∀ x i,V (S x) i=T (V x i)) + (x : Space ℕ H) : + stableEmbedding V (map S x)=map T (stableEmbedding V x) := by + let := Encodable.ofCountable (ℕ×ι) + change reindex (Encodable.encode' (ℕ×ι)) (flatten (mapIsometry V (map S x)))= + map T (reindex (Encodable.encode' (ℕ×ι)) (flatten (mapIsometry V x))) + rw [←reindex_intertwines] + congr 1 + ext p + exact hV (x p.1) p.2 + +private lemma stable_unitary_of_embeddings {A : Type*} [CStarAlgebra A] + (φ : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (ψ : A →⋆ₐ[ℂ] (G →L[ℂ] G)) + (V : H →ₗᵢ[ℂ] Space ι G) (W : G →ₗᵢ[ℂ] Space ℕ H) + (hV : ∀ a x i, V (φ a x) i=ψ a (V x i)) + (hW : ∀ a x i, W (ψ a x) i=φ a (W x i)) : + ∃ U : Space ℕ H ≃ₗᵢ[ℂ] Space ℕ G, + ∀ a x, U (map (φ a) x)=map (ψ a) (U x) := by + exact HilbertModuleSB.exists_unitary_of_embeddings + ((diagonal (ι:=ℕ) (H:=H)).comp φ) ((diagonal (ι:=ℕ) (H:=G)).comp ψ) + (stableEmbedding V) (stableEmbedding W) + (fun a x => stableEmbedding_intertwines V (φ a) (ψ a) (hV a) x) + (fun a x => stableEmbedding_intertwines W (ψ a) (φ a) (hW a) x) + +end InfiniteAmplification + +namespace NormalRepresentation + +open InfiniteAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +private lemma stable_gns_model_of_embedding [TopologicalSpace.SeparableSpace H] + (τ : M →ₚ[ℂ] ℂ) (hn : NormalGNS.BoundedWOTContinuous M τ) + (hf : ∀ a, τ (star a*a)=0 → a=0) + (W : τ.GNS →ₗᵢ[ℂ] Space ℕ H) + (hW : ∀ (a : M) x i, W (τ.gnsStarAlgHom a x) i=a.val (W x i)) : + ∃ U : Space ℕ H ≃ₗᵢ[ℂ] Space ℕ τ.GNS, + ∀ (a : M) x, U (map a.val x)=map (τ.gnsStarAlgHom a) (U x) := by + have embeddings := exists_countable_gns_embedding (H:=H) M τ hn hf + obtain ⟨ι,hι,V,hV⟩ := embeddings + let : Countable ι := hι + exact stable_unitary_of_embeddings (H:=H) (G:=τ.GNS) (ι:=ι) (A:=M) + M.subtype τ.gnsStarAlgHom V W hV hW + +theorem exists_stable_gns_model [TopologicalSpace.SeparableSpace H] : + ∃ τ : M →ₚ[ℂ] ℂ, NormalGNS.BoundedWOTContinuous M τ ∧ + (∀ a,τ (star a*a)=0 → a=0) ∧ + ∃ U : Space ℕ H ≃ₗᵢ[ℂ] Space ℕ τ.GNS, + ∀ (a : M) x,U (map (a : H →L[ℂ] H) x)=map (τ.gnsStarAlgHom a) (U x) := by + let x : ℕ → H := TopologicalSpace.denseSeq H + have hx : DenseRange x := TopologicalSpace.denseRange_denseSeq H + let τ := FaithfulNormalFunctional.restricted x M + have hn := FaithfulNormalFunctional.restricted_normal x M + have hf := FaithfulNormalFunctional.restricted_faithful x M hx + refine ⟨τ,hn,hf,?_⟩ + exact stable_gns_model_of_embedding M τ hn hf + (FaithfulNormalFunctional.gnsEmbedding x M) + (FaithfulNormalFunctional.gnsEmbedding_intertwines x M) + +end NormalRepresentation + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableModelBound.lean b/lean/OAI/Analysis/Commutator/StableModelBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..a835c8b975b067e2dde320a1d27852e90b7cc820 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableModelBound.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralSpectralGeometry +import OAI.Analysis.Commutator.CentralSpectralModel +import OAI.Analysis.Commutator.InfiniteSeparable +import OAI.Analysis.Commutator.UnitaryBoundTransfer + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace ComplexOrder + +namespace Kadison.CentralSpectral + +open CyclicSpectral Decomposable InfiniteAmplification + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (μ : Measure (Spectrum M)) + +variable (U : Space ℕ H ≃ₗᵢ[ℂ] Lp (Space ℕ ℂ) 2 μ) + +variable (hU : ∀ (a : CentralCorner.center M) (v : Space ℕ H), + U (map (a : H →L[ℂ] H) v)=scalarVectorMultiplier μ (gelfandStarTransform _ a) (U v)) + +variable (hind : ∀ (s : Set (Spectrum M)) (hs : MeasurableSet s), + ∃ a : CentralCorner.center M, + scalarMultiplier μ (gelfandStarTransform _ a)=indicatorOperator μ s hs) + +include hU hind + +lemma stable_model_indicators [IsFiniteMeasure μ] (s : Set (Spectrum M)) (hs : MeasurableSet s) : + indicatorOperator (H:=Space ℕ ℂ) μ s hs∈UnitaryTransport.algebra U (algebra M) ∧ + indicatorOperator (H:=Space ℕ ℂ) μ s hs∈Set.centralizer + (UnitaryTransport.algebra U (algebra M) : Set _) := + (CentralCorner.mem_center _ _).mp (central_indicators M μ U hU hind s hs) + +omit hind in +lemma stable_model_center [IsFiniteMeasure μ] (Z : Lp (Space ℕ ℂ) 2 μ →L[ℂ] Lp (Space ℕ ℂ) 2 μ) + (hZ : Z∈UnitaryTransport.algebra U (algebra M)) + (hZc : Z∈(UnitaryTransport.algebra U (algebra M)).commutant) + (C : Space ℕ ℂ →L[ℂ] Space ℕ ℂ) : + Commute (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) Z := + center_commutes_constant M μ U hU Z ⟨hZ,hZc⟩ C + +variable [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace (Lp (Space ℕ ℂ) 2 μ)] + +lemma stable_model_bound (Y : Space ℕ H →L[ℂ] Space ℕ H) + (h : ℕ) (hh : 1≤h) (X : Matrix (Fin h) (Fin h) (Space ℕ H →L[ℂ] Space ℕ H)) + (hX : ∀ i j,X i j∈algebra M) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm (algebra M) Y*‖matrixOperator h X‖ := by + let : TopologicalSpace.SeparableSpace (Space ℕ ℂ) := separable_space + apply UnitaryTransport.bound_of_conjugate_bound U (algebra M) Y h X 9368 + exact uniform_commutator_in_central_spectral_model μ (UnitaryTransport.algebra U (algebra M)) + (stable_model_indicators M μ U hU hind) (stable_model_center M μ U hU) + (U.conjStarAlgEquiv Y) h hh (fun i j => U.conjStarAlgEquiv (X i j)) + (fun i j => (UnitaryTransport.mem_algebra U (algebra M) _).mpr (hX i j)) + +end Kadison.CentralSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableScalarGeometry.lean b/lean/OAI/Analysis/Commutator/StableScalarGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..f0bb3c00d672fa46be52ea81329430f8e699db0d --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableScalarGeometry.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpectralUnitary +import OAI.Analysis.Commutator.L2InfiniteSumCoordinates +import OAI.Analysis.Commutator.ScalarIndicator + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +open InfiniteAmplification + +variable {Ω H ι : Type*} [MeasurableSpace Ω] (μ : Measure Ω) [Countable ι] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [Countable ι] [CompleteSpace H] in +lemma evalL_indicator (i : ι) (s : Set Ω) (hs : MeasurableSet s) (v : Lp (Space ι H) 2 μ) : + evalL μ i (indicatorOperator μ s hs v)=indicatorOperator μ s hs (evalL μ i v) := by + classical + apply Lp.ext + filter_upwards [ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) + (indicatorOperator μ s hs v),indicatorOperator_ae μ s hs v, + indicatorOperator_ae μ s hs (evalL μ i v), + ContinuousLinearMap.coeFn_compLp (lp.evalCLM ℂ (fun _ : ι => H) 2 i) v] with x h₁ h₂ h₃ h₄ + change ((lp.evalCLM ℂ (fun _ : ι => H) 2 i).compLp (indicatorOperator μ s hs v)) x=_ + rw [h₁,h₃] + change (indicatorOperator μ s hs v) x i=s.indicator (evalL μ i v) x + rw [h₂] + by_cases hx : x∈s + · simp only [Set.indicator_of_mem hx] + exact h₄.symm + · simp [hx] + +variable [TopologicalSpace Ω] [T2Space Ω] [CompactSpace Ω] [BorelSpace Ω] + +omit [T2Space Ω] in +lemma vector_indicator_of_scalar (f : C(Ω,ℂ)) (s : Set Ω) (hs : MeasurableSet s) + (hf : CyclicSpectral.scalarMultiplier μ f=indicatorOperator μ s hs) : + scalarVectorMultiplier (H:=Space ι ℂ) μ f=indicatorOperator μ s hs := by + apply ContinuousLinearMap.ext + intro v + apply sub_eq_zero.mp + apply evalL_separates μ + intro i + rw [map_sub,evalL_scalarMultiplier,evalL_indicator] + change (CyclicSpectral.scalarMultiplier μ f) (evalL μ i v)-indicatorOperator μ s hs (evalL μ i v)=0 + rw [hf,sub_self] + +omit [T2Space Ω] in +lemma scalarVectorMultiplier_commutes_constant (f : C(Ω,ℂ)) (C : H →L[ℂ] H) : + Commute (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl))) (scalarVectorMultiplier μ f) := by + apply ContinuousLinearMap.ext + intro v + apply Lp.ext + filter_upwards [operator_ae μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) (scalarVectorMultiplier μ f v), + scalarVectorMultiplier_ae μ f v, + scalarVectorMultiplier_ae μ f (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) v), + operator_ae μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) v] with x h₁ h₂ h₃ h₄ + change operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) (scalarVectorMultiplier μ f v) x= + scalarVectorMultiplier μ f (operator μ (fun _ => C) (fun _ => aestronglyMeasurable_const) + (Eventually.of_forall (fun _ => le_rfl)) v) x + rw [h₁,h₂,h₃,h₄] + exact C.map_smul _ _ + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableSpectralUnitary.lean b/lean/OAI/Analysis/Commutator/StableSpectralUnitary.lean new file mode 100644 index 0000000000000000000000000000000000000000..be8837875fc08425848a22fde078b6fe8969d030 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableSpectralUnitary.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpectralUnitary +import OAI.Analysis.Commutator.InfiniteUnitary +import OAI.Analysis.Commutator.L2InfiniteSumCoordinates + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory + +open scoped Topology InnerProductSpace + +namespace Kadison.CyclicSpectral + +open InfiniteAmplification Decomposable + +variable {Ω H G : Type*} [MeasurableSpace Ω] [TopologicalSpace Ω] [CompactSpace Ω] + [BorelSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + +def stableUnitary (W : Space ℕ H ≃ₗᵢ[ℂ] Space ℕ G) (V : Lp ℂ 2 μ ≃ₗᵢ[ℂ] G) : + Space ℕ H ≃ₗᵢ[ℂ] Lp (Space ℕ ℂ) 2 μ := + W.trans ((mapEquiv (ι:=ℕ) V.symm).trans (infiniteSumEquiv (ι:=ℕ) μ)) + +lemma stableUnitary_intertwines (W : Space ℕ H ≃ₗᵢ[ℂ] Space ℕ G) (V : Lp ℂ 2 μ ≃ₗᵢ[ℂ] G) + (S : H →L[ℂ] H) (T : G →L[ℂ] G) (f : C(Ω,ℂ)) + (hW : ∀ x,W (map S x)=map T (W x)) + (hV : ∀ x,V (scalarMultiplier μ f x)=T (V x)) (v : Space ℕ H) : + stableUnitary μ W V (map S v)=scalarVectorMultiplier μ f (stableUnitary μ W V v) := by + change infiniteSumEquiv μ (mapEquiv V.symm (W (map S v)))=_ + rw [hW] + have he : ∀ x,V.symm (T x)=scalarMultiplier μ f (V.symm x) := by + intro x + apply V.injective + rw [V.apply_symm_apply,hV,V.apply_symm_apply] + rw [mapEquiv_intertwines V.symm _ _ he] + exact infiniteSumEquiv_scalar μ f _ + +end Kadison.CyclicSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StableUniversalAssembly.lean b/lean/OAI/Analysis/Commutator/StableUniversalAssembly.lean new file mode 100644 index 0000000000000000000000000000000000000000..0eb54906e63a42c22f4300a552e84a4b8ceb7a73 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StableUniversalAssembly.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.Commutator.InfiniteBoundTransfer +import OAI.Analysis.Commutator.SeparableUniverseTransfer +import OAI.Analysis.Commutator.StableCentralSpectral +import OAI.Analysis.Commutator.StableModelBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace ComplexOrder + +namespace Kadison.CentralSpectral + +open CyclicSpectral Decomposable InfiniteAmplification + +theorem separable_uniform_bound : SeparableTest.SeparableBound.{0} 9368 := by + intro H _ _ _ _ M Y h hh X hX + obtain ⟨μ,hμ,U,hU,hind,hsep⟩ := exists_stable_center_spectral_model M + let : IsFiniteMeasure μ := hμ + let : TopologicalSpace.SeparableSpace (Space ℕ ℂ) := separable_space + let : TopologicalSpace.SeparableSpace (Lp (Space ℕ ℂ) 2 μ) := hsep + apply bound_of_stable_bound M Y h X hX (by norm_num) + exact stable_model_bound M μ U hU hind (map Y) h hh (fun i j => map (ι:=ℕ) (X i j)) + (fun i j => map_mem_algebra M _ (hX i j)) + +theorem universal_bound {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] (P : VonNeumannAlgebra H) (Y : H →L[ℂ] H) + (h : ℕ) (hh : 1≤h) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) + (hX : ∀ i j,X i j∈P) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + 9368*commutatorSeminorm P Y*‖matrixOperator h X‖ := + SeparableTest.bound_of_small_separable_bound P Y h hh X hX (by norm_num) separable_uniform_bound + +end Kadison.CentralSpectral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StageAverage.lean b/lean/OAI/Analysis/Commutator/StageAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..975f4b3403a70d44861913f521aa6eb70dd3961e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StageAverage.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Commutator.Average +import OAI.Analysis.Commutator.CompactAverage +import OAI.Analysis.Commutator.WeakConvergence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open MeasureTheory MeasureTheory.Measure Filter + +namespace Kadison.CompactAverage + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (G : ℕ → Type*) [∀ n, Group (G n)] [∀ n, TopologicalSpace (G n)] + [∀ n, IsTopologicalGroup (G n)] [∀ n, CompactSpace (G n)] + [∀ n, MeasurableSpace (G n)] [∀ n, BorelSpace (G n)] + +variable (U : ∀ n, G n →* (H ≃ₗᵢ[ℂ] H)) + (hU : ∀ n x, Continuous fun g => U n g x) + (hnest : ∀ i j, i≤j → ∀ g : G i, ∃ k : G j, U j k=U i g) + +variable (μ : ∀ n, Measure (G n)) [∀ n, IsProbabilityMeasure (μ n)] [∀ n, IsMulLeftInvariant (μ n)] + +variable (Y : H →L[ℂ] H) + +omit [∀ n, IsMulLeftInvariant (μ n)] in +include hU in +lemma scalar_integrable (n : ℕ) (x y : H) : + Integrable (fun g => inner ℂ (conjugate (U n) Y g x) y) (μ n) := + ((conjugate_continuous (U n) (hU n) Y x).inner continuous_const).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + +include hU hnest μ in +theorem exists_stage_average {ι : Type*} (a : ι → H →L[ℂ] H) (C : ι → ℝ) + (hC : ∀ i, 0≤C i) + (hb : ∀ n g i, ‖conjugate (U n) Y g * a i-a i*conjugate (U n) Y g‖≤C i) + (p q s : H →L[ℂ] H) + (hc : ∀ n g, p*(conjugate (U n) Y g*s-s*conjugate (U n) Y g)*q = p*(Y*s-s*Y)*q) : + ∃ V : H →L[ℂ] H, ‖V‖≤‖Y‖ ∧ + (∀ n g, V*(U n g : H →L[ℂ] H)=(U n g : H →L[ℂ] H)*V) ∧ + (∀ i, ‖V*a i-a i*V‖≤C i) ∧ p*(V*s-s*V)*q=p*(Y*s-s*Y)*q := by + choose T hT hcomm hcoeff using fun n => exists_average (U n) (hU n) Y (μ n) + let ω : Ultrafilter ℕ := Ultrafilter.of atTop + obtain ⟨V,hV,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω T ‖Y‖ (norm_nonneg _) hT + have hconv : WeakOperatorLimit.Converges T V (ω:Filter ℕ) := hlim + refine ⟨V,hV,?_,?_,?_⟩ + · intro n g + apply hconv.commutes + have he : ∀ᶠ j : ℕ in atTop, T j*(U n g : H →L[ℂ] H)=(U n g : H →L[ℂ] H)*T j := by + filter_upwards [eventually_ge_atTop n] with j hj + obtain ⟨k,hk⟩ := hnest n j hj g + simpa only [hk] using hcomm j k + exact (Ultrafilter.of_le atTop) he + · intro i + apply hconv.commutator_norm (a i) (hC i) + exact Eventually.of_forall fun n => WeakOperatorIntegral.commutator_norm (μ n) + (conjugate (U n) Y) (scalar_integrable G U hU μ Y n) (T n) (hcoeff n) + (a i) (hC i) (fun g => hb n g i) + · apply (hconv.commutator s).preserves_sandwich + exact Eventually.of_forall fun n => WeakOperatorIntegral.preserves_compressed_commutator + (μ n) (conjugate (U n) Y) (scalar_integrable G U hU μ Y n) (T n) (hcoeff n) + p q s (p*(Y*s-s*Y)*q) (hc n) + +end Kadison.CompactAverage + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StageDensity.lean b/lean/OAI/Analysis/Commutator/StageDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a037dc0c281a9ebab249687582944c32a693774 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StageDensity.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixGNS + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +open Matrix + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a*b) = τ (b*a)) (h1 : τ 1 = 1) + +variable {I : Type*} [Fintype I] [DecidableEq I] [Nonempty I] + +omit [Nonempty I] in +lemma centeredStageVector_sub_trace (φ : Matrix I I ℂ →⋆ₐ[ℂ] A) + (a : Matrix I I ℂ) : + centeredStageVector τ φ (a - ((Fintype.card I : ℂ)⁻¹ * a.trace) • 1) = + centeredStageVector τ φ a := by + rw [map_sub, map_smul] + have hz : centeredStageVector τ φ 1 = 0 := by + change center (vacuum τ) (stageVector τ φ 1) = 0 + rw [stage_vacuum, center_vacuum] + rw [hz, smul_zero, sub_zero] + +lemma trace_sub_normalized_trace (a : Matrix I I ℂ) : + (a - ((Fintype.card I : ℂ)⁻¹ * a.trace) • 1).trace = 0 := by + have hn : (Fintype.card I : ℂ) ≠ 0 := by exact_mod_cast Fintype.card_ne_zero + simp only [Matrix.trace_sub, Matrix.trace_smul, Matrix.trace_one, smul_eq_mul] + field_simp + simp + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] + [∀ n, Nonempty (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + +def stageSet (n : ℕ) : Set τ.GNS := Set.range (stageVector τ (φ n)) + +def centeredStageSet (n : ℕ) : Set (centeredSpace (vacuum τ)) := + {x | ∃ a : Matrix (I n) (I n) ℂ, a.trace = 0 ∧ centeredStageVector τ (φ n) a = x} + +lemma centeredStageSet_eq (n : ℕ) : + centeredStageSet τ I φ n = (center (vacuum τ)) '' stageSet τ I φ n := by + ext x + constructor + · rintro ⟨a, _, rfl⟩ + exact ⟨stageVector τ (φ n) a, ⟨a, rfl⟩, rfl⟩ + · rintro ⟨_, ⟨a, rfl⟩, rfl⟩ + exact ⟨a - ((Fintype.card (I n) : ℂ)⁻¹ * a.trace) • 1, + trace_sub_normalized_trace a, centeredStageVector_sub_trace τ (φ n) a⟩ + +lemma dense_centeredStageSet (hd : Dense (⋃ n, stageSet τ I φ n)) : + Dense (⋃ n, centeredStageSet τ I φ n) := by + have hs : Function.Surjective (center (vacuum τ)) := + fun x => ⟨x, center_centered (vacuum τ) x⟩ + have hi : (⋃ n, centeredStageSet τ I φ n) = + (center (vacuum τ)) '' (⋃ n, stageSet τ I φ n) := by + simp only [centeredStageSet_eq, Set.image_iUnion] + rw [hi] + exact hs.denseRange.dense_image (center (vacuum τ)).continuous hd + +variable (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + +variable (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + +omit [∀ n, Nonempty (I n)] in +include e he in +lemma stageSet_mono : Monotone (stageSet τ I φ) := by + intro n m hnm x hx + obtain ⟨a, rfl⟩ := hx + refine ⟨e hnm a, ?_⟩ + change algebraVector τ (φ m (e hnm a)) = algebraVector τ (φ n a) + rw [he] + +include e he in +lemma centeredStageSet_mono : Monotone (centeredStageSet τ I φ) := by + intro n m hnm + rw [centeredStageSet_eq, centeredStageSet_eq] + exact Set.image_mono (stageSet_mono τ I φ e he hnm) + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StageGeneration.lean b/lean/OAI/Analysis/Commutator/StageGeneration.lean new file mode 100644 index 0000000000000000000000000000000000000000..a695e3812f1138c3b59fb972165da75abc3aa079 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StageGeneration.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantOrbit +import OAI.Analysis.Commutator.StageDensity + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) + +variable (I : ℕ → Type*) [∀ n, Fintype (I n)] [∀ n, DecidableEq (I n)] + +variable (φ : ∀ n, Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] A) + +def operatorStage (n : ℕ) : StarSubalgebra ℂ (τ.GNS →L[ℂ] τ.GNS) := + (τ.gnsStarAlgHom.comp (φ n)).range + +def stageAlgebra : StarSubalgebra ℂ (τ.GNS →L[ℂ] τ.GNS) := + ⨆ n, operatorStage τ I φ n + +variable (e : ∀ {n m : ℕ}, n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + +variable (he : ∀ n m (h : n ≤ m) a, φ m (e h a) = φ n a) + +include e he in +lemma operatorStage_mono : Monotone (operatorStage τ I φ) := by + intro n m hnm x hx + obtain ⟨a, rfl⟩ := hx + refine ⟨e hnm a, ?_⟩ + change τ.gnsStarAlgHom (φ m (e hnm a)) = τ.gnsStarAlgHom (φ n a) + rw [he] + +include e he in +lemma orbit_stageAlgebra : + (orbitSubmodule (stageAlgebra τ I φ) (vacuum τ) : Set τ.GNS) = + ⋃ n, stageSet τ I φ n := by + have hS : (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)) = + ⋃ n, (operatorStage τ I φ n : Set (τ.GNS →L[ℂ] τ.GNS)) := + StarSubalgebra.coe_iSup_of_directed (operatorStage_mono τ I φ e he).directed_le + ext x + constructor + · rintro ⟨a, ha, rfl⟩ + change a ∈ (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)) at ha + rw [hS] at ha + obtain ⟨n, hn⟩ := Set.mem_iUnion.mp ha + obtain ⟨b, rfl⟩ := hn + refine Set.mem_iUnion.mpr ⟨n, b, ?_⟩ + exact (left_vacuum τ (φ n b)).symm + · intro hx + obtain ⟨n, b, rfl⟩ := Set.mem_iUnion.mp hx + refine ⟨τ.gnsStarAlgHom (φ n b), ?_, left_vacuum τ (φ n b)⟩ + change τ.gnsStarAlgHom (φ n b) ∈ (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)) + rw [hS] + exact Set.mem_iUnion.mpr ⟨n, b, rfl⟩ + +include e he in +theorem dense_stages_of_bicommutant_generation + (hgen : ∀ a : A, τ.gnsStarAlgHom a ∈ + Set.centralizer (Set.centralizer + (stageAlgebra τ I φ : Set (τ.GNS →L[ℂ] τ.GNS)))) : + Dense (⋃ n, stageSet τ I φ n) := by + have hbase (a : A) : algebraVector τ a ∈ closure (⋃ n, stageSet τ I φ n) := by + have h := bicommutant_mem_cyclicSubspace (stageAlgebra τ I φ) (hgen a) (vacuum τ) + rw [left_vacuum] at h + change algebraVector τ a ∈ closure (orbitSubmodule (stageAlgebra τ I φ) (vacuum τ) : Set τ.GNS) at h + rwa [orbit_stageAlgebra τ I φ e he] at h + intro x + exact (algebraVector_dense τ).induction (fun _ ⟨a, ha⟩ => ha ▸ hbase a) isClosed_closure x + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StandardTrace.lean b/lean/OAI/Analysis/Commutator/StandardTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..ab2c556e0313e18114bc2d9db284de9d717d6052 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StandardTrace.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.NormalGNS +import OAI.Analysis.Commutator.TracialSequenceTrace + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology ComplexOrder + +namespace Kadison.NormalGNS + +open TracialGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +lemma gns_injective (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) : + Function.Injective τ.gnsStarAlgHom := by + intro a b hab + have hz : τ.gnsStarAlgHom (a-b)=0 := + (map_sub τ.gnsStarAlgHom a b).trans (sub_eq_zero.mpr hab) + have hv : algebraVector τ (a-b)=0 := by + have h := congrArg (fun T : τ.GNS →L[ℂ] τ.GNS => T (vacuum τ)) hz + simpa only [left_vacuum,algebraVector_apply,zero_apply] using h + apply sub_eq_zero.mp + apply hfaith (a-b) + rw [←inner_algebraVector,hv,inner_zero_left] + +lemma gns_norm (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (a : M) : + ‖τ.gnsStarAlgHom a‖=‖a‖ := + NonUnitalStarAlgHom.norm_map _ (gns_injective M τ hfaith) a + +variable (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (hnormal : BoundedWOTContinuous M τ) + +def algebra : VonNeumannAlgebra τ.GNS := + BicommutantRange.ofStarHom τ.gnsStarAlgHom (range_bicommutant M τ hτ hnormal) + +@[simp] lemma mem_algebra (T : τ.GNS →L[ℂ] τ.GNS) : + T∈algebra M τ hτ hnormal ↔ ∃ a : M, τ.gnsStarAlgHom a=T := Iff.rfl + +def equivalence (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) : + M ≃⋆ₐ[ℂ] algebra M τ hτ hnormal := + StarAlgEquiv.ofInjective τ.gnsStarAlgHom (gns_injective M τ hfaith) + +@[simp] lemma equivalence_apply (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (a : M) : + (equivalence M τ hτ hnormal hfaith a : τ.GNS →L[ℂ] τ.GNS)=τ.gnsStarAlgHom a := rfl + +def trace : (τ.GNS →L[ℂ] τ.GNS) →ₚ[ℂ] ℂ := VectorFunctional.functional (vacuum τ) + +@[simp] lemma trace_gns (a : M) : trace M τ (τ.gnsStarAlgHom a)=τ a := by + change inner ℂ (vacuum τ) (τ.gnsStarAlgHom a (vacuum τ))=τ a + rw [left_vacuum] + exact inner_vacuum_algebraVector τ a + +lemma trace_continuous : Continuous (fun T : τ.GNS →WOT[ℂ] τ.GNS => trace M τ T.toCLM) := + VectorFunctional.continuous_functional_wot (vacuum τ) + +include hτ hnormal in +lemma trace_tracial : ∀ S∈algebra M τ hτ hnormal, ∀ T∈algebra M τ hτ hnormal, + trace M τ (S*T)=trace M τ (T*S) := by + rintro S ⟨a,rfl⟩ T ⟨b,rfl⟩ + change trace M τ (τ.gnsStarAlgHom a*τ.gnsStarAlgHom b)= + trace M τ (τ.gnsStarAlgHom b*τ.gnsStarAlgHom a) + calc + trace M τ (τ.gnsStarAlgHom a*τ.gnsStarAlgHom b) = + trace M τ (τ.gnsStarAlgHom (a*b)) := + congrArg (trace M τ) (τ.gnsStarAlgHom.map_mul' a b).symm + _ = τ (a*b) := trace_gns M τ (a*b) + _ = τ (b*a) := hτ a b + _ = trace M τ (τ.gnsStarAlgHom (b*a)) := (trace_gns M τ (b*a)).symm + _ = trace M τ (τ.gnsStarAlgHom b*τ.gnsStarAlgHom a) := + congrArg (trace M τ) (τ.gnsStarAlgHom.map_mul' b a) + +include hτ hnormal in +lemma trace_faithful : ∀ T∈algebra M τ hτ hnormal, trace M τ (star T*T)=0 → T=0 := by + intro T hT hz + have hb : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom)) := by + rw [range_bicommutant M τ hτ hnormal] + exact hT + apply bicommutant_vacuum_separating τ hτ hb + rw [trace,VectorFunctional.functional_star_mul] at hz + exact inner_self_eq_zero.mp hz + +lemma trace_one : trace M τ 1=τ 1 := by + exact (congrArg (trace M τ) τ.gnsStarAlgHom.map_one').symm.trans (trace_gns M τ 1) + +include hτ hnormal in +theorem isFactor (hM : FactorCorner.IsFactor M) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) : + FactorCorner.IsFactor (algebra M τ hτ hnormal) := by + intro z hz hc + obtain ⟨a,rfl⟩ := hz + have hca : (a : H →L[ℂ] H)∈Set.centralizer (M : Set (H →L[ℂ] H)) := by + intro b hb + let b' : M := ⟨b,hb⟩ + have he : b'*a=a*b' := by + apply gns_injective M τ hfaith + exact (τ.gnsStarAlgHom.map_mul' b' a).trans + ((hc (τ.gnsStarAlgHom b') ⟨b',rfl⟩).trans (τ.gnsStarAlgHom.map_mul' a b').symm) + exact congrArg Subtype.val he + obtain ⟨c,hc⟩ := hM a a.property hca + have he : a=c • (1 : M) := Subtype.ext hc + refine ⟨c,?_⟩ + change τ.gnsStarAlgHom a=c • (1 : τ.GNS →L[ℂ] τ.GNS) + calc + τ.gnsStarAlgHom a = τ.gnsStarAlgHom (c • (1 : M)) := congrArg τ.gnsStarAlgHom he + _ = c • τ.gnsStarAlgHom 1 := τ.gnsStarAlgHom.toAlgHom.toLinearMap.map_smul c 1 + _ = c • (1 : τ.GNS →L[ℂ] τ.GNS) := + congrArg (fun T : τ.GNS →L[ℂ] τ.GNS => c • T) τ.gnsStarAlgHom.map_one' + +end Kadison.NormalGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StarField.lean b/lean/OAI/Analysis/Commutator/StarField.lean new file mode 100644 index 0000000000000000000000000000000000000000..028bdafd8c672fc2d307c883241ba0374bb0429e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StarField.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Commutator.DiagonalCommute +import OAI.Analysis.Commutator.FieldAdjoint +import OAI.Analysis.Commutator.ScalarIndicatorAdjoint + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +lemma adjoint_measurable (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : + ∀ ξ,AEStronglyMeasurable (fun a => (T a).adjoint ξ) μ := by + let A := operator μ T hm hb + have hcomm (s : Set Ω) (hs : MeasurableSet s) : + Commute A.adjoint (indicatorOperator μ s hs) := by + have h := congrArg star (operator_commutes_indicator μ T hm hb s hs).symm + change A.adjoint*indicatorOperator μ s hs=indicatorOperator μ s hs*A.adjoint + simpa only [A,star_mul,(indicatorOperator_selfAdjoint (H:=H) μ s hs).star_eq,ContinuousLinearMap.star_eq_adjoint] using h + obtain ⟨U,hU,hUb,he⟩ := exists_field_of_commutes_indicator μ A.adjoint hcomm + have hea := adjoint_ae μ T U hm hU hb hUb he.symm + intro ξ + apply (hU ξ).congr + filter_upwards [hea] with a ha + rw [ha] + +omit [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] in +lemma adjoint_field_bound (T : Ω → H →L[ℂ] H) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : ∀ᵐ a ∂μ,‖(T a).adjoint‖≤b := by + simpa only [←ContinuousLinearMap.star_eq_adjoint,norm_star] using hb + +lemma operator_adjoint (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) : + operator μ (fun a => (T a).adjoint) (adjoint_measurable μ T hm hb) + (adjoint_field_bound μ T hb)=(operator μ T hm hb).adjoint := by + apply ContinuousLinearMap.ext + intro f + apply ext_inner_right ℂ + intro g + rw [ContinuousLinearMap.adjoint_inner_left,L2.inner_def,L2.inner_def] + apply integral_congr_ae + filter_upwards [operator_ae μ (fun a => (T a).adjoint) (adjoint_measurable μ T hm hb) + (adjoint_field_bound μ T hb) f,operator_ae μ T hm hb g] with a ha ht + rw [ha,ht,ContinuousLinearMap.adjoint_inner_left] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StarHomFieldLip.lean b/lean/OAI/Analysis/Commutator/StarHomFieldLip.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7fab56fda5750c8cc2beb27ad290644ad949297 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StarHomFieldLip.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.Commutator.DecomposableAlgebra +import OAI.Analysis.Commutator.DecomposableNorm + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +namespace Kadison.Decomposable + +variable {Ω H A : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] [CStarAlgebra A] + +lemma representation_field_diff_bound + (ρ : A →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (T : A → Ω → H →L[ℂ] H) + (hm : ∀ a ξ,AEStronglyMeasurable (fun x => T a x ξ) μ) + (hb : ∀ a,∀ᵐ x ∂μ,‖T a x‖≤‖a‖) + (he : ∀ a,ρ a=operator μ (T a) (hm a) (hb a)) (a b : A) : + ∀ᵐ x ∂μ,‖T a x-T b x‖≤‖a-b‖ := by + apply (operator_norm_le_iff_ae μ (fun x => T a x-T b x) + (sub_measurable μ _ _ (hm a) (hm b)) (sub_bound μ _ _ (hb a) (hb b)) + (norm_nonneg (a-b))).mp + rw [←operator_sub μ _ _ (hm a) (hm b) (hb a) (hb b),←he a,←he b,←map_sub] + exact NonUnitalStarAlgHom.norm_apply_le ρ (a-b) + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StarHomFieldRaw.lean b/lean/OAI/Analysis/Commutator/StarHomFieldRaw.lean new file mode 100644 index 0000000000000000000000000000000000000000..75d970faded785b23ea761fdbc7a5b08985e86d0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StarHomFieldRaw.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Commutator.AddField +import OAI.Analysis.Commutator.DiagonalCommute +import OAI.Analysis.Commutator.FieldAdjoint +import OAI.Analysis.Commutator.FieldUniqueness + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology + +namespace Kadison.Decomposable + +variable {Ω H A : Type} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] [IsFiniteMeasure μ] + [CStarAlgebra A] + +theorem exists_starHom_fields + (ρ : A →⋆ₐ[ℂ] (Lp H 2 μ →L[ℂ] Lp H 2 μ)) + (hcomm : ∀ a (s : Set Ω) (hs : MeasurableSet s), + Commute (ρ a) (indicatorOperator (H:=H) μ s hs)) : + ∃ (T : A → Ω → H →L[ℂ] H) + (hm : ∀ a ξ,AEStronglyMeasurable (fun x => T a x ξ) μ) + (hb : ∀ a,∀ᵐ x ∂μ,‖T a x‖≤‖a‖), + (∀ a,ρ a=operator μ (T a) (hm a) (hb a)) ∧ + (∀ a b,∀ᵐ x ∂μ,T (a+b) x=T a x+T b x) ∧ + (∀ a b,∀ᵐ x ∂μ,T (a*b) x=T a x*T b x) ∧ + (∀ a,∀ᵐ x ∂μ,T (star a) x=star (T a x)) ∧ + (∀ z : ℂ,∀ᵐ x ∂μ,T (z • (1:A)) x=z • (1:H →L[ℂ] H)) := by + choose T hm hbn he using fun a => exists_field_of_commutes_indicator μ (ρ a) (hcomm a) + have hb : ∀ a,∀ᵐ x ∂μ,‖T a x‖≤‖a‖ := fun a => + (hbn a).mono (fun _ hx => hx.trans (NonUnitalStarAlgHom.norm_apply_le ρ a)) + have he' (a : A) : ρ a=operator μ (T a) (hm a) (hb a) := by + apply operator_eq_of_ae_apply + intro f + rw [he a] + exact operator_ae μ (T a) (hm a) (hbn a) f + refine ⟨T,hm,hb,he',?_,?_,?_,?_⟩ + · intro a b + apply field_eq_ae_of_operator_eq μ (T (a+b)) (fun x => T a x+T b x) + (hm (a+b)) (add_measurable μ _ _ (hm a) (hm b)) (hb (a+b)) + (add_field_bound μ _ _ (hb a) (hb b)) + rw [operator_add μ _ _ (hm a) (hm b) (hb a) (hb b),←he',←he',←he',map_add] + · intro a b + apply field_eq_ae_of_operator_eq μ (T (a*b)) (fun x => T a x*T b x) + (hm (a*b)) (mul_measurable μ _ _ (hm a) (hm b)) (hb (a*b)) + (mul_bound μ _ _ (norm_nonneg a) (hb a) (hb b)) + rw [←operator_mul μ _ _ (hm a) (hm b) (norm_nonneg a) (hb a) (hb b), + ←he',←he',←he',map_mul] + · intro a + exact adjoint_ae μ (T a) (T (star a)) (hm a) (hm (star a)) (hb a) (hb (star a)) + (by rw [←he',←he',map_star]; rfl) + · intro z + have hc : (z • (1 : Lp H 2 μ →L[ℂ] Lp H 2 μ))= + operator μ (fun _ => z • (1:H →L[ℂ] H)) + (fun _ => aestronglyMeasurable_const) (Eventually.of_forall (fun _ => le_rfl)) := by + apply operator_eq_of_ae_apply + intro f + exact Lp.coeFn_smul z f + apply field_eq_ae_of_operator_eq μ (T (z • (1:A))) (fun _ => z • (1:H →L[ℂ] H)) + (hm _) (fun _ => aestronglyMeasurable_const) (hb _) + (Eventually.of_forall (fun _ => le_rfl)) + rw [←he',←hc,map_smul,map_one] + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StinespringAction.lean b/lean/OAI/Analysis/Commutator/StinespringAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..11506224bc5862b01654ab7cac9a61fcf2cd54fc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StinespringAction.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Commutator.StinespringKernel + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.Stinespring + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem gram_middle_nonneg (φ : A →CP (H →L[ℂ] H)) {ι : Type*} [Fintype ι] + (a : ι → A) (ξ : ι → H) (k : A) (hk : 0≤k) : + 0 ≤ ∑ i, ∑ j, ⟪ξ i, φ (star (a i)*k*a j) (ξ j)⟫_ℂ := by + have hs : star (CFC.sqrt k)=CFC.sqrt k := (CFC.sqrt_nonneg k).star_eq + have he (i j : ι) : star (CFC.sqrt k*a i)*(CFC.sqrt k*a j)=star (a i)*k*a j := by + rw [star_mul,hs,←mul_assoc, mul_assoc (star (a i)),CFC.sqrt_mul_sqrt_self k hk] + simpa only [he] using gram_nonneg φ (fun i => CFC.sqrt k*a i) ξ + +def middleForm (φ : A →CP (H →L[ℂ] H)) (k : A) (x y : PreSpace φ) : ℂ := + (ofPre φ x).sum (fun a ξ => (ofPre φ y).sum (fun b η => ⟪ξ,φ (star a*k*b) η⟫_ℂ)) + +lemma middleForm_nonneg (φ : A →CP (H →L[ℂ] H)) (k : A) (hk : 0≤k) (x : PreSpace φ) : + 0 ≤ middleForm φ k x x := by + classical + have h := gram_middle_nonneg φ (fun i : (ofPre φ x).support => (i : A)) + (fun i : (ofPre φ x).support => (ofPre φ x) i) k hk + have hi (a : A) : (∑ j : (ofPre φ x).support, + ⟪ofPre φ x a,φ (star a*k*(j : A)) (ofPre φ x j)⟫_ℂ)= + ∑ b ∈ (ofPre φ x).support,⟪ofPre φ x a,φ (star a*k*b) (ofPre φ x b)⟫_ℂ := + Finset.sum_coe_sort _ (fun b : A => ⟪ofPre φ x a,φ (star a*k*b) (ofPre φ x b)⟫_ℂ) + simp_rw [hi] at h + rw [Finset.sum_coe_sort _ (fun a : A => ∑ b ∈ (ofPre φ x).support, + ⟪ofPre φ x a,φ (star a*k*b) (ofPre φ x b)⟫_ℂ)] at h + exact h + +@[simp] lemma middleForm_sub (φ : A →CP (H →L[ℂ] H)) (k l : A) (x y : PreSpace φ) : + middleForm φ (k-l) x y=middleForm φ k x y-middleForm φ l x y := by + classical + simp [middleForm,Finsupp.sum,mul_sub,sub_mul,Finset.sum_sub_distrib] + +@[simp] lemma middleForm_real_one (φ : A →CP (H →L[ℂ] H)) (r : ℝ) (x y : PreSpace φ) : + middleForm φ (algebraMap ℝ A r) x y=(r : ℂ)*form φ x y := by + classical + simp [middleForm,form,Finsupp.sum,Algebra.algebraMap_eq_smul_one, + ←Complex.coe_smul,Finset.mul_sum] + +def leftLinear (φ : A →CP (H →L[ℂ] H)) (a : A) : PreSpace φ →ₗ[ℂ] PreSpace φ := + (toPre φ).toLinearMap.comp ((Finsupp.lmapDomain H ℂ (a*·)).comp (ofPre φ).toLinearMap) + +lemma form_left (φ : A →CP (H →L[ℂ] H)) (a : A) (x y : PreSpace φ) : + form φ (leftLinear φ a x) y=middleForm φ (star a) x y := by + classical + simp only [form,leftLinear,LinearMap.comp_apply,LinearEquiv.coe_coe,ofPre_toPre, + Finsupp.lmapDomain_apply] + rw [Finsupp.sum_mapDomain_index] + · simp [middleForm,star_mul,mul_assoc] + · simp [Finsupp.sum] + · intros; simp [Finsupp.sum,Finset.sum_add_distrib] + +lemma form_right (φ : A →CP (H →L[ℂ] H)) (a : A) (x y : PreSpace φ) : + form φ x (leftLinear φ a y)=middleForm φ a x y := by + classical + unfold form middleForm + simp only [leftLinear,LinearMap.comp_apply,LinearEquiv.coe_coe,ofPre_toPre, + Finsupp.lmapDomain_apply] + apply Finsupp.sum_congr + intro b hb + rw [Finsupp.sum_mapDomain_index] + · simp [mul_assoc] + · simp + · intros; simp + +lemma form_left_left (φ : A →CP (H →L[ℂ] H)) (a : A) (x y : PreSpace φ) : + form φ (leftLinear φ a x) (leftLinear φ a y)=middleForm φ (star a*a) x y := by + classical + rw [form_left] + simp only [middleForm,leftLinear,LinearMap.comp_apply,LinearEquiv.coe_coe,ofPre_toPre, + Finsupp.lmapDomain_apply] + apply Finsupp.sum_congr + intro b hb + rw [Finsupp.sum_mapDomain_index] + · simp [mul_assoc] + · simp + · intros; simp + +lemma leftLinear_bound (φ : A →CP (H →L[ℂ] H)) (a : A) (x : PreSpace φ) : + ‖leftLinear φ a x‖≤‖a‖*‖x‖ := by + have hp := middleForm_nonneg φ (algebraMap ℝ A (‖a‖^2)-star a*a) + (sub_nonneg.mpr (CStarAlgebra.star_mul_le_algebraMap_norm_sq a)) x + rw [middleForm_sub,middleForm_real_one,←form_left_left] at hp + have hf (z : PreSpace φ) : (form φ z z).re=‖z‖^2 := + (norm_sq_eq_re_inner (𝕜:=ℂ) z).symm + have hr := hp.1 + simp only [Complex.zero_re,Complex.sub_re,Complex.mul_re,Complex.ofReal_re, + Complex.ofReal_im,zero_mul,sub_zero,hf] at hr + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (norm_nonneg a) (norm_nonneg x))).mp + rw [mul_pow] + linarith + +def leftAction (φ : A →CP (H →L[ℂ] H)) (a : A) : PreSpace φ →L[ℂ] PreSpace φ := + (leftLinear φ a).mkContinuous ‖a‖ (leftLinear_bound φ a) + +@[simp] lemma leftAction_apply (φ : A →CP (H →L[ℂ] H)) (a : A) (x : PreSpace φ) : + leftAction φ a x=leftLinear φ a x := rfl + +end Kadison.Stinespring + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StinespringDilation.lean b/lean/OAI/Analysis/Commutator/StinespringDilation.lean new file mode 100644 index 0000000000000000000000000000000000000000..cfa14d0b3dea7fbb729b9b0f9d1781d5170cd445 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StinespringDilation.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Commutator.StinespringRepresentation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +open UniformSpace + +namespace Kadison.Stinespring + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def elementary (φ : A →CP (H →L[ℂ] H)) (a : A) : H →ₗ[ℂ] PreSpace φ := + (toPre φ).toLinearMap.comp (Finsupp.lsingle a) + +@[simp] lemma form_elementary (φ : A →CP (H →L[ℂ] H)) (a b : A) (ξ η : H) : + form φ (elementary φ a ξ) (elementary φ b η)=⟪ξ,φ (star a*b) η⟫_ℂ := by + classical + simp [form,elementary,Finsupp.lsingle_apply] + +@[simp] lemma leftLinear_elementary (φ : A →CP (H →L[ℂ] H)) (a b : A) (ξ : H) : + leftLinear φ a (elementary φ b ξ)=elementary φ (a*b) ξ := by + classical + simp [leftLinear,elementary,Finsupp.lmapDomain_apply,Finsupp.lsingle_apply] + +lemma elementary_one_bound (φ : A →CP (H →L[ℂ] H)) (ξ : H) : + ‖elementary φ 1 ξ‖≤Real.sqrt ‖φ 1‖*‖ξ‖ := by + have he : ‖elementary φ 1 ξ‖^2=(⟪ξ,φ 1 ξ⟫_ℂ).re := by + rw [norm_sq_eq_re_inner (𝕜:=ℂ),inner_def,form_elementary,star_one,one_mul] + rfl + have hi := re_inner_le_norm (𝕜:=ℂ) ξ (φ 1 ξ) + change (⟪ξ,φ 1 ξ⟫_ℂ).re ≤ ‖ξ‖ * ‖φ 1 ξ‖ at hi + have hn := mul_le_mul_of_nonneg_left ((φ 1).le_opNorm ξ) (norm_nonneg ξ) + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (Real.sqrt_nonneg _) (norm_nonneg ξ))).mp + rw [mul_pow,Real.sq_sqrt (norm_nonneg _),he] + nlinarith + +def embedding (φ : A →CP (H →L[ℂ] H)) : H →L[ℂ] Space φ := + (Completion.toComplL : PreSpace φ →L[ℂ] Space φ).comp + ((elementary φ 1).mkContinuous (Real.sqrt ‖φ 1‖) (elementary_one_bound φ)) + +@[simp] lemma embedding_apply (φ : A →CP (H →L[ℂ] H)) (ξ : H) : + embedding φ ξ=(elementary φ 1 ξ : Space φ) := rfl + +lemma embedding_norm_le (φ : A →CP (H →L[ℂ] H)) : ‖embedding φ‖≤Real.sqrt ‖φ 1‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (Real.sqrt_nonneg _) + intro ξ + simpa using elementary_one_bound φ ξ + +theorem factorization (φ : A →CP (H →L[ℂ] H)) (a : A) : + φ a=(embedding φ).adjoint.comp ((representation φ a).comp (embedding φ)) := by + ext η + apply ext_inner_left ℂ + intro ξ + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_right, + embedding_apply,representation_coe,leftLinear_elementary,mul_one,Completion.inner_coe, + inner_def,form_elementary,star_one,one_mul] + +lemma embedding_adjoint_embedding (φ : A →CP (H →L[ℂ] H)) : + (embedding φ).adjoint.comp (embedding φ)=φ 1 := by + simpa [ContinuousLinearMap.one_def] using (factorization φ (1 : A)).symm + +lemma embedding_norm_sq (φ : A →CP (H →L[ℂ] H)) : ‖embedding φ‖^2=‖φ 1‖ := by + rw [←embedding_adjoint_embedding,ContinuousLinearMap.norm_adjoint_comp_self] + ring + +end Kadison.Stinespring + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StinespringKernel.lean b/lean/OAI/Analysis/Commutator/StinespringKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..b97a66f47b802c728ae9db980264a8b601a8e780 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StinespringKernel.lean @@ -0,0 +1,131 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicMatrix + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +namespace Kadison.Stinespring + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem gram_nonneg (φ : A →CP (H →L[ℂ] H)) {ι : Type*} [Fintype ι] + (a : ι → A) (ξ : ι → H) : + 0 ≤ ∑ i, ∑ j, ⟪ξ i, φ (star (a i)*a j) (ξ j)⟫_ℂ := by + classical + cases isEmpty_or_nonempty ι with + | inl h => simp + | inr h => + let i₀ : ι := Classical.choice h + let R : CStarMatrix ι ι A := CStarMatrix.ofMatrix (fun i j => if i=i₀ then a j else 0) + have he (i j : ι) : (star R*R) i j=star (a i)*a j := by + rw [CStarMatrix.mul_apply] + change (∑ k, star (if k=i₀ then a i else 0)*(if k=i₀ then a j else 0))=_ + simp + have hp := φ.map_cstarMatrix_nonneg (star R*R) (star_mul_self_nonneg R) + have hq := map_nonneg + (CyclicColumns.matrixRepresentation (StarAlgHom.id ℂ (H →L[ℂ] H))) hp + have hr := ContinuousLinearMap.nonneg_iff_isPositive.mp hq + let v : PiLp 2 (fun _ : ι => H) := WithLp.toLp 2 ξ + have hs := hr.inner_nonneg_right v + change 0 ≤ ⟪v, CyclicColumns.matrixAction + (fun i j => φ ((star R*R) i j)) v⟫_ℂ at hs + simpa [PiLp.inner_apply,CyclicColumns.matrixAction_apply,inner_sum,he,v] using hs + +def PreSpace (_φ : A →CP (H →L[ℂ] H)) := A →₀ H + +instance (φ : A →CP (H →L[ℂ] H)) : AddCommGroup (PreSpace φ) := + inferInstanceAs (AddCommGroup (A →₀ H)) + +instance (φ : A →CP (H →L[ℂ] H)) : Module ℂ (PreSpace φ) := + inferInstanceAs (Module ℂ (A →₀ H)) + +def toPre (φ : A →CP (H →L[ℂ] H)) : (A →₀ H) ≃ₗ[ℂ] PreSpace φ := LinearEquiv.refl ℂ _ + +def ofPre (φ : A →CP (H →L[ℂ] H)) : PreSpace φ ≃ₗ[ℂ] (A →₀ H) := (toPre φ).symm + +@[simp] lemma ofPre_toPre (φ : A →CP (H →L[ℂ] H)) (x : A →₀ H) : + ofPre φ (toPre φ x)=x := rfl + +@[simp] lemma toPre_ofPre (φ : A →CP (H →L[ℂ] H)) (x : PreSpace φ) : + toPre φ (ofPre φ x)=x := rfl + +def form (φ : A →CP (H →L[ℂ] H)) (x y : PreSpace φ) : ℂ := + (ofPre φ x).sum (fun a ξ => (ofPre φ y).sum (fun b η => ⟪ξ,φ (star a*b) η⟫_ℂ)) + +lemma form_conj (φ : A →CP (H →L[ℂ] H)) (x y : PreSpace φ) : + star (form φ x y)=form φ y x := by + classical + change (starRingEnd ℂ) (form φ x y)=_ + simp only [form,Finsupp.sum,map_sum,inner_conj_symm] + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro a ha + apply Finset.sum_congr rfl + intro b hb + rw [←ContinuousLinearMap.adjoint_inner_left] + simp [←ContinuousLinearMap.star_eq_adjoint,←map_star,star_mul] + +lemma form_add_left (φ : A →CP (H →L[ℂ] H)) (x y z : PreSpace φ) : + form φ (x+y) z=form φ x z+form φ y z := by + classical + unfold form + rw [map_add] + exact Finsupp.sum_add_index' (by simp [Finsupp.sum]) + (by intros; simp [Finsupp.sum,Finset.sum_add_distrib]) + +lemma form_smul_left (φ : A →CP (H →L[ℂ] H)) (c : ℂ) (x y : PreSpace φ) : + form φ (c • x) y=star c*form φ x y := by + classical + unfold form + rw [map_smul,Finsupp.sum_smul_index'] + · simp [Finsupp.sum,Finset.mul_sum,mul_comm] + · simp [Finsupp.sum] + +lemma form_nonneg (φ : A →CP (H →L[ℂ] H)) (x : PreSpace φ) : + 0 ≤ form φ x x := by + classical + have h := gram_nonneg φ (fun i : (ofPre φ x).support => (i : A)) + (fun i : (ofPre φ x).support => (ofPre φ x) i) + have hi (a : A) : (∑ j : (ofPre φ x).support, + ⟪ofPre φ x a,φ (star a*(j : A)) (ofPre φ x j)⟫_ℂ)= + ∑ b ∈ (ofPre φ x).support,⟪ofPre φ x a,φ (star a*b) (ofPre φ x b)⟫_ℂ := + Finset.sum_coe_sort _ (fun b : A => ⟪ofPre φ x a,φ (star a*b) (ofPre φ x b)⟫_ℂ) + simp_rw [hi] at h + rw [Finset.sum_coe_sort _ (fun a : A => ∑ b ∈ (ofPre φ x).support, + ⟪ofPre φ x a,φ (star a*b) (ofPre φ x b)⟫_ℂ)] at h + exact h + +abbrev preInner (φ : A →CP (H →L[ℂ] H)) : PreInnerProductSpace.Core ℂ (PreSpace φ) where + inner := form φ + conj_inner_symm x y := form_conj φ y x + re_inner_nonneg x := (form_nonneg φ x).1 + add_left := form_add_left φ + smul_left x y r := form_smul_left φ r x y + +instance (φ : A →CP (H →L[ℂ] H)) : SeminormedAddCommGroup (PreSpace φ) := + InnerProductSpace.Core.toSeminormedAddCommGroup (c:=preInner φ) + +instance (φ : A →CP (H →L[ℂ] H)) : InnerProductSpace ℂ (PreSpace φ) := + InnerProductSpace.ofCore (preInner φ) + +@[simp] lemma inner_def (φ : A →CP (H →L[ℂ] H)) (x y : PreSpace φ) : + ⟪x,y⟫_ℂ=form φ x y := rfl + +abbrev Space (φ : A →CP (H →L[ℂ] H)) := UniformSpace.Completion (PreSpace φ) + +end Kadison.Stinespring + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StinespringRepresentation.lean b/lean/OAI/Analysis/Commutator/StinespringRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..2c727eac8084df55e8495d3f0d9d001a77ead2c6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StinespringRepresentation.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.Commutator.StinespringAction + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace ComplexOrder CStarAlgebra + +open UniformSpace + +namespace Kadison.Stinespring + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +@[simp] lemma middleForm_add (φ : A →CP (H →L[ℂ] H)) (a b : A) (x y : PreSpace φ) : + middleForm φ (a+b) x y=middleForm φ a x y+middleForm φ b x y := by + classical + simp [middleForm,Finsupp.sum,mul_add,add_mul,Finset.sum_add_distrib] + +@[simp] lemma middleForm_smul (φ : A →CP (H →L[ℂ] H)) (c : ℂ) (a : A) (x y : PreSpace φ) : + middleForm φ (c • a) x y=c*middleForm φ a x y := by + classical + simp [middleForm,Finsupp.sum,Finset.mul_sum] + +@[simp] lemma middleForm_zero (φ : A →CP (H →L[ℂ] H)) (x y : PreSpace φ) : + middleForm φ 0 x y=0 := by simp [middleForm,Finsupp.sum] + +lemma leftLinear_one (φ : A →CP (H →L[ℂ] H)) : leftLinear φ 1=LinearMap.id := by + ext x + apply (ofPre φ).injective + simp [leftLinear,Finsupp.lmapDomain_apply] + +lemma leftLinear_mul (φ : A →CP (H →L[ℂ] H)) (a b : A) : + leftLinear φ (a*b)=(leftLinear φ a).comp (leftLinear φ b) := by + ext x + apply (ofPre φ).injective + simp only [leftLinear,LinearMap.comp_apply,LinearEquiv.coe_coe,ofPre_toPre,Finsupp.lmapDomain_apply] + rw [←Finsupp.mapDomain_comp] + congr 1 + ext z + simp [mul_assoc] + +lemma coe_leftLinear_add (φ : A →CP (H →L[ℂ] H)) (a b : A) (x : PreSpace φ) : + (leftLinear φ (a+b) x : Space φ)=(leftLinear φ a x : Space φ)+(leftLinear φ b x : Space φ) := by + apply ext_inner_right ℂ + intro y + induction y using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih y => + rw [←Completion.coe_add,Completion.inner_coe,Completion.inner_coe] + simp [inner_def,form_add_left,form_left,star_add] + +lemma coe_leftLinear_smul (φ : A →CP (H →L[ℂ] H)) (c : ℂ) (a : A) (x : PreSpace φ) : + (leftLinear φ (c • a) x : Space φ)=c • (leftLinear φ a x : Space φ) := by + apply ext_inner_right ℂ + intro y + induction y using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih y => + rw [←Completion.coe_smul,Completion.inner_coe,Completion.inner_coe] + simp [inner_def,form_smul_left,form_left,star_smul] + +lemma coe_leftLinear_zero (φ : A →CP (H →L[ℂ] H)) (x : PreSpace φ) : + (leftLinear φ 0 x : Space φ)=0 := by + simpa using coe_leftLinear_smul φ 0 0 x + +def representation (φ : A →CP (H →L[ℂ] H)) : A →⋆ₐ[ℂ] (Space φ →L[ℂ] Space φ) where + toFun a := (leftAction φ a).completion + map_one' := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [leftLinear_one] + map_mul' a b := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [leftLinear_mul,LinearMap.comp_apply] + map_zero' := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [coe_leftLinear_zero] + map_add' a b := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [coe_leftLinear_add] + commutes' c := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [Algebra.algebraMap_eq_smul_one,coe_leftLinear_smul,leftLinear_one] + map_star' a := by + rw [ContinuousLinearMap.star_eq_adjoint] + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + induction x,y using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih x y => simp [inner_def,form_left,form_right] + +@[simp] lemma representation_coe (φ : A →CP (H →L[ℂ] H)) (a : A) (x : PreSpace φ) : + representation φ a (x : Space φ)=(leftLinear φ a x : Space φ) := by + change (leftAction φ a).completion (x : Space φ)=_ + simp + +end Kadison.Stinespring + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StrongContinuity.lean b/lean/OAI/Analysis/Commutator/StrongContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..df7924fb7f0c45b21c23dd3b737f51ce69bebcaa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StrongContinuity.lean @@ -0,0 +1,80 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +open Filter + +namespace Kadison.StrongContinuity + +variable {X E : Type*} [TopologicalSpace X] [NormedAddCommGroup E] [NormedSpace ℂ E] + +variable (T : X → E →ₗᵢ[ℂ] E) + +def vectors : Submodule ℂ E where + carrier := {x | Continuous (fun g => T g x)} + zero_mem' := by + change Continuous (fun g => T g (0:E)) + simpa only [map_zero] using (continuous_const : Continuous (fun _ : X => (0:E))) + add_mem' := by + intro x y hx hy + change Continuous (fun g => T g x) at hx + change Continuous (fun g => T g y) at hy + change Continuous (fun g => T g (x+y)) + simp only [map_add] + exact hx.add hy + smul_mem' := by + intro a x hx + change Continuous (fun g => T g x) at hx + change Continuous (fun g => T g (a • x)) + simp only [map_smul] + exact continuous_const.smul hx + +lemma isClosed_vectors : IsClosed (vectors T : Set E) := by + apply IsSeqClosed.isClosed + intro u x hu hux + have hl : TendstoUniformly (fun n g => T g (u n)) (fun g => T g x) atTop := by + apply Metric.tendstoUniformly_iff.mpr + intro ε hε + filter_upwards [Metric.tendsto_nhds.mp hux ε hε] with n hn + intro g + simpa only [LinearIsometry.dist_map,dist_comm] using hn + exact hl.continuous (Eventually.of_forall hu).frequently + +lemma of_denseRange {ι : Type*} (v : ι → E) (hd : DenseRange v) + (hv : ∀ i, Continuous fun g => T g (v i)) (x : E) : Continuous fun g => T g x := by + have hs : Set.range v ⊆ (vectors T : Set E) := by rintro _ ⟨i,rfl⟩; exact hv i + have he : (Set.univ : Set E) ⊆ (vectors T : Set E) := by + rw [← hd.closure_range] + exact (isClosed_vectors T).closure_subset_iff.mpr hs + exact he (Set.mem_univ x) + +lemma of_total {S : Set E} (hS : (Submodule.span ℂ S).topologicalClosure=⊤) + (hv : ∀ x ∈ S, Continuous fun g => T g x) (x : E) : Continuous fun g => T g x := by + have hs : Submodule.span ℂ S ≤ vectors T := Submodule.span_le.mpr hv + have ht : (Submodule.span ℂ S).topologicalClosure ≤ vectors T := + Submodule.topologicalClosure_minimal _ hs (isClosed_vectors T) + rw [hS] at ht + exact ht (Submodule.mem_top : x ∈ (⊤ : Submodule ℂ E)) + +lemma joint (h : ∀ x, Continuous fun g => T g x) : Continuous (fun p : X × E => T p.1 p.2) := by + apply continuous_prod_of_continuous_lipschitzWith' _ 1 + · intro g + exact (T g).isometry.lipschitzWith + · exact h + +end Kadison.StrongContinuity + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StrongContractionLimit.lean b/lean/OAI/Analysis/Commutator/StrongContractionLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..43ecf38a43d7d7315a54cca0210124ceb70b8ed6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StrongContractionLimit.lean @@ -0,0 +1,64 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +open Filter + +namespace Kadison.StrongContractionLimit + +variable {ι H G : Type*} [NormedAddCommGroup H] [NormedSpace ℂ H] + [NormedAddCommGroup G] [NormedSpace ℂ G] + +variable {l : Filter ι} + +lemma apply_tendsto (P : ι → H →L[ℂ] G) (Q : H →L[ℂ] G) + (hP : ∀ i,‖P i‖≤1) (hstrong : ∀ x,Tendsto (fun i => P i x) l (𝓝 (Q x))) + {u : ι → H} {x : H} (hu : Tendsto u l (𝓝 x)) : + Tendsto (fun i => P i (u i)) l (𝓝 (Q x)) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + have hlim : Tendsto (fun i => ‖u i-x‖+‖P i x-Q x‖) l (𝓝 0) := by + simpa only [sub_self,norm_zero,zero_add] using + ((hu.sub (tendsto_const_nhds (x := x))).norm.add + (((hstrong x).sub (tendsto_const_nhds (x := Q x))).norm)) + apply squeeze_zero (fun i => norm_nonneg _) _ hlim + intro i + calc + ‖P i (u i)-Q x‖=‖P i (u i-x)+(P i x-Q x)‖ := by rw [map_sub]; congr 1; abel + _≤‖P i (u i-x)‖+‖P i x-Q x‖ := norm_add_le _ _ + _≤‖u i-x‖+‖P i x-Q x‖ := by + apply add_le_add _ le_rfl + exact ((P i).le_opNorm (u i-x)).trans (by + simpa only [one_mul] using + mul_le_mul_of_nonneg_right (hP i) (norm_nonneg (u i-x))) + +lemma sandwich_tendsto (P : ι → H →L[ℂ] H) (hP : ∀ i,‖P i‖≤1) + (hstrong : ∀ x,Tendsto (fun i => P i x) l (𝓝 x)) (Y : H →L[ℂ] H) (x : H) : + Tendsto (fun i => (P i*Y*P i) x) l (𝓝 (Y x)) := by + exact apply_tendsto P (ContinuousLinearMap.id ℂ H) hP hstrong + (Y.continuous.tendsto x |>.comp (hstrong x)) + +lemma norm_le_of_strong [l.NeBot] (T : ι → H →L[ℂ] G) (Y : H →L[ℂ] G) + (hstrong : ∀ x,Tendsto (fun i => T i x) l (𝓝 (Y x))) {C : ℝ} (hC : 0≤C) + (hbound : ∀ᶠ i in l,‖T i‖≤C) : ‖Y‖≤C := by + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro x + apply le_of_tendsto (hstrong x |>.norm) + filter_upwards [hbound] with i hi + exact ((T i).le_opNorm x).trans (mul_le_mul_of_nonneg_right hi (norm_nonneg x)) + +end Kadison.StrongContractionLimit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/StrongDenseTests.lean b/lean/OAI/Analysis/Commutator/StrongDenseTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..49802d906faa700ca0445439862bfdd901416c1c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/StrongDenseTests.lean @@ -0,0 +1,53 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped Topology + +namespace Kadison + +variable {H G : Type*} [NormedAddCommGroup H] [NormedSpace ℂ H] + [NormedAddCommGroup G] [NormedSpace ℂ G] + +lemma strong_tendsto_of_dense_tests {ι κ : Type*} {l : Filter ι} + (v : κ → H) (hv : DenseRange v) (T : ι → H →L[ℂ] G) (A : H →L[ℂ] G) + (hT : ∀ i,‖T i‖≤1) (hA : ‖A‖≤1) + (ht : ∀ j,Tendsto (fun i => T i (v j)) l (𝓝 (A (v j)))) : + ∀ ξ,Tendsto (fun i => T i ξ) l (𝓝 (A ξ)) := by + intro ξ + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨j,hj⟩ := Metric.denseRange_iff.mp hv ξ (ε/4) (by positivity) + have hs : ‖ξ-v j‖<ε/4 := by simpa only [dist_eq_norm,norm_sub_rev] using hj + have he := Metric.tendsto_nhds.mp (ht j) (ε/2) (by positivity) + filter_upwards [he] with i hi + rw [dist_eq_norm] at hi ⊢ + have h1 : ‖T i (ξ-v j)‖≤‖ξ-v j‖ := + ((T i).le_opNorm _).trans (by simpa using mul_le_mul_of_nonneg_right (hT i) (norm_nonneg (ξ-v j))) + have h2 : ‖A (v j-ξ)‖≤‖ξ-v j‖ := + (A.le_opNorm _).trans (by simpa only [one_mul,norm_sub_rev] using + mul_le_mul_of_nonneg_right hA (norm_nonneg (v j-ξ))) + have hid : T i ξ-A ξ=T i (ξ-v j)+(T i (v j)-A (v j))+A (v j-ξ) := by + simp only [map_sub] + abel + rw [hid] + exact (norm_add_le _ _).trans_lt (by + have hn := norm_add_le (T i (ξ-v j)) (T i (v j)-A (v j)) + linarith) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/SubfactorExpectation.lean b/lean/OAI/Analysis/Commutator/SubfactorExpectation.lean new file mode 100644 index 0000000000000000000000000000000000000000..39e977fa27ce7ba07935753d6fcda3ddfd6b87af --- /dev/null +++ b/lean/OAI/Analysis/Commutator/SubfactorExpectation.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeMoments + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.FreeMoments + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable {ι : Type*} {S T : ι → StarSubalgebra ℂ A} {τ : A →ₗ[ℂ] ℂ} + +variable (hsub : ∀ i, T i≤S i) + +def Letter.enlarge (a : Letter T τ) : Letter S τ := + ⟨a.color,a.val,hsub a.color a.mem,a.centered⟩ + +@[simp] lemma word_enlarge (w : List (Letter T τ)) : + word (w.map (Letter.enlarge hsub))=word w := by + induction w with + | nil => rfl + | cons a w ih => simpa only [List.map_cons,word_cons,Letter.enlarge] using congrArg (a.val*·) ih + +lemma Reduced.enlarge {w : List (Letter T τ)} (hw : Reduced w) : + Reduced (w.map (Letter.enlarge hsub)) := by + exact (List.isChain_map (Letter.enlarge hsub)).mpr hw + +variable (hstar : ∀ a : A, τ (star a)=star (τ a)) (h1 : τ 1=1) (hfree : Free S τ) + +include hsub hstar h1 hfree in +lemma residual_word_pairing {j : ι} {a : A} (ha : a∈S j) (ha0 : τ a=0) + (haT : ∀ b∈T j, τ (a*b)=0) (w : List (Letter T τ)) (hw : Reduced w) : + τ (a*word w)=0 := by + let b : Letter S τ := ⟨j,star a,star_mem ha,by rw [hstar,ha0,star_zero]⟩ + have hg := gram_word hstar h1 hfree [b] (w.map (Letter.enlarge hsub)) + (reduced_singleton b) (hw.enlarge hsub) + simp only [word_enlarge,word_cons,word_nil,mul_one,b,star_star] at hg + change τ (a*word w)=gram [b] (w.map (Letter.enlarge hsub)) at hg + rw [hg] + cases w with + | nil => rfl + | cons c w => + cases w with + | nil => + by_cases hj : j=c.color + · simp only [List.map_cons,List.map_nil,gram,b,Letter.enlarge,ite_eq_left hj, + star_star,mul_one] + exact haT c.val (hj ▸ c.mem) + · simp [gram,b,Letter.enlarge,hj] + | cons c' w => + simp only [List.map_cons,gram,b,Letter.enlarge,star_star] + split_ifs <;> simp + +include hsub hstar h1 hfree in +lemma residual_generated_pairing {j : ι} {a x : A} (ha : a∈S j) (ha0 : τ a=0) + (haT : ∀ b∈T j, τ (a*b)=0) (hx : x∈⨆ i,T i) : τ (a*x)=0 := by + rw [←reducedAlgebra_eq_iSup (S := T) hstar h1] at hx + change x∈wordSpan T τ at hx + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨w,hw,rfl⟩ := hx + exact residual_word_pairing hsub hstar h1 hfree ha ha0 haT w hw + | zero => simp + | add x y _ _ hx hy => simp only [mul_add,map_add,hx,hy,add_zero] + | smul z x _ hx => simp only [mul_smul_comm,map_smul,hx,smul_zero] + +end Kadison.FreeMoments + +namespace Kadison.SymmetryAlgebra + +variable {A : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + +variable (s : A) (hs : star s=s) (hs2 : s*s=1) + +def algebra : StarSubalgebra ℂ A where + carrier := {a | ∃ z w : ℂ, a=z • (1:A)+w • s} + zero_mem' := ⟨0,0,by simp⟩ + one_mem' := ⟨1,0,by simp⟩ + add_mem' := by + rintro a b ⟨z,w,rfl⟩ ⟨z',w',rfl⟩ + exact ⟨z+z',w+w',by module⟩ + mul_mem' := by + rintro a b ⟨z,w,rfl⟩ ⟨z',w',rfl⟩ + refine ⟨z*z'+w*w',z*w'+w*z',?_⟩ + simp only [add_mul,mul_add,smul_mul_assoc,mul_smul_comm, + one_mul,mul_one,hs2] + module + algebraMap_mem' z := ⟨z,0,by simp [Algebra.algebraMap_eq_smul_one]⟩ + star_mem' := by + rintro a ⟨z,w,rfl⟩ + exact ⟨star z,star w,by simp only [star_add,star_smul,star_one,hs]⟩ + +@[simp] lemma mem_algebra {a : A} : a∈algebra s hs hs2 ↔ ∃ z w : ℂ,a=z • (1:A)+w • s := Iff.rfl + +lemma self_mem : s∈algebra s hs hs2 := ⟨0,1,by simp⟩ + +lemma le_factor (D : StarSubalgebra ℂ A) (h : s∈D) : algebra s hs hs2≤D := by + rintro a ⟨z,w,rfl⟩ + exact D.add_mem (D.smul_mem D.one_mem z) (D.smul_mem h w) + +variable (S : Bool → StarSubalgebra ℂ A) (τ : A →ₗ[ℂ] ℂ) + +def factors : Bool → StarSubalgebra ℂ A := fun i => if i then algebra s hs hs2 else S false + +variable (hsS : s∈S true) (hs0 : τ s=0) (hstar : ∀ a : A, τ (star a)=star (τ a)) + (h1 : τ 1=1) (hfree : FreeMoments.Free S τ) + +include hsS in +lemma factors_le (i : Bool) : factors s hs hs2 S i≤S i := by + cases i + · exact le_rfl + · exact le_factor s hs hs2 (S true) hsS + +include hsS hs0 hstar h1 hfree in +theorem pairing_projection {a x : A} (ha : a∈S true) + (hx : x∈⨆ i,factors s hs hs2 S i) : + τ (a*x)=τ a*τ x+τ (a*s)*τ (s*x) := by + let r := a-τ a • (1:A)-τ (a*s) • s + have hr : r∈S true := (S true).sub_mem + ((S true).sub_mem ha ((S true).smul_mem (S true).one_mem _)) ((S true).smul_mem hsS _) + have hr0 : τ r=0 := by simp [r,map_sub,map_smul,h1,hs0] + have hrs : τ (r*s)=0 := by + simp [r,sub_mul,map_sub,map_smul,hs2,h1,hs0] + have hrT : ∀ b∈factors s hs hs2 S true, τ (r*b)=0 := by + rintro b ⟨z,w,rfl⟩ + simp only [mul_add,mul_smul_comm,mul_one,map_add,map_smul,hr0,hrs,smul_zero,add_zero] + have hz := FreeMoments.residual_generated_pairing + (factors_le s hs hs2 S hsS) hstar h1 hfree hr hr0 hrT hx + dsimp only [r] at hz + simp only [sub_mul,smul_mul_assoc,one_mul,map_sub,map_smul,smul_eq_mul] at hz + exact (sub_eq_iff_eq_add.mp (sub_eq_zero.mp hz)).trans (add_comm _ _) + +end Kadison.SymmetryAlgebra + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorActions.lean b/lean/OAI/Analysis/Commutator/TensorActions.lean new file mode 100644 index 0000000000000000000000000000000000000000..132eb86a000d1496f3af3d74a7f0a56daa36d530 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorActions.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.CoefficientForm +import OAI.Analysis.Commutator.CoefficientForm2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct + +namespace Kadison + +open UniformSpace + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +def completionIsometry (U : E →ₗᵢ[ℂ] F) : Completion E →ₗᵢ[ℂ] Completion F where + toLinearMap := U.toContinuousLinearMap.completion.toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => simp + +@[simp] lemma completionIsometry_coe (U : E →ₗᵢ[ℂ] F) (x : E) : + completionIsometry U (x : Completion E) = (U x : Completion F) := by + change U.toContinuousLinearMap.completion (x : Completion E) = _ + simp + +namespace PreHilbert + +variable (E F : PreHilbert) + +def powerMap (U : E →ₗᵢ[ℂ] E) : ∀ n, power E n →ₗᵢ[ℂ] power E n + | 0 => LinearIsometry.id + | n+1 => TensorProduct.mapIsometry U (powerMap U n) + +@[simp] lemma powerMap_pure (U : E →ₗᵢ[ℂ] E) (n : ℕ) (x : Fin n → E) : + powerMap E U n (pure E n x) = pure E n (fun i => U (x i)) := by + induction n with + | zero => rfl + | succ n ih => + simp only [powerMap, pure_succ, TensorProduct.mapIsometry_apply, + TensorProduct.map_tmul, LinearIsometry.coe_toLinearMap, ih] + rfl + +def wordMap (U : E →ₗᵢ[ℂ] E) (V : F →ₗᵢ[ℂ] F) (n : ℕ) : + wordSpace E F n →ₗᵢ[ℂ] wordSpace E F n := + completionIsometry (TensorProduct.mapIsometry U (powerMap F V n)) + +@[simp] lemma wordMap_word (U : E →ₗᵢ[ℂ] E) (V : F →ₗᵢ[ℂ] F) (n : ℕ) + (d : E) (x : Fin n → F) : + wordMap E F U V n (word E F n d x) = word E F n (U d) (fun i => V (x i)) := by + simp only [wordMap, word, completionIsometry_coe, TensorProduct.mapIsometry_apply, + TensorProduct.map_tmul, LinearIsometry.coe_toLinearMap, powerMap_pure] + +end PreHilbert + +open PreHilbert + +variable (E F : PreHilbert) (k l : ℕ) + +variable {M : Type*} [AddCommGroup M] [Module ℂ M] [StarAddMonoid M] + +lemma coefficient_invariant + (Y : wordSpace E F k →L[ℂ] wordSpace E F l) (Ω : E) + (v₀ : M →ₗ[ℂ] E) (v₁ : M →ₗ[ℂ] F) + (U : E →ₗᵢ[ℂ] E) (V : F →ₗᵢ[ℂ] F) (C : M → M) + (hstar : ∀ a, star (C a) = C (star a)) + (hv₀ : ∀ a, v₀ (C a) = U (v₀ a)) (hv₁ : ∀ a, v₁ (C a) = V (v₁ a)) + (hΩ : U Ω = Ω) + (hY : Y.comp (wordMap E F U V k).toContinuousLinearMap = + (wordMap E F U V l).toContinuousLinearMap.comp Y) + (A : Option (Fin k ⊕ Fin l) → M) : + coefficient E F k l Y Ω v₀ v₁ (fun i => C (A i)) = + coefficient E F k l Y Ω v₀ v₁ A := by + have hy (x : wordSpace E F k) : + Y (wordMap E F U V k x) = wordMap E F U V l (Y x) := + congrArg (fun T : wordSpace E F k →L[ℂ] wordSpace E F l => T x) hY + simp only [coefficient, hstar, hv₀, hv₁] + rw [← wordMap_word] + have hx : word E F k Ω (fun i => V (v₁ (A (some (.inl i))))) = + wordMap E F U V k (word E F k Ω (fun i => v₁ (A (some (.inl i))))) := by + rw [wordMap_word, hΩ] + rw [hx, hy, LinearIsometry.inner_map_map] + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorAdjoints.lean b/lean/OAI/Analysis/Commutator/TensorAdjoints.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ed1637b9186e01d6ebb34c83390a01b1a87e919 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorAdjoints.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorMultiplicity2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.HilbertTensor + +open ContinuousLinearMap + +variable {E F J K : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [NormedAddCommGroup J] [InnerProductSpace ℂ J] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] + +lemma scalarSlice_adjoint + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (F ⊗[ℂ] K)) + (a : K) (b : J) : scalarSlice T.adjoint a b = (scalarSlice T b a).adjoint := by + simp only [scalarSlice, adjoint_comp, adjoint_adjoint, ContinuousLinearMap.comp_assoc] + +omit [CompleteSpace E] in +lemma multiplicityCompression_adjoint [CompleteSpace J] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) (v : E) : + multiplicityCompression T.adjoint v = (multiplicityCompression T v).adjoint := by + simp only [multiplicityCompression, adjoint_comp, adjoint_adjoint, ContinuousLinearMap.comp_assoc] + +lemma isometry_adjoint_fix (U : E →ₗᵢ[ℂ] E) (v : E) (h : U v = v) : + U.toContinuousLinearMap.adjoint v = v := by + conv_lhs => rw [← h] + exact congrArg (fun T : E →L[ℂ] E => T v) U.adjoint_comp_self + +lemma repeated_pair_adjoint [CompleteSpace J] {ι : Type*} [Fintype ι] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) + (U : ι → E →ₗᵢ[ℂ] E) + (hclass : ∀ a b : J, ∃ c : ι → ℂ, + scalarSlice T a b = ∑ i, c i • (U i).toContinuousLinearMap) + (v w : E) (hv : ‖v‖ = 1) (hUv : ∀ i, U i v = v) (hUw : ∀ i, U i w = w) + (a : J) : T.adjoint (pair w a) = pair w ((multiplicityCompression T v).adjoint a) := by + rw [← multiplicityCompression_adjoint] + have hclassAdj : ∀ b c : J, ∃ d : ι → ℂ, + scalarSlice T.adjoint b c = ∑ i, d i • (U i).toContinuousLinearMap.adjoint := by + intro b c + obtain ⟨d, hd⟩ := hclass c b + refine ⟨fun i => star (d i), ?_⟩ + rw [scalarSlice_adjoint, hd] + simp only [map_sum, map_smulₛₗ, starRingEnd_apply] + exact repeated_pair T.adjoint (fun i => (U i).toContinuousLinearMap.adjoint) hclassAdj v w hv + (fun i => isometry_adjoint_fix (U i) v (hUv i)) + (fun i => isometry_adjoint_fix (U i) w (hUw i)) a + +end Kadison.HilbertTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorCompletion.lean b/lean/OAI/Analysis/Commutator/TensorCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..6e30b93f8017fb0aeb1966be8695f5c5bbb5f0d3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorCompletion.lean @@ -0,0 +1,103 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.HilbertCompletion + +variable {E F G H : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +def coeIsometry (E : Type*) [NormedAddCommGroup E] [InnerProductSpace ℂ E] : + E →ₗᵢ[ℂ] Completion E where + toLinearMap := (Completion.toComplL : E →L[ℂ] Completion E).toLinearMap + norm_map' := Completion.norm_coe + +def map (U : E →ₗᵢ[ℂ] F) : Completion E →ₗᵢ[ℂ] Completion F where + toLinearMap := U.toContinuousLinearMap.completion.toLinearMap + norm_map' x := by + induction x using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih x => simp + +@[simp] lemma map_coe (U : E →ₗᵢ[ℂ] F) (x : E) : map U (x : Completion E) = (U x : Completion F) := by + simp [map] + +def congr (U : E ≃ₗᵢ[ℂ] F) : Completion E ≃ₗᵢ[ℂ] Completion F := + LinearIsometryEquiv.ofSurjective (map U.toLinearIsometry) (by + intro y + refine ⟨map U.symm.toLinearIsometry y, ?_⟩ + induction y using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih y => simp) + +@[simp] lemma congr_coe (U : E ≃ₗᵢ[ℂ] F) (x : E) : congr U (x : Completion E) = (U x : Completion F) := + map_coe U.toLinearIsometry x + +def tensorMap : Completion (E ⊗[ℂ] F) →ₗᵢ[ℂ] Completion (Completion E ⊗[ℂ] Completion F) := + map (TensorProduct.mapIsometry (coeIsometry E) (coeIsometry F)) + +@[simp] lemma tensorMap_coe_tmul (x : E) (y : F) : + tensorMap (E := E) (F := F) ((x ⊗ₜ[ℂ] y) : Completion (E ⊗[ℂ] F)) = + (((x : Completion E) ⊗ₜ[ℂ] (y : Completion F)) : Completion (Completion E ⊗[ℂ] Completion F)) := by + simp [tensorMap, coeIsometry] + +lemma tensorMap_surjective : Function.Surjective (tensorMap (E := E) (F := F)) := by + let R := LinearMap.range (tensorMap (E := E) (F := F)).toLinearMap + have hR : IsClosed (R : Set (Completion (Completion E ⊗[ℂ] Completion F))) := + (tensorMap (E := E) (F := F)).isometry.isClosedEmbedding.isClosed_range + have hp : ∀ (x : Completion E) (y : Completion F), + ((x ⊗ₜ[ℂ] y) : Completion (Completion E ⊗[ℂ] Completion F)) ∈ R := by + intro x y + induction x, y using Completion.induction_on₂ with + | hp => exact hR.preimage (by fun_prop) + | ih x y => exact ⟨((x ⊗ₜ[ℂ] y) : Completion (E ⊗[ℂ] F)), tensorMap_coe_tmul x y⟩ + intro z + change z ∈ R + induction z using Completion.induction_on with + | hp => exact hR + | ih z => + induction z using TensorProduct.inductionOn with + | add x y hx hy => simpa only [Completion.coe_add] using R.add_mem hx hy + | tmul x y => exact hp x y + +def tensor : Completion (E ⊗[ℂ] F) ≃ₗᵢ[ℂ] Completion (Completion E ⊗[ℂ] Completion F) := + LinearIsometryEquiv.ofSurjective tensorMap tensorMap_surjective + +@[simp] lemma tensor_coe_tmul (x : E) (y : F) : + tensor (E := E) (F := F) ((x ⊗ₜ[ℂ] y) : Completion (E ⊗[ℂ] F)) = + (((x : Completion E) ⊗ₜ[ℂ] (y : Completion F)) : Completion (Completion E ⊗[ℂ] Completion F)) := + tensorMap_coe_tmul x y + +def leftSwap : E ⊗[ℂ] (F ⊗[ℂ] G) ≃ₗᵢ[ℂ] F ⊗[ℂ] (E ⊗[ℂ] G) := + (TensorProduct.assocIsometry ℂ E F G).symm |>.trans + (TensorProduct.congrIsometry (TensorProduct.commIsometry ℂ E F) (.refl ℂ G)) |>.trans + (TensorProduct.assocIsometry ℂ F E G) + +@[simp] lemma leftSwap_tmul (x : E) (y : F) (z : G) : + leftSwap (x ⊗ₜ[ℂ] (y ⊗ₜ[ℂ] z)) = y ⊗ₜ[ℂ] (x ⊗ₜ[ℂ] z) := by + simp [leftSwap] + +end Kadison.HilbertCompletion +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorDevelopment.lean b/lean/OAI/Analysis/Commutator/TensorDevelopment.lean new file mode 100644 index 0000000000000000000000000000000000000000..b70a5cc37f297fcfe3ccd60cd808b657bec6191c --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorDevelopment.lean @@ -0,0 +1,212 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter + +namespace Kadison + +namespace HilbertTensor + +variable {𝕜 E F : Type*} [RCLike 𝕜] + [NormedAddCommGroup E] [InnerProductSpace 𝕜 E] + [NormedAddCommGroup F] [InnerProductSpace 𝕜 F] + +noncomputable def slicePre (ℓ : E →L[𝕜] 𝕜) : E ⊗[𝕜] F →L[𝕜] F := + (TensorProduct.lidIsometry 𝕜 F).toContinuousLinearEquiv.toContinuousLinearMap.comp + (TensorProduct.mapL ℓ (ContinuousLinearMap.id 𝕜 F)) + +@[simp] lemma slicePre_tmul (ℓ : E →L[𝕜] 𝕜) (x : E) (y : F) : + slicePre ℓ (x ⊗ₜ[𝕜] y) = ℓ x • y := by simp [slicePre] + +lemma norm_slicePre_le (ℓ : E →L[𝕜] 𝕜) : ‖slicePre (F := F) ℓ‖ ≤ ‖ℓ‖ := by + apply (slicePre (F := F) ℓ).opNorm_le_bound (norm_nonneg ℓ) + intro x + change ‖TensorProduct.lidIsometry 𝕜 F (TensorProduct.mapL ℓ (.id 𝕜 F) x)‖ ≤ _ + rw [(TensorProduct.lidIsometry 𝕜 F).norm_map] + calc + _ ≤ ‖TensorProduct.mapL ℓ (.id 𝕜 F)‖ * ‖x‖ := ContinuousLinearMap.le_opNorm _ _ + _ ≤ (‖ℓ‖ * ‖ContinuousLinearMap.id 𝕜 F‖) * ‖x‖ := + mul_le_mul_of_nonneg_right (TensorProduct.norm_mapL_le _ _) (norm_nonneg _) + _ ≤ ‖ℓ‖ * ‖x‖ := by + simpa using mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left + (ContinuousLinearMap.norm_id_le (𝕜 := 𝕜) (E := F)) (norm_nonneg ℓ)) + (norm_nonneg x) + +noncomputable def slice (ℓ : E →L[𝕜] 𝕜) : + Completion (E ⊗[𝕜] F) →L[𝕜] Completion F := (slicePre (F := F) ℓ).completion + +@[simp] lemma slice_coe (ℓ : E →L[𝕜] 𝕜) (x : E ⊗[𝕜] F) : + slice ℓ (x : Completion (E ⊗[𝕜] F)) = ((slicePre (F := F) ℓ x : F) : Completion F) := by + simp [slice] + +lemma norm_slice_le (ℓ : E →L[𝕜] 𝕜) : ‖slice (F := F) ℓ‖ ≤ ‖ℓ‖ := by + apply (slice (F := F) ℓ).opNorm_le_bound (norm_nonneg ℓ) + intro x + induction x using Completion.induction_on with + | hp => exact isClosed_le (by fun_prop) (by fun_prop) + | ih x => + simpa using (ContinuousLinearMap.le_opNorm (slicePre (F := F) ℓ) x).trans + (mul_le_mul_of_nonneg_right (norm_slicePre_le ℓ) (norm_nonneg x)) + +lemma tendsto_slice_zero {ι : Type*} {l : Filter ι} (ℓ : ι → E →L[𝕜] 𝕜) + {C : NNReal} (hC : ∀ i, ‖ℓ i‖ ≤ C) + (hℓ : ∀ x : E, Tendsto (fun i => ℓ i x) l (𝓝 0)) + (y : Completion (E ⊗[𝕜] F)) : + Tendsto (fun i => slice (F := F) (ℓ i) y) l (𝓝 0) := by + induction y using Completion.induction_on with + | hp => + apply Equicontinuous.isClosed_setOfPred_tendsto _ continuous_const + apply UniformEquicontinuous.equicontinuous + apply LipschitzWith.uniformEquicontinuous _ C + intro i + apply (slice (F := F) (ℓ i)).lipschitzWith.weaken + exact (norm_slice_le (F := F) (ℓ i)).trans (hC i) + | ih y => + induction y using TensorProduct.inductionOn with + | tmul x y => + simpa only [slice_coe, slicePre_tmul, Completion.coe_smul, zero_smul] using + (hℓ x).smul (tendsto_const_nhds (x := (y : Completion F))) + | add x y hx hy => + simpa only [Completion.coe_add, map_add, add_zero] using hx.add hy + +lemma tendsto_orthonormal_inner_zero {v : ℕ → E} (hv : Orthonormal 𝕜 v) (x : E) : + Tendsto (fun n => inner 𝕜 (v n) x) atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + have h := (hv.inner_products_summable x).tendsto_atTop_zero + have hs := (Real.continuous_sqrt.tendsto 0).comp h + simpa only [Function.comp_def, Real.sqrt_sq (norm_nonneg _), Real.sqrt_zero] using hs + +lemma norm_completion (f : E →L[𝕜] F) : ‖f.completion‖ = ‖f‖ := by + apply le_antisymm + · apply f.completion.opNorm_le_bound (norm_nonneg f) + intro x + induction x using Completion.induction_on with + | hp => exact isClosed_le (by fun_prop) (by fun_prop) + | ih x => simpa using f.le_opNorm x + · apply f.opNorm_le_bound (norm_nonneg f.completion) + intro x + simpa using f.completion.le_opNorm (x : Completion E) + +variable {G H : Type*} + [NormedAddCommGroup G] [InnerProductSpace 𝕜 G] + [NormedAddCommGroup H] [InnerProductSpace 𝕜 H] + +lemma norm_mapL (f : E →L[𝕜] F) (g : G →L[𝕜] H) : + ‖TensorProduct.mapL f g‖ = ‖f‖ * ‖g‖ := by + apply le_antisymm (TensorProduct.norm_mapL_le f g) + have hxy (x : E) (y : G) : + ‖f x‖ * ‖g y‖ ≤ ‖TensorProduct.mapL f g‖ * (‖x‖ * ‖y‖) := by + simpa only [TensorProduct.mapL_tmul, TensorProduct.norm_tmul] using + (TensorProduct.mapL f g).le_opNorm (x ⊗ₜ[𝕜] y) + have hy (y : G) : ‖f‖ * ‖g y‖ ≤ ‖TensorProduct.mapL f g‖ * ‖y‖ := by + have h := ((‖g y‖ : 𝕜) • f).opNorm_le_bound + (mul_nonneg (norm_nonneg (TensorProduct.mapL f g)) (norm_nonneg y)) (fun x => ?_) + · simpa only [norm_smul, RCLike.norm_ofReal, abs_of_nonneg (norm_nonneg _), + mul_comm ‖g y‖ ‖f‖] using h + · simpa only [FunLike.coe_smul, Pi.smul_apply, norm_smul, RCLike.norm_ofReal, + abs_of_nonneg (norm_nonneg _), mul_comm ‖g y‖ ‖f x‖, + mul_assoc, mul_comm ‖y‖ ‖x‖] using hxy x y + have h := ((‖f‖ : 𝕜) • g).opNorm_le_bound + (norm_nonneg (TensorProduct.mapL f g)) (fun y => ?_) + · simpa only [norm_smul, RCLike.norm_ofReal, abs_of_nonneg (norm_nonneg _)] using h + · simpa only [FunLike.coe_smul, Pi.smul_apply, norm_smul, RCLike.norm_ofReal, + abs_of_nonneg (norm_nonneg _)] using hy y + +noncomputable def map (f : E →L[𝕜] F) (g : G →L[𝕜] H) : + Completion (E ⊗[𝕜] G) →L[𝕜] Completion (F ⊗[𝕜] H) := + (TensorProduct.mapL f g).completion + +lemma norm_map (f : E →L[𝕜] F) (g : G →L[𝕜] H) : + ‖map f g‖ = ‖f‖ * ‖g‖ := by rw [map, norm_completion, norm_mapL] + +@[simp] lemma map_coe_tmul (f : E →L[𝕜] F) (g : G →L[𝕜] H) (x : E) (y : G) : + map f g ((x ⊗ₜ[𝕜] y : E ⊗[𝕜] G) : Completion (E ⊗[𝕜] G)) = + ((f x ⊗ₜ[𝕜] g y : F ⊗[𝕜] H) : Completion (F ⊗[𝕜] H)) := by + simp [map] + +lemma completion_ext {f g : Completion (E ⊗[𝕜] G) →L[𝕜] H} + (h : ∀ (x : E) (y : G), f ((x ⊗ₜ[𝕜] y : E ⊗[𝕜] G) : Completion _) = + g ((x ⊗ₜ[𝕜] y : E ⊗[𝕜] G) : Completion _)) : f = g := by + ext z + induction z using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih z => + induction z using TensorProduct.inductionOn with + | tmul x y => exact h x y + | add x y hx hy => simp only [Completion.coe_add, map_add, hx, hy] + +lemma map_add_left (f₁ f₂ : E →L[𝕜] F) (g : G →L[𝕜] H) : + map (f₁ + f₂) g = map f₁ g + map f₂ g := by + apply completion_ext + intro x y + simp [TensorProduct.add_tmul, Completion.coe_add] + +lemma map_add_right (f : E →L[𝕜] F) (g₁ g₂ : G →L[𝕜] H) : + map f (g₁ + g₂) = map f g₁ + map f g₂ := by + apply completion_ext + intro x y + simp [TensorProduct.tmul_add, Completion.coe_add] + +lemma map_sub_right (f : E →L[𝕜] F) (g₁ g₂ : G →L[𝕜] H) : + map f (g₁ - g₂) = map f g₁ - map f g₂ := by + apply completion_ext + intro x y + simp [TensorProduct.tmul_sub, Completion.coe_sub] + +lemma map_smul_left (c : 𝕜) (f : E →L[𝕜] F) (g : G →L[𝕜] H) : + map (c • f) g = c • map f g := by + apply completion_ext + intro x y + simp [← TensorProduct.smul_tmul', Completion.coe_smul] + +lemma map_smul_right (c : 𝕜) (f : E →L[𝕜] F) (g : G →L[𝕜] H) : + map f (c • g) = c • map f g := by + apply completion_ext + intro x y + simp [TensorProduct.tmul_smul, Completion.coe_smul] + +lemma map_mul (f₁ f₂ : E →L[𝕜] E) (g₁ g₂ : F →L[𝕜] F) : + map (f₁ * f₂) (g₁ * g₂) = map f₁ g₁ * map f₂ g₂ := by + apply completion_ext + intro x y + simp + +@[simp] lemma map_one_one : map (1 : E →L[𝕜] E) (1 : F →L[𝕜] F) = 1 := by + apply completion_ext + intro x y + simp + +lemma hankel_commutator_norm (T H : E →L[𝕜] E) (B S : F →L[𝕜] F) (u : 𝕜) : + ‖map (1 : E →L[𝕜] E) B * (u • (map T (1 : F →L[𝕜] F) + map H S)) - + (u • (map T (1 : F →L[𝕜] F) + map H S)) * map (1 : E →L[𝕜] E) B‖ = + ‖u‖ * ‖H‖ * ‖B * S - S * B‖ := by + have h : map (1 : E →L[𝕜] E) B * (map T (1 : F →L[𝕜] F) + map H S) - + (map T (1 : F →L[𝕜] F) + map H S) * map (1 : E →L[𝕜] E) B = + map H (B * S - S * B) := by + rw [mul_add, add_mul, ← map_mul, ← map_mul, ← map_mul, ← map_mul] + simp only [one_mul, mul_one, map_sub_right] + abel + rw [mul_smul_comm, smul_mul_assoc, ← smul_sub, h, norm_smul, norm_map, mul_assoc] + +lemma tendsto_orthonormal_slice_zero {v : ℕ → E} (hv : Orthonormal 𝕜 v) + (y : Completion (E ⊗[𝕜] F)) : + Tendsto (fun n => slice (F := F) (innerSL 𝕜 (v n)) y) atTop (𝓝 0) := by + apply tendsto_slice_zero (C := 1) + · intro n + simp only [innerSL_apply_norm, hv.norm_eq_one, NNReal.coe_one, le_refl] + · exact tendsto_orthonormal_inner_zero hv + +end HilbertTensor + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorMultiplicity.lean b/lean/OAI/Analysis/Commutator/TensorMultiplicity.lean new file mode 100644 index 0000000000000000000000000000000000000000..60447dbd4af183c4e4c06130d90b296470f95321 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorMultiplicity.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorDevelopment + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.HilbertTensor + +variable {E F J K : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup J] [InnerProductSpace ℂ J] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] + +def pair (x : E) (a : J) : Completion (E ⊗[ℂ] J) := (x ⊗ₜ[ℂ] a : E ⊗[ℂ] J) + +@[simp] lemma inner_pair (x y : E) (a b : J) : + inner ℂ (pair x a) (pair y b) = inner ℂ x y * inner ℂ a b := by + simp only [pair, Completion.inner_coe, TensorProduct.inner_tmul] + +@[simp] lemma norm_pair (x : E) (a : J) : ‖pair x a‖ = ‖x‖ * ‖a‖ := by + simp only [pair, Completion.norm_coe, TensorProduct.norm_tmul] + +def insertRight (a : J) : E →L[ℂ] Completion (E ⊗[ℂ] J) := + Completion.toComplL.comp ((TensorProduct.mkL ℂ E J).flip a) + +@[simp] lemma insertRight_apply (a : J) (x : E) : insertRight a x = pair x a := rfl + +lemma norm_insertRight_le (a : J) : ‖insertRight (E := E) a‖ ≤ ‖a‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + simp only [insertRight_apply, norm_pair, mul_comm, le_refl] + +def insertLeft (x : E) : J →L[ℂ] Completion (E ⊗[ℂ] J) := + Completion.toComplL.comp (TensorProduct.mkL ℂ E J x) + +@[simp] lemma insertLeft_apply (x : E) (a : J) : insertLeft x a = pair x a := rfl + +lemma norm_insertLeft_le (x : E) : ‖insertLeft (J := J) x‖ ≤ ‖x‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro a + simp only [insertLeft_apply, norm_pair, le_refl] + +@[simp] lemma insertRight_adjoint_pair [CompleteSpace E] (b : J) (x : E) (a : J) : + (insertRight b).adjoint (pair x a) = inner ℂ b a • x := by + apply (ext_inner_left ℂ) + intro y + rw [ContinuousLinearMap.adjoint_inner_right, insertRight_apply, inner_pair, inner_smul_right] + exact mul_comm _ _ + +@[simp] lemma insertLeft_adjoint_pair [CompleteSpace J] (y : E) (x : E) (a : J) : + (insertLeft y).adjoint (pair x a) = inner ℂ y x • a := by + apply (ext_inner_left ℂ) + intro b + rw [ContinuousLinearMap.adjoint_inner_right, insertLeft_apply, inner_pair, inner_smul_right] + +def scalarSlice [CompleteSpace F] (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (F ⊗[ℂ] K)) + (a : J) (b : K) : E →L[ℂ] F := + ((insertRight b).adjoint.comp T).comp (insertRight a) + +lemma scalarSlice_inner [CompleteSpace F] (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (F ⊗[ℂ] K)) + (a : J) (b : K) (x : E) (y : F) : + inner ℂ y (scalarSlice T a b x) = inner ℂ (pair y b) (T (pair x a)) := by + simp only [scalarSlice, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.adjoint_inner_right, insertRight_apply] + +lemma eq_zero_of_pair_inner (z : Completion (E ⊗[ℂ] J)) + (h : ∀ x a, inner ℂ (pair x a) z = 0) : z = 0 := by + apply (inner_self_eq_zero (𝕜 := ℂ)).mp + have hz (y : Completion (E ⊗[ℂ] J)) : inner ℂ y z = 0 := by + induction y using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) continuous_const + | ih y => + induction y using TensorProduct.inductionOn with + | tmul x a => exact h x a + | add x y hx hy => simp only [Completion.coe_add, inner_add_left, hx, hy, add_zero] + exact hz z + +lemma pair_inner_ext (z w : Completion (E ⊗[ℂ] J)) + (h : ∀ x a, inner ℂ (pair x a) z = inner ℂ (pair x a) w) : z = w := by + apply sub_eq_zero.mp + apply eq_zero_of_pair_inner + intro x a + rw [inner_sub_right, h, sub_self] + +lemma eq_zero_of_scalarSlice [CompleteSpace F] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (F ⊗[ℂ] K)) + (h : ∀ a b, scalarSlice T a b = 0) : T = 0 := by + apply completion_ext + intro x a + change T (pair x a) = 0 + apply eq_zero_of_pair_inner + intro y b + rw [← scalarSlice_inner, h, zero_apply, inner_zero_right] + +end Kadison.HilbertTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorMultiplicity2.lean b/lean/OAI/Analysis/Commutator/TensorMultiplicity2.lean new file mode 100644 index 0000000000000000000000000000000000000000..41956e93ce36d0644c0c901754363934f69bbc4a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorMultiplicity2.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorMultiplicity + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.HilbertTensor + +variable {E F J K : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + [NormedAddCommGroup J] [InnerProductSpace ℂ J] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] + +@[simp] lemma map_pair (f : E →L[ℂ] F) (g : J →L[ℂ] K) (x : E) (a : J) : + map f g (pair x a) = pair (f x) (g a) := map_coe_tmul _ _ _ _ + +lemma insertRight_adjoint_map [CompleteSpace E] [CompleteSpace F] + (b : J) (f : E →L[ℂ] F) : + (insertRight b).adjoint.comp (map f (1 : J →L[ℂ] J)) = + f.comp (insertRight b).adjoint := by + apply completion_ext + intro x a + change (insertRight b).adjoint (map f (1 : J →L[ℂ] J) (pair x a)) = + f ((insertRight b).adjoint (pair x a)) + simp only [map_pair, one_apply_eq_self, insertRight_adjoint_pair, map_smul] + +lemma scalarSlice_covariant [CompleteSpace E] [CompleteSpace F] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (F ⊗[ℂ] K)) + (f : E →L[ℂ] E) (g : F →L[ℂ] F) + (h : T.comp (map f (1 : J →L[ℂ] J)) = (map g (1 : K →L[ℂ] K)).comp T) + (a : J) (b : K) : (scalarSlice T a b).comp f = g.comp (scalarSlice T a b) := by + ext x + have ht := congrArg (fun R : Completion (E ⊗[ℂ] J) →L[ℂ] + Completion (F ⊗[ℂ] K) => R (pair x a)) h + have ho := congrArg (fun R : Completion (F ⊗[ℂ] K) →L[ℂ] F => + R (T (pair x a))) (insertRight_adjoint_map b g) + simp only [ContinuousLinearMap.comp_apply, map_pair, one_apply_eq_self] at ht + change (insertRight b).adjoint (T (pair (f x) a)) = + g ((insertRight b).adjoint (T (pair x a))) + rw [ht] + exact ho + +def multiplicityCompression [CompleteSpace J] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) (v : E) : J →L[ℂ] J := + ((insertLeft v).adjoint.comp T).comp (insertLeft v) + +lemma multiplicityCompression_inner [CompleteSpace E] [CompleteSpace J] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) (v : E) (a b : J) : + inner ℂ b (multiplicityCompression T v a) = inner ℂ v (scalarSlice T a b v) := by + simp only [multiplicityCompression, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.adjoint_inner_right, insertLeft_apply, scalarSlice_inner] + +lemma norm_multiplicityCompression_le [CompleteSpace J] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) (v : E) (hv : ‖v‖ = 1) : + ‖multiplicityCompression T v‖ ≤ ‖T‖ := by + have hi : ‖insertLeft (J := J) v‖ ≤ 1 := by simpa only [hv] using norm_insertLeft_le (J := J) v + have hia : ‖(insertLeft (J := J) v).adjoint‖ ≤ 1 := by + simpa only [LinearIsometryEquiv.norm_map] using hi + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + ((mul_le_mul_of_nonneg_right (ContinuousLinearMap.opNorm_comp_le _ _) (norm_nonneg _)).trans + (calc + ‖(insertLeft (J := J) v).adjoint‖ * ‖T‖ * ‖insertLeft (J := J) v‖ + ≤ (1 * ‖T‖) * ‖insertLeft (J := J) v‖ := + mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_right hia (norm_nonneg T)) + (norm_nonneg (insertLeft (J := J) v)) + _ ≤ ‖T‖ := by + simpa only [one_mul, mul_one] using mul_le_mul_of_nonneg_left hi (norm_nonneg T))) + +theorem repeated_pair [CompleteSpace E] [CompleteSpace J] + {ι : Type*} [Fintype ι] + (T : Completion (E ⊗[ℂ] J) →L[ℂ] Completion (E ⊗[ℂ] J)) + (U : ι → E →L[ℂ] E) + (hclass : ∀ a b : J, ∃ c : ι → ℂ, scalarSlice T a b = ∑ i, c i • U i) + (v w : E) (hv : ‖v‖ = 1) (hUv : ∀ i, U i v = v) (hUw : ∀ i, U i w = w) + (a : J) : T (pair w a) = pair w (multiplicityCompression T v a) := by + classical + apply pair_inner_ext + intro x b + obtain ⟨c, hc⟩ := hclass a b + have hc_v : scalarSlice T a b v = (∑ i, c i) • v := by + simp only [hc, sum_apply, smul_apply, hUv, Finset.sum_smul] + have hc_w : scalarSlice T a b w = (∑ i, c i) • w := by + simp only [hc, sum_apply, smul_apply, hUw, Finset.sum_smul] + have hsum : inner ℂ b (multiplicityCompression T v a) = ∑ i, c i := by + rw [multiplicityCompression_inner, hc_v, inner_smul_right, + inner_self_eq_norm_sq_to_K, hv] + simp + rw [← scalarSlice_inner, hc_w, inner_smul_right, inner_pair, hsum] + exact mul_comm _ _ + +end Kadison.HilbertTensor +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorPermutations.lean b/lean/OAI/Analysis/Commutator/TensorPermutations.lean new file mode 100644 index 0000000000000000000000000000000000000000..2514dc0eff084c2c98615422bd04fa2201eb2fce --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorPermutations.lean @@ -0,0 +1,88 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +section Gram + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +theorem inner_linearCombination_eq (a : ι → E) (b : ι → F) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) + (x y : ι →₀ ℂ) : + inner ℂ (Finsupp.linearCombination ℂ b x) (Finsupp.linearCombination ℂ b y) = + inner ℂ (Finsupp.linearCombination ℂ a x) (Finsupp.linearCombination ℂ a y) := by + classical + simp only [Finsupp.linearCombination_apply, Finsupp.sum, sum_inner, inner_sum, + inner_smul_left, inner_smul_right, h] + +def gramIsometry (a : ι → E) (b : ι → F) + (ha : Submodule.span ℂ (Set.range a) = ⊤) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) : E →ₗᵢ[ℂ] F := by + let A := Finsupp.linearCombination ℂ a + let B := Finsupp.linearCombination ℂ b + have hA : Function.Surjective A := by + apply LinearMap.range_eq_top.mp + rwa [Finsupp.range_linearCombination] + have hker : LinearMap.ker A ≤ LinearMap.ker B := by + intro x hx + apply LinearMap.mem_ker.mpr + apply (inner_self_eq_zero (𝕜 := ℂ)).mp + rw [inner_linearCombination_eq a b h] + rw [LinearMap.mem_ker.mp hx] + simp + let f := (LinearMap.ker A).liftQ B hker |>.comp + (A.quotKerEquivOfSurjective hA).symm.toLinearMap + have happ : ∀ x, f (A x) = B x := by + intro x + change (LinearMap.ker A).liftQ B hker + ((A.quotKerEquivOfSurjective hA).symm (A x)) = B x + have he : (A.quotKerEquivOfSurjective hA).symm (A x) = + Submodule.Quotient.mk x := by + apply (A.quotKerEquivOfSurjective hA).injective + simp [LinearMap.quotKerEquivOfSurjective_apply_mk] + rw [he, Submodule.liftQ_apply] + refine ⟨f, ?_⟩ + apply (LinearMap.norm_map_iff_inner_map_map f).mpr + intro x y + obtain ⟨v, rfl⟩ := hA x + obtain ⟨w, rfl⟩ := hA y + rw [happ, happ] + exact inner_linearCombination_eq a b h v w + +@[simp] theorem gramIsometry_apply (a : ι → E) (b : ι → F) + (ha : Submodule.span ℂ (Set.range a) = ⊤) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) (i : ι) : + gramIsometry a b ha h (a i) = b i := by + classical + unfold gramIsometry + dsimp + have hA : Function.Surjective (Finsupp.linearCombination ℂ a) := by + apply LinearMap.range_eq_top.mp + rwa [Finsupp.range_linearCombination] + have he : ((Finsupp.linearCombination ℂ a).quotKerEquivOfSurjective hA).symm + (a i) = Submodule.Quotient.mk (Finsupp.single i 1) := by + apply ((Finsupp.linearCombination ℂ a).quotKerEquivOfSurjective hA).injective + simp [LinearMap.quotKerEquivOfSurjective_apply_mk] + rw [he, Submodule.liftQ_apply] + simp + +end Gram + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorPermutations2.lean b/lean/OAI/Analysis/Commutator/TensorPermutations2.lean new file mode 100644 index 0000000000000000000000000000000000000000..5fdabb264b3ffcf45f67e5d8b5ca8490ffd74c46 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorPermutations2.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.Commutator.TensorPermutations + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison + +section GramEquiv + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +theorem gramIsometry_surjective (a : ι → E) (b : ι → F) + (ha : Submodule.span ℂ (Set.range a) = ⊤) + (hb : Submodule.span ℂ (Set.range b) = ⊤) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) : + Function.Surjective (gramIsometry a b ha h) := by + apply LinearMap.range_eq_top.mp + apply top_unique + rw [← hb] + apply Submodule.span_le.mpr + rintro _ ⟨i, rfl⟩ + exact ⟨a i, gramIsometry_apply a b ha h i⟩ + +def gramEquiv (a : ι → E) (b : ι → F) + (ha : Submodule.span ℂ (Set.range a) = ⊤) + (hb : Submodule.span ℂ (Set.range b) = ⊤) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) : E ≃ₗᵢ[ℂ] F := + LinearIsometryEquiv.ofSurjective (gramIsometry a b ha h) + (gramIsometry_surjective a b ha hb h) + +@[simp] theorem gramEquiv_apply (a : ι → E) (b : ι → F) + (ha : Submodule.span ℂ (Set.range a) = ⊤) + (hb : Submodule.span ℂ (Set.range b) = ⊤) + (h : ∀ i j, inner ℂ (b i) (b j) = inner ℂ (a i) (a j)) (i : ι) : + gramEquiv a b ha hb h (a i) = b i := gramIsometry_apply a b ha h i + +end GramEquiv + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorPermutations3.lean b/lean/OAI/Analysis/Commutator/TensorPermutations3.lean new file mode 100644 index 0000000000000000000000000000000000000000..ff9b0680af0b6a211dcaec33edc8cf62196e7f4e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorPermutations3.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors2 +import OAI.Analysis.Commutator.TensorPermutations2 + +namespace OAI + +noncomputable section + +noncomputable section + +open scoped TensorProduct + +namespace Kadison + +attribute [instance] PreHilbert.normed PreHilbert.ipSpace + +namespace PreHilbert + +end PreHilbert + +end Kadison + +namespace Kadison.PreHilbert + +end Kadison.PreHilbert + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +end Kadison + +namespace Kadison + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Kadison + +namespace Kadison + +section Gram + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end Gram + +end Kadison + +namespace Kadison + +section GramEquiv + +variable {ι E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] + +end GramEquiv + +namespace PreHilbert + +def permute (E : PreHilbert) (n : ℕ) (σ : Equiv.Perm (Fin n)) : + power E n ≃ₗᵢ[ℂ] power E n := + gramEquiv (pure E n) (fun v => pure E n (v ∘ σ)) (span_pure E n) + (by + have hr : Set.range (fun v => pure E n (v ∘ σ)) = Set.range (pure E n) := by + ext x + constructor + · rintro ⟨v, rfl⟩; exact ⟨v ∘ σ, rfl⟩ + · rintro ⟨v, rfl⟩ + refine ⟨v ∘ σ.symm, ?_⟩ + exact congrArg (pure E n) (funext fun i => by simp) + rw [hr, span_pure]) + (by + intro v w + simp only [inner_pure, Function.comp_apply] + exact Equiv.prod_comp σ (fun i => inner ℂ (v i) (w i))) + +@[simp] theorem permute_pure (E : PreHilbert) (n : ℕ) (σ : Equiv.Perm (Fin n)) + (v : Fin n → E) : permute E n σ (pure E n v) = pure E n (v ∘ σ) := + gramEquiv_apply _ _ _ _ _ _ + +def hilbertPermute (E : PreHilbert) (n : ℕ) (σ : Equiv.Perm (Fin n)) : + hilbertPower E n ≃ₗᵢ[ℂ] hilbertPower E n := + (permute E n σ).toLinearEquiv.extendOfIsometry + (UniformSpace.Completion.toComplₗᵢ.toLinearMap) + (UniformSpace.Completion.toComplₗᵢ.toLinearMap) + UniformSpace.Completion.denseRange_coe UniformSpace.Completion.denseRange_coe + (by intro x; simp) + +@[simp] theorem hilbertPermute_pure (E : PreHilbert) (n : ℕ) + (σ : Equiv.Perm (Fin n)) (v : Fin n → E) : + hilbertPermute E n σ (hilbertPure E n v) = hilbertPure E n (v ∘ σ) := by + change ((permute E n σ).toLinearEquiv.extendOfIsometry _ _ _ _ _) + ((UniformSpace.Completion.toComplₗᵢ : power E n →ₗᵢ[ℂ] hilbertPower E n).toLinearMap (pure E n v)) = _ + erw [LinearEquiv.extendOfIsometry_eq] + change (permute E n σ (pure E n v) : UniformSpace.Completion (power E n)) = _ + rw [permute_pure] + rfl + +theorem eq_zero_of_hilbertPure_inner (E : PreHilbert) (n : ℕ) + (x : hilbertPower E n) (h : ∀ v, inner ℂ (hilbertPure E n v) x = 0) : x = 0 := by + apply UniformSpace.Completion.denseRange_coe.eq_zero_of_inner_right ℂ + intro y + have hy : y ∈ Submodule.span ℂ (Set.range (pure E n)) := by rw [span_pure]; trivial + induction hy using Submodule.span_induction with + | mem y hy => obtain ⟨v, rfl⟩ := hy; exact h v + | zero => rw [UniformSpace.Completion.coe_zero, inner_zero_left] + | add a b _ _ ha hb => rw [UniformSpace.Completion.coe_add, inner_add_left, ha, hb, add_zero] + | smul c a _ ha => rw [UniformSpace.Completion.coe_smul, inner_smul_left, ha, mul_zero] + +theorem continuousLinearMap_ext_pure (E : PreHilbert) (n : ℕ) + {F : Type*} [NormedAddCommGroup F] [NormedSpace ℂ F] + (S T : hilbertPower E n →L[ℂ] F) + (h : ∀ v, S (hilbertPure E n v) = T (hilbertPure E n v)) : S = T := by + ext x + refine UniformSpace.Completion.induction_on x (isClosed_eq S.continuous T.continuous) ?_ + intro y + have hy : y ∈ Submodule.span ℂ (Set.range (pure E n)) := by rw [span_pure]; trivial + induction hy using Submodule.span_induction with + | mem y hy => obtain ⟨v, rfl⟩ := hy; exact h v + | zero => rw [UniformSpace.Completion.coe_zero, map_zero, map_zero] + | add a b _ _ ha hb => simp only [UniformSpace.Completion.coe_add, map_add, ha, hb] + | smul c a _ ha => simp only [UniformSpace.Completion.coe_smul, map_smul, ha] + +end PreHilbert + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TensorPowerCompletion.lean b/lean/OAI/Analysis/Commutator/TensorPowerCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f8ba8743cd8cec8bfab3603c129e25ae262de76 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TensorPowerCompletion.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertTensors +import OAI.Analysis.Commutator.TensorCompletion + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder +open scoped InnerProductSpace TensorProduct ComplexOrder +open UniformSpace +open scoped InnerProductSpace _root_.Topology +open scoped TensorProduct +open UniformSpace +open scoped TensorProduct InnerProductSpace + +namespace Kadison.HilbertCompletion + +open UniformSpace + +open scoped TensorProduct + +variable (E F : PreHilbert) + +def powerEquiv (U : Completion E ≃ₗᵢ[ℂ] Completion F) : ∀ n, + Completion (PreHilbert.power E n) ≃ₗᵢ[ℂ] Completion (PreHilbert.power F n) + | 0 => .refl ℂ _ + | n+1 => (tensor (E := E) (F := PreHilbert.power E n)).trans + ((congr (TensorProduct.congrIsometry U (powerEquiv U n))).trans + (tensor (E := F) (F := PreHilbert.power F n)).symm) + +lemma powerEquiv_pure (U : Completion E ≃ₗᵢ[ℂ] Completion F) + (n : ℕ) (v : Fin n → E) (w : Fin n → F) + (h : ∀ i, U (v i : Completion E)=(w i : Completion F)) : + powerEquiv E F U n (PreHilbert.pure E n v : Completion (PreHilbert.power E n)) = + (PreHilbert.pure F n w : Completion (PreHilbert.power F n)) := by + induction n with + | zero => rfl + | succ n ih => + change (tensor (E := F) (F := PreHilbert.power F n)).symm + (congr (TensorProduct.congrIsometry U (powerEquiv E F U n)) + (tensor (E := E) (F := PreHilbert.power E n) + ((v 0 ⊗ₜ[ℂ] PreHilbert.pure E n (Fin.tail v)) : + Completion (E ⊗[ℂ] PreHilbert.power E n)))) = _ + apply (tensor (E := F) (F := PreHilbert.power F n)).injective + rw [LinearIsometryEquiv.apply_symm_apply, tensor_coe_tmul, congr_coe, + TensorProduct.congrIsometry_apply, TensorProduct.congr_tmul] + change ((U (v 0 : Completion E) ⊗ₜ[ℂ] + powerEquiv E F U n (PreHilbert.pure E n (Fin.tail v) : Completion (PreHilbert.power E n))) : + Completion (Completion F ⊗[ℂ] Completion (PreHilbert.power F n))) = _ + rw [h 0, ih (Fin.tail v) (Fin.tail w) (fun i => h i.succ)] + exact (tensor_coe_tmul (w 0) (PreHilbert.pure F n (Fin.tail w))).symm + +variable (E' F' : PreHilbert) + +def wordEquiv (U : Completion E ≃ₗᵢ[ℂ] Completion E') + (V : Completion F ≃ₗᵢ[ℂ] Completion F') (n : ℕ) : + Completion (E ⊗[ℂ] PreHilbert.power F n) ≃ₗᵢ[ℂ] + Completion (E' ⊗[ℂ] PreHilbert.power F' n) := + (tensor (E := E) (F := PreHilbert.power F n)).trans + ((congr (TensorProduct.congrIsometry U (powerEquiv F F' V n))).trans + (tensor (E := E') (F := PreHilbert.power F' n)).symm) + +lemma wordEquiv_pure (U : Completion E ≃ₗᵢ[ℂ] Completion E') + (V : Completion F ≃ₗᵢ[ℂ] Completion F') (n : ℕ) + (a : E) (a' : E') (ha : U (a : Completion E)=(a' : Completion E')) + (v : Fin n → F) (w : Fin n → F') + (hv : ∀ i, V (v i : Completion F)=(w i : Completion F')) : + wordEquiv E F E' F' U V n + ((a ⊗ₜ[ℂ] PreHilbert.pure F n v) : Completion (E ⊗[ℂ] PreHilbert.power F n)) = + ((a' ⊗ₜ[ℂ] PreHilbert.pure F' n w) : Completion (E' ⊗[ℂ] PreHilbert.power F' n)) := by + change (tensor (E := E') (F := PreHilbert.power F' n)).symm + (congr (TensorProduct.congrIsometry U (powerEquiv F F' V n)) + (tensor (E := E) (F := PreHilbert.power F n) + ((a ⊗ₜ[ℂ] PreHilbert.pure F n v) : Completion (E ⊗[ℂ] PreHilbert.power F n)))) = _ + apply (tensor (E := E') (F := PreHilbert.power F' n)).injective + rw [LinearIsometryEquiv.apply_symm_apply, tensor_coe_tmul, congr_coe, + TensorProduct.congrIsometry_apply, TensorProduct.congr_tmul] + change ((U (a : Completion E) ⊗ₜ[ℂ] + powerEquiv F F' V n (PreHilbert.pure F n v : Completion (PreHilbert.power F n))) : + Completion (Completion E' ⊗[ℂ] Completion (PreHilbert.power F' n))) = _ + rw [ha, powerEquiv_pure F F' V n v w hv] + exact (tensor_coe_tmul a' (PreHilbert.pure F' n w)).symm + +end Kadison.HilbertCompletion +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TightField.lean b/lean/OAI/Analysis/Commutator/TightField.lean new file mode 100644 index 0000000000000000000000000000000000000000..c3a70b072f7ff1a58cff90557d5044c169bf1127 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TightField.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.FieldAlgebra + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory Filter + +open scoped Topology InnerProductSpace + +namespace Kadison.Decomposable + +variable {Ω H : Type*} [MeasurableSpace Ω] (μ : Measure Ω) + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] + +omit [CompleteSpace H] [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] in +lemma operator_bound_irrel (T : Ω → H →L[ℂ] H) + (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + {b c : ℝ} (hb : ∀ᵐ a ∂μ,‖T a‖≤b) (hc : ∀ᵐ a ∂μ,‖T a‖≤c) : + operator μ T hm hb=operator μ T hm hc := by + apply operator_eq_of_ae_apply + exact operator_ae μ T hm hb + +lemma fieldMember_tight (Q : Ω → VonNeumannAlgebra H) + {A : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) + {c : ℝ} (hc : 0≤c) (hAc : ‖A‖≤c) : + ∃ (T : Ω → H →L[ℂ] H) (hm : ∀ ξ,AEStronglyMeasurable (fun a => T a ξ) μ) + (hb : ∀ᵐ a ∂μ,‖T a‖≤c),A=operator μ T hm hb ∧ ∀ᵐ a ∂μ,T a∈Q a := by + obtain ⟨T,hm,b,hb,hb0,rfl,hmem⟩ := hA + have hb' := (operator_norm_le_iff_ae μ T hm hb hc).mp hAc + exact ⟨T,hm,hb',operator_bound_irrel μ T hm hb hb',hmem⟩ + +omit [IsFiniteMeasure μ] [TopologicalSpace.SeparableSpace H] in +lemma fieldMember_commutes_indicator (Q : Ω → VonNeumannAlgebra H) + {A : Lp H 2 μ →L[ℂ] Lp H 2 μ} (hA : FieldMember μ Q A) + (s : Set Ω) (hs : MeasurableSet s) : Commute A (indicatorOperator μ s hs) := by + obtain ⟨T,hm,b,hb,_,rfl,_⟩ := hA + exact operator_commutes_indicator μ T hm hb s hs + +end Kadison.Decomposable + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TraceDimension.lean b/lean/OAI/Analysis/Commutator/TraceDimension.lean new file mode 100644 index 0000000000000000000000000000000000000000..a58a153b1927020ea7ffda75a1ab84da1e47610a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TraceDimension.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Commutator.DiffuseProjection +import OAI.Analysis.Commutator.DyadicDimensionAdd +import OAI.Analysis.Commutator.FactorCorner +import OAI.Analysis.Commutator.VonNeumannCStar + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter + +open scoped ComplexOrder InnerProductSpace Topology BigOperators + +namespace Kadison.TraceDimension + +open PartialIsometryOrder PartialIsometryOrder.DyadicPartition + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + +variable (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + +include hτ + +lemma trace_subEquivalent {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (h : SubEquivalent M e f) : (τ ⟨e,heM⟩).re≤(τ ⟨f,hfM⟩).re := by + obtain ⟨v,hv⟩ := h + let a : M := ⟨v.val,v.mem⟩ + have ha : star a*a=⟨e,heM⟩ := Subtype.ext hv + have hb : a*star a≤⟨f,hfM⟩ := v.target_le + calc + _=(τ (star a*a)).re := by rw [ha] + _=(τ (a*star a)).re := congrArg Complex.re (hτ (star a) a) + _≤_ := (τ.monotone hb).1 + +lemma trace_equivalent {e f : H →L[ℂ] H} (heM : e∈M) (hfM : f∈M) + (h : Equivalent M e f) : τ ⟨e,heM⟩=τ ⟨f,hfM⟩ := by + obtain ⟨v,hvi,hvf⟩ := h + let a : M := ⟨v.val,v.mem⟩ + have ha : star a*a=⟨e,heM⟩ := Subtype.ext hvi + have hb : a*star a=⟨f,hfM⟩ := Subtype.ext hvf + rw [←ha,←hb,hτ] + +lemma partition_base_trace {ι : Type*} [Fintype ι] [Nonempty ι] + (D : EqualPartition M ι) (hone : τ 1=1) : + τ ⟨D.base,D.base_mem⟩=(Fintype.card ι:ℂ)⁻¹ := by + have hpiece (i : ι) : τ ⟨D.piece i,D.piece_mem i⟩=τ ⟨D.base,D.base_mem⟩ := + (trace_equivalent M τ hτ D.base_mem (D.piece_mem i) (D.base_equiv_piece i)).symm + have hsum : (∑ i, (⟨D.piece i,D.piece_mem i⟩:M))=1 := by + apply Subtype.ext + change M.toStarSubalgebra.subtype (∑ i,(⟨D.piece i,D.piece_mem i⟩:M))=1 + rw [map_sum] + exact D.total + have he := congrArg τ hsum + rw [map_sum] at he + simp_rw [hpiece] at he + simp only [Finset.sum_const,Finset.card_univ,nsmul_eq_mul,hone] at he + have hn : (Fintype.card ι:ℂ)≠0 := by exact_mod_cast Fintype.card_ne_zero + apply mul_left_cancel₀ hn + rw [mul_inv_cancel₀ hn] + exact he + +lemma partition_part_trace {ι : Type*} [Fintype ι] [Nonempty ι] + (D : EqualPartition M ι) (hone : τ 1=1) (s : Finset ι) : + (τ ⟨D.part s,D.part_mem s⟩).re=(s.card:ℝ)/(Fintype.card ι:ℝ) := by + have hp : (⟨D.part s,D.part_mem s⟩:M)=∑ i∈s,(⟨D.piece i,D.piece_mem i⟩:M) := by + apply Subtype.ext + change D.part s=M.toStarSubalgebra.subtype _ + rw [map_sum] + rfl + rw [hp,map_sum] + have he (i : ι) : τ ⟨D.piece i,D.piece_mem i⟩=(Fintype.card ι:ℂ)⁻¹ := + (trace_equivalent M τ hτ D.base_mem (D.piece_mem i) (D.base_equiv_piece i)).symm.trans + (partition_base_trace M τ hτ D hone) + simp_rw [he] + simp only [Finset.sum_const,nsmul_eq_mul,←Complex.ofReal_natCast, + ←Complex.ofReal_inv,←Complex.ofReal_mul,Complex.ofReal_re,div_eq_mul_inv] + +variable (hfac : FactorCorner.IsFactor M) (hd : DiffuseProjection.HasNoMinimalProjections M) + +lemma dimension_le_trace (hone : τ 1=1) {e : H →L[ℂ] H} + (heM : e∈M) (he : IsStarProjection e) : + dimension M hfac hd e≤(τ ⟨e,heM⟩).re := by + apply le_of_tendsto (lower_tendsto_dimension M hfac hd he) + apply Eventually.of_forall + intro n + let D := partition M hfac hd n + obtain ⟨s,hs,hse⟩ := D.exists_rank e he + have ht := trace_subEquivalent M τ hτ (D.part_mem s) heM hse + rw [partition_part_trace M τ hτ D hone s,hs] at ht + change ((D.rank e:ℝ)/(2:ℝ)^n)≤_ + simpa only [D,cardinality,Nat.cast_pow,Nat.cast_ofNat] using ht + +theorem trace_projection_dimension [Nontrivial H] (hfin : IsFiniteAlgebra M) + (hone : τ 1=1) {e : H →L[ℂ] H} (heM : e∈M) (he : IsStarProjection e) : + (τ ⟨e,heM⟩).re=dimension M hfac hd e := by + apply le_antisymm _ (dimension_le_trace M τ hτ hfac hd hone heM he) + have hc := dimension_le_trace M τ hτ hfac hd hone (M.sub_mem M.one_mem heM) he.one_sub + have hsub : (⟨1-e,M.sub_mem M.one_mem heM⟩:M)=1-⟨e,heM⟩ := rfl + rw [hsub,map_sub,hone,Complex.sub_re,Complex.one_re, + dimension_complement M hfac hd hfin heM he] at hc + linarith + +end Kadison.TraceDimension + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TraceEquivGNS.lean b/lean/OAI/Analysis/Commutator/TraceEquivGNS.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca93314d9d2271d4d2e5bd6ae0f9c89d62942417 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TraceEquivGNS.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.Commutator.GNSVectorUnitary + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.TraceEquivGNS + +open TracialGNS + +variable {A B : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable (e : A ≃⋆ₐ[ℂ] B) (τ : A →ₚ[ℂ] ℂ) (σ : B →ₚ[ℂ] ℂ) + (htrace : ∀ a,σ (e a)=τ a) + +omit [StarOrderedRing A] in +include htrace in +lemma vector_trace (a : A) : τ a=inner ℂ (vacuum σ) + ((σ.gnsStarAlgHom.comp e.toStarAlgHom) a (vacuum σ)) := by + rw [←htrace a] + change σ (e a)=inner ℂ (algebraVector σ 1) (σ.gnsStarAlgHom (e a) (vacuum σ)) + rw [left_vacuum,←algebraVector_apply,inner_algebraVector,star_one,one_mul] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma dense_orbit : DenseRange (fun a : A => (σ.gnsStarAlgHom.comp e.toStarAlgHom) a (vacuum σ)) := by + apply (dense_cyclic_orbit σ).mono + rintro y ⟨b,rfl⟩ + exact ⟨e.symm b,by simp⟩ + +def unitary : τ.GNS ≃ₗᵢ[ℂ] σ.GNS := + VectorGNS.equivalence τ (σ.gnsStarAlgHom.comp e.toStarAlgHom) (vacuum σ) + (vector_trace e τ σ htrace) (dense_orbit e σ) + +lemma unitary_algebraVector (a : A) : + unitary e τ σ htrace (algebraVector τ a)=algebraVector σ (e a) := by + rw [unitary,VectorGNS.equivalence_algebraVector] + exact left_vacuum σ (e a) + +include e htrace in +lemma vector_unitball_closed (hc : IsClosed {x : σ.GNS | ∃ b : B,‖b‖≤1 ∧ algebraVector σ b=x}) : + IsClosed {x : τ.GNS | ∃ a : A,‖a‖≤1 ∧ algebraVector τ a=x} := by + have he : {x : τ.GNS | ∃ a : A,‖a‖≤1 ∧ algebraVector τ a=x} = + (unitary e τ σ htrace) ⁻¹' {x : σ.GNS | ∃ b : B,‖b‖≤1 ∧ algebraVector σ b=x} := by + ext x + constructor + · rintro ⟨a,ha,rfl⟩ + exact ⟨e a,by simpa only [StarAlgEquiv.norm_map] using ha,(unitary_algebraVector e τ σ htrace a).symm⟩ + · rintro ⟨b,hb,hbx⟩ + refine ⟨e.symm b,by simpa only [StarAlgEquiv.norm_map] using hb,?_⟩ + apply (unitary e τ σ htrace).injective + rw [unitary_algebraVector,e.apply_symm_apply,hbx] + rw [he] + exact hc.preimage (unitary e τ σ htrace).continuous + +end Kadison.TraceEquivGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TraceFaithfulHomInjective.lean b/lean/OAI/Analysis/Commutator/TraceFaithfulHomInjective.lean new file mode 100644 index 0000000000000000000000000000000000000000..a48b60583558ed6ea3229d08a69984d26ef509a1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TraceFaithfulHomInjective.lean @@ -0,0 +1,32 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +variable {A B : Type*} [Ring A] [Algebra ℂ A] [StarRing A] [StarModule ℂ A] + [Ring B] [Algebra ℂ B] [StarRing B] [StarModule ℂ B] + +omit [StarModule ℂ A] [StarModule ℂ B] in +lemma traceFaithfulHom_injective (φ : A →⋆ₐ[ℂ] B) (τ : A →ₗ[ℂ] ℂ) (ρ : B →ₗ[ℂ] ℂ) + (hfaith : ∀ a : A,τ (star a*a)=0 → a=0) (htrace : ∀ a,ρ (φ a)=τ a) : + Function.Injective φ := by + intro a b hab + apply sub_eq_zero.mp + apply hfaith + rw [←htrace,map_mul,map_star,map_sub,hab,sub_self,star_zero,mul_zero,map_zero] + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracedSeparableFactorMain.lean b/lean/OAI/Analysis/Commutator/TracedSeparableFactorMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..ea27a0d39e6cb89a3ba2acedfaae19b804614071 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracedSeparableFactorMain.lean @@ -0,0 +1,44 @@ +import Mathlib +import OAI.Analysis.Commutator.NormalGNSSeparable +import OAI.Analysis.Commutator.NormalTracedFactorMain + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.NormalRepresentation + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [TopologicalSpace.SeparableSpace H] + +variable (M : VonNeumannAlgebra H) [Nontrivial M] (τ : M →ₚ[ℂ] ℂ) + +theorem separable_traced_factor_bound + (hτ : ∀ a b : M,τ (a*b)=τ (b*a)) + (hnormal : NormalGNS.BoundedWOTContinuous M τ) + (hfaith : ∀ a : M,τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hfac : FactorCorner.IsFactor M) (hdiffuse : DiffuseProjection.HasNoMinimalProjections M) + (h : ℕ) (hh : 1≤h) (Y : H →L[ℂ] H) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (hX : ∀ i j,X i j∈M) : + ‖diagonalAmplification h Y*matrixOperator h X- + matrixOperator h X*diagonalAmplification h Y‖≤ + (3122*commutatorSeminorm M Y)*‖matrixOperator h X‖ := by + let := NormalGNS.separable_gns M τ hnormal + exact traced_factor_bound M τ hτ hnormal hfaith hone hfac hdiffuse h hh Y X hX + +end Kadison.NormalRepresentation + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialAdjoint.lean b/lean/OAI/Analysis/Commutator/TracialAdjoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..2ced57b2d3657832bcc037a063e6e662c300d784 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialAdjoint.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.CenteredSpace +import OAI.Analysis.Commutator.TracialCommutation + +namespace OAI + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +open Complex ContinuousLinearMap UniformSpace Completion + +namespace Kadison + +namespace TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + +end TracialGNS + +end Kadison + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + +end Kadison.TracialGNS + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +end Kadison + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + +noncomputable def centeredStar : centeredSpace (vacuum τ) →L⋆[ℂ] centeredSpace (vacuum τ) := + ((starMap τ hτ).comp (centeredSpace (vacuum τ)).subtypeL).codRestrict + (centeredSpace (vacuum τ)) (fun x => by + rw [Submodule.mem_orthogonal_singleton_iff_inner_right] + change inner ℂ (vacuum τ) (starMap τ hτ (x : τ.GNS)) = 0 + have h := starMap_inner τ hτ (vacuum τ) (x : τ.GNS) + rw [starMap_vacuum] at h + rw [h, inner_eq_zero_symm] + exact Submodule.mem_orthogonal_singleton_iff_inner_right.mp x.property) + +@[simp] lemma centeredStar_coe (x : centeredSpace (vacuum τ)) : + (centeredStar τ hτ x : τ.GNS) = starMap τ hτ (x : τ.GNS) := rfl + +lemma centeredStar_involutive : Function.Involutive (centeredStar τ hτ) := by + intro x + apply Subtype.ext + exact starMap_involutive τ hτ (x : τ.GNS) + +end Kadison.TracialGNS +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialCommutation.lean b/lean/OAI/Analysis/Commutator/TracialCommutation.lean new file mode 100644 index 0000000000000000000000000000000000000000..55c2abe5958e7c8319e7ea1ce653650d1fb1a33f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialCommutation.lean @@ -0,0 +1,148 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +open scoped ComplexOrder InnerProductSpace + +open Complex ContinuousLinearMap UniformSpace Completion + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + +noncomputable def starPre : τ.PreGNS →L⋆[ℂ] τ.PreGNS := + (τ.toPreGNS.toLinearMap.comp + ((starLinearEquiv ℂ : A ≃ₗ⋆[ℂ] A).toLinearMap.comp τ.ofPreGNS.toLinearMap)).mkContinuous + 1 (fun x => by + change ‖τ.toPreGNS (star (τ.ofPreGNS x))‖ ≤ 1 * ‖x‖ + rw [norm_star_preGNS τ hτ, PositiveLinearMap.toPreGNS_ofPreGNS, one_mul]) + +@[simp] lemma starPre_apply (x : τ.PreGNS) : + starPre τ hτ x = τ.toPreGNS (star (τ.ofPreGNS x)) := rfl + +noncomputable def starMap : τ.GNS →L⋆[ℂ] τ.GNS := (starPre τ hτ).completion + +@[simp] lemma starMap_algebra (a : A) : + starMap τ hτ (algebraVector τ a) = algebraVector τ (star a) := by + simp only [algebraVector_apply, starMap, ContinuousLinearMap.completion_apply_coe, + starPre_apply, PositiveLinearMap.ofPreGNS_toPreGNS] + +lemma starMap_norm (x : τ.GNS) : ‖starMap τ hτ x‖ = ‖x‖ := by + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih a => + change ‖starMap τ hτ (algebraVector τ (τ.ofPreGNS a))‖ = ‖(a : τ.GNS)‖ + rw [starMap_algebra] + simp only [algebraVector_apply, Completion.norm_coe, norm_star_preGNS τ hτ, + PositiveLinearMap.toPreGNS_ofPreGNS] + +lemma starMap_involutive : Function.Involutive (starMap τ hτ) := by + intro x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih a => + change starMap τ hτ (starMap τ hτ (algebraVector τ (τ.ofPreGNS a))) = _ + rw [starMap_algebra, starMap_algebra, star_star] + rfl + +lemma starMap_inner (x y : τ.GNS) : + inner ℂ (starMap τ hτ x) (starMap τ hτ y) = inner ℂ y x := by + induction x, y using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih a b => + change inner ℂ (starMap τ hτ (algebraVector τ (τ.ofPreGNS a))) + (starMap τ hτ (algebraVector τ (τ.ofPreGNS b))) = _ + rw [starMap_algebra, starMap_algebra, inner_algebraVector, star_star, hτ] + simp only [Completion.inner_coe, PositiveLinearMap.preGNS_inner_def] + +@[simp] lemma starMap_vacuum : starMap τ hτ (vacuum τ) = vacuum τ := by + change starMap τ hτ (algebraVector τ 1) = _ + rw [starMap_algebra, star_one] + rfl + +@[simp] lemma starMap_starMap (x : τ.GNS) : starMap τ hτ (starMap τ hτ x)=x := + starMap_involutive τ hτ x + +noncomputable def operatorConjugate (T : τ.GNS →L[ℂ] τ.GNS) : τ.GNS →L[ℂ] τ.GNS := + (starMap τ hτ).comp (T.comp (starMap τ hτ)) + +@[simp] lemma operatorConjugate_apply (T : τ.GNS →L[ℂ] τ.GNS) (x : τ.GNS) : + operatorConjugate τ hτ T x=starMap τ hτ (T (starMap τ hτ x)) := rfl + +lemma operatorConjugate_involutive : Function.Involutive (operatorConjugate τ hτ) := by + intro T + ext x + simp only [operatorConjugate_apply,starMap_starMap] + +lemma commutant_star {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.range τ.gnsStarAlgHom)) : + star T∈Set.centralizer (Set.range τ.gnsStarAlgHom) := by + rintro _ ⟨a,rfl⟩ + have h := congrArg star (hT _ ⟨star a,rfl⟩) + simpa only [star_mul,map_star,star_star] using h.symm + +lemma starMap_commutant_vacuum {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.range τ.gnsStarAlgHom)) : + starMap τ hτ (T (vacuum τ))=star T (vacuum τ) := by + apply (algebraVector_dense τ).eq_of_inner_right ℂ + intro a + have hc : τ.gnsStarAlgHom a (T (vacuum τ))=T (algebraVector τ a) := by + have he := congrArg (fun V : τ.GNS →L[ℂ] τ.GNS => V (vacuum τ)) (hT _ ⟨a,rfl⟩) + simpa only [mul_apply_eq_comp,left_vacuum,algebraVector_apply] using he + calc + _ = inner ℂ (T (vacuum τ)) (starMap τ hτ (algebraVector τ a)) := by + simpa only [starMap_starMap] using + (starMap_inner τ hτ (starMap τ hτ (algebraVector τ a)) (T (vacuum τ))) + _ = inner ℂ (T (vacuum τ)) (τ.gnsStarAlgHom (star a) (vacuum τ)) := by + rw [starMap_algebra,left_vacuum]; rfl + _ = inner ℂ (τ.gnsStarAlgHom a (T (vacuum τ))) (vacuum τ) := by + rw [map_star,ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + _ = inner ℂ (T (algebraVector τ a)) (vacuum τ) := by rw [hc] + _ = inner ℂ (algebraVector τ a) (star T (vacuum τ)) := by + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + +lemma operatorConjugate_commutant_orbit {T R : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.range τ.gnsStarAlgHom)) + (hR : R∈Set.centralizer (Set.range τ.gnsStarAlgHom)) : + operatorConjugate τ hτ T (R (vacuum τ))=R (star T (vacuum τ)) := by + rw [operatorConjugate_apply,starMap_commutant_vacuum τ hτ hR] + change starMap τ hτ ((T*star R) (vacuum τ))=_ + rw [starMap_commutant_vacuum τ hτ (Set.mul_mem_centralizer hT (commutant_star τ hR)),star_mul,star_star] + rfl + +lemma rightMul_mem_commutant (a : A) : + rightMul τ hτ a∈Set.centralizer (Set.range τ.gnsStarAlgHom) := by + rintro _ ⟨b,rfl⟩ + exact left_right_commute τ hτ b a + +theorem operatorConjugate_commutant_mem_bicommutant {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.range τ.gnsStarAlgHom)) : + operatorConjugate τ hτ T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom)) := by + intro R hR + apply ContinuousLinearMap.ext + have he : ∀ a : A, (R*operatorConjugate τ hτ T) (algebraVector τ a)= + (operatorConjugate τ hτ T*R) (algebraVector τ a) := by + intro a + rw [←show rightMul τ hτ a (vacuum τ)=algebraVector τ a from right_vacuum τ hτ a] + have ha := rightMul_mem_commutant τ hτ a + change R (operatorConjugate τ hτ T (rightMul τ hτ a (vacuum τ)))= + operatorConjugate τ hτ T ((R*rightMul τ hτ a) (vacuum τ)) + rw [operatorConjugate_commutant_orbit τ hτ hT ha, + operatorConjugate_commutant_orbit τ hτ hT (Set.mul_mem_centralizer hR ha)] + rfl + exact fun x => congrFun ((algebraVector_dense τ).equalizer + (R*operatorConjugate τ hτ T).continuous (operatorConjugate τ hτ T*R).continuous (funext he)) x + +end Kadison.TracialGNS + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialConjugation.lean b/lean/OAI/Analysis/Commutator/TracialConjugation.lean new file mode 100644 index 0000000000000000000000000000000000000000..0364802626ac0547f408ab3802004dba24032a25 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialConjugation.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialDevelopment + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion + +namespace Kadison.TracialGNS + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + +lemma rightMul_mem_unitary (u : unitary A) : + rightMul τ hτ (u : A) ∈ unitary (τ.GNS →L[ℂ] τ.GNS) := by + rw [Unitary.mem_iff] + constructor + · change (rightMul τ hτ (u : A)).adjoint * rightMul τ hτ (u : A) = 1 + rw [← rightMul_star, ← rightMul_mul, Unitary.mul_star_self_of_mem u.property, rightMul_one] + · change rightMul τ hτ (u : A) * (rightMul τ hτ (u : A)).adjoint = 1 + rw [← rightMul_star, ← rightMul_mul, Unitary.coe_star_mul_self, rightMul_one] + +noncomputable def conjugation (u : unitary A) : τ.GNS →ₗᵢ[ℂ] τ.GNS where + toLinearMap := ((τ.gnsStarAlgHom (u : A)).comp + (rightMul τ hτ (star u : A))).toLinearMap + norm_map' x := by + change ‖τ.gnsStarAlgHom (u : A) (rightMul τ hτ (star u : A) x)‖ = ‖x‖ + rw [ContinuousLinearMap.norm_map_of_mem_unitary (Unitary.map_mem _ u.property)] + exact ContinuousLinearMap.norm_map_of_mem_unitary + (rightMul_mem_unitary τ hτ (star u)) x + +@[simp] lemma conjugation_coe (u : unitary A) (a : A) : + conjugation τ hτ u (τ.toPreGNS a : τ.GNS) = + (τ.toPreGNS ((u : A) * a * (star u : A)) : τ.GNS) := by + change τ.gnsStarAlgHom (u : A) (rightMul τ hτ (star u : A) + (τ.toPreGNS a : τ.GNS)) = _ + rw [rightMul_coe, PositiveLinearMap.ofPreGNS_toPreGNS, left_coe, mul_assoc] + +@[simp] lemma conjugation_vacuum (u : unitary A) : + conjugation τ hτ u (vacuum τ) = vacuum τ := by + rw [vacuum, conjugation_coe, mul_one, Unitary.mul_star_self_of_mem u.property] + +noncomputable def algebraVector : A →ₗ[ℂ] τ.GNS := + (Completion.toComplL : τ.PreGNS →L[ℂ] τ.GNS).toLinearMap.comp τ.toPreGNS.toLinearMap + +@[simp] lemma algebraVector_apply (a : A) : algebraVector τ a = (τ.toPreGNS a : τ.GNS) := rfl + +lemma inner_algebraVector (a b : A) : + inner ℂ (algebraVector τ a) (algebraVector τ b) = τ (star a * b) := by + simp only [algebraVector_apply, Completion.inner_coe, PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS] + +lemma inner_vacuum_algebraVector (a : A) : + inner ℂ (vacuum τ) (algebraVector τ a) = τ a := by + change inner ℂ (algebraVector τ 1) (algebraVector τ a) = _ + rw [inner_algebraVector, star_one, one_mul] + +lemma algebraVector_dense : DenseRange (algebraVector τ) := by + have h := dense_cyclic_orbit τ + change DenseRange (fun a => (τ.toPreGNS a : τ.GNS)) + simpa only [left_vacuum] using h + +end Kadison.TracialGNS +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialConstantFreeObstruction.lean b/lean/OAI/Analysis/Commutator/TracialConstantFreeObstruction.lean new file mode 100644 index 0000000000000000000000000000000000000000..12e945b127852c0803dc4d47d5ac7cc9aa145d4b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialConstantFreeObstruction.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Commutator.FreePositionObstruction +import OAI.Analysis.Commutator.TracialGeneratedAlgebra + +namespace OAI + +noncomputable section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +open Filter + +namespace Kadison.VectorFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma functional_star (x : H) (T : H →L[ℂ] H) : functional x (star T)=star (functional x T) := + map_star (functional x) T + +end Kadison.VectorFunctional + +namespace Kadison.TracialSequence + +open FreeMoments + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (D : VonNeumannAlgebra (boundedSubspace τ ω)) + (hfaith : ∀ a : A,τ (star a*a)=0 → a=0) (h1 : τ 1=1) + +include hfaith h1 in +theorem constant_in_free_subalgebra_scalar + (hfree : Free (GeneratedFreePair.ambient D (constantAction τ ω)) + (VectorFunctional.functional (sequenceVacuum τ ω)).toLinearMap) + (a : A) (ha : constantAction τ ω a∈D) : a=τ a • (1:A) := by + apply mapped_intersection_scalar + (GeneratedFreePair.ambient D (constantAction τ ω)) τ.toLinearMap + (VectorFunctional.functional (sequenceVacuum τ ω)).toLinearMap + (constantAction τ ω) (trace_constant τ ω) + (VectorFunctional.functional_star (sequenceVacuum τ ω)) + hfaith h1 hfree (show (false:Bool)≠true by decide) a + · exact ha + · exact Set.mem_range_self a + +include hfaith h1 in +theorem not_free_of_nonscalar_constant + (a : A) (ha : constantAction τ ω a∈D) (hne : a≠τ a • (1:A)) : + ¬Free (GeneratedFreePair.ambient D (constantAction τ ω)) + (VectorFunctional.functional (sequenceVacuum τ ω)).toLinearMap := by + intro hfree + exact hne (constant_in_free_subalgebra_scalar τ ω D hfaith h1 hfree a ha) + +end Kadison.TracialSequence +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialDCorner.lean b/lean/OAI/Analysis/Commutator/TracialDCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd42605edf3d045aa88bdc085617bbddbd2f998b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialDCorner.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialGNSCorners +import OAI.Analysis.Commutator.VectorFreeGeneration + +namespace OAI + +open Lean in +run_cmd modifyEnv fun env => + Lean.LibrarySuggestions.nameDenyListExt.addEntry env "represented_D_corner_bound" + +noncomputable section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +open Filter + +namespace Kadison.TracialSequence + +lemma represented_D_corner_bound + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hone : τ 1=1) + (D : VonNeumannAlgebra (boundedSubspace τ ω)) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + (hDQ : ∀ d : D,(d:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + (R : Bool → StarSubalgebra ℂ M) + (T : τ.GNS →L[ℂ] τ.GNS) {b c β : ℝ} (hb : 0≤b) (hc : 0≤c) (hβ : β by + change ‖τ.toPreGNS (τ.ofPreGNS x * a)‖ ≤ ‖a‖ * ‖x‖ + calc + _ = ‖τ.toPreGNS (star (τ.ofPreGNS x * a))‖ := + (norm_star_preGNS τ hτ _).symm + _ = ‖τ.leftMulMapPreGNS (star a) (τ.toPreGNS (star (τ.ofPreGNS x)))‖ := by + simp only [star_mul, PositiveLinearMap.leftMulMapPreGNS_apply, + PositiveLinearMap.ofPreGNS_toPreGNS] + _ ≤ ‖star a‖ * ‖τ.toPreGNS (star (τ.ofPreGNS x))‖ := by + exact (ContinuousLinearMap.le_opNorm _ _).trans + (mul_le_mul_of_nonneg_right + (LinearMap.mkContinuous_norm_le _ (norm_nonneg _) _) (norm_nonneg _)) + _ = ‖a‖ * ‖x‖ := by + rw [norm_star, norm_star_preGNS τ hτ, PositiveLinearMap.toPreGNS_ofPreGNS]) + +@[simp] lemma rightMulPre_apply (a : A) (x : τ.PreGNS) : + rightMulPre τ hτ a x = τ.toPreGNS (τ.ofPreGNS x * a) := rfl + +lemma norm_rightMulPre_le (a : A) : ‖rightMulPre τ hτ a‖ ≤ ‖a‖ := by + exact LinearMap.mkContinuous_norm_le _ (norm_nonneg _) _ + +noncomputable def rightMul (a : A) : τ.GNS →L[ℂ] τ.GNS := + (rightMulPre τ hτ a).completion + +@[simp] lemma rightMul_coe (a : A) (x : τ.PreGNS) : + rightMul τ hτ a (x : τ.GNS) = (τ.toPreGNS (τ.ofPreGNS x * a) : τ.GNS) := by + simp [rightMul] + +lemma rightMul_mul (a b : A) : + rightMul τ hτ (a * b) = rightMul τ hτ b * rightMul τ hτ a := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [mul_apply_eq_comp, mul_assoc] + +lemma rightMul_one : rightMul τ hτ 1 = 1 := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp + +lemma left_right_commute (a b : A) : + τ.gnsStarAlgHom a * rightMul τ hτ b = rightMul τ hτ b * τ.gnsStarAlgHom a := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [mul_apply_eq_comp, PositiveLinearMap.gnsStarAlgHom, + PositiveLinearMap.gnsNonUnitalStarAlgHom_apply_coe, mul_assoc] + +lemma rightMul_star (a : A) : rightMul τ hτ (star a) = (rightMul τ hτ a).adjoint := by + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + induction x, y using Completion.induction_on₂ with + | hp => apply isClosed_eq <;> fun_prop + | ih x y => + simp only [rightMul_coe, Completion.inner_coe, PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS, star_mul, star_star] + rw [mul_assoc, hτ, mul_assoc] + +noncomputable def vacuum : τ.GNS := (τ.toPreGNS 1 : τ.GNS) + +lemma left_vacuum (a : A) : τ.gnsStarAlgHom a (vacuum τ) = (τ.toPreGNS a : τ.GNS) := by + simp [vacuum, PositiveLinearMap.gnsStarAlgHom] + +lemma right_vacuum (a : A) : rightMul τ hτ a (vacuum τ) = (τ.toPreGNS a : τ.GNS) := by + simp [vacuum] + +lemma vacuum_norm_sq : ‖vacuum τ‖ ^ 2 = (τ 1).re := by + simp only [vacuum, Completion.norm_coe, PositiveLinearMap.preGNS_norm_def, + PositiveLinearMap.ofPreGNS_toPreGNS, star_one, one_mul] + exact Real.sq_sqrt (τ.map_nonneg (show (0 : A) ≤ 1 from zero_le_one)).1 + +lemma vacuum_norm (h1 : τ 1 = 1) : ‖vacuum τ‖ = 1 := by + have h := vacuum_norm_sq τ + rw [h1] at h + have := norm_nonneg (vacuum τ) + change ‖vacuum τ‖ ^ 2 = 1 at h + nlinarith + +lemma dense_cyclic_orbit : DenseRange (fun a : A => τ.gnsStarAlgHom a (vacuum τ)) := by + have hd := Completion.denseRange_coe (α := τ.PreGNS) + have he : (fun a : A => τ.gnsStarAlgHom a (vacuum τ)) = + (fun x : τ.PreGNS => (x : τ.GNS)) ∘ τ.toPreGNS := by + funext a + exact left_vacuum τ a + rw [he] + exact hd.comp τ.toPreGNS.surjective.denseRange (Completion.continuous_coe _) + +noncomputable def rightStarAlgHom : Aᵐᵒᵖ →⋆ₐ[ℂ] (τ.GNS →L[ℂ] τ.GNS) where + toFun a := rightMul τ hτ a.unop + map_one' := rightMul_one τ hτ + map_zero' := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [Completion.coe_zero] + map_add' a b := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [mul_add, Completion.coe_add] + map_mul' a b := rightMul_mul τ hτ b.unop a.unop + commutes' c := by + ext x + induction x using Completion.induction_on with + | hp => apply isClosed_eq <;> fun_prop + | ih x => simp [Algebra.algebraMap_eq_smul_one, Completion.coe_smul] + map_star' a := rightMul_star τ hτ a.unop + +lemma rightMul_opNorm_le (a : A) : ‖rightMul τ hτ a‖ ≤ ‖a‖ := by + exact NonUnitalStarAlgHom.norm_apply_le (rightStarAlgHom τ hτ) (MulOpposite.op a) + +lemma coe_preGNS_eq_zero_iff + (hfaith : ∀ a : A, τ (star a * a) = 0 → a = 0) (a : A) : + (τ.toPreGNS a : τ.GNS) = 0 ↔ a = 0 := by + constructor + · intro h + apply hfaith a + have hn : ‖τ.toPreGNS a‖ = 0 := by + rw [← Completion.norm_coe, h, norm_zero] + have := τ.preGNS_norm_sq (τ.toPreGNS a) + simpa [hn] using this.symm + · rintro rfl + simp [Completion.coe_zero] + +lemma left_faithful (hfaith : ∀ a : A, τ (star a * a) = 0 → a = 0) : + Function.Injective τ.gnsStarAlgHom := by + apply (injective_iff_map_eq_zero _).mpr + intro a ha + apply (coe_preGNS_eq_zero_iff τ hfaith a).mp + rw [← left_vacuum τ a, ha, zero_apply] + +lemma right_faithful (hfaith : ∀ a : A, τ (star a * a) = 0 → a = 0) : + Function.Injective (rightStarAlgHom τ hτ) := by + apply (injective_iff_map_eq_zero _).mpr + intro a ha + apply MulOpposite.unop_injective + apply (coe_preGNS_eq_zero_iff τ hfaith a.unop).mp + rw [← right_vacuum τ hτ a.unop] + change (rightStarAlgHom τ hτ a) (vacuum τ) = 0 + rw [ha, zero_apply] + +lemma norm_left_eq (hfaith : ∀ a : A, τ (star a * a) = 0 → a = 0) (a : A) : + ‖τ.gnsStarAlgHom a‖ = ‖a‖ := + NonUnitalStarAlgHom.norm_map _ (left_faithful τ hfaith) a + +lemma norm_right_eq (hfaith : ∀ a : A, τ (star a * a) = 0 → a = 0) (a : A) : + ‖rightMul τ hτ a‖ = ‖a‖ := + NonUnitalStarAlgHom.norm_map _ (right_faithful τ hτ hfaith) (MulOpposite.op a) + +lemma coe_norm_sq (a : A) : ‖(τ.toPreGNS a : τ.GNS)‖ ^ 2 = (τ (star a * a)).re := by + rw [norm_sq_eq_re_inner (𝕜 := ℂ), Completion.inner_coe] + rfl + +lemma projection_norm_sq {p : A} (hp : IsStarProjection p) : + ‖(τ.toPreGNS p : τ.GNS)‖ ^ 2 = (τ p).re := by + rw [coe_norm_sq, hp.isSelfAdjoint.star_eq, hp.isIdempotentElem.eq] + +lemma norm_right_partial_isometry {v r : A} (hv : star v * v = r) + {ξ : τ.GNS} (hξ : rightMul τ hτ r ξ = ξ) : + ‖rightMul τ hτ (star v) ξ‖ = ‖ξ‖ := by + have hcomp : (rightMul τ hτ (star v)).adjoint.comp (rightMul τ hτ (star v)) = + rightMul τ hτ r := by + change (rightMul τ hτ (star v)).adjoint * rightMul τ hτ (star v) = _ + rw [← rightMul_star, star_star, ← rightMul_mul, hv] + have hs := ContinuousLinearMap.apply_norm_sq_eq_inner_adjoint_left + (rightMul τ hτ (star v)) ξ + rw [hcomp, hξ, ← norm_sq_eq_re_inner (𝕜 := ℂ)] at hs + exact (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp hs + +@[simp] lemma left_coe (a b : A) : + τ.gnsStarAlgHom a (τ.toPreGNS b : τ.GNS) = (τ.toPreGNS (a * b) : τ.GNS) := by + simp [PositiveLinearMap.gnsStarAlgHom] + +lemma mem_closure_corner_orbit {e r : A} (her : e * r = r) + {ξ : τ.GNS} (heξ : τ.gnsStarAlgHom e ξ = ξ) + (hrξ : rightMul τ hτ r ξ = ξ) : + ξ ∈ closure (Set.range (fun a : A => + τ.gnsStarAlgHom (e * a * e) (τ.toPreGNS r : τ.GNS))) := by + let F : τ.GNS →L[ℂ] τ.GNS := (τ.gnsStarAlgHom e).comp (rightMul τ hτ r) + have hF : F ξ = ξ := by + change τ.gnsStarAlgHom e (rightMul τ hτ r ξ) = ξ + rw [hrξ, heξ] + rw [← hF] + apply map_mem_closure F.continuous (dense_cyclic_orbit τ ξ) + rintro x ⟨a, rfl⟩ + refine ⟨a, ?_⟩ + change τ.gnsStarAlgHom (e * a * e) (τ.toPreGNS r : τ.GNS) = + τ.gnsStarAlgHom e (rightMul τ hτ r (τ.gnsStarAlgHom a (vacuum τ))) + simp only [left_vacuum, rightMul_coe, PositiveLinearMap.ofPreGNS_toPreGNS, + left_coe, mul_assoc, her] + +end TracialGNS + +end Kadison +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialDoubleCompression.lean b/lean/OAI/Analysis/Commutator/TracialDoubleCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..f4cdce79f6e39233207f3b6aba695dc322872399 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialDoubleCompression.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeBaseCompression +import OAI.Analysis.Commutator.TracialVectorSubalgebra + +namespace OAI + +open Lean in +run_cmd modifyEnv fun env => + let env := Lean.LibrarySuggestions.nameDenyListExt.addEntry env "double_embedding" + Lean.LibrarySuggestions.nameDenyListExt.addEntry env "double_compression_preserves" + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder BoundedContinuousFunction + +open Filter UniformSpace ContinuousLinearMap + +namespace Kadison.TracialSequence + +open TracialGNS FreeWordTensor FreeBlocks + +def constantSequence {A : Type} [CStarAlgebra A] : A →⋆ₐ[ℂ] (ℕ →ᵇ A) where + toFun := BoundedContinuousFunction.const ℕ + map_one' := by ext i; rfl + map_mul' a b := by ext i; rfl + map_zero' := by ext i; rfl + map_add' a b := by ext i; rfl + commutes' z := by ext i; rfl + map_star' a := by ext i; rfl + +@[simp] lemma constantSequence_apply {A : Type} [CStarAlgebra A] (a : A) : + constantSequence a=BoundedContinuousFunction.const ℕ a := rfl + +lemma trace_constant {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (a : A) : + sequenceTrace τ ω (leftRestricted τ ω (constantSequence a))=τ a := by + exact (tendsto_nhds_unique (tendsto_trace τ ω (constantSequence a)) tendsto_const_nhds) + +def constantHom {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) : A →⋆ₐ[ℂ] M := + ((leftRestricted τ ω).comp constantSequence).codRestrict M.toStarSubalgebra hconst + +@[simp] lemma constantHom_coe {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) (a : A) : + (constantHom τ ω M hconst a : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)= + leftRestricted τ ω (constantSequence a) := rfl + +lemma constant_trace {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) (a : A) : + τ a=VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) (constantHom τ ω M hconst a) := + (trace_constant τ ω a).symm + +private abbrev doubleCompressionPreGNS {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] (functional : A →ₚ[ℂ] ℂ) : + SeminormedAddCommGroup functional.PreGNS := + InnerProductSpace.Core.toSeminormedAddCommGroup (c := functional.preGNSpreInnerProdSpace) + +lemma double_embedding {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hone : τ 1=1) (x : τ.GNS) : + VectorGNS.embedding (subalgebraState τ ω hτ M hM hone).functional + M.toStarSubalgebra.subtype (sequenceVacuum τ ω) + (VectorGNS.subalgebraTrace_subtype M (sequenceVacuum τ ω)) + (originalEmbedding τ (subalgebraState τ ω hτ M hM hone) + (constantHom τ ω M hconst) (constant_trace τ ω M hconst) x)=constantIn τ ω x := by + let : SeminormedAddCommGroup (subalgebraState τ ω hτ M hM hone).functional.PreGNS := + doubleCompressionPreGNS (subalgebraState τ ω hτ M hM hone).functional + refine (algebraVector_dense τ).induction_on x (isClosed_eq + ((VectorGNS.embedding (subalgebraState τ ω hτ M hM hone).functional + M.toStarSubalgebra.subtype (sequenceVacuum τ ω) + (VectorGNS.subalgebraTrace_subtype M (sequenceVacuum τ ω))).continuous.comp + (originalEmbedding τ (subalgebraState τ ω hτ M hM hone) + (constantHom τ ω M hconst) (constant_trace τ ω M hconst)).continuous) + (constantIn τ ω).continuous) ?_ + intro a + have ha := originalEmbedding_coe τ (subalgebraState τ ω hτ M hM hone) + (constantHom τ ω M hconst) (constant_trace τ ω M hconst) a + refine (congrArg (VectorGNS.embedding (subalgebraState τ ω hτ M hM hone).functional + M.toStarSubalgebra.subtype (sequenceVacuum τ ω) + (VectorGNS.subalgebraTrace_subtype M (sequenceVacuum τ ω))) ha).trans ?_ + exact (VectorGNS.embedding_coe (subalgebraState τ ω hτ M hM hone).functional + M.toStarSubalgebra.subtype (sequenceVacuum τ ω) + (VectorGNS.subalgebraTrace_subtype M (sequenceVacuum τ ω)) + (constantHom τ ω M hconst a)).trans (by + change leftRestricted τ ω (constantSequence a) (sequenceVacuum τ ω)=_ + rw [leftRestricted_vacuum] + apply Subtype.ext + exact vector_const τ ω a) + +lemma double_compression_preserves {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hone : τ 1=1) (T : τ.GNS →L[ℂ] τ.GNS) (x : τ.GNS) : + VectorGNS.compression (subalgebraState τ ω hτ M hM hone).functional + M.toStarSubalgebra.subtype (sequenceVacuum τ ω) (VectorGNS.subalgebraTrace_subtype M (sequenceVacuum τ ω)) (compressed τ ω T) + (originalEmbedding τ (subalgebraState τ ω hτ M hM hone) + (constantHom τ ω M hconst) (constant_trace τ ω M hconst) x)= + originalEmbedding τ (subalgebraState τ ω hτ M hM hone) + (constantHom τ ω M hconst) (constant_trace τ ω M hconst) (T x) := by + apply VectorGNS.compression_on_preserved + calc + _ = compressed τ ω T (constantIn τ ω x) := congrArg (compressed τ ω T) + (double_embedding τ ω M hconst hτ hM hone x) + _ = constantIn τ ω (T x) := compressed_constant τ ω T x + _ = _ := (double_embedding τ ω M hconst hτ hM hone (T x)).symm + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialFreeOriginal.lean b/lean/OAI/Analysis/Commutator/TracialFreeOriginal.lean new file mode 100644 index 0000000000000000000000000000000000000000..3da6699d949ab5c8de87339500c7904a58c184cc --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialFreeOriginal.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialDoubleCompression +import OAI.Analysis.Commutator.TracialRangeCommutation +import OAI.Analysis.Commutator.TracialRepresentedCorner +import OAI.Analysis.Commutator.VectorFreeOriginalBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.TracialSequence + +open FreeWordTensor FreeWordAction FreeMoments FreeBlocks + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + +variable (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hone : τ 1=1) + (hconst : ∀ a : A,leftRestricted τ ω (constantSequence a)∈M) + +variable (D : VonNeumannAlgebra (boundedSubspace τ ω)) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + +variable (R : Bool → StarSubalgebra ℂ M) + (hR : R false=(VectorGNS.inclusion M D hDM).range) + (hP : ∀ a : A,constantHom τ ω M hconst a∈R true) + (hfree : Free R (subalgebraState τ ω hτ M hM hone).functional.toLinearMap) + (hgen : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.centralizer (Set.centralizer (((iSup R).map M.toStarSubalgebra.subtype) : Set _))) + +variable (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] [∀ n,Nonempty (I n)] + (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ},n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a,φ m (inc h a)=φ n a) + (hsize : ∀ n q : ℕ,∃ m,n ≤ m ∧ q ≤ Fintype.card (I m)) + +variable (hDgen : VectorGNS.GeneratedByStages D (sequenceVacuum τ ω) I φ) + +variable {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + (hDQ : ∀ d : D,(d:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + +include hτ hω hM hone hconst hR hP hfree hgen hinc hsize hDgen hDQ in +theorem free_position_small_corners_bound + (hdiffuse : DiffuseProjection.HasNoMinimalProjections D) + (T : τ.GNS →L[ℂ] τ.GNS) + (hTQ : ∀ q : Q,T*τ.gnsStarAlgHom (j q)=τ.gnsStarAlgHom (j q)*T) + {b c β : ℝ} (hb : 0≤b) (hc : 0≤c) (hβ : 0<β) (hβ1 : β≤1) (hβb : β compressed_commutes_of_range τ ω Q j T hTQ d (hDQ d)) + s hs0 hs2 hc hβ hβ1 + ?_ + · with_reducible exact double_compression_preserves τ ω M hconst hτ hM hone T + · exact represented_corner_bound τ ω hτ hω M hM D Q j hDQ T hb hc hβb hTC + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialFreePositionCriterion.lean b/lean/OAI/Analysis/Commutator/TracialFreePositionCriterion.lean new file mode 100644 index 0000000000000000000000000000000000000000..890a83548e639ba27e2d73f25197a9851df0b622 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialFreePositionCriterion.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialGeneratedFreeBound + +namespace OAI + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +open Filter + +namespace Kadison.TracialSequence + +open FreeMoments + +variable {A K : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +structure FreeCornerPositionData {H : Type} [NormedAddCommGroup H] + [InnerProductSpace ℂ H] [CompleteSpace H] (ξ : H) + (action : A →⋆ₐ[ℂ] (H →L[ℂ] H)) (operatorRange : Set (H →L[ℂ] H)) where + algebra : VonNeumannAlgebra H + size : ℕ → ℕ + stage : ∀ n,Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] algebra + inclusion : ∀ {n m : ℕ}, n ≤ m → + Matrix (Fin (size n+1)) (Fin (size n+1)) ℂ →⋆ₐ[ℂ] + Matrix (Fin (size m+1)) (Fin (size m+1)) ℂ + compatible : ∀ n m (h : n ≤ m) a,stage m (inclusion h a)=stage n a + unbounded : ∀ n q : ℕ,∃ m, n ≤ m ∧ q ≤ size m+1 + generated : VectorGNS.GeneratedByStages algebra ξ + (fun n => Fin (size n+1)) stage + free : Free (GeneratedFreePair.ambient algebra action) + (VectorFunctional.functional ξ).toLinearMap + in_range : ∀ d : algebra,(d:H →L[ℂ] H)∈operatorRange + diffuse : DiffuseProjection.HasNoMinimalProjections algebra + +abbrev FreeCornerPosition (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) := + FreeCornerPositionData (sequenceVacuum τ ω) (constantAction τ ω) + (Set.range ((leftRestricted τ ω).comp (mapSequence j))) + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + +theorem FreeCornerPosition.symmetry_bound (F : FreeCornerPosition τ ω Q j) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ) ≤ atTop) (hone : τ 1=1) + (T : τ.GNS →L[ℂ] τ.GNS) + (hTQ : ∀ q : Q,T*τ.gnsStarAlgHom (j q)=τ.gnsStarAlgHom (j q)*T) + {b c β : ℝ} (hb : 0 ≤ b) (hc : 0 ≤ c) (hβ : 0<β) (hβ1 : β ≤ 1) (hβb : β Fin (F.size n+1)) F.stage F.inclusion F.compatible + _ F.generated F.free Q j F.in_range F.diffuse T hTQ hb hc hβ hβ1 hβb hTC s hs0 hs2 + intro n q + simpa only [Fintype.card_fin] using F.unbounded n q + +end Kadison.TracialSequence + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialGNSCorners.lean b/lean/OAI/Analysis/Commutator/TracialGNSCorners.lean new file mode 100644 index 0000000000000000000000000000000000000000..96add475ac17500e89098e8a9487ea2cd802d0ed --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialGNSCorners.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSymmetrization +import OAI.Analysis.Commutator.GNSCornerTransport +import OAI.Analysis.Commutator.TracialSmallCorners + +namespace OAI + +open Lean in +run_cmd modifyEnv fun env => + let env := Lean.LibrarySuggestions.nameDenyListExt.addEntry env "subtype_corner" + let env := Lean.LibrarySuggestions.nameDenyListExt.addEntry env "gnsCompression_commutes" + let env := Lean.LibrarySuggestions.nameDenyListExt.addEntry env "small_represented_corner_bound" + Lean.LibrarySuggestions.nameDenyListExt.addEntry env "gns_small_corner_bound" + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder BoundedContinuousFunction + +open Filter ContinuousLinearMap + +namespace Kadison.VectorGNS + +lemma subtype_corner + {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (M : VonNeumannAlgebra H) (q a : M) (hl : q*a=a) (hr : a*q=a) : + (q:H →L[ℂ] H)*a*q=a := by + have hh : q*a*q=a := by rw [hl,hr] + exact congrArg M.toStarSubalgebra.subtype hh + +def CornerCommutatorBound + {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (M : VonNeumannAlgebra H) (ξ : H) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + {D : Type} [CStarAlgebra D] (f : D →⋆ₐ[ℂ] M) + (R : Bool → StarSubalgebra ℂ M) (T : H →L[ℂ] H) (c : ℝ) (β : ℂ) : Prop := + ∀ X,CornerSymmetrization.CornerElement + (FreeBlocks.factorOperators (vectorState M ξ hfaith hone) f) + (FreeBlocks.ambientOperators (vectorState M ξ hfaith hone) R) + (TracialGNS.vacuum (subalgebraTrace M ξ)) β X → + ‖subalgebraCompression M ξ T*X-X*subalgebraCompression M ξ T‖≤c*‖X‖ + +end Kadison.VectorGNS + +namespace Kadison.TracialSequence + +open FreeWordTensor FreeBlocks + +abbrev gnsCompression + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (T : τ.GNS →L[ℂ] τ.GNS) := + VectorGNS.subalgebraCompression M (sequenceVacuum τ ω) (compressed τ ω T) + +private lemma represented_commutes + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + {D : Type} [CStarAlgebra D] (f : D →⋆ₐ[ℂ] M) + (hfQ : ∀ q : D, (f q : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + (operator : τ.GNS →L[ℂ] τ.GNS) + (hoperator : ∀ entry : Q, + operator*τ.gnsStarAlgHom (j entry)=τ.gnsStarAlgHom (j entry)*operator) + (element : D) : + compressed τ ω operator*(f element:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)= + (f element:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)*compressed τ ω operator := + (Set.forall_mem_range + (f := ((leftRestricted τ ω).comp (mapSequence j))) + (p := fun represented => + compressed τ ω operator*represented=represented*compressed τ ω operator)).mpr + (fun sequence => commutator_zero τ ω operator (mapSequence j sequence) + (fun index => hoperator (sequence index))) + (f element:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) (hfQ element) + +lemma gnsCompression_commutes + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + {D : Type} [CStarAlgebra D] (f : D →⋆ₐ[ℂ] M) + (hfQ : ∀ q : D, (f q : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + (T : τ.GNS →L[ℂ] τ.GNS) + (hT : ∀ q : Q,T*τ.gnsStarAlgHom (j q)=τ.gnsStarAlgHom (j q)*T) (q : D) : + gnsCompression τ ω M T*(VectorGNS.subalgebraTrace M (sequenceVacuum τ ω)).gnsStarAlgHom (f q)= + (VectorGNS.subalgebraTrace M (sequenceVacuum τ ω)).gnsStarAlgHom (f q)*gnsCompression τ ω M T := + VectorGNS.commutes M (sequenceVacuum τ ω) (compressed τ ω T) (f q) + (represented_commutes τ ω M Q j f hfQ T hT q) + +lemma small_represented_corner_bound + {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hτ : ∀ a b : A, τ (a * b) = τ (b * a)) + (hω : (ω : Filter ℕ) ≤ atTop) + (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hM : ∀ a : M, (a : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + {D : Type} [CStarAlgebra D] (f : D →⋆ₐ[ℂ] M) + (hfQ : ∀ q : D, (f q : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + (T : τ.GNS →L[ℂ] τ.GNS) {b c β : ℝ} (hb : 0≤b) (hc : 0≤c) (hβ : β simp [norm] + | succ n ih => + have hbn : ‖b^n‖ ≤ 1 := by + cases n with + | zero => simpa only [pow_zero] using (IsStarProjection.one A).norm_le 1 + | succ n => + exact (norm_pow_le' b (Nat.succ_pos n)).trans + (pow_le_one₀ (_root_.norm_nonneg _) hb) + calc + _=norm τ (a^n*a-b^n*b) := by rw [pow_succ,pow_succ] + _ ≤ norm τ (a^n-b^n)*‖a‖+‖b^n‖*norm τ (a-b) := norm_mul_sub_mul τ hτ _ _ _ _ + _ ≤ (n:ℝ)*norm τ (a-b)+norm τ (a-b) := by + exact add_le_add + ((mul_le_mul_of_nonneg_left ha (norm_nonneg τ _)).trans (by simpa using ih)) + (mul_le_of_le_one_left (norm_nonneg τ _) hbn) + _=_ := by rw [Nat.cast_succ]; ring + +lemma tendsto_of_norm_sub_le {ι : Type*} {l : Filter ι} (f : ι → A) (a : A) + (b : ι → ℝ) (hb : Tendsto b l (𝓝 0)) (h : ∀ i,norm τ (f i-a) ≤ b i) : + Tendsto (fun i => norm τ (f i-a)) l (𝓝 0) := + squeeze_zero (fun index => norm_nonneg τ (f index-a)) h hb + +include hτ in +lemma tendsto_mul {ι : Type*} {l : Filter ι} {a b : ι → A} {x y : A} + (ha : Tendsto (fun i => norm τ (a i-x)) l (𝓝 0)) + (hb : Tendsto (fun i => norm τ (b i-y)) l (𝓝 0)) + {B : ℝ} (hB : ∀ i,‖b i‖ ≤ B) : + Tendsto (fun i => norm τ (a i*b i-x*y)) l (𝓝 0) := by + have hh := (ha.mul_const B).add (hb.const_mul ‖x‖) + simp only [zero_mul,mul_zero,add_zero] at hh + exact squeeze_zero (fun i => norm_nonneg τ _) (fun i => + (norm_mul_sub_mul τ hτ _ _ _ _).trans + (add_le_add (mul_le_mul_of_nonneg_left (hB i) (norm_nonneg τ _)) le_rfl)) hh + +include hτ in +lemma tendsto_trace {ι : Type*} {l : Filter ι} {a : ι → A} {x : A} + (hone : τ 1=1) (ha : Tendsto (fun i => norm τ (a i-x)) l (𝓝 0)) : + Tendsto (fun i => τ (a i)) l (𝓝 (τ x)) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + exact squeeze_zero (fun i => _root_.norm_nonneg _) (fun i => by + simpa only [map_sub] using norm_trace_le τ hτ hone (a i-x)) ha + +end Kadison.TracialL2 + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialL2Tools.lean b/lean/OAI/Analysis/Commutator/TracialL2Tools.lean new file mode 100644 index 0000000000000000000000000000000000000000..6cf481a73844b233b556d380a8fd2d7cf7ab8aca --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialL2Tools.lean @@ -0,0 +1,126 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.TracialL2 + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) + +def norm (a : A) : ℝ := ‖τ.toPreGNS a‖ + +lemma norm_nonneg (a : A) : 0≤norm τ a := _root_.norm_nonneg _ + +lemma norm_sq (a : A) : norm τ a^2=(τ (star a*a)).re := by + rw [norm,InnerProductSpace.norm_sq_eq_re_inner (𝕜:=ℂ)] + rfl + +@[simp] lemma norm_zero : norm τ 0=0 := by simp [norm] + +lemma norm_add (a b : A) : norm τ (a+b)≤norm τ a+norm τ b := by + simpa only [norm,map_add] using norm_add_le (τ.toPreGNS a) (τ.toPreGNS b) + +lemma norm_sub (a b : A) : norm τ (a-b)≤norm τ a+norm τ b := by + simpa only [norm,map_sub] using norm_sub_le (τ.toPreGNS a) (τ.toPreGNS b) + +lemma norm_smul (c : ℂ) (a : A) : norm τ (c • a)=‖c‖*norm τ a := by + simp only [norm,map_smul,_root_.norm_smul] + +lemma norm_real_smul (c : ℝ) (a : A) : norm τ (c • a)=|c| *norm τ a := by + rw [RCLike.real_smul_eq_coe_smul (K:=ℂ),norm_smul] + congr 1 + exact RCLike.norm_ofReal _ + +lemma norm_mul_left (a b : A) : norm τ (a*b)≤‖a‖*norm τ b := by + change ‖τ.leftMulMapPreGNS a (τ.toPreGNS b)‖≤‖a‖*‖τ.toPreGNS b‖ + exact (ContinuousLinearMap.le_opNorm _ _).trans + (mul_le_mul_of_nonneg_right + (LinearMap.mkContinuous_norm_le _ (_root_.norm_nonneg _) _) (_root_.norm_nonneg _)) + +variable (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +include hτ in +lemma norm_star (a : A) : norm τ (star a)=norm τ a := by + apply (sq_eq_sq₀ (norm_nonneg τ _) (norm_nonneg τ _)).mp + rw [norm_sq,norm_sq,star_star,hτ] + +include hτ in +lemma norm_mul_right (a b : A) : norm τ (a*b)≤norm τ a*‖b‖ := by + calc + _=norm τ (star b*star a) := by rw [←star_mul,norm_star τ hτ] + _≤‖star b‖*norm τ (star a) := norm_mul_left τ _ _ + _=_ := by rw [_root_.norm_star,norm_star τ hτ,mul_comm] + +include hτ in +lemma norm_trace_mul (a b : A) : ‖τ (a*b)‖≤norm τ a*norm τ b := by + have h := norm_inner_le_norm (𝕜:=ℂ) (τ.toPreGNS (star a)) (τ.toPreGNS b) + change ‖τ (star (star a)*b)‖≤norm τ (star a)*norm τ b at h + simpa only [star_star,norm_star τ hτ] using h + +lemma norm_projection_sq {p : A} (hp : IsStarProjection p) : norm τ p^2=(τ p).re := by + rw [norm_sq,hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + +lemma norm_mono_square {a b : A} (hab : star a*a ≤ star b*b) : norm τ a≤norm τ b := by + apply (sq_le_sq₀ (norm_nonneg τ _) (norm_nonneg τ _)).mp + rw [norm_sq,norm_sq] + exact (τ.monotone hab).1 + +lemma norm_le_opnorm (hone : τ 1=1) (a : A) : norm τ a≤‖a‖ := by + have h1 : norm τ (1:A)=1 := by + have h := norm_sq τ (1:A) + simp only [star_one,mul_one,hone,Complex.one_re] at h + nlinarith [norm_nonneg τ (1:A)] + simpa only [mul_one,h1] using norm_mul_left τ a 1 + +include hτ in +lemma trace_two_corner_letters {q a b c w z : A} (_hq : IsStarProjection q) + (hw : w*q=w) (hz : q*z=z) + (ha : ‖a‖≤1) (hc : ‖c‖≤1) (hwn : ‖w‖≤1) (hzn : ‖z‖≤1) : + ‖τ (a*w*b*z*c)‖≤norm τ (q*b*q)*norm τ q := by + have he : τ (a*w*b*z*c)=τ ((q*b*q)*(z*c*a*w)) := by + calc + _=τ ((a*w)*(b*(z*c))) := by simp only [mul_assoc] + _=τ ((b*(z*c))*(a*w)) := hτ _ _ + _=τ (b*(z*c*a*w)) := by simp only [mul_assoc] + _=τ (q*(b*(z*c*a*w))) := by + rw [hτ q] + congr 1 + rw [mul_assoc b, mul_assoc (z*c*a) w q,hw] + _=_ := by + congr 1 + have hqR : q*(z*c*a*w)=z*c*a*w := by + rw [←mul_assoc,←mul_assoc,←mul_assoc,hz] + rw [mul_assoc (q*b) q,hqR,mul_assoc q b] + have hnorm : norm τ (z*c*a*w)≤norm τ q := by + have hzq : z=q*z := hz.symm + calc + _≤norm τ (z*c*a)*‖w‖ := norm_mul_right τ hτ _ _ + _≤norm τ (z*c*a) := mul_le_of_le_one_right (norm_nonneg τ _) hwn + _≤norm τ (z*c)*‖a‖ := norm_mul_right τ hτ _ _ + _≤norm τ (z*c) := mul_le_of_le_one_right (norm_nonneg τ _) ha + _≤norm τ z*‖c‖ := norm_mul_right τ hτ _ _ + _≤norm τ z := mul_le_of_le_one_right (norm_nonneg τ _) hc + _=norm τ (q*z) := congrArg (norm τ) hzq + _≤norm τ q*‖z‖ := norm_mul_right τ hτ _ _ + _≤norm τ q := mul_le_of_le_one_right (norm_nonneg τ _) hzn + rw [he] + exact (norm_trace_mul τ hτ _ _).trans + (mul_le_mul_of_nonneg_left hnorm (norm_nonneg τ _)) + +end Kadison.TracialL2 + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialRangeCommutation.lean b/lean/OAI/Analysis/Commutator/TracialRangeCommutation.lean new file mode 100644 index 0000000000000000000000000000000000000000..98fab82d90bac32bd4ec503a620a234c27b4f5c3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialRangeCommutation.lean @@ -0,0 +1,40 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialSmallCorners + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder + +namespace Kadison.TracialSequence + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + +lemma compressed_commutes_of_range (T : τ.GNS →L[ℂ] τ.GNS) + (hT : ∀ q : Q,T*τ.gnsStarAlgHom (j q)=τ.gnsStarAlgHom (j q)*T) + (d : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + (hd : d∈Set.range ((leftRestricted τ ω).comp (mapSequence j))) : + compressed τ ω T*d=d*compressed τ ω T := by + obtain ⟨a,rfl⟩ := hd + exact commutator_zero τ ω T (mapSequence j a) (fun i => hT (a i)) + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialRelativeCommutant.lean b/lean/OAI/Analysis/Commutator/TracialRelativeCommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..c0dae6523cb348f0b17d5026772ce12a46b925ff --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialRelativeCommutant.lean @@ -0,0 +1,184 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialSmallCorners +import OAI.Analysis.Commutator.NormalRelativeCommutant + +namespace OAI + +noncomputable section + +open scoped InnerProductSpace ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open TracialGNS NormalGNS NormalRelativeCommutant + +variable {H D : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [CStarAlgebra D] + +variable (M : VonNeumannAlgebra H) (τ : M →ₚ[ℂ] ℂ) + (hτ : ∀ a b : M, τ (a*b)=τ (b*a)) (π : D →⋆ₐ[ℂ] M) (ω : Ultrafilter ℕ) + +def unitarySequence (u : ℕ → unitary D) : ℕ →ᵇ D := + BoundedContinuousFunction.ofNormedAddCommGroupDiscrete (fun i => (u i:D)) 1 + (fun i => by + cases subsingleton_or_nontrivial D with + | inl hs => exact le_trans (le_of_eq (by rw [Subsingleton.elim (u i:D) 0,norm_zero])) zero_le_one + | inr hn => exact (CStarRing.norm_coe_unitary (u i)).le) + +@[simp] lemma unitarySequence_apply (u : ℕ → unitary D) (i : ℕ) : + unitarySequence u i=(u i:D) := rfl + +lemma unitarySequence_star_mul (u : ℕ → unitary D) : + star (unitarySequence u)*unitarySequence u=1 := by + ext i + exact (u i).property.1 + +lemma unitarySequence_mul_star (u : ℕ → unitary D) : + unitarySequence u*star (unitarySequence u)=1 := by + ext i + exact (u i).property.2 + +lemma conjugate_difference_map_zero {A B : Type*} [Ring A] [Ring B] + [StarRing A] (f : A →+* B) (a b : A) (hb : b*star b=1) + (hc : f b*f a=f a*f b) : f (b*a*star b-a)=0 := by + rw [map_sub,map_mul,map_mul,hc,mul_assoc,←map_mul,hb,map_one,mul_one,sub_self] + +lemma algHom_eq_smul_one_of_sub {A B : Type*} [Ring A] [Ring B] [Algebra ℂ A] [Algebra ℂ B] + (f : A →ₐ[ℂ] B) (a : A) (c : ℂ) (h : f (a-c • 1)=0) : f a=c • 1 := by + simpa only [map_sub,map_smul,map_one,sub_eq_zero] using h + +private lemma norm_map_sub_smul_le {A E : Type*} [AddCommGroup A] [Module ℂ A] + [SeminormedAddCommGroup E] [NormedSpace ℂ E] (f : A →ₗ[ℂ] E) + (x u : A) (c d : ℂ) : + ‖f (x - c • u)‖ ≤ ‖f (x - d • u)‖ + ‖d - c‖ * ‖f u‖ := by + have h : f (x - c • u) = f (x - d • u) + (d - c) • f u := by + simp only [map_sub, map_smul, sub_smul] + abel + calc + _ = ‖f (x - d • u) + (d - c) • f u‖ := congrArg norm h + _ ≤ ‖f (x - d • u)‖ + ‖(d - c) • f u‖ := norm_add_le _ _ + _ = _ := congrArg (‖f (x - d • u)‖ + ·) (norm_smul _ _) + +include hτ in +theorem commutant_contraction_sequence + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (a : ℕ →ᵇ M) (ha : ‖a‖≤1) + (hcomm : ∀ b : ℕ →ᵇ D, + leftRestricted τ ω (mapSequence π b)*leftRestricted τ ω a= + leftRestricted τ ω a*leftRestricted τ ω (mapSequence π b)) : + leftRestricted τ ω a=(sequenceTrace τ ω (leftRestricted τ ω a)) • 1 := by + have hw (i : ℕ) := exists_unitary_witness M τ hτ π hnormal hfaith hone hirr + (a i) ((a.norm_coe_le_norm i).trans ha) + choose u hu using hw + let b := mapSequence π (unitarySequence u) + have hb : b*star b=1 := by + change mapSequence π (unitarySequence u)*star (mapSequence π (unitarySequence u))=1 + rw [←map_star,←map_mul,unitarySequence_mul_star,map_one] + have hc : leftRestricted τ ω (b*a*star b-a)=0 := + conjugate_difference_map_zero (leftRestricted τ ω).toAlgHom.toRingHom a b hb (hcomm _) + have hlim := (vector_eq_zero_iff τ ω _).mp + ((leftRestricted_eq_zero_iff τ ω hτ _).mp hc) + have hcenter : Tendsto (fun i => ‖algebraVector τ (a i-algebraMap ℂ M (τ (a i)))‖) + (ω : Filter ℕ) (𝓝 0) := by + apply squeeze_zero (fun i => norm_nonneg _) (fun i => hu i) + simpa only [b,BoundedContinuousFunction.sub_apply,BoundedContinuousFunction.mul_apply, + BoundedContinuousFunction.star_apply,mapSequence_apply,unitarySequence_apply,mul_zero] + using tendsto_const_nhds.mul hlim + let c := sequenceTrace τ ω (leftRestricted τ ω a) + have htrace : Tendsto (fun i => ‖τ (a i)-c‖*‖vacuum τ‖) + (ω : Filter ℕ) (𝓝 0) := by + have hh := ((tendsto_trace τ ω a).sub (tendsto_const_nhds (x:=c))).norm.mul_const ‖vacuum τ‖ + simpa only [c,sub_self,norm_zero,zero_mul] using hh + have hnorm (i : ℕ) : + ‖algebraVector τ (a i-c • (1:M))‖≤ + ‖algebraVector τ (a i-algebraMap ℂ M (τ (a i)))‖+ + ‖τ (a i)-c‖*‖vacuum τ‖ := by + have hv : algebraVector τ (1 : M) = vacuum τ := rfl + simpa only [Algebra.algebraMap_eq_smul_one, hv] using + norm_map_sub_smul_le (algebraVector τ) (a i) (1 : M) c (τ (a i)) + have hlim0 : Tendsto (fun i => ‖algebraVector τ (a i-c • (1:M))‖) + (ω : Filter ℕ) (𝓝 0) := by + exact squeeze_zero (fun i => norm_nonneg (algebraVector τ (a i-c • (1:M)))) + hnorm (by simpa only [zero_add] using hcenter.add htrace) + have hlim' : Tendsto (fun i => ‖algebraVector τ ((a-c • 1) i)‖) + (ω : Filter ℕ) (𝓝 0) := by + simpa only [BoundedContinuousFunction.sub_apply,BoundedContinuousFunction.smul_apply, + BoundedContinuousFunction.coe_one,Pi.one_apply] using hlim0 + have hz : leftRestricted τ ω (a-c • 1)=0 := + (leftRestricted_eq_zero_iff τ ω hτ _).mpr ((vector_eq_zero_iff τ ω _).mpr hlim') + exact algHom_eq_smul_one_of_sub (leftRestricted τ ω).toAlgHom a c hz + +lemma algHom_commutes_smul {A B : Type*} [Ring A] [Ring B] [Algebra ℂ A] [Algebra ℂ B] + (f : A →ₐ[ℂ] B) (a b : A) (c : ℂ) (h : f b*f a=f a*f b) : + f b*f (c • a)=f (c • a)*f b := by + simp only [map_smul,mul_smul_comm,smul_mul_assoc,h] + +lemma algHom_scalar_of_smul {A B : Type*} [Ring A] [Ring B] [Algebra ℂ A] [Algebra ℂ B] + (f : A →ₐ[ℂ] B) (a : A) {r : ℂ} (hr : r≠0) (c : ℂ) + (h : f (r • a)=c • 1) : ∃ d : ℂ, f a=d • 1 := by + refine ⟨r⁻¹*c,?_⟩ + have hh := congrArg (fun t : B => r⁻¹ • t) h + simpa only [map_smul,smul_smul,inv_mul_cancel₀ hr,one_smul] using hh + +lemma scalar_of_contractions {A B ι : Type*} [NormedRing A] [NormedAlgebra ℂ A] + [Ring B] [Algebra ℂ B] (f : A →ₐ[ℂ] B) (g : ι → B) + (h : ∀ a : A, ‖a‖≤1 → (∀ i, g i*f a=f a*g i) → ∃ c : ℂ, f a=c • 1) + (a : A) (ha : ∀ i, g i*f a=f a*g i) : ∃ c : ℂ, f a=c • 1 := by + by_cases hz : a=0 + · exact ⟨0,by rw [hz,map_zero,zero_smul]⟩ + let r : ℂ := (‖a‖:ℂ)⁻¹ + have hr : r≠0 := inv_ne_zero (Complex.ofReal_ne_zero.mpr (norm_ne_zero_iff.mpr hz)) + have hn : ‖r • a‖≤1 := (norm_smul_inv_norm (𝕜:=ℂ) hz).le + have hc : ∀ i, g i*f (r • a)=f (r • a)*g i := by + intro i + simp only [map_smul,mul_smul_comm,smul_mul_assoc,ha i] + obtain ⟨c,hc⟩ := h (r • a) hn hc + exact algHom_scalar_of_smul f a hr c hc + +lemma scalar_of_range {A B ι : Type*} [Ring A] [Algebra ℂ A] [Ring B] [Algebra ℂ B] + (f : A →ₐ[ℂ] B) (g : ι → B) + (h : ∀ a : A, (∀ i, g i*f a=f a*g i) → ∃ c : ℂ, f a=c • 1) + (T : B) (hT : T∈Set.range f) (hcomm : ∀ i, g i*T=T*g i) : ∃ c : ℂ, T=c • 1 := by + obtain ⟨a,rfl⟩ := hT + exact h a hcomm + +include hτ in +theorem commutant_sequence_scalar + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (a : ℕ →ᵇ M) + (hcomm : ∀ b : ℕ →ᵇ D, + leftRestricted τ ω (mapSequence π b)*leftRestricted τ ω a= + leftRestricted τ ω a*leftRestricted τ ω (mapSequence π b)) : + ∃ c : ℂ, leftRestricted τ ω a=c • 1 := by + apply scalar_of_contractions (leftRestricted τ ω).toAlgHom + (fun b : ℕ →ᵇ D => leftRestricted τ ω (mapSequence π b)) _ a hcomm + intro a ha hc + exact ⟨_,commutant_contraction_sequence M τ hτ π ω hnormal hfaith hone hirr a ha hc⟩ + +include hτ in +theorem full_relative_commutant_scalar + (hnormal : BoundedWOTContinuous M τ) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hone : τ 1=1) + (hirr : ∀ b : M, (∀ a : D, π a*b=b*π a) → ∃ c : ℂ, b=algebraMap ℂ M c) + (hω : (ω : Filter ℕ)≤atTop) + {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hcomm : ∀ b : ℕ →ᵇ D, + leftRestricted τ ω (mapSequence π b)*T=T*leftRestricted τ ω (mapSequence π b)) : + ∃ c : ℂ, T=c • 1 := by + have hr : T∈Set.range (leftRestricted τ ω) := by + exact (congrArg (fun operators => T ∈ operators) (range_bicommutant τ ω hτ hω)).mp hT + exact scalar_of_range (leftRestricted τ ω).toAlgHom + (fun b : ℕ →ᵇ D => leftRestricted τ ω (mapSequence π b)) + (commutant_sequence_scalar M τ hτ π ω hnormal hfaith hone hirr) T hr hcomm + +end Kadison.TracialSequence +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialRepresentedCorner.lean b/lean/OAI/Analysis/Commutator/TracialRepresentedCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..43206a0a73e4f403633b9da5ad6f488881c589b7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialRepresentedCorner.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.RepresentedCornerBound + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +open Filter + +namespace Kadison.TracialSequence + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + +variable (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + +variable (D : VonNeumannAlgebra (boundedSubspace τ ω)) + +variable {K : Type} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (Q : VonNeumannAlgebra K) (j : Q →⋆ₐ[ℂ] A) + (hDQ : ∀ d : D,(d:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j))) + +include hτ hω hM hDQ in +lemma represented_corner_bound (T : τ.GNS →L[ℂ] τ.GNS) + {b c β : ℝ} (hb : 0≤b) (hc : 0≤c) (hβ : β congrFun ((algebraVector_dense τ).equalizer + (operatorConjugate τ hτ (τ.gnsStarAlgHom a)).continuous + (rightMul τ hτ (star a)).continuous (funext he)) x + +lemma operatorConjugate_right (a : A) : + operatorConjugate τ hτ (rightMul τ hτ a)=τ.gnsStarAlgHom (star a) := by + have h := congrArg (operatorConjugate τ hτ) (operatorConjugate_left τ hτ (star a)) + simpa only [operatorConjugate_involutive τ hτ _,star_star] using h.symm + +lemma bicommutant_star {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) : + star T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom)) := by + intro R hR + have h := congrArg star (hT _ (commutant_star τ hR)) + simpa only [star_mul,star_star] using h.symm + +lemma operatorConjugate_bicommutant_mem_commutant {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) : + operatorConjugate τ hτ T∈Set.centralizer (Set.range τ.gnsStarAlgHom) := by + rintro _ ⟨a,rfl⟩ + have h := congrArg (operatorConjugate τ hτ) + (hT _ (rightMul_mem_commutant τ hτ (star a))) + simpa only [operatorConjugate_mul,operatorConjugate_right,star_star] using h + +def rightOperator (T : τ.GNS →L[ℂ] τ.GNS) : τ.GNS →L[ℂ] τ.GNS := + operatorConjugate τ hτ (star T) + +lemma rightOperator_original (a : A) : + rightOperator τ hτ (τ.gnsStarAlgHom a)=rightMul τ hτ a := by + rw [rightOperator,←map_star,operatorConjugate_left,star_star] + +lemma rightOperator_norm (T : τ.GNS →L[ℂ] τ.GNS) : ‖rightOperator τ hτ T‖=‖T‖ := by + rw [rightOperator,operatorConjugate_norm] + exact ContinuousLinearMap.adjoint.norm_map T + +lemma rightOperator_mul (T R : τ.GNS →L[ℂ] τ.GNS) : + rightOperator τ hτ (T*R)=rightOperator τ hτ R*rightOperator τ hτ T := by + rw [rightOperator,star_mul,operatorConjugate_mul] + rfl + +theorem commutation {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.range τ.gnsStarAlgHom)) : + ∃ b : τ.GNS →L[ℂ] τ.GNS, + b∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom)) ∧ + T=rightOperator τ hτ b ∧ ‖b‖=‖T‖ := by + refine ⟨star (operatorConjugate τ hτ T), + bicommutant_star τ (operatorConjugate_commutant_mem_bicommutant τ hτ hT),?_,?_⟩ + · simp only [rightOperator,star_star] + exact (operatorConjugate_involutive τ hτ T).symm + · change ‖ContinuousLinearMap.adjoint (operatorConjugate τ hτ T)‖=‖T‖ + rw [ContinuousLinearMap.adjoint.norm_map,operatorConjugate_norm] + +lemma starMap_bicommutant_vacuum {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) : + starMap τ hτ (T (vacuum τ))=star T (vacuum τ) := by + apply (algebraVector_dense τ).eq_of_inner_right ℂ + intro a + have hc : rightMul τ hτ a (T (vacuum τ))=T (algebraVector τ a) := by + have he := congrArg (fun V : τ.GNS →L[ℂ] τ.GNS => V (vacuum τ)) + (hT _ (rightMul_mem_commutant τ hτ a)) + simpa only [mul_apply_eq_comp,right_vacuum,algebraVector_apply] using he + calc + _ = inner ℂ (T (vacuum τ)) (starMap τ hτ (algebraVector τ a)) := by + simpa only [starMap_starMap] using + (starMap_inner τ hτ (starMap τ hτ (algebraVector τ a)) (T (vacuum τ))) + _ = inner ℂ (T (vacuum τ)) (rightMul τ hτ (star a) (vacuum τ)) := by + rw [starMap_algebra,right_vacuum]; rfl + _ = inner ℂ (rightMul τ hτ a (T (vacuum τ))) (vacuum τ) := by + rw [rightMul_star,ContinuousLinearMap.adjoint_inner_right] + _ = inner ℂ (T (algebraVector τ a)) (vacuum τ) := by rw [hc] + _ = inner ℂ (algebraVector τ a) (star T (vacuum τ)) := by + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + +include hτ in +lemma bicommutant_vacuum_separating {T : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) + (hz : T (vacuum τ)=0) : T=0 := by + apply ContinuousLinearMap.ext + have he : ∀ a : A, T (algebraVector τ a)=0 := by + intro a + have hh := congrArg (fun V : τ.GNS →L[ℂ] τ.GNS => V (vacuum τ)) + (hT _ (rightMul_mem_commutant τ hτ a)) + simpa only [mul_apply_eq_comp,right_vacuum,algebraVector_apply,hz,map_zero] using hh.symm + exact fun x => congrFun ((algebraVector_dense τ).equalizer T.continuous continuous_const (funext he)) x + +include hτ in +lemma bicommutant_trace {T R : τ.GNS →L[ℂ] τ.GNS} + (hT : T∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) + (hR : R∈Set.centralizer (Set.centralizer (Set.range τ.gnsStarAlgHom))) : + inner ℂ (vacuum τ) ((T*R) (vacuum τ))= + inner ℂ (vacuum τ) ((R*T) (vacuum τ)) := by + calc + _ = inner ℂ (star T (vacuum τ)) (R (vacuum τ)) := by + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left] + rfl + _ = inner ℂ (starMap τ hτ (T (vacuum τ))) (R (vacuum τ)) := by + rw [starMap_bicommutant_vacuum τ hτ hT] + _ = inner ℂ (starMap τ hτ (R (vacuum τ))) (T (vacuum τ)) := by + simpa only [starMap_starMap] using + (starMap_inner τ hτ (T (vacuum τ)) (starMap τ hτ (R (vacuum τ)))) + _ = inner ℂ (star R (vacuum τ)) (T (vacuum τ)) := by + rw [starMap_bicommutant_vacuum τ hτ hR] + _ = _ := by + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_left] + rfl + +end Kadison.TracialGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialSequence.lean b/lean/OAI/Analysis/Commutator/TracialSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad27621fbcacc75610efe46af4c1ed1e3721a116 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialSequence.lean @@ -0,0 +1,163 @@ +import Mathlib +import OAI.Analysis.Commutator.HilbertSequenceOperator +import OAI.Analysis.Commutator.ReducingRepresentation +import OAI.Analysis.Commutator.TracialConjugation + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +def vectorCLM : A →L[ℂ] τ.GNS := + (algebraVector τ).mkContinuous ‖vacuum τ‖ (fun a => by + rw [algebraVector_apply,←left_vacuum] + exact ((τ.gnsStarAlgHom a).le_opNorm _).trans (by + rw [mul_comm] + exact mul_le_mul_of_nonneg_left (NonUnitalStarAlgHom.norm_apply_le τ.gnsStarAlgHom a) + (norm_nonneg _))) + +@[simp] lemma vectorCLM_apply (a : A) : vectorCLM τ a=algebraVector τ a := rfl + +def vectorPre (a : ℕ →ᵇ A) : Pre ω τ.GNS := + ⟨BoundedContinuousFunction.comp (vectorCLM τ) (vectorCLM τ).lipschitzWith a⟩ + +@[simp] lemma vectorPre_seq (a : ℕ →ᵇ A) (i : ℕ) : + (vectorPre τ ω a).seq i=algebraVector τ (a i) := rfl + +def vector : (ℕ →ᵇ A) →ₗ[ℂ] Space ω τ.GNS where + toFun a := (vectorPre τ ω a : Space ω τ.GNS) + map_add' a b := by + rw [←Completion.coe_add] + congr 1 + apply (equiv ω τ.GNS).injective + apply BoundedContinuousFunction.ext + intro i + exact map_add (algebraVector τ) _ _ + map_smul' r a := by + rw [←Completion.coe_smul] + congr 1 + apply (equiv ω τ.GNS).injective + apply BoundedContinuousFunction.ext + intro i + exact map_smul (algebraVector τ) _ _ + +lemma vector_eq_zero_iff (a : ℕ →ᵇ A) : vector τ ω a=0 ↔ + Tendsto (fun i => ‖algebraVector τ (a i)‖) (ω : Filter ℕ) (𝓝 0) := + coe_eq_zero_iff ω τ.GNS (vectorPre τ ω a) + +def boundedSubspace : Submodule ℂ (Space ω τ.GNS) := (LinearMap.range (vector τ ω)).topologicalClosure + +instance : CompleteSpace (boundedSubspace τ ω) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +lemma vector_mem (a : ℕ →ᵇ A) : vector τ ω a∈boundedSubspace τ ω := + Submodule.le_topologicalClosure _ (LinearMap.mem_range_self _ a) + +def leftFamily (a : ℕ →ᵇ A) : ℕ →ᵇ (τ.GNS →L[ℂ] τ.GNS) := + BoundedContinuousFunction.mkOfDiscrete (fun i => τ.gnsStarAlgHom (a i)) (2*‖a‖) + (fun i j => (dist_le_norm_add_norm _ _).trans (by + have hi := (NonUnitalStarAlgHom.norm_apply_le τ.gnsStarAlgHom (a i)).trans (a.norm_coe_le_norm i) + have hj := (NonUnitalStarAlgHom.norm_apply_le τ.gnsStarAlgHom (a j)).trans (a.norm_coe_le_norm j) + linarith)) + +@[simp] lemma leftFamily_apply (a : ℕ →ᵇ A) (i : ℕ) : leftFamily τ a i=τ.gnsStarAlgHom (a i) := rfl + +lemma norm_leftFamily_le (a : ℕ →ᵇ A) : ‖leftFamily τ a‖≤‖a‖ := by + apply (BoundedContinuousFunction.norm_le (norm_nonneg a)).mpr + intro i + exact (NonUnitalStarAlgHom.norm_apply_le τ.gnsStarAlgHom (a i)).trans (a.norm_coe_le_norm i) + +def leftHom : (ℕ →ᵇ A) →⋆ₐ[ℂ] (Space ω τ.GNS →L[ℂ] Space ω τ.GNS) := + (actionHom ω).comp { + toFun := leftFamily τ + map_one' := by apply BoundedContinuousFunction.ext; intro i; exact map_one τ.gnsStarAlgHom + map_zero' := by apply BoundedContinuousFunction.ext; intro i; exact map_zero τ.gnsStarAlgHom + map_add' := by intro a b; apply BoundedContinuousFunction.ext; intro i; exact map_add τ.gnsStarAlgHom _ _ + map_mul' := by intro a b; apply BoundedContinuousFunction.ext; intro i; exact map_mul τ.gnsStarAlgHom _ _ + map_star' := by intro a; apply BoundedContinuousFunction.ext; intro i; exact map_star τ.gnsStarAlgHom _ + commutes' := by intro r; apply BoundedContinuousFunction.ext; intro i; exact τ.gnsStarAlgHom.commutes r } + +lemma leftHom_vector (a b : ℕ →ᵇ A) : leftHom τ ω a (vector τ ω b)=vector τ ω (a*b) := by + change act ω (leftFamily τ a) (vectorPre τ ω b : Space ω τ.GNS)=_ + rw [act_coe] + change (actPreLinear ω (leftFamily τ a) (vectorPre τ ω b) : Space ω τ.GNS)= + (vectorPre τ ω (a*b) : Space ω τ.GNS) + congr 1 + apply (equiv ω τ.GNS).injective + apply BoundedContinuousFunction.ext + intro i + change τ.gnsStarAlgHom (a i) (algebraVector τ (b i))=algebraVector τ (a i*b i) + exact left_coe τ _ _ + +lemma leftHom_preserves (a : ℕ →ᵇ A) (x : Space ω τ.GNS) (hx : x∈boundedSubspace τ ω) : + leftHom τ ω a x∈boundedSubspace τ ω := by + apply (Submodule.topologicalClosure_minimal (LinearMap.range (vector τ ω)) + (t := (boundedSubspace τ ω).comap (leftHom τ ω a).toLinearMap) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage (leftHom τ ω a).continuous)) hx + rintro _ ⟨b,rfl⟩ + change leftHom τ ω a (vector τ ω b)∈boundedSubspace τ ω + rw [leftHom_vector] + exact vector_mem τ ω _ + +def leftRestricted : (ℕ →ᵇ A) →⋆ₐ[ℂ] (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) := + ReducingRepresentation.restrict (leftHom τ ω) (boundedSubspace τ ω) (leftHom_preserves τ ω) + +@[simp] lemma leftRestricted_apply (a : ℕ →ᵇ A) (x : boundedSubspace τ ω) : + (leftRestricted τ ω a x:Space ω τ.GNS)=leftHom τ ω a x := rfl + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +lemma vector_mul_norm (a b : A) : ‖algebraVector τ (a*b)‖≤‖b‖*‖algebraVector τ a‖ := by + change ‖(τ.toPreGNS (a*b) : τ.GNS)‖≤‖b‖*‖(τ.toPreGNS a : τ.GNS)‖ + simp only [Completion.norm_coe] + change ‖rightMulPre τ hτ b (τ.toPreGNS a)‖≤_ + exact (rightMulPre τ hτ b).le_of_opNorm_le (norm_rightMulPre_le τ hτ b) _ + +include hτ in +lemma vector_mul_zero {a : ℕ →ᵇ A} (ha : vector τ ω a=0) (b : ℕ →ᵇ A) : + vector τ ω (a*b)=0 := by + rw [vector_eq_zero_iff] at ha ⊢ + have hlim := (tendsto_const_nhds (x := ‖b‖)).mul ha + apply squeeze_zero (fun i => norm_nonneg _) (fun i => + (vector_mul_norm τ hτ (a i) (b i)).trans + (mul_le_mul_of_nonneg_right (b.norm_coe_le_norm i) (norm_nonneg _))) + simpa only [mul_zero] using hlim + +include hτ in +lemma left_null {a : ℕ →ᵇ A} (ha : vector τ ω a=0) : leftRestricted τ ω a=0 := by + apply ContinuousLinearMap.ext + intro x + apply Subtype.ext + change leftHom τ ω a (x:Space ω τ.GNS)=0 + have hclosed : IsClosed {y : Space ω τ.GNS | leftHom τ ω a y=0} := + isClosed_eq (leftHom τ ω a).continuous continuous_const + apply closure_minimal (t := {y : Space ω τ.GNS | leftHom τ ω a y=0}) ?_ hclosed x.property + rintro _ ⟨b,rfl⟩ + change leftHom τ ω a (vector τ ω b)=0 + rw [leftHom_vector] + exact vector_mul_zero τ ω hτ ha b + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialSequenceCompression.lean b/lean/OAI/Analysis/Commutator/TracialSequenceCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..06c782ea94a947c9e2147f231f35652e7ae7cc1a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialSequenceCompression.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Commutator.MainMatrix +import OAI.Analysis.Commutator.ReducingCompression +import OAI.Analysis.Commutator.TracialSequence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence ReducingRepresentation + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma vector_const (a : A) : vector τ ω (BoundedContinuousFunction.const ℕ a)= + constant ω τ.GNS (algebraVector τ a) := by + rw [constant_apply] + change (vectorPre τ ω _ : Space ω τ.GNS)=(constantPre ω τ.GNS _ : Space ω τ.GNS) + congr 1 + +lemma constant_mem (x : τ.GNS) : constant ω τ.GNS x∈boundedSubspace τ ω := by + refine (algebraVector_dense τ).induction_on + (p := fun y => constant ω τ.GNS y∈boundedSubspace τ ω) x ?_ ?_ + · exact (Submodule.isClosed_topologicalClosure _).preimage (constant ω τ.GNS).continuous + · intro a + rw [←vector_const] + exact vector_mem τ ω _ + +def constantIn : τ.GNS →ₗᵢ[ℂ] boundedSubspace τ ω where + toFun x := ⟨constant ω τ.GNS x,constant_mem τ ω x⟩ + map_add' := by intro x y; apply Subtype.ext; exact map_add (constant ω τ.GNS) x y + map_smul' := by intro r x; apply Subtype.ext; exact map_smul (constant ω τ.GNS) r x + norm_map' := (constant ω τ.GNS).norm_map + +@[simp] lemma constantIn_coe (x : τ.GNS) : (constantIn τ ω x:Space ω τ.GNS)=constant ω τ.GNS x := rfl + +def compressed (S : τ.GNS →L[ℂ] τ.GNS) : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω := + compression (boundedSubspace τ ω) (act ω (BoundedContinuousFunction.const ℕ S)) + +lemma norm_compressed_le (S : τ.GNS →L[ℂ] τ.GNS) : ‖compressed τ ω S‖≤‖S‖ := by + exact (norm_compression_le _ _).trans (le_of_eq (norm_act_constant ω S)) + +lemma compressed_constant (S : τ.GNS →L[ℂ] τ.GNS) (x : τ.GNS) : + compressed τ ω S (constantIn τ ω x)=constantIn τ ω (S x) := by + change (boundedSubspace τ ω).orthogonalProjectionOnto + (act ω (BoundedContinuousFunction.const ℕ S) (constant ω τ.GNS x))=_ + rw [act_constant] + exact Submodule.orthogonalProjectionOnto_mem_subspace_eq_self (constantIn τ ω (S x)) + +lemma leftFamily_const (a : A) : leftFamily τ (BoundedContinuousFunction.const ℕ a)= + BoundedContinuousFunction.const ℕ (τ.gnsStarAlgHom a) := rfl + +lemma leftRestricted_constant (a : A) (x : τ.GNS) : + leftRestricted τ ω (BoundedContinuousFunction.const ℕ a) (constantIn τ ω x)= + constantIn τ ω (τ.gnsStarAlgHom a x) := by + apply Subtype.ext + change act ω (leftFamily τ (BoundedContinuousFunction.const ℕ a)) (constant ω τ.GNS x)=_ + rw [leftFamily_const,act_constant] + rfl + +lemma leftRestricted_eq_zero_iff (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) (a : ℕ →ᵇ A) : + leftRestricted τ ω a=0 ↔ vector τ ω a=0 := by + constructor + · intro h + let v : boundedSubspace τ ω := ⟨vector τ ω 1,vector_mem τ ω 1⟩ + have he := congrArg (fun T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + (T v:Space ω τ.GNS)) h + change leftHom τ ω a (vector τ ω 1)=0 at he + simpa only [leftHom_vector,mul_one] using he + · exact left_null τ ω hτ + +lemma commutator_bound (S : τ.GNS →L[ℂ] τ.GNS) (a : ℕ →ᵇ A) (c : ℝ) + (hc : ∀ i, ‖S*τ.gnsStarAlgHom (a i)-τ.gnsStarAlgHom (a i)*S‖≤c) : + ‖compressed τ ω S*leftRestricted τ ω a-leftRestricted τ ω a*compressed τ ω S‖≤c := by + have hc0 : 0≤c := (norm_nonneg _).trans (hc 0) + let T : ℕ →ᵇ (τ.GNS →L[ℂ] τ.GNS) := + BoundedContinuousFunction.const ℕ S*leftFamily τ a-leftFamily τ a*BoundedContinuousFunction.const ℕ S + have hT : ‖T‖≤c := (BoundedContinuousFunction.norm_le hc0).mpr hc + have hid : act ω T=act ω (BoundedContinuousFunction.const ℕ S)*leftHom τ ω a- + leftHom τ ω a*act ω (BoundedContinuousFunction.const ℕ S) := by + change actionHom ω (_*_ - _*_) = _ + rw [map_sub,map_mul,map_mul] + rfl + calc + _ ≤ ‖act ω (BoundedContinuousFunction.const ℕ S)*leftHom τ ω a- + leftHom τ ω a*act ω (BoundedContinuousFunction.const ℕ S)‖ := + norm_commutator_compression_le (leftHom τ ω) (boundedSubspace τ ω) + (leftHom_preserves τ ω) _ a + _ = ‖act ω T‖ := congrArg norm hid.symm + _ ≤ ‖T‖ := norm_act_le ω T + _ ≤ c := hT + +lemma commutator_zero (S : τ.GNS →L[ℂ] τ.GNS) (a : ℕ →ᵇ A) + (ha : ∀ i, S*τ.gnsStarAlgHom (a i)=τ.gnsStarAlgHom (a i)*S) : + compressed τ ω S*leftRestricted τ ω a=leftRestricted τ ω a*compressed τ ω S := by + apply sub_eq_zero.mp + exact (@norm_le_zero_iff (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) _ _).mp + (commutator_bound τ ω S a 0 (fun i => by rw [ha i,sub_self,norm_zero])) + +lemma norm_original_commutator_le (S : τ.GNS →L[ℂ] τ.GNS) (a : A) : + ‖S*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*S‖≤ + ‖compressed τ ω S*leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)- + leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)*compressed τ ω S‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg + (compressed τ ω S*leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)- + leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)*compressed τ ω S)) + intro x + have h := (compressed τ ω S*leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)- + leftRestricted τ ω (BoundedContinuousFunction.const ℕ a)*compressed τ ω S).le_opNorm + (constantIn τ ω x) + simpa only [sub_apply,mul_apply_eq_comp,leftRestricted_constant,compressed_constant, + ←map_sub,LinearIsometry.norm_map] using h + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialSequenceRight.lean b/lean/OAI/Analysis/Commutator/TracialSequenceRight.lean new file mode 100644 index 0000000000000000000000000000000000000000..2ec3af2c0081d269a6de6e7fbf4fd710603752e4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialSequenceRight.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialSequence + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +def vectorIn (a : ℕ →ᵇ A) : boundedSubspace τ ω := ⟨vector τ ω a,vector_mem τ ω a⟩ + +@[simp] lemma vectorIn_coe (a : ℕ →ᵇ A) : (vectorIn τ ω a : Space ω τ.GNS)=vector τ ω a := rfl + +lemma leftRestricted_vector (a b : ℕ →ᵇ A) : + leftRestricted τ ω a (vectorIn τ ω b)=vectorIn τ ω (a*b) := by + apply Subtype.ext + exact leftHom_vector τ ω a b + +lemma operator_ext (S T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + (h : ∀ a : ℕ →ᵇ A, S (vectorIn τ ω a)=T (vectorIn τ ω a)) : S=T := by + apply ContinuousLinearMap.ext + intro x + let P := (boundedSubspace τ ω).orthogonalProjectionOnto + have hc : IsClosed {y : Space ω τ.GNS | S (P y)=T (P y)} := + isClosed_eq (S.continuous.comp P.continuous) (T.continuous.comp P.continuous) + have hm : (LinearMap.range (vector τ ω) : Set (Space ω τ.GNS))⊆ + {y | S (P y)=T (P y)} := by + rintro _ ⟨a,rfl⟩ + have hp : P (vector τ ω a)=vectorIn τ ω a := + (boundedSubspace τ ω).orthogonalProjectionOnto_mem_subspace_eq_self (vectorIn τ ω a) + simpa only [Set.mem_ofPred_eq,hp] using h a + have hx := closure_minimal hm hc x.property + change S (P (x:Space ω τ.GNS))=T (P (x:Space ω τ.GNS)) at hx + simpa only [P,Submodule.orthogonalProjectionOnto_mem_subspace_eq_self] using hx + +def sequenceVacuum : boundedSubspace τ ω := vectorIn τ ω 1 + +@[simp] lemma leftRestricted_vacuum (a : ℕ →ᵇ A) : + leftRestricted τ ω a (sequenceVacuum τ ω)=vectorIn τ ω a := by + rw [sequenceVacuum,leftRestricted_vector,mul_one] + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +def rightFamily (a : ℕ →ᵇ A) : ℕ →ᵇ (τ.GNS →L[ℂ] τ.GNS) := + BoundedContinuousFunction.mkOfDiscrete (fun i => rightMul τ hτ (a i)) (2*‖a‖) + (fun i j => (dist_le_norm_add_norm _ _).trans (by + have hi := (rightMul_opNorm_le τ hτ (a i)).trans (a.norm_coe_le_norm i) + have hj := (rightMul_opNorm_le τ hτ (a j)).trans (a.norm_coe_le_norm j) + linarith)) + +@[simp] lemma rightFamily_apply (a : ℕ →ᵇ A) (i : ℕ) : + rightFamily τ hτ a i=rightMul τ hτ (a i) := rfl + +def rightAction (a : ℕ →ᵇ A) : Space ω τ.GNS →L[ℂ] Space ω τ.GNS := + act ω (rightFamily τ hτ a) + +lemma rightAction_vector (a b : ℕ →ᵇ A) : + rightAction τ ω hτ a (vector τ ω b)=vector τ ω (b*a) := by + change act ω (rightFamily τ hτ a) (vectorPre τ ω b : Space ω τ.GNS)=_ + rw [act_coe] + change (actPreLinear ω (rightFamily τ hτ a) (vectorPre τ ω b) : Space ω τ.GNS)= + (vectorPre τ ω (b*a) : Space ω τ.GNS) + congr 1 + apply (equiv ω τ.GNS).injective + apply BoundedContinuousFunction.ext + intro i + change rightMul τ hτ (a i) (algebraVector τ (b i))=algebraVector τ (b i*a i) + exact rightMul_coe τ hτ (a i) (τ.toPreGNS (b i)) + +lemma rightAction_preserves (a : ℕ →ᵇ A) (x : Space ω τ.GNS) (hx : x∈boundedSubspace τ ω) : + rightAction τ ω hτ a x∈boundedSubspace τ ω := by + apply (Submodule.topologicalClosure_minimal (LinearMap.range (vector τ ω)) + (t := (boundedSubspace τ ω).comap (rightAction τ ω hτ a).toLinearMap) ?_ + ((Submodule.isClosed_topologicalClosure _).preimage (rightAction τ ω hτ a).continuous)) hx + rintro _ ⟨b,rfl⟩ + change rightAction τ ω hτ a (vector τ ω b)∈boundedSubspace τ ω + rw [rightAction_vector] + exact vector_mem τ ω _ + +def rightRestricted (a : ℕ →ᵇ A) : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω := + (rightAction τ ω hτ a).restrict (rightAction_preserves τ ω hτ a) + +lemma rightRestricted_vector (a b : ℕ →ᵇ A) : + rightRestricted τ ω hτ a (vectorIn τ ω b)=vectorIn τ ω (b*a) := by + apply Subtype.ext + exact rightAction_vector τ ω hτ a b + +@[simp] lemma rightRestricted_vacuum (a : ℕ →ᵇ A) : + rightRestricted τ ω hτ a (sequenceVacuum τ ω)=vectorIn τ ω a := by + rw [sequenceVacuum,rightRestricted_vector,one_mul] + +lemma left_right (a b : ℕ →ᵇ A) : + leftRestricted τ ω a*rightRestricted τ ω hτ b= + rightRestricted τ ω hτ b*leftRestricted τ ω a := by + apply operator_ext τ ω + intro c + simp only [mul_apply_eq_comp,leftRestricted_vector,rightRestricted_vector,mul_assoc] + +lemma right_mem_commutant (a : ℕ →ᵇ A) : + rightRestricted τ ω hτ a∈Set.centralizer (Set.range (leftRestricted τ ω)) := by + rintro _ ⟨b,rfl⟩ + exact left_right τ ω hτ b a + +include hτ in +lemma bicommutant_eq_of_vacuum (S T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + (hS : S∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (h : S (sequenceVacuum τ ω)=T (sequenceVacuum τ ω)) : S=T := by + apply operator_ext τ ω + intro a + have hs := congrArg (fun R : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + R (sequenceVacuum τ ω)) (hS _ (right_mem_commutant τ ω hτ a)) + have ht := congrArg (fun R : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + R (sequenceVacuum τ ω)) (hT _ (right_mem_commutant τ ω hτ a)) + simp only [mul_apply_eq_comp,rightRestricted_vacuum] at hs ht + rw [h] at hs + exact hs.symm.trans ht + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialSequenceTrace.lean b/lean/OAI/Analysis/Commutator/TracialSequenceTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..fba9de9184b87a99128b0d822c66c92733a21974 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialSequenceTrace.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialSequenceRight + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison + +namespace VectorFunctional + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def functional (x : H) : (H →L[ℂ] H) →ₚ[ℂ] ℂ where + toLinearMap := { + toFun T := inner ℂ x (T x) + map_add' := by intro S T; simp only [add_apply,inner_add_right] + map_smul' := by intro c T; simp only [smul_apply,inner_smul_right,smul_eq_mul,RingHom.id_apply] } + monotone' := by + intro S T hST + apply sub_nonneg.mp + rw [←inner_sub_right,←sub_apply] + exact (ContinuousLinearMap.nonneg_iff_isPositive.mp (sub_nonneg.mpr hST)).inner_nonneg_right x + +omit [CompleteSpace H] in +@[simp] lemma functional_apply (x : H) (T : H →L[ℂ] H) : + functional x T=inner ℂ x (T x) := rfl + +lemma functional_star_mul (x : H) (T : H →L[ℂ] H) : + functional x (star T*T)=inner ℂ (T x) (T x) := by + rw [functional_apply,mul_apply_eq_comp,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_right] + +omit [CompleteSpace H] in +lemma continuous_functional_wot (x : H) : + Continuous (fun T : H →WOT[ℂ] H => inner ℂ x (T x)) := + ContinuousLinearMapWOT.continuous_dual_apply x (innerSL ℂ x) + +end VectorFunctional + +namespace TracialSequence + +open TracialGNS HilbertSequence + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +def sequenceTrace : (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) →ₚ[ℂ] ℂ := + VectorFunctional.functional (sequenceVacuum τ ω) + +lemma tendsto_trace (a : ℕ →ᵇ A) : Tendsto (fun i => τ (a i)) (ω : Filter ℕ) + (𝓝 (sequenceTrace τ ω (leftRestricted τ ω a))) := by + change Tendsto _ _ (𝓝 (inner ℂ (sequenceVacuum τ ω) (leftRestricted τ ω a (sequenceVacuum τ ω)))) + rw [leftRestricted_vacuum] + change Tendsto _ _ (𝓝 (inner ℂ (vector τ ω 1) (vector τ ω a))) + change Tendsto _ _ (𝓝 (inner ℂ (vectorPre τ ω 1 : Space ω τ.GNS) (vectorPre τ ω a : Space ω τ.GNS))) + rw [Completion.inner_coe] + simpa only [vectorPre_seq,BoundedContinuousFunction.coe_one,Pi.one_apply,inner_algebraVector,star_one,one_mul] using + tendsto_inner ω τ.GNS (vectorPre τ ω 1) (vectorPre τ ω a) + +lemma trace_one : sequenceTrace τ ω 1=τ 1 := by + have h := tendsto_trace τ ω (1 : ℕ →ᵇ A) + simp only [map_one] at h + exact tendsto_nhds_unique h tendsto_const_nhds + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +lemma trace_mul (a b : ℕ →ᵇ A) : sequenceTrace τ ω (leftRestricted τ ω (a*b))= + sequenceTrace τ ω (leftRestricted τ ω (b*a)) := by + apply tendsto_nhds_unique (tendsto_trace τ ω (a*b)) + simpa only [BoundedContinuousFunction.mul_apply,hτ] using tendsto_trace τ ω (b*a) + +include hτ in +lemma trace_faithful {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hz : sequenceTrace τ ω (star T*T)=0) : T=0 := by + have hv : T (sequenceVacuum τ ω)=0 := by + rw [sequenceTrace,VectorFunctional.functional_star_mul] at hz + exact inner_self_eq_zero.mp hz + apply bicommutant_eq_of_vacuum τ ω hτ T 0 hT + · intro b _; simp + · simpa only [zero_apply] using hv + +end TracialSequence + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialSmallCorners.lean b/lean/OAI/Analysis/Commutator/TracialSmallCorners.lean new file mode 100644 index 0000000000000000000000000000000000000000..da6d4bc157542234819ccfc1cc82964d7adb3841 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialSmallCorners.lean @@ -0,0 +1,164 @@ +import Mathlib +import OAI.Analysis.Commutator.ProjectionLifts +import OAI.Analysis.Commutator.TracialUltrapowerTransfer + +namespace OAI + +noncomputable section + +attribute [local instance] Classical.propDecidable + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence + +variable {A B : Type*} [CStarAlgebra A] [CStarAlgebra B] + +def mapSequence (f : A →⋆ₐ[ℂ] B) : (ℕ →ᵇ A) →⋆ₐ[ℂ] (ℕ →ᵇ B) where + toFun a := BoundedContinuousFunction.ofNormedAddCommGroupDiscrete (fun i => f (a i)) + ‖a‖ (fun i => (NonUnitalStarAlgHom.norm_apply_le f (a i)).trans (a.norm_coe_le_norm i)) + map_one' := by ext i; exact map_one f + map_mul' a b := by ext i; exact map_mul f (a i) (b i) + map_zero' := by ext i; exact map_zero f + map_add' a b := by ext i; exact map_add f (a i) (b i) + commutes' z := by ext i; exact AlgHom.commutes f.toAlgHom z + map_star' a := by ext i; exact map_star f (a i) + +@[simp] lemma mapSequence_apply (f : A →⋆ₐ[ℂ] B) (a : ℕ →ᵇ A) (i : ℕ) : + mapSequence f a i=f (a i) := rfl + +variable [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +lemma leftRestricted_eq_of_eventuallyEq {a b : ℕ →ᵇ A} + (hab : (a : ℕ → A)=ᶠ[ω] b) : leftRestricted τ ω a=leftRestricted τ ω b := by + apply sub_eq_zero.mp + rw [←map_sub,leftRestricted_eq_zero_iff τ ω hτ] + change ((vectorPre τ ω (a-b)) : Space ω τ.GNS)=0 + apply (coe_eq_zero_iff ω τ.GNS _).mpr + apply tendsto_const_nhds.congr' + filter_upwards [hab] with i hi + simp only [vectorPre_seq,BoundedContinuousFunction.sub_apply,hi,sub_self, + map_zero,norm_zero] + +def cutSequence {G : Type*} [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [CompleteSpace G] (N : VonNeumannAlgebra G) (q : ℕ →ᵇ N) + (good : ℕ → Prop) : ℕ →ᵇ N := + BoundedContinuousFunction.ofNormedAddCommGroupDiscrete + (fun i => if good i then q i else 0) ‖q‖ (fun i => by + split_ifs + · exact q.norm_coe_le_norm i + · simpa only [norm_zero] using norm_nonneg q) + +@[simp] lemma cutSequence_apply {G : Type*} [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [CompleteSpace G] (N : VonNeumannAlgebra G) (q : ℕ →ᵇ N) + (good : ℕ → Prop) (i : ℕ) : + cutSequence N q good i=if good i then q i else 0 := rfl + +lemma projection_operator_lift {G K : Type*} + [NormedAddCommGroup G] [InnerProductSpace ℂ G] [CompleteSpace G] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + (N : VonNeumannAlgebra G) (φ : (ℕ →ᵇ N) →⋆ₐ[ℂ] (K →L[ℂ] K)) + {e : K →L[ℂ] K} (he : IsStarProjection e) (her : e∈Set.range φ) : + ∃ q : ℕ →ᵇ N, (∀ i, IsStarProjection (q i)) ∧ φ q=e := + ProjectionLifts.projection_lift (ι:=ℕ) (B:=(K →L[ℂ] K)) N φ he her + +lemma projection_rep_lift {G : Type*} [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [CompleteSpace G] (N : VonNeumannAlgebra G) (f : N →⋆ₐ[ℂ] A) + {e : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (he : IsStarProjection e) + (her : e∈Set.range ((leftRestricted τ ω).comp (mapSequence f))) : + ∃ q : ℕ →ᵇ N, (∀ i, IsStarProjection (q i)) ∧ leftRestricted τ ω (mapSequence f q)=e := + projection_operator_lift N + ((leftRestricted τ ω).comp (mapSequence f)) he her + +include hτ in +theorem small_projection_lift {G : Type*} [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [CompleteSpace G] (N : VonNeumannAlgebra G) (f : N →⋆ₐ[ℂ] A) + {b : ℝ} (hb : 0≤b) + {e : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (he : IsStarProjection e) + (her : e∈Set.range ((leftRestricted τ ω).comp (mapSequence f))) + (het : (sequenceTrace τ ω e).re.comp (tendsto_trace τ ω (mapSequence f q)) + change Tendsto (fun i => (τ (f (q i))).re) (ω : Filter ℕ) + (𝓝 (sequenceTrace τ ω (leftRestricted τ ω (mapSequence f q))).re) at ht + have hlim : (sequenceTrace τ ω (leftRestricted τ ω (mapSequence f q))).re < b := + lt_of_eq_of_lt (congrArg (fun T => (sequenceTrace τ ω T).re) hqe) het + have hg : ∀ᶠ i in (ω : Filter ℕ), (τ (f (q i))).re≤b := + (ht.eventually (gt_mem_nhds hlim)).mono (fun _ h => h.le) + let r := cutSequence N q (fun i => (τ (f (q i))).re≤b) + have hrq : (r : ℕ → N)=ᶠ[ω] q := by + filter_upwards [hg] with i hi + exact ite_eq_left hi + have hre : leftRestricted τ ω (mapSequence f r)=e := by + exact (leftRestricted_eq_of_eventuallyEq τ ω hτ + (a := mapSequence f r) (b := mapSequence f q) + (hrq.mono (fun _ hi => congrArg f hi))).trans hqe + have hr (i : ℕ) : IsStarProjection (r i) := by + change IsStarProjection (if _ then q i else 0) + split_ifs + · exact hq i + · exact IsStarProjection.zero _ + have hrt (i : ℕ) : (τ (f (r i))).re≤b := by + change (τ (f (if _ then q i else 0))).re≤b + split_ifs with hi + · exact hi + · simpa only [map_zero,Complex.zero_re] using hb + exact ⟨r,hr,hrt,hre⟩ + +include hτ in +theorem small_corner_bound {G : Type*} [NormedAddCommGroup G] [InnerProductSpace ℂ G] + [CompleteSpace G] (N : VonNeumannAlgebra G) (f : N →⋆ₐ[ℂ] A) + (hω : (ω : Filter ℕ)≤atTop) + (S : τ.GNS →L[ℂ] τ.GNS) {b c : ℝ} (hb : 0≤b) (hc : 0≤c) + (hS : ∀ (q : N), IsStarProjection q → (τ (f q)).re≤b → + ∀ a : A, f q*a*f q=a → + ‖S*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*S‖≤c*‖a‖) + {e T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (he : IsStarProjection e) + (her : e∈Set.range ((leftRestricted τ ω).comp (mapSequence f))) + (het : (sequenceTrace τ ω e).re exact hfi.norm_le _ + _ ≤ ‖T‖ := by simpa only [one_mul,mul_one] using (a.norm_coe_le_norm i).trans hna + exact (hS (r i) (hr i) (hrt i) (z i) hz).trans + (by rw [hzT]; exact mul_le_mul_of_nonneg_left hn hc) + +end Kadison.TracialSequence + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialUltrapower.lean b/lean/OAI/Analysis/Commutator/TracialUltrapower.lean new file mode 100644 index 0000000000000000000000000000000000000000..03af74f3d0d1045d136dccdaa70a6422ad6b25cf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialUltrapower.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Commutator.BicommutantRange +import OAI.Analysis.Commutator.BoundedSequenceClosed +import OAI.Analysis.Commutator.KaplanskyRange +import OAI.Analysis.Commutator.TracialSequenceRight + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder ComplexStarModule + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence ComplexStarModule + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +lemma vector_unitball_isClosed (hω : (ω : Filter ℕ)≤atTop) : + IsClosed {x : boundedSubspace τ ω | ∃ a : ℕ →ᵇ A, ‖a‖≤1 ∧ vectorIn τ ω a=x} := by + have hc := (bounded_image_isClosed ω (vectorCLM τ) hω {a : A | ‖a‖≤1} 1 + (fun _ h => h)).preimage (continuous_subtype_val (p := fun x => x∈boundedSubspace τ ω)) + convert hc using 1 + ext x + constructor + · rintro ⟨a,ha,hax⟩ + refine ⟨a,fun i => (a.norm_coe_le_norm i).trans ha,?_⟩ + exact congrArg Subtype.val hax + · rintro ⟨a,ha,hax⟩ + refine ⟨a,(BoundedContinuousFunction.norm_le (by norm_num : (0:ℝ)≤1)).mpr ha,?_⟩ + exact Subtype.ext hax + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) + +include hτ in +theorem bicommutant_selfAdjoint_contraction (hω : (ω : Filter ℕ)≤atTop) + {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hsT : IsSelfAdjoint T) (hnT : ‖T‖≤1) : + ∃ a : ℕ →ᵇ A, ‖a‖≤1 ∧ leftRestricted τ ω a=T := by + have hx : T (sequenceVacuum τ ω)∈closure + {x : boundedSubspace τ ω | ∃ a : ℕ →ᵇ A, ‖a‖≤1 ∧ vectorIn τ ω a=x} := by + apply Metric.mem_closure_iff.mpr + intro ε hε + obtain ⟨a,_,hna,ha⟩ := Kaplansky.range_selfAdjoint_contraction_finite_approx + Unit (leftRestricted τ ω) hT hsT hnT (fun _ => sequenceVacuum τ ω) ε hε + refine ⟨vectorIn τ ω a,⟨a,hna,rfl⟩,?_⟩ + simpa only [dist_eq_norm,norm_sub_rev,leftRestricted_vacuum] using ha () + rw [(vector_unitball_isClosed τ ω hω).closure_eq] at hx + obtain ⟨a,hna,ha⟩ := hx + refine ⟨a,hna,bicommutant_eq_of_vacuum τ ω hτ _ _ ?_ hT ?_⟩ + · exact Set.subset_centralizer_centralizer (Set.mem_range_self a) + · simpa only [leftRestricted_vacuum] using ha + +include hτ in +theorem range_bicommutant (hω : (ω : Filter ℕ)≤atTop) : + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))= + Set.range (leftRestricted τ ω) := by + let φ : (ℕ →ᵇ A) →⋆ₐ[ℂ] (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) := leftRestricted τ ω + have h : ∀ T∈Set.centralizer (Set.centralizer (Set.range φ)), + IsSelfAdjoint T → ‖T‖≤1 → T∈Set.range φ := by + intro T hT hsT hnT + obtain ⟨a,_,ha⟩ := bicommutant_selfAdjoint_contraction τ ω hτ hω hT hsT hnT + exact ⟨a,ha⟩ + exact BicommutantRange.operatorHom_range φ h + +def ultrapower (hω : (ω : Filter ℕ)≤atTop) : VonNeumannAlgebra (boundedSubspace τ ω) := + BicommutantRange.ofStarHom (leftRestricted τ ω) (range_bicommutant τ ω hτ hω) + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialUltrapowerTransfer.lean b/lean/OAI/Analysis/Commutator/TracialUltrapowerTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..1213bf9a59eeec3df6f2cbc083f77fd875d159ce --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialUltrapowerTransfer.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.Commutator.CStarContractiveLifts +import OAI.Analysis.Commutator.TracialSequenceCompression +import OAI.Analysis.Commutator.TracialSequenceTrace +import OAI.Analysis.Commutator.TracialUltrapower + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace BoundedContinuousFunction ComplexOrder + +open Filter UniformSpace Completion + +namespace Kadison.TracialSequence + +open TracialGNS HilbertSequence + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (hτ : ∀ a b : A, τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤atTop) + +include hτ hω in +theorem bicommutant_norm_lift {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) : + ∃ a : ℕ →ᵇ A, ‖a‖≤‖T‖ ∧ leftRestricted τ ω a=T := by + rw [range_bicommutant τ ω hτ hω] at hT + exact CStarContractiveLifts.operator_norm_lift (leftRestricted τ ω) hT + +include hτ hω in +theorem bicommutant_trace_mul + {S T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hS : S∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) : + sequenceTrace τ ω (S*T)=sequenceTrace τ ω (T*S) := by + rw [range_bicommutant τ ω hτ hω] at hS hT + obtain ⟨a,rfl⟩ := hS + obtain ⟨b,rfl⟩ := hT + simpa only [map_mul] using trace_mul τ ω hτ a b + +include hτ hω in +theorem bicommutant_commutator_bound (S : τ.GNS →L[ℂ] τ.GNS) (c : ℝ) + (hc : 0≤c) + (hS : ∀ a : A, ‖S*τ.gnsStarAlgHom a-τ.gnsStarAlgHom a*S‖≤c*‖a‖) + {T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω} + (hT : T∈Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) : + ‖compressed τ ω S*T-T*compressed τ ω S‖≤c*‖T‖ := by + obtain ⟨a,hna,rfl⟩ := bicommutant_norm_lift τ ω hτ hω hT + apply commutator_bound τ ω S a (c*‖leftRestricted τ ω a‖) + intro i + exact (hS (a i)).trans (mul_le_mul_of_nonneg_left ((a.norm_coe_le_norm i).trans hna) hc) + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TracialVectorSubalgebra.lean b/lean/OAI/Analysis/Commutator/TracialVectorSubalgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..52188421c3b80de7bdb37deaf7acc3cee37d037e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TracialVectorSubalgebra.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeWordTensor +import OAI.Analysis.Commutator.GNSVectorEmbedding +import OAI.Analysis.Commutator.NormalGNS +import OAI.Analysis.Commutator.TracialUltrapowerTransfer + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder + +namespace Kadison.VectorGNS + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def subalgebraTrace (M : VonNeumannAlgebra H) (ξ : H) : M →ₚ[ℂ] ℂ where + toLinearMap := (VectorFunctional.functional ξ).toLinearMap.comp M.toStarSubalgebra.subtype.toLinearMap + monotone' := fun _ _ h => (VectorFunctional.functional ξ).monotone h + +@[simp] lemma subalgebraTrace_apply (M : VonNeumannAlgebra H) (ξ : H) (a : M) : + subalgebraTrace M ξ a=inner ℂ ξ ((a:H →L[ℂ] H) ξ) := rfl + +lemma subalgebraTrace_subtype (M : VonNeumannAlgebra H) (ξ : H) (a : M) : + subalgebraTrace M ξ a=inner ℂ ξ (M.toStarSubalgebra.subtype a ξ) := rfl + +lemma subalgebraTrace_normal (M : VonNeumannAlgebra H) (ξ : H) : + NormalGNS.BoundedWOTContinuous M (subalgebraTrace M ξ) := by + intro C + exact (VectorFunctional.continuous_functional_wot ξ).comp continuous_subtype_val + +abbrev subalgebraEmbedding (M : VonNeumannAlgebra H) (ξ : H) : + (subalgebraTrace M ξ).GNS →ₗᵢ[ℂ] H := + embedding (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ (subalgebraTrace_subtype M ξ) + +abbrev subalgebraCompression (M : VonNeumannAlgebra H) (ξ : H) (T : H →L[ℂ] H) : + (subalgebraTrace M ξ).GNS →L[ℂ] (subalgebraTrace M ξ).GNS := + compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ + (subalgebraTrace_subtype M ξ) T + +@[simp] lemma subalgebraEmbedding_coe (M : VonNeumannAlgebra H) (ξ : H) (a : M) : + subalgebraEmbedding M ξ (TracialGNS.algebraVector (subalgebraTrace M ξ) a)= + (a:H →L[ℂ] H) ξ := + embedding_coe (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ + (subalgebraTrace_subtype M ξ) a + +lemma subalgebraCompression_on_preserved (M : VonNeumannAlgebra H) (ξ : H) + (T : H →L[ℂ] H) (x y : (subalgebraTrace M ξ).GNS) + (hxy : T (subalgebraEmbedding M ξ x)=subalgebraEmbedding M ξ y) : + compression (subalgebraTrace M ξ) M.toStarSubalgebra.subtype ξ + (subalgebraTrace_subtype M ξ) T x=y := + compression_on_preserved _ _ _ _ T x y hxy + +end Kadison.VectorGNS + +namespace Kadison.TracialSequence + +open TracialGNS FreeWordTensor + +variable {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +variable (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) (hω : (ω : Filter ℕ)≤Filter.atTop) + +variable (M : VonNeumannAlgebra (boundedSubspace τ ω)) + (hM : ∀ a : M,(a:boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) ∈ + Set.centralizer (Set.centralizer (Set.range (leftRestricted τ ω)))) + +include hτ hω hM in +lemma subalgebra_tracial (a b : M) : + VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) (a*b)= + VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) (b*a) := + bicommutant_trace_mul τ ω hτ hω (hM a) (hM b) + +include hτ hM in +lemma subalgebra_faithful (a : M) + (ha : VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) (star a*a)=0) : a=0 := by + apply Subtype.ext + exact trace_faithful τ ω hτ (hM a) ha + +lemma subalgebra_normalized (hone : τ 1=1) : + VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) 1=1 := + (trace_one τ ω).trans hone + +abbrev subalgebraState (hone : τ 1=1) : FaithfulState M where + functional := VectorGNS.subalgebraTrace M (sequenceVacuum τ ω) + normalized := subalgebra_normalized τ ω M hone + faithful := subalgebra_faithful τ ω hτ M hM + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TriangularCb.lean b/lean/OAI/Analysis/Commutator/TriangularCb.lean new file mode 100644 index 0000000000000000000000000000000000000000..67061f9b40d64cfdb2ab2950ef5553ba8551a5fb --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TriangularCb.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Commutator.CyclicSpatialImplementation +import OAI.Analysis.Commutator.RectangularColumn +import OAI.Analysis.Commutator.HilbertPair +import OAI.Analysis.Commutator.AmplificationIsometry + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison.RectangularColumn + +open CyclicColumns HilbertPair HilbertPadding + +variable {A K F : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +local instance triangularCbNormedAddCommGroup : NormedAddCommGroup (K →L[ℂ] F) := + ContinuousLinearMap.toNormedAddCommGroup + +local instance triangularCbNormedSpace : NormedSpace ℂ (K →L[ℂ] F) := + ContinuousLinearMap.toNormedSpace + +def diagonalRepresentation (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) : A →⋆ₐ[ℂ] (SumHilbert F K →L[ℂ] SumHilbert F K) where + toAlgHom := triangularHom σ lam 0 (by intros; simp) + map_star' a := by + change triangularMap σ lam 0 (star a)=star (triangularMap σ lam 0 a) + rw [ContinuousLinearMap.star_eq_adjoint] + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp [WithLp.prod_inner_apply,map_star,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_left] + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma diagonalRepresentation_apply (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (a : A) (x : SumHilbert F K) : + diagonalRepresentation σ lam a x=WithLp.toLp 2 (lam a x.fst,σ a x.snd) := by + simp [diagonalRepresentation] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma triangular_split (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) (a : A) : + triangularMap σ lam D a=diagonalRepresentation σ lam a+ + (left F K).toContinuousLinearMap.comp ((D a).comp (right F K).toContinuousLinearMap.adjoint) := by + ext x + apply (WithLp.equiv 2 (F × K)).injective + simp [right_adjoint] + +variable {ι : Type*} [Fintype ι] + +local instance : DecidableEq ι := Classical.decEq ι + +lemma offDiagonal_matrixAction (D : ι → ι → K →L[ℂ] F) : + matrixAction (fun i j => (left F K).toContinuousLinearMap.comp + ((D i j).comp (right F K).toContinuousLinearMap.adjoint))= + (amplifyIsometry ι (left F K)).toContinuousLinearMap.comp + ((matrixAction D).comp (amplifyIsometry ι (right F K)).toContinuousLinearMap.adjoint) := by + ext x i + simp only [matrixAction_apply,ContinuousLinearMap.comp_apply, + LinearIsometry.coe_toContinuousLinearMap,amplifyIsometry_apply,amplifyIsometry_adjoint] + rw [map_sum] + +lemma offDiagonal_matrix_norm_le (D : ι → ι → K →L[ℂ] F) : + ‖matrixAction (fun i j => (left F K).toContinuousLinearMap.comp + ((D i j).comp (right F K).toContinuousLinearMap.adjoint))‖≤‖matrixAction D‖ := by + rw [offDiagonal_matrixAction] + have hL := (amplifyIsometry ι (left F K)).norm_toContinuousLinearMap_le + have hR := (amplifyIsometry ι (right F K)).norm_toContinuousLinearMap_le + calc + _ ≤ ‖(amplifyIsometry ι (left F K)).toContinuousLinearMap‖* + ‖(matrixAction D).comp (amplifyIsometry ι (right F K)).toContinuousLinearMap.adjoint‖ := + ContinuousLinearMap.opNorm_comp_le _ _ + _ ≤ 1*(‖matrixAction D‖*1) := by + apply mul_le_mul hL _ (ContinuousLinearMap.opNorm_nonneg _) (by norm_num) + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_left (by simpa using hR) (ContinuousLinearMap.opNorm_nonneg _)) + _ = ‖matrixAction D‖ := by ring + +lemma triangular_matrix_norm_le (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) + (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) (D : A →L[ℂ] (K →L[ℂ] F)) + (hD : ∀ a b, D (a*b)=(D a).comp (σ b)+(lam a).comp (D b)) + {c : ℝ} (_hc : 0≤c) + (hcb : ∀ (X : CStarMatrix ι ι A),‖matrixAction (fun i j => D (X i j))‖≤c*‖X‖) + (X : CStarMatrix ι ι A) : + ‖CStarMatrix.mapₗ (triangularHom σ lam D hD).toLinearMap X‖≤(1+c)*‖X‖ := by + rw [←CyclicSpatial.matrixRepresentation_norm_eq + (StarAlgHom.id ℂ (SumHilbert F K →L[ℂ] SumHilbert F K)) Function.injective_id] + have he : matrixRepresentation (StarAlgHom.id ℂ (SumHilbert F K →L[ℂ] SumHilbert F K)) + (CStarMatrix.mapₗ (triangularHom σ lam D hD).toLinearMap X)= + matrixRepresentation (diagonalRepresentation σ lam) X+ + matrixAction (fun i j => (left F K).toContinuousLinearMap.comp + ((D (X i j)).comp (right F K).toContinuousLinearMap.adjoint)) := by + ext x i + simp only [CyclicSpatial.represented_matrix_apply,matrixAction_apply,_root_.add_apply,PiLp.add_apply] + change (∑ j,triangularMap σ lam D (X i j) (x j))=_ + simp only [triangular_split,_root_.add_apply,Finset.sum_add_distrib] + rw [he] + exact (norm_add_le _ _).trans ((add_le_add + (matrixRepresentation_norm_le (diagonalRepresentation σ lam) X) + ((offDiagonal_matrix_norm_le _).trans (hcb X))).trans_eq (by ring)) + +end Kadison.RectangularColumn + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TriangularMetric.lean b/lean/OAI/Analysis/Commutator/TriangularMetric.lean new file mode 100644 index 0000000000000000000000000000000000000000..fd9ba9c996ddef41b4c05104065cf1cf70c0c6f1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TriangularMetric.lean @@ -0,0 +1,164 @@ +import Mathlib +import OAI.Analysis.Commutator.RectangularColumn +import OAI.Analysis.Commutator.HilbertPair +import OAI.Analysis.Commutator.GramBounds +import OAI.Analysis.Commutator.FactorMetric + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.RectangularColumn + +open HilbertPair CbFactor + +variable {A K F E : Type*} [CStarAlgebra A] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + [NormedAddCommGroup E] [InnerProductSpace ℂ E] [CompleteSpace E] + +local instance : NormedAddCommGroup (K →L[ℂ] F) := ContinuousLinearMap.toNormedAddCommGroup + +local instance : NormedSpace ℂ (K →L[ℂ] F) := ContinuousLinearMap.toNormedSpace + +variable (σ : A →⋆ₐ[ℂ] (K →L[ℂ] K)) (lam : A →⋆ₐ[ℂ] (F →L[ℂ] F)) + (D : A →L[ℂ] (K →L[ℂ] F)) + +lemma triangular_left (a : A) : + (left F K).toContinuousLinearMap.adjoint.comp (triangularMap σ lam D a)= + (lam a).comp (left F K).toContinuousLinearMap.adjoint+ + (D a).comp (right F K).toContinuousLinearMap.adjoint := by + ext x + simp [left_adjoint,right_adjoint] + +lemma triangular_right (a : A) : + (right F K).toContinuousLinearMap.adjoint.comp (triangularMap σ lam D a)= + (σ a).comp (right F K).toContinuousLinearMap.adjoint := by + ext x + simp [right_adjoint] + +lemma triangular_star_right (a : A) : + (star (triangularMap σ lam D (star a))).comp (right F K).toContinuousLinearMap= + (right F K).toContinuousLinearMap.comp (σ a) := by + have h := congrArg ContinuousLinearMap.adjoint (triangular_right σ lam D (star a)) + simpa only [ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_adjoint, + map_star,ContinuousLinearMap.star_eq_adjoint] using h + +variable (L : E →L[ℂ] SumHilbert F K) (W : SumHilbert F K →L[ℂ] E) + (hLW : L.comp W=1) + (hcov : ∀ a : A,triangularMap σ lam D a*(L.comp L.adjoint)= + (L.comp L.adjoint)*star (triangularMap σ lam D (star a))) + +abbrev lowerFactor := (right F K).toContinuousLinearMap.adjoint.comp L + +abbrev lowerRight := W.comp (right F K).toContinuousLinearMap + +omit [CompleteSpace E] in +include hLW in +lemma lowerFactor_right : (lowerFactor L).comp (lowerRight W)=1 := by + simp only [lowerFactor,lowerRight,ContinuousLinearMap.comp_assoc] + rw [←ContinuousLinearMap.comp_assoc L,hLW] + simp [ContinuousLinearMap.one_def] + +abbrev metricLower := (lowerFactor L).comp (lowerFactor L).adjoint + +abbrev metricUpperRight := (left F K).toContinuousLinearMap.adjoint.comp + ((L.comp L.adjoint).comp (right F K).toContinuousLinearMap) + +lemma metricLower_eq : metricLower L=(right F K).toContinuousLinearMap.adjoint.comp + ((L.comp L.adjoint).comp (right F K).toContinuousLinearMap) := by + simp only [metricLower,lowerFactor,ContinuousLinearMap.adjoint_comp, + ContinuousLinearMap.adjoint_adjoint,ContinuousLinearMap.comp_assoc] + +include hcov in +lemma metricLower_commutes (a : A) : σ a*metricLower L=metricLower L*σ a := by + have h := congrArg (fun T : SumHilbert F K →L[ℂ] SumHilbert F K => + (right F K).toContinuousLinearMap.adjoint.comp (T.comp (right F K).toContinuousLinearMap)) (hcov a) + change _=_ at h + simp only [ContinuousLinearMap.mul_def,←ContinuousLinearMap.comp_assoc, + triangular_right] at h + simpa only [ContinuousLinearMap.comp_assoc,triangular_star_right,metricLower,lowerFactor, + ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_adjoint, + ContinuousLinearMap.mul_def,ContinuousLinearMap.comp_assoc] using h + +include hcov in +lemma metricUpperRight_equation (a : A) : + (lam a).comp (metricUpperRight L)+(D a).comp (metricLower L)= + (metricUpperRight L).comp (σ a) := by + have h := congrArg (fun T : SumHilbert F K →L[ℂ] SumHilbert F K => + (left F K).toContinuousLinearMap.adjoint.comp (T.comp (right F K).toContinuousLinearMap)) (hcov a) + simp only [ContinuousLinearMap.mul_def,←ContinuousLinearMap.comp_assoc, + triangular_left,ContinuousLinearMap.add_comp] at h + simpa only [ContinuousLinearMap.comp_assoc,triangular_star_right,metricLower,lowerFactor, + ContinuousLinearMap.adjoint_comp,ContinuousLinearMap.adjoint_adjoint, + metricUpperRight,ContinuousLinearMap.comp_assoc] using h + +omit [CompleteSpace K] [CompleteSpace F] [CompleteSpace E] in +lemma lowerRight_norm_le {c : ℝ} (hc : 0≤c) (hW : ‖W‖≤c) : ‖lowerRight W‖≤c := by + refine (ContinuousLinearMap.opNorm_comp_le _ _).trans ?_ + exact (mul_le_mul hW (right F K).norm_toContinuousLinearMap_le + (ContinuousLinearMap.opNorm_nonneg _) hc).trans_eq (mul_one c) + +lemma metricUpperRight_norm_le (hL : ‖L‖≤1) : ‖metricUpperRight L‖≤1 := by + have hJ1 : ‖(left F K).toContinuousLinearMap.adjoint‖≤1 := by + simpa using (left F K).norm_toContinuousLinearMap_le + have hJ2 : ‖(right F K).toContinuousLinearMap‖≤1 := (right F K).norm_toContinuousLinearMap_le + have hLa : ‖L.adjoint‖≤1 := by simpa using hL + have hQ : ‖L.comp L.adjoint‖≤1 := + (ContinuousLinearMap.opNorm_comp_le _ _).trans + ((mul_le_mul hL hLa (ContinuousLinearMap.opNorm_nonneg _) zero_le_one).trans_eq (one_mul 1)) + have hQJ : ‖(L.comp L.adjoint).comp (right F K).toContinuousLinearMap‖≤1 := + (ContinuousLinearMap.opNorm_comp_le _ _).trans + ((mul_le_mul hQ hJ2 (ContinuousLinearMap.opNorm_nonneg _) zero_le_one).trans_eq (one_mul 1)) + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + ((mul_le_mul hJ1 hQJ (ContinuousLinearMap.opNorm_nonneg _) zero_le_one).trans_eq (one_mul 1)) + +include hLW hcov in +theorem implementer_of_factor_metric {c : ℝ} (hc : 0≤c) (hL : ‖L‖≤1) (hW : ‖W‖≤c) : + ∃ V : K →L[ℂ] F,‖V‖≤c^2 ∧ ∀ a : A,D a=V.comp (σ a)-(lam a).comp V := by + have hlow := lowerFactor_right L W hLW + have hpos := gram_strictlyPositive (lowerFactor L) (lowerRight W) hlow + let u : (K →L[ℂ] K)ˣ := hpos.isUnit.unit + have hu : (u : K →L[ℂ] K)=metricLower L := hpos.isUnit.unit_spec + have hi : ‖(↑(u⁻¹) : K →L[ℂ] K)‖≤c^2 := + gram_inverse_norm_le (lowerFactor L) (lowerRight W) hlow hc + (lowerRight_norm_le W hc hW) u hu + let V : K →L[ℂ] F := (metricUpperRight L).comp (↑(u⁻¹) : K →L[ℂ] K) + refine ⟨V,?_,?_⟩ + · exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + ((mul_le_mul (metricUpperRight_norm_le L hL) hi + (ContinuousLinearMap.opNorm_nonneg _) zero_le_one).trans_eq (one_mul _)) + · intro a + have hcomm : Commute (σ a) (u : K →L[ℂ] K) := by + rw [hu] + exact metricLower_commutes σ lam D L hcov a + have hinv : (σ a)*(↑(u⁻¹) : K →L[ℂ] K)=(↑(u⁻¹) : K →L[ℂ] K)*(σ a) := + hcomm.units_inv_right.eq + have he := congrArg (fun T : K →L[ℂ] F => T.comp (↑(u⁻¹) : K →L[ℂ] K)) + (metricUpperRight_equation σ lam D L hcov a) + have hcancel : (metricLower L).comp (↑(u⁻¹) : K →L[ℂ] K)=1 := by + rw [←hu] + exact u.mul_inv + rw [ContinuousLinearMap.add_comp, + ContinuousLinearMap.comp_assoc (D a) (metricLower L),hcancel, + ContinuousLinearMap.one_def,ContinuousLinearMap.comp_id] at he + have hh : (σ a).comp (↑(u⁻¹) : K →L[ℂ] K)=(↑(u⁻¹) : K →L[ℂ] K).comp (σ a) := hinv + rw [ContinuousLinearMap.comp_assoc (lam a) (metricUpperRight L), + ContinuousLinearMap.comp_assoc (metricUpperRight L) (σ a),hh, + ←ContinuousLinearMap.comp_assoc (metricUpperRight L)] at he + exact eq_sub_iff_add_eq.mpr (by simpa only [add_comm] using he) + +end Kadison.RectangularColumn + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TwoByTwoPositive.lean b/lean/OAI/Analysis/Commutator/TwoByTwoPositive.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a6fe483312e8910db79661917d3c3b2c2b9728b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TwoByTwoPositive.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Commutator.BalancedDefect + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators ComplexOrder Matrix CStarAlgebra ContinuousFunctionalCalculus + +namespace Kadison.CStarBlock + +variable {A : Type*} + +local instance : DecidableEq (Fin 2) := Classical.decEq (Fin 2) + +def block (a b c d : A) : CStarMatrix (Fin 2) (Fin 2) A := + CStarMatrix.ofMatrix !![a,b;c,d] + +@[simp] lemma block00 (a b c d : A) : block a b c d 0 0=a := rfl + +@[simp] lemma block01 (a b c d : A) : block a b c d 0 1=b := rfl + +@[simp] lemma block10 (a b c d : A) : block a b c d 1 0=c := rfl + +@[simp] lemma block11 (a b c d : A) : block a b c d 1 1=d := rfl + +variable [CStarAlgebra A] + +lemma block_mul (a b c d e f g h : A) : + block a b c d*block e f g h=block (a*e+b*g) (a*f+b*h) (c*e+d*g) (c*f+d*h) := by + ext i j + fin_cases i <;> fin_cases j <;> simp [block,CStarMatrix.mul_apply,Fin.sum_univ_two] + +lemma star_block (a b c d : A) : star (block a b c d)=block (star a) (star c) (star b) (star d) := by + ext i j + fin_cases i <;> fin_cases j <;> rfl + +variable [PartialOrder A] [StarOrderedRing A] + +lemma diagonal_nonneg {ι : Type*} [Fintype ι] [DecidableEq ι] (X : CStarMatrix ι ι A) (hX : 0≤X) (i : ι) : 0≤X i i := by + classical + let : ContinuousFunctionalCalculus ℂ (CStarMatrix ι ι A) IsStarNormal := + IsStarNormal.instContinuousFunctionalCalculus + let : ContinuousFunctionalCalculus ℝ (CStarMatrix ι ι A) IsSelfAdjoint := + IsSelfAdjoint.instContinuousFunctionalCalculus + let : NonnegSpectrumClass ℝ (CStarMatrix ι ι A) := CStarAlgebra.instNonnegSpectrumClass + let R := CFC.sqrt X + have hR : star R*R=X := by rw [(IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg _)).star_eq]; exact CFC.sqrt_mul_sqrt_self X hX + rw [←hR,CStarMatrix.mul_apply] + exact Finset.sum_nonneg (fun j _ => star_mul_self_nonneg (R j i)) + +lemma contraction_block_nonneg (x : A) (hx : ‖x‖≤1) : 0≤block 1 x (star x) 1 := by + have hp : 0≤1-star x*x := by simpa only [star_star] using BalancedDilation.defect_nonneg (star x) (by simpa using hx) + let r := CFC.sqrt (1-star x*x) + have hr : star r=r := (IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg _)).star_eq + have hr2 : r*r=1-star x*x := CFC.sqrt_mul_sqrt_self _ hp + have he : star (block 1 x 0 r)*block 1 x 0 r=block 1 x (star x) 1 := by + rw [star_block,block_mul] + simp [hr,hr2] + rw [←he] + exact star_mul_self_nonneg _ + +lemma contraction_of_block_nonneg (x : A) (hx : 0≤block 1 x (star x) 1) : ‖x‖≤1 := by + let T := block (1:A) (-x) 0 1 + have hp : 0 ≤ star T*block 1 x (star x) 1*T := star_left_conjugate_nonneg hx T + have he : star T*block 1 x (star x) 1*T=block 1 0 0 (1-star x*x) := by + simp [T,star_block,block_mul,sub_eq_add_neg,add_comm] + have hd : 0≤1-star x*x := by simpa only [he,block11] using diagonal_nonneg _ hp 1 + have hn := (CStarAlgebra.norm_le_one_iff_of_nonneg (star x*x) (star_mul_self_nonneg x)).mpr (sub_nonneg.mp hd) + rw [CStarRing.norm_star_mul_self] at hn + nlinarith [norm_nonneg x] + +end Kadison.CStarBlock + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/TwoIsometries.lean b/lean/OAI/Analysis/Commutator/TwoIsometries.lean new file mode 100644 index 0000000000000000000000000000000000000000..d138754f0012ce1a56c9eca5e3163b9f1e5ff3d9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/TwoIsometries.lean @@ -0,0 +1,60 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison + +section Isometries + +variable {A : Type*} [Ring A] [StarRing A] (s t : A) + (hs : star s*s=1) (ht : star t*t=1) (hst : star s*t=0) + +include hs ht hst in +lemma two_isometries_words (n m : ℕ) : + star (s^n*t)*(s^m*t)=if n=m then 1 else 0 := by + classical + have hts : star t*s=0 := by + have he := congrArg star hst + simpa only [star_mul,star_star,star_zero] using he + induction n generalizing m with + | zero => + cases m with + | zero => simpa using ht + | succ m => + simp only [pow_zero,one_mul,pow_succ',Nat.zero_ne_add_one,ite_false] + rw [show star t*(s*s^m*t)=(star t*s)*(s^m*t) by noncomm_ring,hts,zero_mul] + | succ n ih => + cases m with + | zero => + simp only [pow_zero,one_mul,pow_succ',Nat.add_one_ne_zero,ite_false,star_mul] + rw [show star t*(star (s^n)*star s)*t=star t*star (s^n)*(star s*t) by noncomm_ring,hst,mul_zero] + | succ m => + rw [pow_succ',pow_succ',star_mul,star_mul] + rw [show star t*(star (s^n)*star s)*(s*s^m*t)=star (s^n*t)*(star s*s)*(s^m*t) by + rw [star_mul]; noncomm_ring,hs,mul_one,ih] + simp + +include hs ht hst in +theorem two_isometries_finite_family (h : ℕ) : + ∃ v : Fin h → A, ∀ i j, star (v i)*v j=if i=j then 1 else 0 := by + classical + refine ⟨fun i => s^i.val*t,?_⟩ + intro i j + simpa only [Fin.val_inj] using two_isometries_words s t hs ht hst i.val j.val + +end Isometries + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UltrafilterDiagonal.lean b/lean/OAI/Analysis/Commutator/UltrafilterDiagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..a89eea4f31bede86966bd188dcee3b749c842f5a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UltrafilterDiagonal.lean @@ -0,0 +1,46 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology + +open Filter + +namespace Kadison.UltrafilterDiagonal + +theorem depth {l : Filter ℕ} (hl : l≤atTop) (p : ℕ → ℕ → Prop) + (hp : ∀ n, ∀ᶠ i in l, p n i) : + ∃ d : ℕ → ℕ, Tendsto d l atTop ∧ ∀ i j, j ∀ j ∀ j hp j) + filter_upwards [hn,hl (eventually_ge_atTop n)] with i hi hin + exact Nat.le_findGreatest hin hi + +lemma nonprincipal_le_atTop (ω : Ultrafilter ℕ) (hω : ∀ n, ω≠pure n) : + (ω : Filter ℕ)≤atTop := by + rcases ω.le_cofinite_or_eq_pure with h|⟨n,hn⟩ + · exact h.trans_eq Nat.cofinite_eq_atTop + · exact (hω n hn).elim + +end Kadison.UltrafilterDiagonal + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UniformCommutantApproximation.lean b/lean/OAI/Analysis/Commutator/UniformCommutantApproximation.lean new file mode 100644 index 0000000000000000000000000000000000000000..4833dd1e853d0ad9f33c65b6da0d0bf2ce41778a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UniformCommutantApproximation.lean @@ -0,0 +1,40 @@ +import Mathlib +import OAI.Analysis.Commutator.StableUniversalAssembly + +namespace OAI + +noncomputable section + +noncomputable section + +namespace Kadison + +open OperatorAmplification + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem uniform_commutant_approximation (M : VonNeumannAlgebra H) (G : H →L[ℂ] H) : + ∃ T : H →L[ℂ] H, T∈M.commutant ∧ + ‖G-T‖≤9368*commutatorSeminorm M G := by + apply WOTDistance.exists_commutant_approximation M G + (mul_nonneg (by norm_num) (commutatorSeminorm_nonneg M G)) + intro n T hT + cases n with + | zero => + have hT0 : T=0 := Subsingleton.elim _ _ + simp [hT0] + | succ n => + have he : matrixOperator (n+1) (entry (Fin (n+1)) T)=T := by + ext x i + exact (matrixOperator_apply (n+1) (entry (Fin (n+1)) T) x i).trans + (apply_eq_sum_entries (Fin (n+1)) T x i).symm + have hd : diagonal (H:=H) (Fin (n+1)) G=diagonalAmplification (n+1) G := rfl + rw [hd] + simpa only [he] using + CentralSpectral.universal_bound M G (n+1) (Nat.succ_pos n) (entry (Fin (n+1)) T) hT + +end Kadison +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryBoundTransfer.lean b/lean/OAI/Analysis/Commutator/UnitaryBoundTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..2129affa6ee562dd4b54325589ecd217598e31e6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryBoundTransfer.lean @@ -0,0 +1,36 @@ +import Mathlib +import OAI.Analysis.Commutator.UnitaryMainTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.UnitaryTransport + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem bound_of_conjugate_bound (U : H ≃ₗᵢ[ℂ] K) (M : VonNeumannAlgebra H) + (Y : H →L[ℂ] H) (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) (c : ℝ) + (hb : ‖diagonalAmplification h (U.conjStarAlgEquiv Y)* + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))- + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))* + diagonalAmplification h (U.conjStarAlgEquiv Y)‖≤ + c*commutatorSeminorm (algebra U M) (U.conjStarAlgEquiv Y)* + ‖matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))‖) : + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖≤ + c*commutatorSeminorm M Y*‖matrixOperator h X‖ := by + simpa only [matrix_commutator_norm,seminorm,matrix_norm] using hb + +end Kadison.UnitaryTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryCenterTransport.lean b/lean/OAI/Analysis/Commutator/UnitaryCenterTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b7ec168c1dce593a597e17660c9bbe32312f7bf --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryCenterTransport.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.Commutator.CentralCorner +import OAI.Analysis.Commutator.UnitaryMainTransport + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +namespace Kadison.UnitaryTransport + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (U : H ≃ₗᵢ[ℂ] K) (M : VonNeumannAlgebra H) + +lemma mem_center_algebra (a : H →L[ℂ] H) : + U.conjStarAlgEquiv a∈CentralCorner.center (algebra U M) ↔ a∈CentralCorner.center M := by + rw [CentralCorner.mem_center,CentralCorner.mem_center,mem_algebra] + constructor + · rintro ⟨ha,hc⟩ + refine ⟨ha,?_⟩ + intro b hb + apply U.conjStarAlgEquiv.injective + rw [map_mul,map_mul] + exact hc _ ((mem_algebra U M b).mpr hb) + · rintro ⟨ha,hc⟩ + refine ⟨ha,?_⟩ + rintro _ ⟨b,hb,rfl⟩ + change U.conjStarAlgEquiv b*U.conjStarAlgEquiv a=U.conjStarAlgEquiv a*U.conjStarAlgEquiv b + rw [←map_mul,←map_mul,hc b hb] + +lemma center_range (Z : K →L[ℂ] K) (hZ : Z∈CentralCorner.center (algebra U M)) : + ∃ T : H →L[ℂ] H,T∈CentralCorner.center M ∧ U.conjStarAlgEquiv T=Z := by + obtain ⟨T,rfl⟩ := U.conjStarAlgEquiv.surjective Z + exact ⟨T,(mem_center_algebra U M T).mp hZ,rfl⟩ + +end Kadison.UnitaryTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryCommuteNorm.lean b/lean/OAI/Analysis/Commutator/UnitaryCommuteNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..152d8c2f9a3e96bc3a25e6d1ce1971f2d9521d3e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryCommuteNorm.lean @@ -0,0 +1,67 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.UnitaryTransport + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (U : H ≃ₗᵢ[ℂ] K) + +lemma conjugate_inverse (T : K →L[ℂ] K) : + U.conjStarAlgEquiv (U.symm.conjStarAlgEquiv T)=T := by + ext v + simp + +lemma conjugate_commutator (T : K →L[ℂ] K) (a : H →L[ℂ] H) : + U.conjStarAlgEquiv (U.symm.conjStarAlgEquiv T*a-a*U.symm.conjStarAlgEquiv T)= + T*U.conjStarAlgEquiv a-U.conjStarAlgEquiv a*T := by + rw [map_sub,map_mul,map_mul,conjugate_inverse] + +lemma commutator_norm (T : K →L[ℂ] K) (a : H →L[ℂ] H) : + ‖U.symm.conjStarAlgEquiv T*a-a*U.symm.conjStarAlgEquiv T‖= + ‖T*U.conjStarAlgEquiv a-U.conjStarAlgEquiv a*T‖ := by + have : StarHomClass ((H →L[ℂ] H) ≃⋆ₐ[ℂ] (K →L[ℂ] K)) + (H →L[ℂ] H) (K →L[ℂ] K) := + ⟨fun equivalence => equivalence.map_star'⟩ + rw [←conjugate_commutator, + StarAlgEquiv.norm_map (A := H →L[ℂ] H) (B := K →L[ℂ] K) U.conjStarAlgEquiv] + +lemma commutes_iff (T : K →L[ℂ] K) (a : H →L[ℂ] H) : + U.symm.conjStarAlgEquiv T*a=a*U.symm.conjStarAlgEquiv T ↔ + T*U.conjStarAlgEquiv a=U.conjStarAlgEquiv a*T := by + constructor + · intro h + simpa only [map_mul,conjugate_inverse] using congrArg U.conjStarAlgEquiv h + · intro h + apply U.conjStarAlgEquiv.injective + change U.conjStarAlgEquiv (U.symm.conjStarAlgEquiv T*a)= + U.conjStarAlgEquiv (a*U.symm.conjStarAlgEquiv T) + simpa only [map_mul,conjugate_inverse] using h + +lemma commutator_norm_of_conjugates (T b : K →L[ℂ] K) (a : H →L[ℂ] H) + (h : U.conjStarAlgEquiv a=b) : + ‖U.symm.conjStarAlgEquiv T*a-a*U.symm.conjStarAlgEquiv T‖=‖T*b-b*T‖ := by + rw [commutator_norm,h] + +lemma commutes_of_conjugates (T b : K →L[ℂ] K) (a : H →L[ℂ] H) + (h : U.conjStarAlgEquiv a=b) (hc : T*b=b*T) : + U.symm.conjStarAlgEquiv T*a=a*U.symm.conjStarAlgEquiv T := by + rw [commutes_iff,h] + exact hc + +end Kadison.UnitaryTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryDualAction.lean b/lean/OAI/Analysis/Commutator/UnitaryDualAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..069dcc6933d9a71cf5b043a0d7bca7663409e444 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryDualAction.lean @@ -0,0 +1,101 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.UnitaryDualAction + +variable {A : Type*} [CStarAlgebra A] + +lemma weak_ext {f g : WeakDual ℂ A} (h : ∀ a,f a=g a) : f=g := + WeakDual.toStrongDual.injective (ContinuousLinearMap.ext h) + +def act (u : unitary A) (f : WeakDual ℂ A) : WeakDual ℂ A := + StrongDual.toWeakDual (f.toStrongDual.comp (ContinuousLinearMap.mulLeftRight ℂ A (star (u:A)) (u:A))) + +@[simp] lemma act_apply (u : unitary A) (f : WeakDual ℂ A) (a : A) : + act u f a=f (star (u:A)*a*(u:A)) := rfl + +instance action : MulAction (unitary A) (WeakDual ℂ A) where + smul := act + one_smul f := by apply weak_ext; intro a; change f (star (1:A)*a*1)=f a; simp + mul_smul u v f := by + apply weak_ext + intro a + change f (star ((u:A)*(v:A))*a*((u:A)*(v:A)))= + f (star (v:A)*(star (u:A)*a*(u:A))*(v:A)) + simp only [star_mul,mul_assoc] + +@[simp] lemma smul_apply (u : unitary A) (f : WeakDual ℂ A) (a : A) : + (u • f) a=f (star (u:A)*a*(u:A)) := rfl + +instance continuous_action : ContinuousConstSMul (unitary A) (WeakDual ℂ A) where + continuous_const_smul u := WeakDual.continuous_of_continuous_eval + (fun a => WeakDual.eval_continuous (star (u:A)*a*(u:A))) + +lemma conjugate_norm (u : unitary A) (a : A) : + ‖star (u:A)*a*(u:A)‖=‖a‖ := by + rw [CStarRing.norm_mul_coe_unitary] + exact CStarRing.norm_coe_unitary_mul (star u) a + +lemma act_norm_le (u : unitary A) (f : WeakDual ℂ A) : + ‖(u • f).toStrongDual‖≤‖f.toStrongDual‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro a + change ‖f.toStrongDual (star (u:A)*a*(u:A))‖≤‖f.toStrongDual‖*‖a‖ + simpa only [conjugate_norm] using f.toStrongDual.le_opNorm (star (u:A)*a*(u:A)) + +lemma act_norm (u : unitary A) (f : WeakDual ℂ A) : + ‖(u • f).toStrongDual‖=‖f.toStrongDual‖ := by + apply (act_norm_le u f).antisymm + have h := act_norm_le u⁻¹ (u • f) + simpa only [inv_smul_smul] using h + +lemma act_sub (u : unitary A) (f g : WeakDual ℂ A) : u • (f-g)=u • f-u • g := by + apply weak_ext + intro a + rfl + +lemma act_dist (u : unitary A) (f g : WeakDual ℂ A) : + dist (u • f).toStrongDual (u • g).toStrongDual=dist f.toStrongDual g.toStrongDual := by + rw [dist_eq_norm,dist_eq_norm] + have he : (u • f).toStrongDual-(u • g).toStrongDual=(u • (f-g)).toStrongDual := by + rw [act_sub,map_sub] + rw [he,act_norm,map_sub] + +lemma act_linear (u : unitary A) : + ∃ L : WeakDual ℂ A →ₗ[ℝ] WeakDual ℂ A,∀ f,L f=u • f := by + exact ⟨{ toFun := fun f => u • f + map_add' := fun f g => by apply weak_ext; intro a; rfl + map_smul' := fun c f => by apply weak_ext; intro a; rfl },fun _ => rfl⟩ + +theorem trace_of_fixed (f : WeakDual ℂ A) (hf : ∀ u : unitary A,u • f=f) : + ∀ a b : A,f (a*b)=f (b*a) := by + intro a b + let L : A →ₗ[ℂ] ℂ := f.toStrongDual.toLinearMap.comp (LinearMap.mulRight ℂ b) + let R : A →ₗ[ℂ] ℂ := f.toStrongDual.toLinearMap.comp (LinearMap.mulLeft ℂ b) + have hEq : L=R := by + apply LinearMap.ext_on (CStarAlgebra.span_unitary A) + intro v hv + let u : unitary A := ⟨v,hv⟩ + have h := congrArg (fun g : WeakDual ℂ A => g (v*b)) (hf u) + change f (star v*(v*b)*v)=f (v*b) at h + have he : star v*(v*b)*v=b*v := by + rw [←mul_assoc (star v) v b,hv.1,one_mul] + rw [he] at h + exact h.symm + exact congrArg (fun T : A →ₗ[ℂ] ℂ => T a) hEq + +end Kadison.UnitaryDualAction + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryEquivMoments.lean b/lean/OAI/Analysis/Commutator/UnitaryEquivMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..67eee23e4e2a8d2283fa7f48a9c260152dba0110 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryEquivMoments.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeSequenceUnitary + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching FinitePatching.Words FinitePatching.ConjugatedWords + +variable {A B : Type} [CStarAlgebra A] [CStarAlgebra B] + +def pullUnitary (e : A ≃⋆ₐ[ℂ] B) (u : unitary B) : unitary A := + ⟨e.symm u,Unitary.map_mem e.symm.toStarAlgHom u.property⟩ + +lemma map_pullUnitary (e : A ≃⋆ₐ[ℂ] B) (u : unitary B) : + (PartialUnitary.ofUnitary (pullUnitary e u)).map e.toStarAlgHom=PartialUnitary.ofUnitary u := by + rw [PartialUnitary.map_ofUnitary] + congr 1 + apply Subtype.ext + exact e.apply_symm_apply u + +lemma word_pullUnitary {J K : Type} (e : A ≃⋆ₐ[ℂ] B) (u : unitary B) + (x : J → A) (k : K → ℤ) (l : List (Letter J K)) : + e (word x k (PartialUnitary.ofUnitary (pullUnitary e u)) l)= + word (e ∘ x) k (PartialUnitary.ofUnitary u) l := by + rw [show e (word x k (PartialUnitary.ofUnitary (pullUnitary e u)) l)= + word (e ∘ x) k ((PartialUnitary.ofUnitary (pullUnitary e u)).map e.toStarAlgHom) l from + map_word e.toStarAlgHom x k _ l,map_pullUnitary] + +variable [PartialOrder A] [StarOrderedRing A] [PartialOrder B] [StarOrderedRing B] + +lemma pullUnitary_moment_limits (e : A ≃⋆ₐ[ℂ] B) (τ : A →ₚ[ℂ] ℂ) (σ : B →ₚ[ℂ] ℂ) + (htrace : ∀ a,σ (e a)=τ a) (u : ℕ → unitary B) + (hu : ∀ (J : Type) (x : J → B),(∀ j,‖x j‖≤1) → (∀ j,σ (x j)=0) → + ∀ l : List (Letter J Bool),l≠[] → Valid l → + Tendsto (fun n => σ (word x signPower (PartialUnitary.ofUnitary (u n)) l)) atTop (𝓝 0)) : + ∀ (J : Type) (x : J → A),(∀ j,‖x j‖≤1) → (∀ j,τ (x j)=0) → + ∀ l : List (Letter J Bool),l≠[] → Valid l → + Tendsto (fun n => τ (word x signPower (PartialUnitary.ofUnitary (pullUnitary e (u n))) l)) atTop (𝓝 0) := by + intro J x hx hxc l hl hv + have hh := hu J (e ∘ x) (fun j => by simpa only [Function.comp_apply,StarAlgEquiv.norm_map] using hx j) + (fun j => (htrace (x j)).trans (hxc j)) l hl hv + convert hh using 1 + funext n + rw [←htrace,word_pullUnitary] + +section Relative + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M R : VonNeumannAlgebra H) (hRM : R≤M) (e : A ≃⋆ₐ[ℂ] M) (j : R →⋆ₐ[ℂ] A) + (hj : ∀ q,e (j q)=NormalSubalgebra.inclusion M R hRM q) + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + +include hRM hj in +lemma pullUnitary_in_relative_range (u : ℕ → unitary M) + (hu : ∀ n,((u n:M):H →L[ℂ] H)∈R) : + (sequenceUnitary τ ω (fun n => pullUnitary e (u n)) : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω)∈ + Set.range ((leftRestricted τ ω).comp (mapSequence j)) := by + have he : mapSequence j (restrictBoundedUnitary M R u hu)=boundedUnitary (fun n => pullUnitary e (u n)) := by + ext n + apply e.injective + change e (j ⟨u n,hu n⟩)=e (e.symm (u n)) + rw [hj,e.apply_symm_apply] + rfl + exact ⟨restrictBoundedUnitary M R u hu,congrArg (leftRestricted τ ω) he⟩ + +end Relative + +end Kadison.TracialSequence + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryHaar.lean b/lean/OAI/Analysis/Commutator/UnitaryHaar.lean new file mode 100644 index 0000000000000000000000000000000000000000..07ad209bb01214d8dd99af066bcadc791216bf74 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryHaar.lean @@ -0,0 +1,49 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open MeasureTheory MeasureTheory.Measure TopologicalSpace + +namespace Kadison.UnitaryHaar + +variable (A : Type*) [CStarAlgebra A] [FiniteDimensional ℂ A] [Nontrivial A] + +abbrev compactUnitary : CompactSpace (unitary A) := by + let : ProperSpace A := FiniteDimensional.proper ℂ A + apply isCompact_iff_compactSpace.mp + apply (isCompact_closedBall (0:A) 1).of_isClosed_subset isClosed_unitary + intro a ha + simp only [Metric.mem_closedBall,dist_zero_right] + exact (CStarRing.norm_of_mem_unitary ha).le + +variable (G : Type*) [Group G] [TopologicalSpace G] [IsTopologicalGroup G] + [CompactSpace G] [MeasurableSpace G] [BorelSpace G] + +def whole : PositiveCompacts G where + carrier := Set.univ + isCompact' := isCompact_univ + interior_nonempty' := by simp + +def probability : Measure G := haarMeasure (whole G) + +instance : IsProbabilityMeasure (probability G) where + measure_univ := haarMeasure_self + +instance : IsMulLeftInvariant (probability G) := by + dsimp only [probability] + infer_instance + +end Kadison.UnitaryHaar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryMainTransport.lean b/lean/OAI/Analysis/Commutator/UnitaryMainTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..e53e0f8115f0540399592fb1df5b623d3b6a2444 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryMainTransport.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Commutator.CommutatorPerturbation +import OAI.Analysis.Commutator.EquivariantBicommutant + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace BigOperators + +namespace Kadison.UnitaryTransport + +variable {H K : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +variable (U : H ≃ₗᵢ[ℂ] K) + +def algebra (M : VonNeumannAlgebra H) : VonNeumannAlgebra K where + toStarSubalgebra := M.toStarSubalgebra.map U.conjStarAlgEquiv.toStarAlgHom + centralizer_centralizer' := by + change Set.centralizer (Set.centralizer (U.conjStarAlgEquiv.toMulEquiv '' (M : Set (H →L[ℂ] H))))=_ + rw [EquivariantBicommutant.bicommutant_image U.conjStarAlgEquiv.toMulEquiv] + change U.conjStarAlgEquiv.toMulEquiv '' Set.centralizer (Set.centralizer M.carrier)=_ + rw [M.centralizer_centralizer'] + rfl + +@[simp] lemma mem_algebra (M : VonNeumannAlgebra H) (a : H →L[ℂ] H) : + U.conjStarAlgEquiv a∈algebra U M ↔ a∈M := by + change (∃ b,b∈M ∧ U.conjStarAlgEquiv b=U.conjStarAlgEquiv a) ↔ a∈M + constructor + · rintro ⟨b,hb,he⟩ + exact U.conjStarAlgEquiv.injective he ▸ hb + · intro ha; exact ⟨a,ha,rfl⟩ + +lemma conj_norm (a : H →L[ℂ] H) : ‖U.conjStarAlgEquiv a‖=‖a‖ := by + apply le_antisymm + · apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg a) + intro x + simpa only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply,LinearIsometryEquiv.norm_map] + using a.le_opNorm (U.symm x) + · apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + simpa only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply,LinearIsometryEquiv.norm_map, + U.symm_apply_apply] using (U.conjStarAlgEquiv a).le_opNorm (U x) + +lemma seminorm (M : VonNeumannAlgebra H) (Y : H →L[ℂ] H) : + commutatorSeminorm (algebra U M) (U.conjStarAlgEquiv Y)=commutatorSeminorm M Y := by + apply le_antisymm + · apply commutatorSeminorm_le + rintro a ⟨b,hb,rfl⟩ hna + change ‖U.conjStarAlgEquiv Y * U.conjStarAlgEquiv b - + U.conjStarAlgEquiv b * U.conjStarAlgEquiv Y‖ ≤ _ + rw [←map_mul,←map_mul,←map_sub,conj_norm] + change ‖U.conjStarAlgEquiv b‖ ≤ 1 at hna + exact commutator_bound_unitball M Y hb (by simpa only [conj_norm] using hna) + · apply commutatorSeminorm_le + intro a ha hna + have hh := commutator_bound_unitball (algebra U M) (U.conjStarAlgEquiv Y) + ((mem_algebra U M a).mpr ha) (by + rw [conj_norm] + exact hna) + simpa only [←map_mul U.conjStarAlgEquiv,←map_sub U.conjStarAlgEquiv, + conj_norm] using hh + +def copies (h : ℕ) : PiLp 2 (fun _ : Fin h => H) ≃ₗᵢ[ℂ] PiLp 2 (fun _ : Fin h => K) := + LinearIsometryEquiv.piLpCongrRight 2 (fun _ => U) + +omit [CompleteSpace H] [CompleteSpace K] in +@[simp] lemma copies_apply (h : ℕ) (x : PiLp 2 (fun _ : Fin h => H)) (i : Fin h) : + copies U h x i=U (x i) := rfl + +omit [CompleteSpace H] [CompleteSpace K] in +@[simp] lemma copies_symm_apply (h : ℕ) (x : PiLp 2 (fun _ : Fin h => K)) (i : Fin h) : + (copies U h).symm x i=U.symm (x i) := rfl + +lemma diagonal (h : ℕ) (Y : H →L[ℂ] H) : + (copies U h).conjStarAlgEquiv (diagonalAmplification h Y)= + diagonalAmplification h (U.conjStarAlgEquiv Y) := by + ext x i + simp only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply,copies_apply,copies_symm_apply, + diagonalAmplification_apply] + +lemma matrix (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) : + (copies U h).conjStarAlgEquiv (matrixOperator h X)= + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j)) := by + ext x i + simp only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply,copies_apply,copies_symm_apply, + matrixOperator_apply,map_sum] + simpa only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply] using + (matrixOperator_apply h (fun i j => U.conjStarAlgEquiv (X i j)) x i).symm + +lemma matrix_norm (h : ℕ) (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) : + ‖matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))‖=‖matrixOperator h X‖ := by + rw [←matrix,conj_norm] + +lemma matrix_commutator_norm (h : ℕ) (Y : H →L[ℂ] H) + (X : Matrix (Fin h) (Fin h) (H →L[ℂ] H)) : + ‖diagonalAmplification h (U.conjStarAlgEquiv Y)* + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))- + matrixOperator h (fun i j => U.conjStarAlgEquiv (X i j))* + diagonalAmplification h (U.conjStarAlgEquiv Y)‖= + ‖diagonalAmplification h Y*matrixOperator h X-matrixOperator h X*diagonalAmplification h Y‖ := by + rw [←diagonal,←matrix,←map_mul,←map_mul,←map_sub,conj_norm] + +end Kadison.UnitaryTransport + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitaryOrbitHull.lean b/lean/OAI/Analysis/Commutator/UnitaryOrbitHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..6470479a667d3990ff78ecb7e5eb86305de8d5c7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitaryOrbitHull.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteDimensionalAverage + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace + +namespace Kadison.UnitaryOrbit + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) + +def conjugate (v : unitary M) (Y : H →L[ℂ] H) : H →L[ℂ] H := + ((v:M):H →L[ℂ] H)*Y*star ((v:M):H →L[ℂ] H) + +def conjugateLinear (v : unitary M) : (H →L[ℂ] H) →ₗ[ℝ] (H →L[ℂ] H) where + toFun := conjugate M v + map_add' _ _ := by simp [conjugate,mul_add,add_mul] + map_smul' _ _ := by simp [conjugate] + +def hull (Y : H →L[ℂ] H) : Set (H →L[ℂ] H) := + convexHull ℝ (Set.range (fun v : unitary M => conjugate M v Y)) + +lemma hull_self (Y : H →L[ℂ] H) : Y∈hull M Y := by + apply subset_convexHull + exact ⟨1,by simp [conjugate]⟩ + +lemma conjugate_mul (v w : unitary M) (Y : H →L[ℂ] H) : + conjugate M v (conjugate M w Y)=conjugate M (v*w) Y := by + change ((v:M):H →L[ℂ] H)*(((w:M):H →L[ℂ] H)*Y*star ((w:M):H →L[ℂ] H))* + star ((v:M):H →L[ℂ] H)= + (((v:M):H →L[ℂ] H)*((w:M):H →L[ℂ] H))*Y* + star (((v:M):H →L[ℂ] H)*((w:M):H →L[ℂ] H)) + simp only [star_mul,mul_assoc] + +lemma conjugate_mem_hull (v : unitary M) {T Y : H →L[ℂ] H} (hT : T∈hull M Y) : + conjugate M v T∈hull M Y := by + have him : conjugateLinear M v '' (Set.range (fun w : unitary M => conjugate M w Y)) ⊆ + Set.range (fun w : unitary M => conjugate M w Y) := by + rintro _ ⟨_,⟨w,rfl⟩,rfl⟩ + exact ⟨v*w,(conjugate_mul M v w Y).symm⟩ + have hc := convexHull_mono (𝕜 := ℝ) him + rw [← LinearMap.image_convexHull] at hc + exact hc ⟨T,hT,rfl⟩ + +lemma hull_distance {Y T : H →L[ℂ] H} (hT : T∈hull M Y) : + ‖T-Y‖≤commutatorSeminorm M Y := by + have hs : Set.range (fun v : unitary M => conjugate M v Y) ⊆ + Metric.closedBall Y (commutatorSeminorm M Y) := by + rintro _ ⟨v,rfl⟩ + rw [Metric.mem_closedBall,dist_eq_norm] + exact unitary_conjugate_distance M Y v + simpa only [Metric.mem_closedBall,dist_eq_norm] using + (convexHull_min hs (convex_closedBall Y _) hT) + +lemma hull_norm {Y T : H →L[ℂ] H} (hT : T∈hull M Y) : + ‖T‖≤commutatorSeminorm M Y+‖Y‖ := by + calc + ‖T‖=‖T-Y+Y‖ := by rw [sub_add_cancel] + _≤‖T-Y‖+‖Y‖ := norm_add_le _ _ + _≤commutatorSeminorm M Y+‖Y‖ := by linarith [hull_distance M hT] + +lemma midpoint_mem {Y T V : H →L[ℂ] H} (hT : T∈hull M Y) (hV : V∈hull M Y) : + (1/2:ℝ) • T+(1/2:ℝ) • V∈hull M Y := + convex_convexHull ℝ _ hT hV (by norm_num) (by norm_num) (by norm_num) + +end Kadison.UnitaryOrbit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UnitarySequence.lean b/lean/OAI/Analysis/Commutator/UnitarySequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..4217e06bd946c39c73aff213c0a424798b6bcec7 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UnitarySequence.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.Commutator.TracialDoubleCompression +import OAI.Analysis.Commutator.PartialUnitaryHom + +namespace OAI + +open Lean in +run_cmd modifyEnv fun env => + let env := Lean.LibrarySuggestions.nameDenyListExt.addEntry env "trace_sequence_power" + Lean.LibrarySuggestions.nameDenyListExt.addEntry env "trace_sequence_word" + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Topology BoundedContinuousFunction + +open Filter + +namespace Kadison.TracialSequence + +open FinitePatching FinitePatching.Words + +variable {A : Type} [CStarAlgebra A] + +local instance unitarySequenceOrder : PartialOrder (ℕ →ᵇ A) := CStarAlgebra.spectralOrder _ + +local instance unitarySequenceStarOrderedRing : StarOrderedRing (ℕ →ᵇ A) := + CStarAlgebra.spectralOrderedRing _ + +def boundedUnitary (u : ℕ → unitary A) : unitary (ℕ →ᵇ A) := + ⟨BoundedContinuousFunction.ofNormedAddCommGroupDiscrete (fun n => (u n:A)) 1 + (fun n => (PartialUnitary.ofUnitary (u n)).norm_le_one),by + constructor <;> ext n + · exact (u n).property.1 + · exact (u n).property.2⟩ + +@[simp] lemma boundedUnitary_apply (u : ℕ → unitary A) (n : ℕ) : + ((boundedUnitary u : ℕ →ᵇ A) n)=(u n:A) := rfl + +def evalSequence (n : ℕ) : (ℕ →ᵇ A) →⋆ₐ[ℂ] A where + toFun a := a n + map_one' := rfl + map_mul' _ _ := rfl + map_zero' := rfl + map_add' _ _ := rfl + commutes' _ := rfl + map_star' _ := rfl + +lemma eval_partialUnitary (u : ℕ → unitary A) (n : ℕ) : + (PartialUnitary.ofUnitary (boundedUnitary u)).map (evalSequence n)= + PartialUnitary.ofUnitary (u n) := PartialUnitary.ext rfl + +lemma eval_power (u : ℕ → unitary A) (k : ℤ) (n : ℕ) : + ((PartialUnitary.ofUnitary (boundedUnitary u)).power k) n= + (PartialUnitary.ofUnitary (u n)).power k := by + change evalSequence n _=_ + rw [PartialUnitary.map_power,eval_partialUnitary] + +lemma eval_word {J K : Type*} (u : ℕ → unitary A) (x : J → A) (k : K → ℤ) + (l : List (Letter J K)) (n : ℕ) : + (word (constantSequence ∘ x) k (PartialUnitary.ofUnitary (boundedUnitary u)) l) n= + word x k (PartialUnitary.ofUnitary (u n)) l := by + change evalSequence n _=_ + rw [map_word,eval_partialUnitary] + rfl + +def sequenceUnitary {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (u : ℕ → unitary A) : + unitary (boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) := + ⟨leftRestricted τ ω (boundedUnitary u),Unitary.map_mem (leftRestricted τ ω) (boundedUnitary u).property⟩ + +private lemma sequence_partial_map {A : Type} [CStarAlgebra A] + [PartialOrder A] [StarOrderedRing A] (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (u : ℕ → unitary A) : + PartialUnitary.map (B := boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω) + (by exact leftRestricted τ ω) (PartialUnitary.ofUnitary (boundedUnitary u)) = + PartialUnitary.ofUnitary (by exact sequenceUnitary τ ω u) := by + apply PartialUnitary.ext + rfl + +private lemma trace_left_zero_of_tendsto {A : Type} [CStarAlgebra A] + [PartialOrder A] [StarOrderedRing A] (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hω : (ω : Filter ℕ) ≤ atTop) (a : ℕ →ᵇ A) + (hlim : Tendsto (fun n => τ (a n)) atTop (𝓝 0)) : + sequenceTrace τ ω (leftRestricted τ ω a) = 0 := + tendsto_nhds_unique (tendsto_trace τ ω a) (hlim.mono_left hω) + +private lemma sequence_power_map {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (u : ℕ → unitary A) (k : ℤ) : + leftRestricted τ ω ((PartialUnitary.ofUnitary (boundedUnitary u)).power k) = + (PartialUnitary.ofUnitary (by exact sequenceUnitary τ ω u)).power k := by + cases k with + | ofNat n => + cases n with + | zero => exact map_one (leftRestricted τ ω) + | succ n => + change leftRestricted τ ω ((boundedUnitary u : ℕ →ᵇ A) ^ (n + 1)) = + (leftRestricted τ ω (boundedUnitary u)) ^ (n + 1) + exact map_pow (leftRestricted τ ω) (boundedUnitary u : ℕ →ᵇ A) (n + 1) + | negSucc n => + change leftRestricted τ ω (star (boundedUnitary u : ℕ →ᵇ A) ^ (n + 1)) = + (star (leftRestricted τ ω (boundedUnitary u))) ^ (n + 1) + exact (map_pow (leftRestricted τ ω) (star (boundedUnitary u : ℕ →ᵇ A)) (n + 1)).trans + (congrArg (fun a : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => a ^ (n + 1)) + (map_star (leftRestricted τ ω) (boundedUnitary u : ℕ →ᵇ A))) + +private lemma sequence_word_map {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) (u : ℕ → unitary A) + {J K : Type*} (x : J → A) (k : K → ℤ) (l : List (Letter J K)) : + leftRestricted τ ω (word (constantSequence ∘ x) k (PartialUnitary.ofUnitary (boundedUnitary u)) l) = + word (((leftRestricted τ ω).comp constantSequence) ∘ x) k + (PartialUnitary.ofUnitary (by exact sequenceUnitary τ ω u)) l := by + have hs (s : Slot K) : + leftRestricted τ ω (slotPower k (PartialUnitary.ofUnitary (boundedUnitary u)) s) = + slotPower k (PartialUnitary.ofUnitary (by exact sequenceUnitary τ ω u)) s := by + cases s with + | none => exact map_one (leftRestricted τ ω) + | some s => + cases s with + | none => exact map_one (leftRestricted τ ω) + | some i => exact sequence_power_map τ ω u (k i) + have hl (i : Letter J K) : + leftRestricted τ ω (letter (constantSequence ∘ x) k + (PartialUnitary.ofUnitary (boundedUnitary u)) i) = + letter (((leftRestricted τ ω).comp constantSequence) ∘ x) k + (PartialUnitary.ofUnitary (by exact sequenceUnitary τ ω u)) i := by + exact (map_mul (leftRestricted τ ω) (constantSequence (x i.1)) + (slotPower k (PartialUnitary.ofUnitary (boundedUnitary u)) i.2)).trans + (congrArg (fun a : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + leftRestricted τ ω (constantSequence (x i.1)) * a) (hs i.2)) + induction l with + | nil => exact map_one (leftRestricted τ ω) + | cons i l ih => + exact (map_mul (leftRestricted τ ω) + (letter (constantSequence ∘ x) k (PartialUnitary.ofUnitary (boundedUnitary u)) i) + (word (constantSequence ∘ x) k (PartialUnitary.ofUnitary (boundedUnitary u)) l)).trans + (congrArg₂ (fun a b : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => a * b) + (hl i) ih) + +lemma trace_sequence_power {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + (hω : (ω : Filter ℕ)≤atTop) (u : ℕ → unitary A) (k : ℤ) + (hlim : Tendsto (fun n => τ ((PartialUnitary.ofUnitary (u n)).power k)) atTop (𝓝 0)) : + sequenceTrace τ ω ((PartialUnitary.ofUnitary + (by exact sequenceUnitary τ ω u)).power k)=0 := by + have hz := trace_left_zero_of_tendsto τ ω hω + ((PartialUnitary.ofUnitary (boundedUnitary u)).power k) + (Filter.Tendsto.congr (fun n => congrArg τ (eval_power u k n).symm) hlim) + have he := sequence_power_map τ ω u k + exact (congrArg (fun T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + sequenceTrace τ ω T) he).symm.trans hz + +lemma trace_sequence_word {A : Type} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (ω : Ultrafilter ℕ) + {J K : Type*} (hω : (ω : Filter ℕ)≤atTop) (u : ℕ → unitary A) + (x : J → A) (k : K → ℤ) (l : List (Letter J K)) + (hlim : Tendsto (fun n => τ (word x k (PartialUnitary.ofUnitary (u n)) l)) atTop (𝓝 0)) : + sequenceTrace τ ω (word (((leftRestricted τ ω).comp constantSequence) ∘ x) k + (PartialUnitary.ofUnitary + (by exact sequenceUnitary τ ω u)) l)=0 := by + have hz := trace_left_zero_of_tendsto τ ω hω + (word (constantSequence ∘ x) k (PartialUnitary.ofUnitary (boundedUnitary u)) l) + (Filter.Tendsto.congr (fun n => congrArg τ (eval_word u x k l n).symm) hlim) + have he := sequence_word_map τ ω u x k l + exact (congrArg (fun T : boundedSubspace τ ω →L[ℂ] boundedSubspace τ ω => + sequenceTrace τ ω T) he).symm.trans hz + +end Kadison.TracialSequence + +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/UniversalMain.lean b/lean/OAI/Analysis/Commutator/UniversalMain.lean new file mode 100644 index 0000000000000000000000000000000000000000..bbcf4768296a8e159f81e1c2ff3ecf44cedb6e3a --- /dev/null +++ b/lean/OAI/Analysis/Commutator/UniversalMain.lean @@ -0,0 +1,35 @@ +import Mathlib +import OAI.Analysis.Commutator.StableUniversalAssembly + +namespace OAI + +noncomputable section + +section + +noncomputable section + +universe u + +namespace Kadison + +theorem uniform_commutator : + ∃ C : ℝ, 0 ≤ C ∧ ∀ (K : Type u) [NormedAddCommGroup K] [InnerProductSpace ℂ K] + [CompleteSpace K] (P : VonNeumannAlgebra K) (Y : K →L[ℂ] K) + (h : ℕ), 1 ≤ h → ∀ (X : Matrix (Fin h) (Fin h) (K →L[ℂ] K)), + (∀ i j, X i j ∈ P) → + ‖diagonalAmplification h Y * matrixOperator h X - + matrixOperator h X * diagonalAmplification h Y‖ ≤ + C * commutatorSeminorm P Y * ‖matrixOperator h X‖ := by + refine ⟨9368,by norm_num,?_⟩ + intro K _ _ _ P Y h hh X hX + exact CentralSpectral.universal_bound P Y h hh X hX + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/VectorFreeGeneration.lean b/lean/OAI/Analysis/Commutator/VectorFreeGeneration.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f44c7d86d6f047fab6b73cec3ae2f69a62fddda --- /dev/null +++ b/lean/OAI/Analysis/Commutator/VectorFreeGeneration.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Commutator.GNSCornerTransport +import OAI.Analysis.Commutator.NormalGNSClosure +import OAI.Analysis.Commutator.NormalFreeCorner + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder InnerProductSpace + +namespace Kadison.VectorGNS + +open FreeWordTensor FreeWordAction FreeBlocks + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (M : VonNeumannAlgebra H) (ξ : H) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + +abbrev inclusion (D : VonNeumannAlgebra H) (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) : + D →⋆ₐ[ℂ] M := StarSubalgebra.inclusion hDM + +lemma inclusion_injective (D : VonNeumannAlgebra H) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) : + Function.Injective (inclusion M D hDM) := StarSubalgebra.inclusion_injective hDM + +lemma factorTrace_inclusion (D : VonNeumannAlgebra H) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) : + factorTrace (vectorState M ξ hfaith hone) (inclusion M D hDM) + (inclusion_injective M D hDM)=subalgebraTrace D ξ := by + ext a + rfl + +lemma factorTrace_inclusion_normal (D : VonNeumannAlgebra H) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) : + NormalGNS.BoundedWOTContinuous D + (factorTrace (vectorState M ξ hfaith hone) (inclusion M D hDM) + (inclusion_injective M D hDM)) := by + rw [factorTrace_inclusion] + exact subalgebraTrace_normal D ξ + +theorem gns_generation (R : Bool → StarSubalgebra ℂ M) + (hgen : ∀ a : M,(a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer + (((iSup R).map M.toStarSubalgebra.subtype) : Set (H →L[ℂ] H)))) (a : M) : + (subalgebraTrace M ξ).gnsStarAlgHom a∈Set.centralizer (Set.centralizer + (generatedOperators (vectorState M ξ hfaith hone) R : Set _)) := by + let t := vectorState M ξ hfaith hone + let S := (iSup R).map M.toStarSubalgebra.subtype + let N := ambientVonNeumann t R + have hSM : S≤M.toStarSubalgebra := by + rintro x ⟨b,_,rfl⟩ + exact b.property + have hSN (b : M) (hb : (b:H →L[ℂ] H)∈S) : + (subalgebraTrace M ξ).gnsStarAlgHom b∈N := by + obtain ⟨c,hc,hcb⟩ := hb + have he : c=b := Subtype.ext hcb + subst c + exact (mem_ambientOperators t R).mpr (Set.subset_centralizer_centralizer ⟨b,hc,rfl⟩) + exact (mem_ambientOperators t R).mp + (NormalGNS.image_bicommutant_general M (subalgebraTrace M ξ) + (subalgebraTrace_normal M ξ) S hSM N hSN a (hgen a)) + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/VectorFreeOriginalBound.lean b/lean/OAI/Analysis/Commutator/VectorFreeOriginalBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..227e10641a7f7ef0281abe166cadef404b4ccfab --- /dev/null +++ b/lean/OAI/Analysis/Commutator/VectorFreeOriginalBound.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.FreeOriginalBound +import OAI.Analysis.Commutator.RepresentedCornerBound +import OAI.Analysis.Commutator.VectorStageGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped InnerProductSpace ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.VectorGNS + +open FreeWordTensor FreeWordAction FreeMoments FreeBlocks + +variable {H B : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + +variable (M : VonNeumannAlgebra H) (ξ : H) + (htr : ∀ a b : M,subalgebraTrace M ξ (a*b)=subalgebraTrace M ξ (b*a)) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + +variable (D : VonNeumannAlgebra H) (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + (R : Bool → StarSubalgebra ℂ M) (hR : R false=(inclusion M D hDM).range) + (hfree : Free R (subalgebraTrace M ξ).toLinearMap) + (hgen : ∀ a : M,(a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer + (((iSup R).map M.toStarSubalgebra.subtype) : Set (H →L[ℂ] H)))) + +variable (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] [∀ n,Nonempty (I n)] + (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + (inc : ∀ {n m : ℕ},n ≤ m → Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] Matrix (I m) (I m) ℂ) + (hinc : ∀ n m (h : n ≤ m) a,φ m (inc h a)=φ n a) + (hsize : ∀ n q : ℕ,∃ m,n ≤ m ∧ q ≤ Fintype.card (I m)) + (hDgen : GeneratedByStages D ξ I φ) + +include htr hR hfree hgen hinc hsize hDgen in +theorem free_original_bound + (hdiffuse : DiffuseProjection.HasNoMinimalProjections D) + (τ : B →ₚ[ℂ] ℂ) (j : B →⋆ₐ[ℂ] M) (htrace : ∀ a,τ a=subalgebraTrace M ξ (j a)) + (hj : ∀ a : B,j a∈R true) + (U : H →L[ℂ] H) (T : τ.GNS →L[ℂ] τ.GNS) + (hGT : ∀ x,subalgebraCompression M ξ U + (originalEmbedding τ (vectorState M ξ hfaith hone) j htrace x)= + originalEmbedding τ (vectorState M ξ hfaith hone) j htrace (T x)) + (hGD : ∀ d : D,U*(d:H →L[ℂ] H)=(d:H →L[ℂ] H)*U) + (s : unitary B) (hs0 : τ (s:B)=0) (hs2 : (s:B)*(s:B)=1) + {c β : ℝ} (hc : 0≤c) (hβ : 0<β) (hβ1 : β≤1) + (hC : CornerCommutatorBound M ξ hfaith hone (inclusion M D hDM) R U c (β:ℂ)) : + ‖T*τ.gnsStarAlgHom (s:B)-τ.gnsStarAlgHom (s:B)*T‖≤1040*c := + normal_free_original_bound D (vectorState M ξ hfaith hone) htr + (inclusion M D hDM) (inclusion_injective M D hDM) R hR hfree + (gns_generation M ξ hfaith hone R hgen) I φ inc hinc hsize + (factorTrace_generated D ξ I φ M hfaith hone hDM hDgen) + (factorTrace_inclusion_normal M ξ hfaith hone D hDM) hdiffuse + τ j htrace hj (subalgebraCompression M ξ U) T hGT (fun d => commutes M ξ U (inclusion M D hDM d) (hGD d)) s hs0 hs2 c β hc hβ hβ1 hC + +include htr hR hfree hgen hinc hsize hDgen in +theorem free_original_bound_represented + (hdiffuse : DiffuseProjection.HasNoMinimalProjections D) + (τ : B →ₚ[ℂ] ℂ) (j : B →⋆ₐ[ℂ] M) (htrace : ∀ a,τ a=subalgebraTrace M ξ (j a)) + (hj : ∀ a : B,j a∈R true) + (U : H →L[ℂ] H) (T : τ.GNS →L[ℂ] τ.GNS) + (hGT : ∀ x,subalgebraCompression M ξ U + (originalEmbedding τ (vectorState M ξ hfaith hone) j htrace x)= + originalEmbedding τ (vectorState M ξ hfaith hone) j htrace (T x)) + (hGD : ∀ d : D,U*(d:H →L[ℂ] H)=(d:H →L[ℂ] H)*U) + (s : unitary B) (hs0 : τ (s:B)=0) (hs2 : (s:B)*(s:B)=1) + {c β : ℝ} (hc : 0≤c) (hβ : 0<β) (hβ1 : β≤1) + (hC : RepresentedCornerBound M ξ D U c (β:ℂ)) : + ‖T*τ.gnsStarAlgHom (s:B)-τ.gnsStarAlgHom (s:B)*T‖≤1040*c := + free_original_bound M ξ htr hfaith hone D hDM R hR hfree hgen I φ inc hinc + hsize hDgen hdiffuse τ j htrace hj U T hGT hGD s hs0 hs2 hc hβ hβ1 + (represented_corner_bound M ξ htr hfaith hone D hDM R U c (β:ℂ) hC) + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/VectorStageGeneration.lean b/lean/OAI/Analysis/Commutator/VectorStageGeneration.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc81b3951e9e488565d99d5076257379b7c14af6 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/VectorStageGeneration.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Commutator.MatrixStageGNSGeneration +import OAI.Analysis.Commutator.VectorFreeGeneration + +namespace OAI + +noncomputable section + +section + +noncomputable section + +attribute [-instance] NonUnitalStarSubalgebra.nonUnitalCStarAlgebra + +open scoped ComplexOrder Matrix.Norms.L2Operator + +namespace Kadison.VectorGNS + +open FreeWordTensor FreeBlocks + +variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable (D : VonNeumannAlgebra H) (ξ : H) + (I : ℕ → Type*) [∀ n,Fintype (I n)] [∀ n,DecidableEq (I n)] + (φ : ∀ n,Matrix (I n) (I n) ℂ →⋆ₐ[ℂ] D) + +def GeneratedByStages : Prop := ∀ a : D,(subalgebraTrace D ξ).gnsStarAlgHom a∈ + Set.centralizer (Set.centralizer (TracialGNS.stageAlgebra (subalgebraTrace D ξ) I φ : Set _)) + +lemma generatedByStages_of_represented + (hgen : ∀ a : D,(a:H →L[ℂ] H)∈Set.centralizer (Set.centralizer + (NormalGNS.representedStages D I φ : Set (H →L[ℂ] H)))) : + GeneratedByStages D ξ I φ := fun a => + NormalGNS.matrix_stages_gns D (subalgebraTrace D ξ) (subalgebraTrace_normal D ξ) I φ a (hgen a) + +variable (M : VonNeumannAlgebra H) + (hfaith : ∀ a : M,subalgebraTrace M ξ (star a*a)=0 → a=0) + (hone : subalgebraTrace M ξ 1=1) + (hDM : D.toStarSubalgebra≤M.toStarSubalgebra) + +lemma factorTrace_generated (hgen : GeneratedByStages D ξ I φ) : + ∀ a : D,(factorTrace (vectorState M ξ hfaith hone) (inclusion M D hDM) + (inclusion_injective M D hDM)).gnsStarAlgHom a∈Set.centralizer (Set.centralizer + (TracialGNS.stageAlgebra (factorTrace (vectorState M ξ hfaith hone) (inclusion M D hDM) + (inclusion_injective M D hDM)) I φ : Set _)) := by + rw [factorTrace_inclusion] + exact hgen + +end Kadison.VectorGNS + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/VonNeumannCStar.lean b/lean/OAI/Analysis/Commutator/VonNeumannCStar.lean new file mode 100644 index 0000000000000000000000000000000000000000..84c2a7695d85fba1b89c16123d3af6c5e1a70124 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/VonNeumannCStar.lean @@ -0,0 +1,51 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +namespace Kadison.VonNeumannCStar + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +instance isClosed (M : VonNeumannAlgebra H) : IsClosed (M : Set (H →L[ℂ] H)) := by + change IsClosed M.carrier + rw [←M.centralizer_centralizer'] + exact Set.isClosed_centralizer _ + +instance smulMemClass : SMulMemClass (VonNeumannAlgebra H) ℂ (H →L[ℂ] H) where + smul_mem {s} c _ hx := s.toStarSubalgebra.smul_mem hx c + +instance cstarAlgebra (M : VonNeumannAlgebra H) : CStarAlgebra M := + StarSubalgebra.cstarAlgebra M + +lemma sqrt_mem (M : VonNeumannAlgebra H) {T : H →L[ℂ] H} (hT : T∈M) : CFC.sqrt T∈M := by + change CFC.sqrt T∈M.carrier + rw [←M.centralizer_centralizer'] + intro B hB + exact ((show Commute T B from hB T hT).cfcₙ_nnreal NNReal.sqrt).eq.symm + +instance starOrderedRing (M : VonNeumannAlgebra H) : StarOrderedRing M := + StarOrderedRing.of_nonneg_iff' (fun {x y} h z => (show (z : H →L[ℂ] H)+(x : H →L[ℂ] H)≤(z : H →L[ℂ] H)+(y : H →L[ℂ] H) from add_le_add_right (show (x : H →L[ℂ] H)≤(y : H →L[ℂ] H) from h) _)) (by + intro T + constructor + · intro hT + refine ⟨⟨CFC.sqrt (T : H →L[ℂ] H),sqrt_mem M T.property⟩,?_⟩ + apply Subtype.ext + change (T : H →L[ℂ] H)=star (CFC.sqrt (T : H →L[ℂ] H))*CFC.sqrt (T : H →L[ℂ] H) + rw [(CFC.sqrt_nonneg (T : H →L[ℂ] H)).star_eq,CFC.sqrt_mul_sqrt_self (T : H →L[ℂ] H) hT] + · rintro ⟨S,rfl⟩ + exact (star_mul_self_nonneg (S : H →L[ℂ] H))) + +end Kadison.VonNeumannCStar + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WOTBallSeparable.lean b/lean/OAI/Analysis/Commutator/WOTBallSeparable.lean new file mode 100644 index 0000000000000000000000000000000000000000..c960ea12c7a6aabed281b654036ff238b2ae71e1 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WOTBallSeparable.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Commutator.WOTCompact + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology + +open ContinuousLinearMapWOT + +namespace Kadison.WOTDistance + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma isClosed_vonNeumann (M : VonNeumannAlgebra H) : + IsClosed {T : H →WOT[ℂ] H | T.toCLM∈M} := by + have he : {T : H →WOT[ℂ] H | T.toCLM∈M}= + (commutant (Set.centralizer (M : Set (H →L[ℂ] H))) : Set (H →WOT[ℂ] H)) := by + ext T + change T.toCLM∈M.carrier ↔ ∀ a∈Set.centralizer (M : Set (H →L[ℂ] H)),ofCLM a*T=T*ofCLM a + rw [←M.centralizer_centralizer'] + constructor + · intro h a ha + exact congrArg ofCLM (h a ha) + · intro h a ha + exact congrArg toCLM (h a ha) + rw [he] + exact isClosed_commutant _ + +abbrev AlgebraBall (M : VonNeumannAlgebra H) (C : ℝ) := + {T : H →WOT[ℂ] H // T.toCLM∈M ∧ ‖T.toCLM‖≤C} + +lemma compact_algebraBall (M : VonNeumannAlgebra H) {C : ℝ} (hC : 0≤C) : + CompactSpace (AlgebraBall M C) := by + apply isCompact_iff_compactSpace.mp + exact (isCompact_normBall hC).inter_left (isClosed_vonNeumann M) + +theorem secondCountable_algebraBall [TopologicalSpace.SeparableSpace H] + (M : VonNeumannAlgebra H) {C : ℝ} (hC : 0≤C) : + SecondCountableTopology (AlgebraBall M C) := by + classical + let : CompactSpace (AlgebraBall M C) := compact_algebraBall M hC + obtain ⟨v,hv⟩ := TopologicalSpace.exists_dense_seq H + let f : AlgebraBall M C → (ℕ×ℕ → ℂ) := fun T ij => inner ℂ (v ij.1) (T.val (v ij.2)) + have hf : Continuous f := by + apply continuous_pi + intro ij + exact ContinuousLinearMapWOT.continuous_inner_apply continuous_subtype_val _ _ + have hi : Function.Injective f := by + intro T S he + apply Subtype.ext + apply ContinuousLinearMapWOT.toCLM_injective + apply ContinuousLinearMap.ext + intro x + have hcoeff (n m : ℕ) : inner ℂ (v n) (T.val.toCLM (v m))= + inner ℂ (v n) (S.val.toCLM (v m)) := congrFun he (n,m) + have hx (m : ℕ) : T.val.toCLM (v m)=S.val.toCLM (v m) := + hv.eq_of_inner_right ℂ (fun n => hcoeff n m) + exact hv.induction_on x (isClosed_eq T.val.toCLM.continuous S.val.toCLM.continuous) hx + exact (hf.isClosedEmbedding hi).isEmbedding.secondCountableTopology + +end Kadison.WOTDistance + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WOTCompact.lean b/lean/OAI/Analysis/Commutator/WOTCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..2abfb034a13214d870aa35fa6eb8b7f0fb7e99df --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WOTCompact.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace Pointwise + +open Filter ContinuousLinearMapWOT + +namespace Kadison.WOTDistance + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def normBall (C : ℝ) : Set (H →WOT[ℂ] H) := {T | ‖T.toCLM‖≤C} + +lemma isCompact_normBall {C : ℝ} (hC : 0≤C) : IsCompact (normBall (H:=H) C) := by + classical + apply isCompact_iff_ultrafilter_le_nhds.mpr + intro ω hω + let T : (H →WOT[ℂ] H) → H →L[ℂ] H := fun U => if ‖U.toCLM‖≤C then U.toCLM else 0 + have hT : ∀ U, ‖T U‖≤C := by + intro U + dsimp [T] + split_ifs with h + · exact h + · simpa using hC + obtain ⟨V,hV,hlim⟩ := WeakOperatorLimit.exists_ultralimit ω T C hC hT + refine ⟨ofCLM V,hV,?_⟩ + apply (tendsto_iff_forall_inner_apply_tendsto (f:=id)).mpr + intro x y + have hh : Tendsto (fun U => inner ℂ y (T U x)) (ω : Filter (H →WOT[ℂ] H)) + (𝓝 (inner ℂ y (V x))) := by + simpa only [RCLike.star_def,inner_conj_symm] using (hlim x y).star + apply hh.congr' + filter_upwards [Filter.le_principal_iff.mp hω] with U hU + change inner ℂ y (T U x)=inner ℂ y (U x) + change ‖U.toCLM‖≤C at hU + dsimp [T] + rw [ite_eq_left hU] + rfl + +lemma isClosed_normBall {C : ℝ} (hC : 0≤C) : IsClosed (normBall (H:=H) C) := + (isCompact_normBall hC).isClosed + +omit [CompleteSpace H] in +lemma convex_normBall (C : ℝ) : Convex ℝ (normBall (H:=H) C) := by + intro x hx y hy a b ha hb hab + change ‖a • x.toCLM+b • y.toCLM‖≤C + calc + _ ≤ ‖a • x.toCLM‖+‖b • y.toCLM‖ := norm_add_le _ _ + _ = a*‖x.toCLM‖+b*‖y.toCLM‖ := by simp [norm_smul,abs_of_nonneg ha,abs_of_nonneg hb] + _ ≤ a*C+b*C := add_le_add (mul_le_mul_of_nonneg_left hx ha) (mul_le_mul_of_nonneg_left hy hb) + _ = C := by rw [←add_mul,hab,one_mul] + +def commutant (S : Set (H →L[ℂ] H)) : Submodule ℂ (H →WOT[ℂ] H) where + carrier := {T | ∀ a∈S, ofCLM a*T=T*ofCLM a} + zero_mem' := by simp + add_mem' := by intro x y hx hy a ha; simp [mul_add,add_mul,hx a ha,hy a ha] + smul_mem' := by + intro z x hx a ha + apply toCLM_injective + change a*(z • x.toCLM)=(z • x.toCLM)*a + have hh : a*x.toCLM=x.toCLM*a := congrArg toCLM (hx a ha) + rw [mul_smul_comm,smul_mul_assoc,hh] + +omit [CompleteSpace H] in +lemma isClosed_commutant (S : Set (H →L[ℂ] H)) : + IsClosed (commutant S : Set (H →WOT[ℂ] H)) := by + change IsClosed {T | ∀ a∈S, ofCLM a*T=T*ofCLM a} + simp only [Set.ofPred_forall] + apply isClosed_iInter + intro a + apply isClosed_iInter + intro _ + exact isClosed_eq (continuous_const_mul _) (continuous_mul_const _) + +lemma isClosed_commutant_add_ball (S : Set (H →L[ℂ] H)) {C : ℝ} (hC : 0≤C) : + IsClosed ((commutant S : Set (H →WOT[ℂ] H))+normBall C) := by + exact (isClosed_commutant S).add_right_of_isCompact (isCompact_normBall hC) + +end Kadison.WOTDistance + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WOTFunctionals.lean b/lean/OAI/Analysis/Commutator/WOTFunctionals.lean new file mode 100644 index 0000000000000000000000000000000000000000..64ee5a686223fd805341cdcadf4c7503ef716141 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WOTFunctionals.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.FiniteSupportFactorization + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open ContinuousLinearMapWOT + +namespace Kadison.WOTDistance + +open OperatorFunctionals + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def coeffLM (p : H × StrongDual ℂ H) : (H →WOT[ℂ] H) →ₗ[ℂ] ℂ := + (LinearMap.proj p).comp (inducingFn (RingHom.id ℂ) H H) + +omit [CompleteSpace H] in +@[simp] lemma coeffLM_apply (p : H × StrongDual ℂ H) (T : H →L[ℂ] H) : + coeffLM p (ofCLM T)=p.2 (T p.1) := rfl + +omit [CompleteSpace H] in +lemma wot_topology : (inferInstance : TopologicalSpace (H →WOT[ℂ] H))= + ⨅ p : H × StrongDual ℂ H, TopologicalSpace.induced (coeffLM p) inferInstance := by + change TopologicalSpace.induced (inducingFn (RingHom.id ℂ) H H) Pi.topologicalSpace=_ + rw [induced_to_pi] + rfl + +theorem factorization (φ : (H →WOT[ℂ] H) →L[ℂ] ℂ) : + ∃ (n : ℕ) (x y : PiLp 2 (fun _ : Fin n => H)), + (∀ T : H →L[ℂ] H, φ (ofCLM T)=∑ i, inner ℂ (y i) (T (x i))) ∧ + ‖x‖*‖y‖≤‖φ.comp ContinuousLinearMap.WOTofCLM‖ := by + classical + have hm : φ.toLinearMap ∈ Submodule.span ℂ (Set.range (coeffLM (H:=H))) := by + apply (LinearMap.mem_span_iff_continuous _).mpr + rw [←wot_topology] + exact φ.continuous + obtain ⟨c,hc⟩ := Finsupp.mem_span_range_iff_exists_finsupp.mp hm + let a : c.support → H := fun i => i.1.1 + let b : c.support → H := fun i => star (c i.1) • (InnerProductSpace.toDual ℂ H).symm i.1.2 + have he : φ.comp ContinuousLinearMap.WOTofCLM=finiteFunctional a b := by + ext T + change φ.toLinearMap (ofCLM T)=finiteFunctional a b T + rw [←hc] + simp only [Finsupp.sum,LinearMap.sum_apply,LinearMap.smul_apply,smul_eq_mul, + finiteFunctional_apply,coeffLM_apply] + rw [←Finset.sum_attach] + apply Finset.sum_congr rfl + intro i _ + simp [a,b,InnerProductSpace.toDual_symm_apply,mul_comm] + obtain ⟨n,x,y,hxy,hn⟩ := exists_finite_support_factorization a b + refine ⟨n,x,y,?_,?_⟩ + · intro T + have hh := congrArg (fun f : StrongDual ℂ (H →L[ℂ] H) => f T) he + exact hh.trans (hxy T) + · rwa [he] + +end Kadison.WOTDistance + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakConvergence.lean b/lean/OAI/Analysis/Commutator/WeakConvergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0013c16815a0b4b19d9f79480282af76582a0e9 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakConvergence.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Commutator.WeakOperatorLimit + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open Filter + +namespace Kadison.WeakOperatorLimit + +variable {ι H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + +variable {l : Filter ι} {T : ι → H →L[ℂ] H} {V : H →L[ℂ] H} + +def Converges (T : ι → H →L[ℂ] H) (V : H →L[ℂ] H) (l : Filter ι) : Prop := + ∀ x y, Tendsto (fun i => inner ℂ (T i x) y) l (𝓝 (inner ℂ (V x) y)) + +lemma Converges.add {S : ι → H →L[ℂ] H} {W : H →L[ℂ] H} + (hT : Converges T V l) (hS : Converges S W l) : Converges (T+S) (V+W) l := by + intro x y + simpa only [Pi.add_apply,add_apply,inner_add_left] using (hT x y).add (hS x y) + +lemma Converges.sub {S : ι → H →L[ℂ] H} {W : H →L[ℂ] H} + (hT : Converges T V l) (hS : Converges S W l) : Converges (T-S) (V-W) l := by + intro x y + simpa only [Pi.sub_apply,sub_apply,inner_sub_left] using (hT x y).sub (hS x y) + +lemma converges_const (V : H →L[ℂ] H) : Converges (fun _ : ι => V) V l := fun _ _ => tendsto_const_nhds + +lemma Converges.mul_right (hT : Converges T V l) (a : H →L[ℂ] H) : + Converges (fun i => T i*a) (V*a) l := by + intro x y + exact hT (a x) y + +lemma Converges.mul_left [CompleteSpace H] (hT : Converges T V l) (a : H →L[ℂ] H) : + Converges (fun i => a*T i) (a*V) l := by + intro x y + simpa only [mul_apply_eq_comp,← ContinuousLinearMap.adjoint_inner_right a] using hT x (a.adjoint y) + +lemma Converges.commutator [CompleteSpace H] (hT : Converges T V l) (a : H →L[ℂ] H) : + Converges (fun i => T i*a-a*T i) (V*a-a*V) l := + (hT.mul_right a).sub (hT.mul_left a) + +lemma Converges.unique [l.NeBot] {W : H →L[ℂ] H} + (hT : Converges T V l) (hW : Converges T W l) : V=W := by + ext x + exact ext_inner_right ℂ (fun y => tendsto_nhds_unique (hT x y) (hW x y)) + +lemma Converges.eq_const [l.NeBot] (hT : Converges T V l) (W : H →L[ℂ] H) + (hW : ∀ᶠ i in l, T i=W) : V=W := by + apply hT.unique + intro x y + exact tendsto_const_nhds.congr' (hW.mono fun i h => by change inner ℂ (W x) y = inner ℂ (T i x) y; rw [h]) + +lemma Converges.norm [l.NeBot] (hT : Converges T V l) {C : ℝ} (hC : 0≤C) + (hb : ∀ᶠ i in l, ‖T i‖≤C) : ‖V‖≤C := norm_le_of_tendsto hT hC hb + +lemma Converges.commutes [CompleteSpace H] [l.NeBot] (hT : Converges T V l) (a : H →L[ℂ] H) + (hb : ∀ᶠ i in l, T i*a=a*T i) : V*a=a*V := by + apply sub_eq_zero.mp + exact (hT.commutator a).eq_const 0 (hb.mono fun _ h => sub_eq_zero.mpr h) + +lemma Converges.commutator_norm [CompleteSpace H] [l.NeBot] (hT : Converges T V l) (a : H →L[ℂ] H) + {C : ℝ} (hC : 0≤C) (hb : ∀ᶠ i in l, ‖T i*a-a*T i‖≤C) : ‖V*a-a*V‖≤C := + (hT.commutator a).norm hC hb + +lemma Converges.preserves_sandwich [CompleteSpace H] [l.NeBot] (hT : Converges T V l) (a b W : H →L[ℂ] H) + (hb : ∀ᶠ i in l, a*T i*b=W) : a*V*b=W := + ((hT.mul_left a).mul_right b).eq_const W hb + +lemma Converges.dist [l.NeBot] (hT : Converges T V l) (W : H →L[ℂ] H) + {C : ℝ} (hC : 0≤C) (hb : ∀ᶠ i in l, ‖T i-W‖≤C) : ‖V-W‖≤C := + (hT.sub (converges_const W)).norm hC hb + +end Kadison.WeakOperatorLimit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakDualHull.lean b/lean/OAI/Analysis/Commutator/WeakDualHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..d57260bf341e545128f46624ce2c0b1d980bc26f --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakDualHull.lean @@ -0,0 +1,88 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology ComplexOrder + +namespace Kadison.WeakDualHull + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + +local instance : AddCommGroup (WeakDual ℂ E) := inferInstanceAs (AddCommGroup (E →L[ℂ] ℂ)) + +local instance : Module ℝ (WeakDual ℂ E) := inferInstanceAs (Module ℝ (E →L[ℂ] ℂ)) + +def hull (S : Set (WeakDual ℂ E)) : Set (WeakDual ℂ E) := closure (convexHull ℝ S) + +lemma subset_hull (S : Set (WeakDual ℂ E)) : S⊆hull S := + (subset_convexHull ℝ S).trans subset_closure + +lemma convex_hull (S : Set (WeakDual ℂ E)) : Convex ℝ (hull S) := + (convex_convexHull ℝ S).closure + +lemma eval_norm_le {S : Set (WeakDual ℂ E)} (a : E) (R : ℝ) + (h : ∀ f∈S,‖f a‖≤R) {f : WeakDual ℂ E} (hf : f∈hull S) : ‖f a‖≤R := by + have hc : IsClosed {f : WeakDual ℂ E | ‖f a‖≤R} := + isClosed_le (WeakDual.eval_continuous a).norm continuous_const + have hv : Convex ℝ {f : WeakDual ℂ E | ‖f a‖≤R} := by + intro g hg k hk s t hs ht hst + change ‖s • g a+t • k a‖≤R + calc + _ ≤ ‖s • g a‖+‖t • k a‖ := norm_add_le _ _ + _ = s*‖g a‖+t*‖k a‖ := by + rw [norm_smul,norm_smul,Real.norm_eq_abs,Real.norm_eq_abs, + abs_of_nonneg hs,abs_of_nonneg ht] + _ ≤ s*R+t*R := add_le_add (mul_le_mul_of_nonneg_left hg hs) + (mul_le_mul_of_nonneg_left hk ht) + _ = R := by rw [←add_mul,hst,one_mul] + exact closure_minimal (convexHull_min h hv) hc hf + +lemma norm_le {S : Set (WeakDual ℂ E)} (R : ℝ) (hR : 0≤R) + (h : ∀ f∈S,‖f.toStrongDual‖≤R) {f : WeakDual ℂ E} (hf : f∈hull S) : + ‖f.toStrongDual‖≤R := by + apply ContinuousLinearMap.opNorm_le_bound _ hR + intro a + exact eval_norm_le a (R*‖a‖) (fun g hg => + (g.toStrongDual.le_opNorm a).trans (mul_le_mul_of_nonneg_right (h g hg) (norm_nonneg a))) hf + +lemma compact_hull {S : Set (WeakDual ℂ E)} (R : ℝ) (hR : 0≤R) + (h : ∀ f∈S,‖f.toStrongDual‖≤R) : IsCompact (hull S) := by + apply (WeakDual.isCompact_closedBall (0 : StrongDual ℂ E) R).of_isClosed_subset isClosed_closure + intro f hf + simpa only [Set.mem_preimage,Metric.mem_closedBall,dist_zero_right] using norm_le R hR h hf + +lemma eval_eq {S : Set (WeakDual ℂ E)} (a : E) (c : ℂ) + (h : ∀ f∈S,f a=c) {f : WeakDual ℂ E} (hf : f∈hull S) : f a=c := by + have hc : IsClosed {f : WeakDual ℂ E | f a=c} := + isClosed_eq (WeakDual.eval_continuous a) continuous_const + have hv : Convex ℝ {f : WeakDual ℂ E | f a=c} := by + intro g hg k hk s t _ _ hst + change (s • g a+t • k a)=c + rw [hg,hk,←add_smul,hst,one_smul] + exact closure_minimal (convexHull_min h hv) hc hf + +lemma eval_nonneg {S : Set (WeakDual ℂ E)} (a : E) + (h : ∀ f∈S,0≤f a) {f : WeakDual ℂ E} (hf : f∈hull S) : 0≤f a := by + have hc : IsClosed {f : WeakDual ℂ E | 0≤f a} := + isClosed_le continuous_const (WeakDual.eval_continuous a) + have hv : Convex ℝ {f : WeakDual ℂ E | 0≤f a} := by + intro g hg k hk s t hs ht _ + change 0 ≤ s • g a+t • k a + exact add_nonneg (smul_nonneg hs (show 0≤g a from hg)) + (smul_nonneg ht (show 0≤k a from hk)) + exact closure_minimal (convexHull_min h hv) hc hf + +end Kadison.WeakDualHull + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakOperatorAlgebra.lean b/lean/OAI/Analysis/Commutator/WeakOperatorAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..854284b6c5b61d4be08ee1a32b95227c0b3493d8 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakOperatorAlgebra.lean @@ -0,0 +1,59 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped InnerProductSpace Topology + +open Filter + +namespace Kadison.WeakOperatorLimit + +variable {H ι : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +variable {l : Filter ι} [l.NeBot] {T : ι → H →L[ℂ] H} {W : H →L[ℂ] H} + +variable (hlim : ∀ x y, Tendsto (fun i => inner ℂ (T i x) y) l (𝓝 (inner ℂ (W x) y))) + +include hlim + +omit [CompleteSpace H] in +lemma right_eq (A B : H →L[ℂ] H) (h : ∀ᶠ i in l, T i*A=B) : W*A=B := by + ext x + apply ext_inner_right ℂ + intro y + exact tendsto_nhds_unique (hlim (A x) y) (tendsto_const_nhds.congr' (by + filter_upwards [h] with i hi + exact congrArg (fun U : H →L[ℂ] H => inner ℂ (U x) y) hi.symm)) + +lemma intertwine (A B : H →L[ℂ] H) (h : ∀ᶠ i in l, T i*A=B*T i) : W*A=B*W := by + ext x + apply ext_inner_right ℂ + intro y + have he : ∀ᶠ i in l, inner ℂ (T i (A x)) y=inner ℂ (T i x) (star B y) := by + filter_upwards [h] with i hi + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] + exact congrArg (fun U : H →L[ℂ] H => inner ℂ (U x) y) hi + have hl := (hlim x (star B y)).congr' (he.mono fun _ hi => hi.symm) + rw [ContinuousLinearMap.star_eq_adjoint,ContinuousLinearMap.adjoint_inner_right] at hl + exact tendsto_nhds_unique (hlim (A x) y) hl + +lemma mem_vonNeumann (M : VonNeumannAlgebra H) (hM : ∀ᶠ i in l, T i∈M) : W∈M := by + change W∈M.carrier + rw [←M.centralizer_centralizer'] + intro a ha + exact (intertwine hlim a a (hM.mono fun i hi => ha (T i) hi)).symm + +end Kadison.WeakOperatorLimit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakOperatorIntegral.lean b/lean/OAI/Analysis/Commutator/WeakOperatorIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..78101475f9a66eeaa4ed91044039dc29a3ad3974 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakOperatorIntegral.lean @@ -0,0 +1,92 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open MeasureTheory Filter + +namespace Kadison.WeakOperatorIntegral + +variable {ι E F : Type*} [MeasurableSpace ι] + [NormedAddCommGroup E] [NormedSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +theorem exists_integral (μ : Measure ι) [IsProbabilityMeasure μ] + (T : ι → E →L[ℂ] F) (hI : ∀ x y, Integrable (fun i => inner ℂ (T i x) y) μ) + (C : ℝ) (hC : 0 ≤ C) (hT : ∀ i, ‖T i‖ ≤ C) : + ∃ V : E →L[ℂ] F, ‖V‖ ≤ C ∧ ∀ x y, + inner ℂ (V x) y = ∫ i, inner ℂ (T i x) y ∂μ := by + let L : E → F → ℂ := fun x y => ∫ i, inner ℂ (T i x) y ∂μ + have hL : ∀ x y, ‖L x y‖ ≤ C*‖x‖*‖y‖ := by + intro x y + have h := norm_integral_le_of_norm_le_const (μ := μ) (f := fun i => inner ℂ (T i x) y) + (C := C*‖x‖*‖y‖) (Eventually.of_forall (fun i => + (norm_inner_le_norm _ _).trans + (mul_le_mul_of_nonneg_right (((T i).le_opNorm x).trans + (mul_le_mul_of_nonneg_right (hT i) (norm_nonneg x))) (norm_nonneg y)))) + simpa only [probReal_univ,mul_one] using h + have haddY : ∀ x y z, L x (y+z)=L x y+L x z := by + intro x y z + simp only [L,inner_add_right,integral_add (hI x y) (hI x z)] + have hsmulY : ∀ x (a : ℂ) y, L x (a • y)=a * L x y := by + intro x a y + simp only [L,inner_smul_right,integral_const_mul] + let q : E → StrongDual ℂ F := fun x => + ({ toFun := L x + map_add' := haddY x + map_smul' := fun a y => hsmulY x a y } : F →ₗ[ℂ] ℂ).mkContinuous + (C*‖x‖) (hL x) + have hq : ∀ x y, q x y=L x y := fun _ _ => rfl + have haddX : ∀ x z y, L (x+z) y=L x y+L z y := by + intro x z y + simp only [L,map_add,inner_add_left,integral_add (hI x y) (hI z y)] + have hsmulX : ∀ (a : ℂ) x y, L (a • x) y=star a * L x y := by + intro a x y + simp only [L,map_smul,inner_smul_left,RCLike.star_def,integral_const_mul] + let V₀ : E →ₗ[ℂ] F := + { toFun := fun x => (InnerProductSpace.toDual ℂ F).symm (q x) + map_add' := by + intro x z + apply ext_inner_right ℂ + intro y + simp only [inner_add_left,InnerProductSpace.toDual_symm_apply,hq,haddX] + map_smul' := by + intro a x + apply ext_inner_right ℂ + intro y + simp only [inner_smul_left,InnerProductSpace.toDual_symm_apply,hq,hsmulX, + RingHom.id_apply,RCLike.star_def] } + have hV : ∀ x, ‖V₀ x‖ ≤ C*‖x‖ := by + intro x + change ‖(InnerProductSpace.toDual ℂ F).symm (q x)‖ ≤ _ + rw [LinearIsometryEquiv.norm_map] + exact LinearMap.mkContinuous_norm_le _ (mul_nonneg hC (norm_nonneg x)) (hL x) + refine ⟨V₀.mkContinuous C hV,LinearMap.mkContinuous_norm_le _ hC hV,?_⟩ + intro x y + exact InnerProductSpace.toDual_symm_apply + +omit [CompleteSpace F] in +theorem integral_unique (μ : Measure ι) (T : ι → E →L[ℂ] F) + {V W : E →L[ℂ] F} + (hV : ∀ x y, inner ℂ (V x) y = ∫ i, inner ℂ (T i x) y ∂μ) + (hW : ∀ x y, inner ℂ (W x) y = ∫ i, inner ℂ (T i x) y ∂μ) : V = W := by + ext x + apply ext_inner_right ℂ + intro y + exact (hV x y).trans (hW x y).symm + +end Kadison.WeakOperatorIntegral + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakOperatorLimit.lean b/lean/OAI/Analysis/Commutator/WeakOperatorLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..06dd6079edbdfa694b609cd23916ac7d16da75e0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakOperatorLimit.lean @@ -0,0 +1,113 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped Topology InnerProductSpace + +open Filter + +namespace Kadison.WeakOperatorLimit + +variable {ι E F : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + [NormedAddCommGroup F] [InnerProductSpace ℂ F] [CompleteSpace F] + +theorem exists_ultralimit (ω : Ultrafilter ι) (T : ι → E →L[ℂ] F) + (C : ℝ) (hC : 0 ≤ C) (hT : ∀ i, ‖T i‖ ≤ C) : + ∃ V : E →L[ℂ] F, ‖V‖ ≤ C ∧ ∀ x y, + Tendsto (fun i => inner ℂ (T i x) y) (ω : Filter ι) (𝓝 (inner ℂ (V x) y)) := by + have he : ∀ x : E, ∀ y : F, ∃ c : ℂ, ‖c‖ ≤ C*‖x‖*‖y‖ ∧ + Tendsto (fun i => inner ℂ (T i x) y) (ω : Filter ι) (𝓝 c) := by + intro x y + let f : ι → ℂ := fun i => inner ℂ (T i x) y + have hf : ∀ i, f i ∈ Metric.closedBall (0 : ℂ) (C*‖x‖*‖y‖) := by + intro i + simp only [Metric.mem_closedBall,dist_zero_right] + exact (norm_inner_le_norm _ _).trans + (mul_le_mul_of_nonneg_right (((T i).le_opNorm x).trans + (mul_le_mul_of_nonneg_right (hT i) (norm_nonneg x))) (norm_nonneg y)) + obtain ⟨c,hc,hl⟩ := (isCompact_closedBall (0 : ℂ) (C*‖x‖*‖y‖)).ultrafilter_le_nhds + (ω.map f) (by + rw [Ultrafilter.coe_map,Filter.map_le_iff_le_comap,Filter.comap_principal] + exact Filter.le_principal_iff.mpr (Filter.Eventually.of_forall hf)) + exact ⟨c,by simpa only [Metric.mem_closedBall,dist_zero_right] using hc,hl⟩ + choose L hL hlim using he + have haddY : ∀ x y z, L x (y+z)=L x y+L x z := by + intro x y z + apply tendsto_nhds_unique (hlim x (y+z)) + simpa only [inner_add_right] using (hlim x y).add (hlim x z) + have hsmulY : ∀ x (a : ℂ) y, L x (a • y)=a * L x y := by + intro x a y + apply tendsto_nhds_unique (hlim x (a • y)) + simpa only [inner_smul_right] using tendsto_const_nhds.mul (hlim x y) + let q : E → StrongDual ℂ F := fun x => + ({ toFun := L x + map_add' := haddY x + map_smul' := fun a y => hsmulY x a y } : F →ₗ[ℂ] ℂ).mkContinuous + (C*‖x‖) (hL x) + have hq : ∀ x y, q x y=L x y := fun _ _ => rfl + have haddX : ∀ x z y, L (x+z) y=L x y+L z y := by + intro x z y + apply tendsto_nhds_unique (hlim (x+z) y) + simpa only [map_add,inner_add_left] using (hlim x y).add (hlim z y) + have hsmulX : ∀ (a : ℂ) x y, L (a • x) y=star a * L x y := by + intro a x y + apply tendsto_nhds_unique (hlim (a • x) y) + simpa only [map_smul,inner_smul_left,RCLike.star_def] using + tendsto_const_nhds.mul (hlim x y) + let V₀ : E →ₗ[ℂ] F := + { toFun := fun x => (InnerProductSpace.toDual ℂ F).symm (q x) + map_add' := by + intro x z + apply ext_inner_right ℂ + intro y + simp only [inner_add_left,InnerProductSpace.toDual_symm_apply,hq,haddX] + map_smul' := by + intro a x + apply ext_inner_right ℂ + intro y + simp only [inner_smul_left,InnerProductSpace.toDual_symm_apply,hq,hsmulX, + RingHom.id_apply,RCLike.star_def] } + have hV : ∀ x, ‖V₀ x‖ ≤ C*‖x‖ := by + intro x + change ‖(InnerProductSpace.toDual ℂ F).symm (q x)‖ ≤ _ + rw [LinearIsometryEquiv.norm_map] + exact LinearMap.mkContinuous_norm_le _ (mul_nonneg hC (norm_nonneg x)) (hL x) + refine ⟨V₀.mkContinuous C hV,LinearMap.mkContinuous_norm_le _ hC hV,?_⟩ + intro x y + change Tendsto _ _ (𝓝 (inner ℂ ((InnerProductSpace.toDual ℂ F).symm (q x)) y)) + rw [InnerProductSpace.toDual_symm_apply,hq] + exact hlim x y + +omit [CompleteSpace F] in +theorem norm_le_of_tendsto {l : Filter ι} [l.NeBot] {T : ι → E →L[ℂ] F} + {V : E →L[ℂ] F} (hlim : ∀ x y, Tendsto (fun i => inner ℂ (T i x) y) l + (𝓝 (inner ℂ (V x) y))) {C : ℝ} (hC : 0 ≤ C) + (hT : ∀ᶠ i in l, ‖T i‖ ≤ C) : ‖V‖ ≤ C := by + apply ContinuousLinearMap.opNorm_le_bound V hC + intro x + have hi : ‖inner ℂ (V x) (V x)‖ ≤ C*‖x‖*‖V x‖ := by + apply le_of_tendsto (hlim x (V x)).norm + filter_upwards [hT] with i hi + exact (norm_inner_le_norm _ _).trans + (mul_le_mul_of_nonneg_right (((T i).le_opNorm x).trans + (mul_le_mul_of_nonneg_right hi (norm_nonneg x))) (norm_nonneg _)) + rw [← inner_self_re_eq_norm,inner_self_eq_norm_mul_norm] at hi + by_cases hv : ‖V x‖=0 + · rw [hv]; positivity + · have hp : 0 < ‖V x‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hv) + exact (mul_le_mul_iff_left₀ hp).mp (by simpa [pow_two,mul_comm,mul_left_comm,mul_assoc] using hi) + +end Kadison.WeakOperatorLimit + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeakZeroSelection.lean b/lean/OAI/Analysis/Commutator/WeakZeroSelection.lean new file mode 100644 index 0000000000000000000000000000000000000000..3590520c110f1f1c60e56d54b4d1a872c2156b7b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeakZeroSelection.lean @@ -0,0 +1,81 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped BigOperators InnerProductSpace + +open Filter Topology + +namespace Kadison + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℂ E] + +lemma exists_orthonormal_small {I : Type*} [Fintype I] (v : I → E) + (hv : Orthonormal ℂ v) (b : ℕ → E) (n : ℕ) (ε : ℝ) (hε : 0<ε) + (hlarge : (∑ j ∈ Finset.range n, ‖b j‖^2) sq_nonneg ‖inner ℂ (v i) (b k)‖) + (Finset.mem_range.mpr hj) + have hsum := Finset.sum_le_sum (s := Finset.univ) (fun i _ => hlow i) + simp only [Finset.sum_const,Finset.card_univ,nsmul_eq_mul] at hsum + have hupp : (∑ i, ∑ j ∈ Finset.range n, ‖inner ℂ (v i) (b j)‖^2)≤ + ∑ j ∈ Finset.range n, ‖b j‖^2 := by + rw [Finset.sum_comm] + exact Finset.sum_le_sum fun j _ => hv.sum_inner_products_le (b j) + linarith + +theorem exists_weak_zero_sequence (P : Set E) (b : ℕ → E) (hb : DenseRange b) + (hlarge : ∀ N : ℕ, ∃ m : ℕ, N ≤ m ∧ ∃ v : Fin m → E, + Orthonormal ℂ v ∧ ∀ i, v i∈P) : + ∃ v : ℕ → E, (∀ n, v n∈P) ∧ (∀ n, ‖v n‖=1) ∧ + ∀ y : E, Tendsto (fun n => inner ℂ (v n) y) atTop (𝓝 0) := by + classical + have hchoose (n : ℕ) : ∃ x : E, x∈P ∧ ‖x‖=1 ∧ + ∀ j < n, ‖inner ℂ x (b j)‖<(1:ℝ)/(n+1) := by + have hε : 0<(1:ℝ)/(n+1) := by positivity + obtain ⟨N,hN⟩ := exists_nat_gt ((∑ j ∈ Finset.range n, ‖b j‖^2)/((1:ℝ)/(n+1))^2) + obtain ⟨m,hm,v,hv,hP⟩ := hlarge N + have hbound : (∑ j ∈ Finset.range n, ‖b j‖^2) inner ℂ (v n) (b j)) atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply squeeze_zero' (Eventually.of_forall (fun n => norm_nonneg _)) + (eventually_atTop.mpr ⟨j+1,fun n hn => (hvsmall n j (by omega)).le⟩) + exact tendsto_one_div_add_atTop_nhds_zero_nat + have hclosed : IsClosed {y : E | Tendsto (fun n => inner ℂ (v n) y) atTop (𝓝 0)} := by + have hF : Equicontinuous (fun n y => inner ℂ (v n) y) := + (LipschitzWith.uniformEquicontinuous (fun n y => inner ℂ (v n) y) 1 + (fun n => (innerSL ℂ (v n)).lipschitzWith.weaken (by + exact_mod_cast (show ‖innerSL ℂ (v n)‖ ≤ (1:ℝ) by rw [innerSL_apply_norm,hvnorm])))).equicontinuous + exact hF.isClosed_setOfPred_tendsto continuous_const + refine ⟨v,hvP,hvnorm,fun y => ?_⟩ + have hsub : Set.range b ⊆ {y : E | Tendsto (fun n => inner ℂ (v n) y) atTop (𝓝 0)} := by + rintro _ ⟨j,rfl⟩ + exact htest j + exact closure_minimal hsub hclosed (hb y) + +end Kadison + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WeightedSubsequence.lean b/lean/OAI/Analysis/Commutator/WeightedSubsequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..1c42b866726c75532750ea0c08a6026105aac4e4 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WeightedSubsequence.lean @@ -0,0 +1,60 @@ +import Mathlib + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open Filter Finset + +open scoped Topology + +namespace Kadison.PositiveWOT + +theorem exists_weighted_subsequence (q : ℕ → ℕ → ℝ) + (hq : ∀ n j,0≤q n j) (ht : ∀ j,Tendsto (fun n => q n j) atTop (𝓝 0)) : + ∃ u : ℕ → ℕ,StrictMono u ∧ ∀ j,∃ C : ℝ,∀ N, + ∑ k∈range N,((k:ℝ)+1)*q (u k) j≤C := by + have hev (k : ℕ) : ∀ᶠ n in atTop,∀ j∈range (k+1), + q n j≤(1/2:ℝ)^k/((k:ℝ)+1) := by + apply (eventually_all_finset (range (k+1))).mpr + intro j _ + exact ((ht j).eventually_lt_const (by positivity : (0:ℝ)<(1/2:ℝ)^k/((k:ℝ)+1))).mono + fun _ h => h.le + obtain ⟨u,hu,huq⟩ := Tendsto.subseq_mem (V:=fun k => {n | ∀ j∈range (k+1), + q n j≤(1/2:ℝ)^k/((k:ℝ)+1)}) hev (tendsto_id (α:=ℕ) : Tendsto id atTop atTop) + refine ⟨u,hu,?_⟩ + intro j + let z (k : ℕ) : ℝ := ((k:ℝ)+1)*q (u k) j + have hz (k : ℕ) : 0≤z k := mul_nonneg (by positivity) (hq _ _) + have hsmall (k : ℕ) (hjk : j≤k) : z k≤(1/2:ℝ)^k := by + have h := huq k j (mem_range.mpr (by omega)) + dsimp [z] + simpa only [mul_comm,id_eq] using (le_div_iff₀ (by positivity : (0:ℝ)<(k:ℝ)+1)).mp h + refine ⟨(∑ k∈range j,z k)+2,?_⟩ + intro N + change (∑ k∈range N,z k)≤_ + rcases le_total N j with hNj|hjN + · have hh : (∑ k∈range N,z k)≤∑ k∈range j,z k := + sum_le_sum_of_subset_of_nonneg (range_mono hNj) (fun k _ _ => hz k) + linarith + · rw [←sum_range_add_sum_Ico z hjN] + refine add_le_add le_rfl ?_ + calc + (∑ k∈Ico j N,z k)≤∑ k∈Ico j N,(1/2:ℝ)^k := + sum_le_sum (fun k hk => hsmall k (mem_Ico.mp hk).1) + _ ≤ ∑ k∈range N,(1/2:ℝ)^k := sum_le_sum_of_subset_of_nonneg + (by intro k hk; exact mem_range.mpr (mem_Ico.mp hk).2) (by intros; positivity) + _ ≤ 2 := sum_geometric_two_le N + +end Kadison.PositiveWOT + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordCoefficientContinuity.lean b/lean/OAI/Analysis/Commutator/WordCoefficientContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b7a5c3bf55493594724b77898a864f72397078b --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordCoefficientContinuity.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialWordReindex +import OAI.Analysis.Commutator.TracialL2Continuity + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching.Words + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +variable (τ : A →ₚ[ℂ] ℂ) (hτ : ∀ a b : A,τ (a*b)=τ (b*a)) + +include hτ in +lemma word_coefficients_norm_sub (x y : J → A) (k : K → ℤ) + (hx : ∀ j,‖x j‖ ≤ 1) (hy : ∀ j,‖y j‖ ≤ 1) + {δ : ℝ} (hxy : ∀ j,TracialL2.norm τ (x j-y j) ≤ δ) + (v : PartialUnitary A) (l : List (Letter J K)) : + TracialL2.norm τ (word x k v l-word y k v l) ≤ (l.length:ℝ)*δ := by + induction l with + | nil => simp + | cons i l ih => + have hh : TracialL2.norm τ (letter x k v i-letter y k v i) ≤ δ := by + change TracialL2.norm τ (x i.1*slotPower k v i.2-y i.1*slotPower k v i.2) ≤ δ + rw [←sub_mul] + exact (TracialL2.norm_mul_right τ hτ _ _).trans + ((mul_le_of_le_one_right (TracialL2.norm_nonneg τ _) (slotPower_norm k v _)).trans (hxy _)) + rw [word_cons,word_cons] + have h1 := TracialL2.norm_mul_sub_mul τ hτ (letter x k v i) (word x k v l) + (letter y k v i) (word y k v l) + have h2 := add_le_add + ((mul_le_of_le_one_right (TracialL2.norm_nonneg τ _) (word_norm x k hx v l)).trans hh) + ((mul_le_of_le_one_left (TracialL2.norm_nonneg τ _) (letter_norm y k hy v i)).trans ih) + apply h1.trans (h2.trans_eq _) + simp only [List.length_cons,Nat.cast_add,Nat.cast_one] + ring + +include hτ in +lemma trace_word_coefficients_norm_sub (hone : τ 1=1) + (x y : J → A) (k : K → ℤ) (hx : ∀ j,‖x j‖ ≤ 1) (hy : ∀ j,‖y j‖ ≤ 1) + {δ : ℝ} (hxy : ∀ j,TracialL2.norm τ (x j-y j) ≤ δ) + (v : PartialUnitary A) (l : List (Letter J K)) : + ‖τ (word x k v l)-τ (word y k v l)‖ ≤ (l.length:ℝ)*δ := by + rw [←map_sub] + exact (TracialL2.norm_trace_le τ hτ hone _).trans + (word_coefficients_norm_sub τ hτ x y k hx hy hxy v l) + +include hτ in +lemma moment_limit_of_dense_coefficients (hone : τ 1=1) + (x : ℕ → A) (k : K → ℤ) (hx : ∀ j,‖x j‖ ≤ 1) + (hden : ∀ a : A,‖a‖ ≤ 1 → τ a=0 → ∀ ε : ℝ,0<ε → ∃ j,TracialL2.norm τ (a-x j)<ε) + (v : ℕ → PartialUnitary A) + (hlim : ∀ l : List (Letter ℕ K),l≠[] → Valid l → + Tendsto (fun n => τ (word x k (v n) l)) atTop (𝓝 0)) + (y : J → A) (hy : ∀ j,‖y j‖ ≤ 1) (hcy : ∀ j,τ (y j)=0) + (l : List (Letter J K)) (hl : l≠[]) (hv : Valid l) : + Tendsto (fun n => τ (word y k (v n) l)) atTop (𝓝 0) := by + classical + apply Metric.tendsto_nhds.mpr + intro ε hε + let δ := ε/(2*((l.length:ℝ)+1)) + have hδ : 0<δ := by dsimp [δ]; positivity + choose f hf using (fun j => hden (y j) (hy j) (hcy j) δ hδ) + have he : (l.length:ℝ)*δ ≤ ε/2 := by + have hh : 2*((l.length:ℝ)+1)*δ=ε := by dsimp [δ]; field_simp + nlinarith + have hsmall := (hlim (l.map (mapLetter f id)) (by simpa using hl) (valid_map f id hv)).eventually + (Metric.ball_mem_nhds (0:ℂ) (half_pos hε)) + filter_upwards [hsmall] with n hn + have hh : ‖τ (word (x ∘ f) k (v n) l)‖<ε/2 := by + simpa only [Metric.mem_ball,dist_zero_right,word_reindex,Function.comp_id] using hn + have hd := trace_word_coefficients_norm_sub τ hτ hone y (x ∘ f) k hy + (fun j => hx (f j)) (fun j => (hf j).le) (v n) l + rw [dist_zero_right] + have htri := norm_le_norm_sub_add (τ (word y k (v n) l)) (τ (word (x ∘ f) k (v n) l)) + linarith + +end Kadison.FinitePatching.Words + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordPermutations.lean b/lean/OAI/Analysis/Commutator/WordPermutations.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d51f6832ce98667755941c7ec414186f9b4a3a3 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordPermutations.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Commutator.CoefficientForm +import OAI.Analysis.Commutator.TensorActions +import OAI.Analysis.Commutator.TensorPermutations2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.PreHilbert + +open UniformSpace + +open scoped TensorProduct + +def reindexPower (F : PreHilbert) {k l : ℕ} (b : Fin k ≃ Fin l) : + power F k ≃ₗᵢ[ℂ] power F l := + gramEquiv (pure F k) (fun x => pure F l (x ∘ b.symm)) (span_pure F k) + (by + have hr : Set.range (fun x => pure F l (x ∘ b.symm)) = Set.range (pure F l) := by + ext z + constructor + · rintro ⟨x, rfl⟩; exact ⟨x ∘ b.symm, rfl⟩ + · rintro ⟨y, rfl⟩ + refine ⟨y ∘ b, ?_⟩ + exact congrArg (pure F l) (funext fun i => by simp) + rw [hr, span_pure]) + (by + intro x y + simp only [inner_pure, Function.comp_apply] + exact Equiv.prod_comp b.symm (fun i => inner ℂ (x i) (y i))) + +@[simp] lemma reindexPower_pure (F : PreHilbert) {k l : ℕ} (b : Fin k ≃ Fin l) + (x : Fin k → F) : reindexPower F b (pure F k x) = pure F l (x ∘ b.symm) := + gramEquiv_apply _ _ _ _ _ _ + +def wordReindex (E F : PreHilbert) {k l : ℕ} (b : Fin k ≃ Fin l) : + wordSpace E F k →ₗᵢ[ℂ] wordSpace E F l := + completionIsometry (TensorProduct.mapIsometry (LinearIsometry.id : E →ₗᵢ[ℂ] E) + (reindexPower F b).toLinearIsometry) + +@[simp] lemma wordReindex_word (E F : PreHilbert) {k l : ℕ} (b : Fin k ≃ Fin l) + (d : E) (x : Fin k → F) : + wordReindex E F b (word E F k d x) = word E F l d (x ∘ b.symm) := by + simp only [wordReindex, word, completionIsometry_coe, TensorProduct.mapIsometry_apply, TensorProduct.map_tmul, + LinearIsometry.coe_toLinearMap, LinearIsometry.id_apply, LinearIsometryEquiv.coe_toLinearIsometry, reindexPower_pure] + +lemma wordReindex_inner (E F : PreHilbert) {k l : ℕ} (b : Fin k ≃ Fin l) + (d c : E) (x : Fin k → F) (y : Fin l → F) : + inner ℂ (word E F l c y) (wordReindex E F b (word E F k d x)) = + inner ℂ c d * ∏ i, inner ℂ (y (b i)) (x i) := by + rw [wordReindex_word, inner_word] + congr 1 + simpa using (Equiv.prod_comp b (fun j => inner ℂ (y j) (x (b.symm j)))).symm + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordScaling.lean b/lean/OAI/Analysis/Commutator/WordScaling.lean new file mode 100644 index 0000000000000000000000000000000000000000..74502d9dba050c9ff0da6df17e866fa036a6eac0 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordScaling.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Commutator.PartialUnitaryWords + +namespace OAI + +noncomputable section + +section + +noncomputable section + +open scoped ComplexOrder Topology + +open Filter + +namespace Kadison.FinitePatching.Words + +variable {A J K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma letter_smul (x : J → A) (c : J → ℂ) (k : K → ℤ) (v : PartialUnitary A) (i : Letter J K) : + letter (fun j => c j • x j) k v i=c i.1 • letter x k v i := by + simp only [letter,smul_mul_assoc] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma word_smul (x : J → A) (c : J → ℂ) (k : K → ℤ) (v : PartialUnitary A) + (l : List (Letter J K)) : + word (fun j => c j • x j) k v l=(l.map (fun i => c i.1)).prod • word x k v l := by + induction l with + | nil => simp + | cons i l ih => + simp only [word_cons,letter_smul,ih,List.map_cons,List.prod_cons, + smul_mul_assoc,mul_smul_comm,smul_smul] + rw [mul_comm] + +omit [StarOrderedRing A] in +lemma moment_limit_of_contractions (τ : A →ₚ[ℂ] ℂ) (k : K → ℤ) (v : ℕ → PartialUnitary A) + (hlim : ∀ x : J → A,(∀ j,‖x j‖≤1) → (∀ j,τ (x j)=0) → + ∀ l : List (Letter J K),l≠[] → Valid l → + Tendsto (fun n => τ (word x k (v n) l)) atTop (𝓝 0)) + (x : J → A) (hx : ∀ j,τ (x j)=0) + (l : List (Letter J K)) (hl : l≠[]) (hv : Valid l) : + Tendsto (fun n => τ (word x k (v n) l)) atTop (𝓝 0) := by + let c : J → ℂ := fun j => ((‖x j‖+1 : ℝ):ℂ) + let y : J → A := fun j => (c j)⁻¹ • x j + have hc (j : J) : c j≠0 := by + dsimp [c] + exact_mod_cast (show ‖x j‖+1≠0 by positivity) + have hy (j : J) : ‖y j‖≤1 := by + dsimp [y,c] + rw [norm_smul,norm_inv,Complex.norm_real,Real.norm_eq_abs,abs_of_pos (by positivity)] + apply (inv_mul_le_iff₀ (by positivity : 0<‖x j‖+1)).mpr + linarith + have hyc (j : J) : τ (y j)=0 := by simp [y,map_smul,hx] + have he : (fun j => c j • y j)=x := by + funext j + simp [y,smul_smul,hc] + have h := (hlim y hy hyc l hl hv).const_smul ((l.map (fun i => c i.1)).prod) + have hword (n : ℕ) : τ (word x k (v n) l)= + ((l.map (fun i => c i.1)).prod) • τ (word y k (v n) l) := by + rw [←he,word_smul,map_smul] + simpa only [smul_zero,←hword] using h + +end Kadison.FinitePatching.Words + +end + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordTopology.lean b/lean/OAI/Analysis/Commutator/WordTopology.lean new file mode 100644 index 0000000000000000000000000000000000000000..07caed50e8c1b279109b6ca74255829303eaf446 --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordTopology.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Commutator.CoefficientForm + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.PreHilbert + +open UniformSpace TensorProduct + +@[fun_prop] lemma continuous_pure (E : PreHilbert) (n : ℕ) : + Continuous (pure E n) := by + induction n with + | zero => exact continuous_const + | succ n ih => + change Continuous (fun x : Fin (n+1) → E => x 0 ⊗ₜ[ℂ] pure E n (Fin.tail x)) + have ht : Continuous (fun x : Fin (n+1) → E => Fin.tail x) := + continuous_pi (fun i => continuous_apply i.succ) + exact (TensorProduct.continuous_tmul (𝕜 := ℂ) (E := E) (F := power E n)).comp + ((continuous_apply (0 : Fin (n+1))).prodMk (ih.comp ht)) + +@[fun_prop] lemma continuous_word (E F : PreHilbert) (n : ℕ) : + Continuous (fun z : E × (Fin n → F) => word E F n z.1 z.2) := by + unfold word + exact (Completion.continuous_coe (E ⊗[ℂ] power F n)).comp + ((TensorProduct.continuous_tmul (𝕜 := ℂ) (E := E) (F := power F n)).comp + (continuous_fst.prodMk ((continuous_pure F n).comp continuous_snd))) + +lemma eq_zero_of_word_inner (E F : PreHilbert) (n : ℕ) (z : wordSpace E F n) + (hz : ∀ d x, inner ℂ (word E F n d x) z = 0) : z = 0 := by + apply Completion.denseRange_coe.eq_zero_of_inner_right ℂ + intro a + induction a using TensorProduct.inductionOn with + | add a b ha hb => simp [Completion.coe_add, inner_add_left, ha, hb] + | tmul d x => + have hx : x ∈ Submodule.span ℂ (Set.range (pure F n)) := by + rw [span_pure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v, rfl⟩ := hx + exact hz d v + | zero => simp only [TensorProduct.tmul_zero, Completion.coe_zero, inner_zero_left] + | add x y _ _ hx hy => simp [TensorProduct.tmul_add, Completion.coe_add, inner_add_left, hx, hy] + | smul c x _ hx => simp only [TensorProduct.tmul_smul, Completion.coe_smul, inner_smul_left, hx, mul_zero] + +lemma continuousLinearMap_ext_word (E F : PreHilbert) (n : ℕ) {G : Type*} + [NormedAddCommGroup G] [NormedSpace ℂ G] + (T U : wordSpace E F n →L[ℂ] G) + (h : ∀ d x, T (word E F n d x) = U (word E F n d x)) : T = U := by + apply ContinuousLinearMap.ext + intro z + induction z using Completion.induction_on with + | hp => exact isClosed_eq (by fun_prop) (by fun_prop) + | ih a => + induction a using TensorProduct.inductionOn with + | add a b ha hb => simp only [Completion.coe_add, map_add, ha, hb] + | tmul d x => + have hx : x ∈ Submodule.span ℂ (Set.range (pure F n)) := by + rw [span_pure]; trivial + induction hx using Submodule.span_induction with + | mem x hx => + obtain ⟨v, rfl⟩ := hx + exact h d v + | zero => simp only [TensorProduct.tmul_zero, Completion.coe_zero, map_zero] + | add x y _ _ hx hy => simp only [TensorProduct.tmul_add, Completion.coe_add, map_add, hx, hy] + | smul c x _ hx => simp only [TensorProduct.tmul_smul, Completion.coe_smul, map_smul, hx] + +lemma continuousLinearMap_ext_word_inner (E F : PreHilbert) (k l : ℕ) + (T U : wordSpace E F k →L[ℂ] wordSpace E F l) + (h : ∀ d x c y, inner ℂ (word E F l c y) (T (word E F k d x)) = + inner ℂ (word E F l c y) (U (word E F k d x))) : T = U := by + apply continuousLinearMap_ext_word E F k T U + intro d x + apply sub_eq_zero.mp + apply eq_zero_of_word_inner E F l + intro c y + rw [inner_sub_right, h, sub_self] + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordTopology2.lean b/lean/OAI/Analysis/Commutator/WordTopology2.lean new file mode 100644 index 0000000000000000000000000000000000000000..3f16549046c650778766586bfa6a64d10e83a1aa --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordTopology2.lean @@ -0,0 +1,52 @@ +import Mathlib + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.Topology + +open Set + +lemma exists_stage_pi {ι : Type*} [Fintype ι] {E : ι → Type*} + (S : ℕ → (i : ι) → Set (E i)) (hmono : ∀ i, Monotone (fun n => S n i)) + (v : ∀ i, E i) (hv : ∀ i, v i ∈ ⋃ n, S n i) : + ∃ n, ∀ i, v i ∈ S n i := by + classical + have hv' (i) : ∃ n, v i ∈ S n i := Set.mem_iUnion.mp (hv i) + choose a ha using hv' + refine ⟨Finset.univ.sup a, fun i => ?_⟩ + exact hmono i (Finset.le_sup (Finset.mem_univ i)) (ha i) + +lemma dense_iUnion_pi {ι : Type*} [Fintype ι] {E : ι → Type*} + [∀ i, TopologicalSpace (E i)] + (S : ℕ → (i : ι) → Set (E i)) (hmono : ∀ i, Monotone (fun n => S n i)) + (hd : ∀ i, Dense (⋃ n, S n i)) : Dense (⋃ n, Set.pi Set.univ (S n)) := by + apply (dense_pi Set.univ (fun i _ => hd i)).mono + intro v hv + obtain ⟨n, hn⟩ := exists_stage_pi S hmono v (fun i => hv i (Set.mem_univ i)) + exact Set.mem_iUnion.mpr ⟨n, fun i _ => hn i⟩ + +lemma dense_iUnion_prod {E F : Type*} [TopologicalSpace E] [TopologicalSpace F] + (S : ℕ → Set E) (T : ℕ → Set F) (hS : Monotone S) (hT : Monotone T) + (hSd : Dense (⋃ n, S n)) (hTd : Dense (⋃ n, T n)) : + Dense (⋃ n, S n ×ˢ T n) := by + apply (hSd.prod hTd).mono + intro x hx + obtain ⟨n, hn⟩ := Set.mem_iUnion.mp hx.1 + obtain ⟨m, hm⟩ := Set.mem_iUnion.mp hx.2 + exact Set.mem_iUnion.mpr ⟨max n m, hS (le_max_left n m) hn, hT (le_max_right n m) hm⟩ + +end Kadison.Topology +end + +end OAI diff --git a/lean/OAI/Analysis/Commutator/WordTopology3.lean b/lean/OAI/Analysis/Commutator/WordTopology3.lean new file mode 100644 index 0000000000000000000000000000000000000000..6b4c63ce463b20eb018d351fb7eb70087cd9a70e --- /dev/null +++ b/lean/OAI/Analysis/Commutator/WordTopology3.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Commutator.WordTopology +import OAI.Analysis.Commutator.WordTopology2 + +namespace OAI + +noncomputable section +open scoped ComplexOrder InnerProductSpace +open Complex ContinuousLinearMap UniformSpace Completion +open scoped InnerProductSpace +open scoped TensorProduct +open scoped TensorProduct InnerProductSpace Topology +open UniformSpace Completion Filter +open scoped TensorProduct +open UniformSpace Completion +open scoped Matrix.Norms.L2Operator MatrixOrder ComplexOrder + +namespace Kadison.PreHilbert + +def stageWordArgs (E F : PreHilbert) (S : ℕ → Set E) (R : ℕ → Set F) + (j n : ℕ) : Set (E × (Fin j → F)) := S n ×ˢ Set.pi Set.univ (fun _ => R n) + +lemma stageWordArgs_mono (E F : PreHilbert) (S : ℕ → Set E) (R : ℕ → Set F) + (hS : Monotone S) (hR : Monotone R) (j : ℕ) : + Monotone (stageWordArgs E F S R j) := by + intro n m hnm x hx + exact ⟨hS hnm hx.1, fun i hi => hR hnm (hx.2 i hi)⟩ + +lemma dense_stageWordArgs (E F : PreHilbert) (S : ℕ → Set E) (R : ℕ → Set F) + (hS : Monotone S) (hR : Monotone R) (hSd : Dense (⋃ n, S n)) + (hRd : Dense (⋃ n, R n)) (j : ℕ) : Dense (⋃ n, stageWordArgs E F S R j n) := by + exact Topology.dense_iUnion_prod S (fun n => Set.pi Set.univ (fun _ : Fin j => R n)) hS + (fun n m hnm x hx i hi => hR hnm (hx i hi)) hSd + (Topology.dense_iUnion_pi (fun n (_ : Fin j) => R n) (fun _ => hR) (fun _ => hRd)) + +lemma continuous_wordCoefficient (E F : PreHilbert) (k l : ℕ) + (T : wordSpace E F k →L[ℂ] wordSpace E F l) : + Continuous (fun z : (E × (Fin k → F)) × (E × (Fin l → F)) => + inner ℂ (word E F l z.2.1 z.2.2) (T (word E F k z.1.1 z.1.2))) := by + exact (((continuous_word E F l).comp continuous_snd).inner + (T.continuous.comp ((continuous_word E F k).comp continuous_fst))) + +theorem operator_ext_dense_stages (E F : PreHilbert) (k l : ℕ) + (S : ℕ → Set E) (R : ℕ → Set F) (hS : Monotone S) (hR : Monotone R) + (hSd : Dense (⋃ n, S n)) (hRd : Dense (⋃ n, R n)) + (T U : wordSpace E F k →L[ℂ] wordSpace E F l) + (h : ∀ n d, d ∈ S n → ∀ x, (∀ i, x i ∈ R n) → ∀ c, c ∈ S n → + ∀ y, (∀ j, y j ∈ R n) → + inner ℂ (word E F l c y) (T (word E F k d x)) = + inner ℂ (word E F l c y) (U (word E F k d x))) : T = U := by + let W := stageWordArgs E F S R + have hd : Dense (⋃ n, W k n ×ˢ W l n) := + Topology.dense_iUnion_prod (W k) (W l) + (stageWordArgs_mono E F S R hS hR k) (stageWordArgs_mono E F S R hS hR l) + (dense_stageWordArgs E F S R hS hR hSd hRd k) + (dense_stageWordArgs E F S R hS hR hSd hRd l) + apply continuousLinearMap_ext_word_inner E F k l T U + intro d x c y + refine hd.induction (P := fun z => + inner ℂ (word E F l z.2.1 z.2.2) (T (word E F k z.1.1 z.1.2)) = + inner ℂ (word E F l z.2.1 z.2.2) (U (word E F k z.1.1 z.1.2))) ?_ ?_ ((d, x), (c, y)) + · intro z hz + obtain ⟨n, hn⟩ := Set.mem_iUnion.mp hz + exact h n z.1.1 hn.1.1 z.1.2 (fun i => hn.1.2 i (Set.mem_univ i)) + z.2.1 hn.2.1 z.2.2 (fun j => hn.2.2 j (Set.mem_univ j)) + · exact isClosed_eq (continuous_wordCoefficient E F k l T) + (continuous_wordCoefficient E F k l U) + +end Kadison.PreHilbert +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/AlignedEndingData.lean b/lean/OAI/Analysis/Conductivity/Branching/AlignedEndingData.lean new file mode 100644 index 0000000000000000000000000000000000000000..53df8ab4c2c0cd49660767219cb4a83ebc16faf7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/AlignedEndingData.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.CascadePeriodicity +import OAI.Analysis.Conductivity.Branching.EndingCoordinateTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +lemma alignedEndingTensor_bounds {lam k J L K c C : ℝ} + (hb : ∀ x v : Coord3,c*(v ⬝ᵥ v)≤v ⬝ᵥ (finiteEndingTensor (lam/k) J L K x*ᵥv) ∧ + v ⬝ᵥ (finiteEndingTensor (lam/k) J L K x*ᵥv)≤C*(v ⬝ᵥ v)) + (x v : Coord3) : + c*(v ⬝ᵥ v)≤v ⬝ᵥ (alignedEndingTensor lam k J L K x*ᵥv) ∧ + v ⬝ᵥ (alignedEndingTensor lam k J L K x*ᵥv)≤C*(v ⬝ᵥ v) := by + have h := hb (permutedDilation angularAxisSwap k x) (fun i => v (angularAxisSwap i)) + have hn : (fun i => v (angularAxisSwap i)) ⬝ᵥ (fun i => v (angularAxisSwap i))=v ⬝ᵥ v := + Equiv.sum_comp angularAxisSwap (fun i => v i*v i) + rw [hn] at h + have hq := permutedTensor_quadratic angularAxisSwap + (finiteEndingTensor (lam/k) J L K (permutedDilation angularAxisSwap k x)) v + change v ⬝ᵥ (alignedEndingTensor lam k J L K x*ᵥv)=_ at hq + simpa only [hq] using h + +lemma permutedDilation_angularShift (k : ℤ) (n : Fin 2 → ℤ) (x : Coord3) : + permutedDilation angularAxisSwap (k:ℝ) (x+angularShift (2*Real.pi) n)= + permutedDilation angularAxisSwap (k:ℝ) x+ + angularShift (2*Real.pi) ![k*n 1,k*n 0] := by + ext i + fin_cases i <;> simp [permutedDilation,angularAxisSwap_apply,angularShift] <;> ring + +lemma alignedEndingValue_angularPeriodic (lam J L K : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (alignedEndingValue lam k J L K) := by + intro n x + dsimp only [alignedEndingValue] + rw [permutedDilation_angularShift] + exact finiteEndingValue_angularPeriodic _ _ _ _ _ _ + +lemma alignedEndingTensor_angularPeriodic (lam J L K : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (alignedEndingTensor lam k J L K) := by + intro n x + ext i j + dsimp only [alignedEndingTensor] + rw [permutedDilation_angularShift,finiteEndingTensor_angularPeriodic] + +theorem aligned_positive_finite_ending {lam : ℝ} (hlam : 0 direction (Pi.single j 1) (alignedEndingValue lam k J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have hkr : (0:ℝ) ℝ) e.symm).trans + (LinearEquiv.smulOfNeZero ℝ Coord3 k hk).toContinuousLinearEquiv + +lemma permutedDilationEquiv_apply (e : Equiv.Perm (Fin 3)) {k : ℝ} (hk : k≠0) (x : Coord3) : + permutedDilationEquiv e hk x=permutedDilation e k x := by + ext i + simp [permutedDilationEquiv,permutedDilation,ContinuousLinearEquiv.piCongrLeft, + Homeomorph.piCongrLeft,Equiv.piCongrLeft] + +def axialPairScaling {k : ℝ} (hk : k≠0) : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ) := + ContinuousLinearEquiv.piCongrRight (fun i : Fin 2 => + (LinearEquiv.smulOfNeZero ℝ ℝ (if i=0 then k⁻¹ else 1) (by split_ifs <;> simp_all)).toContinuousLinearEquiv) + +lemma axialPairScaling_apply {k : ℝ} (hk : k≠0) (v : Fin 2 → ℝ) (i : Fin 2) : + axialPairScaling hk v i=(if i=0 then k⁻¹ else 1)*v i := rfl + +lemma alignedEnding_axialPair {lam k J L K : ℝ} (hk : k≠0) (x : Coord3) : + axialPairScaling hk (axialPair (finiteEndingValue (lam/k) J L K) + (permutedDilationEquiv angularAxisSwap hk x))=axialPair (alignedEndingValue lam k J L K) x := by + ext i + fin_cases i <;> simp [axialPairScaling_apply,permutedDilationEquiv_apply,axialPair, + permutedDilation,angularAxisSwap_apply,alignedEndingValue,hk] + +def alignedEndingSymmetricTensor (lam k J L K : ℝ) (x : Coord3) : Symmetric3 := + ⟨alignedEndingTensor lam k J L K x,alignedEndingTensor_symm lam k J L K x⟩ + +lemma RegularPatch.alignedEnding {lam k J L K : ℝ} (hk : k≠0) {O : Set Coord3} + (h : RegularPatch (axialPair (finiteEndingValue (lam/k) J L K)) + (finiteEndingSymmetricTensor (lam/k) J L K) O) : + RegularPatch (axialPair (alignedEndingValue lam k J L K)) + (alignedEndingSymmetricTensor lam k J L K) + ((permutedDilationEquiv angularAxisSwap hk) ⁻¹' O) := by + let P := permutedDilationEquiv angularAxisSwap hk + let Q := axialPairScaling hk + have he : (fun x => Q (axialPair (finiteEndingValue (lam/k) J L K) (P x)))= + axialPair (alignedEndingValue lam k J L K) := funext (alignedEnding_axialPair hk) + refine ⟨h.1.preimage P.continuous,?_,?_,?_⟩ + · rw [←he] + exact Q.contDiff.contDiffOn.comp (h.2.1.comp P.contDiff.contDiffOn (fun _ hx => hx)) + (fun _ _ => mem_univ _) + · apply contDiffOn_pi.mpr; intro i + apply contDiffOn_pi.mpr; intro j + have hh := h.2.2.1.comp P.contDiff.contDiffOn (fun _ hx => hx) + have hi := (contDiff_apply ℝ (Fin 3 → ℝ) (angularAxisSwap i)).contDiffOn.comp hh (fun _ _ => mem_univ _) + have hj := (contDiff_apply ℝ ℝ (angularAxisSwap j)).contDiffOn.comp hi (fun _ _ => mem_univ _) + change ContDiffOn ℝ (↑(⊤:ℕ∞)) (fun x => + finiteEndingTensor (lam/k) J L K (P x) (angularAxisSwap i) (angularAxisSwap j)) (P ⁻¹' O) at hj + convert hj using 1 + funext x + simp only [alignedEndingSymmetricTensor,alignedEndingTensor, + P,permutedDilationEquiv_apply] + · rw [←he] + exact TwoFieldRankRegular.linearCoordinates h.1 h.2.1 h.2.2.2 P Q + +theorem alignedEnding_regularRegion_ae {lam k J L K : ℝ} (hk : k≠0) (hL : 0 ![x 0,delayedEndingValue lam k J L K 7 x]) := by + apply contDiff_pi.mpr + intro i + fin_cases i + · exact contDiff_apply ℝ ℝ 0 + · exact delayedEndingValue_C2 hJ hL hK + apply contDiff_axial_paste hu hv (continuous_apply 0) (δ:=1/4) (by norm_num) + intro x hx + rw [he x (by linarith [hx.1]),delayedEndingValue_initial hk hJ x (by linarith [hx.2])] + +lemma matchedEndingPair_periodic {u : Coord3 → Fin 2 → ℝ} + (hu : AngularPeriodic (2*Real.pi) u) (lam J L K : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (matchedEndingPair u lam k J L K) := by + intro n x + have ht : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + simp only [matchedEndingPair,ht,hu n x,delayedEndingValue_periodic _ _ _ _ _ _ n x] + +lemma matchedEndingPair_terminal {u : Coord3 → Fin 2 → ℝ} {lam k J L K : ℝ} + (hJ : 0 hM x hx)) + +lemma smooth_attachedEnd_cut_layer_rate {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {q χ : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (hχ : ∀ x,|χ x|≤1) {K : ℝ≥0} + (hK : LipschitzOnWith K q (sourceClosedCollarBand (-(1:ℝ)/100) (1/100))) + {a b η : ℝ} (ha : a≠0) (hη : 0<η) (hl : -(1:ℝ)/100≤b-η) (hr : b+η≤1/100) + (htrace : ∀ h,f.val 0 h=mFourierCoeff (fun θ => (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) + (hu : MemLp (cutMatchedValue (fun x => a*(sourceCollarTime x-b)) χ + (fun x => (attachedEndPoissonField s f a b 0 x).re-q x)) 2 volume) + {ε : ℝ} (hε : 0<ε) (hεη : ε≤|a| *η) : + (∫ x in {x | 0 a*(sourceCollarTime x-b)) χ + (fun x => (attachedEndPoissonField s f a b 0 x).re-q x) x)^2)≤ + (sourceCollarVolumeConstant*(2*a^2*‖g‖^2+2*(8*(K:ℝ))^2)/|a|^3)*ε^3 := by + let l := min b (b+ε/a) + let r := max b (b+ε/a) + obtain ⟨hlen,hleft,hright,hiff,hnear⟩ := affine_layer_interval (b:=b) ha hε.le + have heη : ε/|a|≤η := (div_le_iff₀ (abs_pos.mpr ha)).mpr (by simpa [mul_comm] using hεη) + have hl' : -(1:ℝ)/100≤l := hl.trans (by dsimp [l]; linarith) + have hr' : r≤(1:ℝ)/100 := (by dsimp [r]; linarith : r≤b+η).trans hr + have hb : b∈Icc (-(1:ℝ)/100) (1/100) := ⟨by linarith,by linarith⟩ + have hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 ε := fun t ht => (hiff t).mp ht + have hp := ((attachedEndPoissonField_memLp s hs f ha hε.le (min_le_max) hl' hr' hT 0).re.sub + (continuous_sourceBand_memLp hq.continuous hl' hr')).integrable_sq + have hup := hu.integrable_sq + calc + _ ≤ ∫ x in sourceClosedCollarBand l r, + (cutMatchedValue (fun x => a*(sourceCollarTime x-b)) χ + (fun x => (attachedEndPoissonField s f a b 0 x).re-q x) x)^2 := by + apply setIntegral_mono_set hup.integrableOn + (Eventually.of_forall (fun x => sq_nonneg _)) + exact Eventually.of_forall (fun x hx => (hiff _).mpr ⟨hx.1.le,hx.2⟩) + _ ≤ ∫ x in sourceClosedCollarBand l r,((attachedEndPoissonField s f a b 0 x).re-q x)^2 := by + apply integral_mono_ae hup.integrableOn hp + apply Eventually.of_forall + intro x + by_cases ht : 0 (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) + (hu : MemLp (cutMatchedValue (fun x => a*(sourceCollarTime x-b)) χ + (fun x => (attachedEndPoissonField s f a b 0 x).re-q x)) 2 volume) : + Tendsto (fun n : ℕ => ((n:ℝ)+1)^2* + ∫ x in {x | 0 a*(sourceCollarTime x-b)) χ + (fun x => (attachedEndPoissonField s f a b 0 x).re-q x) x)^2) atTop (𝓝 0) := by + obtain ⟨K,hK⟩ := smooth_sourceCollar_lipschitz hq + apply seamLayer_scaled_tendsto_of_cubic_pi (mul_pos (abs_pos.mpr ha) hη) + intro ε hε hεη + exact smooth_attachedEnd_cut_layer_rate hs f hq hχ hK ha hη hl hr htrace g hg hu hε hεη + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/AttachedEndGradientL2.lean b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndGradientL2.lean new file mode 100644 index 0000000000000000000000000000000000000000..f5430d783e75901698d0683c99c091fb1a99f9ed --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndGradientL2.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedEndL2 +import OAI.Analysis.Conductivity.Flux.AttachedEndDifferential + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix +open scoped ENNReal + +lemma sourceAngularCollarMeasure_self (b : ℝ) : sourceAngularCollarMeasure b b=0 := by + simp [sourceAngularCollarMeasure] + +lemma sourceCollarTime_level_null {b : ℝ} (hb : b∈Icc (-(1:ℝ)/100) (1/100)) : + volume {y : Fin 3 → ℝ | sourceCollarTime y=b}=0 := by + have hle := (sourceClosedCollarBand_measure_le hb.1 hb.2).trans + (sourcePhysicalCollarMeasure_le (le_refl b) hb.1 hb.2) + rw [sourceAngularCollarMeasure_self,smul_zero] at hle + have he := Measure.le_iff.mp hle univ MeasurableSet.univ + have hs : sourceClosedCollarBand b b={y : Fin 3 → ℝ | sourceCollarTime y=b} := by + ext y; simp [sourceClosedCollarBand] + simp only [Measure.restrict_apply_univ,Measure.coe_zero,Pi.zero_apply,hs] at he + exact le_antisymm he bot_le + +lemma sourceColevel_ae_ne {b : ℝ} (hb : b∈Icc (-(1:ℝ)/100) (1/100)) : + ∀ᵐ y : Fin 3 → ℝ,sourceCollarTime y≠b := by + rw [ae_iff] + simpa only [not_not] using sourceCollarTime_level_null hb + +lemma attachedEndPoisson_grad_bound (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) : + ∃ C : ℝ,0 (attachedEndPoissonField s f a b 0 y).re) y (Pi.single k 1)|≤ + C*∑ d : Fin 3,‖attachedEndPoissonField s f a b d.succ y‖ := by + obtain ⟨C,hC,hbound⟩ := sourceCartesianGradient_uniform_bound + refine ⟨C*(|a|+1),mul_pos hC (by positivity),?_⟩ + intro k + filter_upwards [sourceCollar_open_charts_ae] with y hy hb ht + obtain ⟨i,j,x,hx,rfl⟩ := hy hb + rw [sourceCollarPiece_time_open hx] at ht + rw [attachedEndPoisson_real_fderiv s hs f a b i j hx ht,dotProduct_single,mul_one] + rw [Matrix.mulVec] + apply (Finset.abs_sum_le_sum_abs _ _).trans + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro d _ + rw [abs_mul,endAxialMatrix,Matrix.mulVec_diagonal,abs_mul] + have hd : |![a,1,1] d|≤|a|+1 := by + fin_cases d + · change |a|≤|a|+1; linarith + · change |(1:ℝ)|≤|a|+1; rw [abs_one]; linarith [abs_nonneg a] + · change |(1:ℝ)|≤|a|+1; rw [abs_one]; linarith [abs_nonneg a] + have he := Complex.abs_re_le_norm (attachedEndPoissonField s f a b d.succ (sourceCollarPiece i j x)) + calc + _ ≤ C*((|a|+1)*‖attachedEndPoissonField s f a b d.succ (sourceCollarPiece i j x)‖) := + mul_le_mul (hbound i j x (sourceCollarOpenBox_subset hx) k d) + (mul_le_mul hd he (abs_nonneg _) (by positivity)) (by positivity) hC.le + _ = _ := by ring + +lemma attachedEndPoisson_grad_memLp (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (k : Fin 3) : + MemLp (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y (Pi.single k 1)) + 2 (volume.restrict (sourceClosedCollarBand l r)) := by + obtain ⟨C,hC,hbound⟩ := attachedEndPoisson_grad_bound s hs f a b + have hjet (d : Fin 3) := (attachedEndPoissonField_memLp s hs f ha hR hlr hl hr hT d.succ).norm + have hsum : MemLp (fun y => C*∑ d : Fin 3,‖attachedEndPoissonField s f a b d.succ y‖) 2 + (volume.restrict (sourceClosedCollarBand l r)) := + (memLp_finsetSum Finset.univ (fun d _ => hjet d)).const_mul C + apply hsum.mono' (measurable_fderiv_apply_const ℝ _ _).aestronglyMeasurable + have hband : MeasurableSet (sourceClosedCollarBand l r) := + measurableSet_Icc.preimage measurable_sourcePhysicalCoordinates.fst + filter_upwards [ae_restrict_mem hband,ae_restrict_of_ae (hbound k), + ae_restrict_of_ae (sourceColevel_ae_ne hb)] with y hy hbd hne + rw [Real.norm_eq_abs] + exact hbd ⟨hl.trans hy.1,hy.2.trans hr⟩ + (lt_of_le_of_ne (hT _ hy).1 (Ne.symm (mul_ne_zero ha (sub_ne_zero.mpr hne)))) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/AttachedEndL2.lean b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndL2.lean new file mode 100644 index 0000000000000000000000000000000000000000..a58e59c1e3adf052a1647c912ddb7e084c793f07 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndL2.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarBand +import OAI.Analysis.Conductivity.Fourier.AttachedEndPoisson +import OAI.Analysis.Conductivity.Geometry.AffineCylinder + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +def attachedEndPoissonJet (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (j : Fin 4) : + Lp ℂ 2 (sourcePhysicalCollarMeasure l r) := + sourceCollarPullback hlr hl hr (affineEndPullback ha hT (endPoissonJet s hs R hR f j)) + +lemma attachedEndPoissonJet_ae (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (j : Fin 4) : + attachedEndPoissonJet s hs f ha hR hlr hl hr hT j=ᵐ[sourcePhysicalCollarMeasure l r] + attachedEndPoissonField s f a b j := by + have he : affineEndPullback ha hT (endPoissonJet s hs R hR f j)=ᵐ[sourceCylinderMeasure l r] + endPoissonField s f j ∘ affineEndCoordinates a b := + affineEndPullback_ae_of_ae ha hT _ (endPoissonJet_ae s hs R hR f j) + have hp := sourceCollarPullback_ae_of_ae hlr hl hr _ he + change sourceCollarPullback hlr hl hr (affineEndPullback ha hT (endPoissonJet s hs R hR f j))=ᵐ[sourcePhysicalCollarMeasure l r] _ + exact hp + +lemma attachedEndPoissonField_memLp (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (j : Fin 4) : + MemLp (attachedEndPoissonField s f a b j) 2 + (volume.restrict (sourceClosedCollarBand l r)) := + sourceClosedCollarBand_memLp hl hr + ((memLp_congr_ae (attachedEndPoissonJet_ae s hs f ha hR hlr hl hr hT j)).mp + (Lp.memLp (attachedEndPoissonJet s hs f ha hR hlr hl hr hT j))) + +lemma attachedEndPoissonField_angular_memLp (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (j : Fin 4) : + MemLp (fun z : ℝ×UnitAddTorus (Fin 2) => attachedEndPoissonField s f a b j + (sourceAngularCollar z.1 z.2)) 2 ((volume.restrict (Ioc l r)).prod volume) := by + rw [←sourceCylinderMeasure_eq] + have h : MemLp (endPoissonField s f j ∘ affineEndCoordinates a b) 2 (sourceCylinderMeasure l r) := + (memLp_congr_ae (affineEndPullback_ae_of_ae ha hT _ + (endPoissonJet_ae s hs R hR f j))).mp (Lp.memLp (affineEndPullback ha hT + (endPoissonJet s hs R hR f j))) + apply (memLp_congr_ae _).mp h + have ht : ∀ᵐ z∂sourceCylinderMeasure l r,z.1∈Ioc l r := + Measure.quasiMeasurePreserving_fst.ae (ae_restrict_mem measurableSet_Ioc) + filter_upwards [ht] with z hz + exact (attachedEndPoissonField_angular s f a b j ⟨hl.trans hz.1.le,hz.2.trans hr⟩ z.2).symm + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/AttachedEndLayer.lean b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndLayer.lean new file mode 100644 index 0000000000000000000000000000000000000000..6fddd8aaf1c27b305da3db715b438614b0995f7d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/AttachedEndLayer.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedEndL2 +import OAI.Analysis.Conductivity.Variational.PhysicalStripIntegral +import OAI.Analysis.Conductivity.Geometry.SmoothCollarRate + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal + +lemma continuous_angular_memLp {q : (Fin 3 → ℝ) → ℝ} (hq : Continuous q) + {l r : ℝ} (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + MemLp (fun z : ℝ×UnitAddTorus (Fin 2) => q (sourceAngularCollar z.1 z.2)) 2 + ((volume.restrict (Ioc l r)).prod volume) := by + obtain ⟨M,hM⟩ := (isCompact_sourceClosedCollarBand (le_refl (-(1:ℝ)/100)) + (le_refl ((1:ℝ)/100))).exists_bound_of_continuousOn hq.continuousOn + apply MemLp.of_bound (hq.comp continuous_uncurry_sourceAngularCollar).aestronglyMeasurable M + have ht : ∀ᵐ z : ℝ×UnitAddTorus (Fin 2)∂(volume.restrict (Ioc l r)).prod volume,z.1∈Ioc l r := + Measure.quasiMeasurePreserving_fst.ae (ae_restrict_mem measurableSet_Ioc) + filter_upwards [ht] with z hz + apply hM + change sourceCollarTime (sourceAngularCollar z.1 z.2)∈Icc (-(1:ℝ)/100) (1/100) + rw [sourceAngular_time ⟨hl.trans hz.1.le,hz.2.trans hr⟩] + exact ⟨hl.trans hz.1.le,hz.2.trans hr⟩ + +lemma smooth_attachedEnd_fiber_rate_volume {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) {K : ℝ≥0} + (hK : LipschitzOnWith K q (sourceClosedCollarBand (-(1:ℝ)/100) (1/100))) + {a b t : ℝ} (hb : b∈Icc (-(1:ℝ)/100) (1/100)) (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (hpos : 0 (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) : + (∫ θ,((attachedEndPoissonField s f a b 0 (sourceAngularCollar t θ)).re- + q (sourceAngularCollar t θ))^2)≤(2*a^2*‖g‖^2+2*(8*(K:ℝ))^2)*(t-b)^2 := by + rw [unitTorus_volume_eq_normalized] + exact smooth_attachedEnd_fiber_rate hs f hq hK hb ht hpos htrace g hg + +lemma smooth_attachedEnd_band_rate {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) {K : ℝ≥0} + (hK : LipschitzOnWith K q (sourceClosedCollarBand (-(1:ℝ)/100) (1/100))) + {a b l r R d : ℝ} (ha : a≠0) (hR : 0≤R) (_ : 0≤d) + (hb : b∈Icc (-(1:ℝ)/100) (1/100)) (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (hnear : ∀ t∈Icc l r,|t-b|≤d) + (htrace : ∀ h,f.val 0 h=mFourierCoeff (fun θ => (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) : + (∫ y in sourceClosedCollarBand l r,((attachedEndPoissonField s f a b 0 y).re-q y)^2)≤ + sourceCollarVolumeConstant*(r-l)*((2*a^2*‖g‖^2+2*(8*(K:ℝ))^2)*d^2) := by + apply sourceClosedBand_sq_integral_le + ((Complex.measurable_re.comp (measurable_attachedEndPoissonField s f a b 0)).sub hq.continuous.measurable) + hlr hl hr + · exact ((attachedEndPoissonField_angular_memLp s hs f ha hR hl hr hT 0).re.sub + (continuous_angular_memLp hq.continuous hl hr)).integrable_sq + have ht : ∀ᵐ t∂volume.restrict (Ioc l r),t≠b := by + apply ae_restrict_of_ae + rw [ae_iff] + simpa only [not_not,Set.ofPred_eq_eq_singleton] using (measure_singleton b : volume ({b}:Set ℝ)=0) + filter_upwards [ae_restrict_mem measurableSet_Ioc,ht] with t ht hne + have htb : t-b≠0 := sub_ne_zero.mpr hne + have hpos : 0 Lp ℂ 2 (sourceCylinderMeasure 0 R)) (𝕜:=ℂ) j).restrictScalars ℝ).comp ((endPoissonCLM s hs R hR).restrictScalars ℝ)))) + +lemma attachedEndFlatCLM_ae (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {a b l r R : ℝ} + (ha : a≠0) (hR : 0≤R) (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) (j : Fin 4) : + attachedEndFlatCLM s hs ha hR hlr hl hr hT j f=ᵐ[volume.restrict (sourceClosedCollarBand l r)] + attachedEndPoissonField s f a b j := by + apply (Lp.coeFn_LpToLpOfMeasureLeSMul (c:=1) (by simp) + (by simpa only [one_smul] using sourceClosedCollarBand_measure_le hl hr) _).trans + exact (Measure.absolutelyContinuous_of_le (sourceClosedCollarBand_measure_le hl hr)).ae_eq + (attachedEndPoissonJet_ae s hs f ha hR hlr hl hr hT j) + +lemma attachedEndPoisson_real_fderiv_add_ae (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f g : spectralTraceGraph (torusRate s)) (a b : ℝ) : + ∀ᵐ y : Fin 3 → ℝ,y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) → + 0 (attachedEndPoissonField s (f+g) a b 0 y).re) y= + fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y+ + fderiv ℝ (fun y => (attachedEndPoissonField s g a b 0 y).re) y := by + filter_upwards [attachedEndPoisson_real_differentiable_ae s hs f a b, + attachedEndPoisson_real_differentiable_ae s hs g a b] with y hf hg hy ht + have he : (fun y => (attachedEndPoissonField s (f+g) a b 0 y).re)=ᶠ[𝓝 y] + (fun y => (attachedEndPoissonField s f a b 0 y).re+(attachedEndPoissonField s g a b 0 y).re) := by + filter_upwards [((attachedEndTime_lipschitz a b).choose_spec.continuous.continuousAt).eventually + (lt_mem_nhds ht)] with z hz + change (endPoissonField s (f+g) 0 _).re=_ + rw [endPoissonField_add_pos s hs f g 0 hz] + rfl + rw [he.fderiv_eq] + exact fderiv_fun_add (hf hy ht) (hg hy ht) + +lemma attachedEndPoisson_real_fderiv_rsmul_ae (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (c : ℝ) (f : spectralTraceGraph (torusRate s)) (a b : ℝ) : + ∀ᵐ y : Fin 3 → ℝ,y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) → + 0 (attachedEndPoissonField s (c•f) a b 0 y).re) y= + c • fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y := by + filter_upwards [attachedEndPoisson_real_differentiable_ae s hs f a b] with y hf hy ht + have he : (fun y => (attachedEndPoissonField s (c•f) a b 0 y).re)=ᶠ[𝓝 y] + (fun y => c*(attachedEndPoissonField s f a b 0 y).re) := by + filter_upwards [((attachedEndTime_lipschitz a b).choose_spec.continuous.continuousAt).eventually + (lt_mem_nhds ht)] with z hz + change (endPoissonField s (c•f) 0 _).re=_ + rw [endPoissonField_rsmul_pos s hs c f 0 hz] + simp [attachedEndPoissonField] + rw [he.fderiv_eq] + exact fderiv_const_mul (hf hy ht) c + +lemma attachedEndPoisson_grad_bound_uniform (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (a b : ℝ) : + ∃ C : ℝ,0 (attachedEndPoissonField s f a b 0 y).re) y (Pi.single k 1)|≤ + C*∑ d : Fin 3,‖attachedEndPoissonField s f a b d.succ y‖ := by + obtain ⟨C,hC,hbound⟩ := sourceCartesianGradient_uniform_bound + refine ⟨C*(|a|+1),mul_pos hC (by positivity),?_⟩ + intro f k + filter_upwards [sourceCollar_open_charts_ae] with y hy hb ht + obtain ⟨i,j,x,hx,rfl⟩ := hy hb + rw [sourceCollarPiece_time_open hx] at ht + rw [attachedEndPoisson_real_fderiv s hs f a b i j hx ht,dotProduct_single,mul_one] + rw [Matrix.mulVec] + apply (Finset.abs_sum_le_sum_abs _ _).trans + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro d _ + rw [abs_mul,endAxialMatrix,Matrix.mulVec_diagonal,abs_mul] + have hd : |![a,1,1] d|≤|a|+1 := by + fin_cases d + · change |a|≤|a|+1; linarith + · change |(1:ℝ)|≤|a|+1; rw [abs_one]; linarith [abs_nonneg a] + · change |(1:ℝ)|≤|a|+1; rw [abs_one]; linarith [abs_nonneg a] + have he := Complex.abs_re_le_norm (attachedEndPoissonField s f a b d.succ (sourceCollarPiece i j x)) + calc + _ ≤ C*((|a|+1)*‖attachedEndPoissonField s f a b d.succ (sourceCollarPiece i j x)‖) := + mul_le_mul (hbound i j x (sourceCollarOpenBox_subset hx) k d) + (mul_le_mul hd he (abs_nonneg _) (by positivity)) (by positivity) hC.le + _ = _ := by ring + +lemma lp_norm_le_sum_norm_of_ae {X ι : Type*} [MeasurableSpace X] [Fintype ι] + {μ : Measure X} {u : Lp ℝ 2 μ} {v : ι → Lp ℂ 2 μ} {C : ℝ} (hC : 0≤C) + (h : ∀ᵐ x∂μ,‖u x‖≤C*∑ i,‖v i x‖) : ‖u‖≤C*∑ i,‖v i‖ := by + let w : ι → Lp ℝ 2 μ := fun i => ((Lp.memLp (v i)).norm).toLp (fun x => ‖v i x‖) + have he (i : ι) : w i=ᵐ[μ] (fun x => ‖v i x‖) := ((Lp.memLp (v i)).norm).coeFn_toLp + have hn (i : ι) : ‖w i‖=‖v i‖ := by + dsimp only [w] + rw [Lp.norm_toLp,eLpNorm_norm (v i) (Lp.memLp (v i)).aestronglyMeasurable,Lp.norm_def] + have hh : ‖u‖≤‖C • ∑ i,w i‖ := by + apply Lp.norm_le_norm_of_ae_le + filter_upwards [h,Lp.coeFn_smul C (∑ i,w i),Lp.coeFn_fun_finsetSum Finset.univ w, + ae_all_iff.mpr he] with x hx hs hsum hw + rw [hs] + simp only [Pi.smul_apply,smul_eq_mul,hsum,hw] + simpa only [Real.norm_eq_abs,abs_of_nonneg (mul_nonneg hC (Finset.sum_nonneg (fun i _ => norm_nonneg (v i x))))] using hx + calc + ‖u‖ ≤ ‖C • ∑ i,w i‖ := hh + _ = C*‖∑ i,w i‖ := by rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg hC] + _ ≤ C*∑ i,‖w i‖ := mul_le_mul_of_nonneg_left (norm_sum_le _ _) hC + _ = C*∑ i,‖v i‖ := by simp only [hn] + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a b l r R : ℝ} (ha : a≠0) (hR : 0≤R) + (hb : b∈Icc (-(1:ℝ)/100) (1/100)) (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + +include ha hb hl hr hT in +lemma attachedEndBand_positive_ae : + ∀ᵐ y∂volume.restrict (sourceClosedCollarBand l r), + y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) ∧ 0 fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y (Pi.single k 1)) := + (attachedEndPoisson_grad_memLp s hs f ha hR hb hlr hl hr hT k).coeFn_toLp + +lemma attachedEndGradientL_bound (k : Fin 3) : + ∃ C : ℝ,∀ f,‖attachedEndGradientL s hs ha hR hb hlr hl hr hT k f‖≤C*‖f‖ := by + obtain ⟨C,hC,hbound⟩ := attachedEndPoisson_grad_bound_uniform s hs a b + refine ⟨C*∑ d : Fin 3,‖attachedEndFlatCLM s hs ha hR hlr hl hr hT d.succ‖,fun f => ?_⟩ + have h : ‖attachedEndGradientL s hs ha hR hb hlr hl hr hT k f‖≤ + C*∑ d : Fin 3,‖attachedEndFlatCLM s hs ha hR hlr hl hr hT d.succ f‖ := by + apply lp_norm_le_sum_norm_of_ae hC.le + filter_upwards [attachedEndGradientL_ae s hs ha hR hb hlr hl hr hT k f, + ae_all_iff.mpr (fun d : Fin 3 => attachedEndFlatCLM_ae s hs f ha hR hlr hl hr hT d.succ), + ae_restrict_of_ae (hbound f k),attachedEndBand_positive_ae ha hb hl hr hT] with x hx hj hb hxpos + rw [hx,Real.norm_eq_abs] + simp only [hj] + exact hb hxpos.1 hxpos.2 + calc + _ ≤ C*∑ d : Fin 3,‖attachedEndFlatCLM s hs ha hR hlr hl hr hT d.succ f‖ := h + _ ≤ C*∑ d : Fin 3,‖attachedEndFlatCLM s hs ha hR hlr hl hr hT d.succ‖*‖f‖ := + mul_le_mul_of_nonneg_left (Finset.sum_le_sum (fun d _ => ContinuousLinearMap.le_opNorm _ _)) hC.le + _ = _ := by rw [← Finset.sum_mul]; ring + +def attachedEndGradientCLM (k : Fin 3) : + spectralTraceGraph (torusRate s) →L[ℝ] Lp ℝ 2 (volume.restrict (sourceClosedCollarBand l r)) := + (attachedEndGradientL s hs ha hR hb hlr hl hr hT k).mkContinuousOfExistsBound + (attachedEndGradientL_bound s hs ha hR hb hlr hl hr hT k) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/AttachedFlatTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/AttachedFlatTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..a818399148cea1fb9c41d2a3d690078e2c5902b5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/AttachedFlatTransport.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalFlatTransport +import OAI.Analysis.Conductivity.Flux.AttachedFlatTensor + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def attachedPhysicalFlatTensor (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + attachedFlatTensor s a i j (sourceCollarInverse i j y) + +def attachedPhysicalFlatGradient (a : ℝ) (i j : Fin 4) + (v : (Fin 3 → ℝ) → Fin 3 → ℝ) (y : Fin 3 → ℝ) : Fin 3 → ℝ := + attachedCartesianMatrix a i j (sourceCollarInverse i j y)*ᵥ + v (sourceCollarInverse i j y) + +theorem attachedPhysicalFlat_energy_integral (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (i j : Fin 4) {l r : ℝ} (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (v w : (Fin 3 → ℝ) → Fin 3 → ℝ) : + (∫ y in sourceCollarPiece i j '' sourceExtendedBox l r, + attachedPhysicalFlatGradient a i j v y ⬝ᵥ + (attachedPhysicalFlatTensor s a i j y*ᵥattachedPhysicalFlatGradient a i j w y))= + ∫ x in sourceExtendedBox l r, + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (v x ⬝ᵥ (flatCylinderMatrix s*ᵥw x)) := by + rw [sourceExtended_integral i j hl hr] + apply setIntegral_congr_fun measurableSet_Icc + intro x hx + have hx' : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100) := by + obtain ⟨ht,hi,hj⟩ := mem_sourceExtendedBox.mp hx + exact mem_sourceExtendedBox.mpr ⟨⟨hl.trans ht.1,ht.2.trans hr⟩,hi,hj⟩ + simp only [attachedPhysicalFlatGradient,attachedPhysicalFlatTensor, + sourceCollarInverse_extended i j hl hr hx,smul_eq_mul] + rw [sourceCollarDerivative_det,←sourceCollarJacobian_det] + exact attachedFlatTensor_energy_density s ha i j hx' (v x) (w x) + +lemma attachedPhysicalFlatTensor_symmetric (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : + (attachedPhysicalFlatTensor s a i j y)ᵀ=attachedPhysicalFlatTensor s a i j y := + attachedFlatTensor_symmetric s a i j _ + +theorem attachedPhysicalFlatTensor_elliptic (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a : ℝ} (ha : a≠0) (i j : Fin 4) : + ∃ c C : ℝ,0 (attachedEndPoissonField s f a b 0 y).re) (sourceCollarPiece i j x) v= + attachedPhysicalFlatGradient a i j + (fun x k => (endPoissonField s f k.succ + (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re) + (sourceCollarPiece i j x) ⬝ᵥ v := by + simp only [attachedPhysicalFlatGradient,sourceCollarInverse_point i j hx] + exact attachedCartesianMatrix_poisson_derivative s hs f a b i j hx ht v + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/BranchFiniteEnding.lean b/lean/OAI/Analysis/Conductivity/Branching/BranchFiniteEnding.lean new file mode 100644 index 0000000000000000000000000000000000000000..1784c4c3f4697f269d0bd8007756f9bc868e64c7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/BranchFiniteEnding.lean @@ -0,0 +1,189 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.WeakPairOverlap +import OAI.Analysis.Conductivity.Branching.BranchOutputNormalization + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped Matrix.Norms.Elementwise + +def branchFinitePair {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (i : Fin 3) + (z : TorusEndingData s (branchNormalize i f)) : WeakFiniteTensorPair {x : Coord3 | z.d (z.w.G x).col k) j := by + change (linearColumnsPullback (ContinuousLinearEquiv.refl ℝ Coord3) + (branchNormalizeEquiv i) z.w.G (x-0)).col j=_ + rw [sub_zero,linearColumnsPullback_col] + ext k + fin_cases i <;> fin_cases j <;> + simp [operatorMatrix,branchNormalizeEquiv_apply,branchNormalize,linearFluxPullback, + Fin.sum_univ_two,Pi.single_apply,Matrix.col_apply] + ring + +lemma branchFinitePair_initial {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {f : Fin 2 → TorusL2} (i : Fin 3) (z : TorusEndingData s (branchNormalize i f)) + (x : Coord3) (hx : x 0∈Ioo z.d (z.d+z.e)) : + (branchFinitePair i z).v x=fun j => torusAffineField s (centralBasisSlopes j i) (f j) x := by + rw [branchFinitePair_v,z.initial_field x hx] + change branchNormalize i (fun j => torusAffineField s (normalizedSlope j) + (branchNormalize i f j) x)=_ + rw [branchNormalize_affineField hs i normalizedSlope (branchNormalize i f) (z.d_pos.trans hx.1), + branchNormalize_normalized_slope,branchNormalize_involutive] + +lemma branchFinitePair_terminal {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (i : Fin 3) + (z : TorusEndingData s (branchNormalize i f)) (x : Coord3) (hx : z.R≤x 0) : + (branchFinitePair i z).v x=fun j => centralBasisSlopes j i*x 0+(mFourierCoeff (f j) 0).re := by + rw [branchFinitePair_v] + have he : z.w.v x=(fun j => normalizedSlope j*x 0)+ + (fun j => (mFourierCoeff (branchNormalize i f j : TorusL2) 0).re) := by + ext j + exact z.terminal_component j x hx + rw [he,branchNormalize_add] + have hm := (branchNormalize_means i (branchNormalize i f)).trans + (by rw [branchNormalize_involutive]) + rw [hm] + have hs : branchNormalize i (fun j => normalizedSlope j*x 0)= + fun j => centralBasisSlopes j i*x 0 := by + ext j + fin_cases i <;> fin_cases j <;> simp [branchNormalize,normalizedSlope,centralBasisSlopes] + rw [hs] + rfl + +lemma branchFinitePair_terminal_flux {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (i : Fin 3) + (z : TorusEndingData s (branchNormalize i f)) (x : Coord3) (hx : z.R (z.w.G x).col k)=(fun k => normalizedSlope k • Pi.single 0 1) := + funext fun k => z.terminal_flux k x hx + rw [he] + fin_cases i <;> fin_cases j <;> simp [branchNormalize,normalizedSlope,centralBasisSlopes] + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped Matrix.Norms.Elementwise + +variable {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (i : Fin 3) + (z : TorusEndingData s (branchNormalize i f)) + +lemma branchFinitePair_periodic_v : AngularPeriodic (2*Real.pi) (branchFinitePair i z).v := by + intro n x + simp only [branchFinitePair_v,z.periodic_v n x] + +lemma branchFinitePair_initial_E (x : Coord3) (hx : x 0∈Icc z.d (z.d+z.e)) : + (branchFinitePair i z).E x=flatBackgroundTensor s := by + simpa only [branchFinitePair,WeakFiniteTensorPair.output_E] using z.initial_E x hx + +lemma branchFinitePair_periodic_E : AngularPeriodic (2*Real.pi) (branchFinitePair i z).E := by + simpa only [branchFinitePair,WeakFiniteTensorPair.output_E] using z.periodic_E + +lemma branchFinitePair_initial_flux + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) (hx : x 0∈Ioo z.d (z.d+z.e)) : + ((branchFinitePair i z).G x).col j= + flatModeFlux s (torusAffineField s (centralBasisSlopes j i) (f j)) x := by + apply (branchFinitePair i z).flux_on_flat_patch + (V:={x : Coord3 | x 0∈Ioo z.d (z.d+z.e)}) + (isOpen_Ioo.preimage (continuous_apply 0)) s + (fun x hx => branchFinitePair_initial_E i z x ⟨hx.1.le,hx.2.le⟩) + (fun x j => torusAffineField s (centralBasisSlopes j i) (f j) x) + (contDiffOn_pi.mpr fun j => ((torusAffineField_smooth hs _ _).of_le + (show (2 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono + (fun y hy => z.d_pos.trans hy.1)) + (fun x hx => branchFinitePair_initial hs i z x hx) j x hx + +def branchCorrection (j : Fin 2) : Coord3 → ℝ := + torusEndingCorrection z.d z.e (fun x => (branchFinitePair i z).v x j) + (torusAffineField s (centralBasisSlopes j i) (f j)) + +def branchFluxCorrection (j : Fin 2) : Coord3 → Coord3 := + torusEndingFluxCorrection z.d z.e (fun x => ((branchFinitePair i z).G x).col j) + (flatModeFlux s (torusAffineField s (centralBasisSlopes j i) (f j))) + +lemma branchCorrection_C2 + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) : ContDiff ℝ 2 (branchCorrection i z j) := by + exact torusEndingCorrection_C2 z.e_pos (contDiff_pi.mp (branchFinitePair i z).smooth j) + (((torusAffineField_smooth hs _ _).of_le + (show (2 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono + (fun x hx => z.d_pos.trans hx)) + (fun x hx => congrFun (branchFinitePair_initial hs i z x hx) j) + +lemma branchCorrection_periodic (j : Fin 2) : + AngularPeriodic (2*Real.pi) (branchCorrection i z j) := by + exact torusEndingCorrection_periodic + (fun n x => congrFun (branchFinitePair_periodic_v i z n x) j) + (torusAffineField_periodic _ _ _) + +lemma branchCorrection_zero + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) (hx : x 0 congrFun (branchFinitePair_initial hs i z y hy) j) + (by linarith [z.e_pos] : x 0 z.d_pos.trans hx)) + (fun x hx => branchFinitePair_initial_flux i z hs j x hx) + +lemma branchFluxCorrection_periodic (j : Fin 2) : + AngularPeriodic (2*Real.pi) (branchFluxCorrection i z j) := by + exact torusEndingFluxCorrection_periodic + (fun n x => congrArg (fun M : Matrix (Fin 3) (Fin 2) ℝ => M.col j) + ((branchFinitePair i z).flux_periodic (branchFinitePair_periodic_v i z) + (branchFinitePair_periodic_E i z) n x)) + (flatModeFlux_periodic (torusAffineField_periodic _ _ _)) + +lemma branchFluxCorrection_divergence + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) : coordinateDivergence (branchFluxCorrection i z j) x=0 := by + exact torusEndingFluxCorrection_divergence z.e_pos ((branchFinitePair i z).component_flux_C1 j) + (((flatModeFlux_smoothOn (axial_halfspace_open 0) (torusAffineField_smooth hs _ _)).of_le + (show (1 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono + (fun x hx => z.d_pos.trans hx)) + (fun x hx => branchFinitePair_initial_flux i z hs j x hx) + (fun x hx => (branchFinitePair i z).flux_divergence (axial_halfspace_open z.d) j x hx) + (fun x hx => torusAffineField_flux_divergence hs _ _ (z.d_pos.trans hx)) x + +lemma branchFluxCorrection_zero + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) (hx : x 0=0) : branchFluxCorrection i z j x=0 := by + exact (torusEndingFluxCorrection_initial_zero z.e_pos + (fun y hy => branchFinitePair_initial_flux i z hs j y hy) + (by rw [hx]; linarith [z.d_pos,z.e_pos])).eq_of_nhds + +lemma branchFluxCorrection_terminal (j : Fin 2) (x : Coord3) (hx : z.R fin_cases j <;> simp [branchNormalize] + +lemma branchNormalize_add (i : Fin 3) (u v : Fin 2 → E) : + branchNormalize i (u+v)=branchNormalize i u+branchNormalize i v := by + ext j + fin_cases i <;> fin_cases j <;> simp [branchNormalize] <;> abel + +variable [Module ℝ E] + +def branchNormalizeLinear (i : Fin 3) : (Fin 2 → E) →ₗ[ℝ] (Fin 2 → E) where + toFun := branchNormalize i + map_add' := branchNormalize_add i + map_smul' c u := by + ext j + fin_cases i <;> fin_cases j <;> simp [branchNormalize,smul_sub] + +def branchNormalizeEquiv (i : Fin 3) : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ) := + ({ toLinearMap := branchNormalizeLinear i + invFun := branchNormalize i + left_inv := branchNormalize_involutive i + right_inv := branchNormalize_involutive i } : + (Fin 2 → ℝ) ≃ₗ[ℝ] (Fin 2 → ℝ)).toContinuousLinearEquiv + +@[simp] lemma branchNormalizeEquiv_apply (i : Fin 3) (u : Fin 2 → ℝ) : + branchNormalizeEquiv i u=branchNormalize i u := rfl + +lemma branchNormalize_basis_slopes (i : Fin 3) : + branchNormalize i (fun j => centralBasisSlopes j i)=normalizedSlope := by + ext j + fin_cases i <;> fin_cases j <;> norm_num [branchNormalize,centralBasisSlopes,normalizedSlope] + +lemma branchNormalize_normalized_slope (i : Fin 3) : + branchNormalize i normalizedSlope=(fun j => centralBasisSlopes j i) := by + rw [←branchNormalize_basis_slopes i,branchNormalize_involutive i] + +lemma branchNormalize_affineField {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (i : Fin 3) (κ : Fin 2 → ℝ) (f : Fin 2 → TorusL2) {x : Coord3} (hx : 0 torusAffineField s (κ j) (f j) x)= + fun j => torusAffineField s (branchNormalize i κ j) (branchNormalize i f j) x := by + ext j + fin_cases i <;> fin_cases j <;> + simp [branchNormalize,torusAffineField,torusRealContinuation_neg, + torusRealContinuation_sub hs _ _ hx] <;> ring + +lemma branchNormalize_means (i : Fin 3) (f : Fin 2 → TorusL2) : + branchNormalize i (fun j => (mFourierCoeff (f j) 0).re)= + fun j => (mFourierCoeff (branchNormalize i f j : TorusL2) 0).re := by + fin_cases i + · ext j + fin_cases j + · change -(mFourierCoeff (f 0) 0).re=(mFourierCoeff (-f 0 : TorusL2) 0).re + rw [mFourierCoeff_Lp_neg,Complex.neg_re] + · change (mFourierCoeff (f 1) 0).re-(mFourierCoeff (f 0) 0).re= + (mFourierCoeff (f 1-f 0 : TorusL2) 0).re + simp only [sub_eq_add_neg] + rw [mFourierCoeff_Lp_add,mFourierCoeff_Lp_neg,Complex.add_re,Complex.neg_re] + · rfl + · ext j + fin_cases j <;> rfl + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped Matrix.Norms.Elementwise + +namespace TorusEndingData +variable {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (z : TorusEndingData s f) + +lemma terminal_component (j : Fin 2) (x : Coord3) (hx : z.R≤x 0) : + z.w.v x j=normalizedSlope j*x 0+(mFourierCoeff (f j) 0).re := by + rw [z.terminal_v x hx] + fin_cases j <;> simp [normalizedSlope] + +lemma terminal_gradient (j : Fin 2) (x : Coord3) (hx : z.R z.w.v x j)=ᶠ[𝓝 x] + (fun x => normalizedSlope j*x 0+(mFourierCoeff (f j) 0).re) := by + filter_upwards [(axial_halfspace_open z.R).mem_nhds hx] with y hy + exact z.terminal_component j y hy.le + have hd := (((ContinuousLinearMap.proj (0 : Fin 3) : Coord3 →L[ℝ] ℝ).hasFDerivAt + (x:=x)).const_mul (normalizedSlope j)).add_const ((mFourierCoeff (f j) 0).re) + ext i + change fderiv ℝ z.w.v x (Pi.single i 1) j=normalizedSlope j*((Pi.single (0:Fin 3) (1:ℝ) : Coord3) i) + rw [←potential_component_fderiv (z.w.smooth.differentiable (by norm_num)) j, + he.fderiv_eq (𝕜 := ℝ)] + change fderiv ℝ (fun x => normalizedSlope j * + (ContinuousLinearMap.proj (0 : Fin 3) : Coord3 →L[ℝ] ℝ) x + + (mFourierCoeff (f j) 0).re) x (Pi.single i 1)=_ + rw [hd.fderiv] + fin_cases i <;> simp + +lemma terminal_flux (j : Fin 2) (x : Coord3) (hx : z.R (z.w.G x).col j)=ᵐ[volume.restrict {x : Coord3 | z.R normalizedSlope j • Pi.single 0 1) := by + filter_upwards [ae_restrict_of_ae z.w.constitution, + ae_restrict_mem (axial_halfspace_open z.R).measurableSet] with y hy hyR + rw [←hy] + change z.w.E y*ᵥ(gradientColumns (fderiv ℝ z.w.v y)).col j=_ + rw [z.terminal_gradient j y hyR,Matrix.mulVec_smul,z.terminal_E y hyR.le] + exact (Measure.eqOn_open_of_ae_eq ha (axial_halfspace_open z.R) + (z.w.component_flux_C1 j).continuous.continuousOn continuous_const.continuousOn) hx + +lemma fluxCorrection_at_zero + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) (hx : x 0=0) : z.fluxCorrection j x=0 := by + exact (torusEndingFluxCorrection_initial_zero z.e_pos (fun y hy => z.initial_flux hs j y hy) + (by rw [hx]; linarith [z.d_pos,z.e_pos])).eq_of_nhds + +lemma fluxCorrection_at_terminal (j : Fin 2) (x : Coord3) (hx : z.R cascadePhase D k n (x 0)) := by + unfold cascadePhase + fun_prop + exact (isClosed_le hc continuous_const).measurableSet.union + (isClosed_le continuous_const (continuous_const.mul (continuous_apply 0))).measurableSet + +lemma cascadeIndex_spec {D k : ℝ} (x : Coord3) (ht₀ : 0≤k*x 0) (ht : k*x 0<2*D) : + 0≤cascadePhase D k (cascadeIndex D k x) (x 0) ∧ + cascadePhase D k (cascadeIndex D k x) (x 0)≤D := by + have hs := Nat.find_spec (exists_cascade_index D k (x 0)) + have hu : cascadePhase D k (cascadeIndex D k x) (x 0)≤D := hs.resolve_right (not_le.mpr ht) + refine ⟨?_,hu⟩ + cases hn : cascadeIndex D k x with + | zero => simpa [cascadePhase_zero] using ht₀ + | succ n => + have hmin := Nat.find_min (exists_cascade_index D k (x 0)) (show n hmin (Or.inl h)) + rw [cascadePhase_succ] + linarith + +def cascadeStageTensor (L K k : ℝ) (n : ℕ) (x : Coord3) : Matrix (Fin 3) (Fin 3) ℝ := + if cascadePhase (cascadeLength L K) k n (x 0) (connectorProfile_pos K x).ne') + +lemma cascadeStageTensor_measurable (L K k : ℝ) (n : ℕ) : + Measurable (cascadeStageTensor L K k n) := by + have hp : Continuous (fun x : Coord3 => cascadePhase (cascadeLength L K) k n (x 0)) := by + unfold cascadePhase + fun_prop + have hc : Continuous (fun x : Coord3 => + pureModeTensor (connectorAngular K (cascadePhase (cascadeLength L K) k n (x 0))) (cascadeAxis n)) := by + apply continuous_pi; intro i + apply continuous_pi; intro j + simp only [pureModeTensor, Matrix.diagonal_apply] + split_ifs + · exact (connectorAngular_continuous K).comp hp + · exact continuous_const + · exact continuous_const + have hx : Continuous (fun x : Coord3 => crossingTensor L (cascadeAxis n) (cascadeAxis (n+1)) + ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)-Pi.single 0 (K+2+L))) := + (crossingTensor_continuous L _ _).comp (by fun_prop) + exact Measurable.ite (isOpen_lt hp continuous_const).measurableSet hc.measurable hx.measurable + +lemma cascadeTensor_measurable (L K k : ℝ) : Measurable (cascadeTensor L K k) := by + have hs : Measurable (fun x : Coord3 => cascadeStageTensor L K k + (cascadeIndex (cascadeLength L K) k x) x) := by + apply Measurable.find (cascadeStageTensor_measurable L K k) + intro n + have hc : Continuous (fun x : Coord3 => cascadePhase (cascadeLength L K) k n (x 0)) := by + unfold cascadePhase + fun_prop + exact (isClosed_le hc continuous_const).measurableSet.union + (isClosed_le continuous_const (continuous_const.mul (continuous_apply 0))).measurableSet + have hp : MeasurableSet {x : Coord3 | 0≤k*x 0 ∧ k*x 0<2*cascadeLength L K} := by + apply MeasurableSet.inter + · exact (isClosed_le continuous_const (continuous_const.mul (continuous_apply 0))).measurableSet + · exact (isOpen_lt (continuous_const.mul (continuous_apply 0)) continuous_const).measurableSet + exact Measurable.ite hp hs measurable_const + +lemma cascadeTensor_symm (L K k : ℝ) (x : Coord3) : (cascadeTensor L K k x).IsSymm := by + unfold cascadeTensor cascadeStageTensor + split_ifs + · exact pureModeTensor_symm _ _ + · exact crossingTensor_symm _ _ _ _ + · exact isSymm_one + +lemma cascadeTensor_normal (L K k : ℝ) (x : Coord3) : + cascadeTensor L K k x *ᵥ (Pi.single 0 1 : Coord3) = Pi.single 0 1 := by + unfold cascadeTensor cascadeStageTensor + split_ifs + · exact pureModeTensor_normal (cascadeAxis_ne_zero _) _ + · exact crossingTensor_normal (cascadeAxis_ne_zero _) (cascadeAxis_ne_zero _) _ _ + · exact one_mulVec _ + +lemma cascadeTensor_bounds {L K k : ℝ} + (hL : ∀ z x y X Y : ℝ, + (1/8)*(X^2+Y^2) ≤ crossingXX L z x y*X^2+2*crossingXY L z x y*X*Y+crossingYY L z x y*Y^2 ∧ + crossingXX L z x y*X^2+2*crossingXY L z x y*X*Y+crossingYY L z x y*Y^2 ≤ 10*(X^2+Y^2)) + (hK : ∀ z, 1/8≤connectorAngular K z ∧ connectorAngular K z≤10) + (x v : Coord3) : + (1/8)*(v ⬝ᵥ v) ≤ v ⬝ᵥ (cascadeTensor L K k x *ᵥ v) ∧ + v ⬝ᵥ (cascadeTensor L K k x *ᵥ v) ≤ 10*(v ⬝ᵥ v) := by + unfold cascadeTensor cascadeStageTensor + split_ifs + · exact pureModeTensor_bounds (hK _).1 (hK _).2 _ _ + · exact crossingTensor_bounds hL (cascadeAxis_ne_zero _) (cascadeAxis_ne_zero _) + (cascadeAxis_ne_succ _) _ _ + · rw [one_mulVec] + have hp : 0≤v ⬝ᵥ v := by + apply Finset.sum_nonneg; intro i _; exact mul_self_nonneg _ + constructor <;> nlinarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeGeometry.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4a979cc5055a4390fa9c41c7528606b48152dc3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeGeometry.lean @@ -0,0 +1,200 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ScaledSmoothSeries + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def cascadePhase (D k : ℝ) (j : ℕ) (t : ℝ) : ℝ := + (2:ℝ)^j*(k*t-2*D)+2*D + +lemma cascadePhase_zero (D k t : ℝ) : cascadePhase D k 0 t = k*t := by + simp [cascadePhase] + +lemma cascadePhase_succ (D k t : ℝ) (j : ℕ) : + cascadePhase D k (j+1) t = 2*(cascadePhase D k j t-D) := by + unfold cascadePhase + rw [pow_succ] + ring + +lemma cascadePhase_add (D k t : ℝ) (j n : ℕ) : + cascadePhase D k (j+n) t = (2:ℝ)^n*(cascadePhase D k j t-2*D)+2*D := by + unfold cascadePhase + rw [pow_add] + ring + +lemma cascadePhase_antitone {D k t : ℝ} (ht : k*t ≤ 2*D) : + Antitone (fun j => cascadePhase D k j t) := by + apply antitone_nat_of_succ_le + intro j + have hp : 0 ≤ (2:ℝ)^j := by positivity + rw [cascadePhase_succ] + have : cascadePhase D k j t ≤ 2*D := by + unfold cascadePhase + nlinarith [mul_nonpos_of_nonneg_of_nonpos hp (by linarith : k*t-2*D≤0)] + linarith + +lemma cascadePhase_before {D k t : ℝ} (hD : 0 < D) {i j : ℕ} + (hij : i < j) (hj : 0 ≤ cascadePhase D k j t) : + D ≤ cascadePhase D k i t := by + by_cases ht : k*t ≤ 2*D + · have h := cascadePhase_antitone ht (show i+1≤j by omega) + dsimp only at h + rw [cascadePhase_succ] at h + linarith + · have hp : 0 ≤ (2:ℝ)^i := by positivity + have : 0 ≤ (2:ℝ)^i*(k*t-2*D) := mul_nonneg hp (by linarith) + unfold cascadePhase + linarith + +lemma cascadePhase_after {D k t : ℝ} (hD : 0 < D) {i j : ℕ} + (hij : j+1 < i) (hj : cascadePhase D k j t ≤ D) : + cascadePhase D k i t ≤ -2*D := by + have ht : k*t ≤ 2*D := by + by_contra hh + have hp : 0 < (2:ℝ)^j := by positivity + have : 0 < (2:ℝ)^j*(k*t-2*D) := mul_pos hp (by linarith) + unfold cascadePhase at hj + linarith + have h := cascadePhase_antitone ht (show j + 2 ≤ i by omega) + dsimp only at h + rw [show j+2=(j+1)+1 by omega,cascadePhase_succ,cascadePhase_succ] at h + linarith + +lemma cascadeProfile_only_two {L K k t : ℝ} (hL : 0 < L) (hK : 0 < K) + {j i : ℕ} (hj₁ : 0 ≤ cascadePhase (cascadeLength L K) k j t) + (hj₂ : cascadePhase (cascadeLength L K) k j t ≤ cascadeLength L K) + (hi : i ≠ j) (hi' : i ≠ j+1) : + cascadeProfile L K (cascadePhase (cascadeLength L K) k i t) = 0 := by + have hD := cascade_length_positive hL hK + by_cases hij : i < j + · apply cascadeProfile_zero_right hL + have hh := cascadePhase_before hD hij hj₁ + change K+2+2*L ≤ cascadePhase (cascadeLength L K) k i t at hh + linarith + · apply cascadeProfile_zero_left hL + have hh := cascadePhase_after hD (show j+1 < i by omega) hj₂ + change cascadePhase (cascadeLength L K) k i t ≤ -2*(K+2+2*L) at hh + linarith + +lemma cascadeProfile_terminal {L K k t : ℝ} (hL : 0 < L) (hK : 0 < K) + (ht : 2*cascadeLength L K ≤ k*t) (j : ℕ) : + cascadeProfile L K (cascadePhase (cascadeLength L K) k j t) = 0 := by + apply cascadeProfile_zero_right hL + have hp : 0 ≤ (2:ℝ)^j*(k*t-2*cascadeLength L K) := + mul_nonneg (by positivity) (by linarith) + unfold cascadePhase cascadeLength at * + linarith + +lemma exists_cascade_stage {D k t : ℝ} (_ : 0 < D) + (ht₀ : 0 ≤ k*t) (ht : k*t < 2*D) : + ∃ j : ℕ, 0 ≤ cascadePhase D k j t ∧ cascadePhase D k j t ≤ D := by + have hex : ∃ j : ℕ, cascadePhase D k j t ≤ D := by + obtain ⟨j,hj⟩ := pow_unbounded_of_one_lt (D/(2*D-k*t)) (by norm_num : (1:ℝ)<2) + refine ⟨j,?_⟩ + have hh : D ≤ (2:ℝ)^j*(2*D-k*t) := by + exact (div_le_iff₀ (by linarith : 0<2*D-k*t)).mp hj.le + unfold cascadePhase + nlinarith + let j := Nat.find hex + refine ⟨j,?_,Nat.find_spec hex⟩ + cases hj : j with + | zero => simpa [hj,cascadePhase_zero] using ht₀ + | succ n => + have hn : n < Nat.find hex := by change n < j; omega + have hh := Nat.find_min hex hn + rw [not_le] at hh + rw [cascadePhase_succ] + linarith + +def cascadeAxis (j : ℕ) : Fin 3 := if Even j then 1 else 2 + +lemma cascadeAxis_ne_zero (j : ℕ) : cascadeAxis j ≠ 0 := by + unfold cascadeAxis + split <;> decide + +lemma cascadeAxis_succ (j : ℕ) : cascadeAxis (j+1) = if Even j then 2 else 1 := by + simp only [cascadeAxis,Nat.even_add_one] + split <;> simp_all + +def cascadeCenter (D k : ℝ) (j : ℕ) : Coord3 := + Pi.single 0 ((2*D/k)*(1-1/(2:ℝ)^j)) + +lemma cascade_dilation_time {k : ℝ} (hk : k ≠ 0) (D : ℝ) (j : ℕ) (x : Coord3) : + ((k*2^j) • (x-cascadeCenter D k j)) 0 = cascadePhase D k j (x 0) := by + simp only [Pi.smul_apply,Pi.sub_apply,smul_eq_mul,cascadeCenter,Pi.single_eq_same,cascadePhase] + field_simp + ring + +lemma cascade_dilation_angular (D k : ℝ) (j : ℕ) (x : Coord3) : + ((k*2^j) • (x-cascadeCenter D k j)) (cascadeAxis j) = k*2^j*x (cascadeAxis j) := by + simp [cascadeCenter,Pi.single_eq_of_ne (cascadeAxis_ne_zero j)] + +def cascadeTerm (L K k A : ℝ) (j : ℕ) (x : Coord3) : ℝ := + (A*cascadeRatio L K^j)*cascadeProfile L K (cascadePhase (cascadeLength L K) k j (x 0))* + cos (k*2^j*x (cascadeAxis j)) + +def cascadeValue (L K k A : ℝ) (x : Coord3) : ℝ := ∑' j : ℕ, cascadeTerm L K k A j x + +lemma cascadeTerm_scaled {k : ℝ} (hk : k ≠ 0) (L K A : ℝ) (j : ℕ) (x : Coord3) : + cascadeTerm L K k A j x = (A*cascadeRatio L K^j)* + cascadeMother L K (cascadeAxis j) ((k*2^j) • (x-cascadeCenter (cascadeLength L K) k j)) := by + rw [cascadeMother,cascade_dilation_time hk,cascade_dilation_angular] + unfold cascadeTerm + ring + +theorem cascadeValue_C2 {L K k : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (hk : k ≠ 0) (A : ℝ) : + ContDiff ℝ 2 (cascadeValue L K k A) := by + have hh := geometric_scaled_C2 + (f := fun j => cascadeMother L K (cascadeAxis j)) + (fun _ => cascadeMother_smooth _ _ _) + (fun n => by + obtain ⟨C,hC,hb⟩ := cascadeMother_iterated_bound (lt_of_lt_of_le (by norm_num) hL) n + exact ⟨C,hC,fun j x => hb (cascadeAxis j) x⟩) + (cascadeRatio_pos L K).le (cascadeRatio_small hL hK) A k + (cascadeCenter (cascadeLength L K) k) + convert hh using 1 + funext x + exact tsum_congr fun j => cascadeTerm_scaled hk L K A j x + +lemma cascadeValue_terminal {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (A : ℝ) + (x : Coord3) (hx : 2*cascadeLength L K ≤ k*x 0) : cascadeValue L K k A x = 0 := by + change (∑' j : ℕ, cascadeTerm L K k A j x) = 0 + have h : ∀ j, cascadeTerm L K k A j x = 0 := by + intro j + rw [cascadeTerm,cascadeProfile_terminal hL hK hx,mul_zero,zero_mul] + simp only [h,tsum_zero] + +lemma cascadeValue_two_modes {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (A : ℝ) + (x : Coord3) (j : ℕ) (hj₁ : 0 ≤ cascadePhase (cascadeLength L K) k j (x 0)) + (hj₂ : cascadePhase (cascadeLength L K) k j (x 0) ≤ cascadeLength L K) : + cascadeValue L K k A x = cascadeTerm L K k A j x + cascadeTerm L K k A (j+1) x := by + have h : (∑' i : ℕ, cascadeTerm L K k A i x) = ∑ i ∈ ({j,j+1} : Finset ℕ), cascadeTerm L K k A i x := tsum_eq_sum (s := ({j,j+1} : Finset ℕ)) (f := fun i => cascadeTerm L K k A i x) (by + intro i hi + have hi₁ : i ≠ j := by simpa using fun h => hi (by simp [h]) + have hi₂ : i ≠ j+1 := by simpa using fun h => hi (by simp [h]) + rw [cascadeTerm,cascadeProfile_only_two hL hK hj₁ hj₂ hi₁ hi₂,mul_zero,zero_mul]) + simpa [cascadeValue,Finset.sum_pair (show j ≠ j+1 by omega)] using h + +lemma cascadeValue_zero_phase {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (A : ℝ) + (x : Coord3) (hx : x 0 = 0) : cascadeValue L K k A x = A*cos (k*x 1) := by + have h₁ : 0 ≤ cascadePhase (cascadeLength L K) k 0 (x 0) := by simp [cascadePhase_zero,hx] + have h₂ : cascadePhase (cascadeLength L K) k 0 (x 0) ≤ cascadeLength L K := by + simpa [cascadePhase_zero,hx] using (cascade_length_positive hL hK).le + rw [cascadeValue_two_modes hL hK A x 0 h₁ h₂] + have hz : cascadeProfile L K (cascadePhase (cascadeLength L K) k 1 (x 0)) = 0 := by + apply cascadeProfile_zero_left hL + simp [cascadePhase,hx,cascadeLength] + linarith + rw [cascadeTerm,cascadeTerm,hz] + simp [cascadePhase_zero,hx,cascadeProfile_connector hL (le_refl 0) (show (0:ℝ)≤K+2 by linarith), + connectorProfile,cascadeAxis] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeLocality.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeLocality.lean new file mode 100644 index 0000000000000000000000000000000000000000..f03837e0daf9750fa9225aad252db9ae26132c42 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeLocality.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CascadeGeometry +import OAI.Analysis.Conductivity.Branching.CascadeStreams + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +lemma cascadePhase_lt_terminal {D k t : ℝ} {j : ℕ} + (hj : cascadePhase D k j t < 2*D) : k*t < 2*D := by + have hp : 0 < (2:ℝ)^j := by positivity + unfold cascadePhase at hj + nlinarith + +lemma cascadePhase_before_wide {D k t : ℝ} {i j : ℕ} (ht : k*t ≤ 2*D) (hij : i < j) : + D+cascadePhase D k j t/2 ≤ cascadePhase D k i t := by + have hh := cascadePhase_antitone ht (show i+1 ≤ j by omega) + dsimp only at hh + rw [cascadePhase_succ] at hh + linarith + +lemma cascadePhase_after_wide {D k t : ℝ} {i j : ℕ} (ht : k*t ≤ 2*D) (hij : j+1 < i) : + cascadePhase D k i t ≤ 4*cascadePhase D k j t-6*D := by + have hh := cascadePhase_antitone ht (show j+2 ≤ i by omega) + dsimp only at hh + rw [show j+2=(j+1)+1 by omega,cascadePhase_succ,cascadePhase_succ] at hh + linarith + +lemma cascadePhase_inactive_wide {L K k t : ℝ} (hL : 0 < L) (hK : 0 < K) {j i : ℕ} + (hj₁ : -L/8 < cascadePhase (cascadeLength L K) k j t) + (hj₂ : cascadePhase (cascadeLength L K) k j t < cascadeLength L K+L/8) + (hi : i≠j) (hi' : i≠j+1) : + cascadePhase (cascadeLength L K) k i t < -7*L/2 ∨ + K+2+7*L/4 < cascadePhase (cascadeLength L K) k i t := by + have ht : k*t < 2*cascadeLength L K := cascadePhase_lt_terminal (hj₂.trans + (by unfold cascadeLength; linarith)) + by_cases hij : i < j + · right + have hh := cascadePhase_before_wide ht.le hij + unfold cascadeLength at * + linarith + · left + have hh := cascadePhase_after_wide ht.le (show j+1 < i by omega) + unfold cascadeLength at * + linarith + +lemma cascadeProfile_deriv_zero_left {L K t : ℝ} (hL : 0 < L) (ht : t < -7*L/2) : + deriv (cascadeProfile L K) t = 0 := by + have he : cascadeProfile L K =ᶠ[𝓝 t] fun _ => (0:ℝ) := by + filter_upwards [isOpen_Iio.mem_nhds ht] with y hy + exact cascadeProfile_zero_left hL hy.le + simpa using he.deriv_eq +lemma cascadeProfile_deriv_zero_right {L K t : ℝ} (hL : 0 < L) (ht : K+2+7*L/4 < t) : + deriv (cascadeProfile L K) t = 0 := by + have he : cascadeProfile L K =ᶠ[𝓝 t] fun _ => (0:ℝ) := by + filter_upwards [isOpen_Ioi.mem_nhds ht] with y hy + exact cascadeProfile_zero_right hL hy.le + simpa using he.deriv_eq + +lemma cascadeBaseStream_zero {L K : ℝ} (hL : 0 < L) (a : Fin 3) (x : Coord3) + (ht : x 0 < -7*L/2 ∨ K+2+7*L/4 < x 0) : cascadeBaseStream L K a x = 0 := by + have hd : deriv (cascadeProfile L K) (x 0) = 0 := + ht.elim (cascadeProfile_deriv_zero_left hL) (cascadeProfile_deriv_zero_right hL) + simp [cascadeBaseStream,hd] + +lemma cascadeCrossStream_zero_left {L K : ℝ} (hL : 0 < L) (a b : Fin 3) (x : Coord3) + (ht : x 0 < K+2+L/4) : cascadeCrossStream L K a b x = 0 := by + have hf := crossingResidualFirst_zero hL (show x 0-(K+2+L) < L/2 by linarith) + have hg := crossingResidualSecond_zero_left hL (show x 0-(K+2+L) < -3*L/4 by linarith) + simp [cascadeCrossStream,hf,hg] +lemma cascadeCrossStream_zero_right {L K : ℝ} (hL : 0 < L) (a b : Fin 3) (x : Coord3) + (ht : K+2+7*L/4 < x 0) : cascadeCrossStream L K a b x = 0 := by + have hf := crossingResidualFirst_zero_right hL (show 3*L/4 < x 0-(K+2+L) by linarith) + have hg := crossingResidualSecond_zero hL (show -L/2 < x 0-(K+2+L) by linarith) + simp [cascadeCrossStream,hf,hg] + +lemma cascadeMother_inactive_wide {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (x : Coord3) {j n : ℕ} + (hj₁ : -L/8 < cascadePhase (cascadeLength L K) k j (x 0)) + (hj₂ : cascadePhase (cascadeLength L K) k j (x 0) < cascadeLength L K+L/8) + (hn : n≠j) (hn' : n≠j+1) : + cascadeMother L K (cascadeAxis n) ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)) = 0 ∧ + cascadeBaseStream L K (cascadeAxis n) ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)) = 0 ∧ + cascadeCrossStream L K (cascadeAxis n) (cascadeAxis (n+1)) + ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)) = 0 := by + let y := (k*2^n) • (x-cascadeCenter (cascadeLength L K) k n) + have ht : y 0 < -7*L/2 ∨ K+2+7*L/4 < y 0 := by + dsimp only [y] + rw [cascade_dilation_time hk] + exact cascadePhase_inactive_wide hL hK hj₁ hj₂ hn hn' + refine ⟨?_,cascadeBaseStream_zero hL _ y ht,?_⟩ + · have hp : cascadeProfile L K (y 0) = 0 := ht.elim + (fun h => cascadeProfile_zero_left hL h.le) (fun h => cascadeProfile_zero_right hL h.le) + exact show cascadeProfile L K (y 0)*cos (y (cascadeAxis n))=0 by rw [hp,zero_mul] + · rcases ht with ht | ht + · apply cascadeCrossStream_zero_left hL _ _ y + linarith + · exact cascadeCrossStream_zero_right hL _ _ y ht + +lemma cascadeCrossStream_next_zero_wide {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (x : Coord3) {j : ℕ} + (hj₂ : cascadePhase (cascadeLength L K) k j (x 0) < cascadeLength L K+L/8) : + cascadeCrossStream L K (cascadeAxis (j+1)) (cascadeAxis (j+2)) + ((k*2^(j+1)) • (x-cascadeCenter (cascadeLength L K) k (j+1))) = 0 := by + apply cascadeCrossStream_zero_left hL + rw [cascade_dilation_time hk,cascadePhase_succ] + linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeProfile.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeProfile.lean new file mode 100644 index 0000000000000000000000000000000000000000..50ed5db49b89140c52fc31806ca56a062410f842 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeProfile.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CrossingProfiles +import OAI.Analysis.Conductivity.Fourier.ModeConnector + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +lemma connectorProfile_left {K z : ℝ} (hK : 0 < K) (hz : z ≤ 1) : + connectorProfile K z = exp (-z/2) := by + have hi : (∫ t in (0:ℝ)..z, connectorRate K t) = z/2 := by + calc + _ = ∫ _t in (0:ℝ)..z, (1/2:ℝ) := intervalIntegral.integral_congr (by + intro t ht + exact connectorRate_left hK ((le_max_iff.mp ht.2).elim (by intro h; linarith) (by intro h; linarith))) + _ = _ := by simp; ring + rw [connectorProfile,hi] + congr 1 + ring + +lemma connectorProfile_right {K z : ℝ} (hK : 0 < K) (hz : K+1 ≤ z) : + connectorProfile K z = connectorProfile K (K+2)*exp (-3*(z-(K+2))) := by + have hi : (∫ t in (K+2)..z, connectorRate K t) = 3*(z-(K+2)) := by + calc + _ = ∫ _t in (K+2)..z, (3:ℝ) := intervalIntegral.integral_congr (by + intro t ht + apply connectorRate_right hK + exact le_trans (le_min (by linarith) hz) ht.1) + _ = _ := by simp; ring + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + ((connectorRate_smooth K).continuous.intervalIntegrable 0 (K+2)) + ((connectorRate_smooth K).continuous.intervalIntegrable (K+2) z) + rw [hi] at hadd + unfold connectorProfile + rw [←hadd,neg_add,exp_add] + congr 2 + ring + +def cascadeProfile (L K t : ℝ) : ℝ := + crossingOn L (t/2+L) * connectorProfile K t * crossingOff L (t-(K+2+L)) + +lemma cascadeProfile_smooth (L K : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (cascadeProfile L K) := by + exact (((crossingOn_smooth L).comp ((contDiff_id.div_const 2).add contDiff_const)).mul + (connectorProfile_smooth K)).mul ((crossingOff_smooth L).comp (contDiff_id.sub contDiff_const)) + +lemma cascadeProfile_nonneg (L K t : ℝ) : 0 ≤ cascadeProfile L K t := + mul_nonneg (mul_nonneg (crossingOn_bounds L _).1 (connectorProfile_pos K t).le) + (crossingOff_bounds L _).1 + +lemma cascadeProfile_zero_left {L K t : ℝ} (hL : 0 < L) (ht : t ≤ -7*L/2) : + cascadeProfile L K t = 0 := by + rw [cascadeProfile,crossingOn_eq_zero hL (show t/2+L ≤ -3*L/4 by linarith),zero_mul,zero_mul] +lemma cascadeProfile_zero_right {L K t : ℝ} (hL : 0 < L) (ht : K+2+7*L/4 ≤ t) : + cascadeProfile L K t = 0 := by + rw [cascadeProfile,crossingOff_eq_zero hL (show 3*L/4 ≤ t-(K+2+L) by linarith),mul_zero] + +lemma cascadeProfile_compact {L K : ℝ} (hL : 0 < L) : HasCompactSupport (cascadeProfile L K) := by + apply HasCompactSupport.intro (K := Icc (-7*L/2) (K+2+7*L/4)) isCompact_Icc + intro t ht + rw [mem_Icc,not_and_or,not_le,not_le] at ht + rcases ht with ht | ht + · exact cascadeProfile_zero_left hL ht.le + · exact cascadeProfile_zero_right hL ht.le + +lemma cascadeProfile_connector {L K t : ℝ} (hL : 0 < L) (ht₁ : 0 ≤ t) (ht₂ : t ≤ K+2) : + cascadeProfile L K t = connectorProfile K t := by + rw [cascadeProfile,crossingOn_eq_one hL (show -L/2 ≤ t/2+L by linarith), + crossingOff_eq_one hL (show t-(K+2+L) ≤ L/2 by linarith)] + ring + +lemma cascadeProfile_incoming {L K t : ℝ} (hL : 0 < L) (hK : 0 < K) (ht : t ≤ 0) : + cascadeProfile L K t = crossingOn L (t/2+L)*exp (-t/2) := by + rw [cascadeProfile,connectorProfile_left hK (show t≤1 by linarith), + crossingOff_eq_one hL (show t-(K+2+L) ≤ L/2 by linarith),mul_one] + +lemma cascadeProfile_outgoing {L K t : ℝ} (hL : 0 < L) (hK : 0 < K) (ht : K+2 ≤ t) : + cascadeProfile L K t = connectorProfile K (K+2)*exp (-3*(t-(K+2))) * + crossingOff L (t-(K+2+L)) := by + rw [cascadeProfile,crossingOn_eq_one hL (show -L/2≤t/2+L by linarith),one_mul, + connectorProfile_right hK (show K+1≤t by linarith)] + +def cascadeRatio (L K : ℝ) : ℝ := exp (-4*L)*connectorProfile K (K+2) + +def cascadeLength (L K : ℝ) : ℝ := K+2+2*L + +lemma cascadeRatio_pos (L K : ℝ) : 0 < cascadeRatio L K := + mul_pos (exp_pos _) (connectorProfile_pos _ _) + +lemma cascadeRatio_small {L K : ℝ} (hL : 1 ≤ L) (hK : 0 < K) : + 4*cascadeRatio L K < 1 := by + have he : exp (-4*L) < 1/4 := by + rw [neg_mul,exp_neg,one_div,inv_lt_inv₀ (exp_pos _) (by norm_num : (0:ℝ)<4)] + have := add_one_le_exp (4*L) + linarith + have hc := connectorProfile_le_one (K := K) (z := K+2) (by linarith) + have hq : cascadeRatio L K ≤ exp (-4*L) := by + exact (mul_le_mul_of_nonneg_left hc (exp_pos _).le).trans_eq (mul_one _) + linarith + +lemma cascade_length_positive {L K : ℝ} (hL : 0 < L) (hK : 0 < K) : + 0 < cascadeLength L K := by unfold cascadeLength; linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeProfileDeriv.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeProfileDeriv.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8f0139fa98713be0023cafad111c95a03909cca --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeProfileDeriv.lean @@ -0,0 +1,48 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CrossingBlock + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +lemma cascadeProfile_crossing_current_deriv {L K s : ℝ} (hL : 0 < L) (hK : 0 < K) + (hs : K+2 < s) : + deriv (cascadeProfile L K) s = connectorProfile K (K+2)*exp (-3*L)* + deriv (crossingFirst L) (s-(K+2+L)) := by + have he : cascadeProfile L K =ᶠ[𝓝 s] + fun r => connectorProfile K (K+2)*exp (-3*L)*crossingFirst L (r-(K+2+L)) := by + filter_upwards [Ioi_mem_nhds hs] with r hr + exact cascadeProfile_crossing_current hL hK hr.le + have hd : HasDerivAt (fun r => connectorProfile K (K+2)*exp (-3*L)*crossingFirst L (r-(K+2+L))) + (connectorProfile K (K+2)*exp (-3*L)*deriv (crossingFirst L) (s-(K+2+L))) s := by + simpa only [id_eq,mul_one,Function.comp_def] using (((crossingFirst_smooth L).differentiable (by simp) _).hasDerivAt.comp s + ((hasDerivAt_id s).sub_const (K+2+L))).const_mul (connectorProfile K (K+2)*exp (-3*L)) + rw [he.deriv_eq,hd.deriv] + +lemma cascadeProfile_crossing_next_deriv {L K s : ℝ} (hL : 0 < L) (hK : 0 < K) + (hs : s < cascadeLength L K) : + cascadeRatio L K*deriv (cascadeProfile L K) (2*(s-cascadeLength L K)) = + (connectorProfile K (K+2)*exp (-3*L)/2)*deriv (crossingSecond L) (s-(K+2+L)) := by + have he : (fun r => cascadeRatio L K*cascadeProfile L K (2*(r-cascadeLength L K))) =ᶠ[𝓝 s] + fun r => connectorProfile K (K+2)*exp (-3*L)*crossingSecond L (r-(K+2+L)) := by + filter_upwards [Iio_mem_nhds hs] with r hr + exact cascadeProfile_crossing_next hL hK hr.le + have hd₁ : HasDerivAt (fun r => cascadeRatio L K*cascadeProfile L K (2*(r-cascadeLength L K))) + (2*cascadeRatio L K*deriv (cascadeProfile L K) (2*(s-cascadeLength L K))) s := by + simpa only [id_eq,mul_one,one_mul,Function.comp_def,mul_assoc,mul_left_comm,mul_comm] using (((cascadeProfile_smooth L K).differentiable (by simp) _).hasDerivAt.comp s + (((hasDerivAt_id s).sub_const (cascadeLength L K)).const_mul 2)).const_mul (cascadeRatio L K) + have hd₂ : HasDerivAt (fun r => connectorProfile K (K+2)*exp (-3*L)*crossingSecond L (r-(K+2+L))) + (connectorProfile K (K+2)*exp (-3*L)*deriv (crossingSecond L) (s-(K+2+L))) s := by + simpa only [id_eq,mul_one,Function.comp_def] using (((crossingSecond_smooth L).differentiable (by simp) _).hasDerivAt.comp s + ((hasDerivAt_id s).sub_const (K+2+L))).const_mul (connectorProfile K (K+2)*exp (-3*L)) + have hh := he.deriv_eq + rw [hd₁.deriv,hd₂.deriv] at hh + linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeRankPieces.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeRankPieces.lean new file mode 100644 index 0000000000000000000000000000000000000000..3ae41bf7e72f619ba63f82fa85e3f4e75cf13c52 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeRankPieces.lean @@ -0,0 +1,170 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly +import OAI.Analysis.Conductivity.Variational.AxialLocalRegularity +import OAI.Analysis.Conductivity.Flux.CascadeTensorLocality + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def cascadeSymmetricTensor (L K k : ℝ) (x : Coord3) : Symmetric3 := + ⟨cascadeTensor L K k x,cascadeTensor_symm L K k x⟩ + +lemma cascade_connector_regular {L K k A : ℝ} (hL : 0 s*pureModeValue (connectorProfile K) (cascadeAxis j) (r • (y-c)-0) + let B : Coord3 → Symmetric3 := fun y => + ⟨pureModeTensor (connectorAngular K (cascadePhase (cascadeLength L K) k j (y 0))) (cascadeAxis j), + pureModeTensor_symm _ _⟩ + have hp := pureModeValue_smooth (connectorProfile_smooth K) (cascadeAxis j) + have hF : ContDiff ℝ (↑(⊤:ℕ∞)) F := by + dsimp only [F] + exact contDiff_const.mul (hp.comp ((contDiff_id.sub contDiff_const).const_smul r |>.sub contDiff_const)) + have hB : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => (B y).val) := by + apply pureModeTensor_smooth + exact (connectorAngular_smooth K).comp (by unfold cascadePhase; fun_prop) + apply axialPair_mem_regularRegion_of_model hF hB (i:=cascadeAxis j) ?_ ?_ (cascadeAxis_ne_zero j) ?_ hU hx + · filter_upwards [cascade_connector_nhds x j hj0 hjK] with y hy + simpa only [F,s,r,c,sub_zero] using cascadeValue_connector hL hK hk A y j hy.1 hy.2 + · filter_upwards [cascade_connector_nhds x j hj0 hjK] with y hy + apply Subtype.ext + exact cascadeTensor_connector_eq hL hK y j hy.1 hy.2 + · change direction (Pi.single (cascadeAxis j) 1) + (fun y => s*pureModeValue (connectorProfile K) (cascadeAxis j) (r • (y-c)-0)) x≠0 + rw [direction_affineShift (pureModeValue_diff ((connectorProfile_smooth K).differentiable (by simp)) _)] + rw [pureModeValue_direction ((connectorProfile_smooth K).differentiable (by simp))] + simp only [cascadeAxis_ne_zero,ite_false,ite_true,zero_add,sub_zero] + apply mul_ne_zero (mul_ne_zero ?_ ?_) + · exact mul_ne_zero (neg_ne_zero.mpr (connectorProfile_pos K _).ne') (by + simpa only [r,c,cascade_dilation_coord _ _ _ _ (cascadeAxis_ne_zero j)] using hsin) + · exact mul_ne_zero hA (pow_ne_zero j (cascadeRatio_pos L K).ne') + · exact mul_ne_zero hk (pow_ne_zero j (by norm_num : (2:ℝ)≠0)) + +lemma cascade_crossing_regular {L K k A : ℝ} (hL : 0 s*crossingValue3 L (cascadeAxis j) (cascadeAxis (j+1)) (r • (y-c)-d) + let B : Coord3 → Symmetric3 := fun y => + ⟨crossingTensor L (cascadeAxis j) (cascadeAxis (j+1)) (r • (y-c)-d),crossingTensor_symm _ _ _ _⟩ + have hF : ContDiff ℝ (↑(⊤:ℕ∞)) F := by + dsimp only [F] + exact contDiff_const.mul ((crossingValue3_smooth L _ _).comp + ((contDiff_id.sub contDiff_const).const_smul r |>.sub contDiff_const)) + have hB : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => (B y).val) := + (crossingTensor_smooth L _ _).comp ((contDiff_id.sub contDiff_const).const_smul r |>.sub contDiff_const) + have hf : cascadeValue L K k A =ᶠ[𝓝 x] F := by + filter_upwards [cascade_crossing_nhds x j hjK hjD] with y hy + exact cascadeValue_crossing hL hK hk A y j hy.1 hy.2 + have htensor : cascadeSymmetricTensor L K k =ᶠ[𝓝 x] B := by + filter_upwards [cascade_crossing_nhds x j hjK hjD] with y hy + apply Subtype.ext + exact cascadeTensor_crossing_eq hL hK y j hy.1 hy.2 + have hs : s≠0 := mul_ne_zero (mul_ne_zero hA (pow_ne_zero j (cascadeRatio_pos L K).ne')) + (mul_ne_zero (connectorProfile_pos K _).ne' (exp_pos _).ne') + have hr : r≠0 := mul_ne_zero hk (pow_ne_zero j (by norm_num : (2:ℝ)≠0)) + have ha := cascadeAxis_ne_zero j + have hb := cascadeAxis_ne_zero (j+1) + have hab := cascadeAxis_ne_succ j + by_cases hz : (r • (x-c)-d) 0≤0 + · apply axialPair_mem_regularRegion_of_model hF hB hf htensor ha ?_ hU hx + change direction (Pi.single (cascadeAxis j) 1) + (fun y => s*crossingValue3 L (cascadeAxis j) (cascadeAxis (j+1)) (r • (y-c)-d)) x≠0 + rw [direction_affineShift (crossingValue3_diff L _ _),crossingValue3_direction] + simp only [ha,hab,ite_false,ite_true,zero_add,add_zero,crossing_first_on_left hL hz] + apply mul_ne_zero (mul_ne_zero hs hr) + apply mul_ne_zero (neg_ne_zero.mpr (exp_pos _).ne') + simpa only [r,c,d,Pi.sub_apply,Pi.single_eq_of_ne ha,sub_zero, + cascade_dilation_coord _ _ _ _ ha] using hsin + · apply axialPair_mem_regularRegion_of_model hF hB hf htensor hb ?_ hU hx + change direction (Pi.single (cascadeAxis (j+1)) 1) + (fun y => s*crossingValue3 L (cascadeAxis j) (cascadeAxis (j+1)) (r • (y-c)-d)) x≠0 + rw [direction_affineShift (crossingValue3_diff L _ _),crossingValue3_direction] + simp only [hb,Ne.symm hab,ite_false,ite_true,zero_add,add_zero, + crossing_second_on_right hL (le_of_not_ge hz)] + apply mul_ne_zero (mul_ne_zero hs hr) + apply mul_ne_zero (mul_ne_zero (by norm_num) (exp_pos _).ne') + have he : 2*(r • (x-c)-d) (cascadeAxis (j+1))= + (k*2^(j+1))*x (cascadeAxis (j+1)) := by + simp only [r,c,d,Pi.sub_apply,Pi.single_eq_of_ne hb,sub_zero, + cascade_dilation_coord _ _ _ _ hb,pow_succ] + ring + rw [he] + exact hsin2 + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma cascade_terminal_regular {L K k A : ℝ} (hL : 0 ⟨1,isSymm_one⟩ + have hn : {y : Coord3 | 2*cascadeLength L K ae_cascadePhase_ne hk _ _ n) + have hD : ∀ᵐ x : Coord3, ∀ n : ℕ, cascadePhase (cascadeLength L K) k n (x 0)≠cascadeLength L K := + ae_all_iff.mpr (fun n => ae_cascadePhase_ne hk _ _ n) + have hK2 : ∀ᵐ x : Coord3, ∀ n : ℕ, cascadePhase (cascadeLength L K) k n (x 0)≠K+2 := + ae_all_iff.mpr (fun n => ae_cascadePhase_ne hk _ _ n) + have ht : ∀ᵐ x : Coord3, k*x 0≠2*cascadeLength L K := by + simpa only [cascadePhase_zero] using ae_cascadePhase_ne hk (cascadeLength L K) (2*cascadeLength L K) 0 + have hsin : ∀ᵐ x : Coord3,∀ n : ℕ,sin ((k*2^n)*x (cascadeAxis n))≠0 := + ae_all_iff.mpr (fun n => ae_sin_coord_ne_zero (mul_ne_zero hk (pow_ne_zero n (by norm_num))) _) + filter_upwards [h0,hD,hK2,ht,hsin] with x hx0 hxD hxK hxt hxs + intro hxU hx + by_cases hterm : k*x 0<2*cascadeLength L K + · have hs := cascadeIndex_spec x hx hterm + have hs₁ := lt_of_le_of_ne hs.1 (Ne.symm (hx0 _)) + have hs₂ := lt_of_le_of_ne hs.2 (hxD _) + by_cases hc : cascadePhase (cascadeLength L K) k (cascadeIndex (cascadeLength L K) k x) (x 0) ContinuousLinearMap.proj i + exact ((BoundedSmooth.of_compact (smooth_deriv_infty (cascadeProfile_smooth L K)) + (cascadeProfile_compact hL).deriv).comp_linear (P 0)).mul + (sin_boundedSmooth.comp_linear (P a)) + +lemma cascadeCrossStream_bounded {L K : ℝ} (hL : 0 < L) (a b : Fin 3) : + BoundedSmooth (cascadeCrossStream L K a b) := by + let P : Fin 3 → Coord3 →L[ℝ] ℝ := fun i => ContinuousLinearMap.proj i + have hf := (((BoundedSmooth.of_compact (crossingResidualFirst_smooth L) + (crossingResidualFirst_compact hL)).translate (K+2+L)).comp_linear (P 0)).smul (1/4) + have hg := (((BoundedSmooth.of_compact (crossingResidualSecond_smooth L) + (crossingResidualSecond_compact hL)).translate (K+2+L)).comp_linear (P 0)).smul (1/2) + have hs₁ := sin_boundedSmooth.comp_linear (4 • P b) + have hs₂ := sin_boundedSmooth.comp_linear (2 • P b) + have hsa := sin_boundedSmooth.comp_linear (P a) + have hca := cos_boundedSmooth.comp_linear (P a) + convert (((hf.mul hs₁).mul hsa).sub (((hg.mul hca).mul hsa).mul hs₂)).smul + (connectorProfile K (K+2)*exp (-3*L)) using 1 + funext x + simp only [cascadeCrossStream,Function.comp_def,smul_apply,P, + ContinuousLinearMap.proj_apply] + ring_nf + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CascadeWeakEnd.lean b/lean/OAI/Analysis/Conductivity/Branching/CascadeWeakEnd.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a379d8d747bac28ec2300dd2fe4d3278cce9c3b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CascadeWeakEnd.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CrossingEllipticity +import OAI.Analysis.Conductivity.Scalarization.CascadeConstitution +import OAI.Analysis.Conductivity.Flux.C1WeakDivergence + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +lemma cascade_weak_integrand_ae {L K k : ℝ} (hL : 0 ∑ i, (cascadeTensor L K k x *ᵥ + (fun j => direction (Pi.single j 1) (cascadeValue L K k A) x)) i * + (smoothDirection (Pi.single i 1) ψ).val x) =ᵐ[volume] + (fun x => ∑ i, cascadeFlux L K k A x i*(smoothDirection (Pi.single i 1) ψ).val x) := by + filter_upwards [cascadeTensor_constitution_ae hL hK hk A] with x hx + by_cases h : 0≤k*x 0 + · rw [hx h] + · have hz (i : Fin 3) : (smoothDirection (Pi.single i 1) ψ).val x=0 := by + apply image_eq_zero_of_notMem_tsupport + intro hi + exact h (hs (tsupport_smoothDirection_subset _ _ hi)) + simp only [hz,mul_zero] + +theorem cascade_weak_equation {L K k : ℝ} (hL : 1≤L) (hK : 0 ∑ i, (cascadeTensor L K k x *ᵥ + (fun j => direction (Pi.single j 1) (cascadeValue L K k A) x)) i * + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x, ∑ i, (cascadeTensor L K k x *ᵥ + (fun j => direction (Pi.single j 1) (cascadeValue L K k A) x)) i * + (smoothDirection (Pi.single i 1) ψ).val x) = 0 := by + have he := cascade_weak_integrand_ae (lt_of_lt_of_le (by norm_num) hL) hK hk A ψ hs + constructor + · apply Integrable.congr _ he.symm + apply integrable_finsetSum + intro i _ + exact ((cascadeFlux_C1 hL hK k A i).continuous.mul + (smoothScalar_contDiff (smoothDirection (Pi.single i 1) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (Pi.single i 1) hc).mul_left + · rw [integral_congr_ae he] + exact C1_divergence_zero_test volume (fun i : Fin 3 => Pi.single i 1) + (fun i x => cascadeFlux L K k A x i) (cascadeFlux_C1 hL hK k A) + (cascadeFlux_divergence hL hK k A) ψ hc + +theorem exists_cascade_parameters : ∃ L K : ℝ, 1≤L ∧ 0 cascadeTensor_bounds hl ?_ x v⟩ + intro z + have hh := connectorAngular_bounds hM (le_refl (20*M)) (fun x => (hm x).1) z + exact ⟨hh.1,hh.2.trans (by norm_num)⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CentralChildCollar.lean b/lean/OAI/Analysis/Conductivity/Branching/CentralChildCollar.lean new file mode 100644 index 0000000000000000000000000000000000000000..8757768d95d995137943b0b084f0e2b7c960e4a3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CentralChildCollar.lean @@ -0,0 +1,179 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ExtendedCollar + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +def sourceChildCoordinates (σ : ℝ) (y : Fin 3 → ℝ) : Fin 3 → ℝ := + ![sourceScale*y 1+σ*sourceOffset,sourceScale*y 0,sourceScale*y 2] + +lemma sourceRadius_child_bounds (j : Fin 4) {t b : ℝ} + (ht : -2*centralThickness≤t ∧ t≤ -centralThickness) (hb : |b|≤1) : + (29:ℝ)/1000≤ sourceCollarRadius j t b ∧ sourceCollarRadius j t b≤1001/1000 := by + have hq := squareFace_abs_le j hb 0 + have hqt : |(1-t)*squareFace j b 0|≤1+2*centralThickness := by + have ht0 : 0≤1-t := by norm_num [centralThickness] at ht; linarith + rw [abs_mul,abs_of_nonneg ht0] + have hh := mul_le_mul_of_nonneg_left hq ht0 + linarith [ht.1] + have hh := abs_le.mp hqt + dsimp [sourceCollarRadius,sourceRadialCenter,sourceRadialWidth,sourceHole,centralThickness] at * + constructor <;> linarith + +lemma sourceChildCollar_bounds (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-2*centralThickness) (-centralThickness)) : + |(sourceCollarPiece i j x) 0|≤(1602:ℝ)/1000 ∧ + |(sourceCollarPiece i j x) 1|≤(1001:ℝ)/1000 ∧ + |(sourceCollarPiece i j x) 2|≤(1002:ℝ)/1000 := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + have hr := sourceRadius_child_bounds j ht hb + have hr0 : 0≤ sourceCollarRadius j (x 0) (x 2) := by linarith + have ht0 : 0≤1-x 0 := by norm_num [centralThickness] at ht; linarith + have h0 := squareFace_abs_le i ha 0 + have h1 := squareFace_abs_le i ha 1 + have h2 := squareFace_abs_le j hb 1 + have hh0 := mul_le_mul_of_nonneg_left h0 hr0 + have hh1 := mul_le_mul_of_nonneg_left h1 hr0 + have hh2 := mul_le_mul_of_nonneg_left h2 ht0 + change |sourceLength*sourceCollarRadius j (x 0) (x 2)*squareFace i (x 1) 0|≤_ ∧ + |sourceCollarRadius j (x 0) (x 2)*squareFace i (x 1) 1|≤_ ∧ + |(1-x 0)*squareFace j (x 2) 1|≤_ + simp only [abs_mul,abs_of_nonneg hr0,abs_of_nonneg ht0] + norm_num [sourceLength,centralThickness] at ht ⊢ + constructor + · nlinarith + · constructor <;> linarith + +lemma sourceChildCoordinates_offset (σ : ℝ) (y : Fin 3 → ℝ) : + sourceChildCoordinates σ y 0-σ*sourceOffset=sourceScale*y 1 := by + simp [sourceChildCoordinates] + +lemma sourceChildCollar_parent (i j : Fin 4) {σ : ℝ} (hσ : |σ|=1) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-2*centralThickness) (-centralThickness)) : + centralParentFootprint (sourcePairCoordinates (sourceChildCoordinates σ (sourceCollarPiece i j x))).1 ∧ + |(sourceChildCoordinates σ (sourceCollarPiece i j x)) 2|≤centralHeight := by + have hb := sourceChildCollar_bounds i j hx + let y := sourceCollarPiece i j x + have ha : |σ*sourceOffset|=sourceOffset := by rw [abs_mul,hσ,one_mul]; norm_num [sourceOffset] + have hs : 0 norm_num + have hp := sourceChildCollar_parent i j ha hx + refine ⟨hp.1,hp.2,?_⟩ + rcases sourceChildCollar_same i j σ hx with ht|hs + · exact Or.inl ht + · right + have ho := sourceChildCollar_other i j ha hx + rcases hσ with rfl|rfl + · exact ⟨hs,ho⟩ + · exact ⟨by simpa using ho,hs⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CentralJoinCover.lean b/lean/OAI/Analysis/Conductivity/Branching/CentralJoinCover.lean new file mode 100644 index 0000000000000000000000000000000000000000..fa14462f391e06537676e4de8aeffba96c44736e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CentralJoinCover.lean @@ -0,0 +1,189 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CentralPhysicalRegion + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma centralPhysical_subset_ball {y : Fin 3 → ℝ} (hy : y∈centralPhysical) : + WithLp.toLp 2 y∈ball := by + have hp := (centralParent_time_iff y).mp ((centralPhysical_time_iff y).mp hy).1 + have ho : WithLp.toLp 2 y∈sourceOuterBox := by + change |y 0| ≤ sourceLength ∧ |y 1| ≤ 1 ∧ |y 2| ≤ 1 + rcases hp with ⟨⟨hx,hy,_⟩,hz⟩ + dsimp [sourcePairCoordinates] at hx hy + norm_num [centralOuterX,centralOuterY,centralHeight,sourceLength,sourceRadialWidth, + sourceHole,centralThickness] at hx hy hz ⊢ + exact ⟨by linarith,by linarith,by linarith⟩ + have hn := sourceBox_norm_bound ho + simpa only [ball,Metric.mem_ball,dist_zero_right] using + hn.trans (by norm_num : (5:ℝ)/2<3) + +lemma centralPhysical_mem_interior_of_strict {y : Fin 3 → ℝ} + (hp : centralThickness (hcz k).le⟩ + +def centralJoinOpen (i : Fin 4) : Set (Fin 3 → ℝ) := + ![interior centralPhysical, + sourceCollarTime ⁻¹' Ioo 0 (2*centralThickness), + (fun y => sourceCollarTime ((sourceChildHomeomorph 1).symm y)) ⁻¹' Ioo (-2*centralThickness) 0, + (fun y => sourceCollarTime ((sourceChildHomeomorph (-1)).symm y)) ⁻¹' Ioo (-2*centralThickness) 0] i + +lemma centralJoinOpen_isOpen (i : Fin 4) : IsOpen (centralJoinOpen i) := by + have ht := locallyLipschitz_sourceCollarTime.continuous + fin_cases i + · exact isOpen_interior + · exact isOpen_Ioo.preimage ht + · exact isOpen_Ioo.preimage (ht.comp (sourceChildHomeomorph 1).symm.continuous) + · exact isOpen_Ioo.preimage (ht.comp (sourceChildHomeomorph (-1)).symm.continuous) + +lemma centralJoinOpen_covers : centralPhysical⊆⋃ i,centralJoinOpen i := by + intro y hy + obtain ⟨hp,hc⟩ := (centralPhysical_time_iff y).mp hy + by_cases hpe : sourceCollarTime y=centralThickness + · apply mem_iUnion.mpr + refine ⟨1,?_⟩ + change sourceCollarTime y∈Ioo 0 (2*centralThickness) + rw [hpe] + norm_num [centralThickness] + by_cases hce : ∃ k : Fin 2,sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)= -centralThickness + · obtain ⟨k,hk⟩ := hce + apply mem_iUnion.mpr + fin_cases k + · refine ⟨2,?_⟩ + change sourceCollarTime ((sourceChildHomeomorph 1).symm y)∈Ioo (-2*centralThickness) 0 + norm_num [actualChildSign] at hk + rw [hk] + norm_num [centralThickness] + · refine ⟨3,?_⟩ + change sourceCollarTime ((sourceChildHomeomorph (-1)).symm y)∈Ioo (-2*centralThickness) 0 + norm_num [actualChildSign] at hk + rw [hk] + norm_num [centralThickness] + · exact mem_iUnion.mpr ⟨0,centralPhysical_mem_interior_of_strict + (lt_of_le_of_ne hp (Ne.symm hpe)) (fun k => lt_of_le_of_ne (hc k) (fun he => hce ⟨k,he⟩))⟩ + +theorem exists_centralJoinPartition : + ∃ ρ : SmoothPartitionOfUnity (Fin 4) (modelWithCornersSelf ℝ (Fin 3 → ℝ)) + (Fin 3 → ℝ) centralPhysical,ρ.IsSubordinate centralJoinOpen := + SmoothPartitionOfUnity.exists_isSubordinate _ centralPhysical_compact.isClosed + centralJoinOpen centralJoinOpen_isOpen centralJoinOpen_covers + +theorem exists_centralJoinPartition_neighborhood : + ∃ ρ : SmoothPartitionOfUnity (Fin 4) (modelWithCornersSelf ℝ (Fin 3 → ℝ)) + (Fin 3 → ℝ) centralPhysical,ρ.IsSubordinate centralJoinOpen ∧ + ∀ y∈centralPhysical,(fun z => ∑ i : Fin 4,ρ i z)=ᶠ[𝓝 y] (fun _ => (1:ℝ)) := by + obtain ⟨K,hK,hKc,hCK,hKU⟩ := exists_compact_closed_between centralPhysical_compact + (isOpen_iUnion centralJoinOpen_isOpen) centralJoinOpen_covers + obtain ⟨g,hg⟩ := SmoothPartitionOfUnity.exists_isSubordinate + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) hKc centralJoinOpen centralJoinOpen_isOpen hKU + let ρ : SmoothPartitionOfUnity (Fin 4) (modelWithCornersSelf ℝ (Fin 3 → ℝ)) + (Fin 3 → ℝ) centralPhysical := + { toFun := g.toFun + locallyFinite' := g.locallyFinite' + nonneg' := g.nonneg' + sum_eq_one' := fun y hy => g.sum_eq_one (interior_subset (hCK hy)) + sum_le_one' := g.sum_le_one' } + refine ⟨ρ,hg,fun y hy => ?_⟩ + filter_upwards [mem_interior_iff_mem_nhds.mp (hCK hy)] with z hz + change ∑ i : Fin 4,g i z=1 + simpa only [finsum_eq_sum_of_fintype] using g.sum_eq_one hz + +def centralJoinPartition : SmoothPartitionOfUnity (Fin 4) + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) (Fin 3 → ℝ) centralPhysical := + Classical.choose exists_centralJoinPartition_neighborhood + +lemma centralJoinPartition_subordinate : centralJoinPartition.IsSubordinate centralJoinOpen := + (Classical.choose_spec exists_centralJoinPartition_neighborhood).1 + +lemma centralJoinPartition_eventually_sum {y : Fin 3 → ℝ} (hy : y∈centralPhysical) : + (fun z => ∑ i : Fin 4,centralJoinPartition i z)=ᶠ[𝓝 y] (fun _ => (1:ℝ)) := + (Classical.choose_spec exists_centralJoinPartition_neighborhood).2 y hy + +lemma centralJoinPartition_smooth (i : Fin 4) : ContDiff ℝ (↑(⊤:ℕ∞)) (centralJoinPartition i) := + (centralJoinPartition i).contMDiff.contDiff + +lemma centralJoinPartition_bound (i : Fin 4) (y : Fin 3 → ℝ) : |centralJoinPartition i y| ≤ 1 := by + rw [abs_of_nonneg (centralJoinPartition.nonneg i y)] + exact centralJoinPartition.le_one i y + +lemma centralJoinPartition_interior_support : tsupport (centralJoinPartition 0)⊆centralPhysical := + (centralJoinPartition_subordinate 0).trans interior_subset + +lemma centralJoinPartition_interior_compact : HasCompactSupport (centralJoinPartition 0) := + centralPhysical_compact.of_isClosed_subset (isClosed_tsupport _) centralJoinPartition_interior_support + +lemma centralJoinPartition_parent_support : + tsupport (centralJoinPartition 1)⊆sourceClosedCollarBand 0 (2*centralThickness) := by + intro y hy + have ht := centralJoinPartition_subordinate 1 hy + change sourceCollarTime y∈Ioo 0 (2*centralThickness) at ht + exact ⟨ht.1.le,ht.2.le⟩ + +lemma centralJoinPartition_parent_compact : HasCompactSupport (centralJoinPartition 1) := + (isCompact_sourceClosedCollarBand (by norm_num) (by norm_num [centralThickness])).of_isClosed_subset + (isClosed_tsupport _) centralJoinPartition_parent_support + +def centralChildPatch (k : Fin 2) : Fin 4 := ⟨k.val+2,by omega⟩ + +def centralJoinChildCutoff (k : Fin 2) (y : Fin 3 → ℝ) : ℝ := + centralJoinPartition (centralChildPatch k) (sourceChildCoordinates (actualChildSign k) y) + +lemma centralJoinChildCutoff_smooth (k : Fin 2) : + ContDiff ℝ (↑(⊤:ℕ∞)) (centralJoinChildCutoff k) := + (centralJoinPartition_smooth _).comp (sourceChildCoordinates_contDiff _) + +lemma centralJoinChildCutoff_bound (k : Fin 2) (y : Fin 3 → ℝ) : |centralJoinChildCutoff k y| ≤ 1 := + centralJoinPartition_bound _ _ + +lemma centralJoinChildCutoff_support (k : Fin 2) : + tsupport (centralJoinChildCutoff k)⊆sourceClosedCollarBand (-2*centralThickness) 0 := by + intro y hy + have ht : sourceChildCoordinates (actualChildSign k) y∈tsupport (centralJoinPartition (centralChildPatch k)) := + tsupport_comp_subset_preimage (centralJoinPartition (centralChildPatch k)) + (sourceChildCoordinates_contDiff _).continuous hy + have hp := centralJoinPartition_subordinate (centralChildPatch k) ht + have he : centralJoinOpen (centralChildPatch k)= + (fun z => sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm z)) ⁻¹' Ioo (-2*centralThickness) 0 := by + fin_cases k <;> norm_num [centralJoinOpen,centralChildPatch,actualChildSign] + rw [he] at hp + change sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm + ((sourceChildHomeomorph (actualChildSign k)) y))∈Ioo (-2*centralThickness) 0 at hp + rw [Homeomorph.symm_apply_apply] at hp + exact ⟨hp.1.le,hp.2.le⟩ + +lemma centralJoinChildCutoff_compact (k : Fin 2) : HasCompactSupport (centralJoinChildCutoff k) := + (isCompact_sourceClosedCollarBand (by norm_num [centralThickness]) (by norm_num)).of_isClosed_subset + (isClosed_tsupport _) (centralJoinChildCutoff_support k) + +lemma centralJoinPartition_sum {y : Fin 3 → ℝ} (hy : y∈centralPhysical) : + ∑ i : Fin 4,centralJoinPartition i y=1 := by + simpa only [finsum_eq_sum_of_fintype] using centralJoinPartition.sum_eq_one hy + +lemma centralJoinPartition_derivative_sum {y : Fin 3 → ℝ} (hy : y∈interior centralPhysical) + (j : Fin 3) : ∑ i : Fin 4,fderiv ℝ (centralJoinPartition i) y (Pi.single j 1)=0 := by + have he : (fun z => ∑ i : Fin 4,centralJoinPartition i z)=ᶠ[𝓝 y] (fun _ => (1:ℝ)) := by + filter_upwards [mem_interior_iff_mem_nhds.mp hy] with z hz + exact centralJoinPartition_sum hz + have hd := Filter.EventuallyEq.fderiv_eq he (𝕜:=ℝ) + rw [fderiv_fun_sum (fun i _ => (centralJoinPartition_smooth i).differentiable (by simp) y)] at hd + have h := congrArg (fun L : (Fin 3 → ℝ) →L[ℝ] ℝ => L (Pi.single j 1)) hd + simpa using h + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildCentralL2.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildCentralL2.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0cd2b13cf00b6741b9520781cebec8853cb8571 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildCentralL2.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ParentCompletionJoin + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def actualChildSign (k : Fin 2) : ℝ := if k=0 then 1 else -1 + +def childAxis (i : Fin 3) : Fin 3 := ![1,0,2] i + +lemma childBand_central (k : Fin 2) {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand (-2*centralThickness) (-centralThickness)) : + sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y)∈centralClosed := by + rw [sourceClosedCollarBand_eq _ _ (by norm_num [centralThickness]) + (by norm_num [centralThickness])] at hy + rcases mem_iUnion.mp hy with ⟨i,hi⟩ + rcases mem_iUnion.mp hi with ⟨j,hj⟩ + rcases hj with ⟨x,hx,rfl⟩ + exact sourceChildCollar_central i j (by fin_cases k <;> simp [actualChildSign]) hx + +lemma childCentralBand_measurable : + MeasurableSet (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)) := + (isCompact_sourceClosedCollarBand (by norm_num [centralThickness]) (by norm_num [centralThickness])).measurableSet + +def childCentralRawComponentCLM (s : Fin 3 → ℝ) (k : Fin 2) (i : Fin 4) : + CentralAmbient s →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + (lpZeroExtensionCLM childCentralBand_measurable).comp + ((lpRestrictionCLM (sourceClosedCollarBand (-2*centralThickness) (-centralThickness))).comp + ((sourceChildPullbackCLM (actualChildSign k)).comp + (centralPhysicalWholeCLM.comp (centralAmbientComponent s i)))) + +lemma childCentralRawComponentCLM_smooth_ae (s : Fin 3 → ℝ) (k : Fin 2) + (f : centralSmoothFunctions) (i : Fin 4) : + childCentralRawComponentCLM s k i (centralEmbedL s f)=ᵐ[volume] + (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)).indicator + (fun y => centralJetField f i (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) := by + have hp := (sourceChildPullbackCLM_ae (actualChildSign k) (centralPhysicalWholeCLM (centralSmoothJet f i))).trans + ((sourceChildCoordinates_quasi (actualChildSign k)).ae_eq_comp (centralPhysicalWholeCLM_smooth_ae f i)) + have hr := (lpRestrictionCLM_ae (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)) + (sourceChildPullbackCLM (actualChildSign k) (centralPhysicalWholeCLM (centralSmoothJet f i)))).trans + (ae_restrict_of_ae hp) + apply lpZeroExtensionCLM_ae_of_ae childCentralBand_measurable + filter_upwards [hr,ae_restrict_mem childCentralBand_measurable] with y hy hb + change (lpRestrictionCLM (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)) + (sourceChildPullbackCLM (actualChildSign k) (centralPhysicalWholeCLM (centralSmoothJet f i)))) y=_ + rw [hy,Function.comp_apply,indicator_of_mem (show sourceChildCoordinates (actualChildSign k) y∈centralPhysical from childBand_central k hb)] + +lemma central_child_partial (k : Fin 2) (f : centralSmoothFunctions) (i : Fin 3) (y : Fin 3 → ℝ) : + sourceScale*centralJetField f (childAxis i).succ + (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))= + fderiv ℝ (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) y (Pi.single i 1) := by + have he := (((central_smooth f).comp sourcePairCLE.contDiff).differentiable (by simp) + (sourceChildCoordinates (actualChildSign k) y)).hasFDerivAt.comp y (sourceChildCoordinates_hasFDeriv (actualChildSign k) y) + have hi : sourceChildDerivative (Pi.single i 1)=sourceScale • Pi.single (childAxis i) 1 := by + rw [sourceChildDerivative_apply] + fin_cases i <;> ext j <;> fin_cases j <;> norm_num [childAxis,Pi.single_apply,Fin.ext_iff] + rw [central_parent_partial] + change sourceScale*(fderiv ℝ (f ∘ sourcePairCLE) (sourceChildCoordinates (actualChildSign k) y)) (Pi.single (childAxis i) 1)= + fderiv ℝ ((f ∘ sourcePairCLE) ∘ sourceChildCoordinates (actualChildSign k)) y (Pi.single i 1) + rw [he.fderiv,ContinuousLinearMap.comp_apply,hi,map_smul,smul_eq_mul] + +lemma central_child_trace_eq (s : Fin 3 → ℝ) (k : Fin 2) (f : centralSmoothFunctions) : + smoothCollarTrace s (-centralThickness) + (((central_smooth f).comp sourcePairCLE.contDiff).comp (sourceChildCoordinates_contDiff (actualChildSign k)))= + centralSmoothTrace s f k.succ := by + apply spectralTraceGraph_fst_injective (torusRate s) + change (smoothCollarTrace s (-centralThickness) + (((central_smooth f).comp sourcePairCLE.contDiff).comp (sourceChildCoordinates_contDiff (actualChildSign k)))).val 0 = + (centralSmoothTrace s f k.succ).val 0 + rw [centralSmoothTrace_fst] + ext h + rw [smoothCollarTrace_fst,centralTraceFourier_apply] + fin_cases k <;> rfl + +def childCentralComponentCLM (s : Fin 3 → ℝ) (k : Fin 2) (i : Fin 4) : + CentralAmbient s →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + Fin.cases (childCentralRawComponentCLM s k 0) + (fun j => sourceScale • childCentralRawComponentCLM s k (childAxis j).succ) i + +lemma childCentralComponentCLM_smooth_value (s : Fin 3 → ℝ) (k : Fin 2) (f : centralSmoothFunctions) : + childCentralComponentCLM s k 0 (centralEmbedL s f)=ᵐ[volume] + (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)).indicator + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) := + childCentralRawComponentCLM_smooth_ae s k f 0 + +lemma childCentralComponentCLM_smooth_gradient (s : Fin 3 → ℝ) (k : Fin 2) + (f : centralSmoothFunctions) (i : Fin 3) : + childCentralComponentCLM s k i.succ (centralEmbedL s f)=ᵐ[volume] + (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)).indicator + (fun y => fderiv ℝ (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) y (Pi.single i 1)) := by + apply (Lp.coeFn_smul sourceScale (childCentralRawComponentCLM s k (childAxis i).succ (centralEmbedL s f))).trans + filter_upwards [childCentralRawComponentCLM_smooth_ae s k f (childAxis i).succ] with y hy + change sourceScale*_=_ + rw [hy] + by_cases hb : y∈sourceClosedCollarBand (-2*centralThickness) (-centralThickness) + · simp only [indicator_of_mem hb,central_child_partial] + · simp only [indicator_of_notMem hb,mul_zero] + +lemma childEndBand_measurable : MeasurableSet (sourceClosedCollarBand (-centralThickness) 0) := + (isCompact_sourceClosedCollarBand (by norm_num [centralThickness]) (by norm_num [centralThickness])).measurableSet + +lemma childEndTime_mem {a : ℝ} (ha : 0 (attachedEndPoissonField s f a (-centralThickness) 0 y).re) := by + apply lpZeroExtensionCLM_ae_of_ae childEndBand_measurable + have he := attachedEndFlatCLM_ae s hs f ha.ne' + (show 0≤a*centralThickness by exact mul_nonneg ha.le (by norm_num [centralThickness])) + (show -centralThickness≤(0:ℝ) by norm_num [centralThickness]) (by norm_num [centralThickness]) (by norm_num) + (childEndTime_mem ha) 0 + apply (Complex.reCLM.coeFn_compLpL _).trans + filter_upwards [he] with y hy + exact congrArg Complex.re hy + +lemma childEndGradientCLM_ae (f : spectralTraceGraph (torusRate s)) (i : Fin 3) : + childEndGradientCLM s hs ha i f=ᵐ[volume] + (sourceClosedCollarBand (-centralThickness) 0).indicator + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a (-centralThickness) 0 y).re) y (Pi.single i 1)) := by + apply lpZeroExtensionCLM_ae_of_ae childEndBand_measurable + exact attachedEndGradientL_ae s hs ha.ne' + (show 0≤a*centralThickness by exact mul_nonneg ha.le (by norm_num [centralThickness])) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num) (childEndTime_mem ha) i f + +def childJoinedComponentCLM (k : Fin 2) (i : Fin 4) : CentralAmbient s →L[ℝ] + Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + childCentralComponentCLM s k i+ + ((Fin.cases (childEndValueCLM s hs ha) (childEndGradientCLM s hs ha) : + Fin 4 → spectralTraceGraph (torusRate s) →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ))) i).comp (centralAmbientT s k.succ) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildComplementPartition.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildComplementPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..94b8bb2f50db680bf9e07a842bbab9763d2b4e29 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildComplementPartition.lean @@ -0,0 +1,186 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentFullEndEnergy +import OAI.Analysis.Conductivity.Walls.ChildSeamCutoff + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem centralChild_complement_partition (k : Fin 2) : + ∃ (l : ℝ) (η : (Fin 3 → ℝ) → ℝ),-centralThickness centralJoinChildCutoff k z+η z)=ᶠ[𝓝 y] (fun _ => 1)) := by + let χ : (Fin 3 → ℝ) → ℝ := centralJoinChildCutoff k + let q := fun y => 1-χ y + let K := sourceClosedCollarBand (-centralThickness) 0 ∩ tsupport q + have hK : IsCompact K := + (isCompact_sourceClosedCollarBand (show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]) + (show (0:ℝ)≤1/100 by norm_num)).inter_right (isClosed_tsupport q) + have hKt (y) (hy : y∈K) : -centralThickness ⟨hz.1.le,hz.2.le⟩) + obtain ⟨ψ,hψ1,hψ0,hψb⟩ := exists_contMDiffMap_one_nhds_of_subset_interior + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) hK.isClosed hi (n:=↑(⊤:ℕ∞)) + have hψc : HasCompactSupport ψ := HasCompactSupport.intro hbig hψ0 + have hψs : tsupport ψ⊆sourceClosedCollarBand l (centralThickness/2) := by + apply closure_minimal _ hbig.isClosed + intro y hy + by_contra hn + exact hy (hψ0 y hn) + let η := fun y => q y*ψ y + have hηs : tsupport η⊆sourceClosedCollarBand l (centralThickness/2) := + tsupport_mul_subset_right.trans hψs + refine ⟨l,η,hl,hl₀,(contDiff_const.sub (centralJoinChildCutoff_smooth k)).mul ψ.contMDiff.contDiff, + hψc.mul_left,?_,hηs,?_,?_⟩ + · intro y + have h₀ := centralJoinPartition.nonneg (centralChildPatch k) (sourceChildCoordinates (actualChildSign k) y) + have h₁ := centralJoinPartition.le_one (centralChildPatch k) (sourceChildCoordinates (actualChildSign k) y) + change 0≤χ y at h₀ + change χ y≤1 at h₁ + have h₂ := (hψb y).1 + have h₃ := (hψb y).2 + dsimp only [η,q] + rw [abs_of_nonneg (mul_nonneg (sub_nonneg.mpr h₁) h₂)] + nlinarith [mul_nonneg h₀ h₂] + · intro y hy + apply notMem_tsupport_iff_eventuallyEq.mp + intro hn + have hle := (hηs hn).1 + linarith + · intro y hy + by_cases hk : y∈K + · have hψ := hψ1.filter_mono (nhds_le_nhdsSet hk) + filter_upwards [hψ] with z hz + change centralJoinChildCutoff k z+((1-centralJoinChildCutoff k z)*ψ z)=1 + rw [hz] + ring + · have hq : y∉tsupport q := fun hn => hk ⟨hy,hn⟩ + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hq] with z hz + change q z=0 at hz + change χ z+q z*ψ z=1 + rw [hz,zero_mul,add_zero] + dsimp only [q] at hz + linarith + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem childAttachedCorrection_exists (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 mul_pos ha (sub_pos.mpr (hl.trans_le ht.1)) + obtain ⟨z,hz,hze⟩ := cut_fullAttachedEnd_H10 s hs (centralT s k.succ p) κ ha.ne' hR + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + (show l≤centralThickness/2 by + have ht : (0:ℝ) ![z 1/sourceScale,(z 0-σ*sourceOffset)/sourceScale,z 2/sourceScale] + left_inv := by intro x; ext i; fin_cases i <;> simp [sourceChildCoordinates,sourceScale] + right_inv := by intro x; ext i; fin_cases i <;> simp [sourceChildCoordinates,sourceScale] <;> ring + continuous_toFun := by apply continuous_pi; intro i; fin_cases i <;> dsimp [sourceChildCoordinates] <;> fun_prop + continuous_invFun := by apply continuous_pi; intro i; fin_cases i <;> dsimp <;> fun_prop + +def sourceChildJacobian : Matrix (Fin 3) (Fin 3) ℝ := + ![![0,sourceScale,0],![sourceScale,0,0],![0,0,sourceScale]] + +def sourceChildDerivative : (Fin 3 → ℝ) →L[ℝ] (Fin 3 → ℝ) := + (Matrix.toLin' sourceChildJacobian).toContinuousLinearMap + +lemma sourceChildDerivative_apply (x : Fin 3 → ℝ) : + sourceChildDerivative x=![sourceScale*x 1,sourceScale*x 0,sourceScale*x 2] := by + ext i; fin_cases i <;> simp [sourceChildDerivative,sourceChildJacobian,Matrix.toLin',LinearMap.toMatrix',Matrix.mulVecLin, + Matrix.mulVecBilin,Matrix.mulVec,Fin.sum_univ_succ,dotProduct] + +lemma sourceChildCoordinates_contDiff (σ : ℝ) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (sourceChildCoordinates σ) := by + apply contDiff_pi.mpr; intro i; fin_cases i <;> dsimp [sourceChildCoordinates] <;> fun_prop + +lemma sourceChildCoordinates_hasFDeriv (σ : ℝ) (x : Fin 3 → ℝ) : + HasFDerivAt (sourceChildCoordinates σ) sourceChildDerivative x := by + have he : sourceChildCoordinates σ=fun y => sourceChildDerivative y+![σ*sourceOffset,0,0] := by + funext y; rw [sourceChildDerivative_apply]; ext i; fin_cases i <;> simp [sourceChildCoordinates] + rw [he] + simpa using sourceChildDerivative.hasFDerivAt.add_const ![σ*sourceOffset,0,0] + +lemma sourceChildDerivative_det : sourceChildDerivative.det= -sourceScale^3 := by + change (Matrix.toLin' sourceChildJacobian).det= -sourceScale^3 + rw [LinearMap.det_toLin',Matrix.det_fin_three] + simp [sourceChildJacobian] + ring + +lemma sourceChildDerivative_norm : ‖sourceChildDerivative‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro x + rw [sourceChildDerivative_apply,one_mul] + apply (pi_norm_le_iff_of_nonneg (norm_nonneg x)).mpr + intro i + have h0 := norm_le_pi_norm x (0 : Fin 3) + have h1 := norm_le_pi_norm x (1 : Fin 3) + have h2 := norm_le_pi_norm x (2 : Fin 3) + simp only [Real.norm_eq_abs] at h0 h1 h2 + fin_cases i <;> simp only [Fin.isValue, + Real.norm_eq_abs] <;> norm_num [sourceScale] <;> nlinarith [abs_nonneg (x 0),abs_nonneg (x 1),abs_nonneg (x 2)] + +lemma sourceChild_energy {f : (Fin 3 → ℝ) → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (σ : ℝ) (x : Fin 3 → ℝ) : + sourcePhysicalEnergy (f ∘ sourceChildCoordinates σ) x≤ sourcePhysicalEnergy f (sourceChildCoordinates σ x) := by + have he := ((hf.differentiable (by simp) _).hasFDerivAt.comp x (sourceChildCoordinates_hasFDeriv σ x)).fderiv + have hn := ContinuousLinearMap.opNorm_comp_le (fderiv ℝ f (sourceChildCoordinates σ x)) sourceChildDerivative + have hl := hn.trans (mul_le_of_le_one_right (norm_nonneg _) sourceChildDerivative_norm) + have hs := mul_self_le_mul_self (norm_nonneg _) hl + dsimp only [sourcePhysicalEnergy,Function.comp_apply] + rw [he] + nlinarith + +lemma integral_sourceChild_preimage (σ : ℝ) {K : Set (Fin 3 → ℝ)} (hK : IsCompact K) + (g : (Fin 3 → ℝ) → ℝ) : + (∫ x in sourceChildCoordinates σ ⁻¹' K,g (sourceChildCoordinates σ x))= + (sourceScale^3)⁻¹*(∫ y in K,g y) := by + have hs : sourceScale≠0 := by norm_num [sourceScale] + have hc := (sourceChildHomeomorph σ).isCompact_preimage.mpr hK + have hh := integral_image_eq_integral_abs_det_fderiv_smul volume hc.measurableSet + (fun x _ => (sourceChildCoordinates_hasFDeriv σ x).hasFDerivWithinAt) + (sourceChildHomeomorph σ).injective.injOn g + have him : sourceChildCoordinates σ '' (sourceChildCoordinates σ ⁻¹' K)=K := + Set.image_preimage_eq K (sourceChildHomeomorph σ).surjective + change (∫ x in sourceChildCoordinates σ '' (sourceChildCoordinates σ ⁻¹' K),g x)= + ∫ x in sourceChildCoordinates σ ⁻¹' K,abs sourceChildDerivative.det • g (sourceChildCoordinates σ x) at hh + rw [him] at hh + simp only [sourceChildDerivative_det,abs_neg,abs_pow,abs_of_nonneg (show 0≤sourceScale by norm_num [sourceScale]), + smul_eq_mul,integral_const_mul] at hh + norm_num [sourceScale] at hh ⊢ + linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildEndPartition.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildEndPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4f7951c405bb8d927b8c3d11fabf2fa31be3344 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildEndPartition.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentEndPartition + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem child_end_partition_exists : + ∃ χ η : (Fin 3 → ℝ) → ℝ, + ContDiff ℝ (↑(⊤:ℕ∞)) χ ∧ HasCompactSupport χ ∧ + (∀ x,|χ x|≤1) ∧ tsupport χ⊆sourceClosedCollarBand (-2*centralThickness) 0 ∧ + ContDiff ℝ (↑(⊤:ℕ∞)) η ∧ HasCompactSupport η ∧ + (∀ x,|η x|≤1) ∧ tsupport η⊆sourceClosedCollarBand + (-3*centralThickness/4) (centralThickness/2) ∧ + (∀ x∈sourceClosedCollarBand (-centralThickness) 0, + (fun y => χ y+η y)=ᶠ[𝓝 x] (fun _ => 1)) := by + obtain ⟨χ,hχ,hχc,hχb,hχs,hχ1⟩ := exists_nonneg_band_cutoff + (l₀ := -7*centralThickness/4) (l := -3*centralThickness/2) + (r := -centralThickness/2) (r₀ := -centralThickness/4) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + obtain ⟨ψ,hψ,hψc,hψb,hψs,hψ1⟩ := exists_nonneg_band_cutoff + (l₀ := -3*centralThickness/4) (l := -centralThickness/2) + (r:=centralThickness/4) (r₀:=centralThickness/2) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + let η := fun x => (1-χ x)*ψ x + have hη : ContDiff ℝ (↑(⊤:ℕ∞)) η := (contDiff_const.sub hχ).mul hψ + have hηc : HasCompactSupport η := hψc.mul_left + refine ⟨χ,η,hχ,hχc,?_,?_,hη,hηc,?_,?_,?_⟩ + · intro x + rw [abs_of_nonneg (hχb x).1] + exact (hχb x).2 + · intro x hx + have hb := hχs hx + constructor <;> dsimp [centralThickness] at * <;> linarith [hb.1,hb.2] + · intro x + have h₀ := (hχb x).1 + have h₁ := (hχb x).2 + have h₂ := (hψb x).1 + have h₃ := (hψb x).2 + dsimp only [η] + rw [abs_of_nonneg (mul_nonneg (sub_nonneg.mpr h₁) h₂)] + nlinarith [mul_nonneg h₀ h₂] + · exact tsupport_mul_subset_right.trans hψs + · intro x hx + by_cases ht : -centralThickness/2 ≤ sourceCollarTime x + · have hm : x∈sourceClosedCollarBand (-centralThickness/2) (centralThickness/4) := + ⟨ht,(by dsimp [centralThickness]; linarith [hx.2])⟩ + filter_upwards [hψ1 x hm] with y hy + simp only [η,hy,mul_one] + ring + · have hm : x∈sourceClosedCollarBand (-3*centralThickness/2) (-centralThickness/2) := + ⟨(by dsimp [centralThickness] at *; linarith [hx.1]),(lt_of_not_ge ht).le⟩ + filter_upwards [hχ1 x hm] with y hy + simp [η,hy] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildFullEndEnergy.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildFullEndEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..9e6b38e5e341a939663aa7805cb2269c29d26654 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildFullEndEnergy.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildFullEndH1 + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +theorem childFullEnd_weak_energy_exists (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 originalPiGradient w y ⬝ᵥ + (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y)) + (volume.restrict (sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0)) ∧ + (∫ y in sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0, + originalPiGradient w y ⬝ᵥ (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y))= + ∫ x in sourceExtendedBox (-centralThickness) 0, + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (fullEndFlatCovector s (centralT s k.succ p) κ (a*(x 0-(-centralThickness))) + (torusAngles (sourceFaceAngles i j x)) ⬝ᵥ + (flatCylinderMatrix s*ᵥ((attachedCartesianMatrix a i j x)⁻¹*ᵥ + originalPiGradient ψ (sourceCollarPiece i j x))))) := by + obtain ⟨w,hw,he⟩ := childFullEnd_H10 s hs ha k κ p + have hlow : -(1:ℝ)/100≤-centralThickness := by norm_num [centralThickness] + have hupp : (0:ℝ)≤1/100 := by norm_num + have hband : sourceClosedCollarBand (-centralThickness) 0⊆ + sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := + fun _ hy => ⟨hlow.trans hy.1,hy.2.trans hupp⟩ + have hjet := originalPiGradient_eq_on hband w + (fullAttachedEndGradient s (centralT s k.succ p) a (-centralThickness) κ) + (by filter_upwards [he] with x hx hm; exact (hx hm).2) + refine ⟨w,hw,he,fun ψ i j => ⟨?_,?_⟩⟩ + · exact attachedCollarTensor_weak_integrable s ha.ne' + (sourceCollarClosedPiece_measurable (-centralThickness) 0 i j) + ((sourceCollarClosedPiece_subset hlow hupp i j).trans hband) w ψ + · calc + _ = ∫ y in sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0, + fullAttachedEndGradient s (centralT s k.succ p) a (-centralThickness) κ y ⬝ᵥ + (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae hjet, + ae_restrict_mem (sourceCollarClosedPiece_measurable (-centralThickness) 0 i j)] with y hy hm + rw [hy (sourceCollarClosedPiece_subset hlow hupp i j hm)] + _ = _ := fullAttachedEnd_vector_integral_open s hs (centralT s k.succ p) κ + (originalPiGradient ψ) ha.ne' i j hlow hupp + (fun t ht => mul_pos ha (sub_pos.mpr ht.1)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildInverse.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..aa93a124fa9e9d19cd46fb23c9cef1f5b0f30016 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildInverse.lean @@ -0,0 +1,137 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ChildCentralL2 + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology + +lemma sourceChildInverse_map_volume (σ : ℝ) : + Measure.map (sourceChildHomeomorph σ).symm volume=ENNReal.ofReal (sourceScale^3) • volume := by + apply (sourceChildHomeomorph σ).toMeasurableEquiv.measurableEmbedding.map_injective + change Measure.map (sourceChildHomeomorph σ) (Measure.map (sourceChildHomeomorph σ).symm volume)= + Measure.map (sourceChildHomeomorph σ) (ENNReal.ofReal (sourceScale^3) • volume) + rw [Measure.map_map (sourceChildHomeomorph σ).measurable (sourceChildHomeomorph σ).symm.measurable] + have he : (sourceChildHomeomorph σ) ∘ (sourceChildHomeomorph σ).symm=id := + funext (sourceChildHomeomorph σ).apply_symm_apply + rw [he,Measure.map_id,Measure.map_smul _ (sourceChildHomeomorph σ).measurable.aemeasurable] + change volume=ENNReal.ofReal (sourceScale^3) • Measure.map (sourceChildCoordinates σ) volume + rw [sourceChildCoordinates_map_volume,smul_smul,←ENNReal.ofReal_mul (by norm_num [sourceScale])] + norm_num [sourceScale] + +lemma sourceChildInverse_quasi (σ : ℝ) : + Measure.QuasiMeasurePreserving (sourceChildHomeomorph σ).symm volume volume := by + refine ⟨(sourceChildHomeomorph σ).symm.measurable,?_⟩ + rw [sourceChildInverse_map_volume] + exact Measure.smul_absolutelyContinuous + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def sourceChildPushforwardCLM (σ : ℝ) : Lp E 2 (volume : Measure (Fin 3 → ℝ)) →L[ℝ] + Lp E 2 (volume : Measure (Fin 3 → ℝ)) := + lpBoundedPullbackCLM (sourceChildHomeomorph σ).symm.toMeasurableEquiv ENNReal.ofReal_ne_top + (le_of_eq (sourceChildInverse_map_volume σ)) + +lemma sourceChildPushforwardCLM_ae (σ : ℝ) (f : Lp E 2 (volume : Measure (Fin 3 → ℝ))) : + sourceChildPushforwardCLM σ f=ᵐ[volume] (fun y => f ((sourceChildHomeomorph σ).symm y)) := + lpBoundedPullbackCLM_ae _ _ _ f + +lemma sourceChildInverse_contDiff (σ : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) ((sourceChildHomeomorph σ).symm : (Fin 3 → ℝ) → (Fin 3 → ℝ)) := by + apply contDiff_pi.mpr + intro i + fin_cases i <;> dsimp [sourceChildHomeomorph] + all_goals fun_prop + +def sourceChildInverseDerivative : (Fin 3 → ℝ) →L[ℝ] (Fin 3 → ℝ) := + (sourceScale^2)⁻¹ • sourceChildDerivative + +lemma sourceChildInverseDerivative_apply (y : Fin 3 → ℝ) : + sourceChildInverseDerivative y=![y 1/sourceScale,y 0/sourceScale,y 2/sourceScale] := by + rw [sourceChildInverseDerivative,smul_apply,sourceChildDerivative_apply] + ext i + fin_cases i <;> norm_num [sourceScale] <;> ring + +lemma sourceChildInverse_hasFDeriv (σ : ℝ) (y : Fin 3 → ℝ) : + HasFDerivAt ((sourceChildHomeomorph σ).symm : (Fin 3 → ℝ) → (Fin 3 → ℝ)) sourceChildInverseDerivative y := by + have he : ((sourceChildHomeomorph σ).symm : (Fin 3 → ℝ) → (Fin 3 → ℝ))= + fun y => sourceChildInverseDerivative y+![0,-σ*sourceOffset/sourceScale,0] := by + funext y + rw [sourceChildInverseDerivative_apply] + ext i + fin_cases i <;> simp [sourceChildHomeomorph]; ring + rw [he] + exact sourceChildInverseDerivative.hasFDerivAt.add_const _ + +lemma sourceChildInverse_single (i : Fin 3) : + sourceChildInverseDerivative (Pi.single i 1)=sourceScale⁻¹ • Pi.single (childAxis i) 1 := by + rw [sourceChildInverseDerivative_apply] + fin_cases i <;> ext j <;> fin_cases j <;> norm_num [childAxis,Pi.single_apply,Fin.ext_iff,sourceScale] + +end + +open Set MeasureTheory Filter Topology + +lemma sourceChild_euclidean_norm (σ : ℝ) (y : Fin 3 → ℝ) : + ‖WithLp.toLp 2 (sourceChildCoordinates σ y)‖ ≤ sourceScale * ‖WithLp.toLp 2 y‖ + |σ*sourceOffset| := by + let v : R3 := WithLp.toLp 2 ![y 1,y 0,y 2] + have hv : ‖v‖=‖WithLp.toLp 2 y‖ := by + have h₀ := EuclideanSpace.real_norm_sq_eq v + have h₁ := EuclideanSpace.real_norm_sq_eq (WithLp.toLp 2 y : R3) + simp [v,Fin.sum_univ_succ] at h₀ h₁ + nlinarith [norm_nonneg v,norm_nonneg (WithLp.toLp 2 y : R3)] + have he : (WithLp.toLp 2 (sourceChildCoordinates σ y) : R3)= + sourceScale • v+EuclideanSpace.single 0 (σ*sourceOffset) := by + ext i + fin_cases i <;> simp [sourceChildCoordinates,v] + rw [he] + calc + _ ≤ ‖sourceScale • v‖+‖EuclideanSpace.single 0 (σ*sourceOffset)‖ := norm_add_le _ _ + _ = _ := by rw [norm_smul,hv,PiLp.norm_single,Real.norm_eq_abs, + Real.norm_eq_abs,abs_of_nonneg (show 0 ≤ sourceScale by norm_num [sourceScale])] + +def sourceChildEuclidean (σ : ℝ) : R3 ≃ₜ R3 := + (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).toHomeomorph.trans + ((sourceChildHomeomorph σ).trans (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).symm.toHomeomorph) + +lemma sourceChildEuclidean_apply (σ : ℝ) (x : R3) : + sourceChildEuclidean σ x=WithLp.toLp 2 (sourceChildCoordinates σ (WithLp.ofLp x)) := rfl + +lemma sourceChildEuclidean_symm_apply (σ : ℝ) (x : R3) : + (sourceChildEuclidean σ).symm x=WithLp.toLp 2 ((sourceChildHomeomorph σ).symm (WithLp.ofLp x)) := rfl + +lemma sourceChildEuclidean_symm_contDiff (σ : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) ((sourceChildEuclidean σ).symm : R3 → R3) := + (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).symm.contDiff.comp + ((sourceChildInverse_contDiff σ).comp (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).contDiff) + +lemma sourceChildEuclidean_ball (k : Fin 2) : sourceChildEuclidean (actualChildSign k) '' ball⊆ball := by + rintro x ⟨y,hy,rfl⟩ + have hn := sourceChild_euclidean_norm (actualChildSign k) (WithLp.ofLp y) + have hσ : |actualChildSign k|=1 := by fin_cases k <;> norm_num [actualChildSign] + rw [abs_mul,hσ,one_mul] at hn + change ‖WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) (WithLp.ofLp y))‖ ≤ sourceScale * ‖y‖ + |sourceOffset| at hn + change dist (sourceChildEuclidean (actualChildSign k) y) 0<3 + rw [dist_zero_right,sourceChildEuclidean_apply] + have hy' : ‖y‖<3 := by simpa only [ball,Metric.mem_ball,dist_zero_right] using hy + norm_num [sourceScale,sourceOffset] at hn + linarith + +lemma sourceChildEuclidean_comp_support (k : Fin 2) {f : R3 → ℝ} + (hs : tsupport f⊆ball) : + tsupport (f ∘ (sourceChildEuclidean (actualChildSign k)).symm)⊆ball := by + intro x hx + have hy := tsupport_comp_subset_preimage f (sourceChildEuclidean (actualChildSign k)).symm.continuous hx + have him : x∈sourceChildEuclidean (actualChildSign k) '' ball := + ⟨(sourceChildEuclidean (actualChildSign k)).symm x,hs hy,(sourceChildEuclidean (actualChildSign k)).apply_symm_apply x⟩ + exact sourceChildEuclidean_ball k him + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildJetScaling.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildJetScaling.lean new file mode 100644 index 0000000000000000000000000000000000000000..5f9334d58dd1e6726fabdc0af06a01446cea2fa1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildJetScaling.lean @@ -0,0 +1,195 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildH1Pullback + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +attribute [local instance] Classical.propDecidable + +lemma sourceChildEuclidean_map_volume (σ : ℝ) : + Measure.map (sourceChildEuclidean σ) volume=ENNReal.ofReal ((sourceScale^3)⁻¹) • volume := by + change Measure.map (((WithLp.toLp 2 : Coord3 → R3) ∘ sourceChildCoordinates σ) ∘ + (WithLp.ofLp : R3 → Coord3)) volume=_ + rw [←Measure.map_map ((PiLp.continuous_toLp 2 (fun _ : Fin 3 => ℝ)).measurable.comp + (sourceChildCoordinates_contDiff σ).continuous.measurable) + (PiLp.continuous_ofLp 2 (fun _ : Fin 3 => ℝ)).measurable, + (PiLp.volume_preserving_ofLp (Fin 3)).map_eq, + ←Measure.map_map (PiLp.continuous_toLp 2 (fun _ : Fin 3 => ℝ)).measurable + (sourceChildCoordinates_contDiff σ).continuous.measurable, + sourceChildCoordinates_map_volume, + Measure.map_smul _ (PiLp.continuous_toLp 2 (fun _ : Fin 3 => ℝ)).measurable.aemeasurable, + (PiLp.volume_preserving_toLp (Fin 3)).map_eq] + +lemma sourceChildEuclidean_inverse_map_volume (σ : ℝ) : + Measure.map (sourceChildEuclidean σ).symm volume=ENNReal.ofReal (sourceScale^3) • volume := by + apply (sourceChildEuclidean σ).toMeasurableEquiv.measurableEmbedding.map_injective + change Measure.map (sourceChildEuclidean σ) (Measure.map (sourceChildEuclidean σ).symm volume)= + Measure.map (sourceChildEuclidean σ) (ENNReal.ofReal (sourceScale^3) • volume) + rw [Measure.map_map (sourceChildEuclidean σ).measurable (sourceChildEuclidean σ).symm.measurable] + have he : (sourceChildEuclidean σ) ∘ (sourceChildEuclidean σ).symm=id := + funext (sourceChildEuclidean σ).apply_symm_apply + rw [he,Measure.map_id,Measure.map_smul _ (sourceChildEuclidean σ).measurable.aemeasurable, + sourceChildEuclidean_map_volume,smul_smul, + ←ENNReal.ofReal_mul (by norm_num [sourceScale])] + norm_num [sourceScale] + +lemma integral_sourceChild_inverse (σ : ℝ) (f : R3 → ℝ) : + (∫ x,f ((sourceChildEuclidean σ).symm x))=sourceScale^3*(∫ x,f x) := by + have hh := integral_map_equiv (μ:=(volume : Measure R3)) (sourceChildEuclidean σ).symm.toMeasurableEquiv f + change (∫ x,f x ∂Measure.map (sourceChildEuclidean σ).symm volume)=_ at hh + rw [sourceChildEuclidean_inverse_map_volume,integral_smul_measure,ENNReal.toReal_ofReal (by norm_num [sourceScale]),smul_eq_mul] at hh + exact hh.symm + +def childAxisSwap (v : R3) : R3 := WithLp.toLp 2 (fun i => v (childAxis i)) + +lemma childAxisSwap_zero : childAxisSwap 0=0 := rfl +lemma childAxisSwap_inner (v w : R3) : inner ℝ (childAxisSwap v) w=inner ℝ v (childAxisSwap w) := by + simp only [PiLp.inner_apply,Fin.sum_univ_succ] + simp [childAxisSwap,childAxis,RCLike.inner_apply] + ring + +lemma childAxisSwap_involutive (v : R3) : childAxisSwap (childAxisSwap v)=v := by + ext i + exact congrArg v (childAxis_involutive i) + +lemma childAxisSwap_inner_self (v : R3) : inner ℝ (childAxisSwap v) (childAxisSwap v)=inner ℝ v v := by + rw [childAxisSwap_inner,childAxisSwap_involutive] + +lemma childH1Pullback_value (k : Fin 2) (u : H1) : + weakValue (childH1Pullback k u)=ᵐ[ballMeasure] + (fun x => weakValue u (sourceChildEuclidean (actualChildSign k) x)) := by + filter_upwards [childPullbackJetCLM_ae k u.val] with x hx + change jetValue (childPullbackJetCLM k u.val x)=_ + rw [hx] + rfl + +lemma childH1Pullback_gradient (k : Fin 2) (u : H1) : + weakGradient (childH1Pullback k u)=ᵐ[ballMeasure] + (fun x => sourceScale • childAxisSwap (weakGradient u (sourceChildEuclidean (actualChildSign k) x))) := by + filter_upwards [childPullbackJetCLM_ae k u.val] with x hx + change jetGradient (childPullbackJetCLM k u.val x)=_ + rw [hx] + rfl + +lemma childH10Transport_jet (k : Fin 2) (u : H10) : + (childH10Transport k u).val=ᵐ[ballMeasure] fun x => + if (sourceChildEuclidean (actualChildSign k)).symm x∈ball then + WithLp.toLp 2 (Fin.cases (weakValue u.val ((sourceChildEuclidean (actualChildSign k)).symm x)) + (fun j => sourceScale⁻¹*weakGradient u.val ((sourceChildEuclidean (actualChildSign k)).symm x) (childAxis j))) + else 0 := by + have he := ballWholePiJetCLM_ae_of_ae u.val.val (fun y => u.val.val (WithLp.toLp 2 y)) + (by filter_upwards [] with x; rfl) + apply (childTransportJetCLM_ae_of_ae k u.val.val _ he).trans + exact Eventually.of_forall (fun x => by + change (WithLp.toLp 2 (Fin.cases + ((if (sourceChildEuclidean (actualChildSign k)).symm x∈ball then u.val.val ((sourceChildEuclidean (actualChildSign k)).symm x) else 0) 0) + (fun j => sourceScale⁻¹*(if (sourceChildEuclidean (actualChildSign k)).symm x∈ball then + u.val.val ((sourceChildEuclidean (actualChildSign k)).symm x) else 0) (childAxis j).succ)) : JetFiber)=_ + dsimp only + split_ifs with h + · rfl + · ext i + cases i using Fin.cases <;> simp) + +lemma childH10Transport_value (k : Fin 2) (u : H10) : + weakValue (childH10Transport k u)=ᵐ[ballMeasure] fun x => + if (sourceChildEuclidean (actualChildSign k)).symm x∈ball then + weakValue u.val ((sourceChildEuclidean (actualChildSign k)).symm x) else 0 := by + filter_upwards [childH10Transport_jet k u] with x hx + change jetValue ((childH10Transport k u).val x)=_ + rw [hx] + split_ifs <;> rfl + +lemma childH10Transport_gradient (k : Fin 2) (u : H10) : + weakGradient (childH10Transport k u)=ᵐ[ballMeasure] fun x => + if (sourceChildEuclidean (actualChildSign k)).symm x∈ball then + sourceScale⁻¹ • childAxisSwap (weakGradient u.val ((sourceChildEuclidean (actualChildSign k)).symm x)) else 0 := by + filter_upwards [childH10Transport_jet k u] with x hx + change jetGradient ((childH10Transport k u).val x)=_ + rw [hx] + split_ifs <;> rfl + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +attribute [local instance] Classical.propDecidable + +lemma integral_child_ball (k : Fin 2) (f : R3 → ℝ) + (hf : ∀ᵐ x∂ballMeasure,(sourceChildEuclidean (actualChildSign k)).symm x∉ball → f x=0) : + (∫ x,f x ∂ballMeasure)=sourceScale^3*(∫ x,f (sourceChildEuclidean (actualChildSign k) x) ∂ballMeasure) := by + let S := sourceChildEuclidean (actualChildSign k) + have hid : (fun x => if S.symm x∈ball then f x else 0)= + (fun x => (ball.indicator (fun y => f (S y))) (S.symm x)) := by + funext x + simp only [indicator,Homeomorph.apply_symm_apply] + calc + _ = ∫ x,(if S.symm x∈ball then f x else 0) ∂ballMeasure := by + apply integral_congr_ae + filter_upwards [hf] with x hx + split_ifs with hb + · rfl + · exact hx hb + _ = ∫ x,(if S.symm x∈ball then f x else 0) := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + apply ite_eq_right + intro hh + apply hx + exact sourceChildEuclidean_ball k ⟨S.symm x,hh,S.apply_symm_apply x⟩ + _ = sourceScale^3*(∫ x,ball.indicator (fun y => f (S y)) x) := by + rw [hid] + exact integral_sourceChild_inverse _ _ + _ = _ := by rw [integral_indicator (show MeasurableSet ball from Metric.isOpen_ball.measurableSet)]; rfl + +lemma childH10Transport_gradient_at_child (k : Fin 2) (v : H10) : + (fun x => weakGradient (childH10Transport k v) (sourceChildEuclidean (actualChildSign k) x))=ᵐ[ballMeasure] + (fun x => sourceScale⁻¹ • childAxisSwap (weakGradient v.val x)) := by + filter_upwards [(sourceChildEuclidean_ball_quasi k).ae_eq_comp (childH10Transport_gradient k v), + ae_restrict_mem Metric.isOpen_ball.measurableSet] with x hx hxb + simpa only [Function.comp_apply,Homeomorph.symm_apply_apply,ite_eq_left hxb] using hx + +lemma child_energy_scaling (k : Fin 2) (v : H10) (h : H1) (a : R3 → ℝ) : + (∫ x,a x*inner ℝ (weakGradient (childH10Transport k v) x) (weakGradient h x) ∂ballMeasure)= + sourceScale*(∫ x,a (sourceChildEuclidean (actualChildSign k) x)* + inner ℝ (weakGradient v.val x) (weakGradient (childH1Pullback k h) x) ∂ballMeasure) := by + rw [integral_child_ball k _ (by + filter_upwards [childH10Transport_gradient k v] with x hx hn + rw [hx,ite_eq_right hn,inner_zero_left,mul_zero])] + rw [←integral_const_mul,←integral_const_mul] + apply integral_congr_ae + filter_upwards [childH10Transport_gradient_at_child k v,childH1Pullback_gradient k h] with x hv hh + rw [hv,hh,real_inner_smul_left,real_inner_smul_right,childAxisSwap_inner] + norm_num [sourceScale] + ring + +lemma weakGradient_norm_sq_integral (u : H1) : + ‖weakGradientL u‖^2=(∫ x,inner ℝ (weakGradient u x) (weakGradient u x) ∂ballMeasure) := by + rw [←real_inner_self_eq_norm_sq,L2.inner_def] + apply integral_congr_ae + filter_upwards [weakGradientL_apply_ae u] with x hx + rw [hx] + +lemma child_gradient_norm_sq (k : Fin 2) (v : H10) : + ‖weakGradientL (childH10Transport k v)‖^2=sourceScale*‖weakGradientL v.val‖^2 := by + rw [weakGradient_norm_sq_integral,weakGradient_norm_sq_integral] + rw [integral_child_ball k _ (by + filter_upwards [childH10Transport_gradient k v] with x hx hn + rw [hx,ite_eq_right hn,inner_zero_left])] + rw [←integral_const_mul,←integral_const_mul] + apply integral_congr_ae + filter_upwards [childH10Transport_gradient_at_child k v] with x hv + rw [hv,real_inner_smul_left,real_inner_smul_right,childAxisSwap_inner_self] + norm_num [sourceScale] + ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildLocalizedJet.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildLocalizedJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..27cd452bbcd6267ab53a29e1094af55b90337121 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildLocalizedJet.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ChildCentralL2 + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology + +lemma child_band_indicator_join {a : ℝ} (ha : 0 not_le_of_gt ht h.1 + simp only [indicator_of_mem hc,indicator_of_notMem he,add_zero,ite_eq_right hp] + · have hp : 0 not_le_of_gt ht h.2 + have he : y∈sourceClosedCollarBand (-centralThickness) 0 := ⟨ht.le,hy.2⟩ + simp only [indicator_of_notMem hc,indicator_of_mem he,zero_add,ite_eq_left hp] + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 ((compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single j 1))).comp (childJoinedComponentCLM s hs ha k 0))+ + ((compactMultiplierCLM hχ.continuous hc).comp (childJoinedComponentCLM s hs ha k j.succ))) i + +def childLocalJetCLM : CentralAmbient s →L[ℝ] JetSpace := + physicalFourJetCLM.comp (ContinuousLinearMap.pi (childLocalComponentCLM s hs ha k hχ hc)) + +end + +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 + (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)).indicator + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) y+ + (sourceClosedCollarBand (-centralThickness) 0).indicator + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) y) := by + apply (Lp.coeFn_add _ _).trans + filter_upwards [childCentralComponentCLM_smooth_value s k f,childEndValueCLM_ae s hs ha (centralSmoothTrace s f k.succ)] with y hy hz + change (childCentralComponentCLM s k 0 (centralEmbedL s f)) y+ + (childEndValueCLM s hs ha (centralSmoothTrace s f k.succ)) y=_ + rw [hy,hz] + +lemma childJoinedComponentCLM_smooth_gradient (f : centralSmoothFunctions) (i : Fin 3) : + childJoinedComponentCLM s hs ha k i.succ (centralEmbedL s f)=ᵐ[volume] (fun y => + (sourceClosedCollarBand (-2*centralThickness) (-centralThickness)).indicator + (fun y => fderiv ℝ (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) y (Pi.single i 1)) y+ + (sourceClosedCollarBand (-centralThickness) 0).indicator + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) y (Pi.single i 1)) y) := by + apply (Lp.coeFn_add _ _).trans + filter_upwards [childCentralComponentCLM_smooth_gradient s k f i,childEndGradientCLM_ae s hs ha (centralSmoothTrace s f k.succ) i] with y hy hz + change (childCentralComponentCLM s k i.succ (centralEmbedL s f)) y+ + (childEndGradientCLM s hs ha i (centralSmoothTrace s f k.succ)) y=_ + rw [hy,hz] + +include hχs in +lemma childLocalComponentCLM_smooth_value (f : centralSmoothFunctions) : + childLocalComponentCLM s hs ha k hχ hc 0 (centralEmbedL s f)=ᵐ[volume] + localJoinedValue (fun y => a*(sourceCollarTime y-(-centralThickness))) χ + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) := by + have he := compactMultiplierCLM_ae hχ.continuous hc (childJoinedComponentCLM s hs ha k 0 (centralEmbedL s f)) + filter_upwards [he,childJoinedComponentCLM_smooth_value s hs ha k f, + sourceColevel_ae_ne (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])] with y hy hv hn + simp only [childLocalComponentCLM, Fin.cases_zero, ContinuousLinearMap.comp_apply, localJoinedValue] + rw [hy,hv] + by_cases hys : y∈tsupport χ + · rw [child_band_indicator_join ha y (hχs hys) hn] + · rw [image_eq_zero_of_notMem_tsupport hys] + simp + +include hχs in +lemma childLocalComponentCLM_smooth_gradient (f : centralSmoothFunctions) (i : Fin 3) : + childLocalComponentCLM s hs ha k hχ hc i.succ (centralEmbedL s f)=ᵐ[volume] + localJoinedGradient (fun y => a*(sourceCollarTime y-(-centralThickness))) χ + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) i := by + have he₀ := compactMultiplierCLM_ae ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (childJoinedComponentCLM s hs ha k 0 (centralEmbedL s f)) + have he₁ := compactMultiplierCLM_ae hχ.continuous hc (childJoinedComponentCLM s hs ha k i.succ (centralEmbedL s f)) + apply (Lp.coeFn_add _ _).trans + filter_upwards [he₀,he₁,childJoinedComponentCLM_smooth_value s hs ha k f, + childJoinedComponentCLM_smooth_gradient s hs ha k f i, + sourceColevel_ae_ne (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])] with y h₀ h₁ hv hg hn + change (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (childJoinedComponentCLM s hs ha k 0 (centralEmbedL s f))) y+ + (compactMultiplierCLM hχ.continuous hc (childJoinedComponentCLM s hs ha k i.succ (centralEmbedL s f))) y=_ + rw [h₀,h₁,hv,hg] + simp only [localJoinedGradient] + by_cases hys : y∈tsupport χ + · rw [child_band_indicator_join ha y (hχs hys) hn, + child_band_indicator_join ha y (hχs hys) hn] + · rw [image_eq_zero_of_notMem_tsupport hys,fderiv_of_notMem_tsupport ℝ hys] + simp + +include hχs in +lemma childLocalJetCLM_smooth_ae (f : centralSmoothFunctions) : + childLocalJetCLM s hs ha k hχ hc (centralEmbedL s f)=ᵐ[ballMeasure] (fun x => + WithLp.toLp 2 (Fin.cases + (localJoinedValue (fun y => a*(sourceCollarTime y-(-centralThickness))) χ + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) (WithLp.ofLp x)) + (fun i => localJoinedGradient (fun y => a*(sourceCollarTime y-(-centralThickness))) χ + (fun y => f (sourcePairCoordinates (sourceChildCoordinates (actualChildSign k) y))) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f k.succ) a (-centralThickness) 0 y).re) i (WithLp.ofLp x)))) := by + have h₀ := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (childLocalComponentCLM_smooth_value s hs ha k hχ hc hχs f)) + have h₁ (i : Fin 3) := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (childLocalComponentCLM_smooth_gradient s hs ha k hχ hc hχs f i)) + apply (physicalFourJetCLM_ae (fun i => childLocalComponentCLM s hs ha k hχ hc i (centralEmbedL s f))).trans + filter_upwards [h₀,ae_all_iff.mpr h₁] with x hv hg + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact hv + · exact hg j + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ChildTransportFormula.lean b/lean/OAI/Analysis/Conductivity/Branching/ChildTransportFormula.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c595adcae6246ea12a60253186f708bc8818cfc --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ChildTransportFormula.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildH10Transport + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma childTransportComponentCLM_ae_of_ae (k : Fin 2) (z : JetSpace) + (f : (Fin 3 → ℝ) → JetFiber) (he : ballWholePiJetCLM z=ᵐ[volume] f) (i : Fin 4) : + childTransportComponentCLM k i z=ᵐ[volume] (fun y => Fin.cases + (f ((sourceChildHomeomorph (actualChildSign k)).symm y) 0) + (fun j => sourceScale⁻¹*f ((sourceChildHomeomorph (actualChildSign k)).symm y) (childAxis j).succ) i) := by + have hc (j : Fin 4) : ballWholePiComponentCLM j z=ᵐ[volume] (fun y => f y j) := by + filter_upwards [ballWholePiComponentCLM_ae j z,he] with y hi hy + rw [hi,hy] + have hp (j : Fin 4) := (sourceChildPushforwardCLM_ae (actualChildSign k) (ballWholePiComponentCLM j z)).trans + ((sourceChildInverse_quasi _).ae_eq_comp (hc j)) + refine Fin.cases ?_ (fun j => ?_) i + · exact hp 0 + · apply (Lp.coeFn_smul _ _).trans + filter_upwards [hp (childAxis j).succ] with y hy + exact congrArg (fun t : ℝ => sourceScale⁻¹*t) hy + +lemma childTransportJetCLM_ae_of_ae (k : Fin 2) (z : JetSpace) + (f : (Fin 3 → ℝ) → JetFiber) (he : ballWholePiJetCLM z=ᵐ[volume] f) : + childTransportJetCLM k z=ᵐ[ballMeasure] (fun x => WithLp.toLp 2 (Fin.cases + (f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x)) 0) + (fun j => sourceScale⁻¹*f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x)) (childAxis j).succ))) := by + have hi (i : Fin 4) := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (childTransportComponentCLM_ae_of_ae k z f he i)) + filter_upwards [physicalFourJetCLM_ae (fun i => childTransportComponentCLM k i z),ae_all_iff.mpr hi] with x hx hi + change physicalFourJetCLM (fun i => childTransportComponentCLM k i z) x=_ + rw [hx] + ext i + exact hi i + +lemma childAxis_involutive (i : Fin 3) : childAxis (childAxis i)=i := by + fin_cases i <;> rfl + +lemma sourceChildDerivative_single (i : Fin 3) : + sourceChildDerivative (Pi.single i 1)=sourceScale • Pi.single (childAxis i) 1 := by + rw [sourceChildDerivative_apply] + fin_cases i <;> ext j <;> fin_cases j <;> norm_num [childAxis,Pi.single_apply,Fin.ext_iff] + +lemma physical_child_partial_cancel {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (σ : ℝ) (y : Fin 3 → ℝ) (i : Fin 3) : + sourceScale⁻¹*fderiv ℝ (q ∘ sourceChildCoordinates σ) + ((sourceChildHomeomorph σ).symm y) (Pi.single (childAxis i) 1)= + fderiv ℝ q y (Pi.single i 1) := by + have hD := ((hq.differentiable (by simp)) _).hasFDerivAt.comp + ((sourceChildHomeomorph σ).symm y) (sourceChildCoordinates_hasFDeriv σ _) + rw [hD.fderiv,ContinuousLinearMap.comp_apply,sourceChildDerivative_single, + childAxis_involutive,map_smul,smul_eq_mul] + change sourceScale⁻¹*(sourceScale*fderiv ℝ q + ((sourceChildHomeomorph σ) ((sourceChildHomeomorph σ).symm y)) (Pi.single i 1))=_ + rw [Homeomorph.apply_symm_apply] + rw [←mul_assoc,inv_mul_cancel₀ (by norm_num [sourceScale]),one_mul] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CollarMeasureTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/CollarMeasureTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc1e2808641b99da9a2ceec49b5299ae95b5fbc7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CollarMeasureTransport.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CollarReverseBound + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +lemma finiteMeasure_le_of_nonneg_compact_integrals + {n : ℕ} {μ ν : Measure (Fin n → ℝ)} [IsFiniteMeasure μ] [IsFiniteMeasure ν] + (h : ∀ f : (Fin n → ℝ) → ℝ, Continuous f → HasCompactSupport f → + (∀ x,0≤f x) → (∫ x,f x ∂μ)≤∫ x,f x ∂ν) : μ≤ν := by + have hc (K : Set (Fin n → ℝ)) (hK : IsCompact K) : μ K≤ν K := by + rw [hK.measure_eq_biInf_integral_hasCompactSupport ν] + simp only [le_iInf_iff] + intro f hf hcomp hKf hn + exact ((hf.integrable_of_hasCompactSupport hcomp).measure_le_integral + (Eventually.of_forall hn) (fun x hx => by simp [hKf hx])).trans + (ENNReal.ofReal_le_ofReal (h f hf hcomp hn)) + apply Measure.le_iff.mpr + intro s hs + rw [hs.measure_eq_iSup_isCompact_of_ne_top (measure_ne_top μ s)] + simp only [iSup_le_iff] + intro K hKs hK + exact (hc K hK).trans (measure_mono hKs) + +def sourcePhysicalCollarMeasure (l r : ℝ) : Measure (Fin 3 → ℝ) := + ∑ i : Fin 4,∑ j : Fin 4,volume.restrict (sourceCollarPiece i j '' sourceExtendedBox l r) + +def sourceAngularCollarMeasure (l r : ℝ) : Measure (Fin 3 → ℝ) := + Measure.map (Function.uncurry sourceAngularCollar) + ((volume.restrict (Ioc l r)).prod (volume : Measure (UnitAddTorus (Fin 2)))) + +lemma continuous_uncurry_sourceAngularCollar : Continuous (Function.uncurry sourceAngularCollar) := by + change Continuous (fun z : ℝ×UnitAddTorus (Fin 2) => sourceAngularCollar z.1 z.2) + simpa only [zero_add] using continuous_sourceAngular 0 + +instance sourcePhysicalCollarMeasure_finite (l r : ℝ) : + IsFiniteMeasure (sourcePhysicalCollarMeasure l r) := by + have (i j : Fin 4) : IsFiniteMeasure + (volume.restrict (sourceCollarPiece i j '' sourceExtendedBox l r)) := + ⟨by simpa only [Measure.restrict_apply_univ,sourceExtendedBox] using (isCompact_Icc.image (sourceCollarPiece_contDiff i j).continuous).measure_lt_top⟩ + unfold sourcePhysicalCollarMeasure + infer_instance + +instance sourceAngularCollarMeasure_finite (l r : ℝ) : + IsFiniteMeasure (sourceAngularCollarMeasure l r) := by + unfold sourceAngularCollarMeasure + infer_instance + +lemma integral_sourcePhysicalCollarMeasure {f : (Fin 3 → ℝ) → ℝ} + (hf : Continuous f) (l r : ℝ) : + (∫ x,f x ∂sourcePhysicalCollarMeasure l r)= + ∑ i : Fin 4,∑ j : Fin 4,∫ x in sourceCollarPiece i j '' sourceExtendedBox l r,f x := by + have hi (i j : Fin 4) : IntegrableOn f (sourceCollarPiece i j '' sourceExtendedBox l r) := + hf.continuousOn.integrableOn_compact (isCompact_Icc.image (sourceCollarPiece_contDiff i j).continuous) + unfold sourcePhysicalCollarMeasure + rw [integral_finsetSum_measure (fun i _ => integrable_finsetSum_measure.mpr (fun j _ => hi i j))] + apply Finset.sum_congr rfl + intro i _ + exact integral_finsetSum_measure (fun j _ => hi i j) + +lemma integral_sourceAngularCollarMeasure {f : (Fin 3 → ℝ) → ℝ} + (hf : Continuous f) {l r : ℝ} (hlr : l≤r) : + (∫ x,f x ∂sourceAngularCollarMeasure l r)= + ∫ t in l..r,∫ θ : UnitAddTorus (Fin 2),f (sourceAngularCollar t θ) := by + unfold sourceAngularCollarMeasure + rw [integral_map continuous_uncurry_sourceAngularCollar.aemeasurable hf.aestronglyMeasurable] + have hi : Integrable (fun p : ℝ×UnitAddTorus (Fin 2) => f (sourceAngularCollar p.1 p.2)) + ((volume.restrict (Ioc l r)).prod volume) := by + have hh := (hf.comp continuous_uncurry_sourceAngularCollar).continuousOn.integrableOn_compact (μ:=volume) + ((isCompact_Icc : IsCompact (Icc l r)).prod (isCompact_univ : IsCompact (univ : Set (UnitAddTorus (Fin 2))))) + have hh' := hh.mono_set (prod_mono Ioc_subset_Icc_self Subset.rfl) + simpa only [Function.comp_def,Function.uncurry_def,IntegrableOn,Measure.volume_eq_prod,←Measure.prod_restrict,Measure.restrict_univ] using hh' + simp only [Function.uncurry] + rw [integral_prod _ hi,intervalIntegral.integral_of_le hlr] + +theorem sourcePhysicalCollarMeasure_le {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + sourcePhysicalCollarMeasure l r ≤ + ENNReal.ofReal (2/(faceRayDensityLower 1*faceRayDensityLower sourceRadialWidth)) • + sourceAngularCollarMeasure l r := by + have : IsFiniteMeasure + (ENNReal.ofReal (2/(faceRayDensityLower 1*faceRayDensityLower sourceRadialWidth)) • + sourceAngularCollarMeasure l r) := + ⟨by + rw [Measure.smul_apply] + exact ENNReal.mul_lt_top ENNReal.ofReal_lt_top (measure_lt_top _ _)⟩ + apply finiteMeasure_le_of_nonneg_compact_integrals + intro f hf hcomp hn + rw [integral_sourcePhysicalCollarMeasure hf,integral_smul_measure, + ENNReal.toReal_ofReal (by + have h0 := faceRayDensityLower_pos (w:=1) (by norm_num) + have h1 := faceRayDensityLower_pos (w:=sourceRadialWidth) + (by norm_num [sourceRadialWidth,sourceHole]) + positivity),integral_sourceAngularCollarMeasure hf hlr] + exact sourceAngular_volume_reverse hf hn hlr hl hr + +theorem sourceAngularCollarMeasure_le {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + sourceAngularCollarMeasure l r ≤ + ENNReal.ofReal (100*((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi))) • + sourcePhysicalCollarMeasure l r := by + have : IsFiniteMeasure + (ENNReal.ofReal (100*((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi))) • + sourcePhysicalCollarMeasure l r) := + ⟨by + rw [Measure.smul_apply] + exact ENNReal.mul_lt_top ENNReal.ofReal_lt_top (measure_lt_top _ _)⟩ + apply finiteMeasure_le_of_nonneg_compact_integrals + intro f hf hcomp hn + rw [integral_sourceAngularCollarMeasure hf hlr,integral_smul_measure, + ENNReal.toReal_ofReal (by norm_num [sourceRadialWidth,sourceHole]; positivity), + integral_sourcePhysicalCollarMeasure hf] + exact sourceAngular_volume_bound hf hn hlr hl hr + +theorem sourcePhysical_memLp_of_angular {E : Type*} [NormedAddCommGroup E] + {g : (Fin 3 → ℝ) → E} (hg : StronglyMeasurable g) {p : ℝ≥0∞} {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hm : MemLp (g ∘ Function.uncurry sourceAngularCollar) p + ((volume.restrict (Ioc l r)).prod (volume : Measure (UnitAddTorus (Fin 2))))) : + MemLp g p (sourcePhysicalCollarMeasure l r) := by + have H : MemLp g p (sourceAngularCollarMeasure l r) := + (memLp_map_measure_iff hg.aestronglyMeasurable + continuous_uncurry_sourceAngularCollar.aemeasurable).mpr hm + exact H.of_measure_le_smul ENNReal.ofReal_ne_top (sourcePhysicalCollarMeasure_le hlr hl hr) + +theorem sourceCollar_ae_iff {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + {P : (Fin 3 → ℝ) → Prop} : + (∀ᵐ y∂sourcePhysicalCollarMeasure l r,P y) ↔ + ∀ᵐ y∂sourceAngularCollarMeasure l r,P y := by + exact ⟨fun h => h.filter_mono (Measure.absolutelyContinuous_of_le_smul + (sourceAngularCollarMeasure_le hlr hl hr)).ae_le, + fun h => h.filter_mono (Measure.absolutelyContinuous_of_le_smul + (sourcePhysicalCollarMeasure_le hlr hl hr)).ae_le⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/CrossingBlock.lean b/lean/OAI/Analysis/Conductivity/Branching/CrossingBlock.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca47e43469331353cefe33264837b4084e109408 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/CrossingBlock.lean @@ -0,0 +1,188 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CrossingHxx +import OAI.Analysis.Conductivity.Variational.CrossingEstimates +import OAI.Analysis.Conductivity.Branching.CascadeProfile + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def crossingValue (L z x y : ℝ) : ℝ := + crossingFirst L z*cos x + crossingSecond L z*cos (2*y) + +def crossingXX (L z x y : ℝ) : ℝ := + 9 + crossingHxx (exp (-3*z)) (crossingSecond L z) (crossingResidualSecond L z) 1 2 x y + +def crossingYY (L z x y : ℝ) : ℝ := + 1/4 + crossingHxx (exp (-z)) (crossingFirst L z) (crossingResidualFirst L z) 2 1 y x + +def crossingXY (L z x y : ℝ) : ℝ := + crossingHxy (exp (-3*z)) (crossingResidualSecond L z) 1 2 x y + + crossingHxy (exp (-z)) (crossingResidualFirst L z) 2 1 y x + +def crossingCurrentX (L z x y : ℝ) : ℝ := + -9*crossingFirst L z*sin x - crossingResidualSecond L z*cos x*sin x*cos (2*y) - + 2*crossingResidualFirst L z*(sin (2*y))^2*sin x + +def crossingCurrentY (L z x y : ℝ) : ℝ := + -(crossingSecond L z/2)*sin (2*y) - crossingResidualSecond L z*(sin x)^2*sin (2*y) - + (crossingResidualFirst L z/2)*cos (2*y)*sin (2*y)*cos x + +def crossingCurrentZ (L z x y : ℝ) : ℝ := + deriv (crossingFirst L) z*cos x + deriv (crossingSecond L) z*cos (2*y) + +lemma crossing_first_on_left {L z : ℝ} (hL : 0 < L) (hz : z ≤ 0) : + crossingFirst L z = exp (-3*z) := by + rw [crossingFirst,crossingOff_eq_one hL (by linarith),one_mul] +lemma crossing_second_on_right {L z : ℝ} (hL : 0 < L) (hz : 0 ≤ z) : + crossingSecond L z = exp (-z) := by + rw [crossingSecond,crossingOn_eq_one hL (by linarith),one_mul] + +lemma crossing_corrections_left {L z : ℝ} (hL : 0 < L) (hz : z ≤ 0) (x y : ℝ) : + crossingYY L z x y = 1/4 ∧ + crossingXY L z x y = crossingHxy (exp (-3*z)) (crossingResidualSecond L z) 1 2 x y := by + have hr := crossingResidualFirst_zero hL (show z < L/2 by linarith) + simp [crossingYY,crossingXY,hr,crossingHxx,crossingHxy] +lemma crossing_corrections_right {L z : ℝ} (hL : 0 < L) (hz : 0 ≤ z) (x y : ℝ) : + crossingXX L z x y = 9 ∧ + crossingXY L z x y = crossingHxy (exp (-z)) (crossingResidualFirst L z) 2 1 y x := by + have hr := crossingResidualSecond_zero hL (show -L/2 < z by linarith) + simp [crossingXX,crossingXY,hr,crossingHxx,crossingHxy] + +lemma crossing_current_constitution {L : ℝ} (hL : 0 < L) (z x y : ℝ) : + crossingCurrentX L z x y = + crossingXX L z x y*(-crossingFirst L z*sin x) + + crossingXY L z x y*(-2*crossingSecond L z*sin (2*y)) ∧ + crossingCurrentY L z x y = + crossingXY L z x y*(-crossingFirst L z*sin x) + + crossingYY L z x y*(-2*crossingSecond L z*sin (2*y)) := by + have he₁ : exp (-3*z) ≠ 0 := (exp_pos _).ne' + have he₂ : exp (-z) ≠ 0 := (exp_pos _).ne' + by_cases hz : z ≤ 0 + · have hf := crossing_first_on_left hL hz + have hr := crossingResidualFirst_zero hL (show z < L/2 by linarith) + obtain ⟨hyy,hxy⟩ := crossing_corrections_left hL hz x y + rw [hyy,hxy] + constructor <;> dsimp only [crossingCurrentX,crossingCurrentY,crossingXX] <;> + rw [hr,hf] <;> simp only [crossingHxx,crossingHxy,one_mul,one_pow,mul_one] <;> + field_simp <;> ring + · have hg := crossing_second_on_right hL (le_of_not_ge hz) + have hr := crossingResidualSecond_zero hL (show -L/2 < z by linarith) + obtain ⟨hxx,hxy⟩ := crossing_corrections_right hL (le_of_not_ge hz) x y + rw [hxx,hxy] + constructor <;> dsimp only [crossingCurrentX,crossingCurrentY,crossingYY] <;> + rw [hr,hg] <;> simp only [crossingHxx,crossingHxy,one_mul,mul_one] <;> + field_simp <;> ring + +lemma crossing_value_hasDerivAt_x (L z x y : ℝ) : + HasDerivAt (fun x => crossingValue L z x y) (-crossingFirst L z*sin x) x := by + exact (((hasDerivAt_cos x).const_mul (crossingFirst L z)).add_const + (crossingSecond L z*cos (2*y))).congr_deriv (g' := -crossingFirst L z*sin x) (by ring) +lemma crossing_value_hasDerivAt_y (L z x y : ℝ) : + HasDerivAt (fun y => crossingValue L z x y) (-2*crossingSecond L z*sin (2*y)) y := by + exact (((((hasDerivAt_id y).const_mul 2).cos).const_mul (crossingSecond L z)).const_add + (crossingFirst L z*cos x)).congr_deriv (g' := -2*crossingSecond L z*sin (2*y)) + (by simp only [id_eq,mul_one]; ring) +lemma crossing_value_hasDerivAt_z (L z x y : ℝ) : + HasDerivAt (fun z => crossingValue L z x y) (crossingCurrentZ L z x y) z := by + exact (((crossingFirst_smooth L).differentiable (by simp) z).hasDerivAt.mul_const (cos x)).add + (((crossingSecond_smooth L).differentiable (by simp) z).hasDerivAt.mul_const (cos (2*y))) + +lemma crossing_current_divergence (L z x y : ℝ) : + deriv (fun z => crossingCurrentZ L z x y) z + + deriv (fun x => crossingCurrentX L z x y) x + + deriv (fun y => crossingCurrentY L z x y) y = 0 := by + have hsx := hasDerivAt_sin x + have hcx := hasDerivAt_cos x + have hy := (hasDerivAt_id y).const_mul 2 + have hsy := hy.sin + have hcy := hy.cos + have hx := ((hsx.const_mul (-9*crossingFirst L z)).sub + (((hcx.mul hsx).const_mul (crossingResidualSecond L z)).mul_const (cos (2*y)))).sub + (hsx.const_mul (2*crossingResidualFirst L z*(sin (2*y))^2)) + have hy' := ((hsy.const_mul (-(crossingSecond L z/2))).sub + (hsy.const_mul (crossingResidualSecond L z*(sin x)^2))).sub + (((hcy.mul hsy).const_mul (crossingResidualFirst L z/2)).mul_const (cos x)) + have hz := (((smooth_deriv_infty (crossingFirst_smooth L)).differentiable (by simp) z).hasDerivAt.mul_const + (cos x)).add (((smooth_deriv_infty (crossingSecond_smooth L)).differentiable (by simp) z).hasDerivAt.mul_const + (cos (2*y))) + simp only [Pi.mul_def,Pi.sub_def,Pi.add_def,id_eq,mul_one] at hx hy' hz + have hex : (fun x => crossingCurrentX L z x y) = + (fun x => -9*crossingFirst L z*sin x - crossingResidualSecond L z*(cos x*sin x)*cos (2*y) - + (2*crossingResidualFirst L z*(sin (2*y))^2)*sin x) := by + funext x; unfold crossingCurrentX; ring + have hey : (fun y => crossingCurrentY L z x y) = + (fun y => -(crossingSecond L z/2)*sin (2*y) - crossingResidualSecond L z*(sin x)^2*sin (2*y) - + (crossingResidualFirst L z/2)*(cos (2*y)*sin (2*y))*cos x) := by + funext y; unfold crossingCurrentY; ring + rw [hex,hey,hx.deriv,hy'.deriv] + simp only [crossingCurrentZ] + rw [hz.deriv] + have hr₁ : deriv (deriv (crossingFirst L)) z = crossingResidualFirst L z+9*crossingFirst L z := by + unfold crossingResidualFirst; ring + have hr₂ : deriv (deriv (crossingSecond L)) z = crossingResidualSecond L z+crossingSecond L z := by + unfold crossingResidualSecond; ring + rw [hr₁,hr₂] + linear_combination + -(crossingResidualSecond L z*cos (2*y)) * Real.sin_sq_add_cos_sq x + + -(crossingResidualFirst L z*cos x) * Real.sin_sq_add_cos_sq (2*y) + +lemma cascadeProfile_next_connector_zero {L K s : ℝ} (hL : 0 < L) + (hs : s ≤ K+2) : cascadeProfile L K (2*(s-cascadeLength L K)) = 0 := by + apply cascadeProfile_zero_left hL + unfold cascadeLength + linarith + +lemma cascadeProfile_crossing_current {L K s : ℝ} (hL : 0 < L) (hK : 0 < K) + (hs : K+2 ≤ s) : + cascadeProfile L K s = connectorProfile K (K+2)*exp (-3*L)* + crossingFirst L (s-(K+2+L)) := by + rw [cascadeProfile_outgoing hL hK hs,crossingFirst] + have he : exp (-3*(s-(K+2))) = exp (-3*L)*exp (-3*(s-(K+2+L))) := by + rw [←exp_add] + congr 1 + ring + rw [he] + ring + +lemma cascadeProfile_crossing_next {L K s : ℝ} (hL : 0 < L) (hK : 0 < K) + (hs : s ≤ cascadeLength L K) : + cascadeRatio L K*cascadeProfile L K (2*(s-cascadeLength L K)) = + connectorProfile K (K+2)*exp (-3*L)*crossingSecond L (s-(K+2+L)) := by + rw [cascadeProfile_incoming hL hK (by linarith),cascadeRatio,crossingSecond] + have ha : 2*(s-cascadeLength L K)/2+L = s-(K+2+L) := by + unfold cascadeLength + ring + rw [ha] + have he : exp (-4*L)*exp (-(2*(s-cascadeLength L K))/2) = + exp (-3*L)*exp (-(s-(K+2+L))) := by + rw [←exp_add,←exp_add] + congr 1 + unfold cascadeLength + ring + calc + _ = connectorProfile K (K+2)*crossingOn L (s-(K+2+L))* + (exp (-4*L)*exp (-(2*(s-cascadeLength L K))/2)) := by ring + _ = _ := by rw [he]; ring + +lemma cascade_overlap_value {L K s : ℝ} (hL : 0 < L) (hK : 0 < K) + (hs₁ : K+2 ≤ s) (hs₂ : s ≤ cascadeLength L K) (a x y : ℝ) : + a*cascadeProfile L K s*cos x + + (a*cascadeRatio L K)*cascadeProfile L K (2*(s-cascadeLength L K))*cos (2*y) = + (a*connectorProfile K (K+2)*exp (-3*L))*crossingValue L (s-(K+2+L)) x y := by + rw [cascadeProfile_crossing_current hL hK hs₁] + have hh := cascadeProfile_crossing_next hL hK hs₂ + dsimp only [crossingValue] + calc + _ = a*(connectorProfile K (K+2)*exp (-3*L)*crossingFirst L (s-(K+2+L)))*cos x + + a*(cascadeRatio L K*cascadeProfile L K (2*(s-cascadeLength L K)))*cos (2*y) := by ring + _ = _ := by rw [hh]; ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/DelayedEndingRegularity.lean b/lean/OAI/Analysis/Conductivity/Branching/DelayedEndingRegularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..a3f0bd4f26cdad4495de2a8ae38ad90c81ed42f1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/DelayedEndingRegularity.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AlignedEndingRegularity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def delayedEndingSymmetricTensor (lam k J L K R : ℝ) (x : Coord3) : Symmetric3 := + alignedEndingSymmetricTensor lam k J L K (x-Pi.single 0 R) + +def axialAmplitudeEquiv (a : ℝ) (ha : a≠0) : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ) := + ContinuousLinearEquiv.piCongrRight (fun i : Fin 2 => + (LinearEquiv.smulOfNeZero ℝ ℝ (if i=0 then 1 else a) (by split_ifs <;> simp_all)).toContinuousLinearEquiv) + +lemma axialAmplitudeEquiv_apply (a : ℝ) (ha : a≠0) (v : Fin 2 → ℝ) (i : Fin 2) : + axialAmplitudeEquiv a ha v i=(if i=0 then 1 else a)*v i := rfl + +lemma RegularPatch.amplitude {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {O : Set Coord3} (h : RegularPatch u A O) (a : ℝ) (ha : a≠0) : + RegularPatch (fun x => axialAmplitudeEquiv a ha (u x)) A O := by + refine ⟨h.1,(axialAmplitudeEquiv a ha).contDiff.contDiffOn.comp h.2.1 (fun _ _ => mem_univ _),h.2.2.1,?_⟩ + exact h.2.2.2.linearCoordinates h.1 h.2.1 (ContinuousLinearEquiv.refl ℝ Coord3) (axialAmplitudeEquiv a ha) + +lemma delayedEnding_axialPair (lam k J L K R : ℝ) (x : Coord3) : + axialAmplitudeEquiv (exp (-lam*R)) (exp_pos _).ne' + (axialPair (alignedEndingValue lam k J L K) (x-Pi.single 0 R))+![R,0]= + axialPair (delayedEndingValue lam k J L K R) x := by + ext i + fin_cases i <;> simp [axialAmplitudeEquiv_apply,axialPair,delayedEndingValue] + +lemma RegularPatch.delayedEnding {lam k J L K R : ℝ} {O : Set Coord3} + (h : RegularPatch (axialPair (alignedEndingValue lam k J L K)) + (alignedEndingSymmetricTensor lam k J L K) O) : + RegularPatch (axialPair (delayedEndingValue lam k J L K R)) + (delayedEndingSymmetricTensor lam k J L K R) ((fun x : Coord3 => x-Pi.single 0 R) ⁻¹' O) := by + have hh := (h.amplitude (exp (-lam*R)) (exp_pos _).ne').translate (Pi.single 0 R) ![R,0] + convert hh using 1 + · funext x + exact (delayedEnding_axialPair _ _ _ _ _ _ _).symm + · rfl + +lemma delayedEnding_regularRegion_ae {lam k J L K R : ℝ} (hk : k≠0) (hL : 0 y-Pi.single 0 R) ⁻¹' O,subset_univ _,?_,?_⟩ + · exact hO.delayedEnding (R:=R) + · exact hxO + exact mem_regularRegion_congr_nhds hh (Filter.EventuallyEq.rfl) (Filter.EventuallyEq.rfl) hU hxU + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/Ending.lean b/lean/OAI/Analysis/Conductivity/Branching/Ending.lean new file mode 100644 index 0000000000000000000000000000000000000000..7793adf88baf12a398e661e20308120aa82fa410 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/Ending.lean @@ -0,0 +1,596 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CascadeWeakEnd + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Real Set Filter Topology MeasureTheory Matrix + +def initialConnectorRate (a b K t : ℝ) : ℝ := + a+(b-a)*smoothTransition ((t-1)/K) + +def initialConnectorProfile (a b K t : ℝ) : ℝ := + exp (-(∫ r in (0:ℝ)..t,initialConnectorRate a b K r)) + +lemma initialConnectorRate_smooth (a b K : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (initialConnectorRate a b K) := by + exact contDiff_const.add (contDiff_const.mul (smoothTransition.contDiff.comp + ((contDiff_id.sub contDiff_const).div_const K))) + +lemma initialConnectorRate_bounds (a b K t : ℝ) : + min a b ≤ initialConnectorRate a b K t ∧ initialConnectorRate a b K t ≤ max a b := by + have h0 := smoothTransition.nonneg ((t-1)/K) + have h1 := smoothTransition.le_one ((t-1)/K) + have hamin := min_le_left a b + have hbmin := min_le_right a b + have hamax := le_max_left a b + have hbmax := le_max_right a b + dsimp only [initialConnectorRate] + constructor + · nlinarith [mul_nonneg (sub_nonneg.mpr hamin) (sub_nonneg.mpr h1), + mul_nonneg (sub_nonneg.mpr hbmin) h0] + · nlinarith [mul_nonneg (sub_nonneg.mpr hamax) (sub_nonneg.mpr h1), + mul_nonneg (sub_nonneg.mpr hbmax) h0] + +lemma initialConnectorRate_left {a b K t : ℝ} (hK : 0 < K) (ht : t ≤ 1) : + initialConnectorRate a b K t=a := by + rw [initialConnectorRate,smoothTransition.zero_of_nonpos + (div_nonpos_of_nonpos_of_nonneg (by linarith) hK.le),mul_zero,add_zero] + +lemma initialConnectorRate_right {a b K t : ℝ} (hK : 0 < K) (ht : K+1 ≤ t) : + initialConnectorRate a b K t=b := by + rw [initialConnectorRate,smoothTransition.one_of_one_le + ((le_div_iff₀ hK).mpr (by linarith))] + ring + +lemma initialConnectorRate_deriv (a b K t : ℝ) : + deriv (initialConnectorRate a b K) t= + ((b-a)/K)*deriv smoothTransition ((t-1)/K) := by + have h := ((smoothTransition.contDiff (n:=⊤)).differentiable (by simp) ((t-1)/K)).hasDerivAt + have hh := ((h.comp t (((hasDerivAt_id t).sub_const 1).div_const K)).const_mul (b-a)).const_add a + dsimp only [Function.comp_def,id_eq] at hh + change deriv (fun t => a+(b-a)*smoothTransition ((t-1)/K)) t=_ + rw [hh.deriv] + ring + +lemma exists_initialConnector_length {a b : ℝ} (ha : 0 < a) (hb : 0 < b) : + ∃ K : ℝ,0 < K ∧ ∀ t,|deriv (initialConnectorRate a b K) t| ≤ (min a b)^2/2 := by + obtain ⟨M,hM,hbound⟩ := exists_transition_derivative_bound + let m := min a b + have hm : 0 < m := lt_min ha hb + let K := (2* |b-a| *M+1)/m^2 + have hMp : 0 < M := by linarith + have hK : 0 < K := div_pos (by positivity) (sq_pos_of_pos hm) + have hKe : K*m^2=2* |b-a| *M+1 := div_mul_cancel₀ _ (pow_ne_zero 2 hm.ne') + refine ⟨K,hK,?_⟩ + intro t + rw [initialConnectorRate_deriv,abs_mul,abs_div,abs_of_pos hK] + calc + _ ≤ (|b-a|/K)*M := mul_le_mul_of_nonneg_left (hbound _).1 (by positivity) + _ ≤ m^2/2 := by + rw [div_mul_eq_mul_div,div_le_iff₀ hK] + nlinarith + +lemma initialConnectorProfile_smooth (a b K : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (initialConnectorProfile a b K) := by + let r : SmoothScalar ℝ := ⟨initialConnectorRate a b K,initialConnectorRate_smooth a b K⟩ + exact ((smoothScalar_contDiff (smoothPrimitive r)).neg).exp + +lemma initialConnectorProfile_pos (a b K t : ℝ) : 0 < initialConnectorProfile a b K t := exp_pos _ + +lemma initialConnectorProfile_hasDerivAt (a b K t : ℝ) : + HasDerivAt (initialConnectorProfile a b K) + (-initialConnectorRate a b K t*initialConnectorProfile a b K t) t := by + have hr := (initialConnectorRate_smooth a b K).continuous + have h := intervalIntegral.integral_hasDerivAt_right (hr.intervalIntegrable 0 t) + (hr.stronglyMeasurableAtFilter _ _) hr.continuousAt + change HasDerivAt (fun t => exp (-(∫ r in (0:ℝ)..t,initialConnectorRate a b K r))) _ t + exact h.neg.exp.congr_deriv (g':= -initialConnectorRate a b K t*initialConnectorProfile a b K t) + (by simp only [initialConnectorProfile,Pi.neg_apply]; ring) + +lemma initialConnectorProfile_second (a b K t : ℝ) : + deriv (deriv (initialConnectorProfile a b K)) t= + ((initialConnectorRate a b K t)^2-deriv (initialConnectorRate a b K) t)* + initialConnectorProfile a b K t := by + have he : deriv (initialConnectorProfile a b K)= + fun t => -initialConnectorRate a b K t*initialConnectorProfile a b K t := + funext fun t => (initialConnectorProfile_hasDerivAt a b K t).deriv + rw [he] + have h := (((initialConnectorRate_smooth a b K).differentiable (by simp) t).hasDerivAt.neg).mul + (initialConnectorProfile_hasDerivAt a b K t) + simp only [Pi.mul_def,Pi.neg_def] at h + rw [h.deriv] + ring + +def initialConnectorAngular (a b K t : ℝ) : ℝ := + (initialConnectorRate a b K t)^2-deriv (initialConnectorRate a b K) t + +lemma initialConnectorAngular_smooth (a b K : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (initialConnectorAngular a b K) := + ((initialConnectorRate_smooth a b K).pow 2).sub + (smooth_deriv_infty (initialConnectorRate_smooth a b K)) + +lemma initialConnectorAngular_bounds {a b K : ℝ} (ha : 0 < a) (hb : 0 < b) + (hd : ∀ t,|deriv (initialConnectorRate a b K) t| ≤ (min a b)^2/2) (t : ℝ) : + (min a b)^2/2 ≤ initialConnectorAngular a b K t ∧ + initialConnectorAngular a b K t ≤ (max a b)^2+(min a b)^2/2 := by + have hm : 0 < min a b := lt_min ha hb + have hr := initialConnectorRate_bounds a b K t + have hd' := abs_le.mp (hd t) + have hrp : 0 ≤ initialConnectorRate a b K t := hm.le.trans hr.1 + have hs1 := sq_le_sq₀ hm.le hrp |>.mpr hr.1 + have hs2 := sq_le_sq₀ hrp (hrp.trans hr.2) |>.mpr hr.2 + constructor <;> dsimp [initialConnectorAngular] <;> nlinarith + +lemma initialConnectorProfile_left {a b K t : ℝ} (hK : 0 < K) (ht : t ≤ 1) : + initialConnectorProfile a b K t=exp (-a*t) := by + have hi : (∫ r in (0:ℝ)..t,initialConnectorRate a b K r)=a*t := by + calc + _=∫ _r in (0:ℝ)..t,a := intervalIntegral.integral_congr (by + intro r hr + apply initialConnectorRate_left hK + exact (le_max_iff.mp hr.2).elim (by intro h; linarith) (by intro h; linarith)) + _=_ := by simp; ring + rw [initialConnectorProfile,hi] + congr 1 + ring + +lemma initialConnectorProfile_right {a b K t : ℝ} (hK : 0 < K) (ht : K+1 ≤ t) : + initialConnectorProfile a b K t= + initialConnectorProfile a b K (K+2)*exp (-b*(t-(K+2))) := by + have hi : (∫ r in (K+2)..t,initialConnectorRate a b K r)=b*(t-(K+2)) := by + calc + _=∫ _r in (K+2)..t,b := intervalIntegral.integral_congr (by + intro r hr + exact initialConnectorRate_right hK ((le_min (by linarith) ht).trans hr.1)) + _=_ := by simp; ring + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ:=volume) + ((initialConnectorRate_smooth a b K).continuous.intervalIntegrable 0 (K+2)) + ((initialConnectorRate_smooth a b K).continuous.intervalIntegrable (K+2) t) + rw [hi] at hadd + unfold initialConnectorProfile + rw [←hadd,neg_add,exp_add] + congr 2 + ring + +lemma initialConnector_constitution (a b K : ℝ) {i : Fin 3} (hi : i ≠ 0) (x : Coord3) : + pureModeTensor (initialConnectorAngular a b K (x 0)) i*ᵥ + (fun j => direction (Pi.single j 1) (pureModeValue (initialConnectorProfile a b K) i) x)= + potentialCurl (pureModePotential (initialConnectorProfile a b K) i) x := by + apply pureMode_constitution ((initialConnectorProfile_smooth a b K).differentiable (by simp)) + ((smooth_deriv_infty (initialConnectorProfile_smooth a b K)).differentiable (by simp)) hi + exact initialConnectorProfile_second a b K (x 0) + +end + +section +open Real Set Filter Topology MeasureTheory + +lemma cascadeProfile_near_start {L K t : ℝ} (hL : 1 ≤ L) (hK : 0 < K) + (ht : t∈Icc (-1/4) (1/4)) : cascadeProfile L K t=exp (-t/2) := by + have hLp : 0 < L := lt_of_lt_of_le (by norm_num) hL + rw [cascadeProfile,crossingOn_eq_one hLp (by linarith [ht.1]), + crossingOff_eq_one hLp (by linarith [ht.2]),one_mul,mul_one, + connectorProfile_left hK (by linarith [ht.2])] + +lemma cascadeProfile_deriv_near_start {L K t : ℝ} (hL : 1 ≤ L) (hK : 0 < K) + (ht : t∈Ioo (-1/4) (1/4)) : deriv (cascadeProfile L K) t= -(1/2)*exp (-t/2) := by + have he : cascadeProfile L K =ᶠ[𝓝 t] fun r => exp (-r/2) := by + filter_upwards [isOpen_Ioo.mem_nhds ht] with r hr + exact cascadeProfile_near_start hL hK ⟨hr.1.le,hr.2.le⟩ + rw [he.deriv_eq] + have hd := (((hasDerivAt_id t).neg).div_const 2).exp + dsimp only [Pi.neg_apply,id_eq] at hd + rw [hd.deriv] + ring + +lemma cascadePhase_inactive_start {L K k t : ℝ} (hL : 1 ≤ L) (hK : 0 < K) + (ht : k*t ≤ 1/4) {j : ℕ} (hj : j ≠ 0) : + cascadePhase (cascadeLength L K) k j t < -7*L/2 := by + have hh := cascadePhase_antitone (D:=cascadeLength L K) (k:=k) (t:=t) + (show k*t ≤ 2*cascadeLength L K by unfold cascadeLength; linarith) + (show 1 ≤ j by omega) + change cascadePhase (cascadeLength L K) k j t ≤ cascadePhase (cascadeLength L K) k 1 t at hh + rw [show (1:ℕ)=0+1 from rfl,cascadePhase_succ,cascadePhase_zero] at hh + unfold cascadeLength at * + linarith + +lemma cascadeValue_near_start {L K k : ℝ} (hL : 1 ≤ L) (hK : 0 < K) + (A : ℝ) (x : Coord3) (hx : k*x 0∈Icc (-1/4) (1/4)) : + cascadeValue L K k A x=A*exp (-(k*x 0)/2)*cos (k*x 1) := by + have hLp : 0 < L := lt_of_lt_of_le (by norm_num) hL + have hz : ∀ j : ℕ,j ≠ 0 → cascadeTerm L K k A j x=0 := by + intro j hj + rw [cascadeTerm,cascadeProfile_zero_left hLp + (cascadePhase_inactive_start hL hK hx.2 hj).le,mul_zero,zero_mul] + rw [cascadeValue,tsum_eq_single 0 hz,cascadeTerm,cascadePhase_zero, + cascadeProfile_near_start hL hK hx] + simp [cascadeAxis] + +lemma cascadePotential_near_start {L K k : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (hk : k ≠ 0) + (A : ℝ) (x : Coord3) (hx : k*x 0∈Ioo (-1/4) (1/4)) (i j : Fin 3) : + cascadePotential L K k A i j x = + wedgePotential 0 1 (fun y : Coord3 => -(A/2)*exp (-(k*y 0)/2)*sin (k*y 1)) i j x := by + have hLp : 0 < L := lt_of_lt_of_le (by norm_num) hL + have hz : ∀ n : ℕ,n ≠ 0 → (A*cascadeRatio L K^n)* + cascadePotentialMother L K (cascadeAxis n) (cascadeAxis (n+1)) i j + ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n))=0 := by + intro n hn + let y := (k*2^n) • (x-cascadeCenter (cascadeLength L K) k n) + have hy : y 0 < -7*L/2 := by + dsimp only [y] + rw [cascade_dilation_time hk] + exact cascadePhase_inactive_start hL hK hx.2.le hn + have hb := cascadeBaseStream_zero (K:=K) hLp (cascadeAxis n) y (Or.inl hy) + have hc := cascadeCrossStream_zero_left (K:=K) hLp (cascadeAxis n) (cascadeAxis (n+1)) y + (by linarith) + change (A*cascadeRatio L K^n)*cascadePotentialMother L K (cascadeAxis n) (cascadeAxis (n+1)) i j y=0 + simp [cascadePotentialMother,hb,hc] + rw [cascadePotential,tsum_eq_single 0 hz] + have hcenter : cascadeCenter (cascadeLength L K) k 0=0 := by + ext a + simp [cascadeCenter] + simp only [pow_zero,mul_one,hcenter,sub_zero] + have hc : cascadeCrossStream L K (cascadeAxis 0) (cascadeAxis 1) (k • x)=0 := by + apply cascadeCrossStream_zero_left hLp + change k*x 0 < K+2+L/4 + linarith [hx.2] + have hb : cascadeBaseStream L K (cascadeAxis 0) (k • x)= + (-(1/2)*exp (-(k*x 0)/2))*sin (k*x 1) := by + change deriv (cascadeProfile L K) (k*x 0)*sin (k*x (cascadeAxis 0))=_ + rw [cascadeProfile_deriv_near_start hL hK hx] + rfl + unfold cascadePotentialMother + rw [hc,hb] + simp only [show cascadeAxis 0=1 from rfl,ite_self,add_zero] + unfold wedgePotential + split <;> split <;> ring + +end + +section +open Set Filter Topology + +lemma contDiff_axial_paste {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] {n : WithTop ℕ∞} + {f g : E → F} {t : E → ℝ} {c δ : ℝ} + (hf : ContDiff ℝ n f) (hg : ContDiff ℝ n g) (ht : Continuous t) + (hδ : 0 < δ) (he : ∀ x,t x∈Ioo (c-δ) (c+δ) → f x=g x) : + ContDiff ℝ n (fun x => if t x linarith)] with y hy + split_ifs + · rfl + · exact (he y hy).symm + +lemma axial_paste_eventually_left {E F : Type*} [TopologicalSpace E] + {f g : E → F} {t : E → ℝ} {c : ℝ} (ht : Continuous t) {x : E} (hx : t x if t y if t y linarith [hx.1,hx.2] + rw [cascadeValue_near_start hL hK _ _ hs,pureModeValue, + initialConnectorProfile_right hJ (show J+1 ≤ x 0 by linarith [hx.1])] + simp only [one_mul,Pi.sub_apply,Pi.single_eq_same, + Pi.single_eq_of_ne (show (1:Fin 3)≠0 by decide),sub_zero] + congr 2 + ring_nf + +lemma finiteEnding_potential_overlap {a J L K : ℝ} (hJ : 0 < J) (hL : 1 ≤ L) (hK : 0 < K) + (x : Coord3) (hx : x 0∈Ioo ((J+2)-1/4) ((J+2)+1/4)) (i j : Fin 3) : + pureModePotential (initialConnectorProfile a (1/2) J) 1 i j x= + cascadePotential L K 1 (initialConnectorProfile a (1/2) J (J+2)) i j + (x-Pi.single 0 (J+2)) := by + have hs : 1*((x-Pi.single 0 (J+2) : Coord3) 0)∈Ioo (-1/4) (1/4) := by + simp only [one_mul,Pi.sub_apply,Pi.single_eq_same] + constructor <;> linarith [hx.1,hx.2] + rw [cascadePotential_near_start hL hK (by norm_num) _ _ hs,pureModePotential, + wedgePotential_as_mul,wedgePotential_as_mul] + simp only [one_mul,Pi.sub_apply,Pi.single_eq_same, + Pi.single_eq_of_ne (show (1:Fin 3)≠0 by decide),sub_zero] + rw [(initialConnectorProfile_hasDerivAt a (1/2) J (x 0)).deriv, + initialConnectorRate_right hJ (show J+1 ≤ x 0 by linarith [hx.1]), + initialConnectorProfile_right hJ (show J+1 ≤ x 0 by linarith [hx.1])] + congr 1 + ring_nf + +lemma finiteEndingValue_C2 {a J L K : ℝ} (hJ : 0 < J) (hL : 1 ≤ L) (hK : 0 < K) : + ContDiff ℝ 2 (finiteEndingValue a J L K) := by + apply contDiff_axial_paste (δ:=1/4) ?_ ?_ (continuous_apply 0) (by norm_num) + (finiteEnding_value_overlap hJ hL hK) + · have h := (initialConnectorProfile_smooth a (1/2) J).of_le (show (2:WithTop ℕ∞) ≤ ↑(⊤:ℕ∞) by norm_cast) + unfold pureModeValue + exact (h.comp (contDiff_apply ℝ ℝ 0)).mul ((contDiff_apply ℝ ℝ 1).cos) + · exact (cascadeValue_C2 hL hK (by norm_num : (1:ℝ)≠0) _).comp + (contDiff_id.sub contDiff_const) + +lemma finiteEndingPotential_C2 {a J L K : ℝ} (hJ : 0 < J) (hL : 1 ≤ L) (hK : 0 < K) + (i j : Fin 3) : ContDiff ℝ 2 (finiteEndingPotential a J L K i j) := by + apply contDiff_axial_paste (δ:=1/4) ?_ ?_ (continuous_apply 0) (by norm_num) + (fun x hx => finiteEnding_potential_overlap hJ hL hK x hx i j) + · have h := (smooth_deriv_infty (initialConnectorProfile_smooth a (1/2) J)).of_le + (show (2:WithTop ℕ∞) ≤ ↑(⊤:ℕ∞) by norm_cast) + have hs : ContDiff ℝ 2 (fun x : Coord3 => deriv (initialConnectorProfile a (1/2) J) (x 0)*sin (x 1)) := + (h.comp (contDiff_apply ℝ ℝ 0)).mul ((contDiff_apply ℝ ℝ 1).sin) + unfold pureModePotential wedgePotential + split <;> split + · exact hs.sub hs + · exact hs.sub contDiff_const + · exact contDiff_const.sub hs + · exact contDiff_const.sub contDiff_const + · exact (cascadePotential_C2 hL hK 1 _ i j).comp (contDiff_id.sub contDiff_const) + +lemma finiteEndingPotential_antisymm (a J L K : ℝ) (i j : Fin 3) : + finiteEndingPotential a J L K i j=fun x => -finiteEndingPotential a J L K j i x := by + funext x + unfold finiteEndingPotential + split_ifs + · unfold pureModePotential wedgePotential + ring + · exact congrFun (cascadePotential_antisymm L K 1 _ i j) _ + +lemma finiteEndingValue_initial {a J L K : ℝ} (hJ : 0 < J) (x : Coord3) (hx : x 0 ≤ 1) : + finiteEndingValue a J L K x=exp (-a*x 0)*cos (x 1) := by + rw [finiteEndingValue,ite_eq_left (show x 0 f (y-c)) x=direction v f (x-c) := by + simpa only [one_mul,one_smul] using direction_dilation hf 1 1 c v x + +lemma potentialCurl_translate {S : Fin 3 → Fin 3 → Coord3 → ℝ} + (hS : ∀ i j,Differentiable ℝ (S i j)) (c x : Coord3) (i : Fin 3) : + potentialCurl (fun i j y => S i j (y-c)) x i=potentialCurl S (x-c) i := by + simpa only [one_mul,one_smul] using potentialCurl_dilation hS 1 1 c x i + +lemma finiteEndingTensor_measurable (a J L K : ℝ) : Measurable (finiteEndingTensor a J L K) := by + apply Measurable.ite ((isOpen_lt (continuous_apply 0) continuous_const).measurableSet) + · have h : Continuous (fun x : Coord3 => pureModeTensor (initialConnectorAngular a (1/2) J (x 0)) 1) := by + apply continuous_matrix + intro i j + unfold pureModeTensor Matrix.diagonal + simp only [Matrix.of_apply] + split_ifs + · exact (initialConnectorAngular_smooth a (1/2) J).continuous.comp (continuous_apply 0) + all_goals exact continuous_const + exact h.measurable + · exact (cascadeTensor_measurable L K 1).comp (by fun_prop) + +lemma finiteEndingTensor_symm (a J L K : ℝ) (x : Coord3) : + (finiteEndingTensor a J L K x).IsSymm := by + unfold finiteEndingTensor + split_ifs + · exact pureModeTensor_symm _ _ + · exact cascadeTensor_symm _ _ _ _ + +lemma finiteEndingTensor_normal (a J L K : ℝ) (x : Coord3) : + finiteEndingTensor a J L K x*ᵥPi.single 0 1=Pi.single 0 1 := by + unfold finiteEndingTensor + split_ifs + · exact pureModeTensor_normal (by decide : (1:Fin 3)≠0) _ + · exact cascadeTensor_normal _ _ _ _ + +lemma finiteEnding_constitution_left (a J L K : ℝ) (x : Coord3) (hx : x 0 direction (Pi.single j 1) (finiteEndingValue a J L K) x)= + potentialCurl (finiteEndingPotential a J L K) x := by + have hv : finiteEndingValue a J L K=ᶠ[𝓝 x] pureModeValue (initialConnectorProfile a (1/2) J) 1 := + axial_paste_eventually_left (continuous_apply 0) hx + have hp (i j : Fin 3) : finiteEndingPotential a J L K i j=ᶠ[𝓝 x] + pureModePotential (initialConnectorProfile a (1/2) J) 1 i j := + axial_paste_eventually_left (continuous_apply 0) hx + have hg : (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)= + (fun j => direction (Pi.single j 1) (pureModeValue (initialConnectorProfile a (1/2) J) 1) x) := + funext fun j => direction_congr_nhds hv _ + rw [finiteEndingTensor,ite_eq_left hx,hg] + rw [initialConnector_constitution a (1/2) J (by decide)] + ext i + exact (potentialCurl_congr_nhds x hp i).symm + +lemma finiteEnding_constitution_right {a J L K : ℝ} (_ : 0 direction (Pi.single j 1) (cascadeValue L K 1 (initialConnectorProfile a (1/2) J (J+2))) + (x-Pi.single 0 (J+2)))= + cascadeFlux L K 1 (initialConnectorProfile a (1/2) J (J+2)) (x-Pi.single 0 (J+2))) : + finiteEndingTensor a J L K x*ᵥ(fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)= + potentialCurl (finiteEndingPotential a J L K) x := by + have hv : finiteEndingValue a J L K=ᶠ[𝓝 x] + (fun y => cascadeValue L K 1 (initialConnectorProfile a (1/2) J (J+2)) (y-Pi.single 0 (J+2))) := + axial_paste_eventually_right (continuous_apply 0) hx + have hp (i j : Fin 3) : finiteEndingPotential a J L K i j=ᶠ[𝓝 x] + (fun y => cascadePotential L K 1 (initialConnectorProfile a (1/2) J (J+2)) i j (y-Pi.single 0 (J+2))) := + axial_paste_eventually_right (continuous_apply 0) hx + have hg : (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)= + (fun j => direction (Pi.single j 1) (cascadeValue L K 1 (initialConnectorProfile a (1/2) J (J+2))) + (x-Pi.single 0 (J+2))) := by + funext j + rw [direction_congr_nhds hv _] + exact direction_translate ((cascadeValue_C2 hL hK (by norm_num) _).differentiable (by norm_num)) _ _ _ + rw [finiteEndingTensor,ite_eq_right (not_lt.mpr hx.le),hg,hc] + ext i + rw [potentialCurl_congr_nhds x hp i,potentialCurl_translate + (fun i j => (cascadePotential_C2 hL hK 1 _ i j).differentiable (by norm_num))] + rfl + +lemma finiteEnding_constitution_ae {a J L K : ℝ} (hJ : 0 direction (Pi.single j 1) (finiteEndingValue a J L K) x)= + potentialCurl (finiteEndingPotential a J L K) x := by + have he := (measurePreserving_add_right (volume : Measure Coord3) (-Pi.single 0 (J+2))).quasiMeasurePreserving.ae + (cascadeTensor_constitution_ae (lt_of_lt_of_le (by norm_num) hL) hK (by norm_num : (1:ℝ)≠0) + (initialConnectorProfile a (1/2) J (J+2))) + simp only [←sub_eq_add_neg] at he + filter_upwards [he,ae_coord3_ne 0 (J+2)] with x hx hn + rcases lt_or_gt_of_ne hn with hl|hr + · exact finiteEnding_constitution_left a J L K x hl + · apply finiteEnding_constitution_right hJ hL hK x hr (hx ?_) + simp only [one_mul,Pi.sub_apply,Pi.single_eq_same] + linarith + +lemma finiteEndingFlux_C1 {a J L K : ℝ} (hJ : 0 potentialCurl (finiteEndingPotential a J L K) x i) := by + apply ContDiff.sum + intro j _ + exact direction_C1 (finiteEndingPotential_C2 hJ hL hK i j) _ + +lemma finiteEndingFlux_divergence {a J L K : ℝ} (hJ : 0 potentialCurl (finiteEndingPotential a J L K) y i) x=0 := + antisymmetric_potential_divergence (fun i => Pi.single i 1) (finiteEndingPotential a J L K) + (finiteEndingPotential_C2 hJ hL hK) (finiteEndingPotential_antisymm a J L K) x + +theorem finiteEnding_weak_equation {a J L K : ℝ} (hJ : 0 ∑ i, (finiteEndingTensor a J L K x*ᵥ + (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x, ∑ i, (finiteEndingTensor a J L K x*ᵥ + (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have he : (fun x => ∑ i, (finiteEndingTensor a J L K x*ᵥ + (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=ᵐ[volume] + (fun x => ∑ i, potentialCurl (finiteEndingPotential a J L K) x i* + (smoothDirection (Pi.single i 1) ψ).val x) := by + filter_upwards [finiteEnding_constitution_ae hJ hL hK] with x hx + rw [hx] + constructor + · apply Integrable.congr _ he.symm + apply integrable_finsetSum + intro i _ + exact ((finiteEndingFlux_C1 hJ hL hK i).continuous.mul + (smoothScalar_contDiff (smoothDirection (Pi.single i 1) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (Pi.single i 1) hc).mul_left + · rw [integral_congr_ae he] + exact C1_divergence_zero_test volume (fun i : Fin 3 => Pi.single i 1) + (fun i x => potentialCurl (finiteEndingPotential a J L K) x i) (finiteEndingFlux_C1 hJ hL hK) + (finiteEndingFlux_divergence hJ hL hK) ψ hc + +end + +open Real Set Filter Topology MeasureTheory Matrix + +lemma pureModeTensor_general_bounds {q c C : ℝ} (hc : c≤1) (hC : 1≤C) + (hcq : c≤q) (hqC : q≤C) (i : Fin 3) (v : Coord3) : + c*(v ⬝ᵥ v)≤v ⬝ᵥ (pureModeTensor q i*ᵥv) ∧ + v ⬝ᵥ (pureModeTensor q i*ᵥv)≤C*(v ⬝ᵥ v) := by + rw [pureModeTensor_quadratic] + simp only [dotProduct,Finset.mul_sum,←sq] + constructor <;> apply Finset.sum_le_sum <;> intro j _ + · exact mul_le_mul_of_nonneg_right (by split <;> assumption) (sq_nonneg _) + · exact mul_le_mul_of_nonneg_right (by split <;> assumption) (sq_nonneg _) + +theorem exists_finiteEnding_parameters {a : ℝ} (ha : 0 mul_self_nonneg _) + exact ⟨(mul_le_mul_of_nonneg_right hc8 hv).trans hb.1, + hb.2.trans (mul_le_mul_of_nonneg_right hC10 hv)⟩ + +theorem positive_rate_finite_ending {a : ℝ} (ha : 0 ∑ i, (finiteEndingTensor a J L K x*ᵥ + (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x, ∑ i, (finiteEndingTensor a J L K x*ᵥ + (fun j => direction (Pi.single j 1) (finiteEndingValue a J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + obtain ⟨J,L,K,c,C,hJ,hL,hK,hc,hcC,hbound⟩ := exists_finiteEnding_parameters ha + have hD := cascade_length_positive (lt_of_lt_of_le (by norm_num) hL) hK + exact ⟨J,L,K,J+2+2*cascadeLength L K,c,C,hJ,hL,hK,by linarith,hc,hcC, + finiteEndingValue_C2 hJ hL hK,hbound,finiteEndingValue_initial hJ, + finiteEndingValue_terminal hJ hL hK,finiteEndingTensor_normal a J L K, + finiteEnding_weak_equation hJ hL hK⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/EndingCoordinateTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/EndingCoordinateTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..64149bc87112fe09a13233ca449066489365ef98 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/EndingCoordinateTransport.lean @@ -0,0 +1,219 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.Ending + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +def permutedDilation (e : Equiv.Perm (Fin 3)) (r : ℝ) (x : Coord3) : Coord3 := + fun i => r*x (e i) + +lemma permutedDilation_smooth (e : Equiv.Perm (Fin 3)) (r : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (permutedDilation e r) := by + apply contDiff_pi.mpr + intro i + exact contDiff_const.mul (contDiff_apply ℝ ℝ (e i)) + +lemma direction_permutedDilation {f : Coord3 → ℝ} (hf : Differentiable ℝ f) + (e : Equiv.Perm (Fin 3)) (r : ℝ) (i : Fin 3) (x : Coord3) : + direction (Pi.single i 1) (fun y => f (permutedDilation e r y)) x = + r*direction (Pi.single (e.symm i) 1) f (permutedDilation e r x) := by + let P : Coord3 →L[ℝ] Coord3 := + ContinuousLinearMap.pi (fun j => r • ContinuousLinearMap.proj (e j)) + have hP : (P : Coord3 → Coord3)=permutedDilation e r := rfl + have he : P (Pi.single i 1)=r • Pi.single (e.symm i) 1 := by + ext j + simp only [P,ContinuousLinearMap.pi_apply,_root_.smul_apply, + ContinuousLinearMap.proj_apply,Pi.smul_apply,smul_eq_mul,Pi.single_apply] + simp only [show e j=i ↔ j=e.symm i from e.eq_symm_apply.symm] + have hd := (hf (P x)).hasFDerivAt.comp x P.hasFDerivAt + change fderiv ℝ (f ∘ P) x (Pi.single i 1)=_ + rw [hd.fderiv,ContinuousLinearMap.comp_apply,he,map_smul,smul_eq_mul] + rfl + +lemma potentialCurl_permutedDilation {S : Fin 3 → Fin 3 → Coord3 → ℝ} + (hS : ∀ i j,Differentiable ℝ (S i j)) + (e : Equiv.Perm (Fin 3)) (r : ℝ) (x : Coord3) (i : Fin 3) : + potentialCurl (fun i j y => S (e.symm i) (e.symm j) (permutedDilation e r y)) x i = + r*potentialCurl S (permutedDilation e r x) (e.symm i) := by + simp only [potentialCurl,direction_permutedDilation (hS _ _),Finset.mul_sum] + exact e.symm.sum_comp (fun j => r*direction (Pi.single j 1) (S (e.symm i) j) (permutedDilation e r x)) + +lemma permutedTensor_quadratic (e : Equiv.Perm (Fin 3)) (A : Mat3) (v : Coord3) : + v ⬝ᵥ ((fun i j => A (e.symm i) (e.symm j))*ᵥv) = + (fun i => v (e i)) ⬝ᵥ (A*ᵥ(fun i => v (e i))) := by + simp only [Matrix.mulVec,dotProduct] + have hi := Equiv.sum_comp e (fun i => v i*∑ j,A (e.symm i) (e.symm j)*v j) + rw [←hi] + apply Finset.sum_congr rfl + intro i _ + simp only [Equiv.symm_apply_apply] + congr 1 + have hj := Equiv.sum_comp e (fun j => A i (e.symm j)*v j) + simpa only [Equiv.symm_apply_apply] using hj.symm + +lemma permutedTensor_constitution {f : Coord3 → ℝ} (hf : Differentiable ℝ f) + {S : Fin 3 → Fin 3 → Coord3 → ℝ} (hS : ∀ i j,Differentiable ℝ (S i j)) + (A : Coord3 → Mat3) (e : Equiv.Perm (Fin 3)) (r : ℝ) (x : Coord3) + (h : A (permutedDilation e r x)*ᵥ(fun j => direction (Pi.single j 1) f (permutedDilation e r x))= + potentialCurl S (permutedDilation e r x)) : + (fun i j => A (permutedDilation e r x) (e.symm i) (e.symm j))*ᵥ + (fun j => direction (Pi.single j 1) (fun y => f (permutedDilation e r y)) x)= + potentialCurl (fun i j y => S (e.symm i) (e.symm j) (permutedDilation e r y)) x := by + ext i + rw [potentialCurl_permutedDilation hS] + simp only [Matrix.mulVec,dotProduct,direction_permutedDilation hf] + have hh := congrFun h (e.symm i) + change (∑ j,A (permutedDilation e r x) (e.symm i) j*direction (Pi.single j 1) f (permutedDilation e r x))= + potentialCurl S (permutedDilation e r x) (e.symm i) at hh + rw [←hh,Finset.mul_sum] + calc + _ = ∑ j,r*(A (permutedDilation e r x) (e.symm i) (e.symm j)* + direction (Pi.single (e.symm j) 1) f (permutedDilation e r x)) := by + apply Finset.sum_congr rfl + intro j _ + ring + _ = _ := Equiv.sum_comp e.symm (fun j => r*(A (permutedDilation e r x) (e.symm i) j* + direction (Pi.single j 1) f (permutedDilation e r x))) + +lemma permutedDilation_quasiMeasurePreserving (e : Equiv.Perm (Fin 3)) {r : ℝ} (hr : r≠0) : + Measure.QuasiMeasurePreserving (permutedDilation e r) volume volume := by + have hp := (volume_measurePreserving_piCongrLeft (fun _ : Fin 3 => ℝ) e.symm).quasiMeasurePreserving + have hs := Measure.quasiMeasurePreserving_smul (volume : Measure Coord3) hr + convert hs.comp hp using 1 + funext x i + simp [permutedDilation,MeasurableEquiv.coe_piCongrLeft,Equiv.piCongrLeft_apply] + +end ScalarConductivity + + + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +local instance endingCoordinateTransportMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance endingCoordinateTransportBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +def angularAxisSwap : Equiv.Perm (Fin 3) := Equiv.swap 1 2 + +lemma angularAxisSwap_apply (i : Fin 3) : angularAxisSwap i=![0,2,1] i := by + fin_cases i <;> decide + +lemma angularAxisSwap_symm : angularAxisSwap.symm=angularAxisSwap := rfl + +def alignedEndingValue (lam k J L K : ℝ) (x : Coord3) : ℝ := + finiteEndingValue (lam/k) J L K (permutedDilation angularAxisSwap k x) + +def alignedEndingTensor (lam k J L K : ℝ) (x : Coord3) : Mat3 := + fun i j => finiteEndingTensor (lam/k) J L K (permutedDilation angularAxisSwap k x) + (angularAxisSwap i) (angularAxisSwap j) + +def alignedEndingPotential (lam k J L K : ℝ) (i j : Fin 3) (x : Coord3) : ℝ := + finiteEndingPotential (lam/k) J L K (angularAxisSwap i) (angularAxisSwap j) + (permutedDilation angularAxisSwap k x) + +lemma alignedEndingValue_C2 {lam k J L K : ℝ} (hJ : 0 -alignedEndingPotential lam k J L K j i x := by + funext x + exact congrFun (finiteEndingPotential_antisymm _ _ _ _ _ _) _ + +lemma alignedEndingTensor_measurable (lam k J L K : ℝ) : Measurable (alignedEndingTensor lam k J L K) := by + apply Measurable.of_eval; intro i + apply Measurable.of_eval; intro j + exact (measurable_pi_apply _).comp ((measurable_pi_apply _).comp + ((finiteEndingTensor_measurable _ _ _ _).comp (permutedDilation_smooth _ _).continuous.measurable)) + +lemma alignedEndingTensor_symm (lam k J L K : ℝ) (x : Coord3) : + (alignedEndingTensor lam k J L K x).IsSymm := by + ext i j + exact congrFun (congrFun (finiteEndingTensor_symm (lam/k) J L K (permutedDilation angularAxisSwap k x)) + (angularAxisSwap i)) (angularAxisSwap j) + +lemma alignedEndingTensor_normal (lam k J L K : ℝ) (x : Coord3) : + alignedEndingTensor lam k J L K x*ᵥPi.single 0 1=Pi.single 0 1 := by + ext i + have hh := congrFun (finiteEndingTensor_normal (lam/k) J L K (permutedDilation angularAxisSwap k x)) (angularAxisSwap i) + fin_cases i <;> simpa [alignedEndingTensor, Matrix.mulVec, dotProduct, Fin.sum_univ_three, + angularAxisSwap_apply, Pi.single_apply] using hh + +lemma alignedEnding_initial {lam k J L K : ℝ} (hk : 0 direction (Pi.single j 1) (alignedEndingValue lam k J L K) x)= + potentialCurl (alignedEndingPotential lam k J L K) x := by + have hh := (permutedDilation_quasiMeasurePreserving angularAxisSwap hk).ae + (finiteEnding_constitution_ae (a:=lam/k) hJ hL hK) + filter_upwards [hh] with x hx + exact permutedTensor_constitution ((finiteEndingValue_C2 hJ hL hK).differentiable (by norm_num)) + (fun i j => (finiteEndingPotential_C2 hJ hL hK i j).differentiable (by norm_num)) + (finiteEndingTensor (lam/k) J L K) angularAxisSwap k x hx + +lemma alignedEndingFlux_C1 {lam k J L K : ℝ} (hJ : 0 potentialCurl (alignedEndingPotential lam k J L K) x i) := by + apply ContDiff.sum + intro j _ + exact direction_C1 (alignedEndingPotential_C2 hJ hL hK i j) _ + +lemma alignedEndingFlux_divergence {lam k J L K : ℝ} (hJ : 0 potentialCurl (alignedEndingPotential lam k J L K) y i) x=0 := + antisymmetric_potential_divergence (fun i => Pi.single i 1) (alignedEndingPotential lam k J L K) + (alignedEndingPotential_C2 hJ hL hK) (alignedEndingPotential_antisymm lam k J L K) x + +theorem alignedEnding_weak_equation {lam k J L K : ℝ} (hk : k≠0) (hJ : 0 ∑ i, (alignedEndingTensor lam k J L K x*ᵥ + (fun j => direction (Pi.single j 1) (alignedEndingValue lam k J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x, ∑ i, (alignedEndingTensor lam k J L K x*ᵥ + (fun j => direction (Pi.single j 1) (alignedEndingValue lam k J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have he : (fun x => ∑ i, (alignedEndingTensor lam k J L K x*ᵥ + (fun j => direction (Pi.single j 1) (alignedEndingValue lam k J L K) x)) i* + (smoothDirection (Pi.single i 1) ψ).val x)=ᵐ[volume] + (fun x => ∑ i, potentialCurl (alignedEndingPotential lam k J L K) x i* + (smoothDirection (Pi.single i 1) ψ).val x) := by + filter_upwards [alignedEnding_constitution_ae hk hJ hL hK] with x hx + rw [hx] + constructor + · apply Integrable.congr _ he.symm + apply integrable_finsetSum + intro i _ + exact ((alignedEndingFlux_C1 hJ hL hK i).continuous.mul + (smoothScalar_contDiff (smoothDirection (Pi.single i 1) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (Pi.single i 1) hc).mul_left + · rw [integral_congr_ae he] + exact C1_divergence_zero_test volume (fun i : Fin 3 => Pi.single i 1) + (fun i x => potentialCurl (alignedEndingPotential lam k J L K) x i) (alignedEndingFlux_C1 hJ hL hK) + (alignedEndingFlux_divergence hJ hL hK) ψ hc + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/EndingJoinElliptic.lean b/lean/OAI/Analysis/Conductivity/Branching/EndingJoinElliptic.lean new file mode 100644 index 0000000000000000000000000000000000000000..615be4189e0b3ac0386bda66134e48c87053d176 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/EndingJoinElliptic.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.EndingJoinCutoff + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +local instance endingJoinEllipticMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance endingJoinEllipticBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +lemma delayedEndingTensor_measurable (lam k J L K R : ℝ) : + Measurable (delayedEndingTensor lam k J L K R) := + (alignedEndingTensor_measurable _ _ _ _ _).comp (measurable_id.sub measurable_const) + +lemma endingJoinTensor_measurable {D : Coord3 → Mat3} (hD : Measurable D) (lam k J L K : ℝ) : + Measurable (endingJoinTensor D lam k J L K) := by + have hh : Measurable (fun x : Coord3 => endingJoinCutoff (x 0)) := endingJoinCutoff_smooth.continuous.measurable.comp (measurable_pi_apply (0:Fin 3)) + apply Measurable.of_eval; intro i + apply Measurable.of_eval; intro j + exact ((measurable_const.sub hh).mul ((measurable_pi_apply j).comp ((measurable_pi_apply i).comp hD))).add + (hh.mul ((measurable_pi_apply j).comp ((measurable_pi_apply i).comp (delayedEndingTensor_measurable _ _ _ _ _ _)))) + +lemma endingJoinTensor_symm {D : Coord3 → Mat3} (hD : ∀ x,(D x).IsSymm) (lam k J L K : ℝ) (x : Coord3) : + (endingJoinTensor D lam k J L K x).IsSymm := + ((hD x).smul _).add ((alignedEndingTensor_symm _ _ _ _ _ _).smul _) + +lemma convexTensor_quadratic (A B : Mat3) (t : ℝ) (v : Coord3) : + v ⬝ᵥ (((1-t) • A+t • B)*ᵥv)=(1-t)*(v ⬝ᵥ (A*ᵥv))+t*(v ⬝ᵥ (B*ᵥv)) := by + simp only [Matrix.add_mulVec,Matrix.smul_mulVec,dotProduct_add,dotProduct_smul,smul_eq_mul] + +lemma endingJoinTensor_bounds {D : Coord3 → Mat3} {lam k J L K c C : ℝ} + (hD : ∀ x v : Coord3,c*(v ⬝ᵥ v)≤v ⬝ᵥ (D x*ᵥv) ∧ v ⬝ᵥ (D x*ᵥv)≤C*(v ⬝ᵥ v)) + (hE : ∀ x v : Coord3,c*(v ⬝ᵥ v)≤v ⬝ᵥ (alignedEndingTensor lam k J L K x*ᵥv) ∧ + v ⬝ᵥ (alignedEndingTensor lam k J L K x*ᵥv)≤C*(v ⬝ᵥ v)) (x v : Coord3) : + c*(v ⬝ᵥ v)≤v ⬝ᵥ (endingJoinTensor D lam k J L K x*ᵥv) ∧ + v ⬝ᵥ (endingJoinTensor D lam k J L K x*ᵥv)≤C*(v ⬝ᵥ v) := by + rw [endingJoinTensor,convexTensor_quadratic] + have hd := hD x v + have he := hE (x-Pi.single 0 7) v + change c*(v ⬝ᵥv)≤v ⬝ᵥ(delayedEndingTensor lam k J L K 7 x*ᵥv) ∧ + v ⬝ᵥ(delayedEndingTensor lam k J L K 7 x*ᵥv)≤C*(v ⬝ᵥv) at he + have ht := endingJoinCutoff_bounds (x 0) + have ht' : 0≤1-endingJoinCutoff (x 0) := sub_nonneg.mpr ht.2 + constructor + · nlinarith [mul_le_mul_of_nonneg_left hd.1 ht',mul_le_mul_of_nonneg_left he.1 ht.1] + · nlinarith [mul_le_mul_of_nonneg_left hd.2 ht',mul_le_mul_of_nonneg_left he.2 ht.1] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/EndingJoinOverlap.lean b/lean/OAI/Analysis/Conductivity/Branching/EndingJoinOverlap.lean new file mode 100644 index 0000000000000000000000000000000000000000..6d9ec03f63295e94b14986db310fd77807c8b409 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/EndingJoinOverlap.lean @@ -0,0 +1,51 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AlignedEndingRegularity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real + +lemma endingJoin_overlap {u : Coord3 → Fin 2 → ℝ} {lam k J L K : ℝ} + (hk : 0 + ⟨pureModeTensor (initialConnectorAngular a (1/2) J (y 0)) 1,pureModeTensor_symm _ _⟩ + have hF := pureModeValue_smooth (initialConnectorProfile_smooth a (1/2) J) (1:Fin 3) + have hB : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => (B y).val) := by + apply pureModeTensor_smooth + exact (initialConnectorAngular_smooth a (1/2) J).comp (contDiff_apply ℝ ℝ 0) + apply axialPair_mem_regularRegion_of_model hF hB (i:=1) ?_ ?_ (by decide) ?_ hU hx + · exact axial_paste_eventually_left (continuous_apply 0) ht + · filter_upwards [(isOpen_lt (continuous_apply (0:Fin 3)) continuous_const).mem_nhds ht] with y hy + apply Subtype.ext + exact ite_eq_left hy + · rw [pureModeValue_direction ((initialConnectorProfile_smooth a (1/2) J).differentiable (by simp))] + norm_num only [show (1:Fin 3)≠0 from by decide,ite_false,ite_true,zero_add] + exact mul_ne_zero (neg_ne_zero.mpr (initialConnectorProfile_pos _ _ _ _).ne') hsin + +lemma finiteEnding_cascade_regular {a J L K : ℝ} (x : Coord3) (ht : J+2 cascadeValue L K 1 (initialConnectorProfile a (1/2) J (J+2)) (y-Pi.single 0 (J+2)) := + axial_paste_eventually_right (continuous_apply 0) ht + filter_upwards [he] with y hy + rw [show (![J+2,0] : Fin 2 → ℝ)=![(Pi.single 0 (J+2) : Coord3) 0,0] by simp, + axialPair_translate] + simp only [axialPair,hy] + · filter_upwards [(isOpen_lt continuous_const (continuous_apply (0:Fin 3))).mem_nhds ht] with y hy + apply Subtype.ext + exact ite_eq_right (not_lt.mpr hy.le) + +theorem finiteEnding_regularRegion_ae {a J L K : ℝ} (hL : 0 congrFun (branchFinitePair_initial hs i z y hy) j) hx] with y hy + change _+torusEndingCorrection _ _ _ _ y=_ + rw [hy,add_zero] + +lemma branchSplicedFlux_initial + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {x : Coord3} (hx : x 0 branchFinitePair_initial_flux i z hs j y hy) hx] with y hy + change _+torusEndingFluxCorrection _ _ _ _ y=_ + rw [hy,add_zero] + +lemma branchSplicedField_final (j : Fin 2) {x : Coord3} (hx : z.d+z.e/2 (branchFinitePair i z).v y j) := by + filter_upwards [torusEndingCorrection_terminal + (v:=fun y => (branchFinitePair i z).v y j) + (f:=torusAffineField s (centralBasisSlopes j i) (f j)) hx] with y hy + change _+torusEndingCorrection _ _ _ _ y=_ + rw [hy] + change torusAffineField s (centralBasisSlopes j i) (f j) y+ + ((branchFinitePair i z).v y j-torusAffineField s (centralBasisSlopes j i) (f j) y)=_ + ring + +lemma branchSplicedFlux_final (j : Fin 2) {x : Coord3} (hx : z.d+z.e/2 ((branchFinitePair i z).G y).col j) := by + filter_upwards [torusEndingFluxCorrection_terminal + (G:=fun y => ((branchFinitePair i z).G y).col j) + (F:=flatModeFlux s (torusAffineField s (centralBasisSlopes j i) (f j))) hx] with y hy + change _+torusEndingFluxCorrection _ _ _ _ y=_ + rw [hy] + change flatModeFlux s (torusAffineField s (centralBasisSlopes j i) (f j)) y+ + (((branchFinitePair i z).G y).col j-flatModeFlux s (torusAffineField s (centralBasisSlopes j i) (f j)) y)=_ + abel + +lemma branchSplicedTensor_measurable : Measurable (branchSplicedTensor i z) := by + exact Measurable.ite (measurableSet_lt (measurable_pi_apply 0) measurable_const) + measurable_const (branchFinitePair i z).measurable + +lemma branchSplicedTensor_symm (x : Coord3) : (branchSplicedTensor i z x).IsSymm := by + unfold branchSplicedTensor + split + · exact flatBackgroundTensor_symm s + · exact (branchFinitePair i z).symm x + +lemma branchSplicedTensor_periodic : AngularPeriodic (2*Real.pi) (branchSplicedTensor i z) := by + intro n x + have hzero : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + simp only [branchSplicedTensor,hzero,branchFinitePair_periodic_E i z n x] + +lemma branchSplicedTensor_elliptic + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) : + ∃ c C : ℝ,0 mul_self_nonneg (v k)) + unfold branchSplicedTensor + split + · constructor + · exact (mul_le_mul_of_nonneg_right (min_le_right _ _) hv).trans + (flatBackgroundTensor_lower hs v) + · exact ((le_abs_self _).trans (matrix_quadratic_elementwise_bound _ v)).trans + (mul_le_mul_of_nonneg_right + ((le_add_of_nonneg_right (by norm_num : (0:ℝ)≤1)).trans (le_max_right _ _)) hv) + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) hv).trans (hb x v).1, + (hb x v).2.trans (mul_le_mul_of_nonneg_right (le_max_left _ _) hv)⟩ + +lemma branchSplicedField_smooth + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (j : Fin 2) : + ContDiffOn ℝ 2 (branchSplicedField i z j) {x | 0 fderiv ℝ (branchSplicedField i z j) x (Pi.single k 1))= + branchSplicedFlux i z j x := by + filter_upwards [(branchFinitePair i z).constitution] with x hx + by_cases ht : x 0 M.col j) hx + change _*ᵥ((gradientColumns (fderiv ℝ (branchFinitePair i z).v x)).col j)=_ at hj + have he : (gradientColumns (fderiv ℝ (branchFinitePair i z).v x)).col j= + (fun k => fderiv ℝ (branchFinitePair i z).v x (Pi.single k 1) j) := by + ext k + rfl + rw [he] at hj + simpa only [potential_component_fderiv + ((branchFinitePair i z).smooth.differentiable (by norm_num)) j] using hj + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/JoinHull.lean b/lean/OAI/Analysis/Conductivity/Branching/JoinHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..a7fdeb6dcfbd0a86bc86a423b0b9c08a3e3949dd --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/JoinHull.lean @@ -0,0 +1,201 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.RecoverJoinChild + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set Filter Topology + +def joinHull (U : Set DiagonalTriple) : Set DiagonalTriple := + U ∪ {δ | ∃ i θ α β, 0 ≤ θ ∧ θ ≤ 1 ∧ α ∈ U ∧ β ∈ U ∧ + coordinateJoin i θ α β = δ} + +lemma subset_joinHull (U : Set DiagonalTriple) : U ⊆ joinHull U := fun _ => Or.inl + +lemma joinHull_mono {U V : Set DiagonalTriple} (h : U ⊆ V) : joinHull U ⊆ joinHull V := by + rintro δ (hδ | ⟨i, θ, α, β, hθ₀, hθ₁, hα, hβ, rfl⟩) + · exact Or.inl (h hδ) + · exact Or.inr ⟨i, θ, α, β, hθ₀, hθ₁, h hα, h hβ, rfl⟩ + +lemma joinHull_subset_laminate {a b : ℝ} {U : Set DiagonalTriple} + (hU : ∀ α ∈ U, IsFiniteLaminate a b α) : + ∀ α ∈ joinHull U, IsFiniteLaminate a b α := by + rintro δ (hδ | ⟨i, θ, α, β, hθ₀, hθ₁, hα, hβ, rfl⟩) + · exact hU δ hδ + · exact .join i θ hθ₀ hθ₁ (hU α hα) (hU β hβ) + +lemma isOpen_joinHull {a b : ℝ} (ha : 0 < a) {U : Set DiagonalTriple} + (hU : IsOpen U) (hsub : ∀ α ∈ U, IsFiniteLaminate a b α) : IsOpen (joinHull U) := by + apply isOpen_iff_mem_nhds.mpr + rintro δ (hδ | ⟨i, θ, α, β, hθ₀, hθ₁, hα, hβ, rfl⟩) + · exact mem_of_superset (hU.mem_nhds hδ) (subset_joinHull U) + · by_cases hθ : θ = 0 + · rw [hθ, coordinateJoin_zero] + exact mem_of_superset (hU.mem_nhds hβ) (subset_joinHull U) + · have hαi : α i ≠ 0 := (ha.trans ((hsub α hα).bounds ha i).1).ne' + have hδi : coordinateJoin i θ α β i ≠ 0 := + (ha.trans (coordinateJoin_bounds ha ((hsub α hα).bounds ha) + ((hsub β hβ).bounds ha) i ⟨hθ₀, hθ₁⟩ i).1).ne' + have hc := continuousAt_recoverJoinChild i hθ α β hαi hδi + have he := recoverJoinChild_join i hθ α β + have hm : ∀ᶠ δ' in 𝓝 (coordinateJoin i θ α β), recoverJoinChild i θ β δ' ∈ U := + hc.preimage_mem_nhds (by rw [he]; exact hU.mem_nhds hα) + filter_upwards [hm] with δ' hδ' + exact Or.inr ⟨i, θ, recoverJoinChild i θ β δ', β, + hθ₀, hθ₁, hδ', hβ, coordinateJoin_recoverJoinChild i hθ β δ'⟩ + +lemma joinHull_permute {U : Set DiagonalTriple} + (hU : ∀ α ∈ U, ∀ e : Equiv.Perm (Fin 3), α ∘ e ∈ U) : + ∀ α ∈ joinHull U, ∀ e : Equiv.Perm (Fin 3), α ∘ e ∈ joinHull U := by + rintro δ (hδ | ⟨i, θ, α, β, hθ₀, hθ₁, hα, hβ, rfl⟩) e + · exact Or.inl (hU δ hδ e) + · refine Or.inr ⟨e.symm i, θ, α ∘ e, β ∘ e, hθ₀, hθ₁, hU α hα e, hU β hβ e, ?_⟩ + ext j + simp only [Function.comp_apply, coordinateJoin] + congr 1 + exact propext ⟨fun h => by simpa using congrArg e h, + fun h => by simpa using congrArg e.symm h⟩ + +def depthClass (U : Set DiagonalTriple) : ℕ → Set DiagonalTriple + | 0 => U + | n+1 => joinHull (depthClass U n) + +lemma depthClass_subset_succ (U : Set DiagonalTriple) (n : ℕ) : + depthClass U n ⊆ depthClass U (n+1) := subset_joinHull _ + +lemma depthClass_mono (U : Set DiagonalTriple) : Monotone (depthClass U) := + monotone_nat_of_le_succ (depthClass_subset_succ U) + +lemma depthClass_subset_laminate {a b : ℝ} {U : Set DiagonalTriple} + (hU : ∀ α ∈ U, IsFiniteLaminate a b α) (n : ℕ) : + ∀ α ∈ depthClass U n, IsFiniteLaminate a b α := by + induction n with + | zero => exact hU + | succ n ih => exact joinHull_subset_laminate ih + +lemma isOpen_depthClass {a b : ℝ} (ha : 0 < a) {U : Set DiagonalTriple} + (hU : IsOpen U) (hsub : ∀ α ∈ U, IsFiniteLaminate a b α) (n : ℕ) : + IsOpen (depthClass U n) := by + induction n with + | zero => exact hU + | succ n ih => exact isOpen_joinHull ha ih (depthClass_subset_laminate hsub n) + +lemma depthClass_permute {U : Set DiagonalTriple} + (hU : ∀ α ∈ U, ∀ e : Equiv.Perm (Fin 3), α ∘ e ∈ U) (n : ℕ) : + ∀ α ∈ depthClass U n, ∀ e : Equiv.Perm (Fin 3), α ∘ e ∈ depthClass U n := by + induction n with + | zero => exact hU + | succ n ih => exact joinHull_permute ih + +theorem IsFiniteLaminate.mem_some_depth {a b : ℝ} {U : Set DiagonalTriple} + (hU : ∀ s, a < s → s < b → (fun _ => s) ∈ U) + {α : DiagonalTriple} (hα : IsFiniteLaminate a b α) : + ∃ n, α ∈ depthClass U n := by + induction hα with + | scalar s has hsb => exact ⟨0, hU s has hsb⟩ + | @join i θ hθ₀ hθ₁ α β hα hβ ihα ihβ => + obtain ⟨n, hn⟩ := ihα + obtain ⟨m, hm⟩ := ihβ + exact ⟨max n m + 1, Or.inr ⟨i, θ, α, β, hθ₀, hθ₁, + depthClass_mono U (le_max_left n m) hn, + depthClass_mono U (le_max_right n m) hm, rfl⟩⟩ + +theorem depthClass_plan {a b : ℝ} {U : Set DiagonalTriple} + (hsub : ∀ α ∈ U, IsFiniteLaminate a b α) {n : ℕ} {δ : DiagonalTriple} + (hδ : δ ∈ depthClass U (n+1)) (hn : δ ∉ depthClass U n) : + ∃ i θ α β, 0 < θ ∧ θ < 1 ∧ α ∈ depthClass U n ∧ β ∈ depthClass U n ∧ + coordinateJoin i θ α β = δ ∧ + ∀ t ∈ Icc (0 : ℝ) 1, IsFiniteLaminate a b (coordinateJoin i t α β) := by + rcases hδ with hδ | ⟨i, θ, α, β, hθ₀, hθ₁, hα, hβ, rfl⟩ + · exact (hn hδ).elim + have hθne : θ ≠ 0 := by + intro he + apply hn + simpa [he, coordinateJoin_zero] using hβ + have hθne' : θ ≠ 1 := by + intro he + apply hn + simpa [he, coordinateJoin_one] using hα + refine ⟨i, θ, α, β, lt_of_le_of_ne hθ₀ (Ne.symm hθne), + lt_of_le_of_ne hθ₁ hθne', hα, hβ, rfl, ?_⟩ + intro t ht + exact .join i t ht.1 ht.2 + (depthClass_subset_laminate hsub n α hα) (depthClass_subset_laminate hsub n β hβ) + +def scalarNeighbourhood (a b ε : ℝ) : Set DiagonalTriple := + {α | IsFiniteLaminate a b α ∧ ∃ s : ℝ, ‖α - (fun _ => s)‖ < ε} + +lemma isOpen_scalarNeighbourhood {a b ε : ℝ} (ha : 0 < a) : + IsOpen (scalarNeighbourhood a b ε) := by + have he : IsOpen {α : DiagonalTriple | ∃ s : ℝ, ‖α - (fun _ => s)‖ < ε} := by + simp only [ofPred_exists] + apply isOpen_iUnion + intro s + exact isOpen_lt (continuous_id.sub continuous_const).norm continuous_const + exact (isOpen_finiteLaminate ha).inter he + +lemma scalar_mem_scalarNeighbourhood {a b ε s : ℝ} (hε : 0 < ε) + (has : a < s) (hsb : s < b) : (fun _ => s) ∈ scalarNeighbourhood a b ε := by + refine ⟨.scalar s has hsb, s, ?_⟩ + simpa using hε + +lemma scalarNeighbourhood_permute {a b ε : ℝ} {α : DiagonalTriple} + (hα : α ∈ scalarNeighbourhood a b ε) (e : Equiv.Perm (Fin 3)) : + α ∘ e ∈ scalarNeighbourhood a b ε := by + rcases hα with ⟨hα, s, hs⟩ + refine ⟨hα.permute e, s, ?_⟩ + have he : ‖(α - (fun _ => s)) ∘ e‖ = ‖α - (fun _ => s)‖ := + le_antisymm + ((pi_norm_le_iff_of_nonneg (norm_nonneg _)).2 + (fun i => norm_le_pi_norm (α - fun _ => s) (e i))) + ((pi_norm_le_iff_of_nonneg (norm_nonneg _)).2 (fun i => by + simpa only [Function.comp_apply, Equiv.apply_symm_apply] using + norm_le_pi_norm ((α - fun _ => s) ∘ e) (e.symm i))) + change ‖(α - (fun _ => s)) ∘ e‖ < ε + rw [he] + exact hs + +def endpointGraph {P X : Type*} (a b : P) (G U V : Set X) : Set (P × X) := + {p | p.2 ∈ G ∧ (p.1 ≠ a ∨ p.2 ∈ U) ∧ (p.1 ≠ b ∨ p.2 ∈ V)} + +lemma isOpen_endpointGraph {P X : Type*} [TopologicalSpace P] [T1Space P] + [TopologicalSpace X] (a b : P) {G U V : Set X} + (hG : IsOpen G) (hU : IsOpen U) (hV : IsOpen V) : + IsOpen (endpointGraph a b G U V) := by + exact (hG.preimage continuous_snd).inter + (((isOpen_ne.preimage continuous_fst).union + (hU.preimage continuous_snd)).inter + ((isOpen_ne.preimage continuous_fst).union + (hV.preimage continuous_snd))) + +lemma path_mem_endpointGraph {P X : Type*} (a b : P) (C : P → X) + {K : Set P} {G U V : Set X} (hG : ∀ p ∈ K, C p ∈ G) + (ha : C a ∈ U) (hb : C b ∈ V) : + ∀ p ∈ K, (p, C p) ∈ endpointGraph a b G U V := by + intro p hp + refine ⟨hG p hp, ?_, ?_⟩ + · by_cases h : p = a + · exact Or.inr (h ▸ ha) + · exact Or.inl h + · by_cases h : p = b + · exact Or.inr (h ▸ hb) + · exact Or.inl h + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/JoinedPhysicalEnds.lean b/lean/OAI/Analysis/Conductivity/Branching/JoinedPhysicalEnds.lean new file mode 100644 index 0000000000000000000000000000000000000000..c317ffccccacf4ce91e30d48f66e46a837f288e2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/JoinedPhysicalEnds.lean @@ -0,0 +1,218 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentComplementPartition +import OAI.Analysis.Conductivity.Branching.ChildComplementPartition + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem parentAttachedCorrection_supported (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) (κ : ℝ) (p : centralEnergySpace s) : + ∃ d : H1,d∈H10 ∧ + (∀ᵐ x∂ballMeasure, WithLp.ofLp x∉sourceClosedCollarBand (-2*centralThickness) (2*centralThickness) → + weakValue d x=0 ∧ ∀ i,weakGradient d x i=0) ∧ + (∀ᵐ x∂ballMeasure,centralThickness ≤ sourceCollarTime (WithLp.ofLp x) → + weakValue d x=0 ∧ ∀ i,weakGradient d x i=0) ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + weakValue (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p+d) x= + fullAttachedEndValue s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) ∧ + ∀ i,weakGradient (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p+d) x i= + fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) i) := by + obtain ⟨r,η,hr₀,hr,hη,hηc,hηb,hηs,hηzero,hpart⟩ := centralParent_complement_partition + obtain ⟨v,hv,hve⟩ := compact_collar_slope_value_gradient (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) ha.ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + κ 0 (2*centralThickness) (by norm_num) (by norm_num [centralThickness]) centralJoinPartition_parent_support + have hR : 0≤-a*(3*centralThickness/2) := + mul_nonneg (neg_nonneg.mpr ha.le) (by norm_num [centralThickness]) + have hT : ∀ t∈Icc (-centralThickness/2) r, + affineEndTime a centralThickness t∈Icc 0 (-a*(3*centralThickness/2)) := by + intro t ht + dsimp only [affineEndTime] + constructor + · exact mul_nonneg_of_nonpos_of_nonpos ha.le (sub_nonpos.mpr (ht.2.trans hr.le)) + · have hm := mul_nonpos_of_nonpos_of_nonneg ha.le (sub_nonneg.mpr ht.1) + nlinarith + have hpos : ∀ t∈Icc (-centralThickness/2) r,0 mul_pos_of_neg_of_neg ha (sub_neg.mpr (ht.2.trans_lt hr)) + obtain ⟨z,hz,hze⟩ := cut_fullAttachedEnd_H10 s hs (centralT s 0 p) κ ha.ne hR + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + (show -centralThickness/2≤r by + have ht : (0:ℝ) dsimp [centralThickness] at * <;> linarith + have hχ0 := image_eq_zero_of_notMem_tsupport hχn + have hdχ0 := fderiv_of_notMem_tsupport ℝ hχn + have hη0 := image_eq_zero_of_notMem_tsupport hηn + have hdη0 := fderiv_of_notMem_tsupport ℝ hηn + constructor + · rw [hval] + simp [hx.1,hy.1,hχ0,hη0] + · intro i + rw [hgrad] + simp [hx.2 i,hy.2 i,hχ0,hη0,hdχ0,hdη0] + + · filter_upwards [hve,hze,weakValue_add v z,weakGradient_add v z] with x hx hy hval hgrad hcentral + have ht := hcentral + have hn : a*(sourceCollarTime (WithLp.ofLp x)-centralThickness)≤0 := + mul_nonpos_of_nonpos_of_nonneg ha.le (sub_nonneg.mpr ht) + have hηn : WithLp.ofLp x∉tsupport η := by + intro hm + have ht' := (hηs hm).2 + exact (not_le.mpr hr) (ht.trans ht') + have he : η (WithLp.ofLp x)=0 := image_eq_zero_of_notMem_tsupport hηn + have hd : fderiv ℝ η (WithLp.ofLp x)=0 := fderiv_of_notMem_tsupport ℝ hηn + constructor + · rw [hval] + simp only [Pi.add_apply,hx.1,hy.1,max_eq_left hn,he,mul_zero,zero_mul,add_zero] + · intro i + rw [hgrad] + simp only [WithLp.ofLp_add,Pi.add_apply,hx.2 i,hy.2 i,max_eq_left hn, + ite_eq_right (not_lt_of_ge hn),he,hd,zero_apply,mul_zero,zero_mul,add_zero] + · have hne := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (sourceColevel_ae_ne (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness]))) + have hp : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + 0 mul_pos ha (sub_pos.mpr (hl.trans_le ht.1)) + obtain ⟨z,hz,hze⟩ := cut_fullAttachedEnd_H10 s hs (centralT s k.succ p) κ ha.ne' hR + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + (show l≤centralThickness/2 by + have ht : (0:ℝ) dsimp [centralThickness] at * <;> linarith + have hχ0 := image_eq_zero_of_notMem_tsupport hχn + have hdχ0 := fderiv_of_notMem_tsupport ℝ hχn + have hη0 := image_eq_zero_of_notMem_tsupport hηn + have hdη0 := fderiv_of_notMem_tsupport ℝ hηn + constructor + · rw [hval] + simp [hx.1,hy.1,hχ0,hη0] + · intro i + rw [hgrad] + simp [hx.2 i,hy.2 i,hχ0,hη0,hdχ0,hdη0] + + · filter_upwards [hve,hze,weakValue_add v z,weakGradient_add v z] with x hx hy hval hgrad hcentral + have hn : a*(sourceCollarTime (WithLp.ofLp x)-(-centralThickness))≤0 := + mul_nonpos_of_nonneg_of_nonpos ha.le (sub_nonpos.mpr hcentral) + have he : η (WithLp.ofLp x)=0 := (hηzero _ hcentral).self_of_nhds + have hd : fderiv ℝ η (WithLp.ofLp x)=0 := by + rw [(hηzero _ hcentral).fderiv_eq] + exact fderiv_const_apply (0:ℝ) + constructor + · rw [hval] + simp only [Pi.add_apply,hx.1,hy.1,max_eq_left hn,he,mul_zero,zero_mul,add_zero] + · intro i + rw [hgrad] + simp only [WithLp.ofLp_add,Pi.add_apply,hx.2 i,hy.2 i,max_eq_left hn, + ite_eq_right (not_lt_of_ge hn),he,hd,zero_apply,mul_zero,zero_mul,add_zero] + · have hne := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (sourceColevel_ae_ne (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness]))) + have hp : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand (-centralThickness) 0 → + 0 Q (u (P y))) x)= + (operatorMatrix (P : Coord3 →L[ℝ] Coord3))ᵀ*gradientColumns (fderiv ℝ u (P x))* + (operatorMatrix (Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)))ᵀ := by + change gradientColumns (fderiv ℝ (Q ∘ u ∘ P) x)=_ + rw [(Q.hasFDerivAt.comp x (hu.hasFDerivAt.comp x P.hasFDerivAt)).fderiv] + change (operatorMatrix ((Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)).comp + ((fderiv ℝ u (P x)).comp (P : Coord3 →L[ℝ] Coord3))))ᵀ=_ + simp only [operatorMatrix_comp,Matrix.transpose_mul,Matrix.mul_assoc] + rfl + +lemma linearTensorPullback_columns (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) (A : Coord3 → Mat3) + {u : Coord3 → Fin 2 → ℝ} {x : Coord3} (hu : DifferentiableAt ℝ u (P x)) : + linearTensorPullback P A x*gradientColumns (fderiv ℝ (fun y => Q (u (P y))) x)= + operatorMatrix (P.symm : Coord3 →L[ℝ] Coord3)* + (A (P x)*gradientColumns (fderiv ℝ u (P x)))* + (operatorMatrix (Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)))ᵀ := by + rw [gradientColumns_linearCoordinates P Q hu] + have he : (operatorMatrix (P.symm : Coord3 →L[ℝ] Coord3))ᵀ* + (operatorMatrix (P : Coord3 →L[ℝ] Coord3))ᵀ=1 := by + have he0 := operatorMatrix_equiv_symm_mul P.symm + simp only [ContinuousLinearEquiv.symm_symm] at he0 + rw [←Matrix.transpose_mul,he0,Matrix.transpose_one] + simp only [linearTensorPullback,Matrix.mul_assoc] + rw [←Matrix.mul_assoc (operatorMatrix (P.symm : Coord3 →L[ℝ] Coord3))ᵀ,he,Matrix.one_mul] + +lemma RegularPatch.linearCoordinates {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {O : Set Coord3} (h : RegularPatch u A O) (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) : + RegularPatch (fun x => Q (u (P x))) + (fun x => ⟨linearTensorPullback P (fun y => (A y).val) x, + linearTensorPullback_symmetric P (fun y => (A y).property) x⟩) (P ⁻¹' O) := by + refine ⟨h.1.preimage P.continuous,?_,?_,h.2.2.2.linearCoordinates h.1 h.2.1 P Q⟩ + · exact Q.contDiff.comp_contDiffOn (h.2.1.comp P.contDiff.contDiffOn (fun _ hx => hx)) + · change ContDiffOn ℝ (↑(⊤ : ℕ∞)) (linearTensorPullback P (fun y => (A y).val)) _ + apply (h.1.preimage P.continuous).contDiffOn_iff.mpr + intro x hx + exact contDiffAt_matrix_mul (contDiffAt_matrix_mul contDiffAt_const + ((h.2.2.1.contDiffAt (h.1.mem_nhds hx)).comp x P.contDiff.contDiffAt)) contDiffAt_const + +lemma mem_regularRegion_linearCoordinates {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {U : Set Coord3} (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) {x : Coord3} + (h : P x∈regularRegion u A U) : + x∈regularRegion (fun y => Q (u (P y))) + (fun y => ⟨linearTensorPullback P (fun z => (A z).val) y, + linearTensorPullback_symmetric P (fun z => (A z).property) y⟩) (P ⁻¹' U) := by + obtain ⟨O,hOU,hO,hxO⟩ := mem_regularRegion_iff.mp h + exact mem_regularRegion_iff.mpr ⟨P ⁻¹' O,preimage_mono hOU,hO.linearCoordinates P Q,hxO⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/MatchedEndingRegularity.lean b/lean/OAI/Analysis/Conductivity/Branching/MatchedEndingRegularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..40c7057bece3ebe71b0d68f7ca0718b12ed13e57 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/MatchedEndingRegularity.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.EndingJoinElliptic +import OAI.Analysis.Conductivity.Variational.SmoothRankRegularity +import OAI.Analysis.Conductivity.Branching.DelayedEndingRegularity +import OAI.Analysis.Conductivity.Fourier.EndingJoinMiddleModel + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def endingJoinSymmetricTensor (D : Coord3 → Mat3) (hD : ∀ x,(D x).IsSymm) + (lam k J L K : ℝ) (x : Coord3) : Symmetric3 := + ⟨endingJoinTensor D lam k J L K x,endingJoinTensor_symm hD _ _ _ _ _ x⟩ + +lemma matchedEndingPair_pure {u : Coord3 → Fin 2 → ℝ} {lam k J L K : ℝ} + (hk : 0 ⟨D y,hDs y⟩ + have hr : x∈regularRegion u A univ := + smoothPair_mem_regularRegion hu hD (hxrank ⟨hxpos,ht6⟩) isOpen_univ (mem_univ _) + apply mem_regularRegion_congr_nhds hr ?_ ?_ hU hxU + · exact axial_paste_eventually_left (continuous_apply 0) (by linarith : x 0<13/2) + · filter_upwards [(isOpen_lt (continuous_apply (0:Fin 3)) continuous_const).mem_nhds ht6] with y hy + apply Subtype.ext + exact endingJoinTensor_left _ _ _ _ _ _ _ hy.le + · have h6 : 6 ∑ i,(endingJoinTensor D lam k J L K x*gradientColumns + (fderiv ℝ (matchedEndingPair u lam k J L K) x)).col j i*(smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(endingJoinTensor D lam k J L K x*gradientColumns + (fderiv ℝ (matchedEndingPair u lam k J L K) x)).col j i*(smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have hF := joinedFlux_C1 (lam:=lam) (k:=k) hD hu hJ hL hK j + have he : (fun x => ∑ i,(endingJoinTensor D lam k J L K x*gradientColumns + (fderiv ℝ (matchedEndingPair u lam k J L K) x)).col j i*(smoothDirection (Pi.single i 1) ψ).val x)=ᵐ[volume] + (fun x => ∑ i,joinedFlux D u lam k J L K j x i*(smoothDirection (Pi.single i 1) ψ).val x) := by + filter_upwards [endingJoin_constitution_ae (D:=D) hk hJ hL hK hum] with x hx + rw [hx j] + constructor + · apply Integrable.congr _ he.symm + apply integrable_finsetSum + intro i _ + exact ((contDiff_pi.mp hF i).continuous.mul + (smoothScalar_contDiff (smoothDirection (Pi.single i 1) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (Pi.single i 1) hc).mul_left + · rw [integral_congr_ae he] + apply C1_divergence_zero_ae_test volume (fun i => Pi.single i 1) + (fun i x => joinedFlux D u lam k J L K j x i) (fun i => contDiff_pi.mp hF i) ψ hc + filter_upwards [endingJoin_normal_ae hk hJ hL hK hum hDm] with x hx + intro hxs + have hp := hs (subset_tsupport _ hxs) + exact axialFluxBlend_divergence_zero (endingJoinCutoff_smooth.differentiable (by simp)) + ((symmetricFlux_smooth hD hu j).differentiable (by simp)) + ((delayedPairFlux_C1 hJ hL hK j).differentiable (by norm_num)) + (hPDE j x hp) (delayedPairFlux_divergence hJ hL hK j x) (hx j) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluing.lean b/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluing.lean new file mode 100644 index 0000000000000000000000000000000000000000..cf4c98e68fe62361695ac6e61483789b75b26724 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluing.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.TsupportFiniteSumSubset + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma exists_measurable_disjoint_gluing + {X Y I : Type*} [TopologicalSpace X] [MeasurableSpace X] [BorelSpace X] + [TopologicalSpace Y] [MeasurableSpace Y] [BorelSpace Y] + [Fintype I] (O : I → Set X) (hO : ∀ i, IsOpen (O i)) + (hd : Pairwise (fun i j => Disjoint (O i) (O j))) + (A : X → Y) (hA : Measurable A) (B : I → X → Y) + (hB : ∀ i, ContinuousOn (B i) (O i)) (y₀ : Y) : + ∃ T : X → Y, Measurable T ∧ (∀ i, EqOn T (B i) (O i)) ∧ + EqOn T A (⋃ i, O i)ᶜ := by + classical + let P : Option I → Set X := fun i => match i with + | none => (⋃ i, O i)ᶜ + | some j => O j + let G : Option I → X → Y := fun i => match i with + | none => A + | some j => (O j).piecewise (B j) (fun _ => y₀) + have hP : ∀ i, MeasurableSet (P i) := by + rintro (_ | i) + · exact (MeasurableSet.iUnion (fun i => (hO i).measurableSet)).compl + · exact (hO i).measurableSet + have hG : ∀ i, Measurable (G i) := by + rintro (_ | i) + · exact hA + · exact (hB i).measurable_piecewise continuousOn_const (hO i).measurableSet + obtain ⟨T, hT, hTP⟩ := exists_measurable_piecewise P hP G hG (by + rintro (_ | i) (_ | j) hij x ⟨hxi, hxj⟩ + · exact (hij rfl).elim + · exact (hxi (mem_iUnion.mpr ⟨j, hxj⟩)).elim + · exact (hxj (mem_iUnion.mpr ⟨i, hxi⟩)).elim + · exact (Set.disjoint_left.mp (hd (fun e => hij (congrArg some e))) hxi hxj).elim) + refine ⟨T, hT, ?_, hTP none⟩ + intro i x hx + simpa only [G, Set.piecewise_eq_of_mem (O i) (B i) (fun _ => y₀) hx] using hTP (some i) hx + +instance : MeasurableSpace Symmetric3 := borel Symmetric3 +instance : BorelSpace Symmetric3 := ⟨rfl⟩ + +theorem assemble_compact_tensors + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {I : Type*} [Fintype I] [DecidableEq I] + (O : I → Set Coord3) (hO : ∀ i, IsOpen (O i)) + (hd : Pairwise (fun i j => Disjoint (O i) (O j))) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hA : Measurable A) + (R : ∀ i, CompactTwoFieldReplacement μ (O i) u A) : + ∃ (du : Coord3 → Fin 2 → ℝ) (dF : Coord3 → Matrix (Fin 3) (Fin 2) ℝ) + (T : Coord3 → Symmetric3), + ContDiff ℝ (↑(⊤ : ℕ∞)) du ∧ HasCompactSupport du ∧ tsupport du ⊆ ⋃ i, O i ∧ + ContDiff ℝ (↑(⊤ : ℕ∞)) dF ∧ HasCompactSupport dF ∧ tsupport dF ⊆ ⋃ i, O i ∧ + (∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x ((dF x).col j) ∂μ) = 0) ∧ Measurable T ∧ + (∀ i, EqOn du (R i).du (O i) ∧ EqOn dF (R i).dF (O i) ∧ + EqOn T (R i).tensor (O i)) ∧ EqOn T A (⋃ i, O i)ᶜ ∧ + (∀ x, conductivityFlux (fun y => u y+du y) T x = conductivityFlux u A x+dF x) := by + obtain ⟨du, dF, hus, huc, hUs, hFs, hFc, hFS, hpair, heq, hoff⟩ := + assemble_compact_replacements μ O hO hd u A R + have hB (i : I) : ContinuousOn (R i).tensor (O i) := + Topology.IsInducing.subtypeVal.continuousOn_iff.mpr (R i).smooth_tensor.continuousOn + obtain ⟨T, hT, hTon, hToff⟩ := exists_measurable_disjoint_gluing O hO hd A hA + (fun i => (R i).tensor) hB (A 0) + refine ⟨du, dF, T, hus, huc, hUs, hFs, hFc, hFS, hpair, hT, + fun i => ⟨(heq i).1, (heq i).2.1, hTon i⟩, hToff, ?_⟩ + intro x + by_cases hx : x ∈ ⋃ i, O i + · obtain ⟨i, hxi⟩ := mem_iUnion.mp hx + simp only [conductivityFlux, hTon i hxi, (heq i).2.2 x hxi, (heq i).2.1 hxi] + exact (R i).constitutive x hxi + · have hxu : x ∉ tsupport du := fun hu => hx (hUs hu) + have hder : fderiv ℝ (fun y => u y+du y) x = fderiv ℝ u x := by + apply Filter.EventuallyEq.fderiv_eq + filter_upwards [(isClosed_tsupport du).isOpen_compl.mem_nhds hxu] with y hy + rw [image_eq_zero_of_notMem_tsupport hy, add_zero] + simp only [conductivityFlux, hToff hx, hder, (hoff x hx).2, add_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluingMeasurable.lean b/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluingMeasurable.lean new file mode 100644 index 0000000000000000000000000000000000000000..320e41b126de4bc01625e2ba657d44e82d3c4aa2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/MeasurableDisjointGluingMeasurable.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactGlobalUpdate + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma exists_measurable_disjoint_gluing_measurable + {X Y I : Type*} [MeasurableSpace X] [MeasurableSpace Y] + [Fintype I] (O : I → Set X) (hO : ∀ i, MeasurableSet (O i)) + (hd : Pairwise (fun i j => Disjoint (O i) (O j))) + (A : X → Y) (hA : Measurable A) (B : I → X → Y) + (hB : ∀ i, Measurable (B i)) : + ∃ T : X → Y, Measurable T ∧ (∀ i, EqOn T (B i) (O i)) ∧ + EqOn T A (⋃ i, O i)ᶜ := by + classical + let P : Option I → Set X := fun i => match i with + | none => (⋃ i, O i)ᶜ + | some j => O j + let G : Option I → X → Y := fun i => match i with + | none => A + | some j => B j + have hP : ∀ i, MeasurableSet (P i) := by + rintro (_ | i) + · exact (MeasurableSet.iUnion hO).compl + · exact hO i + have hG : ∀ i, Measurable (G i) := by + rintro (_ | i) + · exact hA + · exact hB i + obtain ⟨T,hT,hTP⟩ := exists_measurable_piecewise P hP G hG (by + rintro (_ | i) (_ | j) hij x ⟨hxi,hxj⟩ + · exact (hij rfl).elim + · exact (hxi (mem_iUnion.mpr ⟨j,hxj⟩)).elim + · exact (hxj (mem_iUnion.mpr ⟨i,hxi⟩)).elim + · exact (Set.disjoint_left.mp (hd (fun e => hij (congrArg some e))) hxi hxj).elim) + exact ⟨T,hT,fun i => hTP (some i),hTP none⟩ + +theorem assemble_global_updates + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {I : Type*} [Fintype I] [DecidableEq I] + {U : Set Coord3} (O : I → Set Coord3) (hO : ∀ i, IsOpen (O i)) + (hOU : ∀ i, O i ⊆ U) (hd : Pairwise (fun i j => Disjoint (O i) (O j))) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hA : Measurable A) + (R : ∀ i, CompactGlobalUpdate μ (O i) u A) : + ∃ S : CompactGlobalUpdate μ U u A, + (S.du = fun x => ∑ i, (R i).du x) ∧ + (S.dF = fun x => ∑ i, (R i).dF x) ∧ + (∀ i, EqOn S.du (R i).du (O i) ∧ EqOn S.dF (R i).dF (O i) ∧ + EqOn S.tensor (R i).tensor (O i)) ∧ EqOn S.tensor A (⋃ i, O i)ᶜ := by + let du : Coord3 → Fin 2 → ℝ := fun x => ∑ i, (R i).du x + let dF : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := fun x => ∑ i, (R i).dF x + have heu : ∀ i, EqOn du (R i).du (O i) := + supported_sum_eq_on O hd (fun i => (R i).du) (fun i => (R i).support_du) + have heF : ∀ i, EqOn dF (R i).dF (O i) := + supported_sum_eq_on O hd (fun i => (R i).dF) (fun i => (R i).support_dF) + have hus : tsupport du ⊆ ⋃ i, O i := + (tsupport_finite_sum_subset _).trans (iUnion_mono (fun i => (R i).support_du)) + have hFs : tsupport dF ⊆ ⋃ i, O i := + (tsupport_finite_sum_subset _).trans (iUnion_mono (fun i => (R i).support_dF)) + obtain ⟨T,hT,hTon,hToff⟩ := exists_measurable_disjoint_gluing_measurable O + (fun i => (hO i).measurableSet) hd A hA (fun i => (R i).tensor) (fun i => (R i).measurable_tensor) + let S : CompactGlobalUpdate μ U u A := { + du := du + dF := dF + tensor := T + smooth_du := ContDiff.sum (fun i _ => (R i).smooth_du) + compact_du := by + simpa only [du, ← Finset.sum_apply] using + (HasCompactSupport.finset_sum (s := Finset.univ) (fun i _ => (R i).compact_du)) + support_du := hus.trans (iUnion_subset hOU) + smooth_dF := ContDiff.sum (fun i _ => (R i).smooth_dF) + compact_dF := by + simpa only [dF, ← Finset.sum_apply] using + (HasCompactSupport.finset_sum (s := Finset.univ) (fun i _ => (R i).compact_dF)) + support_dF := hFs.trans (iUnion_subset hOU) + cauchy_dF := finite_sum_cauchy_preserving μ (fun i => (R i).dF) + (fun i => (R i).smooth_dF) (fun i => (R i).compact_dF) (fun i => (R i).cauchy_dF) + measurable_tensor := hT + constitutive := by + intro x + by_cases hx : x ∈ ⋃ i, O i + · obtain ⟨i,hxi⟩ := mem_iUnion.mp hx + have he : fderiv ℝ (fun y => u y+du y) x = fderiv ℝ (fun y => u y+(R i).du y) x := by + apply Filter.EventuallyEq.fderiv_eq + filter_upwards [(hO i).mem_nhds hxi] with y hy + rw [heu i hy] + simp only [conductivityFlux,hTon i hxi,he,heF i hxi] + exact (R i).constitutive x + · have hxu : x ∉ tsupport du := fun hu => hx (hus hu) + have hder : fderiv ℝ (fun y => u y+du y) x = fderiv ℝ u x := by + apply Filter.EventuallyEq.fderiv_eq + filter_upwards [(isClosed_tsupport du).isOpen_compl.mem_nhds hxu] with y hy + rw [image_eq_zero_of_notMem_tsupport hy,add_zero] + simp only [conductivityFlux,hToff hx,hder,image_eq_zero_of_notMem_tsupport (fun hy => hx (hFs hy)),add_zero] + } + exact ⟨S,rfl,rfl,fun i => ⟨heu i,heF i,hTon i⟩,hToff⟩ + +end ScalarConductivity + +namespace ScalarConductivity +open Set MeasureTheory Metric +open scoped ENNReal + +theorem finite_disjoint_localization_fine + {E I : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [Nontrivial E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {A : Set E} (hA : MeasurableSet A) (hμA : μ A ≠ ∞) + (U : I → Set E) (hU : ∀ i, IsOpen (U i)) (hc : A ⊆ ⋃ i, U i) + {ε : ℝ≥0∞} (hε : ε ≠ 0) {δ : ℝ} (hδ : 0 < δ) : + ∃ (n : ℕ) (Q : Fin n → Set E) (tag : Fin n → I) (center : Fin n → E), + (∀ i, IsOpen (Q i) ∧ IsCompact (closure (Q i)) ∧ closure (Q i) ⊆ U (tag i) ∧ + μ (frontier (Q i)) = 0 ∧ closure (Q i) ⊆ Metric.ball (center i) δ) ∧ + Pairwise (fun i j => Disjoint (Q i) (Q j)) ∧ μ (A \ ⋃ i, Q i) < ε := by + let V : I × E → Set E := fun p => U p.1 ∩ Metric.ball p.2 δ + have hV : ∀ p, IsOpen (V p) := fun p => (hU p.1).inter isOpen_ball + have hcover : A ⊆ ⋃ p, V p := by + intro x hx + obtain ⟨i,hi⟩ := mem_iUnion.mp (hc hx) + exact mem_iUnion.mpr ⟨(i,x),hi,mem_ball_self hδ⟩ + obtain ⟨n,Q,tag,hQ,hd,hmiss⟩ := finite_disjoint_localization_null μ hA hμA V hV hcover hε + exact ⟨n,Q,fun i => (tag i).1,fun i => (tag i).2, + fun i => ⟨(hQ i).1,(hQ i).2.1,(hQ i).2.2.1.trans inter_subset_left, + (hQ i).2.2.2,(hQ i).2.2.1.trans inter_subset_right⟩,hd,hmiss⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/OpenDisjointify.lean b/lean/OAI/Analysis/Conductivity/Branching/OpenDisjointify.lean new file mode 100644 index 0000000000000000000000000000000000000000..3332630a08d094ea48df3794d393a209631b089a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/OpenDisjointify.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set MeasureTheory Metric +open scoped ENNReal Topology + +def openDisjointify {E : Type*} [TopologicalSpace E] {n : ℕ} + (U : Fin n → Set E) (i : Fin n) : Set E := + U i \ ⋃ j ∈ Finset.Iio i, closure (U j) + +lemma openDisjointify_subset {E : Type*} [TopologicalSpace E] {n : ℕ} + (U : Fin n → Set E) (i : Fin n) : openDisjointify U i ⊆ U i := sdiff_subset + +lemma openDisjointify_isOpen {E : Type*} [TopologicalSpace E] {n : ℕ} + (U : Fin n → Set E) (hU : ∀ i, IsOpen (U i)) (i : Fin n) : + IsOpen (openDisjointify U i) := by + apply (hU i).sdiff + exact isClosed_biUnion_finset (fun _ _ => isClosed_closure) + +lemma openDisjointify_pairwise {E : Type*} [TopologicalSpace E] {n : ℕ} + (U : Fin n → Set E) : Pairwise (fun i j => Disjoint (openDisjointify U i) (openDisjointify U j)) := by + intro i j hij + apply disjoint_left.mpr + intro x hxi hxj + rcases lt_or_gt_of_ne hij with hij | hji + · exact hxj.2 (mem_iUnion₂.mpr ⟨i, Finset.mem_Iio.mpr hij, subset_closure hxi.1⟩) + · exact hxi.2 (mem_iUnion₂.mpr ⟨j, Finset.mem_Iio.mpr hji, subset_closure hxj.1⟩) + +lemma openDisjointify_cover {E : Type*} [TopologicalSpace E] {n : ℕ} + (U : Fin n → Set E) (hU : ∀ i, IsOpen (U i)) : + (⋃ i, U i) \ (⋃ i, openDisjointify U i) ⊆ ⋃ i, frontier (U i) := by + classical + intro x hx + by_contra hn + obtain ⟨j, hj⟩ := mem_iUnion.mp hx.1 + let s : Finset (Fin n) := Finset.univ.filter (fun i => x ∈ U i) + have hsn : s.Nonempty := ⟨j, Finset.mem_filter.mpr ⟨Finset.mem_univ _, hj⟩⟩ + let i := s.min' hsn + have hi : x ∈ U i := (Finset.mem_filter.mp (Finset.min'_mem s hsn)).2 + apply hx.2 + apply mem_iUnion.mpr + refine ⟨i, hi, ?_⟩ + intro hc + obtain ⟨j, hj, hxj⟩ := mem_iUnion₂.mp hc + have hfront : x ∉ frontier (U j) := fun h => hn (mem_iUnion.mpr ⟨j, h⟩) + have hin : x ∈ U j := by + by_contra hnot + apply hfront + rw [frontier, (hU j).interior_eq] + exact ⟨hxj, hnot⟩ + have hmin : i ≤ j := Finset.min'_le s j (Finset.mem_filter.mpr ⟨Finset.mem_univ _, hin⟩) + exact not_lt_of_ge hmin (Finset.mem_Iio.mp hj) + +lemma openDisjointify_ae_cover {E : Type*} [TopologicalSpace E] [MeasurableSpace E] + (μ : Measure E) {n : ℕ} (U : Fin n → Set E) (hU : ∀ i, IsOpen (U i)) + (hf : ∀ i, μ (frontier (U i)) = 0) : + μ ((⋃ i, U i) \ ⋃ i, openDisjointify U i) = 0 := by + exact measure_mono_null (openDisjointify_cover U hU) (measure_iUnion_null hf) + +theorem finite_disjoint_localization + {E I : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [Nontrivial E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {A : Set E} (hA : MeasurableSet A) (hμA : μ A ≠ ∞) + (U : I → Set E) (hU : ∀ i, IsOpen (U i)) (hc : A ⊆ ⋃ i, U i) + {ε : ℝ≥0∞} (hε : ε ≠ 0) : + ∃ (n : ℕ) (Q : Fin n → Set E) (tag : Fin n → I), + (∀ i, IsOpen (Q i) ∧ IsCompact (closure (Q i)) ∧ closure (Q i) ⊆ U (tag i)) ∧ + Pairwise (fun i j => Disjoint (Q i) (Q j)) ∧ μ (A \ ⋃ i, Q i) < ε := by + classical + obtain ⟨K, hKA, hK, hKμ⟩ := hA.exists_isCompact_sdiff_lt hμA hε + have hb : ∀ x : K, ∃ i : I, ∃ r : ℝ, 0 < r ∧ closedBall x.val r ⊆ U i := by + intro x + obtain ⟨i, hi⟩ := mem_iUnion.mp (hc (hKA x.property)) + obtain ⟨r, hr, hri⟩ := Metric.isOpen_iff.mp (hU i) x.val hi + refine ⟨i, r/2, by positivity, ?_⟩ + intro y hy + exact hri (show dist y x.val < r from (mem_closedBall.mp hy).trans_lt (by linarith)) + choose tag r hr hri using hb + obtain ⟨t, ht⟩ := hK.elim_finite_subcover (fun x : K => Metric.ball x.val (r x)) + (fun _ => isOpen_ball) (fun x hx => mem_iUnion.mpr ⟨⟨x,hx⟩, mem_ball_self (hr ⟨x,hx⟩)⟩) + let T := {x : K // x ∈ t} + let n := Fintype.card T + let e : Fin n ≃ T := (Fintype.equivFin T).symm + let B : Fin n → Set E := fun i => Metric.ball (e i).val.val (r (e i).val) + have hKB : K ⊆ ⋃ i, B i := by + intro x hx + obtain ⟨y, hyt, hxy⟩ := mem_iUnion₂.mp (ht hx) + let z : T := ⟨y, hyt⟩ + exact mem_iUnion.mpr ⟨e.symm z, by simpa only [B, Equiv.apply_symm_apply] using hxy⟩ + have hBo : ∀ i, IsOpen (B i) := fun _ => isOpen_ball + have hBf : ∀ i, μ (frontier (B i)) = 0 := by + intro i + exact measure_mono_null frontier_ball_subset_sphere (Measure.addHaar_sphere μ _ _) + refine ⟨n, openDisjointify B, fun i => tag (e i).val, ?_, openDisjointify_pairwise B, ?_⟩ + · intro i + have hcl : closure (openDisjointify B i) ⊆ closedBall (e i).val.val (r (e i).val) := + (closure_mono (openDisjointify_subset B i)).trans closure_ball_subset_closedBall + exact ⟨openDisjointify_isOpen B hBo i, + (isCompact_closedBall _ _).of_isClosed_subset isClosed_closure hcl, hcl.trans (hri (e i).val)⟩ + · have hsub : A \ (⋃ i, openDisjointify B i) ⊆ + (A \ K) ∪ ((⋃ i, B i) \ ⋃ i, openDisjointify B i) := by + intro x hx + by_cases hxK : x ∈ K + · exact Or.inr ⟨hKB hxK, hx.2⟩ + · exact Or.inl ⟨hx.1, hxK⟩ + calc + μ (A \ ⋃ i, openDisjointify B i) ≤ + μ (A \ K) + μ ((⋃ i, B i) \ ⋃ i, openDisjointify B i) := + (measure_mono hsub).trans (measure_union_le _ _) + _ = μ (A \ K) := by rw [openDisjointify_ae_cover μ B hBo hBf, add_zero] + _ < ε := hKμ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParametricCorrectionTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/ParametricCorrectionTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..bb7f9d74d4dcc082de3ae28b6e3e06b4d6dfee3c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParametricCorrectionTransport.lean @@ -0,0 +1,180 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ParametricLocalRegularCorrection + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +lemma parametric_physical_source_moment_bound + {u : P×Coord3 → Fin 2 → ℝ} (hu : Continuous u) (p : P) {V : Set Coord3} + (hV : Bornology.IsBounded V) : + ∃ L : ℝ,0 u (q,x)) r‖≤L*M := by + let K := closure V + have hK : IsCompact K := hV.isCompact_closure + obtain ⟨B,hB⟩ := ((isCompact_closedBall p 1).prod hK).exists_bound_of_continuousOn hu.continuousOn + let A := |B|+1 + let W := volume.real K + have hA : 0 hb j x) + have htK : Function.support (fun x => u (q,x) 1*r 0 x-u (q,x) 0*r 1 x)⊆K := by + intro x hx + by_contra hn + have h0 := image_eq_zero_of_notMem_tsupport (fun h => hn (hrK 0 h)) + have h1 := image_eq_zero_of_notMem_tsupport (fun h => hn (hrK 1 h)) + exact hx (by simp [h0,h1]) + have ht : |∫ x,u (q,x) 1*r 0 x-u (q,x) 0*r 1 x|≤(2*A*M)*W := by + apply integral_bound_on_compact hK htK + intro x hx + calc + _ ≤ |u (q,x) 1*r 0 x|+|u (q,x) 0*r 1 x| := abs_sub _ _ + _ ≤ A*M+A*M := by + rw [abs_mul,abs_mul] + exact add_le_add (mul_le_mul (huB x hx 1) (hb 0 x) (abs_nonneg _) hA.le) + (mul_le_mul (huB x hx 0) (hb 1 x) (abs_nonneg _) hA.le) + _ = _ := by ring + apply pi_norm_le_iff_of_nonneg (by positivity) |>.mpr + intro j + have hmass : M*W≤((1+2*A)*(W+1))*M := by + nlinarith [mul_nonneg hM hW,mul_nonneg hA.le (mul_nonneg hM hW),mul_nonneg hA.le hM] + have htorque : (2*A*M)*W≤((1+2*A)*(W+1))*M := by + nlinarith [mul_nonneg hM hW,mul_nonneg hA.le hM] + fin_cases j + · exact (hi 0).trans hmass + · exact (hi 1).trans hmass + · exact ht.trans htorque + +structure ParametricCorrectionBox (u : P×Coord3 → Fin 2 → ℝ) (p : P) (U : Set Coord3) where + region : Set Coord3 + region_open : IsOpen region + region_nonempty : region.Nonempty + region_subset : region⊆U + region_bounded : Bornology.IsBounded region + bounded_solver : ∃ L : ℝ,0 u (q,x)) r=0 → ∀ M : ℝ,0≤M → + (∀ j,UniformC1Bound (r j) M) → + BoundedPhysicallyCorrectable (fun x => u (q,x)) U r (L*M) + +lemma exists_parametric_correction_box + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) + {U : Set Coord3} (hU : IsOpen U) {x : Coord3} (hx : x∈U) + (hD : Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) : + ∃ B : ParametricCorrectionBox u p U,x∈B.region := by + obtain ⟨V,W,L,hV,hp,hW,hxW,hWU,hWb,hL,solve⟩ := + exists_uniform_local_regular_correction hu p hD hU hx + refine ⟨⟨W,hW,⟨x,hxW⟩,hWU,hWb,L,hL,?_⟩,hxW⟩ + exact Filter.eventually_of_mem (hV.mem_nhds hp) solve + +lemma parametric_correction_boxes_cover + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + (hU : IsOpen U) (hD : ∀ x∈U,Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) : + (⋃ B : ParametricCorrectionBox u p U,B.region)=U := by + apply Subset.antisymm + · exact iUnion_subset fun B => B.region_subset + · intro x hx + obtain ⟨B,hB⟩ := exists_parametric_correction_box hu p hU hx (hD x hx) + exact mem_iUnion.mpr ⟨B,hB⟩ + +lemma ParametricCorrectionBox.bounded_transfer + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + (hD : ∀ x∈U,Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) + (B C : ParametricCorrectionBox u p U) (hBC : (B.region∩C.region).Nonempty) : + ∃ L : ℝ,0 u (t,x)) q=physicalSourceMoment (fun x => u (t,x)) r ∧ + (∀ j,UniformC1Bound (q j) (L*M)) ∧ + BoundedPhysicallyCorrectable (fun x => u (t,x)) U (r-q) (L*M) := by + obtain ⟨Q,R,hR,hQ,hQs,hQnear⟩ := parametric_bounded_physical_moments hu p + (B.region_open.inter C.region_open) hBC (inter_subset_left.trans B.region_subset) hD + obtain ⟨Z,hZ,hZnear⟩ := parametric_physical_source_moment_bound hu.continuous p B.region_bounded + obtain ⟨D,hDpos,hsolve⟩ := B.bounded_solver + let L := (D+1)*(1+R*Z) + have hL : 0 u (t,x) + have hv : ContDiff ℝ (↑(⊤:ℕ∞)) v := hu.comp (contDiff_const.prodMk contDiff_id) + let q := Q t (physicalSourceMoment v r) + have hq : CompactSmoothPair q := hQ _ _ + have hqm : physicalSourceMoment v q=physicalSourceMoment v r := ht.1 _ + have hqb (j) : UniformC1Bound (q j) ((R*Z)*M) := (ht.2 _ j).mono + ((mul_le_mul_of_nonneg_left (hZb r hs M hM (fun j x => (hb j x).1)) hR.le).trans_eq (by ring)) + have hsmall : (R*Z)*M≤L*M := by + dsimp [L] + nlinarith [mul_nonneg hR.le hZ.le,mul_nonneg hDpos.le (mul_nonneg hR.le hZ.le)] + have hrq : CompactSmoothPair (r-q) := hr.sub hq + have hsrc : physicalSourceMoment v (r-q)=0 := by + rw [physicalSourceMoment_sub hv.continuous hr hq,hqm,sub_self] + have hdif (j) : UniformC1Bound ((r-q) j) ((1+R*Z)*M) := by + change UniformC1Bound (fun x => r j x-q j x) ((1+R*Z)*M) + convert (hb j).sub ((hr j).1.differentiable (by simp)) ((hq j).1.differentiable (by simp)) (hqb j) using 1; ring + have hc := solve (r-q) hrq (hs.sub ((hQs t _).mono inter_subset_left)) hsrc + ((1+R*Z)*M) (by positivity) hdif + refine ⟨q,hq,(hQs t _).mono inter_subset_right,hqm,fun j => (hqb j).mono hsmall,hc.mono ?_⟩ + dsimp [L] + nlinarith [mul_nonneg hR.le hZ.le,mul_nonneg (add_nonneg zero_le_one (mul_nonneg hR.le hZ.le)) hM] + +lemma parametric_correction_boxes_chain + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ x∈U,Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) + (B C : ParametricCorrectionBox u p U) : + Relation.TransGen (fun B C : ParametricCorrectionBox u p U => (B.region∩C.region).Nonempty) B C := by + have hc : IsPreconnected (⋃ B : ParametricCorrectionBox u p U,B.region) := by + rwa [parametric_correction_boxes_cover hu p hU hD] + exact hc.transGen_of_iUnion (fun B => B.region_open) B C B.region_nonempty C.region_nonempty + +theorem parametric_controlled_source_transport + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ x∈U,Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) + (B C : ParametricCorrectionBox u p U) : + ∃ L : ℝ,0 u (t,x)) q=physicalSourceMoment (fun x => u (t,x)) r ∧ + (∀ j,UniformC1Bound (q j) (L*M)) ∧ + BoundedPhysicallyCorrectable (fun x => u (t,x)) U (r-q) (L*M) := by + have hp := parametric_correction_boxes_chain hu p hU hUc hD B C + induction hp with + | single h => exact B.bounded_transfer hu p hD _ h + | @tail C D hpath hCD ih => + obtain ⟨L,hL,hsolve⟩ := ih + obtain ⟨R,hR,hstep⟩ := C.bounded_transfer hu p hD D hCD + refine ⟨L+R*L,by positivity,?_⟩ + filter_upwards [hsolve,hstep] with t solve step + intro r hr hs M hM hb + obtain ⟨q,hq,hqs,hqm,hqb,hqc⟩ := solve r hr hs M hM hb + obtain ⟨s,hss,hssup,hsm,hsb,hsc⟩ := step q hq hqs (L*M) (mul_nonneg hL.le hM) hqb + refine ⟨s,hss,hssup,hsm.trans hqm,fun j => (hsb j).mono ?_,?_⟩ + · nlinarith [mul_nonneg hL.le hM] + · have hut : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x => u (t,x)) := + hu.comp (contDiff_const.prodMk contDiff_id) + have he := hqc.add hut hsc + rw [sub_add_sub_cancel] at he + exact he.mono (by ring_nf; rfl) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParentCentralL2.lean b/lean/OAI/Analysis/Conductivity/Branching/ParentCentralL2.lean new file mode 100644 index 0000000000000000000000000000000000000000..d6ad4be5018a82592589a0ecbe9eca044d0d9536 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParentCentralL2.lean @@ -0,0 +1,151 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CentralDistribution +import OAI.Analysis.Conductivity.Geometry.SmoothCollarTrace +import OAI.Analysis.Conductivity.Branching.AttachedEndLinear +import OAI.Analysis.Conductivity.Sobolev.LpExtension + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma parentBand_central {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand centralThickness (2*centralThickness)) : + sourcePairCoordinates y∈centralClosed := by + rw [sourceClosedCollarBand_eq _ _ (by norm_num [centralThickness]) + (by norm_num [centralThickness])] at hy + rcases mem_iUnion.mp hy with ⟨i, hi⟩ + rcases mem_iUnion.mp hi with ⟨j, hj⟩ + rcases hj with ⟨x, hx, rfl⟩ + exact sourceParentCollar_central i j hx + +lemma parentBand_measurable : MeasurableSet (sourceClosedCollarBand centralThickness (2*centralThickness)) := + (isCompact_sourceClosedCollarBand (by norm_num [centralThickness]) (by norm_num [centralThickness])).measurableSet + +def centralPhysicalWholeCLM : CentralL2 →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + (Lp.compMeasurePreservingₗᵢ ℝ sourcePairMeasurable sourcePair_volume).toContinuousLinearMap.comp + (lpZeroExtensionCLM centralClosed_compact.measurableSet) + +lemma centralPhysicalWholeCLM_smooth_ae (f : centralSmoothFunctions) (i : Fin 4) : + centralPhysicalWholeCLM (centralSmoothJet f i)=ᵐ[volume] + (fun y => centralPhysical.indicator (fun y => centralJetField f i (sourcePairCoordinates y)) y) := by + have he := lpZeroExtensionCLM_ae_of_ae centralClosed_compact.measurableSet + (centralSmoothJet f i) (centralSmoothJet_ae f i) + have he' := sourcePair_volume.quasiMeasurePreserving.ae_eq_comp he + apply (Lp.coeFn_compMeasurePreserving _ sourcePair_volume).trans + apply he'.trans + filter_upwards [] with y + by_cases hy : sourcePairCoordinates y∈centralClosed <;> simp [centralPhysical,hy,sourcePairMeasurable_apply] + +def parentCentralComponentCLM (s : Fin 3 → ℝ) (i : Fin 4) : + CentralAmbient s →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + (lpZeroExtensionCLM parentBand_measurable).comp + ((lpRestrictionCLM (sourceClosedCollarBand centralThickness (2*centralThickness))).comp + (centralPhysicalWholeCLM.comp (centralAmbientComponent s i))) + +lemma parentCentralComponentCLM_smooth_ae (s : Fin 3 → ℝ) (f : centralSmoothFunctions) (i : Fin 4) : + parentCentralComponentCLM s i (centralEmbedL s f)=ᵐ[volume] + (sourceClosedCollarBand centralThickness (2*centralThickness)).indicator + (fun y => centralJetField f i (sourcePairCoordinates y)) := by + have hr := lpRestrictionCLM_ae (sourceClosedCollarBand centralThickness (2*centralThickness)) + (centralPhysicalWholeCLM (centralSmoothJet f i)) + have he := hr.trans (ae_restrict_of_ae (centralPhysicalWholeCLM_smooth_ae f i)) + have hb : (lpRestrictionCLM (sourceClosedCollarBand centralThickness (2*centralThickness)) + (centralPhysicalWholeCLM (centralSmoothJet f i)))=ᵐ[volume.restrict + (sourceClosedCollarBand centralThickness (2*centralThickness))] + (fun y => centralJetField f i (sourcePairCoordinates y)) := by + filter_upwards [he,ae_restrict_mem parentBand_measurable] with y hy hb + rw [hy,indicator_of_mem (show y∈centralPhysical from parentBand_central hb)] + exact lpZeroExtensionCLM_ae_of_ae parentBand_measurable _ hb + +lemma central_parent_trace_eq (s : Fin 3 → ℝ) (f : centralSmoothFunctions) : + smoothCollarTrace s centralThickness ((central_smooth f).comp sourcePairCLE.contDiff)= + centralSmoothTrace s f 0 := by + apply spectralTraceGraph_fst_injective (torusRate s) + change (smoothCollarTrace s centralThickness ((central_smooth f).comp sourcePairCLE.contDiff)).val 0 = + (centralSmoothTrace s f 0).val 0 + rw [centralSmoothTrace_fst] + ext h + rw [smoothCollarTrace_fst, centralTraceFourier_apply] + rfl + +lemma central_parent_partial (f : centralSmoothFunctions) (i : Fin 3) (y : Fin 3 → ℝ) : + centralJetField f i.succ (sourcePairCoordinates y)= + fderiv ℝ (fun y => f (sourcePairCoordinates y)) y (Pi.single i 1) := by + rw [centralJetField_succ] + have he := (((central_smooth f).differentiable (by simp) _).hasFDerivAt.comp y sourcePairCLE.hasFDerivAt).fderiv + change fderiv ℝ f (sourcePairCLE y) (centralDirection i) = + fderiv ℝ (f ∘ sourcePairCLE) y (Pi.single i 1) + rw [he] + have hi : sourcePairCLE.toContinuousLinearMap (Pi.single i 1)=centralDirection i := by + fin_cases i <;> rfl + exact congrArg (fderiv ℝ f (sourcePairCoordinates y)) hi |>.symm + +lemma parentEndBand_measurable : MeasurableSet (sourceClosedCollarBand 0 centralThickness) := + (isCompact_sourceClosedCollarBand (by norm_num) (by norm_num [centralThickness])).measurableSet + +lemma parentEndTime_mem {a : ℝ} (ha : a<0) (t : ℝ) (ht : t∈Icc 0 centralThickness) : + affineEndTime a centralThickness t∈Icc 0 (-a*centralThickness) := by + have hδ : 0 (attachedEndPoissonField s f a centralThickness 0 y).re) := by + apply lpZeroExtensionCLM_ae_of_ae parentEndBand_measurable + have he := attachedEndFlatCLM_ae s hs f ha.ne + (show 0≤-a*centralThickness by exact mul_nonneg (neg_nonneg.mpr ha.le) (by norm_num [centralThickness])) + (show (0:ℝ)≤centralThickness by norm_num [centralThickness]) (by norm_num) (by norm_num [centralThickness]) + (parentEndTime_mem ha) 0 + apply (Complex.reCLM.coeFn_compLpL _).trans + filter_upwards [he] with y hy + exact congrArg Complex.re hy + +lemma parentEndGradientCLM_ae (f : spectralTraceGraph (torusRate s)) (i : Fin 3) : + parentEndGradientCLM s hs ha i f=ᵐ[volume] + (sourceClosedCollarBand 0 centralThickness).indicator + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a centralThickness 0 y).re) y (Pi.single i 1)) := by + apply lpZeroExtensionCLM_ae_of_ae parentEndBand_measurable + exact attachedEndGradientL_ae s hs ha.ne + (show 0≤-a*centralThickness by exact mul_nonneg (neg_nonneg.mpr ha.le) (by norm_num [centralThickness])) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num) (by norm_num [centralThickness]) (parentEndTime_mem ha) i f + +def parentJoinedComponentCLM (i : Fin 4) : CentralAmbient s →L[ℝ] + Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + parentCentralComponentCLM s i+ + ((Fin.cases (parentEndValueCLM s hs ha) (parentEndGradientCLM s hs ha) : + Fin 4 → spectralTraceGraph (torusRate s) →L[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ))) i).comp (centralAmbientT s 0) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParentComplementPartition.lean b/lean/OAI/Analysis/Conductivity/Branching/ParentComplementPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..2d1e4eb5ebd66dfb0b63af73446f5ef4565efab6 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParentComplementPartition.lean @@ -0,0 +1,186 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentCompletedEndJet +import OAI.Analysis.Conductivity.Variational.EndPartitionJet +import OAI.Analysis.Conductivity.Walls.CentralSeamCutoff + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem centralParent_complement_partition : + ∃ (r : ℝ) (η : (Fin 3 → ℝ) → ℝ),0 centralJoinPartition 1 z+η z)=ᶠ[𝓝 y] (fun _ => 1)) := by + let χ : (Fin 3 → ℝ) → ℝ := centralJoinPartition 1 + let q := fun y => 1-χ y + let K := sourceClosedCollarBand 0 centralThickness ∩ tsupport q + have hK : IsCompact K := + (isCompact_sourceClosedCollarBand (show -(1:ℝ)/100≤0 by norm_num) + (show centralThickness≤1/100 by norm_num [centralThickness])).inter_right (isClosed_tsupport q) + have hKt (y) (hy : y∈K) : sourceCollarTime y ⟨hz.1.le,hz.2.le⟩) + obtain ⟨ψ,hψ1,hψ0,hψb⟩ := exists_contMDiffMap_one_nhds_of_subset_interior + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) hK.isClosed hi (n:=↑(⊤:ℕ∞)) + have hψc : HasCompactSupport ψ := HasCompactSupport.intro hbig hψ0 + have hψs : tsupport ψ⊆sourceClosedCollarBand (-centralThickness/2) r := by + apply closure_minimal _ hbig.isClosed + intro y hy + by_contra hn + exact hy (hψ0 y hn) + let η := fun y => q y*ψ y + have hηs : tsupport η⊆sourceClosedCollarBand (-centralThickness/2) r := + tsupport_mul_subset_right.trans hψs + refine ⟨r,η,hr₀,hr,(contDiff_const.sub (centralJoinPartition_smooth 1)).mul ψ.contMDiff.contDiff, + hψc.mul_left,?_,hηs,?_,?_⟩ + · intro y + have h₀ := centralJoinPartition.nonneg 1 y + have h₁ := centralJoinPartition.le_one 1 y + have h₂ := (hψb y).1 + have h₃ := (hψb y).2 + dsimp only [η,q,χ] + rw [abs_of_nonneg (mul_nonneg (sub_nonneg.mpr h₁) h₂)] + nlinarith [mul_nonneg h₀ h₂] + · intro y hy + apply notMem_tsupport_iff_eventuallyEq.mp + intro hn + have hle := (hηs hn).2 + have hge := ((centralPhysical_time_iff y).mp hy).1 + linarith + · intro y hy + by_cases hk : y∈K + · have hψ := hψ1.filter_mono (nhds_le_nhdsSet hk) + filter_upwards [hψ] with z hz + change centralJoinPartition 1 z+((1-centralJoinPartition 1 z)*ψ z)=1 + rw [hz] + ring + · have hq : y∉tsupport q := fun hn => hk ⟨hy,hn⟩ + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hq] with z hz + change q z=0 at hz + change χ z+q z*ψ z=1 + rw [hz,zero_mul,add_zero] + dsimp only [q] at hz + linarith + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem parentAttachedCorrection_exists (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) (κ : ℝ) (p : centralEnergySpace s) : + ∃ d : H1,d∈H10 ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈centralPhysical → + weakValue d x=0 ∧ ∀ i,weakGradient d x i=0) ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + weakValue (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p+d) x= + fullAttachedEndValue s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) ∧ + ∀ i,weakGradient (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p+d) x i= + fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) i) := by + obtain ⟨r,η,hr₀,hr,hη,hηc,hηb,hηs,hηzero,hpart⟩ := centralParent_complement_partition + obtain ⟨v,hv,hve⟩ := compact_collar_slope_value_gradient (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) ha.ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + κ 0 (2*centralThickness) (by norm_num) (by norm_num [centralThickness]) centralJoinPartition_parent_support + have hR : 0≤-a*(3*centralThickness/2) := + mul_nonneg (neg_nonneg.mpr ha.le) (by norm_num [centralThickness]) + have hT : ∀ t∈Icc (-centralThickness/2) r, + affineEndTime a centralThickness t∈Icc 0 (-a*(3*centralThickness/2)) := by + intro t ht + dsimp only [affineEndTime] + constructor + · exact mul_nonneg_of_nonpos_of_nonpos ha.le (sub_nonpos.mpr (ht.2.trans hr.le)) + · have hm := mul_nonpos_of_nonpos_of_nonneg ha.le (sub_nonneg.mpr ht.1) + nlinarith + have hpos : ∀ t∈Icc (-centralThickness/2) r,0 mul_pos_of_neg_of_neg ha (sub_neg.mpr (ht.2.trans_lt hr)) + obtain ⟨z,hz,hze⟩ := cut_fullAttachedEnd_H10 s hs (centralT s 0 p) κ ha.ne hR + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + (show -centralThickness/2≤r by + have ht : (0:ℝ) not_le_of_gt ht hh.1) _ + +lemma parentJoinedComponentCLM_end_value (u : CentralAmbient s) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand 0 centralThickness → + parentJoinedComponentCLM s hs ha 0 u y= + (attachedEndPoissonField s (centralAmbientT s 0 u) a centralThickness 0 y).re := by + have hadd := Lp.coeFn_add (parentCentralComponentCLM s 0 u) + (parentEndValueCLM s hs ha (centralAmbientT s 0 u)) + filter_upwards [hadd,parentCentralComponentCLM_zero_end s u 0, + parentEndValueCLM_ae s hs ha (centralAmbientT s 0 u), + sourceColevel_ae_ne (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness])] with y hy hc he hn hb + change (parentCentralComponentCLM s 0 u+parentEndValueCLM s hs ha (centralAmbientT s 0 u)) y=_ + rw [hy] + simp only [Pi.add_apply,hc (lt_of_le_of_ne hb.2 hn),he,indicator_of_mem hb,zero_add] + +lemma parentJoinedComponentCLM_end_gradient (u : CentralAmbient s) (i : Fin 3) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand 0 centralThickness → + parentJoinedComponentCLM s hs ha i.succ u y= + fderiv ℝ (fun y => (attachedEndPoissonField s (centralAmbientT s 0 u) + a centralThickness 0 y).re) y (Pi.single i 1) := by + have hadd := Lp.coeFn_add (parentCentralComponentCLM s i.succ u) + (parentEndGradientCLM s hs ha i (centralAmbientT s 0 u)) + filter_upwards [hadd,parentCentralComponentCLM_zero_end s u i.succ, + parentEndGradientCLM_ae s hs ha (centralAmbientT s 0 u) i, + sourceColevel_ae_ne (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness])] with y hy hc he hn hb + change (parentCentralComponentCLM s i.succ u+parentEndGradientCLM s hs ha i (centralAmbientT s 0 u)) y=_ + rw [hy] + simp only [Pi.add_apply,hc (lt_of_le_of_ne hb.2 hn),he,indicator_of_mem hb,zero_add] + +variable {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) + +lemma parentLocalComponentCLM_end_value (u : CentralAmbient s) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand 0 centralThickness → + parentLocalComponentCLM s hs ha hχ hc 0 u y= + χ y*(attachedEndPoissonField s (centralAmbientT s 0 u) a centralThickness 0 y).re := by + filter_upwards [compactMultiplierCLM_ae hχ.continuous hc + (parentJoinedComponentCLM s hs ha 0 u), + parentJoinedComponentCLM_end_value s hs ha u] with y he hv hb + exact he.trans (congrArg (fun z => χ y*z) (hv hb)) + +lemma parentLocalComponentCLM_end_gradient (u : CentralAmbient s) (i : Fin 3) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand 0 centralThickness → + parentLocalComponentCLM s hs ha hχ hc i.succ u y= + fderiv ℝ χ y (Pi.single i 1)* + (attachedEndPoissonField s (centralAmbientT s 0 u) a centralThickness 0 y).re+ + χ y*fderiv ℝ (fun y => (attachedEndPoissonField s (centralAmbientT s 0 u) + a centralThickness 0 y).re) y (Pi.single i 1) := by + have h₀ := compactMultiplierCLM_ae + ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (parentJoinedComponentCLM s hs ha 0 u) + have h₁ := compactMultiplierCLM_ae hχ.continuous hc + (parentJoinedComponentCLM s hs ha i.succ u) + have hadd := Lp.coeFn_add + (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (parentJoinedComponentCLM s hs ha 0 u)) + (compactMultiplierCLM hχ.continuous hc (parentJoinedComponentCLM s hs ha i.succ u)) + filter_upwards [hadd,h₀,h₁,parentJoinedComponentCLM_end_value s hs ha u, + parentJoinedComponentCLM_end_gradient s hs ha u i] with y he h₀ h₁ hv hg hb + apply he.trans + simp only [Pi.add_apply,h₀,h₁,hv hb,hg hb] + +theorem parentCompletionJoin_end_ae (hχb : ∀ x,|χ x|≤1) + (hχs : tsupport χ⊆sourceClosedCollarBand 0 (2*centralThickness)) + (p : centralEnergySpace s) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + weakValue (parentCompletionJoin s hs ha hχ hc hχb hχs p) x= + χ (WithLp.ofLp x)*(attachedEndPoissonField s (centralT s 0 p) + a centralThickness 0 (WithLp.ofLp x)).re ∧ + ∀ i,weakGradient (parentCompletionJoin s hs ha hχ hc hχb hχs p) x i= + fderiv ℝ χ (WithLp.ofLp x) (Pi.single i 1)* + (attachedEndPoissonField s (centralT s 0 p) a centralThickness 0 (WithLp.ofLp x)).re+ + χ (WithLp.ofLp x)*fderiv ℝ (fun y => + (attachedEndPoissonField s (centralT s 0 p) a centralThickness 0 y).re) + (WithLp.ofLp x) (Pi.single i 1) := by + have h₀ := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (parentLocalComponentCLM_end_value s hs ha hχ hc p.val)) + have h₁ (i : Fin 3) := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (parentLocalComponentCLM_end_gradient s hs ha hχ hc p.val i)) + have hjet := physicalFourJetCLM_ae + (fun i => parentLocalComponentCLM s hs ha hχ hc i p.val) + filter_upwards [hjet,h₀,ae_all_iff.mpr h₁] with x hj hv hg hb + constructor + · change WithLp.ofLp ((parentLocalJetCLM s hs ha hχ hc p.val) x) 0=_ + exact (congrArg (fun z : JetFiber => WithLp.ofLp z 0) hj).trans (hv hb) + · intro i + change WithLp.ofLp ((parentLocalJetCLM s hs ha hχ hc p.val) x) i.succ=_ + exact (congrArg (fun z : JetFiber => WithLp.ofLp z i.succ) hj).trans (hg i hb) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParentEndPartition.lean b/lean/OAI/Analysis/Conductivity/Branching/ParentEndPartition.lean new file mode 100644 index 0000000000000000000000000000000000000000..bb1d903afd423b94792339bf788140d7bb9f1b30 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParentEndPartition.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalEndLocalLipschitz +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarBand + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma exists_nonneg_band_cutoff {l₀ l r r₀ : ℝ} (hl : l₀ 1)) := by + have hbig := isCompact_sourceClosedCollarBand hl₀ hr₀ + have hsmall := isCompact_sourceClosedCollarBand (hl₀.trans hl.le) (hr.le.trans hr₀) + have hi : sourceClosedCollarBand l r⊆interior (sourceClosedCollarBand l₀ r₀) := by + intro x hx + apply mem_interior_iff_mem_nhds.mpr + have hm := locallyLipschitz_sourceCollarTime.continuous.continuousAt + (isOpen_Ioo.mem_nhds (show sourceCollarTime x∈Ioo l₀ r₀ from + ⟨hl.trans_le hx.1,hx.2.trans_lt hr⟩)) + exact mem_of_superset hm (fun y hy => ⟨hy.1.le,hy.2.le⟩) + obtain ⟨χ,hχ1,hχ0,hχb⟩ := exists_contMDiffMap_one_nhds_of_subset_interior + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) hsmall.isClosed hi (n:=↑(⊤:ℕ∞)) + refine ⟨χ,χ.contMDiff.contDiff,HasCompactSupport.intro hbig hχ0,hχb,?_,?_⟩ + · apply closure_minimal _ hbig.isClosed + intro x hx + by_contra hn + exact hx (hχ0 x hn) + · intro x hx + exact hχ1.filter_mono (nhds_le_nhdsSet hx) + +theorem parent_end_partition_exists : + ∃ χ η : (Fin 3 → ℝ) → ℝ, + ContDiff ℝ (↑(⊤:ℕ∞)) χ ∧ HasCompactSupport χ ∧ + (∀ x,|χ x|≤1) ∧ tsupport χ⊆sourceClosedCollarBand 0 (2*centralThickness) ∧ + ContDiff ℝ (↑(⊤:ℕ∞)) η ∧ HasCompactSupport η ∧ + (∀ x,|η x|≤1) ∧ tsupport η⊆sourceClosedCollarBand + (-centralThickness/2) (3*centralThickness/4) ∧ + (∀ x∈sourceClosedCollarBand 0 centralThickness, + (fun y => χ y+η y)=ᶠ[𝓝 x] (fun _ => 1)) := by + obtain ⟨χ,hχ,hχc,hχb,hχs,hχ1⟩ := exists_nonneg_band_cutoff + (l₀:=centralThickness/4) (l:=centralThickness/2) + (r:=3*centralThickness/2) (r₀:=7*centralThickness/4) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + obtain ⟨ψ,hψ,hψc,hψb,hψs,hψ1⟩ := exists_nonneg_band_cutoff + (l₀ := -centralThickness/2) (l := -centralThickness/4) + (r:=centralThickness/2) (r₀:=3*centralThickness/4) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + let η := fun x => (1-χ x)*ψ x + have hη : ContDiff ℝ (↑(⊤:ℕ∞)) η := (contDiff_const.sub hχ).mul hψ + have hηc : HasCompactSupport η := hψc.mul_left + refine ⟨χ,η,hχ,hχc,?_,?_,hη,hηc,?_,?_,?_⟩ + · intro x + rw [abs_of_nonneg (hχb x).1] + exact (hχb x).2 + · intro x hx + have hb := hχs hx + constructor <;> dsimp [centralThickness] at * <;> linarith [hb.1,hb.2] + · intro x + have h₀ := (hχb x).1 + have h₁ := (hχb x).2 + have h₂ := (hψb x).1 + have h₃ := (hψb x).2 + dsimp only [η] + rw [abs_of_nonneg (mul_nonneg (sub_nonneg.mpr h₁) h₂)] + nlinarith [mul_nonneg h₀ h₂] + · exact tsupport_mul_subset_right.trans hψs + · intro x hx + by_cases ht : sourceCollarTime x≤centralThickness/2 + · have hm : x∈sourceClosedCollarBand (-centralThickness/4) (centralThickness/2) := + ⟨(by dsimp [centralThickness]; linarith [hx.1]),ht⟩ + filter_upwards [hψ1 x hm] with y hy + simp only [η,hy,mul_one] + ring + · have hm : x∈sourceClosedCollarBand (centralThickness/2) (3*centralThickness/2) := + ⟨(lt_of_not_ge ht).le,(by dsimp [centralThickness] at *; linarith [hx.2])⟩ + filter_upwards [hχ1 x hm] with y hy + simp [η,hy] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParentFullEndEnergy.lean b/lean/OAI/Analysis/Conductivity/Branching/ParentFullEndEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..50e7daac928ac3172c5c19694581f5c241f19ef4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParentFullEndEnergy.lean @@ -0,0 +1,186 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.FullEndClosedEnergy + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +theorem parentFullEnd_weak_energy_exists (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) (κ : ℝ) (p : centralEnergySpace s) : + ∃ w : H1,w∈H10 ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + weakValue w x=fullAttachedEndValue s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) ∧ + ∀ k,weakGradient w x k=fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) k) ∧ + (∀ (ψ : H1) (i j : Fin 4), + Integrable (fun y => originalPiGradient w y ⬝ᵥ + (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y)) + (volume.restrict (sourceCollarPiece i j '' sourceExtendedBox 0 centralThickness)) ∧ + (∫ y in sourceCollarPiece i j '' sourceExtendedBox 0 centralThickness, + originalPiGradient w y ⬝ᵥ (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y))= + ∫ x in sourceExtendedBox 0 centralThickness, + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (fullEndFlatCovector s (centralT s 0 p) κ (a*(x 0-centralThickness)) + (torusAngles (sourceFaceAngles i j x)) ⬝ᵥ + (flatCylinderMatrix s*ᵥ((attachedCartesianMatrix a i j x)⁻¹*ᵥ + originalPiGradient ψ (sourceCollarPiece i j x))))) := by + obtain ⟨w,hw,he⟩ := parentFullEnd_H10 s hs ha κ p + have hlow : -(1:ℝ)/100≤0 := by norm_num + have hupp : centralThickness≤(1:ℝ)/100 := by norm_num [centralThickness] + have hband : sourceClosedCollarBand 0 centralThickness⊆ + sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := + fun _ hy => ⟨hlow.trans hy.1,hy.2.trans hupp⟩ + have hjet := originalPiGradient_eq_on hband w + (fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ) + (by filter_upwards [he] with x hx hm; exact (hx hm).2) + refine ⟨w,hw,he,fun ψ i j => ⟨?_,?_⟩⟩ + · exact attachedCollarTensor_weak_integrable s ha.ne + (sourceCollarClosedPiece_measurable 0 centralThickness i j) + ((sourceCollarClosedPiece_subset hlow hupp i j).trans hband) w ψ + · calc + _ = ∫ y in sourceCollarPiece i j '' sourceExtendedBox 0 centralThickness, + fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ y ⬝ᵥ + (attachedCollarTensor s a y*ᵥoriginalPiGradient ψ y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae hjet, + ae_restrict_mem (sourceCollarClosedPiece_measurable 0 centralThickness i j)] with y hy hm + rw [hy (sourceCollarClosedPiece_subset hlow hupp i j hm)] + _ = _ := fullAttachedEnd_vector_integral_open s hs (centralT s 0 p) κ + (originalPiGradient ψ) ha.ne i j hlow hupp + (fun t ht => mul_pos_of_neg_of_neg ha (sub_neg.mpr ht.2)) + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 not_le_of_gt ht hh.2) _ + +lemma childCentralComponentCLM_zero_end (k : Fin 2) (u : CentralAmbient s) (i : Fin 4) : + ∀ᵐ y∂volume,-centralThickness ?_) i + · exact childCentralRawComponentCLM_zero_end s k u 0 + · filter_upwards [childCentralRawComponentCLM_zero_end s k u (childAxis j).succ, + Lp.coeFn_smul sourceScale (childCentralRawComponentCLM s k (childAxis j).succ u)] with y hy he ht + change (sourceScale • childCentralRawComponentCLM s k (childAxis j).succ u) y=0 + rw [he] + simp only [Pi.smul_apply,smul_eq_mul,hy ht,mul_zero] + +lemma childJoinedComponentCLM_end_value (u : CentralAmbient s) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand (-centralThickness) 0 → + childJoinedComponentCLM s hs ha k 0 u y= + (attachedEndPoissonField s (centralAmbientT s k.succ u) a (-centralThickness) 0 y).re := by + have hadd := Lp.coeFn_add (childCentralComponentCLM s k 0 u) + (childEndValueCLM s hs ha (centralAmbientT s k.succ u)) + filter_upwards [hadd,childCentralComponentCLM_zero_end s k u 0, + childEndValueCLM_ae s hs ha (centralAmbientT s k.succ u), + sourceColevel_ae_ne (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness])] with y hy hc he hn hb + change (childCentralComponentCLM s k 0 u+childEndValueCLM s hs ha (centralAmbientT s k.succ u)) y=_ + rw [hy] + simp only [Pi.add_apply,hc (lt_of_le_of_ne hb.1 (Ne.symm hn)),he,indicator_of_mem hb,zero_add] + +lemma childJoinedComponentCLM_end_gradient (u : CentralAmbient s) (i : Fin 3) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand (-centralThickness) 0 → + childJoinedComponentCLM s hs ha k i.succ u y= + fderiv ℝ (fun y => (attachedEndPoissonField s (centralAmbientT s k.succ u) + a (-centralThickness) 0 y).re) y (Pi.single i 1) := by + have hadd := Lp.coeFn_add (childCentralComponentCLM s k i.succ u) + (childEndGradientCLM s hs ha i (centralAmbientT s k.succ u)) + filter_upwards [hadd,childCentralComponentCLM_zero_end s k u i.succ, + childEndGradientCLM_ae s hs ha (centralAmbientT s k.succ u) i, + sourceColevel_ae_ne (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by + norm_num [centralThickness])] with y hy hc he hn hb + change (childCentralComponentCLM s k i.succ u+childEndGradientCLM s hs ha i (centralAmbientT s k.succ u)) y=_ + rw [hy] + simp only [Pi.add_apply,hc (lt_of_le_of_ne hb.1 (Ne.symm hn)),he,indicator_of_mem hb,zero_add] + +variable {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) + +lemma childLocalComponentCLM_end_value (u : CentralAmbient s) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand (-centralThickness) 0 → + childLocalComponentCLM s hs ha k hχ hc 0 u y= + χ y*(attachedEndPoissonField s (centralAmbientT s k.succ u) a (-centralThickness) 0 y).re := by + filter_upwards [compactMultiplierCLM_ae hχ.continuous hc + (childJoinedComponentCLM s hs ha k 0 u), + childJoinedComponentCLM_end_value s hs ha k u] with y he hv hb + exact he.trans (congrArg (fun z => χ y*z) (hv hb)) + +lemma childLocalComponentCLM_end_gradient (u : CentralAmbient s) (i : Fin 3) : + ∀ᵐ y∂volume,y∈sourceClosedCollarBand (-centralThickness) 0 → + childLocalComponentCLM s hs ha k hχ hc i.succ u y= + fderiv ℝ χ y (Pi.single i 1)* + (attachedEndPoissonField s (centralAmbientT s k.succ u) a (-centralThickness) 0 y).re+ + χ y*fderiv ℝ (fun y => (attachedEndPoissonField s (centralAmbientT s k.succ u) + a (-centralThickness) 0 y).re) y (Pi.single i 1) := by + have h₀ := compactMultiplierCLM_ae + ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (childJoinedComponentCLM s hs ha k 0 u) + have h₁ := compactMultiplierCLM_ae hχ.continuous hc + (childJoinedComponentCLM s hs ha k i.succ u) + have hadd := Lp.coeFn_add + (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (childJoinedComponentCLM s hs ha k 0 u)) + (compactMultiplierCLM hχ.continuous hc (childJoinedComponentCLM s hs ha k i.succ u)) + filter_upwards [hadd,h₀,h₁,childJoinedComponentCLM_end_value s hs ha k u, + childJoinedComponentCLM_end_gradient s hs ha k u i] with y he h₀ h₁ hv hg hb + apply he.trans + simp only [Pi.add_apply,h₀,h₁,hv hb,hg hb] + +theorem childCompletionJoin_end_ae (hχb : ∀ x,|χ x|≤1) + (hχs : tsupport χ⊆sourceClosedCollarBand (-2*centralThickness) 0) + (p : centralEnergySpace s) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈sourceClosedCollarBand (-centralThickness) 0 → + weakValue (childCompletionJoin s hs ha k hχ hc hχb hχs p) x= + χ (WithLp.ofLp x)*(attachedEndPoissonField s (centralT s k.succ p) + a (-centralThickness) 0 (WithLp.ofLp x)).re ∧ + ∀ i,weakGradient (childCompletionJoin s hs ha k hχ hc hχb hχs p) x i= + fderiv ℝ χ (WithLp.ofLp x) (Pi.single i 1)* + (attachedEndPoissonField s (centralT s k.succ p) a (-centralThickness) 0 (WithLp.ofLp x)).re+ + χ (WithLp.ofLp x)*fderiv ℝ (fun y => + (attachedEndPoissonField s (centralT s k.succ p) a (-centralThickness) 0 y).re) + (WithLp.ofLp x) (Pi.single i 1) := by + have h₀ := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (childLocalComponentCLM_end_value s hs ha k hχ hc p.val)) + have h₁ (i : Fin 3) := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (childLocalComponentCLM_end_gradient s hs ha k hχ hc p.val i)) + have hjet := physicalFourJetCLM_ae + (fun i => childLocalComponentCLM s hs ha k hχ hc i p.val) + filter_upwards [hjet,h₀,ae_all_iff.mpr h₁] with x hj hv hg hb + constructor + · change WithLp.ofLp ((childLocalJetCLM s hs ha k hχ hc p.val) x) 0=_ + exact (congrArg (fun z : JetFiber => WithLp.ofLp z 0) hj).trans (hv hb) + · intro i + change WithLp.ofLp ((childLocalJetCLM s hs ha k hχ hc p.val) x) i.succ=_ + exact (congrArg (fun z : JetFiber => WithLp.ofLp z i.succ) hj).trans (hg i hb) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/ParentLocalizedJet.lean b/lean/OAI/Analysis/Conductivity/Branching/ParentLocalizedJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..70b31416ac1d33f2dc5fe2a9075993b8eb334531 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/ParentLocalizedJet.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.LocalJoinedH1 +import OAI.Analysis.Conductivity.Sobolev.LpFourJet +import OAI.Analysis.Conductivity.Branching.ParentCentralL2 + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology + +lemma parent_band_indicator_join {a : ℝ} (ha : a<0) (y : Fin 3 → ℝ) + (hy : y∈sourceClosedCollarBand 0 (2*centralThickness)) + (hne : sourceCollarTime y≠centralThickness) (q p : (Fin 3 → ℝ) → ℝ) : + (sourceClosedCollarBand centralThickness (2*centralThickness)).indicator q y+ + (sourceClosedCollarBand 0 centralThickness).indicator p y= + if 0 not_le_of_gt ht h.1 + have he : y∈sourceClosedCollarBand 0 centralThickness := ⟨hy.1,ht.le⟩ + simp [hc,he,hp] + · have hp : ¬0 not_le_of_gt ht h.2 + simp [hc,he,hp] + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) + {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + +def parentLocalComponentCLM (i : Fin 4) : CentralAmbient s →L[ℝ] + Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + Fin.cases ((compactMultiplierCLM hχ.continuous hc).comp (parentJoinedComponentCLM s hs ha 0)) + (fun j => ((compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single j 1))).comp (parentJoinedComponentCLM s hs ha 0))+ + ((compactMultiplierCLM hχ.continuous hc).comp (parentJoinedComponentCLM s hs ha j.succ))) i + +def physicalFourJetCLM : (Fin 4 → Lp ℝ 2 (volume : Measure (Fin 3 → ℝ))) →L[ℝ] JetSpace := + (lpRestrictionCLM ball).comp + (((Lp.compMeasurePreservingₗᵢ ℝ ((PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).toHomeomorph.toMeasurableEquiv) + (PiLp.volume_preserving_ofLp (Fin 3))).toContinuousLinearMap).comp (lpFourJetCLM volume)) + +lemma physicalFourJetCLM_ae (f : Fin 4 → Lp ℝ 2 (volume : Measure (Fin 3 → ℝ))) : + physicalFourJetCLM f=ᵐ[ballMeasure] (fun x => WithLp.toLp 2 (fun i => f i (WithLp.ofLp x))) := by + apply (lpRestrictionCLM_ae ball _).trans + apply ae_restrict_of_ae + apply (Lp.coeFn_compMeasurePreserving _ (PiLp.volume_preserving_ofLp (Fin 3))).trans + exact (PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp (lpFourJetCLM_ae volume f) + +def parentLocalJetCLM : CentralAmbient s →L[ℝ] JetSpace := + physicalFourJetCLM.comp (ContinuousLinearMap.pi (parentLocalComponentCLM s hs ha hχ hc)) + +end + +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) + {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + (hχs : tsupport χ⊆sourceClosedCollarBand 0 (2*centralThickness)) + +lemma parentJoinedComponentCLM_smooth_value (f : centralSmoothFunctions) : + parentJoinedComponentCLM s hs ha 0 (centralEmbedL s f)=ᵐ[volume] (fun y => + (sourceClosedCollarBand centralThickness (2*centralThickness)).indicator + (fun y => f (sourcePairCoordinates y)) y+ + (sourceClosedCollarBand 0 centralThickness).indicator + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) y) := by + apply (Lp.coeFn_add _ _).trans + filter_upwards [parentCentralComponentCLM_smooth_ae s f 0,parentEndValueCLM_ae s hs ha (centralSmoothTrace s f 0)] with y hy hz + change (parentCentralComponentCLM s 0 (centralEmbedL s f)) y+ + (parentEndValueCLM s hs ha (centralSmoothTrace s f 0)) y=_ + rw [hy,hz] + rfl + +lemma parentJoinedComponentCLM_smooth_gradient (f : centralSmoothFunctions) (i : Fin 3) : + parentJoinedComponentCLM s hs ha i.succ (centralEmbedL s f)=ᵐ[volume] (fun y => + (sourceClosedCollarBand centralThickness (2*centralThickness)).indicator + (fun y => fderiv ℝ (fun y => f (sourcePairCoordinates y)) y (Pi.single i 1)) y+ + (sourceClosedCollarBand 0 centralThickness).indicator + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) y (Pi.single i 1)) y) := by + apply (Lp.coeFn_add _ _).trans + filter_upwards [parentCentralComponentCLM_smooth_ae s f i.succ,parentEndGradientCLM_ae s hs ha (centralSmoothTrace s f 0) i] with y hy hz + change (parentCentralComponentCLM s i.succ (centralEmbedL s f)) y+ + (parentEndGradientCLM s hs ha i (centralSmoothTrace s f 0)) y=_ + rw [hy,hz] + simp only [central_parent_partial] + +include hχs in +lemma parentLocalComponentCLM_smooth_value (f : centralSmoothFunctions) : + parentLocalComponentCLM s hs ha hχ hc 0 (centralEmbedL s f)=ᵐ[volume] + localJoinedValue (fun y => a*(sourceCollarTime y-centralThickness)) χ + (fun y => f (sourcePairCoordinates y)) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) := by + have he := compactMultiplierCLM_ae hχ.continuous hc (parentJoinedComponentCLM s hs ha 0 (centralEmbedL s f)) + filter_upwards [he,parentJoinedComponentCLM_smooth_value s hs ha f, + sourceColevel_ae_ne (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])] with y hy hv hn + simp only [parentLocalComponentCLM, Fin.cases_zero, ContinuousLinearMap.comp_apply, localJoinedValue] + rw [hy,hv] + by_cases hys : y∈tsupport χ + · rw [parent_band_indicator_join ha y (hχs hys) hn] + · rw [image_eq_zero_of_notMem_tsupport hys] + simp + +include hχs in +lemma parentLocalComponentCLM_smooth_gradient (f : centralSmoothFunctions) (i : Fin 3) : + parentLocalComponentCLM s hs ha hχ hc i.succ (centralEmbedL s f)=ᵐ[volume] + localJoinedGradient (fun y => a*(sourceCollarTime y-centralThickness)) χ + (fun y => f (sourcePairCoordinates y)) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) i := by + have he₀ := compactMultiplierCLM_ae ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (parentJoinedComponentCLM s hs ha 0 (centralEmbedL s f)) + have he₁ := compactMultiplierCLM_ae hχ.continuous hc (parentJoinedComponentCLM s hs ha i.succ (centralEmbedL s f)) + apply (Lp.coeFn_add _ _).trans + filter_upwards [he₀,he₁,parentJoinedComponentCLM_smooth_value s hs ha f, + parentJoinedComponentCLM_smooth_gradient s hs ha f i, + sourceColevel_ae_ne (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])] with y h₀ h₁ hv hg hn + change (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (parentJoinedComponentCLM s hs ha 0 (centralEmbedL s f))) y+ + (compactMultiplierCLM hχ.continuous hc (parentJoinedComponentCLM s hs ha i.succ (centralEmbedL s f))) y=_ + rw [h₀,h₁,hv,hg] + simp only [localJoinedGradient] + by_cases hys : y∈tsupport χ + · rw [parent_band_indicator_join ha y (hχs hys) hn, + parent_band_indicator_join ha y (hχs hys) hn] + · rw [image_eq_zero_of_notMem_tsupport hys,fderiv_of_notMem_tsupport ℝ hys] + simp + +include hχs in +lemma parentLocalJetCLM_smooth_ae (f : centralSmoothFunctions) : + parentLocalJetCLM s hs ha hχ hc (centralEmbedL s f)=ᵐ[ballMeasure] (fun x => + WithLp.toLp 2 (Fin.cases + (localJoinedValue (fun y => a*(sourceCollarTime y-centralThickness)) χ + (fun y => f (sourcePairCoordinates y)) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) (WithLp.ofLp x)) + (fun i => localJoinedGradient (fun y => a*(sourceCollarTime y-centralThickness)) χ + (fun y => f (sourcePairCoordinates y)) + (fun y => (attachedEndPoissonField s (centralSmoothTrace s f 0) a centralThickness 0 y).re) i (WithLp.ofLp x)))) := by + have h₀ := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (parentLocalComponentCLM_smooth_value s hs ha hχ hc hχs f)) + have h₁ (i : Fin 3) := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (parentLocalComponentCLM_smooth_gradient s hs ha hχ hc hχs f i)) + apply (physicalFourJetCLM_ae (fun i => parentLocalComponentCLM s hs ha hχ hc i (centralEmbedL s f))).trans + filter_upwards [h₀,ae_all_iff.mpr h₁] with x hv hg + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact hv + · exact hg j + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedAssembly.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedAssembly.lean new file mode 100644 index 0000000000000000000000000000000000000000..081d07b903b2fcc59c1655cb84cd9fc14944496b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedAssembly.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalChildAttachedCorrection +import OAI.Analysis.Conductivity.Branching.JoinedPhysicalEnds + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem physicalChildAttachedCorrection_supported (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 sourceBand_mem_ball ⟨ + (show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans hy.1, + hy.2.trans (by norm_num)⟩) + (fullAttachedEndValue s (centralT s k.succ p) a (-centralThickness) κ) + (fullAttachedEndGradient s (centralT s k.succ p) a (-centralThickness) κ) hde + have hsum : childH10Transport k ⟨u+d,H10.add_mem hu hd⟩= + physicalChildCompletionJoin s hs ha k (centralJoinChildCutoff_smooth k) + (centralJoinChildCutoff_compact k) (centralJoinChildCutoff_bound k) + (centralJoinChildCutoff_support k) p+childH10Transport k ⟨d,hd⟩ := by + rw [childH10Transport_add k u d hu hd] + exact congrArg (fun q : H1 => q+childH10Transport k ⟨d,hd⟩) + (physicalChildCompletionJoin_eq_transport s hs ha k p).symm + rw [hsum] at hh + exact hh + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def physicalJet (v : ℝ) (g : Fin 3 → ℝ) : JetFiber := WithLp.toLp 2 (Fin.cases v g) + +lemma weak_jet_eq_iff (u : H1) (x : R3) (v : ℝ) (g : Fin 3 → ℝ) : + u.val x=physicalJet v g ↔ weakValue u x=v ∧ ∀ i,weakGradient u x i=g i := by + constructor + · intro h + constructor + · exact congrArg (fun z : JetFiber => z 0) h + · intro i + exact congrArg (fun z : JetFiber => z i.succ) h + · rintro ⟨hv,hg⟩ + ext i + exact Fin.cases hv hg i + +lemma weak_jet_zero_iff (u : H1) (x : R3) : + u.val x=0 ↔ weakValue u x=0 ∧ ∀ i,weakGradient u x i=0 := by + have he : physicalJet 0 (fun _ => 0)=0 := by ext i; exact Fin.cases rfl (fun _ => rfl) i + rw [←he,weak_jet_eq_iff] + +def H1JetOn (u : H1) (D : Set (Fin 3 → ℝ)) (f : R3 → JetFiber) : Prop := + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈D → u.val x=f x + +lemma H1JetOn.mono {u : H1} {D E : Set (Fin 3 → ℝ)} {f : R3 → JetFiber} + (h : H1JetOn u D f) (hED : E⊆D) : H1JetOn u E f := by + filter_upwards [h] with x hx hy + exact hx (hED hy) + +lemma H1JetOn.add {u v : H1} {D : Set (Fin 3 → ℝ)} {f g : R3 → JetFiber} + (hu : H1JetOn u D f) (hv : H1JetOn v D g) : + H1JetOn (u+v) D (fun x => f x+g x) := by + filter_upwards [hu,hv,H1_add_jet_ae u v] with x hx hy he hm + rw [he,hx hm,hy hm] + +lemma H1JetOn.add_zero {u v : H1} {D : Set (Fin 3 → ℝ)} {f : R3 → JetFiber} + (hu : H1JetOn u D f) (hv : H1JetOn v D (fun _ => 0)) : H1JetOn (u+v) D f := by + simpa only [_root_.add_zero] using hu.add hv + +lemma H1JetOn.zero_add {u v : H1} {D : Set (Fin 3 → ℝ)} {f : R3 → JetFiber} + (hu : H1JetOn u D (fun _ => 0)) (hv : H1JetOn v D f) : H1JetOn (u+v) D f := by + simpa only [_root_.zero_add] using hu.add hv + +lemma H1JetOn.of_weak {u : H1} {D : Set (Fin 3 → ℝ)} {v : R3 → ℝ} + {g : R3 → Fin 3 → ℝ} + (h : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈D → weakValue u x=v x ∧ + ∀ i,weakGradient u x i=g x i) : H1JetOn u D (fun x => physicalJet (v x) (g x)) := by + filter_upwards [h] with x hx hm + exact (weak_jet_eq_iff u x _ _).mpr (hx hm) + +lemma H1JetOn.zero_of_weak {u : H1} {D : Set (Fin 3 → ℝ)} + (h : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈D → weakValue u x=0 ∧ + ∀ i,weakGradient u x i=0) : H1JetOn u D (fun _ => 0) := by + filter_upwards [h] with x hx hm + exact (weak_jet_zero_iff u x).mpr (hx hm) + +end ScalarConductivity +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedWeakPDE.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedWeakPDE.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b6465c2f90b32e78cd0e0b002f0f881dfce7004 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalAttachedWeakPDE.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalOpenBlock +import OAI.Analysis.Conductivity.Flux.AttachedPhysicalSmoothGreen + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix UnitAddTorus + +lemma smoothCollarTrace_eq_zero (s : Fin 3 → ℝ) (t : ℝ) + {φ : (Fin 3 → ℝ) → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + (hz : ∀ θ : UnitAddTorus (Fin 2),φ (sourceAngularCollar t θ)=0) : + smoothCollarTrace s t hφ=0 := by + apply spectralTraceGraph_fst_injective (torusRate s) + ext h + rw [smoothCollarTrace_fst] + simp [hz,Complex.ofReal_zero,mFourierCoeff] + +lemma physicalSmoothOuterTrace_compact_zero (s : Fin 3 → ℝ) + {φ : (Fin 3 → ℝ) → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + (hφs : tsupport φ⊆(WithLp.toLp 2) ⁻¹' sourceOpenBlock) (i : Fin 3) : + physicalSmoothOuterTrace s hφ i=0 := by + revert i + refine Fin.cases ?_ (fun k => ?_) + · apply smoothCollarTrace_eq_zero + intro θ + apply image_eq_zero_of_notMem_tsupport + intro h + have hb := (sourceOpenBlock_time_iff _).mp (hφs h) + rw [sourceAngular_time (by norm_num)] at hb + exact (lt_irrefl 0) hb.1 + · apply smoothCollarTrace_eq_zero + intro θ + change φ (sourceChildCoordinates (actualChildSign k) (sourceAngularCollar 0 θ))=0 + apply image_eq_zero_of_notMem_tsupport + intro h + have hb := ((sourceOpenBlock_time_iff _).mp (hφs h)).2 k + have he : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) (sourceAngularCollar 0 θ))= + sourceAngularCollar 0 θ := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply _ + rw [he,sourceAngular_time (by norm_num)] at hb + exact (lt_irrefl 0) hb + +lemma cylinderTerminalFlux_zero_test (s : Fin 3 → ℝ) (κ R : ℝ) + (p : spectralTraceGraph (torusRate s)) : cylinderTerminalFlux s κ R p 0=0 := by + simp [cylinderTerminalFlux] + +theorem physical_attached_weak_exists (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 physicalBlockRegion_subset_ball)),ae_restrict_mem physicalBlockRegion_compact.measurableSet] + with y hy hm + rw [hy hm] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergy.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..d25769610fbafb7a8b277dc0cab336fe4e923ff5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergy.lean @@ -0,0 +1,190 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalChildIntegral +import OAI.Analysis.Conductivity.Flux.PhysicalBlockTensor + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +lemma physicalBlockTensor_central_ae (s a : Fin 3 → ℝ) : + ∀ᵐ y∂(volume : Measure (Fin 3 → ℝ)),y∈centralPhysical → physicalBlockTensor s a y=1 := by + have hparent := sourceColevel_ae_ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + have hchild (k : Fin 2) := (sourceChildInverse_quasi (actualChildSign k)).ae + (sourceColevel_ae_ne + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])) + filter_upwards [hparent,hchild 0,hchild 1] with y hp hc₀ hc₁ hy + apply physicalBlockTensorList_outside + intro i _ hi + have ht := (centralPhysical_time_iff y).mp hy + have hn (k : Fin 2) : sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm y)≠-centralThickness := by + fin_cases k + · exact hc₀ + · exact hc₁ + fin_cases i + · change sourceCollarTime y∈Icc 0 centralThickness at hi + exact hp (le_antisymm hi.2 ht.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 0)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hn 0 (le_antisymm (ht.2 0) hi.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 1)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hn 1 (le_antisymm (ht.2 1) hi.1) + +lemma physicalBlockTensor_entry_memLp (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) (i j : Fin 3) : + MemLp (fun y => physicalBlockTensor s a y i j) ∞ + (volume : Measure (Fin 3 → ℝ)) := by + have h := physicalBlockTensor_properties s a hs ha + let heval : (Matrix (Fin 3) (Fin 3) ℝ) →L[ℝ] ℝ := + ((ContinuousLinearMap.proj j) : (Fin 3 → ℝ) →L[ℝ] ℝ).comp + ((ContinuousLinearMap.proj i) : Matrix (Fin 3) (Fin 3) ℝ →L[ℝ] (Fin 3 → ℝ)) + exact heval.comp_memLp' h.2.1 + +theorem physicalBlockTensor_weak_integrable (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) {D : Set (Fin 3 → ℝ)} (hD : MeasurableSet D) + (hb : ∀ y∈D,WithLp.toLp 2 y∈ball) (u v : H1) : + Integrable (fun y => originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y)) (volume.restrict D) := by + have hrow (i : Fin 3) : MemLp (fun y => ∑ j : Fin 3, + physicalBlockTensor s a y i j*originalPiGradient v y j) 2 (volume.restrict D) := by + apply memLp_finsetSum + intro j _ + exact ((physicalBlockTensor_entry_memLp s a hs ha i j).restrict D).mul (r := 2) + (originalPiGradient_memLp_on_ball hD hb v j) + change Integrable (fun y => ∑ i : Fin 3,originalPiGradient u y i* + ∑ j : Fin 3,physicalBlockTensor s a y i j*originalPiGradient v y j) _ + apply integrable_finsetSum + intro i _ + exact (originalPiGradient_memLp_on_ball hD hb u i).integrable_mul (hrow i) + +lemma physicalBlockTensor_end_energy (s a : Fin 3 → ℝ) (i : Fin 3) + {D : Set (Fin 3 → ℝ)} (hD : MeasurableSet D) (hsub : D⊆physicalEndRegion i) + (u v : H1) : + (∫ y in D,originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y))= + ∫ y in D,originalPiGradient u y ⬝ᵥ + (physicalEndTensor s a i y*ᵥoriginalPiGradient v y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_mem hD] with y hy + rw [physicalBlockTensor_local s a i (hsub hy)] + +lemma physicalBlockTensor_central_energy (s a : Fin 3 → ℝ) (u v : H1) : + (∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y))= + ∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ originalPiGradient v y := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae (physicalBlockTensor_central_ae s a), + ae_restrict_mem centralPhysical_compact.measurableSet] with y he hy + rw [he hy,Matrix.one_mulVec] + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def physicalBlockRegion : Set (Fin 3 → ℝ) := + centralPhysical ∪ ⋃ i : Fin 3,physicalEndRegion i + +lemma physicalBlockRegion_compact : IsCompact physicalBlockRegion := + centralPhysical_compact.union (isCompact_iUnion physicalEndRegion_compact) + +lemma physicalEndRegion_subset_ball (i : Fin 3) {y : Fin 3 → ℝ} + (hy : y∈physicalEndRegion i) : WithLp.toLp 2 y∈ball := by + revert hy + refine Fin.cases ?_ (fun k => ?_) i + · intro hy + exact sourceBand_mem_ball ⟨(show -(1:ℝ)/100≤0 by norm_num).trans hy.1, + hy.2.trans (by norm_num [centralThickness])⟩ + · intro hy + apply sourceChild_image_ball (D := sourceClosedCollarBand (-centralThickness) 0) k + (fun z hz => sourceBand_mem_ball + ⟨(show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans hz.1, + hz.2.trans (show (0:ℝ)≤1/100 by norm_num)⟩) y + exact ⟨(sourceChildHomeomorph (actualChildSign k)).symm y,hy, + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y⟩ + +lemma physicalBlockRegion_subset_ball {y : Fin 3 → ℝ} (hy : y∈physicalBlockRegion) : + WithLp.toLp 2 y∈ball := by + rcases hy with hc|he + · exact centralPhysical_subset_ball hc + · obtain ⟨i,hi⟩ := mem_iUnion.mp he + exact physicalEndRegion_subset_ball i hi + +lemma physicalEndRegion_mem_block (i : Fin 3) : physicalEndRegion i⊆physicalBlockRegion := + fun _ hy => Or.inr (mem_iUnion.mpr ⟨i,hy⟩) + +lemma physicalBlockRegion_central_end_exclusive_ae : + ∀ᵐ y∂(volume : Measure (Fin 3 → ℝ)), + y∈centralPhysical → ∀ i : Fin 3,y∉physicalEndRegion i := by + have hparent := sourceColevel_ae_ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + have hchild (k : Fin 2) := (sourceChildInverse_quasi (actualChildSign k)).ae + (sourceColevel_ae_ne + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])) + filter_upwards [hparent,hchild 0,hchild 1] with y hp hc₀ hc₁ hy i hi + have ht := (centralPhysical_time_iff y).mp hy + fin_cases i + · change sourceCollarTime y∈Icc 0 centralThickness at hi + exact hp (le_antisymm hi.2 ht.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 0)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hc₀ (le_antisymm (ht.2 0) hi.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 1)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hc₁ (le_antisymm (ht.2 1) hi.1) + +lemma physicalBlockRegion_indicator_ae (f : (Fin 3 → ℝ) → ℝ) : + physicalBlockRegion.indicator f=ᵐ[volume] + (fun y => centralPhysical.indicator f y+ + ∑ i : Fin 3,(physicalEndRegion i).indicator f y) := by + classical + filter_upwards [physicalBlockRegion_central_end_exclusive_ae] with y he + by_cases hc : y∈centralPhysical + · have hb : y∈physicalBlockRegion := Or.inl hc + rw [indicator_of_mem hb,indicator_of_mem hc] + have hsum : (∑ i : Fin 3,(physicalEndRegion i).indicator f y)=0 := by + apply Finset.sum_eq_zero + intro i _ + exact indicator_of_notMem (he hc i) _ + rw [hsum,add_zero] + · rw [indicator_of_notMem hc] + by_cases hend : ∃ i : Fin 3,y∈physicalEndRegion i + · obtain ⟨i,hi⟩ := hend + have hb : y∈physicalBlockRegion := physicalEndRegion_mem_block i hi + rw [indicator_of_mem hb,zero_add] + symm + calc + _ = (physicalEndRegion i).indicator f y := by + apply Finset.sum_eq_single i + · intro j _ hji + exact indicator_of_notMem (fun hj => + disjoint_left.mp (physicalEndRegion_pairwise_disjoint hji) hj hi) _ + · simp + _ = f y := indicator_of_mem hi f + · have hb : y∉physicalBlockRegion := by + rintro (hh|hh) + · exact hc hh + · exact hend (mem_iUnion.mp hh) + rw [indicator_of_notMem hb,zero_add] + symm + apply Finset.sum_eq_zero + intro i _ + exact indicator_of_notMem (fun hi => hend ⟨i,hi⟩) _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergySum.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergySum.lean new file mode 100644 index 0000000000000000000000000000000000000000..cdcbd549fc70a209b5e206f562e649f9c8d452c0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockEnergySum.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalBlockEnergy + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +lemma physicalBlockRegion_integral (f : (Fin 3 → ℝ) → ℝ) + (hc : IntegrableOn f centralPhysical volume) + (he : ∀ i : Fin 3,IntegrableOn f (physicalEndRegion i) volume) : + (∫ y in physicalBlockRegion,f y)=(∫ y in centralPhysical,f y)+ + ∑ i : Fin 3,∫ y in physicalEndRegion i,f y := by + have hci := hc.integrable_indicator centralPhysical_compact.measurableSet + have hei (i : Fin 3) := (he i).integrable_indicator (physicalEndRegion_compact i).measurableSet + rw [←integral_indicator physicalBlockRegion_compact.measurableSet] + rw [integral_congr_ae (physicalBlockRegion_indicator_ae f)] + rw [integral_add hci (integrable_finsetSum _ (fun i _ => hei i)), + integral_finsetSum _ (fun i _ => hei i), + integral_indicator centralPhysical_compact.measurableSet] + congr 1 + apply Finset.sum_congr rfl + intro i _ + exact integral_indicator (physicalEndRegion_compact i).measurableSet + +theorem physicalBlockTensor_energy_sum (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) (u v : H1) : + Integrable (fun y => originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y)) (volume.restrict physicalBlockRegion) ∧ + (∫ y in physicalBlockRegion,originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y))= + (∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ originalPiGradient v y)+ + ∑ i : Fin 3,∫ y in physicalEndRegion i,originalPiGradient u y ⬝ᵥ + (physicalEndTensor s a i y*ᵥoriginalPiGradient v y) := by + refine ⟨physicalBlockTensor_weak_integrable s a hs ha + physicalBlockRegion_compact.measurableSet (fun _ => physicalBlockRegion_subset_ball) u v,?_⟩ + rw [physicalBlockRegion_integral _ + (physicalBlockTensor_weak_integrable s a hs ha centralPhysical_compact.measurableSet + (fun _ => centralPhysical_subset_ball) u v) + (fun i => physicalBlockTensor_weak_integrable s a hs ha + (physicalEndRegion_compact i).measurableSet + (fun _ => physicalEndRegion_subset_ball i) u v), + physicalBlockTensor_central_energy] + congr 1 + apply Finset.sum_congr rfl + intro i _ + exact physicalBlockTensor_end_energy s a i (physicalEndRegion_compact i).measurableSet + Subset.rfl u v + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceExpandedInner_bounds {y : Fin 3 → ℝ} + (hy : -centralThickness ≤ sourceCollarTime y) : + |y 0|≤1602/1000 ∧ |y 1|≤1001/1000 ∧ |y 2|≤1002/1000 := by + have hh := (sourceCollarTime_ge_iff y (-centralThickness)).mp hy + have hx := (le_max_left (|y 0|/sourceLength) (|y 1|)).trans hh.2.2 + have hy' := (le_max_right (|y 0|/sourceLength) (|y 1|)).trans hh.2.2 + norm_num [centralThickness,sourceRadialWidth,sourceHole,sourceLength] at hx hy' hh ⊢ + exact ⟨by linarith,by linarith,by linarith [hh.1]⟩ + +lemma sourceExpandedChild_far_parent (k : Fin 2) {y : Fin 3 → ℝ} + (hy : -centralThickness ≤ sourceCollarTime y) : + 2*centralThickness ≤ sourceCollarTime (sourceChildCoordinates (actualChildSign k) y) := by + obtain ⟨h₀,h₁,h₂⟩ := sourceExpandedInner_bounds hy + have hsign : |actualChildSign k|=1 := by fin_cases k <;> norm_num [actualChildSign] + have ha : |actualChildSign k*sourceOffset|=sourceOffset := by + rw [abs_mul,hsign,one_mul]; norm_num [sourceOffset] + have hu := abs_add_le (sourceScale*y 1) (actualChildSign k*sourceOffset) + rw [abs_mul,abs_of_pos (show 0 fin_cases j + · exact hkj rfl + · exact sourceExpandedChildren_exclusive y hy hj + · exact sourceExpandedChildren_exclusive y hj hy + · exact hkj rfl + +theorem physicalBlockRegion_time_iff (y : Fin 3 → ℝ) : + y∈physicalBlockRegion ↔ 0≤ sourceCollarTime y ∧ + ∀ k : Fin 2,sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)≤0 := by + have hδ : 0 (hc k).trans (by linarith)⟩ + · obtain ⟨i,hi⟩ := mem_iUnion.mp he + revert hi + refine Fin.cases ?_ (fun k => ?_) i + · intro hi + change sourceCollarTime y∈Icc 0 centralThickness at hi + refine ⟨hi.1,fun k => ?_⟩ + by_contra hn + have hh := hfar k (show -centralThickness≤ sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm y) by linarith [lt_of_not_ge hn]) + linarith [hi.2] + · intro hi + change sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y) + ∈Icc (-centralThickness) 0 at hi + refine ⟨(by linarith [hfar k hi.1]),fun j => ?_⟩ + by_cases hkj : k=j + · simpa only [←hkj] using hi.2 + · exact (sourceExpandedChild_other k j hkj hi.1).le.trans (by linarith) + · rintro ⟨hp,hc⟩ + by_cases ht : sourceCollarTime y≤centralThickness + · exact physicalEndRegion_mem_block 0 ⟨hp,ht⟩ + · by_cases hh : ∀ k : Fin 2,sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm y)≤ -centralThickness + · exact Or.inl ((centralPhysical_time_iff y).mpr ⟨(lt_of_not_ge ht).le,hh⟩) + · push Not at hh + obtain ⟨k,hk⟩ := hh + exact physicalEndRegion_mem_block k.succ ⟨hk.le,hc k⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockRepresentative.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockRepresentative.lean new file mode 100644 index 0000000000000000000000000000000000000000..f788856801d50d979cc93f1534eae422d440e9c9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalBlockRepresentative.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalFiniteEndingData +import OAI.Analysis.Conductivity.Flux.PhysicalSplicedGreen +import OAI.Analysis.Conductivity.Variational.CentralCorrectedRepresentative +import OAI.Analysis.Conductivity.Variational.PhysicalEndOpen +import OAI.Analysis.Conductivity.Geometry.PhysicalRegionGluing + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise +local instance physicalBlockRepresentativeMeasurableSpace : MeasurableSpace Mat3 := inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance physicalBlockRepresentativeBorelSpace : BorelSpace Mat3 := inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +def cartesianTensor + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (y : Coord3) : Symmetric3 := + ⟨variableBlockTensor z.flatTensor z.compression y, + (variableBlockTensor_properties z.flatTensor z.compression (z.flatTensor_properties hs) z.compression_ne).2.2.1 y⟩ + +lemma cartesianTensor_measurable + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) : + Measurable (z.cartesianTensor hs) := by + change @Measurable Coord3 Symmetric3 _ (borel Symmetric3) (z.cartesianTensor hs) + rw [borel_comap, ← BorelSpace.measurable_eq (α := Mat3)] + exact ((variableBlockTensor_properties z.flatTensor z.compression (z.flatTensor_properties hs) z.compression_ne).1).subtype_mk + +theorem corrected_pair_representative + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (w : Fin 2 → H1) + (hwc : ∀ j,H1JetOn (w j) centralPhysical (centralFullJetCLM s (z.p j).val)) + (hwe : ∀ j i,H1JetOn (w j) (physicalEndRegion i) (z.correctedEndJet j i)) : + ∃ v : Coord3 → Fin 2 → ℝ, + (∀ᵐ y : Coord3,y∈physicalBlockRegion → v y=fun j => weakValue (w j) (WithLp.toLp 2 y)) ∧ + (∀ᵐ y : Coord3,y∈physicalBlockRegion → ∀ i : Fin 3,∀ j : Fin 2, + fderiv ℝ (fun x => v x j) y (Pi.single i 1)=weakGradient (w j) (WithLp.toLp 2 y) i) ∧ + volume (physicalBlockRegion \ regularRegion v (z.cartesianTensor hs) physicalBlockRegion)=0 := by + obtain ⟨u,hu,he,hr⟩ := z.central_representative hwc + let O : Option (Fin 3) → Set Coord3 := fun i => i.elim centralStrict physicalEndOpen + let g : Option (Fin 3) → Coord3 → Fin 2 → ℝ := fun i => i.elim u z.endRepresentative + have hO : ∀ i,IsOpen (O i) := by + intro i + cases i with + | none => exact centralStrict_open + | some i => exact physicalEndOpen_open i + have hOU : ∀ i,O i⊆physicalBlockRegion := by + intro i + cases i with + | none => exact fun _ hy => Or.inl (centralStrict_subset hy) + | some i => exact (physicalEndOpen_subset i).trans (physicalEndRegion_mem_block i) + have hc : ∀ᵐ y : Coord3,y∈physicalBlockRegion → y∈⋃ i,O i := by + filter_upwards [centralStrict_conull,ae_all_iff.mpr physicalEndOpen_conull] with y hcc hce hy + rcases hy with hc|he + · exact mem_iUnion.mpr ⟨none,hcc hc⟩ + · obtain ⟨i,hi⟩ := mem_iUnion.mp he + exact mem_iUnion.mpr ⟨some i,hce i hi⟩ + have hES (i : Fin 3) (y : Coord3) : (variableEndTensor z.flatTensor z.compression i y).IsSymm := + (variableEndTensor_properties z.flatTensor z.compression (z.flatTensor_properties hs) z.compression_ne i).2.1 y + have hreg : ∀ i,∀ᵐ y : Coord3,y∈O i → y∈regularRegion (g i) (z.cartesianTensor hs) (O i) := by + intro i + cases i with + | none => + filter_upwards [hr] with y hy hyO + apply mem_regularRegion_congr_nhds (hy hyO) Filter.EventuallyEq.rfl ?_ centralStrict_open hyO + filter_upwards [centralStrict_open.mem_nhds hyO] with x hx + exact Subtype.ext (variableBlockTensor_centralStrict z.flatTensor z.compression hx) + | some i => + filter_upwards [z.endRepresentative_regular hs hES i] with y hy hyO + apply mem_regularRegion_congr_nhds (hy (physicalEndOpen_subset i hyO)) Filter.EventuallyEq.rfl ?_ + (physicalEndOpen_open i) hyO + filter_upwards [(physicalEndOpen_open i).mem_nhds hyO] with x hx + exact Subtype.ext (variableBlockTensor_local z.flatTensor z.compression i (physicalEndOpen_subset i hx)) + have he' : ∀ i,(fun y j => weakValue (w j) (WithLp.toLp 2 y))=ᵐ[volume.restrict (O i)] g i := by + intro i + apply (ae_restrict_iff' (hO i).measurableSet).mpr + cases i with + | none => + filter_upwards [he] with y hy hyO + exact (hy hyO).symm + | some i => + have hv (j : Fin 2) := z.endRepresentative_value hs i j + have hw (j : Fin 2) := (hwe j i).value_cartesian (fun _ => physicalEndRegion_subset_ball i) + filter_upwards [ae_all_iff.mpr hv,ae_all_iff.mpr hw] with y hv hw hyO + funext j + exact (hw j (physicalEndOpen_subset i hyO)).trans (hv j (physicalEndOpen_subset i hyO)) + exact physical_region_glue O hO physicalBlockRegion_compact.measurableSet hOU + (fun _ => physicalBlockRegion_subset_ball) hc w g (z.cartesianTensor hs) hreg he' + +end PhysicalFiniteEndingData +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildAttachedCorrection.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildAttachedCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc249849fe5d128b91b9c5eb77be935839842f65 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildAttachedCorrection.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildFullEndH1 +import OAI.Analysis.Conductivity.Branching.ChildComplementPartition + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma childH10Transport_zero_on (k : Fin 2) (u : H10) (D : Set (Fin 3 → ℝ)) + (he : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈D → + weakValue u.val x=0 ∧ ∀ i,weakGradient u.val x i=0) : + ∀ᵐ x∂ballMeasure, + (sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x)∈D → + weakValue (childH10Transport k u) x=0 ∧ + ∀ i,weakGradient (childH10Transport k u) x i=0 := by + classical + let f : (Fin 3 → ℝ) → JetFiber := fun y => + if WithLp.toLp 2 y∈ball then u.val.val (WithLp.toLp 2 y) else 0 + have hj := childTransportJetCLM_ae_of_ae k u.val.val f + (ballWholePiJetCLM_ae_of_ae u.val.val + (fun y => u.val.val (WithLp.toLp 2 y)) (by filter_upwards [] with x; rfl)) + have he₀ := (ae_restrict_iff' (show MeasurableSet ball from + Metric.isOpen_ball.measurableSet)).mp he + have he₁ := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae he₀ + have he₂ := (sourceChildInverse_quasi (actualChildSign k)).ae he₁ + have he₃ := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae he₂) + filter_upwards [hj,he₃] with x hj hx hm + have hf : f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))=0 := by + dsimp only [f] + split_ifs with hb + · have hh := hx hb hm + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact hh.1 + · exact hh.2 j + · rfl + constructor + · change (childTransportJetCLM k u.val.val x) 0=0 + rw [hj] + change (f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))) 0=0 + rw [hf] + rfl + · intro i + change (childTransportJetCLM k u.val.val x) i.succ=0 + rw [hj] + change sourceScale⁻¹*(f ((sourceChildHomeomorph (actualChildSign k)).symm + (WithLp.ofLp x))) (childAxis i).succ=0 + rw [hf] + simp + +lemma childH10Transport_add (k : Fin 2) (u v : H1) (hu : u∈H10) (hv : v∈H10) : + childH10Transport k ⟨u+v,H10.add_mem hu hv⟩= + childH10Transport k ⟨u,hu⟩+childH10Transport k ⟨v,hv⟩ := by + apply Subtype.ext + change childTransportJetCLM k (u.val+v.val)= + childTransportJetCLM k u.val+childTransportJetCLM k v.val + exact map_add (childTransportJetCLM k) u.val v.val + +lemma physicalChildCompletionJoin_eq_transport (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 sourceBand_mem_ball ⟨ + (show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans hy.1, + hy.2.trans (by norm_num)⟩) + (fullAttachedEndValue s (centralT s k.succ p) a (-centralThickness) κ) + (fullAttachedEndGradient s (centralT s k.succ p) a (-centralThickness) κ) hde + have hsum : childH10Transport k ⟨u+d,H10.add_mem hu hd⟩= + physicalChildCompletionJoin s hs ha k (centralJoinChildCutoff_smooth k) + (centralJoinChildCutoff_compact k) (centralJoinChildCutoff_bound k) + (centralJoinChildCutoff_support k) p+childH10Transport k ⟨d,hd⟩ := by + rw [childH10Transport_add k u d hu hd] + exact congrArg (fun q : H1 => q+childH10Transport k ⟨d,hd⟩) + (physicalChildCompletionJoin_eq_transport s hs ha k p).symm + rw [hsum] at hh + exact hh + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildIntegral.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..d7c4cd1bac16baa938beba80e6cd3b4b15752ad6 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalChildIntegral.lean @@ -0,0 +1,202 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildFullEndH1 +import OAI.Analysis.Conductivity.Flux.PhysicalChildTensor + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +lemma sourceChild_integral (σ : ℝ) {D : Set (Fin 3 → ℝ)} + (hD : MeasurableSet D) (g : (Fin 3 → ℝ) → ℝ) : + (∫ y in sourceChildCoordinates σ '' D,g y)= + ∫ y in D,sourceScale^3*g (sourceChildCoordinates σ y) := by + have h := integral_image_eq_integral_abs_det_fderiv_smul volume hD + (fun x _ => (sourceChildCoordinates_hasFDeriv σ x).hasFDerivWithinAt) + (sourceChildHomeomorph σ).injective.injOn g + change (∫ y in sourceChildCoordinates σ '' D,g y)= + ∫ y in D,|sourceChildDerivative.det| • g (sourceChildCoordinates σ y) at h + simpa only [sourceChildDerivative_det,abs_neg,abs_pow, + abs_of_nonneg (show 0 ≤ sourceScale by norm_num [sourceScale]),smul_eq_mul] using h + +lemma originalPiGradient_memLp_on_ball {D : Set (Fin 3 → ℝ)} (hD : MeasurableSet D) + (hb : ∀ y∈D,WithLp.toLp 2 y∈ball) (u : H1) (k : Fin 3) : + MemLp (fun y => originalPiGradient u y k) 2 (volume.restrict D) := by + have he := ballWholePiComponentCLM_ae_of_ae k.succ u.val + (fun y => u.val (WithLp.toLp 2 y)) (by filter_upwards [] with x; rfl) + apply MemLp.ae_eq ?_ ((Lp.memLp (ballWholePiComponentCLM k.succ u.val)).restrict D) + filter_upwards [ae_restrict_of_ae he,ae_restrict_mem hD] with y hy hm + rw [hy,ite_eq_left (hb y hm)] + rfl + +lemma originalPiGradient_eq_on_ball {D : Set (Fin 3 → ℝ)} + (hb : ∀ y∈D,WithLp.toLp 2 y∈ball) (u : H1) + (G : (Fin 3 → ℝ) → (Fin 3 → ℝ)) + (he : ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈D → ∀ k, + weakGradient u x k=G (WithLp.ofLp x) k) : + ∀ᵐ y : Fin 3 → ℝ,y∈D → originalPiGradient u y=G y := by + have hh := (ae_restrict_iff' (show MeasurableSet ball from Metric.isOpen_ball.measurableSet)).mp he + have hp := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae hh + filter_upwards [hp] with y hy hm + ext k + exact hy (hb y hm) hm k + +lemma sourceChild_image_ball (k : Fin 2) {D : Set (Fin 3 → ℝ)} + (hb : ∀ y∈D,WithLp.toLp 2 y∈ball) : + ∀ y∈sourceChildCoordinates (actualChildSign k) '' D,WithLp.toLp 2 y∈ball := by + rintro _ ⟨y,hy,rfl⟩ + exact sourceChildEuclidean_ball k ⟨WithLp.toLp 2 y,hb y hy,rfl⟩ + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +lemma sourceChildTensorPush_entry_memLp (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (k : Fin 2) (i j : Fin 3) : + MemLp (fun y => sourceChildTensorPush k (attachedCollarTensor s a) y i j) ∞ + (volume : Measure (Fin 3 → ℝ)) := by + have hm := ((attachedCollarTensor_entry_memLp s ha (childAxis i) (childAxis j)).aestronglyMeasurable.comp_quasiMeasurePreserving + (sourceChildInverse_quasi (actualChildSign k))).const_mul sourceScale⁻¹ + obtain ⟨B,hB,h⟩ := attachedFaceTensorList_bounded s ha + (Finset.univ : Finset (Fin 4 × Fin 4)).toList + apply memLp_top_of_bound hm (|sourceScale⁻¹| * B) + apply ae_of_all + intro y + change ‖sourceScale⁻¹*attachedCollarTensor s a + ((sourceChildHomeomorph (actualChildSign k)).symm y) (childAxis i) (childAxis j)‖≤_ + rw [norm_mul,Real.norm_eq_abs] + apply mul_le_mul_of_nonneg_left _ (abs_nonneg _) + exact ((norm_le_pi_norm _ (childAxis j)).trans + (norm_le_pi_norm _ (childAxis i))).trans (h _) + +lemma sourceChildTensorPush_weak_integrable (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (k : Fin 2) {D : Set (Fin 3 → ℝ)} (hD : MeasurableSet D) + (hb : ∀ y∈D,WithLp.toLp 2 y∈ball) (u v : H1) : + Integrable (fun y => originalPiGradient u y ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s a) y*ᵥoriginalPiGradient v y)) + (volume.restrict D) := by + have hrow (i : Fin 3) : MemLp (fun y => ∑ j : Fin 3, + sourceChildTensorPush k (attachedCollarTensor s a) y i j*originalPiGradient v y j) + 2 (volume.restrict D) := by + apply memLp_finsetSum + intro j _ + exact ((sourceChildTensorPush_entry_memLp s ha k i j).restrict D).mul (r := 2) + (originalPiGradient_memLp_on_ball hD hb v j) + change Integrable (fun y => ∑ i : Fin 3,originalPiGradient u y i* + ∑ j : Fin 3,sourceChildTensorPush k (attachedCollarTensor s a) y i j* + originalPiGradient v y j) _ + apply integrable_finsetSum + intro i _ + exact (originalPiGradient_memLp_on_ball hD hb u i).integrable_mul (hrow i) + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +theorem physicalChildFullEnd_weak_energy_exists (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 originalPiGradient w y ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s a) y*ᵥoriginalPiGradient ψ y)) + (volume.restrict (sourceChildCoordinates (actualChildSign k) '' + (sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0))) ∧ + (∫ y in sourceChildCoordinates (actualChildSign k) '' + (sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0), + originalPiGradient w y ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s a) y*ᵥoriginalPiGradient ψ y))= + ∫ x in sourceExtendedBox (-centralThickness) 0, + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (fullEndFlatCovector s (centralT s k.succ p) κ (a*(x 0-(-centralThickness))) + (torusAngles (sourceFaceAngles i j x)) ⬝ᵥ + (flatCylinderMatrix s*ᵥ((attachedCartesianMatrix a i j x)⁻¹*ᵥ + (fun q => sourceScale*originalPiGradient ψ + (sourceChildCoordinates (actualChildSign k) (sourceCollarPiece i j x)) (childAxis q)))))) := by + obtain ⟨w,hw,he⟩ := physicalChildFullEnd_H10 s hs ha k κ p + have hlow : -(1:ℝ)/100≤-centralThickness := by norm_num [centralThickness] + have hupp : (0:ℝ)≤1/100 := by norm_num + have hb : ∀ y∈sourceClosedCollarBand (-centralThickness) 0,WithLp.toLp 2 y∈ball := by + intro y hy + exact sourceBand_mem_ball ⟨hlow.trans hy.1,hy.2.trans hupp⟩ + let D := (sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' + sourceClosedCollarBand (-centralThickness) 0 + have hDball : ∀ y∈D,WithLp.toLp 2 y∈ball := by + intro y hy + apply sourceChild_image_ball k hb y + exact ⟨(sourceChildHomeomorph (actualChildSign k)).symm y,hy, + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y⟩ + have hjet := originalPiGradient_eq_on_ball hDball w + (fun y q => sourceScale⁻¹*fullAttachedEndGradient s (centralT s k.succ p) + a (-centralThickness) κ ((sourceChildHomeomorph (actualChildSign k)).symm y) (childAxis q)) + (by filter_upwards [he] with x hx hm; exact (hx hm).2) + refine ⟨w,hw,he,fun ψ i j => ?_⟩ + let E := sourceCollarPiece i j '' sourceExtendedBox (-centralThickness) 0 + have hE : MeasurableSet E := sourceCollarClosedPiece_measurable _ _ i j + have hEsub := sourceCollarClosedPiece_subset hlow hupp i j + have hchild : MeasurableSet (sourceChildCoordinates (actualChildSign k) '' E) := + (((isCompact_Icc.image (sourceCollarPiece_contDiff i j).continuous).image + (sourceChildCoordinates_contDiff (actualChildSign k)).continuous)).measurableSet + constructor + · exact sourceChildTensorPush_weak_integrable s ha.ne' k hchild + (sourceChild_image_ball k (fun y hy => hb y (hEsub hy))) w ψ + · calc + _ = ∫ y in sourceChildCoordinates (actualChildSign k) '' E, + (fun q => sourceScale⁻¹*fullAttachedEndGradient s (centralT s k.succ p) + a (-centralThickness) κ ((sourceChildHomeomorph (actualChildSign k)).symm y) (childAxis q)) ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s a) y*ᵥoriginalPiGradient ψ y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae hjet,ae_restrict_mem hchild] with y hy hm + apply congrArg (fun v => v ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s a) y*ᵥoriginalPiGradient ψ y)) + apply hy + rcases hm with ⟨z,hz,rfl⟩ + change (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildHomeomorph (actualChildSign k) z)∈sourceClosedCollarBand (-centralThickness) 0 + rw [Homeomorph.symm_apply_apply] + exact hEsub hz + _ = ∫ y in E,fullAttachedEndGradient s (centralT s k.succ p) a (-centralThickness) κ y ⬝ᵥ + (attachedCollarTensor s a y*ᵥ(fun q => sourceScale* + originalPiGradient ψ (sourceChildCoordinates (actualChildSign k) y) (childAxis q))) := by + rw [sourceChild_integral (actualChildSign k) hE] + apply integral_congr_ae + apply ae_of_all + intro y + have hv : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)=y := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply y + dsimp only + rw [hv] + exact sourceChildTensorPush_mixed k (attachedCollarTensor s a) y _ _ + _ = _ := fullAttachedEnd_vector_integral_open s hs (centralT s k.succ p) κ + (fun y q => sourceScale*originalPiGradient ψ (sourceChildCoordinates (actualChildSign k) y) (childAxis q)) + ha.ne' i j hlow hupp (fun t ht => mul_pos ha (sub_pos.mpr ht.1)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalFiniteEndingData.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalFiniteEndingData.lean new file mode 100644 index 0000000000000000000000000000000000000000..08c02db7f96de05aa9e2534d13facfe1d978d940 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalFiniteEndingData.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalAttachedGreen +import OAI.Analysis.Conductivity.Branching.PhysicalRankTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus + +structure PhysicalFiniteEndingData (s : Fin 3 → ℝ) where + p : Fin 2 → centralEnergySpace s + mean_zero : ∀ j,centralM s (p j)=0 + variational : ∀ j,CentralVariationalEquation s (centralBasisSlopes j) (p j) + harmonic : ∀ j,WeaklyHarmonicOn + (centralWholeL2 (centralAmbientComponent s 0 (p j).val)) centralHarmonicRegion + ending : ∀ i : Fin 3,TorusEndingData s + (branchNormalize i (fun j => torusSpectralSynthesis s (centralT s i (p j)))) + +lemma physicalFiniteEndingData_nonempty {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (hres : ∀ h l : Fin 2 → ℤ,torusQuadratic s h=torusQuadratic s l → l=h ∨ l= -h) : + Nonempty (PhysicalFiniteEndingData s) := by + obtain ⟨p,hm,hv,hw,_⟩ := central_pair_regular_exists s + have he (i : Fin 3) := torusEndingData_nonempty hs hres + (branchNormalize i (fun j => torusSpectralSynthesis s (centralT s i (p j)))) + exact ⟨⟨p,hm,hv,hw,fun i => Classical.choice (he i)⟩⟩ + +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +def traces (i : Fin 3) (j : Fin 2) : TorusL2 := torusSpectralSynthesis s (centralT s i (z.p j)) + +def compression (i : Fin 3) : ℝ := + if i=0 then -((z.ending i).R+1)/centralThickness else ((z.ending i).R+1)/centralThickness + +lemma ending_R_pos (i : Fin 3) : 0<(z.ending i).R := by + linarith [(z.ending i).d_pos,(z.ending i).e_pos,(z.ending i).overlap_lt] + +lemma compression_parent : z.compression 0<0 := by + rw [compression,ite_eq_left rfl] + exact div_neg_of_neg_of_pos (neg_neg_of_pos (by linarith [z.ending_R_pos 0])) + (by norm_num [centralThickness]) + +lemma compression_child (k : Fin 2) : 0 (z.compression_child k).ne') i + +lemma end_length (i : Fin 3) : physicalEndLength z.compression i=(z.ending i).R+1 := by + unfold physicalEndLength compression + split_ifs <;> + rw [abs_div,abs_of_pos (show 0 centralT s i (z.p j)) v := by + have hu (j : Fin 2) := complete_physical_attachment s hs z.compression (centralBasisSlopes j) + z.compression_parent z.compression_child (z.p j) + choose u hu0 huc hue using hu + have hd (j : Fin 2) := triplePeriodicCorrection_exists + (fun i => branchCorrection i (z.ending i) j) + (fun i => branchCorrection_periodic i (z.ending i) j) + (fun i => (branchCorrection_C2 i (z.ending i) hs j).of_le (by norm_num)) + (fun i => (z.ending i).d) z.compression (fun i => (z.ending i).d_pos) + (fun i x hx => z.correction_initial_zero i j hx) z.compression_parent z.compression_child + choose d hd0 hdc hde using hd + refine ⟨u,fun j => u j+d j,fun j => ⟨hu0 j,H10.add_mem (hu0 j) (hd0 j)⟩, + fun j => ⟨huc j,(huc j).add_zero (hdc j)⟩, + fun j i => ⟨hue j i,(hue j i).add (hde j i)⟩,?_⟩ + intro j v + exact physical_block_green_extension s z.compression (centralBasisSlopes j) hs z.compression_ne + (fun i => centralT s i (z.p j)) (u j) + (fun _ hφ => attached_block_smooth_green s z.compression (centralBasisSlopes j) hs + z.compression_parent z.compression_child (z.p j) (z.variational j) (u j) (huc j) (hue j) hφ) v + +end PhysicalFiniteEndingData +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalFlatTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalFlatTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed2d7b4cd2d35186d86830f742a40ade510a391b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalFlatTransport.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalFlatEllipticity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma sourceCollarInverse_extended (i j : Fin 4) {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox l r) : + sourceCollarInverse i j (sourceCollarPiece i j x)=x := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + exact sourceCollarInverse_left_pos i j + (lt_of_lt_of_le (by norm_num : (0:ℝ)<1/50) + (sourceCollarRadius_extended j ⟨hl.trans ht.1,ht.2.trans hr⟩ hb).1) + (by linarith [ht.2]) ha hb + +def sourcePhysicalFlatTensor (s : Fin 3 → ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + sourceFlatTensor s i j (sourceCollarInverse i j y) + +def sourcePhysicalFlatGradient (i j : Fin 4) (v : (Fin 3 → ℝ) → Fin 3 → ℝ) + (y : Fin 3 → ℝ) : Fin 3 → ℝ := + sourceCartesianGradientMatrix i j (sourceCollarInverse i j y)*ᵥ + v (sourceCollarInverse i j y) + +theorem sourcePhysicalFlat_energy_integral (s : Fin 3 → ℝ) (i j : Fin 4) + {l r : ℝ} (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (v w : (Fin 3 → ℝ) → Fin 3 → ℝ) : + (∫ y in sourceCollarPiece i j '' sourceExtendedBox l r, + sourcePhysicalFlatGradient i j v y ⬝ᵥ + (sourcePhysicalFlatTensor s i j y*ᵥsourcePhysicalFlatGradient i j w y))= + ∫ x in sourceExtendedBox l r, + angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (v x ⬝ᵥ (flatCylinderMatrix s*ᵥw x)) := by + rw [sourceExtended_integral i j hl hr] + apply setIntegral_congr_fun measurableSet_Icc + intro x hx + have hx' : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100) := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + exact mem_sourceExtendedBox.mpr ⟨⟨hl.trans ht.1,ht.2.trans hr⟩,ha,hb⟩ + simp only [sourcePhysicalFlatGradient,sourcePhysicalFlatTensor, + sourceCollarInverse_extended i j hl hr hx,smul_eq_mul] + rw [sourceCollarDerivative_det,←sourceCollarJacobian_det] + exact sourceFlatTensor_energy_density s i j hx' (v x) (w x) + +lemma sourcePhysicalFlatTensor_symmetric (s : Fin 3 → ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : + (sourcePhysicalFlatTensor s i j y)ᵀ=sourcePhysicalFlatTensor s i j y := + sourceFlatTensor_symmetric s i j _ + +theorem sourcePhysicalFlatTensor_elliptic (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (i j : Fin 4) : + ∃ c C : ℝ,0 (physicalEndPoissonField s f 0 y).re) (sourceCollarPiece i j x) v= + sourcePhysicalFlatGradient i j + (fun x k => (endPoissonField s f k.succ + (x 0,torusAngles (sourceFaceAngles i j x))).re) (sourceCollarPiece i j x) ⬝ᵥ v := by + simp only [sourcePhysicalFlatGradient,sourceCollarInverse_point i j hx] + exact physicalEndPoisson_real_fderiv s hs f i j hx ht v + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalJoin.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ec9c3203e9449514dfaeb3f069fce7058864c75 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalJoin.lean @@ -0,0 +1,223 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalBlockEnergy +import OAI.Analysis.Conductivity.Branching.PhysicalChildAttachedCorrection + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma physical_localized_jet_zero + {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + (f : Fin 4 → Lp ℝ 2 (volume : Measure (Fin 3 → ℝ))) : + let g : Fin 4 → Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + Fin.cases (compactMultiplierCLM hχ.continuous hc (f 0)) + (fun i => compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (f 0) + + compactMultiplierCLM hχ.continuous hc (f i.succ)) + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∉tsupport χ → physicalFourJetCLM g x=0 := by + intro g + have h₀ := compactMultiplierCLM_ae hχ.continuous hc (f 0) + have hᵢ (i : Fin 3) : g i.succ=ᵐ[volume] fun y => + fderiv ℝ χ y (Pi.single i 1)*f 0 y+χ y*f i.succ y := by + apply (Lp.coeFn_add _ _).trans + filter_upwards [compactMultiplierCLM_ae + ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (f 0), + compactMultiplierCLM_ae hχ.continuous hc (f i.succ)] with y h₁ h₂ + exact congrArg₂ (·+·) h₁ h₂ + have h₀' := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp h₀) + have hᵢ' := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae (ae_all_iff.mpr hᵢ)) + filter_upwards [physicalFourJetCLM_ae g,h₀',hᵢ'] with x hx h₀x hᵢx hn + rw [hx] + dsimp only [Function.comp_apply] at h₀x + have hχ0 := image_eq_zero_of_notMem_tsupport hn + have hdχ0 := fderiv_of_notMem_tsupport ℝ hn + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change compactMultiplierCLM hχ.continuous hc (f 0) (WithLp.ofLp x)=0 + rw [h₀x,hχ0,zero_mul] + · change g j.succ (WithLp.ofLp x)=0 + rw [hᵢx j] + simp [hχ0,hdχ0] + +lemma weak_jet_zero_of_val_zero (u : H1) {x : R3} (h : u.val x=0) : + weakValue u x=0 ∧ ∀ i,weakGradient u x i=0 := by + constructor + · change (u.val x) 0=0 + rw [h]; rfl + · intro i + change (u.val x) i.succ=0 + rw [h]; rfl + +lemma parentCompletionJoin_zero_off_support (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) {χ : (Fin 3 → ℝ) → ℝ} + (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + (hχb : ∀ y,|χ y|≤1) (hχs : tsupport χ⊆sourceClosedCollarBand 0 (2*centralThickness)) + (p : centralEnergySpace s) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∉tsupport χ → + weakValue (parentCompletionJoin s hs ha hχ hc hχb hχs p) x=0 ∧ + ∀ i,weakGradient (parentCompletionJoin s hs ha hχ hc hχb hχs p) x i=0 := by + have hh := physical_localized_jet_zero hχ hc (fun i => parentJoinedComponentCLM s hs ha i p.val) + filter_upwards [hh] with x hx hn + exact weak_jet_zero_of_val_zero _ (hx hn) + +lemma childCompletionJoin_zero_off_support (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 childJoinedComponentCLM s hs ha k i p.val) + filter_upwards [hh] with x hx hn + exact weak_jet_zero_of_val_zero _ (hx hn) + +lemma centralInteriorCompletion_zero_off_support (s : Fin 3 → ℝ) + {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + (hχs : tsupport χ⊆centralPhysical) (hχB : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) + (p : centralEnergySpace s) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∉tsupport χ → + weakValue (centralInteriorCompletion s hχ hc hχs hχB p) x=0 ∧ + ∀ i,weakGradient (centralInteriorCompletion s hχ hc hχs hχB p) x i=0 := by + have hh := physical_localized_jet_zero hχ hc + (fun i => centralPhysicalWholeCLM (centralAmbientComponent s i p.val)) + filter_upwards [hh] with x hx hn + exact weak_jet_zero_of_val_zero _ (hx hn) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceJoin_children_separate (k l : Fin 2) (hkl : k≠l) {y : Fin 3 → ℝ} + (hk : -2*centralThickness ≤ sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm y)) + (hl : -2*centralThickness ≤ sourceCollarTime + ((sourceChildHomeomorph (actualChildSign l)).symm y)) : False := by + have h₁ := (sourceJoinInner_bounds hk).2.1 + have h₂ := (sourceJoinInner_bounds hl).2.1 + change |(y 0-actualChildSign k*sourceOffset)/sourceScale|≤1002/1000 at h₁ + change |(y 0-actualChildSign l*sourceOffset)/sourceScale|≤1002/1000 at h₂ + rw [abs_div,abs_of_pos (show 0 fin_cases l + · exact hkl rfl + · norm_num [actualChildSign,sourceScale,sourceOffset] at h₁' h₂' + linarith [h₁'.1,h₂'.2] + · norm_num [actualChildSign,sourceScale,sourceOffset] at h₁' h₂' + linarith [h₂'.1,h₁'.2] + · exact hkl rfl + +lemma physicalOtherEnd_child_time (k : Fin 2) (i : Fin 3) (hik : i≠k.succ) + {y : Fin 3 → ℝ} (hy : y∈physicalEndRegion i) : + sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)< -2*centralThickness := by + by_contra hn + have ht := le_of_not_gt hn + revert hy hik + refine Fin.cases ?_ (fun l => ?_) i + · intro _ hy + have hh := sourceJoinChild_far_parent k ht + have he : sourceChildCoordinates (actualChildSign k) + ((sourceChildHomeomorph (actualChildSign k)).symm y)=y := + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y + rw [he] at hh + change sourceCollarTime y∈Icc 0 centralThickness at hy + norm_num [centralThickness] at hh hy + linarith [hy.2] + · intro hik hy + have hl : -2*centralThickness ≤ sourceCollarTime + ((sourceChildHomeomorph (actualChildSign l)).symm y) := by + change sourceCollarTime ((sourceChildHomeomorph (actualChildSign l)).symm y) + ∈Icc (-centralThickness) 0 at hy + have := hy.1 + dsimp [centralThickness] at * + linarith + exact sourceJoin_children_separate k l (fun he => hik (congrArg Fin.succ he.symm)) ht hl + +lemma physicalChildEnd_parent_time (k : Fin 2) {y : Fin 3 → ℝ} + (hy : y∈physicalEndRegion k.succ) : 2*centralThickness ≤ sourceCollarTime y := by + have hh := physicalChildEnd_far_parent k hy + have he : sourceChildCoordinates (actualChildSign k) + ((sourceChildHomeomorph (actualChildSign k)).symm y)=y := + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y + rwa [he] at hh + +lemma parent_join_zero_on_children (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) (p : centralEnergySpace s) (k : Fin 2) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈physicalEndRegion k.succ → + weakValue (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p) x=0 ∧ + ∀ i,weakGradient (parentCompletionJoin s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p) x i=0 := by + have hh := parentCompletionJoin_zero_off_support s hs ha (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support p + filter_upwards [hh] with x hx hy + apply hx + intro hm + have ht := centralJoinPartition_subordinate 1 hm + change sourceCollarTime (WithLp.ofLp x)∈Ioo 0 (2*centralThickness) at ht + exact (not_le.mpr ht.2) (physicalChildEnd_parent_time k hy) + +lemma physical_child_join_zero_on_other_ends (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 (not_le.mpr hy) ((centralJoinChildCutoff_support k hm).1)) + have hh := childH10Transport_zero_on k ⟨u,hu⟩ _ hz + filter_upwards [hh] with x hx hy + exact hx (physicalOtherEnd_child_time k i hik hy) + +lemma central_interior_join_zero_on_ends (s : Fin 3 → ℝ) (p : centralEnergySpace s) + (i : Fin 3) : + ∀ᵐ x∂ballMeasure,WithLp.ofLp x∈physicalEndRegion i → + weakValue (centralInteriorCompletion s (centralJoinPartition_smooth 0) + centralJoinPartition_interior_compact centralJoinPartition_interior_support + (fun _ hy => centralPhysical_subset_ball (centralJoinPartition_interior_support hy)) p) x=0 ∧ + ∀ j,weakGradient (centralInteriorCompletion s (centralJoinPartition_smooth 0) + centralJoinPartition_interior_compact centralJoinPartition_interior_support + (fun _ hy => centralPhysical_subset_ball (centralJoinPartition_interior_support hy)) p) x j=0 := by + have hh := centralInteriorCompletion_zero_off_support s (centralJoinPartition_smooth 0) + centralJoinPartition_interior_compact centralJoinPartition_interior_support + (fun _ hy => centralPhysical_subset_ball (centralJoinPartition_interior_support hy)) p + have he := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + physicalBlockRegion_central_end_exclusive_ae) + filter_upwards [hh,he] with x hx he hy + exact hx (fun hm => he (centralJoinPartition_interior_support hm) i hy) + +end ScalarConductivity +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalNullTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalNullTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b48b81ccb518a938f1395f72c5cafd5db36d16a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalNullTransport.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalFaceSum +import OAI.Analysis.Conductivity.Sources.FacePasting +import OAI.Analysis.Conductivity.Sources.NonzeroJacobianAE + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +lemma flatEndCoordinates_ae {a : ℝ} (ha : a≠0) (b : ℝ) + {P : Coord3 → Prop} (hP : ∀ᵐ y ∂volume,P y) : + ∀ᵐ x ∂volume,P (flatEndCoordinates a b x) := by + apply ae_comp_of_nonzero_jacobian (endAxialAffine_hasFDeriv a b) _ _ _ hP + · intro x y h + have h0 := congrFun h 0 + have h1 := congrFun h 1 + have h2 := congrFun h 2 + simp only [endAxialAffine,Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val] at h0 h1 h2 + have h0' : x 0=y 0 := by linarith [mul_left_cancel₀ ha h0] + ext k + fin_cases k <;> assumption + · exact measurable_const + · intro x + change (Matrix.toLin' (endAxialMatrix a)).det≠0 + simpa [LinearMap.det_toLin',endAxialMatrix,Matrix.det_diagonal,Fin.prod_univ_succ] using ha + +lemma ae_image_of_differentiable {f : Coord3 → Coord3} {S : Set Coord3} + (hS : MeasurableSet S) (hI : MeasurableSet (f '' S)) (hf : DifferentiableOn ℝ f S) {P : Coord3 → Prop} + (hP : ∀ᵐ x ∂volume.restrict S,P (f x)) : + ∀ᵐ y ∂volume.restrict (f '' S),P y := by + have hn : volume {x | x∈S ∧ ¬ P (f x)}=0 := by + rw [ae_restrict_iff' hS,ae_iff] at hP + simpa using hP + have hn' := addHaar_image_eq_zero_of_differentiableOn_of_addHaar_eq_zero volume + (hf.mono (show {x | x∈S ∧ ¬ P (f x)}⊆S from fun x hx => hx.1)) hn + rw [ae_iff,Measure.restrict_apply' hI] + apply le_antisymm _ bot_le + have he : {y | ¬P y} ∩ f '' S ⊆ f '' {x | x∈S ∧ ¬P (f x)} := by + rintro y ⟨hy,x,hx,rfl⟩ + exact ⟨x,⟨hx,hy⟩,rfl⟩ + exact (measure_mono he).trans hn'.le + +lemma sourceClosedCollarBand_ae_faces {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) {P : Coord3 → Prop} + (hP : ∀ i j : Fin 4,∀ᵐ x ∂volume.restrict (sourceExtendedBox l r), + P (sourceCollarPiece i j x)) : + ∀ᵐ y ∂volume.restrict (sourceClosedCollarBand l r),P y := by + rw [sourceClosedCollarBand_measure_faces hl hr] + simp only [ae_finsetSum_measure_iff,Finset.mem_univ,true_implies] + intro i j + exact ae_image_of_differentiable measurableSet_Icc (sourceCollarClosedPiece_measurable l r i j) + (fun x _ => (sourceCollarPiece_hasFDeriv i j x).differentiableAt.differentiableWithinAt) + (hP i j) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalOpenBlock.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalOpenBlock.lean new file mode 100644 index 0000000000000000000000000000000000000000..29b90ad8be9fcc1bdd6ffbd57cdc60085cc05685 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalOpenBlock.lean @@ -0,0 +1,207 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.PhysicalBlockDomain + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceChild_toLp (σ : ℝ) (y : Fin 3 → ℝ) : + WithLp.toLp 2 (sourceChildCoordinates σ y)=sourceSimilarity σ (WithLp.toLp 2 y) := by + ext i + fin_cases i + · exact (sourceSimilarity_coord σ (WithLp.toLp 2 y)).1.symm + · exact (sourceSimilarity_coord σ (WithLp.toLp 2 y)).2.1.symm + · exact (sourceSimilarity_coord σ (WithLp.toLp 2 y)).2.2.symm + +lemma sourceSimilarity_childInverse (σ : ℝ) (y : Fin 3 → ℝ) : + sourceSimilarity σ (WithLp.toLp 2 ((sourceChildHomeomorph σ).symm y))=WithLp.toLp 2 y := by + rw [←sourceChild_toLp] + exact congrArg (WithLp.toLp 2) ((sourceChildHomeomorph σ).apply_symm_apply y) + +lemma sourceChild_closure_image_iff (σ : ℝ) (y : Fin 3 → ℝ) : + WithLp.toLp 2 y∈sourceSimilarity σ '' closure sourceDomain ↔ + 0≤ sourceCollarTime ((sourceChildHomeomorph σ).symm y) := by + rw [←sourceDomain_closure_time] + constructor + · rintro ⟨x,hx,he⟩ + have hh := (sourceSimilarity σ).injective (he.trans (sourceSimilarity_childInverse σ y).symm) + rwa [←hh] + · intro hy + exact ⟨_,hy,sourceSimilarity_childInverse σ y⟩ + +def sourceOpenBlock : Set R3 := sourceDomain \ ⋃ k : Fin 2, + sourceSimilarity (actualChildSign k) '' closure sourceDomain + +lemma sourceOpenBlock_time_iff (y : Fin 3 → ℝ) : + WithLp.toLp 2 y∈sourceOpenBlock ↔ 0 lt_of_le_of_ne (hc' k) (hc k)⟩ + · rintro ⟨hp',hc'⟩ + exact ⟨hp'.le,fun k => (hc' k).le⟩ + +lemma physicalBlockRegion_openBlock_restrict : + (volume : Measure (Fin 3 → ℝ)).restrict physicalBlockRegion= + volume.restrict ((WithLp.toLp 2) ⁻¹' sourceOpenBlock) := + Measure.restrict_congr_set physicalBlockRegion_openBlock_ae + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +theorem sourceOpenBlock_tensor_energy (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) (u v : H1) : + Integrable (fun y => originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y)) + (volume.restrict ((WithLp.toLp 2) ⁻¹' sourceOpenBlock)) ∧ + (∫ y in (WithLp.toLp 2) ⁻¹' sourceOpenBlock,originalPiGradient u y ⬝ᵥ + (physicalBlockTensor s a y*ᵥoriginalPiGradient v y))= + (∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ originalPiGradient v y)+ + ∑ i : Fin 3,∫ y in physicalEndRegion i,originalPiGradient u y ⬝ᵥ + (physicalEndTensor s a i y*ᵥoriginalPiGradient v y) := by + rw [←physicalBlockRegion_openBlock_restrict] + exact physicalBlockTensor_energy_sum s a hs ha u v + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceOpenBlock_parent_band {y : Fin 3 → ℝ} + (hp : 0 ?_⟩ + by_contra hn + have hc : -centralThickness ≤ sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y) := + (show -centralThickness≤(0:ℝ) by norm_num [centralThickness]).trans (le_of_not_gt hn) + have hfar := sourceExpandedChild_far_parent k hc + have he : sourceChildCoordinates (actualChildSign k) + ((sourceChildHomeomorph (actualChildSign k)).symm y)=y := + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y + rw [he] at hfar + norm_num [centralThickness] at ht hfar + linarith + +lemma sourceOpenBlock_child_band (k : Fin 2) {y : Fin 3 → ℝ} + (hy : -centralThickness ≤ sourceCollarTime y) (ht : sourceCollarTime y<0) : + WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) y)∈sourceOpenBlock := by + apply (sourceOpenBlock_time_iff _).mpr + refine ⟨lt_of_lt_of_le (show (0:ℝ)<2*centralThickness by norm_num [centralThickness]) + (sourceExpandedChild_far_parent k hy),fun j => ?_⟩ + have he : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)=y := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply y + by_cases hkj : k=j + · rw [←hkj,he] + exact ht + · exact (sourceExpandedChild_other k j hkj (show -centralThickness ≤ sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)) by rw [he]; exact hy)).trans + (by norm_num [centralThickness]) + +lemma physicalBlockRegion_mem_closure_openBlock {y : Fin 3 → ℝ} + (hy : y∈physicalBlockRegion) : + y∈closure ((WithLp.toLp 2) ⁻¹' sourceOpenBlock) := by + obtain ⟨hp,hc⟩ := (physicalBlockRegion_time_iff y).mp hy + by_cases h0 : sourceCollarTime y=0 + · let g : ℝ → (Fin 3 → ℝ) := fun t => sourceAngularCollar t (sourcePhysicalAngles y) + have hg : Continuous g := continuous_uncurry_sourceAngularCollar.comp + (continuous_id.prodMk continuous_const) + have hz : (0:ℝ)∈closure (Ioo 0 centralThickness) := by + rw [closure_Ioo (show (0:ℝ)≠centralThickness by norm_num [centralThickness])] + exact ⟨le_rfl,by norm_num [centralThickness]⟩ + have hin : g '' Ioo 0 centralThickness ⊆ (WithLp.toLp 2) ⁻¹' sourceOpenBlock := by + rintro _ ⟨t,ht,rfl⟩ + have he := sourceAngular_time (show t∈Icc (-(1:ℝ)/100) (1/100) from + ⟨by linarith [ht.1],ht.2.le.trans (by norm_num [centralThickness])⟩) (sourcePhysicalAngles y) + exact sourceOpenBlock_parent_band (by dsimp [g]; rw [he]; exact ht.1) (by dsimp [g]; rw [he]; exact ht.2) + have hmem := closure_mono hin (image_closure_subset_closure_image hg ⟨0,hz,rfl⟩) + have he := sourcePhysicalCoordinates_right + (show sourceCollarTime y∈Icc (-(1:ℝ)/100) (1/100) by rw [h0]; norm_num) + rw [h0] at he + simpa only [g,he] using hmem + · by_cases hchild : ∀ k : Fin 2,sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)≠0 + · exact subset_closure ((sourceOpenBlock_time_iff y).mpr + ⟨lt_of_le_of_ne hp (Ne.symm h0),fun k => lt_of_le_of_ne (hc k) (hchild k)⟩) + · push Not at hchild + obtain ⟨k,hk⟩ := hchild + let z := (sourceChildHomeomorph (actualChildSign k)).symm y + let g : ℝ → (Fin 3 → ℝ) := fun t => sourceChildCoordinates (actualChildSign k) + (sourceAngularCollar t (sourcePhysicalAngles z)) + have hg : Continuous g := (sourceChildCoordinates_contDiff _).continuous.comp + (continuous_uncurry_sourceAngularCollar.comp (continuous_id.prodMk continuous_const)) + have hz : (0:ℝ)∈closure (Ioo (-centralThickness) 0) := by + rw [closure_Ioo (show -centralThickness≠(0:ℝ) by norm_num [centralThickness])] + exact ⟨by norm_num [centralThickness],le_rfl⟩ + have hin : g '' Ioo (-centralThickness) 0 ⊆ (WithLp.toLp 2) ⁻¹' sourceOpenBlock := by + rintro _ ⟨t,ht,rfl⟩ + apply sourceOpenBlock_child_band k + · rw [sourceAngular_time (show t∈Icc (-(1:ℝ)/100) (1/100) from + ⟨(show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans ht.1.le, + ht.2.le.trans (by norm_num)⟩)] + exact ht.1.le + · rw [sourceAngular_time (show t∈Icc (-(1:ℝ)/100) (1/100) from + ⟨(show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans ht.1.le, + ht.2.le.trans (by norm_num)⟩)] + exact ht.2 + have hmem := closure_mono hin (image_closure_subset_closure_image hg ⟨0,hz,rfl⟩) + have he := sourcePhysicalCoordinates_right + (show sourceCollarTime z∈Icc (-(1:ℝ)/100) (1/100) by + change sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)∈_ + rw [hk] + norm_num) + change sourceAngularCollar (sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)) + (sourcePhysicalAngles z)=z at he + rw [hk] at he + have he' : sourceChildCoordinates (actualChildSign k) z=y := + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y + simpa only [g,he,he'] using hmem + +theorem physicalBlockRegion_eq_closure_openBlock : physicalBlockRegion= + closure ((WithLp.toLp 2) ⁻¹' sourceOpenBlock) := by + apply Subset.antisymm (fun y hy => physicalBlockRegion_mem_closure_openBlock hy) + apply closure_minimal _ physicalBlockRegion_compact.isClosed + intro y hy + obtain ⟨hp,hc⟩ := (sourceOpenBlock_time_iff y).mp hy + exact (physicalBlockRegion_time_iff y).mpr ⟨hp.le,fun k => (hc k).le⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalRankTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalRankTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..bacdd3575cbf80e0c79afaad9ce3a0387fa4da03 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalRankTransport.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalJoin +import OAI.Analysis.Conductivity.Sobolev.FiniteEndPhysicalH1 +import OAI.Analysis.Conductivity.Branching.PhysicalNullTransport +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarRegularity +import OAI.Analysis.Conductivity.Geometry.RegularPatchCoordinates +import OAI.Analysis.Conductivity.Variational.FlatSpliceRegularity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +lemma branchCollar_regular_ae {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (i : Fin 3) (z : TorusEndingData s (branchNormalize i f)) + {a b l r : ℝ} (ha : a≠0) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Ioo l r,0 branchSplicedField i z j x) a b) + (fun x => ⟨variableCollarTensor (branchSplicedTensor i z) a b x, + variableCollarTensor_symm (branchSplicedTensor_symm i z) a b x⟩) univ := by + apply sourceClosedCollarBand_ae_faces hl hr + intro m n + have hh := sourceFaceAngles_ae (flatEndCoordinates_ae ha b (branchSpliced_regular hs i z)) m n + filter_upwards [ae_restrict_of_ae hh,sourceExtendedBox_open_ae hl hr, + sourceExtendedBox_axial_strict_ae l r] with x hx hxo hxt + have hh := variableCollar_regular_at (branchSplicedTensor_symm i z) ha b m n hxo + (hx (hT _ hxt)) + exact mem_regularRegion_congr_nhds hh Filter.EventuallyEq.rfl Filter.EventuallyEq.rfl + isOpen_univ (mem_univ _) + +lemma sourceChildInverse_fderiv_surjective (k : Fin 2) (y : Coord3) : + Function.Surjective (fderiv ℝ (sourceChildHomeomorph (actualChildSign k)).symm y) := by + rw [(sourceChildInverse_hasFDeriv _ y).fderiv] + intro v + refine ⟨sourceChildDerivative v,?_⟩ + rw [sourceChildInverseDerivative_apply,sourceChildDerivative_apply] + ext i + fin_cases i <;> simp only [Fin.reduceFinMk, Matrix.cons_val_zero, Matrix.cons_val_one, Matrix.cons_val_two] <;> norm_num [sourceScale] + +lemma sourceChildTensorPush_contDiffOn (k : Fin 2) {K : Coord3 → Mat3} {U : Set Coord3} + (hK : ContDiffOn ℝ (↑(⊤:ℕ∞)) K U) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (sourceChildTensorPush k K) + ((sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' U) := by + apply contDiffOn_pi.mpr + intro i + apply contDiffOn_pi.mpr + intro j + exact contDiffOn_const.mul (((contDiffOn_pi.mp + (contDiffOn_pi.mp hK (childAxis i)) (childAxis j))).comp + (sourceChildInverse_contDiff _).contDiffOn (fun _ hx => hx)) + +lemma sourceChild_regular_at (k : Fin 2) {u : Coord3 → Fin 2 → ℝ} {K : Coord3 → Mat3} + (hK : ∀ x,(K x).IsSymm) {U : Set Coord3} {y : Coord3} + (hy : (sourceChildHomeomorph (actualChildSign k)).symm y∈ + regularRegion u (fun x => ⟨K x,hK x⟩) U) : + y∈regularRegion (fun x => u ((sourceChildHomeomorph (actualChildSign k)).symm x)) + (fun x => ⟨sourceChildTensorPush k K x,sourceChildTensorPush_symmetric k K hK x⟩) + ((sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' U) := by + obtain ⟨O,hOU,hO,hyO⟩ := mem_regularRegion_iff.mp hy + refine mem_regularRegion_iff.mpr ⟨(sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' O, + preimage_mono hOU,?_,hyO⟩ + exact RegularPatch.comp hO (hO.1.preimage (sourceChildHomeomorph _).symm.continuous) + (sourceChildInverse_contDiff _).contDiffOn (fun _ hx => hx) + (fun x _ => sourceChildInverse_fderiv_surjective k x) + (sourceChildTensorPush_contDiffOn k hO.2.2.1) + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +def periodicCorrectionJet (f : Coord3 → ℝ) (a : ℝ) (i : Fin 3) (x : R3) : JetFiber := + Fin.cases + (physicalJet (attachedPeriodicField f a centralThickness (WithLp.ofLp x)) + (fun j => lineDeriv ℝ (attachedPeriodicField f a centralThickness) + (WithLp.ofLp x) (Pi.single j 1))) + (fun k => physicalJet + (attachedPeriodicField f a (-centralThickness) + ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))) + (fun j => sourceScale⁻¹*lineDeriv ℝ (attachedPeriodicField f a (-centralThickness)) + ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x)) + (Pi.single (childAxis j) 1))) i + +lemma parentPeriodicCorrection_exists {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : ContDiff ℝ 1 f) + {τ a : ℝ} (hτ : 0<τ) (hz : ∀ x,x 0<τ → f x=0) (ha : a<0) : + ∃ d : H1,d∈H10 ∧ H1JetOn d centralPhysical (fun _ => 0) ∧ + H1JetOn d (physicalEndRegion 0) (periodicCorrectionJet f a 0) ∧ + ∀ k : Fin 2,H1JetOn d (physicalEndRegion k.succ) (fun _ => 0) := by + obtain ⟨d,hd,hdz,hde⟩ := attachedPeriodicCorrection_H10 hp hf + (a:=a) (b:=centralThickness) (l₀:= -centralThickness/2) (l:=0) + (r:=centralThickness) (r₀:=2*centralThickness) hτ hz + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + have hm : H1JetOn d {y | centralThickness ≤ sourceCollarTime y} (fun _ => 0) := by + apply H1JetOn.zero_of_weak + filter_upwards [hdz] with x hx hy + exact hx (mul_nonpos_of_nonpos_of_nonneg ha.le (sub_nonneg.mpr hy)) + exact ⟨d,hd,hm.mono (fun y hy => ((centralPhysical_time_iff y).mp hy).1), + H1JetOn.of_weak hde,fun k => hm.mono (fun y hy => + (show centralThickness≤2*centralThickness by norm_num [centralThickness]).trans + (physicalChildEnd_parent_time k hy))⟩ + +lemma childPeriodicCorrection_exists {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : ContDiff ℝ 1 f) + {τ a : ℝ} (hτ : 0<τ) (hz : ∀ x,x 0<τ → f x=0) (ha : 0 0) ∧ + H1JetOn d (physicalEndRegion k.succ) (periodicCorrectionJet f a k.succ) ∧ + ∀ i : Fin 3,i≠k.succ → H1JetOn d (physicalEndRegion i) (fun _ => 0) := by + obtain ⟨d,hd,hdz,hde⟩ := attachedPeriodicCorrection_H10 hp hf + (a:=a) (b:= -centralThickness) (l₀:= -2*centralThickness) (l:= -centralThickness) + (r:=0) (r₀:=centralThickness/2) hτ hz + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (by norm_num [centralThickness]) + have hz' : ∀ᵐ x∂ballMeasure, WithLp.ofLp x∈{y | sourceCollarTime y≤-centralThickness} → + weakValue d x=0 ∧ ∀ j,weakGradient d x j=0 := by + filter_upwards [hdz] with x hx hy + exact hx (mul_nonpos_of_nonneg_of_nonpos ha.le (sub_nonpos.mpr hy)) + have hm := H1JetOn.zero_of_weak + (D:={y | sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y)≤-centralThickness}) + (childH10Transport_zero_on k ⟨d,hd⟩ + {y | sourceCollarTime y≤-centralThickness} hz') + refine ⟨childH10Transport k ⟨d,hd⟩,childH10Transport_mem_H10 k _, + hm.mono (fun y hy => ((centralPhysical_time_iff y).mp hy).2 k),?_,?_⟩ + · exact H1JetOn.of_weak (childH10Transport_local_jet k ⟨d,hd⟩ + (D:=sourceClosedCollarBand (-centralThickness) 0) + (fun y hy => sourceBand_mem_ball ⟨ + (show -(1:ℝ)/100≤-centralThickness by norm_num [centralThickness]).trans hy.1, + hy.2.trans (by norm_num)⟩) + (attachedPeriodicField f a (-centralThickness)) + (fun y j => lineDeriv ℝ (attachedPeriodicField f a (-centralThickness)) y (Pi.single j 1)) hde) + · exact fun i hik => hm.mono (fun y hy => + (physicalOtherEnd_child_time k i hik hy).le.trans (by norm_num [centralThickness])) + +theorem triplePeriodicCorrection_exists (f : Fin 3 → Coord3 → ℝ) + (hp : ∀ i,AngularPeriodic (2*Real.pi) (f i)) (hf : ∀ i,ContDiff ℝ 1 (f i)) + (τ a : Fin 3 → ℝ) (hτ : ∀ i,0<τ i) (hz : ∀ i x,x 0<τ i → f i x=0) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 0) ∧ + ∀ i,H1JetOn d (physicalEndRegion i) (periodicCorrectionJet (f i) (a i) i) := by + obtain ⟨dp,hdp,hpc,hpe,hpo⟩ := parentPeriodicCorrection_exists (hp 0) (hf 0) (hτ 0) (hz 0) ha₀ + have hex (k : Fin 2) := childPeriodicCorrection_exists (hp k.succ) (hf k.succ) + (hτ k.succ) (hz k.succ) (ha k) k + choose dc hdc hcc hce hco using hex + refine ⟨dp+(dc 0+dc 1),H10.add_mem hdp (H10.add_mem (hdc 0) (hdc 1)), + hpc.add_zero ((hcc 0).add_zero (hcc 1)),?_⟩ + intro i + fin_cases i + · exact hpe.add_zero ((hco 0 0 (by decide)).add_zero (hco 1 0 (by decide))) + · exact (hpo 0).zero_add ((hce 0).add_zero (hco 1 1 (by decide))) + · exact (hpo 1).zero_add ((hco 0 2 (by decide)).zero_add (hce 1)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/PhysicalTraceTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/PhysicalTraceTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..84d376c9f87af26b5e69f3a67fc44049549b8e0c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/PhysicalTraceTransport.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildH1Pullback +import OAI.Analysis.Conductivity.Variational.PhysicalTraceMean + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +local instance physicalTraceTransportMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance physicalTraceTransportProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma physicalRealTrace_child (k : Fin 2) (u : H1) : + physicalRealTraceCLM k.succ u=physicalRealTraceCLM 0 (childH1Pullback k u) := by + have hc : IsClosed {u : H1 | physicalRealTraceCLM k.succ u= + physicalRealTraceCLM 0 (childH1Pullback k u)} := + isClosed_eq (physicalRealTraceCLM k.succ).continuous + ((physicalRealTraceCLM 0).continuous.comp (childH1Pullback k).continuous) + apply (closure_minimal (s:={u : H1 | u.val∈smoothJets}) ?_ hc) (smoothH1_dense u) + rintro v ⟨f,hf,_,he⟩ + have hv : v=smoothH1 f hf := Subtype.ext he + change physicalRealTraceCLM k.succ v=physicalRealTraceCLM 0 (childH1Pullback k v) + rw [hv,childH1Pullback_smooth] + apply Lp.ext + filter_upwards [physicalRealTrace_smooth_ae k.succ hf, + physicalRealTrace_smooth_ae 0 (hf.comp (sourceChildEuclidean_contDiff (actualChildSign k)))] with θ h1 h0 + exact h1.trans h0.symm + +def sourceMeanCLM (i : Fin 3) : H1 →L[ℝ] ℝ := + (Complex.reCLM.comp ((lp.evalCLM ℂ (fun _ : TorusModes => ℂ) 2 0).restrictScalars ℝ)).comp + (physicalOuterTraceCLM i) + +lemma sourceMean_eq_integral (i : Fin 3) (u : H1) : + sourceMeanCLM i u=∫ θ,physicalRealTraceCLM i u θ := (physicalRealTrace_mean i u).symm + +lemma sourceMean_child (k : Fin 2) (u : H1) : + sourceMeanCLM k.succ u=sourceMeanCLM 0 (childH1Pullback k u) := by + rw [sourceMean_eq_integral,sourceMean_eq_integral,physicalRealTrace_child] + +lemma basisFlux_mean (j : Fin 2) (u : H1) : + constantTerminalFluxCLM (centralBasisSlopes j) u= + angularArea*(sourceMeanCLM j.succ u-sourceMeanCLM 0 u) := by + rw [constantTerminalFlux_realTrace] + simp only [←sourceMean_eq_integral] + rw [Fin.sum_univ_three] + fin_cases j + · change angularArea*((-1)*sourceMeanCLM 0 u+1*sourceMeanCLM 1 u+0*sourceMeanCLM 2 u)=angularArea*(sourceMeanCLM 1 u-sourceMeanCLM 0 u) + ring + · change angularArea*((-1)*sourceMeanCLM 0 u+0*sourceMeanCLM 1 u+1*sourceMeanCLM 2 u)=angularArea*(sourceMeanCLM 2 u-sourceMeanCLM 0 u) + ring + +lemma physicalRealTrace_bound (i : Fin 3) (u : H1) {M : ℝ} (hM : 0≤M) + (hb : ∀ᵐ x∂ballMeasure,abs (weakValue u x)≤M) : + ∀ᵐ θ : UnitAddTorus (Fin 2),abs (physicalRealTraceCLM i u θ)≤M := by + have hh := physicalRealTrace_upper_bound i u hM (hb.mono (fun _ h => (abs_le.mp h).2)) + have hn : ∀ᵐ x∂ballMeasure,weakValue (-u) x≤M := by + filter_upwards [hb,weakValue_neg u] with x hx hn + rw [hn,Pi.neg_apply] + linarith [(abs_le.mp hx).1] + have hh' := physicalRealTrace_upper_bound i (-u) hM hn + rw [map_neg] at hh' + filter_upwards [hh,hh',Lp.coeFn_neg (physicalRealTraceCLM i u)] with θ h0 h1 hn + rw [hn,Pi.neg_apply] at h1 + exact abs_le.mpr ⟨by linarith,h0⟩ + +lemma sourceMean_bound (i : Fin 3) (u : H1) {M : ℝ} (hM : 0≤M) + (hb : ∀ᵐ x∂ballMeasure,abs (weakValue u x)≤M) : abs (sourceMeanCLM i u)≤M := by + rw [sourceMean_eq_integral] + have hh : ∀ᵐ θ,‖physicalRealTraceCLM i u θ‖≤M := by + simpa only [Real.norm_eq_abs] using physicalRealTrace_bound i u hM hb + simpa only [Real.norm_eq_abs,Measure.real,measure_univ,ENNReal.toReal_one,mul_one] using norm_integral_le_of_norm_le_const hh + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/QuantitativeRegularTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/QuantitativeRegularTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..418a52aeed7e9c6c1a889234be85b862ad51589d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/QuantitativeRegularTransport.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ControlledCorrectionBoxes +import OAI.Analysis.Conductivity.Variational.QuantitativePhysicalMoments + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +lemma ControlledCorrectionBox.bounded_transfer + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) + (B C : ControlledCorrectionBox u U) (hBC : (B.region∩C.region).Nonempty) : + ∃ L : ℝ,0 (hb j x).1)) hP.le).trans_eq (by ring)) + have hsmall : (P*Z)*M≤L*M := by + dsimp [L] + nlinarith [mul_nonneg hP.le hZ.le,mul_nonneg hDpos.le (mul_nonneg hP.le hZ.le)] + have hrq : CompactSmoothPair (r-q) := hr.sub hq + have hsrc : physicalSourceMoment u (r-q)=0 := by + rw [physicalSourceMoment_sub hu.continuous hr hq,hqm,sub_self] + have hdif (j) : UniformC1Bound ((r-q) j) ((1+P*Z)*M) := by + change UniformC1Bound (fun x => r j x-q j x) ((1+P*Z)*M) + convert (hb j).sub ((hr j).1.differentiable (by simp)) ((hq j).1.differentiable (by simp)) (hqb j) using 1 + ring + have hc := solve (r-q) hrq (hs.sub ((hQs _).mono inter_subset_left)) hsrc + ((1+P*Z)*M) (by positivity) hdif + refine ⟨q,hq,(hQs _).mono inter_subset_right,hqm,fun j => (hqb j).mono hsmall,hc.mono ?_⟩ + dsimp [L] + nlinarith [mul_nonneg hP.le hZ.le,mul_nonneg (add_nonneg zero_le_one (mul_nonneg hP.le hZ.le)) hM] + +lemma controlled_correction_boxes_cover + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) : + (⋃ B : ControlledCorrectionBox u U,B.region)=U := by + apply Subset.antisymm + · exact iUnion_subset fun B => B.region_subset + · intro p hp + obtain ⟨B,hB⟩ := exists_controlled_correction_box hu hU hp (hD p hp) + exact mem_iUnion.mpr ⟨B,hB⟩ + +lemma controlled_correction_boxes_chain + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) (B C : ControlledCorrectionBox u U) : + Relation.TransGen (fun P Q : ControlledCorrectionBox u U => (P.region∩Q.region).Nonempty) B C := by + have hc : IsPreconnected (⋃ B : ControlledCorrectionBox u U,B.region) := by + rwa [controlled_correction_boxes_cover hu hU hD] + exact hc.transGen_of_iUnion (fun B => B.region_open) B C B.region_nonempty C.region_nonempty + +theorem controlled_source_transport + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) (B C : ControlledCorrectionBox u U) : + ∃ L : ℝ,0 exact B.bounded_transfer hu hD _ h + | @tail C D hpath hCD ih => + obtain ⟨L,hL,solve⟩ := ih + obtain ⟨P,hP,step⟩ := C.bounded_transfer hu hD D hCD + refine ⟨L+P*L,by positivity,?_⟩ + intro r hr hs M hM hb + obtain ⟨q,hq,hqs,hqm,hqb,hqc⟩ := solve r hr hs M hM hb + obtain ⟨s,hss,hssup,hsm,hsb,hsc⟩ := step q hq hqs (L*M) (mul_nonneg hL.le hM) hqb + refine ⟨s,hss,hssup,hsm.trans hqm,fun j => (hsb j).mono ?_,?_⟩ + · nlinarith [mul_nonneg hL.le hM] + · have he := hqc.add hu hsc + rw [sub_add_sub_cancel] at he + exact he.mono (by ring_nf; rfl) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/RecoverJoinChild.lean b/lean/OAI/Analysis/Conductivity/Branching/RecoverJoinChild.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a680f729ead04e57b755d447c0bbef883c40b98 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/RecoverJoinChild.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ProductFactorSpec + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity +open Filter Topology + +def recoverJoinChild (i : Fin 3) (θ : ℝ) (β δ : DiagonalTriple) : DiagonalTriple := + fun j => if j = i then θ / ((δ j)⁻¹ - (1 - θ) / β j) + else (δ j - (1 - θ) * β j) / θ + +lemma div_self_div_eq (θ t : ℝ) (hθ : θ ≠ 0) : θ / (θ / t) = t := by + by_cases ht : t = 0 + · simp [ht] + · field_simp + +lemma recoverJoinChild_join (i : Fin 3) {θ : ℝ} (hθ : θ ≠ 0) + (α β : DiagonalTriple) : recoverJoinChild i θ β (coordinateJoin i θ α β) = α := by + ext j + by_cases hj : j = i + · simp only [recoverJoinChild, coordinateJoin, hj, ite_true, inv_inv, add_sub_cancel_right] + exact div_self_div_eq _ _ hθ + · simp only [recoverJoinChild, coordinateJoin, hj, ite_false, add_sub_cancel_right] + exact mul_div_cancel_left₀ _ hθ + +lemma coordinateJoin_recoverJoinChild (i : Fin 3) {θ : ℝ} (hθ : θ ≠ 0) + (β δ : DiagonalTriple) : coordinateJoin i θ (recoverJoinChild i θ β δ) β = δ := by + ext j + by_cases hj : j = i + · simp only [recoverJoinChild, coordinateJoin, hj, ite_true] + rw [div_self_div_eq _ _ hθ, sub_add_cancel, inv_inv] + · simp only [recoverJoinChild, coordinateJoin, hj, ite_false] + rw [mul_div_cancel₀ _ hθ, sub_add_cancel] + +lemma continuousAt_recoverJoinChild (i : Fin 3) {θ : ℝ} (hθ : θ ≠ 0) + (α β : DiagonalTriple) (hα : α i ≠ 0) + (hjoin : coordinateJoin i θ α β i ≠ 0) : + ContinuousAt (recoverJoinChild i θ β) (coordinateJoin i θ α β) := by + apply continuousAt_pi.mpr + intro j + by_cases hj : j = i + · subst j + simp only [recoverJoinChild, ite_true] + apply continuousAt_const.div + · exact ((continuous_apply i).continuousAt.inv₀ hjoin).sub continuousAt_const + · simp only [coordinateJoin, ite_true, inv_inv, add_sub_cancel_right] + exact div_ne_zero hθ hα + · simp only [recoverJoinChild, ite_eq_right hj] + have hc : Continuous (fun δ : DiagonalTriple => δ j) := continuous_apply j + exact (hc.continuousAt.sub continuousAt_const).div continuousAt_const hθ + +lemma coordinateJoin_zero (i : Fin 3) (α β : DiagonalTriple) : coordinateJoin i 0 α β = β := by + ext j + simp [coordinateJoin] + +lemma coordinateJoin_one (i : Fin 3) (α β : DiagonalTriple) : coordinateJoin i 1 α β = α := by + ext j + simp [coordinateJoin] + +theorem isOpen_finiteLaminate {a b : ℝ} (ha : 0 < a) : + IsOpen {α : DiagonalTriple | IsFiniteLaminate a b α} := by + apply isOpen_iff_mem_nhds.mpr + intro α hα + induction hα with + | scalar s has hsb => + exact mem_interior_iff_mem_nhds.mp (scalar_mem_interior_finiteLaminate ha has hsb) + | @join i θ hθ₀ hθ₁ α β hα hβ ihα ihβ => + by_cases hθ : θ = 0 + · simpa [hθ, coordinateJoin_zero] using ihβ + · let δ := coordinateJoin i θ α β + have hαi : α i ≠ 0 := (ha.trans (hα.bounds ha i).1).ne' + have hδi : δ i ≠ 0 := + (ha.trans (coordinateJoin_bounds ha (hα.bounds ha) (hβ.bounds ha) i ⟨hθ₀, hθ₁⟩ i).1).ne' + have hc := continuousAt_recoverJoinChild i hθ α β hαi hδi + have he : recoverJoinChild i θ β δ = α := recoverJoinChild_join i hθ α β + have hm : ∀ᶠ δ' in 𝓝 δ, IsFiniteLaminate a b (recoverJoinChild i θ β δ') := + hc.preimage_mem_nhds (by rw [he]; exact ihα) + filter_upwards [hm] with δ' hδ' + have hj := IsFiniteLaminate.join i θ hθ₀ hθ₁ hδ' hβ + simpa only [coordinateJoin_recoverJoinChild i hθ β δ'] using hj + +lemma IsFiniteLaminate.permute {a b : ℝ} {α : DiagonalTriple} + (h : IsFiniteLaminate a b α) (e : Equiv.Perm (Fin 3)) : + IsFiniteLaminate a b (α ∘ e) := by + induction h with + | scalar s has hsb => exact .scalar s has hsb + | @join i θ hθ₀ hθ₁ α β hα hβ ihα ihβ => + convert IsFiniteLaminate.join (e.symm i) θ hθ₀ hθ₁ ihα ihβ using 1 + ext j + simp only [Function.comp_apply, coordinateJoin] + congr 1 + exact propext ⟨fun h => by simpa using congrArg e.symm h, + fun h => by simpa using congrArg e h⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/RegularMomentTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/RegularMomentTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..c51a1ce0cc1f2f910554ba5588c5bc90ed513fce --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/RegularMomentTransport.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactPhysicalCorrections + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +theorem exists_physical_moments_in_open + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + {U O : Set Coord3} (hO : IsOpen O) (hne : O.Nonempty) (hOU : O⊆U) + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) (m : Coord3) : + ∃ r : PhysicalSourcePair,CompactSmoothPair r ∧ PairSupported r O ∧ + physicalSourceMoment u r=m := by + obtain ⟨p,hp⟩ := hne + obtain ⟨B,_⟩ := exists_regular_correction_box hu hO hp (hD p (hOU hp)) + obtain ⟨r₀,r₁,hr₀,hr₁,hc₀,hc₁,hs₀,hs₁,hm₀,hm₁,hmt⟩ := + physical_overlap_moment_inverse B.chart B.smooth B.inverse_smooth B.widths B.subset_source m + let r : PhysicalSourcePair := ![r₀,r₁] + have hr : CompactSmoothPair r := by + intro j; fin_cases j + · exact ⟨hr₀,hc₀⟩ + · exact ⟨hr₁,hc₁⟩ + have hs : PairSupported r B.chart.target := by + intro j; fin_cases j + · exact hs₀ + · exact hs₁ + refine ⟨r,hr,hs.mono B.target_subset,?_⟩ + ext i + fin_cases i + · exact hm₀ + · exact hm₁ + · change (∫ x,u x 1*r₀ x-u x 0*r₁ x)=m 2 + rw [←hmt] + apply integral_congr_ae + filter_upwards [] with x + by_cases hx : x∈B.chart.target + · have he := B.potentials hx + rw [he] + rfl + · have h₀ : r₀ x=0 := Function.notMem_support.mp (fun hh => hx (hs₀ (subset_tsupport r₀ hh))) + have h₁ : r₁ x=0 := Function.notMem_support.mp (fun hh => hx (hs₁ (subset_tsupport r₁ hh))) + simp [h₀,h₁] + +lemma RegularCorrectionBox.transfer + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) + (B C : RegularCorrectionBox u U) (hBC : (B.region∩C.region).Nonempty) + {r : PhysicalSourcePair} (hr : CompactSmoothPair r) (hs : PairSupported r B.region) : + ∃ q : PhysicalSourcePair,CompactSmoothPair q ∧ PairSupported q C.region ∧ + physicalSourceMoment u q=physicalSourceMoment u r ∧ PhysicallyCorrectable u U (r-q) := by + obtain ⟨q,hq,hqs,hm⟩ := exists_physical_moments_in_open hu + (B.region_open.inter C.region_open) hBC (inter_subset_left.trans B.region_subset) + hD (physicalSourceMoment u r) + refine ⟨q,hq,hqs.mono inter_subset_right,hm,?_⟩ + apply B.correct hu (hr.sub hq) (hs.sub (hqs.mono inter_subset_left)) + rw [physicalSourceMoment_sub hu.continuous hr hq,hm,sub_self] + +lemma regular_correction_boxes_cover + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) : + (⋃ B : RegularCorrectionBox u U,B.region)=U := by + apply Subset.antisymm + · exact iUnion_subset fun B => B.region_subset + · intro p hp + obtain ⟨B,hB⟩ := exists_regular_correction_box hu hU hp (hD p hp) + exact mem_iUnion.mpr ⟨B,hB⟩ + +lemma regular_correction_boxes_chain + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) (B C : RegularCorrectionBox u U) : + Relation.TransGen (fun P Q : RegularCorrectionBox u U => (P.region∩Q.region).Nonempty) B C := by + have hc : IsPreconnected (⋃ B : RegularCorrectionBox u U,B.region) := by + rwa [regular_correction_boxes_cover hu hU hD] + exact hc.transGen_of_iUnion (fun B => B.region_open) B C B.region_nonempty C.region_nonempty + +theorem regular_source_transport + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (hU : IsOpen U) (hUc : IsPreconnected U) + (hD : ∀ p∈U,Function.Surjective (fderiv ℝ u p)) (B C : RegularCorrectionBox u U) + {r : PhysicalSourcePair} (hr : CompactSmoothPair r) (hs : PairSupported r B.region) : + ∃ q : PhysicalSourcePair,CompactSmoothPair q ∧ PairSupported q C.region ∧ + physicalSourceMoment u q=physicalSourceMoment u r ∧ PhysicallyCorrectable u U (r-q) := by + have hp := regular_correction_boxes_chain hu hU hUc hD B C + induction hp with + | single h => exact B.transfer hu hD _ h hr hs + | @tail C D hpath hCD ih => + obtain ⟨q,hq,hqs,hm,hcorr⟩ := ih + obtain ⟨s,hss,hssup,hm',hcorr'⟩ := C.transfer hu hD D hCD hq hqs + refine ⟨s,hss,hssup,hm'.trans hm,?_⟩ + have ht := hcorr.add hu hcorr' + simpa only [sub_add_sub_cancel] using ht + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/SmoothFamilyCorrectionTransport.lean b/lean/OAI/Analysis/Conductivity/Branching/SmoothFamilyCorrectionTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..44a04bd144a7916cae2ae223d067a38593a3cccf --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/SmoothFamilyCorrectionTransport.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParametricCorrectionTransport +import OAI.Analysis.Conductivity.Sources.ParametricSymmetricSources +import OAI.Analysis.Conductivity.Variational.SmoothPhysicalMomentFamily + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +def SmoothVanishingPairFamily (p : P) (W : Set Coord3) + (r : Fin 2 → P×Coord3 → ℝ) : Prop := + (∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) ∧ (∀ j x,r j (p,x)=0) ∧ + ∃ K : Set Coord3,IsCompact K ∧ K⊆W ∧ ∀ q,PairSupported (fun j x => r j (q,x)) K + +namespace SmoothVanishingPairFamily +omit [FiniteDimensional ℝ P] +variable {p : P} {W V : Set Coord3} {r s : Fin 2 → P×Coord3 → ℝ} +lemma mono (hr : SmoothVanishingPairFamily p W r) (hWV : W⊆V) : + SmoothVanishingPairFamily p V r := by + obtain ⟨hsm,hz,K,hK,hKW,hs⟩ := hr + exact ⟨hsm,hz,K,hK,hKW.trans hWV,hs⟩ +lemma compact (hr : SmoothVanishingPairFamily p W r) (q : P) : + CompactSmoothPair (fun j x => r j (q,x)) := by + obtain ⟨hsm,_,K,hK,_,hs⟩ := hr + exact fun j => ⟨(hsm j).comp (contDiff_const.prodMk contDiff_id), + hK.of_isClosed_subset (isClosed_tsupport _) (hs q j)⟩ +lemma supported (hr : SmoothVanishingPairFamily p W r) (q : P) : + PairSupported (fun j x => r j (q,x)) W := by + obtain ⟨_,_,K,_,hKW,hs⟩ := hr + exact (hs q).mono hKW +lemma sub (hr : SmoothVanishingPairFamily p W r) (hs : SmoothVanishingPairFamily p W s) : + SmoothVanishingPairFamily p W (r-s) := by + obtain ⟨hr,hrz,K,hK,hKW,hKr⟩ := hr + obtain ⟨hs,hsz,L,hL,hLW,hLs⟩ := hs + exact ⟨fun j => (hr j).sub (hs j),fun j x => by simp [hrz,hsz], + K∪L,hK.union hL,union_subset hKW hLW,fun q => + ((hKr q).mono subset_union_left).sub ((hLs q).mono subset_union_right)⟩ +end SmoothVanishingPairFamily + +structure VanishingCorrectionRegion (u : P×Coord3 → Fin 2 → ℝ) (p : P) (U : Set Coord3) where + region : Set Coord3 + region_open : IsOpen region + region_nonempty : region.Nonempty + region_subset : region⊆U + region_bounded : Bornology.IsBounded region + solve : ∀ (r : Fin 2 → P×Coord3 → ℝ),SmoothVanishingPairFamily p region r → + ∀ ε : ℝ,0<ε → ∀ᶠ q in 𝓝 p, + physicalSourceMoment (fun x => u (q,x)) (fun j x => r j (q,x))=0 → + BoundedPhysicallyCorrectable (fun x => u (q,x)) U (fun j x => r j (q,x)) ε + +def ParametricCorrectionBox.toVanishing + {u : P×Coord3 → Fin 2 → ℝ} (p : P) {U : Set Coord3} + (B : ParametricCorrectionBox u p U) : VanishingCorrectionRegion u p U := by + refine ⟨B.region,B.region_open,B.region_nonempty,B.region_subset,B.region_bounded,?_⟩ + intro r hr ε hε + obtain ⟨L,hL,solve⟩ := B.bounded_solver + obtain ⟨hsm,hz,K,hK,hKW,hs⟩ := hr + have hsmall (j) := compact_supported_family_C1_small isOpen_univ (mem_univ p) + (hsm j).contDiffOn hK (Filter.Eventually.of_forall (fun q => hs q j)) (hz j) (div_pos hε hL) + filter_upwards [solve,Filter.eventually_all.mpr hsmall] with q hq hb hm + have hrs : CompactSmoothPair (fun j x => r j (q,x)) := + SmoothVanishingPairFamily.compact ⟨hsm,hz,K,hK,hKW,hs⟩ q + have h := hq _ hrs ((hs q).mono hKW) hm (ε/L) (div_pos hε hL).le hb + simpa only [mul_div_cancel₀ ε hL.ne'] using h + +theorem VanishingCorrectionRegion.smooth_transfer + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + (B C : VanishingCorrectionRegion u p U) {x : Coord3} + (hx : x∈B.region∩C.region) + (hD : Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) + {r : Fin 2 → P×Coord3 → ℝ} (hr : SmoothVanishingPairFamily p B.region r) : + ∃ s : Fin 2 → P×Coord3 → ℝ,SmoothVanishingPairFamily p C.region s ∧ + (∀ᶠ q in 𝓝 p,physicalSourceMoment (fun y => u (q,y)) (fun j y => s j (q,y))= + physicalSourceMoment (fun y => u (q,y)) (fun j y => r j (q,y))) ∧ + ∀ ε : ℝ,0<ε → ∀ᶠ q in 𝓝 p, + BoundedPhysicallyCorrectable (fun y => u (q,y)) U + ((fun j y => r j (q,y))-(fun j y => s j (q,y))) ε := by + obtain ⟨K,hK,hKW,hs⟩ := hr.2.2 + let m : P → Coord3 := fun q => physicalSourceMoment (fun y => u (q,y)) (fun j y => r j (q,y)) + have hm : ContDiff ℝ (↑(⊤:ℕ∞)) m := physicalSourceMoment_family_smooth hu hr.1 hK hs + have hmz : m p=0 := by + change physicalSourceMoment (fun y => u (p,y)) (fun j y => r j (p,y))=0 + rw [show (fun j y => r j (p,y))=0 by funext j y; exact hr.2.1 j y,physicalSourceMoment_zero] + obtain ⟨L,hL,hLO,s,hsm,hss,hsz,hsmom⟩ := smooth_physical_moment_family hu p + (B.region_open.inter C.region_open) hx hD hm hmz + have hsf : SmoothVanishingPairFamily p (B.region∩C.region) s := ⟨hsm,hsz,L,hL,hLO,hss⟩ + refine ⟨s,hsf.mono inter_subset_right,hsmom,?_⟩ + intro ε hε + have hsolve := B.solve (r-s) (hr.sub (hsf.mono inter_subset_left)) ε hε + filter_upwards [hsolve,hsmom] with q solve mom + apply solve + have huq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => u (q,y)) := hu.comp (contDiff_const.prodMk contDiff_id) + change physicalSourceMoment (fun y => u (q,y)) + ((fun j y => r j (q,y))-(fun j y => s j (q,y)))=0 + rw [physicalSourceMoment_sub huq.continuous (hr.compact q) (hsf.compact q),mom,sub_self] + +theorem smooth_chain_source_transport + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (p : P) {U : Set Coord3} + {B C : VanishingCorrectionRegion u p U} + (hpath : Relation.TransGen (fun B C : VanishingCorrectionRegion u p U => + ∃ x∈B.region∩C.region,Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) B C) : + ∀ {r : Fin 2 → P×Coord3 → ℝ},SmoothVanishingPairFamily p B.region r → + ∃ s : Fin 2 → P×Coord3 → ℝ,SmoothVanishingPairFamily p C.region s ∧ + (∀ᶠ q in 𝓝 p,physicalSourceMoment (fun y => u (q,y)) (fun j y => s j (q,y))= + physicalSourceMoment (fun y => u (q,y)) (fun j y => r j (q,y))) ∧ + ∀ ε : ℝ,0<ε → ∀ᶠ q in 𝓝 p, + BoundedPhysicallyCorrectable (fun y => u (q,y)) U + ((fun j y => r j (q,y))-(fun j y => s j (q,y))) ε := by + induction hpath with + | @single C h => + obtain ⟨x,hx,hD⟩ := h + exact fun hr => B.smooth_transfer hu p C hx hD hr + | @tail C D hpath hCD ih => + intro r hr + obtain ⟨s,hs,hsm,hsc⟩ := ih hr + obtain ⟨x,hx,hD⟩ := hCD + obtain ⟨t,ht,htm,htc⟩ := C.smooth_transfer hu p D hx hD hs + refine ⟨t,ht,?_,?_⟩ + · filter_upwards [hsm,htm] with q hq htq + exact htq.trans hq + · intro ε hε + filter_upwards [hsc (ε/2) (by linarith),htc (ε/2) (by linarith)] with q hq htq + have huq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => u (q,y)) := + hu.comp (contDiff_const.prodMk contDiff_id) + have h := hq.add huq htq + rw [sub_add_sub_cancel] at h + simpa only [add_halves] using h + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/TorusEndingCorrection.lean b/lean/OAI/Analysis/Conductivity/Branching/TorusEndingCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2e00d3bfcd0275928598c61cffc7d82babb7e0b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/TorusEndingCorrection.lean @@ -0,0 +1,221 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.WeakFluxClassicalC1 +import OAI.Analysis.Conductivity.Geometry.TorusTraceFiniteEnd +import OAI.Analysis.Conductivity.Geometry.TorusAffineField +import OAI.Analysis.Conductivity.Sobolev.AxialExtension +import OAI.Analysis.Conductivity.Variational.WeakPairOverlap + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped Matrix.Norms.Elementwise + +def torusEndingCorrection (d e : ℝ) (v f : Coord3 → ℝ) : Coord3 → ℝ := + axialZeroExtension (d+e/4) (e/2) (v-f) + +def torusEndingFluxCorrection (d e : ℝ) (G F : Coord3 → Coord3) : Coord3 → Coord3 := + axialZeroExtension (d+e/4) (e/2) (G-F) + +lemma torusEndingCorrection_C2 {d e : ℝ} (he : 0 by dsimp at hx ⊢; linarith) + · intro x hx + change v x-f x=0 + exact sub_eq_zero.mpr (hz x ⟨by linarith [hx.1],by linarith [hx.2]⟩) + +lemma torusEndingFluxCorrection_C1 {d e : ℝ} (he : 0 by dsimp at hx ⊢; linarith) + · intro x hx + change G x-F x=0 + exact sub_eq_zero.mpr (hz x ⟨by linarith [hx.1],by linarith [hx.2]⟩) + +lemma torusEndingCorrection_periodic {T d e : ℝ} {v f : Coord3 → ℝ} + (hv : AngularPeriodic T v) (hf : AngularPeriodic T f) : + AngularPeriodic T (torusEndingCorrection d e v f) := by + apply axialZeroExtension_periodic + intro n x + change v (x+angularShift T n)-f (x+angularShift T n)=v x-f x + rw [hv n x,hf n x] + +lemma torusEndingFluxCorrection_periodic {T d e : ℝ} {G F : Coord3 → Coord3} + (hG : AngularPeriodic T G) (hF : AngularPeriodic T F) : + AngularPeriodic T (torusEndingFluxCorrection d e G F) := by + apply axialZeroExtension_periodic + intro n x + change G (x+angularShift T n)-F (x+angularShift T n)=G x-F x + rw [hG n x,hF n x] + +lemma torusEndingFluxCorrection_divergence {d e : ℝ} (he : 0 G x-F x) y=0 + rw [coordinateDivergence_sub_at (hG.differentiable (by norm_num) y) + ((hF.contDiffAt ((axial_halfspace_open d).mem_nhds hyd)).differentiableAt (by norm_num)), + hdG y hyd,hdF y hyd,sub_self] + +lemma torusEndingFluxCorrection_initial_zero {d e : ℝ} (he : 0 0) := by + apply axialZeroExtension_eventually_zero (by linarith : 0 0) := by + apply axialZeroExtension_eventually_zero (by linarith : 0 torusAffineField s (normalizedSlope j) (f j) x + +lemma torusInitialPair_eq (s : Fin 3 → ℝ) (f : Fin 2 → TorusL2) (x : Coord3) : + torusInitialPair s f x=![x 0+torusRealContinuation s (f 0) x,torusRealContinuation s (f 1) x] := by + ext j + fin_cases j <;> simp [torusInitialPair,torusAffineField,normalizedSlope] + +lemma torusInitialPair_smooth {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : Fin 2 → TorusL2) : ContDiffOn ℝ (↑(⊤:ℕ∞)) (torusInitialPair s f) {x | 0 torusAffineField_smooth hs _ _ + +namespace TorusEndingData +variable {s : Fin 3 → ℝ} {f : Fin 2 → TorusL2} (z : TorusEndingData s f) + +lemma initial_field (x : Coord3) (hx : x 0∈Ioo z.d (z.d+z.e)) : + z.w.v x=torusInitialPair s f x := by + rw [z.initial_v x ⟨hx.1.le,hx.2.le⟩,torusInitialPair_eq] + +lemma initial_flux + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) (hx : x 0∈Ioo z.d (z.d+z.e)) : + (z.w.G x).col j=flatModeFlux s (torusAffineField s (normalizedSlope j) (f j)) x := by + apply z.w.flux_on_flat_patch (V:={x : Coord3 | x 0∈Ioo z.d (z.d+z.e)}) + (isOpen_Ioo.preimage (continuous_apply 0)) s + (fun x hx => z.initial_E x ⟨hx.1.le,hx.2.le⟩) (torusInitialPair s f) + (((torusInitialPair_smooth hs f).of_le (show (2 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono (by + intro y hy + exact z.d_pos.trans hy.1)) (fun x hx => z.initial_field x hx) j x hx + +def correction (j : Fin 2) : Coord3 → ℝ := + torusEndingCorrection z.d z.e (fun x => z.w.v x j) + (torusAffineField s (normalizedSlope j) (f j)) + +def fluxCorrection (j : Fin 2) : Coord3 → Coord3 := + torusEndingFluxCorrection z.d z.e (fun x => (z.w.G x).col j) + (flatModeFlux s (torusAffineField s (normalizedSlope j) (f j))) + +lemma correction_C2 + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) : ContDiff ℝ 2 (z.correction j) := by + exact torusEndingCorrection_C2 z.e_pos (contDiff_pi.mp z.w.smooth j) + (((torusAffineField_smooth hs _ _).of_le (show (2 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono (fun x hx => z.d_pos.trans hx)) + (fun x hx => congrFun (z.initial_field x hx) j) + +lemma correction_periodic (j : Fin 2) : AngularPeriodic (2*Real.pi) (z.correction j) := by + exact torusEndingCorrection_periodic (fun n x => congrFun (z.periodic_v n x) j) + (torusAffineField_periodic _ _ _) + +lemma fluxCorrection_C1 + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) : ContDiff ℝ 1 (z.fluxCorrection j) := by + exact torusEndingFluxCorrection_C1 z.e_pos (z.w.component_flux_C1 j) + (((flatModeFlux_smoothOn (axial_halfspace_open 0) (torusAffineField_smooth hs _ _)).of_le + (show (1 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono (fun x hx => z.d_pos.trans hx)) (fun x hx => z.initial_flux hs j x hx) + +lemma fluxCorrection_periodic (j : Fin 2) : AngularPeriodic (2*Real.pi) (z.fluxCorrection j) := by + exact torusEndingFluxCorrection_periodic + (fun n x => congrArg (fun M : Matrix (Fin 3) (Fin 2) ℝ => M.col j) + (z.w.flux_periodic z.periodic_v z.periodic_E n x)) + (flatModeFlux_periodic (torusAffineField_periodic _ _ _)) + +lemma fluxCorrection_divergence + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (x : Coord3) : coordinateDivergence (z.fluxCorrection j) x=0 := by + exact torusEndingFluxCorrection_divergence z.e_pos (z.w.component_flux_C1 j) + (((flatModeFlux_smoothOn (axial_halfspace_open 0) (torusAffineField_smooth hs _ _)).of_le + (show (1 : WithTop ℕ∞)≤↑(⊤:ℕ∞) from WithTop.coe_le_coe.mpr le_top)).mono (fun x hx => z.d_pos.trans hx)) + (fun x hx => z.initial_flux hs j x hx) + (fun x hx => z.w.flux_divergence (axial_halfspace_open z.d) j x hx) + (fun x hx => torusAffineField_flux_divergence hs _ _ (z.d_pos.trans hx)) x + +end TorusEndingData +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Branching/VariableBlockEnergy.lean b/lean/OAI/Analysis/Conductivity/Branching/VariableBlockEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..b70801eea645d1ea82bb4b94b8f0c84f6ae8094b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Branching/VariableBlockEnergy.lean @@ -0,0 +1,142 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalBlockEnergySum +import OAI.Analysis.Conductivity.Variational.PhysicalEnergyContinuous +import OAI.Analysis.Conductivity.Flux.VariableBlockTensor + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal +local instance variableBlockEnergyMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance variableBlockEnergyBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +lemma variableBlockTensor_central_ae (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) : + ∀ᵐ y∂(volume : Measure (Fin 3 → ℝ)),y∈centralPhysical → variableBlockTensor K a y=1 := by + have hparent := sourceColevel_ae_ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + have hchild (k : Fin 2) := (sourceChildInverse_quasi (actualChildSign k)).ae + (sourceColevel_ae_ne + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness])) + filter_upwards [hparent,hchild 0,hchild 1] with y hp hc₀ hc₁ hy + apply variableBlockTensorList_outside + intro i _ hi + have ht := (centralPhysical_time_iff y).mp hy + have hn (k : Fin 2) : sourceCollarTime + ((sourceChildHomeomorph (actualChildSign k)).symm y)≠-centralThickness := by + fin_cases k + · exact hc₀ + · exact hc₁ + fin_cases i + · change sourceCollarTime y∈Icc 0 centralThickness at hi + exact hp (le_antisymm hi.2 ht.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 0)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hn 0 (le_antisymm (ht.2 0) hi.1) + · change sourceCollarTime ((sourceChildHomeomorph (actualChildSign 1)).symm y) + ∈Icc (-centralThickness) 0 at hi + exact hn 1 (le_antisymm (ht.2 1) hi.1) + +lemma variableBlockTensor_entry_memLp (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 variableBlockTensor K a y i j) ∞ + (volume : Measure (Fin 3 → ℝ)) := by + have h := variableBlockTensor_properties K a hK ha + let heval : (Matrix (Fin 3) (Fin 3) ℝ) →L[ℝ] ℝ := + ((ContinuousLinearMap.proj j) : (Fin 3 → ℝ) →L[ℝ] ℝ).comp + ((ContinuousLinearMap.proj i) : Matrix (Fin 3) (Fin 3) ℝ →L[ℝ] (Fin 3 → ℝ)) + exact heval.comp_memLp' h.2.1 + +theorem variableBlockTensor_weak_integrable (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y)) (volume.restrict D) := by + have hrow (i : Fin 3) : MemLp (fun y => ∑ j : Fin 3, + variableBlockTensor K a y i j*originalPiGradient v y j) 2 (volume.restrict D) := by + apply memLp_finsetSum + intro j _ + exact ((variableBlockTensor_entry_memLp K a hK ha i j).restrict D).mul (r := 2) + (originalPiGradient_memLp_on_ball hD hb v j) + change Integrable (fun y => ∑ i : Fin 3,originalPiGradient u y i* + ∑ j : Fin 3,variableBlockTensor K a y i j*originalPiGradient v y j) _ + apply integrable_finsetSum + intro i _ + exact (originalPiGradient_memLp_on_ball hD hb u i).integrable_mul (hrow i) + +lemma variableBlockTensor_end_energy (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (i : Fin 3) + {D : Set (Fin 3 → ℝ)} (hD : MeasurableSet D) (hsub : D⊆physicalEndRegion i) + (u v : H1) : + (∫ y in D,originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y))= + ∫ y in D,originalPiGradient u y ⬝ᵥ + (variableEndTensor K a i y*ᵥoriginalPiGradient v y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_mem hD] with y hy + rw [variableBlockTensor_local K a i (hsub hy)] + +lemma variableBlockTensor_central_energy (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (u v : H1) : + (∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y))= + ∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ originalPiGradient v y := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae (variableBlockTensor_central_ae K a), + ae_restrict_mem centralPhysical_compact.measurableSet] with y he hy + rw [he hy,Matrix.one_mulVec] + +theorem variableBlockTensor_energy_sum (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y)) (volume.restrict physicalBlockRegion) ∧ + (∫ y in physicalBlockRegion,originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y))= + (∫ y in centralPhysical,originalPiGradient u y ⬝ᵥ originalPiGradient v y)+ + ∑ i : Fin 3,∫ y in physicalEndRegion i,originalPiGradient u y ⬝ᵥ + (variableEndTensor K a i y*ᵥoriginalPiGradient v y) := by + refine ⟨variableBlockTensor_weak_integrable K a hK ha + physicalBlockRegion_compact.measurableSet (fun _ => physicalBlockRegion_subset_ball) u v,?_⟩ + rw [physicalBlockRegion_integral _ + (variableBlockTensor_weak_integrable K a hK ha centralPhysical_compact.measurableSet + (fun _ => centralPhysical_subset_ball) u v) + (fun i => variableBlockTensor_weak_integrable K a hK ha + (physicalEndRegion_compact i).measurableSet + (fun _ => physicalEndRegion_subset_ball i) u v), + variableBlockTensor_central_energy] + congr 1 + apply Finset.sum_congr rfl + intro i _ + exact variableBlockTensor_end_energy K a i (physicalEndRegion_compact i).measurableSet + Subset.rfl u v + +lemma variableBlockEnergy_continuous (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 ∫ y in physicalBlockRegion,originalPiGradient u y ⬝ᵥ + (variableBlockTensor K a y*ᵥoriginalPiGradient v y)) := by + have h := variableBlockTensorList_properties K a hK ha (Finset.univ : Finset (Fin 3)).toList + obtain ⟨B,hB,hbound⟩ := h.2.2.2 + apply literal_matrix_energy_continuous _ (fun i j => + (measurable_pi_apply j |>.comp ((measurable_pi_apply i).comp h.1)).aestronglyMeasurable) + B hB.le (fun y i j => ?_) physicalBlockRegion_compact.measurableSet + (fun _ => physicalBlockRegion_subset_ball) u + exact (norm_le_pi_norm ((variableBlockTensor K a y) i) j).trans + ((norm_le_pi_norm (variableBlockTensor K a y) i).trans (hbound y)) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AEFluxWeak.lean b/lean/OAI/Analysis/Conductivity/Flux/AEFluxWeak.lean new file mode 100644 index 0000000000000000000000000000000000000000..c18a4cadfdb4e81216abcfebb6319ceeb184d02d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AEFluxWeak.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.C1WeakDivergence + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +theorem C1_divergence_zero_ae_test + {E ι : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] [Fintype ι] + (μ : Measure E) [μ.IsAddHaarMeasure] (v : ι → E) (F : ι → E → ℝ) + (hF : ∀ i, ContDiff ℝ 1 (F i)) + (ψ : SmoothScalar E) (hc : HasCompactSupport ψ.val) + (hdiv : ∀ᵐ x ∂μ, x∈Function.support ψ.val → ∑ i, direction (v i) (F i) x = 0) : + (∫ x, ∑ i, F i x*(smoothDirection (v i) ψ).val x ∂μ) = 0 := by + have hp := smoothScalar_contDiff ψ + have hI (i : ι) : Integrable (fun x => F i x*(smoothDirection (v i) ψ).val x) μ := + ((hF i).continuous.mul (smoothScalar_contDiff (smoothDirection (v i) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (v i) hc).mul_left + have hI' (i : ι) : Integrable (fun x => ψ.val x*direction (v i) (F i) x) μ := + (hp.continuous.mul (direction_continuous (hF i) _)).integrable_of_hasCompactSupport hc.mul_right + have hibp (i : ι) : (∫ x, F i x*(smoothDirection (v i) ψ).val x ∂μ) = + -(∫ x, ψ.val x*direction (v i) (F i) x ∂μ) := by + have hh := integral_bilinear_hasFDerivAt_right_eq_neg_left_of_integrable + (B := ContinuousLinearMap.mul ℝ ℝ) + (f := F i) (g := ψ.val) (v := v i) + (show Integrable (fun x => direction (v i) (F i) x*ψ.val x) μ by + simpa only [mul_comm] using hI' i) + (hI i) + (((hF i).continuous.mul hp.continuous).integrable_of_hasCompactSupport hc.mul_left) + (fun x _ => ((hF i).differentiable (by norm_num) x).hasFDerivAt) + (fun x _ => (hp.differentiable (by simp) x).hasFDerivAt) + change (∫ x, F i x * (fderiv ℝ ψ.val x) (v i) ∂μ) = + -(∫ x, (fderiv ℝ (F i) x) (v i) * ψ.val x ∂μ) at hh + simpa only [direction,smoothDirection_apply,mul_comm] using hh + rw [integral_finsetSum _ (fun i _ => hI i)] + simp_rw [hibp] + rw [Finset.sum_neg_distrib,←integral_finsetSum _ (fun i _ => hI' i)] + have hz : (fun x => ∑ i, ψ.val x*direction (v i) (F i) x) =ᵐ[μ] fun _ => (0:ℝ) := by + filter_upwards [hdiv] with x hxdiv + rw [←Finset.mul_sum] + by_cases hx : x∈Function.support ψ.val + · rw [hxdiv hx,mul_zero] + · rw [Function.notMem_support.mp hx,zero_mul] + rw [integral_congr_ae hz,integral_zero,neg_zero] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AntisymmetricFlux.lean b/lean/OAI/Analysis/Conductivity/Flux/AntisymmetricFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..5f8d69e71205e54e73104a882dd194293ac8f764 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AntisymmetricFlux.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CascadeGeometry +import OAI.Analysis.Conductivity.Branching.CascadeStreams + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def direction {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : E) (f : E → ℝ) (x : E) : ℝ := fderiv ℝ f x v + +lemma direction_C1 {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} (hf : ContDiff ℝ 2 f) (v : E) : ContDiff ℝ 1 (direction v f) := by + exact (hf.fderiv_right (by norm_num)).clm_apply contDiff_const + +lemma direction_commute {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} (hf : ContDiff ℝ 2 f) (v w x : E) : + direction v (direction w f) x = direction w (direction v f) x := by + have hd : DifferentiableAt ℝ (fderiv ℝ f) x := + (hf.fderiv_right (show (1 : WithTop ℕ∞)+1≤2 by norm_num)).contDiffAt.differentiableAt (by norm_num) + unfold direction + rw [fderiv_clm_apply hd (differentiableAt_const _),fderiv_clm_apply hd (differentiableAt_const _)] + simpa using hf.contDiffAt.isSymmSndFDerivAt (by simp) v w + +lemma direction_neg {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} (hf : Differentiable ℝ f) (v x : E) : + direction v (fun x => -f x) x = -direction v f x := by + change (fderiv ℝ (-f) x) v = -(fderiv ℝ f x) v + rw [(hf x).hasFDerivAt.neg.fderiv] + rfl + +theorem antisymmetric_potential_divergence {E ι : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] [Fintype ι] + (v : ι → E) (S : ι → ι → E → ℝ) + (hS : ∀ i j, ContDiff ℝ 2 (S i j)) + (ha : ∀ i j, S i j = fun x => -S j i x) (x : E) : + ∑ i, direction (v i) (fun y => ∑ j, direction (v j) (S i j) y) x = 0 := by + have hsum (i : ι) : + direction (v i) (fun y => ∑ j, direction (v j) (S i j) y) x = + ∑ j, direction (v i) (direction (v j) (S i j)) x := by + change (fderiv ℝ (fun y => ∑ j, direction (v j) (S i j) y) x) (v i) = _ + rw [fderiv_fun_sum (fun j _ => (direction_C1 (hS i j) (v j)).contDiffAt.differentiableAt (by norm_num))] + simp [direction] + simp_rw [hsum] + have he (i j : ι) : direction (v i) (direction (v j) (S i j)) x = + -direction (v j) (direction (v i) (S j i)) x := by + rw [direction_commute (hS i j),ha i j] + have hn : direction (v i) (fun x => -S j i x) = fun x => -direction (v i) (S j i) x := by + funext y + exact direction_neg ((hS j i).differentiable (by norm_num)) _ _ + rw [hn] + exact direction_neg ((direction_C1 (hS j i) _).differentiable (by norm_num)) _ _ + have heq : (∑ i, ∑ j, direction (v i) (direction (v j) (S i j)) x) = + -(∑ i, ∑ j, direction (v i) (direction (v j) (S i j)) x) := by + conv_lhs => rw [Finset.sum_comm] + conv_lhs => enter [2,i,2,j]; rw [he] + simp only [Finset.sum_neg_distrib] + linarith + +lemma boundedSmooth_zero {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] : + BoundedSmooth (fun _ : E => (0:ℝ)) := + BoundedSmooth.of_compact contDiff_const (HasCompactSupport.intro isCompact_empty (fun _ _ => rfl)) + +lemma geometric_finite_C2 {ι : Type*} [Fintype ι] {f : ι → Coord3 → ℝ} + (hf : ∀ i, BoundedSmooth (f i)) (select : ℕ → ι) + {q : ℝ} (hq : 0 ≤ q) (hqsmall : 4*q<1) (A k : ℝ) (center : ℕ → Coord3) : + ContDiff ℝ 2 (fun x => ∑' j : ℕ, (A*q^j)*f (select j) ((k*2^j) • (x-center j))) := by + apply geometric_scaled_C2 (fun j => (hf (select j)).1) _ hq hqsmall A k center + intro n + choose C hC hb using fun i => (hf i).2 n + refine ⟨∑ i, C i,Finset.sum_nonneg (fun i _ => hC i),fun j x => ?_⟩ + exact (hb (select j) x).trans (Finset.single_le_sum (fun i _ => hC i) (Finset.mem_univ _)) + +def cascadePotentialMother (L K : ℝ) (a b i j : Fin 3) (x : Coord3) : ℝ := + ((if i=0 ∧ j=a then cascadeBaseStream L K a x else 0) + + (if i=a ∧ j=b then cascadeCrossStream L K a b x else 0)) - + ((if j=0 ∧ i=a then cascadeBaseStream L K a x else 0) + + (if j=a ∧ i=b then cascadeCrossStream L K a b x else 0)) + +lemma cascadePotentialMother_antisymm (L K : ℝ) (a b i j : Fin 3) : + cascadePotentialMother L K a b i j = fun x => -cascadePotentialMother L K a b j i x := by + funext x + unfold cascadePotentialMother + ring + +lemma cascadePotentialMother_bounded {L K : ℝ} (hL : 0 < L) (a b i j : Fin 3) : + BoundedSmooth (cascadePotentialMother L K a b i j) := by + unfold cascadePotentialMother + have hb := cascadeBaseStream_bounded (K := K) hL a + have hc := cascadeCrossStream_bounded (K := K) hL a b + apply BoundedSmooth.sub <;> apply BoundedSmooth.add + all_goals split <;> first | exact hb | exact hc | exact boundedSmooth_zero + +def cascadePotential (L K k A : ℝ) (i j : Fin 3) (x : Coord3) : ℝ := + ∑' n : ℕ, (A*cascadeRatio L K^n)* + cascadePotentialMother L K (cascadeAxis n) (cascadeAxis (n+1)) i j + ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)) + +lemma cascadePotential_C2 {L K : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (k A : ℝ) (i j : Fin 3) : + ContDiff ℝ 2 (cascadePotential L K k A i j) := by + exact geometric_finite_C2 + (f := fun ab : Fin 3 × Fin 3 => cascadePotentialMother L K ab.1 ab.2 i j) + (fun ab => cascadePotentialMother_bounded (lt_of_lt_of_le (by norm_num) hL) ab.1 ab.2 i j) + (fun n => (cascadeAxis n,cascadeAxis (n+1))) + (cascadeRatio_pos L K).le (cascadeRatio_small hL hK) A k + (cascadeCenter (cascadeLength L K) k) + +lemma cascadePotential_antisymm (L K k A : ℝ) (i j : Fin 3) : + cascadePotential L K k A i j = fun x => -cascadePotential L K k A j i x := by + funext x + unfold cascadePotential + simp_rw [cascadePotentialMother_antisymm L K _ _ i j, mul_neg,tsum_neg] + +def cascadeFlux (L K k A : ℝ) (x : Coord3) (i : Fin 3) : ℝ := + ∑ j, direction (Pi.single j 1) (cascadePotential L K k A i j) x + +lemma cascadeFlux_C1 {L K : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (k A : ℝ) (i : Fin 3) : + ContDiff ℝ 1 (fun x => cascadeFlux L K k A x i) := by + apply ContDiff.sum + intro j _ + exact direction_C1 (cascadePotential_C2 hL hK k A i j) _ + +theorem cascadeFlux_divergence {L K : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (k A : ℝ) (x : Coord3) : + ∑ i, direction (Pi.single i 1) (fun y => cascadeFlux L K k A y i) x = 0 := + antisymmetric_potential_divergence (fun i => Pi.single i 1) (cascadePotential L K k A) + (cascadePotential_C2 hL hK k A) (cascadePotential_antisymm L K k A) x + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AssembleCompatibleTensors.lean b/lean/OAI/Analysis/Conductivity/Flux/AssembleCompatibleTensors.lean new file mode 100644 index 0000000000000000000000000000000000000000..3e2a9fd9599fd969ef84ebd3c312a089adaf1981 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AssembleCompatibleTensors.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.MeasurableDisjointGluing +import OAI.Analysis.Conductivity.Variational.CompactDepthReductionRegular + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +theorem assemble_compatible_tensors + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {I : Type*} [Fintype I] [DecidableEq I] + (O : I → Set Coord3) (hO : ∀ i, IsOpen (O i)) + (hd : Pairwise (fun i j => Disjoint (O i) (O j))) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hA : Measurable A) + (R : ∀ i, CompactCompatibleReplacement μ (O i) u A) : + ∃ (du : Coord3 → Fin 2 → ℝ) (dF : Coord3 → Matrix (Fin 3) (Fin 2) ℝ) + (T : Coord3 → Symmetric3), + ContDiff ℝ (↑(⊤ : ℕ∞)) du ∧ HasCompactSupport du ∧ tsupport du ⊆ ⋃ i, O i ∧ + ContDiff ℝ (↑(⊤ : ℕ∞)) dF ∧ HasCompactSupport dF ∧ tsupport dF ⊆ ⋃ i, O i ∧ + (∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x ((dF x).col j) ∂μ) = 0) ∧ Measurable T ∧ + (∀ i, EqOn du (R i).du (O i) ∧ EqOn dF (R i).dF (O i) ∧ + EqOn T (R i).tensor (O i)) ∧ EqOn T A (⋃ i, O i)ᶜ ∧ + (∀ x, conductivityFlux (fun y => u y+du y) T x = conductivityFlux u A x+dF x) := by + obtain ⟨du, dF, hus, huc, hUs, hFs, hFc, hFS, hpair, heq, hoff⟩ := + assemble_compatible_replacements μ O hO hd u A R + have hB (i : I) : ContinuousOn (R i).tensor (O i) := + Topology.IsInducing.subtypeVal.continuousOn_iff.mpr (R i).smooth_tensor.continuousOn + obtain ⟨T, hT, hTon, hToff⟩ := exists_measurable_disjoint_gluing O hO hd A hA + (fun i => (R i).tensor) hB (A 0) + refine ⟨du, dF, T, hus, huc, hUs, hFs, hFc, hFS, hpair, hT, + fun i => ⟨(heq i).1, (heq i).2.1, hTon i⟩, hToff, ?_⟩ + intro x + by_cases hx : x ∈ ⋃ i, O i + · obtain ⟨i, hxi⟩ := mem_iUnion.mp hx + simp only [conductivityFlux, hTon i hxi, (heq i).2.2 x hxi, (heq i).2.1 hxi] + exact (R i).constitutive x hxi + · have hxu : x ∉ tsupport du := fun hu => hx (hUs hu) + have hder : fderiv ℝ (fun y => u y+du y) x = fderiv ℝ u x := by + apply Filter.EventuallyEq.fderiv_eq + filter_upwards [(isClosed_tsupport du).isOpen_compl.mem_nhds hxu] with y hy + rw [image_eq_zero_of_notMem_tsupport hy, add_zero] + simp only [conductivityFlux, hToff hx, hder, (hoff x hx).2, add_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AttachedEndDifferential.lean b/lean/OAI/Analysis/Conductivity/Flux/AttachedEndDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..3859ee6df8a409a1d95583d9a47c80c19d65574e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AttachedEndDifferential.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CollarAE +import OAI.Analysis.Conductivity.Fourier.AttachedEndPoisson + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix + +theorem attachedEndPoisson_real_fderiv (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) (ht : 0 (attachedEndPoissonField s f a b 0 y).re) (sourceCollarPiece i j x) v= + (sourceCartesianGradientMatrix i j x *ᵥ (endAxialMatrix a *ᵥ + (fun k : Fin 3 => (attachedEndPoissonField s f a b k.succ (sourceCollarPiece i j x)).re))) ⬝ᵥ v := by + let E := sourceCollarTangentEquiv i j x (sourceCollarOpenBox_subset hx) + let z := endAxialAffine a b (sourceFaceAngles i j x) + let r : Fin 3 → ℝ := fun k => (endPoissonField s f k.succ (z 0,torusAngles z)).re + let w := E.symm v + have hw : sourceCollarJacobian i j x *ᵥ w=v := E.apply_symm_apply v + have hd : (sourceFaceAngleMatrix i j x)ᵀ=sourceFaceAngleMatrix i j x := Matrix.diagonal_transpose _ + have ha : (endAxialMatrix a)ᵀ=endAxialMatrix a := Matrix.diagonal_transpose _ + have hp := Complex.reCLM.hasFDerivAt.comp (sourceCollarPiece i j x) + (attachedEndPoissonField_hasFDeriv s hs f a b i j hx ht) + have hr : r=fun k : Fin 3 => (attachedEndPoissonField s f a b k.succ (sourceCollarPiece i j x)).re := by + funext k + obtain ⟨htx,hi,hj⟩ := mem_sourceExtendedBox.mp (sourceCollarOpenBox_subset hx) + dsimp only [r,z] + rw [←sourceFaceAngles_physical i j hi hj,attachedEndPoissonField_angular s f a b k.succ htx, + torusAngles_endAxialAffine] + rfl + calc + _ = (fderiv ℝ (endFlatPoisson s f) z + (endAxialMatrix a *ᵥ (sourceFaceAngleMatrix i j x *ᵥ w))).re := + congrArg (fun L : (Fin 3 → ℝ) →L[ℝ] ℝ => L v) hp.fderiv + _ = r ⬝ᵥ (endAxialMatrix a *ᵥ (sourceFaceAngleMatrix i j x *ᵥ w)) := + endFlatPoisson_realCLM_apply s hs f (x:=z) ht _ + _ = (sourceFaceAngleMatrix i j x *ᵥ w) ⬝ᵥ (endAxialMatrix a *ᵥ r) := by + simpa only [ha] using Matrix.dotProduct_transpose_mulVec (endAxialMatrix a) r (sourceFaceAngleMatrix i j x *ᵥ w) + _ = w ⬝ᵥ (sourceFaceAngleMatrix i j x *ᵥ (endAxialMatrix a *ᵥ r)) := by + rw [dotProduct_comm (sourceFaceAngleMatrix i j x *ᵥ w) (endAxialMatrix a *ᵥ r)] + simpa only [hd] using Matrix.dotProduct_transpose_mulVec (sourceFaceAngleMatrix i j x) (endAxialMatrix a *ᵥ r) w + _ = w ⬝ᵥ ((sourceCollarJacobian i j x)ᵀ *ᵥ + (sourceCartesianGradientMatrix i j x *ᵥ (endAxialMatrix a *ᵥ r))) := by + rw [sourceCartesianGradient_chain i j (sourceCollarOpenBox_subset hx)] + _ = (sourceCartesianGradientMatrix i j x *ᵥ (endAxialMatrix a *ᵥ r)) ⬝ᵥ + (sourceCollarJacobian i j x *ᵥ w) := Matrix.dotProduct_transpose_mulVec _ _ _ + _ = _ := by rw [hw,hr] + +lemma sourceCollarPiece_time_open {i j : Fin 4} {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : sourceCollarTime (sourceCollarPiece i j x)=x 0 := by + obtain ⟨ht,hi,hj⟩ := mem_sourceExtendedBox.mp (sourceCollarOpenBox_subset hx) + rw [←sourceFaceAngles_physical i j hi hj,sourceAngular_time ht] + +lemma attachedEndPoisson_real_differentiable_ae (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) : + ∀ᵐ y : Fin 3 → ℝ,y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) → + 0 (attachedEndPoissonField s f a b 0 y).re) y := by + filter_upwards [sourceCollar_open_charts_ae] with y hy hb ht + obtain ⟨i,j,x,hx,rfl⟩ := hy hb + rw [sourceCollarPiece_time_open hx] at ht + exact (Complex.reCLM.hasFDerivAt.comp _ (attachedEndPoissonField_hasFDeriv s hs f a b i j hx ht)).differentiableAt + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AttachedFlatTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/AttachedFlatTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..0c18c99b292b7ff3abd139514c6da72bce529d2d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AttachedFlatTensor.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalFlatEllipticity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def attachedCartesianMatrix (a : ℝ) (i j : Fin 4) (x : Fin 3 → ℝ) : + Matrix (Fin 3) (Fin 3) ℝ := sourceCartesianGradientMatrix i j x*endAxialMatrix a + +lemma attachedCartesianMatrix_det_ne_zero {a : ℝ} (ha : a≠0) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + (attachedCartesianMatrix a i j x).det≠0 := by + rw [attachedCartesianMatrix,Matrix.det_mul] + apply mul_ne_zero (sourceCartesianGradientMatrix_det_ne_zero i j hx) + simpa [endAxialMatrix,Matrix.det_diagonal,Fin.prod_univ_succ] using ha + +def attachedFlatTensor (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) (x : Fin 3 → ℝ) : + Matrix (Fin 3) (Fin 3) ℝ := + (|a| *sourceFlatDensity i j x) • + (((attachedCartesianMatrix a i j x)⁻¹)ᵀ*flatCylinderMatrix s* + (attachedCartesianMatrix a i j x)⁻¹) + +lemma attachedFlatTensor_symmetric (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) + (x : Fin 3 → ℝ) : (attachedFlatTensor s a i j x)ᵀ=attachedFlatTensor s a i j x := by + simp only [attachedFlatTensor,Matrix.transpose_smul,Matrix.transpose_mul, + Matrix.transpose_transpose,flatCylinderMatrix_symmetric,Matrix.mul_assoc] + +lemma attachedFlatTensor_energy (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) (v w : Fin 3 → ℝ) : + (attachedCartesianMatrix a i j x*ᵥv) ⬝ᵥ + (attachedFlatTensor s a i j x*ᵥ(attachedCartesianMatrix a i j x*ᵥw))= + |a| *sourceFlatDensity i j x*(v ⬝ᵥ (flatCylinderMatrix s*ᵥw)) := + inverse_congruence_energy _ _ (attachedCartesianMatrix_det_ne_zero ha i j hx) _ _ _ + +lemma attachedFlatTensor_energy_density (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) (v w : Fin 3 → ℝ) : + |(sourceCollarJacobian i j x).det| *((attachedCartesianMatrix a i j x*ᵥv) ⬝ᵥ + (attachedFlatTensor s a i j x*ᵥ(attachedCartesianMatrix a i j x*ᵥw)))= + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (v ⬝ᵥ (flatCylinderMatrix s*ᵥw)) := by + rw [attachedFlatTensor_energy s ha i j hx,sourceFlatDensity,sourceFaceAngleMatrix_det] + field_simp [abs_ne_zero.mpr (sourceCollarJacobian_extended_ne_zero i j hx)] + +lemma flat_inverse_congruence_positive (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (C : Matrix (Fin 3) (Fin 3) ℝ) (hC : C.det≠0) {d : ℝ} (hd : 0 sq_nonneg (u l)) (Finset.mem_univ k)) + have he := inverse_congruence_energy C (flatCylinderMatrix s) hC d u u + rw [hu] at he + rw [he] + exact mul_pos hd ((mul_pos (by norm_num : (0:ℝ)<1/2) hsum).trans_le + (flatCylinderMatrix_coercive s hs u)) + +lemma continuousOn_attachedCartesianMatrix (a : ℝ) (i j : Fin 4) : + ContinuousOn (attachedCartesianMatrix a i j) (sourceExtendedBox (-(1:ℝ)/100) (1/100)) := + (continuousOn_sourceCartesianGradientMatrix i j).mul continuousOn_const + +lemma continuousOn_attachedFlatTensor (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) (i j : Fin 4) : + ContinuousOn (attachedFlatTensor s a i j) (sourceExtendedBox (-(1:ℝ)/100) (1/100)) := by + have hi : ContinuousOn (fun x => (attachedCartesianMatrix a i j x)⁻¹) + (sourceExtendedBox (-(1:ℝ)/100) (1/100)) := by + intro x hx + have hn := attachedCartesianMatrix_det_ne_zero ha i j hx + exact (continuousAt_matrix_inv _ (by + rw [Ring.inverse_eq_inv'] + exact continuousAt_inv₀ hn)).comp_continuousWithinAt + (continuousOn_attachedCartesianMatrix a i j x hx) + exact (continuousOn_const.mul (continuousOn_sourceFlatDensity i j)).smul + ((((continuous_id.matrix_transpose : + Continuous (fun A : Matrix (Fin 3) (Fin 3) ℝ => Aᵀ)).comp_continuousOn hi).mul + continuousOn_const).mul hi) + +theorem attachedFlatTensor_elliptic (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a : ℝ} (ha : a≠0) (i j : Fin 4) : + ∃ c C : ℝ,0 (attachedEndPoissonField s f a b 0 y).re) (sourceCollarPiece i j x) v= + (attachedCartesianMatrix a i j x*ᵥ(fun k : Fin 3 => + (endPoissonField s f k.succ (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re)) ⬝ᵥ v := by + rw [attachedEndPoisson_real_fderiv s hs f a b i j hx ht] + have hfield (k : Fin 3) : attachedEndPoissonField s f a b k.succ (sourceCollarPiece i j x)= + endPoissonField s f k.succ (a*(x 0-b),torusAngles (sourceFaceAngles i j x)) := by + obtain ⟨htx,hi,hj⟩ := mem_sourceExtendedBox.mp (sourceCollarOpenBox_subset hx) + rw [←sourceFaceAngles_physical i j hi hj,attachedEndPoissonField_angular s f a b k.succ htx] + simp_rw [hfield] + rw [attachedCartesianMatrix,Matrix.mulVec_mulVec] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AttachedPhysicalSmoothGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/AttachedPhysicalSmoothGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..a56ef544e61c4665ce63ca5ed1c87b7b39652fed --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AttachedPhysicalSmoothGreen.lean @@ -0,0 +1,196 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalBlockEnergySum +import OAI.Analysis.Conductivity.Variational.CompletePhysicalAttachment +import OAI.Analysis.Conductivity.Flux.PhysicalEndSmoothGreen +import OAI.Analysis.Conductivity.Variational.PhysicalSmoothTest +import OAI.Analysis.Conductivity.Sobolev.CentralPhysicalEnergy + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +def physicalSmoothOuterTrace {φ : (Fin 3 → ℝ) → ℝ} (s : Fin 3 → ℝ) + (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (i : Fin 3) : spectralTraceGraph (torusRate s) := + Fin.cases (smoothCollarTrace s 0 hφ) + (fun k => smoothCollarTrace s 0 (hφ.comp (sourceChildCoordinates_contDiff (actualChildSign k)))) i + +def physicalEndLength (a : Fin 3 → ℝ) (i : Fin 3) : ℝ := |a i| *centralThickness + +lemma H1JetOn.attached_gradient {s a κ : Fin 3 → ℝ} {p : centralEnergySpace s} + {w : H1} {i : Fin 3} (hw : H1JetOn w (physicalEndRegion i) (attachedPhysicalJet s a κ p i)) : + ∀ᵐ y : Fin 3 → ℝ,y∈physicalEndRegion i → originalPiGradient w y= + (fun j => attachedPhysicalJet s a κ p i (WithLp.toLp 2 y) j.succ) := by + apply originalPiGradient_eq_on_ball (fun _ => physicalEndRegion_subset_ball i) w _ + filter_upwards [hw] with x hx hy j + exact congrArg (fun v : JetFiber => v j.succ) (hx hy) + +lemma attached_child_end_energy_pullback (s a κ : Fin 3 → ℝ) (p : centralEnergySpace s) + {φ : (Fin 3 → ℝ) → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (k : Fin 2) : + (∫ y in physicalEndRegion k.succ, + (fun j => attachedPhysicalJet s a κ p k.succ (WithLp.toLp 2 y) j.succ) ⬝ᵥ + (physicalEndTensor s a k.succ y*ᵥphysicalTestCovector φ y))= + ∫ y in sourceClosedCollarBand (-centralThickness) 0, + fullAttachedEndGradient s (centralT s k.succ p) (a k.succ) (-centralThickness) (κ k.succ) y ⬝ᵥ + (attachedCollarTensor s (a k.succ) y*ᵥphysicalTestCovector (φ ∘ sourceChildCoordinates (actualChildSign k)) y) := by + have hreg : physicalEndRegion k.succ=sourceChildCoordinates (actualChildSign k) '' + sourceClosedCollarBand (-centralThickness) 0 := by + change (sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' _=_ + ext y + constructor + · intro hy + exact ⟨(sourceChildHomeomorph (actualChildSign k)).symm y,hy, + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y⟩ + · rintro ⟨x,hx,rfl⟩ + change (sourceChildHomeomorph (actualChildSign k)).symm + ((sourceChildHomeomorph (actualChildSign k)) x)∈sourceClosedCollarBand (-centralThickness) 0 + simpa only [Homeomorph.symm_apply_apply] using hx + conv_lhs => rw [hreg] + conv_lhs => rw [sourceChild_integral (actualChildSign k) childEndBand_measurable] + apply integral_congr_ae + filter_upwards [] with y + change sourceScale^3*((fun j => sourceScale⁻¹*fullAttachedEndGradient s (centralT s k.succ p) + (a k.succ) (-centralThickness) (κ k.succ) + ((sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)) (childAxis j)) ⬝ᵥ + (sourceChildTensorPush k (attachedCollarTensor s (a k.succ)) + (sourceChildCoordinates (actualChildSign k) y)*ᵥphysicalTestCovector φ + (sourceChildCoordinates (actualChildSign k) y)))=_ + have hv : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)=y := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply y + rw [hv, + sourceChildTensorPush_mixed,physicalTestCovector_child hφ] + +lemma attached_parent_jet_smooth_green (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (_ : ∀ k : Fin 2,0 attachedPhysicalJet s a κ p 0 (WithLp.toLp 2 y) j.succ) ⬝ᵥ + (physicalEndTensor s a 0 y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s 0 p)) + (spectralGraphWeight (torusRate s) (centralT s 0 (physicalSmoothCentral s hφ)))- + κ 0*spectralGraphMean (torusRate s) (centralT s 0 (physicalSmoothCentral s hφ))+ + cylinderTerminalFlux s (κ 0) (physicalEndLength a 0) (centralT s 0 p) + (physicalSmoothOuterTrace s hφ 0)) := by + change (∫ y in sourceClosedCollarBand 0 centralThickness, + fullAttachedEndGradient s (centralT s 0 p) (a 0) centralThickness (κ 0) y ⬝ᵥ + (attachedCollarTensor s (a 0) y*ᵥphysicalTestCovector φ y))=_ + rw [fullAttachedEnd_smooth_green_neg s hs (centralT s 0 p) (κ 0) hφ ha₀ + (by norm_num [centralThickness]) (R:=physicalEndLength a 0) + (by dsimp [physicalEndLength]; rw [abs_of_neg ha₀]; ring) + (by norm_num) (by norm_num [centralThickness]),physicalSmoothCentral_parent_trace s hφ] + rfl + +lemma attached_child_jet_smooth_green (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (_ : a 0<0) (ha : ∀ k : Fin 2,0 attachedPhysicalJet s a κ p k.succ (WithLp.toLp 2 y) j.succ) ⬝ᵥ + (physicalEndTensor s a k.succ y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s k.succ p)) + (spectralGraphWeight (torusRate s) (centralT s k.succ (physicalSmoothCentral s hφ)))- + κ k.succ*spectralGraphMean (torusRate s) (centralT s k.succ (physicalSmoothCentral s hφ))+ + cylinderTerminalFlux s (κ k.succ) (physicalEndLength a k.succ) (centralT s k.succ p) + (physicalSmoothOuterTrace s hφ k.succ)) := by + conv_lhs => rw [attached_child_end_energy_pullback s a κ p hφ k] + rw [fullAttachedEnd_smooth_green_pos s hs (centralT s k.succ p) (κ k.succ) + (hφ.comp (sourceChildCoordinates_contDiff (actualChildSign k))) (ha k) + (by norm_num [centralThickness]) (R:=physicalEndLength a k.succ) + (by dsimp [physicalEndLength]; rw [abs_of_pos (ha k)]; ring) + (by norm_num [centralThickness]) (by norm_num),physicalSmoothCentral_child_trace s hφ k] + rfl + +lemma attached_physical_jet_smooth_green (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 attachedPhysicalJet s a κ p i (WithLp.toLp 2 y) j.succ) ⬝ᵥ + (physicalEndTensor s a i y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s i p)) + (spectralGraphWeight (torusRate s) (centralT s i (physicalSmoothCentral s hφ)))- + κ i*spectralGraphMean (torusRate s) (centralT s i (physicalSmoothCentral s hφ))+ + cylinderTerminalFlux s (κ i) (physicalEndLength a i) (centralT s i p) + (physicalSmoothOuterTrace s hφ i)) := by + refine Fin.cases ?_ (fun k => ?_) i + · exact attached_parent_jet_smooth_green s a κ hs ha₀ ha p hφ + · exact attached_child_jet_smooth_green s a κ hs ha₀ ha p hφ k + +lemma attached_physical_end_smooth_green (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 attachedPhysicalJet s a κ p i (WithLp.toLp 2 y) j.succ) ⬝ᵥ + (physicalEndTensor s a i y*ᵥphysicalTestCovector φ y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae (hw i).attached_gradient, + ae_restrict_of_ae (piSmoothH1_gradient hφ (fun _ => physicalEndRegion_subset_ball i)), + ae_restrict_mem (physicalEndRegion_compact i).measurableSet] with y hw hv hy + rw [hw hy,hv hy] + exact he.trans (attached_physical_jet_smooth_green s a κ hs ha₀ ha p hφ i) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +lemma attached_block_smooth_green (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 (ha k).ne') i + rw [(physicalBlockTensor_energy_sum s a hs han w (piSmoothH1 hφ)).2, + central_physical_energy p (physicalSmoothCentral s hφ) w (piSmoothH1 hφ) hwc + (physicalSmoothCentral_jet s hφ)] + simp_rw [attached_physical_end_smooth_green s a κ hs ha₀ ha p w hwe hφ] + rw [←Finset.mul_sum,Finset.sum_add_distrib,Finset.sum_sub_distrib] + have hv := hp (physicalSmoothCentral s hφ) + nlinarith + +theorem physical_attached_smooth_green_exists (s a κ : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 + attached_block_smooth_green s a κ hs ha₀ ha p hp w hwc hwe hφ⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AttachedSplicedGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/AttachedSplicedGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..649d6e365baaeac4cc2adae348e95d4bdd6ad3ab --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AttachedSplicedGreen.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalEndSmoothGreen +import OAI.Analysis.Conductivity.Scalarization.AttachedSplicedConstitution +import OAI.Analysis.Conductivity.Flux.BranchTerminalFluxIntegral +import OAI.Analysis.Conductivity.Fourier.AttachedPeriodicGreen + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped ENNReal +local instance attachedSplicedGreenMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance attachedSplicedGreenProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma symmetric_dotProduct_mulVec_swap {A : Mat3} (hA : A.IsSymm) (u v : Coord3) : + u ⬝ᵥ(A*ᵥv)=(A*ᵥu) ⬝ᵥv := by + rw [←hA,Matrix.dotProduct_transpose_mulVec,dotProduct_comm,hA] + +variable {s : Fin 3 → ℝ} (f : Fin 2 → spectralTraceGraph (torusRate s)) (i : Fin 3) + (z : TorusEndingData s (branchNormalize i (fun j => torusSpectralSynthesis s (f j)))) + +def splicedAttachedGradient (j : Fin 2) (a b : ℝ) (y : Coord3) : Coord3 := + fullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) y+ + (fun k => lineDeriv ℝ (attachedPeriodicField (branchCorrection i z j) a b) y (Pi.single k 1)) + +lemma splicedAttached_energy_ae + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (φ : Coord3 → ℝ) {a b l r : ℝ} (ha : a≠0) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) (ht : ∀ t∈Ioo l r,0 splicedAttachedGradient f i z j a b y ⬝ᵥ + (variableCollarTensor (branchSplicedTensor i z) a b y*ᵥphysicalTestCovector φ y))=ᵐ[ + volume.restrict (sourceClosedCollarBand l r)] + fun y => fullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) y ⬝ᵥ + (attachedCollarTensor s a y*ᵥphysicalTestCovector φ y)+ + attachedPeriodicFlux (branchFluxCorrection i z j) a b y ⬝ᵥphysicalTestCovector φ y := by + filter_upwards [attachedSpliced_constitution_ae hs f i z j ha hl hr ht] with y hy + rw [symmetric_dotProduct_mulVec_swap (variableCollarTensor_symm (branchSplicedTensor_symm i z) a b y), + show variableCollarTensor (branchSplicedTensor i z) a b y*ᵥsplicedAttachedGradient f i z j a b y= + attachedCollarTensor s a y*ᵥfullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) y+ + attachedPeriodicFlux (branchFluxCorrection i z j) a b y from hy,add_dotProduct, + symmetric_dotProduct_mulVec_swap (A:=attachedCollarTensor s a y) + (attachedFaceTensorList_symmetric s a _ y)] + +lemma splicedAttached_smooth_green_pos + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + {a l r R : ℝ} (ha : 0 splicedAttachedGradient f i z j a l y ⬝ᵥ + (variableCollarTensor (branchSplicedTensor i z) a l y*ᵥphysicalTestCovector φ y)) + (sourceClosedCollarBand l r) volume ∧ + (∫ y in sourceClosedCollarBand l r,splicedAttachedGradient f i z j a l y ⬝ᵥ + (variableCollarTensor (branchSplicedTensor i z) a l y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (f j)) + (spectralGraphWeight (torusRate s) (smoothCollarTrace s l hφ))- + centralBasisSlopes j i*spectralGraphMean (torusRate s) (smoothCollarTrace s l hφ)+ + centralBasisSlopes j i*spectralGraphMean (torusRate s) (smoothCollarTrace s r hφ)) := by + have hRp : 0 mul_pos ha (sub_pos.mpr ht.1) + have hO := (fullAttachedEnd_smooth_energy_pullback s hs (f j) (centralBasisSlopes j i) hφ + ha.ne' hlr.le hRp.le hl hr hT ht).1 + obtain ⟨hC,hCI⟩ := attachedPeriodicFlux_smooth_green (branchFluxCorrection_C1 i z hs j) + (branchFluxCorrection_periodic i z j) hφ ha.ne' hlr.le hRp.le hl hr hT + (Or.inl ⟨ha,by ring,hR⟩) (fun x _ => branchFluxCorrection_divergence i z hs j x) + have he := splicedAttached_energy_ae f i z hs j φ ha.ne' hl hr ht + refine ⟨(hO.add hC).congr he.symm,?_⟩ + rw [integral_congr_ae he,integral_add hO hC, + fullAttachedEnd_smooth_green_pos s hs (f j) (centralBasisSlopes j i) hφ ha hlr hR hl hr,hCI, + branchFluxCorrection_initial_integral hs i z j, + branchFluxCorrection_terminal_integral hs f i z j hRp hz _ hφ] + have hend : a⁻¹*R+l=r := by rw [←hR]; field_simp [ha.ne']; ring + rw [hend] + ring + +lemma splicedAttached_smooth_green_neg + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + {a l r R : ℝ} (ha : a<0) (hlr : l splicedAttachedGradient f i z j a r y ⬝ᵥ + (variableCollarTensor (branchSplicedTensor i z) a r y*ᵥphysicalTestCovector φ y)) + (sourceClosedCollarBand l r) volume ∧ + (∫ y in sourceClosedCollarBand l r,splicedAttachedGradient f i z j a r y ⬝ᵥ + (variableCollarTensor (branchSplicedTensor i z) a r y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (f j)) + (spectralGraphWeight (torusRate s) (smoothCollarTrace s r hφ))- + centralBasisSlopes j i*spectralGraphMean (torusRate s) (smoothCollarTrace s r hφ)+ + centralBasisSlopes j i*spectralGraphMean (torusRate s) (smoothCollarTrace s l hφ)) := by + have hRp : 0 mul_pos_of_neg_of_neg ha (sub_neg.mpr ht.2) + have hO := (fullAttachedEnd_smooth_energy_pullback s hs (f j) (centralBasisSlopes j i) hφ + ha.ne hlr.le hRp.le hl hr hT ht).1 + obtain ⟨hC,hCI⟩ := attachedPeriodicFlux_smooth_green (branchFluxCorrection_C1 i z hs j) + (branchFluxCorrection_periodic i z j) hφ ha.ne hlr.le hRp.le hl hr hT + (Or.inr ⟨ha,hR,by ring⟩) (fun x _ => branchFluxCorrection_divergence i z hs j x) + have he := splicedAttached_energy_ae f i z hs j φ ha.ne hl hr ht + refine ⟨(hO.add hC).congr he.symm,?_⟩ + rw [integral_congr_ae he,integral_add hO hC, + fullAttachedEnd_smooth_green_neg s hs (f j) (centralBasisSlopes j i) hφ ha hlr hR hl hr,hCI, + branchFluxCorrection_initial_integral hs i z j, + branchFluxCorrection_terminal_integral hs f i z j hRp hz _ hφ] + have hend : a⁻¹*R+r=l := by rw [←hR]; field_simp [ha.ne]; ring + rw [hend] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/AxialFluxBlend.lean b/lean/OAI/Analysis/Conductivity/Flux/AxialFluxBlend.lean new file mode 100644 index 0000000000000000000000000000000000000000..45c334c6ca5ae22d2ef137c8fff525afaf959f93 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/AxialFluxBlend.lean @@ -0,0 +1,195 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AlignedEndingRegularity + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +def axialFluxBlend (χ : ℝ → ℝ) (F G : Coord3 → Coord3) (x : Coord3) : Coord3 := + fun i => (1-χ (x 0))*F x i+χ (x 0)*G x i + +lemma axialFluxBlend_C1 {χ : ℝ → ℝ} (hχ : ContDiff ℝ 1 χ) {F G : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) (hG : ContDiff ℝ 1 G) : ContDiff ℝ 1 (axialFluxBlend χ F G) := by + apply contDiff_pi.mpr + intro i + exact ((contDiff_const.sub (hχ.comp (contDiff_apply ℝ ℝ 0))).mul (contDiff_pi.mp hF i)).add + ((hχ.comp (contDiff_apply ℝ ℝ 0)).mul (contDiff_pi.mp hG i)) + +lemma axialFluxBlend_divergence {χ : ℝ → ℝ} (hχ : Differentiable ℝ χ) {F G : Coord3 → Coord3} + (hF : Differentiable ℝ F) (hG : Differentiable ℝ G) (x : Coord3) : + coordinateDivergence (axialFluxBlend χ F G) x= + (1-χ (x 0))*coordinateDivergence F x+χ (x 0)*coordinateDivergence G x+ + deriv χ (x 0)*(G x 0-F x 0) := by + have hf (i : Fin 3) : DifferentiableAt ℝ (fun y => F y i) x := differentiableAt_pi.mp (hF x) i + have hg (i : Fin 3) : DifferentiableAt ℝ (fun y => G y i) x := differentiableAt_pi.mp (hG x) i + have hc : DifferentiableAt ℝ (fun y : Coord3 => χ (y 0)) x := + (hχ (x 0)).comp x (differentiableAt_apply 0 x) + have hd (i : Fin 3) : direction (Pi.single i 1) (fun y => axialFluxBlend χ F G y i) x= + (1-χ (x 0))*direction (Pi.single i 1) (fun y => F y i) x+ + χ (x 0)*direction (Pi.single i 1) (fun y => G y i) x+ + deriv χ (x 0)*(if (0:Fin 3)=i then 1 else 0)*(G x i-F x i) := by + have h1 : DifferentiableAt ℝ (fun y => 1-χ (y 0)) x := differentiableAt_const (1:ℝ) |>.sub hc + have h2 : DifferentiableAt ℝ (fun y => (1-χ (y 0))*F y i) x := h1.mul (hf i) + have h3 : DifferentiableAt ℝ (fun y => χ (y 0)*G y i) x := hc.mul (hg i) + change direction (Pi.single i 1) (fun y => (1-χ (y 0))*F y i+χ (y 0)*G y i) x=_ + rw [direction_add h2 h3,direction_mul h1 (hf i),direction_mul hc (hg i), + direction_sub (differentiableAt_const (1:ℝ)) hc,direction_scalar_coord hχ i 0,direction_const] + ring + change (∑ i,direction (Pi.single i 1) (fun y => axialFluxBlend χ F G y i) x)=_ + simp_rw [hd] + simp only [Fin.sum_univ_three,coordinateDivergence,show (0:Fin 3)≠1 by decide, + show (0:Fin 3)≠2 by decide,ite_true,ite_false,mul_one,mul_zero,zero_mul,add_zero] + change _=(1-χ (x 0))*(direction (Pi.single 0 1) (fun y => F y 0) x+ + direction (Pi.single 1 1) (fun y => F y 1) x+direction (Pi.single 2 1) (fun y => F y 2) x)+ + χ (x 0)*(direction (Pi.single 0 1) (fun y => G y 0) x+ + direction (Pi.single 1 1) (fun y => G y 1) x+direction (Pi.single 2 1) (fun y => G y 2) x)+_ + ring + +lemma axialFluxBlend_divergence_zero {χ : ℝ → ℝ} (hχ : Differentiable ℝ χ) {F G : Coord3 → Coord3} + (hF : Differentiable ℝ F) (hG : Differentiable ℝ G) {x : Coord3} + (hFd : coordinateDivergence F x=0) (hGd : coordinateDivergence G x=0) + (hn : deriv χ (x 0)=0 ∨ F x 0=G x 0) : + coordinateDivergence (axialFluxBlend χ F G) x=0 := by + rw [axialFluxBlend_divergence hχ hF hG,hFd,hGd,mul_zero,mul_zero,zero_add,zero_add] + rcases hn with hn|hn + · rw [hn,zero_mul] + · rw [hn,sub_self,mul_zero] + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +theorem C1_divergence_zero_on_test + {E ι : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] [Fintype ι] + (μ : Measure E) [μ.IsAddHaarMeasure] (v : ι → E) (F : ι → E → ℝ) + (hF : ∀ i, ContDiff ℝ 1 (F i)) + (ψ : SmoothScalar E) (hc : HasCompactSupport ψ.val) + (hdiv : ∀ x, x∈Function.support ψ.val → ∑ i, direction (v i) (F i) x = 0) : + (∫ x, ∑ i, F i x*(smoothDirection (v i) ψ).val x ∂μ) = 0 := by + have hp := smoothScalar_contDiff ψ + have hI (i : ι) : Integrable (fun x => F i x*(smoothDirection (v i) ψ).val x) μ := + ((hF i).continuous.mul (smoothScalar_contDiff (smoothDirection (v i) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (v i) hc).mul_left + have hI' (i : ι) : Integrable (fun x => ψ.val x*direction (v i) (F i) x) μ := + (hp.continuous.mul (direction_continuous (hF i) _)).integrable_of_hasCompactSupport hc.mul_right + have hibp (i : ι) : (∫ x, F i x*(smoothDirection (v i) ψ).val x ∂μ) = + -(∫ x, ψ.val x*direction (v i) (F i) x ∂μ) := by + have hh := integral_bilinear_hasFDerivAt_right_eq_neg_left_of_integrable + (B := ContinuousLinearMap.mul ℝ ℝ) + (f := F i) (g := ψ.val) (v := v i) + (show Integrable (fun x => direction (v i) (F i) x*ψ.val x) μ by + simpa only [mul_comm] using hI' i) + (hI i) + (((hF i).continuous.mul hp.continuous).integrable_of_hasCompactSupport hc.mul_left) + (fun x _ => ((hF i).differentiable (by norm_num) x).hasFDerivAt) + (fun x _ => (hp.differentiable (by simp) x).hasFDerivAt) + change (∫ x, F i x * (fderiv ℝ ψ.val x) (v i) ∂μ) = + -(∫ x, (fderiv ℝ (F i) x) (v i) * ψ.val x ∂μ) at hh + simpa only [direction,smoothDirection_apply,mul_comm] using hh + rw [integral_finsetSum _ (fun i _ => hI i)] + simp_rw [hibp] + rw [Finset.sum_neg_distrib,←integral_finsetSum _ (fun i _ => hI' i)] + have hz : (fun x => ∑ i, ψ.val x*direction (v i) (F i) x) = fun _ => (0:ℝ) := by + funext x + rw [←Finset.mul_sum] + by_cases hx : x∈Function.support ψ.val + · rw [hdiv x hx,mul_zero] + · rw [Function.notMem_support.mp hx,zero_mul] + rw [hz,integral_zero,neg_zero] + +theorem axialFluxBlend_weak {χ : ℝ → ℝ} (hχ : ContDiff ℝ 1 χ) {F G : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) (hG : ContDiff ℝ 1 G) {U : Set Coord3} + (hFd : ∀ x∈U,coordinateDivergence F x=0) + (hGd : ∀ x∈U,coordinateDivergence G x=0) + (hn : ∀ x∈U,deriv χ (x 0)=0 ∨ F x 0=G x 0) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) + (hs : tsupport ψ.val⊆U) : + (∫ x, ∑ i, axialFluxBlend χ F G x i*(smoothDirection (Pi.single i 1) ψ).val x)=0 := by + apply C1_divergence_zero_on_test volume (fun i => Pi.single i 1) + (fun i x => axialFluxBlend χ F G x i) + (fun i => contDiff_pi.mp (axialFluxBlend_C1 hχ hF hG) i) ψ hc + intro x hx + have hxU := hs (subset_tsupport _ hx) + exact axialFluxBlend_divergence_zero (hχ.differentiable (by norm_num)) + (hF.differentiable (by norm_num)) (hG.differentiable (by norm_num)) + (hFd x hxU) (hGd x hxU) (hn x hxU) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +def delayedEndingTensor (lam k J L K R : ℝ) (x : Coord3) : Mat3 := + alignedEndingTensor lam k J L K (x-Pi.single 0 R) + +def delayedEndingPotential (lam k J L K R : ℝ) (i j : Fin 3) (x : Coord3) : ℝ := + exp (-lam*R)*alignedEndingPotential lam k J L K i j (x-Pi.single 0 R) + +lemma delayedEndingPotential_C2 {lam k J L K R : ℝ} (hJ : 0 -delayedEndingPotential lam k J L K R j i x := by + funext x + rw [delayedEndingPotential,alignedEndingPotential_antisymm] + simp [delayedEndingPotential] + +lemma delayedEnding_direction {lam k J L K R : ℝ} (hJ : 0 (alignedEndingPotential_C2 (lam:=lam) (k:=k) hJ hL hK i j).differentiable (by norm_num)) + (exp (-lam*R)) 1 (Pi.single 0 R) x i) + +lemma delayedEnding_constitution_ae {lam k J L K R : ℝ} (hk : k≠0) (hJ : 0 direction (Pi.single i 1) (delayedEndingValue lam k J L K R) x)= + potentialCurl (delayedEndingPotential lam k J L K R) x := by + have hh := (measurePreserving_add_right (volume : Measure Coord3) (-Pi.single 0 R)).quasiMeasurePreserving.ae + (alignedEnding_constitution_ae (lam:=lam) hk hJ hL hK) + filter_upwards [hh] with x hx + simp only [←sub_eq_add_neg] at hx + ext i + simp only [delayedEnding_direction hJ hL hK,delayedEnding_curl hJ hL hK] + change (delayedEndingTensor lam k J L K R x*ᵥ(exp (-lam*R) • + (fun j => direction (Pi.single j 1) (alignedEndingValue lam k J L K) (x-Pi.single 0 R)))) i=_ + rw [Matrix.mulVec_smul,delayedEndingTensor,hx] + rfl + +lemma delayedEndingFlux_C1 {lam k J L K R : ℝ} (hJ : 0 Pi.single i 1) (delayedEndingPotential lam k J L K R) + (delayedEndingPotential_C2 hJ hL hK) (delayedEndingPotential_antisymm lam k J L K R) x + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/BranchTerminalFluxIntegral.lean b/lean/OAI/Analysis/Conductivity/Flux/BranchTerminalFluxIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..0fcd66d2893c04b2d0fbb8b38cad6f8717e7ed9b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/BranchTerminalFluxIntegral.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.BranchFiniteEnding +import OAI.Analysis.Conductivity.Fourier.SpectralAffineCovector +import OAI.Analysis.Conductivity.Fourier.SpectralTerminalIntegral + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped ENNReal +local instance branchTerminalFluxIntegralMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance branchTerminalFluxIntegralProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma torusAffineField_flux_normal {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) {R : ℝ} (hR : 0 torusSpectralSynthesis s (f j)))) + (j : Fin 2) {R : ℝ} (hR : 0 φ (sourceAngularCollar b θ)) := + (hφ.continuous.comp (continuous_sourceAngularCollar b)).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + obtain ⟨hi,hI⟩ := fullEndFlatCovector_terminal_integral hs hR (f j) (centralBasisSlopes j i) b hφ + rw [integral_sub (hq.const_mul _) hi,integral_const_mul,hI,smoothCollarTrace_mean_integral] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/C1WeakDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/C1WeakDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..10252fb85ea4977cb47a013aefdb7a2e9c0856de --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/C1WeakDivergence.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.AntisymmetricFlux + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +lemma direction_continuous {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} (hf : ContDiff ℝ 1 f) (v : E) : Continuous (direction v f) := by + have hd : ContDiff ℝ 0 (fderiv ℝ f) := hf.fderiv_right (by norm_num) + exact hd.continuous.clm_apply continuous_const + +theorem C1_divergence_zero_test + {E ι : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] [Fintype ι] + (μ : Measure E) [μ.IsAddHaarMeasure] (v : ι → E) (F : ι → E → ℝ) + (hF : ∀ i, ContDiff ℝ 1 (F i)) + (hdiv : ∀ x, ∑ i, direction (v i) (F i) x = 0) + (ψ : SmoothScalar E) (hc : HasCompactSupport ψ.val) : + (∫ x, ∑ i, F i x*(smoothDirection (v i) ψ).val x ∂μ) = 0 := by + have hp := smoothScalar_contDiff ψ + have hI (i : ι) : Integrable (fun x => F i x*(smoothDirection (v i) ψ).val x) μ := + ((hF i).continuous.mul (smoothScalar_contDiff (smoothDirection (v i) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (v i) hc).mul_left + have hI' (i : ι) : Integrable (fun x => ψ.val x*direction (v i) (F i) x) μ := + (hp.continuous.mul (direction_continuous (hF i) _)).integrable_of_hasCompactSupport hc.mul_right + have hibp (i : ι) : (∫ x, F i x*(smoothDirection (v i) ψ).val x ∂μ) = + -(∫ x, ψ.val x*direction (v i) (F i) x ∂μ) := by + have hh := integral_bilinear_hasFDerivAt_right_eq_neg_left_of_integrable + (B := ContinuousLinearMap.mul ℝ ℝ) + (f := F i) (g := ψ.val) (v := v i) + (show Integrable (fun x => direction (v i) (F i) x*ψ.val x) μ by + simpa only [mul_comm] using hI' i) + (hI i) + (((hF i).continuous.mul hp.continuous).integrable_of_hasCompactSupport hc.mul_left) + (fun x _ => ((hF i).differentiable (by norm_num) x).hasFDerivAt) + (fun x _ => (hp.differentiable (by simp) x).hasFDerivAt) + change (∫ x, F i x * (fderiv ℝ ψ.val x) (v i) ∂μ) = + -(∫ x, (fderiv ℝ (F i) x) (v i) * ψ.val x ∂μ) at hh + simpa only [direction,smoothDirection_apply,mul_comm] using hh + rw [integral_finsetSum _ (fun i _ => hI i)] + simp_rw [hibp] + rw [Finset.sum_neg_distrib,←integral_finsetSum _ (fun i _ => hI' i)] + have hz : (fun x => ∑ i, ψ.val x*direction (v i) (F i) x) = fun _ => (0:ℝ) := by + funext x + rw [←Finset.mul_sum,hdiv x,mul_zero] + rw [hz,integral_zero,neg_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CascadeFluxLocal.lean b/lean/OAI/Analysis/Conductivity/Flux/CascadeFluxLocal.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ea2b516be50560f0e162f4562a483aa1e23d121 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CascadeFluxLocal.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.AntisymmetricFlux +import OAI.Analysis.Conductivity.Branching.CascadeLocality + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def cascadePotentialTerm (L K k A : ℝ) (n : ℕ) (i j : Fin 3) (x : Coord3) : ℝ := + (A*cascadeRatio L K^n)*cascadePotentialMother L K (cascadeAxis n) (cascadeAxis (n+1)) i j + ((k*2^n) • (x-cascadeCenter (cascadeLength L K) k n)) + +lemma cascadePotentialTerm_inactive {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (A : ℝ) (x : Coord3) {m n : ℕ} + (hm₁ : -L/8 < cascadePhase (cascadeLength L K) k m (x 0)) + (hm₂ : cascadePhase (cascadeLength L K) k m (x 0) < cascadeLength L K+L/8) + (hn : n≠m) (hn' : n≠m+1) (i j : Fin 3) : + cascadePotentialTerm L K k A n i j x = 0 := by + obtain ⟨_,hb,hc⟩ := cascadeMother_inactive_wide hL hK hk x hm₁ hm₂ hn hn' + simp [cascadePotentialTerm,cascadePotentialMother,hb,hc] + +lemma cascadePotential_two_terms {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (A : ℝ) (x : Coord3) {m : ℕ} + (hm₁ : -L/8 < cascadePhase (cascadeLength L K) k m (x 0)) + (hm₂ : cascadePhase (cascadeLength L K) k m (x 0) < cascadeLength L K+L/8) + (i j : Fin 3) : cascadePotential L K k A i j x = + cascadePotentialTerm L K k A m i j x + cascadePotentialTerm L K k A (m+1) i j x := by + have he : (∑' n : ℕ, cascadePotentialTerm L K k A n i j x) = + ∑ n ∈ ({m,m+1} : Finset ℕ), cascadePotentialTerm L K k A n i j x := + tsum_eq_sum (s := ({m,m+1} : Finset ℕ)) (fun n hn => + cascadePotentialTerm_inactive hL hK hk A x hm₁ hm₂ + (by simpa using fun h => hn (by simp [h])) + (by simpa using fun h => hn (by simp [h])) i j) + simpa [cascadePotential,cascadePotentialTerm,Finset.sum_pair (show m≠m+1 by omega)] using he + +lemma cascade_stage_nhds {L K k : ℝ} (hL : 0 < L) (x : Coord3) {m : ℕ} + (hm₁ : 0 ≤ cascadePhase (cascadeLength L K) k m (x 0)) + (hm₂ : cascadePhase (cascadeLength L K) k m (x 0) ≤ cascadeLength L K) : + {y : Coord3 | -L/8 < cascadePhase (cascadeLength L K) k m (y 0) ∧ + cascadePhase (cascadeLength L K) k m (y 0) < cascadeLength L K+L/8} ∈ 𝓝 x := by + have hc : Continuous (fun y : Coord3 => cascadePhase (cascadeLength L K) k m (y 0)) := by + unfold cascadePhase + fun_prop + exact (hc.isOpen_preimage _ isOpen_Ioo).mem_nhds ⟨by linarith,by linarith⟩ + +lemma cascadePotential_eventually_two_terms {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (A : ℝ) (x : Coord3) {m : ℕ} + (hm₁ : 0 ≤ cascadePhase (cascadeLength L K) k m (x 0)) + (hm₂ : cascadePhase (cascadeLength L K) k m (x 0) ≤ cascadeLength L K) + (i j : Fin 3) : cascadePotential L K k A i j =ᶠ[𝓝 x] + fun y => cascadePotentialTerm L K k A m i j y + cascadePotentialTerm L K k A (m+1) i j y := by + filter_upwards [cascade_stage_nhds hL x hm₁ hm₂] with y hy + exact cascadePotential_two_terms hL hK hk A y hy.1 hy.2 i j + +lemma cascadePotential_terminal {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (A : ℝ) (x : Coord3) (ht : 2*cascadeLength L K ≤ k*x 0) (i j : Fin 3) : + cascadePotential L K k A i j x = 0 := by + have hh (n : ℕ) : cascadePotentialTerm L K k A n i j x = 0 := by + let y := (k*2^n) • (x-cascadeCenter (cascadeLength L K) k n) + have hy : K+2+7*L/4 < y 0 := by + dsimp only [y] + rw [cascade_dilation_time hk,cascadePhase] + have hp : 0 ≤ (2:ℝ)^n*(k*x 0-2*cascadeLength L K) := mul_nonneg (by positivity) (by linarith) + unfold cascadeLength at * + linarith + have hb := cascadeBaseStream_zero hL (cascadeAxis n) y (Or.inr hy) + have hc := cascadeCrossStream_zero_right hL (cascadeAxis n) (cascadeAxis (n+1)) y hy + change (A*cascadeRatio L K^n)*cascadePotentialMother L K (cascadeAxis n) (cascadeAxis (n+1)) i j y=0 + simp [cascadePotentialMother,hb,hc] + change (∑' n : ℕ, cascadePotentialTerm L K k A n i j x)=0 + simp only [hh,tsum_zero] + +lemma cascadeFlux_terminal_strict {L K k : ℝ} (hL : 0 < L) (hK : 0 < K) (hk : k≠0) + (A : ℝ) (x : Coord3) (ht : 2*cascadeLength L K < k*x 0) (i : Fin 3) : + cascadeFlux L K k A x i = 0 := by + have hn : {y : Coord3 | 2*cascadeLength L K < k*y 0} ∈ 𝓝 x := + (isOpen_lt continuous_const (continuous_const.mul (continuous_apply 0))).mem_nhds ht + unfold cascadeFlux + apply Finset.sum_eq_zero + intro j _ + have he : cascadePotential L K k A i j =ᶠ[𝓝 x] fun _ => (0:ℝ) := by + filter_upwards [hn] with y hy + exact cascadePotential_terminal hL hK hk A y hy.le i j + simp [direction,he.fderiv_eq] + +lemma cascadeFlux_terminal {L K k : ℝ} (hL : 1 ≤ L) (hK : 0 < K) (hk : 0 < k) + (A : ℝ) (x : Coord3) (ht : 2*cascadeLength L K ≤ k*x 0) (i : Fin 3) : + cascadeFlux L K k A x i = 0 := by + have hcont : Continuous (fun r : ℝ => cascadeFlux L K k A (x+r • Pi.single 0 1) i) := + (cascadeFlux_C1 hL hK k A i).continuous.comp + (continuous_const.add (continuous_id.smul continuous_const)) + have hlim : Tendsto (fun r : ℝ => cascadeFlux L K k A (x+r • Pi.single 0 1) i) + (𝓝[>] (0:ℝ)) (𝓝 (cascadeFlux L K k A x i)) := by + simpa only [ContinuousWithinAt,zero_smul,add_zero] using (hcont.continuousAt (x := (0:ℝ))).continuousWithinAt (s := Ioi (0:ℝ)) + have he : (fun r : ℝ => cascadeFlux L K k A (x+r • Pi.single 0 1) i) =ᶠ[𝓝[>] (0:ℝ)] + fun _ => (0:ℝ) := by + filter_upwards [self_mem_nhdsWithin] with r hr + apply cascadeFlux_terminal_strict (lt_of_lt_of_le (by norm_num) hL) hK hk.ne' A + simp only [Pi.add_apply,Pi.smul_apply,Pi.single_eq_same,smul_eq_mul,mul_one] + have hp : 0 < k*r := mul_pos hk hr + nlinarith + exact tendsto_nhds_unique hlim (tendsto_const_nhds.congr' he.symm) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CascadeStageCurl.lean b/lean/OAI/Analysis/Conductivity/Flux/CascadeStageCurl.lean new file mode 100644 index 0000000000000000000000000000000000000000..08f5172b77ec9fdddec9e5b238fa27dbed1b7b3e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CascadeStageCurl.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CascadeFluxLocal +import OAI.Analysis.Conductivity.Branching.CascadeProfileDeriv +import OAI.Analysis.Conductivity.Flux.PotentialCurl + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +lemma cascadeAxis_ne_succ (m : ℕ) : cascadeAxis m ≠ cascadeAxis (m+1) := by + rw [cascadeAxis_succ] + unfold cascadeAxis + split <;> decide + +lemma cascade_dilation_coord (D k : ℝ) (m : ℕ) (x : Coord3) {a : Fin 3} (ha : a≠0) : + ((k*2^m) • (x-cascadeCenter D k m)) a = k*2^m*x a := by + simp [cascadeCenter,Pi.single_eq_of_ne ha] + +lemma cascade_dilation_succ {k : ℝ} (hk : k≠0) (D : ℝ) (m : ℕ) (x : Coord3) : + (k*2^(m+1)) • (x-cascadeCenter D k (m+1)) = + (2:ℝ) • (((k*2^m) • (x-cascadeCenter D k m))-Pi.single 0 D) := by + ext a + by_cases ha : a=0 + · subst a + change ((k*2^(m+1)) • (x-cascadeCenter D k (m+1))) 0 = + 2*(((k*2^m) • (x-cascadeCenter D k m)) 0-D) + rw [cascade_dilation_time hk,cascade_dilation_time hk,cascadePhase_succ] + · change ((k*2^(m+1)) • (x-cascadeCenter D k (m+1))) a = + 2*(((k*2^m) • (x-cascadeCenter D k m)) a-(Pi.single 0 D : Coord3) a) + rw [cascade_dilation_coord _ _ _ _ ha,cascade_dilation_coord _ _ _ _ ha, + Pi.single_eq_of_ne ha,pow_succ] + ring + +lemma cascadePotentialMother_wedges (L K : ℝ) (a b i j : Fin 3) (x : Coord3) : + cascadePotentialMother L K a b i j x = + wedgePotential 0 a (cascadeBaseStream L K a) i j x + + wedgePotential a b (cascadeCrossStream L K a b) i j x := by + unfold cascadePotentialMother wedgePotential + ring + +lemma wedgePotential_scalar (a b i j : Fin 3) (c : ℝ) (H : Coord3 → ℝ) (x : Coord3) : + wedgePotential a b (fun y => c*H y) i j x = c*wedgePotential a b H i j x := by + unfold wedgePotential + split <;> split <;> ring + +lemma wedgePotential_as_mul (a b i j : Fin 3) (H : Coord3 → ℝ) (x : Coord3) : + wedgePotential a b H i j x = + ((if i=a ∧ j=b then (1:ℝ) else 0)-(if j=a ∧ i=b then (1:ℝ) else 0))*H x := by + unfold wedgePotential + split <;> split <;> ring + +lemma cascade_stage_potential_crossing {L K : ℝ} (hL : 0 fin_cases b <;> simp_all + +lemma crossingTensor_symm (L : ℝ) (a b : Fin 3) (x : Coord3) : + (crossingTensor L a b x).IsSymm := by + ext i j + simp only [transpose_apply,crossingTensor] + simp_rw [and_comm] + ring + +lemma crossingTensor_quadratic {a b : Fin 3} (ha : a≠0) (hb : b≠0) (hab : a≠b) + (L : ℝ) (x v : Coord3) : + v ⬝ᵥ (crossingTensor L a b x *ᵥ v) = + (v 0)^2 + crossingXX L (x 0) (x a) (x b)*(v a)^2+ + 2*crossingXY L (x 0) (x a) (x b)*v a*v b+ + crossingYY L (x 0) (x a) (x b)*(v b)^2 := by + rcases cubic_axes ha hb hab with ⟨rfl,rfl⟩ | ⟨rfl,rfl⟩ <;> + simp [dotProduct,Fin.sum_univ_three,crossingTensor_mulVec] <;> ring + +lemma dotProduct_cubic_axes {a b : Fin 3} (ha : a≠0) (hb : b≠0) (hab : a≠b) (v : Coord3) : + v ⬝ᵥ v = (v 0)^2+(v a)^2+(v b)^2 := by + rcases cubic_axes ha hb hab with ⟨rfl,rfl⟩ | ⟨rfl,rfl⟩ <;> + simp [dotProduct,Fin.sum_univ_three] <;> ring + +lemma crossingTensor_bounds {L : ℝ} + (hL : ∀ z x y X Y : ℝ, + (1/8)*(X^2+Y^2) ≤ crossingXX L z x y*X^2+2*crossingXY L z x y*X*Y+crossingYY L z x y*Y^2 ∧ + crossingXX L z x y*X^2+2*crossingXY L z x y*X*Y+crossingYY L z x y*Y^2 ≤ 10*(X^2+Y^2)) + {a b : Fin 3} (ha : a≠0) (hb : b≠0) (hab : a≠b) (x v : Coord3) : + (1/8)*(v ⬝ᵥ v) ≤ v ⬝ᵥ (crossingTensor L a b x *ᵥ v) ∧ + v ⬝ᵥ (crossingTensor L a b x *ᵥ v) ≤ 10*(v ⬝ᵥ v) := by + rw [crossingTensor_quadratic ha hb hab,dotProduct_cubic_axes ha hb hab] + obtain ⟨hl,hu⟩ := hL (x 0) (x a) (x b) (v a) (v b) + constructor <;> nlinarith [sq_nonneg (v 0)] + +lemma pureModeTensor_symm (q : ℝ) (a : Fin 3) : (pureModeTensor q a).IsSymm := by + exact isSymm_diagonal _ + +lemma pureModeTensor_normal {a : Fin 3} (ha : a≠0) (q : ℝ) : + pureModeTensor q a *ᵥ (Pi.single 0 1 : Coord3) = Pi.single 0 1 := by + ext i + rw [pureModeTensor,mulVec_diagonal] + by_cases hi : i=0 + · subst i; simp [Ne.symm ha] + · simp [Pi.single_eq_of_ne hi] + +lemma crossingTensor_normal {a b : Fin 3} (ha : a≠0) (hb : b≠0) + (L : ℝ) (x : Coord3) : + crossingTensor L a b x *ᵥ (Pi.single 0 1 : Coord3) = Pi.single 0 1 := by + ext i + rw [crossingTensor_mulVec] + simp [ha,hb,Pi.single_eq_of_ne,Pi.single_apply,eq_comm] + +lemma crossingTensor_continuous (L : ℝ) (a b : Fin 3) : + Continuous (crossingTensor L a b) := by + have hf := (crossingResidualFirst_smooth L).continuous + have hg := (crossingResidualSecond_smooth L).continuous + have hff := (crossingFirst_smooth L).continuous + have hgg := (crossingSecond_smooth L).continuous + have hxx : Continuous (fun x : Coord3 => crossingXX L (x 0) (x a) (x b)) := by + unfold crossingXX crossingHxx + fun_prop (disch := intro x; positivity) + have hyy : Continuous (fun x : Coord3 => crossingYY L (x 0) (x a) (x b)) := by + unfold crossingYY crossingHxx + fun_prop (disch := intro x; positivity) + have hxy : Continuous (fun x : Coord3 => crossingXY L (x 0) (x a) (x b)) := by + unfold crossingXY crossingHxy + fun_prop (disch := intro x; positivity) + apply continuous_pi; intro i + apply continuous_pi; intro j + unfold crossingTensor + split_ifs <;> fun_prop + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CascadeTensorLocality.lean b/lean/OAI/Analysis/Conductivity/Flux/CascadeTensorLocality.lean new file mode 100644 index 0000000000000000000000000000000000000000..c8b70a36284d21d12ef045033f2d086f50bc2010 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CascadeTensorLocality.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CascadeCoefficient + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma cascadeIndex_eq_of_strict_phase {D k : ℝ} (hD : 0 (connectorProfile_pos K x).ne') + +lemma crossingValue3_smooth (L : ℝ) (a b : Fin 3) : + ContDiff ℝ (↑(⊤:ℕ∞)) (crossingValue3 L a b) := by + have hf := crossingFirst_smooth L + have hg := crossingSecond_smooth L + unfold crossingValue3 crossingValue + fun_prop + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CentralCylinderGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/CentralCylinderGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..4355eeb5563e5f489463388c046fd8132624751b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CentralCylinderGreen.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralJetIdentity +import OAI.Analysis.Conductivity.Flux.CylinderSlopeGreen + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma central_cylinder_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (slopes R : Fin 3 → ℝ) (hR : ∀ i,0 + (centralNeighborhoodCompletion s hs ha₀ ha p).val x+ + centralSlopeJet a slopes (WithLp.ofLp x))) ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈centralPhysical → + w.val x=centralFullJetCLM s p.val x) ∧ + (∀ (R : Fin 3 → ℝ) (hR : ∀ i,0 ⟨?_,?_⟩⟩ + · intro i + exact cylinderEndJet_mem_graph s hs (slopes i) (R i) (hR i).le (centralT s i p) + · intro v z hz + exact central_cylinder_green s hs slopes R hR p hvar v z hz + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +def flatCylinderMatrix (s : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + ![![1,0,0],![0,s 0,s 1],![0,s 1,s 2]] + +lemma flatCylinderMatrix_symmetric (s : Fin 3 → ℝ) : + (flatCylinderMatrix s)ᵀ=flatCylinderMatrix s := by + ext i j + fin_cases i <;> fin_cases j <;> rfl + +lemma flatCylinderMatrix_energy (s v : Fin 3 → ℝ) : + v ⬝ᵥ (flatCylinderMatrix s *ᵥ v)= + (v 0)^2+s 0*(v 1)^2+2*s 1*v 1*v 2+s 2*(v 2)^2 := by + simp [flatCylinderMatrix,Matrix.mulVec,dotProduct,Fin.sum_univ_succ] + ring + +lemma flatCylinderMatrix_coercive (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (v : Fin 3 → ℝ) : + (1/2)*(∑ k : Fin 3,(v k)^2)≤v ⬝ᵥ (flatCylinderMatrix s *ᵥ v) := by + rw [flatCylinderMatrix_energy] + simp only [Fin.sum_univ_succ,Fin.succ_zero_eq_one, + Fin.succ_one_eq_two,Fin.isValue,Finset.univ_eq_empty,Finset.sum_empty,add_zero] + nlinarith [hs (v 1) (v 2),sq_nonneg (v 0)] + +lemma sourceFaceAngleMatrix_det (i j : Fin 4) (x : Fin 3 → ℝ) : + (sourceFaceAngleMatrix i j x).det= + angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2) := by + rw [sourceFaceAngleMatrix,Matrix.det_diagonal] + simp [Fin.prod_univ_succ,angularArea] + ring + +lemma sourceFaceAngleMatrix_det_pos (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + 0<(sourceFaceAngleMatrix i j x).det := by + obtain ⟨_,ha,hb⟩ := mem_sourceExtendedBox.mp hx + rw [sourceFaceAngleMatrix_det] + have h0 := (faceRayDensityLower_pos (w:=1) (by norm_num)).trans_le + (faceRayDensity_lower (w:=1) (by norm_num) i ha) + have hw : 0 rfl + +lemma central_smooth_integration_by_parts {f ψ : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) + (hc : HasCompactSupport ψ) (hs : tsupport ψ⊆centralClosed) (v : Box3) : + (∫ x,ψ x*fderiv ℝ f x v ∂centralMeasure)= + -(∫ x,fderiv ℝ ψ x v*f x ∂centralMeasure) := by + have hdf : Continuous (fun x => fderiv ℝ f x v) := + (hf.continuous_fderiv (by simp)).clm_apply continuous_const + have hdψ : Continuous (fun x => fderiv ℝ ψ x v) := + (hψ.continuous_fderiv (by simp)).clm_apply continuous_const + let : (volume : Measure Box3).IsAddHaarMeasure := + Measure.prod.instIsAddHaarMeasure (volume : Measure (ℝ×ℝ)) (volume : Measure ℝ) + have he := integral_mul_fderiv_eq_neg_fderiv_mul_of_integrable (μ := volume) + (f := ψ) (g := f) (v := v) + ((hdψ.mul hf.continuous).integrable_of_hasCompactSupport (hc.fderiv_apply ℝ v).mul_right) + ((hψ.continuous.mul hdf).integrable_of_hasCompactSupport hc.mul_right) + ((hψ.continuous.mul hf.continuous).integrable_of_hasCompactSupport hc.mul_right) + (fun x _ => hψ.differentiable (by simp) x) + (fun x _ => hf.differentiable (by simp) x) + have hl : (∫ x,ψ x*fderiv ℝ f x v ∂centralMeasure)=∫ x,ψ x*fderiv ℝ f x v := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + rw [image_eq_zero_of_notMem_tsupport (fun hh => hx (hs hh)),zero_mul] + have hr : (∫ x,fderiv ℝ ψ x v*f x ∂centralMeasure)=∫ x,fderiv ℝ ψ x v*f x := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + rw [fderiv_of_notMem_tsupport ℝ (fun hh => hx (hs hh))] + simp + rw [hl,hr] + exact he + +def centralAmbientComponent (s : Fin 3 → ℝ) (i : Fin 4) : + CentralAmbient s →L[ℝ] CentralL2 := + (PiLp.proj 2 (fun _ : Fin 4 => CentralL2) i).comp (centralAmbientJ s) + +theorem central_distributional_derivative (s : Fin 3 → ℝ) + (u : centralEnergySpace s) (ψ : centralSmoothFunctions) + (hc : HasCompactSupport ψ) (hs : tsupport ψ⊆centralClosed) (i : Fin 3) : + inner ℝ (centralSmoothJet ψ 0) (centralAmbientComponent s i.succ u.val)= + -inner ℝ (centralSmoothJet ψ i.succ) (centralAmbientComponent s 0 u.val) := by + have hclosed : IsClosed {z : CentralAmbient s | + inner ℝ (centralSmoothJet ψ 0) (centralAmbientComponent s i.succ z)= + -inner ℝ (centralSmoothJet ψ i.succ) (centralAmbientComponent s 0 z)} := + isClosed_eq (continuous_const.inner (centralAmbientComponent s i.succ).continuous) + ((continuous_const.inner (centralAmbientComponent s 0).continuous).neg) + apply closure_minimal _ hclosed u.property + rintro z ⟨f,rfl⟩ + change inner ℝ (centralSmoothJet ψ 0) (centralSmoothJet f i.succ)= + -inner ℝ (centralSmoothJet ψ i.succ) (centralSmoothJet f 0) + rw [L2.inner_def,L2.inner_def] + have hl : (∫ x,inner ℝ (centralSmoothJet ψ 0 x) (centralSmoothJet f i.succ x) ∂centralMeasure)= + ∫ x,ψ x*fderiv ℝ f x (centralDirection i) ∂centralMeasure := by + apply integral_congr_ae + filter_upwards [centralSmoothJet_ae ψ 0,centralSmoothJet_ae f i.succ] with x hx hy + rw [hx,hy,centralJetField_succ] + simp only [centralJetField,Matrix.cons_val_zero,Real.inner_apply,cubePartial] + have hr : (∫ x,inner ℝ (centralSmoothJet ψ i.succ x) (centralSmoothJet f 0 x) ∂centralMeasure)= + ∫ x,fderiv ℝ ψ x (centralDirection i)*f x ∂centralMeasure := by + apply integral_congr_ae + filter_upwards [centralSmoothJet_ae ψ i.succ,centralSmoothJet_ae f 0] with x hx hy + rw [hx,hy,centralJetField_succ] + simp only [centralJetField,Matrix.cons_val_zero,Real.inner_apply,cubePartial,mul_comm] + rw [hl,hr] + exact central_smooth_integration_by_parts (central_smooth f) (central_smooth ψ) hc hs _ + +def centralSmoothElement (s : Fin 3 → ℝ) (f : centralSmoothFunctions) : centralEnergySpace s := + ⟨centralEmbedL s f,(LinearMap.range (centralEmbedL s)).le_topologicalClosure ⟨f,rfl⟩⟩ + +lemma central_trace_zero (s : Fin 3 → ℝ) (ψ : centralSmoothFunctions) (i : Fin 3) + (hz : ∀ x,ψ (centralBoundary i x)=0) : centralT s i (centralSmoothElement s ψ)=0 := by + apply spectralTraceGraph_fst_injective (torusRate s) + change (centralSmoothTrace s ψ i).val 0=0 + rw [centralSmoothTrace_fst] + apply norm_eq_zero.mp + have hn := centralTraceFourier_norm ψ i + simp only [hz,zero_pow (by decide : 2≠0),integral_zero] at hn + nlinarith only [hn,norm_nonneg (centralTraceFourier ψ i)] + +def CentralVariationalEquation (s slopes : Fin 3 → ℝ) (p : centralEnergySpace s) : Prop := + ∀ v : centralEnergySpace s, + inner ℝ (centralD s p) (centralD s v)+ + angularArea*(∑ i : Fin 3,inner ℝ (spectralGraphWeight (torusRate s) (centralT s i p)) + (spectralGraphWeight (torusRate s) (centralT s i v)))= + angularArea*(∑ i : Fin 3,slopes i*spectralGraphMean (torusRate s) (centralT s i v)) + +theorem central_variational_weak_interior (s slopes : Fin 3 → ℝ) + (hs : ∑ i,slopes i=0) : + ∃ p : centralEnergySpace s,centralM s p=0 ∧ CentralVariationalEquation s slopes p ∧ + ∀ ψ : centralSmoothFunctions,(∀ (i : Fin 3) x,ψ (centralBoundary i x)=0) → + inner ℝ (centralD s p) (centralJetD (centralSmoothJet ψ))=0 := by + obtain ⟨p,hp,hvar,_⟩ := central_unnormalized_variational_exists s slopes hs + refine ⟨p,hp,hvar,?_⟩ + intro ψ hψ + have he := hvar (centralSmoothElement s ψ) + have ht (i : Fin 3) := central_trace_zero s ψ i (hψ i) + have hd : centralD s (centralSmoothElement s ψ)=centralJetD (centralSmoothJet ψ) := rfl + rw [hd] at he + simpa only [ht,map_zero,inner_zero_right,mul_zero,Finset.sum_const_zero,add_zero] using he + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CentralDistributionLaplacian.lean b/lean/OAI/Analysis/Conductivity/Flux/CentralDistributionLaplacian.lean new file mode 100644 index 0000000000000000000000000000000000000000..5257086e6327681d229b911f3e4e187949d2421d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CentralDistributionLaplacian.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactRegularCorrection +import OAI.Analysis.Conductivity.Flux.CentralDistribution + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def centralLaplacian (f : Box3 → ℝ) (x : Box3) : ℝ := + ∑ i : Fin 3,cubePartial (cubePartial f (centralDirection i)) (centralDirection i) x + +def centralSmoothPartial (f : centralSmoothFunctions) (i : Fin 3) : centralSmoothFunctions := + ⟨cubePartial f (centralDirection i),cubePartial_smooth (central_smooth f) _⟩ + +lemma centralSmoothPartial_jet_zero (f : centralSmoothFunctions) (i : Fin 3) : + centralSmoothJet (centralSmoothPartial f i) 0=centralSmoothJet f i.succ := by + apply Lp.ext + filter_upwards [centralSmoothJet_ae (centralSmoothPartial f i) 0, + centralSmoothJet_ae f i.succ] with x hx hy + rw [hx,hy,centralJetField_succ] + rfl + +theorem central_variational_distributional_laplacian (s slopes : Fin 3 → ℝ) + (hs : ∑ i,slopes i=0) : + ∃ p : centralEnergySpace s,centralM s p=0 ∧ CentralVariationalEquation s slopes p ∧ + ∀ ψ : centralSmoothFunctions,HasCompactSupport ψ → tsupport ψ⊆centralClosed → + (∀ (i : Fin 3) x,ψ (centralBoundary i x)=0) → + (∫ x,(centralAmbientComponent s 0 p.val) x*centralLaplacian ψ x ∂centralMeasure)=0 := by + obtain ⟨p,hp,hvar,hweak⟩ := central_variational_weak_interior s slopes hs + refine ⟨p,hp,hvar,?_⟩ + intro ψ hc hsp hboundary + have he := hweak ψ hboundary + rw [PiLp.inner_apply] at he + have hparts (i : Fin 3) : + inner ℝ (centralSmoothJet ψ i.succ) (centralAmbientComponent s i.succ p.val)= + -inner ℝ (centralSmoothJet (centralSmoothPartial ψ i) i.succ) + (centralAmbientComponent s 0 p.val) := by + have hd := central_distributional_derivative s p (centralSmoothPartial ψ i) + (cubePartial_compact hc _) ((tsupport_fderiv_apply_subset ℝ _).trans hsp) i + rwa [centralSmoothPartial_jet_zero] at hd + have hsum : (∑ i : Fin 3,inner ℝ (centralSmoothJet (centralSmoothPartial ψ i) i.succ) + (centralAmbientComponent s 0 p.val))=0 := by + have hrew (i : Fin 3) : + inner ℝ (centralD s p i) (centralJetD (centralSmoothJet ψ) i)= + -inner ℝ (centralSmoothJet (centralSmoothPartial ψ i) i.succ) + (centralAmbientComponent s 0 p.val) := by + rw [real_inner_comm] + exact hparts i + simp only [hrew,Finset.sum_neg_distrib,neg_eq_zero] at he + exact he + have hint (i : Fin 3) : + inner ℝ (centralSmoothJet (centralSmoothPartial ψ i) i.succ) (centralAmbientComponent s 0 p.val)= + ∫ x,(centralAmbientComponent s 0 p.val) x* + cubePartial (cubePartial ψ (centralDirection i)) (centralDirection i) x ∂centralMeasure := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [centralSmoothJet_ae (centralSmoothPartial ψ i) i.succ] with x hx + rw [hx,centralJetField_succ,Real.inner_apply] + exact mul_comm _ _ + have hInt (i : Fin 3) : Integrable (fun x => (centralAmbientComponent s 0 p.val) x* + cubePartial (cubePartial ψ (centralDirection i)) (centralDirection i) x) centralMeasure := + (Lp.memLp _).integrable_mul (central_continuous_memLp + (cubePartial_smooth (cubePartial_smooth (central_smooth ψ) _) _).continuous) + simp only [hint] at hsum + simpa only [centralLaplacian,Finset.mul_sum,integral_finsetSum _ (fun i _ => hInt i)] using hsum + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/ChartTwoFluxLocalized.lean b/lean/OAI/Analysis/Conductivity/Flux/ChartTwoFluxLocalized.lean new file mode 100644 index 0000000000000000000000000000000000000000..4b2b4ecd963978543a3ba8b1cf524bb7c5e881fc --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/ChartTwoFluxLocalized.lean @@ -0,0 +1,172 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.LocalPiolaFluxSub +import OAI.Analysis.Conductivity.Geometry.InverseChartPiolaOperator +import OAI.Analysis.Conductivity.Sobolev.LocalPullback + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +theorem exists_chart_two_flux_localized + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (hdim : Module.finrank ℝ E = 3) (μ : Measure E) [μ.IsAddHaarMeasure] + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + (D : E →L[ℝ] (Fin 2 → ℝ)) (hD : Function.Surjective D) + (u : E → Fin 2 → ℝ) (hu : ∀ y ∈ X.source, D (X y) = u y) + (χ : SmoothScalar E) (hχ : HasCompactSupport χ.val) (hχs : tsupport χ.val ⊆ X.target) + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (h : SmoothScalar ℝ) (hp : Function.Periodic h.val 1) + (hm : ∫ t in (0 : ℝ)..1, h.val t = 0) + (R : Fin 2 → E) (hRs : D (R 0) 1 = D (R 1) 0) (hRn : ∀ j, L (R j) = 0) : + ∃ F : ℝ → Fin 2 → E → E, + (∀ k j, ContDiff ℝ (↑(⊤ : ℕ∞)) (F k j)) ∧ + (∀ k j, HasCompactSupport (F k j) ∧ tsupport (F k j) ⊆ X.source ∧ + tsupport (F k j) ⊆ X.symm '' tsupport χ.val) ∧ + (∀ k y, fderiv ℝ u y (F k 0 y) 1 = fderiv ℝ u y (F k 1 y) 0) ∧ + (∀ k j (ψ : E → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ y, fderiv ℝ ψ y (F k j y) ∂μ) = 0) ∧ + ∀ j, TendstoUniformly + (fun k y => F k j y - localPiolaFlux X.symm + (fun x => (χ.val x * h.val (k * L x)) • R j) y) (fun _ => 0) atTop := by + classical + obtain ⟨G, hg, hs, hsym, hdiv, he⟩ := exists_physical_two_flux hdim μ D hD + χ hχ L hL h hp hm R hRs hRn + have hc (k : ℝ) (j : Fin 2) : HasCompactSupport (G k j) := + hχ.of_isClosed_subset (isClosed_tsupport _) (hs k j) + have hgs (k : ℝ) (j : Fin 2) : tsupport (G k j) ⊆ X.target := (hs k j).trans hχs + refine ⟨fun k j => localPiolaFlux X.symm (G k j), ?_, ?_, ?_, ?_, ?_⟩ + · intro k j + exact localPiolaFlux_smooth X.symm hXi hX (G k j) (hg k j) (hc k j) (hgs k j) + · intro k j + refine ⟨localPiolaFlux_hasCompactSupport X.symm _ (hc k j) (hgs k j), + localPiolaFlux_tsupport X.symm _ (hc k j) (hgs k j), ?_⟩ + apply closure_minimal + ((localPiolaFlux_support X.symm (G k j)).trans + (image_mono (fun _ hx => hs k j (subset_closure hx.1)))) + ((hχ.image_of_continuousOn (X.symm.continuousOn.mono hχs)).isClosed) + · intro k y + by_cases hy : y ∈ X.source + · rw [localPiolaFlux_potential_pairing X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) D u hu (G k 0) hy, + localPiolaFlux_potential_pairing X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) D u hu (G k 1) hy] + simp only [Pi.smul_apply, smul_eq_mul, hsym] + · simp [localPiolaFlux, hy] + · intro k j ψ hψ + exact localPiolaFlux_zero_pairing μ X.symm hXi hX _ (hc k j) (hgs k j) (hdiv k j) ψ hψ + · intro j + apply localPiolaFlux_uniform_error X.symm hXi hX hχ hχs + (fun k => G k j) (fun k x => (χ.val x * h.val (k * L x)) • R j) _ (he j) + intro k x hx + by_contra hn + have hz : χ.val x = 0 := image_eq_zero_of_notMem_tsupport hn + have hgz : G k j x = 0 := image_eq_zero_of_notMem_tsupport (fun hx => hn (hs k j hx)) + apply hx + simp [hz, hgz] + +theorem exists_frozen_chart_two_flux + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (hdim : Module.finrank ℝ E = 3) (μ : Measure E) [μ.IsAddHaarMeasure] + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + (D : E →L[ℝ] (Fin 2 → ℝ)) (hD : Function.Surjective D) + (u : E → Fin 2 → ℝ) (hu : ∀ y ∈ X.source, D (X y) = u y) + {a : E} (ha : a ∈ X.source) (hDa : fderiv ℝ X a = ContinuousLinearMap.id ℝ E) + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (R : Fin 2 → E) (hRs : D (R 0) 1 = D (R 1) 0) (hRn : ∀ j, L (R j) = 0) + {ε : ℝ} (hε : 0 < ε) : + ∃ V : Set E, IsOpen V ∧ a ∈ V ∧ V ⊆ X.source ∧ + ∀ h : SmoothScalar ℝ, Function.Periodic h.val 1 → + (∫ t in (0 : ℝ)..1, h.val t = 0) → (∀ t, |h.val t| ≤ 1) → + ∀ χ : SmoothScalar E, HasCompactSupport χ.val → tsupport χ.val ⊆ X '' V → + (∀ x, 0 ≤ χ.val x ∧ χ.val x ≤ 1) → + ∃ F : ℝ → Fin 2 → E → E, + (∀ k j, ContDiff ℝ (↑(⊤ : ℕ∞)) (F k j)) ∧ + (∀ k j, HasCompactSupport (F k j) ∧ tsupport (F k j) ⊆ V ∧ + tsupport (F k j) ⊆ X.symm '' tsupport χ.val) ∧ + (∀ k y, fderiv ℝ u y (F k 0 y) 1 = fderiv ℝ u y (F k 1 y) 0) ∧ + (∀ k j (ψ : E → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ y, fderiv ℝ ψ y (F k j y) ∂μ) = 0) ∧ + ∀ᶠ k : ℝ in atTop, ∀ j y, + ‖F k j y - (localPullback X χ.val y * h.val (k * L (X y))) • R j‖ < ε := by + let B := ‖R 0‖ + ‖R 1‖ + 1 + have hB : 0 < B := by dsimp [B]; positivity + have hR : ∀ j, ‖R j‖ ≤ B := by + intro j + fin_cases j <;> dsimp [B] <;> linarith only [norm_nonneg (R 0), norm_nonneg (R 1)] + obtain ⟨V, hV, haV, hVs, hfreeze⟩ := inverseChartPiola_freezing X hX hXi ha hDa + (div_pos (half_pos hε) hB) + refine ⟨V, hV, haV, hVs, ?_⟩ + intro h hp hm hb χ hχ hχV hχb + have hχs : tsupport χ.val ⊆ X.target := by + rintro z hz + obtain ⟨y, hy, rfl⟩ := hχV hz + exact X.map_source (hVs hy) + obtain ⟨F, hF, hFs, hsym, hdiv, he⟩ := exists_chart_two_flux_localized hdim μ X hX hXi + D hD u hu χ hχ hχs L hL h hp hm R hRs hRn + have hFi : ∀ k j, tsupport (F k j) ⊆ V := by + intro k j y hy + obtain ⟨z, hz, rfl⟩ := (hFs k j).2.2 hy + obtain ⟨w, hw, rfl⟩ := hχV hz + simpa only [X.left_inv (hVs hw)] using hw + have hχi : tsupport (localPullback X χ.val) ⊆ V := by + intro y hy + obtain ⟨z, hz, rfl⟩ := (localPullback_tsupport X χ.val hχ hχs).2.1 hy + obtain ⟨w, hw, rfl⟩ := hχV hz + simpa only [X.left_inv (hVs hw)] using hw + refine ⟨F, hF, fun k j => ⟨(hFs k j).1, hFi k j, (hFs k j).2.2⟩, hsym, hdiv, ?_⟩ + have herr : ∀ᶠ k : ℝ in atTop, ∀ j y, + ‖F k j y - localPiolaFlux X.symm + (fun z => (χ.val z * h.val (k * L z)) • R j) y‖ < ε / 2 := by + apply Filter.eventually_all.mpr + intro j + simpa only [dist_zero_left] using (Metric.tendstoUniformly_iff.mp (he j)) _ (half_pos hε) + filter_upwards [herr] with k hk j y + by_cases hy : y ∈ V + · have hfr := hfreeze (localPullback X χ.val) (fun z => h.val (k * L z)) (R j) y hy + have hpre : localPiolaFlux X.symm + (fun z => (localPullback X χ.val (X.symm z) * h.val (k * L z)) • R j) y = + localPiolaFlux X.symm (fun z => (χ.val z * h.val (k * L z)) • R j) y := by + rw [localPiolaFlux_inverse_eq X _ (hVs hy), localPiolaFlux_inverse_eq X _ (hVs hy), + localPullback_comp X _ (X.map_source (hVs hy))] + rw [hpre] at hfr + have hcb := localPullback_bounds X χ.val hχb y + have habs : |localPullback X χ.val y * h.val (k * L (X y))| ≤ 1 := by + rw [abs_mul, abs_of_nonneg hcb.1] + exact (mul_le_mul_of_nonneg_left (hb _) hcb.1).trans (by simpa using hcb.2) + have hnorm : |localPullback X χ.val y * h.val (k * L (X y))| * ‖R j‖ ≤ B := + (mul_le_mul_of_nonneg_right habs (norm_nonneg _)).trans (by simpa using hR j) + have hsmall : ‖localPiolaFlux X.symm + (fun z => (χ.val z * h.val (k * L z)) • R j) y - + (localPullback X χ.val y * h.val (k * L (X y))) • R j‖ ≤ ε / 2 := + hfr.trans ((mul_le_mul_of_nonneg_left hnorm (div_pos (half_pos hε) hB).le).trans + (le_of_eq (div_mul_cancel₀ _ hB.ne'))) + exact (norm_sub_le_norm_sub_add_norm_sub (F k j y) _ _).trans_lt (by linarith only [hk j y, hsmall]) + · have hFz : F k j y = 0 := image_eq_zero_of_notMem_tsupport (fun hz => hy (hFi k j hz)) + have hχz : localPullback X χ.val y = 0 := + image_eq_zero_of_notMem_tsupport (fun hz => hy (hχi hz)) + simpa only [hFz, hχz, zero_mul, zero_smul, sub_zero, norm_zero] using hε + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CollarCartesianDifferential.lean b/lean/OAI/Analysis/Conductivity/Flux/CollarCartesianDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..7bf5a79234ee16799e7782ed0a975755fc3c1880 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CollarCartesianDifferential.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ExtendedCollar +import OAI.Analysis.Conductivity.Geometry.TorusFaceIntegration +import OAI.Analysis.Conductivity.Fourier.TorusPoissonContinuous + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix +open scoped Matrix.Norms.Elementwise + +def sourceFaceAngles (i j : Fin 4) (x : Fin 3 → ℝ) : Fin 3 → ℝ := + ![x 0,2*Real.pi*faceRayAngle 1 i (x 1), + 2*Real.pi*faceRayAngle sourceRadialWidth j (x 2)] + +def sourceFaceAngleMatrix (i j : Fin 4) (x : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + Matrix.diagonal ![1,2*Real.pi*faceRayDensity 1 i (x 1), + 2*Real.pi*faceRayDensity sourceRadialWidth j (x 2)] + +lemma sourceFaceAngles_torus (i j : Fin 4) (x : Fin 3 → ℝ) : + torusAngles (sourceFaceAngles i j x)= + ![((faceRayAngle 1 i (x 1):ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j (x 2):ℝ):UnitAddCircle)] := by + ext k + fin_cases k <;> simp [torusAngles,sourceFaceAngles,Real.pi_ne_zero] + +lemma sourceFaceAngles_hasFDeriv (i j : Fin 4) (x : Fin 3 → ℝ) : + HasFDerivAt (sourceFaceAngles i j) + (Matrix.toLin' (sourceFaceAngleMatrix i j x)).toContinuousLinearMap x := by + have h1 := ((hasDerivAt_faceRayAngle 1 i (x 1)).comp_hasFDerivAt x + (hasFDerivAt_apply (𝕜:=ℝ) 1 x)).const_mul (2*Real.pi) + have h2 := ((hasDerivAt_faceRayAngle sourceRadialWidth j (x 2)).comp_hasFDerivAt x + (hasFDerivAt_apply (𝕜:=ℝ) 2 x)).const_mul (2*Real.pi) + have hcoord (k : Fin 3) : HasFDerivAt (fun y => sourceFaceAngles i j y k) + ((ContinuousLinearMap.proj k : (Fin 3 → ℝ) →L[ℝ] ℝ).comp + (Matrix.toLin' (sourceFaceAngleMatrix i j x)).toContinuousLinearMap) x := by + fin_cases k + · convert! hasFDerivAt_apply (𝕜:=ℝ) (0:Fin 3) x using 1 + ext v + simp [sourceFaceAngleMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + · convert! h1 using 1 + ext v + simp [sourceFaceAngleMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + ring + · convert! h2 using 1 + ext v + simp [sourceFaceAngleMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + ring + convert! hasFDerivAt_pi.mpr hcoord using 1 + +lemma sourceFaceAngles_physical (i j : Fin 4) {x : Fin 3 → ℝ} + (ha : |x 1|≤1) (hb : |x 2|≤1) : + sourceAngularCollar (x 0) (torusAngles (sourceFaceAngles i j x))= + sourceCollarPiece i j x := by + rw [sourceFaceAngles_torus,sourceAngular_face _ _ _ _ _ ha hb] + congr 1 + ext k + fin_cases k <;> rfl + +lemma continuous_sourceCollarJacobian (i j : Fin 4) : Continuous (sourceCollarJacobian i j) := by + unfold sourceCollarJacobian sourceCollarRadius squareFace + fun_prop + +lemma continuous_sourceFaceAngleMatrix (i j : Fin 4) : Continuous (sourceFaceAngleMatrix i j) := by + apply continuous_pi + intro a + apply continuous_pi + intro b + by_cases hab : a=b + · subst b + fin_cases a <;> simp only [sourceFaceAngleMatrix,Matrix.diagonal_apply_eq] + · exact continuous_const + · exact continuous_const.mul ((continuous_faceRayDensity 1 i).comp (continuous_apply 1)) + · exact continuous_const.mul ((continuous_faceRayDensity sourceRadialWidth j).comp (continuous_apply 2)) + · simp only [sourceFaceAngleMatrix,Matrix.diagonal_apply_ne _ hab] + exact continuous_const + +lemma sourceCollarJacobian_extended_ne_zero (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + (sourceCollarJacobian i j x).det≠0 := by + have h := sourceExtended_jacobian_lower i j (le_refl _) (le_refl _) hx + rw [sourceCollarDerivative_det,←sourceCollarJacobian_det] at h + exact abs_pos.mp (lt_of_lt_of_le (by norm_num : (0:ℝ)<1/100) h) + +def sourceCartesianGradientMatrix (i j : Fin 4) (x : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + (sourceCollarJacobian i j x)ᵀ⁻¹*sourceFaceAngleMatrix i j x + +lemma sourceCartesianGradient_chain (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) (v : Fin 3 → ℝ) : + (sourceCollarJacobian i j x)ᵀ *ᵥ (sourceCartesianGradientMatrix i j x *ᵥ v)= + sourceFaceAngleMatrix i j x *ᵥ v := by + rw [sourceCartesianGradientMatrix,←Matrix.mulVec_mulVec,Matrix.mulVec_mulVec, + Matrix.mul_nonsing_inv _ (isUnit_iff_ne_zero.mpr (by + rw [Matrix.det_transpose] + exact sourceCollarJacobian_extended_ne_zero i j hx)),Matrix.one_mulVec] + +lemma continuousOn_sourceCartesianGradientMatrix (i j : Fin 4) : + ContinuousOn (sourceCartesianGradientMatrix i j) + (sourceExtendedBox (-(1:ℝ)/100) (1/100)) := by + intro x hx + have hi : ContinuousAt (fun x => (sourceCollarJacobian i j x)ᵀ⁻¹) x := + (continuousAt_matrix_inv _ (by + rw [Ring.inverse_eq_inv'] + exact continuousAt_inv₀ (by + rw [Matrix.det_transpose] + exact sourceCollarJacobian_extended_ne_zero i j hx))).comp + (continuous_sourceCollarJacobian i j).matrix_transpose.continuousAt + exact (hi.mul (continuous_sourceFaceAngleMatrix i j).continuousAt).continuousWithinAt + +lemma sourceCartesianGradient_uniform_bound : ∃ C : ℝ,0 abs_nonneg (C i k)) (Finset.mem_univ j)).trans + (Finset.single_le_sum (fun k _ => Finset.sum_nonneg (fun l _ => abs_nonneg (C k l))) + (Finset.mem_univ i)) + linarith [le_abs_self (C i j)] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..c5e225190f64cde7481f29f9fccf359267108e0e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergence.lean @@ -0,0 +1,170 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactFiberDecomposition + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma interval_integral_eq_integral_of_support {a b : ℝ} (hab : a≤b) + {f : ℝ → ℝ} (hv : ∀ t, f t≠0 → t∈Ioo a b) : + (∫ t in a..b, f t)=∫ t, f t := by + rw [intervalIntegral.integral_of_le hab] + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + by_contra hn + exact hx ⟨(hv x hn).1,(hv x hn).2.le⟩ + +lemma compactFiberMarginal_integral {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] + [MeasureSpace E] [BorelSpace E] [SFinite (volume : Measure E)] + {a b : ℝ} (hab : a≤b) {f : E×ℝ → ℝ} (hf : Integrable f) + (hv : ∀ p, f p≠0 → p.2∈Ioo a b) : + (∫ x, compactFiberMarginal a b f x)=∫ p, f p := by + have he (x : E) : compactFiberMarginal a b f x=∫ t, f (x,t) := + interval_integral_eq_integral_of_support hab (fun t ht => hv (x,t) ht) + simp_rw [he] + exact (integral_prod f hf).symm + +lemma compact_scalar_primitive {a b : ℝ} (hab : a r p.2 + have hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f := hr.comp contDiff_snd + let P : ℝ → ℝ := fun t => fiberPrimitive a f (0,t) + have hP : ContDiff ℝ (↑(⊤ : ℕ∞)) P := + (fiberPrimitive_smooth a hf).comp (contDiff_const.prodMk contDiff_id) + have hvf : ∀ p, f p≠0 → p.2∈Ioo a b := fun p hp => hv p.2 hp + have hzf : ∀ x, (∫ t in a..b, f (x,t))=0 := by + intro x + exact (interval_integral_eq_integral_of_support hab.le hv).trans hz + have hs : Function.support P⊆Icc a b := by + intro t ht + refine ⟨?_,?_⟩ + · by_contra hn + exact ht (fiberPrimitive_below hf.continuous hvf (0,t) (le_of_not_ge hn)) + · by_contra hn + exact ht (fiberPrimitive_above hf.continuous hvf hzf (0,t) (le_of_not_ge hn)) + refine ⟨P,hP,HasCompactSupport.of_support_subset_isCompact isCompact_Icc hs,?_, + closure_minimal hs isClosed_Icc⟩ + intro t + have hd := (((fiberPrimitive_smooth a hf).differentiable (by simp)) (0,t)).hasFDerivAt.comp_hasDerivAt t + ((hasDerivAt_const t (0:ℝ)).prodMk (hasDerivAt_id t)) + exact hd.deriv.trans (fiberPrimitive_derivative a hf (0,t)) + +lemma cube_partial_fiber (f : Box3 → ℝ) (p : Box3) : + cubePartial f ((0,0),1) p=wallDerivative f p := rfl + +theorem compact_box_divergence {a b : Fin 3 → ℝ} (hab : ∀ i,a i (hv (subset_tsupport r hp)).2) hη₃ hsη₃ hvη₃ hiη₃ + let S := compactFiberMarginal (a 1) (b 1) R + have hS := compactFiberMarginal_smooth (hab 1).le hR + have hsS := (compactFiberMarginal_support hsR (a := a 1) (b := b 1)).1 + have hvS : tsupport S⊆Ioo (a 0) (b 0) := by + intro x hx + obtain ⟨p,hp,rfl⟩ := (compactFiberMarginal_support hsR).2 hx + exact (hvR hp).1 + obtain ⟨G,hG,hsG,hdG,htG⟩ := compact_fiber_decomposition (hab 1) hR hsR + (fun p hp => (hvR (subset_tsupport R hp)).2) hη₂ hsη₂ hvη₂ hiη₂ + have hzR : (∫ x,R x)=0 := by + rw [compactFiberMarginal_integral (hab 2).le + (hr.continuous.integrable_of_hasCompactSupport hs) + (fun p hp => (hv (subset_tsupport r hp)).2)] + exact hz + have hzS : (∫ x,S x)=0 := by + rw [compactFiberMarginal_integral (hab 1).le + (hR.continuous.integrable_of_hasCompactSupport hsR) + (fun p hp => (hvR (subset_tsupport R hp)).2)] + exact hzR + obtain ⟨P,hP,hsP,hdP,htP⟩ := compact_scalar_primitive (hab 0) hS + (fun x hx => hvS (subset_tsupport S hx)) hzS + let F₁ : Box3 → ℝ := fun p => η₃ p.2*η₂ p.1.2*P p.1.1 + let F₂ : Box3 → ℝ := fun p => η₃ p.2*G p.1 + have hF₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₁ := + ((hη₃.comp contDiff_snd).mul (hη₂.comp (contDiff_snd.comp contDiff_fst))).mul + (hP.comp (contDiff_fst.comp contDiff_fst)) + have hF₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₂ := + (hη₃.comp contDiff_snd).mul (hG.comp contDiff_fst) + let K := (Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1)) ×ˢ Icc (a 2) (b 2) + have hK : IsCompact K := (isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc + have ht₁ : tsupport F₁⊆K := by + apply closure_minimal _ hK.isClosed + intro p hp + obtain ⟨h₁,h₂⟩ := mul_ne_zero_iff.mp hp + obtain ⟨h₃,h₄⟩ := mul_ne_zero_iff.mp h₁ + exact ⟨⟨htP (subset_tsupport P h₂),Ioo_subset_Icc_self (hvη₂ (subset_tsupport η₂ h₄))⟩, + Ioo_subset_Icc_self (hvη₃ (subset_tsupport η₃ h₃))⟩ + have ht₂ : tsupport F₂⊆K := by + apply closure_minimal _ hK.isClosed + intro p hp + obtain ⟨h₁,h₂⟩ := mul_ne_zero_iff.mp hp + have hh := htG (subset_tsupport G h₂) + obtain ⟨q,hq,hqx⟩ := hh.1 + exact ⟨⟨Ioo_subset_Icc_self (hqx ▸ (hvR hq).1),hh.2⟩, + Ioo_subset_Icc_self (hvη₃ (subset_tsupport η₃ h₁))⟩ + have ht₃' : tsupport F₃⊆K := by + intro p hp + have hh := ht₃ hp + obtain ⟨q,hq,hqp⟩ := hh.1 + have hxy := (hv hq).1 + change q.1∈_ at hxy + rw [hqp] at hxy + exact ⟨⟨Ioo_subset_Icc_self hxy.1,Ioo_subset_Icc_self hxy.2⟩,hh.2⟩ + refine ⟨F₁,F₂,F₃,hF₁,hF₂,hF₃, + HasCompactSupport.of_support_subset_isCompact hK (subset_tsupport F₁ |>.trans ht₁), + HasCompactSupport.of_support_subset_isCompact hK (subset_tsupport F₂ |>.trans ht₂),hsF₃,?_, + union_subset (union_subset ht₁ ht₂) ht₃'⟩ + intro p + have hd₁ : cubePartial F₁ ((1,0),0) p=η₃ p.2*η₂ p.1.2*S p.1.1 := by + have hline := (hasDerivAt_id p.1.1).prodMk (hasDerivAt_const p.1.1 p.1.2) + have he := ((hF₁.differentiable (by simp)) p).hasFDerivAt.comp_hasDerivAt p.1.1 + (hline.prodMk (hasDerivAt_const p.1.1 p.2)) + have he' : HasDerivAt (fun t => F₁ ((t,p.1.2),p.2)) + (cubePartial F₁ ((1,0),0) p) p.1.1 := he + have hp := ((hP.differentiable (by simp)) p.1.1).hasDerivAt.const_mul + (η₃ p.2*η₂ p.1.2) + rw [hdP] at hp + exact he'.unique hp + have hd₂ : cubePartial F₂ ((0,1),0) p=η₃ p.2*wallDerivative G p.1 := by + have hline := (hasDerivAt_const p.1.2 p.1.1).prodMk (hasDerivAt_id p.1.2) + have he := ((hF₂.differentiable (by simp)) p).hasFDerivAt.comp_hasDerivAt p.1.2 + (hline.prodMk (hasDerivAt_const p.1.2 p.2)) + have he' : HasDerivAt (fun t => F₂ ((p.1.1,t),p.2)) + (cubePartial F₂ ((0,1),0) p) p.1.2 := he + have hg := (((hG.differentiable (by simp)) p.1).hasFDerivAt.comp_hasDerivAt + p.1.2 hline).const_mul (η₃ p.2) + exact he'.unique hg + rw [hd₁,hd₂,cube_partial_fiber] + have h₁ := hdG p.1 + have h₂ := hd₃ p + dsimp [S,R] at * + linear_combination (η₃ p.2)*h₁+h₂ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergenceC1.lean b/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergenceC1.lean new file mode 100644 index 0000000000000000000000000000000000000000..bdc0786f40b25dac39b5fea77ffb479cc2c6fd59 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CompactBoxDivergenceC1.lean @@ -0,0 +1,178 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.UniformC1Bounds + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem compact_box_divergence_C1 {a b : Fin 3 → ℝ} (hab : ∀ i,a i (hv hp).2) hη₃ hsη₃ hvη₃ hiη₃ hM hK₃.le + (fun p => (hbound p).1) (fun p => (hbound p).2) (fun t => (hbη₃ t).1) + let S := compactFiberMarginal (a 1) (b 1) R + have hS := compactFiberMarginal_smooth (hab 1).le hR + have hsS := (compactFiberMarginal_support hsR (a := a 1) (b := b 1)).1 + have hvS : tsupport S⊆Ioo (a 0) (b 0) := by + intro x hx + obtain ⟨p,hp,rfl⟩ := (compactFiberMarginal_support hsR).2 hx + exact (hvR hp).1 + have hbS : UniformC1Bound S ((b 1-a 1)*((b 2-a 2)*M)) := + compactFiberMarginal_C1Bound (hab 1).le hR (by positivity) hbR + obtain ⟨G,hG,hsG,hdG,htG,hbG₀,hdbG⟩ := compact_fiber_decomposition_C1 (hab 1) hR hsR + (fun p hp => (hvR hp).2) hη₂ hsη₂ hvη₂ hiη₂ (by positivity) hK₂.le + (fun p => (hbR p).1) (fun p => (hbR p).2) (fun t => (hbη₂ t).1) + have hbG : UniformC1Bound G ((b 1-a 1+1)*(1+K₂*(b 1-a 1))*((b 2-a 2)*M)) := by + intro p + refine ⟨(hbG₀ p).trans ?_,hdbG p⟩ + nlinarith [mul_nonneg (by positivity : 0≤1+K₂*(b 1-a 1)) (by positivity : 0≤(b 2-a 2)*M)] + have hzR : (∫ x,R x)=0 := by + rw [compactFiberMarginal_integral (hab 2).le + (hr.continuous.integrable_of_hasCompactSupport hs) + (fun p hp => (hv (subset_tsupport r hp)).2)] + exact hz + have hzS : (∫ x,S x)=0 := by + rw [compactFiberMarginal_integral (hab 1).le + (hR.continuous.integrable_of_hasCompactSupport hsR) + (fun p hp => (hvR (subset_tsupport R hp)).2)] + exact hzR + obtain ⟨P,hP,hsP,hdP,htP,hbP⟩ := compact_scalar_primitive_bounded (hab 0) hS + (fun x hx => hvS (subset_tsupport S hx)) hzS (by positivity) (fun t => (hbS t).1) + let F₁ : Box3 → ℝ := fun p => η₃ p.2*η₂ p.1.2*P p.1.1 + let F₂ : Box3 → ℝ := fun p => η₃ p.2*G p.1 + have hF₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₁ := + ((hη₃.comp contDiff_snd).mul (hη₂.comp (contDiff_snd.comp contDiff_fst))).mul + (hP.comp (contDiff_fst.comp contDiff_fst)) + have hF₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₂ := + (hη₃.comp contDiff_snd).mul (hG.comp contDiff_fst) + have hbf : UniformC1Bound (fun p : Box3 => η₃ p.2) K₃ := + hbη₃.comp_snd (hη₃.differentiable (by simp)) hK₃.le + have hbg : UniformC1Bound (fun p : Box3 => η₂ p.1.2) K₂ := + (hbη₂.comp_snd (E := ℝ) (hη₂.differentiable (by simp)) hK₂.le).comp_fst + ((hη₂.comp contDiff_snd).differentiable (by simp)) hK₂.le + have hbp : UniformC1Bound (fun p : Box3 => P p.1.1) + ((b 0-a 0+1)*((b 1-a 1)*((b 2-a 2)*M))) := + (hbP.comp_fst (P := ℝ) (hP.differentiable (by simp)) (by positivity)).comp_fst + ((hP.comp contDiff_fst).differentiable (by simp)) (by positivity) + have hbf₁ : UniformC1Bound F₁ (c₁*M) := by + have hh := (hbf.mul ((hη₃.comp contDiff_snd).differentiable (by simp)) + ((hη₂.comp (contDiff_snd.comp contDiff_fst)).differentiable (by simp)) hK₃.le hK₂.le hbg).mul + (((hη₃.comp contDiff_snd).mul (hη₂.comp (contDiff_snd.comp contDiff_fst))).differentiable (by simp)) + ((hP.comp (contDiff_fst.comp contDiff_fst)).differentiable (by simp)) (by positivity) (by positivity) hbp + convert hh using 1 <;> dsimp [F₁,c₁] + ring + have hbf₂ : UniformC1Bound F₂ (c₂*M) := by + have hh := hbf.mul ((hη₃.comp contDiff_snd).differentiable (by simp)) + ((hG.comp contDiff_fst).differentiable (by simp)) hK₃.le (by positivity) + (hbG.comp_fst (hG.differentiable (by simp)) (by positivity)) + convert hh using 1 <;> dsimp [F₂,c₂] + ring + have hbf₃ : UniformC1Bound F₃ (c₃*M) := by + intro p + refine ⟨(hb₃ p).trans ?_,hdB₃ p⟩ + dsimp [c₃] + nlinarith [mul_nonneg (by positivity : 0≤1+K₃*(b 2-a 2)) hM] + let K := (Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1)) ×ˢ Icc (a 2) (b 2) + have hK : IsCompact K := (isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc + have ht₁ : tsupport F₁⊆K := by + apply closure_minimal _ hK.isClosed + intro p hp + obtain ⟨h₁,h₂⟩ := mul_ne_zero_iff.mp hp + obtain ⟨h₃,h₄⟩ := mul_ne_zero_iff.mp h₁ + exact ⟨⟨htP (subset_tsupport P h₂),Ioo_subset_Icc_self (hvη₂ (subset_tsupport η₂ h₄))⟩, + Ioo_subset_Icc_self (hvη₃ (subset_tsupport η₃ h₃))⟩ + have ht₂ : tsupport F₂⊆K := by + apply closure_minimal _ hK.isClosed + intro p hp + obtain ⟨h₁,h₂⟩ := mul_ne_zero_iff.mp hp + have hh := htG (subset_tsupport G h₂) + obtain ⟨q,hq,hqx⟩ := hh.1 + exact ⟨⟨Ioo_subset_Icc_self (hqx ▸ (hvR hq).1),hh.2⟩, + Ioo_subset_Icc_self (hvη₃ (subset_tsupport η₃ h₁))⟩ + have ht₃' : tsupport F₃⊆K := by + intro p hp + have hh := ht₃ hp + obtain ⟨q,hq,hqp⟩ := hh.1 + have hxy := (hv hq).1 + change q.1∈_ at hxy + rw [hqp] at hxy + exact ⟨⟨Ioo_subset_Icc_self hxy.1,Ioo_subset_Icc_self hxy.2⟩,hh.2⟩ + refine ⟨F₁,F₂,F₃,hF₁,hF₂,hF₃, + HasCompactSupport.of_support_subset_isCompact hK (subset_tsupport F₁ |>.trans ht₁), + HasCompactSupport.of_support_subset_isCompact hK (subset_tsupport F₂ |>.trans ht₂),hsF₃,?_, + union_subset (union_subset ht₁ ht₂) ht₃', + hbf₁.mono (mul_le_mul_of_nonneg_right (by dsimp [C]; linarith) hM), + hbf₂.mono (mul_le_mul_of_nonneg_right (by dsimp [C]; linarith) hM), + hbf₃.mono (mul_le_mul_of_nonneg_right (by dsimp [C]; linarith) hM)⟩ + intro p + have hd₁ : cubePartial F₁ ((1,0),0) p=η₃ p.2*η₂ p.1.2*S p.1.1 := by + have hline := (hasDerivAt_id p.1.1).prodMk (hasDerivAt_const p.1.1 p.1.2) + have he := ((hF₁.differentiable (by simp)) p).hasFDerivAt.comp_hasDerivAt p.1.1 + (hline.prodMk (hasDerivAt_const p.1.1 p.2)) + have he' : HasDerivAt (fun t => F₁ ((t,p.1.2),p.2)) + (cubePartial F₁ ((1,0),0) p) p.1.1 := he + have hp := ((hP.differentiable (by simp)) p.1.1).hasDerivAt.const_mul + (η₃ p.2*η₂ p.1.2) + rw [hdP] at hp + exact he'.unique hp + have hd₂ : cubePartial F₂ ((0,1),0) p=η₃ p.2*wallDerivative G p.1 := by + have hline := (hasDerivAt_const p.1.2 p.1.1).prodMk (hasDerivAt_id p.1.2) + have he := ((hF₂.differentiable (by simp)) p).hasFDerivAt.comp_hasDerivAt p.1.2 + (hline.prodMk (hasDerivAt_const p.1.2 p.2)) + have he' : HasDerivAt (fun t => F₂ ((p.1.1,t),p.2)) + (cubePartial F₂ ((0,1),0) p) p.1.2 := he + have hg := (((hG.differentiable (by simp)) p.1).hasFDerivAt.comp_hasDerivAt + p.1.2 hline).const_mul (η₃ p.2) + exact he'.unique hg + rw [hd₁,hd₂,cube_partial_fiber] + have h₁ := hdG p.1 + have h₂ := hd₃ p + dsimp [S,R] at * + linear_combination (η₃ p.2)*h₁+h₂ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CompactFluxDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/CompactFluxDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..48751a9787563ba6b0ea1d9e87cca85f5a517870 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CompactFluxDivergence.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.SynchronizedChartWaves + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def coordinateDivergence (F : Coord3 → Coord3) (x : Coord3) : ℝ := + ∑ i : Fin 3,fderiv ℝ (fun y => F y i) x (Pi.single i 1) + +lemma coordinate_fderiv_expansion (ψ : Coord3 → ℝ) (x v : Coord3) : + fderiv ℝ ψ x v=∑ i : Fin 3,v i*fderiv ℝ ψ x (Pi.single i 1) := by + have he : v=∑ i : Fin 3,v i • Pi.single i 1 := by + ext j + simp [Pi.single_apply] + conv_lhs => rw [he] + simp + +lemma coordinateDivergence_smooth {F : Coord3 → Coord3} + (hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (coordinateDivergence F) := by + apply ContDiff.sum; intro i _ + exact (((contDiff_pi.mp hF) i).fderiv_right (by simp)).clm_apply contDiff_const + +lemma coordinateDivergence_compact {F : Coord3 → Coord3} + (hs : HasCompactSupport F) : HasCompactSupport (coordinateDivergence F) := by + have hc (i : Fin 3) : HasCompactSupport (fun x => fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := by + have hci : HasCompactSupport (fun x => F x i) := hs.comp_left (g := fun v : Coord3 => v i) rfl + exact hci.fderiv_apply ℝ _ + have he : coordinateDivergence F = fun x => + (fderiv ℝ (fun y => F y 0) x (Pi.single 0 1)+ + fderiv ℝ (fun y => F y 1) x (Pi.single 1 1))+ + fderiv ℝ (fun y => F y 2) x (Pi.single 2 1) := by + funext x + simp [coordinateDivergence,Fin.sum_univ_three] + rw [he] + exact ((hc 0).add (hc 1)).add (hc 2) + +theorem coordinateDivergence_weak {F : Coord3 → Coord3} + (hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F) (hs : HasCompactSupport F) + (ψ : Coord3 → ℝ) (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) : + (∫ x,fderiv ℝ ψ x (F x))= -(∫ x,ψ x*coordinateDivergence F x) := by + have hc (i : Fin 3) : HasCompactSupport (fun x => F x i) := + hs.comp_left (g := fun v : Coord3 => v i) rfl + have hFi (i : Fin 3) : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => F x i) := + contDiff_pi.mp hF i + have hdψ (i : Fin 3) : Continuous (fun x => fderiv ℝ ψ x (Pi.single i 1)) := + (hψ.continuous_fderiv (by simp)).clm_apply continuous_const + have hdF (i : Fin 3) : Continuous (fun x => fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := + ((hFi i).continuous_fderiv (by simp)).clm_apply continuous_const + have hi₁ (i : Fin 3) : Integrable (fun x => F x i*fderiv ℝ ψ x (Pi.single i 1)) := + ((hFi i).continuous.mul (hdψ i)).integrable_of_hasCompactSupport (hc i).mul_right + have hi₂ (i : Fin 3) : Integrable (fun x => ψ x*fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := + (hψ.continuous.mul (hdF i)).integrable_of_hasCompactSupport ((hc i).fderiv_apply ℝ _).mul_left + have he (i : Fin 3) : (∫ x,F x i*fderiv ℝ ψ x (Pi.single i 1))= + -(∫ x,ψ x*fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := by + have hh := integral_mul_fderiv_eq_neg_fderiv_mul_of_integrable + (μ := (volume : Measure Coord3)) + (f := ψ) (g := fun x => F x i) (v := Pi.single i 1) + (by simpa only [mul_comm] using hi₁ i) (hi₂ i) + ((hψ.continuous.mul (hFi i).continuous).integrable_of_hasCompactSupport (hc i).mul_left) + (fun x _ => hψ.differentiable (by simp) x) + (fun x _ => (hFi i).differentiable (by simp) x) + have hh' : (∫ x,fderiv ℝ ψ x (Pi.single i 1)*F x i)= + (∫ x,F x i*fderiv ℝ ψ x (Pi.single i 1)) := by + apply integral_congr_ae + exact Filter.Eventually.of_forall (fun x => mul_comm _ _) + rw [hh'] at hh + linarith + have hex : (fun x => fderiv ℝ ψ x (F x))= + (fun x => ∑ i : Fin 3,F x i*fderiv ℝ ψ x (Pi.single i 1)) := by + funext x + exact coordinate_fderiv_expansion ψ x (F x) + rw [hex] + simp only [coordinateDivergence,Finset.mul_sum] + rw [integral_finsetSum _ (fun i _ => hi₁ i),integral_finsetSum _ (fun i _ => hi₂ i)] + simp_rw [he] + simp only [Finset.sum_neg_distrib] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CompactInteriorDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/CompactInteriorDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..12aba22c2419a63d017f3718518bd3a81a5ed38f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CompactInteriorDivergence.lean @@ -0,0 +1,63 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CompactBoxDivergence + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma compact_image_inner_interval {E : Type*} [TopologicalSpace E] + {K : Set E} (hK : IsCompact K) {f : E → ℝ} (hf : ContinuousOn f K) + {a b : ℝ} (hab : a linarith [(hv m hm).1,(hv M hM).2] + · refine ⟨(2*a+b)/3,(a+2*b)/3,by linarith,by linarith,by linarith,?_⟩ + intro x hx; exact (hn ⟨x,hx⟩).elim + +theorem compact_box_divergence_inside {a b : Fin 3 → ℝ} (hab : ∀ i,a i (hv hp).1.1) + obtain ⟨a₁,b₁,ha₁,hab₁,hb₁,hv₁⟩ := compact_image_inner_interval hs + (continuous_fst.snd.continuousOn) (hab 1) (fun p hp => (hv hp).1.2) + obtain ⟨a₂,b₂,ha₂,hab₂,hb₂,hv₂⟩ := compact_image_inner_interval hs + (continuous_snd.continuousOn) (hab 2) (fun p hp => (hv hp).2) + let a' : Fin 3 → ℝ := ![a₀,a₁,a₂] + let b' : Fin 3 → ℝ := ![b₀,b₁,b₂] + have hab' : ∀ i,a' i assumption + obtain ⟨F₁,F₂,F₃,h₁,h₂,h₃,hs₁,hs₂,hs₃,hd,ht⟩ := compact_box_divergence hab' hr hs + (fun p hp => ⟨⟨hv₀ p hp,hv₁ p hp⟩,hv₂ p hp⟩) hz + refine ⟨F₁,F₂,F₃,h₁,h₂,h₃,hs₁,hs₂,hs₃,hd,ht.trans ?_⟩ + intro p hp + exact ⟨⟨⟨ha₀.trans_le hp.1.1.1,hp.1.1.2.trans_lt hb₀⟩, + ⟨ha₁.trans_le hp.1.2.1,hp.1.2.2.trans_lt hb₁⟩⟩, + ⟨ha₂.trans_le hp.2.1,hp.2.2.trans_lt hb₂⟩⟩ + +lemma cubePartial_tsupport {f : Box3 → ℝ} (v : Box3) : + tsupport (cubePartial f v)⊆tsupport f := tsupport_fderiv_apply_subset ℝ v + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CubeWeakDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/CubeWeakDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6f6dba20629a0e24fb3f6bfe1716ab46f41c614 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CubeWeakDivergence.lean @@ -0,0 +1,43 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactRegularCorrection + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +lemma cube_fderiv_expansion (f : Box3 → ℝ) (p w : Box3) : + fderiv ℝ f p w=cubePartial f ((1,0),0) p*w.1.1+ + cubePartial f ((0,1),0) p*w.1.2+cubePartial f ((0,0),1) p*w.2 := by + have hw : w=w.1.1 • ((1,0),0)+w.1.2 • ((0,1),0)+w.2 • ((0,0),1) := by + ext <;> simp + calc + _ = fderiv ℝ f p (w.1.1 • ((1,0),0)+w.1.2 • ((0,1),0)+w.2 • ((0,0),1)) := congrArg _ hw + _ = _ := by simp only [map_add,map_smul,smul_eq_mul,cubePartial]; ring + +theorem cube_weak_divergence {F₁ F₂ F₃ r : Box3 → ℝ} + (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₁) (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₂) + (h₃ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₃) + (hs₁ : HasCompactSupport F₁) (hs₂ : HasCompactSupport F₂) (hs₃ : HasCompactSupport F₃) + (hd : ∀ p,cubePartial F₁ ((1,0),0) p+cubePartial F₂ ((0,1),0) p+ + cubePartial F₃ ((0,0),1) p=r p) + (φ : Box3 → ℝ) (hφ : ContDiff ℝ (↑(⊤ : ℕ∞)) φ) : + (∫ p,fderiv ℝ φ p ((F₁ p,F₂ p),F₃ p))=-(∫ p,φ p*r p) := by + have hi₁ : Integrable (fun p => cubePartial φ ((1,0),0) p*F₁ p) := + ((cubePartial_smooth hφ _).continuous.mul h₁.continuous).integrable_of_hasCompactSupport hs₁.mul_left + have hi₂ : Integrable (fun p => cubePartial φ ((0,1),0) p*F₂ p) := + ((cubePartial_smooth hφ _).continuous.mul h₂.continuous).integrable_of_hasCompactSupport hs₂.mul_left + have hi₃ : Integrable (fun p => cubePartial φ ((0,0),1) p*F₃ p) := + ((cubePartial_smooth hφ _).continuous.mul h₃.continuous).integrable_of_hasCompactSupport hs₃.mul_left + simp_rw [cube_fderiv_expansion] + have hi₁₂ : Integrable (fun p => cubePartial φ ((1,0),0) p*F₁ p+cubePartial φ ((0,1),0) p*F₂ p) := hi₁.add hi₂ + rw [integral_add hi₁₂ hi₃,integral_add hi₁ hi₂] + linarith [cube_coordinate_divergence_moment h₁ h₂ h₃ hs₁ hs₂ hs₃ hd hφ] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CylinderCompletedGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/CylinderCompletedGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..685fbdc28d1fc9630d84129d2870df19a2bfca49 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CylinderCompletedGreen.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CylinderSeriesGreen +import OAI.Analysis.Conductivity.Sobolev.CylinderSobolevGraph + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def spectralWeightedPairL (s : Fin 3 → ℝ) (g : SpectralL2 TorusModes) : + spectralTraceGraph (torusRate s) →L[ℂ] ℂ := + (innerSL ℂ g).comp ((PiLp.proj 2 (fun _ : Fin 2 => SpectralL2 TorusModes) 1).comp + (spectralTraceGraph (torusRate s)).subtypeL) + +def spectralEndWeight (s : Fin 3 → ℝ) (R : ℝ) (f : spectralTraceGraph (torusRate s)) : + SpectralL2 TorusModes := + sequenceMultiplier (fun h => (Real.exp (-torusRate s h*|R|):ℂ)) 1 + zero_le_one (poissonMultiplier_bound s R) (f.val 1) + +lemma spectralWeightedPair_single (s : Fin 3 → ℝ) (g : SpectralL2 TorusModes) + (h : TorusModes) (a : ℂ) : + spectralWeightedPairL s g (spectralTraceSingleL s h a)= + inner ℂ (g h) ((Real.sqrt (torusRate s h):ℂ)*a) := by + change inner ℂ g (lp.single 2 h ((Real.sqrt (torusRate s h):ℂ)*a))=_ + exact lp.inner_single_right h _ g + +lemma spectralWeightedPair_initial (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (h : TorusModes) (a : ℂ) : + spectralWeightedPairL s (f.val 1) (spectralTraceSingleL s h a)= + (torusRate s h:ℂ)*inner ℂ (f.val 0 h) a := by + rw [spectralWeightedPair_single,f.property h] + have he : (Real.sqrt (torusRate s h):ℂ)^2=(torusRate s h:ℂ) := by + exact_mod_cast Real.sq_sqrt (show 0≤torusRate s h from Real.sqrt_nonneg _) + simp only [RCLike.inner_apply,map_mul,Complex.conj_ofReal] + calc + _=(Real.sqrt (torusRate s h):ℂ)^2*(starRingEnd ℂ (f.val 0 h)*a) := by ring + _=_ := by rw [he]; ring + +lemma spectralWeightedPair_terminal (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + {R : ℝ} (hR : 0≤R) (h : TorusModes) (a : ℂ) : + spectralWeightedPairL s (spectralEndWeight s R f) (spectralTraceSingleL s h a)= + (torusRate s h*Real.exp (-torusRate s h*R):ℝ)*inner ℂ (f.val 0 h) a := by + rw [spectralWeightedPair_single] + change inner ℂ ((Real.exp (-torusRate s h*|R|):ℂ)*(f.val 1 h)) _=_ + rw [abs_of_nonneg hR] + change inner ℂ ((Real.exp (-torusRate s h*R):ℂ) • (f.val 1 h)) _=_ + rw [inner_smul_left] + rw [←spectralWeightedPair_single,spectralWeightedPair_initial] + simp only [Complex.conj_ofReal,Complex.ofReal_mul] + ring + +lemma spectralWeightedPair_polynomial (s : Fin 3 → ℝ) (g : SpectralL2 TorusModes) + (t : ℝ) (p : TorusModes →₀ smoothComplexAxis) : + spectralWeightedPairL s g (cylinderPolynomialTraceL s t p)= + ∑ h∈p.support,spectralWeightedPairL s g (spectralTraceSingleL s h (p h t)) := by + rw [cylinderPolynomialTraceL,Finsupp.lsum_apply,Finsupp.sum,map_sum] + rfl + +theorem flatCylinder_completed_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {R : ℝ} (hR : 0 hu y hy.1⟩ + rw [←hz] + exact flatCylinder_completed_green s hs hR f z + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CylinderGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/CylinderGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc6bf18837448121f30033550a2f888c6ac32352 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CylinderGreen.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.AxialDecayL2 + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus + +local instance cylinderGreenMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance cylinderGreenProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma poisson_complex_hermitian_green {q : ℝ → ℂ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (m R : ℝ) (a : ℂ) : + (∫ t in (0:ℝ)..R, + inner ℂ (axialDecayField m (-(m:ℂ)*a) t) (deriv q t) + + (m^2:ℝ)*inner ℂ (axialDecayField m a t) (q t)) = + (m:ℂ)*inner ℂ a (q 0)-(m*Real.exp (-m*R):ℝ)*inner ℂ a (q R) := by + have he (t : ℝ) : HasDerivAt (fun t : ℝ => (Real.exp (-m*t):ℂ)) + ((Real.exp (-m*t)*(-m):ℝ):ℂ) t := by + simpa only [id_eq,mul_one] using (((hasDerivAt_id t).const_mul (-m)).exp).ofReal_comp + have hd (t : ℝ) : HasDerivAt + (fun t : ℝ => (-(m:ℂ)*(Real.exp (-m*t):ℂ)*starRingEnd ℂ a)*q t) + (inner ℂ (axialDecayField m (-(m:ℂ)*a) t) (deriv q t) + + (m^2:ℝ)*inner ℂ (axialDecayField m a t) (q t)) t := by + convert! (((he t).const_mul (-(m:ℂ))).mul_const (starRingEnd ℂ a)).mul + ((hq.differentiable (by simp) t).hasDerivAt) using 1 + simp only [axialDecayField,RCLike.inner_apply,map_mul,map_neg,Complex.conj_ofReal, + Complex.ofReal_mul,Complex.ofReal_neg,Complex.ofReal_pow] + ring + have hc : Continuous (fun t : ℝ => + inner ℂ (axialDecayField m (-(m:ℂ)*a) t) (deriv q t) + + (m^2:ℝ)*inner ℂ (axialDecayField m a t) (q t)) := by + exact ((axialDecayField_continuous _ _).inner (hq.continuous_deriv (by simp))).add + (continuous_const.mul ((axialDecayField_continuous _ _).inner hq.continuous)) + have H := intervalIntegral.integral_eq_sub_of_hasDerivAt + (fun t _ => hd t) (hc.intervalIntegrable 0 R) + rw [H] + simp only [mul_zero,Real.exp_zero,Complex.ofReal_one,mul_one,RCLike.inner_apply, + Complex.ofReal_mul] + ring + +lemma smoothFiniteAxis_memLp {q : ℝ → ℂ} (hq : Continuous q) (R : ℝ) : + MemLp q 2 (FiniteAxisMeasure R) := by + apply (memLp_two_iff_integrable_sq_norm hq.aestronglyMeasurable).mpr + exact (hq.norm.pow 2).integrableOn_Icc.mono_set Ioc_subset_Icc_self + +def smoothFiniteAxisLp {q : ℝ → ℂ} (hq : Continuous q) (R : ℝ) : FiniteAxisL2 R := + (smoothFiniteAxis_memLp hq R).toLp q + +lemma smoothFiniteAxisLp_ae {q : ℝ → ℂ} (hq : Continuous q) (R : ℝ) : + smoothFiniteAxisLp hq R=ᵐ[FiniteAxisMeasure R] q := + (smoothFiniteAxis_memLp hq R).coeFn_toLp + +lemma finiteDecay_green_inner {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (m R : ℝ) (hR : 0≤R) (a : ℂ) : + inner ℂ (finiteDecayLp m R (-(m:ℂ)*a)) (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R)+ + (m^2:ℝ)*inner ℂ (finiteDecayLp m R a) (smoothFiniteAxisLp hq.continuous R)= + (m:ℂ)*inner ℂ a (q 0)-(m*Real.exp (-m*R):ℝ)*inner ℂ a (q R) := by + have h1 := L2.integrable_inner (𝕜:=ℂ) (finiteDecayLp m R (-(m:ℂ)*a)) + (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R) + have h2 := L2.integrable_inner (𝕜:=ℂ) (finiteDecayLp m R a) (smoothFiniteAxisLp hq.continuous R) + rw [L2.inner_def,L2.inner_def,←integral_const_mul,←integral_add h1 (h2.const_mul _)] + have he : (∫ t,inner ℂ (finiteDecayLp m R (-(m:ℂ)*a) t) + (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R t)+ + (m^2:ℝ)*inner ℂ (finiteDecayLp m R a t) (smoothFiniteAxisLp hq.continuous R t) + ∂FiniteAxisMeasure R)= + ∫ t in Ioc (0:ℝ) R,inner ℂ (axialDecayField m (-(m:ℂ)*a) t) (deriv q t)+ + (m^2:ℝ)*inner ℂ (axialDecayField m a t) (q t) := by + apply integral_congr_ae + filter_upwards [finiteDecayLp_ae m R (-(m:ℂ)*a),finiteDecayLp_ae m R a, + smoothFiniteAxisLp_ae (hq.continuous_deriv (by simp)) R,smoothFiniteAxisLp_ae hq.continuous R] + with t h1 h2 h3 h4 + rw [h1,h2,h3,h4] + rw [he,←intervalIntegral.integral_of_le hR] + exact poisson_complex_hermitian_green hq m R a + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CylinderSeriesGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/CylinderSeriesGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..dfb65d34f6569497002e60f337096622c963e194 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CylinderSeriesGreen.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.CylinderModeGreen + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def flatCylinderEnergyLeftCLM (s : Fin 3 → ℝ) {R : ℝ} (v : FiniteCylinderJets R) : + FiniteCylinderJets R →L[ℝ] ℂ where + toFun u := flatCylinderEnergy s u v + map_add' u w := by + simp only [flatCylinderEnergy,PiLp.add_apply,inner_add_left] + ring + map_smul' c u := by + simp only [flatCylinderEnergy,PiLp.smul_apply,inner_smul_left_eq_smul,Complex.real_smul,RingHom.id_apply] + ring + cont := flatCylinderEnergy_continuous_left s v + +def flatCylinderEnergyRightCLM (s : Fin 3 → ℝ) {R : ℝ} (u : FiniteCylinderJets R) : + FiniteCylinderJets R →L[ℂ] ℂ where + toFun v := flatCylinderEnergy s u v + map_add' v w := by + simp only [flatCylinderEnergy,PiLp.add_apply,inner_add_right] + ring + map_smul' c v := by + simp only [flatCylinderEnergy,PiLp.smul_apply,inner_smul_right,smul_eq_mul,RingHom.id_apply] + ring + cont := flatCylinderEnergy_continuous_right s u + +theorem flatCylinder_series_mode_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (R : ℝ) (hR : 0≤R) + (f : spectralTraceGraph (torusRate s)) (k : TorusModes) : + flatCylinderEnergy s (endPoissonJet s hs R hR f) (smoothCylinderModeJet hq R k)= + (torusRate s k:ℂ)*inner ℂ (f.val 0 k) (q 0)- + (torusRate s k*Real.exp (-torusRate s k*R):ℝ)*inner ℂ (f.val 0 k) (q R) := by + have H := (flatCylinderEnergyLeftCLM s (smoothCylinderModeJet hq R k)).hasSum + (endPoissonJet_hasSum s hs R hR f) + have Hsingle : HasSum (fun h => flatCylinderEnergy s + (endPoissonModeJet s R h (f.val 0 h)) (smoothCylinderModeJet hq R k)) + (flatCylinderEnergy s (endPoissonModeJet s R k (f.val 0 k)) (smoothCylinderModeJet hq R k)) := + hasSum_single k (fun h hne => flatCylinderEnergy_distinct_modes s hq R h k _ hne) + have he := H.unique Hsingle + change flatCylinderEnergy s (endPoissonJet s hs R hR f) (smoothCylinderModeJet hq R k)=_ at he + rw [he,flatCylinderEnergy_same_mode s hs hq R k _] + exact finiteDecay_green_inner hq _ R hR _ + +theorem flatCylinder_series_polynomial_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (q : TorusModes → ℝ → ℂ) (hq : ∀ k,ContDiff ℝ (↑(⊤:ℕ∞)) (q k)) + (R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) (F : Finset TorusModes) : + flatCylinderEnergy s (endPoissonJet s hs R hR f) (∑ k∈F,smoothCylinderModeJet (hq k) R k)= + ∑ k∈F,((torusRate s k:ℂ)*inner ℂ (f.val 0 k) (q k 0)- + (torusRate s k*Real.exp (-torusRate s k*R):ℝ)*inner ℂ (f.val 0 k) (q k R)) := by + change flatCylinderEnergyRightCLM s (endPoissonJet s hs R hR f) _=_ + rw [map_sum] + exact Finset.sum_congr rfl (fun k _ => flatCylinder_series_mode_green s hs (hq k) R hR f k) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/CylinderSlopeGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/CylinderSlopeGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f4a5e77cb19f6b6ea3c31f9630bf942932fa0c0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/CylinderSlopeGreen.lean @@ -0,0 +1,190 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CylinderCompletedGreen +import OAI.Analysis.Conductivity.Fourier.CylinderPoissonTrace + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma complex_linear_axis_smooth (r : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fun t : ℝ => (r:ℂ)*(t:ℂ)) := + contDiff_const.mul Complex.ofRealCLM.contDiff + +lemma complex_linear_axis_deriv (r : ℝ) : + deriv (fun t : ℝ => (r:ℂ)*(t:ℂ))=(fun _ => (r:ℂ)) := by + funext t + exact ((hasDerivAt_id t).ofReal_comp.const_mul (r:ℂ)).deriv.trans (by simp) + +def cylinderSlopeJet (r R : ℝ) : FiniteCylinderJets R := + smoothCylinderModeJet (complex_linear_axis_smooth r) R 0 + +lemma cylinderSlopeJet_derivative (r R : ℝ) : + cylinderSlopeJet r R 1=cylinderMode (FiniteAxisMeasure R) 0 + (smoothFiniteAxisLp (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R) := by + change cylinderMode _ _ (smoothFiniteAxisLp (q:=deriv (fun t : ℝ => (r:ℂ)*(t:ℂ))) _ _) = _ + congr 1 + apply Lp.ext + filter_upwards [smoothFiniteAxisLp_ae ((complex_linear_axis_smooth r).continuous_deriv (by simp)) R, + smoothFiniteAxisLp_ae (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R] with t ht hu + rw [ht,hu,complex_linear_axis_deriv] + +lemma cylinderSlopeJet_angular (r R : ℝ) : cylinderSlopeJet r R 2=0 ∧ cylinderSlopeJet r R 3=0 := by + simp [cylinderSlopeJet,smoothCylinderModeJet] + +lemma constant_derivative_inner {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (r R : ℝ) (hR : 0≤R) : + inner ℂ (smoothFiniteAxisLp (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R) + (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R)=(r:ℂ)*(q R-q 0) := by + rw [L2.inner_def] + have he : (∫ t,inner ℂ + (smoothFiniteAxisLp (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R t) + (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R t)∂FiniteAxisMeasure R)= + ∫ t in Ioc (0:ℝ) R,(r:ℂ)*deriv q t := by + apply integral_congr_ae + filter_upwards [smoothFiniteAxisLp_ae (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R, + smoothFiniteAxisLp_ae (hq.continuous_deriv (by simp)) R] with t ht hu + rw [ht,hu] + simp only [RCLike.inner_apply,Complex.conj_ofReal,mul_comm] + rw [he,integral_const_mul,←intervalIntegral.integral_of_le hR] + rw [intervalIntegral.integral_deriv_eq_sub + (fun t _ => hq.differentiable (by simp) t) + ((hq.continuous_deriv (by simp)).intervalIntegrable 0 R)] + +def spectralMeanCLM (s : Fin 3 → ℝ) : spectralTraceGraph (torusRate s) →L[ℂ] ℂ := + (lp.evalCLM ℂ (fun _ : TorusModes => ℂ) 2 0).comp + ((PiLp.proj 2 (fun _ : Fin 2 => SpectralL2 TorusModes) 0).comp + (spectralTraceGraph (torusRate s)).subtypeL) + +lemma spectralMean_single (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) : + spectralMeanCLM s (spectralTraceSingleL s h a)=if h=0 then a else 0 := by + change (lp.single 2 h a : SpectralL2 TorusModes) 0=_ + by_cases hh : h=0 + · subst h; simp + · simp [lp.single_apply,hh] + +lemma flatCylinder_slope_mode_green (s : Fin 3 → ℝ) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (r R : ℝ) (hR : 0≤R) (h : TorusModes) : + flatCylinderEnergy s (cylinderSlopeJet r R) (smoothCylinderModeJet hq R h)= + (r:ℂ)*(spectralMeanCLM s (spectralTraceSingleL s h (q R))- + spectralMeanCLM s (spectralTraceSingleL s h (q 0))) := by + rw [flatCylinderEnergy,cylinderSlopeJet_derivative, + (cylinderSlopeJet_angular r R).1,(cylinderSlopeJet_angular r R).2] + simp only [inner_zero_left,mul_zero,add_zero] + change inner ℂ (cylinderMode _ 0 (smoothFiniteAxisLp continuous_const R)) + (cylinderMode _ h (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R))=_ + rw [cylinderMode_inner,spectralMean_single,spectralMean_single] + by_cases hh : h=0 + · subst h + rw [ite_eq_left rfl,ite_eq_left rfl] + exact constant_derivative_inner hq r R hR + · simp [hh,Ne.symm hh] + +lemma spectralMean_polynomial (s : Fin 3 → ℝ) (t : ℝ) (p : TorusModes →₀ smoothComplexAxis) : + spectralMeanCLM s (cylinderPolynomialTraceL s t p)= + ∑ h∈p.support,spectralMeanCLM s (spectralTraceSingleL s h (p h t)) := by + rw [cylinderPolynomialTraceL,Finsupp.lsum_apply,Finsupp.sum,map_sum] + rfl + +theorem flatCylinder_slope_completed_green (s : Fin 3 → ℝ) (r R : ℝ) (hR : 0≤R) + (z : cylinderSobolevGraph s R) : + flatCylinderEnergy s (cylinderSlopeJet r R) z.val.1= + (r:ℂ)*(spectralMeanCLM s z.val.2.2-spectralMeanCLM s z.val.2.1) := by + let J : CylinderTraceAmbient s R →L[ℂ] FiniteCylinderJets R := ContinuousLinearMap.fst ℂ _ _ + let T₀ : CylinderTraceAmbient s R →L[ℂ] spectralTraceGraph (torusRate s) := + (ContinuousLinearMap.fst ℂ _ _).comp (ContinuousLinearMap.snd ℂ _ _) + let T₁ : CylinderTraceAmbient s R →L[ℂ] spectralTraceGraph (torusRate s) := + (ContinuousLinearMap.snd ℂ _ _).comp (ContinuousLinearMap.snd ℂ _ _) + let L := (flatCylinderEnergyRightCLM s (cylinderSlopeJet r R)).comp J- + (r:ℂ) • ((spectralMeanCLM s).comp T₁-(spectralMeanCLM s).comp T₀) + have hr : LinearMap.range (cylinderPolynomialGraphL s R)≤L.ker := by + rintro _ ⟨p,rfl⟩ + change flatCylinderEnergy s (cylinderSlopeJet r R) (cylinderPolynomialJetL R p)- + (r:ℂ)*(spectralMeanCLM s (cylinderPolynomialTraceL s R p)- + spectralMeanCLM s (cylinderPolynomialTraceL s 0 p))=0 + rw [cylinderPolynomialJetL_apply] + change flatCylinderEnergyRightCLM s (cylinderSlopeJet r R) _-_ = 0 + rw [map_sum,spectralMean_polynomial,spectralMean_polynomial] + change (∑ h∈p.support,flatCylinderEnergy s (cylinderSlopeJet r R) + (smoothCylinderModeJet (smoothComplexAxis_smooth (p h)) R h))-_ = 0 + simp only [flatCylinder_slope_mode_green s _ r R hR, + Finset.mul_sum,Finset.sum_sub_distrib,mul_sub] + ring + exact sub_eq_zero.mp (Submodule.topologicalClosure_minimal _ hr L.isClosed_ker z.property) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def cylinderEndJet (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (r R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) : FiniteCylinderJets R := + endPoissonJet s hs R hR f+cylinderSlopeJet r R + +lemma cylinderSlopeJet_mem_graph (s : Fin 3 → ℝ) (r R : ℝ) : + (cylinderSlopeJet r R,(0,spectralTraceSingleL s 0 ((r:ℂ)*(R:ℂ))))∈cylinderSobolevGraph s R := by + apply Submodule.le_topologicalClosure + refine ⟨Finsupp.single 0 (⟨fun t : ℝ => (r:ℂ)*(t:ℂ),complex_linear_axis_smooth r⟩ : smoothComplexAxis),?_⟩ + apply Prod.ext + · exact cylinderPolynomialJetL_single R 0 _ + · apply Prod.ext + · change cylinderPolynomialTraceL s 0 _=_ + rw [cylinderPolynomialTraceL_single] + simp only [Complex.ofReal_zero,mul_zero,map_zero] + · change cylinderPolynomialTraceL s R _=_ + rw [cylinderPolynomialTraceL_single] + +theorem cylinderEndJet_mem_graph (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (r R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) : + (cylinderEndJet s hs r R hR f, + (f,spectralPoissonTrace s R f+spectralTraceSingleL s 0 ((r:ℂ)*(R:ℂ))))∈ + cylinderSobolevGraph s R := by + have H := (cylinderSobolevGraph s R).add_mem (endPoissonJet_mem_trace_graph s hs R hR f) + (cylinderSlopeJet_mem_graph s r R) + simpa only [Prod.mk_add_mk,add_zero,cylinderEndJet] using H + +lemma spectralWeightedPair_real (s : Fin 3 → ℝ) (f g : spectralTraceGraph (torusRate s)) : + (spectralWeightedPairL s (f.val 1) g).re= + inner ℝ (spectralGraphWeight (torusRate s) f) (spectralGraphWeight (torusRate s) g) := by + change (inner ℂ (f.val 1) (g.val 1)).re=inner ℝ (f.val 1) (g.val 1) + rw [lp.inner_eq_tsum (𝕜:=ℂ),Complex.re_tsum (lp.summable_inner (𝕜:=ℂ) (f.val 1) (g.val 1)), + lp.inner_eq_tsum (𝕜:=ℝ)] + rfl + +lemma spectralMean_real (s : Fin 3 → ℝ) (g : spectralTraceGraph (torusRate s)) : + (spectralMeanCLM s g).re=spectralGraphMean (torusRate s) g := rfl + +def cylinderTerminalFlux (s : Fin 3 → ℝ) (r R : ℝ) + (f g : spectralTraceGraph (torusRate s)) : ℝ := + r*spectralGraphMean (torusRate s) g-(spectralWeightedPairL s (spectralEndWeight s R f) g).re + +theorem cylinderEndJet_real_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (r : ℝ) {R : ℝ} (hR : 0 direction (Pi.single i 1) (delayedEndingValue lam k J L K R) x := + funext (axialPair_gradient_one hd) + rw [hh] + exact hx + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceBounds.lean b/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..e61d3c673ccf18e87344c03c96cefd6adb2704fe --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceBounds.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactFiberDecomposition + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + +omit [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] in +lemma compactFiberMarginal_abs_bound {a b : ℝ} (hab : a≤b) + {f : E×ℝ → ℝ} {M : ℝ} (h : ∀ p,|f p|≤M) (x : E) : + |compactFiberMarginal a b f x|≤(b-a)*M := by + have hh := intervalIntegral.norm_integral_le_of_norm_le_const + (a := a) (b := b) (f := fun t => f (x,t)) (C := M) + (fun t _ => by simpa only [Real.norm_eq_abs] using h (x,t)) + simpa only [Real.norm_eq_abs,abs_of_nonneg (sub_nonneg.mpr hab),mul_comm, + compactFiberMarginal] using hh + +omit [NormedSpace ℝ E] [ProperSpace E] in +lemma fiberPrimitive_abs_bound {a b : ℝ} (hab : a≤b) + {f : E×ℝ → ℝ} (hf : Continuous f) + (hv : ∀ p,f p≠0 → p.2∈Ioo a b) + (hz : ∀ x,(∫ t in a..b,f (x,t))=0) + {M : ℝ} (hM : 0≤M) (h : ∀ p,|f p|≤M) (p : E×ℝ) : + |fiberPrimitive a f p|≤(b-a)*M := by + by_cases ha : p.2≤a + · rw [fiberPrimitive_below hf hv p ha,abs_zero] + positivity + by_cases hb : b≤p.2 + · rw [fiberPrimitive_above hf hv hz p hb,abs_zero] + positivity + rw [fiberPrimitive_eq_integral a hf] + have hh := intervalIntegral.norm_integral_le_of_norm_le_const + (a := a) (b := p.2) (f := fun t => f (p.1,t)) (C := M) + (fun t _ => by simpa only [Real.norm_eq_abs] using h (p.1,t)) + rw [Real.norm_eq_abs,abs_of_pos (sub_pos.mpr (lt_of_not_ge ha))] at hh + exact hh.trans (by nlinarith [lt_of_not_ge hb]) + +theorem compact_fiber_decomposition_bounded {a b : ℝ} (hab : a f p-η p.2*compactFiberMarginal a b f p.1) := by + let R := compactFiberMarginal a b f + have hR := compactFiberMarginal_smooth hab.le hf + have hsR : HasCompactSupport R := (compactFiberMarginal_support (a := a) (b := b) hs).1 + let g := fun p : E×ℝ => f p-η p.2*R p.1 + have hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g := hf.sub ((hη.comp contDiff_snd).mul (hR.comp contDiff_fst)) + have hsg : HasCompactSupport g := by + apply hs.sub + apply HasCompactSupport.of_support_subset_isCompact (hsR.prod hsη) + intro p hp + exact ⟨subset_tsupport R (mul_ne_zero_iff.mp hp).2,subset_tsupport η (mul_ne_zero_iff.mp hp).1⟩ + have hvg : ∀ p,g p≠0 → p.2∈Ioo a b := by + intro p hp + by_contra hn + have hz : f p=0 := by by_contra hh; exact hn (hv p hh) + have hzη : η p.2=0 := image_eq_zero_of_notMem_tsupport (fun hh => hn (hvη hh)) + exact hp (by simp [g,hz,hzη]) + have hzg : ∀ x,(∫ t in a..b,g (x,t))=0 := by + intro x + rw [show (fun t => g (x,t))=(fun t => f (x,t)-η t*R x) from rfl, + intervalIntegral.integral_sub (f := fun t => f (x,t)) (g := fun t => η t*R x) + ((hf.continuous.comp (continuous_const.prodMk continuous_id)).intervalIntegrable a b) + ((hη.continuous.mul continuous_const).intervalIntegrable a b)] + rw [intervalIntegral.integral_mul_const,hiη,one_mul] + exact sub_self _ + have hgb (p : E×ℝ) : |g p|≤(1+K*(b-a))*M := by + calc + |g p| ≤ |f p|+|η p.2| * |R p.1| := by simpa only [g,abs_mul] using abs_sub (f p) (η p.2*R p.1) + _ ≤ M+K*((b-a)*M) := add_le_add (hbound p) + (mul_le_mul (hηbound p.2) (compactFiberMarginal_abs_bound hab.le hbound p.1) (abs_nonneg _) hK) + _ = _ := by ring + have hc := fiberPrimitive_compact hg.continuous hsg hvg hzg + refine ⟨fiberPrimitive a g,fiberPrimitive_smooth a hg,hc.1,?_,?_,?_,?_,rfl⟩ + · intro p + rw [fiberPrimitive_derivative a hg] + exact sub_add_cancel _ _ + · apply hc.2.trans + intro p hp + refine ⟨?_,hp.2⟩ + obtain ⟨q,hq,hqp⟩ := hp.1 + by_contra hn + have hfg : Function.support g⊆(Prod.fst '' tsupport f) ×ˢ univ := by + intro y hy + refine ⟨?_,mem_univ _⟩ + by_contra hyf + have hz : f y=0 := by + by_contra h + exact hyf ⟨y,subset_tsupport f h,rfl⟩ + have hzR : R y.1=0 := image_eq_zero_of_notMem_tsupport + (fun h => hyf ((compactFiberMarginal_support hs).2 h)) + exact hy (by simp [g,hz,hzR]) + have hts := closure_minimal hfg ((hs.image continuous_fst).isClosed.prod isClosed_univ) + exact hn (hqp ▸ (hts hq).1) + · intro p + simpa only [mul_assoc] using fiberPrimitive_abs_bound hab.le hg.continuous hvg hzg + (by positivity : 0≤(1+K*(b-a))*M) hgb p + · intro p + rw [fiberPrimitive_derivative a hg] + exact hgb p + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceC1.lean b/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceC1.lean new file mode 100644 index 0000000000000000000000000000000000000000..6217701adaa609d13d5f15a5167dfc2bad0fe5ea --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FiberDivergenceC1.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.FiberTangentialDerivative + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + +omit [ProperSpace E] in +lemma wallAlong_pullback (d : E) {f : E → ℝ} (hf : Differentiable ℝ f) (p : E×ℝ) : + wallAlong d (fun q : E×ℝ => f q.1) p=fderiv ℝ f p.1 d := by + have hh := (hf p.1).hasFDerivAt.comp p (hasFDerivAt_fst (𝕜 := ℝ) (p := p)) + simp only [Function.comp_def] at hh + rw [wallAlong,hh.fderiv] + rfl + +omit [ProperSpace E] in +lemma wallAlong_normal (d : E) {f : ℝ → ℝ} (hf : Differentiable ℝ f) (p : E×ℝ) : + wallAlong d (fun q : E×ℝ => f q.2) p=0 := by + have hh := (hf p.2).hasFDerivAt.comp p (hasFDerivAt_snd (𝕜 := ℝ) (p := p)) + simp only [Function.comp_def] at hh + rw [wallAlong,hh.fderiv] + simp + +omit [ProperSpace E] in +lemma wallAlong_sub (d : E) {f g : E×ℝ → ℝ} + (hf : Differentiable ℝ f) (hg : Differentiable ℝ g) (p : E×ℝ) : + wallAlong d (fun q => f q-g q) p=wallAlong d f p-wallAlong d g p := by + simp only [wallAlong,fderiv_fun_sub (hf p) (hg p),sub_apply] + +omit [ProperSpace E] in +lemma wallAlong_opNorm_bound (d : E) {f : E×ℝ → ℝ} {M : ℝ} + (h : ∀ p,‖fderiv ℝ f p‖≤M) (p : E×ℝ) : |wallAlong d f p|≤M*‖d‖ := by + have hh := (fderiv ℝ f p).le_opNorm (d,0) + simp only [Prod.norm_def,norm_zero,max_eq_left (norm_nonneg d),Real.norm_eq_abs] at hh + exact hh.trans (mul_le_mul_of_nonneg_right (h p) (norm_nonneg d)) + +omit [ProperSpace E] in +lemma fderiv_normal_tangent (f : E×ℝ → ℝ) (p v : E×ℝ) : + fderiv ℝ f p v=wallAlong v.1 f p+v.2*wallDerivative f p := by + have he : v=(v.1,0)+v.2 • ((0:E),1) := by ext <;> simp + calc + _ = fderiv ℝ f p ((v.1,0)+v.2 • ((0:E),1)) := congrArg (fderiv ℝ f p) he + _ = _ := by simp only [map_add,map_smul,smul_eq_mul,wallAlong,wallDerivative] + +theorem compact_fiber_decomposition_C1 {a b : ℝ} (hab : a hv p (subset_tsupport f hp)) hη hsη hvη hiη hM hK hb hηb + let R := compactFiberMarginal a b f + have hR := compactFiberMarginal_smooth hab.le hf + let g : E×ℝ → ℝ := fun p => f p-η p.2*R p.1 + have hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g := hf.sub ((hη.comp contDiff_snd).mul (hR.comp contDiff_fst)) + have hvG : ∀ p∈tsupport g,p.2∈Ioo a b := by + intro p hp + rcases tsupport_sub _ _ hp with hp|hp + · exact hv p hp + · exact hvη ((tsupport_comp_subset_preimage η continuous_snd) + (tsupport_mul_subset_left hp)) + have hzG : ∀ x,(∫ t in a..b,g (x,t))=0 := by + intro x + rw [show (fun t => g (x,t))=(fun t => f (x,t)-η t*R x) from rfl, + intervalIntegral.integral_sub (f := fun t => f (x,t)) (g := fun t => η t*R x) + ((hf.continuous.comp (continuous_const.prodMk continuous_id)).intervalIntegrable a b) + ((hη.continuous.mul continuous_const).intervalIntegrable a b)] + rw [intervalIntegral.integral_mul_const,hiη,one_mul] + exact sub_self _ + have hdg (d : E) (p : E×ℝ) : wallAlong d g p= + wallAlong d f p-η p.2*compactFiberMarginal a b (wallAlong d f) p.1 := by + change wallAlong d (fun p => f p-(η ∘ Prod.snd) p*(compactFiberMarginal a b f ∘ Prod.fst) p) p = _ + rw [wallAlong_sub d (hf.differentiable (by simp)) + (((hη.comp contDiff_snd).mul (hR.comp contDiff_fst)).differentiable (by simp)), + wallAlong_mul d ((hη.comp contDiff_snd).differentiable (by simp)) + ((hR.comp contDiff_fst).differentiable (by simp))] + dsimp only [Function.comp_def] + rw [wallAlong_normal d (hη.differentiable (by simp)), + wallAlong_pullback d (hR.differentiable (by simp)),compactFiberMarginal_fderiv d hf] + ring + have hbg (d : E) (p : E×ℝ) : |wallAlong d g p|≤(1+K*(b-a))*M*‖d‖ := by + rw [hdg] + calc + _ ≤ |wallAlong d f p|+|η p.2| * |compactFiberMarginal a b (wallAlong d f) p.1| := by + simpa only [abs_mul] using abs_sub (wallAlong d f p) (η p.2*compactFiberMarginal a b (wallAlong d f) p.1) + _ ≤ M*‖d‖+K*((b-a)*(M*‖d‖)) := add_le_add (wallAlong_opNorm_bound d hdb p) + (mul_le_mul (hηb p.2) (compactFiberMarginal_abs_bound hab.le (wallAlong_opNorm_bound d hdb) p.1) + (abs_nonneg _) hK) + _ = _ := by ring + have htang (d : E) (p : E×ℝ) : |wallAlong d F p|≤(b-a)*(1+K*(b-a))*M*‖d‖ := by + rw [hformula] + simpa only [mul_assoc] using fiberPrimitive_tangential_bound d hab.le hg hvG hzG + (by positivity : 0≤(1+K*(b-a))*M*‖d‖) (hbg d) p + refine ⟨F,hF,hsF,heF,htF,hbF,?_⟩ + intro p + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro v + rw [Real.norm_eq_abs,fderiv_normal_tangent] + calc + _ ≤ |wallAlong v.1 F p|+|v.2| * |wallDerivative F p| := by + simpa only [abs_mul] using abs_add_le (wallAlong v.1 F p) (v.2*wallDerivative F p) + _ ≤ (b-a)*(1+K*(b-a))*M*‖v.1‖+|v.2| *((1+K*(b-a))*M) := + add_le_add (htang v.1 p) (mul_le_mul_of_nonneg_left (hdbF p) (abs_nonneg _)) + _ ≤ (b-a)*(1+K*(b-a))*M*‖v‖+‖v‖*((1+K*(b-a))*M) := by + apply add_le_add + · exact mul_le_mul_of_nonneg_left (norm_fst_le v) (by positivity) + · exact mul_le_mul_of_nonneg_right (by simpa only [Real.norm_eq_abs] using norm_snd_le v) (by positivity) + _ = _ := by ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalSmoothTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalSmoothTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..42e46829ed000645e1bbdcb65bb62e588d77c13c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalSmoothTensor.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.FiniteEndPhysicalTensor + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +lemma contDiffAt_mat3_det {A : Coord3 → Mat3} {x : Coord3} {n : WithTop ℕ∞} + (hA : ContDiffAt ℝ n A x) : ContDiffAt ℝ n (fun y => (A y).det) x := by + simp_rw [Matrix.det_fin_three] + have hc (i j : Fin 3) := contDiffAt_pi.mp (contDiffAt_pi.mp hA i) j + fun_prop + +lemma contDiffAt_mat3_adjugate {A : Coord3 → Mat3} {x : Coord3} {n : WithTop ℕ∞} + (hA : ContDiffAt ℝ n A x) : ContDiffAt ℝ n (fun y => (A y).adjugate) x := by + simp_rw [Matrix.adjugate_fin_three] + have hc (i j : Fin 3) := contDiffAt_pi.mp (contDiffAt_pi.mp hA i) j + apply contDiffAt_pi.mpr + intro i + apply contDiffAt_pi.mpr + intro j + fin_cases i <;> fin_cases j <;> norm_num only [Matrix.of_apply, Matrix.cons_val_zero', Matrix.cons_val_succ', Matrix.cons_val_zero, + Matrix.cons_val_one, Matrix.cons_val_two, Matrix.head_cons] <;> fun_prop + +lemma contDiffAt_mat3_inv {A : Coord3 → Mat3} {x : Coord3} {n : WithTop ℕ∞} + (hA : ContDiffAt ℝ n A x) (hd : (A x).det≠0) : + ContDiffAt ℝ n (fun y => (A y)⁻¹) x := by + simp_rw [Matrix.inv_def,Ring.inverse_eq_inv'] + exact ((contDiffAt_mat3_det hA).inv hd).smul (contDiffAt_mat3_adjugate hA) + +lemma contDiffAt_mat3_transpose {A : Coord3 → Mat3} {x : Coord3} {n : WithTop ℕ∞} + (hA : ContDiffAt ℝ n A x) : ContDiffAt ℝ n (fun y => (A y)ᵀ) x := by + exact contDiffAt_pi.mpr (fun i => contDiffAt_pi.mpr (fun j => + contDiffAt_pi.mp (contDiffAt_pi.mp hA j) i)) + +lemma contDiffAt_mat3_mul {A B : Coord3 → Mat3} {x : Coord3} {n : WithTop ℕ∞} + (hA : ContDiffAt ℝ n A x) (hB : ContDiffAt ℝ n B x) : + ContDiffAt ℝ n (fun y => A y*B y) x := by + apply contDiffAt_pi.mpr + intro i + apply contDiffAt_pi.mpr + intro j + simp only [Matrix.mul_apply] + exact ContDiffAt.sum (fun k _ => (contDiffAt_pi.mp (contDiffAt_pi.mp hA i) k).mul + (contDiffAt_pi.mp (contDiffAt_pi.mp hB k) j)) + +lemma contDiff_faceRayAngle (w : ℝ) (j : Fin 4) : + ContDiff ℝ (↑(⊤:ℕ∞)) (faceRayAngle w j) := by + have h1 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun b : ℝ => Real.arctan (b/w)) := + Real.contDiff_arctan.comp (contDiff_id.div_const w) + have h2 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun b : ℝ => Real.arctan (w*b)) := + Real.contDiff_arctan.comp (contDiff_const.mul contDiff_id) + unfold faceRayAngle + fin_cases j <;> simp only [Matrix.cons_val_zero', Matrix.cons_val_succ'] <;> fun_prop + +lemma contDiff_faceRayDensity (w : ℝ) (j : Fin 4) : + ContDiff ℝ (↑(⊤:ℕ∞)) (faceRayDensity w j) := by + have h1 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x : ℝ => (1+(x/w)^2)⁻¹) := + (contDiff_const.add ((contDiff_id.div_const w).pow 2)).inv (fun x => by positivity) + have h2 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x : ℝ => (1+(w*x)^2)⁻¹) := + (contDiff_const.add ((contDiff_const.mul contDiff_id).pow 2)).inv (fun x => by positivity) + unfold faceRayDensity + fin_cases j <;> dsimp <;> simp only [div_eq_mul_inv,one_mul] <;> fun_prop + +lemma contDiff_sourceFaceAngles (i j : Fin 4) : + ContDiff ℝ (↑(⊤:ℕ∞)) (sourceFaceAngles i j) := by + apply contDiff_pi.mpr + intro k + fin_cases k + · exact contDiff_apply _ _ _ + · exact contDiff_const.mul ((contDiff_faceRayAngle 1 i).comp (contDiff_apply _ _ 1)) + · exact contDiff_const.mul ((contDiff_faceRayAngle sourceRadialWidth j).comp (contDiff_apply _ _ 2)) + +lemma contDiff_sourceCollarJacobian (i j : Fin 4) : + ContDiff ℝ (↑(⊤:ℕ∞)) (sourceCollarJacobian i j) := by + apply contDiff_pi.mpr + intro a + apply contDiff_pi.mpr + intro b + fin_cases a <;> fin_cases b <;> + simp only [sourceCollarJacobian, sourceCollarRadius, squareFace, Matrix.cons_val_zero', + Matrix.cons_val_succ', Pi.add_apply, + Pi.smul_apply, smul_eq_mul] <;> fun_prop + +lemma contDiff_sourceFaceAngleMatrix (i j : Fin 4) : + ContDiff ℝ (↑(⊤:ℕ∞)) (sourceFaceAngleMatrix i j) := by + apply contDiff_pi.mpr + intro a + apply contDiff_pi.mpr + intro b + by_cases hab : a=b + · subst b + fin_cases a <;> simp only [sourceFaceAngleMatrix,Matrix.diagonal_apply_eq] + · exact contDiff_const + · exact contDiff_const.mul ((contDiff_faceRayDensity 1 i).comp (contDiff_apply _ _ 1)) + · exact contDiff_const.mul ((contDiff_faceRayDensity sourceRadialWidth j).comp (contDiff_apply _ _ 2)) + · simp only [sourceFaceAngleMatrix,Matrix.diagonal_apply_ne _ hab] + exact contDiff_const + +lemma contDiffAt_sourceCartesianGradientMatrix (i j : Fin 4) {x : Coord3} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + ContDiffAt ℝ (↑(⊤:ℕ∞)) (sourceCartesianGradientMatrix i j) x := by + have hi := contDiffAt_mat3_inv (contDiffAt_mat3_transpose (contDiff_sourceCollarJacobian i j).contDiffAt) + (by rw [Matrix.det_transpose]; exact sourceCollarJacobian_extended_ne_zero i j hx) + exact contDiffAt_mat3_mul hi (contDiff_sourceFaceAngleMatrix i j).contDiffAt + +lemma contDiffAt_attachedCartesianMatrix (a : ℝ) (i j : Fin 4) {x : Coord3} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + ContDiffAt ℝ (↑(⊤:ℕ∞)) (attachedCartesianMatrix a i j) x := + contDiffAt_mat3_mul (contDiffAt_sourceCartesianGradientMatrix i j hx) contDiffAt_const + +lemma contDiffAt_sourceFlatDensity (i j : Fin 4) {x : Coord3} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + ContDiffAt ℝ (↑(⊤:ℕ∞)) (sourceFlatDensity i j) x := by + exact (contDiffAt_mat3_det (contDiff_sourceFaceAngleMatrix i j).contDiffAt).div + ((contDiffAt_mat3_det (contDiff_sourceCollarJacobian i j).contDiffAt).abs + (sourceCollarJacobian_extended_ne_zero i j hx)) + (abs_ne_zero.mpr (sourceCollarJacobian_extended_ne_zero i j hx)) + +lemma contDiffAt_attachedVariableTensor {K : Coord3 → Mat3} {x : Coord3} + (hK : ContDiffAt ℝ (↑(⊤:ℕ∞)) K x) {a : ℝ} (ha : a≠0) (i j : Fin 4) + (hx : x∈sourceCollarOpenBox) : + ContDiffAt ℝ (↑(⊤:ℕ∞)) (attachedVariableTensor K a i j) x := by + have hi := contDiffAt_mat3_inv (contDiffAt_attachedCartesianMatrix a i j (sourceCollarOpenBox_subset hx)) + (attachedCartesianMatrix_det_ne_zero ha i j (sourceCollarOpenBox_subset hx)) + exact (contDiffAt_const.mul (contDiffAt_sourceFlatDensity i j (sourceCollarOpenBox_subset hx))).smul + (contDiffAt_mat3_mul (contDiffAt_mat3_mul (contDiffAt_mat3_transpose hi) hK) hi) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..89fee10212b901d18db6303d0c9f34fd0e1c13bc --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FiniteEndPhysicalTensor.lean @@ -0,0 +1,151 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedFlatTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +local instance finiteEndPhysicalTensorMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance finiteEndPhysicalTensorBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +lemma measurable_real_matrix_mul {α : Type*} [MeasurableSpace α] + {A B : α → Mat3} (hA : Measurable A) (hB : Measurable B) : + Measurable (fun x => A x*B x) := by + apply Measurable.of_eval + intro i + apply Measurable.of_eval + intro j + simp only [Matrix.mul_apply] + exact Finset.measurable_sum _ (fun k _ => hA.eval.eval.mul hB.eval.eval) + +lemma measurable_real_matrix_inverse : Measurable (fun A : Mat3 => A⁻¹) := by + simp_rw [Matrix.inv_def,Ring.inverse_eq_inv'] + exact continuous_id.matrix_det.measurable.inv.smul + continuous_id.matrix_adjugate.measurable + +lemma measurable_sourceCartesianGradientMatrix (i j : Fin 4) : + Measurable (sourceCartesianGradientMatrix i j) := by + unfold sourceCartesianGradientMatrix + exact measurable_real_matrix_mul (measurable_real_matrix_inverse.comp + (continuous_sourceCollarJacobian i j).matrix_transpose.measurable) + (continuous_sourceFaceAngleMatrix i j).measurable + +lemma measurable_attachedCartesianMatrix (a : ℝ) (i j : Fin 4) : + Measurable (attachedCartesianMatrix a i j) := + measurable_real_matrix_mul (measurable_sourceCartesianGradientMatrix i j) measurable_const + +lemma measurable_sourceFlatDensity (i j : Fin 4) : Measurable (sourceFlatDensity i j) := + (continuous_sourceFaceAngleMatrix i j).matrix_det.measurable.div + (continuous_sourceCollarJacobian i j).matrix_det.abs.measurable + +def attachedVariableTensor (K : Coord3 → Mat3) (a : ℝ) (i j : Fin 4) + (x : Coord3) : Mat3 := + (|a| *sourceFlatDensity i j x) • + ((attachedCartesianMatrix a i j x)⁻¹ᵀ*K x*(attachedCartesianMatrix a i j x)⁻¹) + +lemma attachedVariableTensor_measurable {K : Coord3 → Mat3} (hK : Measurable K) + (a : ℝ) (i j : Fin 4) : Measurable (attachedVariableTensor K a i j) := by + have hi := measurable_real_matrix_inverse.comp (measurable_attachedCartesianMatrix a i j) + have ht := (continuous_id.matrix_transpose : Continuous (fun A : Mat3 => Aᵀ)).measurable.comp hi + exact (measurable_const.mul (measurable_sourceFlatDensity i j)).smul (measurable_real_matrix_mul (measurable_real_matrix_mul ht hK) hi) + +lemma attachedVariableTensor_symmetric {K : Coord3 → Mat3} (hK : ∀ x,(K x)ᵀ=K x) + (a : ℝ) (i j : Fin 4) (x : Coord3) : + (attachedVariableTensor K a i j x)ᵀ=attachedVariableTensor K a i j x := by + simp only [attachedVariableTensor,Matrix.transpose_smul,Matrix.transpose_mul, + Matrix.transpose_transpose,hK,Matrix.mul_assoc] + +lemma attachedVariableTensor_energy (K : Coord3 → Mat3) {a : ℝ} (ha : a≠0) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) + (v w : Coord3) : + (attachedCartesianMatrix a i j x*ᵥv) ⬝ᵥ + (attachedVariableTensor K a i j x*ᵥ(attachedCartesianMatrix a i j x*ᵥw))= + |a| *sourceFlatDensity i j x*(v ⬝ᵥ(K x*ᵥw)) := + inverse_congruence_energy _ _ (attachedCartesianMatrix_det_ne_zero ha i j hx) _ _ _ + +lemma attachedVariableTensor_energy_density (K : Coord3 → Mat3) {a : ℝ} (ha : a≠0) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) + (v w : Coord3) : + |(sourceCollarJacobian i j x).det| *((attachedCartesianMatrix a i j x*ᵥv) ⬝ᵥ + (attachedVariableTensor K a i j x*ᵥ(attachedCartesianMatrix a i j x*ᵥw)))= + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (v ⬝ᵥ(K x*ᵥw)) := by + rw [attachedVariableTensor_energy K ha i j hx,sourceFlatDensity,sourceFaceAngleMatrix_det] + field_simp [abs_ne_zero.mpr (sourceCollarJacobian_extended_ne_zero i j hx)] + +theorem attachedVariableTensor_elliptic {K : Coord3 → Mat3} {c C : ℝ} + (hc : 0 fin_cases l <;> rfl + have href := attachedFlatTensor_energy ![1,0,1] ha i j hx u u + rw [hu,hid,Matrix.one_mulVec] at href + have he := attachedVariableTensor_energy K ha i j hx u u + rw [hu] at he + have hd : 0≤|a| *sourceFlatDensity i j x := + mul_nonneg (abs_nonneg _) (sourceFlatDensity_pos i j hx).le + have hh := hK x u + have hlow := mul_le_mul_of_nonneg_left hh.1 hd + have hupp := mul_le_mul_of_nonneg_left hh.2 hd + have hb := hbound x hx v + rw [href] at hb + rw [he] + constructor + · calc + c*l*‖v‖^2 = c*(l*‖v‖^2) := by ring + _ ≤ c*(|a| *sourceFlatDensity i j x*(u ⬝ᵥ u)) := mul_le_mul_of_nonneg_left hb.1 hc.le + _ = |a| *sourceFlatDensity i j x*(c*(u ⬝ᵥ u)) := by ring + _ ≤ _ := hlow + · calc + _ ≤ |a| *sourceFlatDensity i j x*(C*(u ⬝ᵥ u)) := hupp + _ = C*(|a| *sourceFlatDensity i j x*(u ⬝ᵥ u)) := by ring + _ ≤ C*(L*‖v‖^2) := mul_le_mul_of_nonneg_left hb.2 (hc.le.trans hcC) + _ = C*L*‖v‖^2 := by ring + +theorem attachedVariableTensor_energy_integral (K : Coord3 → Mat3) {a : ℝ} (ha : a≠0) + (i j : Fin 4) {l r : ℝ} (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (v w : Coord3 → Coord3) : + (∫ y in sourceCollarPiece i j '' sourceExtendedBox l r, + attachedPhysicalFlatGradient a i j v y ⬝ᵥ + (attachedVariableTensor K a i j (sourceCollarInverse i j y)*ᵥ + attachedPhysicalFlatGradient a i j w y))= + ∫ x in sourceExtendedBox l r, + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + (v x ⬝ᵥ(K x*ᵥw x)) := by + rw [sourceExtended_integral i j hl hr] + apply setIntegral_congr_fun measurableSet_Icc + intro x hx + have hx' : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100) := by + obtain ⟨ht,hi,hj⟩ := mem_sourceExtendedBox.mp hx + exact mem_sourceExtendedBox.mpr ⟨⟨hl.trans ht.1,ht.2.trans hr⟩,hi,hj⟩ + simp only [attachedPhysicalFlatGradient,sourceCollarInverse_extended i j hl hr hx,smul_eq_mul] + rw [sourceCollarDerivative_det,←sourceCollarJacobian_det] + exact attachedVariableTensor_energy_density K ha i j hx' (v x) (w x) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FlatBackgroundTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/FlatBackgroundTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b19e140d23b5f134bd409d2a7240ab411d8356e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FlatBackgroundTensor.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusFluxDecay +import OAI.Analysis.Conductivity.Sources.TorusMoments + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def flatBackgroundTensor (s : Fin 3→ℝ) : Mat3 := !![1,0,0;0,s 0,s 1;0,s 1,s 2] + +lemma flatBackgroundTensor_symm (s : Fin 3→ℝ) : (flatBackgroundTensor s).IsSymm := by + ext i j + fin_cases i <;> fin_cases j <;> rfl + +lemma flatBackgroundTensor_flux {s : Fin 3→ℝ} {u : Coord3→Fin 2→ℝ} + (hu : Differentiable ℝ u) (j : Fin 2) (x : Coord3) : + (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col j= + flatModeFlux s (fun y => u y j) x := by + have hd (i : Fin 3) : gradientColumns (fderiv ℝ u x) i j= + fderiv ℝ (fun y => u y j) x (flatAxis i) := by + rw [potential_component_fderiv hu] + rfl + ext i + fin_cases i <;> + simp [Matrix.col_apply,Fin.sum_univ_three,hd,flatBackgroundTensor, + flatModeFlux,Fin.reduceFinMk,Matrix.vecMul,dotProduct] + +lemma flatBackgroundTensor_source {s : Fin 3→ℝ} {u : Coord3→Fin 2→ℝ} + (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (j : Fin 2) (x : Coord3) : + symmetricSource (fun _ => flatBackgroundTensor s) u j x= + flatTensorLaplacian s (fun y => u y j) x := by + have he : (fun x => (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col j)= + flatModeFlux s (fun y => u y j) := funext (flatBackgroundTensor_flux (hu.differentiable (by simp)) j) + unfold symmetricSource + rw [he,flatModeFlux_divergence (((contDiff_pi.mp hu) j).contDiffAt)] + +lemma flatBackgroundTensor_crossFlux {s : Fin 3→ℝ} {u : Coord3→Fin 2→ℝ} + (hu : Differentiable ℝ u) (x : Coord3) : + symmetricCrossFlux (fun _ => flatBackgroundTensor s) u x= + flatCrossFlux s (fun y => u y 0) (fun y => u y 1) x := by + unfold symmetricCrossFlux flatCrossFlux + rw [flatBackgroundTensor_flux hu,flatBackgroundTensor_flux hu] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/FluxPotentialSymbol.lean b/lean/OAI/Analysis/Conductivity/Flux/FluxPotentialSymbol.lean new file mode 100644 index 0000000000000000000000000000000000000000..64dbe3c67e0c83c0f08f6c07b07565ef2c22ac0d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/FluxPotentialSymbol.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity +open Matrix + +def fluxPotentialSymbol {m n R : Type*} [Fintype m] [Fintype n] + [DecidableEq m] [DecidableEq n] [CommRing R] + (D : Matrix m n R) (N : Matrix n m R) : Matrix n n R := + (D * N).det • 1 - N * (D * N).adjugate * D + +theorem fluxPotentialSymbol_div {m n R : Type*} [Fintype m] [Fintype n] + [DecidableEq m] [DecidableEq n] [CommRing R] + (D : Matrix m n R) (N : Matrix n m R) : + D * fluxPotentialSymbol D N = 0 := by + unfold fluxPotentialSymbol + rw [Matrix.mul_sub, Matrix.mul_smul, Matrix.mul_one] + rw [← Matrix.mul_assoc, ← Matrix.mul_assoc, Matrix.mul_adjugate, + Matrix.smul_mul, Matrix.one_mul, sub_self] + +theorem fluxPotentialSymbol_on_ker {m n R : Type*} [Fintype m] [Fintype n] + [DecidableEq m] [DecidableEq n] [CommRing R] + (D : Matrix m n R) (N : Matrix n m R) (v : n → R) + (hv : D *ᵥ v = 0) : + fluxPotentialSymbol D N *ᵥ v = (D * N).det • v := by + simp only [fluxPotentialSymbol, Matrix.sub_mulVec, Matrix.smul_mulVec, + Matrix.one_mulVec, ← Matrix.mulVec_mulVec, hv, Matrix.mulVec_zero, sub_zero] + +theorem fluxPotentialSymbol_range {m n K : Type*} [Fintype m] [Fintype n] + [DecidableEq m] [DecidableEq n] [Field K] + (D : Matrix m n K) (N : Matrix n m K) (hdet : (D * N).det ≠ 0) : + Set.range (fluxPotentialSymbol D N).mulVec = + {v | D *ᵥ v = 0} := by + ext v + constructor + · rintro ⟨w, rfl⟩ + simp only [Set.mem_ofPred_eq, Matrix.mulVec_mulVec, + fluxPotentialSymbol_div, Matrix.zero_mulVec] + · intro hv + refine ⟨((D * N).det)⁻¹ • v, ?_⟩ + rw [Matrix.mulVec_smul, fluxPotentialSymbol_on_ker D N v hv, + smul_smul, inv_mul_cancel₀ hdet, one_smul] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/LinearFluxWeakTransport.lean b/lean/OAI/Analysis/Conductivity/Flux/LinearFluxWeakTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb0643c1e32aff77574a106d667c440a421c3a4a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/LinearFluxWeakTransport.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.LinearFiniteEndTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +lemma continuousLinearEquiv_det_ne_zero (P : Coord3 ≃L[ℝ] Coord3) : + (P : Coord3 →L[ℝ] Coord3).det≠0 := by + have hd : (fderiv ℝ (P : Coord3 → Coord3) 0).det≠0 := + fderiv_equiv_det_ne_zero P.toEquiv P.differentiable P.symm.differentiable 0 + simpa only [ContinuousLinearEquiv.fderiv] using hd + +lemma continuousLinearEquiv_quasiMeasurePreserving (P : Coord3 ≃L[ℝ] Coord3) : + Measure.QuasiMeasurePreserving P volume volume := + Measure.ContinuousLinearMap.quasiMeasurePreserving volume (P : Coord3 →L[ℝ] Coord3) + (continuousLinearEquiv_det_ne_zero P) + +lemma pi_clm_apply_sum {n : ℕ} (D : (Fin n → ℝ) →L[ℝ] ℝ) (v : Fin n → ℝ) : + D v=∑ i,v i*D (Pi.single i 1) := by + have he : v=∑ i,v i • Pi.single i 1 := by + simpa only [←Pi.single_smul,smul_eq_mul,mul_one] using + (Finset.univ_sum_single v).symm + calc + D v=D (∑ i,v i • Pi.single i 1) := congrArg D he + _ = _ := by simp only [map_sum,map_smul,smul_eq_mul] + +lemma coordinate_flux_pairing (F : Coord3 → Coord3) (ψ : SmoothScalar Coord3) (x : Coord3) : + fderiv ℝ ψ.val x (F x)=∑ i,F x i*(smoothDirection (Pi.single i 1) ψ).val x := + pi_clm_apply_sum _ _ + +def linearFluxPullback (P : Coord3 ≃L[ℝ] Coord3) (F : Coord3 → Coord3) (x : Coord3) : Coord3 := + P.symm (F (P x)) + +lemma linearFluxPullback_weak (P : Coord3 ≃L[ℝ] Coord3) + {F : Coord3 → Coord3} {U : Set Coord3} + (hF : ∀ ψ : SmoothScalar Coord3,HasCompactSupport ψ.val → tsupport ψ.val⊆U → + (∫ x,fderiv ℝ ψ.val x (F x))=0) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) + (hs : tsupport ψ.val⊆P ⁻¹' U) : + (∫ x,fderiv ℝ ψ.val x (linearFluxPullback P F x))=0 := by + let φ : SmoothScalar Coord3 := ⟨ψ.val ∘ P.symm,(smoothScalar_contDiff ψ).comp P.symm.contDiff⟩ + have hφc : HasCompactSupport φ.val := hc.comp_homeomorph P.symm.toHomeomorph + have hφs : tsupport φ.val⊆U := by + intro y hy + have hh : P.symm y∈tsupport ψ.val := tsupport_comp_subset_preimage ψ.val P.symm.continuous hy + simpa only [mem_preimage,P.apply_symm_apply] using hs hh + have he := piolaFlux_pairing volume P.symm.toEquiv P.symm.differentiable + (fderiv_equiv_det_ne_zero P.symm.toEquiv P.symm.differentiable P.differentiable) + F ψ.val ((smoothScalar_contDiff ψ).differentiable (by simp)) + have he' : (∫ x,|(P.symm : Coord3 →L[ℝ] Coord3).det|⁻¹ * + fderiv ℝ ψ.val x (linearFluxPullback P F x))=(0 : ℝ) := by + calc + _=(∫ x,fderiv ℝ ψ.val x (piolaFlux P.symm.toEquiv F x)) := by + congr 1 + funext x + have hd : fderiv ℝ P.symm.toEquiv (P.symm.toEquiv.symm x)= + (P.symm : Coord3 →L[ℝ] Coord3) := P.symm.fderiv + simp only [piolaFlux,hd,map_smul,smul_eq_mul] + rfl + _ = _ := he.trans (hF φ hφc hφs) + rw [integral_const_mul] at he' + exact (mul_eq_zero.mp he').resolve_left (inv_ne_zero (abs_ne_zero.mpr + (continuousLinearEquiv_det_ne_zero P.symm))) + +lemma continuous_flux_compact_test_integrable {F : Coord3 → Coord3} (hF : Continuous F) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) : + Integrable (fun x => fderiv ℝ ψ.val x (F x)) := by + simp_rw [coordinate_flux_pairing] + apply integrable_finsetSum + intro i _ + exact (((continuous_apply i).comp hF).mul + (smoothScalar_contDiff (smoothDirection (Pi.single i 1) ψ)).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (Pi.single i 1) hc).mul_left + +lemma linearFluxPullback_C1 (P : Coord3 ≃L[ℝ] Coord3) {F : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) : ContDiff ℝ 1 (linearFluxPullback P F) := + P.symm.contDiff.comp (hF.comp P.contDiff) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma matrix_mul_transpose_col_sum {n : ℕ} (M : Matrix (Fin 3) (Fin n) ℝ) + (N : Matrix (Fin 2) (Fin n) ℝ) (j : Fin 2) : + (M*Nᵀ).col j=∑ k,N j k • M.col k := by + ext i + simp only [Matrix.col_apply,Matrix.mul_apply,Matrix.transpose_apply,Finset.sum_apply, + Pi.smul_apply,smul_eq_mul,mul_comm] + +def linearColumnsPullback (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) + (G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ) (x : Coord3) : Matrix (Fin 3) (Fin 2) ℝ := + operatorMatrix (P.symm : Coord3 →L[ℝ] Coord3)*G (P x)* + (operatorMatrix (Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)))ᵀ + +lemma linearColumnsPullback_col (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) + (G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ) (x : Coord3) (j : Fin 2) : + (linearColumnsPullback P Q G x).col j= + ∑ k,operatorMatrix (Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)) j k • + linearFluxPullback P (fun y => (G y).col k) x := by + rw [linearColumnsPullback,matrix_mul_transpose_col_sum] + apply Finset.sum_congr rfl + intro k _ + congr 1 + exact operatorMatrix_mulVec (P.symm : Coord3 →L[ℝ] Coord3) ((G (P x)).col k) + +lemma linearColumnsPullback_C1 (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) + {G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} (hG : ContDiff ℝ 1 G) : + ContDiff ℝ 1 (linearColumnsPullback P Q G) := by + rw [contDiff_iff_contDiffAt] + intro x + exact contDiffAt_matrix_mul (contDiffAt_matrix_mul contDiffAt_const + ((hG.comp P.contDiff).contDiffAt)) contDiffAt_const + +lemma linearColumnsPullback_weak (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) + {G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} (hGc : Continuous G) {U : Set Coord3} + (hG : ∀ (j : Fin 2) (ψ : SmoothScalar Coord3),HasCompactSupport ψ.val → tsupport ψ.val⊆U → + (∫ x,fderiv ℝ ψ.val x ((G x).col j))=0) + (j : Fin 2) (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) + (hs : tsupport ψ.val⊆P ⁻¹' U) : + Integrable (fun x => fderiv ℝ ψ.val x ((linearColumnsPullback P Q G x).col j)) ∧ + (∫ x,fderiv ℝ ψ.val x ((linearColumnsPullback P Q G x).col j))=0 := by + have hcont (k : Fin 2) : Continuous (linearFluxPullback P (fun y => (G y).col k)) := by + have hgk : Continuous (fun y => (G y).col k) := + continuous_pi fun i => (continuous_apply k).comp ((continuous_apply i).comp hGc) + exact P.symm.continuous.comp (hgk.comp P.continuous) + have hI (k : Fin 2) := continuous_flux_compact_test_integrable (hcont k) ψ hc + have hw (k : Fin 2) := linearFluxPullback_weak P (hG k) ψ hc hs + have he (x : Coord3) : fderiv ℝ ψ.val x ((linearColumnsPullback P Q G x).col j)= + ∑ k,operatorMatrix (Q : (Fin 2 → ℝ) →L[ℝ] (Fin 2 → ℝ)) j k * + fderiv ℝ ψ.val x (linearFluxPullback P (fun y => (G y).col k) x) := by + rw [linearColumnsPullback_col,map_sum] + simp only [map_smul,smul_eq_mul] + simp_rw [he] + constructor + · exact integrable_finsetSum _ (fun k _ => (hI k).const_mul _) + · rw [integral_finsetSum _ (fun k _ => (hI k).const_mul _)] + simp only [integral_const_mul,hw,mul_zero,Finset.sum_const_zero] + +lemma linearTensorPullback_C1_representative (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) + {u : Coord3 → Fin 2 → ℝ} (hu : Differentiable ℝ u) {A : Coord3 → Mat3} + {G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} + (hG : ∀ᵐ x : Coord3,A x*gradientColumns (fderiv ℝ u x)=G x) : + ∀ᵐ x : Coord3,linearTensorPullback P A x* + gradientColumns (fderiv ℝ (fun y => Q (u (P y))) x)=linearColumnsPullback P Q G x := by + filter_upwards [(continuousLinearEquiv_quasiMeasurePreserving P).ae hG] with x hx + rw [linearTensorPullback_columns P Q A (hu _),hx] + rfl + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/LinearTensorEllipticity.lean b/lean/OAI/Analysis/Conductivity/Flux/LinearTensorEllipticity.lean new file mode 100644 index 0000000000000000000000000000000000000000..70647e5b94b64c61f2df657f951d7038304c0231 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/LinearTensorEllipticity.lean @@ -0,0 +1,267 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalTensorPatch +import OAI.Analysis.Conductivity.Geometry.RegularPatchTranslation +import OAI.Analysis.Conductivity.Flux.LinearFluxWeakTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma matrix_congruence_energy (N A : Mat3) (v : Coord3) : + v ⬝ᵥ ((N*A*Nᵀ)*ᵥv)=(Nᵀ*ᵥv) ⬝ᵥ (A*ᵥ(Nᵀ*ᵥv)) := by + rw [←Matrix.mulVec_mulVec,←Matrix.mulVec_mulVec] + calc + _ = (A*ᵥ(Nᵀ*ᵥv)) ⬝ᵥ (Nᵀ*ᵥv) := by + simpa only [Matrix.transpose_transpose] using + Matrix.dotProduct_transpose_mulVec Nᵀ v (A*ᵥ(Nᵀ*ᵥv)) + _ = _ := dotProduct_comm _ _ + +lemma linearTensorPullback_elliptic (P : Coord3 ≃L[ℝ] Coord3) + {A : Coord3 → Mat3} {c C : ℝ} (hc : 0 (operatorMatrix (P : Coord3 →L[ℝ] Coord3))ᵀ*ᵥw) hz + rw [Matrix.mulVec_mulVec,he,Matrix.one_mulVec,Matrix.mulVec_zero] at hh + exact hv hh + have he (v : Coord3) : v ⬝ᵥ ((N*Nᵀ)*ᵥv)=(Nᵀ*ᵥv) ⬝ᵥ (Nᵀ*ᵥv) := by + simpa only [Matrix.mul_one,Matrix.one_mulVec] using matrix_congruence_energy N 1 v + obtain ⟨l,L,hl,hlL,hbound⟩ := compact_matrix_energy_bounds isCompact_singleton + (fun _ : Unit => N*Nᵀ) continuousOn_const (fun _ _ v hv => by + rw [he] + exact lt_of_le_of_ne (Finset.sum_nonneg (fun i _ => mul_self_nonneg _)) + (Ne.symm (mt dotProduct_self_eq_zero.mp (hn v hv)))) + obtain ⟨d,D,hd,hdD,hid⟩ := identity_matrix_energy_bounds + have hD : 0 ⟨r • (A x).val,by + change (r • (A x).val)ᵀ=r • (A x).val + rw [Matrix.transpose_smul] + exact congrArg (r • ·) (show (A x).valᵀ=(A x).val from (A x).property)⟩) O := by + refine ⟨h.1,h.2.1,?_,h.2.2.2⟩ + change ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => r • (A x).val) O + exact (contDiffOn_const : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun _ : Coord3 => r) O).smul h.2.2.1 + +lemma mem_regularRegion_tensor_smul {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {U : Set Coord3} {x : Coord3} (h : x∈regularRegion u A U) (r : ℝ) : + x∈regularRegion u (fun y => ⟨r • (A y).val,by + change (r • (A y).val)ᵀ=r • (A y).val + rw [Matrix.transpose_smul] + exact congrArg (r • ·) (show (A y).valᵀ=(A y).val from (A y).property)⟩) U := by + obtain ⟨O,hOU,hO,hx⟩ := mem_regularRegion_iff.mp h + exact mem_regularRegion_iff.mpr ⟨O,hOU,hO.tensor_smul r,hx⟩ + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma flux_translate_weak {F : Coord3 → Coord3} {U : Set Coord3} (c : Coord3) + (hF : ∀ ψ : SmoothScalar Coord3,HasCompactSupport ψ.val → tsupport ψ.val⊆U → + (∫ x,fderiv ℝ ψ.val x (F x))=0) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) + (hs : tsupport ψ.val⊆(fun x => x-c) ⁻¹' U) : + (∫ x,fderiv ℝ ψ.val x (F (x-c)))=0 := by + let φ : SmoothScalar Coord3 := ⟨fun y => ψ.val (y+c), + (smoothScalar_contDiff ψ).comp (contDiff_id.add contDiff_const)⟩ + have hφc : HasCompactSupport φ.val := hc.comp_homeomorph (Homeomorph.addRight c) + have hφs : tsupport φ.val⊆U := by + intro y hy + have hh : y+c∈tsupport ψ.val := tsupport_comp_subset_preimage ψ.val + (continuous_id.add continuous_const) hy + simpa only [mem_preimage,add_sub_cancel_right] using hs hh + calc + _ = ∫ y,fderiv ℝ ψ.val (y+c) (F y) := by + simpa only [add_sub_cancel_right] using + (integral_add_right_eq_self (fun x => fderiv ℝ ψ.val x (F (x-c))) c).symm + _ = ∫ y,fderiv ℝ φ.val y (F y) := by simp only [φ,fderiv_comp_add_right] + _ = 0 := hF φ hφc hφs + +lemma translatedTensor_C1_representative {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Mat3} + {G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} (c : Coord3) (d : Fin 2 → ℝ) + (hG : ∀ᵐ x : Coord3,A x*gradientColumns (fderiv ℝ u x)=G x) : + ∀ᵐ x : Coord3,A (x-c)*gradientColumns + (fderiv ℝ (fun y => u (y-c)+d) x)=G (x-c) := by + filter_upwards [(measurePreserving_sub_right volume c).quasiMeasurePreserving.ae hG] with x hx + simpa only [fderiv_add_const,fderiv_comp_sub] using hx + +lemma scalar_flux_weak {F : Coord3 → Coord3} {U : Set Coord3} (r : ℝ) + (hF : ∀ ψ : SmoothScalar Coord3,HasCompactSupport ψ.val → tsupport ψ.val⊆U → + (∫ x,fderiv ℝ ψ.val x (F x))=0) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) (hs : tsupport ψ.val⊆U) : + (∫ x,fderiv ℝ ψ.val x (r • F x))=0 := by + simp only [map_smul,smul_eq_mul,integral_const_mul,hF ψ hc hs,mul_zero] + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +local instance : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +structure WeakFiniteTensorPair (U : Set Coord3) where + v : Coord3 → Fin 2 → ℝ + E : Coord3 → Mat3 + symm : ∀ x,(E x).IsSymm + smooth : ContDiff ℝ 2 v + measurable : Measurable E + elliptic : ∃ c C : ℝ,0 ⟨E y,symm y⟩) U + G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ + flux_C1 : ContDiff ℝ 1 G + constitution : ∀ᵐ x : Coord3,E x*gradientColumns (fderiv ℝ v x)=G x + weak : ∀ (j : Fin 2) (ψ : SmoothScalar Coord3),HasCompactSupport ψ.val → + tsupport ψ.val⊆U → (∫ x,fderiv ℝ ψ.val x ((G x).col j))=0 + +namespace WeakFiniteTensorPair + +lemma linear_smooth {U : Set Coord3} (d : WeakFiniteTensorPair U) + (P : Coord3 ≃L[ℝ] Coord3) (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) : + ContDiff ℝ 2 (fun x => Q (d.v (P x))) := Q.contDiff.comp (d.smooth.comp P.contDiff) + +lemma linear_elliptic {U : Set Coord3} (d : WeakFiniteTensorPair U) + (P : Coord3 ≃L[ℝ] Coord3) : + ∃ l L : ℝ,0 Q (d.v (P y))) + (fun y => ⟨linearTensorPullback P d.E y,linearTensorPullback_symmetric P d.symm y⟩) + (P ⁻¹' U) := by + filter_upwards [(continuousLinearEquiv_quasiMeasurePreserving P).ae d.regular] with x hx + intro hxU + exact mem_regularRegion_linearCoordinates (u := d.v) + (A := fun y => ⟨d.E y,d.symm y⟩) (U := U) P Q (x := x) (hx hxU) + +def linear {U : Set Coord3} (d : WeakFiniteTensorPair U) + (P : Coord3 ≃L[ℝ] Coord3) (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) : + WeakFiniteTensorPair (P ⁻¹' U) where + v x := Q (d.v (P x)) + E := linearTensorPullback P d.E + symm := linearTensorPullback_symmetric P d.symm + smooth := d.linear_smooth P Q + measurable := linearTensorPullback_measurable P d.measurable + elliptic := d.linear_elliptic P + regular := d.linear_regular P Q + G := linearColumnsPullback P Q d.G + flux_C1 := linearColumnsPullback_C1 P Q d.flux_C1 + constitution := linearTensorPullback_C1_representative P Q + (d.smooth.differentiable (by norm_num)) d.constitution + weak j ψ hc hs := (linearColumnsPullback_weak P Q d.flux_C1.continuous d.weak j ψ hc hs).2 + +def translate {U : Set Coord3} (d : WeakFiniteTensorPair U) (c : Coord3) (b : Fin 2 → ℝ) : + WeakFiniteTensorPair ((fun x => x-c) ⁻¹' U) where + v x := d.v (x-c)+b + E x := d.E (x-c) + symm x := d.symm (x-c) + smooth := (d.smooth.comp (contDiff_id.sub contDiff_const)).add contDiff_const + measurable := d.measurable.comp (measurable_id.sub measurable_const) + elliptic := by + obtain ⟨l,L,hl,hlL,hb⟩ := d.elliptic + exact ⟨l,L,hl,hlL,fun x => hb (x-c)⟩ + regular := by + filter_upwards [(measurePreserving_sub_right volume c).quasiMeasurePreserving.ae d.regular] with x hx + exact fun hxU => mem_regularRegion_translate (hx hxU) b + G x := d.G (x-c) + flux_C1 := d.flux_C1.comp (contDiff_id.sub contDiff_const) + constitution := translatedTensor_C1_representative c b d.constitution + weak j := flux_translate_weak c (d.weak j) + +def scaleTensor {U : Set Coord3} (d : WeakFiniteTensorPair U) (r : ℝ) (hr : 0 r)).smul d.measurable + elliptic := by + obtain ⟨l,L,hl,hlL,hb⟩ := d.elliptic + refine ⟨r*l,r*L,mul_pos hr hl,mul_le_mul_of_nonneg_left hlL hr.le,?_⟩ + intro x w + simp only [Matrix.smul_mulVec,dotProduct_smul,smul_eq_mul] + constructor + · simpa only [mul_assoc] using mul_le_mul_of_nonneg_left (hb x w).1 hr.le + · simpa only [mul_assoc] using mul_le_mul_of_nonneg_left (hb x w).2 hr.le + regular := by + filter_upwards [d.regular] with x hx + exact fun hxU => mem_regularRegion_tensor_smul (hx hxU) r + G x := r • d.G x + flux_C1 := (contDiff_const : ContDiff ℝ 1 (fun _ : Coord3 => r)).smul d.flux_C1 + constitution := by + filter_upwards [d.constitution] with x hx + rw [Matrix.smul_mul,hx] + weak j ψ hc hs := by + change (∫ x,fderiv ℝ ψ.val x (r • (d.G x).col j))=0 + exact scalar_flux_weak r (d.weak j) ψ hc hs + +lemma integrable {U : Set Coord3} (d : WeakFiniteTensorPair U) (j : Fin 2) + (ψ : SmoothScalar Coord3) (hc : HasCompactSupport ψ.val) : + Integrable (fun x => fderiv ℝ ψ.val x ((d.G x).col j)) := + continuous_flux_compact_test_integrable + (continuous_pi fun i => (continuous_apply j).comp ((continuous_apply i).comp d.flux_C1.continuous)) ψ hc + +end WeakFiniteTensorPair +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/LocalTensorBounds.lean b/lean/OAI/Analysis/Conductivity/Flux/LocalTensorBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..43371cb833727a3fc2661d89b280ffaad932f47a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/LocalTensorBounds.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.LocalSymmetricPiola + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma matrix_three_product_norm_bound (A B : Mat3) : ‖A*B‖≤3*‖A‖*‖B‖ := by + apply Matrix.norm_le_iff (by positivity) |>.mpr + intro i j + rw [Matrix.mul_apply] + calc + _ ≤ ∑ k : Fin 3,‖A i k*B k j‖ := norm_sum_le _ _ + _ ≤ ∑ _k : Fin 3,‖A‖*‖B‖ := by + apply Finset.sum_le_sum + intro k hk + rw [norm_mul] + exact mul_le_mul (Matrix.norm_entry_le_entrywise_sup_norm A) + (Matrix.norm_entry_le_entrywise_sup_norm B) (norm_nonneg _) (norm_nonneg _) + _ = _ := by simp; ring + +theorem localPiolaTensor_linear_bound + (X : OpenPartialHomeomorph Coord3 Coord3) + (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {K : Set Coord3} (hK : IsCompact K) (hKs : K⊆X.source) : + ∃ C : ℝ,0 operatorMatrix (fderiv ℝ X x) + let g : Coord3 → ℝ := fun x => 9*|(fderiv ℝ X x).det|⁻¹*‖A x‖*‖A x‖ + have hg : ContinuousOn g X.source := by + intro x hx + have hd : ContDiffAt ℝ (↑(⊤ : ℕ∞)) (fderiv ℝ X) x := + (hX.contDiffAt (X.open_source.mem_nhds hx)).fderiv_right (by simp) + have hdM := (operatorMatrix_contDiff (m := Fin 3) (n := Fin 3)).contDiffAt.comp x hd + have hd0 := local_fderiv_det_ne_zero X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) hx + have hdet := ((contDiff_clm_det (E := Coord3) (↑(⊤ : ℕ∞))).contDiffAt.comp x hd).abs hd0 + exact (((continuousAt_const.mul ((hdet.inv (abs_ne_zero.mpr hd0)).continuousAt)).mul + hdM.continuousAt.norm).mul hdM.continuousAt.norm).continuousWithinAt + obtain ⟨D,hD⟩ := (hK.image_of_continuousOn (hg.mono hKs)).isBounded.exists_norm_le + refine ⟨max D 1,lt_of_lt_of_le zero_lt_one (le_max_right _ _),?_⟩ + intro B hsB y + by_cases hy : y∈X.target + · by_cases hxy : X.symm y∈K + · have hbound : g (X.symm y)≤ max D 1 := + (le_abs_self _).trans ((hD _ (mem_image_of_mem _ hxy)).trans (le_max_left _ _)) + simp only [localPiolaTensor,ite_eq_left hy,norm_smul,Real.norm_eq_abs,abs_inv,abs_abs] + calc + _ ≤ |(fderiv ℝ X (X.symm y)).det|⁻¹ * (3*‖A (X.symm y)*B (X.symm y)‖*‖(A (X.symm y))ᵀ‖) := + mul_le_mul_of_nonneg_left (matrix_three_product_norm_bound _ _) (inv_nonneg.mpr (abs_nonneg _)) + _ ≤ |(fderiv ℝ X (X.symm y)).det|⁻¹ * (3*(3*‖A (X.symm y)‖*‖B (X.symm y)‖)*‖A (X.symm y)‖) := by + rw [Matrix.norm_transpose] + gcongr + exact matrix_three_product_norm_bound _ _ + _ = g (X.symm y)*‖B (X.symm y)‖ := by dsimp [g]; ring + _ ≤ _ := mul_le_mul_of_nonneg_right hbound (norm_nonneg _) + · have hz : B (X.symm y)=0 := by + by_contra hn + exact hxy (hsB hn) + simp [localPiolaTensor,hy,hz] + · simp only [localPiolaTensor,ite_eq_right hy,norm_zero] + exact mul_nonneg ((le_max_right D 1).trans' zero_le_one) (norm_nonneg _) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/LocalizedTwoFlux.lean b/lean/OAI/Analysis/Conductivity/Flux/LocalizedTwoFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a16869e951a24b306c3ae1aa4a1c47177169e05 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/LocalizedTwoFlux.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TwoFluxDivergence +import OAI.Analysis.Conductivity.Variational.LocalizedFirstPotential + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity +open Filter Topology + +theorem uniform_zero_const_mul {X I : Type*} {l : Filter I} + {f : I → X → ℝ} (c : ℝ) (hf : TendstoUniformly f (fun _ => 0) l) : + TendstoUniformly (fun i x => c * f i x) (fun _ => 0) l := by + simpa [Function.comp_def] using + (uniformContinuous_const_smul (X := ℝ) c).comp_tendstoUniformly hf + +theorem uniform_zero_add {X I : Type*} {l : Filter I} {f g : I → X → ℝ} + (hf : TendstoUniformly f (fun _ => 0) l) + (hg : TendstoUniformly g (fun _ => 0) l) : + TendstoUniformly (fun i x => f i x + g i x) (fun _ => 0) l := by + have hh := hf.add hg + change TendstoUniformly (fun i x => f i x + g i x) (fun _ => (0 : ℝ) + 0) l at hh + simpa only [add_zero] using hh + +theorem uniform_zero_sub {X I : Type*} {l : Filter I} {f g : I → X → ℝ} + (hf : TendstoUniformly f (fun _ => 0) l) + (hg : TendstoUniformly g (fun _ => 0) l) : + TendstoUniformly (fun i x => f i x - g i x) (fun _ => 0) l := by + have hh := hf.sub hg + change TendstoUniformly (fun i x => f i x - g i x) (fun _ => (0 : ℝ) - 0) l at hh + simpa only [sub_zero] using hh + +def localizedTwoFlux {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (χ : SmoothScalar E) (L : E →L[ℝ] ℝ) + (H₁ H₂ : SmoothScalar ℝ) (α p q r k : ℝ) : Fin 5 → SmoothScalar E := + α • airyFlux v (localizedSecondPotential χ L H₂ k) + + transverseFlux v (p • localizedFirstPotential χ L H₁ k) + (q • localizedFirstPotential χ L H₁ k) + (r • localizedFirstPotential χ L H₁ k) + +theorem twoFluxDivergence_add {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (F G : Fin 5 → SmoothScalar E) : + twoFluxDivergence v (F + G) = twoFluxDivergence v F + twoFluxDivergence v G := by + funext i + fin_cases i <;> simp [twoFluxDivergence] <;> abel + +theorem twoFluxDivergence_smul {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (c : ℝ) (F : Fin 5 → SmoothScalar E) : + twoFluxDivergence v (c • F) = c • twoFluxDivergence v F := by + funext i + fin_cases i <;> simp [twoFluxDivergence, smul_add] + +theorem localizedTwoFlux_divergence {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (χ : SmoothScalar E) (L : E →L[ℝ] ℝ) + (H₁ H₂ : SmoothScalar ℝ) (α p q r k : ℝ) : + twoFluxDivergence v (localizedTwoFlux v χ L H₁ H₂ α p q r k) = 0 := by + rw [localizedTwoFlux, twoFluxDivergence_add, twoFluxDivergence_smul, + airyFlux_divergence, transverseFlux_divergence, smul_zero, zero_add] + +theorem localizedTwoFlux_error_tendsto {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] (v : Fin 3 → E) (χ : SmoothScalar E) (L : E →L[ℝ] ℝ) + (h H₁ H₂ : SmoothScalar ℝ) (α p q r : ℝ) + (hχ : HasCompactSupport χ.val) + (h₁ : smoothDirection 1 H₁ = h) (h₂ : smoothDirection 1 H₂ = H₁) + (hB₁ : ∃ C : ℝ, ∀ t, |H₁.val t| ≤ C) + (hB₂ : ∃ C : ℝ, ∀ t, |H₂.val t| ≤ C) (i : Fin 5) : + TendstoUniformly + (fun k x => (localizedTwoFlux v χ L H₁ H₂ α p q r k i).val x - + (α • airySymbol (fun j => L (v j)) + + transverseSymbol (fun j => L (v j)) p q r) i * + (χ.val x * h.val (k * L x))) (fun _ => 0) atTop := by + have hfirst (j : Fin 3) := + localizedFirstPotential_error_tendsto (v j) χ L H₁ hχ hB₁ + simp only [h₁] at hfirst + have hsecond (j l : Fin 3) := + localizedSecondPotential_error_tendsto (v j) (v l) χ L H₂ hχ hB₂ + (by simpa only [h₂] using hB₁) + simp only [h₂, h₁] at hsecond + fin_cases i + · convert uniform_zero_add (uniform_zero_const_mul α (hsecond 1 1)) + (uniform_zero_const_mul p (hfirst 2)) using 1 + funext k x + simp [localizedTwoFlux, airyFlux, transverseFlux, airySymbol, transverseSymbol, + map_smul, Subalgebra.coe_add] + ring + · convert uniform_zero_add (uniform_zero_const_mul (-α) (hsecond 0 1)) + (uniform_zero_const_mul q (hfirst 2)) using 1 + funext k x + simp [localizedTwoFlux, airyFlux, transverseFlux, airySymbol, transverseSymbol, + map_smul, Subalgebra.coe_add] + ring + · convert uniform_zero_add (uniform_zero_const_mul α (hsecond 0 0)) + (uniform_zero_const_mul r (hfirst 2)) using 1 + funext k x + simp [localizedTwoFlux, airyFlux, transverseFlux, airySymbol, transverseSymbol, + map_smul, Subalgebra.coe_add] + ring + · convert uniform_zero_sub (uniform_zero_const_mul (-p) (hfirst 0)) + (uniform_zero_const_mul q (hfirst 1)) using 1 + funext k x + simp [localizedTwoFlux, airyFlux, transverseFlux, airySymbol, transverseSymbol, + map_smul] + ring + · convert uniform_zero_sub (uniform_zero_const_mul (-q) (hfirst 0)) + (uniform_zero_const_mul r (hfirst 1)) using 1 + funext k x + simp [localizedTwoFlux, airyFlux, transverseFlux, airySymbol, transverseSymbol, + map_smul] + ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/OpenRegularTensorTarget.lean b/lean/OAI/Analysis/Conductivity/Flux/OpenRegularTensorTarget.lean new file mode 100644 index 0000000000000000000000000000000000000000..d1bbfe1e0f673c06982985294e72146fdb6b4e73 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/OpenRegularTensorTarget.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactDepthReductionRegular +import OAI.Analysis.Conductivity.Geometry.RegularPatch + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma isOpen_regular_tensor_target (u : Coord3 → Fin 2 → ℝ) + (A : Coord3 → Symmetric3) (U : Set Coord3) {T : Set Symmetric3} (hT : IsOpen T) : + IsOpen (regularRegion u A U ∩ A ⁻¹' T) := by + rw [isOpen_iff_mem_nhds] + intro x hx + obtain ⟨O,hOU,hO,hxO⟩ := mem_regularRegion_iff.mp hx.1 + have hAc : ContinuousAt A x := Topology.IsInducing.subtypeVal.continuousAt_iff.mpr + (hO.2.2.1.continuousOn.continuousAt (hO.1.mem_nhds hxO)) + exact Filter.inter_mem ((isOpen_regularRegion u A U).mem_nhds hx.1) + (hAc.preimage_mem_nhds (hT.mem_nhds hx.2)) + +theorem finite_regular_depth_reduction + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + {U : Set Coord3} (hUb : Bornology.IsBounded U) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + {a b : ℝ} (ha : 0 < a) {T : Set DiagonalTriple} + (hT : IsOpen T) (hsub : ∀ d ∈ T, IsFiniteLaminate a b d) + (hperm : ∀ d ∈ T, ∀ e : Equiv.Perm (Fin 3), d ∘ e ∈ T) + {n : ℕ} (hsc : (spectralExtension (depthClass T n)).Nonempty) + {G : Set Coord3} (hGm : MeasurableSet G) + (hG : G ⊆ regularRegion u A U ∩ A ⁻¹' spectralExtension (depthClass T (n+1))) + {ε : ℝ} (hε : 0 < ε) : + ∃ (N : ℕ) (O : Fin N → Set Coord3) (R : ∀ i, CompactCompatibleReplacement μ (O i) u A), + (∀ i, IsOpen (O i) ∧ IsCompact (closure (O i)) ∧ closure (O i) ⊆ U ∧ μ (frontier (O i)) = 0) ∧ + Pairwise (fun i j => Disjoint (O i) (O j)) ∧ + (∀ i, RegularPatch (fun x => u x+(R i).du x) (R i).tensor (O i)) ∧ + (∀ i x, x ∈ O i → (R i).tensor x ∈ matrixFiniteLaminate a b) ∧ + μ (G \ ⋃ i, O i) + + ∑ i, μ {x | x ∈ O i ∧ (R i).tensor x ∉ spectralExtension (depthClass T n)} + ≤ ENNReal.ofReal ε := by + classical + have hlocal : ∀ p : G, ∃ W : Set Coord3, + IsOpen W ∧ p.val ∈ W ∧ closure W ⊆ U ∧ IsCompact (closure W) ∧ + ∀ O : Set Coord3, IsOpen O → O ⊆ W → ∀ δ : ℝ, 0 < δ → + ∃ R : CompactCompatibleReplacement μ O u A, + RegularPatch (fun x => u x+R.du x) R.tensor O ∧ + (∀ x ∈ O, R.tensor x ∈ matrixFiniteLaminate a b) ∧ + μ {x | x ∈ O ∧ R.tensor x ∉ spectralExtension (depthClass T n)} ≤ ENNReal.ofReal δ := by + intro p + obtain ⟨V,hVU,hV,hpV⟩ := mem_regularRegion_iff.mp (hG p.property).1 + obtain ⟨W,hW,hpW,hWV,hWc,hop⟩ := exists_compact_depth_reduction_regular μ u A + hV.1 (hUb.subset hVU) hV.2.1 hV.2.2.1 + (fun j ψ hs hc ht => hdiv j ψ hs hc (ht.trans hVU)) hV.2.2.2 + ha hT hsub hperm hpV (hG p.property).2 hsc + refine ⟨W,hW,hpW,hWV.trans hVU,hWc,?_⟩ + intro O hO hOW δ hδ + obtain ⟨R,hr,hRG,hbad⟩ := hop O hO hOW δ hδ + exact ⟨R,⟨hO,(hV.2.1.mono (hOW.trans (subset_closure.trans hWV))).add R.smooth_du.contDiffOn, + R.smooth_tensor,hr⟩,hRG,hbad⟩ + choose W hWo hpW hWU hWc hop using hlocal + have hμG : μ G ≠ ∞ := (hUb.subset (hG.trans (inter_subset_left.trans (regularRegion_subset u A U)))).measure_lt_top.ne + have hcover : G ⊆ ⋃ p : G, W p := fun x hx => mem_iUnion.mpr ⟨⟨x,hx⟩,hpW ⟨x,hx⟩⟩ + obtain ⟨N,O,tag,hO,hd,hmiss⟩ := finite_disjoint_localization_null μ hGm hμG W hWo hcover + (ENNReal.ofReal_pos.mpr (by linarith : 0 < ε/2)).ne' + let δ : ℝ := (ε/2) / (N+1) + have hδ : 0 < δ := div_pos (by linarith) (by positivity) + choose R hR hRG hbad using fun i => hop (tag i) (O i) (hO i).1 + (subset_closure.trans (hO i).2.2.1) δ hδ + refine ⟨N,O,R,fun i => ⟨(hO i).1,(hO i).2.1,(hO i).2.2.1.trans (subset_closure.trans (hWU (tag i))), + (hO i).2.2.2⟩,hd,hR,hRG,?_⟩ + have hsum : (∑ i : Fin N, μ {x | x ∈ O i ∧ (R i).tensor x ∉ spectralExtension (depthClass T n)}) + ≤ ENNReal.ofReal (ε/2) := by + calc + _ ≤ ∑ _i : Fin N, ENNReal.ofReal δ := Finset.sum_le_sum (fun i _ => hbad i) + _ = ENNReal.ofReal ((N : ℝ) * δ) := by simp [ENNReal.ofReal_mul] + _ ≤ ENNReal.ofReal (ε/2) := ENNReal.ofReal_le_ofReal (by + dsimp [δ] + rw [← mul_div_assoc] + apply (div_le_iff₀ (by positivity : (0:ℝ) < N+1)).mpr + nlinarith) + calc + _ ≤ ENNReal.ofReal (ε/2) + ENNReal.ofReal (ε/2) := add_le_add hmiss.le hsum + _ = ENNReal.ofReal ε := by rw [← ENNReal.ofReal_add (by linarith) (by linarith)]; congr 1; ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalAttachedGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalAttachedGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..02be3ddcc8211ee18c3c1c18c886321d8ea5600d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalAttachedGreen.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalOuterTrace +import OAI.Analysis.Conductivity.Fourier.SpectralTerminalL2 +import OAI.Analysis.Conductivity.Variational.PhysicalEnergyContinuous + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +lemma physicalEndLength_pos (a : Fin 3 → ℝ) (ha : ∀ i,a i≠0) (i : Fin 3) : + 0 Fin.cases ha₀.ne (fun k => (ha k).ne') i) + (fun i => centralT s i p) v := by + obtain ⟨p,w,hw0,hpm,hwc,hwe,hg⟩ := physical_attached_smooth_green_exists s a κ hs ha₀ ha hκ + exact ⟨p,w,hw0,hpm,hwc,hwe,fun v => physical_block_green_extension s a κ hs + (fun i => Fin.cases ha₀.ne (fun k => (ha k).ne') i) (fun i => centralT s i p) w hg v⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalBlockTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalBlockTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..60f1254e2c87382b9d8e792d5a32a3b10d76e8eb --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalBlockTensor.lean @@ -0,0 +1,212 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalTensorBound +import OAI.Analysis.Conductivity.Flux.PhysicalChildTensor +import OAI.Analysis.Conductivity.Geometry.PhysicalEndRegions + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal +local instance : MeasurableSpace (Matrix (Fin 3) (Fin 3) ℝ) := borel _ +local instance : BorelSpace (Matrix (Fin 3) (Fin 3) ℝ) := ⟨rfl⟩ + +lemma childAxis_pi_norm (v : Fin 3 → ℝ) : ‖fun i => v (childAxis i)‖=‖v‖ := by + apply le_antisymm + · exact (pi_norm_le_iff_of_nonneg (norm_nonneg v)).mpr + (fun i => norm_le_pi_norm v (childAxis i)) + · apply (pi_norm_le_iff_of_nonneg (norm_nonneg (fun i => v (childAxis i)))).mpr + intro i + have h := norm_le_pi_norm (fun j => v (childAxis j)) (childAxis i) + have he : childAxis (childAxis i)=i := by fin_cases i <;> rfl + simpa only [he] using h + +lemma sourceChildTensorPush_measurable (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) (hA : Measurable A) : + Measurable (sourceChildTensorPush k A) := by + let F : Matrix (Fin 3) (Fin 3) ℝ → Matrix (Fin 3) (Fin 3) ℝ := + fun M i j => sourceScale⁻¹*M (childAxis i) (childAxis j) + have hc : Continuous F := by + apply continuous_pi + intro i + apply continuous_pi + intro j + fun_prop + have hm : Measurable F := hc.measurable + exact hm.comp (hA.comp + (sourceChildHomeomorph (actualChildSign k)).symm.continuous.measurable) + +lemma sourceChildTensorPush_norm_bound (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) {B : ℝ} + (hB : 0 ≤ B) (hA : ∀ y,‖A y‖ ≤ B) (y : Fin 3 → ℝ) : + ‖sourceChildTensorPush k A y‖ ≤ |sourceScale⁻¹| * B := by + apply (pi_norm_le_iff_of_nonneg (mul_nonneg (abs_nonneg _) hB)).mpr + intro i + apply (pi_norm_le_iff_of_nonneg (mul_nonneg (abs_nonneg _) hB)).mpr + intro j + change ‖sourceScale⁻¹*A _ (childAxis i) (childAxis j)‖ ≤ _ + rw [norm_mul,Real.norm_eq_abs] + apply mul_le_mul_of_nonneg_left _ (abs_nonneg _) + exact ((norm_le_pi_norm _ (childAxis j)).trans + (norm_le_pi_norm _ (childAxis i))).trans (hA _) + +def physicalEndTensor (s a : Fin 3 → ℝ) (i : Fin 3) : + (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ := + Fin.cases (attachedCollarTensor s (a 0)) + (fun k => sourceChildTensorPush k (attachedCollarTensor s (a k.succ))) i + +lemma physicalEndTensor_properties (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) (i : Fin 3) : + Measurable (physicalEndTensor s a i) ∧ + (∀ y,(physicalEndTensor s a i y).IsSymm) ∧ + (∃ c C : ℝ,0 ?_) i + · have hp := attachedCollarTensor_properties s hs (ha 0) + exact ⟨hp.1,hp.2.1,hp.2.2.1,attachedFaceTensorList_bounded s (ha 0) _⟩ + · have hp := attachedCollarTensor_properties s hs (ha k.succ) + obtain ⟨c,C,hc,hcC,h⟩ := hp.2.2.1 + obtain ⟨B,hB,hbound⟩ := attachedFaceTensorList_bounded s (ha k.succ) + (Finset.univ : Finset (Fin 4 × Fin 4)).toList + have hspos : 0 v (childAxis j)) + rw [childAxis_pi_norm] at hh + exact ⟨by simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.1 hspos.le, + by simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.2 hspos.le⟩ + +def physicalBlockTensorList (s a : Fin 3 → ℝ) (is : List (Fin 3)) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := by + classical + exact is.foldr (fun i A => if y∈physicalEndRegion i then physicalEndTensor s a i y else A) 1 + +lemma physicalBlockTensorList_cons (s a : Fin 3 → ℝ) (i : Fin 3) (is : List (Fin 3)) + (y : Fin 3 → ℝ) : physicalBlockTensorList s a (i::is) y= + (by classical exact if y∈physicalEndRegion i then physicalEndTensor s a i y + else physicalBlockTensorList s a is y) := rfl + +lemma physicalBlockTensorList_properties (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) (is : List (Fin 3)) : + Measurable (physicalBlockTensorList s a is) ∧ + (∀ y,(physicalBlockTensorList s a is y).IsSymm) ∧ + (∃ c C : ℝ,0 + obtain ⟨c,C,hc,hcC,h⟩ := identity_matrix_energy_bounds + exact ⟨measurable_const,fun _ => Matrix.transpose_one, + ⟨c,C,hc,hcC,fun _ => h⟩, + ⟨‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖+1,by positivity,fun _ => by + change ‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖ ≤ _; linarith⟩⟩ + | cons i is ih => + have hi := physicalEndTensor_properties s a hs ha i + obtain ⟨c,C,hc,hcC,h⟩ := ih.2.2.1 + obtain ⟨d,D,hd,hdD,hlocal⟩ := hi.2.2.1 + obtain ⟨B,hB,hbound⟩ := ih.2.2.2 + obtain ⟨E,hE,hend⟩ := hi.2.2.2 + refine ⟨Measurable.ite (physicalEndRegion_compact i).measurableSet hi.1 ih.1,?_, + ⟨min c d,max C D,lt_min hc hd, + lt_of_le_of_lt (min_le_left _ _) (hcC.trans_le (le_max_left _ _)),?_⟩, + ⟨max B E,hB.trans_le (le_max_left _ _),?_⟩⟩ + · intro y + rw [physicalBlockTensorList_cons] + split_ifs + · exact hi.2.1 y + · exact ih.2.1 y + · intro y v + rw [physicalBlockTensorList_cons] + split_ifs with hy + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) (sq_nonneg _)).trans + (hlocal y v).1,(hlocal y v).2.trans + (mul_le_mul_of_nonneg_right (le_max_right _ _) (sq_nonneg _))⟩ + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) (sq_nonneg _)).trans + (h y v).1,(h y v).2.trans + (mul_le_mul_of_nonneg_right (le_max_left _ _) (sq_nonneg _))⟩ + · intro y + rw [physicalBlockTensorList_cons] + split_ifs + · exact (hend y).trans (le_max_right _ _) + · exact (hbound y).trans (le_max_left _ _) + +def physicalBlockTensor (s a : Fin 3 → ℝ) : + (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ := + physicalBlockTensorList s a (Finset.univ : Finset (Fin 3)).toList + +lemma physicalBlockTensor_local_list (s a : Fin 3 → ℝ) (is : List (Fin 3)) + (i : Fin 3) (hi : i∈is) {y : Fin 3 → ℝ} (hy : y∈physicalEndRegion i) : + physicalBlockTensorList s a is y=physicalEndTensor s a i y := by + classical + induction is with + | nil => simp at hi + | cons j is ih => + rw [physicalBlockTensorList_cons] + by_cases he : j=i + · subst j; simp only [ite_eq_left hy] + · have hn : y∉physicalEndRegion j := fun hj => + (disjoint_left.mp (physicalEndRegion_pairwise_disjoint he) hj hy) + rw [ite_eq_right hn] + exact ih ((List.mem_cons.mp hi).resolve_left (Ne.symm he)) + +lemma physicalBlockTensor_local (s a : Fin 3 → ℝ) (i : Fin 3) + {y : Fin 3 → ℝ} (hy : y∈physicalEndRegion i) : + physicalBlockTensor s a y=physicalEndTensor s a i y := + physicalBlockTensor_local_list s a _ i (by simp) hy + +lemma physicalBlockTensorList_outside (s a : Fin 3 → ℝ) (is : List (Fin 3)) + {y : Fin 3 → ℝ} (hy : ∀ i∈is,y∉physicalEndRegion i) : + physicalBlockTensorList s a is y=1 := by + classical + induction is with + | nil => rfl + | cons i is ih => + rw [physicalBlockTensorList_cons,ite_eq_right (hy i List.mem_cons_self)] + exact ih (fun j hj => hy j (List.mem_cons_of_mem i hj)) + +theorem physicalBlockTensor_properties (s a : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (ha : ∀ i,a i≠0) : + Measurable (physicalBlockTensor s a) ∧ + MemLp (physicalBlockTensor s a) ∞ (volume : Measure (Fin 3 → ℝ)) ∧ + (∀ y,(physicalBlockTensor s a y).IsSymm) ∧ + (∃ c C : ℝ,0 physicalBlockTensor_local s a i hy, + fun y hy => physicalBlockTensorList_outside s a _ (fun i _ => hy i)⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalChildTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalChildTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..7cec5e9789a605a53afba3490e05700bebddfcf4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalChildTensor.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ChildCentralL2 + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def sourceChildTensorPush (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + fun i j => sourceScale⁻¹ * + A ((sourceChildHomeomorph (actualChildSign k)).symm y) (childAxis i) (childAxis j) + +lemma sourceChildTensorPush_symmetric (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) + (hA : ∀ y,(A y).IsSymm) (y : Fin 3 → ℝ) : + (sourceChildTensorPush k A y).IsSymm := by + ext i j + exact congrArg (fun z : ℝ => sourceScale⁻¹*z) + (congrFun (congrFun (hA ((sourceChildHomeomorph (actualChildSign k)).symm y)) + (childAxis i)) (childAxis j)) + +lemma sourceChildTensorPush_mixed (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) + (y g v : Fin 3 → ℝ) : + sourceScale^3 * + ((fun i => sourceScale⁻¹*g (childAxis i)) ⬝ᵥ + (sourceChildTensorPush k A (sourceChildCoordinates (actualChildSign k) y)*ᵥv))= + g ⬝ᵥ (A y*ᵥ(fun i => sourceScale*v (childAxis i))) := by + have he : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)=y := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply y + simp only [sourceChildTensorPush,he,Matrix.mulVec,dotProduct,Fin.sum_univ_three] + have h₀ : childAxis 0=1 := rfl + have h₁ : childAxis 1=0 := rfl + have h₂ : childAxis 2=2 := rfl + simp only [h₀,h₁,h₂] + norm_num [sourceScale] + ring + +lemma sourceChildTensorPush_quadratic (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) + (y v : Fin 3 → ℝ) : + v ⬝ᵥ (sourceChildTensorPush k A y*ᵥv)= + sourceScale⁻¹*((fun i => v (childAxis i)) ⬝ᵥ + (A ((sourceChildHomeomorph (actualChildSign k)).symm y)*ᵥ + (fun i => v (childAxis i)))) := by + simp only [sourceChildTensorPush,Matrix.mulVec,dotProduct,Fin.sum_univ_three] + simp [childAxis] + ring + +lemma childAxis_norm_sq (v : Fin 3 → ℝ) : + (∑ i : Fin 3,(v (childAxis i))^2)=∑ i : Fin 3,(v i)^2 := by + simp only [Fin.sum_univ_three] + simp [childAxis] + ring + +lemma sourceChildTensorPush_elliptic (k : Fin 2) + (A : (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ) (c C : ℝ) + (hA : ∀ y v,c*(∑ i : Fin 3,(v i)^2)≤v ⬝ᵥ (A y*ᵥv) ∧ + v ⬝ᵥ (A y*ᵥv)≤C*(∑ i : Fin 3,(v i)^2)) (y v : Fin 3 → ℝ) : + (sourceScale⁻¹*c)*(∑ i : Fin 3,(v i)^2)≤ + v ⬝ᵥ (sourceChildTensorPush k A y*ᵥv) ∧ + v ⬝ᵥ (sourceChildTensorPush k A y*ᵥv)≤ + (sourceScale⁻¹*C)*(∑ i : Fin 3,(v i)^2) := by + rw [sourceChildTensorPush_quadratic] + have hh := hA ((sourceChildHomeomorph (actualChildSign k)).symm y) + (fun i => v (childAxis i)) + rw [childAxis_norm_sq] at hh + constructor + · simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.1 + (show 0 ≤ sourceScale⁻¹ by norm_num [sourceScale]) + · simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.2 + (show 0 ≤ sourceScale⁻¹ by norm_num [sourceScale]) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndDifferential.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..33838630b873da0ca3a080c5601d18b1cda501e4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndDifferential.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CollarLocalInverse +import OAI.Analysis.Conductivity.Fourier.EndPoissonDifferential + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix + +lemma physicalEndPoissonField_piece (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + physicalEndPoissonField s f 0 (sourceCollarPiece i j x)= + endFlatPoisson s f (sourceFaceAngles i j x) := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + rw [←sourceFaceAngles_physical i j ha hb,physicalEndPoissonField_angular s f 0 ht, + endFlatPoisson_eq] + rfl + +lemma physicalEndPoissonField_local_eq (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + physicalEndPoissonField s f 0 =ᶠ[𝓝 (sourceCollarPiece i j x)] + (fun y => endFlatPoisson s f (sourceFaceAngles i j (sourceCollarInverse i j y))) := by + change ∀ᶠ y in 𝓝 (sourceCollarPiece i j x),physicalEndPoissonField s f 0 y= + endFlatPoisson s f (sourceFaceAngles i j (sourceCollarInverse i j y)) + rw [←sourceCollarPiece_map_nhds i j hx,Filter.eventually_map] + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx, + sourceCollarInverse_eventually_left i j hx] with y hy hi + rw [hi] + exact physicalEndPoissonField_piece s f i j (sourceCollarOpenBox_subset hy) + +lemma sourceCollarInverse_point (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : sourceCollarInverse i j (sourceCollarPiece i j x)=x := + (sourceCollarInverse_eventually_left i j hx).self_of_nhds + +theorem physicalEndPoissonField_hasFDeriv (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) (ht : 0 L (Pi.single k 1)) ⬝ᵥ v := by + have hv : (∑ k,Pi.single k (v k))=v := LinearMap.sum_single_apply (fun _ : n => ℝ) v + conv_lhs => rw [←hv] + rw [map_sum] + apply Finset.sum_congr rfl + intro k _ + have hk : Pi.single k (v k)=v k • Pi.single k (1:ℝ) := by + rw [←Pi.single_smul]; simp + rw [hk,map_smul] + change v k*L (Pi.single k 1)=L (Pi.single k 1)*v k + ring + +lemma endFlatPoisson_realCLM_apply (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {x : Fin 3 → ℝ} (hx : 0 (endPoissonField s f k.succ (x 0,torusAngles x)).re) ⬝ᵥ v := by + change (Complex.reCLM.comp (fderiv ℝ (endFlatPoisson s f) x)) v=_ + rw [realCLM_apply_basis] + apply congrArg (fun g : Fin 3 → ℝ => g ⬝ᵥ v) + funext k + exact congrArg Complex.re (endFlatPoisson_derivative_axis s hs f hx k) + +theorem physicalEndPoisson_real_fderiv (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) (ht : 0 (physicalEndPoissonField s f 0 y).re) (sourceCollarPiece i j x) v= + (sourceCartesianGradientMatrix i j x *ᵥ + (fun k : Fin 3 => (endPoissonField s f k.succ + (x 0,torusAngles (sourceFaceAngles i j x))).re)) ⬝ᵥ v := by + let E := sourceCollarTangentEquiv i j x (sourceCollarOpenBox_subset hx) + let r : Fin 3 → ℝ := fun k => + (endPoissonField s f k.succ (x 0,torusAngles (sourceFaceAngles i j x))).re + let w := E.symm v + have hw : sourceCollarJacobian i j x *ᵥ w=v := E.apply_symm_apply v + have hd : (sourceFaceAngleMatrix i j x)ᵀ=sourceFaceAngleMatrix i j x := + Matrix.diagonal_transpose _ + have hp := Complex.reCLM.hasFDerivAt.comp (sourceCollarPiece i j x) + (physicalEndPoissonField_hasFDeriv s hs f i j hx ht) + calc + _ = (fderiv ℝ (endFlatPoisson s f) (sourceFaceAngles i j x) + (sourceFaceAngleMatrix i j x *ᵥ w)).re := + congrArg (fun L : (Fin 3 → ℝ) →L[ℝ] ℝ => L v) hp.fderiv + _ = r ⬝ᵥ (sourceFaceAngleMatrix i j x *ᵥ w) := + endFlatPoisson_realCLM_apply s hs f (x:=sourceFaceAngles i j x) ht _ + _ = w ⬝ᵥ (sourceFaceAngleMatrix i j x *ᵥ r) := by + rw [←Matrix.dotProduct_transpose_mulVec,hd] + _ = w ⬝ᵥ ((sourceCollarJacobian i j x)ᵀ *ᵥ + (sourceCartesianGradientMatrix i j x *ᵥ r)) := by + rw [sourceCartesianGradient_chain i j (sourceCollarOpenBox_subset hx)] + _ = (sourceCartesianGradientMatrix i j x *ᵥ r) ⬝ᵥ + (sourceCollarJacobian i j x *ᵥ w) := Matrix.dotProduct_transpose_mulVec _ _ _ + _ = _ := by rw [hw] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndSmoothGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndSmoothGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..9b02ceb4a98a23b25bb4c300353449b6d431d3db --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalEndSmoothGreen.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalEndSmoothEnergy + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix +open scoped ENNReal +local instance physicalEndSmoothGreenMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance physicalEndSmoothGreenIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma fullAttachedEnd_smooth_green_pos (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) + {φ : (Fin 3 → ℝ) → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + {a l r R : ℝ} (ha : 0 mul_pos ha (sub_pos.mpr ht.1)) + rw [he.2,mul_assoc,←mul_left_comm angularArea |a|, + integral_affineEndCoordinates_pos ha hlr.le hT (by ring) hR hRp.le + (sourceEndSmoothDensity_cylinder s hs f κ a⁻¹ l R hRp.le hφ).1, + sourceEndSmoothDensity_green s hs f κ a⁻¹ l R hRp hφ] + have hend : a⁻¹*R+l=r := by rw [←hR]; field_simp [ha.ne']; ring + rw [hend] + +lemma fullAttachedEnd_smooth_green_neg (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) + {φ : (Fin 3 → ℝ) → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + {a l r R : ℝ} (ha : a<0) (hlr : l mul_pos_of_neg_of_neg ha (sub_neg.mpr ht.2)) + rw [he.2,mul_assoc,←mul_left_comm angularArea |a|, + integral_affineEndCoordinates_neg ha hlr.le hT hR (by ring) hRp.le + (sourceEndSmoothDensity_cylinder s hs f κ a⁻¹ r R hRp.le hφ).1, + sourceEndSmoothDensity_green s hs f κ a⁻¹ r R hRp hφ] + have hend : a⁻¹*R+r=l := by rw [←hR]; field_simp [ha.ne]; ring + rw [hend] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalSplicedGreen.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalSplicedGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5951e56efc9daabd88a6b33bb51ab5649377324 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalSplicedGreen.lean @@ -0,0 +1,236 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalFiniteEndingData +import OAI.Analysis.Conductivity.Flux.AttachedSplicedGreen +import OAI.Analysis.Conductivity.Branching.VariableBlockEnergy + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +def flatTensor (i : Fin 3) : Coord3 → Mat3 := branchSplicedTensor i (z.ending i) + +lemma correctedEndJet_parent (j : Fin 2) (y : Coord3) : + (fun k : Fin 3 => z.correctedEndJet j 0 (WithLp.toLp 2 y) k.succ)= + splicedAttachedGradient (fun j => centralT s 0 (z.p j)) 0 (z.ending 0) j + (z.compression 0) centralThickness y := by + ext k + rfl + +lemma correctedEndJet_child (j : Fin 2) (n : Fin 2) (y : Coord3) : + (fun k : Fin 3 => z.correctedEndJet j n.succ (WithLp.toLp 2 y) k.succ)= + fun k => sourceScale⁻¹*splicedAttachedGradient (fun j => centralT s n.succ (z.p j)) + n.succ (z.ending n.succ) j (z.compression n.succ) (-centralThickness) + ((sourceChildHomeomorph (actualChildSign n)).symm y) (childAxis k) := by + ext k + dsimp [correctedEndJet,attachedPhysicalJet,periodicCorrectionJet,physicalJet,splicedAttachedGradient] + ring + +lemma corrected_child_energy_pullback (j : Fin 2) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (k : Fin 2) : + (∫ y in physicalEndRegion k.succ, + (fun n : Fin 3 => z.correctedEndJet j k.succ (WithLp.toLp 2 y) n.succ) ⬝ᵥ + (variableEndTensor z.flatTensor z.compression k.succ y*ᵥphysicalTestCovector φ y))= + ∫ y in sourceClosedCollarBand (-centralThickness) 0, + splicedAttachedGradient (fun j => centralT s k.succ (z.p j)) k.succ (z.ending k.succ) j + (z.compression k.succ) (-centralThickness) y ⬝ᵥ + (variableCollarTensor (z.flatTensor k.succ) (z.compression k.succ) (-centralThickness) y*ᵥ + physicalTestCovector (φ ∘ sourceChildCoordinates (actualChildSign k)) y) := by + have hreg : physicalEndRegion k.succ=sourceChildCoordinates (actualChildSign k) '' + sourceClosedCollarBand (-centralThickness) 0 := by + change (sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' _=_ + ext y + constructor + · intro hy + exact ⟨(sourceChildHomeomorph (actualChildSign k)).symm y,hy, + (sourceChildHomeomorph (actualChildSign k)).apply_symm_apply y⟩ + · rintro ⟨x,hx,rfl⟩ + change (sourceChildHomeomorph (actualChildSign k)).symm + ((sourceChildHomeomorph (actualChildSign k)) x)∈sourceClosedCollarBand (-centralThickness) 0 + simpa only [Homeomorph.symm_apply_apply] using hx + conv_lhs => rw [hreg] + conv_lhs => rw [sourceChild_integral (actualChildSign k) childEndBand_measurable] + apply integral_congr_ae + filter_upwards [] with y + rw [z.correctedEndJet_child] + have hv : (sourceChildHomeomorph (actualChildSign k)).symm + (sourceChildCoordinates (actualChildSign k) y)=y := + (sourceChildHomeomorph (actualChildSign k)).symm_apply_apply y + rw [hv] + change sourceScale^3*((fun n => sourceScale⁻¹*splicedAttachedGradient _ _ _ _ _ _ y (childAxis n)) ⬝ᵥ + (sourceChildTensorPush k _ (sourceChildCoordinates (actualChildSign k) y)*ᵥ + physicalTestCovector φ (sourceChildCoordinates (actualChildSign k) y)))=_ + rw [sourceChildTensorPush_mixed,physicalTestCovector_child hφ] + +lemma corrected_parent_jet_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) : + (∫ y in physicalEndRegion 0,(fun k : Fin 3 => z.correctedEndJet j 0 (WithLp.toLp 2 y) k.succ) ⬝ᵥ + (variableEndTensor z.flatTensor z.compression 0 y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s 0 (z.p j))) + (spectralGraphWeight (torusRate s) (centralT s 0 (physicalSmoothCentral s hφ)))- + centralBasisSlopes j 0*spectralGraphMean (torusRate s) (centralT s 0 (physicalSmoothCentral s hφ))+ + centralBasisSlopes j 0*spectralGraphMean (torusRate s) (physicalSmoothOuterTrace s hφ 0)) := by + simp_rw [z.correctedEndJet_parent] + change (∫ y in sourceClosedCollarBand 0 centralThickness,splicedAttachedGradient _ _ _ _ _ _ _ ⬝ᵥ + (variableCollarTensor _ _ _ _*ᵥphysicalTestCovector φ y))=_ + dsimp only [flatTensor] + rw [(splicedAttached_smooth_green_neg (fun j => centralT s 0 (z.p j)) 0 (z.ending 0) hs j hφ + (l:=0) (r:=centralThickness) z.compression_parent (by norm_num [centralThickness]) (R:=physicalEndLength z.compression 0) + (by dsimp [physicalEndLength]; rw [abs_of_neg z.compression_parent]; ring) + (by rw [z.end_length]; linarith) + (by norm_num) (by norm_num [centralThickness])).2,physicalSmoothCentral_parent_trace s hφ] + rfl + +lemma corrected_child_jet_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (k : Fin 2) : + (∫ y in physicalEndRegion k.succ,(fun n : Fin 3 => z.correctedEndJet j k.succ (WithLp.toLp 2 y) n.succ) ⬝ᵥ + (variableEndTensor z.flatTensor z.compression k.succ y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s k.succ (z.p j))) + (spectralGraphWeight (torusRate s) (centralT s k.succ (physicalSmoothCentral s hφ)))- + centralBasisSlopes j k.succ*spectralGraphMean (torusRate s) (centralT s k.succ (physicalSmoothCentral s hφ))+ + centralBasisSlopes j k.succ*spectralGraphMean (torusRate s) (physicalSmoothOuterTrace s hφ k.succ)) := by + rw [z.corrected_child_energy_pullback j hφ k] + dsimp only [flatTensor] + rw [(splicedAttached_smooth_green_pos (fun j => centralT s k.succ (z.p j)) k.succ (z.ending k.succ) hs j + (hφ.comp (sourceChildCoordinates_contDiff (actualChildSign k))) + (l:= -centralThickness) (r:=0) (z.compression_child k) (by norm_num [centralThickness]) (R:=physicalEndLength z.compression k.succ) + (by dsimp [physicalEndLength]; rw [abs_of_pos (z.compression_child k)]; ring) + (by rw [z.end_length]; linarith) + (by norm_num [centralThickness]) (by norm_num)).2,physicalSmoothCentral_child_trace s hφ k] + rfl + +lemma corrected_jet_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (i : Fin 3) : + (∫ y in physicalEndRegion i,(fun n : Fin 3 => z.correctedEndJet j i (WithLp.toLp 2 y) n.succ) ⬝ᵥ + (variableEndTensor z.flatTensor z.compression i y*ᵥphysicalTestCovector φ y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s i (z.p j))) + (spectralGraphWeight (torusRate s) (centralT s i (physicalSmoothCentral s hφ)))- + centralBasisSlopes j i*spectralGraphMean (torusRate s) (centralT s i (physicalSmoothCentral s hφ))+ + centralBasisSlopes j i*spectralGraphMean (torusRate s) (physicalSmoothOuterTrace s hφ i)) := + Fin.cases (z.corrected_parent_jet_green hs j hφ) (fun k => z.corrected_child_jet_green hs j hφ k) i + +end PhysicalFiniteEndingData +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +local instance physicalSplicedGreenMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance physicalSplicedGreenBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +def constantTerminalFluxCLM (κ : Fin 3 → ℝ) : H1 →L[ℝ] ℝ := + angularArea • ∑ i : Fin 3,κ i • + (Complex.reCLM.comp ((lp.evalCLM ℂ (fun _ : TorusModes => ℂ) 2 0).restrictScalars ℝ)).comp + (physicalOuterTraceCLM i) + +lemma constantTerminalFlux_smooth (s κ : Fin 3 → ℝ) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) : + constantTerminalFluxCLM κ (piSmoothH1 hφ)=angularArea*∑ i : Fin 3, + κ i*spectralGraphMean (torusRate s) (physicalSmoothOuterTrace s hφ i) := by + simp only [constantTerminalFluxCLM,_root_.smul_apply,_root_.sum_apply, + ContinuousLinearMap.comp_apply,smul_eq_mul] + congr 1 + apply Finset.sum_congr rfl + intro i _ + rw [physicalOuterTrace_smooth i hφ s] + rfl + +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +lemma flatTensor_properties + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (i : Fin 3) : + Measurable (z.flatTensor i) ∧ (∀ x,(z.flatTensor i x).IsSymm) ∧ + ∃ c C : ℝ,0 z.correctedEndJet j i (WithLp.toLp 2 y) k.succ) := by + apply originalPiGradient_eq_on_ball (fun _ => physicalEndRegion_subset_ball i) w _ + filter_upwards [hw] with x hx hy k + exact congrArg (fun v : JetFiber => v k.succ) (hx hy) + +lemma corrected_end_smooth_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) {w : H1} (hw : ∀ i,H1JetOn w (physicalEndRegion i) (z.correctedEndJet j i)) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) (i : Fin 3) : + (∫ y in physicalEndRegion i,originalPiGradient w y ⬝ᵥ + (variableEndTensor z.flatTensor z.compression i y*ᵥoriginalPiGradient (piSmoothH1 hφ) y))= + angularArea*(inner ℝ (spectralGraphWeight (torusRate s) (centralT s i (z.p j))) + (spectralGraphWeight (torusRate s) (centralT s i (physicalSmoothCentral s hφ)))- + centralBasisSlopes j i*spectralGraphMean (torusRate s) (centralT s i (physicalSmoothCentral s hφ))+ + centralBasisSlopes j i*spectralGraphMean (torusRate s) (physicalSmoothOuterTrace s hφ i)) := by + have he : (∫ y in physicalEndRegion i,originalPiGradient w y ⬝ᵥ + (variableEndTensor z.flatTensor z.compression i y*ᵥoriginalPiGradient (piSmoothH1 hφ) y))= + ∫ y in physicalEndRegion i,(fun n => z.correctedEndJet j i (WithLp.toLp 2 y) n.succ) ⬝ᵥ + (variableEndTensor z.flatTensor z.compression i y*ᵥphysicalTestCovector φ y) := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae (z.corrected_gradient j i (hw i)), + ae_restrict_of_ae (piSmoothH1_gradient hφ (fun _ => physicalEndRegion_subset_ball i)), + ae_restrict_mem (physicalEndRegion_compact i).measurableSet] with y hw hv hy + rw [hw hy,hv hy] + exact he.trans (z.corrected_jet_green hs j hφ i) + +lemma corrected_block_smooth_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (w : H1) (hwc : H1JetOn w centralPhysical (centralFullJetCLM s (z.p j).val)) + (hwe : ∀ i,H1JetOn w (physicalEndRegion i) (z.correctedEndJet j i)) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) : + (∫ y in physicalBlockRegion,originalPiGradient w y ⬝ᵥ + (variableBlockTensor z.flatTensor z.compression y*ᵥoriginalPiGradient (piSmoothH1 hφ) y))= + constantTerminalFluxCLM (centralBasisSlopes j) (piSmoothH1 hφ) := by + rw [(variableBlockTensor_energy_sum z.flatTensor z.compression (z.flatTensor_properties hs) + z.compression_ne w (piSmoothH1 hφ)).2, + central_physical_energy (z.p j) (physicalSmoothCentral s hφ) w (piSmoothH1 hφ) hwc + (physicalSmoothCentral_jet s hφ),constantTerminalFlux_smooth s] + simp_rw [z.corrected_end_smooth_green hs j hwe hφ] + rw [←Finset.mul_sum,Finset.sum_add_distrib,Finset.sum_sub_distrib] + have hv := z.variational j (physicalSmoothCentral s hφ) + nlinarith + +lemma corrected_block_green + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (j : Fin 2) (w : H1) (hwc : H1JetOn w centralPhysical (centralFullJetCLM s (z.p j).val)) + (hwe : ∀ i,H1JetOn w (physicalEndRegion i) (z.correctedEndJet j i)) (v : H1) : + (∫ y in physicalBlockRegion,originalPiGradient w y ⬝ᵥ + (variableBlockTensor z.flatTensor z.compression y*ᵥoriginalPiGradient v y))= + constantTerminalFluxCLM (centralBasisSlopes j) v := by + refine smoothPiH1L_dense.induction_on v ?_ ?_ + · exact isClosed_eq (variableBlockEnergy_continuous z.flatTensor z.compression + (z.flatTensor_properties hs) z.compression_ne w) + (constantTerminalFluxCLM (centralBasisSlopes j)).continuous + intro φ + exact z.corrected_block_smooth_green hs j w hwc hwe (smoothScalar_contDiff φ) + +theorem corrected_pair_green_exists + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) : + ∃ w : Fin 2 → H1,(∀ j,w j∈H10) ∧ + (∀ j,H1JetOn (w j) centralPhysical (centralFullJetCLM s (z.p j).val)) ∧ + (∀ j i,H1JetOn (w j) (physicalEndRegion i) (z.correctedEndJet j i)) ∧ + ∀ j v,(∫ y in physicalBlockRegion,originalPiGradient (w j) y ⬝ᵥ + (variableBlockTensor z.flatTensor z.compression y*ᵥoriginalPiGradient v y))= + constantTerminalFluxCLM (centralBasisSlopes j) v := by + obtain ⟨u,w,h0,hc,he,_⟩ := z.corrected_pair_exists hs + exact ⟨w,fun j => (h0 j).2,fun j => (hc j).2,fun j i => (he j i).2, + fun j v => z.corrected_block_green hs j (w j) (hc j).2 (fun i => (he j i).2) v⟩ + +end PhysicalFiniteEndingData +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorBound.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..0730888f5fa3c915ac46857f1f4dade4a247712e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorBound.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalFaceUniqueness + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal +local instance : MeasurableSpace (Matrix (Fin 3) (Fin 3) ℝ) := borel _ +local instance : BorelSpace (Matrix (Fin 3) (Fin 3) ℝ) := ⟨rfl⟩ + +lemma attachedFaceTensorList_bounded (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (ks : List (Fin 4 × Fin 4)) : + ∃ B : ℝ,0 + exact ⟨‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖+1,by positivity,fun _ => by + change ‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖≤_; linarith⟩ + | cons k ks ih => + obtain ⟨B,hB,h⟩ := ih + obtain ⟨C,hC⟩ := (isCompact_sourceFlatPatch k.1 k.2).exists_bound_of_continuousOn + (continuousOn_attachedPhysicalFlatTensor s ha k.1 k.2) + refine ⟨max B C,lt_of_lt_of_le hB (le_max_left _ _),?_⟩ + intro y + rw [attachedFaceTensorList_cons] + by_cases hy : y∈sourceFlatPatch k.1 k.2 + · simp only [ite_eq_left hy,attachedPatchTensor] + exact (hC y hy).trans (le_max_right _ _) + · simp only [ite_eq_right hy] + exact (h y).trans (le_max_left _ _) + +lemma attachedCollarTensor_memLp_top (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) : + MemLp (attachedCollarTensor s a) ∞ (volume : Measure (Fin 3 → ℝ)) := by + let : TopologicalSpace.PseudoMetrizableSpace (Matrix (Fin 3) (Fin 3) ℝ) := + inferInstanceAs (TopologicalSpace.PseudoMetrizableSpace (Fin 3 → Fin 3 → ℝ)) + let : SecondCountableTopology (Matrix (Fin 3) (Fin 3) ℝ) := + inferInstanceAs (SecondCountableTopology (Fin 3 → Fin 3 → ℝ)) + obtain ⟨B,_,hB⟩ := attachedFaceTensorList_bounded s ha + (Finset.univ : Finset (Fin 4 × Fin 4)).toList + exact memLp_top_of_bound (attachedFaceTensorList_measurable s ha _).aestronglyMeasurable + B (ae_of_all _ hB) + +theorem attachedCollarTensor_poisson_energy (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f g : spectralTraceGraph (torusRate s)) {a b : ℝ} (ha : a≠0) + (i j : Fin 4) {x : Fin 3 → ℝ} (hx : x∈sourceCollarOpenBox) + (ht : 0 fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) + (sourceCollarPiece i j x) (Pi.single k 1) + let G := fun k : Fin 3 => fderiv ℝ (fun y => (attachedEndPoissonField s g a b 0 y).re) + (sourceCollarPiece i j x) (Pi.single k 1) + |(sourceCollarJacobian i j x).det| *(F ⬝ᵥ + (attachedCollarTensor s a (sourceCollarPiece i j x)*ᵥG))= + |a| *angularArea*faceRayDensity 1 i (x 1)*faceRayDensity sourceRadialWidth j (x 2)* + ((fun k : Fin 3 => (endPoissonField s f k.succ + (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re) ⬝ᵥ + (flatCylinderMatrix s*ᵥ(fun k : Fin 3 => (endPoissonField s g k.succ + (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re))) := by + dsimp only + simp_rw [attachedCartesianMatrix_poisson_derivative s hs f a b i j hx ht, + attachedCartesianMatrix_poisson_derivative s hs g a b i j hx ht] + simp only [dotProduct_single,mul_one,attachedCollarTensor_open s a i j hx] + exact attachedFlatTensor_energy_density s ha i j (sourceCollarOpenBox_subset hx) _ _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorPatch.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorPatch.lean new file mode 100644 index 0000000000000000000000000000000000000000..628faf1b3d5ea6906d577c33883d523727aecfae --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalTensorPatch.lean @@ -0,0 +1,223 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedFlatTransport + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise +local instance physicalTensorPatchMeasurableSpace : + MeasurableSpace (Matrix (Fin 3) (Fin 3) ℝ) := borel _ +local instance physicalTensorPatchBorelSpace : BorelSpace (Matrix (Fin 3) (Fin 3) ℝ) := ⟨rfl⟩ + +def sourceFlatPatch (i j : Fin 4) : Set (Fin 3 → ℝ) := + sourceCollarPiece i j '' sourceExtendedBox (-(1:ℝ)/100) (1/100) + +lemma isCompact_sourceFlatPatch (i j : Fin 4) : IsCompact (sourceFlatPatch i j) := + isCompact_Icc.image (sourceCollarPiece_contDiff i j).continuous + +lemma continuousAt_sourceCollarInverse_patch (i j : Fin 4) {y : Fin 3 → ℝ} + (hy : y∈sourceFlatPatch i j) : ContinuousAt (sourceCollarInverse i j) y := by + obtain ⟨x,hx,rfl⟩ := hy + obtain ⟨ht,hi,hj⟩ := mem_sourceExtendedBox.mp hx + have hr : 0 (continuousAt_sourceCollarInverse_patch i j hy).continuousWithinAt) + rintro _ ⟨x,hx,rfl⟩ + simpa only [sourceCollarInverse_extended i j (le_refl _) (le_refl _) hx] using hx + +def attachedPatchTensor (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := + by classical exact if y∈sourceFlatPatch i j then attachedPhysicalFlatTensor s a i j y else 1 + +lemma measurable_attachedPatchTensor (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (i j : Fin 4) : Measurable (attachedPatchTensor s a i j) := by + classical + exact (continuousOn_attachedPhysicalFlatTensor s ha i j).measurable_piecewise + continuousOn_const (isCompact_sourceFlatPatch i j).isClosed.measurableSet + +lemma attachedPatchTensor_symmetric (s : Fin 3 → ℝ) (a : ℝ) (i j : Fin 4) + (y : Fin 3 → ℝ) : (attachedPatchTensor s a i j y)ᵀ=attachedPatchTensor s a i j y := by + classical + unfold attachedPatchTensor + split_ifs + · exact attachedPhysicalFlatTensor_symmetric s a i j y + · exact Matrix.transpose_one + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise +local instance attachedFaceTensorListMeasurableSpace : + MeasurableSpace (Matrix (Fin 3) (Fin 3) ℝ) := borel _ +local instance attachedFaceTensorListBorelSpace : BorelSpace (Matrix (Fin 3) (Fin 3) ℝ) := ⟨rfl⟩ + +def attachedFaceTensorList (s : Fin 3 → ℝ) (a : ℝ) (ks : List (Fin 4 × Fin 4)) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := by + classical + exact ks.foldr (fun k A => if y∈sourceFlatPatch k.1 k.2 then + attachedPatchTensor s a k.1 k.2 y else A) 1 + +lemma attachedFaceTensorList_cons (s : Fin 3 → ℝ) (a : ℝ) + (k : Fin 4 × Fin 4) (ks : List (Fin 4 × Fin 4)) (y : Fin 3 → ℝ) : + attachedFaceTensorList s a (k::ks) y= + (by classical exact if y∈sourceFlatPatch k.1 k.2 then attachedPatchTensor s a k.1 k.2 y + else attachedFaceTensorList s a ks y) := by + classical + rfl + +lemma attachedFaceTensorList_measurable (s : Fin 3 → ℝ) {a : ℝ} (ha : a≠0) + (ks : List (Fin 4 × Fin 4)) : Measurable (attachedFaceTensorList s a ks) := by + classical + induction ks with + | nil => exact measurable_const + | cons k ks ih => + exact Measurable.ite (isCompact_sourceFlatPatch k.1 k.2).isClosed.measurableSet + (measurable_attachedPatchTensor s ha k.1 k.2) ih + +lemma attachedFaceTensorList_symmetric (s : Fin 3 → ℝ) (a : ℝ) + (ks : List (Fin 4 × Fin 4)) (y : Fin 3 → ℝ) : + (attachedFaceTensorList s a ks y)ᵀ=attachedFaceTensorList s a ks y := by + classical + induction ks with + | nil => exact Matrix.transpose_one + | cons k ks ih => + simp only [attachedFaceTensorList_cons] + split_ifs + · exact attachedPatchTensor_symmetric s a k.1 k.2 y + · exact ih + +lemma identity_matrix_energy_bounds : ∃ c C : ℝ,0 mul_self_nonneg (v k))) + (Ne.symm (mt dotProduct_self_eq_zero.mp hv)) + obtain ⟨c,C,hc,hcC,h⟩ := compact_matrix_energy_bounds isCompact_singleton + (fun _ : Unit => (1 : Matrix (Fin 3) (Fin 3) ℝ)) continuousOn_const hp + exact ⟨c,C,hc,hcC,h () (mem_singleton ())⟩ + +lemma attachedFaceTensorList_elliptic (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a : ℝ} (ha : a≠0) (ks : List (Fin 4 × Fin 4)) : + ∃ c C : ℝ,0 + obtain ⟨c,C,hc,hcC,h⟩ := identity_matrix_energy_bounds + exact ⟨c,C,hc,hcC,fun _ => h⟩ + | cons k ks ih => + obtain ⟨c,C,hc,hcC,h⟩ := ih + obtain ⟨d,D,hd,hdD,hk⟩ := attachedPhysicalFlatTensor_elliptic s hs ha k.1 k.2 + refine ⟨min c d,max C D,lt_min hc hd, + lt_of_le_of_lt (min_le_left _ _) (hcC.trans_le (le_max_left _ _)),?_⟩ + intro y v + simp only [attachedFaceTensorList_cons] + by_cases hy : y∈sourceFlatPatch k.1 k.2 + · simp only [ite_eq_left hy,attachedPatchTensor] + exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) (sq_nonneg _)).trans + (hk y hy v).1, + (hk y hy v).2.trans (mul_le_mul_of_nonneg_right (le_max_right _ _) (sq_nonneg _))⟩ + · simp only [ite_eq_right hy] + exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) (sq_nonneg _)).trans + (h y v).1, + (h y v).2.trans (mul_le_mul_of_nonneg_right (le_max_left _ _) (sq_nonneg _))⟩ + +lemma attachedFaceTensorList_outside (s : Fin 3 → ℝ) (a : ℝ) + (ks : List (Fin 4 × Fin 4)) (y : Fin 3 → ℝ) + (hy : ∀ k∈ks,y∉sourceFlatPatch k.1 k.2) : attachedFaceTensorList s a ks y=1 := by + classical + induction ks with + | nil => rfl + | cons k ks ih => + simpa only [attachedFaceTensorList,List.foldr_cons,ite_eq_right (hy k (List.mem_cons_self))] + using ih (fun l hl => hy l (List.mem_cons_of_mem k hl)) + +lemma attachedFaceTensorList_local (s : Fin 3 → ℝ) (a : ℝ) + (ks : List (Fin 4 × Fin 4)) (y : Fin 3 → ℝ) + (hy : ∃ k∈ks,y∈sourceFlatPatch k.1 k.2) : + ∃ k∈ks,y∈sourceFlatPatch k.1 k.2 ∧ + attachedFaceTensorList s a ks y=attachedPhysicalFlatTensor s a k.1 k.2 y := by + classical + induction ks with + | nil => simp at hy + | cons k ks ih => + by_cases hk : y∈sourceFlatPatch k.1 k.2 + · refine ⟨k,List.mem_cons_self,hk,?_⟩ + simp only [attachedFaceTensorList,List.foldr_cons,ite_eq_left hk,attachedPatchTensor] + · obtain ⟨l,hl,hy⟩ := hy + obtain ⟨l,hl,hly,he⟩ := ih ⟨l,(List.mem_cons.mp hl).resolve_left + (fun e => hk (e ▸ hy)),hy⟩ + refine ⟨l,List.mem_cons_of_mem k hl,hly,?_⟩ + simpa only [attachedFaceTensorList,List.foldr_cons,ite_eq_right hk] using he + +def attachedCollarTensor (s : Fin 3 → ℝ) (a : ℝ) : + (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ := + attachedFaceTensorList s a (Finset.univ : Finset (Fin 4 × Fin 4)).toList + +theorem attachedCollarTensor_properties (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a : ℝ} (ha : a≠0) : + Measurable (attachedCollarTensor s a) ∧ + (∀ y,(attachedCollarTensor s a y)ᵀ=attachedCollarTensor s a y) ∧ + (∃ c C : ℝ,0 hy k.1 k.2) + · rintro y ⟨i,j,hy⟩ + obtain ⟨k,_,hk,he⟩ := attachedFaceTensorList_local s a + (Finset.univ : Finset (Fin 4 × Fin 4)).toList y ⟨(i,j),by simp,hy⟩ + exact ⟨k.1,k.2,hk,he⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PhysicalVoltageFlux.lean b/lean/OAI/Analysis/Conductivity/Flux/PhysicalVoltageFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..69214179ca17cda99a63427c72c7ba5bf5d242f0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PhysicalVoltageFlux.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.FieldVectorCLM +import OAI.Analysis.Conductivity.Flux.PhysicalTensorPatch + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +lemma voltageFlux_component (v : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (y : Coord3) (i : Fin 3) (j : Fin 2) : + voltageFlux v A y (i,j)=∑ k : Fin 3,(A y).val i k*voltageGradient v y (k,j) := rfl + +lemma voltageFlux_memLp {U : Set Coord3} (v : Coord3 → Fin 2 → ℝ) + (A : Coord3 → Symmetric3) (hE : MemLp (voltageGradient v) 2 (volume.restrict U)) + (hA : ∀ i j,MemLp (fun y => (A y).val i j) ∞ (volume.restrict U)) : + MemLp (voltageFlux v A) 2 (volume.restrict U) := by + apply memLp_piLp_iff.mpr + intro ⟨i,j⟩ + simp only [voltageFlux_component] + apply memLp_finsetSum + intro k _ + exact (hA i k).mul (r := 2) ((memLp_piLp_iff.mp hE) (k,j)) + +lemma fderiv_flux_eq_sum + (D : Coord3 →L[ℝ] ℝ) (F : Matrix (Fin 3) (Fin 2) ℝ) (j : Fin 2) : + D (F.col j)=∑ i : Fin 3,D (Pi.single i 1)*F i j := by + have he : F.col j=∑ i : Fin 3,F i j • (Pi.single i 1 : Coord3) := by + ext k + simp [Pi.single_apply,Matrix.col_apply] + rw [he,map_sum] + apply Finset.sum_congr rfl + intro i _ + rw [map_smul,smul_eq_mul,mul_comm] + +lemma smoothFluxIntegrable_of_L2 {U : Set Coord3} (v : Coord3 → Fin 2 → ℝ) + (A : Coord3 → Symmetric3) (hF : MemLp (voltageFlux v A) 2 (volume.restrict U)) : + SmoothFluxIntegrable volume U (conductivityFlux v A) := by + intro j ψ hψ hc hs + have hD (i : Fin 3) : MemLp (fun y => fderiv ℝ ψ y (Pi.single i 1)) 2 volume := by + apply Continuous.memLp_of_hasCompactSupport + · exact (hψ.continuous_fderiv (by simp)).clm_apply continuous_const + · exact (hc.fderiv ℝ).comp_left (g:=fun D : Coord3 →L[ℝ] ℝ => D (Pi.single i 1)) rfl + have hi : Integrable (fun y => fderiv ℝ ψ y ((conductivityFlux v A y).col j)) + (volume.restrict U) := by + simp_rw [fderiv_flux_eq_sum] + apply integrable_finsetSum + intro i _ + exact ((hD i).restrict U).integrable_mul ((memLp_piLp_iff.mp hF) (i,j)) + apply (integrableOn_iff_integrable_of_support_subset (s:=U) ?_).mp hi + intro y hy + by_contra hn + have hz : y∉tsupport ψ := fun h => hn (hs h) + exact hy (by dsimp only; rw [fderiv_of_notMem_tsupport ℝ hz]; rfl) + +lemma norm_elliptic_to_dot {A : Coord3 → Mat3} {c C : ℝ} + (hc : 0 F x + G x) = fun x => piolaFlux Y F x + piolaFlux Y G x := by + funext x + simp only [piolaFlux, map_add, smul_add] + +lemma piolaFlux_tsupport_subset {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (Y : E ≃ E) {K : Set E} (hK : IsClosed K) (hoff : ∀ x ∉ K, Y x = x) + (F : E → E) (hF : tsupport F ⊆ K) : tsupport (piolaFlux Y F) ⊆ K := by + apply closure_minimal _ hK + intro x hx + by_contra hn + have hi := equiv_symm_eq_off Y hoff x hn + have hz : F x = 0 := image_eq_zero_of_notMem_tsupport (fun h => hn (hF h)) + apply hx + simp only [piolaFlux, hi, hz, map_zero, smul_zero] + +theorem local_compact_recomposition_difference + {E V : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup V] [NormedSpace ℝ V] + (Y : E ≃ E) (hi : ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm) + {K U : Set E} (hU : IsOpen U) (hUb : Bornology.IsBounded U) + (hK : IsCompact K) (hKU : K ⊆ U) (hoff : ∀ x ∉ K, Y x = x) + (u : E → V) (hu : ContDiffOn ℝ (↑(⊤ : ℕ∞)) u U) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => u (Y.symm x)-u x) ∧ + HasCompactSupport (fun x => u (Y.symm x)-u x) ∧ + tsupport (fun x => u (Y.symm x)-u x) ⊆ K := by + obtain ⟨v, W, hv, _, _, hKW, _, he⟩ := exists_smooth_compact_extension hU hUb hK hKU u hu + have heq : (fun x => u (Y.symm x)-u x) = fun x => v (Y.symm x)-v x := by + funext x + by_cases hx : x ∈ K + · have hix := (equiv_mapsTo_of_fixed_compl Y K hoff).2 hx + rw [he (hKW hx), he (hKW hix)] + · rw [equiv_symm_eq_off Y hoff x hx] + simp + have hs : tsupport (fun x => u (Y.symm x)-u x) ⊆ K := + tsupport_comp_equiv_sub Y.symm hK.isClosed (equiv_symm_eq_off Y hoff) u + refine ⟨?_, hK.of_isClosed_subset isClosed_closure hs, hs⟩ + rw [heq] + exact (hv.comp hi).sub hv + +theorem local_compact_updated_flux + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] (Y : E ≃ E) + (hY : ContDiff ℝ (↑(⊤ : ℕ∞)) Y) (hi : ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm) + {K U : Set E} (hU : IsOpen U) (hUb : Bornology.IsBounded U) + (hK : IsCompact K) (hKU : K ⊆ U) (hoff : ∀ x ∉ K, Y x = x) + (F δ : E → E) (hF : ContDiffOn ℝ (↑(⊤ : ℕ∞)) F U) + (hdiv : ∀ ψ : E → ℝ, ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x (F x) ∂μ) = 0) + (hδ : ContDiff ℝ (↑(⊤ : ℕ∞)) δ) (hsδ : tsupport δ ⊆ K) + (hδdiv : ∀ ψ : E → ℝ, ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x (δ x) ∂μ) = 0) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => piolaFlux Y (fun z => F z+δ z) x-F x) ∧ + HasCompactSupport (fun x => piolaFlux Y (fun z => F z+δ z) x-F x) ∧ + tsupport (fun x => piolaFlux Y (fun z => F z+δ z) x-F x) ⊆ K ∧ + ∀ ψ : E → ℝ, ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x (piolaFlux Y (fun z => F z+δ z) x-F x) ∂μ) = 0 := by + obtain ⟨hs, hc, hsk, hpair⟩ := local_compact_piola_Cauchy_difference μ Y hY hi + hU hUb hK hKU hoff F hF hdiv + have hp := piolaFlux_contDiff Y hY hi δ hδ + have hps := piolaFlux_tsupport_subset Y hK.isClosed hoff δ hsδ + have hpc : HasCompactSupport (piolaFlux Y δ) := hK.of_isClosed_subset isClosed_closure hps + have heq : (fun x => piolaFlux Y (fun z => F z+δ z) x-F x) = + fun x => (piolaFlux Y F x-F x)+piolaFlux Y δ x := by + rw [piolaFlux_add] + funext x; simp only [sub_eq_add_neg]; ac_rfl + have htotal : tsupport (fun x => piolaFlux Y (fun z => F z+δ z) x-F x) ⊆ K := by + rw [heq] + exact (tsupport_add (fun x => piolaFlux Y F x-F x) (piolaFlux Y δ)).trans (union_subset hsk hps) + refine ⟨?_, hK.of_isClosed_subset isClosed_closure htotal, htotal, ?_⟩ + · rw [heq] + exact hs.add hp + · intro ψ hψ + simp_rw [congrFun heq, map_add] + rw [integral_add (smooth_flux_integrable_pairing μ _ hs.continuous hc ψ hψ) + (smooth_flux_integrable_pairing μ _ hp.continuous hpc ψ hψ), hpair ψ hψ, + piolaFlux_zero_pairing μ Y hY hi δ hδdiv ψ hψ, zero_add] + +end ScalarConductivity + +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma operatorMatrix_contDiff {m n : Type*} [Fintype m] [Fintype n] [DecidableEq n] + {k : WithTop ℕ∞} : + ContDiff ℝ k (operatorMatrix : ((n → ℝ) →L[ℝ] (m → ℝ)) → Matrix m n ℝ) := by + apply contDiff_pi.mpr; intro i + apply contDiff_pi.mpr; intro j + exact contDiff_pi.mp (contDiff_id.clm_apply contDiff_const) i + +lemma contDiff_gradientColumns {m : Type*} [Fintype m] [DecidableEq m] + (u : Coord3 → m → ℝ) (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => gradientColumns (fderiv ℝ u x)) := by + rw [contDiff_iff_contDiffAt]; intro x + exact contDiffAt_matrix_transpose ((operatorMatrix_contDiff (m := m) (n := Fin 3)).contDiffAt.comp x + (hu.contDiffAt.fderiv_right (by simp))) + +noncomputable def conductivityFlux (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (x : Coord3) : Matrix (Fin 3) (Fin 2) ℝ := + (A x).val * gradientColumns (fderiv ℝ u x) + +lemma conductivityFlux_contDiffOn (u : Coord3 → Fin 2 → ℝ) + (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) (A : Coord3 → Symmetric3) + {U : Set Coord3} (hU : IsOpen U) + (hA : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (A x).val) U) : + ContDiffOn ℝ (↑(⊤ : ℕ∞)) (conductivityFlux u A) U := by + intro x hx + exact (contDiffAt_matrix_mul ((hA x hx).contDiffAt (hU.mem_nhds hx)) + (contDiff_gradientColumns u hu).contDiffAt).contDiffWithinAt + +structure CompactTwoFieldReplacement (μ : Measure Coord3) (O : Set Coord3) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) where + du : Coord3 → Fin 2 → ℝ + dF : Coord3 → Matrix (Fin 3) (Fin 2) ℝ + tensor : Coord3 → Symmetric3 + smooth_du : ContDiff ℝ (↑(⊤ : ℕ∞)) du + compact_du : HasCompactSupport du + support_du : tsupport du ⊆ O + smooth_dF : ContDiff ℝ (↑(⊤ : ℕ∞)) dF + compact_dF : HasCompactSupport dF + support_dF : tsupport dF ⊆ O + cauchy_dF : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x ((dF x).col j) ∂μ) = 0 + smooth_tensor : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (tensor x).val) O + rank : ∀ x ∈ O, LinearIndependent ℝ + (gradientColumns (fderiv ℝ (fun y => u y+du y) x)).col + constitutive : ∀ x ∈ O, (tensor x).val * + gradientColumns (fderiv ℝ (fun y => u y+du y) x) = conductivityFlux u A x + dF x + +lemma tsupport_matrix_subset {X m n : Type*} [TopologicalSpace X] + [Fintype m] [Fintype n] (F : X → Matrix m n ℝ) {K : Set X} (hK : IsClosed K) + (hF : ∀ j, tsupport (fun x => (F x).col j) ⊆ K) : tsupport F ⊆ K := by + apply closure_minimal _ hK + intro x hx + by_contra hn + apply hx + ext i j + exact congrFun (image_eq_zero_of_notMem_tsupport (fun hk => hn (hF j hk))) i + +theorem synchronized_compact_replacement + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + (u : Coord3 → Fin 2 → ℝ) (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) + (A : Coord3 → Symmetric3) {U O K : Set Coord3} + (hU : IsOpen U) (hUb : Bornology.IsBounded U) (hOU : O ⊆ U) + (hK : IsCompact K) (hKO : K ⊆ O) + (hA : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (A x).val) U) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (Y : Coord3 ≃ Coord3) (hY : ContDiff ℝ (↑(⊤ : ℕ∞)) Y) + (hYi : ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm) (hoff : ∀ x ∉ K, Y x = x) + (z : Coord3 → ℝ) (hz : ContDiff ℝ (↑(⊤ : ℕ∞)) z) + (C : ℝ → Symmetric3) + (hC : ∀ x ∈ O, ContDiffAt ℝ (↑(⊤ : ℕ∞)) (fun t => (C t).val) (z x)) + (δ : Fin 2 → Coord3 → Coord3) + (hδ : ∀ j, ContDiff ℝ (↑(⊤ : ℕ∞)) (δ j)) + (hsδ : ∀ j, tsupport (δ j) ⊆ K) + (hδdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x (δ j x) ∂μ) = 0) + (hstate : ∀ x ∈ O, + let E := gradientColumns (fderiv ℝ u x) + let Ft := conductivityFlux u A x + Matrix.of (fun i j => δ j x i) + let J := operatorMatrix (fderiv ℝ Y x) + let At := repairPushed (C (z x)) J E Ft + 0 < J.det ∧ LinearIndependent ℝ E.col ∧ + At.val * gradientColumns (fderiv ℝ (u ∘ Y.symm) (Y x)) = pushFlux J Ft) : + ∃ R : CompactTwoFieldReplacement μ O u A, ∀ x ∈ O, + R.tensor (Y x) = repairPushed (C (z x)) (operatorMatrix (fderiv ℝ Y x)) + (gradientColumns (fderiv ℝ u x)) + (conductivityFlux u A x + Matrix.of (fun i j => δ j x i)) := by + classical + let Ft : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := + fun x => conductivityFlux u A x + Matrix.of (fun i j => δ j x i) + let G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := + fun x => Matrix.of (fun i j => piolaFlux Y (fun t => (Ft t).col j) x i) + let dF : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := fun x => G x - conductivityFlux u A x + let B : Coord3 → Symmetric3 := fun x => repairPushed (C (z x)) + (operatorMatrix (fderiv ℝ Y x)) (gradientColumns (fderiv ℝ u x)) (Ft x) + let du : Coord3 → Fin 2 → ℝ := fun x => u (Y.symm x)-u x + have heq : (fun x => u x+du x) = u ∘ Y.symm := by + funext x; simp only [du, Function.comp_apply]; abel + have him : MapsTo Y.symm O O := (equiv_mapsTo_of_fixed_compl Y O + (fun x hx => hoff x (fun hk => hx (hKO hk)))).2 + have hF := conductivityFlux_contDiffOn u hu A hU hA + have hcol (j : Fin 2) : ContDiffOn ℝ (↑(⊤ : ℕ∞)) + (fun x => (conductivityFlux u A x).col j) U := by + apply contDiffOn_pi.mpr; intro i + exact contDiffOn_pi.mp (contDiffOn_pi.mp hF i) j + have hdcol (j : Fin 2) := local_compact_updated_flux μ Y hY hYi hU hUb hK + (hKO.trans hOU) hoff (fun x => (conductivityFlux u A x).col j) (δ j) + (hcol j) (hdiv j) (hδ j) (hsδ j) (hδdiv j) + have hdFe (j : Fin 2) : (fun x => (dF x).col j) = + fun x => piolaFlux Y (fun t => (conductivityFlux u A t).col j + δ j t) x - + (conductivityFlux u A x).col j := by rfl + have hdFs : ContDiff ℝ (↑(⊤ : ℕ∞)) dF := by + apply contDiff_pi.mpr; intro i + apply contDiff_pi.mpr; intro j + exact contDiff_pi.mp (hdFe j ▸ (hdcol j).1) i + have hdsupp : tsupport dF ⊆ K := tsupport_matrix_subset dF hK.isClosed + (fun j => hdFe j ▸ (hdcol j).2.2.1) + have hdu := local_compact_recomposition_difference Y hYi hU hUb hK + (hKO.trans hOU) hoff u hu.contDiffOn + have hBs : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (B x).val) O := by + intro x hx + have hd := (hstate x hx).1.ne' + have hi := (hstate x hx).2.1 + have hFt : ContDiffAt ℝ (↑(⊤ : ℕ∞)) Ft x := by + apply ((hF x (hOU hx)).contDiffAt (hU.mem_nhds (hOU hx))).add + apply contDiffAt_pi.mpr; intro i + apply contDiffAt_pi.mpr; intro j + exact contDiffAt_pi.mp (hδ j).contDiffAt i + exact (contDiffAt_repairPushed (fun x => C (z x)) _ _ _ + ((hC x hx).comp x hz.contDiffAt) + ((operatorMatrix_contDiff (m := Fin 3) (n := Fin 3)).contDiffAt.comp x (hY.contDiffAt.fderiv_right (by simp))) + (contDiff_gradientColumns u hu).contDiffAt hFt hd hi).contDiffWithinAt + refine ⟨{ + du := du, dF := dF, tensor := B ∘ Y.symm + smooth_du := hdu.1, compact_du := hdu.2.1, support_du := hdu.2.2.trans hKO + smooth_dF := hdFs, compact_dF := hK.of_isClosed_subset isClosed_closure hdsupp + support_dF := hdsupp.trans hKO + cauchy_dF := ?_ + smooth_tensor := hBs.comp hYi.contDiffOn him + rank := ?_ + constitutive := ?_ }, ?_⟩ + · intro j ψ hψ + simpa only [congrFun (hdFe j)] using (hdcol j).2.2.2 ψ hψ + · intro x hx + rw [heq, ← Y.apply_symm_apply x, gradientColumns_recomposition Y + (hY.differentiable (by simp)) (hYi.differentiable (by simp)) u (hu.differentiable (by simp))] + exact pushGradient_rank _ (hstate (Y.symm x) (him hx)).1.ne' _ + (hstate (Y.symm x) (him hx)).2.1 + · intro x hx + rw [heq] + have hh := (hstate (Y.symm x) (him hx)).2.2 + rw [Y.apply_symm_apply] at hh + change (B (Y.symm x)).val * gradientColumns (fderiv ℝ (u ∘ Y.symm) x) = + conductivityFlux u A x + dF x + rw [hh] + have he : conductivityFlux u A x+dF x=G x := by simp only [dF]; abel + rw [he] + ext i j + have hd : 0 < (fderiv ℝ Y (Y.symm x)).det := by + rw [← operatorMatrix_det]; exact (hstate (Y.symm x) (him hx)).1 + have hp := piolaFlux_columns Y Ft hd j + rw [Y.apply_symm_apply] at hp + exact congrFun hp.symm i + · intro x _ + simp only [Function.comp_apply, Y.symm_apply_apply, B, Ft] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PiolaFluxContDiff.lean b/lean/OAI/Analysis/Conductivity/Flux/PiolaFluxContDiff.lean new file mode 100644 index 0000000000000000000000000000000000000000..610ff04079921153b4d4f61eaca84b48da75c134 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PiolaFluxContDiff.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.DerivativeEquiv +import OAI.Analysis.Conductivity.Variational.ContDiffClmDet + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma piolaFlux_contDiff {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] (Y : E ≃ E) + (hY : ContDiff ℝ (↑(⊤ : ℕ∞)) Y) (hi : ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm) + (F : E → E) (hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (piolaFlux Y F) := by + rw [contDiff_iff_contDiffAt]; intro x + have hd := (hY.contDiffAt.fderiv_right (by simp)).comp x hi.contDiffAt + have hn := fderiv_equiv_det_ne_zero Y (hY.differentiable (by simp)) + (hi.differentiable (by simp)) (Y.symm x) + have hdet := ((contDiff_clm_det (E := E) (↑(⊤ : ℕ∞))).contDiffAt.comp x hd).abs hn + exact (hdet.inv (abs_ne_zero.mpr hn)).smul (hd.clm_apply (hF.contDiffAt.comp x hi.contDiffAt)) + +lemma equiv_symm_eq_off {E : Type*} (Y : E ≃ E) {K : Set E} + (hY : ∀ x ∉ K, Y x = x) : ∀ x ∉ K, Y.symm x = x := by + intro x hx + exact Y.symm_apply_eq.mpr (hY x hx).symm + +lemma fderiv_equiv_eq_id_off {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (Y : E ≃ E) {K : Set E} (hK : IsClosed K) (hY : ∀ x ∉ K, Y x = x) + {x : E} (hx : x ∉ K) : fderiv ℝ Y x = ContinuousLinearMap.id ℝ E := by + have he : Y =ᶠ[𝓝 x] id := by + filter_upwards [hK.isOpen_compl.mem_nhds hx] with y hy + exact hY y hy + rw [he.fderiv_eq] + exact fderiv_id + +lemma tsupport_comp_equiv_sub {E V : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [AddGroup V] [TopologicalSpace V] (Y : E ≃ E) {K : Set E} (hK : IsClosed K) + (hY : ∀ x ∉ K, Y x = x) (f : E → V) : tsupport (fun x => f (Y x)-f x) ⊆ K := by + apply closure_minimal _ hK + intro x hx + by_contra hn + exact hx (by change f (Y x)-f x=0; rw [hY x hn, sub_self]) + +lemma piolaFlux_eq_off {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] (Y : E ≃ E) {K : Set E} (hK : IsClosed K) + (hY : ∀ x ∉ K, Y x = x) (F : E → E) {x : E} (hx : x ∉ K) : + piolaFlux Y F x = F x := by + rw [piolaFlux, equiv_symm_eq_off Y hY x hx, fderiv_equiv_eq_id_off Y hK hY hx] + change |(LinearMap.id : E →ₗ[ℝ] E).det|⁻¹ • F x = F x + simp + +lemma smooth_flux_integrable_pairing {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [IsFiniteMeasureOnCompacts μ] (F : E → E) + (hF : Continuous F) (hc : HasCompactSupport F) (ψ : E → ℝ) + (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) : + Integrable (fun x => fderiv ℝ ψ x (F x)) μ := by + apply (hψ.continuous_fderiv (by simp) |>.clm_apply hF).integrable_of_hasCompactSupport + apply hc.mono + intro x hx + contrapose! hx + simp only [Function.mem_support, not_not] at hx ⊢ + rw [hx, map_zero] + +theorem compact_piola_Cauchy_difference + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] (Y : E ≃ E) + (hY : ContDiff ℝ (↑(⊤ : ℕ∞)) Y) (hi : ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm) + {K U : Set E} (hK : IsCompact K) (hKU : K ⊆ U) (hoff : ∀ x ∉ K, Y x = x) + (F : E → E) (hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F) (hc : HasCompactSupport F) + (hdiv : ∀ ψ : E → ℝ, ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x (F x) ∂μ) = 0) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => piolaFlux Y F x - F x) ∧ + HasCompactSupport (fun x => piolaFlux Y F x - F x) ∧ + tsupport (fun x => piolaFlux Y F x - F x) ⊆ K ∧ + ∀ ψ : E → ℝ, ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ x, fderiv ℝ ψ x (piolaFlux Y F x - F x) ∂μ) = 0 := by + have hG := piolaFlux_contDiff Y hY hi F hF + have hGc := piolaFlux_hasCompactSupport Y (hY.differentiable (by simp)) + (hi.differentiable (by simp)) F hc + have hs : tsupport (fun x => piolaFlux Y F x - F x) ⊆ K := by + apply closure_minimal _ hK.isClosed + intro x hx + by_contra hn + exact hx (by change piolaFlux Y F x - F x = 0 + rw [piolaFlux_eq_off Y hK.isClosed hoff F hn, sub_self]) + refine ⟨hG.sub hF, hK.of_isClosed_subset isClosed_closure hs, hs, ?_⟩ + intro ψ hψ + have hψY := hψ.comp hY + have htest := tsupport_comp_equiv_sub Y hK.isClosed hoff ψ + have hz := hdiv (fun x => ψ (Y x)-ψ x) (hψY.sub hψ) + (hK.of_isClosed_subset isClosed_closure htest) (htest.trans hKU) + have h1 := smooth_flux_integrable_pairing μ F hF.continuous hc ψ hψ + have h2 := smooth_flux_integrable_pairing μ F hF.continuous hc (ψ ∘ Y) hψY + have h3 := smooth_flux_integrable_pairing μ (piolaFlux Y F) hG.continuous hGc ψ hψ + simp only [map_sub] + rw [integral_sub h3 h1, piolaFlux_pairing μ Y (hY.differentiable (by simp)) + (fderiv_equiv_det_ne_zero Y (hY.differentiable (by simp)) (hi.differentiable (by simp))) + F ψ (hψ.differentiable (by simp))] + simp_rw [show (fun x => ψ (Y x) - ψ x) = (ψ ∘ Y) - ψ from rfl] at hz + simp_rw [fderiv_sub (hψY.differentiable (by simp) _) (hψ.differentiable (by simp) _), + _root_.sub_apply] at hz + rw [integral_sub h2 h1] at hz + exact hz + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/PotentialCurl.lean b/lean/OAI/Analysis/Conductivity/Flux/PotentialCurl.lean new file mode 100644 index 0000000000000000000000000000000000000000..d01f3b36ebedeae70a1da1e31fe21d9b90d707ab --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/PotentialCurl.lean @@ -0,0 +1,138 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CrossingBlock +import OAI.Analysis.Conductivity.Variational.DirectionCalculus + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def potentialCurl (S : Fin 3 → Fin 3 → Coord3 → ℝ) (x : Coord3) (i : Fin 3) : ℝ := + ∑ j, direction (Pi.single j 1) (S i j) x + +lemma potentialCurl_add {S T : Fin 3 → Fin 3 → Coord3 → ℝ} + (hS : ∀ i j, Differentiable ℝ (S i j)) (hT : ∀ i j, Differentiable ℝ (T i j)) (x : Coord3) (i : Fin 3) : + potentialCurl (fun i j x => S i j x+T i j x) x i = potentialCurl S x i+potentialCurl T x i := by + simp only [potentialCurl,direction_add (hS _ _ _) (hT _ _ _),Finset.sum_add_distrib] + +lemma potentialCurl_dilation {S : Fin 3 → Fin 3 → Coord3 → ℝ} + (hS : ∀ i j, Differentiable ℝ (S i j)) (s r : ℝ) (c x : Coord3) (i : Fin 3) : + potentialCurl (fun i j y => s*S i j (r • (y-c))) x i = + s*r*potentialCurl S (r • (x-c)) i := by + simp only [potentialCurl,direction_dilation (hS _ _),Finset.mul_sum] + +lemma wedgePotential_diff {H : Coord3 → ℝ} (hH : Differentiable ℝ H) (a b i j : Fin 3) : + Differentiable ℝ (wedgePotential a b H i j) := by + unfold wedgePotential + split <;> split <;> fun_prop + +lemma potentialCurl_wedge {H : Coord3 → ℝ} (hH : Differentiable ℝ H) (a b : Fin 3) (x : Coord3) (i : Fin 3) : + potentialCurl (wedgePotential a b H) x i = + (if i=a then direction (Pi.single b 1) H x else 0) - + (if i=b then direction (Pi.single a 1) H x else 0) := + wedgePotential_flux a b i hH x + +lemma potentialCurl_congr_nhds {S T : Fin 3 → Fin 3 → Coord3 → ℝ} (x : Coord3) + (h : ∀ i j, S i j =ᶠ[𝓝 x] T i j) (i : Fin 3) : potentialCurl S x i = potentialCurl T x i := by + apply Finset.sum_congr rfl + intro j _ + exact direction_congr_nhds (h i j) _ + +def crossingPotential (L : ℝ) (a b i j : Fin 3) (x : Coord3) : ℝ := + wedgePotential 0 a (fun y => deriv (crossingFirst L) (y 0)*sin (y a)) i j x + + wedgePotential 0 b (fun y => (deriv (crossingSecond L) (y 0)/2)*sin (2*y b)) i j x + + wedgePotential a b (angularStream (crossingResidualFirst L) (crossingResidualSecond L) a b) i j x + +lemma crossingPotential_diff (L : ℝ) (a b i j : Fin 3) : Differentiable ℝ (crossingPotential L a b i j) := by + have hf := (smooth_deriv_infty (crossingFirst_smooth L)).differentiable (by simp) + have hg := (smooth_deriv_infty (crossingSecond_smooth L)).differentiable (by simp) + have hF := (crossingResidualFirst_smooth L).differentiable (by simp) + have hG := (crossingResidualSecond_smooth L).differentiable (by simp) + apply Differentiable.add + · apply Differentiable.add + · exact wedgePotential_diff (by fun_prop) _ _ _ _ + · exact wedgePotential_diff (by fun_prop) _ _ _ _ + · exact wedgePotential_diff (angularStream_diff hF hG _ _) _ _ _ _ + +lemma crossingPotential_curl (L : ℝ) {a b : Fin 3} (ha : a≠0) (hb : b≠0) (hab : a≠b) + (x : Coord3) (i : Fin 3) : + potentialCurl (crossingPotential L a b) x i = + (if i=0 then crossingCurrentZ L (x 0) (x a) (x b) else 0) + + (if i=a then crossingCurrentX L (x 0) (x a) (x b) else 0) + + (if i=b then crossingCurrentY L (x 0) (x a) (x b) else 0) := by + have hf := (smooth_deriv_infty (crossingFirst_smooth L)).differentiable (by simp) + have hg := (smooth_deriv_infty (crossingSecond_smooth L)).differentiable (by simp) + have hF := (crossingResidualFirst_smooth L).differentiable (by simp) + have hG := (crossingResidualSecond_smooth L).differentiable (by simp) + let H : Coord3 → ℝ := fun y => deriv (crossingFirst L) (y 0)*sin (y a) + let J : Coord3 → ℝ := fun y => (deriv (crossingSecond L) (y 0)/2)*sin (2*y b) + have hH : Differentiable ℝ H := by dsimp only [H]; fun_prop + have hJ : Differentiable ℝ J := by dsimp only [J]; fun_prop + have hW := angularStream_diff hF hG a b + have hdHa : direction (Pi.single a 1) H x = deriv (crossingFirst L) (x 0)*cos (x a) := by + simpa [H,Ne.symm ha] using direction_scalar_sin hf 1 a a x + have hdH0 : direction (Pi.single 0 1) H x = deriv (deriv (crossingFirst L)) (x 0)*sin (x a) := by + simpa [H,ha,mul_comm] using direction_scalar_sin hf 1 0 a x + have hg' : Differentiable ℝ (fun t => deriv (crossingSecond L) t/2) := by fun_prop + have hgder (t : ℝ) : deriv (fun t => deriv (crossingSecond L) t/2) t = + deriv (deriv (crossingSecond L)) t/2 := (hg t).hasDerivAt.div_const 2 |>.deriv + have hdJb : direction (Pi.single b 1) J x = deriv (crossingSecond L) (x 0)*cos (2*x b) := by + have hh := direction_scalar_sin hg' 2 b b x + simp only [Ne.symm hb,ite_false,ite_true,mul_zero,add_zero] at hh + dsimp only [J] + rw [hh] + ring + have hdJ0 : direction (Pi.single 0 1) J x = deriv (deriv (crossingSecond L)) (x 0)/2*sin (2*x b) := by + simpa only [J,hb,ite_false,ite_true,mul_zero,zero_mul,zero_add,mul_one,one_mul,hgder,mul_comm] using + direction_scalar_sin hg' 2 0 b x + have hx : -direction (Pi.single 0 1) H x + + direction (Pi.single b 1) (angularStream (crossingResidualFirst L) (crossingResidualSecond L) a b) x = + crossingCurrentX L (x 0) (x a) (x b) := by + rw [hdH0,angularStream_b hF hG hb hab] + unfold crossingCurrentX crossingResidualFirst + have hc := Real.cos_two_mul (2*x b) + have ht : 2*(2*x b)=4*x b := by ring + rw [ht] at hc + have hs := Real.sin_sq_add_cos_sq (2*x b) + linear_combination + (deriv (deriv (crossingFirst L)) (x 0)-9*crossingFirst L (x 0))*sin (x a)*hc + + 2*(deriv (deriv (crossingFirst L)) (x 0)-9*crossingFirst L (x 0))*sin (x a)*hs + have hy : -direction (Pi.single 0 1) J x - + direction (Pi.single a 1) (angularStream (crossingResidualFirst L) (crossingResidualSecond L) a b) x = + crossingCurrentY L (x 0) (x a) (x b) := by + rw [hdJ0,angularStream_a hF hG ha hab] + unfold crossingCurrentY crossingResidualSecond + have hs := Real.sin_two_mul (2*x b) + have ht : 2*(2*x b)=4*x b := by ring + rw [ht] at hs + rw [hs] + have hc := Real.sin_sq_add_cos_sq (x a) + linear_combination (deriv (deriv (crossingSecond L)) (x 0)-crossingSecond L (x 0))/2*sin (2*x b)*hc + change potentialCurl (fun i j x => wedgePotential 0 a H i j x + wedgePotential 0 b J i j x + + wedgePotential a b (angularStream (crossingResidualFirst L) (crossingResidualSecond L) a b) i j x) x i = _ + have hHJ : ∀ i j, Differentiable ℝ (fun x => wedgePotential 0 a H i j x + wedgePotential 0 b J i j x) := + fun i j => (wedgePotential_diff hH 0 a i j).add (wedgePotential_diff hJ 0 b i j) + rw [potentialCurl_add hHJ (fun i j => wedgePotential_diff hW a b i j), + potentialCurl_add (fun i j => wedgePotential_diff hH 0 a i j) (fun i j => wedgePotential_diff hJ 0 b i j)] + simp_rw [potentialCurl_wedge hH,potentialCurl_wedge hJ,potentialCurl_wedge hW] + by_cases hi0 : i=0 + · subst i + simp only [Ne.symm ha,Ne.symm hb,ite_false,ite_true,sub_zero,hdHa,hdJb,add_zero] + rfl + · by_cases hia : i=a + · subst i + simp only [ha,hab,ite_false,ite_true,zero_add,zero_sub,sub_zero,add_zero] + exact hx + · by_cases hib : i=b + · subst i + simp only [hb,Ne.symm hab,ite_false,ite_true,zero_add,zero_sub,sub_zero,add_zero] + linarith [hy] + · simp [hi0,hia,hib] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/SmoothFluxIntegrable.lean b/lean/OAI/Analysis/Conductivity/Flux/SmoothFluxIntegrable.lean new file mode 100644 index 0000000000000000000000000000000000000000..05e5946781d361e2bfa00f3a324b7b0210b7c31b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/SmoothFluxIntegrable.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactGlobalUpdate + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma smooth_matrix_column {F : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} + (hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F) (j : Fin 2) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => (F x).col j) := by + exact contDiff_pi.mpr (fun i => (contDiff_pi.mp (contDiff_pi.mp hF i) j)) + +lemma compact_matrix_column {F : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} + (hF : HasCompactSupport F) (j : Fin 2) : HasCompactSupport (fun x => (F x).col j) := by + apply hF.mono + intro x hx hzero + apply hx + change (F x).col j = 0 + rw [hzero] + rfl + +def SmoothFluxIntegrable (μ : Measure Coord3) (U : Set Coord3) + (F : Coord3 → Matrix (Fin 3) (Fin 2) ℝ) : Prop := + ∀ (j : Fin 2) (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + HasCompactSupport ψ → tsupport ψ ⊆ U → + Integrable (fun x => fderiv ℝ ψ x ((F x).col j)) μ + +lemma CompactGlobalUpdate.preserves_harmonic + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) : + SmoothFluxIntegrable μ U (conductivityFlux (fun x => u x+R.du x) R.tensor) ∧ + ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux (fun x => u x+R.du x) R.tensor x).col j) ∂μ) = 0 := by + have he : ∀ j (ψ : Coord3 → ℝ), + (fun x => fderiv ℝ ψ x ((conductivityFlux (fun x => u x+R.du x) R.tensor x).col j)) = + (fun x => fderiv ℝ ψ x ((conductivityFlux u A x).col j) + fderiv ℝ ψ x ((R.dF x).col j)) := by + intro j ψ + funext x + rw [R.constitutive x] + change fderiv ℝ ψ x (((conductivityFlux u A x).col j) + (R.dF x).col j) = _ + exact map_add _ _ _ + constructor + · intro j ψ hψ hc hs + rw [he] + exact (hint j ψ hψ hc hs).add (smooth_flux_integrable_pairing μ + (fun x => (R.dF x).col j) (smooth_matrix_column R.smooth_dF j).continuous (compact_matrix_column R.compact_dF j) ψ hψ) + · intro j ψ hψ hc hs + rw [he,integral_add (hint j ψ hψ hc hs) (smooth_flux_integrable_pairing μ + (fun x => (R.dF x).col j) (smooth_matrix_column R.smooth_dF j).continuous (compact_matrix_column R.compact_dF j) ψ hψ), + hdiv j ψ hψ hc hs,R.cauchy_dF j ψ hψ,add_zero] + +def CompactGlobalUpdate.trans + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + (S : CompactGlobalUpdate μ U (fun x => u x+R.du x) R.tensor) : + CompactGlobalUpdate μ U u A where + du := R.du+S.du + dF := R.dF+S.dF + tensor := S.tensor + smooth_du := R.smooth_du.add S.smooth_du + compact_du := R.compact_du.add S.compact_du + support_du := (tsupport_add _ _).trans (union_subset R.support_du S.support_du) + smooth_dF := R.smooth_dF.add S.smooth_dF + compact_dF := R.compact_dF.add S.compact_dF + support_dF := (tsupport_add _ _).trans (union_subset R.support_dF S.support_dF) + cauchy_dF := by + intro j ψ hψ + change (∫ x, fderiv ℝ ψ x ((R.dF x).col j+(S.dF x).col j) ∂μ) = 0 + simp_rw [map_add] + rw [integral_add (smooth_flux_integrable_pairing μ + (fun x => (R.dF x).col j) (smooth_matrix_column R.smooth_dF j).continuous (compact_matrix_column R.compact_dF j) ψ hψ) + (smooth_flux_integrable_pairing μ + (fun x => (S.dF x).col j) (smooth_matrix_column S.smooth_dF j).continuous (compact_matrix_column S.compact_dF j) ψ hψ), + R.cauchy_dF j ψ hψ,S.cauchy_dF j ψ hψ,add_zero] + measurable_tensor := S.measurable_tensor + constitutive := by + intro x + have he : (fun y => u y+(R.du+S.du) y) = (fun y => (u y+R.du y)+S.du y) := by + funext y; exact (add_assoc _ _ _).symm + rw [he,S.constitutive x,R.constitutive x] + exact add_assoc _ _ _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TorusBoxFlux.lean b/lean/OAI/Analysis/Conductivity/Flux/TorusBoxFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..30c66e0e2f153436bf0ffd75b556be20b4891386 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TorusBoxFlux.lean @@ -0,0 +1,257 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly +import OAI.Analysis.Conductivity.Fourier.AngularPeriodization + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory + +def torusCellIntegral (T : ℝ) (f : Coord3 → ℝ) (t : ℝ) : ℝ := + ∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,f ![t,y,z] + +lemma integral_coord2_Icc {a b : Fin 2 → ℝ} (hab : a≤b) {f : (Fin 2 → ℝ) → ℝ} + (hf : Continuous f) : + (∫ x in Icc a b,f x)=∫ y in a 0..b 0,∫ z in a 1..b 1,f ![y,z] := by + have hc : Continuous (fun q : ℝ×ℝ => f ![q.1,q.2]) := hf.comp (by fun_prop) + have hi := hc.continuousOn.integrableOn_compact (μ:=volume) + (isCompact_Icc.prod isCompact_Icc : IsCompact (Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1))) + have he := (volume_preserving_finTwoArrow ℝ).setIntegral_image_emb + MeasurableEquiv.finTwoArrow.measurableEmbedding (fun q : ℝ×ℝ => f ![q.1,q.2]) (Icc a b) + have hid (x : Fin 2 → ℝ) : ![x 0,x 1]=x := by ext i; fin_cases i <;> rfl + simp only [MeasurableEquiv.finTwoArrow_apply] at he + simp_rw [hid] at he + have him : MeasurableEquiv.finTwoArrow '' Icc a b=Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1) := by + ext q + rw [MeasurableEquiv.image_eq_preimage_symm] + simp only [mem_preimage,mem_Icc,Pi.le_def,mem_prod] + constructor + · intro h + exact ⟨⟨h.1 0,h.2 0⟩,⟨h.1 1,h.2 1⟩⟩ + · intro h + constructor <;> intro i <;> fin_cases i + · exact h.1.1 + · exact h.2.1 + · exact h.1.2 + · exact h.2.2 + change (∫ y in (MeasurableEquiv.finTwoArrow '' Icc a b),f ![y.1,y.2])=_ at he + rw [←he,him] + change (∫ x in Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1),f ![x.1,x.2] ∂volume.prod volume)=_ + rw [setIntegral_prod _ hi] + simp_rw [intervalIntegral.integral_of_le (hab 0),intervalIntegral.integral_of_le (hab 1), + ←integral_Icc_eq_integral_Ioc] + +lemma integral_coord3_Icc {a b : Coord3} (hab : a≤b) {f : Coord3 → ℝ} (hf : Continuous f) : + (∫ x in Icc a b,f x)=∫ t in a 0..b 0,∫ y in a 1..b 1,∫ z in a 2..b 2,f ![t,y,z] := by + have hc : Continuous (fun q : ℝ×(ℝ×ℝ) => f ![q.1,q.2.1,q.2.2]) := hf.comp (by fun_prop) + have hi := hc.continuousOn.integrableOn_compact (μ:=volume) + (isCompact_Icc.prod (isCompact_Icc.prod isCompact_Icc) : + IsCompact (Icc (a 0) (b 0) ×ˢ (Icc (a 1) (b 1) ×ˢ Icc (a 2) (b 2)))) + have he := threeArrow_volume.setIntegral_image_emb threeArrow.measurableEmbedding + (fun q : ℝ×(ℝ×ℝ) => f ![q.1,q.2.1,q.2.2]) (Icc a b) + simp only [threeArrow_apply] at he + have hid (x : Coord3) : ![x 0,x 1,x 2]=x := by ext i; fin_cases i <;> rfl + simp_rw [hid] at he + have him : threeArrow '' Icc a b=Icc (a 0) (b 0) ×ˢ (Icc (a 1) (b 1) ×ˢ Icc (a 2) (b 2)) := by + ext q + rw [MeasurableEquiv.image_eq_preimage_symm] + simp only [mem_preimage,mem_Icc,Pi.le_def,mem_prod,threeArrow_symm_apply] + constructor + · intro h + exact ⟨⟨h.1 0,h.2 0⟩,⟨⟨h.1 1,h.2 1⟩,⟨h.1 2,h.2 2⟩⟩⟩ + · intro h + constructor <;> intro i <;> fin_cases i + · exact h.1.1 + · exact h.2.1.1 + · exact h.2.2.1 + · exact h.1.2 + · exact h.2.1.2 + · exact h.2.2.2 + change (∫ y in (threeArrow '' Icc a b),f ![y.1,y.2.1,y.2.2])=_ at he + rw [←he,him] + change (∫ x in Icc (a 0) (b 0) ×ˢ (Icc (a 1) (b 1) ×ˢ Icc (a 2) (b 2)), + f ![x.1,x.2.1,x.2.2] ∂volume.prod volume)=_ + rw [setIntegral_prod _ hi] + simp_rw [intervalIntegral.integral_of_le (hab 0),intervalIntegral.integral_of_le (hab 1), + intervalIntegral.integral_of_le (hab 2),←integral_Icc_eq_integral_Ioc] + apply setIntegral_congr_fun measurableSet_Icc + intro t _ + exact setIntegral_prod _ ((hc.comp (continuous_const.prodMk continuous_id)).continuousOn.integrableOn_compact + (isCompact_Icc.prod isCompact_Icc)) + +lemma coordinateDivergence_eq_trace {F : Coord3 → Coord3} (hF : Differentiable ℝ F) (x : Coord3) : + coordinateDivergence F x=∑ i : Fin 3,fderiv ℝ F x (Pi.single i 1) i := by + apply Finset.sum_congr rfl + intro i _ + rw [(hasFDerivAt_pi'.mp (hF x).hasFDerivAt i).fderiv] + rfl + +theorem torus_band_divergence {T a b : ℝ} (hT : 0≤T) (hab : a≤b) + {F : Coord3 → Coord3} (hF : ContDiff ℝ (↑(⊤:ℕ∞)) F) (hp : AngularPeriodic T F) : + (∫ t in a..b,torusCellIntegral T (coordinateDivergence F) t)= + torusCellIntegral T (fun x => F x 0) b-torusCellIntegral T (fun x => F x 0) a := by + let A : Coord3 := ![a,0,0] + let B : Coord3 := ![b,T,T] + have hAB : A≤B := by intro i; fin_cases i; exact hab; exact hT; exact hT + have hc := (coordinateDivergence_smooth hF).continuous + have hfd := hF.differentiable (by simp) + have hh := integral_divergence_of_hasFDerivAt_off_countable A B hAB F (fderiv ℝ F) + ∅ countable_empty hF.continuous.continuousOn (fun x _ => (hfd x).hasFDerivAt) + (by simpa only [←coordinateDivergence_eq_trace hfd] using (hc.continuousOn.integrableOn_compact + (μ:=volume) (isCompact_Icc : IsCompact (Icc A B)))) + simp_rw [←coordinateDivergence_eq_trace hfd] at hh + rw [integral_coord3_Icc hAB hc] at hh + have h1 (q : Fin 2 → ℝ) : F ((1:Fin 3).insertNth T q) 1=F ((1:Fin 3).insertNth 0 q) 1 := by + have he : ((1:Fin 3).insertNth 0 q)+angularShift T ![1,0]=(1:Fin 3).insertNth T q := by + ext i; fin_cases i <;> simp [angularShift,Fin.insertNth,Fin.succAboveCases] + have hh := hp ![1,0] ((1:Fin 3).insertNth 0 q) + rw [he] at hh + exact congrFun hh 1 + have h2 (q : Fin 2 → ℝ) : F ((2:Fin 3).insertNth T q) 2=F ((2:Fin 3).insertNth 0 q) 2 := by + have he : ((2:Fin 3).insertNth 0 q)+angularShift T ![0,1]=(2:Fin 3).insertNth T q := by + ext i; fin_cases i <;> simp [angularShift,Fin.insertNth,Fin.succAboveCases] + have hh := hp ![0,1] ((2:Fin 3).insertNth 0 q) + rw [he] at hh + exact congrFun hh 2 + rw [Fin.sum_univ_succ] at hh + simp only [Fin.sum_univ_two,Fin.succ_zero_eq_one,Fin.succ_one_eq_two] at hh + simp only [A,B,Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.head_cons,Matrix.tail_cons] at hh + simp_rw [h1,h2] at hh + simp only [sub_self,add_zero] at hh + have hf0 (c : ℝ) : + (∫ q in Icc (A ∘ (0:Fin 3).succAbove) (B ∘ (0:Fin 3).succAbove), + F ((0:Fin 3).insertNth c q) 0)=torusCellIntegral T (fun x => F x 0) c := by + have hc0 : Continuous (fun q : Fin 2 → ℝ => F ((0:Fin 3).insertNth c q) 0) := + (continuous_apply 0).comp (hF.continuous.comp (by fun_prop)) + refine (integral_coord2_Icc (a:=A ∘ (0:Fin 3).succAbove) (b:=B ∘ (0:Fin 3).succAbove) (fun i => hAB ((0:Fin 3).succAbove i)) hc0).trans ?_ + change (∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,F ((0:Fin 3).insertNth c ![y,z]) 0)=_ + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + have hi : (0:Fin 3).insertNth c ![y,z]=![c,y,z] := by + ext i + fin_cases i <;> simp [Fin.insertNth,Fin.succAboveCases] + exact congrArg (fun x : Coord3 => F x 0) hi + exact hh.trans (congrArg₂ (· - ·) (hf0 b) (hf0 a)) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory + +lemma smooth_smul_of_support_in_open {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {f : E→F} {ρ : E→ℝ} {S : Set E} (hS : IsOpen S) + (hf : ContDiffOn ℝ (↑(⊤:ℕ∞)) f S) (hρ : ContDiff ℝ (↑(⊤:ℕ∞)) ρ) + (hs : tsupport ρ⊆S) : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x => ρ x • f x) := by + apply contDiff_iff_contDiffAt.mpr + intro x + by_cases hx : x∈tsupport ρ + · exact hρ.contDiffAt.smul (hf.contDiffAt (hS.mem_nhds (hs hx))) + · have he : (fun y => ρ y • f y)=ᶠ[𝓝 x] (fun _ => 0) := by + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + simp [hy] + exact contDiffAt_const.congr_of_eventuallyEq he + +lemma axial_band_smooth_extension {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {δ a b T : ℝ} (ha : δ χ (x 0) + have hρ : ContDiff ℝ (↑(⊤:ℕ∞)) ρ := hχ.comp (contDiff_apply ℝ ℝ 0) + have hρs : tsupport ρ⊆{x | δ x 0) (continuous_apply 0) hx)).1 + refine ⟨fun x => ρ x • F x,smooth_smul_of_support_in_open + (isOpen_lt continuous_const (continuous_apply 0)) hF hρ hρs,?_,?_⟩ + · intro n x + change χ (x 0+0) • F (x+angularShift T n)=χ (x 0) • F x + rw [add_zero,hp n x] + · intro x hx + have he : (fun y : Coord3 => χ (y 0))=ᶠ[𝓝 x] (fun _ => 1) := + (hχ1 (x 0) hx).comp_tendsto (continuous_apply 0).continuousAt + filter_upwards [he] with y hy + change χ (y 0) • F y=F y + rw [hy,one_smul] + +lemma coordinateDivergence_congr_nhds {F G : Coord3 → Coord3} {x : Coord3} + (h : F=ᶠ[𝓝 x] G) : coordinateDivergence F x=coordinateDivergence G x := by + unfold coordinateDivergence + apply Finset.sum_congr rfl + intro i _ + have he : (fun y => F y i)=ᶠ[𝓝 x] (fun y => G y i) := h.mono (fun y hy => congrFun hy i) + rw [he.fderiv_eq] + +theorem torus_band_divergence_halfspace {δ T a b : ℝ} (ha : δ F x 0) b-torusCellIntegral T (fun x => F x 0) a := by + obtain ⟨G,hG,hGp,hGF⟩ := axial_band_smooth_extension ha hF hp (b:=b) + have he (t : ℝ) (ht : t∈Icc a b) : + torusCellIntegral T (coordinateDivergence G) t=torusCellIntegral T (coordinateDivergence F) t := by + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + exact coordinateDivergence_congr_nhds (hGF ![t,y,z] ht) + have heF (t : ℝ) (ht : t∈Icc a b) : + torusCellIntegral T (fun x => G x 0) t=torusCellIntegral T (fun x => F x 0) t := by + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + exact congrFun (hGF ![t,y,z] ht).self_of_nhds 0 + have hh := torus_band_divergence hT hab hG hGp + have hl : (∫ t in a..b,torusCellIntegral T (coordinateDivergence G) t)= + ∫ t in a..b,torusCellIntegral T (coordinateDivergence F) t := by + apply intervalIntegral.integral_congr + intro t ht + exact he t (by simpa only [uIcc_of_le hab] using ht) + rw [hl,heF b (right_mem_Icc.mpr hab),heF a (left_mem_Icc.mpr hab)] at hh + exact hh + +lemma torus_flux_constant {δ T a b : ℝ} (ha : δ F x 0) b=torusCellIntegral T (fun x => F x 0) a := by + have hh := torus_band_divergence_halfspace ha hT hab hF hp + have hz : (∫ t in a..b,torusCellIntegral T (coordinateDivergence F) t)=0 := by + rw [←intervalIntegral.integral_zero (a:=a) (b:=b) (μ:=volume)] + apply intervalIntegral.integral_congr + intro t ht + have hta : a≤t := (by simpa only [uIcc_of_le hab] using ht : t∈Icc a b).1 + have he (y z : ℝ) : coordinateDivergence F ![t,y,z]=0 := hd _ (ha.trans_le hta) + simp only [torusCellIntegral,he,intervalIntegral.integral_zero] + rw [hz] at hh + linarith + +lemma torus_flux_zero_of_tendsto {δ T a : ℝ} (ha : δ torusCellIntegral T (fun x => F x 0) t) atTop (𝓝 0)) : + torusCellIntegral T (fun x => F x 0) a=0 := by + have he : (fun t => torusCellIntegral T (fun x => F x 0) t)=ᶠ[atTop] + (fun _ => torusCellIntegral T (fun x => F x 0) a) := by + filter_upwards [eventually_ge_atTop a] with b hab + exact torus_flux_constant ha hT hab hF hp hd + exact tendsto_nhds_unique tendsto_const_nhds (ht.congr' he) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TorusCrossFluxDecay.lean b/lean/OAI/Analysis/Conductivity/Flux/TorusCrossFluxDecay.lean new file mode 100644 index 0000000000000000000000000000000000000000..3e225bfad42638a46c05eee9add98205bc88a4e9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TorusCrossFluxDecay.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusFluxDecay + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma tendsto_linear_mul_exp_neg_gap {gap : ℝ} (hg : 0 t*exp (-gap*(t-1))) atTop (𝓝 0) := by + have hy : Tendsto (fun t : ℝ => gap*(t-1)) atTop atTop := + (tendsto_atTop_add_const_right atTop (-1) tendsto_id).const_mul_atTop hg + have he := (Real.tendsto_pow_mul_exp_neg_atTop_nhds_zero 1).comp hy + have hh := (he.div_const gap).add (tendsto_exp_neg_gap hg) + have hfun : (fun t : ℝ => (gap*(t-1))^1*exp (-(gap*(t-1)))/gap+exp (-gap*(t-1)))= + fun t => t*exp (-gap*(t-1)) := by + ext t + rw [pow_one,←neg_mul] + field_simp + ring + dsimp only [Function.comp_def] at hh + rw [hfun] at hh + simpa using hh + +lemma flatCrossFlux_zero_of_bounds {s : Fin 3→ℝ} {f g : Coord3→ℝ} + (hf : ContDiffOn ℝ (↑(⊤:ℕ∞)) f {x | 0 flatCrossFlux s f g x 0) t=0 := by + apply torus_flux_zero_of_tendsto ht (by positivity) + (flatCrossFlux_smoothOn (axial_halfspace_open 0) hf hg) + (flatCrossFlux_periodic hfp hgp) + · intro x hx + rw [flatCrossFlux_divergence (hf.contDiffAt ((axial_halfspace_open 0).mem_nhds hx)) + (hg.contDiffAt ((axial_halfspace_open 0).mem_nhds hx)),hfh x hx,hgh x hx] + ring + · have hlim : Tendsto (fun t : ℝ => (D*C+B*E)*exp (-gap*(t-1))+ + (A*E)*(t*exp (-gap*(t-1)))) atTop (𝓝 0) := by + simpa using ((tendsto_exp_neg_gap hgap).const_mul (D*C+B*E)).add + ((tendsto_linear_mul_exp_neg_gap hgap).const_mul (A*E)) + apply torusCellIntegral_tendsto_zero (by positivity) hlim + filter_upwards [eventually_ge_atTop (1:ℝ)] with t ht' + intro y z + obtain ⟨hfb,hfd,hgb,hgd⟩ := hb ![t,y,z] ht' + have hAB : 0≤A*t+B := add_nonneg (mul_nonneg hA (le_trans zero_le_one ht')) hB + calc + _ ≤ ‖g ![t,y,z]‖*‖fderiv ℝ f ![t,y,z] (flatAxis 0)‖+ + ‖f ![t,y,z]‖*‖fderiv ℝ g ![t,y,z] (flatAxis 0)‖ := by + simpa only [flatCrossFlux,Pi.sub_apply,Pi.smul_apply,smul_eq_mul,flatModeFlux, + Matrix.cons_val_zero,norm_mul] using norm_sub_le + (g ![t,y,z]*fderiv ℝ f ![t,y,z] (flatAxis 0)) + (f ![t,y,z]*fderiv ℝ g ![t,y,z] (flatAxis 0)) + _ ≤ (D*exp (-gap*(t-1)))*C+(A*t+B)*(E*exp (-gap*(t-1))) := + add_le_add (mul_le_mul hgb hfd (norm_nonneg _) (mul_nonneg hD (exp_nonneg _))) + (mul_le_mul hfb hgd (norm_nonneg _) hAB) + _ = _ := by ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenComplex.lean b/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenComplex.lean new file mode 100644 index 0000000000000000000000000000000000000000..9e2cf5aad5e70c710e6360dba94577b249c1e0c2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenComplex.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusCylinderGreenReal +import OAI.Analysis.Conductivity.Fourier.TorusSmoothModeJet + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus +open scoped ENNReal +local instance torusCylinderGreenComplexMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusCylinderGreenComplexIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +theorem torusCylinder_green_complex {R : ℝ} (hR : 0≤R) + {F : Coord3 → Coord3} {φ : Coord3 → ℂ} + (hF : ContDiff ℝ 1 F) (hφ : ContDiff ℝ 1 φ) + (hp : AngularPeriodic (2*Real.pi) F) (hφp : AngularPeriodic (2*Real.pi) φ) + (hd : ∀ x,x 0∈Icc 0 R → coordinateDivergence F x=0) : + (∫ z,torusPeriodicDescent (fun x => fderiv ℝ φ x (F x)) z + ∂(FiniteAxisMeasure R).prod volume)= + (∫ θ,torusPeriodicDescent (fun x => (F x 0) • φ x) (R,θ))- + (∫ θ,torusPeriodicDescent (fun x => (F x 0) • φ x) (0,θ)) := by + have hc := (hφ.continuous_fderiv (by norm_num)).clm_apply hF.continuous + have hdp : AngularPeriodic (2*Real.pi) (fun x => fderiv ℝ φ x (F x)) := by + intro n x + dsimp only + rw [hφp.fderiv n x,hp n x] + have hpc : Continuous (fun x => (F x 0) • φ x) := ((continuous_apply 0).comp hF.continuous).smul hφ.continuous + have hpp : AngularPeriodic (2*Real.pi) (fun x => (F x 0) • φ x) := by + intro n x + dsimp only + rw [hφp n x,hp n x] + have hi := (continuous_memLp_finiteCylinder_general + (continuous_torusPeriodicDescent hc hdp) R).integrable (by norm_num : (1:ℝ≥0∞)≤2) + have hib (t : ℝ) : Integrable (fun θ => torusPeriodicDescent (fun x => (F x 0) • φ x) (t,θ)) := + ((continuous_torusPeriodicDescent hpc hpp).comp (continuous_const.prodMk continuous_id)).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + have hL (L : ℂ →L[ℝ] ℝ) : + L (∫ z,torusPeriodicDescent (fun x => fderiv ℝ φ x (F x)) z + ∂(FiniteAxisMeasure R).prod volume)= + L ((∫ θ,torusPeriodicDescent (fun x => (F x 0) • φ x) (R,θ))- + (∫ θ,torusPeriodicDescent (fun x => (F x 0) • φ x) (0,θ))) := by + rw [map_sub,←L.integral_comp_comm hi,←L.integral_comp_comm (hib R),←L.integral_comp_comm (hib 0)] + have hLp : AngularPeriodic (2*Real.pi) (fun x => L (φ x)) := by + intro n x + dsimp only + rw [hφp n x] + have he := torusCylinder_green_real hR hF (L.contDiff.comp hφ) hp hLp hd + have hder (x : Coord3) : fderiv ℝ (fun y => L (φ y)) x=L.comp (fderiv ℝ φ x) := + (L.hasFDerivAt.comp x ((hφ.differentiable (by norm_num)) x).hasFDerivAt).fderiv + simpa only [Function.comp_def,torusPeriodicDescent,hder,ContinuousLinearMap.comp_apply,map_smul,smul_eq_mul,mul_comm] using he + exact Complex.ext (hL Complex.reCLM) (hL Complex.imCLM) + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus +open scoped ENNReal +local instance torusCylinderGreenComplexModeMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusCylinderGreenComplexModeIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma complex_coordinate_fderiv_expansion (φ : Coord3 → ℂ) (x v : Coord3) : + fderiv ℝ φ x v=∑ j : Fin 3,(v j:ℂ)*fderiv ℝ φ x (Pi.single j 1) := by + have he : v=∑ j : Fin 3,(v j) • (Pi.single j 1 : Coord3) := by + ext i + fin_cases i <;> simp [Pi.smul_apply,Pi.single_apply] + conv_lhs => rw [he,map_sum] + apply Finset.sum_congr rfl + intro j _ + simp [Complex.real_smul] + +lemma torusFlux_mode_green {R : ℝ} (hR : 0≤R) (s : Fin 3 → ℝ) + {F : Coord3 → Coord3} (hF : ContDiff ℝ 1 F) + (hp : AngularPeriodic (2*Real.pi) F) + (hd : ∀ x,x 0∈Icc 0 R → coordinateDivergence F x=0) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (h : TorusModes) : + cylinderFluxPairL hF.continuous hp R (smoothCylinderModeJet hq R h)= + torusFluxPairL hF.continuous hp s R (spectralTraceSingleL s h (q R))- + torusFluxPairL hF.continuous hp s 0 (spectralTraceSingleL s h (q 0)) := by + have hh := torusCylinder_green_complex hR hF ((flatSmoothMode_smooth hq h).of_le (by simp)) + hp (flatSmoothMode_periodic q h) hd + rw [cylinderFluxPairL_integral,torusFluxPairL_single,torusFluxPairL_single] + convert hh using 1 + · apply integral_congr_ae + filter_upwards [ae_all_iff.mpr (smoothCylinderModeJet_ae hq R h)] with z hz + simp_rw [hz] + simp only [torusPeriodicDescent] + rw [complex_coordinate_fderiv_expansion] + apply Finset.sum_congr rfl + intro j _ + rw [flatSmoothMode_derivative hq] + simp only [torusAngles_scaled,torusRealProjection_representative,Matrix.cons_val_zero] + · congr 1 <;> apply integral_congr_ae <;> exact Filter.Eventually.of_forall (fun θ => by + simp only [torusPeriodicDescent,flatSmoothMode_eq,torusAngles_scaled, + torusRealProjection_representative,Matrix.cons_val_zero,Complex.real_smul]) + +lemma torusFluxPairL_polynomial {F : Coord3 → Coord3} (hF : Continuous F) + (hp : AngularPeriodic (2*Real.pi) F) (s : Fin 3 → ℝ) (t : ℝ) + (p : TorusModes →₀ smoothComplexAxis) : + torusFluxPairL hF hp s t (cylinderPolynomialTraceL s t p)= + ∑ h∈p.support,torusFluxPairL hF hp s t (spectralTraceSingleL s h (p h t)) := by + rw [cylinderPolynomialTraceL,Finsupp.lsum_apply,Finsupp.sum,map_sum] + rfl + +theorem torusFlux_completed_green {R : ℝ} (hR : 0≤R) (s : Fin 3 → ℝ) + {F : Coord3 → Coord3} (hF : ContDiff ℝ 1 F) + (hp : AngularPeriodic (2*Real.pi) F) + (hd : ∀ x,x 0∈Icc 0 R → coordinateDivergence F x=0) + (z : cylinderSobolevGraph s R) : + cylinderFluxPairL hF.continuous hp R z.val.1= + torusFluxPairL hF.continuous hp s R z.val.2.2- + torusFluxPairL hF.continuous hp s 0 z.val.2.1 := by + let J : CylinderTraceAmbient s R →L[ℂ] FiniteCylinderJets R := ContinuousLinearMap.fst ℂ _ _ + let T₀ : CylinderTraceAmbient s R →L[ℂ] spectralTraceGraph (torusRate s) := + (ContinuousLinearMap.fst ℂ _ _).comp (ContinuousLinearMap.snd ℂ _ _) + let T₁ : CylinderTraceAmbient s R →L[ℂ] spectralTraceGraph (torusRate s) := + (ContinuousLinearMap.snd ℂ _ _).comp (ContinuousLinearMap.snd ℂ _ _) + let L := (cylinderFluxPairL hF.continuous hp R).comp J- + (((torusFluxPairL hF.continuous hp s R).comp T₁)- + ((torusFluxPairL hF.continuous hp s 0).comp T₀)) + have hr : LinearMap.range (cylinderPolynomialGraphL s R)≤L.ker := by + rintro _ ⟨p,rfl⟩ + change cylinderFluxPairL hF.continuous hp R (cylinderPolynomialJetL R p)- + (torusFluxPairL hF.continuous hp s R (cylinderPolynomialTraceL s R p)- + torusFluxPairL hF.continuous hp s 0 (cylinderPolynomialTraceL s 0 p))=0 + rw [cylinderPolynomialJetL_apply,map_sum,torusFluxPairL_polynomial,torusFluxPairL_polynomial] + simp_rw [torusFlux_mode_green hR s hF hp hd,Finset.sum_sub_distrib,sub_self] + have hz := Submodule.topologicalClosure_minimal _ hr L.isClosed_ker z.property + exact sub_eq_zero.mp hz + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenReal.lean b/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenReal.lean new file mode 100644 index 0000000000000000000000000000000000000000..67f225dd22d7615b5eac2e46c2b3325741f5872a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TorusCylinderGreenReal.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularJet +import OAI.Analysis.Conductivity.Flux.WeakFluxClassicalC1 +import OAI.Analysis.Conductivity.Fourier.TorusPeriodicDescent + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus +open scoped ENNReal +local instance torusCylinderGreenRealMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusCylinderGreenRealIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma continuous_memLp_finiteCylinder_general {E : Type*} [NormedAddCommGroup E] + {f : ℝ × UnitAddTorus (Fin 2) → E} (hf : Continuous f) (R : ℝ) : + MemLp f 2 ((FiniteAxisMeasure R).prod volume) := by + obtain ⟨C,hC⟩ := ((isCompact_Icc (a:=(0:ℝ)) (b:=R)).prod + (isCompact_univ : IsCompact (univ : Set (UnitAddTorus (Fin 2))))).exists_bound_of_continuousOn hf.continuousOn + apply MemLp.of_bound hf.aestronglyMeasurable C + filter_upwards [finiteCylinder_ae_mem R] with z hz + exact hC z ⟨hz,mem_univ _⟩ + +lemma torusPeriodicDescent_cylinderIntegral {f : Coord3 → ℝ} + (hf : Continuous f) (hp : AngularPeriodic (2*Real.pi) f) {R : ℝ} (hR : 0≤R) : + (∫ z,torusPeriodicDescent f z ∂(FiniteAxisMeasure R).prod volume)= + (2*Real.pi)⁻¹^2*(∫ t in (0:ℝ)..R,torusCellIntegral (2*Real.pi) f t) := by + rw [integral_prod _ ((continuous_memLp_finiteCylinder_general + (continuous_torusPeriodicDescent hf hp) R).integrable (by norm_num))] + simp_rw [torusPeriodicDescent_integral hf hp] + rw [integral_const_mul,intervalIntegral.integral_of_le hR] + +theorem torusCylinder_green_real {R : ℝ} (hR : 0≤R) + {F : Coord3 → Coord3} {φ : Coord3 → ℝ} + (hF : ContDiff ℝ 1 F) (hφ : ContDiff ℝ 1 φ) + (hp : AngularPeriodic (2*Real.pi) F) (hφp : AngularPeriodic (2*Real.pi) φ) + (hd : ∀ x,x 0∈Icc 0 R → coordinateDivergence F x=0) : + (∫ z,torusPeriodicDescent (fun x => fderiv ℝ φ x (F x)) z + ∂(FiniteAxisMeasure R).prod volume)= + (∫ θ,torusPeriodicDescent (fun x => φ x*F x 0) (R,θ))- + (∫ θ,torusPeriodicDescent (fun x => φ x*F x 0) (0,θ)) := by + have hc := (hφ.continuous_fderiv (by norm_num)).clm_apply hF.continuous + have hdp : AngularPeriodic (2*Real.pi) (fun x => fderiv ℝ φ x (F x)) := by + intro n x + dsimp only + rw [hφp.fderiv n x,hp n x] + have hpc : Continuous (fun x => φ x*F x 0) := hφ.continuous.mul ((continuous_apply 0).comp hF.continuous) + have hpp : AngularPeriodic (2*Real.pi) (fun x => φ x*F x 0) := by + intro n x + dsimp only + rw [hφp n x,hp n x] + rw [torusPeriodicDescent_cylinderIntegral hc hdp hR, + torusPeriodicDescent_integral hpc hpp,torusPeriodicDescent_integral hpc hpp, + torus_band_green_C1 (by positivity) hR hF hφ hp hφp hd,mul_sub] + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus +open scoped ENNReal +local instance torusCylinderGreenRealFluxMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusCylinderGreenRealFluxIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +variable {F : Coord3 → Coord3} + +lemma continuous_torusFluxComponent (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (j : Fin 3) : Continuous (fun z => (torusPeriodicDescent F z j:ℂ)) := + Complex.continuous_ofReal.comp ((continuous_apply j).comp (continuous_torusPeriodicDescent hF hp)) + +def cylinderFluxLp (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (R : ℝ) (j : Fin 3) : CylinderL2 (FiniteAxisMeasure R) := + (continuous_memLp_finiteCylinder (continuous_torusFluxComponent hF hp j) R).toLp _ + +lemma cylinderFluxLp_ae (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (R : ℝ) (j : Fin 3) : cylinderFluxLp hF hp R j=ᵐ[(FiniteAxisMeasure R).prod volume] + fun z => (torusPeriodicDescent F z j:ℂ) := + (continuous_memLp_finiteCylinder (continuous_torusFluxComponent hF hp j) R).coeFn_toLp + +def cylinderFluxPairL (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (R : ℝ) : FiniteCylinderJets R →L[ℂ] ℂ := + ∑ j : Fin 3,(innerSL ℂ (cylinderFluxLp hF hp R j)).comp + (PiLp.proj 2 (fun _ : Fin 4 => CylinderL2 (FiniteAxisMeasure R)) j.succ) + +lemma cylinderFluxPairL_apply (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (R : ℝ) (J : FiniteCylinderJets R) : + cylinderFluxPairL hF hp R J=∑ j : Fin 3,inner ℂ (cylinderFluxLp hF hp R j) (J j.succ) := by + simp [cylinderFluxPairL] + +lemma cylinderFluxPairL_integral (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (R : ℝ) (J : FiniteCylinderJets R) : + cylinderFluxPairL hF hp R J= + ∫ z,∑ j : Fin 3,(torusPeriodicDescent F z j:ℂ)*J j.succ z ∂(FiniteAxisMeasure R).prod volume := by + rw [cylinderFluxPairL_apply] + simp_rw [L2.inner_def] + rw [←integral_finsetSum _ (fun i _ => L2.integrable_inner (𝕜:=ℂ) _ _)] + apply integral_congr_ae + filter_upwards [ae_all_iff.mpr (cylinderFluxLp_ae hF hp R)] with z hz + apply Finset.sum_congr rfl + intro j _ + rw [hz j] + simp [RCLike.inner_apply,mul_comm] + +def torusFluxLp (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) (t : ℝ) : TorusL2 := + ContinuousMap.toLp 2 volume ℂ ⟨fun θ => (torusPeriodicDescent F (t,θ) 0:ℂ), + (continuous_torusFluxComponent hF hp 0).comp (continuous_const.prodMk continuous_id)⟩ + +lemma torusFluxLp_ae (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) (t : ℝ) : + torusFluxLp hF hp t=ᵐ[volume] fun θ => (torusPeriodicDescent F (t,θ) 0:ℂ) := + ContinuousMap.coeFn_toLp volume _ + +def torusSpectralSynthesis (s : Fin 3 → ℝ) : spectralTraceGraph (torusRate s) →L[ℂ] TorusL2 := + ((mFourierBasis (d:=Fin 2)).repr.symm.toContinuousLinearEquiv.toContinuousLinearMap).comp + ((PiLp.proj 2 (fun _ : Fin 2 => SpectralL2 TorusModes) 0).comp (spectralTraceGraph (torusRate s)).subtypeL) + +lemma torusSpectralSynthesis_single (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) : + torusSpectralSynthesis s (spectralTraceSingleL s h a)=a • mFourierLp 2 h := by + change (mFourierBasis (d:=Fin 2)).repr.symm (lp.single 2 h a)=_ + rw [show (a:ℂ)=a • (1:ℂ) by simp,lp.single_smul,map_smul,HilbertBasis.repr_symm_single] + simp only [coe_mFourierBasis,smul_eq_mul,mul_one] + +def torusFluxPairL (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (s : Fin 3 → ℝ) (t : ℝ) : spectralTraceGraph (torusRate s) →L[ℂ] ℂ := + (innerSL ℂ (torusFluxLp hF hp t)).comp (torusSpectralSynthesis s) + +lemma torusFluxPairL_integral (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (s : Fin 3 → ℝ) (t : ℝ) (f : spectralTraceGraph (torusRate s)) : + torusFluxPairL hF hp s t f= + ∫ θ,(torusPeriodicDescent F (t,θ) 0:ℂ)*torusSpectralSynthesis s f θ := by + change inner ℂ (torusFluxLp hF hp t) (torusSpectralSynthesis s f)=_ + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [torusFluxLp_ae hF hp t] with θ hθ + rw [hθ] + simp [RCLike.inner_apply,mul_comm] + +lemma torusFluxPairL_single (hF : Continuous F) (hp : AngularPeriodic (2*Real.pi) F) + (s : Fin 3 → ℝ) (t : ℝ) (h : TorusModes) (a : ℂ) : + torusFluxPairL hF hp s t (spectralTraceSingleL s h a)= + ∫ θ,(torusPeriodicDescent F (t,θ) 0:ℂ)*(a*mFourier h θ) := by + rw [torusFluxPairL_integral,torusSpectralSynthesis_single] + apply integral_congr_ae + filter_upwards [Lp.coeFn_smul a (mFourierLp 2 h),coeFn_mFourierLp 2 h] with θ h1 h2 + rw [h1] + simp only [Pi.smul_apply,smul_eq_mul,h2] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TorusFluxDecay.lean b/lean/OAI/Analysis/Conductivity/Flux/TorusFluxDecay.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca6b92c5cd515ab084867e2e01e8e3f4994d38cd --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TorusFluxDecay.lean @@ -0,0 +1,160 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.TorusLeadingDecay +import OAI.Analysis.Conductivity.Fourier.PeriodicFamilyCorrection +import OAI.Analysis.Conductivity.Flux.TorusBoxFlux +import OAI.Analysis.Conductivity.Fourier.FlatFourierFlux + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma torusCellIntegral_norm_le {T C t : ℝ} (hT : 0≤T) {f : Coord3 → ℝ} + (hf : ∀ y z,‖f ![t,y,z]‖≤C) : ‖torusCellIntegral T f t‖≤C*T^2 := by + have hz (y : ℝ) : ‖∫ z in (0:ℝ)..T,f ![t,y,z]‖≤C*T := by + simpa only [sub_zero,abs_of_nonneg hT] using + (intervalIntegral.norm_integral_le_of_norm_le_const (a:=0) (b:=T) (fun z _ => hf y z)) + have hy := intervalIntegral.norm_integral_le_of_norm_le_const (a:=0) (b:=T) (fun y _ => hz y) + simpa only [sub_zero,abs_of_nonneg hT,torusCellIntegral,pow_two,mul_assoc] using hy + +lemma torusCellIntegral_tendsto_zero {T : ℝ} (hT : 0≤T) {f : Coord3 → ℝ} {b : ℝ→ℝ} + (hb : Tendsto b atTop (𝓝 0)) (hf : ∀ᶠ t in atTop,∀ y z,‖f ![t,y,z]‖≤b t) : + Tendsto (torusCellIntegral T f) atTop (𝓝 0) := by + apply squeeze_zero_norm' (hf.mono (fun t ht => torusCellIntegral_norm_le hT ht)) + simpa using hb.mul_const (T^2) + +lemma flatFourier_exponential_bound {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2→ℤ)→ℝ} {B gap : ℝ} (ha : ∀ h,|a h|≤B) (hg : 0≤gap) + (hr : ∀ h,a h≠0 → gap≤torusRate s h) (n : ℕ) : + ∃ C : ℝ,0≤C ∧ ∀ x : Coord3,1≤x 0 → + ‖iteratedFDeriv ℝ n (flatFourier s a phase) x‖≤C*exp (-gap*(x 0-1)) := by + let C := ∑' h,B*((torusRate s h+torusSize h)^n*exp (-torusRate s h)) + have hB : 0≤B := (abs_nonneg (a 0)).trans (ha 0) + refine ⟨C,tsum_nonneg (fun h => ?_),?_⟩ + · have ht := sqrt_nonneg (torusQuadratic s h) + have hz := torusSize_nonneg h + exact mul_nonneg hB (mul_nonneg (pow_nonneg (add_nonneg ht hz) n) (exp_nonneg _)) + · intro x hx + have he : ![0,x 1,x 2]+![x 0,0,0]=x := by ext i; fin_cases i <;> simp + have hh := flatFourier_shift_uniform_bound (a:=a) (phase:=phase) (lam:=0) (R:=0) (T:=x 0) + hs ha le_rfl hg (by simpa only [zero_add] using hr) (by simpa using hx) + n (x:=![0,x 1,x 2]) (by simp) + rw [he] at hh + simpa [C,mul_comm] using hh + +lemma tendsto_exp_neg_gap {gap : ℝ} (hg : 0 exp (-gap*(t-1))) atTop (𝓝 0) := by + apply Real.tendsto_exp_atBot.comp + exact (tendsto_atTop_add_const_right atTop (-1) tendsto_id).const_mul_atTop_of_neg (neg_neg_of_pos hg) + +lemma flatFourier_mean_axial_flux_zero {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2→ℤ)→ℝ} {B gap t : ℝ} (ha : ∀ h,|a h|≤B) (hg : 0 fderiv ℝ (flatFourier s a phase) x (flatAxis 0)) t=0 := by + apply torus_flux_zero_of_tendsto (F:=flatModeFlux s (flatFourier s a phase)) ht + (by positivity) (flatModeFlux_smoothOn (axial_halfspace_open 0) (flatFourier_smooth hs ha)) + (flatModeFlux_periodic (flatFourier_angularPeriodic s a phase)) + (fun x hx => flatFourier_flux_divergence hs ha hx) + obtain ⟨C,hC,hb⟩ := flatFourier_exponential_bound (phase:=phase) hs ha hg.le hr 1 + apply torusCellIntegral_tendsto_zero (by positivity : (0:ℝ)≤2*Real.pi) + (by simpa using (tendsto_exp_neg_gap hg).const_mul C) + filter_upwards [eventually_ge_atTop (1:ℝ)] with t ht' + intro y z + simp only [flatModeFlux,Matrix.cons_val_zero] + rw [←neg_mul] + have hn : ‖flatAxis (0:Fin 3)‖=1 := by simp [flatAxis,Pi.norm_single] + have hh := (fderiv ℝ (flatFourier s a phase) ![t,y,z]).le_opNorm (flatAxis 0) + rw [hn,mul_one,←norm_iteratedFDeriv_one] at hh + exact hh.trans (hb _ ht') + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma coordinateDivergence_smul_at {f : Coord3 → ℝ} {F : Coord3 → Coord3} {x : Coord3} + (hf : DifferentiableAt ℝ f x) (hF : DifferentiableAt ℝ F x) : + coordinateDivergence (fun y => f y • F y) x= + f x*coordinateDivergence F x+fderiv ℝ f x (F x) := by + have he (i : Fin 3) : + fderiv ℝ (fun y => (f y • F y) i) x (Pi.single i 1)= + f x*fderiv ℝ (fun y => F y i) x (Pi.single i 1)+ + F x i*fderiv ℝ f x (Pi.single i 1) := by + change fderiv ℝ (fun y => f y*F y i) x _=_ + rw [fderiv_fun_mul hf ((hasFDerivAt_pi'.mp hF.hasFDerivAt i).differentiableAt)] + rfl + simp only [coordinateDivergence,he,Finset.sum_add_distrib,←Finset.mul_sum] + rw [←coordinate_fderiv_expansion] + +lemma coordinateDivergence_sub_at {F G : Coord3 → Coord3} {x : Coord3} + (hF : DifferentiableAt ℝ F x) (hG : DifferentiableAt ℝ G x) : + coordinateDivergence (fun y => F y-G y) x=coordinateDivergence F x-coordinateDivergence G x := by + unfold coordinateDivergence + rw [←Finset.sum_sub_distrib] + apply Finset.sum_congr rfl + intro i _ + change fderiv ℝ (fun y => F y i-G y i) x _=_ + rw [fderiv_fun_sub ((hasFDerivAt_pi'.mp hF.hasFDerivAt i).differentiableAt) + ((hasFDerivAt_pi'.mp hG.hasFDerivAt i).differentiableAt)] + rfl + +lemma flat_flux_pairing (s : Fin 3→ℝ) (f g : Coord3→ℝ) (x : Coord3) : + fderiv ℝ g x (flatModeFlux s f x)=fderiv ℝ f x (flatModeFlux s g x) := by + rw [coordinate_fderiv_expansion,coordinate_fderiv_expansion] + simp only [Fin.sum_univ_three,flatModeFlux,Matrix.cons_val_zero,Matrix.cons_val_one, + Matrix.cons_val_two,Matrix.head_cons,Matrix.tail_cons,flatAxis] + ring + +def flatCrossFlux (s : Fin 3→ℝ) (f g : Coord3→ℝ) (x : Coord3) : Coord3 := + g x • flatModeFlux s f x-f x • flatModeFlux s g x + +lemma flatCrossFlux_smoothOn {s : Fin 3→ℝ} {f g : Coord3→ℝ} {U : Set Coord3} + (hU : IsOpen U) (hf : ContDiffOn ℝ (↑(⊤:ℕ∞)) f U) + (hg : ContDiffOn ℝ (↑(⊤:ℕ∞)) g U) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (flatCrossFlux s f g) U := + (hg.smul (flatModeFlux_smoothOn hU hf)).sub (hf.smul (flatModeFlux_smoothOn hU hg)) + +lemma flatModeFlux_differentiableAt {s : Fin 3→ℝ} {f : Coord3→ℝ} {x : Coord3} + (hf : ContDiffAt ℝ (↑(⊤:ℕ∞)) f x) : DifferentiableAt ℝ (flatModeFlux s f) x := by + have hd := (hf.fderiv_right (m:=1) + (by exact WithTop.coe_le_coe.mpr (le_top : (2:ℕ∞)≤⊤))).differentiableAt (by simp) + have he (i : Fin 3) := hd.clm_apply (differentiableAt_const (flatAxis i)) + apply differentiableAt_pi.mpr + intro i + fin_cases i + · exact he 0 + · exact ((he 1).const_mul _).add ((he 2).const_mul _) + · exact ((he 1).const_mul _).add ((he 2).const_mul _) + +lemma flatCrossFlux_divergence {s : Fin 3→ℝ} {f g : Coord3→ℝ} {x : Coord3} + (hf : ContDiffAt ℝ (↑(⊤:ℕ∞)) f x) (hg : ContDiffAt ℝ (↑(⊤:ℕ∞)) g x) : + coordinateDivergence (flatCrossFlux s f g) x= + g x*flatTensorLaplacian s f x-f x*flatTensorLaplacian s g x := by + have hfd := hf.differentiableAt (by simp) + have hgd := hg.differentiableAt (by simp) + have hff := flatModeFlux_differentiableAt (s:=s) hf + have hgf := flatModeFlux_differentiableAt (s:=s) hg + unfold flatCrossFlux + rw [coordinateDivergence_sub_at (F:=fun y => g y • flatModeFlux s f y) + (G:=fun y => f y • flatModeFlux s g y) (hgd.smul hff) (hfd.smul hgf), + coordinateDivergence_smul_at hgd hff,coordinateDivergence_smul_at hfd hgf, + flatModeFlux_divergence hf,flatModeFlux_divergence hg,flat_flux_pairing s f g x] + ring + +lemma flatCrossFlux_periodic {s : Fin 3→ℝ} {f g : Coord3→ℝ} {T : ℝ} + (hf : AngularPeriodic T f) (hg : AngularPeriodic T g) : AngularPeriodic T (flatCrossFlux s f g) := by + intro n x + unfold flatCrossFlux + rw [hg n x,hf n x,flatModeFlux_periodic hf n x,flatModeFlux_periodic hg n x] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TwoFluxColumns.lean b/lean/OAI/Analysis/Conductivity/Flux/TwoFluxColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..a3d65b285593107b7af72139e906529450ec42d7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TwoFluxColumns.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.SmoothSupportedAdd + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity + +theorem smooth_integration_by_parts + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (v : E) (f g : SmoothScalar E) (hf : HasCompactSupport f.val) : + (∫ x, f.val x * (smoothDirection v g).val x ∂μ) = + -(∫ x, (smoothDirection v f).val x * g.val x ∂μ) := by + have hc (a b : SmoothScalar E) (ha : HasCompactSupport a.val) : + Integrable (fun x => a.val x * b.val x) μ := + ((smoothScalar_contDiff a).continuous.mul (smoothScalar_contDiff b).continuous).integrable_of_hasCompactSupport ha.mul_right + exact integral_bilinear_hasFDerivAt_right_eq_neg_left_of_integrable + (B := ContinuousLinearMap.mul ℝ ℝ) + (hc (smoothDirection v f) g (compactSupport_smoothDirection v hf)) + (hc f (smoothDirection v g) hf) (hc f g hf) + (fun x _ => ((smoothScalar_contDiff f).differentiable (by simp) x).hasFDerivAt) + (fun x _ => ((smoothScalar_contDiff g).differentiable (by simp) x).hasFDerivAt) + +theorem smooth_divergence_zero_pairing + {E ι : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] [Fintype ι] + (μ : Measure E) [μ.IsAddHaarMeasure] + (v : ι → E) (F : ι → SmoothScalar E) + (hF : ∀ i, HasCompactSupport (F i).val) + (hdiv : ∑ i, smoothDirection (v i) (F i) = 0) (ψ : SmoothScalar E) : + (∫ x, ∑ i, (F i).val x * (smoothDirection (v i) ψ).val x ∂μ) = 0 := by + have hI (i : ι) : Integrable (fun x => (F i).val x * + (smoothDirection (v i) ψ).val x) μ := + ((smoothScalar_contDiff (F i)).continuous.mul + (smoothScalar_contDiff (smoothDirection (v i) ψ)).continuous).integrable_of_hasCompactSupport (hF i).mul_right + have hI' (i : ι) : Integrable (fun x => (smoothDirection (v i) (F i)).val x * + ψ.val x) μ := + ((smoothScalar_contDiff (smoothDirection (v i) (F i))).continuous.mul + (smoothScalar_contDiff ψ).continuous).integrable_of_hasCompactSupport + (compactSupport_smoothDirection (v i) (hF i)).mul_right + rw [integral_finsetSum _ (fun i _ => hI i)] + simp_rw [smooth_integration_by_parts μ _ _ _ (hF _)] + rw [Finset.sum_neg_distrib, ← integral_finsetSum _ (fun i _ => hI' i)] + have hz (x : E) : ∑ i, (smoothDirection (v i) (F i)).val x = 0 := by + have hh := congrArg (fun f : SmoothScalar E => f.val x) hdiv + simpa using hh + simp_rw [← Finset.sum_mul, hz, zero_mul] + simp + +def twoFluxColumns {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (G : Fin 5 → SmoothScalar E) : Fin 2 → Fin 3 → SmoothScalar E := + ![![G 0, G 1, G 3], ![G 1, G 2, G 4]] + +theorem twoFluxColumns_divergence {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] (v : Fin 3 → E) (G : Fin 5 → SmoothScalar E) (j : Fin 2) : + ∑ i, smoothDirection (v i) (twoFluxColumns G j i) = twoFluxDivergence v G j := by + fin_cases j <;> simp [twoFluxColumns, twoFluxDivergence, Fin.sum_univ_succ, add_assoc] + +theorem localizedTwoFlux_weak_pairing + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (v : Fin 3 → E) (χ : SmoothScalar E) (L : E →L[ℝ] ℝ) + (H₁ H₂ : SmoothScalar ℝ) (α p q r k : ℝ) (hχ : HasCompactSupport χ.val) + (j : Fin 2) (ψ : SmoothScalar E) : + (∫ x, ∑ i, (twoFluxColumns (localizedTwoFlux v χ L H₁ H₂ α p q r k) j i).val x * + (smoothDirection (v i) ψ).val x ∂μ) = 0 := by + apply smooth_divergence_zero_pairing μ v _ _ _ ψ + · have hc (i : Fin 5) : HasCompactSupport + (localizedTwoFlux v χ L H₁ H₂ α p q r k i).val := + hχ.of_isClosed_subset (isClosed_tsupport _) + (localizedTwoFlux_support v χ L H₁ H₂ α p q r k i) + intro i + fin_cases j <;> fin_cases i <;> exact hc _ + · rw [twoFluxColumns_divergence, localizedTwoFlux_divergence] + rfl + +def piolaFlux {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : E ≃ E) (F : E → E) (y : E) : E := + |(fderiv ℝ X (X.symm y)).det|⁻¹ • fderiv ℝ X (X.symm y) (F (X.symm y)) + +theorem piolaFlux_pairing + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (X : E ≃ E) (hX : Differentiable ℝ X) + (hdet : ∀ x, (fderiv ℝ X x).det ≠ 0) + (F : E → E) (ψ : E → ℝ) (hψ : Differentiable ℝ ψ) : + (∫ y, fderiv ℝ ψ y (piolaFlux X F y) ∂μ) = + ∫ x, fderiv ℝ (ψ ∘ X) x (F x) ∂μ := by + have hc := integral_image_eq_integral_abs_det_fderiv_smul μ + MeasurableSet.univ (fun x _ => (hX x).hasFDerivAt.hasFDerivWithinAt) + X.injective.injOn (fun y => fderiv ℝ ψ y (piolaFlux X F y)) + simp only [Set.image_univ, Set.range_eq_univ.mpr X.surjective, Measure.restrict_univ] at hc + rw [hc] + apply integral_congr_ae + filter_upwards [] with x + simp only [piolaFlux, X.symm_apply_apply, map_smul, smul_eq_mul] + rw [← mul_assoc, mul_inv_cancel₀ (abs_ne_zero.mpr (hdet x)), one_mul] + rw [fderiv_comp x (hψ _) (hX x)] + rfl + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/TwoFluxDivergence.lean b/lean/OAI/Analysis/Conductivity/Flux/TwoFluxDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..cf08aa009804d001b27ad3553b6bc8f11c29f901 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/TwoFluxDivergence.lean @@ -0,0 +1,49 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.SmoothScalarAlgebra + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity + +def twoFluxDivergence {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (F : Fin 5 → SmoothScalar E) : Fin 2 → SmoothScalar E := + ![smoothDirection (v 0) (F 0) + smoothDirection (v 1) (F 1) + + smoothDirection (v 2) (F 3), + smoothDirection (v 0) (F 1) + smoothDirection (v 1) (F 2) + + smoothDirection (v 2) (F 4)] + +def airyFlux {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (φ : SmoothScalar E) : Fin 5 → SmoothScalar E := + ![smoothDirection (v 1) (smoothDirection (v 1) φ), + -(smoothDirection (v 0) (smoothDirection (v 1) φ)), + smoothDirection (v 0) (smoothDirection (v 0) φ), 0, 0] + +def transverseFlux {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (ψ η ω : SmoothScalar E) : Fin 5 → SmoothScalar E := + ![smoothDirection (v 2) ψ, smoothDirection (v 2) η, smoothDirection (v 2) ω, + -(smoothDirection (v 0) ψ) - smoothDirection (v 1) η, + -(smoothDirection (v 0) η) - smoothDirection (v 1) ω] + +theorem airyFlux_divergence {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : Fin 3 → E) (φ : SmoothScalar E) : + twoFluxDivergence v (airyFlux v φ) = 0 := by + have h01 := smoothDirection_comm (v 0) (v 1) + funext i + fin_cases i <;> simp [twoFluxDivergence, airyFlux, h01] + +theorem transverseFlux_divergence {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] (v : Fin 3 → E) (ψ η ω : SmoothScalar E) : + twoFluxDivergence v (transverseFlux v ψ η ω) = 0 := by + have h02 := smoothDirection_comm (v 0) (v 2) + have h12 := smoothDirection_comm (v 1) (v 2) + funext i + fin_cases i <;> simp [twoFluxDivergence, transverseFlux, h02, h12] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/VariableBlockTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/VariableBlockTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..95015b29cc3042148e4b5c88eae00fafcdd72e9f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/VariableBlockTensor.lean @@ -0,0 +1,194 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalBlockTensor +import OAI.Analysis.Conductivity.Flux.VariableCollarTensor + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal +local instance variableBlockTensorMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance variableBlockTensorBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +def variableEndTensor (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (i : Fin 3) : Coord3 → Mat3 := + Fin.cases (variableCollarTensor (K 0) (a 0) centralThickness) + (fun k => sourceChildTensorPush k + (variableCollarTensor (K k.succ) (a k.succ) (-centralThickness))) i + +lemma variableEndTensor_properties (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 ?_) i + have hk := hp k.succ (-centralThickness) + obtain ⟨c,C,hc,hcC,h⟩ := hk.2.2.1 + obtain ⟨B,hB,hbound⟩ := hk.2.2.2 + have hspos : 0 v (childAxis j)) + rw [childAxis_pi_norm] at hh + exact ⟨by simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.1 hspos.le, + by simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh.2 hspos.le⟩ + +def variableBlockTensorList (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (is : List (Fin 3)) + (y : Fin 3 → ℝ) : Matrix (Fin 3) (Fin 3) ℝ := by + classical + exact is.foldr (fun i A => if y∈physicalEndRegion i then variableEndTensor K a i y else A) 1 + +lemma variableBlockTensorList_cons (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (i : Fin 3) (is : List (Fin 3)) + (y : Fin 3 → ℝ) : variableBlockTensorList K a (i::is) y= + (by classical exact if y∈physicalEndRegion i then variableEndTensor K a i y + else variableBlockTensorList K a is y) := rfl + +lemma variableBlockTensorList_properties (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 + obtain ⟨c,C,hc,hcC,h⟩ := identity_matrix_energy_bounds + exact ⟨measurable_const,fun _ => Matrix.transpose_one, + ⟨c,C,hc,hcC,fun _ => h⟩, + ⟨‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖+1,by positivity,fun _ => by + change ‖(1 : Matrix (Fin 3) (Fin 3) ℝ)‖ ≤ _; linarith⟩⟩ + | cons i is ih => + have hi := variableEndTensor_properties K a hK ha i + obtain ⟨c,C,hc,hcC,h⟩ := ih.2.2.1 + obtain ⟨d,D,hd,hdD,hlocal⟩ := hi.2.2.1 + obtain ⟨B,hB,hbound⟩ := ih.2.2.2 + obtain ⟨E,hE,hend⟩ := hi.2.2.2 + refine ⟨Measurable.ite (physicalEndRegion_compact i).measurableSet hi.1 ih.1,?_, + ⟨min c d,max C D,lt_min hc hd, + lt_of_le_of_lt (min_le_left _ _) (hcC.trans_le (le_max_left _ _)),?_⟩, + ⟨max B E,hB.trans_le (le_max_left _ _),?_⟩⟩ + · intro y + rw [variableBlockTensorList_cons] + split_ifs + · exact hi.2.1 y + · exact ih.2.1 y + · intro y v + rw [variableBlockTensorList_cons] + split_ifs with hy + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) (sq_nonneg _)).trans + (hlocal y v).1,(hlocal y v).2.trans + (mul_le_mul_of_nonneg_right (le_max_right _ _) (sq_nonneg _))⟩ + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) (sq_nonneg _)).trans + (h y v).1,(h y v).2.trans + (mul_le_mul_of_nonneg_right (le_max_left _ _) (sq_nonneg _))⟩ + · intro y + rw [variableBlockTensorList_cons] + split_ifs + · exact (hend y).trans (le_max_right _ _) + · exact (hbound y).trans (le_max_left _ _) + +def variableBlockTensor (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) : + (Fin 3 → ℝ) → Matrix (Fin 3) (Fin 3) ℝ := + variableBlockTensorList K a (Finset.univ : Finset (Fin 3)).toList + +lemma variableBlockTensor_local_list (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (is : List (Fin 3)) + (i : Fin 3) (hi : i∈is) {y : Fin 3 → ℝ} (hy : y∈physicalEndRegion i) : + variableBlockTensorList K a is y=variableEndTensor K a i y := by + classical + induction is with + | nil => simp at hi + | cons j is ih => + rw [variableBlockTensorList_cons] + by_cases he : j=i + · subst j; simp only [ite_eq_left hy] + · have hn : y∉physicalEndRegion j := fun hj => + (disjoint_left.mp (physicalEndRegion_pairwise_disjoint he) hj hy) + rw [ite_eq_right hn] + exact ih ((List.mem_cons.mp hi).resolve_left (Ne.symm he)) + +lemma variableBlockTensor_local (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (i : Fin 3) + {y : Fin 3 → ℝ} (hy : y∈physicalEndRegion i) : + variableBlockTensor K a y=variableEndTensor K a i y := + variableBlockTensor_local_list K a _ i (by simp) hy + +lemma variableBlockTensorList_outside (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) (is : List (Fin 3)) + {y : Fin 3 → ℝ} (hy : ∀ i∈is,y∉physicalEndRegion i) : + variableBlockTensorList K a is y=1 := by + classical + induction is with + | nil => rfl + | cons i is ih => + rw [variableBlockTensorList_cons,ite_eq_right (hy i List.mem_cons_self)] + exact ih (fun j hj => hy j (List.mem_cons_of_mem i hj)) + +theorem variableBlockTensor_properties (K : Fin 3 → Coord3 → Mat3) (a : Fin 3 → ℝ) + (hK : ∀ i,Measurable (K i) ∧ (∀ x,(K i x).IsSymm) ∧ + ∃ c C : ℝ,0 variableBlockTensor_local K a i hy, + fun y hy => variableBlockTensorList_outside K a _ (fun i _ => hy i)⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/VariableCollarTensor.lean b/lean/OAI/Analysis/Conductivity/Flux/VariableCollarTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..611f52e739a1460fed83f59b7fb64ece889447c8 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/VariableCollarTensor.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.FiniteEndPhysicalTensor +import OAI.Analysis.Conductivity.Sources.FacePasting +import OAI.Analysis.Conductivity.Variational.SymmetricQuadraticBound + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise +local instance variableCollarTensorMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance variableCollarTensorBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +def variableFaceTensor (K : Coord3 → Mat3) (a b : ℝ) (i j : Fin 4) : Coord3 → Mat3 := + fun y => attachedVariableTensor + (fun x => K (flatEndCoordinates a b (sourceFaceAngles i j x))) a i j + (sourceCollarInverse i j y) + +def variableCollarTensor (K : Coord3 → Mat3) (a b : ℝ) : Coord3 → Mat3 := + sourceFacePaste (variableFaceTensor K a b) 1 + +lemma variableFaceTensor_measurable {K : Coord3 → Mat3} (hK : Measurable K) + (a b : ℝ) (i j : Fin 4) : Measurable (variableFaceTensor K a b i j) := by + apply (attachedVariableTensor_measurable + (hK.comp ((contDiff_flatEndCoordinates a b).continuous.measurable.comp + (show Differentiable ℝ (sourceFaceAngles i j) from + fun x => (sourceFaceAngles_hasFDeriv i j x).differentiableAt).continuous.measurable)) a i j).comp + (measurable_sourceCollarInverse i j) + +lemma variableCollarTensor_measurable {K : Coord3 → Mat3} (hK : Measurable K) + (a b : ℝ) : Measurable (variableCollarTensor K a b) := + sourceFacePaste_measurable (variableFaceTensor_measurable hK a b) 1 + +lemma variableFaceTensor_symm {K : Coord3 → Mat3} (hK : ∀ x,(K x).IsSymm) + (a b : ℝ) (i j : Fin 4) (y : Coord3) : + (variableFaceTensor K a b i j y).IsSymm := + attachedVariableTensor_symmetric (fun _ => hK _) a i j _ + +lemma sourceFacePasteList_symm {B : Fin 4 → Fin 4 → Coord3 → Mat3} + (hB : ∀ i j y,(B i j y).IsSymm) (ks : List (Fin 4 × Fin 4)) (y : Coord3) : + (sourceFacePasteList B 1 ks y).IsSymm := by + induction ks with + | nil => exact Matrix.transpose_one + | cons k ks ih => + rw [sourceFacePasteList_cons] + split_ifs + · exact hB _ _ _ + · exact ih + +lemma variableCollarTensor_symm {K : Coord3 → Mat3} (hK : ∀ x,(K x).IsSymm) + (a b : ℝ) (y : Coord3) : (variableCollarTensor K a b y).IsSymm := + sourceFacePasteList_symm (variableFaceTensor_symm hK a b) _ y + +lemma sourceFacePasteList_elliptic {B : Fin 4 → Fin 4 → Coord3 → Mat3} + (hB : ∀ i j,∃ c C : ℝ,0 + obtain ⟨c,C,hc,hcC,h⟩ := identity_matrix_energy_bounds + exact ⟨c,C,hc,hcC,fun _ => h⟩ + | cons k ks ih => + obtain ⟨c,C,hc,hcC,h⟩ := ih + obtain ⟨d,D,hd,hdD,hk⟩ := hB k.1 k.2 + refine ⟨min c d,max C D,lt_min hc hd, + lt_of_le_of_lt (min_le_left _ _) (hcC.trans_le (le_max_left _ _)),?_⟩ + intro y v + rw [sourceFacePasteList_cons] + split_ifs with hy + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) (sq_nonneg _)).trans (hk y hy v).1, + (hk y hy v).2.trans (mul_le_mul_of_nonneg_right (le_max_right _ _) (sq_nonneg _))⟩ + · exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) (sq_nonneg _)).trans (h y v).1, + (h y v).2.trans (mul_le_mul_of_nonneg_right (le_max_left _ _) (sq_nonneg _))⟩ + +lemma variableCollarTensor_elliptic {K : Coord3 → Mat3} {c C : ℝ} + (hc : 0 hK (flatEndCoordinates a b (sourceFaceAngles i j x)) v) ha i j + refine ⟨l,L,hl,hlL,?_⟩ + rintro _ ⟨x,hx,rfl⟩ v + simpa only [variableFaceTensor,sourceCollarInverse_extended i j (le_refl _) (le_refl _) hx] + using h x hx v + +lemma variableCollarTensor_bounded {K : Coord3 → Mat3} (hS : ∀ x,(K x).IsSymm) + {c C : ℝ} (hc : 0 ?_⟩ + exact symmetric_matrix_bounded_of_quadratic _ (variableCollarTensor_symm hS a b y) + (hl.trans hlL).le (fun v => ⟨(mul_nonneg hl.le (sq_nonneg _)).trans (h y v).1,(h y v).2⟩) + +lemma variableCollarTensor_open (K : Coord3 → Mat3) (a b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + variableCollarTensor K a b (sourceCollarPiece i j x)= + attachedVariableTensor (fun y => K (flatEndCoordinates a b (sourceFaceAngles i j y))) a i j x := by + rw [variableCollarTensor,sourceFacePaste_open _ _ i j hx] + simp only [variableFaceTensor,sourceCollarInverse_point i j hx] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/VoltageFluxConstraints.lean b/lean/OAI/Analysis/Conductivity/Flux/VoltageFluxConstraints.lean new file mode 100644 index 0000000000000000000000000000000000000000..bd5eb21dae49b393e2afdba66897a8412d8df828 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/VoltageFluxConstraints.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CompactUpdateLp + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +def smoothVoltageGradients (μ : Measure Coord3) (U : Set Coord3) : + Set (Lp FieldVector 2 (μ.restrict U)) := + {z | ∃ (v : Coord3 → Fin 2 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) v ∧ + ∃ (hg : MemLp (voltageGradient v) 2 (μ.restrict U)), z = hg.toLp _} + +def allVoltageGradients (μ : Measure Coord3) (U : Set Coord3) : + Submodule ℝ (Lp FieldVector 2 (μ.restrict U)) := + (Submodule.span ℝ (smoothVoltageGradients μ U)).topologicalClosure + +lemma CompactGlobalUpdate.fluxCorrection_pairing + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + {v : Coord3 → Fin 2 → ℝ} (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) + (hvg : MemLp (voltageGradient v) 2 (μ.restrict U)) : + inner ℝ (hvg.toLp _) ((R.memLp_flux_correction μ).toLp _) = 0 := by + rw [L2.inner_def] + have he : (∫ x, inner ℝ ((hvg.toLp _) x) (((R.memLp_flux_correction μ).toLp _) x) ∂μ.restrict U) = + ∫ x, inner ℝ (voltageGradient v x) (fieldVector (R.dF x)) ∂μ.restrict U := by + apply integral_congr_ae + filter_upwards [hvg.coeFn_toLp,(R.memLp_flux_correction μ).coeFn_toLp] with x hx hy + rw [hx,hy] + rw [he,setIntegral_eq_integral_of_forall_compl_eq_zero] + · simp_rw [voltageGradient_pairing v (hv.differentiable (by simp))] + have hvc : ∀ j, ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => v x j) := + fun j => (contDiff_apply ℝ ℝ j).comp hv + have hint : ∀ j, Integrable (fun x => fderiv ℝ (fun y => v y j) x ((R.dF x).col j)) μ := by + intro j + apply smooth_flux_integrable_pairing μ _ + ((continuous_pi (fun i => (continuous_apply j).comp (continuous_apply i))).comp R.smooth_dF.continuous) + (R.compact_dF.comp_left (g := fun M : Matrix (Fin 3) (Fin 2) ℝ => M.col j) rfl) + _ (hvc j) + rw [integral_finsetSum _ (fun j _ => hint j)] + simp only [R.cauchy_dF _ _ (hvc _),Finset.sum_const_zero] + · intro x hx + rw [image_eq_zero_of_notMem_tsupport (fun hs => hx (R.support_dF hs))] + simp only [show fieldVector 0 = 0 from map_zero fieldVectorCLM,inner_zero_right] + +lemma CompactGlobalUpdate.fluxCorrection_mem_orthogonal + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + (R.memLp_flux_correction μ).toLp _ ∈ (allVoltageGradients μ U)ᗮ := by + let F := (R.memLp_flux_correction μ).toLp _ + let L : Lp FieldVector 2 (μ.restrict U) →L[ℝ] ℝ := innerSL ℝ F + have hker : allVoltageGradients μ U ≤ L.ker := by + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro _ ⟨v,hv,hvg,rfl⟩ + change inner ℝ F (hvg.toLp _) = 0 + rw [real_inner_comm] + exact R.fluxCorrection_pairing μ hv hvg + · exact L.isClosed_ker + intro z hz + rw [real_inner_comm] + exact hker hz + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Flux/WeakFluxClassicalC1.lean b/lean/OAI/Analysis/Conductivity/Flux/WeakFluxClassicalC1.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b6423e566a50a220ecdc6f73593c5317f71b811 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Flux/WeakFluxClassicalC1.lean @@ -0,0 +1,198 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusFluxDecay +import OAI.Analysis.Conductivity.Flux.LinearTensorEllipticity + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma coordinateDivergence_C1_continuous {F : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) : Continuous (coordinateDivergence F) := by + apply continuous_finsetSum + intro i _ + exact (((contDiff_pi.mp hF) i).continuous_fderiv (by norm_num)).clm_apply continuous_const + +theorem coordinateDivergence_C1_weak {F : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) + (ψ : Coord3 → ℝ) (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) (hc : HasCompactSupport ψ) : + (∫ x,fderiv ℝ ψ x (F x))= -(∫ x,ψ x*coordinateDivergence F x) := by + have hFi (i : Fin 3) : ContDiff ℝ 1 (fun x => F x i) := + contDiff_pi.mp hF i + have hdψ (i : Fin 3) : Continuous (fun x => fderiv ℝ ψ x (Pi.single i 1)) := + (hψ.continuous_fderiv (by norm_num)).clm_apply continuous_const + have hdF (i : Fin 3) : Continuous (fun x => fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := + ((hFi i).continuous_fderiv (by norm_num)).clm_apply continuous_const + have hi₁ (i : Fin 3) : Integrable (fun x => F x i*fderiv ℝ ψ x (Pi.single i 1)) := + ((hFi i).continuous.mul (hdψ i)).integrable_of_hasCompactSupport (hc.fderiv_apply ℝ _).mul_left + have hi₂ (i : Fin 3) : Integrable (fun x => ψ x*fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := + (hψ.continuous.mul (hdF i)).integrable_of_hasCompactSupport hc.mul_right + have he (i : Fin 3) : (∫ x,F x i*fderiv ℝ ψ x (Pi.single i 1))= + -(∫ x,ψ x*fderiv ℝ (fun y => F y i) x (Pi.single i 1)) := by + have hh := integral_mul_fderiv_eq_neg_fderiv_mul_of_integrable + (μ := (volume : Measure Coord3)) + (f := ψ) (g := fun x => F x i) (v := Pi.single i 1) + (by simpa only [mul_comm] using hi₁ i) (hi₂ i) + ((hψ.continuous.mul (hFi i).continuous).integrable_of_hasCompactSupport hc.mul_right) + (fun x _ => hψ.differentiable (by norm_num) x) + (fun x _ => (hFi i).differentiable (by norm_num) x) + have hh' : (∫ x,fderiv ℝ ψ x (Pi.single i 1)*F x i)= + (∫ x,F x i*fderiv ℝ ψ x (Pi.single i 1)) := by + apply integral_congr_ae + exact Filter.Eventually.of_forall (fun x => mul_comm _ _) + rw [hh'] at hh + linarith + have hex : (fun x => fderiv ℝ ψ x (F x))= + (fun x => ∑ i : Fin 3,F x i*fderiv ℝ ψ x (Pi.single i 1)) := by + funext x + exact coordinate_fderiv_expansion ψ x (F x) + rw [hex] + simp only [coordinateDivergence,Finset.mul_sum] + rw [integral_finsetSum _ (fun i _ => hi₁ i),integral_finsetSum _ (fun i _ => hi₂ i)] + simp_rw [he] + simp only [Finset.sum_neg_distrib] + +lemma C1_flux_divergence_zero {F : Coord3 → Coord3} {U : Set Coord3} + (hF : ContDiff ℝ 1 F) (hU : IsOpen U) + (hw : ∀ (ψ : SmoothScalar Coord3),HasCompactSupport ψ.val → tsupport ψ.val⊆U → + (∫ x,fderiv ℝ ψ.val x (F x))=0) : + ∀ x∈U,coordinateDivergence F x=0 := by + have hd := coordinateDivergence_C1_continuous hF + have hz : ∀ᵐ x : Coord3,x∈U → coordinateDivergence F x=0 := + hU.ae_eq_zero_of_integral_contDiff_smul_eq_zero + (hd.locallyIntegrable.locallyIntegrableOn U) (by + intro ψ hψ hc hs + have hh := coordinateDivergence_C1_weak hF ψ hψ hc + have he := hw ⟨ψ,hψ⟩ hc hs + change (∫ x,ψ x*coordinateDivergence F x)=0 + change (∫ x,fderiv ℝ ψ x (F x))=0 at he + linarith) + have he : coordinateDivergence F=ᵐ[volume.restrict U] (fun _ => (0:ℝ)) := + (ae_restrict_iff' hU.measurableSet).mpr hz + exact Measure.eqOn_open_of_ae_eq he hU hd.continuousOn continuous_const.continuousOn + +namespace WeakFiniteTensorPair + +lemma flux_periodic {U : Set Coord3} (w : WeakFiniteTensorPair U) {T : ℝ} + (hv : AngularPeriodic T w.v) (hE : AngularPeriodic T w.E) : AngularPeriodic T w.G := by + intro n + have hae : (fun x => w.G (x+angularShift T n))=ᵐ[volume] w.G := by + filter_upwards [w.constitution, + (measurePreserving_add_right volume (angularShift T n)).quasiMeasurePreserving.ae w.constitution] + with x hx hxn + rw [←hx,←hxn,hE n x,hv.fderiv n x] + exact fun x => congrFun (Measure.eq_of_ae_eq hae + (w.flux_C1.continuous.comp (continuous_id.add continuous_const)) w.flux_C1.continuous) x + +lemma flux_divergence {U : Set Coord3} (w : WeakFiniteTensorPair U) (hU : IsOpen U) + (j : Fin 2) : ∀ x∈U,coordinateDivergence (fun y => (w.G y).col j) x=0 := by + apply C1_flux_divergence_zero _ hU (w.weak j) + apply contDiff_pi.mpr + intro i + exact (contDiff_apply ℝ ℝ j).comp ((contDiff_apply ℝ (Fin 2 → ℝ) i).comp w.flux_C1) + +end WeakFiniteTensorPair +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory + +theorem torus_band_divergence_C1 {T a b : ℝ} (hT : 0≤T) (hab : a≤b) + {F : Coord3 → Coord3} (hF : ContDiff ℝ 1 F) (hp : AngularPeriodic T F) : + (∫ t in a..b,torusCellIntegral T (coordinateDivergence F) t)= + torusCellIntegral T (fun x => F x 0) b-torusCellIntegral T (fun x => F x 0) a := by + let A : Coord3 := ![a,0,0] + let B : Coord3 := ![b,T,T] + have hAB : A≤B := by intro i; fin_cases i; exact hab; exact hT; exact hT + have hc := coordinateDivergence_C1_continuous hF + have hfd := hF.differentiable (by norm_num) + have hh := integral_divergence_of_hasFDerivAt_off_countable A B hAB F (fderiv ℝ F) + ∅ countable_empty hF.continuous.continuousOn (fun x _ => (hfd x).hasFDerivAt) + (by simpa only [←coordinateDivergence_eq_trace hfd] using (hc.continuousOn.integrableOn_compact + (μ:=volume) (isCompact_Icc : IsCompact (Icc A B)))) + simp_rw [←coordinateDivergence_eq_trace hfd] at hh + rw [integral_coord3_Icc hAB hc] at hh + have h1 (q : Fin 2 → ℝ) : F ((1:Fin 3).insertNth T q) 1=F ((1:Fin 3).insertNth 0 q) 1 := by + have he : ((1:Fin 3).insertNth 0 q)+angularShift T ![1,0]=(1:Fin 3).insertNth T q := by + ext i; fin_cases i <;> simp [angularShift,Fin.insertNth,Fin.succAboveCases] + have hh := hp ![1,0] ((1:Fin 3).insertNth 0 q) + rw [he] at hh + exact congrFun hh 1 + have h2 (q : Fin 2 → ℝ) : F ((2:Fin 3).insertNth T q) 2=F ((2:Fin 3).insertNth 0 q) 2 := by + have he : ((2:Fin 3).insertNth 0 q)+angularShift T ![0,1]=(2:Fin 3).insertNth T q := by + ext i; fin_cases i <;> simp [angularShift,Fin.insertNth,Fin.succAboveCases] + have hh := hp ![0,1] ((2:Fin 3).insertNth 0 q) + rw [he] at hh + exact congrFun hh 2 + rw [Fin.sum_univ_succ] at hh + simp only [Fin.sum_univ_two,Fin.succ_zero_eq_one,Fin.succ_one_eq_two] at hh + simp only [A,B,Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.head_cons,Matrix.tail_cons] at hh + simp_rw [h1,h2] at hh + simp only [sub_self,add_zero] at hh + have hf0 (c : ℝ) : + (∫ q in Icc (A ∘ (0:Fin 3).succAbove) (B ∘ (0:Fin 3).succAbove), + F ((0:Fin 3).insertNth c q) 0)=torusCellIntegral T (fun x => F x 0) c := by + have hc0 : Continuous (fun q : Fin 2 → ℝ => F ((0:Fin 3).insertNth c q) 0) := + (continuous_apply 0).comp (hF.continuous.comp (by fun_prop)) + refine (integral_coord2_Icc (a:=A ∘ (0:Fin 3).succAbove) (b:=B ∘ (0:Fin 3).succAbove) (fun i => hAB ((0:Fin 3).succAbove i)) hc0).trans ?_ + change (∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,F ((0:Fin 3).insertNth c ![y,z]) 0)=_ + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + have hi : (0:Fin 3).insertNth c ![y,z]=![c,y,z] := by + ext i + fin_cases i <;> simp [Fin.insertNth,Fin.succAboveCases] + exact congrArg (fun x : Coord3 => F x 0) hi + exact hh.trans (congrArg₂ (· - ·) (hf0 b) (hf0 a)) + +lemma coordinateDivergence_smul_scalar {F : Coord3 → Coord3} {φ : Coord3 → ℝ} + {x : Coord3} (hF : DifferentiableAt ℝ F x) (hφ : DifferentiableAt ℝ φ x) : + coordinateDivergence (fun y => φ y • F y) x= + fderiv ℝ φ x (F x)+φ x*coordinateDivergence F x := by + rw [coordinateDivergence_smul_at hφ hF] + ring + +theorem torus_band_green_C1 {T a b : ℝ} (hT : 0≤T) (hab : a≤b) + {F : Coord3 → Coord3} {φ : Coord3 → ℝ} + (hF : ContDiff ℝ 1 F) (hφ : ContDiff ℝ 1 φ) + (hp : AngularPeriodic T F) (hφp : AngularPeriodic T φ) + (hd : ∀ x,x 0∈Icc a b → coordinateDivergence F x=0) : + (∫ t in a..b,torusCellIntegral T (fun x => fderiv ℝ φ x (F x)) t)= + torusCellIntegral T (fun x => φ x*F x 0) b- + torusCellIntegral T (fun x => φ x*F x 0) a := by + have hprod : AngularPeriodic T (fun x => φ x • F x) := by + intro n x + change φ (x+angularShift T n) • F (x+angularShift T n)=φ x • F x + rw [hφp n x,hp n x] + have he := torus_band_divergence_C1 hT hab (hφ.smul hF) hprod + refine Eq.trans ?_ he + apply intervalIntegral.integral_congr + intro t ht + have ht' : t∈Icc a b := by simpa only [uIcc_of_le hab] using ht + unfold torusCellIntegral + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + change fderiv ℝ φ ![t,y,z] (F ![t,y,z])= + coordinateDivergence (fun x => φ x • F x) ![t,y,z] + rw [coordinateDivergence_smul_scalar (hF.differentiable (by norm_num) _) (hφ.differentiable (by norm_num) _), + hd _ ht',mul_zero,add_zero] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AffineFourierField.lean b/lean/OAI/Analysis/Conductivity/Fourier/AffineFourierField.lean new file mode 100644 index 0000000000000000000000000000000000000000..74886b3a5bd57cc8a7f9c7048cc81a0ea27c43a3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AffineFourierField.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.FlatTorusPDE +import OAI.Analysis.Conductivity.Fourier.PeriodicFamilyCorrection + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma flatTensorLaplacian_add {s : Fin 3→ℝ} {f g : Coord3→ℝ} {x : Coord3} + (hf : ContDiffAt ℝ 2 f x) (hg : ContDiffAt ℝ 2 g x) : + flatTensorLaplacian s (fun y => f y+g y) x= + flatTensorLaplacian s f x+flatTensorLaplacian s g x := by + unfold flatTensorLaplacian + rw [fun_iteratedFDeriv_add_apply hf hg,map_add] + +lemma axial_affine_fderiv (α β : ℝ) (x : Coord3) : + fderiv ℝ (fun y : Coord3 => α*y 0+β) x=α • ContinuousLinearMap.proj 0 := by + have hh := (((ContinuousLinearMap.proj (R:=ℝ) (φ:=fun _ : Fin 3 => ℝ) 0).hasFDerivAt (x:=x)).const_mul α).add_const β + exact hh.fderiv + +lemma flatTensorLaplacian_axial_affine (s : Fin 3→ℝ) (α β : ℝ) (x : Coord3) : + flatTensorLaplacian s (fun y => α*y 0+β) x=0 := by + have he : fderiv ℝ (fun y : Coord3 => α*y 0+β)=fun _ => α • ContinuousLinearMap.proj 0 := + funext (axial_affine_fderiv α β) + unfold flatTensorLaplacian flatTensorLaplacianCLM + simp only [_root_.add_apply,_root_.smul_apply, + ContinuousMultilinearMap.apply_apply,smul_eq_mul,iteratedFDeriv_two_apply,he, + fderiv_fun_const,Pi.zero_apply,_root_.zero_apply,mul_zero,add_zero] + +def affineFourierField (s : Fin 3→ℝ) (a phase : (Fin 2→ℤ)→ℝ) (α β : ℝ) (x : Coord3) : ℝ := + α*x 0+β+flatFourier s a phase x + +lemma affineFourierField_smooth {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2→ℤ)→ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) (α β : ℝ) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (affineFourierField s a phase α β) {x | 0 α*x 0+β) by fun_prop).contDiffOn.add + (flatFourier_smooth hs ha) + +lemma affineFourierField_periodic (s : Fin 3→ℝ) (a phase : (Fin 2→ℤ)→ℝ) (α β : ℝ) : + AngularPeriodic (2*Real.pi) (affineFourierField s a phase α β) := by + intro n x + unfold affineFourierField + rw [flatFourier_angularPeriodic s a phase n x] + change α*(x 0+0)+β+_=α*x 0+β+_ + rw [add_zero] + +lemma affineFourierField_harmonic {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2→ℤ)→ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) (α β : ℝ) + {x : Coord3} (hx : 0 (n.factorial : ℝ)⁻¹ • iteratedFDeriv ℝ n f a + let r : ℝ≥0 := ⟨min R (1/C)/2,by positivity⟩ + have hr : 0<(r : ℝ) := by change 0 < min R (1/C)/2; positivity + have hrR : (r : ℝ) y)‖≤ + M*((n+1 : ℕ) : ℝ)*(C*‖y‖)^(n+1) := by + rw [map_add_eq_sum_add_integral_iteratedFDeriv (hdiff n)] + simp only [p,smul_apply,add_sub_cancel_left] + rw [norm_smul,Real.norm_of_nonneg (by positivity)] + have hi : ‖∫ t in (0:ℝ)..1, (1-t)^n • + iteratedFDeriv ℝ (n+1) f (a+t•y) (fun _ => y)‖≤ + M*C^(n+1)*((n+1).factorial : ℝ)*‖y‖^(n+1) := by + refine (intervalIntegral.norm_integral_le_of_norm_le_const + (C := M*C^(n+1)*((n+1).factorial : ℝ)*‖y‖^(n+1)) ?_).trans (by simp) + intro t ht + have ht' : t∈Icc (0:ℝ) 1 := by + simp only [uIoc_of_le zero_le_one,mem_Ioc] at ht + exact ⟨ht.1.le,ht.2⟩ + rw [norm_smul,Real.norm_of_nonneg (pow_nonneg (by linarith [ht'.2]) _)] + calc + _ ≤ 1*(‖iteratedFDeriv ℝ (n+1) f (a+t•y)‖*‖y‖^(n+1)) := + mul_le_mul (pow_le_one₀ (by linarith [ht'.2]) (by linarith [ht'.1])) + (by simpa using (iteratedFDeriv ℝ (n+1) f (a+t•y)).le_opNorm (fun _ => y)) + (norm_nonneg _) (by positivity) + _ ≤ M*C^(n+1)*((n+1).factorial : ℝ)*‖y‖^(n+1) := by + simpa only [one_mul] using mul_le_mul_of_nonneg_right (hb (n+1) _ (hseg t ht')) (by positivity : 0≤‖y‖^(n+1)) + calc + _ ≤ (n.factorial : ℝ)⁻¹*(M*C^(n+1)*((n+1).factorial : ℝ)*‖y‖^(n+1)) := + mul_le_mul_of_nonneg_left hi (by positivity) + _ = _ := by + rw [Nat.factorial_succ,Nat.cast_mul,mul_pow] + have hn : (n.factorial : ℝ)≠0 := by positivity + field_simp + have ht : Tendsto (fun n : ℕ => M*((n+1 : ℕ) : ℝ)*(C*‖y‖)^(n+1)) atTop (𝓝 0) := by + have hh := (tendsto_self_mul_const_pow_of_lt_one (show 0≤C*‖y‖ by positivity) hyC).comp + (tendsto_add_atTop_nat 1) + simpa only [mul_zero,mul_assoc,Function.comp_apply] using hh.const_mul M + have hlim : Tendsto (fun n : ℕ => ∑ k∈Finset.range (n+1), p k (fun _ => y)) atTop (𝓝 (f (a+y))) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + simp_rw [norm_sub_rev] + exact squeeze_zero (fun _ => norm_nonneg _) he ht + apply (hasSum_iff_tendsto_nat_of_summable_norm ?_).mpr + · exact (tendsto_add_atTop_iff_nat 1).mp hlim + · apply Summable.of_nonneg_of_le (fun _ => norm_nonneg _) + (fun n => ?_) ((summable_geometric_of_lt_one (show 0≤C*‖y‖ by positivity) hyC).mul_left M) + calc + ‖p n (fun _ => y)‖≤‖p n‖*‖y‖^n := by simpa using (p n).le_opNorm (fun _ => y) + _≤M*C^n*‖y‖^n := mul_le_mul_of_nonneg_right (hp n) (by positivity) + _=M*(C*‖y‖)^n := by rw [mul_pow]; ring + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped Convolution + +variable {F G : Type*} [NormedAddCommGroup F] [NormedSpace ℝ F] [CompleteSpace F] + [NormedAddCommGroup G] [NormedSpace ℝ G] [CompleteSpace G] + +lemma RadialMeanOn.linearIsometry {f : WeylSpace → F} {a : WeylSpace} {R : ℝ} + (hm : RadialMeanOn f a R) (L : F →ₗᵢ[ℝ] G) : RadialMeanOn (L ∘ f) a R := by + intro s hs x hx + change L (f x)=∫ y, (radialEta radialProfile s y) • L (f (x-y)) + simp_rw [←L.map_smul] + rw [L.integral_comp_comm] + exact congrArg L (hm s hs x hx) + +lemma RadialMeanOn.iterated {f : WeylSpace → F} {a : WeylSpace} {R : ℝ} + (hm : RadialMeanOn f a R) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hc : HasCompactSupport f) (n : ℕ) : RadialMeanOn (iteratedFDeriv ℝ n f) a R := by + induction n with + | zero => + rw [iteratedFDeriv_zero_eq_comp] + exact hm.linearIsometry (continuousMultilinearCurryFin0 ℝ WeylSpace F).symm.toLinearIsometry + | succ n ih => + have : CompleteSpace (WeylSpace →L[ℝ] WeylSpace [×n]→L[ℝ] F) := + (continuousMultilinearCurryLeftEquiv ℝ (fun _ : Fin (n+1) => WeylSpace) F).symm.toIsometryEquiv.completeSpace + rw [iteratedFDeriv_succ_eq_comp_left] + exact (ih.derivative (hf.iteratedFDeriv_right (by exact_mod_cast (show (⊤ : ℕ∞)+n≤⊤ from le_top))) (hc.iteratedFDeriv n)).linearIsometry + (continuousMultilinearCurryLeftEquiv ℝ (fun _ : Fin (n+1) => WeylSpace) F).symm.toLinearIsometry + +lemma RadialMeanOn.iterated_bound {f : WeylSpace → F} {a : WeylSpace} {R M s : ℝ} + (hm : RadialMeanOn f a R) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hc : HasCompactSupport f) (hM : 0≤M) (hs : 0 + intro x hx + simp only [Nat.cast_zero,zero_mul,add_zero] at hx + simpa only [norm_iteratedFDeriv_zero,pow_zero,mul_one] using hb x hx + | succ n ih => + intro x hx + have hx' : dist x a+s by + apply ih + have hh : dist y x ≤ s := hy + have ht := dist_triangle y x a + push_cast at hx + nlinarith) + rw [radialEta_gradient_integral hs] at he + simpa only [pow_succ,mul_assoc] using he + +lemma RadialMeanOn.factorial_bound {f : WeylSpace → F} {a x : WeylSpace} {R M : ℝ} + (hm : RadialMeanOn f a R) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hc : HasCompactSupport f) (hR : 0 hM y) hx n + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNull.lean b/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNull.lean new file mode 100644 index 0000000000000000000000000000000000000000..5229be349dfb4dceb9a8b8cf33acdd36226205fe --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNull.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter MeasureTheory Topology + +section LocalNull +variable {E : Type*} [TopologicalSpace E] [SecondCountableTopology E] + [MeasurableSpace E] (μ : Measure E) + +lemma measure_inter_zero_of_local {U Z : Set E} + (h : ∀ x ∈ U, ∃ V : Set E, x ∈ V ∧ IsOpen V ∧ μ (V ∩ Z) = 0) : + μ (U ∩ Z) = 0 := by + choose V hmem hopen hnull using (fun x : U => h x x.property) + obtain ⟨I,hIc,hcov⟩ := (HereditarilyLindelofSpace.isLindelof U).elim_countable_subcover + V hopen (by intro x hx; exact mem_iUnion.mpr ⟨⟨x,hx⟩,hmem ⟨x,hx⟩⟩) + apply measure_mono_null (t := ⋃ x ∈ I, V x ∩ Z) + · intro x hx + rcases mem_iUnion₂.mp (hcov hx.1) with ⟨y,hy,hxy⟩ + exact mem_iUnion₂.mpr ⟨y,hy,hxy,hx.2⟩ + · exact (measure_biUnion_null_iff hIc).mpr (fun x _ => hnull x) +end LocalNull + +def AnalyticNullProperty (E : Type*) [NormedAddCommGroup E] [NormedSpace ℝ E] + [MeasurableSpace E] (μ : Measure E) : Prop := + ∀ (U : Set E) (f : E → ℝ), IsOpen U → IsPreconnected U → AnalyticOnNhd ℝ f U → + (∃ x ∈ U, f x ≠ 0) → μ (U ∩ f ⁻¹' {0}) = 0 + +lemma analyticNull_real : AnalyticNullProperty ℝ volume := by + intro U f hU hc hf ⟨x,hx,hfx⟩ + have hd : IsDiscrete (f ⁻¹' {0} ∩ U) := isDiscrete_of_codiscreteWithin + (by simpa only [preimage_compl] using + hf.preimage_zero_mem_codiscreteWithin hfx hx ⟨⟨x,hx⟩,hc⟩) + rw [inter_comm] + exact ((HereditarilyLindelofSpace.isLindelof _).countable_of_isDiscrete hd).measure_zero volume + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + [MeasurableSpace E] [BorelSpace E] [MeasurableSpace F] [BorelSpace F] + [SecondCountableTopology E] [SecondCountableTopology F] + +omit [SecondCountableTopology E] in +lemma analytic_zero_measurable {U : Set E} {f : E → ℝ} + (hU : IsOpen U) (hf : AnalyticOnNhd ℝ f U) : + MeasurableSet (U ∩ f ⁻¹' {0}) := by + have ho := hf.continuousOn.isOpen_inter_preimage hU (isClosed_singleton.isOpen_compl : IsOpen ({0}ᶜ : Set ℝ)) + convert hU.measurableSet.diff ho.measurableSet using 1 + ext x + simp only [mem_inter_iff,mem_preimage,mem_singleton_iff,Set.mem_sdiff,mem_compl_iff] + tauto + +omit [SecondCountableTopology E] in +lemma analytic_null_rectangle (μ : Measure E) (ν : Measure F) [SFinite ν] + (hE : AnalyticNullProperty E μ) (hF : AnalyticNullProperty F ν) + {U : Set E} {V : Set F} {f : E × F → ℝ} + (hU : IsOpen U) (hV : IsOpen V) (hcU : IsPreconnected U) (hcV : IsPreconnected V) + (hf : AnalyticOnNhd ℝ f (U ×ˢ V)) (hx : ∃ x ∈ U ×ˢ V, f x ≠ 0) : + μ.prod ν ((U ×ˢ V) ∩ f ⁻¹' {0}) = 0 := by + obtain ⟨⟨x₀,y₀⟩,hxy,hfxy⟩ := hx + have ha : AnalyticOnNhd ℝ (fun x => f (x,y₀)) U := by + intro x hx + have hg : AnalyticAt ℝ (fun t : E => (t,y₀)) x := analyticAt_id.prod analyticAt_const + exact (hf (x,y₀) ⟨hx,hxy.2⟩).comp (f := fun t : E => (t,y₀)) hg + have hn := hE U (fun x => f (x,y₀)) hU hcU ha ⟨x₀,hxy.1,hfxy⟩ + apply Measure.measure_prod_null_of_ae_null (analytic_zero_measurable (hU.prod hV) hf) + filter_upwards [compl_mem_ae_iff.mpr hn] with x hx + by_cases hxU : x ∈ U + · have hfx : f (x,y₀) ≠ 0 := by simpa [hxU] using hx + have hb : AnalyticOnNhd ℝ (fun y => f (x,y)) V := by + intro y hy + have hg : AnalyticAt ℝ (fun t : F => (x,t)) y := analyticAt_const.prod analyticAt_id + exact (hf (x,y) ⟨hxU,hy⟩).comp (f := fun t : F => (x,t)) hg + change ν (Prod.mk x ⁻¹' ((U ×ˢ V) ∩ f ⁻¹' {0})) = 0 + have he : Prod.mk x ⁻¹' ((U ×ˢ V) ∩ f ⁻¹' {0}) = + V ∩ (fun y => f (x,y)) ⁻¹' {0} := by ext y; simp [hxU] + rw [he] + exact hF V (fun y => f (x,y)) hV hcV hb ⟨y₀,hxy.2,hfx⟩ + · simp [hxU] + +lemma analyticNull_prod (μ : Measure E) (ν : Measure F) [SFinite ν] + (hE : AnalyticNullProperty E μ) (hF : AnalyticNullProperty F ν) : + AnalyticNullProperty (E × F) (μ.prod ν) := by + intro U f hU hc hf ⟨x₀,hx₀,hfx₀⟩ + apply measure_inter_zero_of_local + intro p hp + obtain ⟨ε,hε,hsub⟩ := Metric.isOpen_iff.mp hU p hp + let V := Metric.ball p.1 ε ×ˢ Metric.ball p.2 ε + have hVm : p ∈ V := ⟨Metric.mem_ball_self hε,Metric.mem_ball_self hε⟩ + have hVo : IsOpen V := Metric.isOpen_ball.prod Metric.isOpen_ball + have hVU : V ⊆ U := by + intro q hq + apply hsub + rw [Metric.mem_ball,Prod.dist_eq] + exact max_lt hq.1 hq.2 + have hne : ∃ x ∈ V, f x ≠ 0 := by + by_contra! hn + have he : f =ᶠ[𝓝 p] 0 := by + filter_upwards [hVo.mem_nhds hVm] with x hx + exact hn x hx + exact hfx₀ (hf.eqOn_zero_of_preconnected_of_eventuallyEq_zero hc hp he hx₀) + refine ⟨V,hVm,hVo,?_⟩ + exact analytic_null_rectangle μ ν hE hF Metric.isOpen_ball Metric.isOpen_ball + (convex_ball _ _).isPreconnected (convex_ball _ _).isPreconnected (hf.mono hVU) hne + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter MeasureTheory Topology + +section Transfer +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + [MeasurableSpace E] [BorelSpace E] [MeasurableSpace F] [BorelSpace F] + [SecondCountableTopology E] [SecondCountableTopology F] + +omit [BorelSpace E] [SecondCountableTopology E] [SecondCountableTopology F] in +lemma analyticNull_of_equiv (μ : Measure E) (ν : Measure F) (e : E ≃L[ℝ] F) + (he : MeasurePreserving e μ ν) (hF : AnalyticNullProperty F ν) : + AnalyticNullProperty E μ := by + intro U f hU hc hf ⟨x,hx,hfx⟩ + let V := e '' U + have hVo : IsOpen V := e.toHomeomorph.isOpenMap _ hU + have hg : AnalyticOnNhd ℝ (fun y => f (e.symm y)) V := by + rintro y ⟨z,hz,rfl⟩ + apply (hf z hz).comp_of_eq (e.symm.analyticAt _) (e.symm_apply_apply z) + have hn := hF V (fun y => f (e.symm y)) hVo + (hc.image e e.continuous.continuousOn) hg ⟨e x,mem_image_of_mem _ hx,by simpa using hfx⟩ + rw [←he.measure_preimage (analytic_zero_measurable hVo hg).nullMeasurableSet] at hn + have hs : U ∩ f ⁻¹' {0} = e ⁻¹' (V ∩ (fun y => f (e.symm y)) ⁻¹' {0}) := by + ext z + simp [V] + rw [hs] + exact hn +end Transfer + +def splitFinCLE (n : ℕ) : (Fin (n+1) → ℝ) ≃L[ℝ] ℝ × (Fin n → ℝ) := + LinearEquiv.toContinuousLinearEquiv + { toEquiv := (Fin.insertNthEquiv (fun _ : Fin (n+1) => ℝ) 0).symm + map_add' := by intros; rfl + map_smul' := by intros; rfl } + +lemma splitFinCLE_measurePreserving (n : ℕ) : + MeasurePreserving (splitFinCLE n) volume volume := + volume_preserving_piFinSuccAbove (fun _ : Fin (n+1) => ℝ) 0 + +theorem analyticNull_fin (n : ℕ) : AnalyticNullProperty (Fin n → ℝ) volume := by + induction n with + | zero => + intro U f hU hc hf ⟨x,hx,hfx⟩ + have h : U ∩ f ⁻¹' {0} = ∅ := by + apply eq_empty_of_forall_notMem + intro y hy + exact hfx (by simpa only [Subsingleton.elim y x, mem_preimage, mem_singleton_iff] using hy.2) + rw [h,measure_empty] + | succ n ih => + exact analyticNull_of_equiv volume volume (splitFinCLE n) (splitFinCLE_measurePreserving n) + (analyticNull_prod volume volume analyticNull_real ih) + +lemma analytic_zero_volume {n : ℕ} {U : Set (Fin n → ℝ)} {f : (Fin n → ℝ) → ℝ} + (hU : IsOpen U) (hc : IsPreconnected U) (hf : AnalyticOnNhd ℝ f U) + (hn : ∃ x ∈ U, f x ≠ 0) : volume (U ∩ f ⁻¹' {0}) = 0 := + analyticNull_fin n U f hU hc hf hn + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNullEuclidean.lean b/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNullEuclidean.lean new file mode 100644 index 0000000000000000000000000000000000000000..5dae3e1ef0949a6f2086daa982c8215693e9d390 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AnalyticNullEuclidean.lean @@ -0,0 +1,33 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AnalyticNull + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +lemma analyticNull_euclidean (n : ℕ) : AnalyticNullProperty (EuclideanSpace ℝ (Fin n)) volume := + analyticNull_of_equiv volume volume + (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin n => ℝ)) + (PiLp.volume_preserving_ofLp (Fin n)) (analyticNull_fin n) + +lemma analytic_directional_fderiv {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} {U : Set E} (hf : AnalyticOnNhd ℝ f U) (w : E) : + AnalyticOnNhd ℝ (fun x => fderiv ℝ f x w) U := + (ContinuousLinearMap.apply ℝ ℝ w).comp_analyticOnNhd hf.fderiv + +lemma analytic_gradient_minor {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {u v : E → ℝ} {U : Set E} (hu : AnalyticOnNhd ℝ u U) + (hv : AnalyticOnNhd ℝ v U) (p q : E) : + AnalyticOnNhd ℝ (fun x => fderiv ℝ u x p*fderiv ℝ v x q- + fderiv ℝ u x q*fderiv ℝ v x p) U := + ((analytic_directional_fderiv hu p).mul (analytic_directional_fderiv hv q)).sub + ((analytic_directional_fderiv hu q).mul (analytic_directional_fderiv hv p)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularFourierConjugacy.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularFourierConjugacy.lean new file mode 100644 index 0000000000000000000000000000000000000000..d9b66d9b86afba560665b943a594267f7620a69a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularFourierConjugacy.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierPairFlux +import OAI.Analysis.Conductivity.Fourier.LeadingFrequencyAlignment + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +lemma normalizedAngularTensor_quadratic (s : Fin 3 → ℝ) + (A : Matrix (Fin 2) (Fin 2) ℤ) (x y : ℝ) : + normalizedAngularTensor s A 0*x^2+2*normalizedAngularTensor s A 1*x*y+ + normalizedAngularTensor s A 2*y^2= + angularNormalization A * + (s 0*((A 1 1:ℝ)*x-(A 1 0:ℝ)*y)^2+ + 2*s 1*((A 1 1:ℝ)*x-(A 1 0:ℝ)*y)*(-(A 0 1:ℝ)*x+(A 0 0:ℝ)*y)+ + s 2*(-(A 0 1:ℝ)*x+(A 0 0:ℝ)*y)^2) := by + dsimp [normalizedAngularTensor] + ring + +lemma angular_vecMul_zero (h : Fin 2 → ℤ) (A : Matrix (Fin 2) (Fin 2) ℤ) : + ((h ᵥ* A) 0:ℝ)=(h 0:ℝ)*(A 0 0:ℝ)+(h 1:ℝ)*(A 1 0:ℝ) := by + simp [Matrix.vecMul,dotProduct,Fin.sum_univ_two] + +lemma angular_vecMul_one (h : Fin 2 → ℤ) (A : Matrix (Fin 2) (Fin 2) ℤ) : + ((h ᵥ* A) 1:ℝ)=(h 0:ℝ)*(A 0 1:ℝ)+(h 1:ℝ)*(A 1 1:ℝ) := by + simp [Matrix.vecMul,dotProduct,Fin.sum_univ_two] + +lemma angular_vecMul_inverse {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (h : Fin 2 → ℤ) : + (A 1 1:ℝ)*((h ᵥ* A) 0:ℝ)-(A 1 0:ℝ)*((h ᵥ* A) 1:ℝ)=(h 0:ℝ) ∧ + -(A 0 1:ℝ)*((h ᵥ* A) 0:ℝ)+(A 0 0:ℝ)*((h ᵥ* A) 1:ℝ)=(h 1:ℝ) := by + have hdZ : A 0 0*A 1 1-A 0 1*A 1 0=1 := by simpa only [det_fin_two] using hA + have hd : (A 0 0:ℝ)*(A 1 1:ℝ)-(A 0 1:ℝ)*(A 1 0:ℝ)=1 := by exact_mod_cast hdZ + rw [angular_vecMul_zero,angular_vecMul_one] + constructor + · calc + _ = ((A 0 0:ℝ)*(A 1 1:ℝ)-(A 0 1:ℝ)*(A 1 0:ℝ))*(h 0:ℝ) := by ring + _ = _ := by rw [hd,one_mul] + · calc + _ = ((A 0 0:ℝ)*(A 1 1:ℝ)-(A 0 1:ℝ)*(A 1 0:ℝ))*(h 1:ℝ) := by ring + _ = _ := by rw [hd,one_mul] + +lemma torusQuadratic_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) (h : Fin 2 → ℤ) : + torusQuadratic (normalizedAngularTensor s A) (h ᵥ* A)= + angularNormalization A*torusQuadratic s h := by + unfold torusQuadratic + rw [normalizedAngularTensor_quadratic,(angular_vecMul_inverse hA h).1, + (angular_vecMul_inverse hA h).2] + +lemma torusRate_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) (h : Fin 2 → ℤ) : + torusRate (normalizedAngularTensor s A) (h ᵥ* A)= + Real.sqrt (angularNormalization A)*torusRate s h := by + unfold torusRate + rw [torusQuadratic_angular_conjugacy s hA, + Real.sqrt_mul (angularNormalization_pos A).le] + +def angularNormalizedLift (A : Matrix (Fin 2) (Fin 2) ℤ) (x : Coord3) : Coord3 := + ![Real.sqrt (angularNormalization A)*x 0, + (A 0 0:ℝ)*x 1+(A 0 1:ℝ)*x 2,(A 1 0:ℝ)*x 1+(A 1 1:ℝ)*x 2] + +lemma torusAngular_normalizedLift (h : Fin 2 → ℤ) + (A : Matrix (Fin 2) (Fin 2) ℤ) (x : Coord3) : + torusAngular h (angularNormalizedLift A x)=torusAngular (h ᵥ* A) x := by + simp only [torusAngular,_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.proj_apply,smul_eq_mul] + rw [angular_vecMul_zero,angular_vecMul_one] + dsimp [angularNormalizedLift] + ring + +theorem flatPhaseMode_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (h : Fin 2 → ℤ) (phase : ℝ) (x : Coord3) : + flatPhaseMode s h phase (angularNormalizedLift A x)= + flatPhaseMode (normalizedAngularTensor s A) (h ᵥ* A) phase x := by + unfold flatPhaseMode + rw [torusAngular_normalizedLift,torusRate_angular_conjugacy s hA] + congr 2 + dsimp [angularNormalizedLift] + ring + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +def angularInverseMatrix (A : Matrix (Fin 2) (Fin 2) ℤ) : Matrix (Fin 2) (Fin 2) ℤ := + !![A 1 1,-A 0 1;-A 1 0,A 0 0] + +lemma angular_mul_inverse {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) : + A*angularInverseMatrix A=1 := by + have hd : A 0 0*A 1 1-A 0 1*A 1 0=1 := by simpa only [det_fin_two] using hA + ext i j + fin_cases i <;> fin_cases j <;> + simp [Matrix.mul_apply,Fin.sum_univ_two,angularInverseMatrix] <;> nlinarith + +lemma angular_inverse_mul {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) : + angularInverseMatrix A*A=1 := by + have hd : A 0 0*A 1 1-A 0 1*A 1 0=1 := by simpa only [det_fin_two] using hA + ext i j + fin_cases i <;> fin_cases j <;> + simp [Matrix.mul_apply,Fin.sum_univ_two,angularInverseMatrix] <;> nlinarith + +def angularFrequencyEquiv (A : Matrix (Fin 2) (Fin 2) ℤ) (hA : A.det=1) : + (Fin 2 → ℤ) ≃ (Fin 2 → ℤ) where + toFun h := h ᵥ* A + invFun h := h ᵥ* angularInverseMatrix A + left_inv h := by + change (h ᵥ* A) ᵥ* angularInverseMatrix A=h + rw [vecMul_vecMul,angular_mul_inverse hA,vecMul_one] + right_inv h := by + change (h ᵥ* angularInverseMatrix A) ᵥ* A=h + rw [vecMul_vecMul,angular_inverse_mul hA,vecMul_one] + +@[simp] lemma angularFrequencyEquiv_apply (A : Matrix (Fin 2) (Fin 2) ℤ) + (hA : A.det=1) (h : Fin 2 → ℤ) : angularFrequencyEquiv A hA h=h ᵥ* A := rfl + +@[simp] lemma angularFrequencyEquiv_symm_vecMul (A : Matrix (Fin 2) (Fin 2) ℤ) + (hA : A.det=1) (h : Fin 2 → ℤ) : + (angularFrequencyEquiv A hA).symm (h ᵥ* A)=h := + (angularFrequencyEquiv A hA).symm_apply_apply h + +theorem flatFourier_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (a phase : (Fin 2 → ℤ) → ℝ) (x : Coord3) : + flatFourier s a phase (angularNormalizedLift A x)= + flatFourier (normalizedAngularTensor s A) + (a ∘ (angularFrequencyEquiv A hA).symm) + (phase ∘ (angularFrequencyEquiv A hA).symm) x := by + unfold flatFourier + conv_rhs => rw [←(angularFrequencyEquiv A hA).tsum_eq] + apply tsum_congr + intro h + simp only [Function.comp_apply,angularFrequencyEquiv_apply,angularFrequencyEquiv_symm_vecMul] + rw [flatPhaseMode_angular_conjugacy s hA] + +lemma normalizedFourierCoefficients_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (a : (Fin 2 → ℤ) → ℝ) (lam T : ℝ) (h : Fin 2 → ℤ) : + normalizedFourierCoefficients (normalizedAngularTensor s A) + (Real.sqrt (angularNormalization A)*lam) T + (a ∘ (angularFrequencyEquiv A hA).symm) (angularFrequencyEquiv A hA h)= + normalizedFourierCoefficients s lam (Real.sqrt (angularNormalization A)*T) a h := by + simp only [normalizedFourierCoefficients,Function.comp_apply, + angularFrequencyEquiv_apply,angularFrequencyEquiv_symm_vecMul,torusRate_angular_conjugacy s hA] + congr 2 + ring + +lemma angular_conjugacy_gap (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + {a : (Fin 2 → ℤ) → ℝ} {lam gap : ℝ} + (hgap : 0 sourceAngularCollar (t+z.1) z.2) := by + simp_rw [sourceAngular_affine] + exact ((continuous_sourceAngularCollar t).comp continuous_snd).add + (continuous_fst.smul (continuous_sourceAngularVelocity.comp continuous_snd)) + +lemma continuous_parametric_interval {X : Type*} [TopologicalSpace X] + [FirstCountableTopology X] [LocallyCompactSpace X] {f : X → ℝ → ℝ} + (hf : Continuous (Function.uncurry f)) {a b : ℝ} (hab : a≤b) : + Continuous (fun x => ∫ t in a..b,f x t) := by + have hh := continuous_parametric_integral_of_continuous (μ:=volume) hf (s:=Icc a b) isCompact_Icc + simpa only [intervalIntegral.integral_of_le hab,integral_Icc_eq_integral_Ioc] using hh + +lemma continuous_torus_interval_swap {f : ℝ → UnitAddTorus (Fin 2) → ℝ} + (hf : Continuous (Function.uncurry f)) (a b : ℝ) : + (∫ t in a..b,∫ x,f t x)=∫ x,∫ t in a..b,f t x := by + have hi : IntegrableOn (Function.uncurry f) (uIoc a b ×ˢ (univ : Set (UnitAddTorus (Fin 2)))) := + (hf.continuousOn.integrableOn_compact (isCompact_uIcc.prod isCompact_univ)).mono_set + (prod_mono uIoc_subset_uIcc Subset.rfl) + apply intervalIntegral_integral_swap + simpa only [IntegrableOn,Measure.volume_eq_prod,←Measure.prod_restrict,Measure.restrict_univ] using hi + +def sourcePhysicalEnergy (f : (Fin 3 → ℝ) → ℝ) (y : Fin 3 → ℝ) : ℝ := + 64*‖fderiv ℝ f y‖^2+2*(f y)^2 + +lemma sourcePhysicalEnergy_nonneg (f : (Fin 3 → ℝ) → ℝ) (y : Fin 3 → ℝ) : + 0≤ sourcePhysicalEnergy f y := by unfold sourcePhysicalEnergy; positivity + +lemma continuous_sourcePhysicalEnergy {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : Continuous (sourcePhysicalEnergy f) := + (continuous_const.mul ((hf.continuous_fderiv (by simp)).norm.pow 2)).add + (continuous_const.mul (hf.continuous.pow 2)) + +lemma integrate_torus_interval_bound {F : UnitAddTorus (Fin 2) → ℝ} + {G : ℝ → UnitAddTorus (Fin 2) → ℝ} (hF : Continuous F) + (hG : Continuous (Function.uncurry G)) {a b C : ℝ} (hab : a≤b) + (hb : ∀ x,F x≤C*(∫ t in a..b,G t x)) : + (∫ x,F x)≤C*(∫ t in a..b,∫ x,G t x) := by + have hs : Continuous (Function.uncurry (fun x t => G t x)) := hG.comp continuous_swap + have ht : Continuous (fun x => ∫ t in a..b,G t x) := continuous_parametric_interval hs hab + have hi : Integrable (fun x => C*(∫ t in a..b,G t x)) := + (continuous_const.mul ht).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _) + rw [continuous_torus_interval_swap hG,←integral_const_mul] + exact integral_mono (hF.integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _)) hi hb + +theorem sourceAngular_integrated_trace {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t : ℝ) {η : ℝ} (hη : 0<η) : + (∫ x : UnitAddTorus (Fin 2),(f (sourceAngularCollar t x))^2)≤ + (1+1/η)*(∫ a in (0:ℝ)..η,∫ x : UnitAddTorus (Fin 2), + sourcePhysicalEnergy f (sourceAngularCollar (t+a) x)) := by + apply integrate_torus_interval_bound (F:=fun x => (f (sourceAngularCollar t x))^2) + (G:=fun a x => sourcePhysicalEnergy f (sourceAngularCollar (t+a) x)) + ((hf.continuous.comp (continuous_sourceAngularCollar t)).pow 2) + ((continuous_sourcePhysicalEnergy hf).comp (continuous_sourceAngular t)) hη.le + intro x + exact sourceAngular_pointwise_trace hf t hη x + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularIntegration.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularIntegration.lean new file mode 100644 index 0000000000000000000000000000000000000000..08df32b5212b2993d1b948b8cfeedc4feb8e6184 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularIntegration.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AngularNormalTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +theorem integral_circle_faces {w : ℝ} (hw : 0 F (a:UnitAddCircle)) := + hF.comp (AddCircle.continuous_mk' 1) + have hh (j : Fin 4) : + (∫ b in (-1:ℝ)..1,F ((faceRayAngle w j b:ℝ):UnitAddCircle)*faceRayDensity w j b)= + ∫ a in faceRayAngle w j (-1)..faceRayAngle w j 1,F (a:UnitAddCircle) := by + exact intervalIntegral.integral_comp_mul_deriv + (fun b _ => hasDerivAt_faceRayAngle w j b) (continuous_faceRayDensity w j).continuousOn hc + simp_rw [hh] + have he := faceRayAngle_endpoints hw + rw [AddCircle.integral_haarAddCircle] + simp only [inv_one,one_smul] + rw [←AddCircle.intervalIntegral_preimage 1 (faceRayAngle w 0 (-1))] + rw [Fin.sum_univ_four,←he.2] + have h0 := he.1 (0:Fin 3) + have h1 := he.1 (1:Fin 3) + have h2 := he.1 (2:Fin 3) + change faceRayAngle w 0 1=faceRayAngle w 1 (-1) at h0 + change faceRayAngle w 1 1=faceRayAngle w 2 (-1) at h1 + change faceRayAngle w 2 1=faceRayAngle w 3 (-1) at h2 + rw [←h0,←h1,←h2] + rw [intervalIntegral.integral_add_adjacent_intervals (hc.intervalIntegrable _ _) (hc.intervalIntegrable _ _), + intervalIntegral.integral_add_adjacent_intervals (hc.intervalIntegrable _ _) (hc.intervalIntegrable _ _), + intervalIntegral.integral_add_adjacent_intervals (hc.intervalIntegrable _ _) (hc.intervalIntegrable _ _)] + +theorem integral_rectangularRay_le {w : ℝ} (hw : 0 f (rectangularRay w θ)) hw (hf.comp (continuous_rectangularRay hw hw'))] + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro j _ + rw [←intervalIntegral.integral_const_mul] + apply intervalIntegral.integral_mono_on (by norm_num) + · have ha : Continuous (faceRayAngle w j) := continuous_iff_continuousAt.mpr + (fun b => (hasDerivAt_faceRayAngle w j b).continuousAt) + exact ((hf.comp (continuous_rectangularRay hw hw')).comp + ((AddCircle.continuous_mk' 1).comp ha)).mul + (continuous_faceRayDensity w j) |>.intervalIntegrable _ _ + · have hc : Continuous (fun b : ℝ => ![w*squareFace j b 0,squareFace j b 1]) := by + apply continuous_pi + intro i + fin_cases i + · unfold squareFace; fun_prop + · unfold squareFace; fun_prop + exact (continuous_const.mul (hf.comp hc)).intervalIntegrable _ _ + · intro b hb + rw [faceRayAngle_image hw j (abs_le.mpr hb)] + exact (mul_le_mul_of_nonneg_left (faceRayDensity_bounds hw hw' j b).2 + (hn ![w*squareFace j b 0,squareFace j b 1])).trans_eq (mul_comm _ _) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularInverseTensor.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularInverseTensor.lean new file mode 100644 index 0000000000000000000000000000000000000000..57d808f32eb53691b6aa369fd55146324158dc72 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularInverseTensor.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.GeneralModeFiniteEndNormal + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma angularLiftMatrix_background {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (s : Fin 3 → ℝ) : + angularLiftMatrix A*flatBackgroundTensor (normalizedAngularTensor s A)*(angularLiftMatrix A)ᵀ= + angularNormalization A • flatBackgroundTensor s := by + have hd := congrArg (fun z : ℝ => z^2) (real_angular_det_one hA) + norm_num only [one_pow] at hd + have hm := Real.sq_sqrt (angularNormalization_pos A).le + ext i j + fin_cases i <;> fin_cases j <;> + simp [Matrix.mul_apply,Fin.sum_univ_three,Matrix.transpose_apply, + angularLiftMatrix,flatBackgroundTensor,normalizedAngularTensor] + · nlinarith [hm] + · linear_combination angularNormalization A * s 0 * hd + · linear_combination angularNormalization A * s 1 * hd + · linear_combination angularNormalization A * s 1 * hd + · linear_combination angularNormalization A * s 2 * hd + +lemma angularInverseLift_shift (A : Matrix (Fin 2) (Fin 2) ℤ) + (T : ℝ) (n : Fin 2 → ℤ) (x : Coord3) : + angularInverseLift A (x+angularShift T n)=angularInverseLift A x+ + angularShift T ![A 1 1*n 0-A 0 1*n 1,-A 1 0*n 0+A 0 0*n 1] := by + ext i + fin_cases i <;> simp [angularInverseLift,angularShift] <;> ring + +lemma AngularPeriodic.angularInverseLift {E : Type*} {T : ℝ} {f : Coord3 → E} + (hf : AngularPeriodic T f) (A : Matrix (Fin 2) (Fin 2) ℤ) : + AngularPeriodic T (f ∘ angularInverseLift A) := by + intro n x + simp only [Function.comp_apply,angularInverseLift_shift] + exact hf _ _ + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix Real +open scoped Matrix.Norms.Elementwise + +def undoAngularPoint (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) + (d : ℝ) (x : Coord3) : Coord3 := + angularInverseLift A (x-![d,0,0])-![0,θ 0,θ 1] + +lemma undoAngularPoint_zero (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) + (d : ℝ) (x : Coord3) : + undoAngularPoint A θ d x 0=(x 0-d)/sqrt (angularNormalization A) := by + simp [undoAngularPoint,angularInverseLift] + +lemma undoAngularPoint_forward {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (θ : Fin 2 → ℝ) (d : ℝ) (x : Coord3) : + angularNormalizedLift A (angularRealTranslation θ (undoAngularPoint A θ d x))=x-![d,0,0] := by + have he : angularRealTranslation θ (undoAngularPoint A θ d x)= + angularInverseLift A (x-![d,0,0]) := by + ext i + fin_cases i <;> simp [angularRealTranslation,undoAngularPoint] + rw [he,angularNormalizedLift_inverse hA] + +lemma undoAngularPoint_contDiff {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (θ : Fin 2 → ℝ) (d : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (undoAngularPoint A θ d) := + (((angularNormalizedEquiv A hA).symm.contDiff).comp + (contDiff_id.sub contDiff_const)).sub contDiff_const + +lemma AngularPeriodic.undoAngularPoint {F : Type*} {T : ℝ} {f : Coord3 → F} + (hf : AngularPeriodic T f) (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) (d : ℝ) : + AngularPeriodic T (f ∘ undoAngularPoint A θ d) := by + intro n x + simp only [Function.comp_apply,ScalarConductivity.undoAngularPoint] + rw [show x+angularShift T n-![d,0,0]=(x-![d,0,0])+angularShift T n by abel, + angularInverseLift_shift] + rw [show ScalarConductivity.angularInverseLift A (x-![d,0,0])+ + angularShift T ![A 1 1*n 0-A 0 1*n 1,-A 1 0*n 0+A 0 0*n 1]-![0,θ 0,θ 1]= + (ScalarConductivity.angularInverseLift A (x-![d,0,0])-![0,θ 0,θ 1])+ + angularShift T ![A 1 1*n 0-A 0 1*n 1,-A 1 0*n 0+A 0 0*n 1] by abel] + exact hf _ _ + +def undoAngularValue (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) + (d lam : ℝ) (v : Coord3 → Fin 2 → ℝ) (x : Coord3) : Fin 2 → ℝ := + ![sqrt (angularNormalization A)*v (undoAngularPoint A θ d x) 0+d, + exp (-lam*d)*v (undoAngularPoint A θ d x) 1] + +def undoAngularTensor (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) + (d : ℝ) (E : Coord3 → Mat3) (x : Coord3) : Mat3 := + (angularNormalization A)⁻¹ • + (angularLiftMatrix A*E (undoAngularPoint A θ d x)*(angularLiftMatrix A)ᵀ) + +lemma undoAngularValue_matching {s : Fin 3 → ℝ} {A : Matrix (Fin 2) (Fin 2) ℤ} + (hA : A.det=1) (θ : Fin 2 → ℝ) (d : ℝ) (h₀ : Fin 2 → ℤ) + (a b pa pb : (Fin 2 → ℤ) → ℝ) {v : Coord3 → Fin 2 → ℝ} + (hv : ∀ y,y 0∈Icc 0 (1/2) → v y= + ![y 0+flatFourier s (normalizedFourierCoefficients s 0 d a) pa + (angularNormalizedLift A (angularRealTranslation θ y))/sqrt (angularNormalization A), + flatPhaseMode s h₀ (pb h₀) (angularNormalizedLift A (angularRealTranslation θ y))+ + flatFourier s (normalizedFourierCoefficients s (torusRate s h₀) d b) pb + (angularNormalizedLift A (angularRealTranslation θ y))]) + {x : Coord3} (hx : (x 0-d)/sqrt (angularNormalization A)∈Icc 0 (1/2)) : + undoAngularValue A θ d (torusRate s h₀) v x= + ![x 0+flatFourier s a pa x,flatPhaseMode s h₀ (pb h₀) x+flatFourier s b pb x] := by + have hm : sqrt (angularNormalization A)≠0 := (sqrt_pos.mpr (angularNormalization_pos A)).ne' + have hxy : (x-![d,0,0])+![d,0,0]=x := sub_add_cancel _ _ + have he : exp (-torusRate s h₀*d)*exp (torusRate s h₀*d)=1 := by + rw [←exp_add,show -torusRate s h₀*d+torusRate s h₀*d=0 by ring,exp_zero] + have hmode := flatPhaseMode_translation s h₀ (pb h₀) d (x-![d,0,0]) + rw [hxy] at hmode + unfold undoAngularValue + rw [hv _ (by simpa only [undoAngularPoint_zero] using hx),undoAngularPoint_forward hA, + flatFourier_normalized_translation,flatFourier_normalized_translation,hxy] + ext j + fin_cases j + · change sqrt (angularNormalization A)*(undoAngularPoint A θ d x 0+ + exp (0*d)*flatFourier s a pa x/sqrt (angularNormalization A))+d=x 0+flatFourier s a pa x + rw [undoAngularPoint_zero] + simp only [zero_mul,exp_zero,one_mul] + field_simp [hm] + ring + · change exp (-torusRate s h₀*d)*(flatPhaseMode s h₀ (pb h₀) (x-![d,0,0])+ + exp (torusRate s h₀*d)*flatFourier s b pb x)=_ + rw [mul_add,←mul_assoc,he,one_mul,←hmode] + rfl + +lemma undoAngularTensor_matching {s : Fin 3 → ℝ} {A : Matrix (Fin 2) (Fin 2) ℤ} + (hA : A.det=1) (θ : Fin 2 → ℝ) (d : ℝ) {E : Coord3 → Mat3} + (hE : ∀ y,y 0∈Icc 0 (1/2) → E y=flatBackgroundTensor (normalizedAngularTensor s A)) + {x : Coord3} (hx : (x 0-d)/sqrt (angularNormalization A)∈Icc 0 (1/2)) : + undoAngularTensor A θ d E x=flatBackgroundTensor s := by + rw [undoAngularTensor,hE _ (by simpa only [undoAngularPoint_zero] using hx), + angularLiftMatrix_background hA,smul_smul,inv_mul_cancel₀ (angularNormalization_pos A).ne',one_smul] + +lemma undoAngularValue_terminal (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) + (d lam T : ℝ) {v : Coord3 → Fin 2 → ℝ} (hv : ∀ y,T≤y 0 → v y=![y 0,0]) + {x : Coord3} (hx : d+sqrt (angularNormalization A)*T≤x 0) : + undoAngularValue A θ d lam v x=![x 0,0] := by + have hm : 0 ∫ z in (0:ℝ)..T,f ![t,y,z]) := by + simp_rw [intervalIntegral.integral_of_le hT,←integral_Icc_eq_integral_Ioc] + apply continuous_parametric_integral_of_continuous _ isCompact_Icc + exact hf.comp (by fun_prop) + +lemma integral_coord3_iterated {f : Coord3 → ℝ} (hf : Integrable f) : + (∫ x,f x)=∫ t,∫ y,∫ z,f ![t,y,z] := by + have hi : Integrable (fun x : ℝ×(ℝ×ℝ) => f (threeArrow.symm x)) := + (threeArrow_volume.symm.integrable_comp hf.aestronglyMeasurable).mpr hf + rw [←threeArrow_volume.symm.integral_comp' f] + change (∫ x,f (threeArrow.symm x) ∂volume.prod volume)=_ + rw [integral_prod _ hi] + apply integral_congr_ae + filter_upwards [hi.prod_right_ae] with t ht + change (∫ x,f (threeArrow.symm (t,x)) ∂volume.prod volume)=_ + rw [integral_prod _ ht] + simp only [threeArrow_symm_apply] + +theorem angularCutoff_integral {T a b : ℝ} (hT : 0 angularCutoff T x*f x) := + ((angularCutoff_smooth T).continuous.mul hf).integrable_of_hasCompactSupport + (angularCutoff_compact hT hs) + rw [integral_coord3_iterated hi] + apply integral_congr_ae + apply Filter.Eventually.of_forall + intro t + have hz (y : ℝ) : + (∫ z,angularCutoff T ![t,y,z]*f ![t,y,z])= + periodCutoff T y*(∫ z in (0:ℝ)..T,f ![t,y,z]) := by + change (∫ z,periodCutoff T y*periodCutoff T z*f ![t,y,z])=_ + simp_rw [mul_assoc] + rw [integral_const_mul] + congr 1 + exact periodCutoff_integral hT (hf.comp (by fun_prop)) (hp.coordinate_two t y) + simp_rw [hz] + apply periodCutoff_integral hT (continuous_angular_integral hT.le hf t) + intro y + apply intervalIntegral.integral_congr + intro z _ + exact hp.coordinate_one t z y + +def periodicSourceMoment (T : ℝ) (u : Coord3 → Fin 2 → ℝ) (r : PhysicalSourcePair) : Coord3 := + ![∫ t,∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,r 0 ![t,y,z], + ∫ t,∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,r 1 ![t,y,z], + ∫ t,∫ y in (0:ℝ)..T,∫ z in (0:ℝ)..T,u ![t,y,z] 1*r 0 ![t,y,z]-u ![t,y,z] 0*r 1 ![t,y,z]] + +theorem physicalSourceMoment_angularCutoff {T a b : ℝ} (hT : 0 angularCutoff T x*r j x)=periodicSourceMoment T u r := by + have ht : Continuous (fun x => u x 1*r 0 x-u x 0*r 1 x) := by fun_prop + have htp : AngularPeriodic T (fun x => u x 1*r 0 x-u x 0*r 1 x) := by + intro n x + dsimp only + rw [hur n x,hrp 0 n x,hrp 1 n x] + have hts : tsupport (fun x => u x 1*r 0 x-u x 0*r 1 x)⊆{x | x 0∈Icc a b} := + (tsupport_sub _ _).trans (union_subset + ((tsupport_mul_subset_right).trans (hrs 0)) ((tsupport_mul_subset_right).trans (hrs 1))) + ext i + fin_cases i + · exact angularCutoff_integral hT (hr 0) (hrp 0) (hrs 0) + · exact angularCutoff_integral hT (hr 1) (hrp 1) (hrs 1) + · change (∫ x,u x 1*(angularCutoff T x*r 0 x)-u x 0*(angularCutoff T x*r 1 x))=_ + have he : (fun x => u x 1*(angularCutoff T x*r 0 x)-u x 0*(angularCutoff T x*r 1 x))= + (fun x => angularCutoff T x*(u x 1*r 0 x-u x 0*r 1 x)) := by funext x; ring + rw [he] + exact angularCutoff_integral hT ht htp hts + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +omit [NormedSpace ℝ E] in +theorem angularPeriodize_uniform_bound {T : ℝ} (hT : 0 -(N:ℤ)) (fun _ => (N:ℤ)) + have hs0 : (0 : Fin 2 → ℤ)∈s := by + simp only [s,Finset.mem_Icc] + constructor <;> intro i <;> simp + refine ⟨s.card,Finset.card_pos.mpr ⟨0,hs0⟩,?_⟩ + intro f C hC hf hbound x + by_cases hn : ∃ n : Fin 2 → ℤ,f (x+angularShift T n)≠0 + · obtain ⟨n0,hn0⟩ := hn + let e : (Fin 2 → ℤ) ↪ (Fin 2 → ℤ) := (Equiv.addRight n0).toEmbedding + have hsub : Function.support (fun n => f (x+angularShift T n))⊆↑(s.map e) := by + intro n hn + have hdiff : angularShift T (n-n0)=(x+angularShift T n)-(x+angularShift T n0) := by + have ha := angularShift_add T (n-n0) n0 + rw [sub_add_cancel] at ha + rw [ha] + abel + have hnorm : ‖angularShift T (n-n0)‖≤2*R := by + rw [hdiff] + exact (norm_sub_le _ _).trans (by linarith [hf _ hn,hf _ hn0]) + have hi (i : Fin 2) : |((n-n0) i:ℝ)|<(N:ℝ) := by + have hh := (norm_le_pi_norm (angularShift T (n-n0)) i.succ).trans hnorm + rw [angularShift_succ,Real.norm_eq_abs,abs_mul,abs_of_pos hT] at hh + exact ((le_div_iff₀ hT).mpr (by simpa only [mul_comm] using hh)).trans_lt hN + have hin : n-n0∈s := by + change _∈Finset.Icc _ _ + rw [Finset.mem_Icc] + constructor <;> intro i + · exact_mod_cast (abs_lt.mp (hi i)).1.le + · exact_mod_cast (abs_lt.mp (hi i)).2.le + exact Finset.mem_map.mpr ⟨n-n0,hin,by simp [e]⟩ + rw [angularPeriodize,finsum_eq_sum_of_support_subset _ hsub] + calc + _ ≤ ∑ n∈s.map e,‖f (x+angularShift T n)‖ := norm_sum_le _ _ + _ ≤ ∑ _n∈s.map e,C := Finset.sum_le_sum (fun n _ => hbound _) + _ = s.card*C := by simp + · have hz : (fun n : Fin 2 → ℤ => f (x+angularShift T n))=0 := by + funext n + exact not_ne_iff.mp (fun h => hn ⟨n,h⟩) + rw [angularPeriodize,hz] + have he : finsum (0 : (Fin 2 → ℤ) → E)=0 := finsum_zero + rw [he,norm_zero] + positivity + +omit [NormedSpace ℝ E] in +lemma angularPeriodize_axial_support {T a b : ℝ} {f : Coord3 → E} + (hs : tsupport f⊆{x | x 0∈Icc a b}) : + tsupport (angularPeriodize T f)⊆{x | x 0∈Icc a b} := by + apply closure_minimal _ (isClosed_Icc.preimage (continuous_apply 0)) + intro x hx + by_contra hx0 + apply hx + unfold angularPeriodize + have hz : (fun n : Fin 2 → ℤ => f (x+angularShift T n))=0 := by + funext n + apply image_eq_zero_of_notMem_tsupport + intro h + have hh := hs h + change (x 0+0)∈Icc a b at hh + apply hx0 + change x 0∈Icc a b + simpa only [add_zero] using hh + rw [hz] + exact finsum_zero + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularMeasureExact.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularMeasureExact.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9ffb20b988bcdd9a7590e2fc93b2610103e2f8b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularMeasureExact.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularGraph + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +def faceRayMeasure (w : ℝ) (j : Fin 4) : Measure UnitAddCircle := + Measure.map (fun b : ℝ => ((faceRayAngle w j b:ℝ):UnitAddCircle)) + ((volume.restrict (Ioc (-1:ℝ) 1)).withDensity (fun b => ENNReal.ofReal (faceRayDensity w j b))) + +lemma continuous_faceRayCircle (w : ℝ) (j : Fin 4) : + Continuous (fun b : ℝ => ((faceRayAngle w j b:ℝ):UnitAddCircle)) := + (AddCircle.continuous_mk' 1).comp + (continuous_iff_continuousAt.mpr fun b => (hasDerivAt_faceRayAngle w j b).continuousAt) + +instance finite_faceRayMeasure (w : ℝ) (j : Fin 4) : IsFiniteMeasure (faceRayMeasure w j) := by + have h : IntegrableOn (faceRayDensity w j) (Icc (-1:ℝ) 1) volume := + (continuous_faceRayDensity w j).continuousOn.integrableOn_compact + (isCompact_Icc (a:=(-1:ℝ)) (b:=1)) + have := isFiniteMeasure_withDensity_ofReal (h.mono_set Ioc_subset_Icc_self).hasFiniteIntegral + unfold faceRayMeasure + infer_instance + +lemma integral_faceRayMeasure {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {w : ℝ} (hw : 0 ENNReal.ofReal_lt_top)] + congr 1 + funext b + rw [ENNReal.toReal_ofReal (faceRayDensity_pos' hw j b).le] + +theorem haar_circle_eq_sum_faceRayMeasure {w : ℝ} (hw : 0 F θ) hw F.continuous] + apply Finset.sum_congr rfl + intro j _ + rw [integral_faceRayMeasure (F := fun θ => F θ) hw j F.continuous.aestronglyMeasurable] + rw [intervalIntegral.integral_of_le (by norm_num : (-1:ℝ)≤1)] + apply integral_congr_ae + filter_upwards [] with b + simp only [smul_eq_mul,mul_comm] + · intro j _ + exact F.integrable + +theorem integral_circle_faces_integrable {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] {w : ℝ} (hw : 0 Measure.zero_le _) (Finset.mem_univ j)) + rw [haar_circle_eq_sum_faceRayMeasure hw,integral_finsetSum_measure (fun j _ => hint j)] + apply Finset.sum_congr rfl + intro j _ + exact integral_faceRayMeasure hw j (hint j).aestronglyMeasurable + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularNormalTrace.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularNormalTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..831284522cf682d6ba2dd79314fefd424537bea8 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularNormalTrace.lean @@ -0,0 +1,212 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.IntervalTraceEnergy +import OAI.Analysis.Conductivity.Sources.AngularTrace + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +def sourceAngularVelocity (x : UnitAddTorus (Fin 2)) : Fin 3 → ℝ := + let z := sourceRayCoordinates x + ![-sourceLength*z 2*z 0,-z 2*z 1,-z 3] + +lemma sourceAngular_affine (t a : ℝ) (x : UnitAddTorus (Fin 2)) : + sourceAngularCollar (t+a) x=sourceAngularCollar t x+a • sourceAngularVelocity x := by + ext i + fin_cases i <;> simp [sourceAngularCollar,sourceAngularPolynomial,sourceAngularVelocity] <;> ring + +lemma sourceAngularVelocity_norm (x : UnitAddTorus (Fin 2)) : ‖sourceAngularVelocity x‖≤8 := by + have hz := sourceRayCoordinates_mem x + have hb (i : Fin 4) : |sourceRayCoordinates x i|≤2 := abs_le.mpr ⟨hz.1 i,hz.2 i⟩ + apply (pi_norm_le_iff_of_nonneg (by norm_num : (0:ℝ)≤8)).mpr + intro i + fin_cases i <;> simp [sourceAngularVelocity,Real.norm_eq_abs] + · have hh := mul_le_mul (hb 2) (hb 0) (abs_nonneg _) (by norm_num : (0:ℝ)≤2) + norm_num [sourceLength] at * + nlinarith [abs_nonneg (sourceRayCoordinates x 2*sourceRayCoordinates x 0)] + · have hh := mul_le_mul (hb 2) (hb 1) (abs_nonneg _) (by norm_num : (0:ℝ)≤2) + linarith + · linarith [hb 3] + +lemma continuous_sourceAngularVelocity : Continuous sourceAngularVelocity := by + apply continuous_pi + intro i + fin_cases i <;> simp only [sourceAngularVelocity] + · exact (continuous_const.mul ((continuous_apply (2 : Fin 4)).comp continuous_sourceRayCoordinates)).mul + ((continuous_apply (0 : Fin 4)).comp continuous_sourceRayCoordinates) + · exact (((continuous_apply (2 : Fin 4)).comp continuous_sourceRayCoordinates).neg).mul + ((continuous_apply (1 : Fin 4)).comp continuous_sourceRayCoordinates) + · exact ((continuous_apply (3 : Fin 4)).comp continuous_sourceRayCoordinates).neg + +lemma sourceAngular_normal_deriv {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t a : ℝ) (x : UnitAddTorus (Fin 2)) : + deriv (fun s => f (sourceAngularCollar (t+s) x)) a= + fderiv ℝ f (sourceAngularCollar (t+a) x) (sourceAngularVelocity x) := by + have hd := (((hf.differentiable (by simp) (sourceAngularCollar t x+a • sourceAngularVelocity x)).hasFDerivAt).comp_hasDerivAt a + (((hasDerivAt_id a).smul_const (sourceAngularVelocity x)).const_add (sourceAngularCollar t x))).deriv + change deriv (fun s : ℝ => f (sourceAngularCollar t x+s • sourceAngularVelocity x)) a=_ at hd + simpa only [sourceAngular_affine,one_smul] using hd + +theorem sourceAngular_pointwise_trace {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t : ℝ) {η : ℝ} (hη : 0<η) + (x : UnitAddTorus (Fin 2)) : + (f (sourceAngularCollar t x))^2≤(1+1/η)*(∫ a in (0:ℝ)..η, + 64*‖fderiv ℝ f (sourceAngularCollar (t+a) x)‖^2+ + 2*(f (sourceAngularCollar (t+a) x))^2) := by + have hq : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun a : ℝ => f (sourceAngularCollar (t+a) x)) := by + simp_rw [sourceAngular_affine] + exact hf.comp (contDiff_const.add (contDiff_id.smul contDiff_const)) + have hh := fourier_mode_trace_energy hq hη (m:=1) (by norm_num) + simp only [add_zero,one_pow,one_mul] at hh + apply hh.trans + apply mul_le_mul_of_nonneg_left _ (by positivity) + apply intervalIntegral.integral_mono_on hη.le + · exact (((hq.continuous_deriv (by simp)).pow 2).add + (continuous_const.mul (hq.continuous.pow 2))).intervalIntegrable _ _ + · have hc : Continuous (fun a : ℝ => sourceAngularCollar (t+a) x) := by + simp_rw [sourceAngular_affine]; fun_prop + exact ((continuous_const.mul ((hf.continuous_fderiv (by simp)).comp hc |>.norm.pow 2)).add + (continuous_const.mul (hq.continuous.pow 2))).intervalIntegrable _ _ + · intro a _ + rw [sourceAngular_normal_deriv hf] + have hb := (fderiv ℝ f (sourceAngularCollar (t+a) x)).le_opNorm (sourceAngularVelocity x) + have hb' := hb.trans (mul_le_mul_of_nonneg_left (sourceAngularVelocity_norm x) (norm_nonneg _)) + have hs := mul_self_le_mul_self (norm_nonneg _) hb' + simp only [Real.norm_eq_abs,←pow_two,sq_abs] at hs + nlinarith + +lemma rayDirection_coe_angle (a : ℝ) : + rayDirection ((a/(2*Real.pi):ℝ):UnitAddCircle)=![Real.cos a,Real.sin a] := by + have he : fourier 1 ((a/(2*Real.pi):ℝ):UnitAddCircle)=Complex.exp ((a:ℂ)*Complex.I) := by + rw [fourier_coe_apply] + congr 1 + push_cast + have hp : (Real.pi:ℂ)≠0 := Complex.ofReal_ne_zero.mpr Real.pi_pos.ne' + field_simp + ext i + fin_cases i + · simp [rayDirection,he] + · simp [rayDirection,he] + +lemma rectangularRay_of_direction {w k : ℝ} (hw : 0 simp [squareFace,squareFaceBase,squareFaceDirection, + Real.cos_arctan,Real.sin_arctan] <;> field_simp + · apply rectangularRay_of_direction hw (k:=(Real.sqrt (1+(w*b)^2))⁻¹) + (inv_pos.mpr (hp _)) _ 1 hb + dsimp only [faceRayAngle] + rw [rayDirection_coe_angle] + ext i; fin_cases i <;> simp [squareFace,squareFaceBase,squareFaceDirection, + Real.cos_add,Real.sin_add,Real.cos_arctan,Real.sin_arctan]; ring + · apply rectangularRay_of_direction hw (k:=(w*Real.sqrt (1+(b/w)^2))⁻¹) + (inv_pos.mpr (mul_pos hw (hp _))) _ 2 hb + dsimp only [faceRayAngle] + rw [rayDirection_coe_angle] + ext i; fin_cases i <;> simp [squareFace,squareFaceBase,squareFaceDirection, + Real.cos_add,Real.sin_add,Real.cos_arctan,Real.sin_arctan] <;> field_simp + · apply rectangularRay_of_direction hw (k:=(Real.sqrt (1+(w*b)^2))⁻¹) + (inv_pos.mpr (hp _)) _ 3 hb + dsimp only [faceRayAngle] + rw [rayDirection_coe_angle] + have he : 3*Real.pi/2=Real.pi+Real.pi/2 := by ring + rw [he] + ext i; fin_cases i <;> simp [squareFace,squareFaceBase,squareFaceDirection, + Real.cos_add,Real.sin_add,Real.cos_arctan,Real.sin_arctan]; ring + +lemma faceRayAngle_endpoints {w : ℝ} (hw : 0 simp [faceRayAngle,one_div,neg_div,Real.arctan_neg,hx] <;> ring + · simp [faceRayAngle,one_div,neg_div,Real.arctan_neg,hx] + field_simp + ring + +def faceRayDensity (w : ℝ) (j : Fin 4) (b : ℝ) : ℝ := + ![(1/(1+(b/w)^2))/w,w/(1+(w*b)^2), + (1/(1+(b/w)^2))/w,w/(1+(w*b)^2)] j/(2*Real.pi) + +lemma hasDerivAt_faceRayAngle (w : ℝ) (j : Fin 4) (b : ℝ) : + HasDerivAt (faceRayAngle w j) (faceRayDensity w j b) b := by + have h0 := ((Real.hasDerivAt_arctan (b/w)).comp b ((hasDerivAt_id b).div_const w)).div_const (2*Real.pi) + have h1 := (((Real.hasDerivAt_arctan (w*b)).comp b ((hasDerivAt_id b).const_mul w)).const_add (Real.pi/2)).div_const (2*Real.pi) + have h2 := (((Real.hasDerivAt_arctan (b/w)).comp b ((hasDerivAt_id b).div_const w)).const_add Real.pi).div_const (2*Real.pi) + have h3 := (((Real.hasDerivAt_arctan (w*b)).comp b ((hasDerivAt_id b).const_mul w)).const_add (3*Real.pi/2)).div_const (2*Real.pi) + unfold faceRayAngle faceRayDensity + fin_cases j + · simpa [faceRayAngle,faceRayDensity,div_eq_mul_inv,mul_assoc,mul_comm,mul_left_comm] using h0 + · simpa [faceRayAngle,faceRayDensity,div_eq_mul_inv,mul_assoc,mul_comm,mul_left_comm] using h1 + · simpa [faceRayAngle,faceRayDensity,div_eq_mul_inv,mul_assoc,mul_comm,mul_left_comm] using h2 + · simpa [faceRayAngle,faceRayDensity,div_eq_mul_inv,mul_assoc,mul_comm,mul_left_comm] using h3 + +lemma continuous_faceRayDensity (w : ℝ) (j : Fin 4) : Continuous (faceRayDensity w j) := by + have h0 : Continuous (fun b : ℝ => (1/(1+(b/w)^2))/w/(2*Real.pi)) := by + have hd : Continuous (fun b : ℝ => 1+(b/w)^2) := by fun_prop + exact ((continuous_const.div hd (fun b => ne_of_gt (by positivity))).div_const w).div_const _ + have h1 : Continuous (fun b : ℝ => (w/(1+(w*b)^2))/(2*Real.pi)) := by + have hd : Continuous (fun b : ℝ => 1+(w*b)^2) := by fun_prop + exact (continuous_const.div hd (fun b => ne_of_gt (by positivity))).div_const _ + fin_cases j + · exact h0 + · exact h1 + · exact h0 + · exact h1 + +lemma faceRayDensity_bounds {w : ℝ} (hw : 0 simp [angularShift] +lemma angularShift_add (T : ℝ) (n m : Fin 2 → ℤ) : + angularShift T (n+m)=angularShift T n+angularShift T m := by + ext i + fin_cases i <;> simp [angularShift,mul_add] +lemma angularShift_succ (T : ℝ) (n : Fin 2 → ℤ) (i : Fin 2) : + angularShift T n i.succ=T*(n i:ℝ) := by fin_cases i <;> rfl + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def angularPeriodize (T : ℝ) (f : Coord3 → E) (x : Coord3) : E := + ∑ᶠ n : Fin 2 → ℤ,f (x+angularShift T n) + +def AngularPeriodic (T : ℝ) (f : Coord3 → E) : Prop := + ∀ n x,f (x+angularShift T n)=f x + +omit [NormedSpace ℝ E] in +lemma angularPeriodize_periodic (T : ℝ) (f : Coord3 → E) : + AngularPeriodic T (angularPeriodize T f) := by + intro n x + unfold angularPeriodize + calc + _ = ∑ᶠ m : Fin 2 → ℤ,f (x+angularShift T (m+n)) := by + congr 1 + funext m + rw [angularShift_add] + congr 1 + abel + _ = _ := finsum_comp_equiv (Equiv.addRight n) (f := fun m => f (x+angularShift T m)) + +omit [NormedSpace ℝ E] in +lemma angular_translates_locallyFinite {T : ℝ} (hT : 0 Function.support (fun x => f (x+angularShift T n))) := by + obtain ⟨R,hR⟩ := hc.isBounded.exists_norm_le + intro x + obtain ⟨N,hN⟩ := exists_nat_gt ((R+‖x‖+1)/T) + refine ⟨Metric.ball x 1,Metric.ball_mem_nhds x zero_lt_one,?_⟩ + apply (Set.finite_Icc (fun _ : Fin 2 => -(N:ℤ)) (fun _ => (N:ℤ))).subset + rintro n ⟨z,hz,hzx⟩ + have hzs : z+angularShift T n∈tsupport f := subset_tsupport f hz + have hzn : ‖z‖<‖x‖+1 := by + have hh : ‖z‖ ≤ ‖x‖+dist z x := by + simpa only [dist_eq_norm,add_comm,norm_sub_rev] using norm_le_norm_add_norm_sub x z + linarith [Metric.mem_ball.mp hzx] + have hsn : ‖angularShift T n‖.trans hN + constructor + · intro i + have hh := (abs_lt.mp (hi i)).1.le + exact_mod_cast hh + · intro i + have hh := (abs_lt.mp (hi i)).2.le + exact_mod_cast hh + +lemma angularPeriodize_smooth {T : ℝ} (hT : 0 (contMDiff_iff_contDiff).mpr + (hf.comp (contDiff_id.add contDiff_const))) (angular_translates_locallyFinite hT hc) + +omit [NormedSpace ℝ E] in +lemma angularPeriodize_local_sum {T : ℝ} (hT : 0 f (x+angularShift T n)) := + (angular_translates_locallyFinite hT hc).point_finite x + +lemma angularPeriodize_fderiv {T : ℝ} (hT : 0 ∑ n∈s,f (y+angularShift T n)) := + hs.mono (fun _ h => h.1) + rw [he.fderiv_eq] + have hn : (fun y => ∑ n∈s,f (y+angularShift T n))=∑ n∈s,(fun y => f (y+angularShift T n)) := by + funext y; simp only [Finset.sum_apply] + rw [hn,fderiv_sum (A:=fun n y => f (y+angularShift T n)) (fun n _ => + (hf.comp (contDiff_id.add (contDiff_const (c:=angularShift T n)))).differentiable (by simp) x)] + simp only [fderiv_comp_add_right] + symm + apply finsum_eq_sum_of_support_subset + intro n hn + by_contra hns + have hz : (fun y => f (y+angularShift T n))=ᶠ[𝓝 x] (fun _ => 0) := + hs.mono (fun _ h => h.2 n hns) + have hh := hz.fderiv_eq (𝕜:=ℝ) + rw [fderiv_comp_add_right] at hh + exact hn (hh.trans (fderiv_const_apply (𝕜:=ℝ) (0:E))) + +lemma AngularPeriodic.fderiv {T : ℝ} {f : Coord3 → E} (hf : AngularPeriodic T f) : + AngularPeriodic T (fderiv ℝ f) := by + intro n x + have he : (fun y => f (y+angularShift T n))=f := funext (hf n) + rw [←fderiv_comp_add_right,he] + +lemma coordinateDivergence_comp_add (F : Coord3 → Coord3) (a x : Coord3) : + coordinateDivergence (fun y => F (y+a)) x=coordinateDivergence F (x+a) := by + unfold coordinateDivergence + apply Finset.sum_congr rfl + intro i _ + rw [fderiv_comp_add_right (f:=fun y => F y i)] + +lemma symmetricSource_congr_nhds {H K : Coord3 → Mat3} {u : Coord3 → Fin 2 → ℝ} + {x : Coord3} (h : H=ᶠ[𝓝 x] K) (j : Fin 2) : + symmetricSource H u j x=symmetricSource K u j x := by + unfold symmetricSource coordinateDivergence + apply Finset.sum_congr rfl + intro i _ + have he : (fun y => (H y*gradientColumns (fderiv ℝ u y)).col j i)=ᶠ[𝓝 x] + (fun y => (K y*gradientColumns (fderiv ℝ u y)).col j i) := by + filter_upwards [h] with y hy + rw [hy] + rw [he.fderiv_eq] + +lemma symmetricSource_finset_sum {ι : Type*} (s : Finset ι) (H : ι → Coord3 → Mat3) + (hH : ∀ i∈s,ContDiff ℝ (↑(⊤:ℕ∞)) (H i)) + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (j : Fin 2) : + symmetricSource (∑ i∈s,H i) u j=∑ i∈s,symmetricSource (H i) u j := by + classical + induction s using Finset.induction with + | empty => simp [symmetricSource_zero] + | @insert a s ha ih => + simp only [Finset.sum_insert ha] + have hsum : ContDiff ℝ (↑(⊤:ℕ∞)) (∑ i∈s,H i) := by + convert (ContDiff.sum (fun i hi => hH i (Finset.mem_insert_of_mem hi))) using 1 + funext y; simp only [Finset.sum_apply] + rw [symmetricSource_add (hH a (Finset.mem_insert_self _ _)) hsum hu j, + ih (fun i hi => hH i (Finset.mem_insert_of_mem hi))] + +lemma symmetricSource_angular_translate {T : ℝ} {u : Coord3 → Fin 2 → ℝ} + (hu : AngularPeriodic T u) (H : Coord3 → Mat3) (j : Fin 2) (n : Fin 2 → ℤ) (x : Coord3) : + symmetricSource (fun y => H (y+angularShift T n)) u j x= + symmetricSource H u j (x+angularShift T n) := by + have he : (fun y => (H (y+angularShift T n)*gradientColumns (fderiv ℝ u y)).col j)= + (fun y => (H (y+angularShift T n)*gradientColumns (fderiv ℝ u (y+angularShift T n))).col j) := by + funext y + rw [hu.fderiv n y] + unfold symmetricSource + rw [he] + exact coordinateDivergence_comp_add (fun y => (H y*gradientColumns (fderiv ℝ u y)).col j) _ _ + +theorem symmetricSource_angularPeriodize {T : ℝ} (hT : 0 H (y+angularShift T n)) := by + filter_upwards [hs] with y hy + simpa only [Finset.sum_apply] using hy.1 + rw [symmetricSource_congr_nhds he j, + symmetricSource_finset_sum s (fun n y => H (y+angularShift T n)) + (fun n _ => hH.comp (contDiff_id.add (contDiff_const (c:=angularShift T n)))) hu j] + simp only [Finset.sum_apply,symmetricSource_angular_translate hp] + symm + apply finsum_eq_sum_of_support_subset + intro n hn + by_contra hns + have hz : (fun y => H (y+angularShift T n))=ᶠ[𝓝 x] (0 : Coord3 → Mat3) := + hs.mono (fun _ h => h.2 n hns) + have hh := symmetricSource_congr_nhds (u:=u) hz j + rw [symmetricSource_angular_translate hp,symmetricSource_zero] at hh + exact hn hh + +lemma angularPeriodize_symmetric {T : ℝ} (hT : 0 hs _) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularPhaseTranslation.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularPhaseTranslation.lean new file mode 100644 index 0000000000000000000000000000000000000000..702396f94aa70d7d9477c3c6345fd5a195756ef1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularPhaseTranslation.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AngularFourierConjugacy + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +def angularRealTranslation (v : Fin 2 → ℝ) (x : Coord3) : Coord3 := + ![x 0,x 1+v 0,x 2+v 1] + +def angularShiftPhase (phase : (Fin 2 → ℤ) → ℝ) (v : Fin 2 → ℝ) + (h : Fin 2 → ℤ) : ℝ := phase h+(h 0:ℝ)*v 0+(h 1:ℝ)*v 1 + +lemma flatPhaseMode_angular_translation (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) + (phase : ℝ) (v : Fin 2 → ℝ) (x : Coord3) : + flatPhaseMode s h phase (angularRealTranslation v x)= + flatPhaseMode s h (phase+(h 0:ℝ)*v 0+(h 1:ℝ)*v 1) x := by + unfold flatPhaseMode + congr 1 + congr 1 + simp only [torusAngular,_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.proj_apply,smul_eq_mul] + dsimp [angularRealTranslation] + ring + +theorem flatFourier_angular_translation (s : Fin 3 → ℝ) + (a phase : (Fin 2 → ℤ) → ℝ) (v : Fin 2 → ℝ) (x : Coord3) : + flatFourier s a phase (angularRealTranslation v x)= + flatFourier s a (angularShiftPhase phase v) x := by + unfold flatFourier + apply tsum_congr + intro h + rw [flatPhaseMode_angular_translation] + rfl + +lemma alignedPhaseTranslation_zero {k : ℤ} (hk : 0 angularIntMap A (x+ + fun i => ((v i/(2*Real.pi):ℝ) : UnitAddCircle))) volume volume := by + obtain ⟨k,A,hk,hA,he⟩ := leading_frequency_SL2_alignment hh + let v : Fin 2 → ℝ := ![0,-phase/(k:ℝ)] + refine ⟨k,A,v,hk,hA,he,normalizedAngularTensor_lower hs hA,?_,?_⟩ + · intro x + rw [flatPhaseMode_angular_conjugacy s hA,he,flatPhaseMode_angular_translation] + rw [show phase+((![0,k] : Fin 2 → ℤ) 0:ℝ)*v 0+ + ((![0,k] : Fin 2 → ℤ) 1:ℝ)*v 1=0 from alignedPhaseTranslation_zero hk phase] + · exact (angularIntMap_measurePreserving hA).comp (measurePreserving_add_right volume _) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AngularSignedTrace.lean b/lean/OAI/Analysis/Conductivity/Fourier/AngularSignedTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..310071f79f634ca6b844c31e2cdf634a03488aa0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AngularSignedTrace.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AngularIntegratedTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus + +lemma sourceAngular_signed_deriv {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t a σ : ℝ) (x : UnitAddTorus (Fin 2)) : + deriv (fun s => f (sourceAngularCollar (t+σ*s) x)) a= + fderiv ℝ f (sourceAngularCollar (t+σ*a) x) (σ • sourceAngularVelocity x) := by + have hd := (((hf.differentiable (by simp) (sourceAngularCollar t x+(σ*a) • sourceAngularVelocity x)).hasFDerivAt).comp_hasDerivAt a + ((((hasDerivAt_id a).const_mul σ).smul_const (sourceAngularVelocity x)).const_add (sourceAngularCollar t x))).deriv + change deriv (fun s : ℝ => f (sourceAngularCollar t x+(σ*s) • sourceAngularVelocity x)) a=_ at hd + simpa only [sourceAngular_affine,mul_one] using hd + +lemma continuous_sourceAngular_signed (t σ : ℝ) : + Continuous (fun z : ℝ×UnitAddTorus (Fin 2) => sourceAngularCollar (t+σ*z.1) z.2) := by + simp_rw [sourceAngular_affine] + exact ((continuous_sourceAngularCollar t).comp continuous_snd).add + ((continuous_const.mul continuous_fst).smul (continuous_sourceAngularVelocity.comp continuous_snd)) + +lemma sourceAngular_signed_pointwise {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t σ : ℝ) (hσ : |σ|≤1) + {η : ℝ} (hη : 0<η) (x : UnitAddTorus (Fin 2)) : + (f (sourceAngularCollar t x))^2≤(1+1/η)*(∫ a in (0:ℝ)..η, + sourcePhysicalEnergy f (sourceAngularCollar (t+σ*a) x)) := by + have hq : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun a : ℝ => f (sourceAngularCollar (t+σ*a) x)) := by + simp_rw [sourceAngular_affine] + exact hf.comp (contDiff_const.add ((contDiff_const.mul contDiff_id).smul contDiff_const)) + have hh := fourier_mode_trace_energy hq hη (m:=1) (by norm_num) + simp only [mul_zero,add_zero,one_pow,one_mul] at hh + apply hh.trans + apply mul_le_mul_of_nonneg_left _ (by positivity) + apply intervalIntegral.integral_mono_on hη.le + · exact (((hq.continuous_deriv (by simp)).pow 2).add + (continuous_const.mul (hq.continuous.pow 2))).intervalIntegrable _ _ + · have hc : Continuous (fun a : ℝ => sourceAngularCollar (t+σ*a) x) := by + simp_rw [sourceAngular_affine]; fun_prop + exact ((continuous_sourcePhysicalEnergy hf).comp hc).intervalIntegrable _ _ + · intro a _ + rw [sourceAngular_signed_deriv hf] + have hv : ‖σ • sourceAngularVelocity x‖≤8 := by + rw [norm_smul,Real.norm_eq_abs] + exact (mul_le_mul hσ (sourceAngularVelocity_norm x) (norm_nonneg _) (by norm_num)).trans_eq (by ring) + have hb := (fderiv ℝ f (sourceAngularCollar (t+σ*a) x)).le_opNorm (σ • sourceAngularVelocity x) + have hb' := hb.trans (mul_le_mul_of_nonneg_left hv (norm_nonneg _)) + have hs := mul_self_le_mul_self (norm_nonneg _) hb' + simp only [Real.norm_eq_abs,←pow_two,sq_abs] at hs + unfold sourcePhysicalEnergy + nlinarith + +theorem sourceAngular_signed_trace {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (t σ : ℝ) (hσ : |σ|≤1) + {η : ℝ} (hη : 0<η) : + (∫ x : UnitAddTorus (Fin 2),(f (sourceAngularCollar t x))^2)≤ + (1+1/η)*(∫ a in (0:ℝ)..η,∫ x : UnitAddTorus (Fin 2), + sourcePhysicalEnergy f (sourceAngularCollar (t+σ*a) x)) := by + apply integrate_torus_interval_bound (F:=fun x => (f (sourceAngularCollar t x))^2) + (G:=fun a x => sourcePhysicalEnergy f (sourceAngularCollar (t+σ*a) x)) + ((hf.continuous.comp (continuous_sourceAngularCollar t)).pow 2) + ((continuous_sourcePhysicalEnergy hf).comp (continuous_sourceAngular_signed t σ)) hη.le + intro x + exact sourceAngular_signed_pointwise hf t σ hσ hη x + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AttachedEndPoisson.lean b/lean/OAI/Analysis/Conductivity/Fourier/AttachedEndPoisson.lean new file mode 100644 index 0000000000000000000000000000000000000000..618e2bae42fc6ae8a9d3812baae8f64b652982c4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AttachedEndPoisson.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.PhysicalEndDifferential +import OAI.Analysis.Conductivity.Variational.PhysicalEndLocalLipschitz + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix + +def endAxialAffine (a b : ℝ) (x : Fin 3 → ℝ) : Fin 3 → ℝ := + ![a*(x 0-b),x 1,x 2] + +def endAxialMatrix (a : ℝ) : Matrix (Fin 3) (Fin 3) ℝ := diagonal ![a,1,1] + +lemma endAxialAffine_contDiff (a b : ℝ) : ContDiff ℝ (↑(⊤:ℕ∞)) (endAxialAffine a b) := by + apply contDiff_pi.mpr + intro i + fin_cases i + · change ContDiff ℝ _ (fun x : Fin 3 → ℝ => a*(x 0-b)) + fun_prop + · change ContDiff ℝ _ (fun x : Fin 3 → ℝ => x 1) + fun_prop + · change ContDiff ℝ _ (fun x : Fin 3 → ℝ => x 2) + fun_prop + +lemma endAxialAffine_hasFDeriv (a b : ℝ) (x : Fin 3 → ℝ) : + HasFDerivAt (endAxialAffine a b) (Matrix.toLin' (endAxialMatrix a)).toContinuousLinearMap x := by + have hc (k : Fin 3) : HasFDerivAt (fun y => endAxialAffine a b y k) + ((ContinuousLinearMap.proj k : (Fin 3 → ℝ) →L[ℝ] ℝ).comp + (Matrix.toLin' (endAxialMatrix a)).toContinuousLinearMap) x := by + fin_cases k + · convert! ((hasFDerivAt_apply (𝕜:=ℝ) (0:Fin 3) x).sub_const b).const_mul a using 1 + ext v + simp [endAxialMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + · convert! hasFDerivAt_apply (𝕜:=ℝ) (1:Fin 3) x using 1 + ext v + simp [endAxialMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + · convert! hasFDerivAt_apply (𝕜:=ℝ) (2:Fin 3) x using 1 + ext v + simp [endAxialMatrix,Matrix.toLin'_apply,Matrix.mulVec_diagonal] + convert! hasFDerivAt_pi.mpr hc using 1 + +lemma torusAngles_endAxialAffine (a b : ℝ) (x : Fin 3 → ℝ) : + torusAngles (endAxialAffine a b x)=torusAngles x := by + ext k + fin_cases k <;> rfl + +def attachedEndPoissonField (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (a b : ℝ) (j : Fin 4) (y : Fin 3 → ℝ) : ℂ := + endPoissonField s f j (a*(sourceCollarTime y-b),sourcePhysicalAngles y) + +lemma measurable_attachedEndPoissonField (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (j : Fin 4) : + Measurable (attachedEndPoissonField s f a b j) := by + apply (measurable_endPoissonField s f j).comp + exact (measurable_const.mul (measurable_sourcePhysicalCoordinates.fst.sub measurable_const)).prodMk + measurable_sourcePhysicalAngles + +lemma attachedEndPoissonField_angular (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (j : Fin 4) + {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) (θ : UnitAddTorus (Fin 2)) : + attachedEndPoissonField s f a b j (sourceAngularCollar t θ)= + endPoissonField s f j (a*(t-b),θ) := by + simp only [attachedEndPoissonField,sourceAngular_time ht,sourcePhysicalAngles_angular ht] + +lemma attachedEndPoissonField_piece (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + attachedEndPoissonField s f a b 0 (sourceCollarPiece i j x)= + endFlatPoisson s f (endAxialAffine a b (sourceFaceAngles i j x)) := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + rw [←sourceFaceAngles_physical i j ha hb,attachedEndPoissonField_angular s f a b 0 ht, + endFlatPoisson_eq,torusAngles_endAxialAffine] + rfl + +lemma attachedEndPoissonField_local_eq (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + attachedEndPoissonField s f a b 0 =ᶠ[𝓝 (sourceCollarPiece i j x)] + (fun y => endFlatPoisson s f (endAxialAffine a b (sourceFaceAngles i j (sourceCollarInverse i j y)))) := by + change ∀ᶠ y in 𝓝 (sourceCollarPiece i j x),attachedEndPoissonField s f a b 0 y= + endFlatPoisson s f (endAxialAffine a b (sourceFaceAngles i j (sourceCollarInverse i j y))) + rw [←sourceCollarPiece_map_nhds i j hx,Filter.eventually_map] + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx, + sourceCollarInverse_eventually_left i j hx] with y hy hi + rw [hi] + exact attachedEndPoissonField_piece s f a b i j (sourceCollarOpenBox_subset hy) + +theorem attachedEndPoissonField_hasFDeriv (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b : ℝ) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) (ht : 0 (attachedEndPoissonField s f a b 0 y).re) x := by + have hflat := (localLipAt_of_contDiffAt ((endAxialAffine_contDiff a b).of_le + (show (1:WithTop ℕ∞)≤↑(⊤:ℕ∞) by simp)).contDiffAt).comp (sourceLocalFlat_localLip hx) + have hc := (torusRealContinuation_smooth hs ((mFourierBasis (d:=Fin 2)).repr.symm (f.val 0))).of_le + (show (1:WithTop ℕ∞)≤↑(⊤:ℕ∞) by simp) + have hc' := hc.contDiffAt ((axial_halfspace_open 0).mem_nhds + (show 0<(endAxialAffine a b (sourceLocalFlat x x)) 0 from ht)) + apply ((localLipAt_of_contDiffAt hc').comp (f:=endAxialAffine a b ∘ sourceLocalFlat x) hflat).congr + have htime : ∀ᶠ y in 𝓝 x,0 direction (Pi.single k 1) (fun y => f (flatEndCoordinates a b y)) x)= + endAxialMatrix a*ᵥ(fun k => fderiv ℝ f (flatEndCoordinates a b x) (Pi.single k 1)) := by + have he := (hf (flatEndCoordinates a b x)).hasFDerivAt.comp x (endAxialAffine_hasFDeriv a b x) + ext k + change fderiv ℝ (f ∘ flatEndCoordinates a b) x (Pi.single k 1)=_ + rw [he.fderiv] + change fderiv ℝ f (flatEndCoordinates a b x) (endAxialMatrix a*ᵥPi.single k 1)=_ + simp only [endAxialMatrix, Matrix.diagonal_mulVec_single, Matrix.mulVec_diagonal] + rw [show Pi.single k (![a,1,1] k * (1:ℝ)) = + ![a,1,1] k • (Pi.single k (1:ℝ) : Coord3) by + ext j + by_cases hj : j=k + · subst j; simp + · simp [Pi.single_eq_of_ne hj]] + rw [map_smul] + rfl + +lemma attachedPeriodicField_fderiv {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : Differentiable ℝ f) + (a b : ℝ) (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) (v : Coord3) : + fderiv ℝ (attachedPeriodicField f a b) (sourceCollarPiece i j x) v= + (attachedCartesianMatrix a i j x*ᵥ(fun k => fderiv ℝ f + (flatEndCoordinates a b (sourceFaceAngles i j x)) (Pi.single k 1))) ⬝ᵥ v := by + rw [attachedPeriodicField,physicalPeriodicField_fderiv (hp.flatEnd a b) + (hf.comp ((contDiff_flatEndCoordinates a b).differentiable (by norm_num))) i j hx v, + flatEndCoordinates_covector hf,attachedCartesianMatrix,Matrix.mulVec_mulVec] + +lemma attachedPeriodicField_covector {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : Differentiable ℝ f) + (a b : ℝ) (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + (fun k => lineDeriv ℝ (attachedPeriodicField f a b) (sourceCollarPiece i j x) (Pi.single k 1))= + attachedCartesianMatrix a i j x*ᵥ(fun k => fderiv ℝ f + (flatEndCoordinates a b (sourceFaceAngles i j x)) (Pi.single k 1)) := by + have hd := (physicalPeriodicField_hasFDeriv (hp.flatEnd a b) + (hf.comp ((contDiff_flatEndCoordinates a b).differentiable (by norm_num))) i j hx).differentiableAt + change DifferentiableAt ℝ (attachedPeriodicField f a b) (sourceCollarPiece i j x) at hd + ext k + rw [hd.lineDeriv_eq_fderiv,attachedPeriodicField_fderiv hp hf a b i j hx] + simp + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicFlux.lean b/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..41b9dd6ff49e9807ba4c29ebca32333a80887080 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicFlux.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularPhysicalTest +import OAI.Analysis.Conductivity.Sources.FaceIntegral +import OAI.Analysis.Conductivity.Variational.PhysicalFaceSum +import OAI.Analysis.Conductivity.Geometry.AffineCylinderIntegral +import OAI.Analysis.Conductivity.Sources.FacePasting +import OAI.Analysis.Conductivity.Sources.FluxCylinder + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus Matrix +open scoped ENNReal +local instance attachedPeriodicFluxMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance attachedPeriodicFluxIsProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma inverseTranspose_flux_pair (A : Mat3) (hA : A.det≠0) (v w : Coord3) : + (A⁻¹ᵀ*ᵥv) ⬝ᵥ(A*ᵥw)=v ⬝ᵥw := by + rw [dotProduct_comm,Matrix.dotProduct_transpose_mulVec,Matrix.mulVec_mulVec, + Matrix.nonsing_inv_mul _ (isUnit_iff_ne_zero.mpr hA),Matrix.one_mulVec] + +def attachedPeriodicFluxFace (F : Coord3 → Coord3) (a b : ℝ) (i j : Fin 4) + (y : Coord3) : Coord3 := + let x := sourceCollarInverse i j y + (|a| *sourceFlatDensity i j x) • ((attachedCartesianMatrix a i j x)⁻¹ᵀ*ᵥ + F (flatEndCoordinates a b (sourceFaceAngles i j x))) + +def attachedPeriodicFlux (F : Coord3 → Coord3) (a b : ℝ) : Coord3 → Coord3 := + sourceFacePaste (attachedPeriodicFluxFace F a b) 0 + +lemma attachedPeriodicFlux_open (F : Coord3 → Coord3) (a b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + attachedPeriodicFlux F a b (sourceCollarPiece i j x)= + (|a| *sourceFlatDensity i j x) • ((attachedCartesianMatrix a i j x)⁻¹ᵀ*ᵥ + F (flatEndCoordinates a b (sourceFaceAngles i j x))) := by + rw [attachedPeriodicFlux,sourceFacePaste_open _ _ i j hx] + simp only [attachedPeriodicFluxFace,sourceCollarInverse_point i j hx] + +lemma attachedPeriodicFlux_test_density {F : Coord3 → Coord3} + (hp : AngularPeriodic (2*Real.pi) F) {a b : ℝ} (ha : a≠0) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + |(sourceCollarJacobian i j x).det| * + (attachedPeriodicFlux F a b (sourceCollarPiece i j x) ⬝ᵥ + physicalTestCovector φ (sourceCollarPiece i j x))= + (|a| *angularArea)*(sourceFaceWeight i j x* + sourceFluxDensity F a⁻¹ b φ (affineEndCoordinates a b (sourceFaceParameter i j x))) := by + rw [attachedPeriodicFlux_open F a b i j hx, + ←attachedFlatTestCovector_transport φ ha i j (sourceCollarOpenBox_subset hx),smul_dotProduct, + inverseTranspose_flux_pair _ (attachedCartesianMatrix_det_ne_zero ha i j (sourceCollarOpenBox_subset hx))] + have hp' : torusPeriodicDescent F (affineEndCoordinates a b (sourceFaceParameter i j x))= + F (flatEndCoordinates a b (sourceFaceAngles i j x)) := by + simpa only [flatEndCoordinates_axial,flatEndCoordinates_angles,affineEndCoordinates, + Prod.map_apply,affineEndTime,id_eq,sourceFaceParameter,show sourceFaceAngles i j x 0=x 0 from rfl] using + torusPeriodicDescent_angles hp (flatEndCoordinates a b (sourceFaceAngles i j x)) + simp only [sourceFluxDensity,hp'] + have hj := sourceAngularJet_attachedCovector hφ ha b i j hx + change (fun k : Fin 3 => (sourceAngularJet φ a⁻¹ b k.succ + (affineEndCoordinates a b (sourceFaceParameter i j x))).re)=attachedFlatTestCovector φ a i j x at hj + rw [hj,smul_eq_mul,sourceFlatDensity,sourceFaceWeight,sourceFaceAngleMatrix_det] + field_simp [abs_ne_zero.mpr (sourceCollarJacobian_extended_ne_zero i j (sourceCollarOpenBox_subset hx))] + +theorem attachedPeriodicFlux_smooth_pullback {F : Coord3 → Coord3} (hF : Continuous F) + (hp : AngularPeriodic (2*Real.pi) F) {φ : Coord3 → ℝ} + (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) {a b l r R : ℝ} (ha : a≠0) + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) : + IntegrableOn (fun y => attachedPeriodicFlux F a b y ⬝ᵥphysicalTestCovector φ y) + (sourceClosedCollarBand l r) volume ∧ + (∫ y in sourceClosedCollarBand l r,attachedPeriodicFlux F a b y ⬝ᵥphysicalTestCovector φ y)= + |a| *angularArea*(∫ z,sourceFluxDensity F a⁻¹ b φ (affineEndCoordinates a b z) + ∂(volume.restrict (Ioc l r)).prod volume) := by + let H := sourceFluxDensity F a⁻¹ b φ + let G := fun y => attachedPeriodicFlux F a b y ⬝ᵥphysicalTestCovector φ y + have hH := (sourceFluxDensity_cylinder hF hp a⁻¹ b R hφ).1 + have hg := integrable_affineEndCoordinates ha hT hH + have he (i j : Fin 4) : + (fun x => |(sourceCollarDerivative i j x).det| • G (sourceCollarPiece i j x))=ᵐ[ + volume.restrict (sourceExtendedBox l r)] + (fun x => (|a| *angularArea)*(sourceFaceWeight i j x* + H (affineEndCoordinates a b (sourceFaceParameter i j x)))) := by + filter_upwards [sourceExtendedBox_open_ae hl hr] with x hx + dsimp only [G,H] + rw [smul_eq_mul,sourceCollarDerivative_det,←sourceCollarJacobian_det] + exact attachedPeriodicFlux_test_density hp ha hφ i j hx + have hi (i j : Fin 4) : IntegrableOn G + (sourceCollarPiece i j '' sourceExtendedBox l r) volume := by + apply (integrableOn_image_iff_integrableOn_abs_det_fderiv_smul volume measurableSet_Icc + (fun x _ => (sourceCollarPiece_hasFDeriv i j x).hasFDerivWithinAt) + (sourceExtendedBox_injOn i j hl hr) G).mpr + exact ((integrable_sourceFacePullback hlr hg i j).const_mul (|a| *angularArea)).congr (he i j).symm + have hG : IntegrableOn G (sourceClosedCollarBand l r) volume := by + unfold IntegrableOn + rw [sourceClosedCollarBand_measure_faces hl hr] + exact integrable_finsetSum_measure.mpr (fun i _ => + integrable_finsetSum_measure.mpr fun j _ => hi i j) + refine ⟨hG,?_⟩ + change (∫ y in sourceClosedCollarBand l r,G y)=_ + rw [integral_sourceClosedCollarBand_faces hl hr hG, + integral_sourceCylinder_faces (F:=fun z => sourceFluxDensity F a⁻¹ b φ + (affineEndCoordinates a b z)) hlr hg,Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro j _ + rw [sourceExtended_integral i j hl hr G,integral_congr_ae (he i j),integral_const_mul] + rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicGreen.lean b/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..961af26739172dad8c2b81da39ccc130db7f8759 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/AttachedPeriodicGreen.lean @@ -0,0 +1,47 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AttachedPeriodicFlux + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus Matrix +open scoped ENNReal +local instance attachedPeriodicGreenMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance attachedPeriodicGreenIsProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +theorem attachedPeriodicFlux_smooth_green {F : Coord3 → Coord3} + (hF : ContDiff ℝ 1 F) (hp : AngularPeriodic (2*Real.pi) F) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) + {a b l r R : ℝ} (ha : a≠0) (hlr : l≤r) (hR : 0≤R) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (he : (0 attachedPeriodicFlux F a b y ⬝ᵥphysicalTestCovector φ y) + (sourceClosedCollarBand l r) volume ∧ + (∫ y in sourceClosedCollarBand l r,attachedPeriodicFlux F a b y ⬝ᵥphysicalTestCovector φ y)= + angularArea*((∫ θ,torusPeriodicDescent F (R,θ) 0* + φ (sourceAngularCollar (a⁻¹*R+b) θ))- + (∫ θ,torusPeriodicDescent F (0,θ) 0*φ (sourceAngularCollar b θ))) := by + obtain ⟨hi,hiE⟩ := attachedPeriodicFlux_smooth_pullback hF.continuous hp hφ ha hlr hl hr hT + refine ⟨hi,hiE.trans ?_⟩ + have hI := (sourceFluxDensity_cylinder hF.continuous hp a⁻¹ b R hφ).1 + have hj : |a| *(∫ z,sourceFluxDensity F a⁻¹ b φ (affineEndCoordinates a b z) + ∂(volume.restrict (Ioc l r)).prod volume)= + ∫ z,sourceFluxDensity F a⁻¹ b φ z ∂(FiniteAxisMeasure R).prod volume := by + rcases he with ⟨h,he₀,heR⟩|⟨h,heR,he₀⟩ + · exact integral_affineEndCoordinates_pos h hlr hT he₀ heR hR hI + · exact integral_affineEndCoordinates_neg h hlr hT heR he₀ hR hI + rw [mul_comm |a| angularArea,mul_assoc,hj,sourceFluxDensity_green hF hp hR hd a⁻¹ b hφ] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CascadePeriodicity.lean b/lean/OAI/Analysis/Conductivity/Fourier/CascadePeriodicity.lean new file mode 100644 index 0000000000000000000000000000000000000000..5dacf5e83b7cab08f6d49902317de645af79ccf0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CascadePeriodicity.lean @@ -0,0 +1,151 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.Ending +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly +import OAI.Analysis.Conductivity.Fourier.AngularPeriodization + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +def angularInteger (n : Fin 2 → ℤ) : Fin 3 → ℤ := ![0,n 0,n 1] + +lemma angularShift_apply (T : ℝ) (n : Fin 2 → ℤ) (i : Fin 3) : + angularShift T n i=T*(angularInteger n i:ℝ) := by + fin_cases i <;> simp [angularShift,angularInteger] + +lemma sin_int_angular_shift (q : ℤ) (n : Fin 2 → ℤ) (x : Coord3) (i : Fin 3) : + sin ((q:ℝ)*(x+angularShift (2*Real.pi) n) i)=sin ((q:ℝ)*x i) := by + have he : (q:ℝ)*(x+angularShift (2*Real.pi) n) i= + (q:ℝ)*x i+((q*angularInteger n i:ℤ):ℝ)*(2*Real.pi) := by + simp only [Pi.add_apply,angularShift_apply,Int.cast_mul] + ring + rw [he,sin_add_int_mul_two_pi] + +lemma cos_int_angular_shift (q : ℤ) (n : Fin 2 → ℤ) (x : Coord3) (i : Fin 3) : + cos ((q:ℝ)*(x+angularShift (2*Real.pi) n) i)=cos ((q:ℝ)*x i) := by + have he : (q:ℝ)*(x+angularShift (2*Real.pi) n) i= + (q:ℝ)*x i+((q*angularInteger n i:ℤ):ℝ)*(2*Real.pi) := by + simp only [Pi.add_apply,angularShift_apply,Int.cast_mul] + ring + rw [he,cos_add_int_mul_two_pi] + +lemma cascadeTerm_angularPeriodic (L K A : ℝ) (k : ℤ) (j : ℕ) : + AngularPeriodic (2*Real.pi) (cascadeTerm L K k A j) := by + intro n x + have hc := cos_int_angular_shift (k*2^j) n x (cascadeAxis j) + push_cast at hc + simpa only [cascadeTerm,Pi.add_apply,angularShift,Matrix.cons_val_zero,add_zero] using + congrArg (fun z => (A*cascadeRatio L K^j)* + cascadeProfile L K (cascadePhase (cascadeLength L K) k j (x 0))*z) hc + +lemma cascadeValue_angularPeriodic (L K A : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (cascadeValue L K k A) := by + intro n x + apply tsum_congr + intro j + exact cascadeTerm_angularPeriodic L K A k j n x + +lemma crossingTensor_angularPeriodic (L : ℝ) (a b : Fin 3) : + AngularPeriodic (2*Real.pi) (crossingTensor L a b) := by + intro n x + have hs (i : Fin 3) : sin ((x+angularShift (2*Real.pi) n) i)=sin (x i) := by + simpa using sin_int_angular_shift 1 n x i + have hc (i : Fin 3) : cos ((x+angularShift (2*Real.pi) n) i)=cos (x i) := by + simpa using cos_int_angular_shift 1 n x i + have hs2 (i : Fin 3) : sin (2*(x+angularShift (2*Real.pi) n) i)=sin (2*x i) := by + simpa using sin_int_angular_shift 2 n x i + have hc2 (i : Fin 3) : cos (2*(x+angularShift (2*Real.pi) n) i)=cos (2*x i) := by + simpa using cos_int_angular_shift 2 n x i + have hzero : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + ext i j + simp only [crossingTensor,crossingXX,crossingYY,crossingXY,crossingHxx,crossingHxy, + one_mul,hs,hc,hs2,hc2,hzero] + +lemma angularShift_dilation (q : ℤ) (n : Fin 2 → ℤ) (x c d : Coord3) : + (q:ℝ) • (x+angularShift (2*Real.pi) n-c)-d= + ((q:ℝ) • (x-c)-d)+angularShift (2*Real.pi) (fun i => q*n i) := by + have hshift : (q:ℝ) • angularShift (2*Real.pi) n= + angularShift (2*Real.pi) (fun i => q*n i) := by + ext i + fin_cases i + · change (q:ℝ)*0=0 + ring + · change (q:ℝ)*((2*Real.pi)*(n 0:ℝ))=(2*Real.pi)*((q*n 0:ℤ):ℝ) + push_cast + ring + · change (q:ℝ)*((2*Real.pi)*(n 1:ℝ))=(2*Real.pi)*((q*n 1:ℤ):ℝ) + push_cast + ring + rw [smul_sub,smul_add,smul_sub,hshift] + abel + +lemma cascadeStageTensor_angularPeriodic (L K : ℝ) (k : ℤ) (j : ℕ) : + AngularPeriodic (2*Real.pi) (cascadeStageTensor L K k j) := by + intro n x + have hs : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + unfold cascadeStageTensor + rw [hs] + split_ifs + · rfl + · have he := angularShift_dilation (k*2^j) n x (cascadeCenter (cascadeLength L K) k j) + (Pi.single 0 (K+2+L)) + push_cast at he + rw [he,crossingTensor_angularPeriodic] + +lemma cascadeTensor_angularPeriodic (L K : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (cascadeTensor L K k) := by + intro n x + have hs : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + have hi : cascadeIndex (cascadeLength L K) k (x+angularShift (2*Real.pi) n)= + cascadeIndex (cascadeLength L K) k x := by simp only [cascadeIndex,hs] + unfold cascadeTensor + rw [hs,hi] + split_ifs + · exact cascadeStageTensor_angularPeriodic L K k _ n x + · rfl + +lemma cascadeValue_one_angularPeriodic (L K A : ℝ) : + AngularPeriodic (2*Real.pi) (cascadeValue L K 1 A) := by + simpa only [Int.cast_one] using (cascadeValue_angularPeriodic L K A (1:ℤ)) + +lemma cascadeTensor_one_angularPeriodic (L K : ℝ) : + AngularPeriodic (2*Real.pi) (cascadeTensor L K 1) := by + simpa only [Int.cast_one] using (cascadeTensor_angularPeriodic L K (1:ℤ)) + +lemma finiteEndingValue_angularPeriodic (a J L K : ℝ) : + AngularPeriodic (2*Real.pi) (finiteEndingValue a J L K) := by + intro n x + have hs : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + have he : x+angularShift (2*Real.pi) n-Pi.single 0 (J+2)= + (x-Pi.single 0 (J+2))+angularShift (2*Real.pi) n := by abel + unfold finiteEndingValue + rw [hs] + split_ifs + · unfold pureModeValue + rw [hs] + have hh := cos_int_angular_shift 1 n x 1 + simpa using congrArg (fun z => initialConnectorProfile a (1/2) J (x 0)*z) hh + · rw [he] + apply cascadeValue_one_angularPeriodic + +lemma finiteEndingTensor_angularPeriodic (a J L K : ℝ) : + AngularPeriodic (2*Real.pi) (finiteEndingTensor a J L K) := by + intro n x + have hs : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + have he : x+angularShift (2*Real.pi) n-Pi.single 0 (J+2)= + (x-Pi.single 0 (J+2))+angularShift (2*Real.pi) n := by abel + unfold finiteEndingTensor + rw [hs] + split_ifs + · rfl + · rw [he] + exact cascadeTensor_one_angularPeriodic L K n (x-Pi.single 0 (J+2)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CollarAngularInverse.lean b/lean/OAI/Analysis/Conductivity/Fourier/CollarAngularInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..951a121bd7ee3a0b89d06d06238c6e50514fcb3d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CollarAngularInverse.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +def complexUnitAngle (z : ℂ) : UnitAddCircle := (z.arg/(2*Real.pi) : ℝ) + +lemma measurable_complexUnitAngle : Measurable complexUnitAngle := by + exact (show Continuous (fun x : ℝ => (x : UnitAddCircle)) from continuous_quotient_mk').measurable.comp + (Complex.measurable_arg.div_const _) + +lemma fourier_complexUnitAngle (z : ℂ) : + fourier 1 (complexUnitAngle z)=Complex.exp ((z.arg : ℂ)*Complex.I) := by + rw [complexUnitAngle,fourier_coe_apply] + congr 1 + push_cast + field_simp + +lemma complexUnitAngle_fourier (x : UnitAddCircle) : + complexUnitAngle (fourier 1 x)=x := by + apply AddCircle.injective_toCircle (by norm_num : (1:ℝ)≠0) + apply Subtype.ext + have hn : ‖fourier 1 x‖=1 := by simp [fourier_apply,Circle.norm_coe] + have he := Complex.norm_mul_exp_arg_mul_I (fourier 1 x) + rw [hn,Complex.ofReal_one,one_mul,←fourier_complexUnitAngle] at he + simpa [fourier_apply] using he + +lemma complexUnitAngle_pos_mul (z : ℂ) {r : ℝ} (hr : 0.trans_eq (one_mul w) + +lemma sourceAngular_radius_pos {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : + 0 (sourceRadialCenter+(1-t)*rectangularRay sourceRadialWidth (θ 1) 0)*z) hh + +lemma sourceAngular_time {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : sourceCollarTime (sourceAngularCollar t θ)=t := by + have hs : 0<1-t := by linarith [ht.2] + have hw : 0 complexUnitAngle (sourceComplexDirections y i) + +lemma continuous_sourceComplexDirections : Continuous sourceComplexDirections := by + apply continuous_pi + intro i + fin_cases i <;> unfold sourceComplexDirections sourceRadial <;> fun_prop + +lemma measurable_sourcePhysicalAngles : Measurable sourcePhysicalAngles := by + apply Measurable.of_eval + intro i + exact measurable_complexUnitAngle.comp + (((continuous_apply i).comp continuous_sourceComplexDirections).measurable) + +lemma sourceComplexDirections_angular {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : + sourceComplexDirections (sourceAngularCollar t θ)= + ![(((sourceRadialCenter+(1-t)*rectangularRay sourceRadialWidth (θ 1) 0)/ + rayDenominator 1 (θ 0):ℝ):ℂ)*fourier 1 (θ 0), + (((1-t)/rayDenominator sourceRadialWidth (θ 1):ℝ):ℂ)*fourier 1 (θ 1)] := by + ext i + fin_cases i + · apply Complex.ext <;> + simp [sourceComplexDirections,sourceAngularCollar,sourceAngularPolynomial, + sourceRayCoordinates,rectangularRay,rayDirection,Complex.mul_re,Complex.mul_im] <;> + norm_num [sourceLength] <;> ring + · change ((sourceRadial (sourceAngularCollar t θ)-sourceRadialCenter:ℝ):ℂ)+ + Complex.I*((sourceAngularCollar t θ) 2:ℂ)=_ + rw [sourceAngular_radial ht,add_sub_cancel_left] + apply Complex.ext <;> + simp [sourceAngularCollar,sourceAngularPolynomial,sourceRayCoordinates, + rectangularRay,rayDirection,Complex.mul_re,Complex.mul_im] <;> ring + +lemma sourcePhysicalAngles_angular {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : sourcePhysicalAngles (sourceAngularCollar t θ)=θ := by + have h0 : 0 g) + +lemma glue_derivative_compact_bound {gap : ℝ} (hg : 0 (hC _ ⟨p,hp,rfl⟩).trans (le_max_left _ _)⟩ + +lemma glue_scaled_iterated_bound {gap d C : ℝ} (hg : 0 expNegInvGlue (z.1/d)) z‖≤C*gap⁻¹^n := by + let P : (ℝ×Coord3) →L[ℝ] ℝ := d⁻¹ • ContinuousLinearMap.fst ℝ ℝ Coord3 + have hdpos : 0 expNegInvGlue (z.1/d))=expNegInvGlue ∘ P := by + funext w; simp [P,div_eq_mul_inv,mul_comm] + rw [he] + exact (linear_comp_iterated_point_bound P expNegInvGlue.contDiff n z).trans + (mul_le_mul (hb _ hpv) (pow_le_pow_left₀ (norm_nonneg _) hpn n) + (by positivity) hC) + +lemma flatPhaseMode_shift_snd_bound (s : Fin 3→ℝ) (h : Fin 2→ℤ) + (phase T δ : ℝ) (n : ℕ) {z : ℝ×Coord3} (hz : δ≤T+z.2 0) : + ‖iteratedFDeriv ℝ n (fun z : ℝ×Coord3 => flatPhaseMode s h phase (z.2+![T,0,0])) z‖≤ + (torusRate s h+torusSize h)^n*exp (-δ*torusRate s h) := by + let f : Coord3→ℝ := fun y => flatPhaseMode s h phase (y+![T,0,0]) + let P : (ℝ×Coord3) →L[ℝ] Coord3 := ContinuousLinearMap.snd ℝ ℝ Coord3 + have hf : ContDiff ℝ (↑(⊤:ℕ∞)) f := (flatPhaseMode_smooth s h phase).comp (contDiff_id.add contDiff_const) + change ‖iteratedFDeriv ℝ n (f ∘ P) z‖≤_ + apply (linear_comp_iterated_point_bound P hf n z).trans + have hp : ‖P‖^n≤1 := pow_le_one₀ (norm_nonneg _) (ContinuousLinearMap.norm_snd_le ℝ ℝ Coord3) + apply (mul_le_of_le_one_right (norm_nonneg _) hp).trans + have he : iteratedFDeriv ℝ n f (P z)=iteratedFDeriv ℝ n (flatPhaseMode s h phase) (z.2+![T,0,0]) := + iteratedFDeriv_comp_add_right (f := flatPhaseMode s h phase) n _ _ + rw [he] + apply (flatPhaseMode_iterated_bound s h phase n _).trans + have hr : 0≤torusRate s h := sqrt_nonneg _ + apply mul_le_mul_of_nonneg_left _ (pow_nonneg (add_nonneg hr (torusSize_nonneg h)) _) + apply exp_le_exp.mpr + simpa only [Pi.add_apply,Matrix.cons_val_zero] using + (show -torusRate s h*(z.2 0+T)≤-δ*torusRate s h by nlinarith) + +def compactifiedFourierTerm (s : Fin 3→ℝ) (lam T0 : ℝ) + (a phase : (Fin 2→ℤ)→ℝ) (h : Fin 2→ℤ) (z : ℝ×Coord3) : ℝ := + a h*exp (lam*T0) * + (expNegInvGlue (z.1/(torusRate s h-lam))*flatPhaseMode s h (phase h) (z.2+![T0,0,0])) + +def compactifiedFourierTail (s : Fin 3→ℝ) (lam T0 : ℝ) + (a phase : (Fin 2→ℤ)→ℝ) (z : ℝ×Coord3) : ℝ := + ∑' h,compactifiedFourierTerm s lam T0 a phase h z + +lemma compactifiedFourierTerm_smooth (s : Fin 3→ℝ) (lam T0 : ℝ) + (a phase : (Fin 2→ℤ)→ℝ) (h : Fin 2→ℤ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (compactifiedFourierTerm s lam T0 a phase h) := by + unfold compactifiedFourierTerm + exact contDiff_const.mul ((expNegInvGlue.contDiff.comp (contDiff_fst.div_const _)).mul + ((flatPhaseMode_smooth s h (phase h)).comp (contDiff_snd.add contDiff_const))) + +lemma compactifiedFourierTerm_iterated_bound {s : Fin 3→ℝ} {lam T0 gap B δ : ℝ} + {a phase : (Fin 2→ℤ)→ℝ} (hg : 0 mul_nonneg + (mul_nonneg (Nat.cast_nonneg _) (mul_nonneg (hC i) (by positivity))) (by positivity) + have hfun : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z : ℝ×Coord3 => + expNegInvGlue (z.1/(torusRate s h-lam))*flatPhaseMode s h (phase h) (z.2+![T0,0,0])) := + (expNegInvGlue.contDiff.comp (contDiff_fst.div_const _)).mul + ((flatPhaseMode_smooth s h (phase h)).comp (contDiff_snd.add contDiff_const)) + change ‖iteratedFDeriv ℝ n ((a h*exp (lam*T0)) • + (fun z : ℝ×Coord3 => expNegInvGlue (z.1/(torusRate s h-lam))* + flatPhaseMode s h (phase h) (z.2+![T0,0,0]))) z‖≤_ + rw [iteratedFDeriv_const_smul_apply (((contDiff_infty.mp hfun) n).contDiffAt),norm_smul, + Real.norm_eq_abs,abs_mul,abs_of_pos (exp_pos _)] + apply mul_le_mul (mul_le_mul_of_nonneg_right (ha h) (exp_nonneg _)) _ (norm_nonneg _) + (mul_nonneg hB (exp_nonneg _)) + apply (norm_iteratedFDeriv_mul_le + (expNegInvGlue.contDiff.comp (contDiff_fst.div_const _)) + ((flatPhaseMode_smooth s h (phase h)).comp (contDiff_snd.add contDiff_const)) z + (by exact_mod_cast (le_top : (n:ℕ∞)≤⊤))).trans + apply Finset.sum_le_sum + intro i hi + exact mul_le_mul (mul_le_mul_of_nonneg_left + (glue_scaled_iterated_bound hg (by linarith [hr h hz]) i (hC i) (hb i) hp) + (Nat.cast_nonneg _)) (flatPhaseMode_shift_snd_bound s h (phase h) T0 δ (n-i) hx) + (norm_nonneg _) (by positivity [hC i]) + +theorem compactifiedFourierTail_smooth {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {lam T0 gap B δ : ℝ} {a phase : (Fin 2→ℤ)→ℝ} + (hg : 0 glue_derivative_compact_bound hg n + apply local_smooth_tsum (isOpen_Ioo.prod (axial_halfspace_open _)) + ((convex_Ioo (𝕜 := ℝ) (-1 : ℝ) 1).isPreconnected.prod (axial_halfspace_connected _)) + (compactifiedFourierTerm_smooth s lam T0 a phase) + (fun n h => B*exp (lam*T0)*(∑ i∈Finset.range (n+1),(n.choose i:ℝ)*(C i*gap⁻¹^i)* + ((torusRate s h+torusSize h)^(n-i)*exp (-δ*torusRate s h)))) + · intro n + apply Summable.mul_left + exact summable_sum (fun i _ => (flatMode_derivative_summable hs (n-i) hδ).mul_left _) + · intro n h z hz + apply compactifiedFourierTerm_iterated_bound hg hB ha hr C hC hb n h + · exact (abs_lt.mpr hz.1).le + · have hx := hz.2 + dsimp at hx + linarith + +lemma compactifiedFourierTail_of_pos {s : Fin 3→ℝ} {lam T0 : ℝ} + {a phase : (Fin 2→ℤ)→ℝ} + (hr : ∀ h,a h≠0 → lam f z.1*g z.2) 2 + (μ.prod volume) := by + apply (memLp_two_iff_integrable_sq_norm + ((Lp.aestronglyMeasurable f).comp_fst.mul (Lp.aestronglyMeasurable g).comp_snd)).mpr + simpa only [Pi.mul_apply,norm_mul,mul_pow] using + ((Lp.memLp f).integrable_norm_pow (by decide : (2:ℕ)≠0)).mul_prod + ((Lp.memLp g).integrable_norm_pow (by decide : (2:ℕ)≠0)) + +def cylinderTensor {μ : Measure ℝ} (f : Lp ℂ 2 μ) (g : TorusL2) : CylinderL2 μ := + (cylinderTensor_memLp f g).toLp _ + +lemma cylinderTensor_ae {μ : Measure ℝ} (f : Lp ℂ 2 μ) (g : TorusL2) : + cylinderTensor f g =ᵐ[μ.prod volume] + fun z : ℝ × UnitAddTorus (Fin 2) => f z.1*g z.2 := + (cylinderTensor_memLp f g).coeFn_toLp + +lemma cylinderTensor_add {μ : Measure ℝ} (f f' : Lp ℂ 2 μ) (g : TorusL2) : + cylinderTensor (f+f') g=cylinderTensor f g+cylinderTensor f' g := by + apply Lp.ext + filter_upwards [cylinderTensor_ae (f+f') g,cylinderTensor_ae f g, + cylinderTensor_ae f' g,Lp.coeFn_add (cylinderTensor f g) (cylinderTensor f' g), + Measure.quasiMeasurePreserving_fst.ae (Lp.coeFn_add f f')] with z hz h1 h2 h3 h4 + rw [hz,h3] + simp only [Pi.add_apply] at h4 ⊢ + rw [h1,h2,h4] + exact add_mul _ _ _ + +lemma cylinderTensor_smul {μ : Measure ℝ} (c : ℂ) (f : Lp ℂ 2 μ) (g : TorusL2) : + cylinderTensor (c•f) g=c•cylinderTensor f g := by + apply Lp.ext + filter_upwards [cylinderTensor_ae (c•f) g,cylinderTensor_ae f g, + Lp.coeFn_smul c (cylinderTensor f g), + Measure.quasiMeasurePreserving_fst.ae (Lp.coeFn_smul c f)] with z hz h1 h2 h3 + rw [hz,h2] + simp only [Pi.smul_apply] at h3 ⊢ + rw [h1,h3] + simp only [smul_eq_mul,mul_assoc] + +lemma cylinderTensor_inner {μ : Measure ℝ} [SFinite μ] + (f f' : Lp ℂ 2 μ) (g g' : TorusL2) : + inner ℂ (cylinderTensor f g) (cylinderTensor f' g')= + inner ℂ f f'*inner ℂ g g' := by + rw [L2.inner_def,L2.inner_def,L2.inner_def,←integral_prod_mul] + apply integral_congr_ae + filter_upwards [cylinderTensor_ae f g,cylinderTensor_ae f' g'] with z hz hz' + rw [hz,hz'] + simp only [RCLike.inner_apply,map_mul] + ring + +lemma cylinderTensor_norm_sq {μ : Measure ℝ} [SFinite μ] + (f : Lp ℂ 2 μ) (g : TorusL2) : + ‖cylinderTensor f g‖^2=‖f‖^2*‖g‖^2 := by + have he := cylinderTensor_inner f f g g + simp only [inner_self_eq_norm_sq_to_K] at he + exact_mod_cast he + +def cylinderMode (μ : Measure ℝ) [SFinite μ] (h : TorusModes) : + Lp ℂ 2 μ →ₗᵢ[ℂ] CylinderL2 μ where + toFun f := cylinderTensor f (mFourierLp 2 h) + map_add' f g := cylinderTensor_add f g _ + map_smul' c f := cylinderTensor_smul c f _ + norm_map' f := by + change ‖cylinderTensor f (mFourierLp 2 h)‖=‖f‖ + have he := cylinderTensor_norm_sq f (mFourierLp 2 h) + rw [(orthonormal_mFourier (d:=Fin 2)).norm_eq_one h,one_pow,mul_one] at he + nlinarith only [he,norm_nonneg (cylinderTensor f (mFourierLp 2 h)),norm_nonneg f] + +lemma cylinderMode_orthogonal (μ : Measure ℝ) [SFinite μ] : + OrthogonalFamily ℂ (fun _ : TorusModes => Lp ℂ 2 μ) (cylinderMode μ) := by + intro h k hk f g + change inner ℂ (cylinderTensor f (mFourierLp 2 h)) + (cylinderTensor g (mFourierLp 2 k))=0 + rw [cylinderTensor_inner,(orthonormal_mFourier (d:=Fin 2)).inner_eq_zero hk,mul_zero] + +def cylinderFourier (μ : Measure ℝ) [SFinite μ] : + lp (fun _ : TorusModes => Lp ℂ 2 μ) 2 →ₗᵢ[ℂ] CylinderL2 μ := + (cylinderMode_orthogonal μ).linearIsometry + +lemma cylinderFourier_hasSum (μ : Measure ℝ) [SFinite μ] + (f : lp (fun _ : TorusModes => Lp ℂ 2 μ) 2) : + HasSum (fun h => cylinderMode μ h (f h)) (cylinderFourier μ f) := + (cylinderMode_orthogonal μ).hasSum_linearIsometry f + +lemma cylinderFourier_norm_sq (μ : Measure ℝ) [SFinite μ] + (f : lp (fun _ : TorusModes => Lp ℂ 2 μ) 2) : + ‖cylinderFourier μ f‖^2=∑' h,‖f h‖^2 := by + rw [(cylinderFourier μ).norm_map] + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using + lp.norm_rpow_eq_tsum (by norm_num : 0<(2:ℝ≥0∞).toReal) f + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierComplete.lean b/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierComplete.lean new file mode 100644 index 0000000000000000000000000000000000000000..45c99845624f24180a4e1f9754e180a815869118 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierComplete.lean @@ -0,0 +1,185 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.AxialDecayL2 + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance cylinderFourierCompleteMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance cylinderFourierCompleteProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma cylinderL2_slice_memLp {μ : Measure ℝ} [SFinite μ] (F : CylinderL2 μ) : + ∀ᵐ t ∂μ, MemLp (fun θ => F (t,θ)) 2 (volume : Measure (UnitAddTorus (Fin 2))) := by + filter_upwards [(Lp.aestronglyMeasurable F).prodMk_left, + ((Lp.memLp F).integrable_norm_pow (by decide : (2:ℕ)≠0)).prod_right_ae] + with t ht hI + exact (memLp_two_iff_integrable_sq_norm ht).mpr hI + +lemma torusFourierCoeff_norm_sq_le {f : UnitAddTorus (Fin 2) → ℂ} + (hf : MemLp f 2 volume) (h : TorusModes) : + ‖mFourierCoeff f h‖^2 ≤ ∫ θ, ‖f θ‖^2 := by + let g : TorusL2 := hf.toLp f + have he : mFourierCoeff f h = mFourierCoeff g h := by + unfold mFourierCoeff + apply integral_congr_ae + filter_upwards [hf.coeFn_toLp] with θ hθ + rw [hθ] + rw [he,←mFourierBasis_repr, HilbertBasis.repr_apply_apply] + have hN := norm_inner_le_norm (𝕜:=ℂ) (mFourierBasis (d:=Fin 2) h) g + rw [coe_mFourierBasis,(orthonormal_mFourier (d:=Fin 2)).norm_eq_one h,one_mul] at hN + have heN : ‖g‖^2 = ∫ θ, ‖f θ‖^2 := by + rw [complexLp_norm_sq] + apply integral_congr_ae + filter_upwards [hf.coeFn_toLp] with θ hθ + rw [hθ] + rw [←heN] + simpa only [coe_mFourierBasis] using pow_le_pow_left₀ (norm_nonneg _) hN 2 + +def cylinderCoefficient {μ : Measure ℝ} (F : CylinderL2 μ) (h : TorusModes) (t : ℝ) : ℂ := + mFourierCoeff (fun θ => F (t,θ)) h + +lemma cylinderCoefficient_aestronglyMeasurable {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) : AEStronglyMeasurable (cylinderCoefficient F h) μ := by + exact (((mFourier (-h)).continuous.stronglyMeasurable.aestronglyMeasurable.comp_snd).mul + (Lp.aestronglyMeasurable F)).integral_prod_right' + +lemma cylinderCoefficient_memLp {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) : MemLp (cylinderCoefficient F h) 2 μ := by + apply (memLp_two_iff_integrable_sq_norm (cylinderCoefficient_aestronglyMeasurable F h)).mpr + apply (((Lp.memLp F).integrable_norm_pow (by decide : (2:ℕ)≠0)).integral_prod_left).mono' + ((cylinderCoefficient_aestronglyMeasurable F h).norm.pow 2) + filter_upwards [cylinderL2_slice_memLp F] with t ht + simpa only [Pi.pow_apply,Real.norm_eq_abs,abs_pow,abs_norm,cylinderCoefficient] using + torusFourierCoeff_norm_sq_le ht h + +def cylinderCoefficientLp {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) : Lp ℂ 2 μ := + (cylinderCoefficient_memLp F h).toLp _ + +lemma cylinderCoefficientLp_ae {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) : + cylinderCoefficientLp F h =ᵐ[μ] cylinderCoefficient F h := + (cylinderCoefficient_memLp F h).coeFn_toLp + +lemma cylinderMode_inner_coefficient {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) (f : Lp ℂ 2 μ) : + inner ℂ (cylinderMode μ h f) F = inner ℂ f (cylinderCoefficientLp F h) := by + have hae : (fun z : ℝ × UnitAddTorus (Fin 2) => + inner ℂ ((cylinderMode μ h f) z) (F z)) =ᵐ[μ.prod volume] + fun z => (starRingEnd ℂ) (f z.1) * (mFourier (-h) z.2 * F z) := by + filter_upwards [cylinderTensor_ae f (mFourierLp 2 h), + Measure.quasiMeasurePreserving_snd.ae (coeFn_mFourierLp 2 h)] with z hz he + change inner ℂ ((cylinderTensor f (mFourierLp 2 h)) z) (F z) = _ + rw [hz,he] + simp only [RCLike.inner_apply,map_mul,mFourier_neg] + ring + have hI := (L2.integrable_inner (cylinderMode μ h f) F).congr hae + rw [L2.inner_def,L2.inner_def,integral_congr_ae hae,integral_prod _ hI] + apply integral_congr_ae + filter_upwards [cylinderCoefficientLp_ae F h] with t ht + rw [ht,integral_const_mul] + simp only [cylinderCoefficient,mFourierCoeff,smul_eq_mul,RCLike.inner_apply] + ring + +lemma cylinderModes_total {μ : Measure ℝ} [SFinite μ] (F : CylinderL2 μ) + (hF : ∀ (h : TorusModes) (f : Lp ℂ 2 μ), inner ℂ (cylinderMode μ h f) F = 0) : + F = 0 := by + have hc (h : TorusModes) : cylinderCoefficientLp F h = 0 := by + apply (inner_self_eq_zero (𝕜:=ℂ)).mp + exact (cylinderMode_inner_coefficient F h (cylinderCoefficientLp F h)).symm.trans + (hF h (cylinderCoefficientLp F h)) + have hac (h : TorusModes) : cylinderCoefficient F h =ᵐ[μ] 0 := by + exact (cylinderCoefficientLp_ae F h).symm.trans (by rw [hc h]; exact Lp.coeFn_zero _ _ _) + have haslice : ∀ᵐ t ∂μ, ∀ᵐ θ ∂(volume : Measure (UnitAddTorus (Fin 2))), F (t,θ) = 0 := by + filter_upwards [cylinderL2_slice_memLp F, ae_all_iff.mpr hac] with t ht hct + let g : TorusL2 := ht.toLp (fun θ => F (t,θ)) + have hcg (h : TorusModes) : mFourierCoeff g h = 0 := by + calc + mFourierCoeff g h = cylinderCoefficient F h t := by + unfold mFourierCoeff cylinderCoefficient + apply integral_congr_ae + filter_upwards [ht.coeFn_toLp] with θ hθ + rw [hθ] + _ = 0 := hct h + have hg : g = 0 := by + apply mFourierBasis.repr.injective + rw [map_zero] + ext h + simpa only [mFourierBasis_repr,lp.coeFn_zero,Pi.zero_apply] using hcg h + have hg' : g =ᵐ[volume] (0 : UnitAddTorus (Fin 2) → ℂ) := by + rw [hg] + exact Lp.coeFn_zero _ _ _ + exact ht.coeFn_toLp.symm.trans hg' + have hn : ‖F‖^2 = 0 := by + rw [complexLp_norm_sq,integral_prod _ ((Lp.memLp F).integrable_norm_pow (by decide : (2:ℕ)≠0))] + apply integral_eq_zero_of_ae + filter_upwards [haslice] with t ht + apply integral_eq_zero_of_ae + filter_upwards [ht] with θ hθ + simp only [hθ,norm_zero,zero_pow (by decide : (2:ℕ)≠0),Pi.zero_apply] + exact norm_eq_zero.mp (sq_eq_zero_iff.mp hn) + +theorem cylinderFourier_surjective (μ : Measure ℝ) [SFinite μ] : + Function.Surjective (cylinderFourier μ) := by + classical + let L := (cylinderFourier μ).toContinuousLinearMap + let K := L.range + have hclosed : IsClosed (K : Set (CylinderL2 μ)) := + (cylinderFourier μ).isometry.isClosedEmbedding.isClosed_range + let : CompleteSpace K := hclosed.completeSpace_coe + have horth : Kᗮ = ⊥ := by + apply le_antisymm ?_ bot_le + intro F hF + change F = 0 + apply cylinderModes_total F + intro h f + apply hF + exact ⟨lp.single 2 h f,(cylinderMode_orthogonal μ).linearIsometry_apply_single f⟩ + have htop : K = ⊤ := (Submodule.orthogonal_eq_bot_iff).mp horth + intro F + have hF : F∈K := by rw [htop]; trivial + exact hF + +def cylinderFourierEquiv (μ : Measure ℝ) [SFinite μ] : + lp (fun _ : TorusModes => Lp ℂ 2 μ) 2 ≃ₗᵢ[ℂ] CylinderL2 μ := + LinearIsometryEquiv.ofSurjective (cylinderFourier μ) (cylinderFourier_surjective μ) + +lemma cylinderCoefficient_fourier {μ : Measure ℝ} [SFinite μ] + (q : lp (fun _ : TorusModes => Lp ℂ 2 μ) 2) (h : TorusModes) : + cylinderCoefficientLp (cylinderFourier μ q) h = q h := by + classical + apply ext_inner_left ℂ + intro f + rw [←cylinderMode_inner_coefficient] + have he : cylinderMode μ h f=cylinderFourier μ (lp.single 2 h f) := + ((cylinderMode_orthogonal μ).linearIsometry_apply_single f).symm + rw [he,(cylinderFourier μ).inner_map_map,lp.inner_single_left] + +lemma cylinderFourierEquiv_symm_apply {μ : Measure ℝ} [SFinite μ] + (F : CylinderL2 μ) (h : TorusModes) : + (cylinderFourierEquiv μ).symm F h = cylinderCoefficientLp F h := by + have he := cylinderCoefficient_fourier ((cylinderFourierEquiv μ).symm F) h + change cylinderCoefficientLp ((cylinderFourierEquiv μ) ((cylinderFourierEquiv μ).symm F)) h=_ at he + simpa only [LinearIsometryEquiv.apply_symm_apply] using he.symm + +theorem cylinderCoefficient_hasSum {μ : Measure ℝ} [SFinite μ] (F : CylinderL2 μ) : + HasSum (fun h => cylinderMode μ h (cylinderCoefficientLp F h)) F := by + have hh := cylinderFourier_hasSum μ ((cylinderFourierEquiv μ).symm F) + simp only [cylinderFourierEquiv_symm_apply] at hh + change HasSum _ ((cylinderFourierEquiv μ) ((cylinderFourierEquiv μ).symm F)) at hh + simpa only [LinearIsometryEquiv.apply_symm_apply] using hh + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierGraph.lean b/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierGraph.lean new file mode 100644 index 0000000000000000000000000000000000000000..118f48e0f8211030491424146c88dbed4e3d66f4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CylinderFourierGraph.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.CylinderPoissonTrace +import OAI.Analysis.Conductivity.Fourier.CylinderFourierComplete + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def cylinderJetCoefficient (R : ℝ) (J : FiniteCylinderJets R) (h : TorusModes) : FiniteAxisJets R := + WithLp.toLp 2 (fun j => cylinderCoefficientLp (J j) h) + +lemma cylinderJetCoefficient_hasSum (R : ℝ) (J : FiniteCylinderJets R) : + HasSum (fun h => cylinderJetMode R h (cylinderJetCoefficient R J h)) J := by + have ht : Tendsto (fun F : Finset TorusModes => fun j => + ∑ h ∈ F,cylinderJetMode R h (cylinderJetCoefficient R J h) j) + atTop (𝓝 (fun j => J j)) := by + apply tendsto_pi_nhds.mpr + intro j + exact cylinderCoefficient_hasSum (J j) + have hmap := (PiLp.continuous_toLp 2 (fun _ : Fin 4 => CylinderL2 (FiniteAxisMeasure R))).continuousAt.tendsto.comp ht + change Tendsto (fun F : Finset TorusModes => ∑ h ∈ F,cylinderJetMode R h (cylinderJetCoefficient R J h)) atTop _ + convert hmap using 1 + funext F + apply PiLp.ext + intro j + simp only [Function.comp_apply,WithLp.ofLp_toLp,WithLp.ofLp_sum,Finset.sum_apply] + +theorem cylinderH1_of_smooth_coefficients (R : ℝ) (J : FiniteCylinderJets R) + (q : TorusModes → smoothComplexAxis) + (hq : ∀ h,cylinderJetCoefficient R J h=smoothAxisModeJet (smoothComplexAxis_smooth (q h)) R h) : + J∈cylinderH1Space R := by + have hsum := cylinderJetCoefficient_hasSum R J + simp only [hq,cylinderJetMode_smooth] at hsum + apply mem_closure_of_tendsto hsum + apply Eventually.of_forall + intro F + apply Submodule.sum_mem + intro h _ + exact ⟨Finsupp.single h (q h),cylinderPolynomialJetL_single R h (q h)⟩ + +theorem cylinderGraph_of_smooth_coefficients (s : Fin 3 → ℝ) (R : ℝ) + (J : FiniteCylinderJets R) (q : TorusModes → smoothComplexAxis) + (hq : ∀ h,cylinderJetCoefficient R J h=smoothAxisModeJet (smoothComplexAxis_smooth (q h)) R h) + (f₀ f₁ : spectralTraceGraph (torusRate s)) + (hf₀ : ∀ h,f₀.val 0 h=q h 0) (hf₁ : ∀ h,f₁.val 0 h=q h R) : + (J,(f₀,f₁))∈cylinderSobolevGraph s R := by + classical + have hsum := cylinderJetCoefficient_hasSum R J + simp only [hq,cylinderJetMode_smooth] at hsum + have hg := hsum.prodMk ((spectralTraceSingle_hasSum s f₀).prodMk (spectralTraceSingle_hasSum s f₁)) + apply mem_closure_of_tendsto hg + apply Eventually.of_forall + intro F + apply Submodule.sum_mem + intro h _ + refine ⟨Finsupp.single h (q h),?_⟩ + change (cylinderPolynomialJetL R (Finsupp.single h (q h)), + (cylinderPolynomialTraceL s 0 (Finsupp.single h (q h)), + cylinderPolynomialTraceL s R (Finsupp.single h (q h))))=_ + rw [cylinderPolynomialJetL_single,cylinderPolynomialTraceL_single,cylinderPolynomialTraceL_single,hf₀,hf₁] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CylinderModeGreen.lean b/lean/OAI/Analysis/Conductivity/Fourier/CylinderModeGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..004d6aa72d1a61782269eca32d7d8f18f95f768c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CylinderModeGreen.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.EndPoissonJets +import OAI.Analysis.Conductivity.Flux.CylinderGreen + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus + +local instance cylinderModeGreenMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance cylinderModeGreenProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +def flatCylinderEnergy (s : Fin 3 → ℝ) {R : ℝ} (u v : FiniteCylinderJets R) : ℂ := + inner ℂ (u 1) (v 1)+(s 0:ℂ)*inner ℂ (u 2) (v 2)+ + (s 1:ℂ)*(inner ℂ (u 2) (v 3)+inner ℂ (u 3) (v 2))+ + (s 2:ℂ)*inner ℂ (u 3) (v 3) + +lemma flatCylinderEnergy_continuous_left (s : Fin 3 → ℝ) {R : ℝ} (v : FiniteCylinderJets R) : + Continuous (fun u => flatCylinderEnergy s u v) := by + unfold flatCylinderEnergy + fun_prop + +lemma flatCylinderEnergy_continuous_right (s : Fin 3 → ℝ) {R : ℝ} (u : FiniteCylinderJets R) : + Continuous (fun v => flatCylinderEnergy s u v) := by + unfold flatCylinderEnergy + fun_prop + +lemma cylinderMode_inner (R : ℝ) (h k : TorusModes) (f g : FiniteAxisL2 R) : + inner ℂ (cylinderMode (FiniteAxisMeasure R) h f) (cylinderMode (FiniteAxisMeasure R) k g)= + if h=k then inner ℂ f g else 0 := by + by_cases he : h=k + · subst k + rw [ite_eq_left rfl] + exact (cylinderMode (FiniteAxisMeasure R) h).inner_map_map f g + · rw [ite_eq_right he] + exact cylinderMode_orthogonal (FiniteAxisMeasure R) he f g + +def smoothCylinderModeJet {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (k : TorusModes) : FiniteCylinderJets R := + WithLp.toLp 2 ![cylinderMode (FiniteAxisMeasure R) k (smoothFiniteAxisLp hq.continuous R), + cylinderMode (FiniteAxisMeasure R) k (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R), + cylinderMode (FiniteAxisMeasure R) k ((Complex.I*(k 0:ℂ))•smoothFiniteAxisLp hq.continuous R), + cylinderMode (FiniteAxisMeasure R) k ((Complex.I*(k 1:ℂ))•smoothFiniteAxisLp hq.continuous R)] + +lemma flatCylinderEnergy_distinct_modes (s : Fin 3 → ℝ) {q : ℝ → ℂ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (R : ℝ) (h k : TorusModes) (a : ℂ) (hne : h≠k) : + flatCylinderEnergy s (endPoissonModeJet s R h a) (smoothCylinderModeJet hq R k)=0 := by + simp only [flatCylinderEnergy,endPoissonModeJet,smoothCylinderModeJet,WithLp.ofLp_toLp, + Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.cons_val_three,Matrix.head_cons,Matrix.tail_cons, + cylinderMode_inner,ite_eq_right hne,mul_zero,add_zero] + +lemma torusRate_sq_of_lower (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (h : TorusModes) : + torusRate s h^2=torusQuadratic s h := by + apply Real.sq_sqrt + exact (show (0:ℝ)≤(1/2)*((h 0:ℝ)^2+(h 1:ℝ)^2) by positivity).trans (hs _ _) + +lemma flatCylinderEnergy_same_mode (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (R : ℝ) (h : TorusModes) (a : ℂ) : + flatCylinderEnergy s (endPoissonModeJet s R h a) (smoothCylinderModeJet hq R h)= + inner ℂ (finiteDecayLp (torusRate s h) R (-(torusRate s h:ℂ)*a)) + (smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R)+ + ((torusRate s h)^2:ℝ)*inner ℂ (finiteDecayLp (torusRate s h) R a) + (smoothFiniteAxisLp hq.continuous R) := by + simp only [flatCylinderEnergy,endPoissonModeJet,smoothCylinderModeJet,WithLp.ofLp_toLp, + Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.cons_val_three,Matrix.head_cons,Matrix.tail_cons, + cylinderMode_inner,ite_true,endModeCoefficient] + simp only [finiteDecayLp_smul,inner_smul_left,inner_smul_right,map_mul,map_intCast,Complex.conj_I] + rw [torusRate_sq_of_lower s hs h] + simp only [torusQuadratic,Complex.ofReal_add,Complex.ofReal_mul,Complex.ofReal_pow, + Complex.ofReal_intCast,Complex.ofReal_ofNat] + ring_nf + simp only [Complex.I_sq] + ring + +theorem flatCylinder_mode_green (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (R : ℝ) (hR : 0≤R) + (h k : TorusModes) (a : ℂ) : + flatCylinderEnergy s (endPoissonModeJet s R h a) (smoothCylinderModeJet hq R k)= + if h=k then + (torusRate s h:ℂ)*inner ℂ a (q 0)- + (torusRate s h*Real.exp (-torusRate s h*R):ℝ)*inner ℂ a (q R) + else 0 := by + by_cases he : h=k + · subst k + rw [ite_eq_left rfl,flatCylinderEnergy_same_mode s hs hq R h a] + exact finiteDecay_green_inner hq _ R hR a + · rw [ite_eq_right he] + exact flatCylinderEnergy_distinct_modes s hq R h k a he + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/CylinderPoissonTrace.lean b/lean/OAI/Analysis/Conductivity/Fourier/CylinderPoissonTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..099864ead0268694784a87ecc9561780f3268d91 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/CylinderPoissonTrace.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CylinderPoissonH1 + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal + +def spectralPoissonTrace (s : Fin 3 → ℝ) (R : ℝ) + (f : spectralTraceGraph (torusRate s)) : spectralTraceGraph (torusRate s) := + ⟨WithLp.toLp 2 (fun j => sequenceMultiplier + (fun h => (Real.exp (-torusRate s h*|R|):ℂ)) 1 zero_le_one + (poissonMultiplier_bound s R) (f.val j)),by + intro h + change (Real.exp (-torusRate s h*|R|):ℂ)*(f.val 1 h)= + (Real.sqrt (torusRate s h):ℂ)*((Real.exp (-torusRate s h*|R|):ℂ)*(f.val 0 h)) + rw [f.property h] + ring⟩ + +lemma spectralTraceSingle_hasSum (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) : + HasSum (fun h => spectralTraceSingleL s h (f.val 0 h)) f := by + have hc (j : Fin 2) : + HasSum (fun h => (spectralTraceSingleL s h (f.val 0 h)).val j) (f.val j) := by + fin_cases j + · exact lp.hasSum_single (by norm_num : (2:ℝ≥0∞)≠⊤) (f.val 0) + · have H := lp.hasSum_single (by norm_num : (2:ℝ≥0∞)≠⊤) (f.val 1) + convert H using 1 + · funext h + change (lp.single 2 h ((Real.sqrt (torusRate s h):ℂ)*f.val 0 h) : SpectralL2 TorusModes)=lp.single 2 h (f.val 1 h) + rw [f.property h] + · rfl + have ht : Tendsto (fun F : Finset TorusModes => fun j => + ∑ h∈F,(spectralTraceSingleL s h (f.val 0 h)).val j) atTop + (𝓝 (fun j => f.val j)) := tendsto_pi_nhds.mpr hc + have H := (PiLp.continuous_toLp 2 (fun _ : Fin 2 => SpectralL2 TorusModes)).continuousAt.tendsto.comp ht + change Tendsto (fun F : Finset TorusModes => ∑ h∈F,spectralTraceSingleL s h (f.val 0 h)) atTop (𝓝 f) + apply tendsto_subtype_rng.mpr + convert H using 1 + funext F + apply PiLp.ext + intro j + simp only [Function.comp_apply,WithLp.ofLp_toLp,Submodule.coe_sum,WithLp.ofLp_sum,Finset.sum_apply] + +lemma cylinderPolynomialJetL_single (R : ℝ) (h : TorusModes) (q : smoothComplexAxis) : + cylinderPolynomialJetL R (Finsupp.single h q)= + smoothCylinderModeJet (smoothComplexAxis_smooth q) R h := by + rw [cylinderPolynomialJetL,Finsupp.lsum_single] + exact cylinderJetMode_smooth _ R h + +lemma cylinderPolynomialTraceL_single (s : Fin 3 → ℝ) (t : ℝ) (h : TorusModes) + (q : smoothComplexAxis) : + cylinderPolynomialTraceL s t (Finsupp.single h q)=spectralTraceSingleL s h (q t) := by + rw [cylinderPolynomialTraceL,Finsupp.lsum_single] + rfl + +lemma endPoissonModeJet_mem_trace_graph (s : Fin 3 → ℝ) {R : ℝ} (_ : 0≤R) + (h : TorusModes) (a : ℂ) : + (endPoissonModeJet s R h a, + (spectralTraceSingleL s h a, + spectralTraceSingleL s h ((Real.exp (-torusRate s h*R):ℂ)*a)))∈cylinderSobolevGraph s R := by + apply Submodule.le_topologicalClosure + refine ⟨Finsupp.single h (⟨axialDecayField (torusRate s h) a,axialDecayField_smooth _ _⟩ : smoothComplexAxis),?_⟩ + apply Prod.ext + · exact (cylinderPolynomialJetL_single R h _).trans (endPoissonModeJet_smooth s R h a).symm + · apply Prod.ext + · change cylinderPolynomialTraceL s 0 _=_ + rw [cylinderPolynomialTraceL_single] + simp only [axialDecayField,mul_zero,Real.exp_zero,Complex.ofReal_one,one_mul] + · change cylinderPolynomialTraceL s R _=_ + rw [cylinderPolynomialTraceL_single] + rfl + +theorem endPoissonJet_mem_trace_graph (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) : + (endPoissonJet s hs R hR f,(f,spectralPoissonTrace s R f))∈cylinderSobolevGraph s R := by + have H := (endPoissonJet_hasSum s hs R hR f).prodMk + ((spectralTraceSingle_hasSum s f).prodMk (spectralTraceSingle_hasSum s (spectralPoissonTrace s R f))) + apply (Submodule.isClosed_topologicalClosure _).mem_of_tendsto H + apply Filter.Eventually.of_forall + intro F + apply Submodule.sum_mem + intro h _ + change (endPoissonModeJet s R h (f.val 0 h), + (spectralTraceSingleL s h (f.val 0 h),spectralTraceSingleL s h + ((Real.exp (-torusRate s h*|R|):ℂ)*(f.val 0 h))))∈cylinderSobolevGraph s R + rw [abs_of_nonneg hR] + exact endPoissonModeJet_mem_trace_graph s hR h _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonDifferential.lean b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..ded461b54ac8596fa09649b4db82fbadfbff2a2f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonDifferential.lean @@ -0,0 +1,155 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusPoissonContinuous +import OAI.Analysis.Conductivity.Fourier.EndPoissonRepresentative + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus + +def endFrequency (s : Fin 3 → ℝ) (h : TorusModes) : (Fin 3 → ℝ) →L[ℝ] ℂ := + (-(torusRate s h:ℂ)) • Complex.ofRealCLM.comp (ContinuousLinearMap.proj 0) + + (Complex.I*(h 0:ℂ)) • Complex.ofRealCLM.comp (ContinuousLinearMap.proj 1) + + (Complex.I*(h 1:ℂ)) • Complex.ofRealCLM.comp (ContinuousLinearMap.proj 2) + +lemma endFrequency_apply (s : Fin 3 → ℝ) (h : TorusModes) (x : Fin 3 → ℝ) : + endFrequency s h x= (-(torusRate s h*x 0):ℝ)+ + (torusAngular h x:ℂ)*Complex.I := by + simp [endFrequency,torusAngular] + ring + +lemma endFrequency_norm_le (s : Fin 3 → ℝ) (h : TorusModes) : + ‖endFrequency s h‖≤torusRate s h+torusSize h := by + apply ContinuousLinearMap.opNorm_le_bound _ (by + have hm : 0≤torusRate s h := Real.sqrt_nonneg _ + linarith [torusSize_nonneg h]) + intro v + have hv (j : Fin 3) : ‖(v j:ℂ)‖≤‖v‖ := by simpa using norm_le_pi_norm v j + have hm : 0≤torusRate s h := Real.sqrt_nonneg _ + change ‖-(torusRate s h:ℂ)*(v 0:ℂ)+Complex.I*(h 0:ℂ)*(v 1:ℂ)+ + Complex.I*(h 1:ℂ)*(v 2:ℂ)‖≤_ + calc + _ ≤ ‖-(torusRate s h:ℂ)*(v 0:ℂ)‖+‖Complex.I*(h 0:ℂ)*(v 1:ℂ)‖+ + ‖Complex.I*(h 1:ℂ)*(v 2:ℂ)‖ := (norm_add_le _ _).trans + (add_le_add (norm_add_le _ _) (le_refl _)) + _ = torusRate s h*‖(v 0:ℂ)‖+|(h 0:ℝ)| *‖(v 1:ℂ)‖+ + |(h 1:ℝ)| *‖(v 2:ℂ)‖ := by simp [abs_of_nonneg hm] + _ ≤ torusRate s h*‖v‖+|(h 0:ℝ)| *‖v‖+|(h 1:ℝ)| *‖v‖ := by gcongr <;> exact hv _ + _ = _ := by dsimp [torusSize]; ring + +def endFlatMode (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (x : Fin 3 → ℝ) : ℂ := + a*Complex.exp (endFrequency s h x) + +lemma endFlatMode_eq (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (x : Fin 3 → ℝ) : + endFlatMode s h a x=endPoissonModeField s h a 0 (x 0,torusAngles x) := by + rw [endFlatMode,endFrequency_apply,Complex.exp_add,←Complex.ofReal_exp] + rw [endPoissonModeField,mFourier_torusAngles] + change a*((Real.exp (-(torusRate s h*x 0)):ℂ)*_) = + (Real.exp (-torusRate s h*x 0):ℂ)*a*_ + rw [neg_mul] + ring + +lemma endFlatMode_norm (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (x : Fin 3 → ℝ) : + ‖endFlatMode s h a x‖=‖a‖*Real.exp (-torusRate s h*x 0) := by + rw [endFlatMode,norm_mul,Complex.norm_exp,endFrequency_apply] + simp + +lemma endFlatMode_hasFDeriv (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (x : Fin 3 → ℝ) : + HasFDerivAt (endFlatMode s h a) (endFlatMode s h a x • endFrequency s h) x := by + convert! ((endFrequency s h).hasFDerivAt (x:=x)).cexp.const_mul a using 1 + simp only [endFlatMode,mul_smul] + +lemma endFlatMode_derivative_bound (s : Fin 3 → ℝ) (h : TorusModes) + {a : ℂ} {B δ : ℝ} (ha : ‖a‖≤B) {x : Fin 3 → ℝ} (hx : δ≤x 0) : + ‖endFlatMode s h a x • endFrequency s h‖≤ + B*((torusRate s h+torusSize h)*Real.exp (-δ*torusRate s h)) := by + have hm : 0≤torusRate s h := Real.sqrt_nonneg _ + have hr : 0≤torusRate s h+torusSize h := add_nonneg hm (torusSize_nonneg h) + have he : Real.exp (-torusRate s h*x 0)≤Real.exp (-δ*torusRate s h) := by + apply Real.exp_le_exp.mpr + nlinarith [mul_le_mul_of_nonneg_left hx hm] + rw [norm_smul,endFlatMode_norm] + calc + _ ≤ (B*Real.exp (-δ*torusRate s h))*(torusRate s h+torusSize h) := + mul_le_mul (mul_le_mul ha he (Real.exp_nonneg _) ((norm_nonneg _).trans ha)) + (endFrequency_norm_le s h) (norm_nonneg _) (mul_nonneg ((norm_nonneg _).trans ha) (Real.exp_nonneg _)) + _ = _ := by ring + +def endFlatPoisson (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (x : Fin 3 → ℝ) : ℂ := ∑' h,endFlatMode s h (f.val 0 h) x + +lemma endFlatPoisson_eq (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (x : Fin 3 → ℝ) : + endFlatPoisson s f x=endPoissonField s f 0 (x 0,torusAngles x) := by + exact tsum_congr (fun h => endFlatMode_eq s h (f.val 0 h) x) + +lemma endFlatPoisson_derivative_summable (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) {x : Fin 3 → ℝ} (hx : 0 endFlatMode s h (f.val 0 h) x • endFrequency s h) := by + apply Summable.of_norm + have hu : Summable (fun h => ‖f.val 0‖*((torusRate s h+torusSize h)* + Real.exp (-x 0*torusRate s h))) := by + simpa only [pow_one] using (flatMode_derivative_summable hs 1 hx).mul_left ‖f.val 0‖ + exact hu.of_nonneg_of_le (fun h => norm_nonneg _) (fun h => + endFlatMode_derivative_bound s h (lp.norm_apply_le_norm (by norm_num) (f.val 0) h) le_rfl) + +theorem endFlatPoisson_hasFDeriv (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) {x : Fin 3 → ℝ} (hx : 0 ‖f.val 0‖*((torusRate s h+torusSize h)* + Real.exp (-(x 0/2)*torusRate s h))) := by + simpa only [pow_one] using + (flatMode_derivative_summable hs 1 (show 0 endFlatMode_hasFDeriv s h (f.val 0 h) y) + (fun h y hy => endFlatMode_derivative_bound s h + (lp.norm_apply_le_norm (by norm_num) (f.val 0) h) hy.le) + (show x 0/2 simp [endFrequency,endPoissonModeField,endModeCoefficient] <;> ring + +lemma endFlatPoisson_derivative_axis (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) {x : Fin 3 → ℝ} (hx : 0 L (Pi.single j 1)) + (endFlatPoisson_hasFDeriv s hs f hx).fderiv + _ = ∑' h,(endFlatMode s h (f.val 0 h) x • endFrequency s h) (Pi.single j 1) := + (ContinuousLinearMap.apply ℝ ℂ (Pi.single j 1)).map_tsum + (endFlatPoisson_derivative_summable s hs f hx) + _ = _ := tsum_congr (fun h => endFlatMode_axis s h (f.val 0 h) x j) + +lemma endFlatPoisson_real_derivative_axis (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) {x : Fin 3 → ℝ} (hx : 0 (endFlatPoisson s f y).re) x (Pi.single j 1)= + (endPoissonField s f j.succ (x 0,torusAngles x)).re := by + have he := endFlatPoisson_hasFDeriv s hs f hx + have hr := (Complex.reCLM.hasFDerivAt.comp x he).fderiv + calc + _ = ((∑' h,endFlatMode s h (f.val 0 h) x • endFrequency s h) (Pi.single j 1)).re := + congrArg (fun L : (Fin 3 → ℝ) →L[ℝ] ℝ => L (Pi.single j 1)) hr + _ = (fderiv ℝ (endFlatPoisson s f) x (Pi.single j 1)).re := + congrArg (fun L : (Fin 3 → ℝ) →L[ℝ] ℂ => (L (Pi.single j 1)).re) he.fderiv.symm + _ = _ := congrArg Complex.re (endFlatPoisson_derivative_axis s hs f hx j) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonJets.lean b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..54b3ee8225e9fce0d759669096c7d2ad9cc9034b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonJets.lean @@ -0,0 +1,259 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.AxialDecayL2 + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma finiteDecayLp_real_norm_sq (m R r : ℝ) (a : ℂ) : + ‖finiteDecayLp m R ((r:ℂ)*a)‖^2=r^2*‖finiteDecayLp m R a‖^2 := by + rw [finiteDecayLp_smul,norm_smul,mul_pow,Complex.norm_real,Real.norm_eq_abs,sq_abs] + +lemma finiteDecayLp_imag_norm_sq (m R r : ℝ) (a : ℂ) : + ‖finiteDecayLp m R (Complex.I*(r:ℂ)*a)‖^2=r^2*‖finiteDecayLp m R a‖^2 := by + rw [finiteDecayLp_smul,norm_smul,norm_mul,Complex.norm_I,one_mul,mul_pow, + Complex.norm_real,Real.norm_eq_abs,sq_abs] + +lemma torusFrequency_sq_le_rate (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (h : TorusModes) (j : Fin 2) : (h j:ℝ)^2 ≤ 4*(torusRate s h)^2 := by + have hh := torusRate_lower hs h + have hj : |(h j:ℝ)| ≤ torusSize h := by + fin_cases j <;> simp only [torusSize,Fin.zero_eta,Fin.mk_one] + · exact le_add_of_nonneg_right (abs_nonneg _) + · exact le_add_of_nonneg_left (abs_nonneg _) + have hnon : 0 ≤ torusRate s h := Real.sqrt_nonneg _ + have habs : |(h j:ℝ)| ≤ 2*torusRate s h := by linarith + have he := pow_le_pow_left₀ (abs_nonneg (h j:ℝ)) habs 2 + simpa only [sq_abs,mul_pow,show (2:ℝ)^2=4 by norm_num] using he + +lemma finiteDecayLp_angular_bound (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (h : TorusModes) (j : Fin 2) (a : ℂ) : + ‖finiteDecayLp (torusRate s h) R (Complex.I*(h j:ℂ)*a)‖^2 ≤ + 2*torusRate s h*‖a‖^2 := by + have hr := finiteDecayLp_rate_norm_sq (torusRate s h) R (Real.sqrt_nonneg _) a + rw [finiteDecayLp_real_norm_sq] at hr + have hh := mul_le_mul_of_nonneg_right (torusFrequency_sq_le_rate s hs h j) + (sq_nonneg ‖finiteDecayLp (torusRate s h) R a‖) + have he : (h j:ℂ)=((h j:ℝ):ℂ) := by norm_cast + rw [he,finiteDecayLp_imag_norm_sq] + nlinarith only [hr,hh] + +lemma finiteDecayLp_axial_bound (m R : ℝ) (hm : 0 ≤ m) (a : ℂ) : + ‖finiteDecayLp m R (-(m:ℂ)*a)‖^2 ≤ m*‖a‖^2/2 := by + have hh := finiteDecayLp_rate_norm_sq m R hm a + rw [finiteDecayLp_real_norm_sq] at hh + rw [show -(m:ℂ)=((-m:ℝ):ℂ) by simp,finiteDecayLp_real_norm_sq,neg_sq] + exact hh + +def endModeCoefficient (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) : Fin 4 → ℂ := + ![a,-(torusRate s h:ℂ)*a,Complex.I*(h 0:ℂ)*a,Complex.I*(h 1:ℂ)*a] + +abbrev FiniteCylinderJets (R : ℝ) := + PiLp 2 (fun _ : Fin 4 => CylinderL2 (FiniteAxisMeasure R)) + +def endPoissonSequence (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : + lp (fun _ : TorusModes => FiniteAxisL2 R) 2 := + ⟨fun h => finiteDecayLp (torusRate s h) R (endModeCoefficient s h (f.val 0 h) j),by + have hu := (lp.memℓp (f.val 0)).summable (by norm_num : 0 < (2:ℝ≥0∞).toReal) + simp only [ENNReal.toReal_ofNat,Real.rpow_two] at hu + have hw : Summable (fun h => torusRate s h*‖f.val 0 h‖^2) := + (spectralTraceGraph_exists_iff (fun h => Real.sqrt_nonneg _) (f.val 0)).mp ⟨f,rfl⟩ + apply (memℓp_gen_iff (by norm_num : 0 < (2:ℝ≥0∞).toReal)).mpr + simp only [ENNReal.toReal_ofNat,Real.rpow_two] + fin_cases j + · exact (hu.mul_left R).of_nonneg_of_le (fun h => sq_nonneg _) + (fun h => finiteDecayLp_norm_sq (Real.sqrt_nonneg _) hR (f.val 0 h)) + · exact (hw.div_const 2).of_nonneg_of_le (fun h => sq_nonneg _) + (fun h => finiteDecayLp_axial_bound (torusRate s h) R (Real.sqrt_nonneg _) (f.val 0 h)) + · exact (hw.mul_left 2).of_nonneg_of_le (fun h => sq_nonneg _) + (fun h => by simpa [endModeCoefficient,mul_assoc] using finiteDecayLp_angular_bound s hs R h 0 (f.val 0 h)) + · exact (hw.mul_left 2).of_nonneg_of_le (fun h => sq_nonneg _) + (fun h => by simpa [endModeCoefficient,mul_assoc] using finiteDecayLp_angular_bound s hs R h 1 (f.val 0 h))⟩ + +def endPoissonJet (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) (f : spectralTraceGraph (torusRate s)) : FiniteCylinderJets R := + WithLp.toLp 2 (fun j => cylinderFourier (FiniteAxisMeasure R) (endPoissonSequence s hs R hR f j)) + +def endPoissonModeJet (s : Fin 3 → ℝ) (R : ℝ) (h : TorusModes) (a : ℂ) : FiniteCylinderJets R := + WithLp.toLp 2 (fun j => cylinderMode (FiniteAxisMeasure R) h + (finiteDecayLp (torusRate s h) R (endModeCoefficient s h a j))) + +lemma endPoissonJet_component_hasSum (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : + HasSum (fun h => endPoissonModeJet s R h (f.val 0 h) j) (endPoissonJet s hs R hR f j) := + cylinderFourier_hasSum (FiniteAxisMeasure R) (endPoissonSequence s hs R hR f j) + +lemma endPoissonJet_hasSum (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) (f : spectralTraceGraph (torusRate s)) : + HasSum (fun h => endPoissonModeJet s R h (f.val 0 h)) (endPoissonJet s hs R hR f) := by + have ht : Tendsto (fun F : Finset TorusModes => fun j => ∑ h ∈ F,endPoissonModeJet s R h (f.val 0 h) j) + atTop (𝓝 (fun j => endPoissonJet s hs R hR f j)) := by + apply tendsto_pi_nhds.mpr + intro j + exact endPoissonJet_component_hasSum s hs R hR f j + have hmap := (PiLp.continuous_toLp 2 (fun _ : Fin 4 => CylinderL2 (FiniteAxisMeasure R))).continuousAt.tendsto.comp ht + change Tendsto (fun F : Finset TorusModes => ∑ h ∈ F,endPoissonModeJet s R h (f.val 0 h)) atTop _ + convert hmap using 1 + funext F + apply PiLp.ext + intro j + simp only [Function.comp_apply,WithLp.ofLp_toLp,WithLp.ofLp_sum,Finset.sum_apply] + +theorem endPoissonJet_mem_mode_closure (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) (f : spectralTraceGraph (torusRate s)) : + endPoissonJet s hs R hR f ∈ closure + {u : FiniteCylinderJets R | ∃ (F : Finset TorusModes) (a : TorusModes → ℂ), + u=∑ h ∈ F,endPoissonModeJet s R h (a h)} := by + apply mem_closure_of_tendsto (endPoissonJet_hasSum s hs R hR f) + exact Filter.Eventually.of_forall (fun F => ⟨F,fun h => f.val 0 h,rfl⟩) + +end + +open Set MeasureTheory Filter Topology +open scoped ENNReal + +lemma spectralGraph_norm_sq {ι : Type*} (w : ι → ℝ) (f : spectralTraceGraph w) : + ‖f‖^2=‖f.val 0‖^2+‖f.val 1‖^2 := by + change ‖f.val‖^2=_ + rw [PiLp.norm_sq_eq_of_L2] + simp only [Fin.sum_univ_two] + +lemma spectralGraph_weight_norm_sq {ι : Type*} (w : ι → ℝ) (hw : ∀ i,0 ≤ w i) + (f : spectralTraceGraph w) : + ‖f.val 1‖^2=∑' i,w i*‖f.val 0 i‖^2 := by + have hn := lp.norm_rpow_eq_tsum (by norm_num : 0<(2:ℝ≥0∞).toReal) (f.val 1) + have he (i : ι) : ‖f.val 1 i‖^2=w i*‖f.val 0 i‖^2 := by + rw [f.property i] + exact sqrt_weight_norm_sq hw (f.val 0) i + simpa only [ENNReal.toReal_ofNat,Real.rpow_two,he] using hn + +lemma endModeCoefficient_add (s : Fin 3 → ℝ) (h : TorusModes) (a b : ℂ) (j : Fin 4) : + endModeCoefficient s h (a+b) j=endModeCoefficient s h a j+endModeCoefficient s h b j := by + fin_cases j <;> simp [endModeCoefficient,mul_add] + +lemma endModeCoefficient_smul (s : Fin 3 → ℝ) (h : TorusModes) (c a : ℂ) (j : Fin 4) : + endModeCoefficient s h (c*a) j=c*endModeCoefficient s h a j := by + fin_cases j <;> dsimp [endModeCoefficient] <;> ring + +variable (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0 ≤ R) + +lemma endPoissonSequence_add (f g : spectralTraceGraph (torusRate s)) (j : Fin 4) : + endPoissonSequence s hs R hR (f+g) j= + endPoissonSequence s hs R hR f j+endPoissonSequence s hs R hR g j := by + apply lp.ext + funext h + change finiteDecayLp _ _ (endModeCoefficient s h (f.val 0 h+g.val 0 h) j)=_ + rw [endModeCoefficient_add,finiteDecayLp_add] + rfl + +lemma endPoissonSequence_smul (c : ℂ) (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : + endPoissonSequence s hs R hR (c•f) j=c•endPoissonSequence s hs R hR f j := by + apply lp.ext + funext h + change finiteDecayLp _ _ (endModeCoefficient s h (c*f.val 0 h) j)=_ + rw [endModeCoefficient_smul,finiteDecayLp_smul] + rfl + +lemma endPoissonJet_add (f g : spectralTraceGraph (torusRate s)) : + endPoissonJet s hs R hR (f+g)=endPoissonJet s hs R hR f+endPoissonJet s hs R hR g := by + apply PiLp.ext + intro j + change cylinderFourier _ (endPoissonSequence _ _ _ _ (f+g) j)=_ + rw [endPoissonSequence_add,map_add] + rfl + +lemma endPoissonJet_smul (c : ℂ) (f : spectralTraceGraph (torusRate s)) : + endPoissonJet s hs R hR (c•f)=c•endPoissonJet s hs R hR f := by + apply PiLp.ext + intro j + change cylinderFourier _ (endPoissonSequence _ _ _ _ (c•f) j)=_ + rw [endPoissonSequence_smul,map_smul] + rfl + +lemma endPoissonJet_component_norm_sq (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : + ‖endPoissonJet s hs R hR f j‖^2= + ∑' h,‖finiteDecayLp (torusRate s h) R (endModeCoefficient s h (f.val 0 h) j)‖^2 := + cylinderFourier_norm_sq _ _ + +lemma endPoissonJet_component_bound (f : spectralTraceGraph (torusRate s)) : + ‖endPoissonJet s hs R hR f 0‖^2 ≤ R*‖f.val 0‖^2 ∧ + ‖endPoissonJet s hs R hR f 1‖^2 ≤ ‖f.val 1‖^2/2 ∧ + ‖endPoissonJet s hs R hR f 2‖^2 ≤ 2*‖f.val 1‖^2 ∧ + ‖endPoissonJet s hs R hR f 3‖^2 ≤ 2*‖f.val 1‖^2 := by + have hu := (lp.memℓp (f.val 0)).summable (by norm_num : 0<(2:ℝ≥0∞).toReal) + simp only [ENNReal.toReal_ofNat,Real.rpow_two] at hu + have hw : Summable (fun h => torusRate s h*‖f.val 0 h‖^2) := + (spectralTraceGraph_exists_iff (fun h => Real.sqrt_nonneg _) (f.val 0)).mp ⟨f,rfl⟩ + have huEq : ‖f.val 0‖^2=∑' h,‖f.val 0 h‖^2 := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using + lp.norm_rpow_eq_tsum (by norm_num : 0<(2:ℝ≥0∞).toReal) (f.val 0) + have hwEq := spectralGraph_weight_norm_sq (torusRate s) (fun h => Real.sqrt_nonneg _) f + have hj (j : Fin 4) : Summable (fun h => + ‖finiteDecayLp (torusRate s h) R (endModeCoefficient s h (f.val 0 h) j)‖^2) := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two,endPoissonSequence] using + (lp.memℓp (endPoissonSequence s hs R hR f j)).summable + (by norm_num : 0<(2:ℝ≥0∞).toReal) + refine ⟨?_,?_,?_,?_⟩ + · rw [endPoissonJet_component_norm_sq,huEq,←tsum_mul_left] + exact (hj 0).tsum_le_tsum (fun h => finiteDecayLp_norm_sq (Real.sqrt_nonneg _) hR (f.val 0 h)) + (hu.mul_left R) + · rw [endPoissonJet_component_norm_sq,hwEq,←tsum_div_const] + exact (hj 1).tsum_le_tsum (fun h => finiteDecayLp_axial_bound _ _ (Real.sqrt_nonneg _) (f.val 0 h)) + (hw.div_const 2) + · rw [endPoissonJet_component_norm_sq,hwEq,←tsum_mul_left] + exact (hj 2).tsum_le_tsum (fun h => by + simpa [endModeCoefficient,mul_assoc] using finiteDecayLp_angular_bound s hs R h 0 (f.val 0 h)) + (hw.mul_left 2) + · rw [endPoissonJet_component_norm_sq,hwEq,←tsum_mul_left] + exact (hj 3).tsum_le_tsum (fun h => by + simpa [endModeCoefficient,mul_assoc] using finiteDecayLp_angular_bound s hs R h 1 (f.val 0 h)) + (hw.mul_left 2) + +lemma endPoissonJet_norm_sq_le (f : spectralTraceGraph (torusRate s)) : + ‖endPoissonJet s hs R hR f‖^2 ≤ (R+5)*‖f‖^2 := by + obtain ⟨h0,h1,h2,h3⟩ := endPoissonJet_component_bound s hs R hR f + rw [PiLp.norm_sq_eq_of_L2] + simp only [Fin.sum_univ_four] + rw [spectralGraph_norm_sq] + nlinarith [sq_nonneg ‖f.val 0‖,sq_nonneg ‖f.val 1‖,mul_nonneg hR (sq_nonneg ‖f.val 1‖)] + +lemma endPoissonJet_norm_le (f : spectralTraceGraph (torusRate s)) : + ‖endPoissonJet s hs R hR f‖ ≤ (R+6)*‖f‖ := by + have hn := endPoissonJet_norm_sq_le s hs R hR f + have hb : R+5 ≤ (R+6)^2 := by nlinarith [sq_nonneg R] + have hh := mul_le_mul_of_nonneg_right hb (sq_nonneg ‖f‖) + nlinarith [norm_nonneg (endPoissonJet s hs R hR f),norm_nonneg f, + mul_nonneg (show 0 ≤ R+6 by linarith) (norm_nonneg f)] + +def endPoissonCLM : spectralTraceGraph (torusRate s) →L[ℂ] FiniteCylinderJets R := + ({ toFun := fun f => endPoissonJet s hs R hR f + map_add' := endPoissonJet_add s hs R hR + map_smul' := endPoissonJet_smul s hs R hR } : + spectralTraceGraph (torusRate s) →ₗ[ℂ] FiniteCylinderJets R).mkContinuous (R+6) + (endPoissonJet_norm_le s hs R hR) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonRepresentative.lean b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonRepresentative.lean new file mode 100644 index 0000000000000000000000000000000000000000..47f61a17323006bc38ff9149bff31362161e0a5c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/EndPoissonRepresentative.lean @@ -0,0 +1,192 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusFlatMode +import OAI.Analysis.Conductivity.Sobolev.CollarLpPullback +import OAI.Analysis.Conductivity.Fourier.EndPoissonJets + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma lp_hasSum_ae_unique {X E ι : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [Countable ι] [Infinite ι] + {μ : Measure X} {p : ℝ≥0∞} [Fact (1≤p)] + {u : Lp E p μ} {f : ι → Lp E p μ} {a : ι → X → E} {g : X → E} + (hf : HasSum f u) (ha : ∀ i,f i=ᵐ[μ] a i) + (hg : ∀ᵐ x∂μ,HasSum (fun i => a i x) (g x)) : u=ᵐ[μ] g := by + obtain ⟨e⟩ := nonempty_equiv_of_countable (α:=ℕ) (β:=ι) + have ht := (e.hasSum_iff.mpr hf).tendsto_sum_nat + obtain ⟨ns,hns,hn⟩ := (tendstoInMeasure_of_tendsto_Lp ht).exists_seq_tendsto_ae + have hs : ∀ᵐ x∂μ,∀ n : ℕ,(∑ i∈Finset.range n,f (e i)) x= + ∑ i∈Finset.range n,a (e i) x := by + have hA : ∀ᵐ x∂μ,∀ i : ℕ,f (e i) x=a (e i) x := ae_all_iff.mpr (fun i => ha (e i)) + have hF : ∀ᵐ x∂μ,∀ n : ℕ,(∑ i∈Finset.range n,f (e i)) x= + ∑ i∈Finset.range n,f (e i) x := + ae_all_iff.mpr (fun n => Lp.coeFn_fun_finsetSum (Finset.range n) (fun i => f (e i))) + filter_upwards [hA,hF] with x hx hy n + rw [hy] + exact Finset.sum_congr rfl (fun i _ => hx i) + filter_upwards [hg,hn,hs] with x hx hn hs + have hpoint := ((e.hasSum_iff.mpr hx).tendsto_sum_nat).comp hns.tendsto_atTop + have hco : (fun i => (∑ k∈Finset.range (ns i),f (e k)) x)= + (fun i => ∑ k∈Finset.range (ns i),a (e k) x) := funext (fun i => hs (ns i)) + change Tendsto (fun i => (∑ k∈Finset.range (ns i),f (e k)) x) atTop (𝓝 (u x)) at hn + rw [hco] at hn + exact tendsto_nhds_unique hn hpoint + +def endPoissonModeField (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (j : Fin 4) + (z : ℝ × UnitAddTorus (Fin 2)) : ℂ := + (Real.exp (-torusRate s h*z.1):ℂ)*endModeCoefficient s h a j*mFourier h z.2 + +def endPoissonField (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) (j : Fin 4) + (z : ℝ × UnitAddTorus (Fin 2)) : ℂ := + ∑' h,endPoissonModeField s h (f.val 0 h) j z + +lemma endPoissonModeJet_ae (s : Fin 3 → ℝ) (R : ℝ) (h : TorusModes) (a : ℂ) (j : Fin 4) : + endPoissonModeJet s R h a j=ᵐ[(FiniteAxisMeasure R).prod volume] + endPoissonModeField s h a j := by + have h1 := (Measure.quasiMeasurePreserving_fst + (μ := FiniteAxisMeasure R) (ν := (volume : Measure (UnitAddTorus (Fin 2))))).ae + (finiteDecayLp_ae (torusRate s h) R (endModeCoefficient s h a j)) + have h2 := (Measure.quasiMeasurePreserving_snd + (μ := FiniteAxisMeasure R) (ν := (volume : Measure (UnitAddTorus (Fin 2))))).ae (coeFn_mFourierLp 2 h) + filter_upwards [cylinderTensor_ae + (finiteDecayLp (torusRate s h) R (endModeCoefficient s h a j)) (mFourierLp 2 h),h1,h2] + with z hz h1 h2 + change cylinderTensor _ _ z=_ + rw [hz,h1,h2] + rfl + +lemma endModeCoefficient_norm_bound (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) (j : Fin 4) : + ‖endModeCoefficient s h a j‖ ≤ (1+torusRate s h+torusSize h)*‖a‖ := by + have hm : 0≤torusRate s h := Real.sqrt_nonneg _ + have hsize := torusSize_nonneg h + fin_cases j + · change ‖a‖≤_ + nlinarith [mul_nonneg hm (norm_nonneg a),mul_nonneg hsize (norm_nonneg a)] + · change ‖-(torusRate s h:ℂ)*a‖≤_ + rw [norm_mul,norm_neg,Complex.norm_real,Real.norm_eq_abs,abs_of_nonneg hm] + exact mul_le_mul_of_nonneg_right (by linarith) (norm_nonneg a) + · change ‖Complex.I*(h 0:ℂ)*a‖≤_ + rw [norm_mul,norm_mul,Complex.norm_I,one_mul] + have he : ‖(h 0:ℂ)‖=|(h 0:ℝ)| := by simp + rw [he] + have hh : |(h 0:ℝ)|≤torusSize h := le_add_of_nonneg_right (abs_nonneg _) + exact mul_le_mul_of_nonneg_right (by linarith) (norm_nonneg a) + · change ‖Complex.I*(h 1:ℂ)*a‖≤_ + rw [norm_mul,norm_mul,Complex.norm_I,one_mul] + have he : ‖(h 1:ℂ)‖=|(h 1:ℝ)| := by simp + rw [he] + have hh : |(h 1:ℝ)|≤torusSize h := le_add_of_nonneg_left (abs_nonneg _) + exact mul_le_mul_of_nonneg_right (by linarith) (norm_nonneg a) + +lemma endPoissonField_hasSum (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) (j : Fin 4) + {z : ℝ × UnitAddTorus (Fin 2)} (hz : 0 endPoissonModeField s h (f.val 0 h) j z) (endPoissonField s f j z) := by + apply Summable.hasSum + apply Summable.of_norm + have hb : Summable (fun h => ‖f.val 0‖*((1+torusRate s h+torusSize h)* + Real.exp (-z.1*torusRate s h))) := by + have h0 := torusRate_exp_summable hs hz + have h1 := flatMode_derivative_summable hs 1 hz + simpa only [pow_one,add_mul,one_mul,add_assoc] using (h0.add h1).mul_left ‖f.val 0‖ + apply hb.of_nonneg_of_le (fun h => norm_nonneg _) (fun h => ?_) + have hc := endModeCoefficient_norm_bound s h (f.val 0 h) j + have ha := lp.norm_apply_le_norm (by norm_num : (2:ℝ≥0∞)≠0) (f.val 0) h + have hp : 0≤1+torusRate s h+torusSize h := by + have hm : 0≤torusRate s h := Real.sqrt_nonneg _ + linarith [torusSize_nonneg h] + have hc' := hc.trans (mul_le_mul_of_nonneg_left ha hp) + have hm : ‖mFourier h z.2‖≤1 := by simpa only [mFourier_norm] using (mFourier h).norm_coe_le_norm z.2 + unfold endPoissonModeField + rw [norm_mul,norm_mul,Complex.norm_real,Real.norm_eq_abs,abs_of_pos (Real.exp_pos _)] + calc + _ ≤ (Real.exp (-torusRate s h*z.1)*((1+torusRate s h+torusSize h)*‖f.val 0‖))*1 := + mul_le_mul (mul_le_mul_of_nonneg_left hc' (Real.exp_nonneg _)) hm (norm_nonneg _) + (mul_nonneg (Real.exp_nonneg _) (mul_nonneg hp (norm_nonneg _))) + _ = _ := by rw [show -torusRate s h*z.1= -z.1*torusRate s h by ring]; ring + +theorem endPoissonJet_ae (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : + endPoissonJet s hs R hR f j=ᵐ[(FiniteAxisMeasure R).prod volume] endPoissonField s f j := by + apply lp_hasSum_ae_unique (endPoissonJet_component_hasSum s hs R hR f j) + (fun h => endPoissonModeJet_ae s R h (f.val 0 h) j) + have ht : ∀ᵐ t∂FiniteAxisMeasure R,0 (continuous_endPoissonModeField s h (f.val 0 h) j).measurable) + +def physicalEndPoissonField (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : (Fin 3 → ℝ) → ℂ := + endPoissonField s f j ∘ sourcePhysicalCoordinates + +lemma measurable_physicalEndPoissonField (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (j : Fin 4) : Measurable (physicalEndPoissonField s f j) := + (measurable_endPoissonField s f j).comp measurable_sourcePhysicalCoordinates + +lemma physicalEndPoissonField_angular (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (j : Fin 4) {t : ℝ} + (ht : t∈Icc (-(1:ℝ)/100) (1/100)) (θ : UnitAddTorus (Fin 2)) : + physicalEndPoissonField s f j (sourceAngularCollar t θ)=endPoissonField s f j (t,θ) := by + simp only [physicalEndPoissonField,Function.comp_apply,sourcePhysicalCoordinates_angular ht] + +def physicalEndPoissonJet (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (hR' : R≤1/100) (f : spectralTraceGraph (torusRate s)) + (j : Fin 4) : Lp ℂ 2 (sourcePhysicalCollarMeasure 0 R) := + sourceCollarPullback hR (by norm_num) hR' (endPoissonJet s hs R hR f j) + +lemma physicalEndPoissonJet_ae (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (hR' : R≤1/100) (f : spectralTraceGraph (torusRate s)) + (j : Fin 4) : physicalEndPoissonJet s hs R hR hR' f j=ᵐ[sourcePhysicalCollarMeasure 0 R] + physicalEndPoissonField s f j := + sourceCollarPullback_ae_of_ae hR (by norm_num) hR' _ (endPoissonJet_ae s hs R hR f j) + +lemma physicalEndPoissonField_memLp (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (hR' : R≤1/100) (f : spectralTraceGraph (torusRate s)) + (j : Fin 4) : MemLp (physicalEndPoissonField s f j) 2 (sourcePhysicalCollarMeasure 0 R) := + (memLp_congr_ae (physicalEndPoissonJet_ae s hs R hR hR' f j)).mp + (Lp.memLp (physicalEndPoissonJet s hs R hR hR' f j)) + +lemma physicalEndPoissonJet_hasSum (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (hR' : R≤1/100) (f : spectralTraceGraph (torusRate s)) + (j : Fin 4) : + HasSum (fun h => sourceCollarPullback hR (by norm_num) hR' + (endPoissonModeJet s R h (f.val 0 h) j)) + (physicalEndPoissonJet s hs R hR hR' f j) := + sourceCollarPullback_hasSum hR (by norm_num) hR' (endPoissonJet_component_hasSum s hs R hR f j) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinMiddleModel.lean b/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinMiddleModel.lean new file mode 100644 index 0000000000000000000000000000000000000000..568a628f1a6bbff7ef81483b2f9ab1ef0da210f9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinMiddleModel.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.PeriodicBandCompactness +import OAI.Analysis.Conductivity.Walls.EndingJoinCutoff + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def delayedInitialTensor (lam k J R : ℝ) (x : Coord3) : Mat3 := + fun i j => pureModeTensor (initialConnectorAngular (lam/k) (1/2) J (k*(x 0-R))) 1 + (angularAxisSwap i) (angularAxisSwap j) + +lemma delayedInitialTensor_smooth (lam k J R : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (delayedInitialTensor lam k J R) := by + have hq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x : Coord3 => initialConnectorAngular (lam/k) (1/2) J (k*(x 0-R))) := + (initialConnectorAngular_smooth _ _ _).comp (contDiff_const.mul ((contDiff_apply ℝ ℝ 0).sub contDiff_const)) + have hh := pureModeTensor_smooth hq (1:Fin 3) + apply contDiff_pi.mpr; intro i + apply contDiff_pi.mpr; intro j + exact contDiff_pi.mp (contDiff_pi.mp hh (angularAxisSwap i)) (angularAxisSwap j) + +lemma delayedInitialTensor_symm (lam k J R : ℝ) (x : Coord3) : + (delayedInitialTensor lam k J R x).IsSymm := by + ext i j + exact congrFun (congrFun (pureModeTensor_symm _ _) (angularAxisSwap i)) (angularAxisSwap j) + +lemma delayedEndingTensor_initial {lam k J L K R : ℝ} (x : Coord3) (hx : k*(x 0-R) (endingJoinMiddleTensor s lam k J x).val) := by + have hχ := endingJoinCutoff_smooth.comp (contDiff_apply ℝ ℝ (0:Fin 3)) + exact ((contDiff_const.sub hχ).smul contDiff_const).add (hχ.smul (delayedInitialTensor_smooth _ _ _ _)) + +lemma endingJoinMiddle_regular_ae (s : Fin 3 → ℝ) (lam J : ℝ) {k : ℝ} (hk : k≠0) : + ∀ᵐ x : Coord3,x∈regularRegion (wallCoordinatePair (pureWallMode 1 lam k)) + (endingJoinMiddleTensor s lam k J) univ := by + have hu : ContDiff ℝ (↑(⊤:ℕ∞)) (wallCoordinatePair (pureWallMode 1 lam k)) := + wallCoordinatePair_smooth (pureWallMode_smooth _ _ _) + have hh := regularRegion_ae_of_simple_minor hu (endingJoinMiddleTensor_smooth s lam k J) isOpen_univ + (fun x _ hx => (pureMode_pairMinor_noncritical (by norm_num : (1:ℝ)≠0) hk x).resolve_left (not_not.mpr hx)) + filter_upwards [hh] with x hx + exact hx (mem_univ _) + +lemma wallCoordinatePair_pure (lam k : ℝ) (x : Coord3) : + wallCoordinatePair (pureWallMode 1 lam k) x=![x 0,exp (-lam*x 0)*cos (k*x 2)] := by + simp [wallCoordinatePair,pureWallMode,boxCoordinates_apply] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinPeriodicity.lean b/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinPeriodicity.lean new file mode 100644 index 0000000000000000000000000000000000000000..3666b0ced1f85f37bc1fd6eadd1003d5b7dba7c1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/EndingJoinPeriodicity.lean @@ -0,0 +1,31 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.EndingJoinCutoff + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma delayedEndingTensor_periodic (lam J L K R : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (delayedEndingTensor lam k J L K R) := by + intro n x + change alignedEndingTensor lam k J L K (x+angularShift (2*Real.pi) n-Pi.single 0 R)=_ + rw [add_sub_right_comm,alignedEndingTensor_angularPeriodic] + rfl + +lemma endingJoinTensor_periodic {D : Coord3 → Mat3} + (hD : AngularPeriodic (2*Real.pi) D) (lam J L K : ℝ) (k : ℤ) : + AngularPeriodic (2*Real.pi) (endingJoinTensor D lam k J L K) := by + intro n x + have ht : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + simp only [endingJoinTensor,ht,hD n x,delayedEndingTensor_periodic _ _ _ _ _ _ n x] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FlatFourierFlux.lean b/lean/OAI/Analysis/Conductivity/Fourier/FlatFourierFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8b543c09862b38960278344c0d13842a8c2eb3c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FlatFourierFlux.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.FlatTorusPDE +import OAI.Analysis.Conductivity.Fourier.AngularPeriodization + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +def flatModeFlux (s : Fin 3 → ℝ) (f : Coord3 → ℝ) (x : Coord3) : Coord3 := + ![fderiv ℝ f x (flatAxis 0), + s 0*fderiv ℝ f x (flatAxis 1)+s 1*fderiv ℝ f x (flatAxis 2), + s 1*fderiv ℝ f x (flatAxis 1)+s 2*fderiv ℝ f x (flatAxis 2)] + +lemma flatModeFlux_smoothOn {s : Fin 3 → ℝ} {f : Coord3 → ℝ} {U : Set Coord3} + (hU : IsOpen U) (hf : ContDiffOn ℝ (↑(⊤:ℕ∞)) f U) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (flatModeFlux s f) U := by + have hd := hf.fderiv_of_isOpen hU (m:=↑(⊤:ℕ∞)) (by simp) + have he (i : Fin 3) := hd.clm_apply (contDiffOn_const (c:=flatAxis i)) + apply contDiffOn_pi.mpr + intro i + fin_cases i + · exact he 0 + · exact (contDiffOn_const.mul (he 1)).add (contDiffOn_const.mul (he 2)) + · exact (contDiffOn_const.mul (he 1)).add (contDiffOn_const.mul (he 2)) + +lemma flatModeFlux_divergence {s : Fin 3 → ℝ} {f : Coord3 → ℝ} {x : Coord3} + (hf : ContDiffAt ℝ (↑(⊤:ℕ∞)) f x) : + coordinateDivergence (flatModeFlux s f) x=flatTensorLaplacian s f x := by + have hd := (hf.fderiv_right (m:=1) (by exact WithTop.coe_le_coe.mpr (le_top : (2:ℕ∞)≤⊤))).differentiableAt (by simp) + have he (i : Fin 3) : + fderiv ℝ (fun y => fderiv ℝ f y (flatAxis i)) x=(fderiv ℝ (fderiv ℝ f) x).flip (flatAxis i) := by + rw [fderiv_clm_apply hd (differentiableAt_const _)] + simp + have he' (i : Fin 3) : DifferentiableAt ℝ (fun y => fderiv ℝ f y (flatAxis i)) x := + hd.clm_apply (differentiableAt_const _) + have hsum := hf.isSymmSndFDerivAt (by simp) + unfold coordinateDivergence + rw [Fin.sum_univ_three] + change fderiv ℝ (fun y => fderiv ℝ f y (flatAxis 0)) x (flatAxis 0)+ + fderiv ℝ (fun y => s 0*fderiv ℝ f y (flatAxis 1)+s 1*fderiv ℝ f y (flatAxis 2)) x (flatAxis 1)+ + fderiv ℝ (fun y => s 1*fderiv ℝ f y (flatAxis 1)+s 2*fderiv ℝ f y (flatAxis 2)) x (flatAxis 2)=_ + rw [fderiv_fun_add ((he' 1).const_mul _) ((he' 2).const_mul _), + fderiv_fun_add ((he' 1).const_mul _) ((he' 2).const_mul _)] + simp only [fderiv_const_mul (he' _),he,_root_.add_apply, + _root_.smul_apply,ContinuousLinearMap.flip_apply,smul_eq_mul] + unfold flatTensorLaplacian flatTensorLaplacianCLM + simp only [_root_.add_apply,_root_.smul_apply, + ContinuousMultilinearMap.apply_apply,smul_eq_mul,iteratedFDeriv_two_apply, + Matrix.cons_val_zero,Matrix.cons_val_one] + rw [hsum.eq (flatAxis 2) (flatAxis 1)] + ring + +lemma flatModeFlux_periodic {s : Fin 3 → ℝ} {f : Coord3 → ℝ} {T : ℝ} + (hf : AngularPeriodic T f) : AngularPeriodic T (flatModeFlux s f) := by + intro n x + unfold flatModeFlux + rw [hf.fderiv n x] + +lemma flatFourier_flux_divergence {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) {x : Coord3} (hx : 0 ⟨?_,?_⟩⟩ + · simpa only [norm_iteratedFDeriv_zero] using hb x hx + · have hh := (fderiv ℝ (flatFourier s a phase) x).le_opNorm (flatAxis 0) + have hn : ‖flatAxis (0:Fin 3)‖=1 := by simp [flatAxis,Pi.norm_single] + rw [hn,mul_one,←norm_iteratedFDeriv_one] at hh + exact hh.trans (hd x hx) + +theorem affine_fourier_cross_flux_zero {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a b pa pb : (Fin 2→ℤ)→ℝ} {Ba Bb ga gb t : ℝ} + (ha : ∀ h,|a h|≤Ba) (hb : ∀ h,|b h|≤Bb) (hga : 0 flatCrossFlux s (affineFourierField s a pa α β) (flatFourier s b pb) x 0) t=0 := by + obtain ⟨C,D,hC,hD,hbd⟩ := flatFourier_value_derivative_decay (phase:=pa) hs ha hga.le hra + obtain ⟨E,F,hE,hF,hbf⟩ := flatFourier_value_derivative_decay (phase:=pb) hs hb hgb.le hrb + apply flatCrossFlux_zero_of_bounds + (affineFourierField_smooth hs ha α β) (flatFourier_smooth hs hb) + (affineFourierField_periodic s a pa α β) (flatFourier_angularPeriodic s b pb) + (fun _ hx => affineFourierField_harmonic hs ha α β hx) + (fun _ hx => flatFourier_harmonic hs hb hx) + (A:=|α|) (B:=|β|+C) (C:=|α|+D) (D:=E) (E:=F) + (abs_nonneg _) (add_nonneg (abs_nonneg _) hC) (add_nonneg (abs_nonneg _) hD) + hE hF hgb ht + intro x hx + have hxp : 0 fderiv ℝ (affineFourierField s a phase α β) x (flatAxis 0)) t= + (2*Real.pi)^2*α := by + have hf := flatFourier_smooth (phase:=phase) hs ha + have hd := (hf.fderiv_of_isOpen (axial_halfspace_open 0) (m:=↑(⊤:ℕ∞)) (by simp)).clm_apply + (contDiffOn_const (c:=flatAxis 0)) + have hc := (halfspace_slice_smooth hd ht).continuous + have he : torusCellIntegral (2*Real.pi) + (fun x => fderiv ℝ (affineFourierField s a phase α β) x (flatAxis 0)) t= + torusCellIntegral (2*Real.pi) (fun x => α+fderiv ℝ (flatFourier s a phase) x (flatAxis 0)) t := by + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + change fderiv ℝ (affineFourierField s a phase α β) ![t,y,z] (flatAxis 0)=_ + rw [affineFourierField_fderiv hs ha α β (x:=![t,y,z]) ht] + simp [flatAxis] + rw [he,torusCellIntegral_add (by positivity) continuous_const hc, + torusCellIntegral_const,flatFourier_mean_axial_flux_zero hs ha hg hr ht,add_zero] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEnding.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEnding.lean new file mode 100644 index 0000000000000000000000000000000000000000..858d32414ecb529918e901b44595c9544dabd038 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEnding.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.MatchedEndingWeak +import OAI.Analysis.Conductivity.Fourier.EndingJoinPeriodicity +import OAI.Analysis.Conductivity.Branching.MatchedEndingRegularity + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Real Matrix +open scoped Matrix.Norms.Elementwise + +local instance fourierFiniteEndingMeasurableSpaceMat3 : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance fourierFiniteEndingBorelSpaceMat3 : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem aligned_fourier_finite_ending {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : 0 ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have hk0 : k≠0 := ne_of_gt hk + have hkr : (0:ℝ) mul_self_nonneg _) + exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) hw).trans (hDb x w).1, + (hDb x w).2.trans (mul_le_mul_of_nonneg_right (le_max_left _ _) hw)⟩ + have he' : ∀ x w : Coord3,c*(w ⬝ᵥ w)≤w ⬝ᵥ(alignedEndingTensor lam k J L K x*ᵥw) ∧ + w ⬝ᵥ(alignedEndingTensor lam k J L K x*ᵥw)≤C*(w ⬝ᵥ w) := by + intro x w + have hw : 0≤w ⬝ᵥ w := Finset.sum_nonneg (fun i _ => mul_self_nonneg _) + have hh := alignedEndingTensor_bounds he x w + exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) hw).trans hh.1, + hh.2.trans (mul_le_mul_of_nonneg_right (le_max_right _ _) hw)⟩ + have hDmeas : Measurable D := by + apply Measurable.of_eval; intro i + apply Measurable.of_eval; intro j + exact ((continuous_apply j).comp ((continuous_apply i).comp hDs.continuous)).measurable + refine ⟨p,T,c,C,hp,hpδ,hT,lt_min (by norm_num) hce, + (min_le_right _ _).trans (hceCe.trans (le_max_right _ _)), + matchedEndingPair u lam k J L K,endingJoinTensor D lam k J L K, + matchedEndingPair_C2 (hus.of_le (show (2:WithTop ℕ∞)≤↑(⊤:ℕ∞) by norm_cast)) hkr hJ hL hK hum, + endingJoinTensor_measurable hDmeas _ _ _ _ _, + matchedEndingPair_periodic hup _ _ _ _ _,endingJoinTensor_periodic hDp _ _ _ _ _, + ?_,endingJoinTensor_bounds hDb' he',?_,?_,?_,?_,?_,?_⟩ + · refine ⟨endingJoinTensor_symm hDsym _ _ _ _ _,?_⟩ + exact matchedEnding_regularRegion_ae hDs hus hDsym hkr hJ (by linarith) hK hum hDm hurank + (isOpen_lt continuous_const (continuous_apply 0)) (Subset.refl _) + · intro x hx + rw [matchedEndingPair,ite_eq_left (by linarith [hx.2])] + exact huin x hx + · intro x hx + rw [endingJoinTensor_left _ _ _ _ _ _ _ (by linarith [hx.2])] + by_cases hh : x 0<1/2 + · exact hDflat x (fun h => (not_le.mpr hh) h.1) + have heq : x 0=1/2 := le_antisymm hx.2 (le_of_not_gt hh) + + have hnear : ∀ᶠ y in 𝓝[<] (1/2:ℝ),D (Function.update x 0 y)=flatBackgroundTensor s := by + filter_upwards [self_mem_nhdsWithin] with y hy + apply hDflat + simpa using (show y∉Icc (1/2:ℝ) (11/2) from fun h => (not_le.mpr hy) h.1) + have hlim : Tendsto (fun y : ℝ => D (Function.update x 0 y)) (𝓝[<] (1/2:ℝ)) (𝓝 (D x)) := by + have hupp : Continuous (fun y : ℝ => Function.update x 0 y) := by + apply continuous_pi + intro i + by_cases hi : i=0 + · subst i + change Continuous (fun y : ℝ => y) + exact continuous_id + · simpa [Function.update_of_ne hi] using (continuous_const : Continuous (fun _ : ℝ => x i)) + have hc : Continuous (fun y : ℝ => D (Function.update x 0 y)) := hDs.continuous.comp hupp + have := (hc.tendsto (1/2)).mono_left (nhdsWithin_le_nhds (s:=Iio (1/2:ℝ))) + simpa only [←heq,Function.update_eq_self] using this + exact tendsto_nhds_unique hlim (tendsto_const_nhds.congr' (Filter.EventuallyEq.symm hnear)) + · intro x hx + apply matchedEndingPair_terminal hJ hL hK x (by linarith) + have hh : (J+2+2*cascadeLength L K)/(k:ℝ)≤x 0-7 := by dsimp [T] at hx; linarith + simpa only [mul_comm] using (div_le_iff₀ hkr).mp hh + · filter_upwards [hurank] with x hx + intro hbnd + rw [matchedEndingPair_left_deriv (by linarith [hbnd.2])] + exact hx hbnd + · refine ⟨(fun x i j => joinedFlux D u lam k J L K j x i),?_,?_⟩ + · exact contDiff_pi.mpr (fun i => contDiff_pi.mpr (fun j => + contDiff_pi.mp (joinedFlux_C1 hDs hus hJ hL hK j) i)) + · filter_upwards [endingJoin_constitution_ae (D:=D) hkr hJ hL hK hum] with x hx + ext i j + exact congrFun (hx j) i + · intro j ψ hcψ hsψ + exact matchedEnding_weak_equation hDs hus hkr hJ hL hK hum hDm hPDE j ψ hcψ hsψ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEndingNormal.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEndingNormal.lean new file mode 100644 index 0000000000000000000000000000000000000000..92ba9b5594a4ec53c887bb28a34aeb7c705131b5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierFiniteEndingNormal.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.MatchedEndingWeak +import OAI.Analysis.Conductivity.Fourier.EndingJoinPeriodicity +import OAI.Analysis.Conductivity.Branching.MatchedEndingRegularity + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Real Matrix +open scoped Matrix.Norms.Elementwise + +local instance fourierFiniteEndingNormalMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance fourierFiniteEndingNormalBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem aligned_fourier_finite_ending_with_normal {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : 0 ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + have hk0 : k≠0 := ne_of_gt hk + have hkr : (0:ℝ) mul_self_nonneg _) + exact ⟨(mul_le_mul_of_nonneg_right (min_le_left _ _) hw).trans (hDb x w).1, + (hDb x w).2.trans (mul_le_mul_of_nonneg_right (le_max_left _ _) hw)⟩ + have he' : ∀ x w : Coord3,c*(w ⬝ᵥ w)≤w ⬝ᵥ(alignedEndingTensor lam k J L K x*ᵥw) ∧ + w ⬝ᵥ(alignedEndingTensor lam k J L K x*ᵥw)≤C*(w ⬝ᵥ w) := by + intro x w + have hw : 0≤w ⬝ᵥ w := Finset.sum_nonneg (fun i _ => mul_self_nonneg _) + have hh := alignedEndingTensor_bounds he x w + exact ⟨(mul_le_mul_of_nonneg_right (min_le_right _ _) hw).trans hh.1, + hh.2.trans (mul_le_mul_of_nonneg_right (le_max_right _ _) hw)⟩ + have hDmeas : Measurable D := by + apply Measurable.of_eval; intro i + apply Measurable.of_eval; intro j + exact ((continuous_apply j).comp ((continuous_apply i).comp hDs.continuous)).measurable + refine ⟨p,T,c,C,hp,hpδ,hT,lt_min (by norm_num) hce, + (min_le_right _ _).trans (hceCe.trans (le_max_right _ _)), + matchedEndingPair u lam k J L K,endingJoinTensor D lam k J L K, + matchedEndingPair_C2 (hus.of_le (show (2:WithTop ℕ∞)≤↑(⊤:ℕ∞) by norm_cast)) hkr hJ hL hK hum, + endingJoinTensor_measurable hDmeas _ _ _ _ _, + matchedEndingPair_periodic hup _ _ _ _ _,endingJoinTensor_periodic hDp _ _ _ _ _, + ?_,endingJoinTensor_bounds hDb' he',?_,?_,?_,?_,?_,?_,?_⟩ + · refine ⟨endingJoinTensor_symm hDsym _ _ _ _ _,?_⟩ + exact matchedEnding_regularRegion_ae hDs hus hDsym hkr hJ (by linarith) hK hum hDm hurank + (isOpen_lt continuous_const (continuous_apply 0)) (Subset.refl _) + · intro x hx + rw [matchedEndingPair,ite_eq_left (by linarith [hx.2])] + exact huin x hx + · intro x hx + rw [endingJoinTensor_left _ _ _ _ _ _ _ (by linarith [hx.2])] + by_cases hh : x 0<1/2 + · exact hDflat x (fun h => (not_le.mpr hh) h.1) + have heq : x 0=1/2 := le_antisymm hx.2 (le_of_not_gt hh) + + have hnear : ∀ᶠ y in 𝓝[<] (1/2:ℝ),D (Function.update x 0 y)=flatBackgroundTensor s := by + filter_upwards [self_mem_nhdsWithin] with y hy + apply hDflat + simpa using (show y∉Icc (1/2:ℝ) (11/2) from fun h => (not_le.mpr hy) h.1) + have hlim : Tendsto (fun y : ℝ => D (Function.update x 0 y)) (𝓝[<] (1/2:ℝ)) (𝓝 (D x)) := by + have hupp : Continuous (fun y : ℝ => Function.update x 0 y) := by + apply continuous_pi + intro i + by_cases hi : i=0 + · subst i + change Continuous (fun y : ℝ => y) + exact continuous_id + · simpa [Function.update_of_ne hi] using (continuous_const : Continuous (fun _ : ℝ => x i)) + have hc : Continuous (fun y : ℝ => D (Function.update x 0 y)) := hDs.continuous.comp hupp + have := (hc.tendsto (1/2)).mono_left (nhdsWithin_le_nhds (s:=Iio (1/2:ℝ))) + simpa only [←heq,Function.update_eq_self] using this + exact tendsto_nhds_unique hlim (tendsto_const_nhds.congr' (Filter.EventuallyEq.symm hnear)) + · intro x hx + apply matchedEndingPair_terminal hJ hL hK x (by linarith) + have hh : (J+2+2*cascadeLength L K)/(k:ℝ)≤x 0-7 := by dsimp [T] at hx; linarith + simpa only [mul_comm] using (div_le_iff₀ hkr).mp hh + · intro x hx + rw [endingJoinTensor_right _ _ _ _ _ _ _ hx] + exact alignedEndingTensor_normal _ _ _ _ _ _ + · filter_upwards [hurank] with x hx + intro hbnd + rw [matchedEndingPair_left_deriv (by linarith [hbnd.2])] + exact hx hbnd + · refine ⟨(fun x i j => joinedFlux D u lam k J L K j x i),?_,?_⟩ + · exact contDiff_pi.mpr (fun i => contDiff_pi.mpr (fun j => + contDiff_pi.mp (joinedFlux_C1 hDs hus hJ hL hK j) i)) + · filter_upwards [endingJoin_constitution_ae (D:=D) hkr hJ hL hK hum] with x hx + ext i j + exact congrFun (hx j) i + · intro j ψ hcψ hsψ + exact matchedEnding_weak_equation hDs hus hkr hJ hL hK hum hDm hPDE j ψ hcψ hsψ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingElliptic.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingElliptic.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b67e856890b0f3a9a982b2c69abc2b39bc6b73a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingElliptic.lean @@ -0,0 +1,191 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierMatchingFamilyCorrection + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real Matrix +open scoped Matrix.Norms.Elementwise + +lemma matrix_quadratic_elementwise_bound (H : Mat3) (v : Coord3) : + |v ⬝ᵥ (H*ᵥv)| ≤ 3*‖H‖*(v ⬝ᵥ v) := by + change |∑ i : Fin 3,v i*∑ j : Fin 3,H i j*v j| ≤ _ + simp_rw [Finset.mul_sum] + calc + _ ≤ ∑ i : Fin 3,∑ j : Fin 3,|v i*(H i j*v j)| := by + apply (Finset.abs_sum_le_sum_abs _ _).trans + apply Finset.sum_le_sum + intro i _ + exact Finset.abs_sum_le_sum_abs _ _ + _ ≤ ∑ i : Fin 3,∑ j : Fin 3,‖H‖*((v i)^2+(v j)^2)/2 := by + apply Finset.sum_le_sum + intro i _ + apply Finset.sum_le_sum + intro j _ + have hh : |H i j|≤‖H‖ := by + change ‖H i j‖≤‖H‖ + exact Matrix.norm_entry_le_entrywise_sup_norm H + rw [abs_mul,abs_mul] + have hmul := mul_le_mul_of_nonneg_left hh (mul_nonneg (abs_nonneg (v i)) (abs_nonneg (v j))) + have hs := mul_nonneg (norm_nonneg H) (sq_nonneg (|v i|-|v j|)) + rw [sub_sq,sq_abs,sq_abs] at hs + nlinarith + _ = _ := by simp [Fin.sum_univ_three,dotProduct]; ring + +lemma flatBackgroundTensor_lower {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (v : Coord3) : + (1/2)*(v ⬝ᵥ v) ≤ v ⬝ᵥ (flatBackgroundTensor s*ᵥv) := by + have h := hs (v 1) (v 2) + simp [flatBackgroundTensor,dotProduct,Matrix.mulVec,Fin.sum_univ_three] at * + nlinarith [sq_nonneg (v 0)] + +lemma flatBackgroundTensor_small_perturbation {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {H : Mat3} (hH : ‖H‖≤1/12) (v : Coord3) : + (1/4)*(v ⬝ᵥ v) ≤ v ⬝ᵥ ((flatBackgroundTensor s+H)*ᵥv) ∧ + v ⬝ᵥ ((flatBackgroundTensor s+H)*ᵥv)≤(3*‖flatBackgroundTensor s‖+1)*(v ⬝ᵥ v) := by + have hv : 0≤v ⬝ᵥ v := Finset.sum_nonneg (fun i _ => mul_self_nonneg (v i)) + have hb := flatBackgroundTensor_lower hs v + have hq := abs_le.mp (matrix_quadratic_elementwise_bound H v) + have hf := (le_abs_self (v ⬝ᵥ (flatBackgroundTensor s*ᵥv))).trans + (matrix_quadratic_elementwise_bound (flatBackgroundTensor s) v) + have he : v ⬝ᵥ ((flatBackgroundTensor s+H)*ᵥv)= + v ⬝ᵥ (flatBackgroundTensor s*ᵥv)+v ⬝ᵥ (H*ᵥv) := by rw [add_mulVec,dotProduct_add] + rw [he] + have hm := mul_le_mul_of_nonneg_right hH hv + constructor <;> nlinarith + +theorem elliptic_fourier_matching {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : k≠0) {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 fourierMatchingPair s k f g (p,x)), + (fun x => flatBackgroundTensor s+H x), + (fourierMatchingPair_smooth s k hfs hgs).comp (contDiff_const.prodMk contDiff_id), + contDiff_const.add hHs,fourierMatchingPair_periodic s k hfp hgp p,?_,?_,?_,hHe,?_,?_,?_⟩ + · intro n x + dsimp only + rw [hHp n x] + · intro x + exact (flatBackgroundTensor_symm s).add (hHsym x) + · intro x v + exact flatBackgroundTensor_small_perturbation hs (hHb x) v + · intro x hx + have hz : H x=0 := image_eq_zero_of_notMem_tsupport (fun hx' => hx (hHt hx')) + dsimp only + rw [hz,add_zero] + · intro x hx + have hd := hdata p ⟨hp,hp2⟩ x ⟨hx.1,by linarith [hx.2]⟩ + simp only [fourierMatchingPair,fourierMatchingCutoff_left (show x 0≤2 by linarith [hx.2]),one_mul,hd.1,hd.2] + · intro x hx + simp only [fourierMatchingPair,fourierMatchingCutoff_right hx,zero_mul,add_zero] + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real Matrix +open scoped Matrix.Norms.Elementwise + +theorem smooth_fourier_matching_with_origin {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : k≠0) {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 f (p,x))) ∧ + (∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) ∧ + (∀ x,f (0,x)=0) ∧ (∀ x,g (0,x)=0) ∧ + (∀ p∈Ioc 0 (1/2),∀ x : Coord3,x 0∈Icc 0 6 → + f (p,x)=flatFourier s (normalizedFourierCoefficients s 0 (10+1/p) a) pa x ∧ + g (p,x)=flatFourier s (normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b) pb x) ∧ + ∀ ε : ℝ,0<ε → ∀ᶠ p in 𝓝 (0:ℝ),p∈Ioc 0 (1/2) → + ∃ H : Coord3 → Mat3,ContDiff ℝ (↑(⊤:ℕ∞)) H ∧ AngularPeriodic (2*Real.pi) H ∧ + tsupport H⊆{x | x 0∈Icc (1/2) (11/2)} ∧ (∀ x,(H x).IsSymm) ∧ + (∀ x,‖H x‖≤ε) ∧ ∀ j x,0 flatBackgroundTensor s+H y) (fun y => fourierMatchingPair s k f g (p,y)) j x=0 := by + obtain ⟨f,hfs,hfp,hfz,hfe⟩ := exists_smooth_periodic_normalized_tail + (lam:=0) (T0:=10) (δ:=1) (R:=7) (phase:=pa) hs hga hA ha (by norm_num) + (by simpa only [zero_add] using hra) (by norm_num) + obtain ⟨g,hgs,hgp,hgz,hge⟩ := exists_smooth_periodic_normalized_tail + (lam:=torusRate s ![0,k]) (T0:=10) (δ:=1) (R:=7) (phase:=pb) hs hgb hB hb (by norm_num) + hrb (by norm_num) + have hdata (p : ℝ) (hp : p∈Ioc 0 (1/2)) (x : Coord3) (hx : x 0∈Icc 0 6) : + f (p,x)=flatFourier s (normalizedFourierCoefficients s 0 (10+1/p) a) pa x ∧ + g (p,x)=flatFourier s (normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b) pb x := by + have hx' : x 0∈Icc (-7:ℝ) 7 := ⟨by linarith [hx.1],by linarith [hx.2]⟩ + constructor + · rw [hfe p hp x hx',flatFourier_normalized_translation] + · rw [hge p hp x hx',flatFourier_normalized_translation] + refine ⟨f,g,hfs,hgs,hfp,hgp,hfz 0 le_rfl,hgz 0 le_rfl,hdata,?_⟩ + intro ε hε + have hlam := axial_torusRate_pos hs hk + have hcor := fourierMatchingFamily_correction hs hk hfs hgs hfp hgp (hfz 0 le_rfl) (hgz 0 le_rfl) hε + filter_upwards [hcor] with p hcor + intro hp + have hT : 0≤10+1/p := by have hpos := hp.1; positivity + let aa := normalizedFourierCoefficients s 0 (10+1/p) a + let bb := normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b + have haa : ∀ h,|aa h|≤A := normalizedFourierCoefficients_bound ha hT + (fun h hh => hga.le.trans (hra h hh)) + have hbb : ∀ h,|bb h|≤B := normalizedFourierCoefficients_bound hb hT + (fun h hh => by linarith [hrb h hh]) + have hraa : ∀ h,aa h≠0 → ga≤torusRate s h := by + intro h hh + exact hra h (fun hz => hh ((normalizedFourierCoefficients_zero_iff _ _ _ _ _).mpr hz)) + have hrbb : ∀ h,bb h≠0 → torusRate s ![0,k]≤torusRate s h := by + intro h hh + have hn : b h≠0 := fun hz => hh ((normalizedFourierCoefficients_zero_iff _ _ _ _ _).mpr hz) + linarith [hrb h hn] + have hff (x : Coord3) (hx : x 0∈Icc 0 6) : f (p,x)=flatFourier s aa pa x := (hdata p hp x hx).1 + have hgg (x : Coord3) (hx : x 0∈Icc 0 6) : g (p,x)=flatFourier s bb pb x := (hdata p hp x hx).2 + have hm := fourierMatchingResidual_moments hs k hfs hgs hfp hgp haa hbb hpb hga hlam hraa hrbb hff hgg + obtain ⟨H,hH,hHp,hHs,hHsy,hHr,hHb⟩ := hcor hm + refine ⟨H,hH,hHp,hHs,hHsy,hHb,?_⟩ + exact fourierMatching_corrected_equation hs k hfs hgs haa hbb hpb hff hgg hH hHr + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingFamilyCorrection.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingFamilyCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..2076e0e3a94a4fd9ed6b30c7408ef303970b6b45 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingFamilyCorrection.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierMatchingLocalData + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real Matrix +open scoped Matrix.Norms.Elementwise + +lemma axial_torusRate_pos {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : k≠0) : 0 f (p,x))) + (hgp : ∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) + (hfz : ∀ x,f (0,x)=0) (hgz : ∀ x,g (0,x)=0) {ε : ℝ} (hε : 0<ε) : + ∀ᶠ p in 𝓝 (0:ℝ),periodicSourceMoment (2*Real.pi) (fun y => fourierMatchingPair s k f g (p,y)) + (fun j y => fourierMatchingResidual s k f g j (p,y))=0 → + ∃ H : Coord3 → Mat3,ContDiff ℝ (↑(⊤:ℕ∞)) H ∧ AngularPeriodic (2*Real.pi) H ∧ + tsupport H⊆{x | x 0∈Icc (1/2) (11/2)} ∧ (∀ x,(H x).IsSymm) ∧ + (∀ j,symmetricSource H (fun y => fourierMatchingPair s k f g (p,y)) j=(fun y => fourierMatchingResidual s k f g j (p,y))) ∧ + ∀ x,‖H x‖≤ε := by + have hF := fourierMatchingPair_smooth s k hfs hgs + have hF0 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z => fourierMatchingPair s k f g z 0) := + (contDiff_apply ℝ ℝ (0:Fin 2)).comp hF + have hF1 : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z => fourierMatchingPair s k f g z 1) := + (contDiff_apply ℝ ℝ (1:Fin 2)).comp hF + have hup (p : ℝ) : AngularPeriodic (2*Real.pi) + (fun y => ![fourierMatchingPair s k f g (p,y) 0,fourierMatchingPair s k f g (p,y) 1]) := + fourierMatchingPair_periodic s k hfp hgp p + have hub (x : Coord3) : fourierMatchingPair s k f g (0,x) 0=x 0 := by + simp [fourierMatchingPair,hfz] + have hvb (x : Coord3) : fourierMatchingPair s k f g (0,x) 1= + pureWallMode 1 (torusRate s ![0,k]) (k:ℝ) (boxCoordinates x) := by + simp [fourierMatchingPair,hgz,pureWallMode_eq_flatPhaseMode] + have hlam := axial_torusRate_pos hs hk + have hk' : (k:ℝ)≠0 := by exact_mod_cast hk + exact periodic_pure_mode_family_correction hF0 hF1 (0:ℝ) + (by norm_num : (1:ℝ)≠0) hlam.ne' hk' (by positivity : 0<2*Real.pi) + (by norm_num : (1/2:ℝ)<1) (by norm_num : (5:ℝ)<11/2) hub hvb hup + (fourierMatchingResidual_smooth s k hfs hgs) + (fourierMatchingResidual_base hs k hfz hgz) + (fun j p => fourierMatchingResidual_periodic s k hfp hgp p j) + (fun j p => fourierMatchingResidual_support s k f g p j) hε + +lemma fourierMatching_corrected_equation {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (k : ℤ) {f g : ℝ×Coord3 → ℝ} {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B p : ℝ} + (hfs : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hgs : ContDiff ℝ (↑(⊤:ℕ∞)) g) + (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) (hp : pb ![0,k]=0) + (hf : ∀ y : Coord3,y 0∈Icc 0 6 → f (p,y)=flatFourier s a pa y) + (hg : ∀ y : Coord3,y 0∈Icc 0 6 → g (p,y)=flatFourier s b pb y) + {H : Coord3 → Mat3} (hH : ContDiff ℝ (↑(⊤:ℕ∞)) H) + (hHr : ∀ j,symmetricSource H (fun y => fourierMatchingPair s k f g (p,y)) j=(fun y => fourierMatchingResidual s k f g j (p,y))) : + ∀ j x,0 flatBackgroundTensor s+H y) + (fun y => fourierMatchingPair s k f g (p,y)) j x=0 := by + intro j x hx + have hFs : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Coord3 => fourierMatchingPair s k f g (p,y)) := + (fourierMatchingPair_smooth s k hfs hgs).comp ((contDiff_const (c:=p)).prodMk contDiff_id) + have hadd := congrFun (symmetricSource_add (H:=fun _ => flatBackgroundTensor s) (K:=H) contDiff_const hH hFs j) x + have hr := congrFun (hHr j) x + have hre := fourierMatchingResidual_exact hs k hfs hgs ha hb hp hf hg j x hx + change symmetricSource (fun y => flatBackgroundTensor s+H y) (fun y => fourierMatchingPair s k f g (p,y)) j x= + symmetricSource (fun _ => flatBackgroundTensor s) (fun y => fourierMatchingPair s k f g (p,y)) j x+ + symmetricSource H (fun y => fourierMatchingPair s k f g (p,y)) j x at hadd + exact hadd.trans (by rw [hr,hre,add_neg_cancel]) + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real Matrix +open scoped Matrix.Norms.Elementwise + +theorem smooth_fourier_matching {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : k≠0) {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 f (p,x))) ∧ + (∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) ∧ + (∀ p∈Ioc 0 (1/2),∀ x : Coord3,x 0∈Icc 0 6 → + f (p,x)=flatFourier s (normalizedFourierCoefficients s 0 (10+1/p) a) pa x ∧ + g (p,x)=flatFourier s (normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b) pb x) ∧ + ∀ ε : ℝ,0<ε → ∀ᶠ p in 𝓝 (0:ℝ),p∈Ioc 0 (1/2) → + ∃ H : Coord3 → Mat3,ContDiff ℝ (↑(⊤:ℕ∞)) H ∧ AngularPeriodic (2*Real.pi) H ∧ + tsupport H⊆{x | x 0∈Icc (1/2) (11/2)} ∧ (∀ x,(H x).IsSymm) ∧ + (∀ x,‖H x‖≤ε) ∧ ∀ j x,0 flatBackgroundTensor s+H y) (fun y => fourierMatchingPair s k f g (p,y)) j x=0 := by + obtain ⟨f,hfs,hfp,hfz,hfe⟩ := exists_smooth_periodic_normalized_tail + (lam:=0) (T0:=10) (δ:=1) (R:=7) (phase:=pa) hs hga hA ha (by norm_num) + (by simpa only [zero_add] using hra) (by norm_num) + obtain ⟨g,hgs,hgp,hgz,hge⟩ := exists_smooth_periodic_normalized_tail + (lam:=torusRate s ![0,k]) (T0:=10) (δ:=1) (R:=7) (phase:=pb) hs hgb hB hb (by norm_num) + hrb (by norm_num) + have hdata (p : ℝ) (hp : p∈Ioc 0 (1/2)) (x : Coord3) (hx : x 0∈Icc 0 6) : + f (p,x)=flatFourier s (normalizedFourierCoefficients s 0 (10+1/p) a) pa x ∧ + g (p,x)=flatFourier s (normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b) pb x := by + have hx' : x 0∈Icc (-7:ℝ) 7 := ⟨by linarith [hx.1],by linarith [hx.2]⟩ + constructor + · rw [hfe p hp x hx',flatFourier_normalized_translation] + · rw [hge p hp x hx',flatFourier_normalized_translation] + refine ⟨f,g,hfs,hgs,hfp,hgp,hdata,?_⟩ + intro ε hε + have hlam := axial_torusRate_pos hs hk + have hcor := fourierMatchingFamily_correction hs hk hfs hgs hfp hgp (hfz 0 le_rfl) (hgz 0 le_rfl) hε + filter_upwards [hcor] with p hcor + intro hp + have hT : 0≤10+1/p := by have hpos := hp.1; positivity + let aa := normalizedFourierCoefficients s 0 (10+1/p) a + let bb := normalizedFourierCoefficients s (torusRate s ![0,k]) (10+1/p) b + have haa : ∀ h,|aa h|≤A := normalizedFourierCoefficients_bound ha hT + (fun h hh => hga.le.trans (hra h hh)) + have hbb : ∀ h,|bb h|≤B := normalizedFourierCoefficients_bound hb hT + (fun h hh => by linarith [hrb h hh]) + have hraa : ∀ h,aa h≠0 → ga≤torusRate s h := by + intro h hh + exact hra h (fun hz => hh ((normalizedFourierCoefficients_zero_iff _ _ _ _ _).mpr hz)) + have hrbb : ∀ h,bb h≠0 → torusRate s ![0,k]≤torusRate s h := by + intro h hh + have hn : b h≠0 := fun hz => hh ((normalizedFourierCoefficients_zero_iff _ _ _ _ _).mpr hz) + linarith [hrb h hn] + have hff (x : Coord3) (hx : x 0∈Icc 0 6) : f (p,x)=flatFourier s aa pa x := (hdata p hp x hx).1 + have hgg (x : Coord3) (hx : x 0∈Icc 0 6) : g (p,x)=flatFourier s bb pb x := (hdata p hp x hx).2 + have hm := fourierMatchingResidual_moments hs k hfs hgs hfp hgp haa hbb hpb hga hlam hraa hrbb hff hgg + obtain ⟨H,hH,hHp,hHs,hHsy,hHr,hHb⟩ := hcor hm + refine ⟨H,hH,hHp,hHs,hHsy,hHb,?_⟩ + exact fourierMatching_corrected_equation hs k hfs hgs haa hbb hpb hff hgg hH hHr + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingInterpolation.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingInterpolation.lean new file mode 100644 index 0000000000000000000000000000000000000000..929409d08c05c20176ce3c6faf073dabeb3ceab1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingInterpolation.lean @@ -0,0 +1,160 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierPairFlux + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +def fourierMatchingCutoff (t : ℝ) : ℝ := 1-smoothTransition ((t-2)/2) + +lemma fourierMatchingCutoff_smooth : ContDiff ℝ (↑(⊤:ℕ∞)) fourierMatchingCutoff := + contDiff_const.sub (smoothTransition.contDiff.comp ((contDiff_id.sub contDiff_const).div_const 2)) + +lemma fourierMatchingCutoff_left {t : ℝ} (ht : t≤2) : fourierMatchingCutoff t=1 := by + rw [fourierMatchingCutoff,smoothTransition.zero_of_nonpos (by linarith),sub_zero] + +lemma fourierMatchingCutoff_right {t : ℝ} (ht : 4≤t) : fourierMatchingCutoff t=0 := by + rw [fourierMatchingCutoff,smoothTransition.one_of_one_le (by linarith),sub_self] + +def fourierMatchingPair (s : Fin 3 → ℝ) (k : ℤ) (f g : ℝ×Coord3 → ℝ) + (z : ℝ×Coord3) : Fin 2 → ℝ := + ![z.2 0+fourierMatchingCutoff (z.2 0)*f z, + flatPhaseMode s ![0,k] 0 z.2+fourierMatchingCutoff (z.2 0)*g z] + +lemma fourierMatchingPair_smooth (s : Fin 3 → ℝ) (k : ℤ) {f g : ℝ×Coord3 → ℝ} + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hg : ContDiff ℝ (↑(⊤:ℕ∞)) g) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fourierMatchingPair s k f g) := by + have ht : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z : ℝ×Coord3 => z.2 0) := + (contDiff_apply ℝ ℝ (0:Fin 3)).comp contDiff_snd + apply contDiff_pi.mpr + intro j + fin_cases j + · exact ht.add ((fourierMatchingCutoff_smooth.comp ht).mul hf) + · exact ((flatPhaseMode_smooth s ![0,k] 0).comp contDiff_snd).add + ((fourierMatchingCutoff_smooth.comp ht).mul hg) + +lemma fourierMatchingPair_periodic (s : Fin 3 → ℝ) (k : ℤ) {f g : ℝ×Coord3 → ℝ} + (hf : ∀ p,AngularPeriodic (2*Real.pi) (fun x => f (p,x))) + (hg : ∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) (p : ℝ) : + AngularPeriodic (2*Real.pi) (fun x => fourierMatchingPair s k f g (p,x)) := by + intro n x + dsimp only [fourierMatchingPair] + have hfe : f (p,x+angularShift (2*Real.pi) n)=f (p,x) := hf p n x + have hge : g (p,x+angularShift (2*Real.pi) n)=g (p,x) := hg p n x + rw [hfe,hge,flatPhaseMode_angularPeriodic s ![0,k] 0 n x] + have he : (x+angularShift (2*Real.pi) n) 0=x 0 := by simp [angularShift] + rw [he] + +lemma fourierMatchingPair_base (s : Fin 3 → ℝ) (k : ℤ) {f g : ℝ×Coord3 → ℝ} + (hf : ∀ x,f (0,x)=0) (hg : ∀ x,g (0,x)=0) (x : Coord3) : + fourierMatchingPair s k f g (0,x)= + ![x 0,pureWallMode 1 (torusRate s ![0,k]) (k:ℝ) (boxCoordinates x)] := by + simp only [fourierMatchingPair,hf,hg,mul_zero,add_zero,pureWallMode_eq_flatPhaseMode] + +lemma fourierMatchingPair_left_nhds (s : Fin 3 → ℝ) (k : ℤ) (f g : ℝ×Coord3 → ℝ) + (p : ℝ) {x : Coord3} (hx : x 0<2) : + (fun y => fourierMatchingPair s k f g (p,y))=ᶠ[𝓝 x] + (fun y => ![y 0+f (p,y),flatPhaseMode s ![0,k] 0 y+g (p,y)]) := by + have hn : ∀ᶠ y in 𝓝 x,y 0<2 := (isOpen_lt (continuous_apply 0) continuous_const).mem_nhds hx + filter_upwards [hn] with y hy + simp only [fourierMatchingPair,fourierMatchingCutoff_left hy.le,one_mul] + +lemma fourierMatchingPair_right_nhds (s : Fin 3 → ℝ) (k : ℤ) (f g : ℝ×Coord3 → ℝ) + (p : ℝ) {x : Coord3} (hx : 4 fourierMatchingPair s k f g (p,y))=ᶠ[𝓝 x] + (fun y => ![y 0,flatPhaseMode s ![0,k] 0 y]) := by + have hn : ∀ᶠ y in 𝓝 x,4 flatBackgroundTensor s) + (fun x => fourierMatchingPair s k f g (z.1,x)) j z.2 + +lemma fourierMatchingResidual_smooth (s : Fin 3 → ℝ) (k : ℤ) {f g : ℝ×Coord3 → ℝ} + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hg : ContDiff ℝ (↑(⊤:ℕ∞)) g) (j : Fin 2) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fourierMatchingResidual s k f g j) := by + have hr := symmetricSource_parametric_smoothOn (V:=univ) isOpen_univ + (H:=fun _ : ℝ×Coord3 => flatBackgroundTensor s) contDiffOn_const + (fourierMatchingPair_smooth s k hf hg).contDiffOn j + rw [contDiffOn_univ] at hr + exact ((fourierResidualCutoff_smooth.comp + ((contDiff_apply ℝ ℝ (0:Fin 3)).comp contDiff_snd)).neg).mul hr + +lemma fourierMatchingResidual_periodic (s : Fin 3 → ℝ) (k : ℤ) {f g : ℝ×Coord3 → ℝ} + (hf : ∀ p,AngularPeriodic (2*Real.pi) (fun x => f (p,x))) + (hg : ∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) (p : ℝ) (j : Fin 2) : + AngularPeriodic (2*Real.pi) (fun x => fourierMatchingResidual s k f g j (p,x)) := by + intro n x + have he := symmetricSource_angular_translate (fourierMatchingPair_periodic s k hf hg p) + (fun _ => flatBackgroundTensor s) j n x + dsimp only [fourierMatchingResidual] + rw [←he] + simp only [Pi.add_apply,angularShift,Matrix.cons_val_zero,add_zero] + +lemma fourierMatchingResidual_support (s : Fin 3 → ℝ) (k : ℤ) (f g : ℝ×Coord3 → ℝ) + (p : ℝ) (j : Fin 2) : + tsupport (fun x => fourierMatchingResidual s k f g j (p,x))⊆{x | x 0∈Icc 1 5} := by + apply closure_minimal _ (isClosed_Icc.preimage (continuous_apply 0)) + intro x hx + constructor + · by_contra hh + exact hx (by simp only [fourierMatchingResidual,fourierResidualCutoff_zero_left (le_of_not_ge hh),neg_zero,zero_mul]) + · by_contra hh + exact hx (by simp only [fourierMatchingResidual,fourierResidualCutoff_zero_right (le_of_not_ge hh),neg_zero,zero_mul]) + +lemma flatPurePair_source_zero {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) (k : ℤ) (j : Fin 2) (x : Coord3) : + symmetricSource (fun _ => flatBackgroundTensor s) (fun y => ![y 0,flatPhaseMode s ![0,k] 0 y]) j x=0 := by + have hu : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Coord3 => ![y 0,flatPhaseMode s ![0,k] 0 y]) := by + apply contDiff_pi.mpr + intro j + fin_cases j + · exact contDiff_apply ℝ ℝ 0 + · exact flatPhaseMode_smooth s ![0,k] 0 + rw [flatBackgroundTensor_source hu] + fin_cases j + · change flatTensorLaplacian s (fun y : Coord3 => y 0) x=0 + simpa only [one_mul,add_zero] using flatTensorLaplacian_axial_affine s 1 0 x + · exact flatPhaseMode_harmonic hs ![0,k] 0 x + +lemma fourierMatchingResidual_base {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (k : ℤ) {f g : ℝ×Coord3 → ℝ} (hf : ∀ x,f (0,x)=0) (hg : ∀ x,g (0,x)=0) + (j : Fin 2) (x : Coord3) : fourierMatchingResidual s k f g j (0,x)=0 := by + have he : (fun y => fourierMatchingPair s k f g (0,y))= + (fun y => ![y 0,flatPhaseMode s ![0,k] 0 y]) := by + funext y + simp only [fourierMatchingPair,hf,hg,mul_zero,add_zero] + unfold fourierMatchingResidual + rw [he,flatPurePair_source_zero hs,mul_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingLocalData.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingLocalData.lean new file mode 100644 index 0000000000000000000000000000000000000000..98baa513cebb4f741c6f4eaf9754228076d4e80f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierMatchingLocalData.lean @@ -0,0 +1,234 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.TorusLocalizedMoments +import OAI.Analysis.Conductivity.Fourier.FourierMatchingInterpolation + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma flatTensorLaplacian_congr_nhds (s : Fin 3 → ℝ) {f g : Coord3 → ℝ} {x : Coord3} + (h : f=ᶠ[𝓝 x] g) : flatTensorLaplacian s f x=flatTensorLaplacian s g x := + congrArg (flatTensorLaplacianCLM s) ((h.iteratedFDeriv ℝ 2).self_of_nhds) + +lemma fourier_left_coeff_bound {k : ℤ} {b : (Fin 2 → ℤ) → ℝ} {B : ℝ} + (hb : ∀ h,|b h|≤B) (h : Fin 2 → ℤ) : + |(Pi.single ![0,k] (1:ℝ) : (Fin 2 → ℤ) → ℝ) h+b h|≤1+B := + (abs_add_le _ _).trans (add_le_add (single_fourier_coeff_bound _ _) (hb h)) + +lemma fourierMatchingPair_left_fourier {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (k : ℤ) {f g : ℝ×Coord3 → ℝ} {a b pa pb : (Fin 2 → ℤ) → ℝ} {B p : ℝ} + (hb : ∀ h,|b h|≤B) (hp : pb ![0,k]=0) + (hf : ∀ y : Coord3,y 0∈Icc 0 6 → f (p,y)=flatFourier s a pa y) + (hg : ∀ y : Coord3,y 0∈Icc 0 6 → g (p,y)=flatFourier s b pb y) + {x : Coord3} (hx : x 0∈Ioo 0 2) : + (fun y => fourierMatchingPair s k f g (p,y) 0)=ᶠ[𝓝 x] affineFourierField s a pa 1 0 ∧ + (fun y => fourierMatchingPair s k f g (p,y) 1)=ᶠ[𝓝 x] + flatFourier s (fun h => (Pi.single ![0,k] (1:ℝ) : (Fin 2 → ℤ) → ℝ) h+b h) pb := by + have hn : ∀ᶠ y in 𝓝 x,y 0∈Ioo 0 2 := + (isOpen_Ioo.preimage (continuous_apply 0)).mem_nhds hx + constructor + · filter_upwards [hn] with y hy + change y 0+fourierMatchingCutoff (y 0)*f (p,y)=_ + rw [fourierMatchingCutoff_left hy.2.le,one_mul,hf y ⟨hy.1.le,by linarith [hy.2]⟩] + simp only [affineFourierField,one_mul,add_zero] + · filter_upwards [hn] with y hy + change flatPhaseMode s ![0,k] 0 y+fourierMatchingCutoff (y 0)*g (p,y)=_ + rw [fourierMatchingCutoff_left hy.2.le,one_mul,hg y ⟨hy.1.le,by linarith [hy.2]⟩, + flatFourier_add hs (single_fourier_coeff_bound ![0,k]) hb hy.1, + flatFourier_single,hp,one_mul] + +lemma fourierMatchingPair_right_fourier (s : Fin 3 → ℝ) (k : ℤ) (f g : ℝ×Coord3 → ℝ) + (pa pb : (Fin 2 → ℤ) → ℝ) (hp : pb ![0,k]=0) (p : ℝ) {x : Coord3} (hx : 4 fourierMatchingPair s k f g (p,y) 0)=ᶠ[𝓝 x] affineFourierField s (fun _ => 0) pa 1 0 ∧ + (fun y => fourierMatchingPair s k f g (p,y) 1)=ᶠ[𝓝 x] flatFourier s (Pi.single ![0,k] 1) pb := by + have hn : ∀ᶠ y in 𝓝 x,4 -r j x)=-periodicSourceMoment T u r := by + have hpoint (x : Coord3) : u x 1*(-r 0 x)-u x 0*(-r 1 x)= + -(u x 1*r 0 x-u x 0*r 1 x) := by ring + ext i + fin_cases i + · change (∫ t,∫ y in 0..T,∫ z in 0..T,-r 0 ![t,y,z])=-(∫ t,∫ y in 0..T,∫ z in 0..T,r 0 ![t,y,z]) + simp only [intervalIntegral.integral_neg,integral_neg] + · change (∫ t,∫ y in 0..T,∫ z in 0..T,-r 1 ![t,y,z])=-(∫ t,∫ y in 0..T,∫ z in 0..T,r 1 ![t,y,z]) + simp only [intervalIntegral.integral_neg,integral_neg] + · change (∫ t,∫ y in 0..T,∫ z in 0..T,u ![t,y,z] 1*(-r 0 ![t,y,z])-u ![t,y,z] 0*(-r 1 ![t,y,z]))= + -(∫ t,∫ y in 0..T,∫ z in 0..T,u ![t,y,z] 1*r 0 ![t,y,z]-u ![t,y,z] 0*r 1 ![t,y,z]) + simp only [hpoint,intervalIntegral.integral_neg,integral_neg] + +theorem fourier_matching_three_moments {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a b : Fin 2 → (Fin 2 → ℤ) → ℝ} {pa pb : Fin 2 → (Fin 2 → ℤ) → ℝ} + {Ba Bb ga gb : Fin 2 → ℝ} {l d α : ℝ} {β : Fin 2 → ℝ} + (ha : ∀ e h,|a e h|≤Ba e) (hb : ∀ e h,|b e h|≤Bb e) + (hga : ∀ e,0 u y 0)=ᶠ[𝓝 x] affineFourierField s (a e) (pa e) α (β e)) + (he1 : ∀ e x,x 0=![l,d] e → (fun y => u y 1)=ᶠ[𝓝 x] flatFourier s (b e) (pb e)) + (hrs : ∀ j,tsupport (r j)⊆{x | x 0∈Icc l d}) + (hre : ∀ j x,x 0∈Icc l d → r j x=symmetricSource (fun _ => flatBackgroundTensor s) u j x) : + periodicSourceMoment (2*Real.pi) u r=0 ∧ + periodicSourceMoment (2*Real.pi) u (fun j x => -r j x)=0 := by + have ht (e : Fin 2) : 0 flatBackgroundTensor s) contDiff_const hu (fun _ _ => rfl) hup + (fun _ => flatBackgroundTensor_symm s) hrs hre + have hz : periodicSourceMoment (2*Real.pi) u r=0 := by + rw [hm] + ext i + fin_cases i + · change _-_=0 + rw [heR.1,heL.1,sub_self] + · change _-_=0 + rw [heR.2.1,heL.2.1,sub_self] + · change _-_=0 + rw [heR.2.2,heL.2.2,sub_self] + exact ⟨hz,by rw [periodicSourceMoment_neg,hz,neg_zero]⟩ + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma fourierMatchingResidual_exact {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (k : ℤ) {f g : ℝ×Coord3 → ℝ} {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B p : ℝ} + (hfs : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hgs : ContDiff ℝ (↑(⊤:ℕ∞)) g) + (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) (hp : pb ![0,k]=0) + (hf : ∀ y : Coord3,y 0∈Icc 0 6 → f (p,y)=flatFourier s a pa y) + (hg : ∀ y : Coord3,y 0∈Icc 0 6 → g (p,y)=flatFourier s b pb y) + (j : Fin 2) (x : Coord3) (hx : 0 flatBackgroundTensor s) (fun y => fourierMatchingPair s k f g (p,y)) j x := by + have hu : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Coord3 => fourierMatchingPair s k f g (p,y)) := + (fourierMatchingPair_smooth s k hfs hgs).comp ((contDiff_const (c:=p)).prodMk contDiff_id) + by_cases hmid : x 0∈Icc 2 4 + · simp only [fourierMatchingResidual,fourierResidualCutoff_one hmid,neg_mul,one_mul] + have hz : symmetricSource (fun _ => flatBackgroundTensor s) (fun y => fourierMatchingPair s k f g (p,y)) j x=0 := by + rw [flatBackgroundTensor_source hu] + by_cases hleft : x 0<2 + · have he := fourierMatchingPair_left_fourier hs k hb hp hf hg (x:=x) ⟨hx,hleft⟩ + fin_cases j + · change flatTensorLaplacian s (fun y => fourierMatchingPair s k f g (p,y) 0) x=0 + rw [flatTensorLaplacian_congr_nhds s he.1] + exact affineFourierField_harmonic hs ha 1 0 hx + · change flatTensorLaplacian s (fun y => fourierMatchingPair s k f g (p,y) 1) x=0 + rw [flatTensorLaplacian_congr_nhds s he.2] + exact flatFourier_harmonic hs (fourier_left_coeff_bound hb) hx + · have hright : 4 fourierMatchingPair s k f g (p,y) 0) x=0 + rw [flatTensorLaplacian_congr_nhds s he.1] + exact affineFourierField_harmonic hs (B:=0) (by intro h; simp) 1 0 (by linarith) + · change flatTensorLaplacian s (fun y => fourierMatchingPair s k f g (p,y) 1) x=0 + rw [flatTensorLaplacian_congr_nhds s he.2] + exact flatFourier_harmonic hs (single_fourier_coeff_bound ![0,k]) (by linarith) + simp only [fourierMatchingResidual,hz,mul_zero,neg_zero] + +lemma fourier_single_plus_rate {s : Fin 3 → ℝ} {k : ℤ} {b : (Fin 2 → ℤ) → ℝ} + (hb : ∀ h,b h≠0 → torusRate s ![0,k]≤torusRate s h) : + ∀ h,(Pi.single ![0,k] (1:ℝ) : (Fin 2 → ℤ) → ℝ) h+b h≠0 → torusRate s ![0,k]≤torusRate s h := by + classical + intro h hh + by_cases he : h=![0,k] + · subst h; exact le_rfl + · apply hb h + simpa only [Pi.single_eq_of_ne he,zero_add] using hh + +lemma fourierMatchingResidual_moments {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (k : ℤ) {f g : ℝ×Coord3 → ℝ} {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B p ga : ℝ} + (hfs : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hgs : ContDiff ℝ (↑(⊤:ℕ∞)) g) + (hfp : ∀ p,AngularPeriodic (2*Real.pi) (fun x => f (p,x))) + (hgp : ∀ p,AngularPeriodic (2*Real.pi) (fun x => g (p,x))) + (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) (hp : pb ![0,k]=0) + (hga : 0 fourierMatchingPair s k f g (p,y)) + (fun j y => fourierMatchingResidual s k f g j (p,y))=0 := by + classical + let aa : Fin 2 → (Fin 2 → ℤ) → ℝ := ![a,fun _ => 0] + let bb : Fin 2 → (Fin 2 → ℤ) → ℝ := ![fun h => (Pi.single ![0,k] (1:ℝ) : (Fin 2 → ℤ) → ℝ) h+b h,Pi.single ![0,k] 1] + have haa : ∀ e h,|aa e h|≤![A,0] e := by intro e h; fin_cases e; exact ha h; simp [aa] + have hbb : ∀ e h,|bb e h|≤![1+B,1] e := by + intro e h + fin_cases e + · exact fourier_left_coeff_bound hb h + · exact single_fourier_coeff_bound _ _ + have hraa : ∀ e h,aa e h≠0 → ga≤torusRate s h := by + intro e h hh + fin_cases e + · exact hra h hh + · exact False.elim (hh rfl) + have hrbb : ∀ e h,bb e h≠0 → torusRate s ![0,k]≤torusRate s h := by + intro e h hh + fin_cases e + · exact fourier_single_plus_rate hrb h hh + · by_cases he : h=![0,k] + · subst h; exact le_rfl + · exact False.elim (hh (Pi.single_eq_of_ne he 1)) + have he (e : Fin 2) (x : Coord3) (hx : x 0=![1,5] e) : + (fun y => fourierMatchingPair s k f g (p,y) 0)=ᶠ[𝓝 x] affineFourierField s (aa e) pa 1 0 ∧ + (fun y => fourierMatchingPair s k f g (p,y) 1)=ᶠ[𝓝 x] flatFourier s (bb e) pb := by + fin_cases e + · exact fourierMatchingPair_left_fourier hs k hb hp hf hg ⟨by simpa using hx ▸ (show (0:ℝ)<1 by norm_num),by simpa using hx ▸ (show (1:ℝ)<2 by norm_num)⟩ + · exact fourierMatchingPair_right_fourier s k f g pa pb hp p (by simpa using hx ▸ (show (4:ℝ)<5 by norm_num)) + have hrs (j : Fin 2) : tsupport (fun y => -fourierMatchingResidual s k f g j (p,y))⊆{x | x 0∈Icc 1 5} := by + rw [show (fun y => -fourierMatchingResidual s k f g j (p,y))= -(fun y => fourierMatchingResidual s k f g j (p,y)) from rfl,tsupport_neg] + exact fourierMatchingResidual_support s k f g p j + have hre (j : Fin 2) (x : Coord3) (hx : x 0∈Icc 1 5) : + -fourierMatchingResidual s k f g j (p,x)= symmetricSource (fun _ => flatBackgroundTensor s) + (fun y => fourierMatchingPair s k f g (p,y)) j x := by + rw [fourierMatchingResidual_exact hs k hfs hgs ha hb hp hf hg j x (by linarith [hx.1]),neg_neg] + have hu : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Coord3 => fourierMatchingPair s k f g (p,y)) := + (fourierMatchingPair_smooth s k hfs hgs).comp ((contDiff_const (c:=p)).prodMk contDiff_id) + have hm := fourier_matching_three_moments hs haa hbb (fun _ => hga) (fun _ => hgb) + hraa hrbb (by norm_num : (0:ℝ)<1) (by norm_num : (1:ℝ)≤5) + hu + (fourierMatchingPair_periodic s k hfp hgp p) (fun e x hx => (he e x hx).1) (fun e x hx => (he e x hx).2) hrs hre + simpa only [neg_neg,Function.comp_apply] using hm.2 + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/FourierPairFlux.lean b/lean/OAI/Analysis/Conductivity/Fourier/FourierPairFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d1c7c582cfdfb4a515d9474ec383e488a0c8f6d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/FourierPairFlux.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierEndConcomitant +import OAI.Analysis.Conductivity.Fourier.FourierEndFlux +import OAI.Analysis.Conductivity.Flux.FlatBackgroundTensor + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma torusCellIntegral_congr_slice {T t : ℝ} {f g : Coord3 → ℝ} + (h : ∀ x,x 0=t → f x=g x) : torusCellIntegral T f t=torusCellIntegral T g t := by + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + exact h ![t,y,z] rfl + +theorem fourier_pair_boundary_flux {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a b pa pb : (Fin 2 → ℤ) → ℝ} {Ba Bb ga gb t : ℝ} + (ha : ∀ h,|a h|≤Ba) (hb : ∀ h,|b h|≤Bb) (hga : 0 u y 0)=ᶠ[𝓝 x] affineFourierField s a pa α β) + (he1 : ∀ x,x 0=t → (fun y => u y 1)=ᶠ[𝓝 x] flatFourier s b pb) : + torusCellIntegral (2*Real.pi) + (fun x => (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col 0 0) t=(2*Real.pi)^2*α ∧ + torusCellIntegral (2*Real.pi) + (fun x => (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col 1 0) t=0 ∧ + torusCellIntegral (2*Real.pi) (fun x => symmetricCrossFlux (fun _ => flatBackgroundTensor s) u x 0) t=0 := by + have hf0 := torusCellIntegral_congr_slice (T:=2*Real.pi) + (f:=fun x => (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col 0 0) + (g:=fun x => fderiv ℝ (affineFourierField s a pa α β) x (flatAxis 0)) + (fun x hx => by + rw [flatBackgroundTensor_flux hu] + change fderiv ℝ (fun y => u y 0) x (flatAxis 0)=_ + rw [(he0 x hx).fderiv_eq]) + have hf1 := torusCellIntegral_congr_slice (T:=2*Real.pi) + (f:=fun x => (flatBackgroundTensor s*gradientColumns (fderiv ℝ u x)).col 1 0) + (g:=fun x => fderiv ℝ (flatFourier s b pb) x (flatAxis 0)) + (fun x hx => by + rw [flatBackgroundTensor_flux hu] + change fderiv ℝ (fun y => u y 1) x (flatAxis 0)=_ + rw [(he1 x hx).fderiv_eq]) + have hfc := torusCellIntegral_congr_slice (T:=2*Real.pi) + (f:=fun x => symmetricCrossFlux (fun _ => flatBackgroundTensor s) u x 0) + (g:=fun x => flatCrossFlux s (affineFourierField s a pa α β) (flatFourier s b pb) x 0) + (fun x hx => by + rw [flatBackgroundTensor_crossFlux hu] + change u x 1*fderiv ℝ (fun y => u y 0) x (flatAxis 0)- + u x 0*fderiv ℝ (fun y => u y 1) x (flatAxis 0)=_ + have hv0 : u x 0=affineFourierField s a pa α β x := (he0 x hx).self_of_nhds + have hv1 : u x 1=flatFourier s b pb x := (he1 x hx).self_of_nhds + rw [(he0 x hx).fderiv_eq,(he1 x hx).fderiv_eq,hv0,hv1] + rfl) + exact ⟨hf0.trans (affine_fourier_mean_axial_flux hs ha hga hra α β ht), + hf1.trans (flatFourier_mean_axial_flux_zero hs hb hgb hrb ht), + hfc.trans (affine_fourier_cross_flux_zero hs ha hb hga hgb hra hrb α β ht)⟩ + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma flatFourier_add {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a b phase : (Fin 2 → ℤ) → ℝ} {A B : ℝ} + (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) {x : Coord3} (hx : 0 a h+b h) phase x=flatFourier s a phase x+flatFourier s b phase x := by + unfold flatFourier + simp only [add_mul] + exact (flatFourier_summable hs ha hx).tsum_add (flatFourier_summable hs hb hx) + +lemma flatFourier_single (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (c : ℝ) + (phase : (Fin 2 → ℤ) → ℝ) (x : Coord3) : + flatFourier s (Pi.single h c) phase x=c*flatPhaseMode s h (phase h) x := by + classical + unfold flatFourier + rw [tsum_eq_single h] + · simp + · intro k hk + simp [Pi.single_eq_of_ne hk] + +lemma flatFourier_zero (s : Fin 3 → ℝ) (phase : (Fin 2 → ℤ) → ℝ) (x : Coord3) : + flatFourier s (fun _ => 0) phase x=0 := by simp [flatFourier] + +lemma flatFourier_const_mul (s : Fin 3 → ℝ) (a phase : (Fin 2 → ℤ) → ℝ) (c : ℝ) (x : Coord3) : + flatFourier s (fun h => c*a h) phase x=c*flatFourier s a phase x := by + simp only [flatFourier,mul_assoc,tsum_mul_left] + +lemma flatFourier_translation (s : Fin 3 → ℝ) (a phase : (Fin 2 → ℤ) → ℝ) (T : ℝ) (x : Coord3) : + flatFourier s a phase (x+![T,0,0])= + flatFourier s (fun h => a h*exp (-torusRate s h*T)) phase x := by + unfold flatFourier + apply tsum_congr + intro h + rw [flatPhaseMode_translation] + ring + +lemma translated_fourier_coeff_bound {s : Fin 3 → ℝ} {a : (Fin 2 → ℤ) → ℝ} {B T : ℝ} + (ha : ∀ h,|a h|≤B) (hT : 0≤T) (h : Fin 2 → ℤ) : + |a h*exp (-torusRate s h*T)|≤B := by + have he : exp (-torusRate s h*T)≤1 := exp_le_one_iff.mpr + (mul_nonpos_of_nonpos_of_nonneg (neg_nonpos.mpr (sqrt_nonneg _)) hT) + rw [abs_mul,abs_of_pos (exp_pos _)] + exact (mul_le_mul_of_nonneg_left he (abs_nonneg _)).trans (by simpa using ha h) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +def normalizedFourierCoefficients (s : Fin 3 → ℝ) (lam T : ℝ) + (a : (Fin 2 → ℤ) → ℝ) (h : Fin 2 → ℤ) : ℝ := a h*exp (-(torusRate s h-lam)*T) + +lemma normalizedFourierCoefficients_zero_iff (s : Fin 3 → ℝ) (lam T : ℝ) + (a : (Fin 2 → ℤ) → ℝ) (h : Fin 2 → ℤ) : + normalizedFourierCoefficients s lam T a h=0 ↔ a h=0 := by + simp [normalizedFourierCoefficients,exp_ne_zero] + +lemma normalizedFourierCoefficients_bound {s : Fin 3 → ℝ} {lam T B : ℝ} + {a : (Fin 2 → ℤ) → ℝ} (ha : ∀ h,|a h|≤B) (hT : 0≤T) + (hr : ∀ h,a h≠0 → lam≤torusRate s h) (h : Fin 2 → ℤ) : + |normalizedFourierCoefficients s lam T a h|≤B := by + by_cases hz : a h=0 + · simpa only [normalizedFourierCoefficients,hz,zero_mul,abs_zero] using + (abs_nonneg (a h)).trans (ha h) + have he : exp (-(torusRate s h-lam)*T)≤1 := exp_le_one_iff.mpr + (mul_nonpos_of_nonpos_of_nonneg (neg_nonpos.mpr (sub_nonneg.mpr (hr h hz))) hT) + rw [normalizedFourierCoefficients,abs_mul,abs_of_pos (exp_pos _)] + exact (mul_le_mul_of_nonneg_left he (abs_nonneg _)).trans (by simpa using ha h) + +lemma flatFourier_normalized_translation (s : Fin 3 → ℝ) (lam T : ℝ) + (a phase : (Fin 2 → ℤ) → ℝ) (x : Coord3) : + flatFourier s (normalizedFourierCoefficients s lam T a) phase x= + exp (lam*T)*flatFourier s a phase (x+![T,0,0]) := by + rw [flatFourier_translation,←flatFourier_const_mul] + unfold flatFourier + apply tsum_congr + intro h + have he : exp (-(torusRate s h-lam)*T)=exp (lam*T)*exp (-torusRate s h*T) := by + rw [←exp_add] + congr 1 + ring + simp only [normalizedFourierCoefficients,he] + ring + +lemma pureWallMode_eq_flatPhaseMode (s : Fin 3 → ℝ) (k : ℤ) (x : Coord3) : + pureWallMode 1 (torusRate s ![0,k]) (k:ℝ) (boxCoordinates x)=flatPhaseMode s ![0,k] 0 x := by + simp [pureWallMode,flatPhaseMode,torusAngular,boxCoordinates_apply] + +lemma single_fourier_coeff_bound (h : Fin 2 → ℤ) (k : Fin 2 → ℤ) : |(Pi.single h (1:ℝ) : (Fin 2 → ℤ) → ℝ) k|≤1 := by + classical + by_cases hk : k=h + · subst k; simp + · simp [Pi.single_eq_of_ne hk] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeFiniteEndNormal.lean b/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeFiniteEndNormal.lean new file mode 100644 index 0000000000000000000000000000000000000000..50ab40022ef0f06a0ebca6487c4831436e130ea5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeFiniteEndNormal.lean @@ -0,0 +1,205 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.GeneralModeEndingScalarization +import OAI.Analysis.Conductivity.Fourier.FourierFiniteEndingNormal + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology TopologicalSpace MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +local instance generalModeFiniteEndNormalMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance generalModeFiniteEndNormalBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem general_mode_finite_ending_raw_normal {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {h₀ : Fin 2 → ℤ} (hh₀ : h₀≠0) + {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + obtain ⟨k,Q,hk,hQ,he⟩ := leading_frequency_SL2_alignment hh₀ + let m := Real.sqrt (angularNormalization Q) + have hm : 0 < m := Real.sqrt_pos.mpr (angularNormalization_pos Q) + let e := angularFrequencyEquiv Q hQ + let θ : Fin 2 → ℝ := ![0,-pb h₀/(k:ℝ)] + let a' : (Fin 2 → ℤ) → ℝ := fun h => a (e.symm h)/m + let b' : (Fin 2 → ℤ) → ℝ := b ∘ e.symm + let pa' := angularShiftPhase (pa ∘ e.symm) θ + let pb' := angularShiftPhase (pb ∘ e.symm) θ + have hphase : pb' ![0,k]=0 := by + have he0 : e.symm ![0,k]=h₀ := by + rw [←he] + exact e.symm_apply_apply h₀ + dsimp [pb',angularShiftPhase] + rw [he0] + exact alignedPhaseTranslation_zero hk (pb h₀) + have hmode (x : Coord3) : + flatPhaseMode s h₀ (pb h₀) (angularNormalizedLift Q (angularRealTranslation θ x))= + flatPhaseMode (normalizedAngularTensor s Q) ![0,k] 0 x := by + rw [flatPhaseMode_angular_conjugacy s hQ,he,flatPhaseMode_angular_translation] + rw [show pb h₀+((![0,k] : Fin 2 → ℤ) 0:ℝ)*θ 0+ + ((![0,k] : Fin 2 → ℤ) 1:ℝ)*θ 1=0 from alignedPhaseTranslation_zero hk (pb h₀)] + have hab : ∀ h,|a' h|≤A/m := by + intro h + dsimp [a'] + rw [abs_div,abs_of_pos hm] + exact (div_le_div_iff_of_pos_right hm).2 (ha _) + have hbb : ∀ h,|b' h|≤B := fun h => hb (e.symm h) + have hgapA := angular_conjugacy_gap s hQ (a:=a) (lam:=0) hga + (fun h hh => by simpa only [zero_add] using hra h hh) + have hgapB := angular_conjugacy_gap s hQ hgb hrb + have hrate : torusRate (normalizedAngularTensor s Q) ![0,k]=m*torusRate s h₀ := by + rw [←he,torusRate_angular_conjugacy s hQ] + have hra' : ∀ h,a' h≠0 → m*ga≤torusRate (normalizedAngularTensor s Q) h := by + intro h hh + have hh' : (a ∘ e.symm) h≠0 := by + intro hz + apply hh + dsimp [a'] + rw [show a (e.symm h)=0 from hz,zero_div] + simpa only [mul_zero,zero_add] using hgapA.2 h hh' + have hrb' : ∀ h,b' h≠0 → torusRate (normalizedAngularTensor s Q) ![0,k]+m*gb≤ + torusRate (normalizedAngularTensor s Q) h := by + intro h hh + rw [hrate] + exact hgapB.2 h hh + obtain ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hv,hEm,hvp,hEp,⟨hsym,hreg⟩,hbound,hvin,hEin,hterm,hnormal,_hrank,hG,hpde⟩ := + aligned_fourier_finite_ending_with_normal (pa:=pa') + (normalizedAngularTensor_lower hs hQ) hk (div_nonneg hA hm.le) hB hab hbb + (mul_pos hm hga) (mul_pos hm hgb) hra' hrb' hphase hδ + refine ⟨Q,θ,k,hQ,hk,he,p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,?_,hEin,hterm,hnormal,hreg,hG,hpde⟩ + intro x hx + rw [hvin x hx,hmode] + congr 1 + · congr 1 + rw [normalizedFourierCoefficients_div,flatFourier_div_coefficients] + congr 1 + simpa only [pa',e,Function.comp_def,mul_zero] using normalized_flatFourier_angular_conjugacy s hQ a pa 0 (10+1/p) θ x + · rw [hrate] + congr 2 + simpa only [b',pb',m,e,Function.comp_apply] using normalized_flatFourier_angular_conjugacy s hQ b pb (torusRate s h₀) (10+1/p) θ x + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def angularInverseLift (A : Matrix (Fin 2) (Fin 2) ℤ) (x : Coord3) : Coord3 := + ![x 0/Real.sqrt (angularNormalization A), + (A 1 1:ℝ)*x 1-(A 0 1:ℝ)*x 2,-(A 1 0:ℝ)*x 1+(A 0 0:ℝ)*x 2] + +def angularNormalizedLinear (A : Matrix (Fin 2) (Fin 2) ℤ) : Coord3 →ₗ[ℝ] Coord3 where + toFun := angularNormalizedLift A + map_add' x y := by ext i; fin_cases i <;> simp [angularNormalizedLift] <;> ring + map_smul' c x := by ext i; fin_cases i <;> simp [angularNormalizedLift] <;> ring + +def angularInverseLinear (A : Matrix (Fin 2) (Fin 2) ℤ) : Coord3 →ₗ[ℝ] Coord3 where + toFun := angularInverseLift A + map_add' x y := by ext i; fin_cases i <;> simp [angularInverseLift] <;> ring + map_smul' c x := by ext i; fin_cases i <;> simp [angularInverseLift] <;> ring + +lemma real_angular_det_one {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) : + (A 0 0:ℝ)*(A 1 1:ℝ)-(A 0 1:ℝ)*(A 1 0:ℝ)=1 := by + have h : A 0 0*A 1 1-A 0 1*A 1 0=1 := by simpa only [Matrix.det_fin_two] using hA + exact_mod_cast h + +lemma angularNormalizedLift_inverse {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) (x : Coord3) : + angularNormalizedLift A (angularInverseLift A x)=x := by + have hd := real_angular_det_one hA + have hm : Real.sqrt (angularNormalization A)≠0 := (Real.sqrt_pos.mpr (angularNormalization_pos A)).ne' + ext i + fin_cases i + · change Real.sqrt (angularNormalization A) * (x 0 / Real.sqrt (angularNormalization A)) = x 0 + field_simp [hm] + · change (A 0 0:ℝ)*((A 1 1:ℝ)*x 1-(A 0 1:ℝ)*x 2)+ + (A 0 1:ℝ)*(-(A 1 0:ℝ)*x 1+(A 0 0:ℝ)*x 2)=x 1 + nlinarith [congrArg (fun z : ℝ => z*x 1) hd] + · change (A 1 0:ℝ)*((A 1 1:ℝ)*x 1-(A 0 1:ℝ)*x 2)+ + (A 1 1:ℝ)*(-(A 1 0:ℝ)*x 1+(A 0 0:ℝ)*x 2)=x 2 + nlinarith [congrArg (fun z : ℝ => z*x 2) hd] + +lemma angularInverseLift_normalized {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) (x : Coord3) : + angularInverseLift A (angularNormalizedLift A x)=x := by + have hd := real_angular_det_one hA + have hm : Real.sqrt (angularNormalization A)≠0 := (Real.sqrt_pos.mpr (angularNormalization_pos A)).ne' + ext i + fin_cases i + · simp [angularNormalizedLift,angularInverseLift,hm] + · change (A 1 1:ℝ)*((A 0 0:ℝ)*x 1+(A 0 1:ℝ)*x 2)- + (A 0 1:ℝ)*((A 1 0:ℝ)*x 1+(A 1 1:ℝ)*x 2)=x 1 + nlinarith [congrArg (fun z : ℝ => z*x 1) hd] + · change -(A 1 0:ℝ)*((A 0 0:ℝ)*x 1+(A 0 1:ℝ)*x 2)+ + (A 0 0:ℝ)*((A 1 0:ℝ)*x 1+(A 1 1:ℝ)*x 2)=x 2 + nlinarith [congrArg (fun z : ℝ => z*x 2) hd] + +def angularNormalizedEquiv (A : Matrix (Fin 2) (Fin 2) ℤ) (hA : A.det=1) : Coord3 ≃L[ℝ] Coord3 := + (LinearEquiv.ofLinearMap (angularNormalizedLinear A) (angularInverseLinear A) + (by apply LinearMap.ext; intro x; exact angularNormalizedLift_inverse hA x) + (by apply LinearMap.ext; intro x; exact angularInverseLift_normalized hA x)).toContinuousLinearEquiv + +@[simp] lemma angularNormalizedEquiv_apply (A : Matrix (Fin 2) (Fin 2) ℤ) (hA : A.det=1) (x : Coord3) : + angularNormalizedEquiv A hA x=angularNormalizedLift A x := rfl + +@[simp] lemma angularNormalizedEquiv_symm_apply (A : Matrix (Fin 2) (Fin 2) ℤ) (hA : A.det=1) (x : Coord3) : + (angularNormalizedEquiv A hA).symm x=angularInverseLift A x := rfl + +def angularLiftMatrix (A : Matrix (Fin 2) (Fin 2) ℤ) : Mat3 := + !![Real.sqrt (angularNormalization A),0,0; + 0,(A 0 0:ℝ),(A 0 1:ℝ);0,(A 1 0:ℝ),(A 1 1:ℝ)] + +lemma operatorMatrix_angularNormalizedEquiv (A : Matrix (Fin 2) (Fin 2) ℤ) (hA : A.det=1) : + operatorMatrix (angularNormalizedEquiv A hA : Coord3 →L[ℝ] Coord3)=angularLiftMatrix A := by + ext i j + fin_cases i <;> fin_cases j <;> + simp [operatorMatrix,angularLiftMatrix,angularNormalizedEquiv,angularNormalizedLinear, + angularNormalizedLift] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeRecombinedEnding.lean b/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeRecombinedEnding.lean new file mode 100644 index 0000000000000000000000000000000000000000..fd8592be85f59065b2ac1d078428b797a8fbd754 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/GeneralModeRecombinedEnding.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.GeneralModeEndingScalarization +import OAI.Analysis.Conductivity.Variational.VoltageRecombination + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +local instance generalModeRecombinedEndingMeasurableSpaceMat3 : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance generalModeRecombinedEndingBorelSpaceMat3 : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem general_mode_ending_affine_H1_scalarization {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {h₀ : Fin 2 → ℤ} (hh₀ : h₀≠0) + {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : voltageH1Jets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (σ : Coord3 → ℝ), + Measurable σ ∧ MemLp σ ∞ (volume.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _)∈zeroVoltageJets volume U ∧ + (∀ᵐ x ∂volume.restrict U,σ x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=σ x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets volume U,inner ℝ W.val.2 F=0) ∧ + ∀ (M : Matrix (Fin 2) (Fin 2) ℝ) (d : Fin 2 → ℝ), + ∃ (hu' : MemLp (fun x => voltageRecombine M (v x)+d) 2 (volume.restrict U)) + (hE' : MemLp (voltageGradient (fun x => voltageRecombine M (v x)+d)) 2 (volume.restrict U)) + (z' : voltageH1Jets volume U) (F' : Lp FieldVector 2 (volume.restrict U)), + z'.val-(hu'.toLp _,hE'.toLp _)∈zeroVoltageJets volume U ∧ + (∀ᵐ x ∂volume.restrict U,F' x=σ x • z'.val.2 x) ∧ + (∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F'= + inner ℝ W.val.2 ((fieldRecombine M).compLpL 2 (volume.restrict U) (hF.toLp _))) ∧ + (∀ W : zeroVoltageJets volume U,inner ℝ W.val.2 F'=0) := by + obtain ⟨Q,θ,k,hQ,hk,he,p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,hvin,hEin,hterm,hscalar⟩ := + general_mode_ending_H1_scalarization (pa:=pa) (pb:=pb) hs hh₀ hA hB ha hb hga hgb hra hrb hδ + refine ⟨Q,θ,k,hQ,hk,he,p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,hvin,hEin,hterm,?_⟩ + intro U hU hUb hUh + obtain ⟨hu,hE,hF,z,F,σ,hσm,hσb,hzero,hconst,hcauchy,hweak⟩ := hscalar U hU hUb hUh + refine ⟨hu,hE,hF,z,F,σ,hσm,hσb,hzero,hconst,hcauchy,hweak,?_⟩ + intro M d + let : IsFiniteMeasure (volume.restrict U) := + isFiniteMeasure_restrict.mpr hUb.measure_lt_top.ne + obtain ⟨z',F',hz',hF',hzero',hconst',hcauchy',hweak'⟩ := + scalar_voltage_affine_recombine volume U M d z (hu.toLp _,hE.toLp _) F (hF.toLp _) σ + hzero (hconst.mono fun _ hx => hx.2) hcauchy hweak + obtain ⟨hu',hE',hjet⟩ := voltageJetRecombine_affine_toLp volume U M d + (hv.differentiable (by norm_num)) hu hE + refine ⟨hu',hE',z',F',?_,hconst',hcauchy',hweak'⟩ + rwa [hjet] at hzero' + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/LeadingFrequencyAlignment.lean b/lean/OAI/Analysis/Conductivity/Fourier/LeadingFrequencyAlignment.lean new file mode 100644 index 0000000000000000000000000000000000000000..5631fafd217fca281028f8cf1487a8bd7a58c30f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/LeadingFrequencyAlignment.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +theorem leading_frequency_SL2_alignment {h : Fin 2 → ℤ} (hh : h≠0) : + ∃ (k : ℤ) (A : Matrix (Fin 2) (Fin 2) ℤ), + 0 x*v+y*(-u)) h0 h1 + _ = 0 := by ring + · simp only [Matrix.vecMul,dotProduct,Fin.sum_univ_two,Matrix.of_apply, + Matrix.cons_val_zero,Matrix.cons_val_one] + change h 0*a+h 1*b=(Int.gcd (h 0) (h 1):ℤ) + calc + _ = (u*a+v*b)*(Int.gcd (h 0) (h 1):ℤ) := by + calc + _ = (u*(Int.gcd (h 0) (h 1):ℤ))*a+(v*(Int.gcd (h 0) (h 1):ℤ))*b := + congrArg₂ (fun x y : ℤ => x*a+y*b) h0 h1 + _ = _ := by ring + _ = _ := by rw [hab,one_mul] + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +def angularIntMap (A : Matrix (Fin 2) (Fin 2) ℤ) : + UnitAddTorus (Fin 2) →+ UnitAddTorus (Fin 2) where + toFun x := ![A 0 0 • x 0+A 0 1 • x 1,A 1 0 • x 0+A 1 1 • x 1] + map_zero' := by ext i; fin_cases i <;> simp + map_add' x y := by ext i; fin_cases i <;> simp [smul_add] <;> abel + +lemma angularIntMap_continuous (A : Matrix (Fin 2) (Fin 2) ℤ) : + Continuous (angularIntMap A) := by + apply continuous_pi + intro i + fin_cases i <;> + exact (continuous_apply 0 |>.zsmul _).add (continuous_apply 1 |>.zsmul _) + +lemma angularIntMap_surjective {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) : + Function.Surjective (angularIntMap A) := by + have hd : A 0 0*A 1 1-A 0 1*A 1 0=1 := by simpa only [Matrix.det_fin_two] using hA + intro y + refine ⟨![A 1 1 • y 0- A 0 1 • y 1,-A 1 0 • y 0+A 0 0 • y 1],?_⟩ + ext i + fin_cases i + · change A 0 0 • (A 1 1 • y 0-A 0 1 • y 1)+ + A 0 1 • (-A 1 0 • y 0+A 0 0 • y 1)=y 0 + calc + _ = (A 0 0*A 1 1-A 0 1*A 1 0) • y 0 := by module + _ = _ := by rw [hd,one_smul] + · change A 1 0 • (A 1 1 • y 0-A 0 1 • y 1)+ + A 1 1 • (-A 1 0 • y 0+A 0 0 • y 1)=y 1 + calc + _ = (A 0 0*A 1 1-A 0 1*A 1 0) • y 1 := by module + _ = _ := by rw [hd,one_smul] + +lemma angularIntMap_measurePreserving {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) : + MeasurePreserving (angularIntMap A) (volume : Measure (UnitAddTorus (Fin 2))) volume := + AddMonoidHom.measurePreserving (angularIntMap_continuous A) (angularIntMap_surjective hA) rfl + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +def angularNormalization (A : Matrix (Fin 2) (Fin 2) ℤ) : ℝ := + (A 0 0:ℝ)^2+(A 0 1:ℝ)^2+(A 1 0:ℝ)^2+(A 1 1:ℝ)^2+1 + +def normalizedAngularTensor (s : Fin 3 → ℝ) (A : Matrix (Fin 2) (Fin 2) ℤ) : Fin 3 → ℝ := + let a : ℝ := A 0 0 + let b : ℝ := A 0 1 + let c : ℝ := A 1 0 + let d : ℝ := A 1 1 + let M := angularNormalization A + ![M*(s 0*d^2-2*s 1*b*d+s 2*b^2), + M*(-s 0*c*d+s 1*(a*d+b*c)-s 2*a*b), + M*(s 0*c^2-2*s 1*a*c+s 2*a^2)] + +lemma angularNormalization_pos (A : Matrix (Fin 2) (Fin 2) ℤ) : + 0 |(smoothDirection v f).val x|) μ := + ((smoothScalar_contDiff (smoothDirection v f)).continuous.abs).integrable_of_hasCompactSupport + (compactSupport_smoothDirection v hf).abs + calc + |∫ x, (smoothDirection v f).val x * g.val x ∂μ| ≤ + ∫ x, |(smoothDirection v f).val x * g.val x| ∂μ := abs_integral_le_integral_abs + _ ≤ ∫ x, (k⁻¹ * C) * |(smoothDirection v f).val x| ∂μ := by + apply integral_mono_of_nonneg + · filter_upwards [] with x + positivity + · exact hi.const_mul _ + · filter_upwards [] with x + change |(smoothDirection v f).val x * (k⁻¹ * H.val (k * L x))| ≤ _ + rw [abs_mul, abs_mul, abs_of_nonneg (inv_nonneg.mpr hk.le)] + nlinarith [mul_le_mul_of_nonneg_left (hC (k * L x)) + (mul_nonneg (abs_nonneg ((smoothDirection v f).val x)) (inv_nonneg.mpr hk.le))] + _ = _ := by rw [integral_const_mul] + +theorem periodic_oscillations_weak + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (f : SmoothScalar E) (hf : HasCompactSupport f.val) + (h : SmoothScalar ℝ) (hper : Function.Periodic h.val 1) + (hmean : ∫ t in (0 : ℝ)..1, h.val t = 0) : + Filter.Tendsto (fun n : ℕ => ∫ x, f.val x * h.val ((n + 1 : ℝ) * L x) ∂μ) + Filter.atTop (nhds 0) := by + obtain ⟨v, hv⟩ : ∃ v, L v = 1 := by + have hex : ∃ w, L w ≠ 0 := by + by_contra hn + apply hL + ext w + simpa using not_exists.mp hn w + obtain ⟨w, hw⟩ := hex + refine ⟨(L w)⁻¹ • w, ?_⟩ + simp [hw] + obtain ⟨H₁, H₂, hd₁, hd₂, hp₁, hp₂, ⟨C, hb₁⟩, hb₂⟩ := + periodic_two_primitives h hper hmean + have hb (n : ℕ) := linear_phase_derivative_integral_bound μ v L hv f hf H₁ C hb₁ + (by positivity : (0 : ℝ) < n + 1) + simp only [hd₁] at hb + apply tendsto_of_tendsto_of_tendsto_of_le_of_le + (g := fun n : ℕ => -((n + 1 : ℝ)⁻¹ * C * ∫ x, |(smoothDirection v f).val x| ∂μ)) + (h := fun n : ℕ => (n + 1 : ℝ)⁻¹ * C * ∫ x, |(smoothDirection v f).val x| ∂μ) + · simpa using ((tendsto_inv_atTop_zero.comp (Filter.tendsto_atTop_add_const_right _ 1 tendsto_natCast_atTop_atTop)).mul_const C + |>.mul_const (∫ x, |(smoothDirection v f).val x| ∂μ)).neg + · simpa using ((tendsto_inv_atTop_zero.comp (Filter.tendsto_atTop_add_const_right _ 1 tendsto_natCast_atTop_atTop)).mul_const C + |>.mul_const (∫ x, |(smoothDirection v f).val x| ∂μ)) + · exact fun n => (abs_le.mp (hb n)).1 + · exact fun n => (abs_le.mp (hb n)).2 + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/ModeConnector.lean b/lean/OAI/Analysis/Conductivity/Fourier/ModeConnector.lean new file mode 100644 index 0000000000000000000000000000000000000000..53a969ba81522f10b6cd0fe92f88a8c369e4bb0b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/ModeConnector.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.SmoothPrimitive + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory + +def connectorRate (K z : ℝ) : ℝ := + 1/2 + (5/2)*smoothTransition ((z-1)/K) + +def connectorProfile (K z : ℝ) : ℝ := + exp (-(∫ t in (0 : ℝ)..z, connectorRate K t)) + +lemma connectorRate_smooth (K : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (connectorRate K) := by + exact contDiff_const.add (contDiff_const.mul (smoothTransition.contDiff.comp + ((contDiff_id.sub contDiff_const).div_const K))) + +lemma connectorRate_bounds (K z : ℝ) : 1/2 ≤ connectorRate K z ∧ connectorRate K z ≤ 3 := by + have h₁ := smoothTransition.nonneg ((z-1)/K) + have h₂ := smoothTransition.le_one ((z-1)/K) + constructor <;> dsimp [connectorRate] <;> linarith + +lemma connectorRate_left {K z : ℝ} (hK : 0 < K) (hz : z ≤ 1) : + connectorRate K z = 1/2 := by + rw [connectorRate,smoothTransition.zero_of_nonpos + (div_nonpos_of_nonpos_of_nonneg (by linarith) hK.le)] + ring +lemma connectorRate_right {K z : ℝ} (hK : 0 < K) (hz : K+1 ≤ z) : + connectorRate K z = 3 := by + rw [connectorRate,smoothTransition.one_of_one_le + ((le_div_iff₀ hK).mpr (by linarith))] + ring + +lemma connectorRate_hasDerivAt (K z : ℝ) : HasDerivAt (connectorRate K) + ((5/(2*K))*deriv smoothTransition ((z-1)/K)) z := by + have h := ((smoothTransition.contDiff (n := ⊤)).differentiable (by simp) + ((z-1)/K)).hasDerivAt + have hh := ((h.comp z (((hasDerivAt_id z).sub_const 1).div_const K)).const_mul (5/2)).const_add (1/2) + have he : (5/2)*(deriv smoothTransition ((z-1)/K)*(1/K)) = + (5/(2*K))*deriv smoothTransition ((z-1)/K) := by ring + change HasDerivAt (fun w => 1/2+(5/2)*smoothTransition ((w-1)/K)) + ((5/(2*K))*deriv smoothTransition ((z-1)/K)) z + exact hh.congr_deriv (g' := (5/(2*K))*deriv smoothTransition ((z-1)/K)) he + +lemma connectorRate_derivative_bounds {M K : ℝ} (hM : 1 ≤ M) (hK : 20*M ≤ K) + (hbound : ∀ x : ℝ, |deriv smoothTransition x| ≤ M) (z : ℝ) : + 0 ≤ deriv (connectorRate K) z ∧ deriv (connectorRate K) z ≤ 1/8 := by + have hKp : 0 < K := by linarith + rw [(connectorRate_hasDerivAt K z).deriv] + have hn : 0 ≤ deriv smoothTransition ((z-1)/K) := smoothTransition.monotone.deriv_nonneg + have hu : deriv smoothTransition ((z-1)/K) ≤ M := + (le_abs_self _).trans (hbound _) + constructor + · positivity + · calc + _ ≤ (5/(2*K))*M := mul_le_mul_of_nonneg_left hu (by positivity) + _ ≤ 1/8 := by + rw [div_mul_eq_mul_div,div_le_iff₀ (by positivity : 0 < 2*K)] + linarith + +lemma connectorProfile_pos (K z : ℝ) : 0 < connectorProfile K z := exp_pos _ +lemma connectorProfile_smooth (K : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (connectorProfile K) := by + let r : SmoothScalar ℝ := ⟨connectorRate K,connectorRate_smooth K⟩ + exact ((smoothScalar_contDiff (smoothPrimitive r)).neg).exp + +lemma connectorProfile_hasDerivAt (K z : ℝ) : HasDerivAt (connectorProfile K) + (-connectorRate K z*connectorProfile K z) z := by + have hr := (connectorRate_smooth K).continuous + have h := intervalIntegral.integral_hasDerivAt_right (hr.intervalIntegrable 0 z) + (hr.stronglyMeasurableAtFilter _ _) hr.continuousAt + change HasDerivAt (fun w => exp (-(∫ t in (0:ℝ)..w, connectorRate K t))) + (-connectorRate K z*connectorProfile K z) z + exact h.neg.exp.congr_deriv (g' := -connectorRate K z*connectorProfile K z) + (by simp only [connectorProfile,Pi.neg_apply]; ring) + +lemma connectorProfile_second (K z : ℝ) : + deriv (deriv (connectorProfile K)) z = + ((connectorRate K z)^2-deriv (connectorRate K) z)*connectorProfile K z := by + have he : deriv (connectorProfile K) = fun z => -connectorRate K z*connectorProfile K z := + funext fun z => (connectorProfile_hasDerivAt K z).deriv + rw [he] + have h := (((connectorRate_smooth K).differentiable (by simp) z).hasDerivAt.neg).mul + (connectorProfile_hasDerivAt K z) + simp only [Pi.mul_def,Pi.neg_def] at h + rw [h.deriv] + ring + +def connectorAngular (K z : ℝ) : ℝ := + deriv (deriv (connectorProfile K)) z / connectorProfile K z + +lemma connectorAngular_formula (K z : ℝ) : connectorAngular K z = + (connectorRate K z)^2-deriv (connectorRate K) z := by + rw [connectorAngular,connectorProfile_second,mul_div_cancel_right₀ _ + (connectorProfile_pos K z).ne'] + +lemma connectorAngular_bounds {M K : ℝ} (hM : 1 ≤ M) (hK : 20*M ≤ K) + (hbound : ∀ x : ℝ, |deriv smoothTransition x| ≤ M) (z : ℝ) : + 1/8 ≤ connectorAngular K z ∧ connectorAngular K z ≤ 9 := by + rw [connectorAngular_formula] + obtain ⟨hl,hu⟩ := connectorRate_bounds K z + obtain ⟨hdl,hdu⟩ := connectorRate_derivative_bounds hM hK hbound z + constructor <;> nlinarith + +lemma connectorProfile_zero (K : ℝ) : connectorProfile K 0 = 1 := by + simp [connectorProfile] + +lemma connector_integral_pos {K : ℝ} (hK : 0 < K) : + 0 < ∫ t in (0 : ℝ)..(K+2), connectorRate K t := by + have hle : (K+2)/2 ≤ ∫ t in (0 : ℝ)..(K+2), connectorRate K t := by + calc + _ = ∫ _t in (0 : ℝ)..(K+2), (1/2 : ℝ) := by simp; ring + _ ≤ _ := intervalIntegral.integral_mono_on (by linarith) + (continuous_const.intervalIntegrable _ _) + ((connectorRate_smooth K).continuous.intervalIntegrable _ _) + (fun x _ => (connectorRate_bounds K x).1) + linarith + +lemma connectorProfile_le_one {K z : ℝ} (hz : 0 ≤ z) : connectorProfile K z ≤ 1 := by + apply exp_le_one_iff.mpr + have hn : 0 ≤ ∫ t in (0 : ℝ)..z, connectorRate K t := + intervalIntegral.integral_nonneg hz (fun t _ => le_trans (by norm_num) (connectorRate_bounds K t).1) + exact neg_nonpos.mpr hn + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PeriodicAveragingSmooth.lean b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicAveragingSmooth.lean new file mode 100644 index 0000000000000000000000000000000000000000..cfe9c0e930f7567c59825f87b5f4e9b09e7d07a7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicAveragingSmooth.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.LinearPhaseDerivativeIntegralBound +import OAI.Analysis.Conductivity.Variational.TransitionMajorant + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +namespace ScalarConductivity + +theorem periodic_averaging_smooth + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (f : SmoothScalar E) (hf : HasCompactSupport f.val) + (h : SmoothScalar ℝ) (hper : Function.Periodic h.val 1) : + Tendsto (fun n : ℕ => ∫ x, f.val x * h.val ((n + 1 : ℝ) * L x) ∂μ) + atTop (𝓝 ((∫ t in (0 : ℝ)..1, h.val t) * ∫ x, f.val x ∂μ)) := by + let m : ℝ := ∫ t in (0 : ℝ)..1, h.val t + let g : SmoothScalar ℝ := h - algebraMap ℝ (SmoothScalar ℝ) m + have hg : Function.Periodic g.val 1 := by + intro t + change h.val (t + 1) - m = h.val t - m + rw [hper t] + have hm : (∫ t in (0 : ℝ)..1, g.val t) = 0 := by + change (∫ t in (0 : ℝ)..1, h.val t - m) = 0 + rw [intervalIntegral.integral_sub ((smoothScalar_contDiff h).continuous.intervalIntegrable _ _) + intervalIntegrable_const] + simp [m] + have hi : Integrable f.val μ := (smoothScalar_contDiff f).continuous.integrable_of_hasCompactSupport hf + have he (n : ℕ) : (∫ x, f.val x * h.val ((n + 1 : ℝ) * L x) ∂μ) = + (∫ x, f.val x * g.val ((n + 1 : ℝ) * L x) ∂μ) + m * ∫ x, f.val x ∂μ := by + have hi' : Integrable (fun x => f.val x * h.val ((n + 1 : ℝ) * L x)) μ := + ((smoothScalar_contDiff f).continuous.mul + ((smoothScalar_contDiff h).continuous.comp (continuous_const.mul L.continuous))).integrable_of_hasCompactSupport (hf.mul_right) + change _ = (∫ x, f.val x * (h.val ((n + 1 : ℝ) * L x) - m) ∂μ) + _ + simp_rw [mul_sub] + rw [integral_sub hi' (hi.mul_const m), integral_mul_const] + ring + simp_rw [he] + simpa only [zero_add] using (periodic_oscillations_weak μ L hL f hf g hg hm).add_const + (m * ∫ x, f.val x ∂μ) + +theorem eventually_impure_measure_le + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (f : SmoothScalar E) (hf : HasCompactSupport f.val) (hfn : ∀ x, 0 ≤ f.val x) + (S : Set E) (hS : ∀ x ∈ S, 1 ≤ f.val x) + {θ δ ε : ℝ} (hδ : 0 < δ) (hδθ : δ ≤ θ) (hw : θ + δ ≤ 1) + (hδw : 3 * δ ≤ 1) (hε : 4 * δ * (∫ x, f.val x ∂μ) < ε) : + ∀ᶠ n : ℕ in atTop, + μ {x | x ∈ S ∧ periodicPulse θ δ ((n + 1 : ℝ) * L x) ≠ 0 ∧ + periodicPulse θ δ ((n + 1 : ℝ) * L x) ≠ 1} ≤ ENNReal.ofReal ε := by + let H : SmoothScalar ℝ := ⟨transitionMajorant θ δ, transitionMajorant_smooth hδ⟩ + have ht := periodic_averaging_smooth μ L hL f hf H (transitionMajorant_periodic θ δ) + change Tendsto _ _ (𝓝 ((∫ t in (0 : ℝ)..1, transitionMajorant θ δ t) * ∫ x, f.val x ∂μ)) at ht + rw [transitionMajorant_integral hδ hδw] at ht + filter_upwards [ht.eventually_lt_const hε] with n hn + have hi : Integrable (fun x => f.val x * transitionMajorant θ δ ((n + 1 : ℝ) * L x)) μ := + ((smoothScalar_contDiff f).continuous.mul + ((transitionMajorant_smooth hδ).continuous.comp (continuous_const.mul L.continuous))).integrable_of_hasCompactSupport (hf.mul_right) + apply (hi.measure_le_integral (ae_of_all μ (fun x => mul_nonneg (hfn x) + (transitionMajorant_bounds hδ hδw _).1)) ?_).trans (ENNReal.ofReal_le_ofReal hn.le) + intro x hx + calc + 1 = 1 * 1 := by norm_num + _ ≤ _ := mul_le_mul (hS x hx.1) (transitionMajorant_dominates hδ hδθ hw hδw hx.2.1 hx.2.2) (by norm_num) (by linarith [hS x hx.1]) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PeriodicBandCompactness.lean b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicBandCompactness.lean new file mode 100644 index 0000000000000000000000000000000000000000..66acabecfc8f7c830bae11b23092001eb9cdc1ed --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicBandCompactness.lean @@ -0,0 +1,212 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.FourierMatchingElliptic +import OAI.Analysis.Conductivity.Variational.SimpleLevelNull + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +lemma exists_angular_translate_mem_box {T : ℝ} (hT : 0 -⌊x i.succ/T⌋ + have hn (i : Fin 2) : 0≤x i.succ+T*(n i:ℝ) ∧ x i.succ+T*(n i:ℝ)≤T := by + have h0 := (le_div_iff₀ hT).mp (Int.floor_le (x i.succ/T)) + have h1 := (div_lt_iff₀ hT).mp (Int.lt_floor_add_one (x i.succ/T)) + simp only [n,Int.cast_neg] + constructor <;> nlinarith + refine ⟨n,?_,?_⟩ + · intro i + fin_cases i + · change a≤x 0+0 + simpa only [add_zero] using hx.1 + · exact (hn 0).1 + · exact (hn 1).1 + · intro i + fin_cases i + · change x 0+0≤b + simpa only [add_zero] using hx.2 + · exact (hn 0).2 + · exact (hn 1).2 + +variable {P : Type*} [TopologicalSpace P] + +lemma periodic_band_nonzero_eventually {F G : P×Coord3 → ℝ} + (hF : Continuous F) (hG : Continuous G) {T : ℝ} (hT : 0 F (p,x))) + (hpG : ∀ p,AngularPeriodic T (fun x => G (p,x))) + (p₀ : P) (a b : ℝ) + (hb : ∀ x : Coord3,x 0∈Icc a b → F (p₀,x)≠0 ∨ G (p₀,x)≠0) : + ∀ᶠ p in 𝓝 p₀,∀ x : Coord3,x 0∈Icc a b → F (p,x)≠0 ∨ G (p,x)≠0 := by + have he : ∀ᶠ p in 𝓝 p₀,∀ x∈Icc (![a,0,0] : Coord3) ![b,T,T], F (p,x)≠0 ∨ G (p,x)≠0 := by + apply isCompact_Icc.eventually_forall_of_forall_eventually + intro x hx + rcases hb x ⟨hx.1 0,hx.2 0⟩ with hf|hg + · exact (hF.continuousAt.eventually_ne hf).mono (fun z hz => Or.inl hz) + · exact (hG.continuousAt.eventually_ne hg).mono (fun z hz => Or.inr hz) + filter_upwards [he] with p hp + intro x hx + obtain ⟨n,hn⟩ := exists_angular_translate_mem_box hT x hx + simpa only [hpF p n x,hpG p n x] using hp (x+angularShift T n) hn + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Real + +lemma pairMinor_wallCoordinatePair {v : Box3 → ℝ} (hv : Differentiable ℝ v) (x : Coord3) : + pairMinor (wallCoordinatePair v) x=wallDerivative v (boxCoordinates x) := by + simp [pairMinor,wallCoordinatePair_derivative hv,boxCoordinates_apply,wallDerivative] + rfl + +lemma direction_boxCoordinates {v : Box3 → ℝ} (hv : Differentiable ℝ v) (x : Coord3) : + direction (Pi.single 2 1) (fun y => v (boxCoordinates y)) x=wallDerivative v (boxCoordinates x) := by + change fderiv ℝ (v ∘ boxCoordinates) x (Pi.single 2 1)=_ + rw [boxCoordinates_fderiv v hv] + simp [wallDerivative,boxCoordinates_apply] + rfl + +lemma pureMode_pairMinor_noncritical {σ lam k : ℝ} (hσ : σ≠0) (hk : k≠0) (x : Coord3) : + pairMinor (wallCoordinatePair (pureWallMode σ lam k)) x≠0 ∨ + direction (Pi.single 2 1) (pairMinor (wallCoordinatePair (pureWallMode σ lam k))) x≠0 := by + have hs := pureWallMode_smooth σ lam k + have he : pairMinor (wallCoordinatePair (pureWallMode σ lam k))= + fun x => wallDerivative (pureWallMode σ lam k) (boxCoordinates x) := + funext (pairMinor_wallCoordinatePair (hs.differentiable (by simp))) + rw [he,direction_boxCoordinates ((wallDerivative_smooth hs).differentiable (by simp))] + dsimp only + rw [boxCoordinates_apply,pureWallMode_normalDerivative,pureWallMode_normalSecond] + by_cases hz : sin (k*x 2)=0 + · right + have hc : cos (k*x 2)≠0 := by + intro hc + have hh := sin_sq_add_cos_sq (k*x 2) + rw [hz,hc] at hh + norm_num at hh + exact neg_ne_zero.mpr (mul_ne_zero (mul_ne_zero (mul_ne_zero hσ (exp_ne_zero _)) hc) (pow_ne_zero 2 hk)) + · left + exact mul_ne_zero (mul_ne_zero hσ (exp_ne_zero _)) (mul_ne_zero (neg_ne_zero.mpr hz) hk) + +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma familyDirection_smooth {f : P×Coord3 → ℝ} + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (v : Coord3) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fun z : P×Coord3 => direction v (fun y => f (z.1,y)) z.2) := by + have hh : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z : (P×Coord3)×Coord3 => f (z.1.1,z.2)) := + hf.comp ((contDiff_fst.comp contDiff_fst).prodMk contDiff_snd) + exact (hh.fderiv contDiff_snd (by simp)).clm_apply contDiff_const + +lemma AngularPeriodic.direction {T : ℝ} {f : Coord3 → ℝ} (hf : AngularPeriodic T f) (v : Coord3) : + AngularPeriodic T (direction v f) := by + intro n x + change _root_.fderiv ℝ f (x+angularShift T n) v=_root_.fderiv ℝ f x v + rw [hf.fderiv n x] + +theorem periodic_pure_mode_rank_eventually {u : P×Coord3 → Fin 2 → ℝ} + (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {T : ℝ} (hT : 0 u (p,x))) (p₀ : P) + {σ lam k : ℝ} (hσ : σ≠0) (hk : k≠0) + (hb : ∀ x,u (p₀,x)=wallCoordinatePair (pureWallMode σ lam k) x) (a b : ℝ) : + ∀ᶠ p in 𝓝 p₀,∀ x : Coord3,x 0∈Icc a b → pairMinor (fun y => u (p,y)) x=0 → + direction (Pi.single 2 1) (pairMinor (fun y => u (p,y))) x≠0 := by + have hM := familyPairMinor_smooth hu + have hN := familyDirection_smooth hM (Pi.single 2 1) + have he := periodic_band_nonzero_eventually hM.continuous hN.continuous hT + (fun p => (hp p).pairMinor) (fun p => (hp p).pairMinor.direction (Pi.single 2 1)) p₀ a b (by + intro x _ + have hh : (fun y => u (p₀,y))=wallCoordinatePair (pureWallMode σ lam k) := funext hb + simpa only [hh] using pureMode_pairMinor_noncritical hσ hk (lam:=lam) x) + filter_upwards [he] with p hp + intro x hx hz + exact (hp x hx).resolve_left (not_not.mpr hz) + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set Filter Topology Real Matrix MeasureTheory +open scoped Matrix.Norms.Elementwise + +theorem elliptic_fourier_matching_regular {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : k≠0) {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 simp [fourierMatchingPair,hfz,hgz,wallCoordinatePair,pureWallMode_eq_flatPhaseMode] + have hRank := periodic_pure_mode_rank_eventually hF (by positivity : 0<2*Real.pi) + (fourierMatchingPair_periodic s k hfp hgp) 0 (by norm_num : (1:ℝ)≠0) hk' hbase 0 6 + have hh := (hcor (1/12) (by norm_num)).and hRank + obtain ⟨r,hr,hrb'⟩ := Metric.mem_nhds_iff.mp hh + let p := min (r/2) (min (δ/2) (1/4)) + have hp : 0

fourierMatchingPair s k f g (p,x)), + (fun x => flatBackgroundTensor s+H x), + (fourierMatchingPair_smooth s k hfs hgs).comp (contDiff_const.prodMk contDiff_id), + contDiff_const.add hHs,fourierMatchingPair_periodic s k hfp hgp p,?_,?_,?_,hHe,?_,?_,?_,?_⟩ + · intro n x + dsimp only + rw [hHp n x] + · intro x + exact (flatBackgroundTensor_symm s).add (hHsym x) + · intro x v + exact flatBackgroundTensor_small_perturbation hs (hHb x) v + · intro x hx + have hz : H x=0 := image_eq_zero_of_notMem_tsupport (fun hx' => hx (hHt hx')) + dsimp only + rw [hz,add_zero] + · intro x hx + have hd := hdata p ⟨hp,hp2⟩ x ⟨hx.1,by linarith [hx.2]⟩ + simp only [fourierMatchingPair,fourierMatchingCutoff_left (show x 0≤2 by linarith [hx.2]),one_mul,hd.1,hd.2] + · intro x hx + simp only [fourierMatchingPair,fourierMatchingCutoff_right hx,zero_mul,add_zero] + + · have hU : IsOpen {x : Coord3 | x 0∈Ioo (0:ℝ) 6} := + isOpen_Ioo.preimage (continuous_apply 0) + have ha := simple_coord_zero_ae (pairMinor_smooth (hF.comp (contDiff_const.prodMk contDiff_id))) + hU.measurableSet (by + intro x hx + exact hr x ⟨hx.1.le,hx.2.le⟩) + filter_upwards [ha] with x hx + intro hxU + exact pairMinor_rank (hx hxU) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PeriodicFamilyCorrection.lean b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicFamilyCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..84c2138738a6b9b86c0f5219f0ecef9d997009f3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PeriodicFamilyCorrection.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.PureModeFamilyLocalCorrection +import OAI.Analysis.Conductivity.Fourier.AngularLocalizedMoments + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real Matrix +open scoped Matrix.Norms.Elementwise +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +lemma correctionBox_convex (a b : Coord3) : Convex ℝ (correctionBox a b) := by + have he : correctionBox a b=Set.univ.pi (fun i => Ioo (a i) (b i)) := by + ext x + simp only [mem_correctionBox,Set.mem_pi,mem_univ,true_implies,mem_Ioo] + rw [he] + exact convex_pi (fun _ _ => convex_Ioo _ _) + +theorem periodic_pure_mode_family_correction + {u v : P×Coord3 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (p : P) + {σ lam k T l a b d : ℝ} (hσ : σ≠0) (hlam : lam≠0) (hk : k≠0) (hT : 0 ![u (q,y),v (q,y)])) + {r : Fin 2 → P×Coord3 → ℝ} + (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) + (hrz : ∀ j x,r j (p,x)=0) + (hrp : ∀ j q,AngularPeriodic T (fun x => r j (q,x))) + (hrs : ∀ j q,tsupport (fun x => r j (q,x))⊆{x | x 0∈Icc a b}) + {ε : ℝ} (hε : 0<ε) : + ∀ᶠ q in 𝓝 p,periodicSourceMoment T (fun y => ![u (q,y),v (q,y)]) (fun j y => r j (q,y))=0 → + ∃ H : Coord3 → Mat3,ContDiff ℝ (↑(⊤:ℕ∞)) H ∧ AngularPeriodic T H ∧ + tsupport H⊆{x | x 0∈Icc l d} ∧ (∀ x,(H x).IsSymm) ∧ + (∀ j,symmetricSource H (fun y => ![u (q,y),v (q,y)]) j=(fun y => r j (q,y))) ∧ + ∀ x,‖H x‖≤ε := by + let L : Coord3 := ![l,-T-1,-T-1] + let D : Coord3 := ![d,T+1,T+1] + let U := correctionBox L D + let K : Set Coord3 := Icc ![a,-T,-T] ![b,T,T] + let R : Fin 2 → P×Coord3 → ℝ := fun j z => angularCutoff T z.2*r j z + have hKU : K⊆U := by + intro x hx + apply mem_correctionBox.mpr + intro i + fin_cases i + · exact ⟨hla.trans_le (hx.1 0),(hx.2 0).trans_lt hbd⟩ + · have h1 : -T≤x 1 ∧ x 1≤T := ⟨hx.1 1,hx.2 1⟩ + constructor <;> dsimp [L,D] <;> linarith [h1.1,h1.2] + · have h2 : -T≤x 2 ∧ x 2≤T := ⟨hx.1 2,hx.2 2⟩ + constructor <;> dsimp [L,D] <;> linarith [h2.1,h2.2] + have hR : SmoothVanishingPairFamily p U R := by + refine ⟨fun j => ((angularCutoff_smooth T).comp contDiff_snd).mul (hr j),?_,K,isCompact_Icc,hKU,?_⟩ + · intro j x + dsimp [R] + rw [hrz,mul_zero] + · intro q j + exact angularCutoff_compact_support hT (hrs j q) + obtain ⟨B,hB⟩ := (isCompact_Icc : IsCompact (Icc L D)).isBounded.exists_norm_le + obtain ⟨M,hM,hMp⟩ := angularPeriodize_uniform_bound (E:=Mat3) hT B + have hMr : (0:ℝ) ![u (q,y),v (q,y)]) := by + apply contDiff_pi.mpr + intro j + fin_cases j + · exact hu.comp (contDiff_const.prodMk contDiff_id) + · exact hv.comp (contDiff_const.prodMk contDiff_id) + have hmo : physicalSourceMoment (fun y => ![u (q,y),v (q,y)]) (fun j y => R j (q,y))=0 := by + exact (physicalSourceMoment_angularCutoff (r:=fun j x => r j (q,x)) hT hF.continuous (hup q) + (fun j => ((hr j).comp (contDiff_const.prodMk contDiff_id)).continuous) + (fun j => hrp j q) (fun j => hrs j q)).trans hm + obtain ⟨H,hH,hHc,hHs,hHsy,hHr,hHb⟩ := hq hmo + have hnorm : ∀ x,H x≠0 → ‖x‖≤B := by + intro x hx + apply hB x + have hh := mem_correctionBox.mp (hHs (subset_tsupport H hx)) + exact ⟨fun i => (hh i).1.le,fun i => (hh i).2.le⟩ + have hax : tsupport H⊆{x | x 0∈Icc l d} := by + intro x hx + have hh := mem_correctionBox.mp (hHs hx) 0 + exact ⟨hh.1.le,hh.2.le⟩ + refine ⟨angularPeriodize T H,angularPeriodize_smooth hT hH hHc, + angularPeriodize_periodic T H,angularPeriodize_axial_support hax, + angularPeriodize_symmetric hT hHc hHsy,?_,?_⟩ + · intro j + funext x + rw [symmetricSource_angularPeriodize hT hH hHc hF (hup q),hHr j] + exact congrFun (angularCutoff_periodize hT (hrp j q)) x + · intro x + have hh := hMp H (ε/M) hεM.le hnorm hHb x + have he : (M:ℝ)*(ε/M)=ε := by field_simp + rwa [he] at hh + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +lemma flatPhaseMode_angularPeriodic (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (phase : ℝ) : + AngularPeriodic (2*Real.pi) (flatPhaseMode s h phase) := by + intro n x + have he : torusAngular h (x+angularShift (2*Real.pi) n)+phase= + torusAngular h x+phase+(h 0*n 0+h 1*n 1:ℤ)*(2*Real.pi) := by + change (h 0:ℝ)*(x 1+2*Real.pi*(n 0:ℝ))+(h 1:ℝ)*(x 2+2*Real.pi*(n 1:ℝ))+phase= + (h 0:ℝ)*x 1+(h 1:ℝ)*x 2+phase+(h 0*n 0+h 1*n 1:ℤ)*(2*Real.pi) + push_cast + ring + change exp (-torusRate s h*(x 0+0))*cos (torusAngular h (x+angularShift (2*Real.pi) n)+phase)=_ + rw [add_zero,he,cos_add_int_mul_two_pi] + rfl + +lemma flatFourier_angularPeriodic (s : Fin 3 → ℝ) (a phase : (Fin 2 → ℤ) → ℝ) : + AngularPeriodic (2*Real.pi) (flatFourier s a phase) := by + intro n x + unfold flatFourier + apply tsum_congr + intro h + rw [flatPhaseMode_angularPeriodic s h (phase h) n x] + +lemma compactifiedFourierTail_angularPeriodic (s : Fin 3 → ℝ) (lam T0 : ℝ) + (a phase : (Fin 2 → ℤ) → ℝ) (p : ℝ) : + AngularPeriodic (2*Real.pi) (fun x => compactifiedFourierTail s lam T0 a phase (p,x)) := by + intro n x + unfold compactifiedFourierTail + apply tsum_congr + intro h + dsimp [compactifiedFourierTerm] + have he : x+angularShift (2*Real.pi) n+![T0,0,0]=(x+![T0,0,0])+angularShift (2*Real.pi) n := by abel + rw [he,flatPhaseMode_angularPeriodic] + +lemma exists_normalized_periodic_end_cutoff {R T0 δ : ℝ} (hT : δ-T0 < -R) : + ∃ ρ : (ℝ×Coord3)→ℝ,ContDiff ℝ (↑(⊤:ℕ∞)) ρ ∧ + tsupport ρ⊆Ioo (-1) 1 ×ˢ {x : Coord3 | δ-T0 ρ (p,x))) ∧ + (∀ p∈Icc (-(1:ℝ)/2) (1/2),∀ x : Coord3, x 0∈Icc (-R) R → ρ (p,x)=1) := by + let K : Set (ℝ×ℝ) := Icc (-(1:ℝ)/2) (1/2) ×ˢ Icc (-R) R + let Ω : Set (ℝ×ℝ) := Ioo (-1) 1 ×ˢ Ioo (δ-T0) (R+1) + have hK : IsCompact K := isCompact_Icc.prod isCompact_Icc + have hΩ : IsOpen Ω := isOpen_Ioo.prod isOpen_Ioo + have hb : Bornology.IsBounded Ω := + ((isCompact_Icc : IsCompact (Icc (-1:ℝ) 1)).isBounded.subset Ioo_subset_Icc_self).prod + ((isCompact_Icc : IsCompact (Icc (δ-T0) (R+1))).isBounded.subset Ioo_subset_Icc_self) + have hsub : K⊆Ω := by + intro z hz + exact ⟨⟨by linarith [hz.1.1],by linarith [hz.1.2]⟩, + ⟨hT.trans_le hz.2.1,by linarith [hz.2.2]⟩⟩ + obtain ⟨χ,hχ,hχc,hχs,hχb,hχ1⟩ := exists_smooth_core_cutoff hK hΩ hb hsub + let Q : (ℝ×Coord3)→(ℝ×ℝ) := fun z => (z.1,z.2 0) + have hQ : ContDiff ℝ (↑(⊤:ℕ∞)) Q := by dsimp [Q]; fun_prop + refine ⟨χ ∘ Q,hχ.comp hQ,?_,fun z => hχb _,?_,?_⟩ + · intro z hz + have he := hχs (tsupport_comp_subset_preimage χ hQ.continuous hz) + exact ⟨he.1,he.2.1⟩ + · intro p T n x + change χ (p,x 0+0)=χ (p,x 0) + rw [add_zero] + · intro p hp x hx + exact (hχ1 (p,x 0) ⟨hp,hx⟩).self_of_nhds + +theorem exists_smooth_periodic_normalized_tail {s : Fin 3→ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {lam T0 gap B δ R : ℝ} {a phase : (Fin 2→ℤ)→ℝ} + (hg : 0 f (p,x))) ∧ + (∀ p≤0,∀ x,f (p,x)=0) ∧ + (∀ p∈Ioc 0 (1/2),∀ x : Coord3,x 0∈Icc (-R) R → + f (p,x)=exp (lam*(T0+1/p))*flatFourier s a phase (x+![T0+1/p,0,0])) := by + obtain ⟨ρ,hρ,hρs,hρb,hρp,hρ1⟩ := exists_normalized_periodic_end_cutoff hT + have hr' : ∀ h,a h≠0 → lam by linarith [hr h hh] + refine ⟨fun z => ρ z*compactifiedFourierTail s lam T0 a phase z, + smooth_mul_of_support_in_open (isOpen_Ioo.prod (axial_halfspace_open _)) + (compactifiedFourierTail_smooth hs hg hB ha hδ hr) hρ hρs,?_,?_,?_⟩ + · intro p n x + dsimp only + exact congrArg₂ (· * ·) (hρp p (2*Real.pi) n x) + (compactifiedFourierTail_angularPeriodic s lam T0 a phase p n x) + · intro p hp x + dsimp only + rw [compactifiedFourierTail_of_nonpos hr' hp,mul_zero] + · intro p hp x hx + dsimp only + rw [hρ1 p ⟨by linarith [hp.1],hp.2⟩ x hx,one_mul,compactifiedFourierTail_of_pos hr' hp.1] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PoissonGreen.lean b/lean/OAI/Analysis/Conductivity/Fourier/PoissonGreen.lean new file mode 100644 index 0000000000000000000000000000000000000000..69cef0fe27eeb9909a3f314a00f267b9668060a6 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PoissonGreen.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +lemma poisson_real_mode_green {q : ℝ → ℝ} + (hq : ContDiff ℝ (↑(⊤ : ℕ∞)) q) (m a R : ℝ) : + (∫ t in (0:ℝ)..R, (-m*a*Real.exp (-m*t))*deriv q t + + m^2*a*Real.exp (-m*t)*q t) = + m*a*q 0-m*a*Real.exp (-m*R)*q R := by + have he (t : ℝ) : HasDerivAt (fun t : ℝ => Real.exp (-m*t)) + (Real.exp (-m*t)*(-m)) t := by + simpa only [id_eq,mul_one] using ((hasDerivAt_id t).const_mul (-m)).exp + have hder (t : ℝ) : HasDerivAt + (fun t : ℝ => (-m*a*Real.exp (-m*t))*q t) + ((-m*a*Real.exp (-m*t))*deriv q t + + m^2*a*Real.exp (-m*t)*q t) t := by + convert! ((he t).const_mul (-m*a)).mul + ((hq.differentiable (by simp) t).hasDerivAt) using 1 + ring + have hc : Continuous (fun t : ℝ => (-m*a*Real.exp (-m*t))*deriv q t + + m^2*a*Real.exp (-m*t)*q t) := by + have hd := hq.continuous_deriv (by simp) + fun_prop + have hh := intervalIntegral.integral_eq_sub_of_hasDerivAt + (fun t _ => hder t) (hc.intervalIntegrable 0 R) + convert! hh using 1 + simp only [mul_zero,Real.exp_zero,mul_one] + ring + +lemma poisson_complex_mode_green {q : ℝ → ℂ} + (hq : ContDiff ℝ (↑(⊤ : ℕ∞)) q) (m R : ℝ) (a : ℂ) : + (∫ t in (0:ℝ)..R, + (-m*Real.exp (-m*t))*(a.re*(deriv q t).re+a.im*(deriv q t).im) + + (m^2*Real.exp (-m*t))*(a.re*(q t).re+a.im*(q t).im)) = + m*(a.re*(q 0).re+a.im*(q 0).im) - + m*Real.exp (-m*R)*(a.re*(q R).re+a.im*(q R).im) := by + have hr := poisson_real_mode_green (Complex.reCLM.contDiff.comp hq) m a.re R + have hi := poisson_real_mode_green (Complex.imCLM.contDiff.comp hq) m a.im R + have hdr (t : ℝ) : deriv (fun x => (q x).re) t=(deriv q t).re := by + exact (Complex.reCLM.hasFDerivAt.comp_hasDerivAt t + ((hq.differentiable (by simp) t).hasDerivAt)).deriv + have hdi (t : ℝ) : deriv (fun x => (q x).im) t=(deriv q t).im := by + exact (Complex.imCLM.hasFDerivAt.comp_hasDerivAt t + ((hq.differentiable (by simp) t).hasDerivAt)).deriv + change (∫ t in (0:ℝ)..R, (-m*a.re*Real.exp (-m*t))*deriv (fun x => (q x).re) t + + m^2*a.re*Real.exp (-m*t)*(q t).re)=_ at hr + change (∫ t in (0:ℝ)..R, (-m*a.im*Real.exp (-m*t))*deriv (fun x => (q x).im) t + + m^2*a.im*Real.exp (-m*t)*(q t).im)=_ at hi + simp only [hdr] at hr + simp only [hdi] at hi + have hc (b : ℝ) (r : ℂ → ℝ) (h : Continuous r) : + Continuous (fun t : ℝ => (-m*b*Real.exp (-m*t))*r (deriv q t) + + m^2*b*Real.exp (-m*t)*r (q t)) := by + have hd := hq.continuous_deriv (by simp) + exact (by fun_prop) + have hs := intervalIntegral.integral_add (μ := volume) + ((hc a.re Complex.re Complex.continuous_re).intervalIntegrable 0 R) + ((hc a.im Complex.im Complex.continuous_im).intervalIntegrable 0 R) + rw [hr,hi] at hs + convert! hs using 1 + · apply intervalIntegral.integral_congr + intro t ht + ring + · simp only [Function.comp_apply,Complex.reCLM_apply,Complex.imCLM_apply] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PoissonTraceRate.lean b/lean/OAI/Analysis/Conductivity/Fourier/PoissonTraceRate.lean new file mode 100644 index 0000000000000000000000000000000000000000..36ff9df7bdbbf4881a6aca91ad3922dee2f9bf5b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PoissonTraceRate.lean @@ -0,0 +1,171 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusPoissonContinuous +import OAI.Analysis.Conductivity.Fourier.EndPoissonRepresentative + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +lemma poissonMultiplier_sub_one_bound {m t : ℝ} (hm : 0≤ m) (ht : 0≤t) : + ‖(Real.exp (-m*t):ℂ)-1‖≤ m*t := by + rw [←Complex.ofReal_one,←Complex.ofReal_sub,Complex.norm_real,Real.norm_eq_abs, + abs_of_nonpos (sub_nonpos.mpr (Real.exp_le_one_iff.mpr (by nlinarith : -m*t≤0)))] + linarith [Real.add_one_le_exp (-m*t)] + +lemma torusPoissonFlow_trace_rate (s : Fin 3 → ℝ) {t : ℝ} (ht : 0≤t) + (f : TorusL2) (g : SpectralL2 (Fin 2 → ℤ)) + (hg : ∀ h,g h=(torusRate s h:ℂ)*mFourierCoeff f h) : + ‖torusPoissonFlow s t f-f‖≤t*‖g‖ := by + let F := (mFourierBasis (d:=Fin 2)).repr + have hb : ‖F (torusPoissonFlow s t f-f)‖≤‖t • g‖ := by + apply lp.norm_mono (p:=2) (by norm_num) + intro h + change ‖mFourierBasis.repr (torusPoissonFlow s t f-f) h‖≤‖(t • g) h‖ + rw [map_sub,lp.coeFn_sub,Pi.sub_apply,mFourierBasis_repr,mFourierBasis_repr, + torusPoissonFlow_coeff,abs_of_nonneg ht,←sub_one_mul] + change ‖((Real.exp (-torusRate s h*t):ℂ)-1)*mFourierCoeff f h‖≤‖t • g h‖ + rw [norm_mul,norm_smul,Real.norm_eq_abs,abs_of_nonneg ht,hg,norm_mul, + Complex.norm_real,Real.norm_eq_abs,abs_of_nonneg (show 0≤torusRate s h from Real.sqrt_nonneg _)] + exact (mul_le_mul_of_nonneg_right + (poissonMultiplier_sub_one_bound (Real.sqrt_nonneg _) ht) (norm_nonneg _)).trans_eq (by dsimp [torusRate]; ring) + simpa only [F,LinearIsometryEquiv.norm_map,norm_smul,Real.norm_eq_abs,abs_of_nonneg ht] using hb + +lemma torusRate_sq_polynomial_bound (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : + (torusRate s h)^2 ≤ (|s 0|+|s 1|+|s 2|)*((h 0:ℝ)^2+(h 1:ℝ)^2) := by + let B := (h 0:ℝ)^2+(h 1:ℝ)^2 + have hB : 0≤B := by dsimp [B]; positivity + have hab : 2*|(h 0:ℝ)| * |(h 1:ℝ)|≤B := by + dsimp [B] + nlinarith [sq_nonneg (|(h 0:ℝ)|-|(h 1:ℝ)|),sq_abs (h 0:ℝ),sq_abs (h 1:ℝ)] + have hcross : 2*s 1*(h 0:ℝ)*(h 1:ℝ)≤|s 1| * B := by + calc + _ ≤ |2*s 1*(h 0:ℝ)*(h 1:ℝ)| := le_abs_self _ + _ = |s 1| * (2*|(h 0:ℝ)| * |(h 1:ℝ)|) := by + rw [abs_mul,abs_mul,abs_mul]; norm_num; ring + _ ≤ |s 1| * B := mul_le_mul_of_nonneg_left hab (abs_nonneg _) + have hx := mul_le_mul_of_nonneg_right (le_abs_self (s 0)) (sq_nonneg (h 0:ℝ)) + have hy := mul_le_mul_of_nonneg_right (le_abs_self (s 2)) (sq_nonneg (h 1:ℝ)) + have hx' : |s 0| * (h 0:ℝ)^2≤|s 0| * B := mul_le_mul_of_nonneg_left + (by dsimp [B]; nlinarith [sq_nonneg (h 1:ℝ)]) (abs_nonneg _) + have hy' : |s 2| * (h 1:ℝ)^2≤|s 2| * B := mul_le_mul_of_nonneg_left + (by dsimp [B]; nlinarith [sq_nonneg (h 0:ℝ)]) (abs_nonneg _) + by_cases hq : 0≤torusQuadratic s h + · rw [torusRate,Real.sq_sqrt hq] + dsimp [torusQuadratic,B] at * + nlinarith + · rw [torusRate,Real.sqrt_eq_zero_of_nonpos (le_of_not_ge hq),zero_pow (by decide)] + positivity + +lemma sourceAngularTrace_H1_summable (t : ℝ) {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + Summable (fun h : Fin 2 → ℤ => (1+(h 0:ℝ)^2+(h 1:ℝ)^2)* + ‖mFourierCoeff (fun x => (f (sourceAngularCollar t x):ℂ)) h‖^2) := by + let G : (Fin 4 → ℝ) → ℂ := fun z => (f (sourceAngularPolynomial t z):ℂ) + have hG : ContDiff ℝ (↑(⊤ : ℕ∞)) G := + Complex.ofRealCLM.contDiff.comp (hf.comp (contDiff_sourceAngularPolynomial t)) + obtain ⟨K,hK⟩ := hG.contDiffOn.exists_lipschitzOnWith (by simp) + (convex_Icc _ _) isCompact_Icc + let F : C(UnitAddTorus (Fin 2),ℂ) := + ⟨fun x => G (sourceRayCoordinates x),hG.continuous.comp continuous_sourceRayCoordinates⟩ + have hdiff (j : Fin 2) (u : ℝ) (x : UnitAddTorus (Fin 2)) : + ‖F (x+torusCoordinateShift j u)-F x‖≤((K:ℝ)*sourceRayConstant)*|u| := by + have hh := hK.dist_le_mul _ (sourceRayCoordinates_mem (x+torusCoordinateShift j u)) + _ (sourceRayCoordinates_mem x) + rw [dist_eq_norm,dist_eq_norm] at hh + apply hh.trans + simpa only [mul_assoc] using mul_le_mul_of_nonneg_left + (sourceRayCoordinates_difference j u x) K.coe_nonneg + exact torus_coordinate_H1_summable F (fun _ => (K:ℝ)*sourceRayConstant) + (fun _ => mul_nonneg K.coe_nonneg sourceRayConstant_nonneg) hdiff + +lemma sourceAngularTrace_rate_sq_summable (s : Fin 3 → ℝ) (t : ℝ) + {f : (Fin 3 → ℝ) → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + Summable (fun h : Fin 2 → ℤ => (torusRate s h)^2* + ‖mFourierCoeff (fun x => (f (sourceAngularCollar t x):ℂ)) h‖^2) := by + refine ((sourceAngularTrace_H1_summable t hf).mul_left + (|s 0|+|s 1|+|s 2|)).of_nonneg_of_le (fun h => by positivity) (fun h => ?_) + rw [←mul_assoc] + apply mul_le_mul_of_nonneg_right _ (sq_nonneg _) + exact (torusRate_sq_polynomial_bound s h).trans + (mul_le_mul_of_nonneg_left (by linarith) (by positivity)) + +lemma centralTrace_rate_sq_summable (s : Fin 3 → ℝ) + (f : centralSmoothFunctions) (i : Fin 3) : + Summable (fun h => (torusRate s h)^2*‖centralTraceFourier f i h‖^2) := by + simp only [centralTraceFourier_apply] + have hf : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun y : Fin 3 → ℝ => f (sourcePairCoordinates y)) := + (central_smooth f).comp sourcePairCLE.contDiff + fin_cases i + · simpa [centralBoundary] using sourceAngularTrace_rate_sq_summable s centralThickness hf + · simpa [centralBoundary,Function.comp_def] using + sourceAngularTrace_rate_sq_summable s (-centralThickness) (hf.comp (sourceChildCoordinates_contDiff 1)) + · simpa [centralBoundary,Function.comp_def] using + sourceAngularTrace_rate_sq_summable s (-centralThickness) (hf.comp (sourceChildCoordinates_contDiff (-1))) + +lemma centralTrace_rate_memℓp (s : Fin 3 → ℝ) (f : centralSmoothFunctions) (i : Fin 3) : + Memℓp (fun h => (torusRate s h:ℂ)*centralTraceFourier f i h) 2 := by + apply (memℓp_gen_iff (by norm_num : 0<(2:ℝ≥0∞).toReal)).mpr + simpa only [ENNReal.toReal_ofNat,Real.rpow_two,norm_mul,mul_pow, + Complex.norm_real,Real.norm_eq_abs,sq_abs] using centralTrace_rate_sq_summable s f i + +end + +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma complexL2_norm_sq {X : Type*} [MeasurableSpace X] {μ : Measure X} + (f : Lp ℂ 2 μ) : ‖f‖^2=∫ x,‖f x‖^2 ∂μ := by + rw [←real_inner_self_eq_norm_sq,L2.inner_def] + simp only [real_inner_self_eq_norm_sq] + +lemma continuousMap_L2_sq (f : C(UnitAddTorus (Fin 2),ℂ)) : + (∫ θ,‖f θ‖^2)=‖f.toLp 2 volume ℂ‖^2 := by + rw [complexL2_norm_sq] + apply integral_congr_ae + filter_upwards [ContinuousMap.coeFn_toLp (μ:=volume) (p:=2) (𝕜:=ℂ) f] with θ hθ + rw [hθ] + +lemma torusPoissonContinuous_trace_sq {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {t : ℝ} (ht : 0 by rw [hg,hq]) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PureMode.lean b/lean/OAI/Analysis/Conductivity/Fourier/PureMode.lean new file mode 100644 index 0000000000000000000000000000000000000000..13c9f4fcffbd82c035e942ed0fd062e1149008f3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PureMode.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CrossingGradient + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +def pureModeValue (f : ℝ → ℝ) (a : Fin 3) (x : Coord3) : ℝ := + f (x 0)*cos (x a) + +def pureModePotential (f : ℝ → ℝ) (a : Fin 3) : Fin 3 → Fin 3 → Coord3 → ℝ := + wedgePotential 0 a (fun x => deriv f (x 0)*sin (x a)) + +def pureModeTensor (q : ℝ) (a : Fin 3) : Matrix (Fin 3) (Fin 3) ℝ := + diagonal (fun i => if i=a then q else 1) + +lemma pureModeValue_diff {f : ℝ → ℝ} (hf : Differentiable ℝ f) (a : Fin 3) : + Differentiable ℝ (pureModeValue f a) := by + unfold pureModeValue + fun_prop + +lemma pureModePotential_diff {f : ℝ → ℝ} (hf : Differentiable ℝ (deriv f)) + (a i j : Fin 3) : Differentiable ℝ (pureModePotential f a i j) := by + exact wedgePotential_diff (by fun_prop) _ _ _ _ + +lemma pureModeValue_direction {f : ℝ → ℝ} (hf : Differentiable ℝ f) + (a i : Fin 3) (x : Coord3) : + direction (Pi.single i 1) (pureModeValue f a) x = + (if i=0 then deriv f (x 0)*cos (x a) else 0) + + (if i=a then -f (x 0)*sin (x a) else 0) := by + have h := direction_scalar_cos hf 1 i a x + simp only [one_mul] at h + unfold pureModeValue + rw [h] + simp_rw [@eq_comm _ a i,@eq_comm _ (0:Fin 3) i] + split_ifs <;> ring + +lemma pureModePotential_curl {f : ℝ → ℝ} (hf : Differentiable ℝ (deriv f)) + {a : Fin 3} (ha : a≠0) (x : Coord3) (i : Fin 3) : + potentialCurl (pureModePotential f a) x i = + (if i=0 then deriv f (x 0)*cos (x a) else 0) - + (if i=a then deriv (deriv f) (x 0)*sin (x a) else 0) := by + rw [pureModePotential,potentialCurl_wedge (by fun_prop)] + have ha' := direction_scalar_sin hf 1 a a x + have h0 := direction_scalar_sin hf 1 0 a x + simp only [one_mul,ha,Ne.symm ha,ite_true,ite_false,mul_one,mul_zero,add_zero,zero_add] at ha' h0 + rw [ha',h0] + ring_nf + +lemma pureMode_constitution {f : ℝ → ℝ} (hf : Differentiable ℝ f) + (hf' : Differentiable ℝ (deriv f)) {a : Fin 3} (ha : a≠0) (x : Coord3) + (q : ℝ) (heq : deriv (deriv f) (x 0) = q*f (x 0)) : + pureModeTensor q a *ᵥ (fun i => direction (Pi.single i 1) (pureModeValue f a) x) = + potentialCurl (pureModePotential f a) x := by + ext i + rw [pureModeTensor,mulVec_diagonal] + simp only [pureModeValue_direction hf,pureModePotential_curl hf' ha,heq] + by_cases h0 : i=0 + · subst i + simp [Ne.symm ha] + · by_cases hai : i=a + · subst i + simp [ha] + ring + · simp [h0,hai] + +lemma pureModeTensor_quadratic (q : ℝ) (a : Fin 3) (v : Coord3) : + v ⬝ᵥ (pureModeTensor q a *ᵥ v) = ∑ i, (if i=a then q else 1)*(v i)^2 := by + simp only [pureModeTensor,mulVec_diagonal,dotProduct] + apply Finset.sum_congr rfl + intro i _ + ring + +lemma pureModeTensor_bounds {q : ℝ} (hq₁ : 1/8 ≤ q) (hq₂ : q ≤ 10) + (a : Fin 3) (v : Coord3) : + (1/8)*(v ⬝ᵥ v) ≤ v ⬝ᵥ (pureModeTensor q a *ᵥ v) ∧ + v ⬝ᵥ (pureModeTensor q a *ᵥ v) ≤ 10*(v ⬝ᵥ v) := by + rw [pureModeTensor_quadratic] + simp only [dotProduct,Finset.mul_sum,←sq] + constructor <;> apply Finset.sum_le_sum <;> intro i _ + · apply mul_le_mul_of_nonneg_right _ (sq_nonneg _) + split <;> linarith + · apply mul_le_mul_of_nonneg_right _ (sq_nonneg _) + split <;> linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PureModeFamilyLocalCorrection.lean b/lean/OAI/Analysis/Conductivity/Fourier/PureModeFamilyLocalCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae60a615573dcb6a744cd4155113e9e3c87ea118 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PureModeFamilyLocalCorrection.lean @@ -0,0 +1,171 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.SmoothFamilyGlobalCorrection +import OAI.Analysis.Conductivity.Walls.SimpleCriticalWallRegion + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +lemma pureWallMode_shift_wall {σ lam k a : ℝ} (ha : sin (k*a)=0) (y : Coord3) : + pureWallMode σ lam k (boxCoordinates (y+![0,0,a]))= + pureWallMode (σ*cos (k*a)) lam k (boxCoordinates y) := by + change σ*exp (-lam*(y 0+0))*cos (k*(y 2+a))= + (σ*cos (k*a))*exp (-lam*y 0)*cos (k*y 2) + rw [add_zero,mul_add,cos_add,ha,mul_zero,sub_zero] + ring + +theorem exists_pure_mode_critical_family_region + {u v : P×Coord3 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (p : P) + {σ lam k : ℝ} (hσ : σ≠0) (hlam : lam≠0) (hk : k≠0) + (hub : ∀ y,u (p,y)=y 0) + (hvb : ∀ y,v (p,y)=pureWallMode σ lam k (boxCoordinates y)) + {x : Coord3} (hxz : sin (k*x 2)=0) + {U : Set Coord3} (hU : IsOpen U) (hx : x∈U) : + ∃ B : VanishingCorrectionRegion (fun z => ![u z,v z]) p U,x∈B.region := by + let a : Coord3 := ![0,0,x 2] + let τ : P×Coord3 → P×Coord3 := fun z => (z.1,z.2+a) + have hτ : ContDiff ℝ (↑(⊤:ℕ∞)) τ := contDiff_fst.prodMk (contDiff_snd.add contDiff_const) + let ut := u∘τ + let vt := v∘τ + have hut : ∀ y,ut (p,y)=y 0 := by + intro y + change u (p,y+a)=y 0 + rw [hub] + change y 0+0=y 0 + exact add_zero _ + have hvt : ∀ y,vt (p,y)=pureWallMode (σ*cos (k*x 2)) lam k (boxCoordinates y) := by + intro y + exact (hvb (y+a)).trans (pureWallMode_shift_wall hxz y) + have hcos : cos (k*x 2)≠0 := by + intro h + have hh := sin_sq_add_cos_sq (k*x 2) + rw [hxz,h] at hh + norm_num at hh + let Y₀ := ((Homeomorph.refl P).prodCongr (Homeomorph.subRight a)).toOpenPartialHomeomorph + let Y := Y₀.restr (univ×ˢU) + have hYs : Y.source=univ×ˢU := by + simp only [Y,OpenPartialHomeomorph.restr_source,(isOpen_univ.prod hU).interior_eq] + exact univ_inter _ + have hY : ∀ q y,(Y (q,y)).1=q := fun _ _ => rfl + have hsm : ContDiff ℝ (↑(⊤:ℕ∞)) Y := contDiff_fst.prodMk (contDiff_snd.sub contDiff_const) + have hinv : ContDiffOn ℝ (↑(⊤:ℕ∞)) Y.symm Y.target := + (contDiff_fst.prodMk (contDiff_snd.add contDiff_const)).contDiffOn + have hpot : ∀ z∈Y.source,![ut (z.1,(Y z).2),vt (z.1,(Y z).2)]=![u z,v z] := by + intro z _ + change ![u (z.1,z.2-a+a),v (z.1,z.2-a+a)]=![u z,v z] + rw [sub_add_cancel] + have huv : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z => ![u z,v z]) := + contDiff_pi.mpr (by intro i; fin_cases i; exact hu; exact hv) + have htv : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z => ![ut z,vt z]) := huv.comp hτ + apply exists_transported_vanishing_region huv htv p Y hY hsm hinv + (hYs ▸ Subset.rfl) (hYs ▸ (show (p,x)∈univ×ˢU from ⟨mem_univ _,hx⟩)) hpot + intro A hA hxA + apply exists_simple_critical_wall_region (hu.comp hτ) (hv.comp hτ) p + (mul_ne_zero hσ hcos) hlam hk hut hvt (x := x-a) (by simp [a]) hA hxA + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +lemma pureWallMode_pair_regular {σ lam k : ℝ} (hσ : σ≠0) (hk : k≠0) + {x : Coord3} (hx : sin (k*x 2)≠0) : + Function.Surjective (fderiv ℝ (wallCoordinatePair (pureWallMode σ lam k)) x) := by + apply wallCoordinatePair_surjective ((pureWallMode_smooth σ lam k).differentiable (by simp)) + rw [pureWallMode_normalDerivative] + exact mul_ne_zero (mul_ne_zero hσ (exp_ne_zero _)) (mul_ne_zero (neg_ne_zero.mpr hx) hk) + +lemma exists_sin_ne_zero_in_open {k : ℝ} (hk : k≠0) + {O : Set Coord3} (hO : IsOpen O) (hne : O.Nonempty) : + ∃ x∈O,sin (k*x 2)≠0 := by + obtain ⟨x,hx⟩ := hne + by_cases hs : sin (k*x 2)=0 + · obtain ⟨ε,hε,hball⟩ := Metric.isOpen_iff.mp hO x hx + let δ := min ε (Real.pi/|k|)/2 + have hak : 0 < |k| := abs_pos.mpr hk + have hδ : 0<δ := by dsimp [δ]; positivity + have hδε : δ<ε := by dsimp [δ]; linarith [min_le_left ε (Real.pi/|k|)] + have hδpi : δ ![u (q,y),v (q,y)]) (fun j y => r j (q,y))=0 → + BoundedPhysicallyCorrectable (fun y => ![u (q,y),v (q,y)]) U (fun j y => r j (q,y)) ε := by + let F : P×Coord3 → Fin 2 → ℝ := fun z => ![u z,v z] + have hF : ContDiff ℝ (↑(⊤:ℕ∞)) F := + contDiff_pi.mpr (by intro i; fin_cases i; exact hu; exact hv) + have hFb : (fun y => F (p,y))=wallCoordinatePair (pureWallMode σ lam k) := by + funext y j + fin_cases j + · exact hub y + · exact hvb y + have hreg {y : Coord3} (hy : sin (k*y 2)≠0) : + Function.Surjective (fderiv ℝ (fun y => F (p,y)) y) := by + rw [hFb] + exact pureWallMode_pair_regular hσ hk hy + have hcover : (⋃ B : VanishingCorrectionRegion F p U,B.region)=U := by + apply Subset.antisymm (iUnion_subset (fun B => B.region_subset)) + intro x hx + by_cases hs : sin (k*x 2)=0 + · obtain ⟨B,hB⟩ := exists_pure_mode_critical_family_region hu hv p hσ hlam hk hub hvb hs hU hx + exact mem_iUnion.mpr ⟨B,hB⟩ + · obtain ⟨B,hB⟩ := exists_parametric_correction_box hF p hU hx (hreg hs) + exact mem_iUnion.mpr ⟨B.toVanishing p,hB⟩ + apply global_vanishing_family_correction hF p hUc hcover ?_ hr hε + intro O hO hne _ + obtain ⟨x,hx,hs⟩ := exists_sin_ne_zero_in_open hk hO hne + exact ⟨x,hx,hreg hs⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/PureModeWall.lean b/lean/OAI/Analysis/Conductivity/Fourier/PureModeWall.lean new file mode 100644 index 0000000000000000000000000000000000000000..c86653916a8dfd5373ed27c27c7cbc0c67d97814 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/PureModeWall.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.RecenteredWallField + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +def pureWallMode (σ lam k : ℝ) (x : Box3) : ℝ := + σ*exp (-lam*x.1.1)*cos (k*x.2) + +lemma pureWallMode_smooth (σ lam k : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (pureWallMode σ lam k) := by + unfold pureWallMode + fun_prop + +lemma pureWallMode_normalDerivative (σ lam k : ℝ) (q : ℝ×ℝ) (z : ℝ) : + wallDerivative (pureWallMode σ lam k) (q,z)= + σ*exp (-lam*q.1)*(-sin (k*z)*k) := by + apply wallDerivative_eq_of_hasDeriv ((pureWallMode_smooth σ lam k).differentiable (by simp)) + simpa only [pureWallMode,mul_one,id_eq] using + (((hasDerivAt_id z).const_mul k).cos.const_mul (σ*exp (-lam*q.1))) + +lemma pureWallMode_normalSecond (σ lam k : ℝ) (q : ℝ×ℝ) (z : ℝ) : + wallDerivative (wallDerivative (pureWallMode σ lam k)) (q,z)= + -(σ*exp (-lam*q.1)*cos (k*z)*k^2) := by + apply wallDerivative_eq_of_hasDeriv + ((wallDerivative_smooth (pureWallMode_smooth σ lam k)).differentiable (by simp)) + have h := (((((hasDerivAt_id z).const_mul k).sin.neg).mul_const k).const_mul + (σ*exp (-lam*q.1))) + convert! h using 1 <;> first | rfl | (simp only [pureWallMode_normalDerivative,id_eq,Pi.neg_apply] <;> ring) + +lemma pureWallMode_wall_value (σ lam k : ℝ) (q : ℝ×ℝ) : + pureWallMode σ lam k (q,0)=σ*exp (-lam*q.1) := by simp [pureWallMode] + +lemma pureWallMode_wall_critical (σ lam k : ℝ) (q : ℝ×ℝ) : + wallDerivative (pureWallMode σ lam k) (q,0)=0 := by + simp [pureWallMode_normalDerivative] + +lemma pureWallMode_wall_simple {σ lam k : ℝ} (hσ : σ≠0) (hk : k≠0) (q : ℝ×ℝ) : + wallDerivative (wallDerivative (pureWallMode σ lam k)) (q,0)≠0 := by + rw [pureWallMode_normalSecond] + simp only [mul_zero,cos_zero,mul_one,neg_ne_zero] + exact mul_ne_zero (mul_ne_zero hσ (exp_ne_zero _)) (pow_ne_zero 2 hk) + +lemma sin_ne_zero_of_abs_lt_pi {z : ℝ} (hz : z≠0) (hp : |z| v (q,y)) (z,0)=0) + {σ lam k : ℝ} (hσ : σ≠0) (hlam : lam≠0) (hk : k≠0) + (hbase : ∀ y,v (p,y)=pureWallMode σ lam k y) + {W : Set Coord3} (hW : IsOpen W) {x : Coord3} (hx : x∈W) (hxz : x 2=0) : + ∃ B : VanishingCorrectionRegion (fun z => wallCoordinatePair (fun y => v (z.1,y)) z.2) p W, + x∈B.region := by + have hstrip : IsOpen {y : Coord3 | |k*y 2| linarith [hz.1.1,hz.1.2] + · change dist z.2 (x 1)<δ + rw [Real.dist_eq,abs_lt] + constructor <;> linarith [hz.2.1,hz.2.2] + · change dist (0:ℝ) (x 2)<δ + simpa only [hxz,dist_self] using hδ + have hcp : Convex ℝ {y : Coord3 | 0 rfl,fun _ _ => rfl⟩ 0 + have hcn : Convex ℝ {y : Coord3 | y 2<0} := + convex_halfSpace_lt ⟨fun _ _ => rfl,fun _ _ => rfl⟩ 0 + have hnb : ∀ y∈U,wallQuotient (wallDerivative (fun z => v (p,z))) (boxCoordinates y)≠0 := by + intro y hy + rw [show (fun z => v (p,z))=pureWallMode σ lam k from funext hbase] + exact pureWallMode_quotient_nonzero hσ hk _ (hball hy).2 + let B := criticalWallRegion hv p hz Metric.isOpen_ball Metric.isBounded_ball + (fun y hy => (hball hy).1) (Metric.nonempty_ball.mpr hδ) + (((convex_ball x δ).inter hcp).isPreconnected) + (((convex_ball x δ).inter hcn).isPreconnected) hproj hnb + (show x 0-δ/2 (hbase (z,0)).trans (pureWallMode_wall_value σ lam k z)) + exact ⟨B,Metric.mem_ball_self hδ⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/RectangularRayTrace.lean b/lean/OAI/Analysis/Conductivity/Fourier/RectangularRayTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..003303b4c6ae7f154958da29d1a8a61609126d14 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/RectangularRayTrace.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +def rayDirection (θ : UnitAddCircle) : Fin 2 → ℝ := + ![(fourier 1 θ).re,(fourier 1 θ).im] + +def rayDenominator (w : ℝ) (θ : UnitAddCircle) : ℝ := + max (|rayDirection θ 0|/w) |rayDirection θ 1| + +def rectangularRay (w : ℝ) (θ : UnitAddCircle) : Fin 2 → ℝ := + fun i => rayDirection θ i/rayDenominator w θ + +lemma rayDirection_unit (θ : UnitAddCircle) : + (rayDirection θ 0)^2+(rayDirection θ 1)^2=1 := by + have hh : ‖fourier 1 θ‖=1 := by simp [fourier_apply,Circle.norm_coe] + have hs := Complex.sq_norm (fourier 1 θ) + rw [hh,Complex.normSq_apply] at hs + simpa [rayDirection,pow_two] using hs.symm + +lemma rayDirection_abs (θ : UnitAddCircle) (i : Fin 2) : + |rayDirection θ i|≤1 := by + have hh : ‖fourier 1 θ‖=1 := by simp [fourier_apply,Circle.norm_coe] + fin_cases i + · exact (Complex.abs_re_le_norm (fourier 1 θ)).trans_eq hh + · exact (Complex.abs_im_le_norm (fourier 1 θ)).trans_eq hh + +lemma rayDenominator_lower {w : ℝ} (hw : 0 ne_of_gt (lt_of_lt_of_le (by norm_num) (rayDenominator_lower hw hw' θ)))) + +lemma fourier_one_translation_bound (θ : UnitAddCircle) (t : ℝ) : + ‖fourier 1 (θ+(t:UnitAddCircle))-fourier 1 θ‖≤2*Real.pi*|t| := by + have he : fourier 1 (θ+(t:UnitAddCircle))=fourier 1 θ*fourier 1 (t:UnitAddCircle) := by + simp [fourier_apply,AddCircle.toCircle_add,Circle.coe_mul] + rw [he,←mul_sub_one,norm_mul] + have hh : ‖fourier 1 θ‖=1 := by simp [fourier_apply,Circle.norm_coe] + rw [hh,one_mul,fourier_coe_apply] + have hx := Real.norm_exp_I_mul_ofReal_sub_one_le (x:=2*Real.pi*t) + have he' : (2*Real.pi*Complex.I*(1:ℤ)*(t:ℂ))= + Complex.I*((2*Real.pi*t:ℝ):ℂ) := by push_cast; ring + rw [←he'] at hx + simpa only [Int.cast_one,Complex.ofReal_one,mul_one,div_one,Real.norm_eq_abs,abs_mul, + abs_of_pos Real.pi_pos,abs_of_nonneg (by norm_num : (0:ℝ)≤2)] using hx + +lemma rayDirection_difference (θ : UnitAddCircle) (t : ℝ) (i : Fin 2) : + |rayDirection (θ+(t:UnitAddCircle)) i-rayDirection θ i|≤2*Real.pi*|t| := by + apply le_trans _ (fourier_one_translation_bound θ t) + fin_cases i + · simpa [rayDirection] using Complex.abs_re_le_norm + (fourier 1 (θ+(t:UnitAddCircle))-fourier 1 θ) + · simpa [rayDirection] using Complex.abs_im_le_norm + (fourier 1 (θ+(t:UnitAddCircle))-fourier 1 θ) + +lemma rayDenominator_difference {w : ℝ} (hw : 0 simp [squareFaceParameter,squareFace,squareFaceBase,squareFaceDirection] + +lemma squareFace_max (i : Fin 4) {a : ℝ} (ha : |a|≤1) : + max |squareFace i a 0| |squareFace i a 1|=1 := by + fin_cases i <;> simp [squareFace,squareFaceBase,squareFaceDirection,abs_neg, + max_eq_left ha,max_eq_right ha] + +lemma squareFace_determinant (i : Fin 4) (a : ℝ) : + squareFace i a 0*squareFaceDirection i 1- + squareFaceDirection i 0*squareFace i a 1=1 := by + fin_cases i <;> simp [squareFace,squareFaceBase,squareFaceDirection] + +lemma squareFace_min_max (v : Fin 2 → ℝ) (hm : max |v 0| |v 1|=1) : + ∃ i : Fin 4, ∃ a : ℝ, |a|≤1 ∧ squareFace i a=v := by + have h0 : |v 0|≤1 := le_max_left _ _ |>.trans hm.le + have h1 : |v 1|≤1 := le_max_right _ _ |>.trans hm.le + rcases max_cases |v 0| |v 1| with h | h + · have he : |v 0|=1 := h.1.symm.trans hm + rcases abs_cases (v 0) with hp | hn + · refine ⟨0,v 1,h1,?_⟩ + have hv : v 0=1 := hp.1.symm.trans he + ext k; fin_cases k <;> simp [squareFace,squareFaceBase,squareFaceDirection,hv] + · refine ⟨2,-v 1,by simpa using h1,?_⟩ + have hv : v 0= -1 := by linarith [hn.1,he] + ext k; fin_cases k <;> simp [squareFace,squareFaceBase,squareFaceDirection,hv] + · have he : |v 1|=1 := h.1.symm.trans hm + rcases abs_cases (v 1) with hp | hn + · refine ⟨1,-v 0,by simpa using h0,?_⟩ + have hv : v 1=1 := hp.1.symm.trans he + ext k; fin_cases k <;> simp [squareFace,squareFaceBase,squareFaceDirection,hv] + · refine ⟨3,v 0,h0,?_⟩ + have hv : v 1= -1 := by linarith [hn.1,he] + ext k; fin_cases k <;> simp [squareFace,squareFaceBase,squareFaceDirection,hv] + +def sourceRadialCenter : ℝ := (1+sourceHole)/2 +def sourceRadialWidth : ℝ := (1-sourceHole)/2 + +def sourceCollarRadius (j : Fin 4) (t b : ℝ) : ℝ := + sourceRadialCenter+sourceRadialWidth*(1-t)*squareFace j b 0 + +def sourceCollarPiece (i j : Fin 4) (x : Fin 3 → ℝ) : Fin 3 → ℝ := + ![sourceLength*sourceCollarRadius j (x 0) (x 2)*squareFace i (x 1) 0, + sourceCollarRadius j (x 0) (x 2)*squareFace i (x 1) 1, + (1-x 0)*squareFace j (x 2) 1] + +def sourceRadial (x : Fin 3 → ℝ) : ℝ := max (|x 0|/sourceLength) |x 1| + +def sourceCrossCoordinates (x : Fin 3 → ℝ) : Fin 2 → ℝ := + ![(sourceRadial x-sourceRadialCenter)/sourceRadialWidth,x 2] + +def sourceCollarTime (x : Fin 3 → ℝ) : ℝ := + 1-max |sourceCrossCoordinates x 0| |sourceCrossCoordinates x 1| + +lemma sourceCollarRadius_bounds (j : Fin 4) {t b : ℝ} + (ht : t∈Icc 0 1) (hb : |b|≤1) : + sourceHole≤ sourceCollarRadius j t b ∧ sourceCollarRadius j t b≤1 := by + have hq : |squareFace j b 0|≤1 := (le_max_left _ _).trans (squareFace_max j hb).le + have hq' := abs_le.mp hq + have hprod : |(1-t)*squareFace j b 0|≤1 := by + rw [abs_mul,abs_of_nonneg (by linarith [ht.2] : 0≤1-t)] + nlinarith [ht.1,ht.2] + have hh := abs_le.mp hprod + dsimp [sourceCollarRadius,sourceRadialCenter,sourceRadialWidth,sourceHole] + constructor <;> linarith + +lemma sourceCollarPiece_radial (i j : Fin 4) {x : Fin 3 → ℝ} + (ht : x 0∈Icc 0 1) (ha : |x 1|≤1) (hb : |x 2|≤1) : + sourceRadial (sourceCollarPiece i j x)=sourceCollarRadius j (x 0) (x 2) := by + have hr : 0≤ sourceCollarRadius j (x 0) (x 2) := by + have hh := (sourceCollarRadius_bounds j ht hb).1 + dsimp [sourceHole] at hh + linarith + have hL : 0 squareFace i (y l) k) + (squareFaceDirection i k • (ContinuousLinearMap.proj l : (Fin 3 → ℝ) →L[ℝ] ℝ)) x := by + convert (hasFDerivAt_const (𝕜 := ℝ) (squareFaceBase i k) x).add + ((hasFDerivAt_apply (𝕜 := ℝ) l x).mul_const (squareFaceDirection i k)) using 1 <;> first | rfl | simp + +lemma sourceCollarPiece_hasFDeriv (i j : Fin 4) (x : Fin 3 → ℝ) : + HasFDerivAt (sourceCollarPiece i j) (sourceCollarDerivative i j x) x := by + have ht := (hasFDerivAt_const (1:ℝ) x).sub (hasFDerivAt_apply (𝕜 := ℝ) 0 x) + have hr := (hasFDerivAt_const sourceRadialCenter x).add + ((ht.const_mul sourceRadialWidth).mul (squareFace_coord_hasFDeriv j 0 2 x)) + have hf0 := (hr.const_mul sourceLength).mul (squareFace_coord_hasFDeriv i 0 1 x) + have hf1 := hr.mul (squareFace_coord_hasFDeriv i 1 1 x) + have hf2 := ht.mul (squareFace_coord_hasFDeriv j 1 2 x) + have hcoord (k : Fin 3) : HasFDerivAt (fun y => sourceCollarPiece i j y k) + ((ContinuousLinearMap.proj k : (Fin 3 → ℝ) →L[ℝ] ℝ).comp + (sourceCollarDerivative i j x)) x := by + fin_cases k + · convert hf0 using 1 <;> try rfl + ext y + simp [sourceCollarDerivative,sourceCollarJacobian,Matrix.toLin',LinearMap.toMatrix',Matrix.mulVecLin,Matrix.mulVecBilin, + Matrix.mulVec,Fin.sum_univ_succ,dotProduct,sourceCollarRadius] + ring + · convert hf1 using 1 <;> try rfl + ext y + simp [sourceCollarDerivative,sourceCollarJacobian,Matrix.toLin',LinearMap.toMatrix',Matrix.mulVecLin,Matrix.mulVecBilin, + Matrix.mulVec,Fin.sum_univ_succ,dotProduct,sourceCollarRadius] + ring + · convert hf2 using 1 <;> try rfl + ext y + simp [sourceCollarDerivative,sourceCollarJacobian,Matrix.toLin',LinearMap.toMatrix',Matrix.mulVecLin,Matrix.mulVecBilin, + Matrix.mulVec,Fin.sum_univ_succ,dotProduct,sourceCollarRadius] + ring + have hfull := hasFDerivAt_pi.mpr hcoord + convert hfull using 1 + rfl + +lemma sourceCollarPiece_contDiff (i j : Fin 4) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (sourceCollarPiece i j) := by + apply contDiff_pi.mpr + intro k + fin_cases k <;> simp [sourceCollarPiece,sourceCollarRadius,squareFace] <;> fun_prop + +lemma sourceCollarJacobian_det (i j : Fin 4) (x : Fin 3 → ℝ) : + (sourceCollarJacobian i j x).det = + -sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0) := by + rw [Matrix.det_fin_three] + simp [sourceCollarJacobian] + calc + _= -sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0)* + (squareFace i (x 1) 0*squareFaceDirection i 1- + squareFaceDirection i 0*squareFace i (x 1) 1)* + (squareFace j (x 2) 0*squareFaceDirection j 1- + squareFaceDirection j 0*squareFace j (x 2) 1) := by ring + _= _ := by rw [squareFace_determinant,squareFace_determinant]; ring + +lemma sourceCollarJacobian_det_ne_zero (i j : Fin 4) {x : Fin 3 → ℝ} + (ht : x 0∈Ico 0 1) (hb : |x 2|≤1) : + (sourceCollarJacobian i j x).det≠0 := by + rw [sourceCollarJacobian_det] + have hr : 0 (sourceCollarPiece_hasFDeriv i j x).hasFDerivWithinAt) + (sourceCollarBox_injOn i j hη)] + apply setIntegral_congr_fun (sourceCollarBox_measurable η) + intro x hx + obtain ⟨ht,ha,hb⟩ := mem_sourceCollarBox.mp hx + dsimp only + rw [sourceCollarDerivative_det] + have hr := (sourceCollarRadius_bounds j ⟨ht.1,ht.2.trans hη.le⟩ hb).1 + have hd : 0 ≤ sourceHole := by norm_num [sourceHole] + have hL : 0 ≤ sourceLength := by norm_num [sourceLength] + have hw : 0 ≤ sourceRadialWidth := by norm_num [sourceRadialWidth,sourceHole] + have hrr : 0 ≤ sourceCollarRadius j (x 0) (x 2) := hd.trans hr + have hq : 0 ≤ 1-x 0 := by linarith [ht.2] + have he : -sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0)= + -(sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0)) := by ring + rw [he,abs_neg,abs_of_nonneg (by positivity)] + +lemma sourceCollarPiece_lipschitz (i j : Fin 4) (η : ℝ) : + ∃ C : NNReal,LipschitzOnWith C (sourceCollarPiece i j) (sourceCollarBox η) := by + exact (sourceCollarPiece_contDiff i j).contDiffOn.exists_lipschitzOnWith + (by simp) (convex_Icc _ _) (sourceCollarBox_compact η) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SmoothAngularCutoff.lean b/lean/OAI/Analysis/Conductivity/Fourier/SmoothAngularCutoff.lean new file mode 100644 index 0000000000000000000000000000000000000000..a1e667ce3b8d7353e1ceee9effa254fbb651fe50 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SmoothAngularCutoff.lean @@ -0,0 +1,136 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory + +def periodCutoff (T x : ℝ) : ℝ := smoothTransition (x/T+1)-smoothTransition (x/T) + +lemma periodCutoff_smooth (T : ℝ) : ContDiff ℝ (↑(⊤:ℕ∞)) (periodCutoff T) := + (smoothTransition.contDiff.comp ((contDiff_id.div_const T).add contDiff_const)).sub + (smoothTransition.contDiff.comp (contDiff_id.div_const T)) + +lemma periodCutoff_nonneg (T x : ℝ) : 0≤periodCutoff T x := + sub_nonneg.mpr (smoothTransition.monotone (by linarith)) + +lemma periodCutoff_zero_left {T : ℝ} (hT : 0 periodCutoff T (y+T*n)) + have hf : (fun n : ℤ => periodCutoff T (y+T*((n+m:ℤ):ℝ)))= + (fun n : ℤ => periodCutoff T (x+T*n)) := by + funext n + congr 1 + simp only [y,Int.cast_add] + ring + change (∑ᶠ n : ℤ,periodCutoff T (y+T*((n+m:ℤ):ℝ)))=_ at he + rw [hf,periodCutoff_finsum_core hT hy] at he + exact he + +theorem periodCutoff_integral {T : ℝ} (hT : 0 periodCutoff T x*g x + have hf : Continuous f := (periodCutoff_smooth T).continuous.mul hg + have hs : Function.support f⊆Ioc (-T) T := by + intro x hx + constructor + · by_contra h + exact hx (by simp [f,periodCutoff_zero_left hT (le_of_not_gt h)]) + · by_contra h + exact hx (by simp [f,periodCutoff_zero_right hT (le_of_not_ge h)]) + rw [←intervalIntegral.integral_eq_integral_of_support_subset hs, + ←intervalIntegral.integral_add_adjacent_intervals (hf.intervalIntegrable (-T) 0) (hf.intervalIntegrable 0 T)] + have he : (∫ x in -T..(0:ℝ),f x)=∫ x in (0:ℝ)..T,f (x-T) := by + rw [intervalIntegral.integral_comp_sub_right] + simp + rw [he] + have hi : IntervalIntegrable (fun x => f (x-T)) volume 0 T := + (hf.comp (continuous_id.sub continuous_const)).intervalIntegrable 0 T + rw [←intervalIntegral.integral_add hi (hf.intervalIntegrable 0 T)] + apply intervalIntegral.integral_congr + intro x hx + have hx' : x∈Icc 0 T := by simpa only [uIcc_of_le hT.le] using hx + have hgp : g (x-T)=g x := by simpa using hp.sub_eq x + dsimp [f] + rw [hgp,←add_mul] + rw [add_comm (periodCutoff T (x-T)),periodCutoff_partition hT hx',one_mul] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SmoothHarmonicAnalytic.lean b/lean/OAI/Analysis/Conductivity/Fourier/SmoothHarmonicAnalytic.lean new file mode 100644 index 0000000000000000000000000000000000000000..35497ae86375c55eae647ff2a5e8f0b14ed9c86e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SmoothHarmonicAnalytic.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AnalyticDerivativeBounds +import OAI.Analysis.Conductivity.Variational.WeakHarmonicMean + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Laplacian InnerProductSpace + +lemma WeaklyHarmonicOn.mono {f : WeylSpace → ℝ} {U V : Set WeylSpace} + (hw : WeaklyHarmonicOn f U) (hV : V⊆U) : WeaklyHarmonicOn f V := by + intro ψ hψ hc hs + exact hw ψ hψ hc (hs.trans hV) + +theorem smooth_weak_harmonic_analyticAt {f : WeylSpace → ℝ} {U : Set WeylSpace} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hw : WeaklyHarmonicOn f U) + (hU : IsOpen U) {a : WeylSpace} (ha : a∈U) : AnalyticAt ℝ f a := by + obtain ⟨r,hr,hsub⟩ := Metric.mem_nhds_iff.mp (hU.mem_nhds ha) + let b : ContDiffBump a := { + rIn := r/2, rOut := r, rIn_pos := by positivity, rIn_lt_rOut := by linarith } + let g : WeylSpace → ℝ := fun x => b x*f x + have hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g := b.contDiff.mul hf + have hc : HasCompactSupport g := b.hasCompactSupport.mul_right + have he : EqOn f g (Metric.ball a (r/2)) := by + intro x hx + have hb : b x=1 := b.one_of_mem_closedBall (Metric.ball_subset_closedBall hx) + simp [g,hb] + have hwg : WeaklyHarmonicOn g (Metric.ball a (r/2)) := + .congr_restrict Metric.isOpen_ball.measurableSet + ((ae_restrict_iff' Metric.isOpen_ball.measurableSet).mpr (ae_of_all _ he)) + (hw.mono ((Metric.ball_subset_ball (by linarith)).trans hsub)) + have hgA : AnalyticAt ℝ g a := + (weaklyHarmonic_smooth_mean hg hc hwg).analyticAt hg hc (by positivity) + apply hgA.congr + filter_upwards [Metric.ball_mem_nhds a (by positivity : 0 (endFlatPoisson s f y).re) := by + filter_upwards [(axial_halfspace_open 0).mem_nhds hx] with y hy + rw [torusRealContinuation_spectral hs f hy,endFlatPoisson_eq] + +lemma torusAffineField_spectral_covector {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) {x : Coord3} (hx : 0 fderiv ℝ (torusAffineField s κ (torusSpectralSynthesis s f)) x (Pi.single k 1))= + fullEndFlatCovector s f κ (x 0) (torusAngles x) := by + have he := torusRealContinuation_spectral_eventually hs f hx + have hd := ((torusRealContinuation_smooth hs (torusSpectralSynthesis s f)).contDiffAt + ((axial_halfspace_open 0).mem_nhds hx)).differentiableAt (by norm_num) + have ha := ((hasFDerivAt_apply (𝕜:=ℝ) (0:Fin 3) x).const_mul κ) + ext k + change fderiv ℝ ((fun y : Coord3 => κ*y 0)+torusRealContinuation s (torusSpectralSynthesis s f)) x + (Pi.single k 1)=(endPoissonField s f k.succ (x 0,torusAngles x)).re+κ*(Pi.single (0:Fin 3) (1:ℝ) : Coord3) k + rw [(ha.add hd.hasFDerivAt).fderiv] + change κ*(Pi.single k (1:ℝ) : Coord3) 0+fderiv ℝ (torusRealContinuation s (torusSpectralSynthesis s f)) x (Pi.single k 1)=_ + rw [he.fderiv_eq,endFlatPoisson_real_derivative_axis s hs f hx k] + fin_cases k <;> simp + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionMono.lean b/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionMono.lean new file mode 100644 index 0000000000000000000000000000000000000000..46b787093484f0c8e0edf7728d0beb18afa59479 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionMono.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.MatrixFiniteLaminate +import OAI.Analysis.Conductivity.Variational.SynchronizedChartWaves +import OAI.Analysis.Conductivity.Branching.JoinHull + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma spectralExtension_mono {T S : Set DiagonalTriple} (h : T ⊆ S) : + spectralExtension T ⊆ spectralExtension S := by + rintro A ⟨Q,hQ,d,hd,he⟩ + exact ⟨Q,hQ,d,h hd,he⟩ + +lemma spectral_depth_mono (T : Set DiagonalTriple) : + Monotone (fun n => spectralExtension (depthClass T n)) := by + intro m n h + exact spectralExtension_mono (depthClass_mono T h) + +lemma matrixFiniteLaminate_mem_some_depth {a b : ℝ} {T : Set DiagonalTriple} + (hT : ∀ s, a < s → s < b → (fun _ => s) ∈ T) + {A : Symmetric3} (hA : A ∈ matrixFiniteLaminate a b) : + ∃ n, A ∈ spectralExtension (depthClass T n) := by + obtain ⟨Q,hQ,d,hd,he⟩ := hA + obtain ⟨n,hn⟩ := hd.mem_some_depth hT + exact ⟨n,Q,hQ,d,hn,he⟩ + +lemma exists_finite_depth_loss + (μ : Measure Coord3) (A : Coord3 → Symmetric3) (hA : Measurable A) + {U : Set Coord3} (hU : MeasurableSet U) (hμU : μ U ≠ ∞) + {a b : ℝ} (ha : 0 < a) {T : Set DiagonalTriple} + (hT : IsOpen T) (hsub : ∀ d ∈ T, IsFiniteLaminate a b d) + (hperm : ∀ d ∈ T, ∀ e : Equiv.Perm (Fin 3), d ∘ e ∈ T) + (hscalar : ∀ s, a < s → s < b → (fun _ => s) ∈ T) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) + {ε : ℝ≥0∞} (hε : 0 < ε) : + ∃ n, μ (U \ A ⁻¹' spectralExtension (depthClass T n)) < ε := by + let B : ℕ → Set Coord3 := fun n => U \ A ⁻¹' spectralExtension (depthClass T n) + have hB : ∀ n, MeasurableSet (B n) := fun n => hU.diff + ((isOpen_spectralExtension (isOpen_depthClass ha hT hsub n) (depthClass_permute hperm n)).measurableSet.preimage hA) + have hmono : Antitone B := fun _ _ h => sdiff_subset_sdiff_right + (preimage_mono (spectral_depth_mono T h)) + have hnull : μ (⋂ n, B n) = 0 := by + apply measure_eq_zero_iff_ae_notMem.mpr + filter_upwards [hgraph] with x hx hin + have h0 := mem_iInter.mp hin 0 + obtain ⟨n,hn⟩ := matrixFiniteLaminate_mem_some_depth hscalar (hx h0.1) + exact (mem_iInter.mp hin n).2 hn + have ht : Tendsto (fun n => μ (B n)) atTop (𝓝 0) := by + rw [← hnull] + exact tendsto_measure_iInter_atTop (fun n => (hB n).nullMeasurableSet) hmono + ⟨0, ((measure_mono sdiff_subset).trans_lt (lt_top_iff_ne_top.mpr hμU)).ne⟩ + exact (ht.eventually (gt_mem_nhds hε)).exists + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionNonemptyNonempty.lean b/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionNonemptyNonempty.lean new file mode 100644 index 0000000000000000000000000000000000000000..33e2ad7d1f82566783d207ef6a14d9b41abd2e80 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SpectralExtensionNonemptyNonempty.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.Refl + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma spectralExtension_nonempty_of_nonempty {T : Set DiagonalTriple} (hT : T.Nonempty) : + (spectralExtension T).Nonempty := by + obtain ⟨d,hd⟩ := hT + have hQ : (1 : Mat3) ∈ orthogonalFrames := by simp [orthogonalFrames] + exact ⟨conjugateDiagonal 1 d,conjugateDiagonal_spectral hQ hd⟩ + +theorem global_scalar_tensor_approximation + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUm : MeasurableSet U) (hUb : Bornology.IsBounded U) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) + {η ε : ℝ} (hη : 0 < η) (hε : 0 < ε) : + ∃ R : CompactGlobalUpdate μ U u A, + μ (U \ regularRegion (fun x => u x+R.du x) R.tensor U) = 0 ∧ + (∀ᵐ x ∂μ, x ∈ U → R.tensor x ∈ matrixFiniteLaminate a b) ∧ + μ (U \ R.tensor ⁻¹' spectralExtension (scalarNeighbourhood a b η)) ≤ ENNReal.ofReal ε := by + let T := scalarNeighbourhood a b η + have hTo : IsOpen T := isOpen_scalarNeighbourhood ha + have hsub : ∀ d ∈ T, IsFiniteLaminate a b d := fun _ hd => hd.1 + have hperm : ∀ d ∈ T, ∀ e : Equiv.Perm (Fin 3), d ∘ e ∈ T := fun _ hd e => scalarNeighbourhood_permute hd e + have hscalar : ∀ s, a < s → s < b → (fun _ => s) ∈ T := fun _ hs ht => scalar_mem_scalarNeighbourhood hη hs ht + have hsc : (spectralExtension T).Nonempty := spectralExtension_nonempty_of_nonempty + ⟨fun _ => (a+b)/2,hscalar _ (by linarith) (by linarith)⟩ + have hAmSubtype : @Measurable Coord3 Symmetric3 _ Subtype.instMeasurableSpace A := by + change @Measurable Coord3 Symmetric3 _ (borel Symmetric3) A at hAm + rw [borel_comap, ← BorelSpace.measurable_eq (α := Mat3)] at hAm + exact hAm + obtain ⟨n,hn⟩ := exists_finite_depth_loss μ A hAmSubtype hUm hUb.measure_lt_top.ne ha hTo hsub + hperm hscalar hgraph (ENNReal.ofReal_pos.mpr (by linarith : 0 < ε/2)) + obtain ⟨R,hRreg,hRG,hRloss⟩ := global_finite_depth_iteration μ ha hTo hsub hperm hsc hUb n + u A hAm hint hdiv hreg hgraph (by linarith : 0 < ε/2) + refine ⟨R,hRreg,hRG,hRloss.trans ?_⟩ + calc + _ ≤ ENNReal.ofReal (ε/2) + ENNReal.ofReal (ε/2) := add_le_add hn.le le_rfl + _ = ENNReal.ofReal ε := by rw [← ENNReal.ofReal_add (by linarith) (by linarith)]; congr 1; ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalIntegral.lean b/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b08ad03cd8eacd99eb03526c8067b012beb27a9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalIntegral.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.SpectralTerminalL2 +import OAI.Analysis.Conductivity.Sources.FluxCylinder + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped ENNReal +local instance spectralTerminalIntegralMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance spectralTerminalIntegralIsProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma spectralTerminalDensity_coeff (s : Fin 3 → ℝ) {R : ℝ} (hR : 0 -endPoissonField s f 1 (R,θ) := by + let u := (mFourierBasis (d:=Fin 2)).repr.symm (spectralTerminalDensity s hR f) + have hc (h : TorusModes) : mFourierCoeff u h=spectralTerminalDensity s hR f h := by + rw [←mFourierBasis_repr] + change (mFourierBasis (d:=Fin 2)).repr ((mFourierBasis (d:=Fin 2)).repr.symm _) h=_ + rw [LinearIsometryEquiv.apply_symm_apply] + apply lp_hasSum_ae_unique (hasSum_mFourier_series_L2 u) + (a:=fun h θ => -endPoissonModeField s h (f.val 0 h) 1 (R,θ)) + · intro h + filter_upwards [Lp.coeFn_smul (mFourierCoeff u h) (mFourierLp 2 h),coeFn_mFourierLp 2 h] + with θ h1 h2 + rw [h1] + simp only [Pi.smul_apply,smul_eq_mul,h2,hc,spectralTerminalDensity_coeff] + simp [endPoissonModeField,endModeCoefficient,mul_assoc,mul_left_comm,mul_comm] + · exact Filter.Eventually.of_forall (fun θ => (endPoissonField_hasSum s hs f 1 hR).neg) + +lemma smoothCollarTrace_mean_integral (s : Fin 3 → ℝ) (b : ℝ) + {φ : Coord3 → ℝ} (hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ) : + spectralGraphMean (torusRate s) (smoothCollarTrace s b hφ)= + ∫ θ,φ (sourceAngularCollar b θ) := by + change ((smoothCollarTrace s b hφ).val 0 0).re=_ + rw [smoothCollarTrace_fst] + simp only [mFourierCoeff,neg_zero,mFourier_zero,ContinuousMap.one_apply,one_smul] + have hc : Continuous (fun θ => (φ (sourceAngularCollar b θ):ℂ)) := + Complex.continuous_ofReal.comp (hφ.continuous.comp (continuous_sourceAngularCollar b)) + simpa using (Complex.reCLM.integral_comp_comm + (hc.integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _))).symm + +lemma spectralTerminalDensity_smooth_pair {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {R : ℝ} (hR : 0 (endPoissonField s f 1 (R,θ)).re*φ (sourceAngularCollar b θ)) ∧ + (∫ θ,(endPoissonField s f 1 (R,θ)).re*φ (sourceAngularCollar b θ))= + -(spectralWeightedPairL s (spectralEndWeight s R f) (smoothCollarTrace s b hφ)).re := by + let u := (mFourierBasis (d:=Fin 2)).repr.symm (spectralTerminalDensity s hR f) + let v := torusSpectralSynthesis s (smoothCollarTrace s b hφ) + have hi := L2.integrable_inner (𝕜:=ℂ) u v + have he : (fun θ => -(inner ℂ (u θ) (v θ)).re)=ᵐ[volume] + (fun θ => (endPoissonField s f 1 (R,θ)).re*φ (sourceAngularCollar b θ)) := by + filter_upwards [spectralTerminalDensity_synthesis_ae hs hR f, + torusSpectralSynthesis_smoothCollar_ae s b hφ] with θ hu hv + change -(inner ℂ (((mFourierBasis (d:=Fin 2)).repr.symm (spectralTerminalDensity s hR f)) θ) + (torusSpectralSynthesis s (smoothCollarTrace s b hφ) θ)).re=_ + rw [hu,hv] + simp [RCLike.inner_apply,Complex.mul_re,mul_comm] + refine ⟨hi.re.neg.congr he,?_⟩ + rw [←integral_congr_ae he,integral_neg] + have hinner : inner ℂ u v=inner ℂ (spectralTerminalDensity s hR f) + ((smoothCollarTrace s b hφ).val 0) := + (mFourierBasis (d:=Fin 2)).repr.symm.inner_map_map _ _ + rw [←spectralTerminalDensity_pair s hR f (smoothCollarTrace s b hφ),←hinner,L2.inner_def] + congr 1 + exact Complex.reCLM.integral_comp_comm hi + +lemma fullEndFlatCovector_terminal_integral {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {R : ℝ} (hR : 0 fullEndFlatCovector s f κ R θ 0*φ (sourceAngularCollar b θ)) ∧ + (∫ θ,fullEndFlatCovector s f κ R θ 0*φ (sourceAngularCollar b θ))= + cylinderTerminalFlux s κ R f (smoothCollarTrace s b hφ) := by + obtain ⟨hi,he⟩ := spectralTerminalDensity_smooth_pair hs hR f b hφ + have hq : Integrable (fun θ => φ (sourceAngularCollar b θ)) := + (hφ.continuous.comp (continuous_sourceAngularCollar b)).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + have hp : (fun θ => fullEndFlatCovector s f κ R θ 0*φ (sourceAngularCollar b θ))= + (fun θ => (endPoissonField s f 1 (R,θ)).re*φ (sourceAngularCollar b θ)+ + κ*φ (sourceAngularCollar b θ)) := by + funext θ + simp [fullEndFlatCovector,add_mul] + rw [hp] + refine ⟨hi.add (hq.const_mul κ),?_⟩ + rw [integral_add hi (hq.const_mul κ),integral_const_mul,he,cylinderTerminalFlux, + smoothCollarTrace_mean_integral] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalL2.lean b/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalL2.lean new file mode 100644 index 0000000000000000000000000000000000000000..8425c4338efb39fedb1b174a5f1aee27427b4cb7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/SpectralTerminalL2.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CylinderSlopeGreen + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sqrt_rate_exp_bound {r R : ℝ} (hr : 0≤r) (hR : 0 ((Real.sqrt (torusRate s h)*Real.exp (-torusRate s h*R):ℝ):ℂ)) + (1+R⁻¹) (by positivity) + (fun h => by simpa only [Complex.norm_real,Real.norm_eq_abs] using + sqrt_rate_exp_bound (r:=torusRate s h) (Real.sqrt_nonneg _) hR) (f.val 1) + +lemma spectralTerminalDensity_pair (s : Fin 3 → ℝ) {R : ℝ} (hR : 0 ℂ) 2 0).restrictScalars ℝ)- + Complex.reCLM.comp ((innerSL ℂ (spectralTerminalDensity s hR f)).restrictScalars ℝ) + +lemma terminalFluxL2CLM_trace (s : Fin 3 → ℝ) (κ : ℝ) {R : ℝ} (hR : 0 (q x).re) t=(deriv q t).re := by + exact (Complex.reCLM.hasFDerivAt.comp_hasDerivAt t + ((hq.differentiable (by simp) t).hasDerivAt)).deriv + have hdi (t : ℝ) : deriv (fun x => (q x).im) t=(deriv q t).im := by + exact (Complex.imCLM.hasFDerivAt.comp_hasDerivAt t + ((hq.differentiable (by simp) t).hasDerivAt)).deriv + have hd := hq.continuous_deriv (by simp) + have hInt : (∫ t in (0:ℝ)..η, ‖deriv q t‖^2+(1+m^2)*‖q t‖^2)= + (∫ t in (0:ℝ)..η, ((deriv q t).re)^2+(1+m^2)*(q t).re^2)+ + (∫ t in (0:ℝ)..η, ((deriv q t).im)^2+(1+m^2)*(q t).im^2) := by + have hir : IntervalIntegrable (fun t => ((deriv q t).re)^2+(1+m^2)*(q t).re^2) volume 0 η := + (((Complex.continuous_re.comp hd).pow 2).add + (continuous_const.mul ((Complex.continuous_re.comp hq.continuous).pow 2))).intervalIntegrable 0 η + have hii : IntervalIntegrable (fun t => ((deriv q t).im)^2+(1+m^2)*(q t).im^2) volume 0 η := + (((Complex.continuous_im.comp hd).pow 2).add + (continuous_const.mul ((Complex.continuous_im.comp hq.continuous).pow 2))).intervalIntegrable 0 η + rw [←intervalIntegral.integral_add hir hii] + apply intervalIntegral.integral_congr + intro t _ + simp only [Complex.sq_norm, Complex.normSq_apply] + simp only [←sq] + ring + change m*(q 0).re^2 ≤ (1+1/η)*(∫ t in (0:ℝ)..η, + (deriv (fun x => (q x).re) t)^2+(1+m^2)*(q t).re^2) at hr + change m*(q 0).im^2 ≤ (1+1/η)*(∫ t in (0:ℝ)..η, + (deriv (fun x => (q x).im) t)^2+(1+m^2)*(q t).im^2) at hi + simp only [hdr] at hr + simp only [hdi] at hi + rw [hInt,Complex.sq_norm,Complex.normSq_apply] + simp only [←sq] + nlinarith + +lemma poisson_mode_energy {m : ℝ} (hm : 0 ≤ m) (a : ℂ) : + IntegrableOn (fun t : ℝ => 2*m^2*Real.exp (-2*m*t)*‖a‖^2) (Ioi 0) ∧ + (∫ t in Ioi (0:ℝ), 2*m^2*Real.exp (-2*m*t)*‖a‖^2)=m*‖a‖^2 := by + rcases hm.eq_or_lt with hm | hm + · subst m; simp + · have hn : -2*m<0 := by linarith + have hi := (integrableOn_exp_mul_Ioi hn 0).const_mul (2*m^2*‖a‖^2) + have he : (fun t : ℝ => 2*m^2*Real.exp (-2*m*t)*‖a‖^2)= + (fun t => (2*m^2*‖a‖^2)*Real.exp ((-2*m)*t)) := by funext t; ring + rw [he] + refine ⟨hi,?_⟩ + rw [integral_const_mul,integral_exp_mul_Ioi hn 0] + simp only [mul_zero,Real.exp_zero] + field_simp + +lemma poisson_spectral_energy {ι : Type*} [Countable ι] {m : ι → ℝ} + (hm : ∀ i,0 ≤ m i) (a : ι → ℂ) (ha : Summable (fun (i : ι) => m i*‖a i‖^2)) : + (∫ t in Ioi (0:ℝ), ∑' i,2*(m i)^2*Real.exp (-2*m i*t)*‖a i‖^2)= + ∑' i,m i*‖a i‖^2 := by + symm + have he (i : ι) : (∫ t in Ioi (0:ℝ), ‖2*(m i)^2*Real.exp (-2*m i*t)*‖a i‖^2‖)= + m i*‖a i‖^2 := by + rw [show (fun t : ℝ => ‖2*(m i)^2*Real.exp (-2*m i*t)*‖a i‖^2‖)= + (fun t => 2*(m i)^2*Real.exp (-2*m i*t)*‖a i‖^2) from by + funext t; rw [Real.norm_eq_abs,abs_of_nonneg]; positivity] + exact (poisson_mode_energy (hm i) (a i)).2 + have hsum : Summable (fun i => ∫ t in Ioi (0:ℝ), + ‖2*(m i)^2*Real.exp (-2*m i*t)*‖a i‖^2‖) := by simpa only [he] using ha + simpa only [(poisson_mode_energy (hm _) (a _)).2] using + integral_tsum_of_summable_integral_norm + (fun i => (poisson_mode_energy (hm i) (a i)).1) hsum + +lemma spectral_trace_summable {ι : Type*} (q : ι → ℝ → ℂ) (m : ι → ℝ) + (hq : ∀ i,ContDiff ℝ (↑(⊤ : ℕ∞)) (q i)) (hm : ∀ i,0 ≤ m i) + {η E : ℝ} (hη : 0<η) + (hE : ∀ F : Finset ι, (∫ t in (0:ℝ)..η, F.sum (fun (i : ι) => + ‖deriv (q i) t‖^2+(1+(m i)^2)*‖q i t‖^2)) ≤ E) : + Summable (fun (i : ι) => m i*‖q i 0‖^2) ∧ + (∑' i,m i*‖q i 0‖^2)≤(1+1/η)*E := by + have hnon : 0 ≤ (fun (i : ι) => m i*‖q i 0‖^2) := fun i => mul_nonneg (hm i) (sq_nonneg _) + have hfin (F : Finset ι) : (∑ i ∈ F,m i*‖q i 0‖^2)≤(1+1/η)*E := by + have hi (i : ι) : IntervalIntegrable (fun t => + ‖deriv (q i) t‖^2+(1+(m i)^2)*‖q i t‖^2) volume 0 η := by + exact (((hq i).continuous_deriv (by simp)).norm.pow 2 |>.add + (continuous_const.mul ((hq i).continuous.norm.pow 2))).intervalIntegrable 0 η + calc + (∑ i ∈ F,m i*‖q i 0‖^2) ≤ ∑ i ∈ F,(1+1/η)*(∫ t in (0:ℝ)..η, + ‖deriv (q i) t‖^2+(1+(m i)^2)*‖q i t‖^2) := + Finset.sum_le_sum fun i _ => complex_fourier_mode_trace_energy (hq i) hη (hm i) + _=(1+1/η)*(∫ t in (0:ℝ)..η,F.sum (fun (i : ι) => + ‖deriv (q i) t‖^2+(1+(m i)^2)*‖q i t‖^2)) := by + rw [intervalIntegral.integral_finsetSum (fun i _ => hi i),Finset.mul_sum] + _≤(1+1/η)*E := mul_le_mul_of_nonneg_left (hE F) (by positivity) + exact ⟨summable_of_sum_le hnon hfin,Real.tsum_le_of_sum_le hnon hfin⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusDirectionalFourier.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusDirectionalFourier.lean new file mode 100644 index 0000000000000000000000000000000000000000..a31bec165aee06ca3afb673fceeb3c694baa4b6d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusDirectionalFourier.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralSmoothTrace + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal +local instance torusDirectionalFourierMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance torusDirectionalFourierProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma torusCoordinateShift_add (j : Fin 2) (s t : ℝ) : + torusCoordinateShift j (s+t)=torusCoordinateShift j s+torusCoordinateShift j t := by + ext i + by_cases hi : i=j <;> simp [torusCoordinateShift,hi] + +lemma torusCoordinateShift_zero (j : Fin 2) : torusCoordinateShift j 0=0 := by + ext i + simp [torusCoordinateShift] + +lemma continuous_torusCoordinateShift (j : Fin 2) : Continuous (torusCoordinateShift j) := by + apply continuous_pi + intro i + by_cases hi : i=j + · simpa [torusCoordinateShift,hi] using AddCircle.continuous_mk' (1:ℝ) + · simpa [torusCoordinateShift,hi] using (continuous_const : Continuous (fun _ : ℝ => (0 : UnitAddCircle))) + +theorem mFourierCoeff_of_directional_derivative + (f : C(UnitAddTorus (Fin 2),ℂ)) (j : Fin 2) (K : ℝ) (hK : 0≤K) + (hLip : ∀ t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤K*|t|) + {d : UnitAddTorus (Fin 2) → ℂ} (hd : AEStronglyMeasurable d volume) + (hder : ∀ᵐ θ : UnitAddTorus (Fin 2), + HasDerivAt (fun t => f (θ+torusCoordinateShift j t)) (d θ) 0) + (h : TorusModes) : + mFourierCoeff d h = (2*Real.pi*Complex.I*(h j)) * mFourierCoeff f h := by + let F : ℝ → UnitAddTorus (Fin 2) → ℂ := fun t θ => + mFourier (-h) θ * f (θ+torusCoordinateShift j t) + have hFc (t : ℝ) : Continuous (F t) := + (mFourier (-h)).continuous.mul (f.continuous.comp (continuous_id.add continuous_const)) + have hFL : ∀ᵐ θ : UnitAddTorus (Fin 2), + LipschitzOnWith (Real.nnabs K) (fun t => F t θ) univ := by + apply Eventually.of_forall + intro θ + apply LipschitzWith.lipschitzOnWith + apply LipschitzWith.of_dist_le_mul + intro t s + have he : θ+torusCoordinateShift j t= + (θ+torusCoordinateShift j s)+torusCoordinateShift j (t-s) := by + rw [add_assoc,←torusCoordinateShift_add,add_sub_cancel] + calc + dist (F t θ) (F s θ)=‖f (θ+torusCoordinateShift j t)-f (θ+torusCoordinateShift j s)‖ := by + rw [dist_eq_norm] + simp only [F,←mul_sub,norm_mul,mFourier_norm_one,one_mul] + _≤K*|t-s| := by rw [he]; exact hLip (t-s) (θ+torusCoordinateShift j s) + _=(Real.nnabs K:ℝ)*dist t s := by rw [Real.coe_nnabs,abs_of_nonneg hK,Real.dist_eq] + have hI := hasDerivAt_integral_of_dominated_loc_of_lip + (μ:=(volume : Measure (UnitAddTorus (Fin 2)))) + (F:=F) (F':=fun θ => mFourier (-h) θ*d θ) + (s:=univ) (bound:=fun _ => K) (x₀:=(0:ℝ)) (univ_mem) + (Eventually.of_forall fun t => (hFc t).aestronglyMeasurable) + ((hFc 0).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _)) + ((mFourier (-h)).continuous.aestronglyMeasurable.mul hd) hFL + (integrable_const _) (hder.mono fun θ hθ => hθ.const_mul _) + have he : (fun t => ∫ θ,F t θ) = + fun t : ℝ => Complex.exp (2*Real.pi*Complex.I*(h j)*t)*mFourierCoeff f h := by + funext t + change mFourierCoeff (fun θ => f (θ+torusCoordinateShift j t)) h=_ + rw [mFourierCoeff_translation,mFourier_coordinateShift] + rw [he] at hI + have hE := ((((hasDerivAt_id (0:ℝ)).ofReal_comp).const_mul + (2*Real.pi*Complex.I*(h j))).cexp).mul_const (mFourierCoeff f h) + have heD := hI.2.unique hE + simpa only [mFourierCoeff,smul_eq_mul,id_eq,Complex.ofReal_zero,mul_zero, + Complex.exp_zero,Complex.ofReal_one,mul_one,one_mul] using heD + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusFlatMode.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusFlatMode.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd315330c77fd32f84d00c380f328eba06fced23 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusFlatMode.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.TorusExponential +import OAI.Analysis.Conductivity.Variational.ScaledSmoothSeries + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology + +lemma flat_proj_norm (i : Fin 3) : + ‖(ContinuousLinearMap.proj i : (Fin 3 → ℝ) →L[ℝ] ℝ)‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro x + simpa using norm_le_pi_norm x i + +def torusAngular (h : Fin 2 → ℤ) : (Fin 3 → ℝ) →L[ℝ] ℝ := + (h 0:ℝ) • ContinuousLinearMap.proj 1 + (h 1:ℝ) • ContinuousLinearMap.proj 2 + +lemma torusAngular_norm (h : Fin 2 → ℤ) : ‖torusAngular h‖≤torusSize h := by + apply (norm_add_le _ _).trans + rw [norm_smul,norm_smul] + exact add_le_add (mul_le_of_le_one_right (norm_nonneg _) (flat_proj_norm _)) + (mul_le_of_le_one_right (norm_nonneg _) (flat_proj_norm _)) + +def flatMode (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (x : Fin 3 → ℝ) : ℝ := + exp (-torusRate s h*x 0) * cos (torusAngular h x) + +lemma flatMode_smooth (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (flatMode s h) := by + unfold flatMode + fun_prop + +lemma axial_exp_iterated_bound (lam : ℝ) (hlam : 0≤lam) (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (fun y : Fin 3 → ℝ => exp (-lam*y 0)) x‖ ≤ lam^n*exp (-lam*x 0) := by + let P : (Fin 3 → ℝ) →L[ℝ] ℝ := ContinuousLinearMap.proj 0 + have he : ContDiff ℝ (↑n) (fun t => exp (-lam*t)) := by fun_prop + change ‖iteratedFDeriv ℝ n ((fun t => exp (-lam*t)) ∘ P) x‖≤_ + rw [P.iteratedFDeriv_comp_right he x le_rfl] + have hb := (iteratedFDeriv ℝ n (fun t => exp (-lam*t)) (P x)).norm_compContinuousLinearMap_le (fun _ => P) + apply hb.trans + simp only [Finset.prod_const,Finset.card_univ,Fintype.card_fin] + have hp : ‖P‖^n≤1 := pow_le_one₀ (norm_nonneg _) (flat_proj_norm 0) + apply (mul_le_of_le_one_right (norm_nonneg _) hp).trans_eq + rw [norm_iteratedFDeriv_eq_norm_iteratedDeriv,iteratedDeriv_exp_const_mul] + simp only [Real.norm_eq_abs,abs_mul,abs_pow,abs_neg,abs_of_nonneg hlam,abs_of_pos (exp_pos _)] + rfl + +lemma angular_cos_iterated_bound (h : Fin 2 → ℤ) (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (fun y => cos (torusAngular h y)) x‖≤(torusSize h)^n := by + have hh := linear_comp_iterated_bound (torusAngular h) Real.contDiff_cos + (fun z => by simpa only [norm_iteratedFDeriv_eq_norm_iteratedDeriv] using + (sin_cos_iterated_bound n z).2) x + apply hh.trans + rw [one_mul] + exact pow_le_pow_left₀ (norm_nonneg _) (torusAngular_norm h) _ + +lemma flatMode_iterated_bound (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) + (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (flatMode s h) x‖≤ + (torusRate s h+torusSize h)^n*exp (-torusRate s h*x 0) := by + have he : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Fin 3 → ℝ => exp (-torusRate s h*y 0)) := by fun_prop + have hc : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => cos (torusAngular h y)) := by fun_prop + apply (norm_iteratedFDeriv_mul_le he hc x (by exact_mod_cast (le_top : (n:ℕ∞)≤⊤))).trans + calc + _ ≤ ∑ i∈Finset.range (n+1), (n.choose i:ℝ)* + ((torusRate s h)^i*exp (-torusRate s h*x 0))*(torusSize h)^(n-i) := by + apply Finset.sum_le_sum + intro i hi + exact mul_le_mul (mul_le_mul_of_nonneg_left + (axial_exp_iterated_bound _ (sqrt_nonneg _) i x) (Nat.cast_nonneg _)) + (angular_cos_iterated_bound h (n-i) x) (norm_nonneg _) (by dsimp [torusRate]; positivity) + _ = _ := by + rw [add_pow,Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + ring + +lemma flatMode_derivative_summable {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (n : ℕ) {δ : ℝ} (hδ : 0<δ) : + Summable (fun h => (torusRate s h+torusSize h)^n*exp (-δ*torusRate s h)) := by + refine ((torusRate_poly_exp_summable hs n hδ).mul_left ((3:ℝ)^n)).of_nonneg_of_le + (fun h => by dsimp [torusRate,torusSize]; positivity) ?_ + intro h + have hl := torusRate_lower hs h + have hlam : 0≤torusRate s h := sqrt_nonneg _ + calc + _ ≤ (3*torusRate s h)^n*exp (-δ*torusRate s h) := + mul_le_mul_of_nonneg_right (pow_le_pow_left₀ (add_nonneg hlam (torusSize_nonneg h)) (by linarith) _) (exp_nonneg _) + _ = _ := by rw [mul_pow,mul_assoc] + +def flatPhaseMode (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (phase : ℝ) (x : Fin 3 → ℝ) : ℝ := + exp (-torusRate s h*x 0) * cos (torusAngular h x+phase) + +lemma flatPhaseMode_smooth (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (phase : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (flatPhaseMode s h phase) := by + unfold flatPhaseMode + fun_prop + +lemma angular_phase_iterated_bound (h : Fin 2 → ℤ) (phase : ℝ) (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (fun y => cos (torusAngular h y+phase)) x‖≤(torusSize h)^n := by + have hc : ContDiff ℝ (↑(⊤:ℕ∞)) (fun z : ℝ => cos (z+phase)) := by fun_prop + have hh := linear_comp_iterated_bound (torusAngular h) hc + (fun z => by simpa only [norm_iteratedFDeriv_eq_norm_iteratedDeriv,iteratedDeriv_comp_add_const] + using (sin_cos_iterated_bound n (z+phase)).2) x + apply hh.trans + rw [one_mul] + exact pow_le_pow_left₀ (norm_nonneg _) (torusAngular_norm h) _ + +lemma flatPhaseMode_iterated_bound (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (phase : ℝ) + (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (flatPhaseMode s h phase) x‖≤ + (torusRate s h+torusSize h)^n*exp (-torusRate s h*x 0) := by + have he : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Fin 3 → ℝ => exp (-torusRate s h*y 0)) := by fun_prop + have hc : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => cos (torusAngular h y+phase)) := by fun_prop + apply (norm_iteratedFDeriv_mul_le he hc x (by exact_mod_cast (le_top : (n:ℕ∞)≤⊤))).trans + calc + _ ≤ ∑ i∈Finset.range (n+1), (n.choose i:ℝ)* + ((torusRate s h)^i*exp (-torusRate s h*x 0))*(torusSize h)^(n-i) := by + apply Finset.sum_le_sum + intro i hi + exact mul_le_mul (mul_le_mul_of_nonneg_left + (axial_exp_iterated_bound _ (sqrt_nonneg _) i x) (Nat.cast_nonneg _)) + (angular_phase_iterated_bound h phase (n-i) x) (norm_nonneg _) (by dsimp [torusRate]; positivity) + _ = _ := by + rw [add_pow,Finset.sum_mul] + apply Finset.sum_congr rfl + intro i hi + ring + +lemma weighted_phase_iterated_bound {s : Fin 3 → ℝ} {h : Fin 2 → ℤ} + (phase a : ℝ) (n : ℕ) (x : Fin 3 → ℝ) : + ‖iteratedFDeriv ℝ n (fun y => a*flatPhaseMode s h phase y) x‖≤ + |a| *((torusRate s h+torusSize h)^n*exp (-torusRate s h*x 0)) := by + have hh : ContDiffAt ℝ (↑n) (flatPhaseMode s h phase) x := + ((contDiff_infty.mp (flatPhaseMode_smooth s h phase)) n).contDiffAt + change ‖iteratedFDeriv ℝ n (a • flatPhaseMode s h phase) x‖≤_ + rw [iteratedFDeriv_const_smul_apply hh,norm_smul,Real.norm_eq_abs] + exact mul_le_mul_of_nonneg_left (flatPhaseMode_iterated_bound s h phase n x) (abs_nonneg _) + +lemma flatPhaseMode_translation (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) (phase T : ℝ) + (x : Fin 3 → ℝ) : + flatPhaseMode s h phase (x+![T,0,0]) = exp (-torusRate s h*T)*flatPhaseMode s h phase x := by + simp only [flatPhaseMode,torusAngular,add_apply, + smul_apply,ContinuousLinearMap.proj_apply,Pi.add_apply, + Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.head_cons,Matrix.tail_cons, + smul_eq_mul,add_zero] + rw [mul_add,exp_add] + ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierAnalytic.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierAnalytic.lean new file mode 100644 index 0000000000000000000000000000000000000000..273897dfaf0faa0e908de671ae64ea602cd64bf4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierAnalytic.lean @@ -0,0 +1,207 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.RegularPatch +import OAI.Analysis.Conductivity.Fourier.AnalyticNullEuclidean +import OAI.Analysis.Conductivity.Fourier.TorusPoissonContinuous +import OAI.Analysis.Conductivity.Fourier.AnalyticDerivativeBounds + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory UnitAddTorus + +lemma flatFourier_factorial_bound {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B δ : ℝ} (ha : ∀ h,|a h|≤B) (hδ : 0<δ) + (n : ℕ) {x : Coord3} (hx : δ≤x 0) : + ‖iteratedFDeriv ℝ n (flatFourier s a phase) x‖≤ + (B*(∑' h : Fin 2 → ℤ,exp (-(δ/2)*torusRate s h)))* + (3/(δ/2))^n*(n.factorial : ℝ) := by + have hB : 0≤B := (abs_nonneg (a 0)).trans (ha 0) + have he := torusRate_exp_summable hs (by positivity : 0<δ/2) + have hmode := (flatMode_derivative_summable hs n hδ).mul_left B + have hb (h : Fin 2 → ℤ) : + B*((torusRate s h+torusSize h)^n*exp (-δ*torusRate s h))≤ + (B*((3:ℝ)^n*((n.factorial : ℝ)/(δ/2)^n)))*exp (-(δ/2)*torusRate s h) := by + have hl := torusRate_lower hs h + have hlam : 0≤torusRate s h := sqrt_nonneg _ + calc + _ ≤ B * ((3:ℝ)^n*(((n.factorial : ℝ)/(δ/2)^n)*exp (-(δ/2)*torusRate s h))) := by + apply mul_le_mul_of_nonneg_left _ hB + calc + _≤(3*torusRate s h)^n*exp (-δ*torusRate s h) := + mul_le_mul_of_nonneg_right (pow_le_pow_left₀ (add_nonneg hlam (torusSize_nonneg h)) (by linarith) _) (exp_nonneg _) + _=3^n*((torusRate s h)^n*exp (-δ*torusRate s h)) := by rw [mul_pow]; ring + _≤3^n*(((n.factorial : ℝ)/(δ/2)^n)*exp (-(δ/2)*torusRate s h)) := + mul_le_mul_of_nonneg_left (pow_mul_exp_bound n hδ hlam) (by positivity) + _ = _ := by ring + calc + _≤∑' h,B*((torusRate s h+torusSize h)^n*exp (-δ*torusRate s h)) := + flatFourier_iterated_norm hs ha hδ n hx + _≤∑' h,(B*((3:ℝ)^n*((n.factorial : ℝ)/(δ/2)^n)))*exp (-(δ/2)*torusRate s h) := + hmode.tsum_le_tsum hb (he.mul_left _) + _=_ := by + rw [tsum_mul_left] + generalize δ/2 = θ + rw [div_pow] + ring + +lemma flatFourier_analytic {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) : + AnalyticOnNhd ℝ (flatFourier s a phase) {x | 0 exp_nonneg _))) (by positivity) + · exact (flatFourier_smooth hs ha).mono (fun y hy => by + have h := hball hy + change x 0/2 simp only [map_add,map_smul,Pi.add_apply,Pi.smul_apply,smul_eq_mul] + · change ((y 0*D q 1-y 1*D q 0)/(D p 0*D q 1-D p 1*D q 0))*D p 0+ + ((D p 0*y 1-D p 1*y 0)/(D p 0*D q 1-D p 1*D q 0))*D q 0=y 0 + rw [div_mul_eq_mul_div,div_mul_eq_mul_div,←add_div,div_eq_iff hn] + ring + · change ((y 0*D q 1-y 1*D q 0)/(D p 0*D q 1-D p 1*D q 0))*D p 1+ + ((D p 0*y 1-D p 1*y 0)/(D p 0*D q 1-D p 1*D q 0))*D q 1=y 1 + rw [div_mul_eq_mul_div,div_mul_eq_mul_div,←add_div,div_eq_iff hn] + ring + +lemma potential_component_fderivAt {u : Coord3 → Fin 2 → ℝ} {x : Coord3} + (hu : DifferentiableAt ℝ u x) (j : Fin 2) (v : Coord3) : + fderiv ℝ (fun y => u y j) x v=fderiv ℝ u x v j := by + rw [(hasFDerivAt_pi'.mp hu.hasFDerivAt j).fderiv] + rfl + +theorem analyticPair_regular_of_patch {u : Coord3 → Fin 2 → ℝ} + {A : Coord3 → Symmetric3} {U O : Set Coord3} + (hU : IsOpen U) (hc : IsPreconnected U) + (hu : ∀ j,AnalyticOnNhd ℝ (fun x => u x j) U) + (hA : ContDiffOn ℝ (↑(⊤:ℕ∞)) (fun x => (A x).val) U) + (hO : IsOpen O) (hOU : O⊆U) (hne : O.Nonempty) + (hr : TwoFieldRankRegular u O) : + ∀ᵐ x : Coord3,x∈U → x∈regularRegion u A U := by + have hus : ContDiffOn ℝ (↑(⊤:ℕ∞)) u U := + (AnalyticOnNhd.pi hu).contDiffOn_of_completeSpace + have hud (x) (hx : x∈U) := + (hus.differentiableOn (by simp) x hx).differentiableAt (hU.mem_nhds hx) + obtain ⟨a,ha⟩ := hne + rcases hr with hr|hr|⟨κ,hκ⟩ + · have hs := gradientColumns_surjective _ (hr a ha) + obtain ⟨p,hp⟩ := hs ![1,0] + obtain ⟨q,hq⟩ := hs ![0,1] + let M : Coord3 → ℝ := fun x => + fderiv ℝ (fun y => u y 0) x p*fderiv ℝ (fun y => u y 1) x q- + fderiv ℝ (fun y => u y 0) x q*fderiv ℝ (fun y => u y 1) x p + have hM : AnalyticOnNhd ℝ M U := analytic_gradient_minor (hu 0) (hu 1) p q + have hMa : M a≠0 := by + dsimp only [M] + simp only [potential_component_fderivAt (hud a (hOU ha)),hp,hq] + norm_num + have hz := analyticNull_fin 3 U M hU hc hM ⟨a,hOU ha,hMa⟩ + filter_upwards [compl_mem_ae_iff.mpr hz] with x hx hxu + have hn : M x≠0 := by simpa [hxu] using hx + have hh := Filter.inter_mem (hU.mem_nhds hxu) ((hM x hxu).continuousAt.eventually_ne hn) + obtain ⟨V,hVsub,hV,hxV⟩ := mem_nhds_iff.mp hh + have hVU : V⊆U := fun y hy => (hVsub hy).1 + refine mem_regularRegion_iff.mpr ⟨V,hVU,⟨hV,hus.mono hVU,hA.mono hVU,Or.inl ?_⟩,hxV⟩ + intro y hy + apply gradientColumns_rank + apply pairCLM_surjective_of_minor _ p q + have hn := (hVsub hy).2 + change M y≠0 at hn + dsimp only [M] at hn + simpa only [potential_component_fderivAt (hud y (hVU hy)),mul_comm] using hn + · obtain ⟨v,l,κ,hv,hl,hd,he⟩ := hr + obtain ⟨j,hj⟩ := hl + let l' : Fin 2 → ℝ := fun k => l k/l j + let κ' : Fin 2 → ℝ := fun k => κ k-(l k/l j)*κ j + have heg (k : Fin 2) : EqOn (fun x => u x k) + (fun x => l' k*u x j+κ' k) U := by + apply (hu k).eqOn_of_preconnected_of_eventuallyEq + ((analyticOnNhd_const.mul (hu j)).add analyticOnNhd_const) hc (hOU ha) + filter_upwards [hO.mem_nhds ha] with x hx + change u x k = l' k*u x j+κ' k + dsimp only [l',κ'] + rw [he x hx k,he x hx j] + field_simp [hj] + ring + have hev : (fun x => u x j)=ᶠ[𝓝 a] (fun x => l j*v x+κ j) := + Filter.Eventually.mono (hO.mem_nhds ha) (fun x hx => he x hx j) + have hvd := (hv.differentiableOn (by simp) a ha).differentiableAt (hO.mem_nhds ha) + have hf : fderiv ℝ (fun x => u x j) a=l j • fderiv ℝ v a := by + rw [hev.fderiv_eq,((hvd.hasFDerivAt.const_mul (l j)).add_const (κ j)).fderiv] + have hfn : fderiv ℝ (fun x => u x j) a≠0 := by + rw [hf] + exact smul_ne_zero hj (hd a ha) + obtain ⟨w,hw⟩ : ∃ w : Coord3,fderiv ℝ (fun x => u x j) a w≠0 := by + by_contra! h + exact hfn (ContinuousLinearMap.ext h) + have hD := analytic_directional_fderiv (hu j) w + have hz := analyticNull_fin 3 U (fun x => fderiv ℝ (fun y => u y j) x w) + hU hc hD ⟨a,hOU ha,hw⟩ + filter_upwards [compl_mem_ae_iff.mpr hz] with x hx hxu + have hn : fderiv ℝ (fun y => u y j) x w≠0 := by simpa [hxu] using hx + have hh := Filter.inter_mem (hU.mem_nhds hxu) ((hD x hxu).continuousAt.eventually_ne hn) + obtain ⟨V,hVsub,hV,hxV⟩ := mem_nhds_iff.mp hh + have hVU : V⊆U := fun y hy => (hVsub hy).1 + refine mem_regularRegion_iff.mpr ⟨V,hVU,⟨hV,hus.mono hVU,hA.mono hVU, + Or.inr (Or.inl ⟨fun y => u y j,l',κ',(hu j).contDiffOn_of_completeSpace.mono hVU, + ⟨j,?_⟩,?_,fun y hy k => heg k (hVU hy)⟩)⟩,hxV⟩ + · simp [l',hj] + · intro y hy hyz + exact (hVsub hy).2 (by rw [hyz]; rfl) + · have heg (k : Fin 2) : EqOn (fun x => u x k) (fun _ => κ k) U := by + apply (hu k).eqOn_of_preconnected_of_eventuallyEq analyticOnNhd_const hc (hOU ha) + filter_upwards [hO.mem_nhds ha] with x hx + exact congrFun (hκ x hx) k + exact ae_of_all _ (fun x hx => mem_regularRegion_iff.mpr + ⟨U,Subset.rfl,⟨hU,hus,hA,Or.inr (Or.inr ⟨κ,fun y hy => funext (fun k => heg k hy)⟩)⟩,hx⟩) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierSmooth.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierSmooth.lean new file mode 100644 index 0000000000000000000000000000000000000000..2f2af61a8695afcb7d1c1ab5075f261c4e01f551 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierSmooth.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.LocalSmoothSeries +import OAI.Analysis.Conductivity.Fourier.TorusFlatMode + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +def flatFourier (s : Fin 3 → ℝ) (a phase : (Fin 2 → ℤ) → ℝ) (x : Fin 3 → ℝ) : ℝ := + ∑' h, a h*flatPhaseMode s h (phase h) x + +lemma axial_halfspace_open (δ : ℝ) : IsOpen {x : Fin 3 → ℝ | δ x 0) + ⟨fun _ _ => rfl,fun _ _ => rfl⟩ δ).isPreconnected + +lemma weighted_phase_halfspace_bound {s : Fin 3 → ℝ} {a phase : (Fin 2 → ℤ) → ℝ} + {B δ : ℝ} (ha : ∀ h, |a h|≤B) (n : ℕ) (h : Fin 2 → ℤ) + {x : Fin 3 → ℝ} (hx : δ≤x 0) : + ‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) x‖≤ + B*((torusRate s h+torusSize h)^n*exp (-δ*torusRate s h)) := by + apply (weighted_phase_iterated_bound (phase h) (a h) n x).trans + have hrate : 0≤torusRate s h := sqrt_nonneg _ + have hexp : exp (-torusRate s h*x 0)≤exp (-δ*torusRate s h) := by + apply exp_le_exp.mpr + nlinarith [mul_le_mul_of_nonneg_left hx hrate] + have hsize := torusSize_nonneg h + exact mul_le_mul (ha h) (mul_le_mul_of_nonneg_left hexp (by positivity)) + (by positivity) ((abs_nonneg _).trans (ha h)) + +lemma flatFourier_smooth_halfspace {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B δ : ℝ} (ha : ∀ h, |a h|≤B) (hδ : 0<δ) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (flatFourier s a phase) {x | δ contDiff_const.mul (flatPhaseMode_smooth s h (phase h))) + (fun n h => B*((torusRate s h+torusSize h)^n*exp (-δ*torusRate s h))) + · intro n + exact (flatMode_derivative_summable hs n hδ).mul_left B + · intro n h x hx + exact weighted_phase_halfspace_bound ha n h hx.le + +lemma flatFourier_smooth {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B : ℝ} (ha : ∀ h, |a h|≤B) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (flatFourier s a phase) {x | 0 a h*flatPhaseMode s h (phase h) y) x := by + apply local_iteratedFDeriv_tsum (axial_halfspace_open (x 0/2)) (axial_halfspace_connected (x 0/2)) + (fun h => contDiff_const.mul (flatPhaseMode_smooth s h (phase h))) + (fun n h => B*((torusRate s h+torusSize h)^n*exp (-(x 0/2)*torusRate s h))) + · intro n + exact (flatMode_derivative_summable hs n (by linarith)).mul_left B + · intro n h y hy + exact weighted_phase_halfspace_bound ha n h hy.le + · change x 0/2 ‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) x‖) := Summable.of_nonneg_of_le (fun h => norm_nonneg _) + (fun h => weighted_phase_halfspace_bound ha n h hx) hb + exact (norm_tsum_le_tsum_norm hn).trans + (hn.tsum_le_tsum (fun h => weighted_phase_halfspace_bound ha n h hx) hb) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierTranslation.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierTranslation.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ef89155667363d37d0eec5740627f999966dcba --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusFourierTranslation.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : Measure.IsAddHaarMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (Measure.IsAddHaarMeasure AddCircle.haarAddCircle) +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma mFourier_spatial_add {d : Type*} [Fintype d] (h : d → ℤ) + (x y : UnitAddTorus d) : mFourier h (x+y)=mFourier h x*mFourier h y := by + simp only [mFourier,ContinuousMap.coe_mk,Pi.add_apply,fourier_apply, + smul_add,AddCircle.toCircle_add,Circle.coe_mul,Finset.prod_mul_distrib] + +lemma mFourier_norm_one {d : Type*} [Fintype d] (h : d → ℤ) + (x : UnitAddTorus d) : ‖mFourier h x‖=1 := by + simp [mFourier,fourier_apply,norm_prod,Circle.norm_coe] + +lemma mFourierCoeff_translation {d : Type*} [Fintype d] + (f : UnitAddTorus d → ℂ) (b : UnitAddTorus d) (h : d → ℤ) : + mFourierCoeff (fun x => f (x+b)) h=mFourier h b*mFourierCoeff f h := by + have hh := integral_add_right_eq_self (μ:=(volume : Measure (UnitAddTorus d))) + (fun x => mFourier (-h) x*f x) b + change (∫ x,mFourier (-h) x*f (x+b))=mFourier h b*(∫ x,mFourier (-h) x*f x) + rw [←hh,←integral_const_mul] + apply integral_congr_ae + filter_upwards [] with x + rw [mFourier_spatial_add] + have hz : mFourier h b*mFourier (-h) b=1 := by + rw [←mFourier_add] + simp only [add_neg_cancel,mFourier_zero,ContinuousMap.one_apply] + calc + _=mFourier (-h) x*f (x+b)*1 := by ring + _=mFourier (-h) x*f (x+b)*(mFourier h b*mFourier (-h) b) := by rw [hz] + _=_ := by ring + +def torusCoordinateShift (j : Fin 2) (t : ℝ) : UnitAddTorus (Fin 2) := + fun i => if i=j then (t : UnitAddCircle) else 0 + +lemma mFourier_coordinateShift (h : Fin 2 → ℤ) (j : Fin 2) (t : ℝ) : + mFourier h (torusCoordinateShift j t)= + Complex.exp (2*Real.pi*Complex.I*(h j)*t) := by + fin_cases j <;> simp [mFourier,torusCoordinateShift,Fin.prod_univ_two] + +lemma mFourierCoeff_difference (f g : C(UnitAddTorus (Fin 2),ℂ)) (h : Fin 2 → ℤ) : + mFourierCoeff (f-g) h=mFourierCoeff f h-mFourierCoeff g h := by + unfold mFourierCoeff + simp only [ContinuousMap.coe_sub,Pi.sub_apply,smul_sub] + apply integral_sub + · exact ((mFourier (-h)).continuous.smul f.continuous).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + · exact ((mFourier (-h)).continuous.smul g.continuous).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + +lemma torus_fourier_difference_bessel (f : C(UnitAddTorus (Fin 2),ℂ)) + (j : Fin 2) (t : ℝ) (s : Finset (Fin 2 → ℤ)) : + ∑ h∈s,‖(Complex.exp (2*Real.pi*Complex.I*(h j)*t)-1)*mFourierCoeff f h‖^2 ≤ + ∫ x : UnitAddTorus (Fin 2), ‖f (x+torusCoordinateShift j t)-f x‖^2 := by + let g : C(UnitAddTorus (Fin 2),ℂ) := + (f.comp ⟨fun x => x+torusCoordinateShift j t,continuous_id.add continuous_const⟩)-f + have hg (h : Fin 2 → ℤ) : mFourierCoeff g h= + (Complex.exp (2*Real.pi*Complex.I*(h j)*t)-1)*mFourierCoeff f h := by + rw [mFourierCoeff_difference] + change mFourierCoeff (fun x => f (x+torusCoordinateShift j t)) h-_=_ + rw [mFourierCoeff_translation,mFourier_coordinateShift]; ring + have hlp := hasSum_sq_mFourierCoeff (ContinuousMap.toLp 2 volume ℂ g) + have he : ∫ x : UnitAddTorus (Fin 2),‖(ContinuousMap.toLp 2 volume ℂ g : UnitAddTorus (Fin 2) → ℂ) x‖^2= + ∫ x : UnitAddTorus (Fin 2),‖g x‖^2 := by + apply integral_congr_ae + filter_upwards [ContinuousMap.coeFn_toLp (𝕜:=ℂ) (p:=2) volume g] with x hx + rw [hx] + rw [he] at hlp + simp only [mFourierCoeff_toLp,hg] at hlp + exact sum_le_hasSum s (fun _ _ => sq_nonneg _) hlp + +end + +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma torus_phase_difference_limit (n : ℤ) : + Tendsto (fun t : ℝ => ‖t⁻¹ • + (Complex.exp (2*Real.pi*Complex.I*n*t)-1)‖^2) (𝓝[≠] (0:ℝ)) + (𝓝 ((2*Real.pi*(n:ℝ))^2)) := by + have hd := (((hasDerivAt_id (0:ℝ)).ofReal_comp).const_mul + (2*Real.pi*Complex.I*(n:ℂ))).cexp + have hl := hd.tendsto_slope_zero.norm.pow 2 + simpa only [id_eq,zero_add,Complex.ofReal_zero,mul_zero,Complex.exp_zero, + mul_one,norm_mul,Complex.norm_ofNat,Complex.norm_real, + Real.norm_eq_abs,abs_of_pos Real.pi_pos,Complex.norm_I,mul_one, + Complex.norm_intCast,mul_pow,sq_abs,norm_one,one_pow,one_mul,abs_one] using hl + +lemma torus_difference_integral_bound (f : C(UnitAddTorus (Fin 2),ℂ)) + (j : Fin 2) (K : ℝ) (hK : 0≤K) + (hf : ∀ t x,‖f (x+torusCoordinateShift j t)-f x‖≤K*|t|) (t : ℝ) : + (∫ x : UnitAddTorus (Fin 2), ‖f (x+torusCoordinateShift j t)-f x‖^2)≤K^2*t^2 := by + have hint : Integrable (fun x : UnitAddTorus (Fin 2) => + ‖f (x+torusCoordinateShift j t)-f x‖^2) volume := + ((f.continuous.comp (continuous_id.add continuous_const)).sub f.continuous).norm.pow 2 + |>.integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _) + calc + _≤∫ _ : UnitAddTorus (Fin 2),(K*|t|)^2 := by + apply integral_mono hint (integrable_const _) + intro x + exact (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hK (abs_nonneg t))).mpr (hf t x) + _=K^2*t^2 := by simp [mul_pow,sq_abs] + +lemma torus_coordinate_fourier_bound (f : C(UnitAddTorus (Fin 2),ℂ)) + (j : Fin 2) (K : ℝ) (hK : 0≤K) + (hf : ∀ t x,‖f (x+torusCoordinateShift j t)-f x‖≤K*|t|) + (s : Finset (Fin 2 → ℤ)) : + ∑ h∈s,(2*Real.pi*(h j:ℝ))^2*‖mFourierCoeff f h‖^2≤K^2 := by + have hl := tendsto_finsetSum s (fun h _ => + (torus_phase_difference_limit (h j)).mul_const (‖mFourierCoeff f h‖^2)) + apply le_of_tendsto hl + filter_upwards [self_mem_nhdsWithin] with t ht + have ht' : t≠0 := ht + have hb := (torus_fourier_difference_bessel f j t s).trans + (torus_difference_integral_bound f j K hK hf t) + have hs := mul_le_mul_of_nonneg_left hb (sq_nonneg t⁻¹) + calc + _=t⁻¹^2*∑ h∈s,‖(Complex.exp (2*Real.pi*Complex.I*(h j)*t)-1)* + mFourierCoeff f h‖^2 := by + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro h hh + simp only [norm_smul,Real.norm_eq_abs,norm_mul,mul_pow,sq_abs] + ring + _≤t⁻¹^2*(K^2*t^2) := hs + _=K^2 := by field_simp + +theorem torus_coordinate_fourier_summable (f : C(UnitAddTorus (Fin 2),ℂ)) + (j : Fin 2) (K : ℝ) (hK : 0≤K) + (hf : ∀ t x,‖f (x+torusCoordinateShift j t)-f x‖≤K*|t|) : + Summable (fun h : Fin 2 → ℤ => (2*Real.pi*(h j:ℝ))^2*‖mFourierCoeff f h‖^2) := by + apply summable_of_sum_le (fun _ => mul_nonneg (sq_nonneg _) (sq_nonneg _)) + exact torus_coordinate_fourier_bound f j K hK hf + +lemma torusCoordinateShift_norm (j : Fin 2) (t : ℝ) : + ‖torusCoordinateShift j t‖≤|t| := by + apply (pi_norm_le_iff_of_nonneg (abs_nonneg _)).mpr + intro i + dsimp only [torusCoordinateShift] + split_ifs + · exact QuotientAddGroup.norm_mk_le_norm + · simp + +lemma torus_lipschitz_coordinate_bound (f : C(UnitAddTorus (Fin 2),ℂ)) + (K : ℝ≥0) (hf : LipschitzWith K f) (j : Fin 2) (t : ℝ) + (x : UnitAddTorus (Fin 2)) : + ‖f (x+torusCoordinateShift j t)-f x‖≤(K:ℝ)*|t| := by + have hh := hf.dist_le_mul (x+torusCoordinateShift j t) x + rw [dist_eq_norm,dist_eq_norm,add_sub_cancel_left] at hh + exact hh.trans (mul_le_mul_of_nonneg_left (torusCoordinateShift_norm j t) K.coe_nonneg) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusLeadingRealMode.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusLeadingRealMode.lean new file mode 100644 index 0000000000000000000000000000000000000000..7698e9b0305c90bfdbcf0082be500ede990785fb --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusLeadingRealMode.lean @@ -0,0 +1,180 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus Real Complex + +lemma torusQuadratic_neg_mode (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : + torusQuadratic s (-h)=torusQuadratic s h := by + simp only [torusQuadratic,Pi.neg_apply,Int.cast_neg] + ring + +lemma torusRate_neg_mode (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : + torusRate s (-h)=torusRate s h := by + simp only [torusRate,torusQuadratic_neg_mode] + +lemma torusAngular_neg_mode (h : Fin 2 → ℤ) (x : Fin 3 → ℝ) : + torusAngular (-h) x= -torusAngular h x := by + simp only [torusAngular,Pi.neg_apply,Int.cast_neg,add_apply, + smul_apply,ContinuousLinearMap.proj_apply,smul_eq_mul] + ring + +lemma polar_real_cosine (c : ℂ) (t : ℝ) : + ‖c‖*Real.cos (t+c.arg)=c.re*Real.cos t-c.im*Real.sin t := by + by_cases hc : c=0 + · simp [hc] + · rw [Real.cos_add,Complex.cos_arg hc,Complex.sin_arg] + field_simp + +def realTorusCoeff (f : TorusL2) (h : Fin 2 → ℤ) : ℂ := + (mFourierCoeff f h+star (mFourierCoeff f (-h)))/2 + +lemma realTorusCoeff_neg (f : TorusL2) (h : Fin 2 → ℤ) : + realTorusCoeff f (-h)=star (realTorusCoeff f h) := by + simp [realTorusCoeff,star_div₀,star_add,add_comm] + +lemma realTorusCoeff_bound (f : TorusL2) (h : Fin 2 → ℤ) : + ‖realTorusCoeff f h‖≤‖f‖ := by + unfold realTorusCoeff + rw [norm_div] + change ‖mFourierCoeff f h+star (mFourierCoeff f (-h))‖ / ‖(2:ℂ)‖ ≤ ‖f‖ + + have hh := norm_add_le (mFourierCoeff f h) (star (mFourierCoeff f (-h))) + have ha := torusFourierCoeff_bound f h + have hb := torusFourierCoeff_bound f (-h) + simp only [norm_star] at hh + norm_num only [Complex.norm_ofNat] at * + linarith + +lemma realTorusCoeff_polar_mode (s : Fin 3 → ℝ) (f : TorusL2) + (h : Fin 2 → ℤ) (x : Fin 3 → ℝ) : + ‖realTorusCoeff f h‖*flatPhaseMode s h (realTorusCoeff f h).arg x= + (((Real.exp (-torusRate s h*x 0):ℂ)*mFourierCoeff f h* + Complex.exp ((torusAngular h x:ℂ)*Complex.I)).re+ + ((Real.exp (-torusRate s (-h)*x 0):ℂ)*mFourierCoeff f (-h)* + Complex.exp ((torusAngular (-h) x:ℂ)*Complex.I)).re)/2 := by + rw [torusRate_neg_mode,torusAngular_neg_mode] + rw [complex_mode_real,complex_mode_real] + simp only [flatPhaseMode,Real.cos_add_pi_div_two,Real.cos_neg,Real.sin_neg] + rw [←mul_assoc,mul_comm ‖realTorusCoeff f h‖,mul_assoc,polar_real_cosine] + simp only [realTorusCoeff,Complex.div_ofNat_re,Complex.div_ofNat_im,Complex.add_re, + Complex.add_im,Complex.star_def,Complex.conj_re,Complex.conj_im] + ring + +lemma torusRealContinuation_polar {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : TorusL2) {x : Fin 3 → ℝ} (hx : 0 ‖realTorusCoeff f h‖) (fun h => (realTorusCoeff f h).arg) x := by + let F := fun h : Fin 2 → ℤ => + (((Real.exp (-torusRate s h*x 0):ℂ)*mFourierCoeff f h)* + Complex.exp ((torusAngular h x:ℂ)*Complex.I)).re + have hc := (ContinuousMap.evalCLM ℂ (torusAngles x)).hasSum + (poisson_series_norm_summable hs hx f).of_norm.hasSum + have hr := Complex.reCLM.hasSum hc + change HasSum (fun h => ((Real.exp (-torusRate s h*x 0):ℂ)*mFourierCoeff f h* + mFourier h (torusAngles x)).re) (torusRealContinuation s f x) at hr + simp_rw [mFourier_torusAngles] at hr + change HasSum F (torusRealContinuation s f x) at hr + have hn : HasSum (fun h => F (-h)) (torusRealContinuation s f x) := + (Equiv.neg (Fin 2 → ℤ)).hasSum_iff.mpr hr + have hh := (hr.add hn).div_const 2 + have he : (torusRealContinuation s f x+torusRealContinuation s f x)/2= + torusRealContinuation s f x := by ring + rw [he] at hh + exact hh.tsum_eq.symm.trans (by + unfold flatFourier + apply tsum_congr + intro h + exact (realTorusCoeff_polar_mode s f h x).symm) + +lemma realTorusCoeff_zero_re (f : TorusL2) : + (realTorusCoeff f 0).re=(mFourierCoeff f 0).re := by + simp only [realTorusCoeff,neg_zero,Complex.div_ofNat_re,Complex.add_re, + Complex.star_def,Complex.conj_re] + ring + +lemma realTorusCoeff_polar_zero (s : Fin 3 → ℝ) (f : TorusL2) (x : Fin 3 → ℝ) : + ‖realTorusCoeff f 0‖*flatPhaseMode s 0 (realTorusCoeff f 0).arg x= + (mFourierCoeff f 0).re := by + simp [flatPhaseMode,torusRate,torusQuadratic,torusAngular,realTorusCoeff_zero_re] + +lemma realTorusCoeff_polar_neg (s : Fin 3 → ℝ) (f : TorusL2) + (h : Fin 2 → ℤ) (x : Fin 3 → ℝ) : + ‖realTorusCoeff f (-h)‖*flatPhaseMode s (-h) (realTorusCoeff f (-h)).arg x= + ‖realTorusCoeff f h‖*flatPhaseMode s h (realTorusCoeff f h).arg x := by + dsimp only [flatPhaseMode] + rw [←mul_assoc,mul_comm ‖realTorusCoeff f (-h)‖,mul_assoc,polar_real_cosine, + ←mul_assoc,mul_comm ‖realTorusCoeff f h‖,mul_assoc,polar_real_cosine, + torusRate_neg_mode,torusAngular_neg_mode,realTorusCoeff_neg] + simp [Real.cos_neg,Real.sin_neg] + +def realTorusAmplitude (f : TorusL2) (h : Fin 2 → ℤ) : ℝ := + if h=0 then 0 else ‖realTorusCoeff f h‖ + +def realTorusPhase (f : TorusL2) (h : Fin 2 → ℤ) : ℝ := (realTorusCoeff f h).arg + +lemma realTorusAmplitude_bound (f : TorusL2) (h : Fin 2 → ℤ) : + |realTorusAmplitude f h|≤‖f‖ := by + unfold realTorusAmplitude + split_ifs + · simp + · simpa only [abs_of_nonneg (norm_nonneg _)] using realTorusCoeff_bound f h + +lemma torusRealContinuation_mean_free {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : TorusL2) {x : Fin 3 → ℝ} (hx : 0 simp + +lemma torusRate_uniform_positive {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) : + ∃ g>0,∀ h : Fin 2 → ℤ,h≠0 → g≤torusRate s h := by + have he : ({h : Fin 2 → ℤ | h≠0} : Set (Fin 2 → ℤ)).Nonempty := by + refine ⟨![1,0],?_⟩ + intro he + have := congrFun he 0 + norm_num at this + obtain ⟨h,hh,hmin⟩ := torus_modes_have_first hs he + refine ⟨torusRate s h,Real.sqrt_pos.mpr (torusQuadratic_pos hs hh),?_⟩ + intro l hl + exact Real.sqrt_le_sqrt (hmin l hl) + +lemma torus_leading_rate_gap {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (hres : ∀ h l : Fin 2 → ℤ,torusQuadratic s h=torusQuadratic s l → l=h ∨ l= -h) + {M : Set (Fin 2 → ℤ)} (hne : M.Nonempty) (hzero : 0∉M) : + ∃ h∈M,00, + ∀ l∈M,l≠h → l≠-h → torusRate s h+g≤torusRate s l := by + obtain ⟨h,hh,hq,d,hd,hmin⟩ := torus_leading_pair_gap hs hres hne hzero + refine ⟨h,hh,Real.sqrt_pos.mpr hq,Real.sqrt (torusQuadratic s h+d)-torusRate s h, + sub_pos.mpr (Real.sqrt_lt_sqrt hq.le (by linarith)),?_⟩ + intro l hl hne hn + have hle := Real.sqrt_le_sqrt (hmin l hl hne hn) + change Real.sqrt (torusQuadratic s h)+(Real.sqrt (torusQuadratic s h+d)- + Real.sqrt (torusQuadratic s h))≤Real.sqrt (torusQuadratic s l) + linarith + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusNonresonance.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusNonresonance.lean new file mode 100644 index 0000000000000000000000000000000000000000..3fb2d63e8a960b92c8c52238140069cabdf3f477 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusNonresonance.lean @@ -0,0 +1,180 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory + +def torusQuadratic (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : ℝ := + s 0*(h 0 : ℝ)^2+2*s 1*(h 0 : ℝ)*(h 1 : ℝ)+s 2*(h 1 : ℝ)^2 + +lemma real_outer_pair_injective {a b c d : ℝ} + (h0 : a^2=c^2) (h1 : b^2=d^2) (h2 : a*b=c*d) : + (a=c ∧ b=d) ∨ (a= -c ∧ b= -d) := by + rcases sq_eq_sq_iff_eq_or_eq_neg.mp h0 with h0|h0 <;> + rcases sq_eq_sq_iff_eq_or_eq_neg.mp h1 with h1|h1 + · exact Or.inl ⟨h0,h1⟩ + · by_cases hc : c=0 + · right; constructor <;> linarith + · left; refine ⟨h0,?_⟩ + have hz : c*(b-d)=0 := by rw [h0] at h2; nlinarith + have := (mul_eq_zero.mp hz).resolve_left hc + linarith + · by_cases hd : d=0 + · right; constructor <;> linarith + · left; refine ⟨?_,h1⟩ + have hz : (a-c)*d=0 := by rw [h1] at h2; nlinarith + have := (mul_eq_zero.mp hz).resolve_right hd + linarith + · exact Or.inr ⟨h0,h1⟩ + +def torusResonanceForm (h l : Fin 2 → ℤ) : (Fin 3 → ℝ) →ₗ[ℝ] ℝ where + toFun s := torusQuadratic s h-torusQuadratic s l + map_add' _ _ := by simp only [torusQuadratic,Pi.add_apply]; ring + map_smul' _ _ := by simp only [torusQuadratic,Pi.smul_apply,smul_eq_mul,RingHom.id_apply]; ring + +lemma torusResonance_proper {h l : Fin 2 → ℤ} (he : l ≠ h) (hn : l ≠ -h) : + (torusResonanceForm h l).ker ≠ ⊤ := by + intro hk + have hh (s : Fin 3 → ℝ) : torusQuadratic s h=torusQuadratic s l := by + have : s∈(torusResonanceForm h l).ker := hk ▸ Submodule.mem_top + exact sub_eq_zero.mp this + have h0 := hh ![1,0,0] + have h1 := hh ![0,0,1] + have h2 := hh ![0,1,0] + norm_num [torusQuadratic,Matrix.cons_val_two] at h0 h1 h2 + have h2' : (h 0 : ℝ)*(h 1 : ℝ)=(l 0 : ℝ)*(l 1 : ℝ) := by linarith + rcases real_outer_pair_injective h0 h1 h2' with hh|hh + · apply he; ext i; fin_cases i + · exact_mod_cast hh.1.symm + · exact_mod_cast hh.2.symm + · apply hn; ext i; fin_cases i + · change l 0= -(h 0) + exact_mod_cast (show (l 0 : ℝ)= -(h 0 : ℝ) by linarith [hh.1]) + · change l 1= -(h 1) + exact_mod_cast (show (l 1 : ℝ)= -(h 1 : ℝ) by linarith [hh.2]) + +theorem exists_nonresonant_angular_tensor : ∃ s : Fin 3 → ℝ, + (∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) ∧ + (∀ h l : Fin 2 → ℤ, torusQuadratic s h=torusQuadratic s l → l=h ∨ l= -h) := by + let I := {p : (Fin 2 → ℤ) × (Fin 2 → ℤ) // p.2 ≠ p.1 ∧ p.2 ≠ -p.1} + let bad : Set (Fin 3 → ℝ) := ⋃ p : I, ((torusResonanceForm p.val.1 p.val.2).ker : Set (Fin 3 → ℝ)) + have hbad : volume bad=0 := by + apply measure_iUnion_null + intro p + exact Measure.addHaar_submodule volume _ (torusResonance_proper p.property.1 p.property.2) + let o : Fin 3 → ℝ := ![1,0,1] + obtain ⟨s,hs,hsg⟩ : ∃ s∈Metric.ball o (1/4), s∉bad := by + by_contra! hn + have hsub : Metric.ball o (1/4)⊆bad := hn + have hle := measure_mono (μ := volume) hsub + rw [hbad] at hle + exact (Metric.measure_ball_pos volume o (by norm_num : (0:ℝ)<1/4)).not_ge hle + refine ⟨s,?_,?_⟩ + · have hnorm : ‖s-o‖<1/4 := by simpa only [Metric.mem_ball,dist_eq_norm] using hs + have hi (i : Fin 3) : |s i-o i|<1/4 := by + simpa only [Pi.sub_apply,Real.norm_eq_abs] using (norm_le_pi_norm (s-o) i).trans_lt hnorm + have h0 := (abs_lt.mp (hi 0)).1 + have h1 := abs_lt.mp (hi 1) + have h2 := (abs_lt.mp (hi 2)).1 + norm_num [o,Matrix.cons_val_two] at h0 h1 h2 + intro x y + nlinarith [mul_nonneg (show 0 ≤ s 0-3/4 by linarith) (sq_nonneg x), + mul_nonneg (show 0 ≤ s 2-3/4 by linarith) (sq_nonneg y), + mul_nonneg (show 0 ≤ 1/4+s 1 by linarith) (sq_nonneg (x+y)), + mul_nonneg (show 0 ≤ 1/4-s 1 by linarith) (sq_nonneg (x-y))] + · intro h l hh + by_contra! hn + apply hsg + apply mem_iUnion.mpr + refine ⟨⟨(h,l),hn⟩,?_⟩ + exact sub_eq_zero.mpr hh + +end + +open Set + +lemma torusQuadratic_sublevel_finite {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) : {h : Fin 2 → ℤ | torusQuadratic s h ≤ R}.Finite := by + obtain ⟨N,hN⟩ := exists_nat_gt (|2*R|+1) + have hN0 : 0 < (N:ℝ) := lt_trans (by positivity) hN + apply (Set.Finite.pi' (fun _ : Fin 2 => Set.finite_Icc (-(N:ℤ)) N)).subset + intro h hh i + change torusQuadratic s h ≤ R at hh + have hq := hs (h 0) (h 1) + change (1/2)*((h 0:ℝ)^2+(h 1:ℝ)^2) ≤ torusQuadratic s h at hq + have hb : (h i:ℝ)^2 ≤ 2*R := by + fin_cases i <;> simp only [Fin.zero_eta, Fin.mk_one] at * + · nlinarith [sq_nonneg (h 1:ℝ)] + · nlinarith [sq_nonneg (h 0:ℝ)] + have hN2 : 2*R < (N:ℝ)^2 := by + have habs := le_abs_self (2*R) + nlinarith [sq_nonneg ((N:ℝ)-1)] + have hbound : -(N:ℝ) ≤ (h i:ℝ) ∧ (h i:ℝ) ≤ N := by + constructor + · nlinarith [sq_nonneg ((h i:ℝ)+(N:ℝ))] + · nlinarith [sq_nonneg ((h i:ℝ)-(N:ℝ))] + exact_mod_cast hbound + +lemma torusQuadratic_pos {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {h : Fin 2 → ℤ} (hh : h≠0) : 0 simp [h0,h1] + rcases hn with hn|hn + · nlinarith [sq_pos_of_ne_zero hn,sq_nonneg (h 1:ℝ)] + · nlinarith [sq_pos_of_ne_zero hn,sq_nonneg (h 0:ℝ)] + +lemma torus_modes_have_first {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {M : Set (Fin 2 → ℤ)} (hne : M.Nonempty) : + ∃ h∈M, ∀ l∈M, torusQuadratic s h ≤ torusQuadratic s l := by + obtain ⟨h₀,hh₀⟩ := hne + let K := M∩{h | torusQuadratic s h ≤ torusQuadratic s h₀} + have hK : K.Finite := (torusQuadratic_sublevel_finite hs _).subset inter_subset_right + obtain ⟨h,hh,hmin⟩ := Set.exists_min_image K (torusQuadratic s) hK ⟨h₀,hh₀,show torusQuadratic s h₀ ≤ torusQuadratic s h₀ from le_rfl⟩ + refine ⟨h,hh.1,fun l hl => ?_⟩ + by_cases hll : torusQuadratic s l ≤ torusQuadratic s h₀ + · exact hmin l ⟨hl,hll⟩ + · exact hh.2.trans (le_of_not_ge hll) + +theorem torus_leading_pair_gap {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (hres : ∀ h l : Fin 2 → ℤ, torusQuadratic s h=torusQuadratic s l → l=h ∨ l= -h) + {M : Set (Fin 2 → ℤ)} (hne : M.Nonempty) (hzero : 0∉M) : + ∃ h∈M, 0 hzero (he ▸ hh)),?_⟩ + let N := {l∈M | l≠h ∧ l≠-h} + by_cases hN : N.Nonempty + · obtain ⟨g,hg,hgmin⟩ := torus_modes_have_first hs hN + have hlt : torusQuadratic s h simp [torusAngles,torusRealProjection,Real.pi_ne_zero] + +lemma torusPeriodicDescent_real {f : Coord3 → E} + (hp : AngularPeriodic (2*Real.pi) f) (t : ℝ) (x : Fin 2 → ℝ) : + torusPeriodicDescent f (t,torusRealProjection x)=f ![t,2*Real.pi*x 0,2*Real.pi*x 1] := by + change f ![t,2*Real.pi*torusRealRepresentative (torusRealProjection x) 0, + 2*Real.pi*torusRealRepresentative (torusRealProjection x) 1]=_ + apply hp.eq_of_angles + · rfl + rw [torusAngles_scaled,torusAngles_scaled,torusRealProjection_representative] + +lemma torusPeriodicDescent_angles {f : Coord3 → E} + (hp : AngularPeriodic (2*Real.pi) f) (x : Coord3) : + torusPeriodicDescent f (x 0,torusAngles x)=f x := by + change f ![x 0,2*Real.pi*torusRealRepresentative (torusAngles x) 0, + 2*Real.pi*torusRealRepresentative (torusAngles x) 1]=_ + apply hp.eq_of_angles + · rfl + rw [torusAngles_scaled,torusRealProjection_representative] + +lemma isOpenMap_torusRealProjection : IsOpenMap torusRealProjection := by + change IsOpenMap (Pi.map (fun _ : Fin 2 => ((↑) : ℝ → UnitAddCircle))) + exact IsOpenMap.piMap (fun _ => QuotientAddGroup.isOpenMap_coe) + (Filter.Eventually.of_forall fun _ => QuotientAddGroup.mk_surjective) + +lemma torusRealProjection_surjective : Function.Surjective torusRealProjection := + fun θ => ⟨torusRealRepresentative θ,torusRealProjection_representative θ⟩ + +lemma continuous_torusPeriodicDescent {f : Coord3 → E} + (hf : Continuous f) (hp : AngularPeriodic (2*Real.pi) f) : + Continuous (torusPeriodicDescent f) := by + let P := Prod.map (id : ℝ → ℝ) torusRealProjection + have hP : IsQuotientMap P := (IsOpenMap.id.prodMap isOpenMap_torusRealProjection).isQuotientMap + (continuous_id.prodMap continuous_torusRealProjection) + (Function.surjective_id.prodMap torusRealProjection_surjective) + apply hP.continuous_iff.mpr + have he : torusPeriodicDescent f ∘ P = + fun z : ℝ × (Fin 2 → ℝ) => f ![z.1,2*Real.pi*z.2 0,2*Real.pi*z.2 1] := by + funext z + exact torusPeriodicDescent_real hp z.1 z.2 + rw [he] + exact hf.comp (by fun_prop) + +lemma integral_unitTorus_iterated_general [CompleteSpace E] + {F : UnitAddTorus (Fin 2) → E} (hF : Continuous F) : + (∫ θ,F θ)=∫ θ : UnitAddCircle,∫ η : UnitAddCircle,F ![θ,η] + ∂AddCircle.haarAddCircle ∂AddCircle.haarAddCircle := by + have hc : Continuous (MeasurableEquiv.finTwoArrow.symm : + UnitAddCircle × UnitAddCircle → UnitAddTorus (Fin 2)) := by + change Continuous (fun z : UnitAddCircle × UnitAddCircle => ![z.1,z.2]) + fun_prop + rw [←(volume_preserving_finTwoArrow UnitAddCircle).symm.integral_comp'] + change (∫ z : UnitAddCircle × UnitAddCircle,F (MeasurableEquiv.finTwoArrow.symm z) + ∂volume.prod volume)=_ + rw [integral_prod (fun z : UnitAddCircle × UnitAddCircle => F (MeasurableEquiv.finTwoArrow.symm z)) + ((hF.comp hc).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _))] + rfl + +lemma integral_unitCircle_haar_interval {F : UnitAddCircle → E} : + (∫ θ : UnitAddCircle,F θ ∂AddCircle.haarAddCircle)=∫ t in (0:ℝ)..1,F (t:UnitAddCircle) := by + have h := (UnitAddCircle.intervalIntegral_preimage 0 F).symm + simpa only [zero_add,unitCircle_volume_eq_haar] using h + +lemma torusPeriodicDescent_integral {f : Coord3 → ℝ} + (hf : Continuous f) (hp : AngularPeriodic (2*Real.pi) f) (t : ℝ) : + (∫ θ,torusPeriodicDescent f (t,θ))=(2*Real.pi)⁻¹^2*torusCellIntegral (2*Real.pi) f t := by + have hc : Continuous (fun θ => torusPeriodicDescent f (t,θ)) := + (continuous_torusPeriodicDescent hf hp).comp (continuous_const.prodMk continuous_id) + rw [integral_unitTorus_iterated_general hc] + rw [integral_unitCircle_haar_interval] + have hπ : 2*Real.pi≠0 := by positivity + have hi (x : ℝ) : (∫ θ : UnitAddCircle,torusPeriodicDescent f (t,![(x:UnitAddCircle),θ]) + ∂AddCircle.haarAddCircle)= + (2*Real.pi)⁻¹*(∫ y in (0:ℝ)..(2*Real.pi),f ![t,2*Real.pi*x,y]) := by + rw [integral_unitCircle_haar_interval] + have he (y : ℝ) : torusPeriodicDescent f (t,![(x:UnitAddCircle),(y:UnitAddCircle)])= + f ![t,2*Real.pi*x,2*Real.pi*y] := torusPeriodicDescent_real hp t ![x,y] + simp_rw [he] + rw [intervalIntegral.integral_comp_mul_left (fun y => f ![t,2*Real.pi*x,y]) hπ] + simp + simp_rw [hi] + rw [intervalIntegral.integral_const_mul, + intervalIntegral.integral_comp_mul_left (fun x => ∫ y in (0:ℝ)..(2*Real.pi),f ![t,x,y]) hπ] + simp only [mul_zero,mul_one,smul_eq_mul,torusCellIntegral] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonContinuous.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonContinuous.lean new file mode 100644 index 0000000000000000000000000000000000000000..90c2b76d31bdff397cc16371532b76f060de068a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonContinuous.lean @@ -0,0 +1,143 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusPoissonFlow +import OAI.Analysis.Conductivity.Fourier.TorusFourierSmooth + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance torusPoissonContinuousMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusPoissonContinuousProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma poisson_series_norm_summable {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {t : ℝ} (ht : 0 ‖((Real.exp (-torusRate s h*t):ℂ)*mFourierCoeff f h) • mFourier h‖) := by + apply ((torusRate_exp_summable hs ht).mul_left ‖f‖).of_nonneg_of_le + (fun _ => norm_nonneg _) (fun h => ?_) + rw [norm_smul,mFourier_norm,mul_one,norm_mul,Complex.norm_real,Real.norm_eq_abs, + abs_of_pos (Real.exp_pos _)] + simpa only [mul_comm,neg_mul,mul_neg] using + mul_le_mul_of_nonneg_left (torusFourierCoeff_bound f h) (Real.exp_nonneg (-torusRate s h*t)) + +def torusPoissonContinuous (s : Fin 3 → ℝ) (t : ℝ) (f : TorusL2) : + C(UnitAddTorus (Fin 2),ℂ) := + ∑' h, ((Real.exp (-torusRate s h*t):ℂ)*mFourierCoeff f h) • mFourier h + +theorem torusPoissonContinuous_toLp {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {t : ℝ} (ht : 0 a h*flatPhaseMode s h (phase h) x) := by + apply Summable.of_norm + apply ((torusRate_exp_summable hs hx).mul_left B).of_nonneg_of_le (fun _ => norm_nonneg _) + intro h + rw [Real.norm_eq_abs,abs_mul,flatPhaseMode,abs_mul,abs_of_pos (exp_pos _)] + calc + _ ≤ B*(exp (-torusRate s h*x 0)*1) := mul_le_mul (ha h) + (mul_le_mul_of_nonneg_left (abs_cos_le_one _) (exp_nonneg _)) (by positivity) + ((abs_nonneg _).trans (ha h)) + _ = _ := by rw [mul_one]; congr 2; ring + +lemma complex_mode_real (c : ℂ) (r θ : ℝ) : + ((exp r:ℂ)*c*Complex.exp ((θ:ℂ)*Complex.I)).re= + c.re*(exp r*cos θ)+c.im*(exp r*cos (θ+Real.pi/2)) := by + rw [Complex.exp_mul_I] + rw [←Complex.ofReal_cos, ←Complex.ofReal_sin] + simp only [Complex.add_re, Complex.add_im,Complex.mul_re,Complex.mul_im,Complex.ofReal_re, + Complex.ofReal_im,Complex.I_re,Complex.I_im] + rw [cos_add_pi_div_two] + ring + +def torusRealContinuation (s : Fin 3 → ℝ) (f : TorusL2) (x : Fin 3 → ℝ) : ℝ := + (torusPoissonContinuous s (x 0) f (torusAngles x)).re + +lemma torusRealContinuation_eq {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : TorusL2) {x : Fin 3 → ℝ} (hx : 0 (mFourierCoeff f h).re) (fun _ => 0) x+ + flatFourier s (fun h => (mFourierCoeff f h).im) (fun _ => Real.pi/2) x := by + have hre (h) : |(mFourierCoeff f h).re|≤‖f‖ := + (Complex.abs_re_le_norm _).trans (torusFourierCoeff_bound f h) + have him (h) : |(mFourierCoeff f h).im|≤‖f‖ := + (Complex.abs_im_le_norm _).trans (torusFourierCoeff_bound f h) + have hc := (ContinuousMap.evalCLM ℂ (torusAngles x)).hasSum + (poisson_series_norm_summable hs hx f).of_norm.hasSum + have hr := Complex.reCLM.hasSum hc + change HasSum (fun h => ((exp (-torusRate s h*x 0):ℂ)*mFourierCoeff f h*mFourier h (torusAngles x)).re) + (torusRealContinuation s f x) at hr + rw [←hr.tsum_eq] + unfold flatFourier + rw [←(flatFourier_summable hs hre hx).tsum_add (flatFourier_summable hs him hx)] + apply tsum_congr + intro h + rw [mFourier_torusAngles,complex_mode_real] + simp only [flatPhaseMode,add_zero] + +lemma torusRealContinuation_smooth {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : TorusL2) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (torusRealContinuation s f) {x | 0 torusRealContinuation_eq hs f hx) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonFlow.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4c4e585310db37429debafb434aec755e3d80aa --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusPoissonFlow.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.L2SpectralMultiplier +import OAI.Analysis.Conductivity.Geometry.TorusExponential + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance torusPoissonFlowMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ + +abbrev TorusL2 := Lp ℂ 2 (volume : Measure (UnitAddTorus (Fin 2))) + +lemma poissonMultiplier_bound (s : Fin 3 → ℝ) (t : ℝ) (h : Fin 2 → ℤ) : + ‖(Real.exp (-torusRate s h*|t|):ℂ)‖≤1 := by + rw [Complex.norm_real,Real.norm_eq_abs,abs_of_pos (Real.exp_pos _)] + apply Real.exp_le_one_iff.mpr + exact mul_nonpos_of_nonpos_of_nonneg (neg_nonpos.mpr (Real.sqrt_nonneg _)) (abs_nonneg _) + +def torusPoissonFlow (s : Fin 3 → ℝ) (t : ℝ) (f : TorusL2) : TorusL2 := + (mFourierBasis (d:=Fin 2)).repr.symm + (sequenceMultiplier (fun h => (Real.exp (-torusRate s h*|t|):ℂ)) 1 + zero_le_one (poissonMultiplier_bound s t) ((mFourierBasis (d:=Fin 2)).repr f)) + +lemma torusPoissonFlow_coeff (s : Fin 3 → ℝ) (t : ℝ) (f : TorusL2) (h : Fin 2 → ℤ) : + mFourierCoeff (torusPoissonFlow s t f) h= + (Real.exp (-torusRate s h*|t|):ℂ)*mFourierCoeff f h := by + rw [←mFourierBasis_repr,torusPoissonFlow,LinearIsometryEquiv.apply_symm_apply, + sequenceMultiplier_apply,mFourierBasis_repr] + +lemma torusPoissonFlow_zero (s : Fin 3 → ℝ) (f : TorusL2) : torusPoissonFlow s 0 f=f := by + apply (mFourierBasis (d:=Fin 2)).repr.injective + ext h + rw [mFourierBasis_repr,torusPoissonFlow_coeff] + simp only [abs_zero,mul_zero,Real.exp_zero,Complex.ofReal_one,one_mul] + exact (mFourierBasis_repr f h).symm + +lemma torusPoissonFlow_tendsto (s : Fin 3 → ℝ) (f : TorusL2) : + Tendsto (fun t => torusPoissonFlow s t f) (𝓝 0) (𝓝 f) := by + have hm : ∀ h : Fin 2 → ℤ, + Tendsto (fun t : ℝ => (Real.exp (-torusRate s h*|t|):ℂ)) (𝓝 0) (𝓝 1) := by + intro h + have hc : Continuous (fun t : ℝ => (Real.exp (-torusRate s h*|t|):ℂ)) := by fun_prop + simpa using hc.continuousAt.tendsto (x:=0) + have hh := sequenceMultiplier_coeff_tendsto + (fun t h => (Real.exp (-torusRate s h*|t|):ℂ)) 1 zero_le_one + (poissonMultiplier_bound s) hm ((mFourierBasis (d:=Fin 2)).repr f) + simpa only [Function.comp_def,torusPoissonFlow,LinearIsometryEquiv.symm_apply_apply] using + (mFourierBasis (d:=Fin 2)).repr.symm.continuous.continuousAt.tendsto.comp hh + +lemma torusFourierCoeff_bound (f : TorusL2) (h : Fin 2 → ℤ) : + ‖mFourierCoeff f h‖≤‖f‖ := by + rw [←mFourierBasis_repr] + exact (lp.norm_apply_le_norm (by norm_num : (2:ℝ≥0∞)≠0) _ h).trans_eq + ((mFourierBasis (d:=Fin 2)).repr.norm_map f) + +lemma torusPoissonFlow_norm (s : Fin 3 → ℝ) (t : ℝ) (f : TorusL2) : + ‖torusPoissonFlow s t f‖≤‖f‖ := by + unfold torusPoissonFlow + rw [LinearIsometryEquiv.norm_map] + apply ((sequenceMultiplier _ 1 zero_le_one (poissonMultiplier_bound s t)).le_opNorm _).trans + have hm := sequenceMultiplier_norm _ 1 zero_le_one (poissonMultiplier_bound s t) + simpa only [one_mul,LinearIsometryEquiv.norm_map] using + mul_le_mul_of_nonneg_right hm (norm_nonneg ((mFourierBasis (d:=Fin 2)).repr f)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusSmoothModeJet.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusSmoothModeJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..e5f981132e3e63b32b0273bf8341a613fee07dab --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusSmoothModeJet.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularGraph +import OAI.Analysis.Conductivity.Fourier.AngularPeriodization + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus +open scoped ENNReal +local instance torusSmoothModeJetMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance torusSmoothModeJetIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma torusAngles_shift (n : Fin 2 → ℤ) (x : Coord3) : + torusAngles (x+angularShift (2*Real.pi) n)=torusAngles x := by + have hπ : 2*Real.pi≠0 := by positivity + ext i + fin_cases i <;> simp [torusAngles,angularShift,add_div,hπ,mul_div_cancel_left₀] + +def angularFrequency (h : TorusModes) : Coord3 →L[ℝ] ℂ := + (Complex.I*(h 0:ℂ)) • Complex.ofRealCLM.comp (ContinuousLinearMap.proj 1)+ + (Complex.I*(h 1:ℂ)) • Complex.ofRealCLM.comp (ContinuousLinearMap.proj 2) + +lemma angularFrequency_apply (h : TorusModes) (x : Coord3) : + angularFrequency h x=(torusAngular h x:ℂ)*Complex.I := by + simp [angularFrequency,torusAngular] + ring + +def flatSmoothMode (q : ℝ → ℂ) (h : TorusModes) (x : Coord3) : ℂ := + q (x 0)*Complex.exp (angularFrequency h x) + +lemma flatSmoothMode_eq (q : ℝ → ℂ) (h : TorusModes) (x : Coord3) : + flatSmoothMode q h x=q (x 0)*mFourier h (torusAngles x) := by + rw [flatSmoothMode,angularFrequency_apply,mFourier_torusAngles] + +lemma flatSmoothMode_smooth {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (h : TorusModes) : ContDiff ℝ (↑(⊤:ℕ∞)) (flatSmoothMode q h) := + (hq.comp (contDiff_apply ℝ ℝ (0:Fin 3))).mul (angularFrequency h).contDiff.cexp + +lemma flatSmoothMode_periodic (q : ℝ → ℂ) (h : TorusModes) : + AngularPeriodic (2*Real.pi) (flatSmoothMode q h) := by + intro n x + rw [flatSmoothMode_eq,flatSmoothMode_eq,torusAngles_shift] + simp [angularShift] + +def smoothModePointJet (q : ℝ → ℂ) (h : TorusModes) (j : Fin 4) + (z : ℝ × UnitAddTorus (Fin 2)) : ℂ := + ![q z.1,deriv q z.1,(Complex.I*(h 0))*q z.1,(Complex.I*(h 1))*q z.1] j*mFourier h z.2 + +lemma flatSmoothMode_derivative {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (h : TorusModes) (x : Coord3) (j : Fin 3) : + fderiv ℝ (flatSmoothMode q h) x (Pi.single j 1)= + smoothModePointJet q h j.succ (x 0,torusAngles x) := by + have hq' := ((hq.differentiable (by simp) (x 0)).hasDerivAt.hasFDerivAt).comp x (f:=fun y : Coord3 => y 0) + ((ContinuousLinearMap.proj (R:=ℝ) (φ:=fun _ : Fin 3 => ℝ) 0).hasFDerivAt (x:=x)) + have he := ((angularFrequency h).hasFDerivAt (x:=x)).cexp + have hd := hq'.mul he + change HasFDerivAt (flatSmoothMode q h) _ x at hd + rw [hd.fderiv] + rw [smoothModePointJet,mFourier_torusAngles,←angularFrequency_apply] + fin_cases j <;> simp [angularFrequency] <;> ring + +lemma smoothCylinderModeJet_ae {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) (j : Fin 4) : + smoothCylinderModeJet hq R h j=ᵐ[(FiniteAxisMeasure R).prod volume] + smoothModePointJet q h j := by + have h1 := (Measure.quasiMeasurePreserving_fst + (μ:=FiniteAxisMeasure R) (ν:=(volume : Measure (UnitAddTorus (Fin 2))))).ae + (smoothAxisModeJet_ae hq R h j) + have h2 := (Measure.quasiMeasurePreserving_snd + (μ:=FiniteAxisMeasure R) (ν:=(volume : Measure (UnitAddTorus (Fin 2))))).ae + (coeFn_mFourierLp 2 h) + have hc : smoothCylinderModeJet hq R h j= + cylinderTensor (smoothAxisModeJet hq R h j) (mFourierLp 2 h) := by + fin_cases j <;> rfl + rw [hc] + filter_upwards [cylinderTensor_ae (smoothAxisModeJet hq R h j) (mFourierLp 2 h),h1,h2] + with z hz ht hθ + rw [hz,ht,hθ] + rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/TorusSpectralContinuation.lean b/lean/OAI/Analysis/Conductivity/Fourier/TorusSpectralContinuation.lean new file mode 100644 index 0000000000000000000000000000000000000000..c846d2d45dcf4f771643af2b7e4415413fd9eeac --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/TorusSpectralContinuation.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusCylinderGreenReal + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus + +lemma torusSpectralSynthesis_coeff (s : Fin 3 → ℝ) + (f : spectralTraceGraph (torusRate s)) (h : Fin 2 → ℤ) : + mFourierCoeff (torusSpectralSynthesis s f) h=f.val 0 h := by + rw [←mFourierBasis_repr] + change (mFourierBasis (d:=Fin 2)).repr ((mFourierBasis (d:=Fin 2)).repr.symm (f.val 0)) h=_ + rw [LinearIsometryEquiv.apply_symm_apply] + +lemma torusRealContinuation_spectral {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : spectralTraceGraph (torusRate s)) {x : Coord3} (hx : 0 simp [Matrix.mulVec,dotProduct, + angularLiftMatrix,Pi.single_apply] + +lemma angularLiftMatrix_transpose_normal (A : Matrix (Fin 2) (Fin 2) ℤ) : + (angularLiftMatrix A)ᵀ*ᵥPi.single 0 1=sqrt (angularNormalization A) • Pi.single 0 1 := by + ext i + fin_cases i <;> simp [Matrix.mulVec,dotProduct, + angularLiftMatrix,Pi.single_apply] + +lemma undoAngularTensor_normal {A : Matrix (Fin 2) (Fin 2) ℤ} + (θ : Fin 2 → ℝ) (d : ℝ) {E : Coord3 → Mat3} {x : Coord3} + (hE : E (undoAngularPoint A θ d x)*ᵥPi.single 0 1=Pi.single 0 1) : + undoAngularTensor A θ d E x*ᵥPi.single 0 1=Pi.single 0 1 := by + rw [undoAngularTensor,Matrix.smul_mulVec,←Matrix.mulVec_mulVec, + angularLiftMatrix_transpose_normal,←Matrix.mulVec_mulVec,Matrix.mulVec_smul,hE, + Matrix.mulVec_smul,angularLiftMatrix_normal,smul_smul,smul_smul] + rw [mul_assoc,←sq,sq_sqrt (angularNormalization_pos A).le, + inv_mul_cancel₀ (angularNormalization_pos A).ne',one_smul] + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix Real +open scoped Matrix.Norms.Elementwise + +theorem original_mode_finite_ending {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {h₀ : Fin 2 → ℤ} (hh₀ : h₀≠0) + {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0 := by + obtain ⟨k,Q,hk,hQ,he⟩ := leading_frequency_SL2_alignment hh₀ + let m := Real.sqrt (angularNormalization Q) + have hm : 0 < m := Real.sqrt_pos.mpr (angularNormalization_pos Q) + let e := angularFrequencyEquiv Q hQ + let θ : Fin 2 → ℝ := ![0,-pb h₀/(k:ℝ)] + let a' : (Fin 2 → ℤ) → ℝ := fun h => a (e.symm h)/m + let b' : (Fin 2 → ℤ) → ℝ := b ∘ e.symm + let pa' := angularShiftPhase (pa ∘ e.symm) θ + let pb' := angularShiftPhase (pb ∘ e.symm) θ + have hphase : pb' ![0,k]=0 := by + have he0 : e.symm ![0,k]=h₀ := by + rw [←he] + exact e.symm_apply_apply h₀ + dsimp [pb',angularShiftPhase] + rw [he0] + exact alignedPhaseTranslation_zero hk (pb h₀) + have hmode (x : Coord3) : + flatPhaseMode s h₀ (pb h₀) (angularNormalizedLift Q (angularRealTranslation θ x))= + flatPhaseMode (normalizedAngularTensor s Q) ![0,k] 0 x := by + rw [flatPhaseMode_angular_conjugacy s hQ,he,flatPhaseMode_angular_translation] + rw [show pb h₀+((![0,k] : Fin 2 → ℤ) 0:ℝ)*θ 0+ + ((![0,k] : Fin 2 → ℤ) 1:ℝ)*θ 1=0 from alignedPhaseTranslation_zero hk (pb h₀)] + have hab : ∀ h,|a' h|≤A/m := by + intro h + dsimp [a'] + rw [abs_div,abs_of_pos hm] + exact (div_le_div_iff_of_pos_right hm).2 (ha _) + have hbb : ∀ h,|b' h|≤B := fun h => hb (e.symm h) + have hgapA := angular_conjugacy_gap s hQ (a:=a) (lam:=0) hga + (fun h hh => by simpa only [zero_add] using hra h hh) + have hgapB := angular_conjugacy_gap s hQ hgb hrb + have hrate : torusRate (normalizedAngularTensor s Q) ![0,k]=m*torusRate s h₀ := by + rw [←he,torusRate_angular_conjugacy s hQ] + have hra' : ∀ h,a' h≠0 → m*ga≤torusRate (normalizedAngularTensor s Q) h := by + intro h hh + have hh' : (a ∘ e.symm) h≠0 := by + intro hz + apply hh + dsimp [a'] + rw [show a (e.symm h)=0 from hz,zero_div] + simpa only [mul_zero,zero_add] using hgapA.2 h hh' + have hrb' : ∀ h,b' h≠0 → torusRate (normalizedAngularTensor s Q) ![0,k]+m*gb≤ + torusRate (normalizedAngularTensor s Q) h := by + intro h hh + rw [hrate] + exact hgapB.2 h hh + obtain ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hv,hEm,hvp,hEp,⟨hsym,hreg⟩,hbound,hvin,hEin,hterm,_hrank,hG,hpde⟩ := + aligned_fourier_finite_ending (pa:=pa') + (normalizedAngularTensor_lower hs hQ) hk (div_nonneg hA hm.le) hB hab hbb + (mul_pos hm hga) (mul_pos hm hgb) hra' hrb' hphase hδ + refine ⟨Q,θ,k,hQ,hk,he,p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,?_,hEin,hterm,hreg,hG,hpde⟩ + intro x hx + rw [hvin x hx,hmode] + congr 1 + · congr 1 + rw [normalizedFourierCoefficients_div,flatFourier_div_coefficients] + congr 1 + simpa only [pa',e,Function.comp_def,mul_zero] using normalized_flatFourier_angular_conjugacy s hQ a pa 0 (10+1/p) θ x + · rw [hrate] + congr 2 + simpa only [b',pb',m,e,Function.comp_apply] using normalized_flatFourier_angular_conjugacy s hQ b pb (torusRate s h₀) (10+1/p) θ x + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Fourier/UndoAngularWeakPair.lean b/lean/OAI/Analysis/Conductivity/Fourier/UndoAngularWeakPair.lean new file mode 100644 index 0000000000000000000000000000000000000000..dfcf77f66c369dcad8f1b2ab577fc6d80608a6f0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Fourier/UndoAngularWeakPair.lean @@ -0,0 +1,153 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.LinearTensorEllipticity +import OAI.Analysis.Conductivity.Fourier.AngularInverseTensor + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix Real +open scoped Matrix.Norms.Elementwise + +def undoAngularOutput (A : Matrix (Fin 2) (Fin 2) ℤ) (d lam : ℝ) : + (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ) := + ContinuousLinearEquiv.piCongrRight (fun i : Fin 2 => + (LinearEquiv.smulOfNeZero ℝ ℝ + (if i=0 then sqrt (angularNormalization A) else exp (-lam*d)) + (by split_ifs; exact (sqrt_pos.mpr (angularNormalization_pos A)).ne'; exact exp_ne_zero _)).toContinuousLinearEquiv) + +@[simp] lemma undoAngularOutput_apply (A : Matrix (Fin 2) (Fin 2) ℤ) (d lam : ℝ) + (v : Fin 2 → ℝ) (i : Fin 2) : + undoAngularOutput A d lam v i= + (if i=0 then sqrt (angularNormalization A) else exp (-lam*d))*v i := rfl + +def undoAngularTranslation (A : Matrix (Fin 2) (Fin 2) ℤ) (θ : Fin 2 → ℝ) (d : ℝ) : Coord3 := + ![d,0,0]+angularNormalizedLift A ![0,θ 0,θ 1] + +lemma undoAngularPoint_eq_affine {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (θ : Fin 2 → ℝ) (d : ℝ) (x : Coord3) : + (angularNormalizedEquiv A hA).symm (x-undoAngularTranslation A θ d)= + undoAngularPoint A θ d x := by + unfold undoAngularTranslation + rw [←sub_sub,map_sub,angularNormalizedEquiv_symm_apply, + angularNormalizedEquiv_symm_apply,angularInverseLift_normalized hA] + rfl + +lemma undoAngular_domain {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (θ : Fin 2 → ℝ) (d : ℝ) : + ((fun x => x-undoAngularTranslation A θ d) ⁻¹' + ((angularNormalizedEquiv A hA).symm ⁻¹' {y : Coord3 | 0 simp [undoAngularValue] + +lemma undoAngular_E {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (θ : Fin 2 → ℝ) (d lam : ℝ) (w : WeakFiniteTensorPair {y : Coord3 | 0 (G y).col j) ψ x,hx] + _ = 0 := (hpde j ψ hψ hψs).2 } + exact ⟨Q,θ,hQ,p,T,hp,hpδ,hT,w,hvp,hEp,hvin,hEin,hterm,hnormal⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/AffineBoxPoincare.lean b/lean/OAI/Analysis/Conductivity/Geometry/AffineBoxPoincare.lean new file mode 100644 index 0000000000000000000000000000000000000000..b8c4d1d7b0f326078193b497caa64a3a72bc5071 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/AffineBoxPoincare.lean @@ -0,0 +1,155 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.UnitSquarePoincare + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory + +lemma unitCubeAverage_add {f g : Box3 → ℝ} (hf : Continuous f) (hg : Continuous g) : + unitCubeAverage (fun z => f z+g z)=unitCubeAverage f+unitCubeAverage g := by + dsimp [unitCubeAverage] + have hh (y : ℝ×ℝ) := unitAverage_add (f := fun x => f (y,x)) (g := fun x => g (y,x)) + (hf.comp (continuous_const.prodMk continuous_id)) (hg.comp (continuous_const.prodMk continuous_id)) + simp_rw [hh] + exact unitSquareAverage_add (continuous_unitAverage hf) (continuous_unitAverage hg) + +lemma unitCubeAverage_mul (c : ℝ) (f : Box3 → ℝ) : + unitCubeAverage (fun z => c*f z)=c*unitCubeAverage f := by + simp only [unitCubeAverage,unitAverage_mul,unitSquareAverage_mul] + +lemma unitCubeAverage_const (c : ℝ) : unitCubeAverage (fun _ => c)=c := by + simp only [unitCubeAverage,unitAverage_const,unitSquareAverage_const] + +lemma unitCubeAverage_mono {f g : Box3 → ℝ} (hf : Continuous f) (hg : Continuous g) + (h : ∀ z : Box3, f z ≤ g z) : unitCubeAverage f ≤ unitCubeAverage g := by + apply unitSquareAverage_mono (continuous_unitAverage hf) (continuous_unitAverage hg) + intro y hy x hx + apply unitAverage_mono (hf.comp (continuous_const.prodMk continuous_id)) + (hg.comp (continuous_const.prodMk continuous_id)) + intro t ht; exact h _ + +def boxRescale (a r : Box3) (z : Box3) : Box3 := + ((a.1.1+r.1.1*z.1.1,a.1.2+r.1.2*z.1.2),a.2+r.2*z.2) + +def boxAverage (a r : Box3) (f : Box3 → ℝ) : ℝ := + unitCubeAverage (fun z => f (boxRescale a r z)) + +lemma boxRescale_smooth (a r : Box3) : ContDiff ℝ (↑(⊤ : ℕ∞)) (boxRescale a r) := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun z : Box3 => + ((a.1.1+r.1.1*z.1.1,a.1.2+r.1.2*z.1.2),a.2+r.2*z.2)) + fun_prop + +lemma boxRescale_fderiv (a r z v : Box3) : + fderiv ℝ (boxRescale a r) z v=((r.1.1*v.1.1,r.1.2*v.1.2),r.2*v.2) := by + let D : Box3 →L[ℝ] Box3 := + ((r.1.1 • (ContinuousLinearMap.fst ℝ ℝ ℝ).comp (ContinuousLinearMap.fst ℝ (ℝ×ℝ) ℝ)).prod + (r.1.2 • (ContinuousLinearMap.snd ℝ ℝ ℝ).comp (ContinuousLinearMap.fst ℝ (ℝ×ℝ) ℝ))).prod + (r.2 • ContinuousLinearMap.snd ℝ (ℝ×ℝ) ℝ) + have he : boxRescale a r=fun z => a+D z := by rfl + rw [he,fderiv_const_add,D.fderiv] + rfl + +lemma box_partial_one {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a r z : Box3) : + cubePartial (f ∘ boxRescale a r) ((1,0),0) z= + r.1.1*cubePartial f ((1,0),0) (boxRescale a r z) := by + rw [cubePartial,fderiv_comp z (hf.differentiable (by simp) _) ((boxRescale_smooth a r).differentiable (by simp) _)] + change fderiv ℝ f (boxRescale a r z) (fderiv ℝ (boxRescale a r) z ((1,0),0)) = _ + rw [boxRescale_fderiv] + have he : ((r.1.1*(1:ℝ),r.1.2*0),r.2*0)=r.1.1 • (((1,0),0) : Box3) := by simp + rw [he,map_smul] + rfl + +lemma box_partial_two {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a r z : Box3) : + cubePartial (f ∘ boxRescale a r) ((0,1),0) z= + r.1.2*cubePartial f ((0,1),0) (boxRescale a r z) := by + rw [cubePartial,fderiv_comp z (hf.differentiable (by simp) _) ((boxRescale_smooth a r).differentiable (by simp) _)] + change fderiv ℝ f (boxRescale a r z) (fderiv ℝ (boxRescale a r) z ((0,1),0)) = _ + rw [boxRescale_fderiv] + have he : ((r.1.1*(0:ℝ),r.1.2*1),r.2*0)=r.1.2 • (((0,1),0) : Box3) := by simp + rw [he,map_smul] + rfl + +lemma box_partial_three {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a r z : Box3) : + cubePartial (f ∘ boxRescale a r) ((0,0),1) z= + r.2*cubePartial f ((0,0),1) (boxRescale a r z) := by + rw [cubePartial,fderiv_comp z (hf.differentiable (by simp) _) ((boxRescale_smooth a r).differentiable (by simp) _)] + change fderiv ℝ f (boxRescale a r z) (fderiv ℝ (boxRescale a r) z ((0,0),1)) = _ + rw [boxRescale_fderiv] + have he : ((r.1.1*(0:ℝ),r.1.2*0),r.2*1)=r.2 • (((0,0),1) : Box3) := by simp + rw [he,map_smul] + rfl + +theorem smooth_box_poincare {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a r : Box3) : + boxAverage a r (fun z => (f z-boxAverage a r f)^2) ≤ + 4*boxAverage a r (fun z => + r.1.1^2*(cubePartial f ((1,0),0) z)^2+ + r.1.2^2*(cubePartial f ((0,1),0) z)^2+ + r.2^2*(cubePartial f ((0,0),1) z)^2) := by + have h := smooth_unit_cube_poincare (hf.comp (boxRescale_smooth a r)) + change unitCubeAverage (fun z => (f (boxRescale a r z)-boxAverage a r f)^2) ≤ + 4*unitCubeAverage (fun z => _) at h + simpa only [box_partial_one hf,box_partial_two hf,box_partial_three hf,mul_pow,boxAverage] using h + +def closedBox (a r : Box3) : Set Box3 := + (Icc a.1.1 (a.1.1+r.1.1) ×ˢ Icc a.1.2 (a.1.2+r.1.2)) ×ˢ Icc a.2 (a.2+r.2) + +lemma isCompact_closedBox (a r : Box3) : IsCompact (closedBox a r) := + (isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc + +lemma unitSquareAverage_eq_integral {f : ℝ×ℝ → ℝ} (hf : Continuous f) : + unitSquareAverage f=∫ z in Icc (0:ℝ) 1 ×ˢ Icc (0:ℝ) 1, f z := by + exact (setIntegral_prod f (hf.continuousOn.integrableOn_compact + (isCompact_Icc.prod isCompact_Icc))).symm + +lemma unitCubeAverage_eq_integral {f : Box3 → ℝ} (hf : Continuous f) : + unitCubeAverage f=∫ z in (Icc (0:ℝ) 1 ×ˢ Icc (0:ℝ) 1) ×ˢ Icc (0:ℝ) 1, f z := by + rw [unitCubeAverage,unitSquareAverage_eq_integral (continuous_unitAverage hf)] + exact (setIntegral_prod f (hf.continuousOn.integrableOn_compact + ((isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc))).symm + +lemma unitAverage_comp_affine (f : ℝ → ℝ) (a : ℝ) {r : ℝ} (hr : 0 f (a+r*t))=r⁻¹*(∫ x in Icc a (a+r), f x) := by + rw [unitAverage_eq_interval] + have h := intervalIntegral.integral_comp_mul_add (a := 0) (b := 1) f hr.ne' a + simp only [mul_zero,mul_one,zero_add,smul_eq_mul] at h + rw [add_comm r a,intervalIntegral.integral_of_le (by linarith : a≤a+r), + ← integral_Icc_eq_integral_Ioc] at h + simpa only [add_comm a] using h + +lemma box_volume_integral_iterated {f : Box3 → ℝ} (hf : Continuous f) (a r : Box3) : + (∫ z in closedBox a r, f z)= + ∫ x in Icc a.1.1 (a.1.1+r.1.1), ∫ y in Icc a.1.2 (a.1.2+r.1.2), + ∫ t in Icc a.2 (a.2+r.2), f ((x,y),t) := by + have hc : Continuous (fun p : ℝ×ℝ => ∫ t in Icc a.2 (a.2+r.2), f (p,t)) := + continuous_parametric_integral_of_continuous (f := fun p t => f (p,t)) hf isCompact_Icc + calc + _ = ∫ p in Icc a.1.1 (a.1.1+r.1.1) ×ˢ Icc a.1.2 (a.1.2+r.1.2), + ∫ t in Icc a.2 (a.2+r.2), f (p,t) := + setIntegral_prod f (hf.continuousOn.integrableOn_compact (isCompact_closedBox a r)) + _ = _ := setIntegral_prod _ (hc.continuousOn.integrableOn_compact + (isCompact_Icc.prod isCompact_Icc)) + +lemma boxAverage_eq_integral {f : Box3 → ℝ} (hf : Continuous f) (a r : Box3) + (h₁ : 0 f ((a.1.1+r.1.1*v,a.1.2+r.1.2*w),t)) a.2 h₃ + have hy (v : ℝ) := unitAverage_comp_affine + (fun w => ∫ t in Icc a.2 (a.2+r.2), f ((a.1.1+r.1.1*v,w),t)) a.1.2 h₂ + have hz := unitAverage_comp_affine + (fun v => ∫ w in Icc a.1.2 (a.1.2+r.1.2), + ∫ t in Icc a.2 (a.2+r.2), f ((v,w),t)) a.1.1 h₁ + simp only [boxAverage,unitCubeAverage,unitSquareAverage,boxRescale] + simp_rw [hx,unitAverage_mul,hy,unitAverage_mul,hz] + rw [box_volume_integral_iterated hf,mul_inv,mul_inv] + ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinder.lean b/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinder.lean new file mode 100644 index 0000000000000000000000000000000000000000..0f3a39cbab4a28655e09a18679ccf84d3d19cf41 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinder.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CollarLpPullback +import OAI.Analysis.Conductivity.Variational.AxialDecayL2 + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +def affineEndTime (a b : ℝ) (t : ℝ) : ℝ := a*(t-b) + +def affineEndCoordinates (a b : ℝ) : ℝ×UnitAddTorus (Fin 2) → ℝ×UnitAddTorus (Fin 2) := + Prod.map (affineEndTime a b) id + +lemma measurable_affineEndTime (a b : ℝ) : Measurable (affineEndTime a b) := by + unfold affineEndTime; fun_prop + +lemma measurable_affineEndCoordinates (a b : ℝ) : Measurable (affineEndCoordinates a b) := + (measurable_affineEndTime a b).prodMap measurable_id + +lemma affineEndTime_volume {a : ℝ} (ha : a≠0) (b : ℝ) : + Measure.map (affineEndTime a b) volume=ENNReal.ofReal |a⁻¹| • volume := by + have he : affineEndTime a b=(fun t => a*t) ∘ (fun t : ℝ => t+(-b)) := by + funext t; simp [affineEndTime,sub_eq_add_neg] + rw [he,←Measure.map_map (f:=fun t : ℝ => t+(-b)) (g:=fun t : ℝ => a*t) + (by fun_prop) (by fun_prop),map_add_right_eq_self,Real.map_volume_mul_left ha] + +lemma affineEndTime_interval_le {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) : + Measure.map (affineEndTime a b) (volume.restrict (Ioc l r)) ≤ + ENNReal.ofReal |a⁻¹| • FiniteAxisMeasure R := by + have hS : Ioc l r⊆(affineEndTime a b) ⁻¹' Icc 0 R := fun t ht => hT t ⟨ht.1.le,ht.2⟩ + have hle : Measure.map (affineEndTime a b) (volume.restrict (Ioc l r)) ≤ + (Measure.map (affineEndTime a b) volume).restrict (Icc 0 R) := by + rw [Measure.restrict_map (measurable_affineEndTime a b) measurableSet_Icc] + exact Measure.map_mono (Measure.restrict_mono hS le_rfl) (measurable_affineEndTime a b) + have hcc : volume.restrict (Icc (0:ℝ) R)=FiniteAxisMeasure R := by + exact Measure.restrict_congr_set (Ioc_ae_eq_Icc' (measure_singleton (0:ℝ))).symm + rwa [affineEndTime_volume ha,Measure.restrict_smul,hcc] at hle + +lemma affineEndCoordinates_interval_le {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) : + Measure.map (affineEndCoordinates a b) (sourceCylinderMeasure l r) ≤ + ENNReal.ofReal |a⁻¹| • sourceCylinderMeasure 0 R := by + unfold sourceCylinderMeasure + rw [affineEndCoordinates,←Measure.map_prod_map _ _ (measurable_affineEndTime a b) measurable_id, + Measure.map_id,←Measure.prod_smul_left] + exact Measure.prod_mono (affineEndTime_interval_le ha hT) le_rfl + +def affineEndPullback {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) : + Lp ℂ 2 (sourceCylinderMeasure 0 R) →L[ℝ] Lp ℂ 2 (sourceCylinderMeasure l r) := + ((Lp.compMeasurePreservingₗᵢ ℝ (affineEndCoordinates a b) + ⟨measurable_affineEndCoordinates a b,rfl⟩).toContinuousLinearMap).comp + (Lp.LpToLpOfMeasureLeSMul ENNReal.ofReal_ne_top (affineEndCoordinates_interval_le ha hT)) + +lemma affineEndPullback_ae {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (f : Lp ℂ 2 (sourceCylinderMeasure 0 R)) : + affineEndPullback ha hT f=ᵐ[sourceCylinderMeasure l r] f ∘ affineEndCoordinates a b := by + have h0 := Lp.coeFn_LpToLpOfMeasureLeSMul ENNReal.ofReal_ne_top + (affineEndCoordinates_interval_le ha hT) f + have h1 := Lp.coeFn_compMeasurePreserving + (Lp.LpToLpOfMeasureLeSMul ENNReal.ofReal_ne_top (affineEndCoordinates_interval_le ha hT) f) + (show MeasurePreserving (affineEndCoordinates a b) (sourceCylinderMeasure l r) + (Measure.map (affineEndCoordinates a b) (sourceCylinderMeasure l r)) from + ⟨measurable_affineEndCoordinates a b,rfl⟩) + exact h1.trans ((show Measure.QuasiMeasurePreserving (affineEndCoordinates a b) (sourceCylinderMeasure l r) + (Measure.map (affineEndCoordinates a b) (sourceCylinderMeasure l r)) from + ⟨measurable_affineEndCoordinates a b,Measure.absolutelyContinuous_rfl⟩).ae_eq_comp h0) + +lemma affineEndPullback_ae_of_ae {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (f : Lp ℂ 2 (sourceCylinderMeasure 0 R)) {g : ℝ×UnitAddTorus (Fin 2) → ℂ} + (hg : f=ᵐ[sourceCylinderMeasure 0 R] g) : + affineEndPullback ha hT f=ᵐ[sourceCylinderMeasure l r] g ∘ affineEndCoordinates a b := by + apply (affineEndPullback_ae ha hT f).trans + have hq : Measure.QuasiMeasurePreserving (affineEndCoordinates a b) (sourceCylinderMeasure l r) + (sourceCylinderMeasure 0 R) := + ⟨measurable_affineEndCoordinates a b, + Measure.absolutelyContinuous_of_le_smul (affineEndCoordinates_interval_le ha hT)⟩ + exact hq.ae_eq_comp hg + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinderIntegral.lean b/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinderIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2a2b71dc0e970b2fb24641a4a03615333ba3113 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/AffineCylinderIntegral.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.AffineCylinder + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal +local instance affineCylinderIntegralMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance affineCylinderIntegralProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma integrable_affineEndCoordinates {a b l r R : ℝ} (ha : a≠0) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + {F : ℝ × UnitAddTorus (Fin 2) → ℝ} + (hF : Integrable F ((FiniteAxisMeasure R).prod volume)) : + Integrable (F ∘ affineEndCoordinates a b) ((volume.restrict (Ioc l r)).prod volume) := by + have hle := affineEndCoordinates_interval_le ha hT + have hν : sourceCylinderMeasure 0 R=(FiniteAxisMeasure R).prod volume := by + rfl + have hμ : sourceCylinderMeasure l r=(volume.restrict (Ioc l r)).prod volume := by + rfl + rw [hν,hμ] at hle + have h := (hF.smul_measure (c:=ENNReal.ofReal |a⁻¹|) ENNReal.ofReal_ne_top).mono_measure hle + exact (integrable_map_measure h.aestronglyMeasurable + (measurable_affineEndCoordinates a b).aemeasurable).mp h + +lemma integral_affineEndCoordinates_pos {a b l r R : ℝ} (ha : 0 F (affineEndCoordinates a b z)) hg,integral_prod F hF,abs_of_pos ha, + ←intervalIntegral.integral_of_le hlr,←intervalIntegral.integral_of_le hR] + have he : (fun t => ∫ θ,F (affineEndCoordinates a b (t,θ)))= + (fun t => (fun u => ∫ θ,F (u,θ)) (a*t-a*b)) := by + funext t + simp only [affineEndCoordinates,Prod.map_apply,affineEndTime,id_eq] + rw [mul_sub] + rw [he] + change a • (∫ t in l..r,(fun u => ∫ θ,F (u,θ)) (a*t-a*b))=_ + rw [intervalIntegral.smul_integral_comp_mul_sub (fun u => ∫ θ,F (u,θ)) a (a*b)] + rw [←mul_sub,←mul_sub,hl,hr] + +lemma integral_affineEndCoordinates_neg {a b l r R : ℝ} (ha : a<0) (hlr : l≤r) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (hl : a*(l-b)=R) (hr : a*(r-b)=0) (hR : 0≤R) + {F : ℝ × UnitAddTorus (Fin 2) → ℝ} + (hF : Integrable F ((FiniteAxisMeasure R).prod volume)) : + |a| *(∫ z,F (affineEndCoordinates a b z) ∂(volume.restrict (Ioc l r)).prod volume)= + ∫ z,F z ∂(FiniteAxisMeasure R).prod volume := by + have hg := integrable_affineEndCoordinates ha.ne hT hF + rw [integral_prod (fun z => F (affineEndCoordinates a b z)) hg,integral_prod F hF,abs_of_neg ha, + ←intervalIntegral.integral_of_le hlr,←intervalIntegral.integral_of_le hR] + have he : (fun t => ∫ θ,F (affineEndCoordinates a b (t,θ)))= + (fun t => (fun u => ∫ θ,F (u,θ)) (a*t-a*b)) := by + funext t + simp only [affineEndCoordinates,Prod.map_apply,affineEndTime,id_eq] + rw [mul_sub] + rw [he,neg_mul] + change -(a • (∫ t in l..r,(fun u => ∫ θ,F (u,θ)) (a*t-a*b)))=_ + rw [intervalIntegral.smul_integral_comp_mul_sub (fun u => ∫ θ,F (u,θ)) a (a*b)] + rw [←mul_sub,←mul_sub,hl,hr,intervalIntegral.integral_symm,neg_neg] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/BoxCoordinateBridge.lean b/lean/OAI/Analysis/Conductivity/Geometry/BoxCoordinateBridge.lean new file mode 100644 index 0000000000000000000000000000000000000000..8af180f93a382956c145db555f74b76d34813078 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/BoxCoordinateBridge.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.SynchronizedChartWaves +import OAI.Analysis.Conductivity.Geometry.BoxIteration + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +def boxCoordinates : Coord3 ≃L[ℝ] Box3 := + (show Coord3 ≃ₗ[ℝ] Box3 from + { toFun := fun x => ((x 0,x 1),x 2) + invFun := fun p => ![p.1.1,p.1.2,p.2] + left_inv := by intro x; ext i; fin_cases i <;> rfl + right_inv := by intro p; rfl + map_add' := by intro x y; rfl + map_smul' := by intro r x; rfl }).toContinuousLinearEquiv + +lemma boxCoordinates_apply (x : Coord3) : boxCoordinates x=((x 0,x 1),x 2) := rfl +lemma boxCoordinates_symm_apply (p : Box3) : boxCoordinates.symm p=![p.1.1,p.1.2,p.2] := rfl + +lemma boxCoordinates_volume : MeasurePreserving boxCoordinates := by + exact (volume_preserving_prodAssoc.symm (MeasurableEquiv.prodAssoc : Box3≃ᵐ ℝ×(ℝ×ℝ))).comp + threeArrow_volume + +lemma boxCoordinates_integral (f : Box3 → ℝ) : + (∫ x,f (boxCoordinates x))=(∫ p,f p) := + boxCoordinates_volume.integral_comp boxCoordinates.toHomeomorph.measurableEmbedding f + +lemma boxCoordinates_integral_symm (f : Coord3 → ℝ) : + (∫ p,f (boxCoordinates.symm p))=(∫ x,f x) := by + have h := boxCoordinates_integral (fun p => f (boxCoordinates.symm p)) + simpa only [boxCoordinates.symm_apply_apply] using h.symm + +lemma boxCoordinates_fderiv (f : Box3 → ℝ) (hf : Differentiable ℝ f) + (x v : Coord3) : + fderiv ℝ (f∘boxCoordinates) x v=fderiv ℝ f (boxCoordinates x) (boxCoordinates v) := by + rw [fderiv_comp x (hf _) boxCoordinates.differentiableAt] + have he : fderiv ℝ (fun x => boxCoordinates x) x=boxCoordinates.toContinuousLinearMap := + boxCoordinates.toContinuousLinearMap.hasFDerivAt.fderiv + rw [he] + rfl + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/BoxEnergyPoincare.lean b/lean/OAI/Analysis/Conductivity/Geometry/BoxEnergyPoincare.lean new file mode 100644 index 0000000000000000000000000000000000000000..f6c77a64db8fa9f0815612eea155b586530dafa8 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/BoxEnergyPoincare.lean @@ -0,0 +1,228 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.RectangularTorusAtlas +import OAI.Analysis.Conductivity.Geometry.AffineBoxPoincare +import OAI.Analysis.Conductivity.Variational.OverlapPoincare + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory + +def cubeEnergyDensity (f : Box3 → ℝ) (z : Box3) : ℝ := + (cubePartial f ((1,0),0) z)^2+(cubePartial f ((0,1),0) z)^2+ + (cubePartial f ((0,0),1) z)^2 + +lemma continuous_cubeEnergyDensity {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : Continuous (cubeEnergyDensity f) := + (((continuous_cubePartial hf _).pow 2).add ((continuous_cubePartial hf _).pow 2)).add + ((continuous_cubePartial hf _).pow 2) + +lemma cubeEnergyDensity_nonneg (f : Box3 → ℝ) (z : Box3) : 0≤cubeEnergyDensity f z := by + unfold cubeEnergyDensity; positivity + +theorem smooth_box_volume_poincare {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a r : Box3) + (h₁ : 0 r.1.1^2*(cubePartial f ((1,0),0) z)^2+ + r.1.2^2*(cubePartial f ((0,1),0) z)^2+r.2^2*(cubePartial f ((0,0),1) z)^2 + have he : Continuous e := + ((continuous_const.mul ((continuous_cubePartial hf _).pow 2)).add + (continuous_const.mul ((continuous_cubePartial hf _).pow 2))).add + (continuous_const.mul ((continuous_cubePartial hf _).pow 2)) + have hP := smooth_box_poincare hf a r + rw [boxAverage_eq_integral (f := fun z => (f z-boxAverage a r f)^2) ((hf.continuous.sub continuous_const).pow 2) a r h₁ h₂ h₃, + boxAverage_eq_integral (f := e) he a r h₁ h₂ h₃] at hP + have hV : 0 R*cubeEnergyDensity f z) + (he.continuousOn.integrableOn_compact (isCompact_closedBox a r)) + ((continuous_const.mul (continuous_cubeEnergyDensity hf)).continuousOn.integrableOn_compact + (isCompact_closedBox a r)) + (fun z => show e z ≤ R*cubeEnergyDensity f z by + dsimp [e,R,cubeEnergyDensity] + have hx := mul_nonneg (sq_nonneg r.1.1) + (add_nonneg (sq_nonneg (cubePartial f ((0,1),0) z)) (sq_nonneg (cubePartial f ((0,0),1) z))) + have hy := mul_nonneg (sq_nonneg r.1.2) + (add_nonneg (sq_nonneg (cubePartial f ((1,0),0) z)) (sq_nonneg (cubePartial f ((0,0),1) z))) + have ht := mul_nonneg (sq_nonneg r.2) + (add_nonneg (sq_nonneg (cubePartial f ((1,0),0) z)) (sq_nonneg (cubePartial f ((0,1),0) z))) + nlinarith) + rw [integral_const_mul] at hi + change _ ≤ 4*R*(∫ z in closedBox a r, cubeEnergyDensity f z) + nlinarith + +structure RectFootprint where + xl : ℝ + xu : ℝ + yl : ℝ + yu : ℝ + +def RectFootprint.carrier (Q : RectFootprint) : Set (ℝ×ℝ) := + Icc Q.xl Q.xu ×ˢ Icc Q.yl Q.yu + +def RectFootprint.inter (Q R : RectFootprint) : RectFootprint := + ⟨max Q.xl R.xl,min Q.xu R.xu,max Q.yl R.yl,min Q.yu R.yu⟩ + +lemma RectFootprint.inter_carrier (Q R : RectFootprint) : + (Q.inter R).carrier=Q.carrier∩R.carrier := by + ext z + simp only [RectFootprint.carrier,RectFootprint.inter,mem_prod,mem_Icc,mem_inter_iff, + max_le_iff,le_min_iff] + tauto + +def RectFootprint.prism (Q : RectFootprint) (lo hi : ℝ) : Set Box3 := + Q.carrier ×ˢ Icc lo hi + +lemma RectFootprint.prism_closedBox (Q : RectFootprint) (lo hi : ℝ) : + Q.prism lo hi = closedBox ((Q.xl,Q.yl),lo) ((Q.xu-Q.xl,Q.yu-Q.yl),hi-lo) := by + simp [RectFootprint.prism,RectFootprint.carrier,closedBox] + +lemma RectFootprint.prism_compact (Q : RectFootprint) (lo hi : ℝ) : + IsCompact (Q.prism lo hi) := (isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc + +def centralThickness : ℝ := 1/1000 +def centralOuterX : ℝ := sourceLength*(1-sourceRadialWidth*centralThickness) +def centralInnerX : ℝ := sourceLength*(sourceHole+sourceRadialWidth*centralThickness) +def centralOuterY : ℝ := 1-sourceRadialWidth*centralThickness +def centralInnerY : ℝ := sourceHole+sourceRadialWidth*centralThickness +def centralHeight : ℝ := 1-centralThickness +def centralChildHeight : ℝ := sourceScale*(1+centralThickness) +def centralChildOuterX : ℝ := sourceScale*(1+sourceRadialWidth*centralThickness) +def centralChildOuterY : ℝ := sourceScale*sourceLength*(1+sourceRadialWidth*centralThickness) +def centralChildInnerX : ℝ := sourceScale*(sourceHole-sourceRadialWidth*centralThickness) +def centralChildInnerY : ℝ := sourceScale*sourceLength*(sourceHole-sourceRadialWidth*centralThickness) + +def centralParentStrip (i : Fin 4) : RectFootprint := + ![⟨centralInnerX,centralOuterX,-centralOuterY,centralOuterY⟩, + ⟨-centralOuterX,centralOuterX,centralInnerY,centralOuterY⟩, + ⟨-centralOuterX,-centralInnerX,-centralOuterY,centralOuterY⟩, + ⟨-centralOuterX,centralOuterX,-centralOuterY,-centralInnerY⟩] i + +def centralChildOption (σ : ℝ) (k : Fin 5) : RectFootprint := + ![⟨σ*sourceOffset+centralChildOuterX,centralOuterX,-centralOuterY,centralOuterY⟩, + ⟨-centralOuterX,centralOuterX,centralChildOuterY,centralOuterY⟩, + ⟨-centralOuterX,σ*sourceOffset-centralChildOuterX,-centralOuterY,centralOuterY⟩, + ⟨-centralOuterX,centralOuterX,-centralOuterY,-centralChildOuterY⟩, + ⟨σ*sourceOffset-centralChildInnerX,σ*sourceOffset+centralChildInnerX, + -centralChildInnerY,centralChildInnerY⟩] k + +def centralParentFootprint (z : ℝ×ℝ) : Prop := + |z.1| ≤ centralOuterX ∧ |z.2| ≤ centralOuterY ∧ + (centralInnerX ≤ |z.1| ∨ centralInnerY ≤ |z.2|) + +def centralAvoidChild (σ : ℝ) (z : ℝ×ℝ) : Prop := + centralChildOuterX ≤ |z.1-σ*sourceOffset| ∨ centralChildOuterY ≤ |z.2| ∨ + (|z.1-σ*sourceOffset| ≤ centralChildInnerX ∧ |z.2| ≤ centralChildInnerY) + +lemma centralParentStrip_mem {z : ℝ×ℝ} : + (∃ i,z∈(centralParentStrip i).carrier) ↔ centralParentFootprint z := by + simp only [centralParentStrip,Fin.exists_fin_succ,Matrix.cons_val_zero,Matrix.cons_val_succ, + Fin.exists_fin_zero,or_false,RectFootprint.carrier,mem_prod,mem_Icc, + centralParentFootprint,abs_le,le_abs] + have hx : 0 ≤ centralInnerX ∧ centralInnerX ≤ centralOuterX := by + norm_num [centralInnerX,centralOuterX,sourceLength,sourceHole,sourceRadialWidth,centralThickness] + have hy : 0 ≤ centralInnerY ∧ centralInnerY ≤ centralOuterY := by + norm_num [centralInnerY,centralOuterY,sourceHole,sourceRadialWidth,centralThickness] + constructor + · rintro (h|h|h|h) + · exact ⟨⟨by linarith [h.1.1],h.1.2⟩,h.2,Or.inl (Or.inl h.1.1)⟩ + · exact ⟨h.1,⟨by linarith [h.2.1],h.2.2⟩,Or.inr (Or.inl h.2.1)⟩ + · exact ⟨⟨h.1.1,by linarith [h.1.2]⟩,h.2,Or.inl (Or.inr (by linarith [h.1.2]))⟩ + · exact ⟨h.1,⟨h.2.1,by linarith [h.2.2]⟩,Or.inr (Or.inr (by linarith [h.2.2]))⟩ + · intro hp + rcases hp.2.2 with (h|h)|(h|h) + · left; exact ⟨⟨h,hp.1.2⟩,hp.2.1⟩ + · right; right; left; exact ⟨⟨hp.1.1,by linarith⟩,hp.2.1⟩ + · right; left; exact ⟨hp.1,⟨h,hp.2.1.2⟩⟩ + · right; right; right; exact ⟨hp.1,⟨hp.2.1.1,by linarith⟩⟩ + +lemma centralChildOption_mem {σ : ℝ} {z : ℝ×ℝ} + (hbox : |z.1| ≤ centralOuterX ∧ |z.2| ≤ centralOuterY) : + (∃ k,z∈(centralChildOption σ k).carrier) ↔ centralAvoidChild σ z := by + simp only [centralChildOption,Fin.exists_fin_succ,Matrix.cons_val_zero,Matrix.cons_val_succ, + Fin.exists_fin_zero,or_false,RectFootprint.carrier,mem_prod,mem_Icc, + centralAvoidChild,abs_le,le_abs] + have hx := abs_le.mp hbox.1 + have hy := abs_le.mp hbox.2 + constructor + · rintro (h|h|h|h|h) + · exact Or.inl (Or.inl (by linarith [h.1.1])) + · exact Or.inr (Or.inl (Or.inl h.2.1)) + · exact Or.inl (Or.inr (by linarith [h.1.2])) + · exact Or.inr (Or.inl (Or.inr (by linarith [h.2.2]))) + · exact Or.inr (Or.inr ⟨⟨by linarith [h.1.1],by linarith [h.1.2]⟩,h.2⟩) + · rintro ((h|h)|(h|h)|h) + · exact Or.inl ⟨⟨by linarith,hx.2⟩,hy⟩ + · exact Or.inr (Or.inr (Or.inl ⟨⟨hx.1,by linarith⟩,hy⟩)) + · exact Or.inr (Or.inl ⟨hx,⟨h,hy.2⟩⟩) + · exact Or.inr (Or.inr (Or.inr (Or.inl ⟨hx,⟨hy.1,by linarith⟩⟩))) + · exact Or.inr (Or.inr (Or.inr (Or.inr ⟨⟨by linarith [h.1.1],by linarith [h.1.2]⟩,h.2⟩))) + +def centralColumn (i : Fin 4) (j k : Fin 5) : RectFootprint := + ((centralParentStrip i).inter (centralChildOption 1 j)).inter (centralChildOption (-1) k) + +lemma centralColumn_cover {z : ℝ×ℝ} : + (∃ i j k,z∈(centralColumn i j k).carrier) ↔ + centralParentFootprint z ∧ centralAvoidChild 1 z ∧ centralAvoidChild (-1) z := by + simp only [centralColumn,RectFootprint.inter_carrier,mem_inter_iff] + constructor + · rintro ⟨i,j,k,⟨hp,hj⟩,hk⟩ + have hh := centralParentStrip_mem.mp ⟨i,hp⟩ + exact ⟨hh,(centralChildOption_mem ⟨hh.1,hh.2.1⟩).mp ⟨j,hj⟩, + (centralChildOption_mem ⟨hh.1,hh.2.1⟩).mp ⟨k,hk⟩⟩ + · rintro ⟨hp,hj,hk⟩ + obtain ⟨i,hi⟩ := centralParentStrip_mem.mpr hp + obtain ⟨j,hj⟩ := (centralChildOption_mem ⟨hp.1,hp.2.1⟩).mpr hj + obtain ⟨k,hk⟩ := (centralChildOption_mem ⟨hp.1,hp.2.1⟩).mpr hk + exact ⟨i,j,k,⟨hi,hj⟩,hk⟩ + +def centralClosed : Set Box3 := {z | centralParentFootprint z.1 ∧ |z.2| ≤ centralHeight ∧ + (centralChildHeight ≤ |z.2| ∨ (centralAvoidChild 1 z.1 ∧ centralAvoidChild (-1) z.1))} + +def centralTop (i : Fin 4) : Set Box3 := + (centralParentStrip i).prism centralChildHeight centralHeight + +def centralBottom (i : Fin 4) : Set Box3 := + (centralParentStrip i).prism (-centralHeight) (-centralChildHeight) + +theorem centralClosed_cover : centralClosed = + (⋃ i,centralTop i) ∪ (⋃ i,centralBottom i) ∪ + ⋃ i : Fin 4,⋃ j : Fin 5,⋃ k : Fin 5,(centralColumn i j k).prism (-centralHeight) centralHeight := by + ext z + simp only [centralClosed,mem_ofPred_eq,mem_union,mem_iUnion,centralTop,centralBottom, + RectFootprint.prism,mem_prod,mem_Icc] + constructor + · rintro ⟨hp,hz,ht|⟨hj,hk⟩⟩ + · obtain ⟨i,hi⟩ := centralParentStrip_mem.mpr hp + have hb := abs_le.mp hz + rcases le_abs.mp ht with h|h + · exact Or.inl (Or.inl ⟨i,hi,h,hb.2⟩) + · exact Or.inl (Or.inr ⟨i,hi,hb.1,by linarith⟩) + · obtain ⟨i,j,k,hh⟩ := centralColumn_cover.mpr ⟨hp,hj,hk⟩ + exact Or.inr ⟨i,j,k,hh,abs_le.mp hz⟩ + · rintro ((⟨i,hi,hz⟩|⟨i,hi,hz⟩)|⟨i,j,k,hi,hz⟩) + · refine ⟨centralParentStrip_mem.mp ⟨i,hi⟩,abs_le.mpr ⟨?_,hz.2⟩,Or.inl (le_abs.mpr (Or.inl hz.1))⟩ + have hh : 0 ≤ centralChildHeight+centralHeight := by norm_num [centralChildHeight,centralHeight,sourceScale,centralThickness] + linarith + · refine ⟨centralParentStrip_mem.mp ⟨i,hi⟩,abs_le.mpr ⟨hz.1,?_⟩,Or.inl (le_abs.mpr (Or.inr (by linarith [hz.2])))⟩ + have hh : 0 ≤ centralChildHeight+centralHeight := by norm_num [centralChildHeight,centralHeight,sourceScale,centralThickness] + linarith + · have hh := centralColumn_cover.mp ⟨i,j,k,hi⟩ + exact ⟨hh.1,abs_le.mpr hz,Or.inr hh.2⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/BoxIteration.lean b/lean/OAI/Analysis/Conductivity/Geometry/BoxIteration.lean new file mode 100644 index 0000000000000000000000000000000000000000..cfd6c609cb172fae7157c5b6d210c6915b8d3fd7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/BoxIteration.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ExtendedCollar + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +def threeArrow : (Fin 3 → ℝ) ≃ᵐ ℝ×(ℝ×ℝ) := + (MeasurableEquiv.piFinSuccAbove (fun _ : Fin 3 => ℝ) 0).trans + ((MeasurableEquiv.refl ℝ).prodCongr (MeasurableEquiv.finTwoArrow)) + +lemma threeArrow_apply (x : Fin 3 → ℝ) : threeArrow x=(x 0,x 1,x 2) := by rfl +lemma threeArrow_symm_apply (x : ℝ×(ℝ×ℝ)) : threeArrow.symm x=![x.1,x.2.1,x.2.2] := by + ext i; fin_cases i <;> rfl + +lemma threeArrow_volume : MeasurePreserving threeArrow := by + exact ((MeasurePreserving.id volume).prod (volume_preserving_finTwoArrow ℝ)).comp + (volume_preserving_piFinSuccAbove (fun _ : Fin 3 => ℝ) 0) + +lemma sourceExtendedBox_image (l r : ℝ) : + threeArrow '' sourceExtendedBox l r=Icc l r ×ˢ (Icc (-1:ℝ) 1 ×ˢ Icc (-1:ℝ) 1) := by + ext z + rw [MeasurableEquiv.image_eq_preimage_symm] + simp [threeArrow_symm_apply,mem_sourceExtendedBox,abs_le,Prod.le_def] + tauto + +lemma integral_sourceExtendedBox {g : (Fin 3 → ℝ) → ℝ} (hg : Continuous g) + {l r : ℝ} (hlr : l≤r) : + (∫ x in sourceExtendedBox l r,g x)= + ∫ t in l..r,∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1,g ![t,a,b] := by + have hc : Continuous (fun z : ℝ×(ℝ×ℝ) => g ![z.1,z.2.1,z.2.2]) := hg.comp (by fun_prop) + have hi := hc.continuousOn.integrableOn_compact (μ:=volume) + (isCompact_Icc.prod (isCompact_Icc.prod isCompact_Icc) : + IsCompact (Icc l r ×ˢ (Icc (-1:ℝ) 1 ×ˢ Icc (-1:ℝ) 1))) + have he := threeArrow_volume.setIntegral_image_emb threeArrow.measurableEmbedding + (fun z : ℝ×(ℝ×ℝ) => g ![z.1,z.2.1,z.2.2]) (sourceExtendedBox l r) + simp only [threeArrow_apply] at he + have hid (x : Fin 3 → ℝ) : ![x 0,x 1,x 2]=x := by ext i; fin_cases i <;> rfl + simp_rw [hid] at he + have him := sourceExtendedBox_image l r + simp only [threeArrow_apply] at him + rw [←he,him] + change (∫ y in Icc l r ×ˢ (Icc (-1:ℝ) 1 ×ˢ Icc (-1:ℝ) 1), + g ![y.1,y.2.1,y.2.2] ∂volume.prod volume)=_ + rw [setIntegral_prod _ hi] + simp_rw [intervalIntegral.integral_of_le hlr, + intervalIntegral.integral_of_le (by norm_num : (-1:ℝ)≤1),←integral_Icc_eq_integral_Ioc] + apply setIntegral_congr_fun measurableSet_Icc + intro t ht + exact setIntegral_prod _ ((hc.comp (continuous_const.prodMk continuous_id)).continuousOn.integrableOn_compact + (isCompact_Icc.prod isCompact_Icc)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/BoxMomentRightInverse.lean b/lean/OAI/Analysis/Conductivity/Geometry/BoxMomentRightInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..b02954ef6e4cf98816c632ae1b4b11c520795e26 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/BoxMomentRightInverse.lean @@ -0,0 +1,187 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactRegularCorrection +import OAI.Analysis.Conductivity.Flux.CompactInteriorDivergence +import OAI.Analysis.Conductivity.Variational.FiniteMomentTransfer + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +lemma exists_unit_global_interval_bump {a b : ℝ} (hab : a ht ⟨(hv hh).1,(hv hh).2.le⟩) + rwa [he] at hi + +lemma exists_unit_box_bump {a b : Fin 3 → ℝ} (hab : ∀ i,a i (η₁ p.1.1*η₂ p.1.2)*η₃ p.2 + have hK : ContDiff ℝ (↑(⊤ : ℕ∞)) K := + ((h₁.comp (contDiff_fst.comp contDiff_fst)).mul + (h₂.comp (contDiff_snd.comp contDiff_fst))).mul (h₃.comp contDiff_snd) + have hsK : HasCompactSupport K := by + apply HasCompactSupport.of_support_subset_isCompact ((hs₁.prod hs₂).prod hs₃) + intro p hp + have hh := mul_ne_zero_iff.mp hp + have hh' := mul_ne_zero_iff.mp hh.1 + exact ⟨⟨subset_tsupport η₁ hh'.1,subset_tsupport η₂ hh'.2⟩,subset_tsupport η₃ hh.2⟩ + have htK : tsupport K⊆(tsupport η₁ ×ˢ tsupport η₂) ×ˢ tsupport η₃ := by + apply closure_minimal _ ((hs₁.isClosed.prod hs₂.isClosed).prod hs₃.isClosed) + intro p hp + have hh := mul_ne_zero_iff.mp hp + have hh' := mul_ne_zero_iff.mp hh.1 + exact ⟨⟨subset_tsupport η₁ hh'.1,subset_tsupport η₂ hh'.2⟩,subset_tsupport η₃ hh.2⟩ + refine ⟨K,hK,hsK,htK.trans (prod_mono (prod_mono hv₁ hv₂) hv₃),?_⟩ + change (∫ p : (ℝ×ℝ)×ℝ,(η₁ p.1.1*η₂ p.1.2)*η₃ p.2)=1 + rw [Measure.volume_eq_prod,integral_prod_mul (fun p : ℝ×ℝ => η₁ p.1*η₂ p.2) η₃, + Measure.volume_eq_prod,integral_prod_mul η₁ η₂,hi₁,hi₂,hi₃] + norm_num + +lemma cubePartial_integral_zero {K : Box3 → ℝ} + (hK : ContDiff ℝ (↑(⊤ : ℕ∞)) K) (hs : HasCompactSupport K) (v : Box3) : + (∫ p,cubePartial K v p)=0 := by + have hh := cube_integration_by_parts (f := fun _ => (1:ℝ)) contDiff_const hK hs v + simpa [cubePartial] using hh + +theorem box_moment_right_inverse {a b : Fin 3 → ℝ} (hab : ∀ i,a i m 0*K p+c*D p + let r₂ := fun p => m 1*K p + have hD : ContDiff ℝ (↑(⊤ : ℕ∞)) D := cubePartial_smooth hK _ + have hsD : HasCompactSupport D := cubePartial_compact hs _ + have hvD : tsupport D⊆(Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2) := + (cubePartial_tsupport _).trans hv + have iK : Integrable K := hK.continuous.integrable_of_hasCompactSupport hs + have iD : Integrable D := hD.continuous.integrable_of_hasCompactSupport hsD + have hDz : (∫ p,D p)=0 := cubePartial_integral_zero hK hs _ + have hf₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun p : Box3 => p.1.1) := contDiff_fst.comp contDiff_fst + have hf₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun p : Box3 => p.1.2) := contDiff_snd.comp contDiff_fst + have hDm : (∫ p : Box3,p.1.2*D p)= -1 := by + have hh := cube_integration_by_parts hf₂ hK hs ((0,1),0) + simpa only [cubePartial_snd_fst,one_mul,hi] using hh + have iK₁ : Integrable (fun p : Box3 => p.1.1*K p) := + (hf₁.continuous.mul hK.continuous).integrable_of_hasCompactSupport hs.mul_left + have iK₂ : Integrable (fun p : Box3 => p.1.2*K p) := + (hf₂.continuous.mul hK.continuous).integrable_of_hasCompactSupport hs.mul_left + have iD₂ : Integrable (fun p : Box3 => p.1.2*D p) := + (hf₂.continuous.mul hD.continuous).integrable_of_hasCompactSupport hsD.mul_left + refine ⟨r₁,r₂,(contDiff_const.mul hK).add (contDiff_const.mul hD), + contDiff_const.mul hK,(hs.mul_left).add hsD.mul_left,hs.mul_left,?_,?_,?_,?_,?_⟩ + · exact (tsupport_add _ _).trans (union_subset + (tsupport_mul_subset_right.trans hv) (tsupport_mul_subset_right.trans hvD)) + · exact tsupport_mul_subset_right.trans hv + · dsimp only [r₁] + rw [integral_add (iK.const_mul _) (iD.const_mul _),integral_const_mul,integral_const_mul,hi,hDz] + ring + · dsimp only [r₂] + rw [integral_const_mul,hi,mul_one] + · have he : (fun p : Box3 => p.1.2*r₁ p-p.1.1*r₂ p)= + (fun p => m 0*(p.1.2*K p)+c*(p.1.2*D p)-m 1*(p.1.1*K p)) := by + funext p; dsimp only [r₁,r₂]; ring + have iKD : Integrable (fun p : Box3 => m 0*(p.1.2*K p)+c*(p.1.2*D p)) := + (iK₂.const_mul _).add (iD₂.const_mul _) + rw [he,integral_sub iKD (iK₁.const_mul _), + integral_add (iK₂.const_mul _) (iD₂.const_mul _),integral_const_mul,integral_const_mul, + integral_const_mul,hDm] + dsimp only [c] + ring + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory + +theorem box_moment_bounded_right_inverse {a b : Fin 3 → ℝ} (hab : ∀ i,a i ∑ i,m i*g i j p) p‖≤B*‖m‖) := by + choose g₀ g₁ hg₀ hg₁ hs₀ hs₁ hv₀ hv₁ hi₀ hi₁ hit using + fun i : Fin 3 => box_moment_right_inverse hab (Pi.single i 1) + let g : Fin 3 → Fin 2 → Box3 → ℝ := fun i => ![g₀ i,g₁ i] + have hg (i : Fin 3) (j : Fin 2) : ContDiff ℝ (↑(⊤ : ℕ∞)) (g i j) := by + fin_cases j + · exact hg₀ i + · exact hg₁ i + have hs (i : Fin 3) (j : Fin 2) : HasCompactSupport (g i j) := by + fin_cases j + · exact hs₀ i + · exact hs₁ i + have hv (i : Fin 3) (j : Fin 2) : tsupport (g i j)⊆ + (Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2) := by + fin_cases j + · exact hv₀ i + · exact hv₁ i + have hm (i : Fin 3) (j : Fin 2) : (∫ p,g i j p)=(Pi.single i (1 : ℝ) : Fin 3 → ℝ) (j.castLE (by decide : 2≤3)) := by + fin_cases j + · exact hi₀ i + · exact hi₁ i + have hmt (i : Fin 3) : (∫ p : Box3,p.1.2*g i 0 p-p.1.1*g i 1 p)= (Pi.single i (1 : ℝ) : Fin 3 → ℝ) 2 := hit i + have hI (i : Fin 3) (j : Fin 2) : Integrable (g i j) := + (hg i j).continuous.integrable_of_hasCompactSupport (hs i j) + refine ⟨g,hg,hs,hv,?_,?_⟩ + · intro m + have hh (j : Fin 2) : (∫ p,∑ i,m i*g i j p)=m (j.castLE (by decide : 2≤3)) := by + rw [integral_finsetSum _ (fun i _ => (hI i j).const_mul (m i))] + simp_rw [integral_const_mul,hm] + simp [Pi.single_apply] + refine ⟨hh 0,hh 1,?_⟩ + have hU : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun p : Box3 => p.1.1) := contDiff_fst.comp contDiff_fst + have hV : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun p : Box3 => p.1.2) := contDiff_snd.comp contDiff_fst + have htI (i : Fin 3) : Integrable (fun p : Box3 => p.1.2*g i 0 p-p.1.1*g i 1 p) := + ((hV.continuous.mul (hg i 0).continuous).integrable_of_hasCompactSupport (hs i 0).mul_left).sub + ((hU.continuous.mul (hg i 1).continuous).integrable_of_hasCompactSupport (hs i 1).mul_left) + have he : (fun p : Box3 => p.1.2*(∑ i,m i*g i 0 p)-p.1.1*(∑ i,m i*g i 1 p))= + (fun p => ∑ i,m i*(p.1.2*g i 0 p-p.1.1*g i 1 p)) := by + funext p + simp only [Finset.mul_sum,←Finset.sum_sub_distrib] + apply Finset.sum_congr rfl + intro i _ + ring + rw [he,integral_finsetSum _ (fun i _ => (htI i).const_mul (m i))] + simp_rw [integral_const_mul,hmt] + simp [Pi.single_apply] + · intro j n + obtain ⟨B,hB,hbound⟩ := fixed_smooth_tests_bound (fun i => g i j) + (fun i => hg i j) (fun i => hs i j) n + refine ⟨B,hB,?_⟩ + intro m p + simpa only [smul_eq_mul] using hbound m ‖m‖ (norm_nonneg _) (norm_le_pi_norm m) p + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CentralSlopeJet.lean b/lean/OAI/Analysis/Conductivity/Geometry/CentralSlopeJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..e81b6d59e9dc844857b8d554681598ed9ab56f65 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CentralSlopeJet.lean @@ -0,0 +1,137 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CentralJoinCover +import OAI.Analysis.Conductivity.Geometry.CutSlopeGradient +import OAI.Analysis.Conductivity.Variational.WholeBallJetFormula +import OAI.Analysis.Conductivity.Branching.ChildTransportFormula + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def collarSlopeJet (χ : (Fin 3 → ℝ) → ℝ) (a b κ : ℝ) (y : Fin 3 → ℝ) : JetFiber := + WithLp.toLp 2 (Fin.cases + (κ*(χ y*max 0 (a*(sourceCollarTime y-b)))) + (fun i => κ*(fderiv ℝ χ y (Pi.single i 1)*max 0 (a*(sourceCollarTime y-b))+ + χ y*(if 0 a*(sourceCollarTime z-b)) y (Pi.single i 1) else 0)))) + +lemma collarSlopeJet_eq_zero {χ : (Fin 3 → ℝ) → ℝ} {a b κ : ℝ} {y : Fin 3 → ℝ} + (ht : a*(sourceCollarTime y-b)≤0) : collarSlopeJet χ a b κ y=0 := by + ext i + refine Fin.cases ?_ (fun j => ?_) i <;> + simp [collarSlopeJet,max_eq_left ht,not_lt.mpr ht] + +lemma collarSlopeJet_zero_not_tsupport {χ : (Fin 3 → ℝ) → ℝ} {a b κ : ℝ} {y : Fin 3 → ℝ} + (hy : y∉tsupport χ) : collarSlopeJet χ a b κ y=0 := by + ext i + refine Fin.cases ?_ (fun j => ?_) i <;> + simp [collarSlopeJet,image_eq_zero_of_notMem_tsupport hy,fderiv_of_notMem_tsupport ℝ hy] + +lemma compact_collar_slope_jet {χ : (Fin 3 → ℝ) → ℝ} + (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {a : ℝ} (ha : a≠0) {b : ℝ} (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (κ l r : ℝ) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand l r) : + ∃ w : H1,w∈H10 ∧ w.val=ᵐ[ballMeasure] + (fun x => collarSlopeJet χ a b κ (WithLp.ofLp x)) := by + obtain ⟨w,hw,hwe⟩ := compact_collar_slope_value_gradient hχ hc hχb ha hb κ l r hl hr hχs + refine ⟨w,hw,?_⟩ + filter_upwards [hwe] with x hx + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact hx.1 + · exact hx.2 j + +lemma ballWholePiJetCLM_slope_ae {z : JetSpace} {χ : (Fin 3 → ℝ) → ℝ} {a b κ : ℝ} + (hs : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) + (he : z=ᵐ[ballMeasure] (fun x => collarSlopeJet χ a b κ (WithLp.ofLp x))) : + ballWholePiJetCLM z=ᵐ[volume] collarSlopeJet χ a b κ := by + apply (ballWholePiJetCLM_ae_of_ae z (collarSlopeJet χ a b κ) he).trans + exact Filter.Eventually.of_forall (fun y => by + dsimp only + split_ifs with hb + · rfl + · exact (collarSlopeJet_zero_not_tsupport (fun hy => hb (hs y hy))).symm) + +def physicalChildSlopeJet (k : Fin 2) (a κ : ℝ) (y : Fin 3 → ℝ) : JetFiber := + let z := collarSlopeJet (centralJoinChildCutoff k) a (-centralThickness) κ + ((sourceChildHomeomorph (actualChildSign k)).symm y) + WithLp.toLp 2 (Fin.cases (z 0) (fun j => sourceScale⁻¹*z (childAxis j).succ)) + +lemma exists_parentSlopeExtension {a : ℝ} (ha : a<0) (κ : ℝ) : + ∃ w : H1,w∈H10 ∧ w.val=ᵐ[ballMeasure] (fun x => + collarSlopeJet (centralJoinPartition 1) a centralThickness κ (WithLp.ofLp x)) := + compact_collar_slope_jet (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) ha.ne + (by norm_num [centralThickness]) κ 0 (2*centralThickness) + (by norm_num) (by norm_num [centralThickness]) centralJoinPartition_parent_support + +lemma exists_childSlopeExtension {a : ℝ} (ha : 0 physicalChildSlopeJet k a κ (WithLp.ofLp x)) := by + obtain ⟨w,hw,hwe⟩ := compact_collar_slope_jet (centralJoinChildCutoff_smooth k) + (centralJoinChildCutoff_compact k) (centralJoinChildCutoff_bound k) ha.ne' + (show -centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + κ (-2*centralThickness) 0 (by norm_num [centralThickness]) (by norm_num) + (centralJoinChildCutoff_support k) + refine ⟨childH10Transport k ⟨w,hw⟩,childH10Transport_mem_H10 k _,?_⟩ + have hB : ∀ y∈tsupport (centralJoinChildCutoff k),WithLp.toLp 2 y∈ball := by + intro y hy + have hb := centralJoinChildCutoff_support k hy + exact sourceBand_mem_ball ⟨le_trans (by norm_num [centralThickness]) hb.1, + le_trans hb.2 (by norm_num)⟩ + exact childTransportJetCLM_ae_of_ae k w.val _ (ballWholePiJetCLM_slope_ae hB hwe) + +lemma parentSlopeJet_zero_central {a : ℝ} (ha : a<0) (κ : ℝ) {y : Fin 3 → ℝ} + (hy : y∈centralPhysical) : collarSlopeJet (centralJoinPartition 1) a centralThickness κ y=0 := + collarSlopeJet_eq_zero (mul_nonpos_of_nonpos_of_nonneg ha.le + (sub_nonneg.mpr ((centralPhysical_time_iff y).mp hy).1)) + +lemma physicalChildSlopeJet_zero_central {a : ℝ} (ha : 0 ?_) i <;> simp + +def centralSlopeJet (a κ : Fin 3 → ℝ) (y : Fin 3 → ℝ) : JetFiber := + collarSlopeJet (centralJoinPartition 1) (a 0) centralThickness (κ 0) y+ + physicalChildSlopeJet 0 (a 1) (κ 1) y+physicalChildSlopeJet 1 (a 2) (κ 2) y + +theorem centralSlopeExtension_exists (a κ : Fin 3 → ℝ) + (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 centralSlopeJet a κ (WithLp.ofLp x)) ∧ + (∀ᵐ x∂ballMeasure,WithLp.ofLp x∈centralPhysical → w.val x=0) := by + obtain ⟨wp,hp,hep⟩ := exists_parentSlopeExtension ha₀ (κ 0) + obtain ⟨w₀,h₀,he₀⟩ := exists_childSlopeExtension (ha 0) (κ 1) 0 + obtain ⟨w₁,h₁,he₁⟩ := exists_childSlopeExtension (ha 1) (κ 2) 1 + have he : (wp+w₀+w₁).val=ᵐ[ballMeasure] (fun x => centralSlopeJet a κ (WithLp.ofLp x)) := by + filter_upwards [Lp.coeFn_add wp.val w₀.val,Lp.coeFn_add (wp.val+w₀.val) w₁.val,hep,he₀,he₁] + with x h₀ h₁ hp hc₀ hc₁ + change (wp.val+w₀.val+w₁.val) x=_ + simp only [Pi.add_apply] at h₀ h₁ + rw [h₁,h₀,hp,hc₀,hc₁] + rfl + refine ⟨wp+w₀+w₁,H10.add_mem (H10.add_mem hp h₀) h₁,he,?_⟩ + filter_upwards [he] with x hx + intro hy + rw [hx] + dsimp only [centralSlopeJet] + have hzero₀ : physicalChildSlopeJet 0 (a 1) (κ 1) (WithLp.ofLp x)=0 := by + exact physicalChildSlopeJet_zero_central (show 0 Icc (![(-(1:ℝ)/100),-1,-1] k) (![1/100,1,1] k)) := by + ext x + simp only [sourceExtendedBox,mem_Icc,Set.mem_pi,mem_univ,true_implies,Pi.le_def] + simp only [forall_and] + rw [hbox,interior_pi_set (finite_univ),show (fun k : Fin 3 => interior + (Icc (![(-(1:ℝ)/100),-1,-1] k) (![1/100,1,1] k)))= + (fun k => Ioo (![(-(1:ℝ)/100),-1,-1] k) (![1/100,1,1] k)) from funext (fun _ => interior_Icc)] + ext x + simp only [sourceCollarOpenBox,mem_ofPred_eq,Set.mem_pi,mem_univ,true_implies,Fin.forall_fin_succ, + mem_Ioo,Matrix.cons_val_zero,Matrix.cons_val_succ,Fin.forall_fin_zero, + abs_lt] + simp + +lemma sourceCollar_frontier_null (i j : Fin 4) : + volume (sourceCollarPiece i j '' frontier (sourceExtendedBox (-(1:ℝ)/100) (1/100)))=0 := by + let B := sourceExtendedBox (-(1:ℝ)/100) (1/100) + have hB : IsClosed B := isClosed_Icc + have hs : frontier B⊆B := hB.frontier_subset + have hzero : volume (frontier B)=0 := (convex_Icc _ _).addHaar_frontier volume + have H := measure_image_le_det volume isClosed_frontier.measurableSet + (fun x hx => (sourceCollarPiece_contDiff i j).differentiable (by simp) x) + ((sourceExtendedBox_injOn i j (by rfl) (by rfl)).mono hs) + (C:=2) (fun x hx => by + rw [(sourceCollarPiece_hasFDeriv i j x).fderiv] + exact sourceExtended_jacobian_upper i j (by rfl) (by rfl) (hs hx)) + have H' : volume (sourceCollarPiece i j '' frontier B) ≤ 0 := by + simpa only [hzero,mul_zero] using H + exact le_antisymm H' bot_le + +lemma sourceCollar_open_charts_ae : ∀ᵐ y : Fin 3 → ℝ, + y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) → + ∃ i j : Fin 4,∃ x∈sourceCollarOpenBox,sourceCollarPiece i j x=y := by + let N := ⋃ i : Fin 4,⋃ j : Fin 4,sourceCollarPiece i j '' + frontier (sourceExtendedBox (-(1:ℝ)/100) (1/100)) + have hN : volume N=0 := measure_iUnion_null (fun i => + measure_iUnion_null (fun j => sourceCollar_frontier_null i j)) + have hn : ∀ᵐ y : Fin 3 → ℝ,y∉N := by + rw [ae_iff] + simpa only [not_not,Set.ofPred_mem_eq] using hN + filter_upwards [hn] with y hy ht + rw [sourceClosedCollarBand_eq _ _ (by rfl) (by rfl)] at ht + obtain ⟨i,hi⟩ := mem_iUnion.mp ht + obtain ⟨j,x,hx,he⟩ := mem_iUnion.mp hi + refine ⟨i,j,x,?_,he⟩ + rw [sourceCollarOpenBox_eq_interior] + by_contra hn + apply hy + exact mem_iUnion.mpr ⟨i,mem_iUnion.mpr ⟨j,⟨x, + ⟨subset_closure hx,hn⟩,he⟩⟩⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CollarInteriorFacts.lean b/lean/OAI/Analysis/Conductivity/Geometry/CollarInteriorFacts.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae4c9505da8da68413cc6582cacf1eaceed3339e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CollarInteriorFacts.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalEndLocalLipschitz +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarBand + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceDirections_ne_zero_on_band {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100)) : + ∀ i,sourceComplexDirections y i≠0 := by + intro i he + have hr := congrArg Complex.re he + have hi := congrArg Complex.im he + fin_cases i + · simp [sourceComplexDirections] at hr hi + have hy0 : y 0=0 := hr.resolve_right (by norm_num [sourceLength]) + have hh := sourceRadial_pos_of_time hy.1 + simp [sourceRadial,hy0,hi] at hh + · simp [sourceComplexDirections] at hr hi + have hh : sourceCollarTime y=1 := by + simp [sourceCollarTime,sourceCrossCoordinates,hr,hi] + have ht := hy.2 + rw [hh] at ht + norm_num at ht + +lemma sourceBand_euclidean_bound {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100)) : + ‖WithLp.toLp 2 y‖≤(5:ℝ)/2 := by + have hm : max |(sourceRadial y-sourceRadialCenter)/sourceRadialWidth| |y 2|≤101/100 := by + have ht := hy.1 + change -(1:ℝ)/100≤1-max |(sourceRadial y-sourceRadialCenter)/sourceRadialWidth| |y 2| at ht + linarith + have hrad : sourceRadial y≤101/100 := by + have hh := (le_abs_self ((sourceRadial y-sourceRadialCenter)/sourceRadialWidth)).trans + ((le_max_left _ _).trans hm) + norm_num [sourceRadialCenter,sourceRadialWidth,sourceHole,div_eq_mul_inv] at hh + linarith + have h0 : |y 0|≤17/10 := by + have hh := (le_max_left (|y 0|/sourceLength) |y 1|).trans hrad + norm_num [sourceLength,div_eq_mul_inv] at hh + linarith + have h1 : |y 1|≤11/10 := by + have hh := (le_max_right (|y 0|/sourceLength) |y 1|).trans hrad + linarith + have h2 : |y 2|≤11/10 := by + have hh := (le_max_right _ _).trans hm + linarith + have h0' := pow_le_pow_left₀ (abs_nonneg _) h0 2 + have h1' := pow_le_pow_left₀ (abs_nonneg _) h1 2 + have h2' := pow_le_pow_left₀ (abs_nonneg _) h2 2 + have hn := EuclideanSpace.real_norm_sq_eq (WithLp.toLp 2 y : R3) + simp [Fin.sum_univ_succ] at hn + simp only [sq_abs] at h0' h1' h2' + nlinarith [norm_nonneg (WithLp.toLp 2 y : R3)] + +lemma LocalLipAt.sub {E : Type*} [PseudoMetricSpace E] {p q : E → ℝ} {x : E} + (hp : LocalLipAt p x) (hq : LocalLipAt q x) : LocalLipAt (fun y => p y-q y) x := by + obtain ⟨K,t,ht,hK⟩ := hp + obtain ⟨L,u,hu,hL⟩ := hq + exact ⟨K+L,t∩u,inter_mem ht hu,(hK.mono inter_subset_left).sub (hL.mono inter_subset_right)⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CollarLip.lean b/lean/OAI/Analysis/Conductivity/Geometry/CollarLip.lean new file mode 100644 index 0000000000000000000000000000000000000000..34984758154ab893fa39ca2e3e6df9dcd28dce9b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CollarLip.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalEndLocalLipschitz + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped NNReal + +lemma sourceRadial_lipschitz : ∃ K,LipschitzWith K sourceRadial := by + have h0 := ((ContinuousLinearMap.toSpanSingleton ℝ (sourceLength⁻¹ : ℝ)).lipschitzWith.comp + (localLipschitz_abs.comp (LipschitzWith.eval (α := fun _ : Fin 3 => ℝ) (0:Fin 3)))) + have h1 := localLipschitz_abs.comp (LipschitzWith.eval (α := fun _ : Fin 3 => ℝ) (1:Fin 3)) + have H := h0.max h1 + refine ⟨max (‖ContinuousLinearMap.toSpanSingleton ℝ sourceLength⁻¹‖₊*(1*1)) (1*1),?_⟩ + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [sourceRadial,div_eq_mul_inv,ContinuousLinearMap.toSpanSingleton_apply,Function.comp_apply,smul_eq_mul] using H.dist_le_mul x y + +lemma sourceCollarTime_lipschitz : ∃ K,LipschitzWith K sourceCollarTime := by + obtain ⟨K,hK⟩ := sourceRadial_lipschitz + have h0 := localLipschitz_abs.comp ((ContinuousLinearMap.toSpanSingleton ℝ (sourceRadialWidth⁻¹ : ℝ)).lipschitzWith.comp + (hK.sub (LipschitzWith.const sourceRadialCenter))) + have h1 := localLipschitz_abs.comp (LipschitzWith.eval (α := fun _ : Fin 3 => ℝ) (2:Fin 3)) + have H := (LipschitzWith.const (1:ℝ)).sub (h0.max h1) + refine ⟨0+max (1*(‖ContinuousLinearMap.toSpanSingleton ℝ sourceRadialWidth⁻¹‖₊*(K+0))) (1*1),?_⟩ + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [Matrix.cons_val_zero,Matrix.cons_val_one,sourceCollarTime,sourceCrossCoordinates,div_eq_mul_inv,ContinuousLinearMap.toSpanSingleton_apply,Function.comp_apply,smul_eq_mul] using H.dist_le_mul x y + +lemma attachedEndTime_lipschitz (a b : ℝ) : + ∃ K,LipschitzWith K (fun y => a*(sourceCollarTime y-b)) := by + obtain ⟨K,hK⟩ := sourceCollarTime_lipschitz + have H := (ContinuousLinearMap.toSpanSingleton ℝ a).lipschitzWith.comp (hK.sub (LipschitzWith.const b)) + refine ⟨‖ContinuousLinearMap.toSpanSingleton ℝ a‖₊*(K+0),?_⟩ + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [ContinuousLinearMap.toSpanSingleton_apply,Function.comp_apply,smul_eq_mul,mul_comm] using H.dist_le_mul x y + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CollarLocalInverse.lean b/lean/OAI/Analysis/Conductivity/Geometry/CollarLocalInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..56820d5ab596da7075230793670fad1787315adb --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CollarLocalInverse.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CollarCartesianDifferential + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +def sourceCollarOpenBox : Set (Fin 3 → ℝ) := + {x | (-(1:ℝ)/100 < x 0 ∧ x 0 < 1/100) ∧ |x 1|<1 ∧ |x 2|<1} + +lemma isOpen_sourceCollarOpenBox : IsOpen sourceCollarOpenBox := by + exact ((isOpen_lt continuous_const (continuous_apply 0)).inter + (isOpen_lt (continuous_apply 0) continuous_const)).inter + ((isOpen_lt (continuous_apply 1).abs continuous_const).inter + (isOpen_lt (continuous_apply 2).abs continuous_const)) + +lemma sourceCollarOpenBox_subset : sourceCollarOpenBox ⊆ + sourceExtendedBox (-(1:ℝ)/100) (1/100) := by + intro x hx + exact mem_sourceExtendedBox.mpr ⟨⟨hx.1.1.le,hx.1.2.le⟩,hx.2.1.le,hx.2.2.le⟩ + +def sourceCollarTangentEquiv (i j : Fin 4) (x : Fin 3 → ℝ) + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + (Fin 3 → ℝ) ≃L[ℝ] (Fin 3 → ℝ) := + (LinearMap.equivOfDetNeZero (Matrix.toLin' (sourceCollarJacobian i j x)) + (by rw [LinearMap.det_toLin']; exact sourceCollarJacobian_extended_ne_zero i j hx)).toContinuousLinearEquiv + +lemma sourceCollarTangentEquiv_apply (i j : Fin 4) (x : Fin 3 → ℝ) + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) (v : Fin 3 → ℝ) : + sourceCollarTangentEquiv i j x hx v = sourceCollarJacobian i j x *ᵥ v := rfl + +lemma sourceCollarPiece_hasStrictFDeriv (i j : Fin 4) (x : Fin 3 → ℝ) + (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) : + HasStrictFDerivAt (sourceCollarPiece i j) (sourceCollarTangentEquiv i j x hx).toContinuousLinearMap + x := by + have hf := (sourceCollarPiece_contDiff i j).hasStrictFDerivAt (x:=x) (by simp) + rw [(sourceCollarPiece_hasFDeriv i j x).fderiv] at hf + exact hf + +lemma sourceCollarInverse_eventually_left (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + ∀ᶠ y in 𝓝 x,sourceCollarInverse i j (sourceCollarPiece i j y)=y := by + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx] with y hy + exact sourceCollarInverse_left_pos i j + (lt_of_lt_of_le (by norm_num : (0:ℝ)<1/50) + (sourceCollarRadius_extended j ⟨hy.1.1.le,hy.1.2.le⟩ hy.2.2.le).1) + (by linarith [hy.1.2]) hy.2.1.le hy.2.2.le + +lemma sourceCollarInverse_hasStrictFDeriv (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + HasStrictFDerivAt (sourceCollarInverse i j) + (sourceCollarTangentEquiv i j x (sourceCollarOpenBox_subset hx)).symm.toContinuousLinearMap + (sourceCollarPiece i j x) := + (sourceCollarPiece_hasStrictFDeriv i j x (sourceCollarOpenBox_subset hx)).to_local_left_inverse + (sourceCollarInverse_eventually_left i j hx) + +lemma sourceCollarPiece_map_nhds (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + Filter.map (sourceCollarPiece i j) (𝓝 x)=𝓝 (sourceCollarPiece i j x) := + (sourceCollarPiece_hasStrictFDeriv i j x (sourceCollarOpenBox_subset hx)).map_nhds_eq_of_equiv + +lemma sourceCollarInverse_eventually_right (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + ∀ᶠ y in 𝓝 (sourceCollarPiece i j x),sourceCollarPiece i j (sourceCollarInverse i j y)=y := by + rw [←sourceCollarPiece_map_nhds i j hx,Filter.eventually_map] + filter_upwards [sourceCollarInverse_eventually_left i j hx] with y hy + rw [hy] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CollarReverseBound.lean b/lean/OAI/Analysis/Conductivity/Geometry/CollarReverseBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..8fc6f4bf68cc10e236f81d369bf50aa99a2cd51e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CollarReverseBound.lean @@ -0,0 +1,176 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CollarVolumeBound + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +def faceRayDensityLower (w : ℝ) : ℝ := w/(1+w^2)/(2*Real.pi) + +lemma faceRayDensityLower_pos {w : ℝ} (hw : 0 abs ((sourceCollarDerivative i j x).det)) := by + simp_rw [sourceCollarDerivative_det] + unfold sourceCollarRadius squareFace + fun_prop + exact (hc.mul (hg.comp (sourceCollarPiece_contDiff i j).continuous)).continuousOn.integrableOn_compact isCompact_Icc + · exact (continuous_const.mul (hg.comp (sourceCollarPiece_contDiff i j).continuous)).continuousOn.integrableOn_compact isCompact_Icc + · exact measurableSet_Icc + · intro x hx + exact mul_le_mul_of_nonneg_right (sourceExtended_jacobian_upper i j hl hr hx) (hn _) + +theorem integral_sourceAngular_lower {f : (Fin 3 → ℝ) → ℝ} + (hf : Continuous f) (hn : ∀ z,0≤f z) (t : ℝ) : + (faceRayDensityLower 1*faceRayDensityLower sourceRadialWidth)* + (∑ i : Fin 4,∑ j : Fin 4,∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1, + f (sourceCollarPiece i j ![t,a,b])) ≤ + ∫ x : UnitAddTorus (Fin 2),f (sourceAngularCollar t x) := by + have hw : 0 f (sourceAngularCollar t x)) + (w₀:=1) (w₁:=sourceRadialWidth) (by norm_num) hw + (hf.comp (continuous_sourceAngularCollar t)),Finset.mul_sum] + apply Finset.sum_le_sum + intro i _ + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro j _ + rw [←intervalIntegral.integral_const_mul] + apply intervalIntegral.integral_mono_on (by norm_num) + · exact (continuous_const.mul (continuous_parametric_unitInterval + (f:=fun a b => f (sourceCollarPiece i j ![t,a,b])) + (hf.comp (sourceAngularFace_continuous t i j)))).intervalIntegrable _ _ + · exact ((continuous_parametric_unitInterval + (continuous_torusFaceTerm 1 sourceRadialWidth + (hf.comp (continuous_sourceAngularCollar t)) i j)).mul + (continuous_faceRayDensity 1 i)).intervalIntegrable _ _ + · intro a ha + have hinner : faceRayDensityLower sourceRadialWidth* + (∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b])) ≤ + ∫ b in (-1:ℝ)..1, + torusFaceTerm 1 sourceRadialWidth (fun x => f (sourceAngularCollar t x)) i j a b := by + rw [←intervalIntegral.integral_const_mul] + apply intervalIntegral.integral_mono_on (by norm_num) + · exact (continuous_const.mul ((hf.comp (sourceAngularFace_continuous t i j)).comp + (continuous_const.prodMk continuous_id))).intervalIntegrable _ _ + · exact ((continuous_torusFaceTerm 1 sourceRadialWidth + (hf.comp (continuous_sourceAngularCollar t)) i j).comp + (continuous_const.prodMk continuous_id)).intervalIntegrable _ _ + · intro b hb + dsimp only [torusFaceTerm] + rw [sourceAngular_face t a b i j (abs_le.mpr ha) (abs_le.mpr hb),mul_comm] + exact mul_le_mul_of_nonneg_left (faceRayDensity_lower hw j (abs_le.mpr hb)) (hn _) + have hnint : 0≤ ∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b]) := + intervalIntegral.integral_nonneg (by norm_num) (fun _ _ => hn _) + calc + _ = (faceRayDensityLower sourceRadialWidth* + (∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b])))*faceRayDensityLower 1 := by ring + _ ≤ _ := mul_le_mul hinner (faceRayDensity_lower (by norm_num) i (abs_le.mpr ha)) + hk₀ ((mul_nonneg hk₁ hnint).trans hinner) + +theorem sourceAngular_volume_reverse {g : (Fin 3 → ℝ) → ℝ} + (hg : Continuous g) (hn : ∀ y,0≤g y) {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + (∑ i : Fin 4,∑ j : Fin 4,∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y)≤ + (2/(faceRayDensityLower 1*faceRayDensityLower sourceRadialWidth))* + (∫ t in l..r,∫ x : UnitAddTorus (Fin 2),g (sourceAngularCollar t x)) := by + let k := faceRayDensityLower 1*faceRayDensityLower sourceRadialWidth + have hk : 0 ∫ x : UnitAddTorus (Fin 2),g (sourceAngularCollar t x)) := by + have hcs : Continuous (fun p : ℝ×UnitAddTorus (Fin 2) => sourceAngularCollar p.1 p.2) := by + simpa only [zero_add] using continuous_sourceAngular 0 + have hh := continuous_parametric_integral_of_continuous (μ:=volume) + (f:=fun t (x : UnitAddTorus (Fin 2)) => g (sourceAngularCollar t x)) + (hg.comp hcs) (s:=univ) isCompact_univ + simpa using hh + have hsum : Continuous (fun t : ℝ => ∑ i : Fin 4,∑ j : Fin 4, + ∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1,g (sourceCollarPiece i j ![t,a,b])) := + continuous_finsetSum _ (fun i _ => continuous_finsetSum _ (fun j _ => continuous_collarFace_integral hg i j)) + have Hint : k*(∑ i : Fin 4,∑ j : Fin 4, + ∫ x in sourceExtendedBox l r,g (sourceCollarPiece i j x))≤ + ∫ t in l..r,∫ x : UnitAddTorus (Fin 2),g (sourceAngularCollar t x) := by + have hh := intervalIntegral.integral_mono_on (μ:=volume) hlr + ((continuous_const.mul hsum).intervalIntegrable l r) + (hcont.intervalIntegrable l r) (fun t _ => integral_sourceAngular_lower hg hn t) + simp only [Pi.mul_apply] at hh + rw [intervalIntegral.integral_const_mul] at hh + convert hh using 2 + rw [intervalIntegral.integral_finsetSum (fun i _ => + (continuous_finsetSum _ (fun j _ => continuous_collarFace_integral hg i j)).intervalIntegrable l r)] + apply Finset.sum_congr rfl + intro i _ + rw [intervalIntegral.integral_finsetSum (fun j _ => (continuous_collarFace_integral hg i j).intervalIntegrable l r)] + apply Finset.sum_congr rfl + intro j _ + exact integral_sourceExtendedBox (hg.comp (sourceCollarPiece_contDiff i j).continuous) hlr + calc + _ ≤ ∑ i : Fin 4,∑ j : Fin 4,2*(∫ x in sourceExtendedBox l r,g (sourceCollarPiece i j x)) := by + apply Finset.sum_le_sum + intro i _ + apply Finset.sum_le_sum + intro j _ + exact sourceExtended_integral_upper hg hn i j hl hr + _ = (2/k)*(k*(∑ i : Fin 4,∑ j : Fin 4, + ∫ x in sourceExtendedBox l r,g (sourceCollarPiece i j x))) := by + simp_rw [←Finset.mul_sum] + field_simp + _ ≤ _ := mul_le_mul_of_nonneg_left Hint (by positivity) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CollarVolumeBound.lean b/lean/OAI/Analysis/Conductivity/Geometry/CollarVolumeBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..6d044f68a57ea0fcc573a7ff996831425f9bdad6 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CollarVolumeBound.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.BoxIteration +import OAI.Analysis.Conductivity.Geometry.TorusFaceIntegration +import OAI.Analysis.Conductivity.Fourier.AngularIntegratedTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +lemma sourceExtendedBox_compact (l r : ℝ) : IsCompact (sourceExtendedBox l r) := isCompact_Icc + +theorem sourceExtended_integral_bound {g : (Fin 3 → ℝ) → ℝ} + (hg : Continuous g) (hn : ∀ y,0≤g y) (i j : Fin 4) {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + (∫ x in sourceExtendedBox l r,g (sourceCollarPiece i j x))≤ + 100*(∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y) := by + rw [sourceExtended_integral i j hl hr,←integral_const_mul] + apply setIntegral_mono_on + · exact (hg.comp (sourceCollarPiece_contDiff i j).continuous).continuousOn.integrableOn_compact isCompact_Icc + · have hc : Continuous (fun x : Fin 3 → ℝ => abs ((sourceCollarDerivative i j x).det)) := by + simp_rw [sourceCollarDerivative_det] + unfold sourceCollarRadius squareFace + fun_prop + exact (continuous_const.mul (hc.mul (hg.comp (sourceCollarPiece_contDiff i j).continuous))).continuousOn.integrableOn_compact isCompact_Icc + · exact measurableSet_Icc + · intro x hx + have hh := sourceExtended_jacobian_lower i j hl hr hx + change g (sourceCollarPiece i j x)≤100*(abs ((sourceCollarDerivative i j x).det)*g (sourceCollarPiece i j x)) + nlinarith [mul_nonneg (hn (sourceCollarPiece i j x)) (show 0≤abs ((sourceCollarDerivative i j x).det)-1/100 by linarith)] + +lemma continuous_collarFace_integral {g : (Fin 3 → ℝ) → ℝ} (hg : Continuous g) (i j : Fin 4) : + Continuous (fun t : ℝ => ∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1,g (sourceCollarPiece i j ![t,a,b])) := by + apply continuous_parametric_unitInterval (f:=fun t a => ∫ b in (-1:ℝ)..1,g (sourceCollarPiece i j ![t,a,b])) + apply continuous_parametric_unitInterval (f:=fun p : ℝ×ℝ => fun b => g (sourceCollarPiece i j ![p.1,p.2,b])) + exact hg.comp ((sourceCollarPiece_contDiff i j).continuous.comp (by fun_prop)) + +theorem sourceAngular_volume_bound {g : (Fin 3 → ℝ) → ℝ} + (hg : Continuous g) (hn : ∀ y,0≤g y) {l r : ℝ} + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + (∫ t in l..r,∫ x : UnitAddTorus (Fin 2),g (sourceAngularCollar t x))≤ + (100*((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi)))* + ∑ i : Fin 4,∑ j : Fin 4,∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y := by + let c : ℝ := ((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi)) + have hw : 0 ∫ x : UnitAddTorus (Fin 2),g (sourceAngularCollar t x)) := by + have hcs : Continuous (fun p : ℝ×UnitAddTorus (Fin 2) => sourceAngularCollar p.1 p.2) := by + simpa only [zero_add] using continuous_sourceAngular 0 + have hh := continuous_parametric_integral_of_continuous (μ:=volume) + (f:=fun t (x : UnitAddTorus (Fin 2)) => g (sourceAngularCollar t x)) + (hg.comp hcs) (s:=univ) isCompact_univ + simpa using hh + have hsum : Continuous (fun t : ℝ => ∑ i : Fin 4,∑ j : Fin 4, + ∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1,g (sourceCollarPiece i j ![t,a,b])) := + continuous_finsetSum _ (fun i _ => continuous_finsetSum _ (fun j _ => continuous_collarFace_integral hg i j)) + calc + _≤∫ t in l..r,c*(∑ i : Fin 4,∑ j : Fin 4, + ∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1,g (sourceCollarPiece i j ![t,a,b])) := + intervalIntegral.integral_mono_on hlr (hcont.intervalIntegrable l r) + ((continuous_const.mul hsum).intervalIntegrable l r) (fun t _ => integral_sourceAngular_le hg hn t) + _=c*(∑ i : Fin 4,∑ j : Fin 4,∫ x in sourceExtendedBox l r,g (sourceCollarPiece i j x)) := by + rw [intervalIntegral.integral_const_mul] + congr 1 + rw [intervalIntegral.integral_finsetSum (fun i _ => + (continuous_finsetSum _ (fun j _ => continuous_collarFace_integral hg i j)).intervalIntegrable l r)] + apply Finset.sum_congr rfl + intro i _ + rw [intervalIntegral.integral_finsetSum (fun j _ => (continuous_collarFace_integral hg i j).intervalIntegrable l r)] + apply Finset.sum_congr rfl + intro j _ + exact (integral_sourceExtendedBox (hg.comp (sourceCollarPiece_contDiff i j).continuous) hlr).symm + _≤c*(∑ i : Fin 4,∑ j : Fin 4,100*(∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y)) := by + apply mul_le_mul_of_nonneg_left _ hc + apply Finset.sum_le_sum + intro i _ + apply Finset.sum_le_sum + intro j _ + exact sourceExtended_integral_bound hg hn i j hl hr + _=_ := by simp_rw [←Finset.mul_sum]; dsimp [c]; ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CompactRegularBoxCorrection.lean b/lean/OAI/Analysis/Conductivity/Geometry/CompactRegularBoxCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..b284b7e3a3b9dedb5cca0a5f25479c50cc2200d9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CompactRegularBoxCorrection.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactRegularCorrection +import OAI.Analysis.Conductivity.Flux.CompactInteriorDivergence + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem compact_regular_box_correction {a b : Fin 3 → ℝ} (hab : ∀ i,a i p.1.1) := contDiff_fst.comp contDiff_fst + have hf₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun p : Box3 => p.1.2) := contDiff_snd.comp contDiff_fst + have hIF := cube_coordinate_divergence_moment hF₁ hF₂ hF₃ hsF₁ hsF₂ hsF₃ hdF hf₂ + have hIG := cube_coordinate_divergence_moment hG₁ hG₂ hG₃ hsG₁ hsG₂ hsG₃ hdG hf₁ + simp only [cubePartial_fst_fst,cubePartial_snd_fst,zero_mul,one_mul,integral_zero,neg_zero, + sub_zero,zero_sub] at hIF hIG + have hi₁ : Integrable (fun p : Box3 => p.1.2*r₁ p) := (hf₂.continuous.mul hr₁.continuous).integrable_of_hasCompactSupport (μ := volume) hs₁.mul_left + have hi₂ : Integrable (fun p : Box3 => p.1.1*r₂ p) := (hf₁.continuous.mul hr₂.continuous).integrable_of_hasCompactSupport (μ := volume) hs₂.mul_left + have hzq : (∫ p,F₂ p-G₁ p)=0 := by + rw [integral_sub (hF₂.continuous.integrable_of_hasCompactSupport hsF₂) + (hG₁.continuous.integrable_of_hasCompactSupport hsG₁)] + rw [integral_sub hi₁ hi₂,hIF,hIG] at ht + linarith + let U := (Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2) + have htF₁ : tsupport F₁⊆U := (subset_union_left.trans subset_union_left).trans htF + have htF₂ : tsupport F₂⊆U := (subset_union_right.trans subset_union_left).trans htF + have htF₃ : tsupport F₃⊆U := subset_union_right.trans htF + have htG₁ : tsupport G₁⊆U := (subset_union_left.trans subset_union_left).trans htG + have htG₂ : tsupport G₂⊆U := (subset_union_right.trans subset_union_left).trans htG + have htG₃ : tsupport G₃⊆U := subset_union_right.trans htG + have htq : tsupport (fun p => F₂ p-G₁ p)⊆U := + (tsupport_sub _ _).trans (union_subset htF₂ htG₁) + obtain ⟨h₁,h₂,h₃,hh₁,hh₂,hh₃,hsh₁,hsh₂,hsh₃,hdh,hth⟩ := + compact_box_divergence_inside hab (hF₂.sub hG₁) (hsF₂.sub hsG₁) htq hzq + have hth₁ : tsupport h₁⊆U := (subset_union_left.trans subset_union_left).trans hth + have hth₂ : tsupport h₂⊆U := (subset_union_right.trans subset_union_left).trans hth + have hth₃ : tsupport h₃⊆U := subset_union_right.trans hth + let A := fun p => F₁ p+cubePartial h₁ ((0,1),0) p + let B := fun p => G₁ p+cubePartial h₂ ((0,1),0) p + let C := fun p => F₃ p+cubePartial h₃ ((0,1),0) p + let D := fun p => G₂ p-cubePartial h₂ ((1,0),0) p + let H : Fin 3 → Fin 3 → Box3 → ℝ := ![![A,B,C],![B,D,G₃],![C,G₃,fun _ => 0]] + have hA := hF₁.add (cubePartial_smooth hh₁ ((0,1),0)) + have hB := hG₁.add (cubePartial_smooth hh₂ ((0,1),0)) + have hC := hF₃.add (cubePartial_smooth hh₃ ((0,1),0)) + have hD := hG₂.sub (cubePartial_smooth hh₂ ((1,0),0)) + have hsA := hsF₁.add (cubePartial_compact hsh₁ ((0,1),0)) + have hsB := hsG₁.add (cubePartial_compact hsh₂ ((0,1),0)) + have hsC := hsF₃.add (cubePartial_compact hsh₃ ((0,1),0)) + have hsD := hsG₂.sub (cubePartial_compact hsh₂ ((1,0),0)) + have hB' : B=(fun p => F₂ p-cubePartial h₁ ((1,0),0) p-cubePartial h₃ ((0,0),1) p) := by + funext p + change G₁ p+cubePartial h₂ ((0,1),0) p=_ + linarith [hdh p] + have htA : tsupport A⊆U := (tsupport_add _ _).trans + (union_subset htF₁ ((cubePartial_tsupport _).trans hth₁)) + have htB : tsupport B⊆U := (tsupport_add _ _).trans + (union_subset htG₁ ((cubePartial_tsupport _).trans hth₂)) + have htC : tsupport C⊆U := (tsupport_add _ _).trans + (union_subset htF₃ ((cubePartial_tsupport _).trans hth₃)) + have htD : tsupport D⊆U := (tsupport_sub _ _).trans + (union_subset htG₂ ((cubePartial_tsupport _).trans hth₂)) + have ht0 : tsupport (fun _ : Box3 => (0:ℝ))⊆U := by simp + refine ⟨H,?_,?_,?_,?_,?_,?_⟩ + · intro i j; fin_cases i <;> fin_cases j + all_goals first | exact hA | exact hB | exact hC | exact hD | exact hG₃ | exact contDiff_const + · intro i j; fin_cases i <;> fin_cases j + all_goals first | exact hsA | exact hsB | exact hsC | exact hsD | exact hsG₃ | exact HasCompactSupport.zero + · intro i j; fin_cases i <;> fin_cases j + all_goals first | exact htA | exact htB | exact htC | exact htD | exact htG₃ | exact ht0 + · intro i j p; fin_cases i <;> fin_cases j <;> rfl + · intro p + change cubePartial A ((1,0),0) p+cubePartial B ((0,1),0) p+cubePartial C ((0,0),1) p=r₁ p + rw [hB'] + change cubePartial (fun p => F₁ p+cubePartial h₁ ((0,1),0) p) ((1,0),0) p+ + cubePartial (fun p => F₂ p-cubePartial h₁ ((1,0),0) p-cubePartial h₃ ((0,0),1) p) ((0,1),0) p+ + cubePartial (fun p => F₃ p+cubePartial h₃ ((0,1),0) p) ((0,0),1) p=r₁ p + rw [cubePartial_add (hF₁.differentiable (by simp)) ((cubePartial_smooth hh₁ _).differentiable (by simp)), + cubePartial_sub ((hF₂.sub (cubePartial_smooth hh₁ _)).differentiable (by simp)) + ((cubePartial_smooth hh₃ _).differentiable (by simp)), + cubePartial_sub (hF₂.differentiable (by simp)) ((cubePartial_smooth hh₁ _).differentiable (by simp)), + cubePartial_add (hF₃.differentiable (by simp)) ((cubePartial_smooth hh₃ _).differentiable (by simp)), + cubePartial_commute hh₁ ((0,1),0) ((1,0),0),cubePartial_commute hh₃ ((0,1),0) ((0,0),1)] + linarith [hdF p] + · intro p + change cubePartial B ((1,0),0) p+cubePartial D ((0,1),0) p+cubePartial G₃ ((0,0),1) p=r₂ p + change cubePartial (fun p => G₁ p+cubePartial h₂ ((0,1),0) p) ((1,0),0) p+ + cubePartial (fun p => G₂ p-cubePartial h₂ ((1,0),0) p) ((0,1),0) p+ + cubePartial G₃ ((0,0),1) p=r₂ p + rw [cubePartial_add (hG₁.differentiable (by simp)) ((cubePartial_smooth hh₂ _).differentiable (by simp)), + cubePartial_sub (hG₂.differentiable (by simp)) ((cubePartial_smooth hh₂ _).differentiable (by simp)), + cubePartial_commute hh₂ ((0,1),0) ((1,0),0)] + linarith [hdG p] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CompactSplitSubpatch.lean b/lean/OAI/Analysis/Conductivity/Geometry/CompactSplitSubpatch.lean new file mode 100644 index 0000000000000000000000000000000000000000..2d25be8f447b57a90e71a11d7b34ab3b19304f79 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CompactSplitSubpatch.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.LocalSplitSubpatchRetained +import OAI.Analysis.Conductivity.Flux.PiolaFluxAdd + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +theorem exists_compact_split_on_subpatch + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + (u : Coord3 → Fin 2 → ℝ) (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) + (A : Coord3 → Symmetric3) {p : Coord3} (hAp : ContinuousAt A p) + {U : Set Coord3} (hU : IsOpen U) (hUb : Bornology.IsBounded U) (hpU : p ∈ U) + (hA : ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (A x).val) U) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hD : Function.Surjective (fderiv ℝ u p)) + (d : Coord3) (L : Coord3 →L[ℝ] ℝ) (hLd : L d = 1) + (B : Mat3) (hB : B.IsSymm) (hBn : ∀ v, L (B *ᵥ v) = 0) + {θ c m : ℝ} (hθ : 0 < θ) (hθ1 : θ < 1) + (hm : 0 < m) (hpath : ∀ z ∈ Icc (-θ) (1-θ), m ≤ 1+c*z) + (C : ℝ → Symmetric3) (hC : ∀ z ∈ Icc (-θ) (1-θ), ContinuousAt C z) + (hCs : ∀ z ∈ Icc (-θ) (1-θ), ContDiffAt ℝ (↑(⊤ : ℕ∞)) (fun t => (C t).val) z) + (hdet : ∀ z ∈ Icc (-θ) (1-θ), 0 < (splitJacobian d L c z).det) + (hconstit : ∀ z ∈ Icc (-θ) (1-θ), + (C z).val = (splitJacobian d L c z).det⁻¹ • + (splitJacobian d L c z * ((A p).val + z • B) * (splitJacobian d L c z)ᵀ)) + {G : Set (ℝ × Symmetric3)} (hG : IsOpen G) + (hCG : ∀ z ∈ Icc (-θ) (1-θ), (z, C z) ∈ G) : + ∃ W : Set Coord3, IsOpen W ∧ p ∈ W ∧ closure W ⊆ U ∧ IsCompact (closure W) ∧ + ∀ O : Set Coord3, IsOpen O → O ⊆ W → ∀ ε : ℝ, 0 < ε → + ∃ (R : CompactTwoFieldReplacement μ O u A) (q : Coord3 → ℝ), + ContDiff ℝ (↑(⊤ : ℕ∞)) q ∧ + (∀ x, q x ∈ Icc (-θ) (1-θ)) ∧ + (∀ x ∈ O, (q x, R.tensor x) ∈ G) ∧ + μ {x | x ∈ O ∧ q x ≠ -θ ∧ q x ≠ 1-θ} ≤ ENNReal.ofReal ε := by + obtain ⟨X, W, hW, hpW, hWU, hWc, hWX, hX, hXi, hop⟩ := + exists_local_split_on_subpatch_retained μ u hu A hAp hD d L hLd B hB hBn + hθ hθ1 hm hpath C hC hdet hconstit hG hCG hU hpU + refine ⟨W, hW, hpW, hWU, hWc, ?_⟩ + intro O hO hOW ε hε + have hOU : O ⊆ U := hOW.trans (subset_closure.trans hWU) + have hOX : O ⊆ X.source := hOW.trans hWX + obtain ⟨χ, H, F, hχc, hχO, hχb, hHr, hF, hFs, hFdiv, hn⟩ := hop O hO hOW ε hε + obtain ⟨n, hn⟩ := hn.exists + obtain ⟨Y, hY, hYi, hoffO, _, hform, hpure, hstate⟩ := hn + have hχt : tsupport χ.val ⊆ X.target := hχO.trans (by + rintro y ⟨x, hx, rfl⟩; exact X.map_source (hOX hx)) + let K := X.symm '' tsupport χ.val + have hK : IsCompact K := hχc.image_of_continuousOn (X.symm.continuousOn.mono hχt) + have hKO : K ⊆ O := by + rintro x ⟨y, hy, rfl⟩ + obtain ⟨t, ht, rfl⟩ := hχO hy + simpa only [X.left_inv (hOX ht)] using ht + have hχp := localPullback_tsupport X χ.val hχc hχt + have hoff : ∀ x ∉ K, Y x = x := by + intro x hx + have hz := image_eq_zero_of_notMem_tsupport (fun h => hx (hχp.2.1 h)) + rw [hform x, hz, mul_zero, zero_mul, zero_smul, add_zero] + let z : Coord3 → ℝ := fun x => localPullback X χ.val x * + (smoothDirection 1 H).val ((n+1 : ℝ) * L (X x)) + have hz : ContDiff ℝ (↑(⊤ : ℕ∞)) z := + (localPullback_contDiff X hX.contDiffOn χ.val (smoothScalar_contDiff χ) hχc hχt).mul + ((smoothScalar_contDiff (smoothDirection 1 H)).comp + (contDiff_const.mul (L.contDiff.comp hX))) + have hzr : ∀ x, z x ∈ Icc (-θ) (1-θ) := fun x => + scalar_cutoff_segment hθ.le (by linarith) (localPullback_bounds X χ.val hχb x) (hHr _) + obtain ⟨R, hRt⟩ := synchronized_compact_replacement μ u hu A hU hUb hOU hK hKO hA hdiv + Y hY hYi hoff z hz C (fun x _ => hCs _ (hzr x)) (F (n+1 : ℝ)) + (hF _) (fun j => (hFs _ j).2.2) (hFdiv _) (fun x hx => + ⟨(hstate x hx).1, (hstate x hx).2.1, (hstate x hx).2.2.2⟩) + let q : Coord3 → ℝ := z ∘ Y.symm + have him : MapsTo Y.symm O O := (equiv_mapsTo_of_fixed_compl Y O hoffO).2 + refine ⟨R, q, hz.comp hYi, fun x => hzr _, ?_, hpure⟩ + intro x hx + have ht := hRt (Y.symm x) (him hx) + rw [Y.apply_symm_apply] at ht + rw [ht] + exact (hstate (Y.symm x) (him hx)).2.2.1 + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/ControlledCorrectionBoxes.lean b/lean/OAI/Analysis/Conductivity/Geometry/ControlledCorrectionBoxes.lean new file mode 100644 index 0000000000000000000000000000000000000000..32563a50369881471f95868ede68bd44d4152407 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/ControlledCorrectionBoxes.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.LocalPhysicalCorrectionBound + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +structure ControlledCorrectionBox (u : Coord3 → Fin 2 → ℝ) (U : Set Coord3) + extends RegularCorrectionBox u U where + outerLower : Coord3 + outerUpper : Coord3 + lower_gap : ∀ i,outerLower i (B.lower_gap i).le) (fun i => (B.upper_gap i).le))) +end ControlledCorrectionBox + +lemma exists_controlled_correction_box + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + {U : Set Coord3} (hU : IsOpen U) {p : Coord3} (hp : p∈U) + (hD : Function.Surjective (fderiv ℝ u p)) : + ∃ B : ControlledCorrectionBox u U,p∈B.region := by + obtain ⟨X,hpX,hXU,hX,hXi,he⟩ := exists_regular_potential_coordinates hu p hD hU hp + let x := X.symm p + obtain ⟨ε,hε,hball⟩ := Metric.isOpen_iff.mp X.open_source x (X.map_target hpX) + let a : Coord3 := fun i => x i-ε/3 + let b : Coord3 := fun i => x i+ε/3 + let c : Coord3 := fun i => x i-2*ε/3 + let d : Coord3 := fun i => x i+2*ε/3 + have hc : closedCorrectionBox c d⊆X.source := by + intro y hy + apply hball + rw [Metric.mem_ball,dist_pi_lt_iff hε] + intro i + rw [Real.dist_eq,abs_lt] + have hi : c i≤y i ∧ y i≤d i := by + fin_cases i + · exact hy.1.1 + · exact hy.1.2 + · exact hy.2 + dsimp [c,d] at hi + constructor <;> linarith + have hca : ∀ i,c i by dsimp [c,a]; linarith + have hbd : ∀ i,b i by dsimp [b,d]; linarith + let B : ControlledCorrectionBox u U := + ⟨⟨X,a,b,fun i => by dsimp [a,b]; linarith, + (correctionBox_subset_closed (fun i => (hca i).le) (fun i => (hbd i).le)).trans hc, + hX,hXi.contDiffOn,fun _ _ => congrFun he _,hXU⟩,c,d,hca,hbd,hc⟩ + refine ⟨B,x,?_,X.right_inv hpX⟩ + exact mem_correctionBox.mpr (fun i => by change x i-ε/3 linarith) + +def BoundedPhysicallyCorrectable (u : Coord3 → Fin 2 → ℝ) (U : Set Coord3) + (r : PhysicalSourcePair) (N : ℝ) : Prop := + ∃ H : Coord3 → Mat3,ContDiff ℝ (↑(⊤:ℕ∞)) H ∧ HasCompactSupport H ∧ + tsupport H⊆U ∧ (∀ x,(H x).IsSymm) ∧ (∀ j,symmetricSource H u j=r j) ∧ + ∀ x,‖H x‖≤N + +namespace BoundedPhysicallyCorrectable +variable {u : Coord3 → Fin 2 → ℝ} {U : Set Coord3} {r s : PhysicalSourcePair} {M N : ℝ} +lemma mono (h : BoundedPhysicallyCorrectable u U r M) (hMN : M≤N) : + BoundedPhysicallyCorrectable u U r N := by + obtain ⟨H,hH,hc,hs,hsy,hr,hb⟩ := h + exact ⟨H,hH,hc,hs,hsy,hr,fun x => (hb x).trans hMN⟩ +lemma zero (hN : 0≤N) : BoundedPhysicallyCorrectable u U 0 N := by + refine ⟨0,contDiff_const,HasCompactSupport.zero,by simp [tsupport_zero],fun _ => Matrix.isSymm_zero,?_,?_⟩ + · intro j; funext x; simp [symmetricSource,coordinateDivergence,Matrix.col] + · intro x; simpa using hN +lemma add (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (hr : BoundedPhysicallyCorrectable u U r M) (hs : BoundedPhysicallyCorrectable u U s N) : + BoundedPhysicallyCorrectable u U (r+s) (M+N) := by + obtain ⟨H,hH,hHc,hHs,hHsy,hHr,hHb⟩ := hr + obtain ⟨K,hK,hKc,hKs,hKsy,hKr,hKb⟩ := hs + refine ⟨H+K,hH.add hK,hHc.add hKc,(tsupport_add H K).trans (union_subset hHs hKs), + fun x => (hHsy x).add (hKsy x),?_,fun x => (norm_add_le _ _).trans (add_le_add (hHb x) (hKb x))⟩ + intro j + rw [symmetricSource_add hH hK hu j,hHr j,hKr j] + rfl +lemma correctable (h : BoundedPhysicallyCorrectable u U r N) : PhysicallyCorrectable u U r := by + obtain ⟨H,hH,hc,hs,hsy,hr,_⟩ := h + exact ⟨H,hH,hc,hs,hsy,hr⟩ +end BoundedPhysicallyCorrectable + +lemma ControlledCorrectionBox.bounded_solver + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) {U : Set Coord3} + (B : ControlledCorrectionBox u U) : + ∃ L : ℝ,0 ?_⟩ + have hz (j : Fin 2) : (∫ x,r j x)=0 := by + fin_cases j + · exact congrFun hm 0 + · exact congrFun hm 1 + obtain ⟨H,hH,hc,hsub,hsy,hsrc,hbound⟩ := solve r (fun j => (hr j).1) (fun j => (hr j).2) + hs hz (congrFun hm 2) M hM hb + exact ⟨H,hH,hc,hsub.trans B.target_subset,hsy,hsrc,hbound⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CoordinateCorrectionC0.lean b/lean/OAI/Analysis/Conductivity/Geometry/CoordinateCorrectionC0.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b9f24dde848bfa27391f41c844febf87521df8a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CoordinateCorrectionC0.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CoordinateWeakCorrection +import OAI.Analysis.Conductivity.Variational.CompactRegularC0 + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory +open scoped Matrix.Norms.Elementwise + +theorem compact_coordinate_box_correction_C0 {a b c d : Fin 3 → ℝ} + (hab : ∀ i,a i H i j (boxCoordinates x) + have hB : ContDiff ℝ (↑(⊤ : ℕ∞)) B := + contDiff_pi.mpr (fun i => contDiff_pi.mpr (fun j => (hH i j).comp boxCoordinates.contDiff)) + have hbc : HasCompactSupport B := matrix_hasCompactSupport B (fun i j => + (hcH i j).comp_homeomorph boxCoordinates.toHomeomorph) + have hbs : tsupport B⊆boxCoordinates ⁻¹' ((Icc (c 0) (d 0) ×ˢ Icc (c 1) (d 1)) ×ˢ Icc (c 2) (d 2)) := by + apply matrix_tsupport_subset B + intro i j + exact (tsupport_comp_subset_preimage (H i j) boxCoordinates.continuous).trans (preimage_mono (hsH i j)) + have hcol (x : Coord3) (j : Fin 3) : (B x).col j= + ![H 0 j (boxCoordinates x),H 1 j (boxCoordinates x),H 2 j (boxCoordinates x)] := by + ext i; fin_cases i <;> rfl + refine ⟨B,hB,hbc,hbs,?_,?_,?_,?_⟩ + · intro x + ext i j + exact hsy j i (boxCoordinates x) + · intro φ hφ + simp_rw [hcol] + exact cube_weak_divergence_to_coordinates (hH 0 0) (hH 1 0) (hH 2 0) + (hcH 0 0) (hcH 1 0) (hcH 2 0) hd₁ φ hφ + · intro φ hφ + simp_rw [hcol] + exact cube_weak_divergence_to_coordinates (hH 0 1) (hH 1 1) (hH 2 1) + (hcH 0 1) (hcH 1 1) (hcH 2 1) hd₂ φ hφ + + · intro x + apply Matrix.norm_le_iff (mul_nonneg hL.le hM) |>.mpr + intro i j + exact hbH i j (boxCoordinates x) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CoordinateWeakCorrection.lean b/lean/OAI/Analysis/Conductivity/Geometry/CoordinateWeakCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6e0fc74a8e1935d7f84b6e732bac8c981164b93 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CoordinateWeakCorrection.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CompactRegularBoxCorrection +import OAI.Analysis.Conductivity.Geometry.BoxCoordinateBridge +import OAI.Analysis.Conductivity.Flux.CubeWeakDivergence +import OAI.Analysis.Conductivity.Variational.MatrixCompact + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory +open scoped Matrix.Norms.Elementwise + +lemma cube_weak_divergence_to_coordinates {F₁ F₂ F₃ r : Box3 → ℝ} + (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₁) (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₂) + (h₃ : ContDiff ℝ (↑(⊤ : ℕ∞)) F₃) + (hs₁ : HasCompactSupport F₁) (hs₂ : HasCompactSupport F₂) (hs₃ : HasCompactSupport F₃) + (hd : ∀ p,cubePartial F₁ ((1,0),0) p+cubePartial F₂ ((0,1),0) p+ + cubePartial F₃ ((0,0),1) p=r p) + (φ : Coord3 → ℝ) (hφ : ContDiff ℝ (↑(⊤ : ℕ∞)) φ) : + (∫ x,fderiv ℝ φ x ![F₁ (boxCoordinates x),F₂ (boxCoordinates x),F₃ (boxCoordinates x)])= + -(∫ x,φ x*r (boxCoordinates x)) := by + have he (p w : Box3) : fderiv ℝ (φ∘boxCoordinates.symm) p w= + fderiv ℝ φ (boxCoordinates.symm p) (boxCoordinates.symm w) := by + rw [fderiv_comp p (hφ.differentiable (by simp) _) boxCoordinates.symm.differentiableAt, + boxCoordinates.symm.fderiv] + rfl + have h := cube_weak_divergence h₁ h₂ h₃ hs₁ hs₂ hs₃ hd (φ∘boxCoordinates.symm) + (hφ.comp boxCoordinates.symm.contDiff) + simp_rw [he,Function.comp_apply] at h + rw [←boxCoordinates_integral (fun p => fderiv ℝ φ (boxCoordinates.symm p) + (boxCoordinates.symm ((F₁ p,F₂ p),F₃ p))), + ←boxCoordinates_integral (fun p => φ (boxCoordinates.symm p)*r p)] at h + simpa only [boxCoordinates.symm_apply_apply,boxCoordinates_symm_apply] using h + +theorem compact_coordinate_box_correction {a b : Fin 3 → ℝ} (hab : ∀ i,a i H i j (boxCoordinates x) + have hB : ContDiff ℝ (↑(⊤ : ℕ∞)) B := + contDiff_pi.mpr (fun i => contDiff_pi.mpr (fun j => (hH i j).comp boxCoordinates.contDiff)) + have hbc : HasCompactSupport B := matrix_hasCompactSupport B (fun i j => + (hcH i j).comp_homeomorph boxCoordinates.toHomeomorph) + have hbs : tsupport B⊆boxCoordinates ⁻¹' ((Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2)) := by + apply matrix_tsupport_subset B + intro i j + exact (tsupport_comp_subset_preimage (H i j) boxCoordinates.continuous).trans (preimage_mono (hsH i j)) + have hcol (x : Coord3) (j : Fin 3) : (B x).col j= + ![H 0 j (boxCoordinates x),H 1 j (boxCoordinates x),H 2 j (boxCoordinates x)] := by + ext i; fin_cases i <;> rfl + refine ⟨B,hB,hbc,hbs,?_,?_,?_⟩ + · intro x + ext i j + exact hsy j i (boxCoordinates x) + · intro φ hφ + simp_rw [hcol] + exact cube_weak_divergence_to_coordinates (hH 0 0) (hH 1 0) (hH 2 0) + (hcH 0 0) (hcH 1 0) (hcH 2 0) hd₁ φ hφ + · intro φ hφ + simp_rw [hcol] + exact cube_weak_divergence_to_coordinates (hH 0 1) (hH 1 1) (hH 2 1) + (hcH 0 1) (hcH 1 1) (hcH 2 1) hd₂ φ hφ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CutSlopeGradient.lean b/lean/OAI/Analysis/Conductivity/Geometry/CutSlopeGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..1f6aa7291f47589c6da0827955651ac6e95218b3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CutSlopeGradient.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedEndGradientL2 +import OAI.Analysis.Conductivity.Sobolev.CutSlopeH1 + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma differentiable_cut_positive {X : Type*} [NormedAddCommGroup X] [NormedSpace ℝ X] + {χ τ : X → ℝ} {x : X} (hχ : DifferentiableAt ℝ χ x) + (hτ : DifferentiableAt ℝ τ x) (hne : τ x≠0) (κ : ℝ) : + DifferentiableAt ℝ (fun x => κ*(χ x*max 0 (τ x))) x := by + rcases lt_or_gt_of_ne hne with hn | hp + · have he : (fun x => κ*(χ x*max 0 (τ x))) =ᶠ[𝓝 x] (fun _ => 0) := by + filter_upwards [hτ.continuousAt.eventually (gt_mem_nhds hn)] with y hy + simp [max_eq_left hy.le] + exact (differentiableAt_const (0:ℝ)).congr_of_eventuallyEq he + · have he : (fun x => κ*(χ x*max 0 (τ x))) =ᶠ[𝓝 x] (fun x => κ*(χ x*τ x)) := by + filter_upwards [hτ.continuousAt.eventually (lt_mem_nhds hp)] with y hy + rw [max_eq_right hy.le] + exact ((hχ.mul hτ).const_mul κ).congr_of_eventuallyEq he + +lemma fderiv_cut_positive {X : Type*} [NormedAddCommGroup X] [NormedSpace ℝ X] + {χ τ : X → ℝ} {x : X} (hχ : DifferentiableAt ℝ χ x) + (hτ : DifferentiableAt ℝ τ x) (hne : τ x≠0) (κ : ℝ) (v : X) : + fderiv ℝ (fun x => κ*(χ x*max 0 (τ x))) x v= + κ*(fderiv ℝ χ x v*max 0 (τ x)+χ x*(if 0<τ x then fderiv ℝ τ x v else 0)) := by + rcases lt_or_gt_of_ne hne with hn | hp + · have he : (fun x => κ*(χ x*max 0 (τ x))) =ᶠ[𝓝 x] (fun _ => 0) := by + filter_upwards [hτ.continuousAt.eventually (gt_mem_nhds hn)] with y hy + simp [max_eq_left hy.le] + rw [he.fderiv_eq,fderiv_const_apply] + simp [max_eq_left hn.le,not_lt_of_ge hn.le] + · have he : (fun x => κ*(χ x*max 0 (τ x))) =ᶠ[𝓝 x] (fun x => κ*(χ x*τ x)) := by + filter_upwards [hτ.continuousAt.eventually (lt_mem_nhds hp)] with y hy + rw [max_eq_right hy.le] + have hh := ((hχ.hasFDerivAt.mul hτ.hasFDerivAt).const_mul κ).fderiv + simp only [Pi.mul_apply] at hh + rw [he.fderiv_eq,hh] + simp [smul_apply,add_apply,smul_eq_mul,max_eq_right hp.le,hp] + ring + +theorem compact_collar_slope_value_gradient {χ : (Fin 3 → ℝ) → ℝ} + (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {a : ℝ} (ha : a≠0) {b : ℝ} (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (κ l r : ℝ) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand l r) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=κ*(χ (WithLp.ofLp x)*max 0 (a*(sourceCollarTime (WithLp.ofLp x)-b))) ∧ + ∀ i,weakGradient w x i=κ*(fderiv ℝ χ (WithLp.ofLp x) (Pi.single i 1)*max 0 (a*(sourceCollarTime (WithLp.ofLp x)-b))+ + χ (WithLp.ofLp x)*(if 0 a*(sourceCollarTime y-b)) (WithLp.ofLp x) (Pi.single i 1) else 0))) := by + obtain ⟨w,hw,hwe⟩ := compact_collar_slope_H1 hχ hc hχb a b κ l r hl hr hχs + refine ⟨w,hw,?_⟩ + obtain ⟨K,hK⟩ := attachedEndTime_lipschitz a b + have hd := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (hK.ae_differentiableAt (μ:=volume))) + have hn := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + (sourceColevel_ae_ne hb)) + filter_upwards [hwe,hd,hn] with x hx hd hn + refine ⟨hx.1,fun i => ?_⟩ + have hne : a*(sourceCollarTime (WithLp.ofLp x)-b)≠0 := mul_ne_zero ha (sub_ne_zero.mpr hn) + have hχd := hχ.differentiable (by simp) (WithLp.ofLp x) + have hD := differentiable_cut_positive hχd hd hne κ + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hE := hD.hasFDerivAt.comp x E.hasFDerivAt + simp only [Function.comp_def] at hE + rw [hx.2 i,hE.differentiableAt.lineDeriv_eq_fderiv,hE.fderiv,ContinuousLinearMap.comp_apply] + have hi : E.toContinuousLinearMap (EuclideanSpace.single i 1)=Pi.single i 1 := rfl + rw [hi] + exact fderiv_cut_positive hχd hd hne κ _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CylinderJetOrthogonal.lean b/lean/OAI/Analysis/Conductivity/Geometry/CylinderJetOrthogonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..d2fff01aaa13bac08fb0f2aa62d0f3058316fab3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CylinderJetOrthogonal.lean @@ -0,0 +1,159 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.PoissonTraceRate +import OAI.Analysis.Conductivity.Fourier.CylinderModeGreen + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +abbrev FiniteAxisJets (R : ℝ) := PiLp 2 (fun _ : Fin 4 => FiniteAxisL2 R) + +def cylinderJetMode (R : ℝ) (h : TorusModes) : + FiniteAxisJets R →ₗᵢ[ℂ] FiniteCylinderJets R where + toFun q := WithLp.toLp 2 (fun j => cylinderMode (FiniteAxisMeasure R) h (q j)) + map_add' q r := by + apply PiLp.ext + intro j + exact map_add (cylinderMode (FiniteAxisMeasure R) h) (q j) (r j) + map_smul' c q := by + apply PiLp.ext + intro j + exact map_smul (cylinderMode (FiniteAxisMeasure R) h) c (q j) + norm_map' q := by + have he : ‖WithLp.toLp 2 (fun j => cylinderMode (FiniteAxisMeasure R) h (q j))‖^2=‖q‖^2 := by + simp only [PiLp.norm_sq_eq_of_L2,LinearIsometry.norm_map] + exact (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp he + +lemma cylinderJetMode_orthogonal (R : ℝ) : + OrthogonalFamily ℂ (fun _ : TorusModes => FiniteAxisJets R) (cylinderJetMode R) := by + intro h k hne q r + rw [PiLp.inner_apply] + have hz (j : Fin 4) : inner ℂ ((cylinderJetMode R h q) j) ((cylinderJetMode R k r) j)=0 := + cylinderMode_orthogonal (FiniteAxisMeasure R) hne (q j) (r j) + simp only [hz,Finset.sum_const_zero] + +def smoothAxisModeJet {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) : FiniteAxisJets R := + WithLp.toLp 2 ![smoothFiniteAxisLp hq.continuous R, + smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R, + (Complex.I*(h 0:ℂ))•smoothFiniteAxisLp hq.continuous R, + (Complex.I*(h 1:ℂ))•smoothFiniteAxisLp hq.continuous R] + +lemma cylinderJetMode_smooth {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) : + cylinderJetMode R h (smoothAxisModeJet hq R h)=smoothCylinderModeJet hq R h := by + ext j + fin_cases j <;> rfl + +lemma smoothAxisModeJet_norm_sq {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) : + ‖smoothAxisModeJet hq R h‖^2= + ‖smoothFiniteAxisLp (hq.continuous_deriv (by simp)) R‖^2+ + (1+(h 0:ℝ)^2+(h 1:ℝ)^2)*‖smoothFiniteAxisLp hq.continuous R‖^2 := by + rw [PiLp.norm_sq_eq_of_L2] + simp only [smoothAxisModeJet,Fin.sum_univ_succ,Fin.sum_univ_zero,WithLp.ofLp_toLp, + Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two,Matrix.cons_val_three, + Matrix.head_cons,Matrix.tail_cons,Fin.succ_zero_eq_one,Fin.succ_one_eq_two,show (2:Fin 3).succ=(3:Fin 4) by rfl,norm_smul,norm_mul, + Complex.norm_I,one_mul,mul_pow,add_zero] + have hh (j : Fin 2) : ‖(h j:ℂ)‖^2=(h j:ℝ)^2 := by + rw [show (h j:ℂ)=((h j:ℝ):ℂ) by norm_cast,Complex.norm_real,Real.norm_eq_abs,sq_abs] + rw [hh,hh] + ring + +lemma smoothCylinder_polynomial_norm_sq (q : TorusModes → ℝ → ℂ) + (hq : ∀ h,ContDiff ℝ (↑(⊤:ℕ∞)) (q h)) (R : ℝ) (F : Finset TorusModes) : + ‖∑ h∈F,smoothCylinderModeJet (hq h) R h‖^2= + ∑ h∈F,(‖smoothFiniteAxisLp ((hq h).continuous_deriv (by simp)) R‖^2+ + (1+(h 0:ℝ)^2+(h 1:ℝ)^2)*‖smoothFiniteAxisLp (hq h).continuous R‖^2) := by + simp_rw [←cylinderJetMode_smooth] + rw [(cylinderJetMode_orthogonal R).norm_sum] + exact Finset.sum_congr rfl (fun h _ => smoothAxisModeJet_norm_sq (hq h) R h) + +lemma smoothFiniteAxisLp_norm_sq {q : ℝ → ℂ} (hq : Continuous q) {R : ℝ} (hR : 0≤R) : + ‖smoothFiniteAxisLp hq R‖^2=∫ t in (0:ℝ)..R,‖q t‖^2 := by + rw [complexLp_norm_sq,intervalIntegral.integral_of_le hR] + apply integral_congr_ae + filter_upwards [smoothFiniteAxisLp_ae hq R] with t ht + rw [ht] + +lemma complex_fourier_mode_trace_energy_right {q : ℝ → ℂ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) {R m : ℝ} (hR : 0 q (R-t)) := + hq.comp (contDiff_const.sub contDiff_id) + have hd (t : ℝ) : deriv (fun u => q (R-u)) t= -(deriv q (R-t)) := by + have hi : HasDerivAt (fun u : ℝ => R-u) (-1) t := by + simpa using (hasDerivAt_id t).const_sub R + simpa only [Function.comp_def,neg_smul,one_smul] using + (((hq.differentiable (by simp) (R-t)).hasDerivAt).scomp t hi).deriv + have hb := complex_fourier_mode_trace_energy hf hR hm + simp only [sub_zero,hd,norm_neg] at hb + have hi := intervalIntegral.integral_comp_sub_left + (fun t => ‖deriv q t‖^2+(1+m^2)*‖q t‖^2) (a:=0) (b:=R) R + rw [sub_self,sub_zero] at hi + rw [hi] at hb + exact hb + +def cylinderTraceConstant (s : Fin 3 → ℝ) (R : ℝ) : ℝ := + (1+1/R)*(3+2*(|s 0|+|s 1|+|s 2|)) + +lemma cylinderTraceConstant_pos (s : Fin 3 → ℝ) {R : ℝ} (hR : 0 ‖deriv q t‖^2) volume 0 R := + (hd.norm.pow 2).intervalIntegrable _ _ + have hU : IntervalIntegrable (fun t => (1+(1+torusRate s h)^2)*‖q t‖^2) volume 0 R := + (continuous_const.mul (hq.continuous.norm.pow 2)).intervalIntegrable _ _ + rw [intervalIntegral.integral_add hD hU, + intervalIntegral.integral_const_mul,←smoothFiniteAxisLp_norm_sq hd hR.le, + ←smoothFiniteAxisLp_norm_sq hq.continuous hR.le,smoothAxisModeJet_norm_sq] + let C := |s 0|+|s 1|+|s 2| + let n := (h 0:ℝ)^2+(h 1:ℝ)^2 + have hC : 0≤C := by dsimp [C]; positivity + have hn : 0≤n := by dsimp [n]; positivity + have hm := torusRate_sq_polynomial_bound s h + change (torusRate s h)^2≤C*n at hm + have hb : 1+(1+torusRate s h)^2≤3+2*C*n := by + nlinarith [sq_nonneg (torusRate s h-1)] + have hb' : 1+(1+torusRate s h)^2≤(3+2*C)*(1+(h 0:ℝ)^2+(h 1:ℝ)^2) := by + have hcn : 0≤3*n := mul_nonneg (by norm_num) hn + dsimp [n] at * + nlinarith + have hz := mul_le_mul_of_nonneg_right hb' (sq_nonneg ‖smoothFiniteAxisLp hq.continuous R‖) + have hy := mul_le_mul_of_nonneg_right (show (1:ℝ)≤3+2*C by linarith) + (sq_nonneg ‖smoothFiniteAxisLp hd R‖) + dsimp only [C] at hz hy + nlinarith only [hz,hy] + +lemma smoothAxisMode_trace_left (s : Fin 3 → ℝ) + {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) {R : ℝ} (hR : 0 (f x : ℂ)) t).im=0 := by + by_cases h : DifferentiableAt ℝ (fun x => (f x:ℂ)) t + · have hh := (Complex.imCLM.hasFDerivAt).comp_hasDerivAt t h.hasDerivAt + have he := hh.deriv + have heq : Complex.imCLM ∘ (fun x => (f x:ℂ)) = fun _ => (0:ℝ) := by + funext x; rfl + rw [heq,deriv_const] at he + exact he.symm + · rw [deriv_zero_of_not_differentiableAt h,Complex.zero_im] + +lemma sourceAngularJet_im (f : (Fin 3 → ℝ) → ℝ) (a b : ℝ) + (j : Fin 4) (z : ℝ × UnitAddTorus (Fin 2)) : + (sourceAngularJet f a b j z).im=0 := by + have hd (k : Fin 2) : (torusDirectionalDerivative + (fun θ => sourceAngularTest f a b (z.1,θ)) k z.2).im=0 := + deriv_ofReal_im_zero _ _ + fin_cases j + · rfl + · rfl + · change (torusDirectionalDerivative _ 0 z.2 / (2*Real.pi:ℂ)).im=0 + simp [Complex.div_im,hd] + · change (torusDirectionalDerivative _ 1 z.2 / (2*Real.pi:ℂ)).im=0 + simp [Complex.div_im,hd] + +lemma flatCylinderMatrix_mixed (s u v : Fin 3 → ℝ) : + u ⬝ᵥ (flatCylinderMatrix s*ᵥv)= + u 0*v 0+s 0*(u 1*v 1)+s 1*(u 1*v 2+u 2*v 1)+s 2*(u 2*v 2) := by + simp [flatCylinderMatrix,Matrix.mulVec,dotProduct,Fin.sum_univ_succ] + ring + +lemma cylinderSlopeJet_covector_ae (r R : ℝ) (k : Fin 3) : + cylinderSlopeJet r R k.succ=ᵐ[(FiniteAxisMeasure R).prod volume] + fun _ => ((r • Pi.single 0 (1:ℝ)) k : ℂ) := by + fin_cases k + · change (cylinderSlopeJet r R 1)=ᵐ[(FiniteAxisMeasure R).prod volume] + (fun _ => (((r • Pi.single 0 (1:ℝ)) (0:Fin 3)):ℂ)) + simp only [Pi.smul_apply,Pi.single_apply,ite_true,smul_eq_mul,mul_one] + rw [cylinderSlopeJet_derivative] + have h1 := cylinderTensor_ae + (smoothFiniteAxisLp (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R) (mFourierLp 2 0) + have h2 := (Measure.quasiMeasurePreserving_fst (μ:=FiniteAxisMeasure R) + (ν:=(volume : Measure (UnitAddTorus (Fin 2))))).ae + (smoothFiniteAxisLp_ae (continuous_const : Continuous (fun _ : ℝ => (r:ℂ))) R) + have h3 := (Measure.quasiMeasurePreserving_snd (μ:=FiniteAxisMeasure R) + (ν:=(volume : Measure (UnitAddTorus (Fin 2))))).ae (coeFn_mFourierLp 2 0) + filter_upwards [h1,h2,h3] with z hz ht hθ + change cylinderTensor _ _ z=_ + rw [hz,ht,hθ] + simp [mFourier] + · change (cylinderSlopeJet r R 2)=ᵐ[(FiniteAxisMeasure R).prod volume] + (fun _ => (((r • Pi.single 0 (1:ℝ)) (1:Fin 3)):ℂ)) + simp only [Pi.smul_apply,Pi.single_apply,show (1:Fin 3)≠0 by decide, + ite_false,smul_eq_mul,mul_zero,Complex.ofReal_zero] + rw [(cylinderSlopeJet_angular r R).1] + filter_upwards [Lp.coeFn_zero (ℂ) 2 ((FiniteAxisMeasure R).prod volume)] with z hz + exact hz + · change (cylinderSlopeJet r R 3)=ᵐ[(FiniteAxisMeasure R).prod volume] + (fun _ => (((r • Pi.single 0 (1:ℝ)) (2:Fin 3)):ℂ)) + simp only [Pi.smul_apply,Pi.single_apply,show (2:Fin 3)≠0 by decide, + ite_false,smul_eq_mul,mul_zero,Complex.ofReal_zero] + rw [(cylinderSlopeJet_angular r R).2] + filter_upwards [Lp.coeFn_zero (ℂ) 2 ((FiniteAxisMeasure R).prod volume)] with z hz + exact hz + +lemma cylinderEndJet_covector_ae (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (r R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) : + ∀ᵐ z∂(FiniteAxisMeasure R).prod volume, + (fun k : Fin 3 => (cylinderEndJet s hs r R hR f k.succ z).re)= + fullEndFlatCovector s f r z.1 z.2 := by + have h (k : Fin 3) : ∀ᵐ z∂(FiniteAxisMeasure R).prod volume, + (cylinderEndJet s hs r R hR f k.succ z).re=fullEndFlatCovector s f r z.1 z.2 k := by + filter_upwards [Lp.coeFn_add (endPoissonJet s hs R hR f k.succ) + (cylinderSlopeJet r R k.succ),endPoissonJet_ae s hs R hR f k.succ, + cylinderSlopeJet_covector_ae r R k] with z hz hp hr + change ((endPoissonJet s hs R hR f k.succ+cylinderSlopeJet r R k.succ) z).re=_ + rw [hz] + simp only [Pi.add_apply,hp,hr,Complex.add_re,Complex.ofReal_re,fullEndFlatCovector] + filter_upwards [ae_all_iff.mpr h] with z hz + exact funext hz + +lemma flatCylinderEnergy_real_integral (s : Fin 3 → ℝ) {R : ℝ} + (u v : FiniteCylinderJets R) + (hv : ∀ k : Fin 3,∀ᵐ z∂(FiniteAxisMeasure R).prod volume,(v k.succ z).im=0) : + Integrable (fun z => (fun k : Fin 3 => (u k.succ z).re) ⬝ᵥ + (flatCylinderMatrix s*ᵥ(fun k : Fin 3 => (v k.succ z).re))) + ((FiniteAxisMeasure R).prod volume) ∧ + (flatCylinderEnergy s u v).re= + ∫ z,(fun k : Fin 3 => (u k.succ z).re) ⬝ᵥ + (flatCylinderMatrix s*ᵥ(fun k : Fin 3 => (v k.succ z).re)) + ∂(FiniteAxisMeasure R).prod volume := by + let P (i j : Fin 4) := fun z => inner ℂ (u i z) (v j z) + have hP (i j : Fin 4) : Integrable (P i j) ((FiniteAxisMeasure R).prod volume) := + L2.integrable_inner (𝕜:=ℂ) _ _ + let F := fun z => P 1 1 z+(s 0:ℂ)*P 2 2 z+ + (s 1:ℂ)*(P 2 3 z+P 3 2 z)+(s 2:ℂ)*P 3 3 z + have hF : Integrable F ((FiniteAxisMeasure R).prod volume) := + (((hP 1 1).add ((hP 2 2).const_mul (s 0:ℂ))).add + (((hP 2 3).add (hP 3 2)).const_mul (s 1:ℂ))).add ((hP 3 3).const_mul (s 2:ℂ)) + have he : (fun z => (F z).re)=ᵐ[(FiniteAxisMeasure R).prod volume] + (fun z => (fun k : Fin 3 => (u k.succ z).re) ⬝ᵥ + (flatCylinderMatrix s*ᵥ(fun k : Fin 3 => (v k.succ z).re))) := by + filter_upwards [hv 0,hv 1,hv 2] with z h1 h2 h3 + change (v 1 z).im=0 at h1 + change (v 2 z).im=0 at h2 + change (v 3 z).im=0 at h3 + rw [flatCylinderMatrix_mixed] + simp [F,P,RCLike.inner_apply,Complex.mul_re,h1,h2,h3] + ring + refine ⟨hF.re.congr he,?_⟩ + rw [←integral_congr_ae he] + change _ = ∫ z,RCLike.re (F z) ∂(FiniteAxisMeasure R).prod volume + rw [integral_re hF] + congr 1 + change flatCylinderEnergy s u v = ∫ z,F z ∂(FiniteAxisMeasure R).prod volume + unfold F + rw [integral_add (f:=fun z => P 1 1 z+(s 0:ℂ)*P 2 2 z+ + (s 1:ℂ)*(P 2 3 z+P 3 2 z)) (g:=fun z => (s 2:ℂ)*P 3 3 z) + (((hP 1 1).add ((hP 2 2).const_mul (s 0:ℂ))).add + (((hP 2 3).add (hP 3 2)).const_mul (s 1:ℂ))) ((hP 3 3).const_mul (s 2:ℂ)), + integral_add (f:=fun z => P 1 1 z+(s 0:ℂ)*P 2 2 z) + (g:=fun z => (s 1:ℂ)*(P 2 3 z+P 3 2 z)) + ((hP 1 1).add ((hP 2 2).const_mul (s 0:ℂ))) + (((hP 2 3).add (hP 3 2)).const_mul (s 1:ℂ)), + integral_add (f:=P 1 1) (g:=fun z => (s 0:ℂ)*P 2 2 z) + (hP 1 1) ((hP 2 2).const_mul (s 0:ℂ)),integral_const_mul, + integral_const_mul,integral_const_mul,integral_add (hP 2 3) (hP 3 2)] + rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/CylinderPolynomial.lean b/lean/OAI/Analysis/Conductivity/Geometry/CylinderPolynomial.lean new file mode 100644 index 0000000000000000000000000000000000000000..2bd92140dc63d1f664a734c3cd909bb6ec494b4c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/CylinderPolynomial.lean @@ -0,0 +1,197 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CylinderJetOrthogonal + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def smoothComplexAxis : Submodule ℂ (ℝ → ℂ) where + carrier := {q | ContDiff ℝ (↑(⊤ : ℕ∞)) q} + zero_mem' := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun _ : ℝ => (0:ℂ)) + exact contDiff_const + add_mem' := by + intro q r hq hr + exact (show ContDiff ℝ (↑(⊤ : ℕ∞)) q from hq).add + (show ContDiff ℝ (↑(⊤ : ℕ∞)) r from hr) + smul_mem' := by + intro c q hq + exact (show ContDiff ℝ (↑(⊤ : ℕ∞)) q from hq).const_smul c + +instance : CoeFun smoothComplexAxis (fun _ => ℝ → ℂ) := ⟨fun q => q.val⟩ + +lemma smoothComplexAxis_smooth (q : smoothComplexAxis) : + ContDiff ℝ (↑(⊤ : ℕ∞)) q := q.property + +lemma smoothFiniteAxisLp_add {q r : ℝ → ℂ} (hq : Continuous q) (hr : Continuous r) (R : ℝ) : + smoothFiniteAxisLp (hq.add hr) R=smoothFiniteAxisLp hq R+smoothFiniteAxisLp hr R := by + apply Lp.ext + filter_upwards [smoothFiniteAxisLp_ae (hq.add hr) R,smoothFiniteAxisLp_ae hq R, + smoothFiniteAxisLp_ae hr R,Lp.coeFn_add (smoothFiniteAxisLp hq R) (smoothFiniteAxisLp hr R)] + with t h1 h2 h3 h4 + simp only [h1,h4,h2,h3,Pi.add_apply] + +lemma smoothFiniteAxisLp_smul {q : ℝ → ℂ} (hq : Continuous q) (c : ℂ) (R : ℝ) : + smoothFiniteAxisLp (hq.const_smul c) R=c•smoothFiniteAxisLp hq R := by + apply Lp.ext + filter_upwards [smoothFiniteAxisLp_ae (hq.const_smul c) R,smoothFiniteAxisLp_ae hq R, + Lp.coeFn_smul c (smoothFiniteAxisLp hq R)] with t h1 h2 h3 + simp only [h1,h3,h2,Pi.smul_apply] + +lemma smoothAxisModeJet_add (q r : smoothComplexAxis) (R : ℝ) (h : TorusModes) : + smoothAxisModeJet (smoothComplexAxis_smooth (q+r)) R h= + smoothAxisModeJet (smoothComplexAxis_smooth q) R h+ + smoothAxisModeJet (smoothComplexAxis_smooth r) R h := by + have hd : deriv (fun t => q t+r t)=deriv q+deriv r := by + funext t + exact deriv_add ((smoothComplexAxis_smooth q).differentiable (by simp) t) + ((smoothComplexAxis_smooth r).differentiable (by simp) t) + apply PiLp.ext + intro j + fin_cases j + · exact smoothFiniteAxisLp_add (smoothComplexAxis_smooth q).continuous + (smoothComplexAxis_smooth r).continuous R + · change smoothFiniteAxisLp ((smoothComplexAxis_smooth (q+r)).continuous_deriv (by simp)) R= + smoothFiniteAxisLp ((smoothComplexAxis_smooth q).continuous_deriv (by simp)) R+ + smoothFiniteAxisLp ((smoothComplexAxis_smooth r).continuous_deriv (by simp)) R + simp only [show ((q+r : smoothComplexAxis) : ℝ → ℂ)=(fun t => q t+r t) from rfl,hd] + exact smoothFiniteAxisLp_add _ _ R + · change (Complex.I*(h 0:ℂ))•smoothFiniteAxisLp _ R=_ + rw [smoothFiniteAxisLp_add] + exact smul_add _ _ _ + · change (Complex.I*(h 1:ℂ))•smoothFiniteAxisLp _ R=_ + rw [smoothFiniteAxisLp_add] + exact smul_add _ _ _ + +lemma smoothAxisModeJet_smul (c : ℂ) (q : smoothComplexAxis) (R : ℝ) (h : TorusModes) : + smoothAxisModeJet (smoothComplexAxis_smooth (c•q)) R h= + c•smoothAxisModeJet (smoothComplexAxis_smooth q) R h := by + have hd : deriv (fun t => c•q t)=c•deriv q := by + funext t + exact deriv_const_smul c ((smoothComplexAxis_smooth q).differentiable (by simp) t) + apply PiLp.ext + intro j + fin_cases j + · exact smoothFiniteAxisLp_smul (smoothComplexAxis_smooth q).continuous c R + · change smoothFiniteAxisLp ((smoothComplexAxis_smooth (c•q)).continuous_deriv (by simp)) R= + c•smoothFiniteAxisLp ((smoothComplexAxis_smooth q).continuous_deriv (by simp)) R + simp only [show ((c•q : smoothComplexAxis) : ℝ → ℂ)=(fun t => c•q t) from rfl,hd] + exact smoothFiniteAxisLp_smul _ c R + · change (Complex.I*(h 0:ℂ))•smoothFiniteAxisLp _ R=_ + rw [smoothFiniteAxisLp_smul] + exact smul_comm _ _ _ + · change (Complex.I*(h 1:ℂ))•smoothFiniteAxisLp _ R=_ + rw [smoothFiniteAxisLp_smul] + exact smul_comm _ _ _ + +def smoothAxisModeJetL (R : ℝ) (h : TorusModes) : smoothComplexAxis →ₗ[ℂ] FiniteAxisJets R where + toFun q := smoothAxisModeJet (smoothComplexAxis_smooth q) R h + map_add' q r := smoothAxisModeJet_add q r R h + map_smul' c q := smoothAxisModeJet_smul c q R h + +def cylinderPolynomialJetL (R : ℝ) : (TorusModes →₀ smoothComplexAxis) →ₗ[ℂ] FiniteCylinderJets R := + Finsupp.lsum ℂ (fun h => (cylinderJetMode R h).toLinearMap.comp (smoothAxisModeJetL R h)) + +lemma cylinderPolynomialJetL_apply (R : ℝ) (p : TorusModes →₀ smoothComplexAxis) : + cylinderPolynomialJetL R p= + ∑ h∈p.support,smoothCylinderModeJet (smoothComplexAxis_smooth (p h)) R h := by + rw [cylinderPolynomialJetL,Finsupp.lsum_apply] + exact Finset.sum_congr rfl (fun h _ => cylinderJetMode_smooth _ R h) + +open Set MeasureTheory Filter Topology +open scoped ENNReal + +abbrev SpectralModeFiber := PiLp 2 (fun _ : Fin 2 => ℂ) + +def spectralJetSingle (h : TorusModes) : SpectralModeFiber →ₗᵢ[ℂ] SpectralJet TorusModes where + toFun a := WithLp.toLp 2 (fun j => (lp.single 2 h (a j) : SpectralL2 TorusModes)) + map_add' a b := by + apply PiLp.ext + intro j + exact lp.single_add (E := fun _ : TorusModes => ℂ) 2 h (a j) (b j) + map_smul' c a := by + apply PiLp.ext + intro j + exact lp.single_smul (E := fun _ : TorusModes => ℂ) 2 h c (a j) + norm_map' a := by + have he : ‖WithLp.toLp 2 (fun j : Fin 2 => (lp.single 2 h (a j) : SpectralL2 TorusModes))‖^2=‖a‖^2 := by + simp only [PiLp.norm_sq_eq_of_L2,lp.norm_single (by norm_num : (0:ℝ≥0∞)<2)] + exact (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp he + +lemma spectralJetSingle_orthogonal : + OrthogonalFamily ℂ (fun _ : TorusModes => SpectralModeFiber) spectralJetSingle := by + intro h k hne a b + rw [PiLp.inner_apply] + have hz (j : Fin 2) : inner ℂ (lp.single 2 h (a j) : SpectralL2 TorusModes) (lp.single 2 k (b j))=0 := by + rw [lp.inner_single_left,lp.single_apply,Pi.single_eq_of_ne hne,inner_zero_right] + exact (Finset.sum_congr rfl (fun j _ => hz j)).trans (Finset.sum_const_zero) + +def weightedModeFiberL (s : Fin 3 → ℝ) (h : TorusModes) : ℂ →ₗ[ℂ] SpectralModeFiber where + toFun a := WithLp.toLp 2 ![a,(Real.sqrt (torusRate s h):ℂ)*a] + map_add' a b := by apply PiLp.ext; intro j; fin_cases j <;> simp [mul_add] + map_smul' c a := by + apply PiLp.ext + intro j + fin_cases j <;> simp [mul_comm,mul_assoc] + +lemma weightedModeFiber_norm_sq (s : Fin 3 → ℝ) (h : TorusModes) (a : ℂ) : + ‖weightedModeFiberL s h a‖^2=(1+torusRate s h)*‖a‖^2 := by + rw [PiLp.norm_sq_eq_of_L2] + change (∑ j : Fin 2,‖(![a,(Real.sqrt (torusRate s h):ℂ)*a] j)‖^2)=_ + simp only [Fin.sum_univ_two,Matrix.cons_val_zero, + Matrix.cons_val_one,norm_mul,mul_pow,Complex.norm_real,Real.norm_eq_abs, + abs_of_nonneg (Real.sqrt_nonneg _),Real.sq_sqrt (show 0≤torusRate s h from Real.sqrt_nonneg _)] + ring + +def spectralTraceSingleL (s : Fin 3 → ℝ) (h : TorusModes) : + ℂ →ₗ[ℂ] spectralTraceGraph (torusRate s) := + ((spectralJetSingle h).toLinearMap.comp (weightedModeFiberL s h)).codRestrict _ (by + intro a k + change (lp.single 2 h ((Real.sqrt (torusRate s h):ℂ)*a) : SpectralL2 TorusModes) k= + (Real.sqrt (torusRate s k):ℂ)*(lp.single 2 h a : SpectralL2 TorusModes) k + by_cases hk : k=h + · subst k; simp + · simp only [lp.single_apply,Pi.single_eq_of_ne hk,mul_zero]) + +def cylinderPolynomialTraceL (s : Fin 3 → ℝ) (t : ℝ) : + (TorusModes →₀ smoothComplexAxis) →ₗ[ℂ] spectralTraceGraph (torusRate s) := + Finsupp.lsum ℂ (fun h => (spectralTraceSingleL s h).comp + ((LinearMap.proj t).comp smoothComplexAxis.subtype)) + +lemma cylinderPolynomialTraceL_apply (s : Fin 3 → ℝ) (t : ℝ) + (p : TorusModes →₀ smoothComplexAxis) : + (cylinderPolynomialTraceL s t p).val= + ∑ h∈p.support,spectralJetSingle h (weightedModeFiberL s h (p h t)) := by + rw [cylinderPolynomialTraceL,Finsupp.lsum_apply] + change (spectralTraceGraph (torusRate s)).subtype (∑ h∈p.support,_)=_ + rw [map_sum] + rfl + +lemma cylinderPolynomialTraceL_norm_sq (s : Fin 3 → ℝ) (t : ℝ) + (p : TorusModes →₀ smoothComplexAxis) : + ‖cylinderPolynomialTraceL s t p‖^2= + ∑ h∈p.support,(1+torusRate s h)*‖p h t‖^2 := by + change ‖(cylinderPolynomialTraceL s t p).val‖^2=_ + rw [cylinderPolynomialTraceL_apply,spectralJetSingle_orthogonal.norm_sum] + exact Finset.sum_congr rfl (fun h _ => weightedModeFiber_norm_sq s h (p h t)) + +lemma cylinderPolynomial_trace_bound (s : Fin 3 → ℝ) {R : ℝ} (hR : 0 linarith + +lemma sourceExtendedBox_injOn (i j : Fin 4) {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + InjOn (sourceCollarPiece i j) (sourceExtendedBox l r) := by + have hi (x : Fin 3 → ℝ) (hx : x∈sourceExtendedBox l r) : + sourceCollarInverse i j (sourceCollarPiece i j x)=x := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + exact sourceCollarInverse_left_pos i j + (lt_of_lt_of_le (by norm_num : (0:ℝ)<1/50) + (sourceCollarRadius_extended j ⟨hl.trans ht.1,ht.2.trans hr⟩ hb).1) + (by linarith [ht.2]) ha hb + intro x hx y hy he + apply_fun sourceCollarInverse i j at he + rwa [hi x hx,hi y hy] at he + +lemma sourceExtended_jacobian_lower (i j : Fin 4) {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + {x : Fin 3 → ℝ} (hx : x∈sourceExtendedBox l r) : + (1:ℝ)/100≤abs ((sourceCollarDerivative i j x).det) := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + have ht' : x 0∈Icc (-(1:ℝ)/100) (1/100) := ⟨hl.trans ht.1,ht.2.trans hr⟩ + have hR := (sourceCollarRadius_extended j ht' hb).1 + rw [sourceCollarDerivative_det] + have he : -sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0)= + -(sourceLength*sourceCollarRadius j (x 0) (x 2)*sourceRadialWidth*(1-x 0)) := by ring + rw [he,abs_neg,abs_of_nonneg (by + have : 0≤ sourceCollarRadius j (x 0) (x 2) := by linarith + have : 0≤1-x 0 := by linarith [ht'.2] + norm_num [sourceLength,sourceRadialWidth,sourceHole]; positivity)] + have hh := mul_le_mul hR (show (99:ℝ)/100≤1-x 0 by linarith [ht'.2]) + (by norm_num : (0:ℝ)≤99/100) (by linarith : 0≤ sourceCollarRadius j (x 0) (x 2)) + norm_num [sourceLength,sourceRadialWidth,sourceHole] + nlinarith + +theorem sourceExtended_integral {F : Type*} [NormedAddCommGroup F] [NormedSpace ℝ F] + (i j : Fin 4) {l r : ℝ} (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (g : (Fin 3 → ℝ) → F) : + (∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y)= + ∫ x in sourceExtendedBox l r,abs ((sourceCollarDerivative i j x).det) • + g (sourceCollarPiece i j x) := by + exact integral_image_eq_integral_abs_det_fderiv_smul volume measurableSet_Icc + (fun x _ => (sourceCollarPiece_hasFDeriv i j x).hasFDerivWithinAt) + (sourceExtendedBox_injOn i j hl hr) g + +lemma squareFace_abs_le (i : Fin 4) {a : ℝ} (ha : |a|≤1) (k : Fin 2) : + |squareFace i a k|≤1 := by + fin_cases k + · exact (le_max_left _ _).trans (squareFace_max i ha).le + · exact (le_max_right _ _).trans (squareFace_max i ha).le + +lemma sourceRadius_trim_bounds (j : Fin 4) {t b : ℝ} + (ht : centralThickness≤t ∧ t≤2*centralThickness) (hb : |b|≤1) : + centralInnerY≤ sourceCollarRadius j t b ∧ sourceCollarRadius j t b≤centralOuterY := by + have hq := squareFace_abs_le j hb 0 + have hqt : |(1-t)*squareFace j b 0|≤1-centralThickness := by + have ht0 : 0≤1-t := by norm_num [centralThickness] at ht; linarith + rw [abs_mul,abs_of_nonneg ht0] + have hh := mul_le_mul_of_nonneg_left hq ht0 + linarith [ht.1] + have hh := abs_le.mp hqt + dsimp [sourceCollarRadius,centralInnerY,centralOuterY,sourceRadialCenter,sourceRadialWidth,sourceHole,centralThickness] at * + constructor <;> linarith + +def sourcePairCoordinates (y : Fin 3 → ℝ) : Box3 := ((y 0,y 1),y 2) + +lemma sourceParentCollar_parent (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox centralThickness (2*centralThickness)) : + centralParentFootprint (sourcePairCoordinates (sourceCollarPiece i j x)).1 ∧ + |(sourcePairCoordinates (sourceCollarPiece i j x)).2|≤centralHeight := by + obtain ⟨ht,ha,hb⟩ := mem_sourceExtendedBox.mp hx + have hr := sourceRadius_trim_bounds j ht hb + have hr0 : 0≤ sourceCollarRadius j (x 0) (x 2) := by + have hh : 0 apply Or.inl + · norm_num [centralChildOuterX,sourceScale,sourceRadialWidth,sourceHole,centralThickness,sourceOffset] at * + linarith + · norm_num [centralChildOuterX,sourceScale,sourceRadialWidth,sourceHole,centralThickness,sourceOffset] at * + linarith + · have he : |(sourceCollarPiece i 0 x) 1|=sourceCollarRadius 0 (x 0) (x 2) := by + simp only [sourceCollarPiece,Matrix.cons_val_one,Matrix.cons_val_zero,abs_mul,abs_of_nonneg hr0] + rw [←h.1,hm,mul_one] + have hh : centralChildOuterY≤|(sourceCollarPiece i 0 x) 1| := by + rw [he] + norm_num [centralChildOuterY,sourceScale,sourceLength,sourceRadialWidth,sourceHole,centralThickness] + linarith + exact ⟨Or.inr (Or.inl hh),Or.inr (Or.inl hh)⟩ + · left + simp only [sourceCollarPiece,Matrix.cons_val_two,squareFace,squareFaceBase,squareFaceDirection, + Pi.add_apply,Pi.smul_apply,smul_eq_mul] + norm_num [centralChildHeight,sourceScale,centralThickness] at ht ⊢ + linarith [le_abs_self (1-x 0),neg_le_abs (x 0-1)] + · right + change 0≤ sourceCollarRadius 2 (x 0) (x 2) at hr0 + have hsmall : sourceCollarRadius 2 (x 0) (x 2)≤(31:ℝ)/1000 := by + change sourceRadialCenter+sourceRadialWidth*(1-x 0)*((-1:ℝ)+x 2*0)≤31/1000 + norm_num [sourceRadialCenter,sourceRadialWidth,sourceHole,centralThickness] at ht ⊢ + linarith + have hq := squareFace_abs_le i ha 0 + have hsmall' : |(sourceCollarPiece i 2 x) 0|≤(1:ℝ)/20 := by + simp only [sourceCollarPiece,Matrix.cons_val_zero,abs_mul,abs_of_pos hL,abs_of_nonneg hr0] + norm_num [sourceLength] + nlinarith + have hlow1 := abs_sub_le sourceOffset ((sourceCollarPiece i 2 x) 0) + have hlow2 := abs_sub_le (-sourceOffset) ((sourceCollarPiece i 2 x) 0) + have htri1 := abs_add_le (sourceOffset-(sourceCollarPiece i 2 x) 0) ((sourceCollarPiece i 2 x) 0) + have htri2 := abs_add_le (-sourceOffset-(sourceCollarPiece i 2 x) 0) ((sourceCollarPiece i 2 x) 0) + simp only [sub_add_cancel,abs_sub_comm sourceOffset,abs_sub_comm (-sourceOffset)] at htri1 htri2 + have hc1 : centralChildOuterX≤|(sourceCollarPiece i 2 x) 0-sourceOffset| := by + norm_num [centralChildOuterX,sourceScale,sourceRadialWidth,sourceHole,centralThickness,sourceOffset] at * + linarith + have hc2 : centralChildOuterX≤|(sourceCollarPiece i 2 x) 0+sourceOffset| := by + norm_num [centralChildOuterX,sourceScale,sourceRadialWidth,sourceHole,centralThickness,sourceOffset] at * + linarith + exact ⟨Or.inl (by simpa using hc1),Or.inl (by simpa using hc2)⟩ + · left + simp only [sourceCollarPiece,Matrix.cons_val_two,squareFace,squareFaceBase,squareFaceDirection, + Pi.add_apply,Pi.smul_apply,smul_eq_mul] + norm_num [centralChildHeight,sourceScale,centralThickness] at ht ⊢ + linarith [le_abs_self (1-x 0),neg_le_abs (x 0-1)] + +theorem sourceParentCollar_central (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceExtendedBox centralThickness (2*centralThickness)) : + sourcePairCoordinates (sourceCollarPiece i j x)∈centralClosed := + ⟨(sourceParentCollar_parent i j hx).1,(sourceParentCollar_parent i j hx).2, + sourceParentCollar_avoids i j hx⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/FlatTorusPDE.lean b/lean/OAI/Analysis/Conductivity/Geometry/FlatTorusPDE.lean new file mode 100644 index 0000000000000000000000000000000000000000..ef2e86fc9fa55df5389ae20639aed498436e8f60 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/FlatTorusPDE.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusFourierSmooth + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def expCosLinear (L K : E →L[ℝ] ℝ) (p : ℝ) (x : E) : ℝ := exp (L x)*cos (K x+p) + +lemma expCosLinear_deriv (L K : E →L[ℝ] ℝ) (p : ℝ) (x : E) : + HasFDerivAt (expCosLinear L K p) + (expCosLinear L K p x • L + expCosLinear L K (p+Real.pi/2) x • K) x := by + have hh := (L.hasFDerivAt (x := x)).exp.mul ((K.hasFDerivAt.add_const p).cos) + convert hh using 1 <;> ext v <;> + simp [smul_eq_mul,expCosLinear,Pi.mul_apply,←add_assoc,cos_add_pi_div_two] + ring + +lemma expCosLinear_fderiv (L K : E →L[ℝ] ℝ) (p : ℝ) (x v : E) : + fderiv ℝ (expCosLinear L K p) x v = + expCosLinear L K p x*L v+expCosLinear L K (p+Real.pi/2) x*K v := by + rw [(expCosLinear_deriv L K p x).fderiv] + rfl + +lemma expCosLinear_hessian (L K : E →L[ℝ] ℝ) (p : ℝ) (x v w : E) : + (iteratedFDeriv ℝ 2 (expCosLinear L K p) x) ![v,w] = + (L v*L w-K v*K w)*expCosLinear L K p x+ + (L v*K w+K v*L w)*expCosLinear L K (p+Real.pi/2) x := by + have hd : DifferentiableAt ℝ (fderiv ℝ (expCosLinear L K p)) x := by + have hc : ContDiff ℝ 2 (expCosLinear L K p) := by unfold expCosLinear; fun_prop + exact (hc.fderiv_right (m := 1) (by norm_num)).differentiable (by norm_num) x + have he := fderiv_clm_apply (c := fderiv ℝ (expCosLinear L K p)) hd + (differentiableAt_const (c := w)) + have hfun : (fun y => fderiv ℝ (expCosLinear L K p) y w)= + fun y => expCosLinear L K p y*L w+expCosLinear L K (p+Real.pi/2) y*K w := by + funext y + exact expCosLinear_fderiv L K p y w + rw [hfun] at he + have hh := ((expCosLinear_deriv L K p x).mul_const (L w)).add + ((expCosLinear_deriv L K (p+Real.pi/2) x).mul_const (K w)) + have hhe := hh.fderiv + change fderiv ℝ (fun y => expCosLinear L K p y*L w+ + expCosLinear L K (p+Real.pi/2) y*K w) x=_ at hhe + rw [hhe] at he + have hv := congrArg (fun A : E →L[ℝ] ℝ => A v) he + rw [iteratedFDeriv_two_apply] + simp only [Matrix.cons_val_zero,Matrix.cons_val_one] + simp only [fderiv_const_apply,ContinuousLinearMap.comp_zero,zero_add, + ContinuousLinearMap.flip_apply,add_apply,smul_apply, + smul_eq_mul] at hv + rw [←hv] + have hp : p+Real.pi/2+Real.pi/2=p+Real.pi := by ring + simp only [expCosLinear,hp,←add_assoc,cos_add_pi] + ring + +def flatAxis (i : Fin 3) : Fin 3 → ℝ := Pi.single i 1 + +def flatTensorLaplacianCLM (s : Fin 3 → ℝ) : + ContinuousMultilinearMap ℝ (fun _ : Fin 2 => Fin 3 → ℝ) ℝ →L[ℝ] ℝ := + ContinuousMultilinearMap.apply ℝ _ ℝ ![flatAxis 0,flatAxis 0]+ + s 0 • ContinuousMultilinearMap.apply ℝ _ ℝ ![flatAxis 1,flatAxis 1]+ + (2*s 1) • ContinuousMultilinearMap.apply ℝ _ ℝ ![flatAxis 1,flatAxis 2]+ + s 2 • ContinuousMultilinearMap.apply ℝ _ ℝ ![flatAxis 2,flatAxis 2] + +def flatTensorLaplacian (s : Fin 3 → ℝ) (f : (Fin 3 → ℝ) → ℝ) (x : Fin 3 → ℝ) : ℝ := + flatTensorLaplacianCLM s (iteratedFDeriv ℝ 2 f x) + +lemma flatPhaseMode_harmonic {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (h : Fin 2 → ℤ) (p : ℝ) (x : Fin 3 → ℝ) : + flatTensorLaplacian s (flatPhaseMode s h p) x=0 := by + let L : (Fin 3 → ℝ) →L[ℝ] ℝ := -torusRate s h • ContinuousLinearMap.proj 0 + have hf : flatPhaseMode s h p=expCosLinear L (torusAngular h) p := rfl + have hsq : torusRate s h^2=torusQuadratic s h := by + apply sq_sqrt + exact (by positivity : 0≤(1/2)*((h 0:ℝ)^2+(h 1:ℝ)^2)).trans (hs _ _) + rw [flatTensorLaplacian,hf] + simp only [flatTensorLaplacianCLM,add_apply, + smul_apply,ContinuousMultilinearMap.apply_apply,smul_eq_mul, + expCosLinear_hessian] + simp only [L,torusAngular,add_apply,smul_apply, + ContinuousLinearMap.proj_apply,flatAxis,Pi.single_apply,smul_eq_mul] + simp only [show (0:Fin 3)≠2 by decide,show (1:Fin 3)≠2 by decide, + show (2:Fin 3)≠1 by decide,show (2:Fin 3)≠0 by decide, + show (0:Fin 3)≠1 by decide,show (1:Fin 3)≠0 by decide, + ite_true,ite_false,mul_zero,zero_mul,mul_one,add_zero,zero_add,sub_zero, + zero_sub,neg_mul,neg_neg,mul_neg] + dsimp [torusQuadratic] at hsq + have hm := congrArg (fun r => r*expCosLinear L (torusAngular h) p x) hsq + dsimp [L,torusAngular] at hm + linear_combination hm + +lemma weighted_flatPhaseMode_harmonic {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (h : Fin 2 → ℤ) (p a : ℝ) (x : Fin 3 → ℝ) : + flatTensorLaplacian s (fun y => a*flatPhaseMode s h p y) x=0 := by + change flatTensorLaplacianCLM s (iteratedFDeriv ℝ 2 (a • flatPhaseMode s h p) x)=0 + rw [iteratedFDeriv_const_smul_apply + (((contDiff_infty.mp (flatPhaseMode_smooth s h p)) 2).contDiffAt),map_smul] + change a • flatTensorLaplacian s (flatPhaseMode s h p) x=0 + rw [flatPhaseMode_harmonic hs,smul_zero] + +theorem flatFourier_harmonic {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) + {x : Fin 3 → ℝ} (hx : 0 ‖iteratedFDeriv ℝ 2 + (fun y => a h*flatPhaseMode s h (phase h) y) x‖) := + Summable.of_nonneg_of_le (fun h => norm_nonneg _) + (fun h => weighted_phase_halfspace_bound ha 2 h le_rfl) hb + rw [flatTensorLaplacian,flatFourier_iterated hs ha 2 hx, + (flatTensorLaplacianCLM s).map_tsum hn.of_norm] + have hz (h : Fin 2 → ℤ) : flatTensorLaplacianCLM s (iteratedFDeriv ℝ 2 + (fun y => a h*flatPhaseMode s h (phase h) y) x)=0 := + weighted_flatPhaseMode_harmonic hs h (phase h) (a h) x + simp only [hz,tsum_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/InverseChartPiolaOperator.lean b/lean/OAI/Analysis/Conductivity/Geometry/InverseChartPiolaOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..0af6ec2d1828181b310b9333bbac31f6e2794773 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/InverseChartPiolaOperator.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ContDiffClmDet + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +def inverseChartPiolaOperator {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (y : E) : E →L[ℝ] E := + |(fderiv ℝ X.symm (X y)).det|⁻¹ • fderiv ℝ X.symm (X y) + +lemma localPiolaFlux_inverse_eq {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F : E → E) {y : E} (hy : y ∈ X.source) : + localPiolaFlux X.symm F y = inverseChartPiolaOperator X y (F (X y)) := by + simp only [localPiolaFlux, X.symm_symm, show y ∈ X.symm.target from hy, ite_eq_left, + inverseChartPiolaOperator, _root_.smul_apply] + +lemma inverseChartPiolaOperator_continuousAt + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + (X : OpenPartialHomeomorph E E) + (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {a : E} (ha : a ∈ X.source) : ContinuousAt (inverseChartPiolaOperator X) a := by + have hca : ContDiffAt ℝ (↑(⊤ : ℕ∞)) (fderiv ℝ X.symm) (X a) := + ((hXi _ (X.map_source ha)).contDiffAt + (X.open_target.mem_nhds (X.map_source ha))).fderiv_right (by simp) + have hda := ((hX a ha).contDiffAt (X.open_source.mem_nhds ha)).continuousAt + have hd : ContinuousAt (fun y => fderiv ℝ X.symm (X y)) a := hca.continuousAt.comp hda + have hdet0 := local_fderiv_det_ne_zero X.symm (hXi.differentiableOn (by simp)) + (hX.differentiableOn (by simp)) (X.map_source ha) + have hc : ContinuousAt (fun y => (fderiv ℝ X.symm (X y)).det) a := + ((contDiff_clm_det (E := E) (↑(⊤ : ℕ∞))).continuous.continuousAt).comp hd + exact (hc.abs.inv₀ (abs_ne_zero.mpr hdet0)).smul hd + +lemma inverseChartPiolaOperator_eq_id + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) + (hX : DifferentiableOn ℝ X X.source) (hXi : DifferentiableOn ℝ X.symm X.target) + {a : E} (ha : a ∈ X.source) (hDa : fderiv ℝ X a = ContinuousLinearMap.id ℝ E) : + inverseChartPiolaOperator X a = ContinuousLinearMap.id ℝ E := by + have hdi := local_fderiv_symm_comp X hX hXi ha + rw [hDa, ContinuousLinearMap.comp_id] at hdi + simp only [inverseChartPiolaOperator, hdi, ContinuousLinearMap.det, + ContinuousLinearMap.coe_id, LinearMap.det_id, abs_one, inv_one, one_smul] + +theorem inverseChartPiola_freezing + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + (X : OpenPartialHomeomorph E E) + (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {a : E} (ha : a ∈ X.source) (hDa : fderiv ℝ X a = ContinuousLinearMap.id ℝ E) + {ε : ℝ} (hε : 0 < ε) : + ∃ V : Set E, IsOpen V ∧ a ∈ V ∧ V ⊆ X.source ∧ + ∀ (χ h : E → ℝ) (R : E) (y : E), y ∈ V → + ‖localPiolaFlux X.symm (fun z => (χ (X.symm z) * h z) • R) y - + (χ y * h (X y)) • R‖ ≤ ε * (|χ y * h (X y)| * ‖R‖) := by + have heq := inverseChartPiolaOperator_eq_id X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) ha hDa + have hc : ContinuousAt (fun y => inverseChartPiolaOperator X y - + ContinuousLinearMap.id ℝ E) a := + (inverseChartPiolaOperator_continuousAt X hX hXi ha).sub continuousAt_const + have hevent : ∀ᶠ y in 𝓝 a, + ‖inverseChartPiolaOperator X y - ContinuousLinearMap.id ℝ E‖ < ε := by + have ht := hc.norm.eventually (gt_mem_nhds (show + ‖inverseChartPiolaOperator X a - ContinuousLinearMap.id ℝ E‖ < ε by + rw [heq, sub_self, norm_zero]; exact hε)) + exact ht + obtain ⟨V, hVsub, hV, haV⟩ := mem_nhds_iff.mp (hevent.and (X.open_source.mem_nhds ha)) + refine ⟨V, hV, haV, fun y hy => (hVsub hy).2, ?_⟩ + intro χ h R y hy + rw [localPiolaFlux_inverse_eq X _ (hVsub hy).2, X.left_inv (hVsub hy).2] + rw [map_smul] + have hid : (χ y * h (X y)) • (inverseChartPiolaOperator X y R) - + (χ y * h (X y)) • R = + (χ y * h (X y)) • ((inverseChartPiolaOperator X y - ContinuousLinearMap.id ℝ E) R) := by + simp only [_root_.sub_apply, ContinuousLinearMap.id_apply, smul_sub] + rw [hid, norm_smul, Real.norm_eq_abs] + calc + |χ y * h (X y)| * ‖(inverseChartPiolaOperator X y - ContinuousLinearMap.id ℝ E) R‖ ≤ + |χ y * h (X y)| * (ε * ‖R‖) := + mul_le_mul_of_nonneg_left ((ContinuousLinearMap.le_opNorm _ _).trans + (mul_le_mul_of_nonneg_right (hVsub hy).1.le (norm_nonneg _))) (abs_nonneg _) + _ = ε * (|χ y * h (X y)| * ‖R‖) := by ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/LocalFamilyRegionCoordinates.lean b/lean/OAI/Analysis/Conductivity/Geometry/LocalFamilyRegionCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..5c44384e8e708c0bf9ec6adfdedaf56978e514fa --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/LocalFamilyRegionCoordinates.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ParametricCorrectionRegionPiola + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology +open scoped Matrix.Norms.Elementwise +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +theorem exists_transported_vanishing_region + {u v : P×Coord3 → Fin 2 → ℝ} + (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (p : P) + (Y : OpenPartialHomeomorph (P×Coord3) (P×Coord3)) + (hY : ∀ q x,(Y (q,x)).1=q) + (hsm : ContDiff ℝ (↑(⊤:ℕ∞)) Y) + (hinv : ContDiffOn ℝ (↑(⊤:ℕ∞)) Y.symm Y.target) + {U : Set Coord3} (hYU : Y.source⊆univ×ˢU) + {x : Coord3} (hx : (p,x)∈Y.source) + (hpot : ∀ z∈Y.source,v (z.1,(Y z).2)=u z) + (hlocal : ∀ A : Set Coord3,IsOpen A → (Y (p,x)).2∈A → + ∃ B : VanishingCorrectionRegion v p A,(Y (p,x)).2∈B.region) : + ∃ B : VanishingCorrectionRegion u p U,x∈B.region := by + let z := (Y (p,x)).2 + have hpz : (p,z)∈Y.target := by + have he : (p,z)=Y (p,x) := Prod.ext (hY p x).symm rfl + rw [he] + exact Y.map_source hx + obtain ⟨V₀,A₀,hV₀,hA₀,hp₀,hz₀,hprod₀⟩ := exists_open_product_inside Y.open_target hpz + obtain ⟨δ,hδ,hδball⟩ := Metric.isOpen_iff.mp hV₀ p hp₀ + obtain ⟨η,hη,hηball⟩ := Metric.isOpen_iff.mp hA₀ z hz₀ + let Kp := Metric.closedBall p (δ/2) + let Ka := Metric.closedBall z (η/2) + let A := Metric.ball z (η/2) + have hpK : Kp⊆V₀ := fun q hq => hδball + (lt_of_le_of_lt hq (by linarith : δ/2<δ)) + have haK : Ka⊆A₀ := fun y hy => hηball + (lt_of_le_of_lt hy (by linarith : η/2<η)) + have hjoint : Kp×ˢKa⊆Y.target := fun q hq => hprod₀ ⟨hpK hq.1,haK hq.2⟩ + obtain ⟨C,hC,hbound⟩ := parametric_chart_compact_bounds Y hY hsm hinv + ((isCompact_closedBall _ _).prod (isCompact_closedBall _ _)) hjoint + obtain ⟨B,hzB⟩ := hlocal A Metric.isOpen_ball (Metric.mem_ball_self (by positivity)) + obtain ⟨τ,hτ,hτball⟩ := Metric.isOpen_iff.mp B.region_open z hzB + let K := Metric.closedBall z (τ/2) + have hKB : K⊆B.region := fun y hy => hτball + (lt_of_le_of_lt hy (by linarith : τ/2<τ)) + let O : Set (P×Coord3) := Y.source∩{q | (Y q).2∈Metric.ball z (τ/2)} + have hO : IsOpen O := Y.open_source.inter + (Metric.isOpen_ball.preimage (continuous_snd.comp hsm.continuous)) + have hxO : (p,x)∈O := ⟨hx,Metric.mem_ball_self (by positivity)⟩ + obtain ⟨V₁,W₁,hV₁,hW₁,hp₁,hx₁,hprod₁⟩ := exists_open_product_inside hO hxO + let V := Metric.ball p (δ/2)∩V₁ + let W := W₁∩Metric.ball x 1 + have hVp : p∈V := ⟨Metric.mem_ball_self (by positivity),hp₁⟩ + have hWx : x∈W := ⟨hx₁,Metric.mem_ball_self zero_lt_one⟩ + have hWU : W⊆U := fun y hy => (hYU (hprod₁ (show (p,y)∈V₁×ˢW₁ from ⟨hp₁,hy.1⟩)).1).2 + have hVA : V×ˢA⊆Y.target := fun q hq => hjoint + ⟨Metric.ball_subset_closedBall hq.1.1,Metric.ball_subset_closedBall hq.2⟩ + have hW : ∀ q∈V,W⊆(fiberSlice Y hY q).symm '' K := by + intro q hq y hy + have hh := hprod₁ (show (q,y)∈V₁×ˢW₁ from ⟨hq.2,hy.1⟩) + exact ⟨(Y (q,y)).2,Metric.ball_subset_closedBall hh.2,(fiberSlice Y hY q).left_inv hh.1⟩ + have himage : ∀ q∈V,(fiberSlice Y hY q).symm '' A⊆U := by + rintro q hq _ ⟨y,hy,rfl⟩ + exact (hYU ((fiberSlice Y hY q).map_target (hVA ⟨hq,hy⟩))).2 + have hpot' : ∀ q∈V,∀ y∈A,u (q,(fiberSlice Y hY q).symm y)=v (q,y) := by + intro q hq y hy + have hyt := hVA (show (q,y)∈V×ˢA from ⟨hq,hy⟩) + have hys := (fiberSlice Y hY q).map_target hyt + have hh := hpot (q,(fiberSlice Y hY q).symm y) hys + rw [show (Y (q,(fiberSlice Y hY q).symm y)).2=y from + (fiberSlice Y hY q).right_inv hyt] at hh + exact hh.symm + let D := VanishingCorrectionRegion.piola hu hv p Y hY hsm hinv + (Metric.isOpen_ball.inter hV₁) hVp (Metric.isBounded_ball.subset inter_subset_left) + Metric.isOpen_ball B (isCompact_closedBall _ _) hKB hVA hW + (hW₁.inter Metric.isOpen_ball) ⟨x,hWx⟩ + (Metric.isBounded_ball.subset inter_subset_right) hWU himage hpot' hC + (fun q hq y hy => (hbound (q,y) + ⟨Metric.ball_subset_closedBall hq.1,Metric.ball_subset_closedBall hy⟩).2.2.2) + exact ⟨D,hWx⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/LocalSplitSubpatchRetained.lean b/lean/OAI/Analysis/Conductivity/Geometry/LocalSplitSubpatchRetained.lean new file mode 100644 index 0000000000000000000000000000000000000000..e6a4d439b921d7353d64bd6fbb3f85db49f3f411 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/LocalSplitSubpatchRetained.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PairedPotential +import OAI.Analysis.Conductivity.Sobolev.LocalPullbackTsupportInside + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped ENNReal Matrix.Norms.Elementwise +theorem exists_local_split_on_subpatch_retained + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + (u : Coord3 → Fin 2 → ℝ) (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) + (A : Coord3 → Symmetric3) {p : Coord3} (hA : ContinuousAt A p) + (hD : Function.Surjective (fderiv ℝ u p)) + (d : Coord3) (L : Coord3 →L[ℝ] ℝ) (hLd : L d = 1) + (B : Mat3) (hB : B.IsSymm) (hBn : ∀ v, L (B *ᵥ v) = 0) + {θ c m : ℝ} (hθ : 0 < θ) (hθ1 : θ < 1) + (hm : 0 < m) (hpath : ∀ z ∈ Icc (-θ) (1-θ), m ≤ 1 + c * z) + (C : ℝ → Symmetric3) (hC : ∀ z ∈ Icc (-θ) (1-θ), ContinuousAt C z) + (hdet : ∀ z ∈ Icc (-θ) (1-θ), 0 < (splitJacobian d L c z).det) + (hconstit : ∀ z ∈ Icc (-θ) (1-θ), + (C z).val = (splitJacobian d L c z).det⁻¹ • + (splitJacobian d L c z * ((A p).val + z • B) * (splitJacobian d L c z)ᵀ)) + {G : Set (ℝ × Symmetric3)} (hG : IsOpen G) + (hCG : ∀ z ∈ Icc (-θ) (1-θ), (z, C z) ∈ G) + {U : Set Coord3} (hU : IsOpen U) (hpU : p ∈ U) : + ∃ (X : OpenPartialHomeomorph Coord3 Coord3) (W : Set Coord3), + IsOpen W ∧ p ∈ W ∧ closure W ⊆ U ∧ IsCompact (closure W) ∧ W ⊆ X.source ∧ + ContDiff ℝ (↑(⊤ : ℕ∞)) X ∧ + ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target ∧ + ∀ O : Set Coord3, IsOpen O → O ⊆ W → + ∀ ε : ℝ, 0 < ε → + ∃ (χ : SmoothScalar Coord3) (H : SmoothScalar ℝ) (F : ℝ → Fin 2 → Coord3 → Coord3), + HasCompactSupport χ.val ∧ tsupport χ.val ⊆ X '' O ∧ + (∀ x, 0 ≤ χ.val x ∧ χ.val x ≤ 1) ∧ + (∀ t, -θ ≤ (smoothDirection 1 H).val t ∧ (smoothDirection 1 H).val t ≤ 1-θ) ∧ + (∀ k j, ContDiff ℝ (↑(⊤ : ℕ∞)) (F k j)) ∧ + (∀ k j, HasCompactSupport (F k j) ∧ tsupport (F k j) ⊆ O ∧ tsupport (F k j) ⊆ X.symm '' tsupport χ.val) ∧ + (∀ k j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ y, fderiv ℝ ψ y (F k j y) ∂μ) = 0) ∧ + ∀ᶠ n : ℕ in atTop, ∃ Y : Coord3 ≃ Coord3, + ContDiff ℝ (↑(⊤ : ℕ∞)) Y ∧ ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm ∧ + (∀ x ∉ O, Y x = x) ∧ Y '' O = O ∧ + (∀ x, Y x = x + (c * (n+1 : ℝ)⁻¹ * localPullback X χ.val x * + H.val ((n+1 : ℝ) * L (X x))) • d) ∧ + μ {x | x ∈ O ∧ + localPullback X χ.val (Y.symm x) * + (smoothDirection 1 H).val ((n+1 : ℝ) * L (X (Y.symm x))) ≠ -θ ∧ + localPullback X χ.val (Y.symm x) * + (smoothDirection 1 H).val ((n+1 : ℝ) * L (X (Y.symm x))) ≠ 1-θ} ≤ + ENNReal.ofReal ε ∧ + ∀ x ∈ O, + let z := localPullback X χ.val x * (smoothDirection 1 H).val ((n+1 : ℝ) * L (X x)) + let E := gradientColumns (fderiv ℝ u x) + let Ft := (A x).val * E + Matrix.of (fun i j => F (n+1 : ℝ) j x i) + let J := operatorMatrix (fderiv ℝ Y x) + let At := repairPushed (C z) J E Ft + 0 < J.det ∧ LinearIndependent ℝ E.col ∧ (z, At) ∈ G ∧ + At.val * gradientColumns (fderiv ℝ (u ∘ Y.symm) (Y x)) = pushFlux J Ft := by + have hb : 0 ≤ 1-θ := by linarith + have hb1 : 1-θ ≤ 1 := by linarith + obtain ⟨X, V, hV, hpV, hVU, hVX, hX, hXi, M, hM, hop⟩ := + exists_local_two_field_split μ u hu A hA hD d L hLd B hB hBn + hθ.le hb hθ1.le hb1 hm hpath C hC hdet hconstit hG hCG hU hpU + obtain ⟨W, hW, hpW, hWV, hWc, hXW, D, hDpos, hDb⟩ := + exists_bounded_chart_neighborhood X hX.continuous hXi hV hVX hpV + have hWV' : W ⊆ V := subset_closure.trans hWV + have hWX : W ⊆ X.source := hWV'.trans hVX + have hL : L ≠ 0 := by intro hz; simp only [hz, _root_.zero_apply] at hLd; norm_num at hLd + refine ⟨X, W, hW, hpW, hWV.trans hVU, hWc, hWX, hX, hXi, ?_⟩ + intro O hO hOW ε hε + have hOX : O ⊆ X.source := hOW.trans hWX + have hOV : O ⊆ V := hOW.trans hWV' + have hXO := hXW.subset (image_mono hOW) + obtain ⟨χ, H, hχc, hχW, hχb, hHp, hHm, hHb, hHr, hpure⟩ := + exists_chart_pure_profile μ X hO hOX (hXi.differentiableOn (by simp)) + hXO hXO.measure_lt_top.ne hDpos (fun x hx => hDb x (image_mono hOW hx)) L hL hθ hθ1 (div_pos hε hM) + obtain ⟨F, hF, hFs, hdiv, hlim⟩ := hop H hHp hHm hHb hHr χ hχc + (hχW.trans (image_mono hOV)) hχb + have hχt : tsupport χ.val ⊆ X.target := hχW.trans (by + rintro y ⟨x, hx, rfl⟩; exact X.map_source (hOX hx)) + have hχp : tsupport (localPullback X χ.val) ⊆ O := + localPullback_tsupport_inside X χ.val hχc hOX hχW + refine ⟨χ, H, F, hχc, hχW, hχb, hHr, hF, ?_, hdiv, ?_⟩ + · intro k j + refine ⟨(hFs k j).1, ?_, (hFs k j).2.2⟩ + intro x hx + obtain ⟨y, hy, rfl⟩ := (hFs k j).2.2 hx + obtain ⟨z, hz, rfl⟩ := hχW hy + simpa only [X.left_inv (hOX hz)] using hz + have hnat : Tendsto (fun n : ℕ => (n+1 : ℝ)) atTop atTop := + Filter.tendsto_atTop_add_const_right _ 1 tendsto_natCast_atTop_atTop + filter_upwards [hnat.eventually hlim, hpure] with n hn hnp + obtain ⟨Y, hY, hYi, _, _, hform, hYM, hstate⟩ := hn + have hoff : ∀ x ∉ O, Y x = x := by + intro x hx + have hz := image_eq_zero_of_notMem_tsupport (fun h => hx (hχp h)) + rw [hform x, hz, mul_zero, zero_mul, zero_smul, add_zero] + have himage := equiv_image_set_of_eq_off Y O hoff + refine ⟨Y, hY, hYi, hoff, himage, hform, ?_, fun x hx => hstate x (hOV hx)⟩ + let z : Coord3 → ℝ := fun x => localPullback X χ.val x * + (smoothDirection 1 H).val ((n+1 : ℝ) * L (X x)) + have hz : Continuous z := + (localPullback_contDiff X hX.contDiffOn χ.val (smoothScalar_contDiff χ) hχc hχt).continuous.mul + ((smoothScalar_contDiff (smoothDirection 1 H)).continuous.comp + (continuous_const.mul (L.continuous.comp hX.continuous))) + have he := pushed_exception_measure_le μ Y (hY.differentiable (by simp)) + hO.measurableSet himage z hz (-θ) (1-θ) hYM + calc + _ ≤ ENNReal.ofReal M * μ {x | x ∈ O ∧ z x ≠ -θ ∧ z x ≠ 1-θ} := he + _ ≤ ENNReal.ofReal M * ENNReal.ofReal (ε/M) := mul_le_mul_right hnp _ + _ = ENNReal.ofReal ε := by + rw [← ENNReal.ofReal_mul hM.le, mul_div_cancel₀ ε hM.ne'] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/MatrixPerturbInverse.lean b/lean/OAI/Analysis/Conductivity/Geometry/MatrixPerturbInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..f1baaeddb946318cae0777ff6560f91a17def1cc --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/MatrixPerturbInverse.lean @@ -0,0 +1,63 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Matrix Filter Topology +open scoped Matrix.Norms.Elementwise + +variable {ι P : Type*} [Fintype ι] [DecidableEq ι] [TopologicalSpace P] + +omit [DecidableEq ι] in +lemma matrix_pi_mulVec_bound (A : Matrix ι ι ℝ) (b : ι → ℝ) (i : ι) : + ‖(A*ᵥb) i‖≤(Fintype.card ι:ℝ)*‖A‖*‖b‖ := by + change ‖∑ j,A i j*b j‖≤_ + calc + _≤∑ j,‖A i j*b j‖ := norm_sum_le _ _ + _≤∑ j,‖A‖*‖b‖ := by + apply Finset.sum_le_sum + intro j _ + rw [norm_mul] + exact mul_le_mul ((norm_le_pi_norm (A i) j).trans (norm_le_pi_norm A i)) + (norm_le_pi_norm b j) (norm_nonneg _) (norm_nonneg _) + _=_ := by simp [mul_assoc] + +theorem matrix_inverse_locally_bounded {M : P → Matrix ι ι ℝ} {p₀ : P} + (hM : ContinuousAt M p₀) (h₀ : IsUnit (M p₀)) : + ∃ C : ℝ,0 (M p)⁻¹) p₀ := + (continuousAt_matrix_inv _ hdi).comp hM + have hn : ∀ᶠ p in 𝓝 p₀,‖(M p)⁻¹‖<‖(M p₀)⁻¹‖+1 := + hi.norm.eventually (gt_mem_nhds (by linarith)) + have hd : ∀ᶠ p in 𝓝 p₀,(M p).det≠0 := + ((continuous_id.matrix_det).continuousAt.comp hM).tendsto.eventually (isOpen_ne.mem_nhds hd₀) + let C := ((Fintype.card ι:ℝ)+1)*(‖(M p₀)⁻¹‖+1) + have hC : 0 hVA ⟨hz.1,B.region_subset hz.2⟩) hW hr + have hsolve := B.solve R hR (ε/C) (div_pos hε hC) + filter_upwards [hRe,hsolve,hV.mem_nhds hp] with q he solve hq hm + let X := (fiberSlice Y hY q).symm + have hX : ContDiffOn ℝ (↑(⊤:ℕ∞)) X X.source := (fiberSlice_smooth Y hY hsm hinv q).2 + have hXi : ContDiffOn ℝ (↑(⊤:ℕ∞)) X.symm X.target := + (fiberSlice_smooth Y hY hsm hinv q).1.contDiffOn + have hAs : A⊆X.source := fun y hy => hVA ⟨hq,hy⟩ + have huq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => u (q,y)) := hu.comp (contDiff_const.prodMk contDiff_id) + have hvq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => v (q,y)) := hv.comp (contDiff_const.prodMk contDiff_id) + have hps : EqOn (fun y => u (q,y)) ((fun y => v (q,y))∘X.symm) (X '' A) := by + rintro _ ⟨y,hy,rfl⟩ + change u (q,X y)=v (q,X.symm (X y)) + rw [X.left_inv (hAs hy)] + exact hpot q hq y hy + have hrX (j) : tsupport (fun y => r j (q,y))⊆X.target := + (hr.supported q j).trans ((hW q hq).trans (by + rintro _ ⟨y,hy,rfl⟩ + exact X.map_source (hAs (B.region_subset (hKB hy))))) + have hre : (fun j => localPiolaSource X (fun y => R j (q,y)))=(fun j y => r j (q,y)) := by + funext j + rw [congrFun he j] + exact localPiolaSource_inverse X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) _ ((subset_tsupport _).trans (hrX j)) + have hRs : PairSupported (fun j y => R j (q,y)) A := (hR.supported q).mono B.region_subset + have hRm : physicalSourceMoment (fun y => v (q,y)) (fun j y => R j (q,y))=0 := by + have hh := physicalSourceMoment_piola_local X hX hXi huq hvq hAs hps (hR.compact q) hRs + rw [hre,hm] at hh + exact hh.symm + have hh := (solve hRm).piola_local X hX hXi huq hvq hA hAs hps hC.le + (hbound q hq) (hR.compact q) hRs + rw [hre,mul_div_cancel₀ ε hC.ne'] at hh + exact hh.region_mono (himage q hq) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/ParametricPotentialCoordinates.lean b/lean/OAI/Analysis/Conductivity/Geometry/ParametricPotentialCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..f0b66a1c220f34fe998bfc06b3fccc38a9231bc5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/ParametricPotentialCoordinates.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.RegularPotentialCoordinates +import OAI.Analysis.Conductivity.Variational.ParametricDiffeomorph + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology + +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +theorem exists_parametric_potential_coordinates + {u : P×Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (p : P) (x : Coord3) (hD : Function.Surjective (fderiv ℝ (fun y => u (p,y)) x)) + {U : Set (P×Coord3)} (hU : IsOpen U) (hpx : (p,x)∈U) : + ∃ Y : OpenPartialHomeomorph (P×Coord3) (P×Coord3), + (p,x)∈Y.source ∧ Y.source⊆U ∧ + (∀ q y,(Y (q,y)).1=q) ∧ + (∀ q y,coordinatePair (Y (q,y)).2=u (q,y)) ∧ + ContDiff ℝ (↑(⊤:ℕ∞)) Y ∧ ContDiffOn ℝ (↑(⊤:ℕ∞)) Y.symm Y.target := by + let D := fderiv ℝ (fun y => u (p,y)) x + obtain ⟨Q,hQ⟩ := ContinuousLinearMap.HasRightInverse.of_surjective_of_finiteDimensional hD + let L := potentialCompletionEquiv D hD + let φ : P×Coord3 → Coord3 := fun q => L (completedPotential (fun y => u (q.1,y)) D Q q.2) + have hφ : ContDiff ℝ (↑(⊤:ℕ∞)) φ := + L.contDiff.comp (((Q.contDiff.comp hu).add contDiff_snd).sub (Q.contDiff.comp (D.contDiff.comp contDiff_snd))) + have hup : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => u (p,y)) := + hu.comp (contDiff_const.prodMk contDiff_id) + have hφd : fderiv ℝ (fun y => φ (p,y)) x=(L : Coord3 →L[ℝ] Coord3) := by + have hh := L.hasFDerivAt.comp x (completedPotential_derivative + ((hup.differentiable (by simp) x).hasFDerivAt) Q) + simpa only [φ,D,Function.comp_def,ContinuousLinearMap.comp_id] using hh.fderiv + obtain ⟨Y,hp,hsub,he,hY,hYi⟩ := exists_parametric_diffeomorph hφ p x L hφd hU hpx + refine ⟨Y,hp,hsub,fun q y => by rw [he],?_,hY,hYi⟩ + intro q y + rw [he] + exact (potentialCompletionEquiv_pairing D hD _).trans + (completedPotential_pairing (fun y => u (q,y)) D Q hQ y) + +omit [FiniteDimensional ℝ P] in +lemma fiberSlice_smooth + (Y : OpenPartialHomeomorph (P×Coord3) (P×Coord3)) + (hY : ∀ p x,(Y (p,x)).1=p) + (hsm : ContDiff ℝ (↑(⊤:ℕ∞)) Y) + (hinv : ContDiffOn ℝ (↑(⊤:ℕ∞)) Y.symm Y.target) (p : P) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fiberSlice Y hY p) ∧ + ContDiffOn ℝ (↑(⊤:ℕ∞)) (fiberSlice Y hY p).symm (fiberSlice Y hY p).target := by + constructor + · exact contDiff_snd.comp (hsm.comp (contDiff_const.prodMk contDiff_id)) + · exact contDiff_snd.contDiffOn.comp + (hinv.comp (contDiff_const.prodMk contDiff_id).contDiffOn (fun _ hx => hx)) + (fun _ _ => mem_univ _) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalBoxCorrection.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalBoxCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..54acedd61465900dd74ae72098e436c1ba77faa7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalBoxCorrection.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CoordinateWeakCorrection +import OAI.Analysis.Conductivity.Sources.LocalPiola + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory +open scoped Matrix.Norms.Elementwise + +def coordinatePairCLM : Coord3 →L[ℝ] (Fin 2 → ℝ) := + ContinuousLinearMap.pi (fun j => ContinuousLinearMap.proj (j.castLE (by decide : 2≤3))) + +def coordinatePair : Coord3 → Fin 2 → ℝ := coordinatePairCLM + +lemma coordinatePair_smooth : ContDiff ℝ (↑(⊤ : ℕ∞)) coordinatePair := + coordinatePairCLM.contDiff + +@[simp] lemma coordinatePair_zero (x : Coord3) : coordinatePair x 0=x 0 := rfl +@[simp] lemma coordinatePair_one (x : Coord3) : coordinatePair x 1=x 1 := rfl + +lemma coordinatePair_columns (B : Mat3) (x : Coord3) (j : Fin 2) : + (B*gradientColumns (fderiv ℝ coordinatePair x)).col j=(B.col (j.castLE (by decide : 2≤3))) := by + have hd : fderiv ℝ coordinatePair x=coordinatePairCLM := coordinatePairCLM.hasFDerivAt.fderiv + rw [hd] + ext i + fin_cases j + all_goals simp [Matrix.mul_apply,gradientColumns,LinearMap.toMatrix', + coordinatePairCLM,Matrix.transpose_apply,Matrix.col,Pi.single_apply] + +theorem physical_box_symmetric_correction + (X : OpenPartialHomeomorph Coord3 Coord3) + (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {a b : Fin 3 → ℝ} (hab : ∀ i,a i ![r₁ (boxCoordinates x),r₂ (boxCoordinates x)] j) y) := by + obtain ⟨B,hB,hcB,htB,hsy,hw₁,hw₂⟩ := + compact_coordinate_box_correction hab hr₁ hr₂ hs₁ hs₂ hv₁ hv₂ hz₁ hz₂ ht + apply local_symmetric_source_transport X hX hXi B hB hcB (htB.trans hbox) hsy + coordinatePair coordinatePair_smooth.contDiffOn + · intro j + fin_cases j + · exact hs₁.comp_homeomorph boxCoordinates.toHomeomorph + · exact hs₂.comp_homeomorph boxCoordinates.toHomeomorph + · intro j + fin_cases j + · exact ((tsupport_comp_subset_preimage r₁ boxCoordinates.continuous).trans (preimage_mono hv₁)).trans hbox + · exact ((tsupport_comp_subset_preimage r₂ boxCoordinates.continuous).trans (preimage_mono hv₂)).trans hbox + · intro j ψ hψ + simp_rw [coordinatePair_columns] + fin_cases j + · exact hw₁ ψ hψ + · exact hw₂ ψ hψ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarBand.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarBand.lean new file mode 100644 index 0000000000000000000000000000000000000000..0a38030e71ba9e145f237721a96ad1c602a5512b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarBand.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CollarMeasureTransport +import OAI.Analysis.Conductivity.Fourier.CollarAngularInverse +import OAI.Analysis.Conductivity.Flux.CollarCartesianDifferential + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus + +lemma squareFace_scaled_surjective (v : Fin 2 → ℝ) {r : ℝ} (hr : 0 volume.restrict + (⋃ j : Fin 4,sourceCollarPiece i j '' sourceExtendedBox l r)) := Measure.restrict_iUnion_le + _ = ∑ i : Fin 4,volume.restrict + (⋃ j : Fin 4,sourceCollarPiece i j '' sourceExtendedBox l r) := Measure.sum_fintype _ + _ ≤ ∑ i : Fin 4,∑ j : Fin 4,volume.restrict + (sourceCollarPiece i j '' sourceExtendedBox l r) := by + apply Finset.sum_le_sum + intro i _ + simpa only [Measure.sum_fintype] using + (Measure.restrict_iUnion_le (μ:=volume) + (s:=fun j : Fin 4 => sourceCollarPiece i j '' sourceExtendedBox l r)) + _ = _ := rfl + +lemma sourceClosedCollarBand_memLp {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) {f : (Fin 3 → ℝ) → ℂ} + (hf : MemLp f 2 (sourcePhysicalCollarMeasure l r)) : + MemLp f 2 (volume.restrict (sourceClosedCollarBand l r)) := + hf.mono_measure (sourceClosedCollarBand_measure_le hl hr) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarRegularity.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarRegularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..95560700266a4a4c6f1a509708ffc9cf1ef4524f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarRegularity.lean @@ -0,0 +1,121 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.RegularPatch +import OAI.Analysis.Conductivity.Variational.FiniteEndPhysicalRegularity +import OAI.Analysis.Conductivity.Flux.FiniteEndPhysicalSmoothTensor +import OAI.Analysis.Conductivity.Flux.VariableCollarTensor + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +def variableFaceField (u : Coord3 → Fin 2 → ℝ) (a b : ℝ) (i j : Fin 4) : Coord3 → Fin 2 → ℝ := + fun y => u (flatEndCoordinates a b (sourceFaceAngles i j (sourceCollarInverse i j y))) + +def variableCollarField (u : Coord3 → Fin 2 → ℝ) (a b : ℝ) : Coord3 → Fin 2 → ℝ := + sourceFacePaste (variableFaceField u a b) 0 + +lemma variableCollarField_open (u : Coord3 → Fin 2 → ℝ) (a b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + variableCollarField u a b (sourceCollarPiece i j x)= + u (flatEndCoordinates a b (sourceFaceAngles i j x)) := by + rw [variableCollarField,sourceFacePaste_open _ _ i j hx] + simp only [variableFaceField,sourceCollarInverse_point i j hx] + +lemma flatEndCoordinates_fderiv_surjective {a : ℝ} (ha : a≠0) (b : ℝ) (x : Coord3) : + Function.Surjective (fderiv ℝ (flatEndCoordinates a b) x) := by + change Function.Surjective (fderiv ℝ (endAxialAffine a b) x) + rw [(endAxialAffine_hasFDeriv a b x).fderiv] + exact (LinearMap.equivOfDetNeZero (Matrix.toLin' (endAxialMatrix a)) (by + simpa [LinearMap.det_toLin',endAxialMatrix,Matrix.det_diagonal,Fin.prod_univ_succ] using ha)).surjective + +lemma sourceFaceAngles_fderiv_surjective (i j : Fin 4) {x : Coord3} + (hx : x∈sourceCollarOpenBox) : Function.Surjective (fderiv ℝ (sourceFaceAngles i j) x) := by + rw [(sourceFaceAngles_hasFDeriv i j x).fderiv] + exact (LinearMap.equivOfDetNeZero (Matrix.toLin' (sourceFaceAngleMatrix i j x)) (by + rw [LinearMap.det_toLin']; exact (sourceFaceAngleMatrix_det_pos i j (sourceCollarOpenBox_subset hx)).ne')).surjective + +lemma variableCollarTensor_local_eq (K : Coord3 → Mat3) (a b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) : + variableCollarTensor K a b =ᶠ[𝓝 (sourceCollarPiece i j x)] + (attachedVariableTensor (K ∘ flatEndCoordinates a b ∘ sourceFaceAngles i j) a i j ∘ sourceCollarInverse i j) := by + change ∀ᶠ y in 𝓝 (sourceCollarPiece i j x), _ = _ + rw [←sourceCollarPiece_map_nhds i j hx,eventually_map] + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx] with y hy + simpa only [Function.comp_def,sourceCollarInverse_point i j hy] using + variableCollarTensor_open K a b i j hy + +lemma variableCollarTensor_smooth_at {K : Coord3 → Mat3} {a : ℝ} (ha : a≠0) (b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) + (hK : ContDiffAt ℝ (↑(⊤:ℕ∞)) K (flatEndCoordinates a b (sourceFaceAngles i j x))) : + ContDiffAt ℝ (↑(⊤:ℕ∞)) (variableCollarTensor K a b) (sourceCollarPiece i j x) := by + have hk : ContDiffAt ℝ (↑(⊤:ℕ∞)) (K ∘ flatEndCoordinates a b ∘ sourceFaceAngles i j) x := + hK.comp x ((contDiff_flatEndCoordinates a b).contDiffAt.comp x + (contDiff_sourceFaceAngles i j).contDiffAt) + have ht : ContDiffAt ℝ (↑(⊤:ℕ∞)) + (attachedVariableTensor (K ∘ flatEndCoordinates a b ∘ sourceFaceAngles i j) a i j) + (sourceCollarInverse i j (sourceCollarPiece i j x)) := by + rw [sourceCollarInverse_point i j hx] + exact contDiffAt_attachedVariableTensor hk ha i j hx + exact (ht.comp _ (sourceCollarInverse_contDiffAt i j hx)).congr_of_eventuallyEq + (variableCollarTensor_local_eq K a b i j hx) + +theorem variableCollar_regular_at {u : Coord3 → Fin 2 → ℝ} {K : Coord3 → Mat3} + (hS : ∀ x,(K x).IsSymm) {a : ℝ} (ha : a≠0) (b : ℝ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) {U : Set Coord3} + (hr : flatEndCoordinates a b (sourceFaceAngles i j x)∈ + regularRegion u (fun y => ⟨K y,hS y⟩) U) : + sourceCollarPiece i j x∈regularRegion (variableCollarField u a b) + (fun y => ⟨variableCollarTensor K a b y,variableCollarTensor_symm hS a b y⟩) + (sourceCollarPiece i j '' sourceCollarOpenBox) := by + obtain ⟨O,hOU,hO,hxO⟩ := mem_regularRegion_iff.mp hr + let V := sourceCollarPiece i j '' sourceCollarOpenBox + let g : Coord3 → Coord3 := fun y => flatEndCoordinates a b (sourceFaceAngles i j (sourceCollarInverse i j y)) + have hV : IsOpen V := isOpen_sourceCollarOpenImage i j + have hg : ContDiffOn ℝ (↑(⊤:ℕ∞)) g V := + (contDiff_flatEndCoordinates a b).comp_contDiffOn + ((contDiff_sourceFaceAngles i j).comp_contDiffOn (sourceCollarInverse_contDiffOn i j)) + let W := V∩g ⁻¹' O + have hW : IsOpen W := hg.continuousOn.isOpen_inter_preimage hV hO.1 + have hm : MapsTo g W O := fun _ hy => hy.2 + have hd : ∀ y∈W,Function.Surjective (fderiv ℝ g y) := by + rintro y ⟨⟨z,hz,rfl⟩,_⟩ + have hinv := (sourceCollarInverse_contDiffAt i j hz).differentiableAt (by simp) + have hang := (contDiff_sourceFaceAngles i j).differentiable (by simp) + have hflat := (contDiff_flatEndCoordinates a b).differentiable (by simp) + change Function.Surjective (fderiv ℝ (flatEndCoordinates a b ∘ (sourceFaceAngles i j ∘ sourceCollarInverse i j)) _) + rw [fderiv_comp _ (hflat _) ((hang _).comp _ hinv),fderiv_comp _ (hang _) hinv] + have hsur : Function.Surjective (fderiv ℝ (sourceFaceAngles i j) + (sourceCollarInverse i j (sourceCollarPiece i j z))) := by + simpa only [sourceCollarInverse_point i j hz] using sourceFaceAngles_fderiv_surjective i j hz + exact (flatEndCoordinates_fderiv_surjective ha b _).comp + (hsur.comp (sourceCollarInverse_fderiv_surjective i j ⟨z,hz,rfl⟩)) + have hB : ContDiffOn ℝ (↑(⊤:ℕ∞)) (variableCollarTensor K a b) W := by + rintro y hy + obtain ⟨z,hz,rfl⟩ := hy.1 + apply (variableCollarTensor_smooth_at ha b i j hz ?_).contDiffWithinAt + have hgz : g (sourceCollarPiece i j z)=flatEndCoordinates a b (sourceFaceAngles i j z) := by + simp only [g,sourceCollarInverse_point i j hz] + simpa only [hgz] using (hO.2.2.1 _ hy.2).contDiffAt (hO.1.mem_nhds hy.2) + have hp : RegularPatch (fun y => u (g y)) + (fun y => ⟨variableCollarTensor K a b y,variableCollarTensor_symm hS a b y⟩) W := + ⟨hW,hO.2.1.comp (hg.mono inter_subset_left) hm,hB, + hO.2.2.2.smoothCoordinates hO.1 hW hO.2.1 (hg.mono inter_subset_left) hm hd⟩ + have hc : EqOn (variableCollarField u a b) (fun y => u (g y)) W := by + rintro y ⟨⟨z,hz,rfl⟩,_⟩ + simpa only [g,sourceCollarInverse_point i j hz] using variableCollarField_open u a b i j hz + refine mem_regularRegion_iff.mpr ⟨W,inter_subset_left,hp.congr hc (fun _ _ => rfl),?_⟩ + refine ⟨⟨x,hx,rfl⟩,?_⟩ + change g (sourceCollarPiece i j x)∈O + simpa only [g,sourceCollarInverse_point i j hx] using hxO + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarTrace.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..9be0caa68c5c0dff6b5265707a5939a430f79a1e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalCollarTrace.lean @@ -0,0 +1,158 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralAnchor +import OAI.Analysis.Conductivity.Geometry.CollarVolumeBound +import OAI.Analysis.Conductivity.Fourier.AngularSignedTrace + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology UnitAddTorus + +def physicalRayConstant : ℝ := + 1600*((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi)) + +lemma physicalRayConstant_pos : 0 Finset.sum_le_sum (s:=Finset.univ) + (fun j _ => setIntegral_mono_set hi (Filter.Eventually.of_forall hn) (Filter.Eventually.of_forall (hsub i j)))) + have hsum : (∑ i : Fin 4,∑ j : Fin 4,∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y)≤ + 16*(∫ y in K,g y) := by + simp only [Finset.sum_const,Finset.card_univ,Fintype.card_fin,nsmul_eq_mul] at hm + change (∑ i : Fin 4,∑ j : Fin 4,∫ y in sourceCollarPiece i j '' sourceExtendedBox l r,g y)≤ + 4*(4*(∫ y in K,g y)) at hm + linarith + apply hh.trans + calc + _≤(100*((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi)))*(16*(∫ y in K,g y)) := + mul_le_mul_of_nonneg_left hsum hc + _=_ := by unfold physicalRayConstant; ring + +theorem sourceAngular_physical_trace_forward {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) {K : Set (Fin 3 → ℝ)} (hK : IsCompact K) + (t : ℝ) {η : ℝ} (hη : 0<η) (hl : -(1:ℝ)/100≤t) (hr : t+η≤1/100) + (hsub : ∀ i j,sourceCollarPiece i j '' sourceExtendedBox t (t+η)⊆K) : + (∫ x : UnitAddTorus (Fin 2),(f (sourceAngularCollar t x))^2)≤ + ((1+1/η)*physicalRayConstant)*(∫ y in K,sourcePhysicalEnergy f y) := by + have ht := sourceAngular_integrated_trace hf t hη + have he := intervalIntegral.integral_comp_add_left + (fun a => ∫ x : UnitAddTorus (Fin 2),sourcePhysicalEnergy f (sourceAngularCollar a x)) + (a:=0) (b:=η) t + rw [he,add_zero] at ht + have hv := sourceAngular_volume_in (continuous_sourcePhysicalEnergy hf) + (sourcePhysicalEnergy_nonneg f) hK (by linarith : t≤t+η) hl hr hsub + exact ht.trans (by have hh := mul_le_mul_of_nonneg_left hv (show 0≤1+1/η by positivity); nlinarith [hh]) + +theorem sourceAngular_physical_trace_backward {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) {K : Set (Fin 3 → ℝ)} (hK : IsCompact K) + (t : ℝ) {η : ℝ} (hη : 0<η) (hl : -(1:ℝ)/100≤t-η) (hr : t≤1/100) + (hsub : ∀ i j,sourceCollarPiece i j '' sourceExtendedBox (t-η) t⊆K) : + (∫ x : UnitAddTorus (Fin 2),(f (sourceAngularCollar t x))^2)≤ + ((1+1/η)*physicalRayConstant)*(∫ y in K,sourcePhysicalEnergy f y) := by + have ht := sourceAngular_signed_trace hf t (-1) (by norm_num) hη + simp only [neg_one_mul,←sub_eq_add_neg] at ht + have he := intervalIntegral.integral_comp_sub_left + (fun a => ∫ x : UnitAddTorus (Fin 2),sourcePhysicalEnergy f (sourceAngularCollar a x)) + (a:=0) (b:=η) t + rw [he,sub_zero] at ht + have hv := sourceAngular_volume_in (continuous_sourcePhysicalEnergy hf) + (sourcePhysicalEnergy_nonneg f) hK (by linarith : t-η≤t) hl hr hsub + exact ht.trans (by have hh := mul_le_mul_of_nonneg_left hv (show 0≤1+1/η by positivity); nlinarith [hh]) + +end + +open Set MeasureTheory + +def sourcePairEquiv : (Fin 3 → ℝ) ≃ₗ[ℝ] Box3 where + toFun := sourcePairCoordinates + invFun := fun z => ![z.1.1,z.1.2,z.2] + left_inv := by intro x; ext i; fin_cases i <;> rfl + right_inv := by intro z; rfl + map_add' := by intros; rfl + map_smul' := by intros; rfl + +def sourcePairCLE : (Fin 3 → ℝ) ≃L[ℝ] Box3 := sourcePairEquiv.toContinuousLinearEquiv + +def sourcePairMeasurable : (Fin 3 → ℝ) ≃ᵐ Box3 := + threeArrow.trans (MeasurableEquiv.prodAssoc (α:=ℝ) (β:=ℝ) (γ:=ℝ)).symm + +lemma sourcePairMeasurable_apply (x : Fin 3 → ℝ) : sourcePairMeasurable x=sourcePairCoordinates x := rfl + +lemma sourcePair_volume : MeasurePreserving sourcePairMeasurable := + (volume_preserving_prodAssoc (α₁:=ℝ) (β₁:=ℝ) (γ₁:=ℝ)).symm.comp threeArrow_volume + +def centralPhysical : Set (Fin 3 → ℝ) := sourcePairCoordinates ⁻¹' centralClosed + +lemma centralPhysical_compact : IsCompact centralPhysical := by + exact sourcePairCLE.toHomeomorph.isCompact_preimage.mpr centralClosed_compact + +lemma sourcePair_central_image : sourcePairMeasurable '' centralPhysical=centralClosed := by + exact sourcePairMeasurable.image_preimage centralClosed + +lemma integral_centralPhysical (g : Box3 → ℝ) : + (∫ x in centralPhysical,g (sourcePairCoordinates x))=(∫ z in centralClosed,g z) := by + have h := sourcePair_volume.setIntegral_image_emb sourcePairMeasurable.measurableEmbedding g centralPhysical + rw [sourcePair_central_image] at h + exact h.symm + +lemma linear_three_bound (A : (Fin 3 → ℝ) →L[ℝ] ℝ) : + ‖A‖^2≤3*((A ![1,0,0])^2+(A ![0,1,0])^2+(A ![0,0,1])^2) := by + have hn : ‖A‖≤|A ![1,0,0]|+|A ![0,1,0]|+|A ![0,0,1]| := by + apply A.opNorm_le_bound (by positivity) + intro v + have he : v=v 0 • ![1,0,0]+v 1 • ![0,1,0]+v 2 • ![0,0,1] := by + ext i; fin_cases i <;> simp + have hh := abs_add_le (A (v 0 • ![1,0,0]+v 1 • ![0,1,0])) (A (v 2 • ![0,0,1])) + have hh' := abs_add_le (A (v 0 • ![1,0,0])) (A (v 1 • ![0,1,0])) + have hv (i : Fin 3) : |v i|≤‖v‖ := norm_le_pi_norm v i + conv_lhs => rw [he] + rw [map_add,map_add,map_smul,map_smul,map_smul] + change |v 0 * A ![1,0,0]+v 1*A ![0,1,0]+v 2*A ![0,0,1]|≤_ + have ha := abs_add_le (v 0 * A ![1,0,0]+v 1*A ![0,1,0]) (v 2*A ![0,0,1]) + have hb := abs_add_le (v 0 * A ![1,0,0]) (v 1*A ![0,1,0]) + simp only [abs_mul] at ha hb + have h0 := mul_le_mul_of_nonneg_right (hv 0) (abs_nonneg (A ![1,0,0])) + have h1 := mul_le_mul_of_nonneg_right (hv 1) (abs_nonneg (A ![0,1,0])) + have h2 := mul_le_mul_of_nonneg_right (hv 2) (abs_nonneg (A ![0,0,1])) + nlinarith + have hs := mul_self_le_mul_self (norm_nonneg A) hn + nlinarith [sq_abs (A ![1,0,0]),sq_abs (A ![0,1,0]),sq_abs (A ![0,0,1]), + sq_nonneg (|A ![1,0,0]|-|A ![0,1,0]|),sq_nonneg (|A ![1,0,0]|-|A ![0,0,1]|), + sq_nonneg (|A ![0,1,0]|-|A ![0,0,1]|)] + +lemma sourcePair_energy {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (x : Fin 3 → ℝ) : + sourcePhysicalEnergy (f ∘ sourcePairCoordinates) x≤ + 192*cubeEnergyDensity f (sourcePairCoordinates x)+2*(f (sourcePairCoordinates x))^2 := by + have he : fderiv ℝ (f ∘ sourcePairCoordinates) x= + (fderiv ℝ f (sourcePairCoordinates x)).comp sourcePairCLE.toContinuousLinearMap := by + exact ((hf.differentiable (by simp) _).hasFDerivAt.comp x sourcePairCLE.hasFDerivAt).fderiv + have hb := linear_three_bound (fderiv ℝ (f ∘ sourcePairCoordinates) x) + rw [he] at hb + change ‖(fderiv ℝ f (sourcePairCoordinates x)).comp sourcePairCLE.toContinuousLinearMap‖^2≤ + 3*(cubeEnergyDensity f (sourcePairCoordinates x)) at hb + dsimp [sourcePhysicalEnergy] + rw [he] + linarith + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalEndRegions.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalEndRegions.lean new file mode 100644 index 0000000000000000000000000000000000000000..279ca20195d03db445e8305b23489cf67c5a8910 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalEndRegions.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CentralPhysicalRegion + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def physicalEndRegion (i : Fin 3) : Set (Fin 3 → ℝ) := + Fin.cases (sourceClosedCollarBand 0 centralThickness) + (fun k => (sourceChildHomeomorph (actualChildSign k)).symm ⁻¹' + sourceClosedCollarBand (-centralThickness) 0) i + +lemma physicalEndRegion_compact (i : Fin 3) : IsCompact (physicalEndRegion i) := by + refine Fin.cases ?_ (fun k => ?_) i + · exact isCompact_sourceClosedCollarBand (by norm_num) (by norm_num [centralThickness]) + · exact (sourceChildHomeomorph (actualChildSign k)).symm.isCompact_preimage.mpr + (isCompact_sourceClosedCollarBand (by norm_num [centralThickness]) (by norm_num)) + +lemma sourceSmallBand_bounds {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand (-centralThickness) 0) : + |y 0|≤1602/1000 ∧ |y 1|≤1001/1000 ∧ |y 2|≤1002/1000 := by + have hh := (sourceCollarTime_ge_iff y (-centralThickness)).mp hy.1 + have hx := (le_max_left (|y 0|/sourceLength) (|y 1|)).trans hh.2.2 + have hy' := (le_max_right (|y 0|/sourceLength) (|y 1|)).trans hh.2.2 + norm_num [centralThickness,sourceRadialWidth,sourceHole,sourceLength] at hx hy' hh ⊢ + exact ⟨by linarith,by linarith,by linarith [hh.1]⟩ + +lemma physicalChildEnd_far_parent (k : Fin 2) {y : Fin 3 → ℝ} + (hy : y∈sourceClosedCollarBand (-centralThickness) 0) : + 2*centralThickness ≤ sourceCollarTime (sourceChildCoordinates (actualChildSign k) y) := by + obtain ⟨h₀,h₁,h₂⟩ := sourceSmallBand_bounds hy + have hsign : |actualChildSign k|=1 := by fin_cases k <;> norm_num [actualChildSign] + have ha : |actualChildSign k*sourceOffset|=sourceOffset := by + rw [abs_mul,hsign,one_mul]; norm_num [sourceOffset] + have hu := abs_add_le (sourceScale*y 1) (actualChildSign k*sourceOffset) + rw [abs_mul,abs_of_pos (show 0 Disjoint (physicalEndRegion i) (physicalEndRegion j)) := by + intro i j hij + fin_cases i <;> fin_cases j + all_goals first | exact (hij rfl).elim | exact physicalEndRegion_parent_child_disjoint 0 | + exact physicalEndRegion_parent_child_disjoint 1 | + exact (physicalEndRegion_parent_child_disjoint 0).symm | + exact (physicalEndRegion_parent_child_disjoint 1).symm | + exact physicalEndRegion_children_disjoint | exact physicalEndRegion_children_disjoint.symm + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/PhysicalRegionGluing.lean b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalRegionGluing.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a63e31a4e51b5fe5d295c72a44663509beea904 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/PhysicalRegionGluing.lean @@ -0,0 +1,49 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalRepresentativeGluing + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +theorem physical_region_glue {ι : Type*} [Countable ι] + (O : ι → Set Coord3) (hO : ∀ i,IsOpen (O i)) + {U : Set Coord3} (hUm : MeasurableSet U) (hOU : ∀ i,O i⊆U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) + (hcover : ∀ᵐ y : Coord3,y∈U → y∈⋃ i,O i) + (w : Fin 2 → H1) (g : ι → Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (hreg : ∀ i,∀ᵐ y : Coord3,y∈O i → y∈regularRegion (g i) A (O i)) + (he : ∀ i,(fun y j => weakValue (w j) (WithLp.toLp 2 y))=ᵐ[volume.restrict (O i)] g i) : + ∃ v : Coord3 → Fin 2 → ℝ, + (∀ᵐ y : Coord3,y∈U → v y=fun j => weakValue (w j) (WithLp.toLp 2 y)) ∧ + (∀ᵐ y : Coord3,y∈U → ∀ i : Fin 3,∀ j : Fin 2, + fderiv ℝ (fun x => v x j) y (Pi.single i 1)=weakGradient (w j) (WithLp.toLp 2 y) i) ∧ + volume (U \ regularRegion v A U)=0 := by + let I := Σ i : ι,{V : Set Coord3 // V⊆O i ∧ RegularPatch (g i) A V} + let V : I → Set Coord3 := fun i => i.2.val + let f : I → Coord3 → Fin 2 → ℝ := fun i => g i.1 + have hV : ∀ i,IsOpen (V i) := fun i => i.2.property.2.1 + have hVU : ∀ i,V i⊆U := fun i => i.2.property.1.trans (hOU i.1) + have hVR : ∀ i,RegularPatch (f i) A (V i) := fun i => i.2.property.2 + have hc : ∀ᵐ y : Coord3,y∈U → y∈⋃ i,V i := by + filter_upwards [hcover,ae_all_iff.mpr hreg] with y hc hr hy + obtain ⟨i,hi⟩ := mem_iUnion.mp (hc hy) + obtain ⟨W,hWO,hW,hyW⟩ := mem_regularRegion_iff.mp (hr i hi) + exact mem_iUnion.mpr ⟨⟨i,⟨W,hWO,hW⟩⟩,hyW⟩ + have he' : ∀ i,(fun y j => weakValue (w j) (WithLp.toLp 2 y))=ᵐ[volume.restrict (V i)] f i := by + intro index + apply (ae_restrict_iff' (hV index).measurableSet).mpr + filter_upwards [(ae_restrict_iff' (hO index.1).measurableSet).mp (he index.1)] with point equality membership + exact equality (index.2.property.1 membership) + exact physical_representative_glue V hV hUm hVU hUb hc w f A hVR he' + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RectanglePoincare.lean b/lean/OAI/Analysis/Conductivity/Geometry/RectanglePoincare.lean new file mode 100644 index 0000000000000000000000000000000000000000..ff540e3ba021ea92ba13bc405cefa91d15c0afc2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RectanglePoincare.lean @@ -0,0 +1,138 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.BoxEnergyPoincare + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory + +lemma RectFootprint.prism_volume (Q : RectFootprint) (lo hi : ℝ) : + volume (Q.prism lo hi)=ENNReal.ofReal (Q.xu-Q.xl)*ENNReal.ofReal (Q.yu-Q.yl)* + ENNReal.ofReal (hi-lo) := by + simp only [RectFootprint.prism,RectFootprint.carrier,Measure.volume_eq_prod, + Measure.prod_prod,Real.volume_Icc] + +lemma RectFootprint.prism_volume_pos (Q : RectFootprint) (lo hi : ℝ) : + 0 < volume (Q.prism lo hi) ↔ Q.xl h ((Q.prism_volume_pos lo hi).mp hp))) + simp [localVariance,Measure.restrict_eq_zero.mpr hz] + +lemma rectangle_energy_mono {Q R : Set Box3} {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hR : IsCompact R) (hQR : Q⊆R) : + (∫ z in Q,cubeEnergyDensity f z) ≤ ∫ z in R,cubeEnergyDensity f z := by + exact setIntegral_mono_set ((continuous_cubeEnergyDensity hf).continuousOn.integrableOn_compact hR) + (Filter.Eventually.of_forall (fun _ => cubeEnergyDensity_nonneg f _)) + (Filter.Eventually.of_forall (fun _ hx => hQR hx)) + +theorem RectFootprint.poincare_in (Q : RectFootprint) (lo hi : ℝ) {R : Set Box3} + (hR : IsCompact R) (hQR : Q.prism lo hi⊆R) {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + localVariance volume (Q.prism lo hi) f (Q.average lo hi f) ≤ + Q.poincareConstant lo hi*(∫ z in R,cubeEnergyDensity f z) := by + exact (Q.poincare lo hi hf).trans (mul_le_mul_of_nonneg_left (rectangle_energy_mono hf hR hQR) + (Q.poincareConstant_nonneg lo hi)) + +open Set MeasureTheory + +variable {X : Type*} [MeasurableSpace X] + +def patchCluster (Q : ℕ → Set X) : ℕ → Set X + | 0 => Q 0 + | n+1 => patchCluster Q n ∪ Q (n+1) + +omit [MeasurableSpace X] in +lemma patchCluster_mono (Q : ℕ → Set X) {n m : ℕ} (h : n ≤ m) : + patchCluster Q n ⊆ patchCluster Q m := by + induction h with + | refl => exact Subset.rfl + | @step m h ih => exact ih.trans (subset_union_left (t := Q (m+1))) + +omit [MeasurableSpace X] in +lemma subset_patchCluster (Q : ℕ → Set X) (n : ℕ) : Q n ⊆ patchCluster Q n := by + cases n with + | zero => exact Subset.rfl + | succ n => exact subset_union_right + +def patchPoincareConstant (μ : Measure X) (Q : ℕ → Set X) (A : ℕ → ℝ) : ℕ → ℝ + | 0 => A 0 + | n+1 => patchPoincareConstant μ Q A n+2*A (n+1)+ + 4*μ.real (Q (n+1))/μ.real (patchCluster Q n ∩ Q (n+1))* + (patchPoincareConstant μ Q A n+A (n+1)) + +lemma patchPoincareConstant_nonneg (μ : Measure X) (Q : ℕ → Set X) (A : ℕ → ℝ) + (hA : ∀ n, 0≤A n) (n : ℕ) : 0≤patchPoincareConstant μ Q A n := by + induction n with + | zero => exact hA 0 + | succ n ih => + dsimp [patchPoincareConstant] + have hQ : 0≤μ.real (Q (n+1)) := ENNReal.toReal_nonneg + have hO : 0≤μ.real (patchCluster Q n ∩ Q (n+1)) := ENNReal.toReal_nonneg + have hn := hA (n+1) + positivity + +theorem connected_patch_poincare (μ : Measure X) (Q : ℕ → Set X) (A : ℕ → ℝ) + (hA : ∀ n, 0≤A n) {f : X → ℝ} (m : ℕ → ℝ) (E : ℝ) (hE : 0≤E) (N : ℕ) + (hfin : ∀ n≤N, μ (Q n)≠⊤) + (hover : ∀ n (f x-c)^2) (Q n) μ) + (hloc : ∀ n≤N, localVariance μ (Q n) f (m n) ≤ A n*E) : + localVariance μ (patchCluster Q N) f (m 0) ≤ patchPoincareConstant μ Q A N*E := by + have hi : ∀ n≤N, ∀ c : ℝ, IntegrableOn (fun x => (f x-c)^2) (patchCluster Q n) μ := by + intro n hn + induction n with + | zero => exact hint 0 (by omega) + | succ n ih => + intro c + exact (ih (by omega) c).union (hint (n+1) hn c) + have hfinite : ∀ n≤N, μ (patchCluster Q n)≠⊤ := by + intro n hn + induction n with + | zero => exact hfin 0 (by omega) + | succ n ih => + exact ne_top_of_le_ne_top (ENNReal.add_ne_top.mpr ⟨ih (by omega),hfin (n+1) hn⟩) + (measure_union_le _ _) + have hall : ∀ n≤N, localVariance μ (patchCluster Q n) f (m 0) ≤ patchPoincareConstant μ Q A n*E := by + intro n hn + induction n with + | zero => exact hloc 0 (by omega) + | succ n ih => + exact overlap_poincare_glue μ hE (patchPoincareConstant_nonneg μ Q A hA n) (hA (n+1)) + (hfinite n (by omega)) (hfin (n+1) hn) (hover n (by omega)) + (hi n (by omega) (m 0)) (hint (n+1) hn (m (n+1))) (hint (n+1) hn (m 0)) + (ih (by omega)) (hloc (n+1) hn) + exact hall N le_rfl + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularPatch.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatch.lean new file mode 100644 index 0000000000000000000000000000000000000000..142dd753e845445cdbcb42bbeaffb7104c8b3d8e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatch.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.Unchanged + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma TwoFieldRankRegular.congr {u v : Coord3 → Fin 2 → ℝ} {O : Set Coord3} + (hO : IsOpen O) (h : TwoFieldRankRegular u O) (he : EqOn v u O) : + TwoFieldRankRegular v O := by + rcases h with h | h | ⟨κ,hκ⟩ + · left + intro x hx + rw [fderiv_eq_of_eqOn_open hO he hx] + exact h x hx + · right; left + obtain ⟨w,l,κ,hw,hl,hwd,hrel⟩ := h + exact ⟨w,l,κ,hw,hl,hwd,fun x hx j => by rw [he hx]; exact hrel x hx j⟩ + · exact Or.inr (Or.inr ⟨κ,fun x hx => (he hx).trans (hκ x hx)⟩) + +def RegularPatch (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (O : Set Coord3) : Prop := + IsOpen O ∧ ContDiffOn ℝ (↑(⊤ : ℕ∞)) u O ∧ + ContDiffOn ℝ (↑(⊤ : ℕ∞)) (fun x => (A x).val) O ∧ TwoFieldRankRegular u O + +lemma RegularPatch.mono {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {O W : Set Coord3} (h : RegularPatch u A O) (hW : IsOpen W) (hWO : W ⊆ O) : + RegularPatch u A W := + ⟨hW,h.2.1.mono hWO,h.2.2.1.mono hWO,h.2.2.2.mono hWO⟩ + +lemma RegularPatch.congr {u v : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} + {O : Set Coord3} (h : RegularPatch u A O) (hu : EqOn v u O) (hA : EqOn B A O) : + RegularPatch v B O := by + exact ⟨h.1,h.2.1.congr hu,h.2.2.1.congr (fun x hx => congrArg Subtype.val (hA hx)), + h.2.2.2.congr h.1 hu⟩ + +def regularRegion (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (U : Set Coord3) : Set Coord3 := + ⋃ (O : Set Coord3) (_ : O ⊆ U) (_ : RegularPatch u A O), O + +lemma isOpen_regularRegion (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (U : Set Coord3) : IsOpen (regularRegion u A U) := by + exact isOpen_iUnion (fun O => isOpen_iUnion (fun _ => isOpen_iUnion (fun h => h.1))) + +lemma regularRegion_subset (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (U : Set Coord3) : regularRegion u A U ⊆ U := by + intro x hx + obtain ⟨O,hx⟩ := mem_iUnion.mp hx + obtain ⟨hOU,hx⟩ := mem_iUnion.mp hx + obtain ⟨_,hx⟩ := mem_iUnion.mp hx + exact hOU hx + +lemma mem_regularRegion_iff {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {U : Set Coord3} {p : Coord3} : p ∈ regularRegion u A U ↔ + ∃ O : Set Coord3, O ⊆ U ∧ RegularPatch u A O ∧ p ∈ O := by + simp only [regularRegion, mem_iUnion, exists_prop] + +lemma exists_precompact_regular_patch {u : Coord3 → Fin 2 → ℝ} + {A : Coord3 → Symmetric3} {U : Set Coord3} {p : Coord3} + (hp : p ∈ regularRegion u A U) : + ∃ W : Set Coord3, p ∈ W ∧ closure W ⊆ U ∧ IsCompact (closure W) ∧ RegularPatch u A W := by + obtain ⟨O,hOU,hO,hpO⟩ := mem_regularRegion_iff.mp hp + obtain ⟨W,hW,hpW,hWO,hWc⟩ := exists_precompact_open_inside hO.1 hpO + exact ⟨W,hpW,hWO.trans hOU,hWc,hO.mono hW (subset_closure.trans hWO)⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchCoordinates.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..482950cef94eadf24abcf0fbc71d28295daf6e20 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchCoordinates.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.RegularPatch + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma TwoFieldRankRegular.comp {u : Coord3 → Fin 2 → ℝ} {O V : Set Coord3} + (hO : IsOpen O) (hV : IsOpen V) + (hu : ContDiffOn ℝ (↑(⊤:ℕ∞)) u O) (h : TwoFieldRankRegular u O) + {P : Coord3 → Coord3} (hP : ContDiffOn ℝ (↑(⊤:ℕ∞)) P V) + (hm : MapsTo P V O) (hd : ∀ x∈V,Function.Surjective (fderiv ℝ P x)) : + TwoFieldRankRegular (fun x => u (P x)) V := by + have hPd (x) (hx : x∈V) := + (hP.differentiableOn (by simp) x hx).differentiableAt (hV.mem_nhds hx) + rcases h with h|h|⟨κ,hκ⟩ + · left + intro x hx + have hud := (hu.differentiableOn (by simp) (P x) (hm hx)).differentiableAt + (hO.mem_nhds (hm hx)) + change LinearIndependent ℝ (gradientColumns (fderiv ℝ (u ∘ P) x)).col + rw [(hud.hasFDerivAt.comp x (hPd x hx).hasFDerivAt).fderiv] + exact gradientColumns_rank _ ((gradientColumns_surjective _ (h (P x) (hm hx))).comp (hd x hx)) + · right; left + obtain ⟨v,l,κ,hv,hl,hvd,he⟩ := h + refine ⟨fun x => v (P x),l,κ,hv.comp hP hm,hl,?_,fun x hx j => he (P x) (hm hx) j⟩ + intro x hx hz + have hvd' := (hv.differentiableOn (by simp) (P x) (hm hx)).differentiableAt + (hO.mem_nhds (hm hx)) + change fderiv ℝ (v ∘ P) x=0 at hz + rw [(hvd'.hasFDerivAt.comp x (hPd x hx).hasFDerivAt).fderiv] at hz + apply hvd (P x) (hm hx) + ext y + obtain ⟨t,ht⟩ := hd x hx y + have ht' := congrArg (fun D : Coord3 →L[ℝ] ℝ => D t) hz + simpa only [ContinuousLinearMap.comp_apply,ht,_root_.zero_apply] using ht' + · exact Or.inr (Or.inr ⟨κ,fun x hx => hκ (P x) (hm hx)⟩) + +lemma RegularPatch.comp {u : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} + {O V : Set Coord3} (h : RegularPatch u A O) (hV : IsOpen V) + {P : Coord3 → Coord3} (hP : ContDiffOn ℝ (↑(⊤:ℕ∞)) P V) + (hm : MapsTo P V O) (hd : ∀ x∈V,Function.Surjective (fderiv ℝ P x)) + (hB : ContDiffOn ℝ (↑(⊤:ℕ∞)) (fun x => (B x).val) V) : + RegularPatch (fun x => u (P x)) B V := + ⟨hV,h.2.1.comp hP hm,hB,h.2.2.2.comp h.1 hV h.2.1 hP hm hd⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchLinear.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchLinear.lean new file mode 100644 index 0000000000000000000000000000000000000000..78cb22405212baab28496a83b5bc5d1ad7a308b2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchLinear.lean @@ -0,0 +1,57 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactDepthReductionTwo + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +lemma TwoFieldRankRegular.linearCoordinates {u : Coord3 → Fin 2 → ℝ} {O : Set Coord3} + (hO : IsOpen O) (hu : ContDiffOn ℝ (↑(⊤:ℕ∞)) u O) + (h : TwoFieldRankRegular u O) (P : Coord3 ≃L[ℝ] Coord3) + (Q : (Fin 2 → ℝ) ≃L[ℝ] (Fin 2 → ℝ)) : + TwoFieldRankRegular (fun x => Q (u (P x))) (P ⁻¹' O) := by + rcases h with h|h|⟨κ,hκ⟩ + · left + intro x hx + have hd := (hu.differentiableOn (by simp) (P x) hx).differentiableAt (hO.mem_nhds hx) + have he := Q.hasFDerivAt.comp x (hd.hasFDerivAt.comp x P.hasFDerivAt) + change LinearIndependent ℝ (gradientColumns (fderiv ℝ (Q ∘ u ∘ P) x)).col + rw [he.fderiv] + apply gradientColumns_rank + exact Q.surjective.comp ((gradientColumns_surjective _ (h (P x) hx)).comp P.surjective) + · right; left + obtain ⟨v,l,κ,hv,hl,hd,he⟩ := h + refine ⟨fun x => v (P x),Q l,Q κ,?_,?_,?_,?_⟩ + · exact hv.comp P.contDiff.contDiffOn (fun _ hx => hx) + · obtain ⟨j,hj⟩ := hl + by_contra! hh + have hz : Q l=0 := funext hh + have hl0 : l=0 := Q.injective (hz.trans (map_zero Q).symm) + exact hj (congrFun hl0 j) + · intro x hx hz + have hxv := (hv.differentiableOn (by simp) (P x) hx).differentiableAt (hO.mem_nhds hx) + have hh := (hxv.hasFDerivAt.comp x P.hasFDerivAt).fderiv + change fderiv ℝ (v ∘ P) x=0 at hz + rw [hh] at hz + apply hd (P x) hx + ext y + have h := congrArg (fun D : Coord3 →L[ℝ] ℝ => D (P.symm y)) hz + change (fderiv ℝ v (P x)) (P (P.symm y))=0 at h + simpa only [P.apply_symm_apply,_root_.zero_apply] using h + · intro x hx j + have hh : u (P x)=v (P x) • l+κ := by + ext i + simpa only [Pi.add_apply,Pi.smul_apply,smul_eq_mul,mul_comm] using he (P x) hx i + change Q (u (P x)) j=Q l j*v (P x)+Q κ j + rw [hh,map_add,map_smul] + simp only [Pi.add_apply,Pi.smul_apply,smul_eq_mul,mul_comm] + · exact Or.inr (Or.inr ⟨Q κ,fun x hx => congrArg Q (hκ (P x) hx)⟩) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchTranslation.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchTranslation.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0d92e1d4621efae076d5e54914a65f6e35b9d6a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularPatchTranslation.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.AxialPairRank + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma TwoFieldRankRegular.translate {u : Coord3 → Fin 2 → ℝ} {O : Set Coord3} + (h : TwoFieldRankRegular u O) (c : Coord3) (d : Fin 2 → ℝ) : + TwoFieldRankRegular (fun x => u (x-c)+d) ((fun x => x-c) ⁻¹' O) := by + rcases h with h|h|⟨κ,hκ⟩ + · left + intro x hx + rw [fderiv_add_const,fderiv_comp_sub] + exact h (x-c) hx + · right; left + obtain ⟨v,l,κ,hv,hl,hd,he⟩ := h + refine ⟨fun x => v (x-c),l,κ+d,?_,hl,?_,?_⟩ + · exact hv.comp (contDiff_id.sub contDiff_const).contDiffOn (fun _ hx => hx) + · intro x hx + rw [fderiv_comp_sub] + exact hd (x-c) hx + · intro x hx j + simp only [Pi.add_apply,he (x-c) hx j] + ring + · exact Or.inr (Or.inr ⟨κ+d,fun x hx => by dsimp only; rw [hκ (x-c) hx]⟩) + +lemma RegularPatch.translate {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} {O : Set Coord3} + (h : RegularPatch u A O) (c : Coord3) (d : Fin 2 → ℝ) : + RegularPatch (fun x => u (x-c)+d) (fun x => A (x-c)) ((fun x => x-c) ⁻¹' O) := by + refine ⟨h.1.preimage (continuous_id.sub continuous_const),?_,?_,h.2.2.2.translate c d⟩ + · exact (h.2.1.comp (contDiff_id.sub contDiff_const).contDiffOn (fun _ hx => hx)).add contDiffOn_const + · exact h.2.2.1.comp (contDiff_id.sub contDiff_const).contDiffOn (fun _ hx => hx) + +lemma mem_regularRegion_translate {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {U : Set Coord3} {x c : Coord3} (h : x-c∈regularRegion u A U) (d : Fin 2 → ℝ) : + x∈regularRegion (fun y => u (y-c)+d) (fun y => A (y-c)) ((fun y => y-c) ⁻¹' U) := by + obtain ⟨O,hOU,hO,hxO⟩ := mem_regularRegion_iff.mp h + exact mem_regularRegion_iff.mpr ⟨(fun y => y-c) ⁻¹' O,preimage_mono hOU,hO.translate c d,hxO⟩ + +lemma mem_regularRegion_congr_nhds {u v : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} + {V U : Set Coord3} {x : Coord3} (h : x∈regularRegion u A V) + (hu : v =ᶠ[𝓝 x] u) (hA : B =ᶠ[𝓝 x] A) (hU : IsOpen U) (hx : x∈U) : + x∈regularRegion v B U := by + obtain ⟨O,hOV,hO,hxO⟩ := mem_regularRegion_iff.mp h + have hh : {y | y∈O ∧ y∈U ∧ v y=u y ∧ B y=A y}∈𝓝 x := by + filter_upwards [hO.1.mem_nhds hxO,hU.mem_nhds hx,hu,hA] with y hy0 hyU hyu hyA + exact ⟨hy0,hyU,hyu,hyA⟩ + obtain ⟨W,hWsub,hW,hxW⟩ := mem_nhds_iff.mp hh + refine mem_regularRegion_iff.mpr ⟨W,fun y hy => (hWsub hy).2.1,?_,hxW⟩ + exact (hO.mono hW (fun y hy => (hWsub hy).1)).congr + (fun y hy => (hWsub hy).2.2.1) (fun y hy => (hWsub hy).2.2.2) + +lemma axialPair_translate (f : Coord3 → ℝ) (c x : Coord3) : + axialPair f (x-c)+![c 0,0]=axialPair (fun y => f (y-c)) x := by + ext i + fin_cases i <;> simp [axialPair] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularPotentialCoordinates.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularPotentialCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..3e93a16737525d025fd11f7a72eb791241c9b186 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularPotentialCoordinates.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.LocalPhysicalCorrection + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +def potentialCompletion (D : Coord3 →L[ℝ] (Fin 2 → ℝ)) : Mat3 := + ![(gradientColumns D).col 0,(gradientColumns D).col 1, + crossProduct ((gradientColumns D).col 0) ((gradientColumns D).col 1)] + +lemma potentialCompletion_det_ne_zero (D : Coord3 →L[ℝ] (Fin 2 → ℝ)) + (hD : Function.Surjective D) : (potentialCompletion D).det≠0 := by + have hc : crossProduct ((gradientColumns D).col 0) ((gradientColumns D).col 1)≠0 := by + apply crossProduct_ne_zero_iff_linearIndependent.mpr + have he : ![(gradientColumns D).col 0,(gradientColumns D).col 1] = + (gradientColumns D).col := by + ext j i + fin_cases j <;> rfl + rw [he] + exact gradientColumns_rank D hD + rw [potentialCompletion,←triple_product_eq_det, + triple_product_permutation ((gradientColumns D).col 0), + triple_product_permutation ((gradientColumns D).col 1)] + exact mt dotProduct_self_eq_zero.mp hc + +lemma potentialCompletion_pairing (D : Coord3 →L[ℝ] (Fin 2 → ℝ)) (x : Coord3) : + coordinatePair (potentialCompletion D*ᵥx)=D x := by + rw [←gradientColumns_apply D x] + ext j + fin_cases j <;> rfl + +def potentialCompletionEquiv (D : Coord3 →L[ℝ] (Fin 2 → ℝ)) + (hD : Function.Surjective D) : Coord3 ≃L[ℝ] Coord3 := + (LinearMap.equivOfDetNeZero (Matrix.toLin' (potentialCompletion D)) + (by rw [LinearMap.det_toLin']; exact potentialCompletion_det_ne_zero D hD)).toContinuousLinearEquiv + +lemma potentialCompletionEquiv_pairing (D : Coord3 →L[ℝ] (Fin 2 → ℝ)) + (hD : Function.Surjective D) (x : Coord3) : + coordinatePair (potentialCompletionEquiv D hD x)=D x := + potentialCompletion_pairing D x + +theorem exists_regular_potential_coordinates + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (a : Coord3) (hD : Function.Surjective (fderiv ℝ u a)) + {U : Set Coord3} (hU : IsOpen U) (ha : a∈U) : + ∃ X : OpenPartialHomeomorph Coord3 Coord3, + a∈X.target ∧ X.target⊆U ∧ + ContDiffOn ℝ (↑(⊤:ℕ∞)) X X.source ∧ + ContDiff ℝ (↑(⊤:ℕ∞)) X.symm ∧ + u=coordinatePair∘X.symm := by + obtain ⟨Y,haY,hYU,hY,hYi,he,hder⟩ := exists_potential_chart hu a hD hU ha + let L : Coord3 ≃L[ℝ] Coord3 := potentialCompletionEquiv (fderiv ℝ u a) hD + let Z := Y.transHomeomorph L.toHomeomorph + refine ⟨Z.symm,haY,hYU,?_,?_,?_⟩ + · change ContDiffOn ℝ (↑(⊤:ℕ∞)) (fun z => Y.symm (L.symm z)) {z | L.symm z∈Y.target} + exact hYi.comp L.symm.contDiff.contDiffOn (fun _ hx => hx) + · change ContDiff ℝ (↑(⊤:ℕ∞)) (fun z => L (Y z)) + exact L.contDiff.comp hY + · funext x + exact (he x).symm.trans (potentialCompletionEquiv_pairing _ hD (Y x)).symm + +end ScalarConductivity + +end + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +lemma mem_correctionBox {a b x : Coord3} : x∈correctionBox a b ↔ ∀ i,a i x i-ε,fun i => x i+ε,fun i => by linarith, + mem_correctionBox.mpr (fun i => by constructor <;> linarith),?_⟩ + intro y hy + apply hball + rw [Metric.mem_ball,dist_pi_lt_iff hε] + intro i + rw [Real.dist_eq,abs_lt] + have hi := mem_correctionBox.mp hy i + constructor <;> linarith + +structure RegularCorrectionBox (u : Coord3 → Fin 2 → ℝ) (U : Set Coord3) where + chart : OpenPartialHomeomorph Coord3 Coord3 + lower : Coord3 + upper : Coord3 + widths : ∀ i,lower i (B.lower i+B.upper i)/2), + (fun i => (B.lower i+B.upper i)/2),?_,rfl⟩ + exact mem_correctionBox.mpr (fun i => by have := B.widths i; constructor <;> linarith) + +end RegularCorrectionBox + +theorem exists_regular_correction_box + {u : Coord3 → Fin 2 → ℝ} (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + {U : Set Coord3} (hU : IsOpen U) {p : Coord3} (hp : p∈U) + (hD : Function.Surjective (fderiv ℝ u p)) : + ∃ B : RegularCorrectionBox u U,p∈B.region := by + obtain ⟨X,hpX,hXU,hX,hXi,he⟩ := exists_regular_potential_coordinates hu p hD hU hp + obtain ⟨a,b,hab,hx,hs⟩ := exists_correctionBox_inside X.open_source (X.map_target hpX) + let B : RegularCorrectionBox u U := ⟨X,a,b,hab,hs,hX,hXi.contDiffOn,fun _ _ => congrFun he _,hXU⟩ + exact ⟨B,X.symm p,hx,X.right_inv hpX⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionCongrSubset.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionCongrSubset.lean new file mode 100644 index 0000000000000000000000000000000000000000..91ac2082196c3c8737917cc6bc6bdf9c717af180 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionCongrSubset.lean @@ -0,0 +1,199 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.SpectralExtensionNonemptyNonempty +import OAI.Analysis.Conductivity.Branching.MeasurableDisjointGluingMeasurable + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma regularRegion_congr_subset {u v : Coord3 → Fin 2 → ℝ} + {A B : Coord3 → Symmetric3} {O U : Set Coord3} (hOU : O ⊆ U) + (hu : EqOn v u O) (hA : EqOn B A O) : + regularRegion u A O ⊆ regularRegion v B U := by + intro x hx + obtain ⟨V,hVO,hV,hxV⟩ := mem_regularRegion_iff.mp hx + exact mem_regularRegion_iff.mpr ⟨V,hVO.trans hOU,hV.congr (hu.mono hVO) (hA.mono hVO),hxV⟩ + +lemma regularRegion_piecewise_ae + (μ : Measure Coord3) {I : Type*} [Fintype I] + {u v : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} {U : Set Coord3} + (O : I → Set Coord3) (hO : ∀ i, IsOpen (O i)) (hOU : ∀ i, O i ⊆ U) + (old : μ (U \ regularRegion u A U) = 0) + (localgood : ∀ i, μ (O i \ regularRegion v B (O i)) = 0) + (hu : EqOn v u (⋃ i, O i)ᶜ) (hA : EqOn B A (⋃ i, O i)ᶜ) + (hnull : ∀ i, μ (frontier (O i)) = 0) : + μ (U \ regularRegion v B U) = 0 := by + have hs : U \ regularRegion v B U ⊆ (U \ regularRegion u A U) ∪ + (⋃ i, O i \ regularRegion v B (O i)) ∪ (⋃ i, frontier (O i)) := by + intro x hx + by_cases hr : x ∈ regularRegion u A U + · by_cases hi : x ∈ ⋃ i, O i + · obtain ⟨i,hi⟩ := mem_iUnion.mp hi + exact Or.inl (Or.inr (mem_iUnion.mpr ⟨i,hi,fun hh => hx.2 + (regularRegion_congr_subset (hOU i) (fun _ _ => rfl) (fun _ _ => rfl) hh)⟩)) + · by_cases hf : x ∈ ⋃ i, frontier (O i) + · exact Or.inr hf + · exfalso + apply hx.2 + obtain ⟨V,hVU,hV,hxV⟩ := mem_regularRegion_iff.mp hr + let W := V \ ⋃ i, closure (O i) + have hW : IsOpen W := hV.1.sdiff (isClosed_iUnion_of_finite (fun _ => isClosed_closure)) + have hxW : x ∈ W := by + refine ⟨hxV,?_⟩ + intro hh + obtain ⟨i,hi'⟩ := mem_iUnion.mp hh + apply hf + refine mem_iUnion.mpr ⟨i,?_⟩ + rw [frontier,(hO i).interior_eq] + exact ⟨hi',fun hh => hi (mem_iUnion.mpr ⟨i,hh⟩)⟩ + have hWoff : W ⊆ (⋃ i, O i)ᶜ := by + intro y hy hh + obtain ⟨i,hyi⟩ := mem_iUnion.mp hh + exact hy.2 (mem_iUnion.mpr ⟨i,subset_closure hyi⟩) + exact mem_regularRegion_iff.mpr ⟨W,sdiff_subset.trans hVU, + (hV.mono hW sdiff_subset).congr (hu.mono hWoff) (hA.mono hWoff),hxW⟩ + · exact Or.inl (Or.inl ⟨hx.1,hr⟩) + exact measure_mono_null hs (measure_union_null (measure_union_null old + (measure_iUnion_null localgood)) (measure_iUnion_null hnull)) + +end ScalarConductivity + +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise ENNReal + +lemma regularRegion_restrict_open {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + {U O : Set Coord3} (hO : IsOpen O) : + O ∩ regularRegion u A U ⊆ regularRegion u A O := by + intro x hx + obtain ⟨V,hVU,hV,hxV⟩ := mem_regularRegion_iff.mp hx.2 + exact mem_regularRegion_iff.mpr ⟨V ∩ O,inter_subset_right, + hV.mono (hV.1.inter hO) inter_subset_left,hxV,hx.1⟩ + +theorem fine_global_scalar_tensor_approximation + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) + {η ε δ : ℝ} (hη : 0 < η) (hε : 0 < ε) (hδ : 0 < δ) : + ∃ (N : ℕ) (O : Fin N → Set Coord3) (center : Fin N → Coord3) + (R : ∀ i, CompactGlobalUpdate μ (O i) u A) (S : CompactGlobalUpdate μ U u A), + (∀ i, IsOpen (O i) ∧ closure (O i) ⊆ U ∧ closure (O i) ⊆ Metric.ball (center i) δ) ∧ + Pairwise (fun i j => Disjoint (O i) (O j)) ∧ + S.du = (fun x => ∑ i, (R i).du x) ∧ S.dF = (fun x => ∑ i, (R i).dF x) ∧ + μ (U \ regularRegion (fun x => u x+S.du x) S.tensor U) = 0 ∧ + (∀ᵐ x ∂μ, x ∈ U → S.tensor x ∈ matrixFiniteLaminate a b) ∧ + μ (U \ S.tensor ⁻¹' spectralExtension (scalarNeighbourhood a b η)) ≤ ENNReal.ofReal ε := by + classical + let G := regularRegion u A U + have hGo : IsOpen G := isOpen_regularRegion u A U + have hGU : G ⊆ U := regularRegion_subset u A U + obtain ⟨N,O,tag,center,hO,hd,hmiss⟩ := finite_disjoint_localization_fine μ hGo.measurableSet + (hUb.subset hGU).measure_lt_top.ne (fun _ : Unit => G) (fun _ => hGo) + (fun x hx => mem_iUnion.mpr ⟨(),hx⟩) + (ENNReal.ofReal_pos.mpr (by linarith : 0 < ε/2)).ne' hδ + have hOU : ∀ i, O i ⊆ U := fun i => subset_closure.trans ((hO i).2.2.1.trans hGU) + have hOr : ∀ i, μ (O i \ regularRegion u A (O i)) = 0 := by + intro i + have hs : O i ⊆ regularRegion u A (O i) := fun x hx => + regularRegion_restrict_open (hO i).1 ⟨hx,(hO i).2.2.1 (subset_closure hx)⟩ + simp only [sdiff_eq_empty.mpr hs,measure_empty] + let ρ : ℝ := (ε/2)/(N+1) + have hρ : 0 < ρ := div_pos (by linarith) (by positivity) + have hlocal : ∀ i, ∃ R : CompactGlobalUpdate μ (O i) u A, + μ (O i \ regularRegion (fun x => u x+R.du x) R.tensor (O i)) = 0 ∧ + (∀ᵐ x ∂μ, x ∈ O i → R.tensor x ∈ matrixFiniteLaminate a b) ∧ + μ (O i \ R.tensor ⁻¹' spectralExtension (scalarNeighbourhood a b η)) ≤ ENNReal.ofReal ρ := by + intro i + apply global_scalar_tensor_approximation μ ha hab (hO i).1.measurableSet (hUb.subset (hOU i)) u A hAm + (fun j ψ hs hc ht => hint j ψ hs hc (ht.trans (hOU i))) + (fun j ψ hs hc ht => hdiv j ψ hs hc (ht.trans (hOU i))) (hOr i) + · filter_upwards [hgraph] with x hx + exact fun hi => hx (hOU i hi) + · exact hη + · exact hρ + choose R hRreg hRG hRbad using hlocal + obtain ⟨S,hsu,hsF,hS,hSoff⟩ := assemble_global_updates μ O (fun i => (hO i).1) hOU hd u A hAm R + have hsuoff : EqOn (fun x => u x+S.du x) u (⋃ i, O i)ᶜ := by + intro x hx + change u x+S.du x = u x + rw [hsu] + change u x+(∑ i, (R i).du x) = u x + rw [supported_sum_eq_zero_off O _ (fun i => (R i).support_du) hx,add_zero] + have hregS : μ (U \ regularRegion (fun x => u x+S.du x) S.tensor U) = 0 := by + apply regularRegion_piecewise_ae μ O (fun i => (hO i).1) hOU hreg _ hsuoff hSoff + (fun i => (hO i).2.2.2.1) + intro i + apply measure_mono_null _ (hRreg i) + exact sdiff_subset_sdiff_right (regularRegion_congr_subset Subset.rfl + (fun x hx => by rw [(hS i).1 hx]) (hS i).2.2) + refine ⟨N,O,center,R,S,fun i => ⟨(hO i).1,(hO i).2.2.1.trans hGU,(hO i).2.2.2.2⟩, + hd,hsu,hsF,hregS,?_,?_⟩ + · have hRGall : ∀ᵐ x ∂μ, ∀ i, x ∈ O i → (R i).tensor x ∈ matrixFiniteLaminate a b := + (ae_all_iff).mpr hRG + filter_upwards [hgraph,hRGall] with x hx hRx + intro hxU + by_cases hi : x ∈ ⋃ i, O i + · obtain ⟨i,hi⟩ := mem_iUnion.mp hi + rw [(hS i).2.2 hi] + exact hRx i hi + · rw [hSoff hi] + exact hx hxU + · let T := spectralExtension (scalarNeighbourhood a b η) + let bad : Fin N → Set Coord3 := fun i => O i \ (R i).tensor ⁻¹' T + have hs : U \ S.tensor ⁻¹' T ⊆ (U \ G) ∪ ((G \ ⋃ i, O i) ∪ ⋃ i, bad i) := by + intro x hx + by_cases hxG : x ∈ G + · right + by_cases hxO : x ∈ ⋃ i, O i + · right + obtain ⟨i,hi⟩ := mem_iUnion.mp hxO + exact mem_iUnion.mpr ⟨i,hi,fun ht => hx.2 (by change S.tensor x ∈ T; rw [(hS i).2.2 hi]; exact ht)⟩ + · exact Or.inl ⟨hxG,hxO⟩ + · exact Or.inl ⟨hx.1,hxG⟩ + have hsum : (∑ i : Fin N, μ (bad i)) ≤ ENNReal.ofReal (ε/2) := by + calc + _ ≤ ∑ _i : Fin N, ENNReal.ofReal ρ := Finset.sum_le_sum (fun i _ => hRbad i) + _ = ENNReal.ofReal ((N : ℝ)*ρ) := by simp [ENNReal.ofReal_mul] + _ ≤ ENNReal.ofReal (ε/2) := ENNReal.ofReal_le_ofReal (by + dsimp [ρ] + rw [← mul_div_assoc] + apply (div_le_iff₀ (by positivity : (0:ℝ) < N+1)).mpr + nlinarith) + calc + _ ≤ μ (U \ G) + (μ (G \ ⋃ i, O i) + ∑ i, μ (bad i)) := + (measure_mono (μ := μ) hs).trans ((measure_union_le _ _).trans + (add_le_add le_rfl ((measure_union_le _ _).trans (add_le_add le_rfl (measure_iUnion_fintype_le μ bad))))) + _ ≤ ENNReal.ofReal (ε/2)+ENNReal.ofReal (ε/2) := by + rw [hreg,zero_add] + exact add_le_add hmiss.le hsum + _ = ENNReal.ofReal ε := by + rw [← ENNReal.ofReal_add (by linarith) (by linarith)] + congr 1 + ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionFiniteGluing.lean b/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionFiniteGluing.lean new file mode 100644 index 0000000000000000000000000000000000000000..a663bd9c12ad3158802a7a6f1db70206e12822ac --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/RegularRegionFiniteGluing.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.RegularPatch + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +lemma regularRegion_finite_gluing + {I : Type*} [Fintype I] + {u v : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} {U : Set Coord3} + (O : I → Set Coord3) (hOU : ∀ i, O i ⊆ U) + (hnew : ∀ i, RegularPatch v B (O i)) + (hu : EqOn v u (⋃ i, O i)ᶜ) (hA : EqOn B A (⋃ i, O i)ᶜ) : + regularRegion u A U \ (⋃ i, frontier (O i)) ⊆ regularRegion v B U := by + intro x hx + by_cases hxi : x ∈ ⋃ i, O i + · obtain ⟨i,hi⟩ := mem_iUnion.mp hxi + exact mem_regularRegion_iff.mpr ⟨O i,hOU i,hnew i,hi⟩ + · obtain ⟨V,hVU,hV,hxV⟩ := mem_regularRegion_iff.mp hx.1 + let W := V \ ⋃ i, closure (O i) + have hclosed : IsClosed (⋃ i, closure (O i)) := isClosed_iUnion_of_finite (fun _ => isClosed_closure) + have hW : IsOpen W := hV.1.sdiff hclosed + have hxW : x ∈ W := by + refine ⟨hxV,?_⟩ + intro hxc + obtain ⟨i,hi⟩ := mem_iUnion.mp hxc + apply hx.2 + refine mem_iUnion.mpr ⟨i,?_⟩ + rw [frontier, (hnew i).1.interior_eq] + exact ⟨hi,fun hh => hxi (mem_iUnion.mpr ⟨i,hh⟩)⟩ + have hWoff : W ⊆ (⋃ i, O i)ᶜ := by + intro y hy hi + apply hy.2 + obtain ⟨i,hyi⟩ := mem_iUnion.mp hi + exact mem_iUnion.mpr ⟨i,subset_closure hyi⟩ + exact mem_regularRegion_iff.mpr ⟨W,sdiff_subset.trans hVU, + (hV.mono hW sdiff_subset).congr (hu.mono hWoff) (hA.mono hWoff),hxW⟩ + +lemma regularRegion_finite_gluing_ae + (μ : Measure Coord3) {I : Type*} [Fintype I] + {u v : Coord3 → Fin 2 → ℝ} {A B : Coord3 → Symmetric3} {U : Set Coord3} + (hold : μ (U \ regularRegion u A U) = 0) + (O : I → Set Coord3) (hOU : ∀ i, O i ⊆ U) + (hnew : ∀ i, RegularPatch v B (O i)) + (hu : EqOn v u (⋃ i, O i)ᶜ) (hA : EqOn B A (⋃ i, O i)ᶜ) + (hnull : ∀ i, μ (frontier (O i)) = 0) : + μ (U \ regularRegion v B U) = 0 := by + have hs : U \ regularRegion v B U ⊆ + (U \ regularRegion u A U) ∪ (⋃ i, frontier (O i)) := by + intro x hx + by_cases hr : x ∈ regularRegion u A U + · right + by_contra hf + exact hx.2 (regularRegion_finite_gluing O hOU hnew hu hA ⟨hr,hf⟩) + · exact Or.inl ⟨hx.1,hr⟩ + exact measure_mono_null hs (measure_union_null hold (measure_iUnion_null hnull)) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarRate.lean b/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarRate.lean new file mode 100644 index 0000000000000000000000000000000000000000..1334792faa016fc5275b8d12dd6d26489abca9e9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarRate.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarBand +import OAI.Analysis.Conductivity.Fourier.PoissonTraceRate +import OAI.Analysis.Conductivity.Fourier.AttachedEndPoisson + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal + +lemma sourceAngular_time_displacement (t b : ℝ) (θ : UnitAddTorus (Fin 2)) : + ‖sourceAngularCollar t θ-sourceAngularCollar b θ‖≤8*|t-b| := by + rw [show sourceAngularCollar t θ=sourceAngularCollar b θ+(t-b) • sourceAngularVelocity θ by + simpa only [add_sub_cancel] using sourceAngular_affine b (t-b) θ,add_sub_cancel_left,norm_smul, + Real.norm_eq_abs] + simpa only [mul_comm] using mul_le_mul_of_nonneg_left (sourceAngularVelocity_norm θ) (abs_nonneg (t-b)) + +lemma smooth_sourceCollar_lipschitz {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) : + ∃ K : ℝ≥0,LipschitzOnWith K q (sourceClosedCollarBand (-(1:ℝ)/100) (1/100)) := by + obtain ⟨R,hR⟩ := (isCompact_sourceClosedCollarBand (le_refl _) (le_refl _)).isBounded.subset_closedBall 0 + obtain ⟨K,hK⟩ := hq.contDiffOn.exists_lipschitzOnWith (s:=Metric.closedBall 0 R) + (by simp) (convex_closedBall (0:Fin 3 → ℝ) R) (isCompact_closedBall _ _) + exact ⟨K,hK.mono hR⟩ + +lemma smooth_sourceCollar_value_displacement {q : (Fin 3 → ℝ) → ℝ} {K : ℝ≥0} + (hK : LipschitzOnWith K q (sourceClosedCollarBand (-(1:ℝ)/100) (1/100))) + {t b : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : + |q (sourceAngularCollar t θ)-q (sourceAngularCollar b θ)|≤8*(K:ℝ)*|t-b| := by + have ht' : sourceAngularCollar t θ∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := by + change sourceCollarTime (sourceAngularCollar t θ)∈Icc (-(1:ℝ)/100) (1/100) + rw [sourceAngular_time ht]; exact ht + have hb' : sourceAngularCollar b θ∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := by + change sourceCollarTime (sourceAngularCollar b θ)∈Icc (-(1:ℝ)/100) (1/100) + rw [sourceAngular_time hb]; exact hb + have H := (hK.dist_le_mul _ ht' _ hb').trans + (mul_le_mul_of_nonneg_left (sourceAngular_time_displacement t b θ) K.coe_nonneg) + simpa only [Real.dist_eq,dist_eq_norm,Real.norm_eq_abs,mul_assoc,mul_left_comm] using H + +local instance smoothCollarRateMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance smoothCollarRateProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma endPoissonField_eq_traceFlow {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (q : C(UnitAddTorus (Fin 2),ℂ)) + (hq : ∀ h,f.val 0 h=mFourierCoeff q h) {t : ℝ} (ht : 0 (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) : + (∫ θ,((attachedEndPoissonField s f a b 0 (sourceAngularCollar t θ)).re- + q (sourceAngularCollar t θ))^2)≤(2*a^2*‖g‖^2+2*(8*(K:ℝ))^2)*(t-b)^2 := by + let Q : C(UnitAddTorus (Fin 2),ℂ) := ⟨fun θ => (q (sourceAngularCollar b θ):ℂ), + Complex.continuous_ofReal.comp (hq.continuous.comp (continuous_sourceAngularCollar b))⟩ + let P := torusPoissonContinuous s (a*(t-b)) (Q.toLp 2 volume ℂ) + have he (θ : UnitAddTorus (Fin 2)) : + attachedEndPoissonField s f a b 0 (sourceAngularCollar t θ)=P θ := + (attachedEndPoissonField_angular s f a b 0 ht θ).trans + (endPoissonField_eq_traceFlow hs f Q htrace hpos θ) + have hP : Continuous (fun θ => (P θ).re-q (sourceAngularCollar t θ)) := + (Complex.continuous_re.comp P.continuous).sub (hq.continuous.comp (continuous_sourceAngularCollar t)) + simp_rw [he] + have hbound (θ : UnitAddTorus (Fin 2)) : + ((P θ).re-q (sourceAngularCollar t θ))^2≤ + 2*‖P θ-Q θ‖^2+2*(8*(K:ℝ)*|t-b|)^2 := by + have hp := Complex.abs_re_le_norm (P θ-Q θ) + have hq' := smooth_sourceCollar_value_displacement hK ht hb θ + have hq'' : |q (sourceAngularCollar b θ)-q (sourceAngularCollar t θ)|≤8*(K:ℝ)*|t-b| := by + rwa [abs_sub_comm] at hq' + have h1 := pow_le_pow_left₀ (abs_nonneg _) hp 2 + have h2 := pow_le_pow_left₀ (abs_nonneg _) hq'' 2 + simp only [sq_abs,Complex.sub_re,Complex.ofReal_re,Q,ContinuousMap.coe_mk] at h1 h2 + dsimp only [Q,ContinuousMap.coe_mk] + nlinarith [sq_nonneg ((P θ).re-q (sourceAngularCollar b θ)- + (q (sourceAngularCollar b θ)-q (sourceAngularCollar t θ)))] + have hpint : Integrable (fun θ => ‖P θ-Q θ‖^2) := + (((P.continuous.sub Q.continuous).norm).pow 2).integrable_of_hasCompactSupport (isCompact_univ.of_isClosed_subset (isClosed_tsupport _) (subset_univ _)) + have hfin : Integrable (fun θ => ((P θ).re-q (sourceAngularCollar t θ))^2) := + (hP.pow 2).integrable_of_hasCompactSupport (isCompact_univ.of_isClosed_subset (isClosed_tsupport _) (subset_univ _)) + have H := integral_mono hfin ((hpint.const_mul 2).add (integrable_const _)) hbound + simp only [Pi.add_apply] at H + rw [integral_add (hpint.const_mul 2) (integrable_const _),integral_const_mul,integral_const] at H + have hrate : (∫ θ,‖P θ-Q θ‖^2)≤(a*(t-b))^2*‖g‖^2 := + torusPoissonContinuous_trace_sq hs hpos Q g (fun h => by rw [hg,mFourierCoeff_toLp,htrace]; rfl) + simp only [probReal_univ,one_smul] at H + calc + _ ≤ 2*((a*(t-b))^2*‖g‖^2)+2*(8*(K:ℝ)*|t-b|)^2 := by linarith + _ = _ := by rw [mul_pow,mul_pow,sq_abs]; ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarTrace.lean b/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4e39467f98c10379f992373bd6c1b5b2c831c1c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/SmoothCollarTrace.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.AttachedEndMatchedH1 + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance smoothCollarTraceCircleMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance smoothCollarTraceCircleIsProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +def smoothCollarTraceFourier (b : ℝ) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) : SpectralL2 TorusModes := + (mFourierBasis (d:=Fin 2)).repr + (ContinuousMap.toLp 2 volume ℂ + ⟨fun θ => (q (sourceAngularCollar b θ):ℂ), + Complex.continuous_ofReal.comp (hq.continuous.comp (continuous_sourceAngularCollar b))⟩) + +lemma smoothCollarTraceFourier_apply (b : ℝ) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (h : TorusModes) : + smoothCollarTraceFourier b hq h=mFourierCoeff (fun θ => (q (sourceAngularCollar b θ):ℂ)) h := by + rw [smoothCollarTraceFourier,mFourierBasis_repr,mFourierCoeff_toLp] + rfl + +def smoothCollarTrace (s : Fin 3 → ℝ) (b : ℝ) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) : spectralTraceGraph (torusRate s) := + ((spectralTraceGraph_exists_iff (w:=torusRate s) (fun h => Real.sqrt_nonneg _) (smoothCollarTraceFourier b hq)).mpr + (by simpa only [smoothCollarTraceFourier_apply] using sourceAngularTrace_summable s b hq)).choose + +lemma smoothCollarTrace_fst (s : Fin 3 → ℝ) (b : ℝ) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (h : TorusModes) : + (smoothCollarTrace s b hq).val 0 h=mFourierCoeff (fun θ => (q (sourceAngularCollar b θ):ℂ)) h := by + have he := ((spectralTraceGraph_exists_iff (w:=torusRate s) (fun h => Real.sqrt_nonneg _) (smoothCollarTraceFourier b hq)).mpr + (by simpa only [smoothCollarTraceFourier_apply] using sourceAngularTrace_summable s b hq)).choose_spec + change (smoothCollarTrace s b hq).val 0=smoothCollarTraceFourier b hq at he + rw [he,smoothCollarTraceFourier_apply] + +lemma smoothCollarTrace_rate_memℓp (s : Fin 3 → ℝ) (b : ℝ) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) : + Memℓp (fun h => (torusRate s h:ℂ)*(smoothCollarTrace s b hq).val 0 h) 2 := by + apply (memℓp_gen_iff (by norm_num : 0<(2:ℝ≥0∞).toReal)).mpr + simpa only [ENNReal.toReal_ofNat,Real.rpow_two,norm_mul,mul_pow, + Complex.norm_real,Real.norm_eq_abs,sq_abs,smoothCollarTrace_fst] using sourceAngularTrace_rate_sq_summable s b hq + +theorem smoothCollarTrace_matched_H1 {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {q χ : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {a b η : ℝ} (ha : a≠0) (hη : 0<η) (hl : -(1:ℝ)/100≤b-η) (hr : b+η≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand (b-η) (b+η)) : + let f := smoothCollarTrace s b hq + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=cutMatchedValue (fun y => a*(sourceCollarTime y-b)) χ + (fun y => (attachedEndPoissonField s f a b 0 y).re-q y) (WithLp.ofLp x) ∧ + ∀ i,weakGradient w x i=cutMatchedGradient (fun y => a*(sourceCollarTime y-b)) χ + (fun y => (attachedEndPoissonField s f a b 0 y).re-q y) + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y-fderiv ℝ q y) + i (WithLp.ofLp x)) := by + exact smooth_attachedEnd_matched_H1 hs _ hq hχ hc hχb ha hη hl hr hχs + (smoothCollarTrace_fst s b hq) + ⟨_,smoothCollarTrace_rate_memℓp s b hq⟩ (fun _ => rfl) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/SplitJacobian.lean b/lean/OAI/Analysis/Conductivity/Geometry/SplitJacobian.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b9f8735401690109e133b05f5c57df553a28391 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/SplitJacobian.lean @@ -0,0 +1,177 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompletedPotential +import OAI.Analysis.Conductivity.Variational.SynchronizedChartWaves +import OAI.Analysis.Conductivity.Variational.RepairPushedGraphStability + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set Filter Topology MeasureTheory +open scoped Matrix.Norms.Elementwise + +def splitJacobian (d : Coord3) (L : Coord3 →L[ℝ] ℝ) (c z : ℝ) : Mat3 := + operatorMatrix (ContinuousLinearMap.id ℝ Coord3 + lineShiftGradientOperator d c (z • L)) + +lemma splitJacobian_continuous (d : Coord3) (L : Coord3 →L[ℝ] ℝ) (c : ℝ) : + Continuous (splitJacobian d L c) := + operatorMatrix_continuous.comp (continuous_const.add + ((lineShiftGradientOperator d c).continuous.comp (continuous_id.smul continuous_const))) + +lemma matrix_two_pairing_symm (E F : Matrix (Fin 3) (Fin 2) ℝ) + (h : (Eᵀ * F) 1 0 = (Eᵀ * F) 0 1) : (Eᵀ * F).IsSymm := by + ext i j + fin_cases i <;> fin_cases j <;> simp_all [Matrix.transpose_apply] + +theorem exists_local_two_field_split + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + (u : Coord3 → Fin 2 → ℝ) (hu : ContDiff ℝ (↑(⊤ : ℕ∞)) u) + (A : Coord3 → Symmetric3) {p : Coord3} (hA : ContinuousAt A p) + (hD : Function.Surjective (fderiv ℝ u p)) + (d : Coord3) (L : Coord3 →L[ℝ] ℝ) (hLd : L d = 1) + (B : Mat3) (hB : B.IsSymm) (hBn : ∀ v, L (B *ᵥ v) = 0) + {a b c m : ℝ} (ha : 0 ≤ a) (hb : 0 ≤ b) (ha1 : a ≤ 1) (hb1 : b ≤ 1) + (hm : 0 < m) (hpath : ∀ z ∈ Icc (-a) b, m ≤ 1 + c * z) + (C : ℝ → Symmetric3) (hC : ∀ z ∈ Icc (-a) b, ContinuousAt C z) + (hdet : ∀ z ∈ Icc (-a) b, 0 < (splitJacobian d L c z).det) + (hconstit : ∀ z ∈ Icc (-a) b, + (C z).val = (splitJacobian d L c z).det⁻¹ • + (splitJacobian d L c z * ((A p).val + z • B) * (splitJacobian d L c z)ᵀ)) + {G : Set (ℝ × Symmetric3)} (hG : IsOpen G) + (hCG : ∀ z ∈ Icc (-a) b, (z, C z) ∈ G) + {U : Set Coord3} (hU : IsOpen U) (hpU : p ∈ U) : + ∃ (X : OpenPartialHomeomorph Coord3 Coord3) (V : Set Coord3), + IsOpen V ∧ p ∈ V ∧ V ⊆ U ∧ V ⊆ X.source ∧ + ContDiff ℝ (↑(⊤ : ℕ∞)) X ∧ + ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target ∧ + ∃ M : ℝ, 0 < M ∧ + ∀ H : SmoothScalar ℝ, Function.Periodic (smoothDirection 1 H).val 1 → + (∫ t in (0 : ℝ)..1, (smoothDirection 1 H).val t = 0) → + (∃ B : ℝ, ∀ t, |H.val t| ≤ B) → + (∀ t, -a ≤ (smoothDirection 1 H).val t ∧ (smoothDirection 1 H).val t ≤ b) → + ∀ χ : SmoothScalar Coord3, HasCompactSupport χ.val → tsupport χ.val ⊆ X '' V → + (∀ x, 0 ≤ χ.val x ∧ χ.val x ≤ 1) → + ∃ F : ℝ → Fin 2 → Coord3 → Coord3, + (∀ k j, ContDiff ℝ (↑(⊤ : ℕ∞)) (F k j)) ∧ + (∀ k j, HasCompactSupport (F k j) ∧ tsupport (F k j) ⊆ V ∧ + tsupport (F k j) ⊆ X.symm '' tsupport χ.val) ∧ + (∀ k j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ y, fderiv ℝ ψ y (F k j y) ∂μ) = 0) ∧ + ∀ᶠ k : ℝ in atTop, ∃ Y : Coord3 ≃ Coord3, + ContDiff ℝ (↑(⊤ : ℕ∞)) Y ∧ ContDiff ℝ (↑(⊤ : ℕ∞)) Y.symm ∧ + (∀ x ∉ V, Y x = x) ∧ Y '' V = V ∧ + (∀ x, Y x = x + (c * k⁻¹ * localPullback X χ.val x * + H.val (k * L (X x))) • d) ∧ + (∀ x, |(fderiv ℝ Y x).det| ≤ M) ∧ + ∀ x ∈ V, + let z := localPullback X χ.val x * (smoothDirection 1 H).val (k * L (X x)) + let E := gradientColumns (fderiv ℝ u x) + let Ft : Matrix (Fin 3) (Fin 2) ℝ := (A x).val * E + Matrix.of (fun i j => F k j x i) + let J := operatorMatrix (fderiv ℝ Y x) + let At := repairPushed (C z) J E Ft + 0 < J.det ∧ LinearIndependent ℝ E.col ∧ (z, At) ∈ G ∧ + At.val * gradientColumns (fderiv ℝ (u ∘ Y.symm) (Y x)) = pushFlux J Ft := by + classical + let D := fderiv ℝ u p + let E₀ := gradientColumns D + let E : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := fun y => gradientColumns (fderiv ℝ u y) + let F₀ := (A p).val * E₀ + let Fe : Coord3 → Matrix (Fin 3) (Fin 2) ℝ := fun y => (A y).val * E y + let J := splitJacobian d L c + let Fb : ℝ → Matrix (Fin 3) (Fin 2) ℝ := fun z => ((A p).val + z • B) * E₀ + have hEc : Continuous E := by + apply continuous_pi; intro i + apply continuous_pi; intro j + exact (continuous_apply j).comp ((hu.continuous_fderiv (by simp)).clm_apply continuous_const) + have hFc : ContinuousAt Fe p := matrix_mul_contAt (continuousAt_subtype_val.comp hA) hEc.continuousAt + have hFbc : Continuous Fb := by + apply continuous_iff_continuousAt.mpr + intro z + exact matrix_mul_contAt (continuousAt_const.add (continuousAt_id.smul continuousAt_const)) continuousAt_const + have hrank : LinearIndependent ℝ E₀.col := gradientColumns_rank D hD + have hexact : ∀ z ∈ Icc (-a) b, repairPushed (C z) (J z) E₀ (Fb z) = C z := by + intro z hz + exact repairPushed_exact (C z) (J z) ((A p).val + z • B) E₀ (hdet z hz).ne' (hconstit z hz) + obtain ⟨O, _, hKO, ε, hε, heps⟩ := repairPushed_graph_stability isCompact_Icc + C J (fun _ => E₀) Fb hC (fun _ _ => (splitJacobian_continuous d L c).continuousAt) + (fun _ _ => continuousAt_const) (fun _ _ => hFbc.continuousAt) hdet (fun _ _ => hrank) hG + (fun z hz => by rw [hexact z hz]; exact hCG z hz) + have hnb : ∀ᶠ x in 𝓝 p, ‖E x - E₀‖ < ε/2 ∧ ‖Fe x - F₀‖ < ε/2 := by + have he := hEc.continuousAt.eventually (Metric.ball_mem_nhds (E p) (half_pos hε)) + have hf := hFc.eventually (Metric.ball_mem_nhds (Fe p) (half_pos hε)) + simpa only [Metric.mem_ball, dist_eq_norm] using he.and hf + obtain ⟨W, hWb, hWo, hpW⟩ := mem_nhds_iff.mp hnb + obtain ⟨X, hpX, hXs, hX, hXi, hXu, hDX⟩ := exists_potential_chart hu p hD + (hU.inter hWo) ⟨hpU, hpW⟩ + have hpol := symmetric_wave_polarization D B hB L hBn + obtain ⟨V, hV, hpV, hVs, hpert⟩ := exists_synchronized_chart_waves + (by simp [Coord3]) μ X hX hXi D hD u (fun y _ => hXu y) + hpX hDX d L hLd ha hb ha1 hb1 hm (by positivity : 0 < ε/2) + hpath (B * E₀).col hpol.1 hpol.2 + obtain ⟨M, hM, hMbd⟩ := synchronized_det_bound d c L (ε/2) + refine ⟨X, V, hV, hpV, hVs.trans (fun _ hx => (hXs hx).1), hVs, hX, hXi, M, hM, ?_⟩ + intro H hHp hHm hH hHr χ hχ hχV hχb + obtain ⟨F, hF, hFs, hsym, hdiv, hlim⟩ := hpert H hHp hHm hH hHr χ hχ hχV hχb + refine ⟨F, hF, hFs, hdiv, ?_⟩ + filter_upwards [hlim] with k hk + obtain ⟨Y, hY, hYi, hoff, himage, hform, hFerr, hJerr⟩ := hk + refine ⟨Y, hY, hYi, hoff, himage, hform, ?_, ?_⟩ + · intro x + apply hMbd _ _ _ (hJerr x).le + have hz := scalar_cutoff_segment ha hb (localPullback_bounds X χ.val hχb x) (hHr (k * L (X x))) + exact abs_le.mpr ⟨by linarith only [hz.1, ha1], by linarith only [hz.2, hb1]⟩ + intro x hx + let z := localPullback X χ.val x * (smoothDirection 1 H).val (k * L (X x)) + let Q : Matrix (Fin 3) (Fin 2) ℝ := fun i j => F k j x i + let Jy := operatorMatrix (fderiv ℝ Y x) + have hz : z ∈ Icc (-a) b := scalar_cutoff_segment ha hb + (localPullback_bounds X χ.val hχb x) (hHr _) + have hsmall := hWb (hXs (hVs hx)).2 + have hdJ : ‖Jy - J z‖ < ε/2 := by + change ‖operatorMatrix (fderiv ℝ Y x) - operatorMatrix _‖ < ε/2 + rw [← operatorMatrix_sub] + exact (operatorMatrix_norm_le _).trans_lt (hJerr x) + have hdF : ‖Fe x + Q - Fb z‖ < ε := by + have hq : ‖Q - z • (B * E₀)‖ < ε/2 := by + apply columns_norm_lt _ (half_pos hε) + intro j + exact hFerr j x + have heq : Fe x + Q - Fb z = (Fe x - F₀) + (Q - z • (B * E₀)) := by + dsimp only [Fb, F₀] + rw [Matrix.add_mul, Matrix.smul_mul] + abel + rw [heq] + exact (norm_add_le _ _).trans_lt (by linarith only [hq, hsmall.2]) + have hbound : ‖(Jy - J z, E x - E₀, Fe x + Q - Fb z)‖ < ε := by + rw [Prod.norm_def, Prod.norm_def, max_lt_iff, max_lt_iff] + exact ⟨hdJ.trans (by linarith), hsmall.1.trans (by linarith), hdF⟩ + have hs := heps z (hKO hz) (Jy - J z) (E x - E₀) (Fe x + Q - Fb z) hbound + simp only [add_sub_cancel] at hs + refine ⟨hs.1, hs.2.1, hs.2.2, ?_⟩ + rw [gradientColumns_recomposition Y (hY.differentiable (by simp)) + (hYi.differentiable (by simp)) u (hu.differentiable (by simp))] + apply repairPushed_mul _ _ _ _ hs.1.ne' hs.2.1 + rw [Matrix.mul_add] + apply (symmetric_gram_pairing (A x) (E x)).add + apply matrix_two_pairing_symm + rw [← gradientColumns_pairing, ← gradientColumns_pairing] + exact hsym k x + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusAffineField.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusAffineField.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2636dc3b84b01681191a5887ee8722ba2917e04 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusAffineField.lean @@ -0,0 +1,63 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AffineFourierField +import OAI.Analysis.Conductivity.Flux.FlatBackgroundTensor +import OAI.Analysis.Conductivity.Fourier.TorusLeadingRealMode +import OAI.Analysis.Conductivity.Fourier.TorusSmoothModeJet + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus + +def torusAffineField (s : Fin 3 → ℝ) (κ : ℝ) (f : TorusL2) (x : Coord3) : ℝ := + κ*x 0+torusRealContinuation s f x + +lemma torusAffineField_smooth {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (κ : ℝ) (f : TorusL2) : ContDiffOn ℝ (↑(⊤:ℕ∞)) (torusAffineField s κ f) {x | 0 κ*x 0) by fun_prop).contDiffOn.add + (torusRealContinuation_smooth hs f) + +lemma torusAffineField_periodic (s : Fin 3 → ℝ) (κ : ℝ) (f : TorusL2) : + AngularPeriodic (2*Real.pi) (torusAffineField s κ f) := by + intro n x + simp only [torusAffineField,torusRealContinuation,torusAngles_shift] + simp [angularShift] + +lemma torusAffineField_polar_eventually {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (κ : ℝ) (f : TorusL2) {x : Coord3} (hx : 0 fderiv ℝ f x (Pi.single i 1)) := by + ext i + fin_cases i <;> simp [flatModeFlux,flatBackgroundTensor,Matrix.mulVec,dotProduct,Fin.sum_univ_three,flatAxis] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusDirectionalDerivative.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusDirectionalDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..89390b34f6de364b8ae6dd3e78c730cf5afa208f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusDirectionalDerivative.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusDirectionalFourier + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal +local instance torusDirectionalDerivativeMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance torusDirectionalDerivativeProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +abbrev TorusRealPlane := Fin 2 → ℝ + +def torusRealProjection (x : TorusRealPlane) : UnitAddTorus (Fin 2) := fun j => (x j:UnitAddCircle) +def torusRealRepresentative (θ : UnitAddTorus (Fin 2)) : TorusRealPlane := + (measurableEquivPiIoc (fun _ : Fin 2 => (0:ℝ)) θ).val + +lemma continuous_torusRealProjection : Continuous torusRealProjection := by + apply continuous_pi + intro j + exact (AddCircle.continuous_mk' (1:ℝ)).comp (continuous_apply j) + +lemma measurable_torusRealRepresentative : Measurable torusRealRepresentative := + measurable_subtype_coe.comp (measurableEquivPiIoc (fun _ : Fin 2 => (0:ℝ))).measurable + +lemma torusRealProjection_representative (θ : UnitAddTorus (Fin 2)) : + torusRealProjection (torusRealRepresentative θ)=θ := + (measurableEquivPiIoc (fun _ : Fin 2 => (0:ℝ))).symm_apply_apply θ + +lemma torusRealProjection_add (x y : TorusRealPlane) : + torusRealProjection (x+y)=torusRealProjection x+torusRealProjection y := by + ext j + simp [torusRealProjection] + +lemma torusRealProjection_direction (j : Fin 2) (t : ℝ) : + torusRealProjection (t • Pi.single j (1:ℝ))=torusCoordinateShift j t := by + ext i + by_cases hij : i=j <;> simp [torusRealProjection,torusCoordinateShift,hij] + +lemma torusRealRepresentative_ae {P : TorusRealPlane → Prop} + (h : ∀ᵐ x ∂(volume : Measure TorusRealPlane),P x) : + ∀ᵐ θ : UnitAddTorus (Fin 2), P (torusRealRepresentative θ) := by + let K : Set TorusRealPlane := {x | ∀ i,x i∈Ioc (0:ℝ) (0+1)} + have hK : MeasurableSet K := MeasurableSet.univ_pi' (fun _ => measurableSet_Ioc) + have hp := (measurePreserving_subtype_coe hK).comp + (measurePreserving_equivPiIoc (fun _ : Fin 2 => (0:ℝ))) + exact hp.quasiMeasurePreserving.ae (ae_restrict_of_ae h) + +lemma torusRealLift_lipschitz (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) + (hLip : ∀ j t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤(K:ℝ)*|t|) : + LipschitzWith (2*K) (fun x : TorusRealPlane => f (torusRealProjection x)) := by + apply LipschitzWith.of_dist_le_mul + intro x y + have he : torusRealProjection x=(torusRealProjection y+torusCoordinateShift 0 (x 0-y 0))+ + torusCoordinateShift 1 (x 1-y 1) := by + ext j + fin_cases j <;> simp [torusRealProjection,torusCoordinateShift] + have hx (j : Fin 2) : |x j-y j|≤dist x y := by + simpa only [Real.dist_eq] using dist_le_pi_dist x y j + calc + dist (f (torusRealProjection x)) (f (torusRealProjection y)) ≤ + dist (f (torusRealProjection x)) + (f (torusRealProjection y+torusCoordinateShift 0 (x 0-y 0)))+ + dist (f (torusRealProjection y+torusCoordinateShift 0 (x 0-y 0))) + (f (torusRealProjection y)) := dist_triangle _ _ _ + _≤(K:ℝ)*|x 1-y 1|+(K:ℝ)*|x 0-y 0| := by + apply add_le_add + · rw [dist_eq_norm,he] + exact hLip 1 _ _ + · rw [dist_eq_norm] + exact hLip 0 _ _ + _≤((2*K:ℝ≥0):ℝ)*dist x y := by + push_cast + nlinarith [mul_le_mul_of_nonneg_left (hx 0) K.coe_nonneg, + mul_le_mul_of_nonneg_left (hx 1) K.coe_nonneg] + +def torusDirectionalDerivative (f : UnitAddTorus (Fin 2) → ℂ) (j : Fin 2) + (θ : UnitAddTorus (Fin 2)) : ℂ := + lineDeriv ℝ (fun x => f (torusRealProjection x)) (torusRealRepresentative θ) (Pi.single j 1) + +lemma torusDirectionalDerivative_eq (f : UnitAddTorus (Fin 2) → ℂ) (j : Fin 2) + (θ : UnitAddTorus (Fin 2)) : + torusDirectionalDerivative f j θ=deriv (fun t => f (θ+torusCoordinateShift j t)) 0 := by + unfold torusDirectionalDerivative lineDeriv + congr 2 + ext t + change f (torusRealProjection (torusRealRepresentative θ+t • Pi.single j 1))=_ + rw [torusRealProjection_add,torusRealProjection_representative,torusRealProjection_direction] + +lemma measurable_torusDirectionalDerivative {f : UnitAddTorus (Fin 2) → ℂ} + (hf : Continuous f) (j : Fin 2) : Measurable (torusDirectionalDerivative f j) := + (measurable_lineDeriv (hf.comp continuous_torusRealProjection)).comp measurable_torusRealRepresentative + +lemma torusDirectionalDerivative_ae (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) + (hLip : ∀ j t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤(K:ℝ)*|t|) (j : Fin 2) : + ∀ᵐ θ : UnitAddTorus (Fin 2), + HasDerivAt (fun t => f (θ+torusCoordinateShift j t)) (torusDirectionalDerivative f j θ) 0 := by + have hd : ∀ᵐ x ∂(volume : Measure TorusRealPlane), + DifferentiableAt ℝ (fun y => f (torusRealProjection y)) x := + (torusRealLift_lipschitz f K hLip).ae_differentiableAt + filter_upwards [torusRealRepresentative_ae hd] with θ hθ + have he (t : ℝ) : f (torusRealProjection (torusRealRepresentative θ+t • Pi.single j 1))= + f (θ+torusCoordinateShift j t) := by + rw [torusRealProjection_add,torusRealProjection_representative,torusRealProjection_direction] + simpa only [HasLineDerivAt,he,torusDirectionalDerivative] using (hθ.lineDifferentiableAt (v:=Pi.single j 1)).hasLineDerivAt + +lemma torusDirectionalDerivative_norm (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) + (hLip : ∀ j t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤(K:ℝ)*|t|) + (j : Fin 2) (θ : UnitAddTorus (Fin 2)) : + ‖torusDirectionalDerivative f j θ‖≤2*K := by + have h := norm_lineDeriv_le_of_lipschitz ℝ (torusRealLift_lipschitz f K hLip) + (x₀:=torusRealRepresentative θ) (v:=Pi.single j 1) + simpa only [torusDirectionalDerivative,NNReal.coe_mul,NNReal.coe_ofNat, + Pi.norm_single,norm_one,mul_one] using h + +theorem torusDirectionalDerivative_fourier (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) + (hLip : ∀ j t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤(K:ℝ)*|t|) + (j : Fin 2) (h : TorusModes) : + mFourierCoeff (torusDirectionalDerivative f j) h= + (2*Real.pi*Complex.I*(h j))*mFourierCoeff f h := + mFourierCoeff_of_directional_derivative f j K K.coe_nonneg (hLip j) + (measurable_torusDirectionalDerivative f.continuous j).aestronglyMeasurable + (torusDirectionalDerivative_ae f K hLip j) h + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusExponential.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusExponential.lean new file mode 100644 index 0000000000000000000000000000000000000000..38408fadf42f80c0c382454d1f97fc1462d10dc1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusExponential.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusNonresonance + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +def torusSize (h : Fin 2 → ℤ) : ℝ := |(h 0:ℝ)|+|(h 1:ℝ)| +def torusRate (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : ℝ := √(torusQuadratic s h) + +lemma torusSize_nonneg (h : Fin 2 → ℤ) : 0≤torusSize h := by unfold torusSize; positivity + +lemma torusRate_lower {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (h : Fin 2 → ℤ) : torusSize h/2 ≤ torusRate s h := by + have hq := hs (h 0) (h 1) + change (1/2)*((h 0:ℝ)^2+(h 1:ℝ)^2) ≤ torusQuadratic s h at hq + have hq0 : 0≤torusQuadratic s h := le_trans (by positivity) hq + have hr := Real.sq_sqrt hq0 + have h0 := Real.sqrt_nonneg (torusQuadratic s h) + have ha := sq_abs (h 0:ℝ) + have hb := sq_abs (h 1:ℝ) + have hab := sq_nonneg (|(h 0:ℝ)|-|(h 1:ℝ)|) + dsimp [torusSize,torusRate] + nlinarith [abs_nonneg (h 0:ℝ),abs_nonneg (h 1:ℝ)] + +lemma int_exp_summable {r : ℝ} (hr : 0 exp (-r*|(z:ℝ)|)) := by + rw [summable_int_iff_summable_nat_and_neg] + have hn : Summable (fun n : ℕ => exp (-r*(n:ℝ))) := by + simpa only [mul_comm (-r)] using summable_exp_nat_mul_iff.mpr (neg_neg_of_pos hr) + constructor <;> simpa using hn + +lemma torus_exp_summable {r : ℝ} (hr : 0 exp (-r*torusSize h)) := by + have h := (int_exp_summable hr).mul_of_nonneg (int_exp_summable hr) + (fun _ => exp_nonneg _) (fun _ => exp_nonneg _) + have hh := (finTwoArrowEquiv ℤ).summable_iff.mpr h + convert hh using 1 + ext q + simp only [Function.comp_def,finTwoArrowEquiv,piFinTwoEquiv,Equiv.coe_fn_mk] + rw [torusSize,mul_add,exp_add] + +lemma torusRate_exp_summable {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {r : ℝ} (hr : 0 exp (-r*torusRate s h)) := by + refine (torus_exp_summable (show 0 exp_nonneg _) (fun h => ?_) + apply exp_le_exp.mpr + have := mul_le_mul_of_nonpos_left (torusRate_lower hs h) (by linarith : -r≤0) + linarith + +lemma pow_mul_exp_bound (n : ℕ) {r x : ℝ} (hr : 0 (torusRate s h)^n*exp (-r*torusRate s h)) := by + refine ((torusRate_exp_summable hs (show 0 by dsimp [torusRate]; positivity) ?_ + intro h + exact pow_mul_exp_bound n hr (sqrt_nonneg _) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusFaceIntegration.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusFaceIntegration.lean new file mode 100644 index 0000000000000000000000000000000000000000..28625571240b4d2472107abbe43d4e40bfdbc55c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusFaceIntegration.lean @@ -0,0 +1,158 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AngularIntegration + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +lemma unitCircle_volume_eq_haar : (volume : Measure UnitAddCircle)=AddCircle.haarAddCircle := by + simpa using (AddCircle.volume_eq_smul_haarAddCircle (T:=1)) + +lemma integral_unitTorus_iterated {F : UnitAddTorus (Fin 2) → ℝ} (hF : Continuous F) : + (∫ x,F x)=∫ θ : UnitAddCircle,∫ φ : UnitAddCircle,F ![θ,φ] + ∂AddCircle.haarAddCircle ∂AddCircle.haarAddCircle := by + have hc : Continuous (MeasurableEquiv.finTwoArrow.symm : + UnitAddCircle × UnitAddCircle → UnitAddTorus (Fin 2)) := by + change Continuous (fun p : UnitAddCircle × UnitAddCircle => ![p.1,p.2]) + fun_prop + rw [←(volume_preserving_finTwoArrow UnitAddCircle).symm.integral_comp'] + change (∫ x : UnitAddCircle × UnitAddCircle,F (MeasurableEquiv.finTwoArrow.symm x) + ∂volume.prod volume)=_ + rw [integral_prod (fun x : UnitAddCircle × UnitAddCircle => F (MeasurableEquiv.finTwoArrow.symm x)) + ((hF.comp hc).integrable_of_hasCompactSupport (HasCompactSupport.of_compactSpace _))] + simp only [unitCircle_volume_eq_haar] + rfl + +lemma continuous_faceRayAngle (w : ℝ) (j : Fin 4) : Continuous (faceRayAngle w j) := + continuous_iff_continuousAt.mpr (fun b => (hasDerivAt_faceRayAngle w j b).continuousAt) + +lemma continuous_parametric_unitInterval {X : Type*} [TopologicalSpace X] + [FirstCountableTopology X] [LocallyCompactSpace X] {f : X → ℝ → ℝ} + (hf : Continuous (Function.uncurry f)) : + Continuous (fun x => ∫ b in (-1:ℝ)..1,f x b) := by + have hh := continuous_parametric_integral_of_continuous (μ:=volume) hf (s:=Icc (-1:ℝ) 1) isCompact_Icc + simpa only [intervalIntegral.integral_of_le (by norm_num : (-1:ℝ)≤1), + integral_Icc_eq_integral_Ioc] using hh + +lemma continuous_torus_partial_integral {F : UnitAddTorus (Fin 2) → ℝ} (hF : Continuous F) : + Continuous (fun θ : UnitAddCircle => ∫ φ : UnitAddCircle,F ![θ,φ] + ∂AddCircle.haarAddCircle) := by + have hh := continuous_parametric_integral_of_continuous + (μ:=AddCircle.haarAddCircle) (f:=fun θ φ : UnitAddCircle => F ![θ,φ]) + (hF.comp (by change Continuous (fun p : UnitAddCircle × UnitAddCircle => ![p.1,p.2]); fun_prop)) + (s:=univ) isCompact_univ + simpa using hh + +def torusFaceTerm (w₀ w₁ : ℝ) (F : UnitAddTorus (Fin 2) → ℝ) + (j k : Fin 4) (a b : ℝ) : ℝ := + F ![((faceRayAngle w₀ j a:ℝ):UnitAddCircle),((faceRayAngle w₁ k b:ℝ):UnitAddCircle)]* + faceRayDensity w₁ k b + +lemma continuous_torusFaceTerm (w₀ w₁ : ℝ) {F : UnitAddTorus (Fin 2) → ℝ} + (hF : Continuous F) (j k : Fin 4) : + Continuous (Function.uncurry (torusFaceTerm w₀ w₁ F j k)) := by + have h0 := (AddCircle.continuous_mk' 1).comp (continuous_faceRayAngle w₀ j) + have h1 := (AddCircle.continuous_mk' 1).comp (continuous_faceRayAngle w₁ k) + have hv : Continuous (fun p : ℝ×ℝ => + ![((faceRayAngle w₀ j p.1:ℝ):UnitAddCircle),((faceRayAngle w₁ k p.2:ℝ):UnitAddCircle)]) := by + apply continuous_pi + intro i + fin_cases i + · exact h0.comp continuous_fst + · exact h1.comp continuous_snd + exact (hF.comp hv).mul ((continuous_faceRayDensity w₁ k).comp continuous_snd) + +theorem integral_unitTorus_faces {w₀ w₁ : ℝ} (hw₀ : 0 F ![((faceRayAngle w₀ j a:ℝ):UnitAddCircle),φ]) + (hF.comp (by fun_prop)) + simp_rw [hi,Finset.sum_mul] + exact intervalIntegral.integral_finsetSum (fun k _ => + ((continuous_parametric_unitInterval (continuous_torusFaceTerm w₀ w₁ hF j k)).mul + (continuous_faceRayDensity w₀ j)).intervalIntegrable _ _) + +lemma sourceAngular_face (t a b : ℝ) (i j : Fin 4) (ha : |a|≤1) (hb : |b|≤1) : + sourceAngularCollar t + ![((faceRayAngle 1 i a:ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j b:ℝ):UnitAddCircle)]= + sourceCollarPiece i j ![t,a,b] := by + have h0 := faceRayAngle_image (w:=1) (by norm_num) i ha + have h1 := faceRayAngle_image (w:=sourceRadialWidth) + (by norm_num [sourceRadialWidth,sourceHole]) j hb + ext k + fin_cases k <;> + simp [sourceAngularCollar,sourceAngularPolynomial,sourceRayCoordinates,h0,h1, + sourceCollarPiece,sourceCollarRadius] <;> ring_nf <;> simp + +lemma sourceAngularFace_continuous (t : ℝ) (i j : Fin 4) : + Continuous (fun p : ℝ×ℝ => sourceCollarPiece i j ![t,p.1,p.2]) := by + exact (sourceCollarPiece_contDiff i j).continuous.comp (by fun_prop) + +theorem integral_sourceAngular_le {f : (Fin 3 → ℝ) → ℝ} + (hf : Continuous f) (hn : ∀ z,0≤f z) (t : ℝ) : + (∫ x : UnitAddTorus (Fin 2),f (sourceAngularCollar t x))≤ + ((1/sourceRadialWidth)/(2*Real.pi))*((1:ℝ)/(2*Real.pi))* + ∑ i : Fin 4,∑ j : Fin 4,∫ a in (-1:ℝ)..1,∫ b in (-1:ℝ)..1, + f (sourceCollarPiece i j ![t,a,b]) := by + have hw : 0 f (sourceAngularCollar t x)) (w₀:=1) (w₁:=sourceRadialWidth) (by norm_num) hw + (hf.comp (continuous_sourceAngularCollar t))] + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro i _ + rw [Finset.mul_sum] + apply Finset.sum_le_sum + intro j _ + rw [←intervalIntegral.integral_const_mul] + apply intervalIntegral.integral_mono_on (by norm_num) + · exact ((continuous_parametric_unitInterval + (continuous_torusFaceTerm 1 sourceRadialWidth (hf.comp (continuous_sourceAngularCollar t)) i j)).mul + (continuous_faceRayDensity 1 i)).intervalIntegrable _ _ + · exact (continuous_const.mul (continuous_parametric_unitInterval (f:=fun a b => f (sourceCollarPiece i j ![t,a,b])) + (hf.comp (sourceAngularFace_continuous t i j)))).intervalIntegrable _ _ + · intro a ha + have hinner : (∫ b in (-1:ℝ)..1, + torusFaceTerm 1 sourceRadialWidth (fun x => f (sourceAngularCollar t x)) i j a b)≤ + c₁*(∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b])) := by + rw [←intervalIntegral.integral_const_mul] + apply intervalIntegral.integral_mono_on (by norm_num) + · exact ((continuous_torusFaceTerm 1 sourceRadialWidth + (hf.comp (continuous_sourceAngularCollar t)) i j).comp + (continuous_const.prodMk continuous_id)).intervalIntegrable _ _ + · exact (continuous_const.mul ((hf.comp (sourceAngularFace_continuous t i j)).comp + (continuous_const.prodMk continuous_id))).intervalIntegrable _ _ + · intro b hb + dsimp only [torusFaceTerm] + rw [sourceAngular_face t a b i j (abs_le.mpr ha) (abs_le.mpr hb)] + exact (mul_le_mul_of_nonneg_left (faceRayDensity_bounds hw hw' j b).2 (hn _)).trans_eq + (mul_comm _ _) + have hnint : 0≤ ∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b]) := + intervalIntegral.integral_nonneg (by norm_num) (fun _ _ => hn _) + have hden := faceRayDensity_bounds (w:=1) (by norm_num) (by norm_num) i a + have hden' : faceRayDensity 1 i a≤c₀ := by simpa [c₀] using hden.2 + calc + _≤(c₁*(∫ b in (-1:ℝ)..1,f (sourceCollarPiece i j ![t,a,b])))*c₀ := + mul_le_mul hinner hden' hden.1 (mul_nonneg hc₁ hnint) + _=_ := by ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusIntegralAlgebra.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusIntegralAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..5717568b410e27603ef11f0ba9558ccc76116a91 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusIntegralAlgebra.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusBoxFlux + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +lemma torusCellIntegral_eq_box {T t : ℝ} (hT : 0≤T) {f : Coord3→ℝ} + (hf : Continuous (fun x : Fin 2→ℝ => f ![t,x 0,x 1])) : + torusCellIntegral T f t=∫ x in Icc (0:Fin 2→ℝ) (fun _ => T),f ![t,x 0,x 1] := by + symm + simpa only [torusCellIntegral,Pi.zero_apply,Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.head_cons] using + integral_coord2_Icc (a:=(0:Fin 2→ℝ)) (b:=fun _ => T) (fun _ => hT) hf + +lemma torusCellIntegral_add {T t : ℝ} (hT : 0≤T) {f g : Coord3→ℝ} + (hf : Continuous (fun x : Fin 2→ℝ => f ![t,x 0,x 1])) + (hg : Continuous (fun x : Fin 2→ℝ => g ![t,x 0,x 1])) : + torusCellIntegral T (fun x => f x+g x) t=torusCellIntegral T f t+torusCellIntegral T g t := by + rw [torusCellIntegral_eq_box hT (hf.add hg),torusCellIntegral_eq_box hT hf, + torusCellIntegral_eq_box hT hg] + exact integral_add (hf.continuousOn.integrableOn_compact isCompact_Icc) + (hg.continuousOn.integrableOn_compact isCompact_Icc) + +lemma torusCellIntegral_const (T t c : ℝ) : torusCellIntegral T (fun _ => c) t=T^2*c := by + simp only [torusCellIntegral,intervalIntegral.integral_const,sub_zero,smul_eq_mul] + ring + +lemma torusCellIntegral_smul (T t c : ℝ) (f : Coord3→ℝ) : + torusCellIntegral T (fun x => c*f x) t=c*torusCellIntegral T f t := by + simp only [torusCellIntegral,intervalIntegral.integral_const_mul] + +lemma halfspace_slice_smooth {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {δ t : ℝ} {f : Coord3→E} (hf : ContDiffOn ℝ (↑(⊤:ℕ∞)) f {x | δ f ![t,y 0,y 1]) := by + apply contDiff_iff_contDiffAt.mpr + intro y + have hc : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Fin 2→ℝ => ![t,y 0,y 1]) := by + apply contDiff_pi.mpr + intro i + fin_cases i <;> dsimp <;> fun_prop + exact (hf.contDiffAt ((axial_halfspace_open δ).mem_nhds ht)).comp y hc.contDiffAt + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecay.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecay.lean new file mode 100644 index 0000000000000000000000000000000000000000..fcab3f5170c9c2ecf5b3a95e2924dd9983980227 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecay.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusFourierSmooth + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology + +lemma spectral_shift_exp_bound {lam gap rate T R t : ℝ} + (hlam : 0≤lam) (hgap : 0≤gap) (hrate : lam+gap≤rate) + (hT : R+1≤T) (ht : -R≤t) : + exp (lam*T)*exp (-rate*(T+t)) ≤ + exp (lam*(R+1))*exp (-gap*(T-R-1))*exp (-rate) := by + rw [←exp_add,←exp_add,←exp_add] + apply exp_le_exp.mpr + have hr : 0≤rate := le_trans (add_nonneg hlam hgap) hrate + have h1 := mul_nonneg (sub_nonneg.mpr hrate) (show 0≤T-R-1 by linarith) + have h2 := mul_nonneg hr (show 0≤t+R by linarith) + nlinarith + +lemma flatFourier_shift_uniform_bound {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ, (1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B lam gap R T : ℝ} + (ha : ∀ h, |a h|≤B) (hlam : 0≤lam) (hgap : 0≤gap) + (hsep : ∀ h, a h≠0 → lam+gap≤torusRate s h) (hT : R+1≤T) + (n : ℕ) {x : Fin 3 → ℝ} (hx : -R≤x 0) : + exp (lam*T)*‖iteratedFDeriv ℝ n (flatFourier s a phase) (x+![T,0,0])‖ ≤ + (exp (lam*(R+1))*exp (-gap*(T-R-1)))* + ∑' h, B*((torusRate s h+torusSize h)^n*exp (-torusRate s h)) := by + have hy : 0<(x+![T,0,0]) 0 := by + simp only [Pi.add_apply,Matrix.cons_val_zero]; linarith + rw [flatFourier_iterated hs ha n hy] + let C := exp (lam*(R+1))*exp (-gap*(T-R-1)) + have hC : 0≤C := by dsimp [C]; positivity + have hB : 0≤B := (abs_nonneg (a 0)).trans (ha 0) + have hb : Summable (fun h => B*((torusRate s h+torusSize h)^n*exp (-torusRate s h))) := by + simpa using (flatMode_derivative_summable hs n (show (0:ℝ)<1 by norm_num)).mul_left B + have hi (h : Fin 2 → ℤ) : + exp (lam*T)*‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) (x+![T,0,0])‖ ≤ + C*(B*((torusRate s h+torusSize h)^n*exp (-torusRate s h))) := by + by_cases hz : a h=0 + · simp only [hz,zero_mul,iteratedFDeriv_fun_zero,Pi.zero_apply,norm_zero,mul_zero] + exact mul_nonneg hC (mul_nonneg hB (mul_nonneg (pow_nonneg (add_nonneg (sqrt_nonneg _) (torusSize_nonneg h)) n) (exp_nonneg _))) + have hp : 0≤(torusRate s h+torusSize h)^n := by + have := torusSize_nonneg h + dsimp [torusRate]; positivity + have h1 := mul_le_mul_of_nonneg_right (ha h) hp + have h2 := spectral_shift_exp_bound hlam hgap (hsep h hz) hT hx + have h3 := mul_le_mul h1 h2 (by positivity) (mul_nonneg hB hp) + have hd := weighted_phase_iterated_bound (s:=s) (h:=h) (phase h) (a h) n (x+![T,0,0]) + apply (mul_le_mul_of_nonneg_left hd (exp_nonneg _)).trans + simpa only [Pi.add_apply,Matrix.cons_val_zero,C,add_comm,mul_assoc,mul_left_comm,mul_comm] using h3 + have hn : Summable (fun h => ‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) (x+![T,0,0])‖) := by + have hδ : 0<(x+![T,0,0]) 0/2 := by positivity + exact Summable.of_nonneg_of_le (fun h => norm_nonneg _) + (fun h => weighted_phase_halfspace_bound ha n h (by linarith : (x+![T,0,0]) 0/2≤(x+![T,0,0]) 0)) + ((flatMode_derivative_summable hs n hδ).mul_left B) + calc + _ ≤ exp (lam*T)*(∑' h, ‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) (x+![T,0,0])‖) := + mul_le_mul_of_nonneg_left (norm_tsum_le_tsum_norm hn) (exp_nonneg _) + _ = ∑' h, exp (lam*T)*‖iteratedFDeriv ℝ n (fun y => a h*flatPhaseMode s h (phase h) y) (x+![T,0,0])‖ := tsum_mul_left.symm + _ ≤ ∑' h, C*(B*((torusRate s h+torusSize h)^n*exp (-torusRate s h))) := + (hn.mul_left _).tsum_le_tsum hi (hb.mul_left C) + _ = _ := tsum_mul_left + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecomposition.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c60bf05fdb6b421ae3fadf66351f6ceea720771 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusLeadingDecomposition.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.GeneralModeEndingScalarization +import OAI.Analysis.Conductivity.Fourier.TorusLeadingRealMode + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory UnitAddTorus Real + +lemma flatFourier_remove_mode {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {a phase : (Fin 2 → ℤ) → ℝ} {B : ℝ} (ha : ∀ h,|a h|≤B) + (h₀ : Fin 2 → ℤ) {x : Fin 3 → ℝ} (hx : 0 if h=h₀ then 0 else a h) phase x := by + classical + rw [flatFourier,(flatFourier_summable hs ha hx).tsum_eq_add_tsum_ite h₀] + congr 1 + unfold flatFourier + apply tsum_congr + intro h + split_ifs <;> simp_all + +lemma torusRealContinuation_constant_of_no_modes {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : TorusL2) (hf : ∀ h : Fin 2 → ℤ,h≠0 → realTorusCoeff f h=0) + {x : Fin 3 → ℝ} (hx : 0 if h=h₀ then 0 else realTorusAmplitude f h + let a'' : (Fin 2 → ℤ) → ℝ := fun h => if h= -h₀ then 0 else a' h + let b : (Fin 2 → ℤ) → ℝ := fun h => a'' h/L + have ha' (h) : |a' h|≤‖f‖ := by + dsimp [a']; split_ifs + · simp + · exact realTorusAmplitude_bound f h + have ha'' (h) : |a'' h|≤‖f‖ := by + dsimp [a'']; split_ifs + · simp + · exact ha' h + refine ⟨h₀,L,‖f‖/L,g,b,hh₀.1,hL,div_nonneg (norm_nonneg _) hL.le,hg,?_,?_,?_⟩ + · intro h + dsimp [b] + rw [abs_div,abs_of_pos hL] + exact (div_le_div_iff_of_pos_right hL).mpr (ha'' h) + · intro h hh + have hz : h≠0 := by + intro he + apply hh + simp [b,a'',a',realTorusAmplitude,he] + have hd : realTorusCoeff f h≠0 := by + intro he + apply hh + simp [b,a'',a',realTorusAmplitude,he] + have he : h≠h₀ := by + intro he + apply hh + simp [b,a'',a',he] + have hn' : h≠-h₀ := by + intro he + apply hh + simp [b,a'',he] + exact hgap h ⟨hz,hd⟩ he hn' + · intro x hx + rw [torusRealContinuation_mean_free hs f hx, + flatFourier_remove_mode hs (realTorusAmplitude_bound f) h₀ hx] + change (mFourierCoeff f 0).re+(_+flatFourier s a' (realTorusPhase f) x)=_ + rw [flatFourier_remove_mode hs ha' (-h₀) hx] + have he : realTorusAmplitude f h₀*flatPhaseMode s h₀ (realTorusPhase f h₀) x= + ‖realTorusCoeff f h₀‖*flatPhaseMode s h₀ (realTorusPhase f h₀) x := by + simp [realTorusAmplitude,hh₀.1] + have hen : a' (-h₀)*flatPhaseMode s (-h₀) (realTorusPhase f (-h₀)) x= + ‖realTorusCoeff f h₀‖*flatPhaseMode s h₀ (realTorusPhase f h₀) x := by + simpa [a',hn,realTorusAmplitude,hneg,realTorusPhase] using realTorusCoeff_polar_neg s f h₀ x + rw [he,hen] + change _=(mFourierCoeff f 0).re+L*(_+flatFourier s (fun h => a'' h/L) _ x) + rw [flatFourier_div_coefficients] + rw [mul_add,mul_div_cancel₀ _ hL.ne'] + dsimp [L,a''] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusLipschitzTrace.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusLipschitzTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..938e1baf120a94929f0e935a475d4640ac565bb7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusLipschitzTrace.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.TorusFourierTranslation +import OAI.Analysis.Conductivity.Geometry.TorusExponential +import OAI.Analysis.Conductivity.Sources.WeightedSpectralSpace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal +local instance : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma torus_lipschitz_H1_summable (f : C(UnitAddTorus (Fin 2),ℂ)) + (K : ℝ≥0) (hf : LipschitzWith K f) : + Summable (fun h : Fin 2 → ℤ => + (1+(h 0:ℝ)^2+(h 1:ℝ)^2)*‖mFourierCoeff f h‖^2) := by + have h0 : Summable (fun h : Fin 2 → ℤ => ‖mFourierCoeff f h‖^2) := by + simpa only [mFourierCoeff_toLp] using + (hasSum_sq_mFourierCoeff (ContinuousMap.toLp 2 volume ℂ f)).summable + have hj (j : Fin 2) : Summable (fun h : Fin 2 → ℤ => (h j:ℝ)^2*‖mFourierCoeff f h‖^2) := by + have hh := (torus_coordinate_fourier_summable f j K K.coe_nonneg + (torus_lipschitz_coordinate_bound f K hf j)).mul_left ((2*Real.pi)^2)⁻¹ + apply hh.congr + intro h + have hp : Real.pi≠0 := Real.pi_pos.ne' + field_simp + apply ((h0.add (hj 0)).add (hj 1)).congr + intro h + ring + +lemma torus_coordinate_H1_summable (f : C(UnitAddTorus (Fin 2),ℂ)) + (K : Fin 2 → ℝ) (hK : ∀ j,0≤K j) + (hf : ∀ j t x,‖f (x+torusCoordinateShift j t)-f x‖≤K j*|t|) : + Summable (fun h : Fin 2 → ℤ => + (1+(h 0:ℝ)^2+(h 1:ℝ)^2)*‖mFourierCoeff f h‖^2) := by + have h0 : Summable (fun h : Fin 2 → ℤ => ‖mFourierCoeff f h‖^2) := by + simpa only [mFourierCoeff_toLp] using + (hasSum_sq_mFourierCoeff (ContinuousMap.toLp 2 volume ℂ f)).summable + have hj (j : Fin 2) : Summable (fun h : Fin 2 → ℤ => (h j:ℝ)^2*‖mFourierCoeff f h‖^2) := by + have hh := (torus_coordinate_fourier_summable f j (K j) (hK j) (hf j)).mul_left ((2*Real.pi)^2)⁻¹ + apply hh.congr + intro h + have hp : Real.pi≠0 := Real.pi_pos.ne' + field_simp + apply ((h0.add (hj 0)).add (hj 1)).congr + intro h + ring + +lemma torusRate_polynomial_bound (s : Fin 3 → ℝ) (h : Fin 2 → ℤ) : + torusRate s h≤(1+|s 0|+|s 1|+|s 2|)*(1+(h 0:ℝ)^2+(h 1:ℝ)^2) := by + let C := 1+|s 0|+|s 1|+|s 2| + let B := (h 0:ℝ)^2+(h 1:ℝ)^2 + have hC : 1≤C := by dsimp [C]; linarith [abs_nonneg (s 0),abs_nonneg (s 1),abs_nonneg (s 2)] + have hB : 0≤B := by dsimp [B]; positivity + have hcross : 2*s 1*(h 0:ℝ)*(h 1:ℝ)≤|s 1| * B := by + have hab : 2*|(h 0:ℝ)| * |(h 1:ℝ)| ≤ B := by + dsimp [B] + nlinarith [sq_nonneg (|(h 0:ℝ)|-|(h 1:ℝ)|),sq_abs (h 0:ℝ),sq_abs (h 1:ℝ)] + calc + _≤|2*s 1*(h 0:ℝ)*(h 1:ℝ)| := le_abs_self _ + _=|s 1| * (2*|(h 0:ℝ)| * |(h 1:ℝ)|) := by rw [abs_mul,abs_mul,abs_mul]; norm_num; ring + _≤|s 1| * B := mul_le_mul_of_nonneg_left hab (abs_nonneg _) + have hQ : torusQuadratic s h≤C*B := by + have hx := mul_le_mul_of_nonneg_right (le_abs_self (s 0)) (sq_nonneg (h 0:ℝ)) + have hy := mul_le_mul_of_nonneg_right (le_abs_self (s 2)) (sq_nonneg (h 1:ℝ)) + have hx' : |s 0| * (h 0:ℝ)^2≤|s 0| * B := mul_le_mul_of_nonneg_left + (by dsimp [B]; nlinarith [sq_nonneg (h 1:ℝ)]) (abs_nonneg _) + have hy' : |s 2| * (h 1:ℝ)^2≤|s 2| * B := mul_le_mul_of_nonneg_left + (by dsimp [B]; nlinarith [sq_nonneg (h 0:ℝ)]) (abs_nonneg _) + dsimp [torusQuadratic,C] + nlinarith + have hroot : torusRate s h≤1+max (torusQuadratic s h) 0 := by + dsimp [torusRate] + by_cases hq : 0≤torusQuadratic s h + · rw [max_eq_left hq] + have hh := Real.sq_sqrt hq + nlinarith [sq_nonneg (Real.sqrt (torusQuadratic s h)-1)] + · rw [Real.sqrt_eq_zero_of_nonpos (le_of_not_ge hq),max_eq_right (le_of_not_ge hq)] + norm_num + have hm : max (torusQuadratic s h) 0≤C*B := max_le hQ (mul_nonneg (by linarith) hB) + change torusRate s h≤C*(1+(h 0:ℝ)^2+(h 1:ℝ)^2) + calc + _≤1+C*B := hroot.trans (add_le_add (le_refl 1) hm) + _≤C*(1+(h 0:ℝ)^2+(h 1:ℝ)^2) := by dsimp [B] at *; nlinarith + +theorem torus_lipschitz_trace_summable (s : Fin 3 → ℝ) + (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) (hf : LipschitzWith K f) : + Summable (fun h : Fin 2 → ℤ => torusRate s h*‖mFourierCoeff f h‖^2) := by + refine ((torus_lipschitz_H1_summable f K hf).mul_left (1+|s 0|+|s 1|+|s 2|)).of_nonneg_of_le + (fun h => mul_nonneg (Real.sqrt_nonneg _) (sq_nonneg _)) (fun h => ?_) + simpa only [mul_assoc] using mul_le_mul_of_nonneg_right (torusRate_polynomial_bound s h) (sq_nonneg _) + +theorem torus_coordinate_trace_summable (s : Fin 3 → ℝ) + (f : C(UnitAddTorus (Fin 2),ℂ)) (K : Fin 2 → ℝ) (hK : ∀ j,0≤K j) + (hf : ∀ j t x,‖f (x+torusCoordinateShift j t)-f x‖≤K j*|t|) : + Summable (fun h : Fin 2 → ℤ => torusRate s h*‖mFourierCoeff f h‖^2) := by + refine ((torus_coordinate_H1_summable f K hK hf).mul_left (1+|s 0|+|s 1|+|s 2|)).of_nonneg_of_le + (fun h => mul_nonneg (Real.sqrt_nonneg _) (sq_nonneg _)) (fun h => ?_) + simpa only [mul_assoc] using mul_le_mul_of_nonneg_right (torusRate_polynomial_bound s h) (sq_nonneg _) + +theorem torus_lipschitz_trace_exists (s : Fin 3 → ℝ) + (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) (hf : LipschitzWith K f) : + ∃ z : spectralTraceGraph (torusRate s), ∀ h,(z.val 0) h=mFourierCoeff f h := by + let F := (mFourierBasis (d:=Fin 2)).repr (ContinuousMap.toLp 2 volume ℂ f) + have he h : F h=mFourierCoeff f h := by rw [mFourierBasis_repr,mFourierCoeff_toLp] + obtain ⟨z,hz⟩ := (spectralTraceGraph_exists_iff (fun _ => Real.sqrt_nonneg _) F).mpr + (by simpa only [he,torusRate] using torus_lipschitz_trace_summable s f K hf) + exact ⟨z,fun h => by rw [hz,he]⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusLocalizedMoments.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusLocalizedMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a0aa26066b550731af3d73ee6d99af28d4dae0c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusLocalizedMoments.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.TorusMoments + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise + +lemma torus_band_integral_congr {T a b : ℝ} (hab : a≤b) {f g : Coord3 → ℝ} + (h : ∀ x,x 0∈Icc a b → f x=g x) : + (∫ t in a..b,torusCellIntegral T f t)=∫ t in a..b,torusCellIntegral T g t := by + apply intervalIntegral.integral_congr + intro t ht + have ht' : t∈Icc a b := by simpa only [uIcc_of_le hab] using ht + apply intervalIntegral.integral_congr + intro y _ + apply intervalIntegral.integral_congr + intro z _ + exact h ![t,y,z] ht' + +theorem periodic_localized_source_moment_formula {T a b : ℝ} (hT : 0≤T) (hab : a≤b) + {H : Coord3 → Mat3} {u : Coord3 → Fin 2 → ℝ} {r : Fin 2 → Coord3 → ℝ} + (hH : ContDiff ℝ (↑(⊤:ℕ∞)) H) (hu : ContDiff ℝ (↑(⊤:ℕ∞)) u) + (hHp : AngularPeriodic T H) (hup : AngularPeriodic T u) (hHs : ∀ x,(H x).IsSymm) + (hrs : ∀ j,tsupport (r j)⊆{x | x 0∈Icc a b}) + (hre : ∀ j x,x 0∈Icc a b → r j x=symmetricSource H u j x) : + periodicSourceMoment T u r= + ![torusCellIntegral T (fun x => (H x*gradientColumns (fderiv ℝ u x)).col 0 0) b- + torusCellIntegral T (fun x => (H x*gradientColumns (fderiv ℝ u x)).col 0 0) a, + torusCellIntegral T (fun x => (H x*gradientColumns (fderiv ℝ u x)).col 1 0) b- + torusCellIntegral T (fun x => (H x*gradientColumns (fderiv ℝ u x)).col 1 0) a, + torusCellIntegral T (fun x => symmetricCrossFlux H u x 0) b- + torusCellIntegral T (fun x => symmetricCrossFlux H u x 0) a] := by + have hmain (j : Fin 2) := (torus_full_integral_eq_band hab (hrs j)).trans + ((torus_band_integral_congr (T:=T) hab (hre j)).trans + (torus_band_divergence hT hab (symmetricFlux_smooth hH hu j) (symmetricFlux_periodic hHp hup j))) + have hts : tsupport (fun x => u x 1*r 0 x-u x 0*r 1 x)⊆{x | x 0∈Icc a b} := + (tsupport_sub _ _).trans (union_subset + (tsupport_mul_subset_right.trans (hrs 0)) (tsupport_mul_subset_right.trans (hrs 1))) + have hc := torus_full_integral_eq_band (T:=T) hab hts + have he := torus_band_integral_congr (T:=T) hab (f:=fun x => u x 1*r 0 x-u x 0*r 1 x) + (g:=coordinateDivergence (symmetricCrossFlux H u)) (fun x hx => by + rw [symmetricCrossFlux_divergence hH hu hHs,hre 0 x hx,hre 1 x hx]) + have hd := torus_band_divergence hT hab (symmetricCrossFlux_smooth hH hu) + (symmetricCrossFlux_periodic hHp hup) + ext i + fin_cases i + · exact hmain 0 + · exact hmain 1 + · exact hc.trans (he.trans hd) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/TorusTraceFiniteEnd.lean b/lean/OAI/Analysis/Conductivity/Geometry/TorusTraceFiniteEnd.lean new file mode 100644 index 0000000000000000000000000000000000000000..6068defff20d166e44357fc82bf72ce03056334a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/TorusTraceFiniteEnd.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.UndoAngularProperties +import OAI.Analysis.Conductivity.Geometry.TorusLeadingDecomposition +import OAI.Analysis.Conductivity.Variational.RankProjectionFirst + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +open scoped Matrix.Norms.Elementwise + +theorem torus_trace_finite_ending {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (hres : ∀ h l : Fin 2 → ℤ,torusQuadratic s h=torusQuadratic s l → l=h ∨ l= -h) + (f g : TorusL2) : + ∃ d e R : ℝ,0 simp [Q,c] <;> ring + · simpa only [z,WeakFiniteTensorPair.output_E] using hEi + · intro x hx + simp only [z,WeakFiniteTensorPair.output_v,hvt x hx] + ext i + fin_cases i <;> simp [Q,c] + · simpa only [z,WeakFiniteTensorPair.output_E] using hEt + · have hgc (h : Fin 2 → ℤ) (hh : h≠0) : realTorusCoeff g h=0 := by + by_contra hn + exact hg ⟨h,hh,hn⟩ + have hh₀ : (![1,0] : Fin 2 → ℤ)≠0 := by + intro hn + have := congrFun hn 0 + norm_num at this + obtain ⟨d,e,R,hd,he,hdR,w,hvp,hEp,hvi,hEi,hvt,hEt⟩ := + original_mode_finite_ending (pa:=realTorusPhase f) (pb:=fun _ => 0) + (a:=realTorusAmplitude f) (b:=fun _ => 0) (B:=0) (gb:=1) + hs hh₀ (norm_nonneg f) le_rfl (realTorusAmplitude_bound f) (by simp) + hga (by norm_num) haf (by simp) + let c : Fin 2 → ℝ := ![(mFourierCoeff f 0).re,(mFourierCoeff g 0).re] + let z := w.projectFirst.output (ContinuousLinearEquiv.refl ℝ (Fin 2 → ℝ)) c + have hzv (x : Coord3) : z.v x=![w.v x 0,0]+c := by + rw [show z.v x= _ from WeakFiniteTensorPair.output_v _ _ _ x] + rfl + have hzE : z.E=w.E := by + rw [show z.E= _ from WeakFiniteTensorPair.output_E _ _ _] + rfl + refine ⟨d,e,R,hd,he,hdR,z,?_,?_,?_,?_,?_,?_⟩ + · intro n x + rw [hzv,hzv,hvp n x] + · simpa only [hzE] using hEp + · intro x hx + rw [hzv,hvi x hx,torusRealContinuation_mean_free hs f (hd.trans_le hx.1), + torusRealContinuation_constant_of_no_modes hs g hgc (hd.trans_le hx.1)] + ext i + fin_cases i <;> simp [c] + ring + · simpa only [hzE] using hEi + · intro x hx + rw [hzv,hvt x hx] + ext i + fin_cases i <;> simp [c] + · simpa only [hzE] using hEt + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/UniformPhysicalBoxCorrection.lean b/lean/OAI/Analysis/Conductivity/Geometry/UniformPhysicalBoxCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..15c0a8451c7861f29d7a01a43f6d88e1cb00e821 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/UniformPhysicalBoxCorrection.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.LocalPhysicalCorrectionBound +import OAI.Analysis.Conductivity.Variational.MetricControlledPiola + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory +open scoped Matrix.Norms.Elementwise + +theorem uniform_physical_box_symmetric_correction_C0 + {I : Type*} (Xs : I → OpenPartialHomeomorph Coord3 Coord3) + (hXs : ∀ i,ContDiffOn ℝ (↑(⊤:ℕ∞)) (Xs i) (Xs i).source) + (hXis : ∀ i,ContDiffOn ℝ (↑(⊤:ℕ∞)) (Xs i).symm (Xs i).target) + {a b c d : Coord3} (hab : ∀ i,a i ![r₁ (boxCoordinates x),r₂ (boxCoordinates x)] j) y)) ∧ + (∀ y,‖H y‖≤L*M) := by + obtain ⟨L,hL,solve⟩ := compact_coordinate_box_correction_C0 hab hca hbd + refine ⟨P*L,mul_pos hP hL,?_⟩ + intro i r₁ r₂ hr₁ hr₂ hs₁ hs₂ hv₁ hv₂ hz₁ hz₂ ht M hM hb₁ hb₂ + let X := Xs i + have hX := hXs i + have hXi := hXis i + have hbox := hboxes i + have hPi := fun (B : Coord3 → Mat3) (hB : Function.support B⊆closedCorrectionBox c d) (y : Coord3) => + localPiolaTensor_bound_of_coefficient X hP.le (hmetric i) B hB y + + obtain ⟨B,hB,hcB,htB,hsy,hw₁,hw₂,hbB⟩ := + solve r₁ r₂ hr₁ hr₂ hs₁ hs₂ hv₁ hv₂ hz₁ hz₂ ht M hM hb₁ hb₂ + have hBs : tsupport B⊆X.source := htB.trans hbox + have hinner : (Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2)⊆ + (Icc (c 0) (d 0) ×ˢ Icc (c 1) (d 1)) ×ˢ Icc (c 2) (d 2) := by + intro p hp + exact ⟨⟨⟨((hca 0).trans hp.1.1.1).le,(hp.1.1.2.trans (hbd 0)).le⟩, + ⟨((hca 1).trans hp.1.2.1).le,(hp.1.2.2.trans (hbd 1)).le⟩⟩, + ⟨((hca 2).trans hp.2.1).le,(hp.2.2.trans (hbd 2)).le⟩⟩ + let r : Fin 2 → Coord3 → ℝ := fun j x => ![r₁ (boxCoordinates x),r₂ (boxCoordinates x)] j + have hcr : ∀ j,HasCompactSupport (r j) := by + intro j + fin_cases j + · exact hs₁.comp_homeomorph boxCoordinates.toHomeomorph + · exact hs₂.comp_homeomorph boxCoordinates.toHomeomorph + have hsr : ∀ j,tsupport (r j)⊆X.source := by + intro j + fin_cases j + · exact ((tsupport_comp_subset_preimage r₁ boxCoordinates.continuous).trans + (preimage_mono (hv₁.trans hinner))).trans hbox + · exact ((tsupport_comp_subset_preimage r₂ boxCoordinates.continuous).trans + (preimage_mono (hv₂.trans hinner))).trans hbox + have hweak : ∀ j (φ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) φ → + (∫ x,fderiv ℝ φ x ((B x*gradientColumns (fderiv ℝ coordinatePair x)).col j))= + -(∫ x,φ x*r j x) := by + intro j φ hφ + simp_rw [coordinatePair_columns] + fin_cases j + · exact hw₁ φ hφ + · exact hw₂ φ hφ + refine ⟨localPiolaTensor X B,localPiolaTensor_smooth X hX hXi B hB hcB hBs, + (localPiolaTensor_compact X B hcB hBs).1,(localPiolaTensor_compact X B hcB hBs).2, + localPiolaTensor_isSymm X B hsy,?_,?_⟩ + · intro j ψ hψ + change (∫ y,fderiv ℝ ψ y ((localPiolaTensor X B y*gradientColumns (fderiv ℝ (coordinatePair∘X.symm) y)).col j))=_ + simp_rw [localPiolaTensor_columns X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) B coordinatePair + (coordinatePair_smooth.differentiable (by simp)).differentiableOn] + have htj := tensorColumn_tsupport B (fun x => gradientColumns (fderiv ℝ coordinatePair x)) j + exact localPiolaFlux_weak_source volume X hX hXi _ _ + (hcB.of_isClosed_subset isClosed_closure htj) (hcr j) (htj.trans hBs) (hsr j) (hweak j) ψ hψ + · intro y + exact (hPi B ((subset_tsupport B).trans htB) y).trans + ((mul_le_mul_of_nonneg_left (hbB _) hP.le).trans_eq (by ring)) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Geometry/UnitBoxAverage.lean b/lean/OAI/Analysis/Conductivity/Geometry/UnitBoxAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..c965c0d37d648d46319332e1a6d9395b7a14286a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Geometry/UnitBoxAverage.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactParametricIntegral +import OAI.Analysis.Conductivity.Variational.IntervalMeanPoincare + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +variable {E G : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + [NormedAddCommGroup G] [NormedSpace ℝ G] [CompleteSpace G] + +def unitAverage (f : ℝ → G) : G := ∫ t in Icc (0:ℝ) 1, f t + +omit [CompleteSpace G] in +lemma unitAverage_eq_interval (f : ℝ → G) : + unitAverage f = ∫ t in (0:ℝ)..1, f t := by + rw [intervalIntegral.integral_of_le (by norm_num)] + exact integral_Icc_eq_integral_Ioc + +lemma unitAverage_const (c : G) : unitAverage (fun _ => c)=c := by + rw [unitAverage_eq_interval,intervalIntegral.integral_const] + simp + +omit [CompleteSpace G] in +lemma unitAverage_add {f g : ℝ → G} (hf : Continuous f) (hg : Continuous g) : + unitAverage (fun t => f t+g t)=unitAverage f+unitAverage g := + integral_add hf.integrableOn_Icc hg.integrableOn_Icc + +omit [CompleteSpace G] in +lemma unitAverage_sub {f g : ℝ → G} (hf : Continuous f) (hg : Continuous g) : + unitAverage (fun t => f t-g t)=unitAverage f-unitAverage g := + integral_sub hf.integrableOn_Icc hg.integrableOn_Icc + +omit [CompleteSpace G] in +lemma unitAverage_smul (c : ℝ) (f : ℝ → G) : + unitAverage (fun t => c • f t)=c • unitAverage f := integral_smul c f + +lemma unitAverage_mul (c : ℝ) (f : ℝ → ℝ) : + unitAverage (fun t => c*f t)=c*unitAverage f := integral_const_mul c f + +lemma unitAverage_mono {f g : ℝ → ℝ} (hf : Continuous f) (hg : Continuous g) + (h : ∀ t∈Icc (0:ℝ) 1, f t ≤ g t) : unitAverage f ≤ unitAverage g := by + apply integral_mono_ae hf.integrableOn_Icc hg.integrableOn_Icc + filter_upwards [ae_restrict_mem measurableSet_Icc] with t ht + exact h t ht + +lemma unitAverage_nonneg {f : ℝ → ℝ} (hf : ∀ t∈Icc (0:ℝ) 1, 0 ≤ f t) : + 0 ≤ unitAverage f := by + apply integral_nonneg_of_ae + filter_upwards [ae_restrict_mem measurableSet_Icc] with t ht + exact hf t ht + +lemma unitAverage_sq_le {f : ℝ → ℝ} (hf : Continuous f) : + (unitAverage f)^2 ≤ unitAverage (fun t => (f t)^2) := by + simpa only [unitAverage_eq_interval,sub_zero,one_mul] using + interval_integral_sq_le (by norm_num : (0:ℝ) ≤ 1) hf + +omit [NormedSpace ℝ E] [CompleteSpace G] in +lemma continuous_unitAverage {f : E×ℝ → G} (hf : Continuous f) : + Continuous (fun x => unitAverage (fun t => f (x,t))) := + by + exact continuous_parametric_integral_of_continuous (f := fun x t => f (x,t)) hf isCompact_Icc + +lemma contDiff_unitAverage {f : E×ℝ → G} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => unitAverage (fun t => f (x,t))) := + contDiff_compact_integral hf isCompact_Icc + +omit [CompleteSpace G] in +lemma fderiv_unitAverage {f : E×ℝ → G} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (x v : E) : + fderiv ℝ (fun y => unitAverage (fun t => f (y,t))) x v = + unitAverage (fun t => fderiv ℝ f (x,t) (v,0)) := by + let D : E×ℝ → E →L[ℝ] G := fun z => + (fderiv ℝ f z).comp (ContinuousLinearMap.inl ℝ E ℝ) + have hD : Continuous D := (hf.fderiv_right (m := 0) (by simp)).continuous.clm_comp continuous_const + have hd (y : E) (t : ℝ) : HasFDerivAt (fun w => f (w,t)) (D (y,t)) y := by + exact ((hf.differentiable (by simp) (y,t)).hasFDerivAt).comp y + ((hasFDerivAt_id y).prodMk (hasFDerivAt_const t y)) + have hi := hasFDerivAt_compact_integral (μ := volume) hf.continuous hD hd + (isCompact_Icc : IsCompact (Icc (0:ℝ) 1)) x + change (fderiv ℝ (fun y => ∫ t in Icc (0:ℝ) 1, f (y,t)) x) v = _ + rw [hi.fderiv] + exact ContinuousLinearMap.integral_apply (hD.comp (continuous_const.prodMk continuous_id) |>.integrableOn_Icc) v + +lemma unitAverage_mean_poincare {f : ℝ → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + unitAverage (fun t => (f t-unitAverage f)^2) ≤ + unitAverage (fun t => (deriv f t)^2) := by + simpa only [unitAverage_eq_interval,sub_zero,one_pow,one_mul,div_one] using + smooth_interval_mean_poincare hf (by norm_num : (0:ℝ)<1) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Main.lean b/lean/OAI/Analysis/Conductivity/Main.lean new file mode 100644 index 0000000000000000000000000000000000000000..4946318f6ceb4f3dbf4ae2cbd673123e5f6f8d68 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Main.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.WeightedGaugeDN +import OAI.Analysis.Conductivity.Sobolev.CriticalWallParticularC0 +import OAI.Analysis.Conductivity.Fourier.PoissonGreen +import OAI.Analysis.Conductivity.Walls.SeamCubicRate +import OAI.Analysis.Conductivity.Walls.PhysicalCollarCutoff +import OAI.Analysis.Conductivity.Geometry.CylinderPhysicalEquiv +import OAI.Analysis.Conductivity.Branching.ChildFullEndEnergy +import OAI.Analysis.Conductivity.Variational.BoundedPiolaCorrection +import OAI.Analysis.Conductivity.Geometry.RegularPatchLinear +import OAI.Analysis.Conductivity.Variational.PhysicalCentralRegularPair +import OAI.Analysis.Conductivity.Fourier.GeneralModeRecombinedEnding +import OAI.Analysis.Conductivity.Geometry.RegularPatchCoordinates +import OAI.Analysis.Conductivity.Variational.CentralCorrectedRepresentative +import OAI.Analysis.Conductivity.Branching.PhysicalBlockRepresentative +import OAI.Analysis.Conductivity.Sources.PhysicalPatching +import OAI.Analysis.Conductivity.Sources.IteratedAverages + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma WeightedAnnihilation.smul {a : R3 → ℝ} {w u : H1} {c : ℝ} + (hw : WeightedAnnihilation a w u c) (δ : ℝ) : + WeightedAnnihilation a (δ • w) u c := by + intro f hf hc hs + calc + (∫ x,a x*inner ℝ (weakGradient (δ • w) x) + ((weakValue u x-c) • gradient f x+f x • weakGradient u x) ∂ballMeasure)= + ∫ x,δ*(a x*inner ℝ (weakGradient w x) + ((weakValue u x-c) • gradient f x+f x • weakGradient u x)) ∂ballMeasure := by + apply integral_congr_ae + filter_upwards [weakGradient_smul δ w] with x hx + rw [hx,Pi.smul_apply,real_inner_smul_left] + ring + _=0 := by rw [integral_const_mul,hw f hf hc hs,mul_zero] + +theorem actual_nested_weighted_source_exists : + ∃ (a : R3 → ℝ) (c C : ℝ) (w : H1), + Measurable a ∧ 0 ⟨(copiedScalarCoefficient_bounds r.bounds x).1, + (copiedScalarCoefficient_bounds r.bounds x).2.trans (by linarith)⟩) + · have hh := weakValue_bound_smul hMb δ + simpa only [abs_of_pos hδ,hδM] using hh + · intro u hu hb + exact ⟨sourceMeanCLM 0 u,(r.nested_source_weighted ht hu hb).smul δ⟩ + +theorem main_nonuniqueness : MainStatement := by + obtain ⟨a,c,C,w,ha,hc,hcC,hab,hnear,hw0,hw,hwne,hsupp,hweighted⟩ := + actual_nested_weighted_source_exists + exact MainStatement_of_weighted_source a ha c C hc hcC hab hnear w hw0 hw hwne + (5/2) (by norm_num) (by norm_num) hsupp hweighted + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Model.lean b/lean/OAI/Analysis/Conductivity/Model.lean new file mode 100644 index 0000000000000000000000000000000000000000..195c6c554c8ada86f070bc609f6e5d4e5178f5ec --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Model.lean @@ -0,0 +1,81 @@ +import Mathlib + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal + +namespace ScalarConductivity + +abbrev R3 := EuclideanSpace ℝ (Fin 3) +abbrev JetFiber := EuclideanSpace ℝ (Fin 4) +def ball : Set R3 := Metric.ball 0 3 +def ballMeasure : Measure R3 := volume.restrict ball +abbrev JetSpace := Lp JetFiber 2 ballMeasure + +def smoothJet (f : R3 → ℝ) (x : R3) : JetFiber := + WithLp.toLp 2 (Fin.cases (f x) (fun i => gradient f x i)) + +def smoothJets : Set JetSpace := + { z | ∃ (f : R3 → ℝ) (_ : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hf : MemLp (smoothJet f) 2 ballMeasure), z = hf.toLp (smoothJet f) } + +def compactSmoothJets : Set JetSpace := + { z | ∃ (f : R3 → ℝ) (_ : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (_ : HasCompactSupport f) (_ : tsupport f ⊆ ball) + (hf : MemLp (smoothJet f) 2 ballMeasure), z = hf.toLp (smoothJet f) } + +def H1Space : Submodule ℝ JetSpace := + (Submodule.span ℝ smoothJets).topologicalClosure +abbrev H1 := H1Space + +def zeroTraceAmbient : Submodule ℝ JetSpace := + (Submodule.span ℝ compactSmoothJets).topologicalClosure + +def H10 : Submodule ℝ H1 := zeroTraceAmbient.comap H1Space.subtype + +instance H10_isClosed : IsClosed (H10 : Set H1) := by + exact (Submodule.isClosed_topologicalClosure + (Submodule.span ℝ compactSmoothJets)).preimage continuous_subtype_val + +abbrev TraceSpace := H1 ⧸ H10 +abbrev TraceDual := TraceSpace →L[ℝ] ℝ +abbrev DNOperator := TraceSpace →L[ℝ] TraceDual + +def trace (u : H1) : TraceSpace := H10.mkQ u + +def weakGradient (u : H1) (x : R3) : R3 := + WithLp.toLp 2 (fun i => (u.val x) i.succ) + +def energy (γ : R3 → ℝ) (u v : H1) : ℝ := + ∫ x, γ x * inner ℝ (weakGradient u x) (weakGradient v x) ∂ballMeasure + +def Harmonic (γ : R3 → ℝ) (u : H1) : Prop := + ∀ h : H1, h ∈ H10 → energy γ u h = 0 + +def IsDirichletToNeumann (γ : R3 → ℝ) (Λ : DNOperator) : Prop := + ∀ f : TraceSpace, ∃ u : H1, + trace u = f ∧ Harmonic γ u ∧ + (∀ u' : H1, trace u' = f → Harmonic γ u' → u' = u) ∧ + ∀ v : H1, Λ f (trace v) = energy γ u v + +def EqualOneNearBoundary (γ : R3 → ℝ) : Prop := + ∃ r : ℝ, 0 < r ∧ r < 3 ∧ ∀ᵐ x ∂ballMeasure, r < ‖x‖ → γ x = 1 + +def MainStatement : Prop := + ∃ (γ₀ γ₁ : R3 → ℝ) (c C : ℝ) (Λ : DNOperator), + 0 < c ∧ c < C ∧ + Measurable γ₀ ∧ Measurable γ₁ ∧ + MemLp γ₀ ∞ ballMeasure ∧ MemLp γ₁ ∞ ballMeasure ∧ + (∀ᵐ x ∂ballMeasure, c ≤ γ₀ x ∧ γ₀ x ≤ C) ∧ + (∀ᵐ x ∂ballMeasure, c ≤ γ₁ x ∧ γ₁ x ≤ C) ∧ + EqualOneNearBoundary γ₀ ∧ EqualOneNearBoundary γ₁ ∧ + 0 < ballMeasure {x | γ₀ x ≠ γ₁ x} ∧ + IsDirichletToNeumann γ₀ Λ ∧ IsDirichletToNeumann γ₁ Λ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/ApproxScalar.lean b/lean/OAI/Analysis/Conductivity/Scalarization/ApproxScalar.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c5d510fd6ee3e6474e6db2c2241668ebe8e1dcb --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/ApproxScalar.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.ScalarRelationLpStrongClosed +import OAI.Analysis.Conductivity.Variational.DenseWeakStrongContinuityPoints + +namespace OAI + +section +noncomputable section +open MeasureTheory +open scoped ENNReal +noncomputable section +open Matrix Filter Topology +namespace ScalarConductivity +open Filter Topology Set TopologicalSpace + +lemma tendstoInMeasure_of_small_exceptional_sets + {X V : Type*} [MeasurableSpace X] [SeminormedAddCommGroup V] + (μ : Measure X) (f : ℕ → X → V) (ε : ℕ → ℝ) + (hε : Tendsto ε atTop (𝓝 0)) + (hbound : ∀ n, μ {x | ε n ≤ ‖f n x‖} ≤ ENNReal.ofReal (ε n)) : + TendstoInMeasure μ f atTop (fun _ => 0) := by + rw [tendstoInMeasure_iff_norm] + intro δ hδ + simp only [sub_zero] + apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds + (by simpa only [ENNReal.ofReal_zero] using ENNReal.tendsto_ofReal hε) + · exact Filter.Eventually.of_forall (fun _ => bot_le) + · filter_upwards [(tendsto_order.1 hε).2 δ hδ] with n hn + exact (measure_mono (fun x hx => hn.le.trans hx)).trans (hbound n) + +def ApproxScalar {X V : Type*} [MeasurableSpace X] + [NormedAddCommGroup V] [NormedSpace ℝ V] + (μ : Measure X) (a b ε : ℝ) (Z : Lp V 2 μ × Lp V 2 μ) : Prop := + ∃ s : X → ℝ, Measurable s ∧ + (∀ᵐ x ∂μ, s x ∈ Icc a b) ∧ + μ {x | ε ≤ ‖Z.2 x - s x • Z.1 x‖} ≤ ENNReal.ofReal ε + +theorem exact_scalar_of_weak_density + {X V : Type*} [MeasurableSpace X] [NormedAddCommGroup V] + [InnerProductSpace ℝ V] [MeasurableSpace V] [BorelSpace V] + [SecondCountableTopology V] (μ : Measure X) + [SeparableSpace (Lp V 2 μ)] {a b : ℝ} (hab : a ≤ b) + (K : Set (WeakSpace ℝ (Lp V 2 μ × Lp V 2 μ))) + (hK : IsCompact K) (hKn : K.Nonempty) + (hdense : ∀ ε > 0, Dense {z : K | ApproxScalar μ a b ε + ((toWeakSpace ℝ (Lp V 2 μ × Lp V 2 μ)).symm z.val)}) : + ∃ (Z : Lp V 2 μ × Lp V 2 μ) (s : X → ℝ), + toWeakSpace ℝ (Lp V 2 μ × Lp V 2 μ) Z ∈ K ∧ Measurable s ∧ + (∀ᵐ x ∂μ, s x ∈ Icc a b ∧ Z.2 x = s x • Z.1 x) := by + classical + let : Nonempty K := hKn.to_subtype + let φ : K → Lp V 2 μ × Lp V 2 μ := + fun z => (toWeakSpace ℝ (Lp V 2 μ × Lp V 2 μ)).symm z.val + obtain ⟨z, hz⟩ := (dense_weakToStrong_continuityPoints K hK).nonempty + change ContinuousAt φ z at hz + let ε : ℕ → ℝ := fun n => 1 / ((n : ℝ) + 1) + have hεp : ∀ n, 0 < ε n := fun n => div_pos zero_lt_one (Nat.cast_add_one_pos n) + have hεt : Tendsto ε atTop (𝓝 0) := by + simpa only [ε] using tendsto_one_div_add_atTop_nhds_zero_nat + have hn : ∀ n, ∃ w : K, ApproxScalar μ a b (ε n) (φ w) ∧ dist (φ w) (φ z) < ε n := by + intro n + have hnbr : {w : K | dist (φ w) (φ z) < ε n} ∈ 𝓝 z := + hz.preimage_mem_nhds (Metric.ball_mem_nhds _ (hεp n)) + obtain ⟨w, hw, hw'⟩ := (hdense (ε n) (hεp n)).inter_nhds_nonempty hnbr + exact ⟨w, hw, hw'⟩ + choose w hw hd using hn + have hwt : Tendsto (fun n => φ (w n)) atTop (𝓝 (φ z)) := by + apply tendsto_iff_dist_tendsto_zero.2 + exact squeeze_zero (fun n => dist_nonneg) (fun n => (hd n).le) hεt + choose s hsm hsb hsr using hw + obtain ⟨σ, hσm, hσ⟩ := scalar_relation_Lp_strong_closed hab hsb + (continuous_fst.tendsto _ |>.comp hwt) (continuous_snd.tendsto _ |>.comp hwt) + (tendstoInMeasure_of_small_exceptional_sets μ + (fun n x => (φ (w n)).2 x - s n x • (φ (w n)).1 x) ε hεt hsr) + refine ⟨φ z, σ, ?_, hσm, hσ⟩ + simpa only [φ, LinearEquiv.apply_symm_apply] using z.property + +end ScalarConductivity + +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/AttachedSplicedConstitution.lean b/lean/OAI/Analysis/Conductivity/Scalarization/AttachedSplicedConstitution.lean new file mode 100644 index 0000000000000000000000000000000000000000..e729da12cd79d2fb1495e739b7bf397d41469002 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/AttachedSplicedConstitution.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.VariableCollarTensor +import OAI.Analysis.Conductivity.Fourier.AttachedPeriodicDerivative +import OAI.Analysis.Conductivity.Branching.PhysicalNullTransport +import OAI.Analysis.Conductivity.Branching.FlatEndingSplice +import OAI.Analysis.Conductivity.Fourier.SpectralAffineCovector +import OAI.Analysis.Conductivity.Fourier.AttachedPeriodicFlux + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +lemma attachedVariableTensor_flux (K : Coord3 → Mat3) {a : ℝ} (ha : a≠0) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceExtendedBox (-(1:ℝ)/100) (1/100)) (v : Coord3) : + attachedVariableTensor K a i j x*ᵥ(attachedCartesianMatrix a i j x*ᵥv)= + (|a| *sourceFlatDensity i j x) • ((attachedCartesianMatrix a i j x)⁻¹ᵀ*ᵥ(K x*ᵥv)) := by + have he : (attachedCartesianMatrix a i j x)⁻¹*ᵥ + (attachedCartesianMatrix a i j x*ᵥv)=v := by + rw [Matrix.mulVec_mulVec,Matrix.nonsing_inv_mul _ + (isUnit_iff_ne_zero.mpr (attachedCartesianMatrix_det_ne_zero ha i j hx)),Matrix.one_mulVec] + simp only [attachedVariableTensor,Matrix.smul_mulVec,←Matrix.mulVec_mulVec,he] + +lemma correctedEndGradient_transport {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : Fin 2 → spectralTraceGraph (torusRate s)) (i : Fin 3) + (z : TorusEndingData s (branchNormalize i (fun j => torusSpectralSynthesis s (f j)))) + (j : Fin 2) (a b : ℝ) (m n : Fin 4) {x : Coord3} + (hx : x∈sourceCollarOpenBox) (ht : 0 lineDeriv ℝ (attachedPeriodicField (branchCorrection i z j) a b) + (sourceCollarPiece m n x) (Pi.single k 1))= + attachedCartesianMatrix a m n x*ᵥ(fun k => fderiv ℝ (branchSplicedField i z j) + (flatEndCoordinates a b (sourceFaceAngles m n x)) (Pi.single k 1)) := by + let y := flatEndCoordinates a b (sourceFaceAngles m n x) + have hy : 0 flatBackgroundTensor s) a m n x*ᵥ + (attachedCartesianMatrix a m n x*ᵥ_) = _ + rw [attachedVariableTensor_flux _ ha m n (sourceCollarOpenBox_subset hx),flatModeFlux_tensor] + have he := torusAffineField_spectral_covector hs f κ + (show 0<(flatEndCoordinates a b (sourceFaceAngles m n x)) 0 from ht) + have ha' : torusAngles (flatEndCoordinates a b (sourceFaceAngles m n x))= + torusAngles (sourceFaceAngles m n x) := torusAngles_endAxialAffine a b _ + rw [ha'] at he + rw [he] + rfl + +lemma attachedSpliced_constitution_point {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : Fin 2 → spectralTraceGraph (torusRate s)) (i : Fin 3) + (z : TorusEndingData s (branchNormalize i (fun j => torusSpectralSynthesis s (f j)))) + (j : Fin 2) {a b : ℝ} (ha : a≠0) (m n : Fin 4) {x : Coord3} + (hx : x∈sourceCollarOpenBox) (ht : 0 fderiv ℝ (branchSplicedField i z j) + (flatEndCoordinates a b (sourceFaceAngles m n x)) (Pi.single k 1))= + branchSplicedFlux i z j (flatEndCoordinates a b (sourceFaceAngles m n x))) : + variableCollarTensor (branchSplicedTensor i z) a b (sourceCollarPiece m n x)*ᵥ + (fullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) (sourceCollarPiece m n x)+ + (fun k => lineDeriv ℝ (attachedPeriodicField (branchCorrection i z j) a b) + (sourceCollarPiece m n x) (Pi.single k 1)))= + attachedCollarTensor s a (sourceCollarPiece m n x)*ᵥ + fullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) (sourceCollarPiece m n x)+ + attachedPeriodicFlux (branchFluxCorrection i z j) a b (sourceCollarPiece m n x) := by + rw [correctedEndGradient_transport hs f i z j a b m n hx ht, + variableCollarTensor_open _ a b m n hx,attachedVariableTensor_flux _ ha m n (sourceCollarOpenBox_subset hx),hE, + branchSplicedFlux,Matrix.mulVec_add,smul_add, + fullAttachedEnd_flat_flux hs (f j) (centralBasisSlopes j i) ha m n hx ht, + attachedPeriodicFlux_open _ a b m n hx] + +lemma attachedSpliced_constitution_ae {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (f : Fin 2 → spectralTraceGraph (torusRate s)) (i : Fin 3) + (z : TorusEndingData s (branchNormalize i (fun j => torusSpectralSynthesis s (f j)))) + (j : Fin 2) {a b l r : ℝ} (ha : a≠0) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Ioo l r,0 lineDeriv ℝ (attachedPeriodicField (branchCorrection i z j) a b) y (Pi.single k 1))= + attachedCollarTensor s a y*ᵥfullAttachedEndGradient s (f j) a b (centralBasisSlopes j i) y+ + attachedPeriodicFlux (branchFluxCorrection i z j) a b y := by + apply sourceClosedCollarBand_ae_faces hl hr + intro m n + have he := sourceFaceAngles_ae + (flatEndCoordinates_ae ha b (branchSpliced_constitution i z hs j)) m n + filter_upwards [ae_restrict_of_ae he,sourceExtendedBox_open_ae hl hr, + sourceExtendedBox_axial_strict_ae l r] with x hx hxo hxt + exact attachedSpliced_constitution_point hs f i z j ha m n hxo (hT _ hxt) hx + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/CascadeConnectorConstitution.lean b/lean/OAI/Analysis/Conductivity/Scalarization/CascadeConnectorConstitution.lean new file mode 100644 index 0000000000000000000000000000000000000000..465c68783f1302b7859edc4006db03949d323c0b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/CascadeConnectorConstitution.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.LocalConstitution +import OAI.Analysis.Conductivity.Fourier.PureMode + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +lemma cascadeProfile_deriv_connector {L K t : ℝ} (hL : 0 cascadePhase (cascadeLength L K) k m (y 0)) := by + unfold cascadePhase + fun_prop + exact (hc.isOpen_preimage _ isOpen_Ioo).mem_nhds ⟨hs₁,hs₂⟩ + +theorem cascade_connector_constitution {L K k : ℝ} (hL : 0 direction (Pi.single i 1) (cascadeValue L K k A) x) = cascadeFlux L K k A x := by + have hf := (connectorProfile_smooth K).differentiable (by simp) + have hf' := (smooth_deriv_infty (connectorProfile_smooth K)).differentiable (by simp) + apply local_scaled_constitution (pureModeValue_diff hf _) (pureModePotential_diff hf' _) + (A*cascadeRatio L K^m) (k*2^m) (cascadeCenter (cascadeLength L K) k m) 0 x + · filter_upwards [cascade_connector_nhds x m hs₁ hs₂] with y hy + simpa only [sub_zero] using cascadeValue_connector hL hK hk A y m hy.1 hy.2 + · intro i j + filter_upwards [cascade_connector_nhds x m hs₁ hs₂] with y hy + rw [cascadePotential_two_terms hL hK hk A y (m := m) (by linarith [hy.1]) + (by have hh : K+2 (volume : Measure ℝ)) i r + +lemma ae_cascadePhase_ne {k : ℝ} (hk : k≠0) (D r : ℝ) (n : ℕ) : + ∀ᵐ x : Coord3, cascadePhase D k n (x 0)≠r := by + filter_upwards [ae_coord3_ne 0 ((r-2*D+2^n*(2*D))/(2^n*k))] with x hx + intro he + apply hx + apply (eq_div_iff (mul_ne_zero (by positivity) hk)).mpr + unfold cascadePhase at he + nlinarith + +lemma cascadeValue_direction_terminal {L K k : ℝ} (hL : 0 (0:ℝ) := by + filter_upwards [hn] with y hy + exact cascadeValue_terminal hL hK A y hy.le + simp [direction,he.fderiv_eq] + +theorem cascadeTensor_constitution_ae {L K k : ℝ} (hL : 0 direction (Pi.single i 1) (cascadeValue L K k A) x) = + cascadeFlux L K k A x := by + have h0 : ∀ᵐ x : Coord3, ∀ n : ℕ, cascadePhase (cascadeLength L K) k n (x 0)≠0 := + ae_all_iff.mpr (fun n => ae_cascadePhase_ne hk _ _ n) + have hD : ∀ᵐ x : Coord3, ∀ n : ℕ, cascadePhase (cascadeLength L K) k n (x 0)≠cascadeLength L K := + ae_all_iff.mpr (fun n => ae_cascadePhase_ne hk _ _ n) + have hK2 : ∀ᵐ x : Coord3, ∀ n : ℕ, cascadePhase (cascadeLength L K) k n (x 0)≠K+2 := + ae_all_iff.mpr (fun n => ae_cascadePhase_ne hk _ _ n) + have ht : ∀ᵐ x : Coord3, k*x 0≠2*cascadeLength L K := by + simpa only [cascadePhase_zero] using ae_cascadePhase_ne hk (cascadeLength L K) (2*cascadeLength L K) 0 + filter_upwards [h0,hD,hK2,ht] with x hx0 hxD hxK hxt + intro hx + by_cases hterm : k*x 0<2*cascadeLength L K + · have hs := cascadeIndex_spec x hx hterm + have hs₁ := lt_of_le_of_ne hs.1 (Ne.symm (hx0 _)) + have hs₂ := lt_of_le_of_ne hs.2 (hxD _) + rw [cascadeTensor,ite_eq_left ⟨hx,hterm⟩,cascadeStageTensor] + split_ifs with hc + · exact cascade_connector_constitution hL hK hk A x _ hs₁ hc + · exact cascade_crossing_constitution hL hK hk A x _ + (lt_of_le_of_ne (le_of_not_gt hc) (Ne.symm (hxK _))) hs₂ + · have ht' : 2*cascadeLength L K ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0) + {U : Set Coord3} (hU : IsOpen U) (hUb : Bornology.IsBounded U) + (hUpos : U⊆{x : Coord3 | 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : voltageH1Jets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (s : Coord3 → ℝ), + Measurable s ∧ MemLp s ∞ (volume.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _)∈zeroVoltageJets volume U ∧ + (∀ᵐ x ∂volume.restrict U,s x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=s x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets volume U,inner ℝ W.val.2 F=0) := by + let A : Coord3 → Symmetric3 := fun y => ⟨E y,hsym y⟩ + let : IsFiniteMeasure (volume.restrict U) := + isFiniteMeasure_restrict.mpr hUb.measure_lt_top.ne + let : Fact ((2 : ℝ≥0∞) ≠ ∞) := ⟨by norm_num⟩ + have hAm : Measurable A := by + change @Measurable Coord3 Symmetric3 _ (borel Symmetric3) A + rw [borel_comap, ← BorelSpace.measurable_eq (α := Mat3)] + exact hEm.subtype_mk + obtain ⟨hu,hE,huH1⟩ := C1_voltageJet_mem (hv.of_le (by norm_num)) hUb hU.measurableSet + have hFg : Continuous (fun x => fieldVector (G x)) := fieldVectorCLM.continuous.comp hG.continuous + have heq : voltageFlux v A =ᵐ[volume] fun x => fieldVector (G x) := by + filter_upwards [hconst] with x hx + exact congrArg fieldVector hx + have hF : MemLp (voltageFlux v A) 2 (volume.restrict U) := + (continuous_memLp_bounded_coord hFg hUb hU.measurableSet).ae_eq + (heq.filter_mono (ae_mono Measure.restrict_le_self)).symm + have hw (j : Fin 2) (ψ : Coord3 → ℝ) (hψ : ContDiff ℝ (↑(⊤:ℕ∞)) ψ) + (hcψ : HasCompactSupport ψ) (hsψ : tsupport ψ⊆U) : + Integrable (fun x => fderiv ℝ ψ x ((conductivityFlux v A x).col j)) ∧ + (∫ x,fderiv ℝ ψ x ((conductivityFlux v A x).col j))=0 := by + have hh := hweak j ⟨ψ,hψ⟩ hcψ (hsψ.trans hUpos) + have heqf : (fun x => fderiv ℝ ψ x ((conductivityFlux v A x).col j)) = + (fun x => ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) (⟨ψ,hψ⟩ : SmoothScalar Coord3)).val x) := by + funext x + rw [clm_coord3_expansion] + rfl + rw [heqf] + exact hh + have hregU : volume (U\regularRegion v A U)=0 := by + apply measure_eq_zero_iff_ae_notMem.mpr + filter_upwards [hreg] with x hx hh + exact hh.2 (mem_regularRegion_congr_nhds (hx (hUpos hh.1)) + Filter.EventuallyEq.rfl Filter.EventuallyEq.rfl hU hh.1) + obtain ⟨z,F,s,hres⟩ := finite_field_scalarization volume hc hcC hUb hU.measurableSet + v A hAm hu hE hF huH1 + (fun j ψ hψ hcψ hsψ => (hw j ψ hψ hcψ hsψ).1) + (fun j ψ hψ hcψ hsψ => (hw j ψ hψ hcψ hsψ).2) hregU + (ae_of_all _ (fun x _ => hb x)) + exact ⟨hu,hE,hF,z,F,s,hres⟩ + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology TopologicalSpace MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +local instance alignedFourierEndingH1MeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance alignedFourierEndingH1BorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem aligned_fourier_ending_H1_scalarization {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : voltageH1Jets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (σ : Coord3 → ℝ), + Measurable σ ∧ MemLp σ ∞ (volume.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _)∈zeroVoltageJets volume U ∧ + (∀ᵐ x ∂volume.restrict U,σ x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=σ x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets volume U,inner ℝ W.val.2 F=0) := by + obtain ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hv,hEm,hvp,hEp,⟨hsym,hreg⟩, + hbound,hvin,hEin,hterm,hr,⟨G,hG,hconst⟩,hw⟩ := + aligned_fourier_finite_ending (pa:=pa) hs hk hA hB ha hb hga hgb hra hrb hpb hδ + refine ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,hvin,hEin,hterm,?_⟩ + intro U hU hUb hUpos + exact scalarization_H1_of_concrete_C1flux hv hEm hsym hG hconst hc hcC hbound hreg hw hU hUb hUpos + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/ConcreteFluxScalarization.lean b/lean/OAI/Analysis/Conductivity/Scalarization/ConcreteFluxScalarization.lean new file mode 100644 index 0000000000000000000000000000000000000000..a36cf768f989f6d8f92e03af82f952235fa42b20 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/ConcreteFluxScalarization.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.UniformMatrixScalarization +import OAI.Analysis.Conductivity.Fourier.FourierFiniteEnding + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology TopologicalSpace MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +local instance concreteFluxScalarizationMeasurableSpaceMat3 : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance concreteFluxScalarizationBorelSpaceMat3 : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +lemma continuous_memLp_bounded_coord {F : Type*} [NormedAddCommGroup F] + [MeasurableSpace F] [BorelSpace F] [SecondCountableTopology F] + {f : Coord3 → F} (hf : Continuous f) {U : Set Coord3} + (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) : + MemLp f 2 (volume.restrict U) := by + let : IsFiniteMeasure (volume.restrict U) := + isFiniteMeasure_restrict.mpr hUb.measure_lt_top.ne + obtain ⟨M,hM⟩ := hUb.isCompact_closure.exists_bound_of_continuousOn hf.continuousOn + apply MemLp.of_bound hf.measurable.aestronglyMeasurable M + filter_upwards [ae_restrict_mem hUm] with x hx + exact hM x (subset_closure hx) + +lemma clm_coord3_expansion (L : Coord3 →L[ℝ] ℝ) (w : Coord3) : + L w=∑ i,w i*L (Pi.single i 1) := by + have he : w=∑ i : Fin 3,w i • Pi.single i 1 := by + ext j + simp [Pi.single_apply] + conv_lhs => rw [he] + simp only [map_sum,map_smul,smul_eq_mul] + +theorem scalarization_of_concrete_C1flux + {v : Coord3 → Fin 2 → ℝ} (hv : ContDiff ℝ 2 v) + {E : Coord3 → Mat3} (hEm : Measurable E) (hsym : ∀ x,(E x).IsSymm) + {G : Coord3 → Matrix (Fin 3) (Fin 2) ℝ} (hG : ContDiff ℝ 1 G) + (hconst : ∀ᵐ x : Coord3,E x*gradientColumns (fderiv ℝ v x)=G x) + {c C : ℝ} (hc : 0 ⟨E y,hsym y⟩) {y : Coord3 | 0 ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x) ∧ + (∫ x,∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) ψ).val x)=0) + {U : Set Coord3} (hU : IsOpen U) (hUb : Bornology.IsBounded U) + (hUpos : U⊆{x : Coord3 | 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : zeroVoltageJets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (s : Coord3 → ℝ), + Measurable s ∧ MemLp s ∞ (volume.restrict U) ∧ + (∀ᵐ x ∂volume.restrict U,s x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=s x • ((hE.toLp _+z.val.2) x)) ∧ + (∀ W∈allVoltageGradients volume U,inner ℝ W F=inner ℝ W (hF.toLp _)) := by + let A : Coord3 → Symmetric3 := fun y => ⟨E y,hsym y⟩ + let : IsFiniteMeasure (volume.restrict U) := + isFiniteMeasure_restrict.mpr hUb.measure_lt_top.ne + let : Fact ((2 : ℝ≥0∞) ≠ ∞) := ⟨by norm_num⟩ + have hAm : Measurable A := by + change @Measurable Coord3 Symmetric3 _ (borel Symmetric3) A + rw [borel_comap, ← BorelSpace.measurable_eq (α := Mat3)] + exact hEm.subtype_mk + have hvg : Continuous (voltageGradient v) := + gradientVectorCLM.continuous.comp (hv.continuous_fderiv (by norm_num)) + have hE := continuous_memLp_bounded_coord hvg hUb hU.measurableSet + have hFg : Continuous (fun x => fieldVector (G x)) := fieldVectorCLM.continuous.comp hG.continuous + have heq : voltageFlux v A =ᵐ[volume] fun x => fieldVector (G x) := by + filter_upwards [hconst] with x hx + exact congrArg fieldVector hx + have hF : MemLp (voltageFlux v A) 2 (volume.restrict U) := + (continuous_memLp_bounded_coord hFg hUb hU.measurableSet).ae_eq + (heq.filter_mono (ae_mono Measure.restrict_le_self)).symm + have hw (j : Fin 2) (ψ : Coord3 → ℝ) (hψ : ContDiff ℝ (↑(⊤:ℕ∞)) ψ) + (hcψ : HasCompactSupport ψ) (hsψ : tsupport ψ⊆U) : + Integrable (fun x => fderiv ℝ ψ x ((conductivityFlux v A x).col j)) ∧ + (∫ x,fderiv ℝ ψ x ((conductivityFlux v A x).col j))=0 := by + have hh := hweak j ⟨ψ,hψ⟩ hcψ (hsψ.trans hUpos) + have heqf : (fun x => fderiv ℝ ψ x ((conductivityFlux v A x).col j)) = + (fun x => ∑ i,(E x*gradientColumns (fderiv ℝ v x)).col j i* + (smoothDirection (Pi.single i 1) (⟨ψ,hψ⟩ : SmoothScalar Coord3)).val x) := by + funext x + rw [clm_coord3_expansion] + rfl + rw [heqf] + exact hh + have hregU : volume (U\regularRegion v A U)=0 := by + apply measure_eq_zero_iff_ae_notMem.mpr + filter_upwards [hreg] with x hx hh + exact hh.2 (mem_regularRegion_congr_nhds (hx (hUpos hh.1)) + Filter.EventuallyEq.rfl Filter.EventuallyEq.rfl hU hh.1) + obtain ⟨z,F,s,hsm,hs,hC⟩ := exact_scalarization_Cauchy_flux volume + (uniform_laminate_coverage hc hcC).1 (uniform_laminate_coverage hc hcC).2.1 + hUb hU.measurableSet v A hAm hE hF + (fun j ψ hψ hcψ hsψ => (hw j ψ hψ hcψ hsψ).1) + (fun j ψ hψ hcψ hsψ => (hw j ψ hψ hcψ hsψ).2) hregU + (ae_of_all _ (fun x _ => uniform_matrix_laminate_coverage hc hcC (A x) (hb x))) + refine ⟨hE,hF,z,F,s,hsm,?_,hs,hC⟩ + apply memLp_top_of_bound hsm.aestronglyMeasurable (laminateUpper C) + filter_upwards [hs] with x hx + rw [Real.norm_eq_abs,abs_of_nonneg ((uniform_laminate_coverage hc hcC).1.le.trans hx.1.1)] + exact hx.1.2 + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology TopologicalSpace MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +local instance alignedFourierEndingScalarizationMeasurableSpaceMat3 : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance alignedFourierEndingScalarizationBorelSpaceMat3 : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +theorem aligned_fourier_ending_scalarization {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {k : ℤ} (hk : 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : zeroVoltageJets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (σ : Coord3 → ℝ), + Measurable σ ∧ MemLp σ ∞ (volume.restrict U) ∧ + (∀ᵐ x ∂volume.restrict U,σ x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=σ x • ((hE.toLp _+z.val.2) x)) ∧ + (∀ W∈allVoltageGradients volume U,inner ℝ W F=inner ℝ W (hF.toLp _)) := by + obtain ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hv,hEm,hvp,hEp,⟨hsym,hreg⟩, + hbound,hvin,hEin,hterm,hr,⟨G,hG,hconst⟩,hw⟩ := + aligned_fourier_finite_ending (pa:=pa) hs hk hA hB ha hb hga hgb hra hrb hpb hδ + refine ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,hvin,hEin,hterm,?_⟩ + intro U hU hUb hUpos + exact scalarization_of_concrete_C1flux hv hEm hsym hG hconst hc hcC hbound hreg hw hU hUb hUpos + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/DefectMeasure.lean b/lean/OAI/Analysis/Conductivity/Scalarization/DefectMeasure.lean new file mode 100644 index 0000000000000000000000000000000000000000..eeaa7e41b52e99ba5e25ddb462cf301e978a7e63 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/DefectMeasure.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal + +lemma defect_tendstoInMeasure_of_small_exceptions + {X V : Type*} [MeasurableSpace X] [NormedAddCommGroup V] [NormedSpace ℝ V] + (μ : Measure X) (E : ℕ → Lp V 2 μ) (r : ℕ → X → V) + (η : ℕ → ℝ) (hη : ∀ n, 0 ≤ η n) (hηt : Tendsto η atTop (𝓝 0)) + (B : ℕ → Set X) (hB : Tendsto (fun n => μ (B n)) atTop (𝓝 0)) + {C : ℝ} (hC : 0 ≤ C) (hEC : ∀ n, ‖E n‖ ≤ C) + (hdef : ∀ n, ∀ᵐ x ∂μ, x ∉ B n → ‖r n x‖ ≤ η n * ‖E n x‖) : + TendstoInMeasure μ r atTop (fun _ => 0) := by + let Z : ℕ → Lp V 2 μ := fun n => η n • E n + have hZ : Tendsto Z atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + apply squeeze_zero (fun n => norm_nonneg _) _ (by simpa using hηt.mul_const C) + intro n + change ‖η n • E n‖ ≤ η n * C + rw [norm_smul, Real.norm_of_nonneg (hη n)] + simpa only [mul_comm] using mul_le_mul (hEC n) le_rfl (hη n) hC + have hZI : TendstoInMeasure μ (fun n x => Z n x) atTop (fun _ => 0) := by + have hh := tendstoInMeasure_of_tendsto_Lp hZ + apply hh.congr_right + filter_upwards [Lp.coeFn_zero (E := V) (p := 2) (μ := μ)] with x hx + exact hx + rw [tendstoInMeasure_iff_norm] at hZI ⊢ + intro ε hε + simp only [sub_zero] at hZI ⊢ + apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds + (by simpa only [add_zero] using hB.add (hZI ε hε)) + · exact Eventually.of_forall (fun _ => bot_le) + · apply Eventually.of_forall + intro n + have hs : ∀ᵐ x ∂μ, x ∈ {x | ε ≤ ‖r n x‖} → x ∈ B n ∪ {x | ε ≤ ‖Z n x‖} := by + filter_upwards [hdef n, Lp.coeFn_smul (η n) (E n)] with x hx hz + intro hr + by_cases hb : x ∈ B n + · exact Or.inl hb + · right + have he : ‖Z n x‖ = η n * ‖E n x‖ := by + change ‖(η n • E n : Lp V 2 μ) x‖ = _ + rw [hz, Pi.smul_apply, norm_smul, Real.norm_of_nonneg (hη n)] + exact (hr.trans (hx hb)).trans_eq he.symm + exact (measure_mono_ae hs).trans (measure_union_le _ _) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/DenseClosureApprox.lean b/lean/OAI/Analysis/Conductivity/Scalarization/DenseClosureApprox.lean new file mode 100644 index 0000000000000000000000000000000000000000..9575c825d687c19e90a23fba6ed1d253bcc74304 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/DenseClosureApprox.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.FineScalarSequence + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology + +lemma dense_property_in_closure + {X : Type*} [TopologicalSpace X] (S : Set X) (P : X → Prop) + (h : ∀ x ∈ S, ∃ z : ℕ → X, Tendsto z atTop (𝓝 x) ∧ + (∀ n, z n ∈ S) ∧ ∀ᶠ n in atTop, P (z n)) : + Dense {x : closure S | P x.val} := by + rw [Subtype.dense_iff] + apply closure_minimal _ isClosed_closure + intro x hx + obtain ⟨z,hz,hzS,hzP⟩ := h x hx + apply mem_closure_of_tendsto hz + filter_upwards [hzP] with n hn + exact ⟨⟨z n,subset_closure (hzS n)⟩,hn,rfl⟩ + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology TopologicalSpace +open scoped ENNReal + +def finiteUpdatePairs + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + (U : Set Coord3) (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) (a b : ℝ) : + Set (Lp FieldVector 2 (μ.restrict U) × Lp FieldVector 2 (μ.restrict U)) := + {Z | ∃ R : CompactGlobalUpdate μ U u A, + μ (U \ regularRegion (fun x => u x+R.du x) R.tensor U) = 0 ∧ + (∀ᵐ x ∂μ, x ∈ U → R.tensor x ∈ matrixFiniteLaminate a b) ∧ + Z = R.fieldPair μ hE hF} + +lemma finiteUpdatePairs_nonempty + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (hAm : Measurable A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) {a b : ℝ} + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) : + (finiteUpdatePairs μ U u A hE hF a b).Nonempty := by + refine ⟨(CompactGlobalUpdate.refl μ U u A hAm).fieldPair μ hE hF, + CompactGlobalUpdate.refl μ U u A hAm,?_,hgraph,rfl⟩ + simpa only [CompactGlobalUpdate.refl,Pi.zero_apply,add_zero] using hreg + +lemma dense_ApproxScalar_in_finiteUpdateClosure + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) {ε : ℝ} (hε : 0 < ε) : + Dense {z : closure (toWeakSpace ℝ _ '' finiteUpdatePairs μ U u A hE hF a b) | + ApproxScalar (μ.restrict U) a b ε ((toWeakSpace ℝ _).symm z.val)} := by + apply dense_property_in_closure + rintro _ ⟨Z,⟨R,hregR,hgraphR,rfl⟩,rfl⟩ + obtain ⟨hER,hFR⟩ := R.fields_memLp μ hUm hreg hE hF + obtain ⟨hintR,hdivR⟩ := R.preserves_harmonic μ hint hdiv + obtain ⟨S,hregS,hgraphS,hw,happrox⟩ := exists_fine_scalar_sequence μ ha hab hUb hUm + (fun x => u x+R.du x) R.tensor R.measurable_tensor hER hFR hintR hdivR hregR hgraphR + have he : ∀ n, (R.trans μ (S n)).fieldPair μ hE hF = (S n).fieldPair μ hER hFR := + fun n => R.fieldPair_trans μ hUm (S n) hreg hregR hE hF hER hFR + refine ⟨fun n => toWeakSpace ℝ _ ((R.trans μ (S n)).fieldPair μ hE hF),?_,?_,?_⟩ + · simpa only [he,R.fieldPair_eq μ hUm hreg hE hF hER hFR] using hw + · intro n + refine ⟨_,⟨R.trans μ (S n),?_,hgraphS n,rfl⟩,rfl⟩ + simpa only [CompactGlobalUpdate.trans,Pi.add_apply,add_assoc] using hregS n + · filter_upwards [happrox ε hε] with n hn + change ApproxScalar (μ.restrict U) a b ε ((R.trans μ (S n)).fieldPair μ hE hF) + rwa [he n] + +theorem exact_scalar_in_finiteUpdateClosure + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + [SeparableSpace (Lp FieldVector 2 (μ.restrict U))] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) : + ∃ (Z : Lp FieldVector 2 (μ.restrict U) × Lp FieldVector 2 (μ.restrict U)) + (s : Coord3 → ℝ), + toWeakSpace ℝ _ Z ∈ closure (toWeakSpace ℝ _ '' finiteUpdatePairs μ U u A hE hF a b) ∧ + Measurable s ∧ (∀ᵐ x ∂μ.restrict U, s x ∈ Icc a b ∧ Z.2 x = s x • Z.1 x) := by + apply exact_scalar_of_weak_density (μ.restrict U) hab.le + · apply isCompact_weak_closure_of_pair_bounds + rintro Z ⟨R,hregR,hgraphR,rfl⟩ + exact R.fieldPair_energy_bound μ hUm hreg hE hF hint hdiv ha hab hgraphR + · exact ((finiteUpdatePairs_nonempty μ hAm hE hF hreg hgraph).image _).closure + · intro ε hε + exact dense_ApproxScalar_in_finiteUpdateClosure μ ha hab hUb hUm u A hE hF hint hdiv hreg hε + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/EndingJoinConstitution.lean b/lean/OAI/Analysis/Conductivity/Scalarization/EndingJoinConstitution.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b34a92c70aaea65bf4404a6aea2c742361185d0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/EndingJoinConstitution.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.EndingJoinCutoff +import OAI.Analysis.Conductivity.Flux.DelayedPairFlux +import OAI.Analysis.Conductivity.Branching.EndingJoinOverlap + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory Matrix + +def matchingFlux (D : Coord3 → Mat3) (u : Coord3 → Fin 2 → ℝ) (j : Fin 2) (x : Coord3) : Coord3 := + (D x*gradientColumns (fderiv ℝ u x)).col j + +def joinedFlux (D : Coord3 → Mat3) (u : Coord3 → Fin 2 → ℝ) (lam k J L K : ℝ) (j : Fin 2) : Coord3 → Coord3 := + axialFluxBlend endingJoinCutoff (matchingFlux D u j) (delayedPairFlux lam k J L K 7 j) + +lemma endingJoin_constitution_ae {D : Coord3 → Mat3} {u : Coord3 → Fin 2 → ℝ} + {lam k J L K : ℝ} (hk : 0 (Z n).2 x-s n x • (Z n).1 x) atTop (fun _ => 0)) : + ∀ ε > 0, ∀ᶠ n in atTop, ApproxScalar μ a b ε (Z n) := by + intro ε hε + have hh := (tendstoInMeasure_iff_norm.mp ht) ε hε + simp only [sub_zero] at hh + filter_upwards [hh.eventually (eventually_le_nhds (ENNReal.ofReal_pos.mpr hε))] with n hn + exact ⟨s n,hsm n,hsb n,hn⟩ + +lemma measurable_matrix_diagonal {X : Type*} [MeasurableSpace X] + {A : X → Symmetric3} (hA : Measurable A) (i : Fin 3) : + Measurable (fun x => (A x).val i i) := by + have hc : Continuous (fun q : Symmetric3 => q.val i i) := + (continuous_apply i).comp ((continuous_apply i).comp continuous_subtype_val) + exact hc.measurable.comp hA + +theorem exists_fine_scalar_sequence + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) : + ∃ S : ℕ → CompactGlobalUpdate μ U u A, + (∀ n, μ (U \ regularRegion (fun x => u x+(S n).du x) (S n).tensor U) = 0) ∧ + (∀ n, ∀ᵐ x ∂μ, x ∈ U → (S n).tensor x ∈ matrixFiniteLaminate a b) ∧ + Tendsto (fun n => toWeakSpace ℝ _ ((S n).fieldPair μ hE hF)) atTop + (𝓝 (toWeakSpace ℝ _ (hE.toLp _,hF.toLp _))) ∧ + (∀ ε > 0, ∀ᶠ n in atTop, ApproxScalar (μ.restrict U) a b ε ((S n).fieldPair μ hE hF)) := by + classical + let η : ℕ → ℝ := fun n => 1/((n:ℝ)+1) + have hηp : ∀ n, 0 < η n := fun n => div_pos zero_lt_one (Nat.cast_add_one_pos n) + have hηt : Tendsto η atTop (𝓝 0) := tendsto_one_div_add_atTop_nhds_zero_nat + choose N O center R S hcell hdis hsu hsF hregS hgraphS hbad using + fun n => fine_global_scalar_tensor_approximation μ ha hab hUb u A hAm hint hdiv + hreg hgraph (hηp n) (hηp n) (hηp n) + have hBnd := fun n => (S n).correction_energy_bound μ hUm hreg hE hF hint hdiv ha hab (hgraphS n) + have hCE : 0 ≤ (b/a+1)*‖hE.toLp _‖ := by have hb := ha.trans hab; positivity + have hCF : 0 ≤ (b^2/a)*‖hE.toLp _‖+‖hF.toLp _‖ := by positivity + obtain ⟨hwE,hwF⟩ := fine_updates_weak_tendsto_zero μ hUb N O center R S η hηt + (fun n i => subset_closure.trans (hcell n i).2.1) + (fun n i => subset_closure.trans (hcell n i).2.2) hdis hsu hsF hCE hCF + (fun n => (hBnd n).1) (fun n => (hBnd n).2) + have hw : Tendsto (fun n => toWeakSpace ℝ _ ((S n).fieldPair μ hE hF)) atTop + (𝓝 (toWeakSpace ℝ _ (hE.toLp _,hF.toLp _))) := by + have ht := continuous_weak_pair.tendsto (0,0) |>.comp (hwE.prodMk_nhds hwF) + have ht' := ht.const_add (toWeakSpace ℝ _ (hE.toLp _,hF.toLp _)) + simpa [CompactGlobalUpdate.fieldPair,Function.comp_def,← map_add] using ht' + let Z := fun n => (S n).fieldPair μ hE hF + let s : ℕ → Coord3 → ℝ := fun n x => ((S n).tensor x).val 0 0 + have hsm : ∀ n, Measurable (s n) := fun n => measurable_matrix_diagonal (S n).measurable_tensor 0 + have hsb : ∀ n, ∀ᵐ x ∂μ.restrict U, s n x ∈ Icc a b := by + intro n + filter_upwards [(ae_restrict_iff' hUm).mpr (hgraphS n)] with x hx + exact matrixFiniteLaminate_diagonal_bounds ha hx 0 + let B := fun n => U \ (S n).tensor ⁻¹' spectralExtension (scalarNeighbourhood a b (η n)) + have hBt : Tendsto (fun n => (μ.restrict U) (B n)) atTop (𝓝 0) := by + apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds + (by simpa using ENNReal.tendsto_ofReal hηt) + · exact Eventually.of_forall fun _ => bot_le + · exact Eventually.of_forall fun n => (Measure.restrict_apply_le U (B n)).trans (hbad n) + have hdef : ∀ n, ∀ᵐ x ∂μ.restrict U, x ∉ B n → + ‖(Z n).2 x-s n x • (Z n).1 x‖ ≤ 2*η n * ‖(Z n).1 x‖ := by + intro n + filter_upwards [(S n).fieldPair_ae μ hUm hreg hE hF,ae_restrict_mem hUm] with x hx hxU + intro hxB + have hxG : (S n).tensor x ∈ spectralExtension (scalarNeighbourhood a b (η n)) := by + by_contra hn + exact hxB ⟨hxU,hn⟩ + dsimp only [Z,s] + rw [hx.1,hx.2] + exact scalarNeighbourhood_defect_bound (hηp n).le hxG _ + have hr := defect_tendstoInMeasure_of_small_exceptions (μ.restrict U) + (fun n => (Z n).1) (fun n x => (Z n).2 x-s n x • (Z n).1 x) + (fun n => 2*η n) (fun n => mul_nonneg (by norm_num) (hηp n).le) + (by simpa using hηt.const_mul 2) B hBt + (show 0 ≤ (b/a)*‖hE.toLp _‖ by have hb := ha.trans hab; positivity) + (fun n => ((S n).fieldPair_energy_bound μ hUm hreg hE hF hint hdiv ha hab (hgraphS n)).1) hdef + exact ⟨S,hregS,hgraphS,hw,eventually_ApproxScalar_of_tendstoInMeasure (μ.restrict U) Z s hsm hsb hr⟩ + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology + +lemma CompactGlobalUpdate.fieldPair_trans + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + (S : CompactGlobalUpdate μ U (fun x => u x+R.du x) R.tensor) + (hreg : μ (U \ regularRegion u A U) = 0) + (hreg' : μ (U \ regularRegion (fun x => u x+R.du x) R.tensor U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hE' : MemLp (voltageGradient (fun x => u x+R.du x)) 2 (μ.restrict U)) + (hF' : MemLp (voltageFlux (fun x => u x+R.du x) R.tensor) 2 (μ.restrict U)) : + (R.trans μ S).fieldPair μ hE hF = S.fieldPair μ hE' hF' := by + have he : (fun x => u x+(R.trans μ S).du x) = + (fun x => (u x+R.du x)+S.du x) := by + funext x + exact (add_assoc _ _ _).symm + apply Prod.ext + · apply Lp.ext + filter_upwards [(R.trans μ S).fieldPair_ae μ hUm hreg hE hF, + S.fieldPair_ae μ hUm hreg' hE' hF'] with x hx hy + rw [hx.1,hy.1,he] + · apply Lp.ext + filter_upwards [(R.trans μ S).fieldPair_ae μ hUm hreg hE hF, + S.fieldPair_ae μ hUm hreg' hE' hF'] with x hx hy + rw [hx.2,hy.2,he] + rfl + +lemma CompactGlobalUpdate.fieldPair_refl + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (hAm : Measurable A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) : + (CompactGlobalUpdate.refl μ U u A hAm).fieldPair μ hE hF = (hE.toLp _,hF.toLp _) := by + have he : voltageGradient (CompactGlobalUpdate.refl μ U u A hAm).du = 0 := by + funext x + simp [CompactGlobalUpdate.refl,voltageGradient] + have hf : (fun x => fieldVector ((CompactGlobalUpdate.refl μ U u A hAm).dF x)) = 0 := by + funext x + exact map_zero fieldVectorCLM + simp [fieldPair, he, hf] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/GeneralModeEndingScalarization.lean b/lean/OAI/Analysis/Conductivity/Scalarization/GeneralModeEndingScalarization.lean new file mode 100644 index 0000000000000000000000000000000000000000..3851646f3073bc4aa954a39acafda651bd2b28da --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/GeneralModeEndingScalarization.lean @@ -0,0 +1,157 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.ConcreteFluxH1Scalarization +import OAI.Analysis.Conductivity.Fourier.AngularPhaseTranslation + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology TopologicalSpace MeasureTheory Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +local instance generalModeEndingScalarizationMeasurableSpace : MeasurableSpace Mat3 := + inferInstanceAs (MeasurableSpace (Fin 3 → Fin 3 → ℝ)) +local instance generalModeEndingScalarizationBorelSpace : BorelSpace Mat3 := + inferInstanceAs (BorelSpace (Fin 3 → Fin 3 → ℝ)) + +lemma flatFourier_div_coefficients (s : Fin 3 → ℝ) + (a phase : (Fin 2 → ℤ) → ℝ) (d : ℝ) (x : Coord3) : + flatFourier s (fun h => a h/d) phase x=flatFourier s a phase x/d := by + unfold flatFourier + simp_rw [div_mul_eq_mul_div] + exact tsum_div_const + +lemma normalizedFourierCoefficients_div (s : Fin 3 → ℝ) (lam T d : ℝ) + (a : (Fin 2 → ℤ) → ℝ) : + normalizedFourierCoefficients s lam T (fun h => a h/d)= + fun h => normalizedFourierCoefficients s lam T a h/d := by + funext h + unfold normalizedFourierCoefficients + ring + +lemma normalized_flatFourier_angular_conjugacy (s : Fin 3 → ℝ) + {A : Matrix (Fin 2) (Fin 2) ℤ} (hA : A.det=1) + (a phase : (Fin 2 → ℤ) → ℝ) (lam T : ℝ) (θ : Fin 2 → ℝ) (x : Coord3) : + flatFourier (normalizedAngularTensor s A) + (normalizedFourierCoefficients (normalizedAngularTensor s A) + (Real.sqrt (angularNormalization A)*lam) T + (a ∘ (angularFrequencyEquiv A hA).symm)) + (angularShiftPhase (phase ∘ (angularFrequencyEquiv A hA).symm) θ) x= + flatFourier s (normalizedFourierCoefficients s lam + (Real.sqrt (angularNormalization A)*T) a) phase + (angularNormalizedLift A (angularRealTranslation θ x)) := by + rw [flatFourier_angular_conjugacy s hA,flatFourier_angular_translation] + congr 1 + funext h + obtain ⟨g,rfl⟩ := (angularFrequencyEquiv A hA).surjective h + simpa only [Function.comp_apply,Equiv.symm_apply_apply] using + normalizedFourierCoefficients_angular_conjugacy s hA a lam T g + +theorem general_mode_ending_H1_scalarization {s : Fin 3 → ℝ} + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2) ≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + {h₀ : Fin 2 → ℤ} (hh₀ : h₀≠0) + {a b pa pb : (Fin 2 → ℤ) → ℝ} {A B ga gb : ℝ} + (hA : 0≤A) (hB : 0≤B) (ha : ∀ h,|a h|≤A) (hb : ∀ h,|b h|≤B) + (hga : 0 ⟨E y,hsym y⟩)) 2 (volume.restrict U)) + (z : voltageH1Jets volume U) (F : Lp FieldVector 2 (volume.restrict U)) (σ : Coord3 → ℝ), + Measurable σ ∧ MemLp σ ∞ (volume.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _)∈zeroVoltageJets volume U ∧ + (∀ᵐ x ∂volume.restrict U,σ x∈Icc (laminateLower c C) (laminateUpper C) ∧ + F x=σ x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets volume U,inner ℝ W.val.2 F=0) := by + obtain ⟨k,Q,hk,hQ,he⟩ := leading_frequency_SL2_alignment hh₀ + let m := Real.sqrt (angularNormalization Q) + have hm : 0 < m := Real.sqrt_pos.mpr (angularNormalization_pos Q) + let e := angularFrequencyEquiv Q hQ + let θ : Fin 2 → ℝ := ![0,-pb h₀/(k:ℝ)] + let a' : (Fin 2 → ℤ) → ℝ := fun h => a (e.symm h)/m + let b' : (Fin 2 → ℤ) → ℝ := b ∘ e.symm + let pa' := angularShiftPhase (pa ∘ e.symm) θ + let pb' := angularShiftPhase (pb ∘ e.symm) θ + have hphase : pb' ![0,k]=0 := by + have he0 : e.symm ![0,k]=h₀ := by + rw [←he] + exact e.symm_apply_apply h₀ + dsimp [pb',angularShiftPhase] + rw [he0] + exact alignedPhaseTranslation_zero hk (pb h₀) + have hmode (x : Coord3) : + flatPhaseMode s h₀ (pb h₀) (angularNormalizedLift Q (angularRealTranslation θ x))= + flatPhaseMode (normalizedAngularTensor s Q) ![0,k] 0 x := by + rw [flatPhaseMode_angular_conjugacy s hQ,he,flatPhaseMode_angular_translation] + rw [show pb h₀+((![0,k] : Fin 2 → ℤ) 0:ℝ)*θ 0+ + ((![0,k] : Fin 2 → ℤ) 1:ℝ)*θ 1=0 from alignedPhaseTranslation_zero hk (pb h₀)] + have hab : ∀ h,|a' h|≤A/m := by + intro h + dsimp [a'] + rw [abs_div,abs_of_pos hm] + exact (div_le_div_iff_of_pos_right hm).2 (ha _) + have hbb : ∀ h,|b' h|≤B := fun h => hb (e.symm h) + have hgapA := angular_conjugacy_gap s hQ (a:=a) (lam:=0) hga + (fun h hh => by simpa only [zero_add] using hra h hh) + have hgapB := angular_conjugacy_gap s hQ hgb hrb + have hrate : torusRate (normalizedAngularTensor s Q) ![0,k]=m*torusRate s h₀ := by + rw [←he,torusRate_angular_conjugacy s hQ] + have hra' : ∀ h,a' h≠0 → m*ga≤torusRate (normalizedAngularTensor s Q) h := by + intro h hh + have hh' : (a ∘ e.symm) h≠0 := by + intro hz + apply hh + dsimp [a'] + rw [show a (e.symm h)=0 from hz,zero_div] + simpa only [mul_zero,zero_add] using hgapA.2 h hh' + have hrb' : ∀ h,b' h≠0 → torusRate (normalizedAngularTensor s Q) ![0,k]+m*gb≤ + torusRate (normalizedAngularTensor s Q) h := by + intro h hh + rw [hrate] + exact hgapB.2 h hh + obtain ⟨p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,hvin,hEin,hterm,hscalar⟩ := + aligned_fourier_ending_H1_scalarization (pa:=pa') + (normalizedAngularTensor_lower hs hQ) hk (div_nonneg hA hm.le) hB hab hbb + (mul_pos hm hga) (mul_pos hm hgb) hra' hrb' hphase hδ + refine ⟨Q,θ,k,hQ,hk,he,p,T,c,C,hp,hpδ,hT,hc,hcC,v,E,hsym,hv,hEm,hvp,hEp,hbound,?_,hEin,hterm,hscalar⟩ + intro x hx + rw [hvin x hx,hmode] + congr 1 + · congr 1 + rw [normalizedFourierCoefficients_div,flatFourier_div_coefficients] + congr 1 + simpa only [pa',e,Function.comp_def,mul_zero] using normalized_flatFourier_angular_conjugacy s hQ a pa 0 (10+1/p) θ x + · rw [hrate] + congr 2 + simpa only [b',pb',m,e,Function.comp_apply] using normalized_flatFourier_angular_conjugacy s hQ b pb (torusRate s h₀) (10+1/p) θ x + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/LocalConstitution.lean b/lean/OAI/Analysis/Conductivity/Scalarization/LocalConstitution.lean new file mode 100644 index 0000000000000000000000000000000000000000..b85fca4f0f9cae9d6dbd1f55b973c47694f39bf1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/LocalConstitution.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.CascadeStageCurl +import OAI.Analysis.Conductivity.Variational.CrossingGradient + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Real Set Filter Topology MeasureTheory Matrix + +lemma direction_affineShift {f : Coord3 → ℝ} (hf : Differentiable ℝ f) + (s r : ℝ) (c d v x : Coord3) : + direction v (fun y => s*f (r • (y-c)-d)) x = s*r*direction v f (r • (x-c)-d) := by + have hT : Differentiable ℝ (fun y : Coord3 => f (y-d)) := hf.comp (differentiable_id.sub_const d) + rw [direction_dilation hT] + have hh := direction_dilation hf 1 1 d v (r • (x-c)) + simpa only [one_mul,one_smul] using congrArg (fun z => s*r*z) hh + +lemma potentialCurl_affineShift {S : Fin 3 → Fin 3 → Coord3 → ℝ} + (hS : ∀ i j, Differentiable ℝ (S i j)) (s r : ℝ) (c d x : Coord3) (i : Fin 3) : + potentialCurl (fun i j y => s*S i j (r • (y-c)-d)) x i = + s*r*potentialCurl S (r • (x-c)-d) i := by + simp only [potentialCurl,direction_affineShift (hS _ _),Finset.mul_sum] + +lemma local_scaled_constitution {V v : Coord3 → ℝ} + {T S : Fin 3 → Fin 3 → Coord3 → ℝ} + (hv : Differentiable ℝ v) (hS : ∀ i j, Differentiable ℝ (S i j)) + (s r : ℝ) (c d x : Coord3) (A : Matrix (Fin 3) (Fin 3) ℝ) + (hV : V =ᶠ[𝓝 x] fun y => s*v (r • (y-c)-d)) + (hT : ∀ i j, T i j =ᶠ[𝓝 x] fun y => s*S i j (r • (y-c)-d)) + (hc : A *ᵥ (fun i => direction (Pi.single i 1) v (r • (x-c)-d)) = + potentialCurl S (r • (x-c)-d)) : + A *ᵥ (fun i => direction (Pi.single i 1) V x) = potentialCurl T x := by + ext i + rw [potentialCurl_congr_nhds x hT i,potentialCurl_affineShift hS] + have hg (j : Fin 3) : direction (Pi.single j 1) V x = + (s*r)*direction (Pi.single j 1) v (r • (x-c)-d) := by + rw [direction_congr_nhds hV,direction_affineShift hv] + simp only [mulVec,dotProduct,hg] + calc + _ = s*r*∑ j, A i j*direction (Pi.single j 1) v (r • (x-c)-d) := by + rw [Finset.mul_sum]; apply Finset.sum_congr rfl; intro j _; ring + _ = _ := by rw [←hc]; rfl + +lemma cascadeValue_crossing {L K k : ℝ} (hL : 0 ring_nf + +lemma cascade_crossing_nhds {L K k : ℝ} (x : Coord3) (m : ℕ) + (hs₁ : K+2 < cascadePhase (cascadeLength L K) k m (x 0)) + (hs₂ : cascadePhase (cascadeLength L K) k m (x 0) < cascadeLength L K) : + {y : Coord3 | K+2 < cascadePhase (cascadeLength L K) k m (y 0) ∧ + cascadePhase (cascadeLength L K) k m (y 0) < cascadeLength L K} ∈ 𝓝 x := by + have hc : Continuous (fun y : Coord3 => cascadePhase (cascadeLength L K) k m (y 0)) := by + unfold cascadePhase + fun_prop + exact (hc.isOpen_preimage _ isOpen_Ioo).mem_nhds ⟨hs₁,hs₂⟩ + +theorem cascade_crossing_constitution {L K k : ℝ} (hL : 0 direction (Pi.single i 1) (cascadeValue L K k A) x) = + cascadeFlux L K k A x := by + apply local_scaled_constitution (crossingValue3_diff L _ _) (crossingPotential_diff L _ _) + ((A*cascadeRatio L K^m)*(connectorProfile K (K+2)*exp (-3*L))) (k*2^m) + (cascadeCenter (cascadeLength L K) k m) (Pi.single 0 (K+2+L)) x + · filter_upwards [cascade_crossing_nhds x m hs₁ hs₂] with y hy + exact cascadeValue_crossing hL hK hk A y m hy.1 hy.2 + · intro i j + filter_upwards [cascade_crossing_nhds x m hs₁ hs₂] with y hy + rw [cascadePotential_two_terms hL hK hk A y (m := m) (by linarith [hy.1]) (by linarith [hy.2])] + exact cascadePotentialTerm_crossing_pair hL hK hk A y m hy.1 hy.2 i j + · exact crossingTensor_constitution hL (cascadeAxis_ne_zero m) + (cascadeAxis_ne_zero (m+1)) (cascadeAxis_ne_succ m) _ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/OriginalScalarizationCauchy.lean b/lean/OAI/Analysis/Conductivity/Scalarization/OriginalScalarizationCauchy.lean new file mode 100644 index 0000000000000000000000000000000000000000..5c83efd2f1a3e3248b1974624007ebc4059c9c00 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/OriginalScalarizationCauchy.lean @@ -0,0 +1,39 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.OriginalH1VoltageRestriction + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal Classical + +lemma originalVoltageJetCLM_pairing {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (u : H1) (j : Fin 2) + (F : Lp FieldVector 2 (volume.restrict U)) : + inner ℝ (originalVoltageJetCLM U j u.val).2 F= + ∫ x,∑ i,weakGradient u (WithLp.toLp 2 x) i*F x (i,j) ∂volume.restrict U := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [(originalVoltageJetCLM_ae U hU hUb j u.val).2] with x hx + rw [hx] + simp [PiLp.inner_apply,RCLike.inner_apply,Fintype.sum_prod_type,weakGradient,mul_comm] + +theorem scalarization_original_weak_gradient_cauchy {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) + {F G : Lp FieldVector 2 (volume.restrict U)} + (hF : ∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 G) + (u : H1) (j : Fin 2) : + (∫ x,∑ i,weakGradient u (WithLp.toLp 2 x) i*F x (i,j) ∂volume.restrict U)= + (∫ x,∑ i,weakGradient u (WithLp.toLp 2 x) i*G x (i,j) ∂volume.restrict U) := by + rw [←originalVoltageJetCLM_pairing hU hUb u j F,←originalVoltageJetCLM_pairing hU hUb u j G] + exact scalarization_original_H1_test_bridge hU hUb hbounded hF u j + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/PhysicalScalarization.lean b/lean/OAI/Analysis/Conductivity/Scalarization/PhysicalScalarization.lean new file mode 100644 index 0000000000000000000000000000000000000000..c01d29f89a0b6987682e430236128443de71b0ec --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/PhysicalScalarization.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.OriginalScalarizationCauchy +import OAI.Analysis.Conductivity.Variational.PhysicalOpenVoltage + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise ENNReal + +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +theorem scalar_pair_green_exists + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) : + ∃ (σ : Coord3 → ℝ) (c C : ℝ) (w q : Fin 2 → H1), + Measurable σ ∧ MemLp σ ∞ (volume.restrict physicalOpenBlock) ∧ + 0 weakValue (w j) (WithLp.toLp 2 y) := by + filter_upwards [hv] with y hy hyU + exact hy (physicalOpenBlock_subset hyU) + have hd' : ∀ᵐ y : Coord3,y∈physicalOpenBlock → ∀ i : Fin 3,∀ j : Fin 2, + fderiv ℝ (fun x => v x j) y (Pi.single i 1)=weakGradient (w j) (WithLp.toLp 2 y) i := by + filter_upwards [hd] with y hy hyU + exact hy (physicalOpenBlock_subset hyU) + have hr' := regularRegion_conull_open_restrict physicalOpenBlock_open physicalOpenBlock_subset hr + obtain ⟨hu,hE,hjet,hH1⟩ := original_pair_voltageH1 physicalOpenBlock_open.measurableSet + (fun _ => physicalOpenBlock_subset_ball) physicalOpenBlock_bounded w v (z.cartesianTensor hs) hv' hd' hr' + have hg := voltageGradient_original_ae physicalOpenBlock_open.measurableSet hd' hr' + have hF := voltageFlux_memLp v (z.cartesianTensor hs) hE + (z.cartesianTensor_entry_memLp hs physicalOpenBlock) + obtain ⟨l,L,hl,hlL,hb⟩ := z.cartesianTensor_dot_elliptic hs + obtain ⟨Z,F,σ,hσm,hσL,hzero,hσ,hcau,_⟩ := finite_field_scalarization volume hl hlL.le + physicalOpenBlock_bounded physicalOpenBlock_open.measurableSet v (z.cartesianTensor hs) + (z.cartesianTensor_measurable hs) hu hE hF hH1 (smoothFluxIntegrable_of_L2 v _ hF) + (fun j ψ hψ _ hψs => z.corrected_voltage_divergence hs w hc he v hg j hψ hψs) + hr' (Filter.Eventually.of_forall (fun y _ => hb y)) + rw [hjet] at hzero + obtain ⟨q,hq,hqjet,hqv,hqg⟩ := original_pair_zeroVoltage_extension physicalOpenBlock_open.measurableSet + (fun _ => physicalOpenBlock_subset_ball) w hw Z.val hzero + refine ⟨σ,laminateLower l L,laminateUpper L,w,q,hσm,hσL, + (uniform_laminate_coverage hl hlL.le).1,(uniform_laminate_coverage hl hlL.le).2.1, + hσ.mono (fun _ h => h.1),hq,hc,he,⟨Z.val,hzero,hqjet⟩,?_⟩ + intro j h + have hcc := scalarization_original_weak_gradient_cauchy physicalOpenBlock_open.measurableSet + (fun _ => physicalOpenBlock_subset_ball) physicalOpenBlock_bounded hcau h j + have hlhs : (∫ y,∑ i,weakGradient h (WithLp.toLp 2 y) i*F y (i,j) ∂volume.restrict physicalOpenBlock)= + ∫ y in physicalOpenBlock,σ y*(originalPiGradient (q j) y ⬝ᵥ originalPiGradient h y) := by + apply integral_congr_ae + filter_upwards [hσ,hqg] with y hσ hqg + rw [hσ.2] + simp only [PiLp.smul_apply,smul_eq_mul,hqg,dotProduct,Finset.mul_sum,originalPiGradient] + apply Finset.sum_congr rfl + intro i _ + ring + have hrhs : (∫ y,∑ i,weakGradient h (WithLp.toLp 2 y) i*(hF.toLp _) y (i,j) ∂volume.restrict physicalOpenBlock)= + ∫ y in physicalOpenBlock,originalPiGradient (w j) y ⬝ᵥ + (variableBlockTensor z.flatTensor z.compression y*ᵥoriginalPiGradient h y) := by + apply integral_congr_ae + filter_upwards [hF.coeFn_toLp,hg] with y hF hg + rw [hF] + simp_rw [voltageFlux_component,hg] + change originalPiGradient h y ⬝ᵥ((z.cartesianTensor hs y).val*ᵥoriginalPiGradient (w j) y)=_ + have hsym : (z.cartesianTensor hs y).valᵀ=(z.cartesianTensor hs y).val := (z.cartesianTensor hs y).property + have hh := Matrix.dotProduct_transpose_mulVec (z.cartesianTensor hs y).val + (originalPiGradient h y) (originalPiGradient (w j) y) + rw [hsym] at hh + exact hh + rw [hlhs,hrhs] at hcc + exact hcc.trans (by simpa only [physicalOpenBlock,physicalBlockRegion_openBlock_restrict] using hgreen j h) + +end PhysicalFiniteEndingData +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationLpStrongClosed.lean b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationLpStrongClosed.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7396058911fa058c94252e5dd9b199678b9b533 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationLpStrongClosed.lean @@ -0,0 +1,46 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.ScalarRelationStrongClosed + +namespace OAI + +section +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity +open Filter Topology Set TopologicalSpace + +theorem scalar_relation_Lp_strong_closed + {X V : Type*} [MeasurableSpace X] {μ : Measure X} + [NormedAddCommGroup V] [InnerProductSpace ℝ V] + [MeasurableSpace V] [BorelSpace V] [SecondCountableTopology V] + {a b : ℝ} (hab : a ≤ b) + {E F : Lp V 2 μ} {En Fn : ℕ → Lp V 2 μ} {sn : ℕ → X → ℝ} + (hs : ∀ n, ∀ᵐ x ∂μ, sn n x ∈ Set.Icc a b) + (hE : Tendsto En atTop (𝓝 E)) (hF : Tendsto Fn atTop (𝓝 F)) + (hres : TendstoInMeasure μ (fun n x => Fn n x - sn n x • En n x) + atTop (fun _ => 0)) : + ∃ s : X → ℝ, Measurable s ∧ + (∀ᵐ x ∂μ, s x ∈ Set.Icc a b ∧ F x = s x • E x) := by + obtain ⟨φ, hφ, hElim⟩ := + (tendstoInMeasure_of_tendsto_Lp hE).exists_seq_tendsto_ae + obtain ⟨ψ, hψ, hFlim⟩ := + ((tendstoInMeasure_of_tendsto_Lp hF).comp hφ.tendsto_atTop).exists_seq_tendsto_ae + obtain ⟨ξ, hξ, hrlim⟩ := + ((hres.comp hφ.tendsto_atTop).comp hψ.tendsto_atTop).exists_seq_tendsto_ae + apply scalar_relation_ae_strong_closed hab (Lp.stronglyMeasurable E).measurable + (Lp.stronglyMeasurable F).measurable (En := fun n => En (φ (ψ (ξ n)))) + (Fn := fun n => Fn (φ (ψ (ξ n)))) (sn := fun n => sn (φ (ψ (ξ n)))) + · exact fun n => hs _ + · filter_upwards [hElim] with x hx + exact (hx.comp hψ.tendsto_atTop).comp hξ.tendsto_atTop + · filter_upwards [hFlim] with x hx + exact hx.comp hξ.tendsto_atTop + · exact hrlim + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationStrongClosed.lean b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationStrongClosed.lean new file mode 100644 index 0000000000000000000000000000000000000000..d6b99862cadaae4d796566ea94ef730370968b5c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarRelationStrongClosed.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +section + +noncomputable section +open MeasureTheory +open scoped ENNReal + +namespace ScalarConductivity + +end ScalarConductivity + +namespace ScalarConductivity +open Filter Topology + +theorem scalar_relation_strong_closed + {V : Type*} [NormedAddCommGroup V] [NormedSpace ℝ V] + {a b : ℝ} {E F : V} {En Fn : ℕ → V} {sn : ℕ → ℝ} + (hs : ∀ n, sn n ∈ Set.Icc a b) + (hE : Tendsto En atTop (𝓝 E)) (hF : Tendsto Fn atTop (𝓝 F)) + (hres : Tendsto (fun n => Fn n - sn n • En n) atTop (𝓝 0)) : + ∃ s ∈ Set.Icc a b, F = s • E := by + obtain ⟨s, hs', φ, hφ, hlim⟩ := + tendsto_subseq_of_bounded (Metric.isBounded_Icc a b) hs + have hsmem : s ∈ Set.Icc a b := by + simpa only [isClosed_Icc.closure_eq] using hs' + refine ⟨s, hsmem, ?_⟩ + have hlim' : Tendsto (fun n => Fn (φ n) - sn (φ n) • En (φ n)) + atTop (𝓝 (F - s • E)) := + (hF.comp hφ.tendsto_atTop).sub (hlim.smul (hE.comp hφ.tendsto_atTop)) + have hz : F - s • E = 0 := + tendsto_nhds_unique hlim' (hres.comp hφ.tendsto_atTop) + exact sub_eq_zero.mp hz + +end ScalarConductivity + +namespace ScalarConductivity +open Filter Topology + +def commonScalar {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] + (a : ℝ) (E F : V) : ℝ := by + classical + exact if E = 0 then a else inner ℝ E F / ‖E‖ ^ 2 + +theorem commonScalar_of_relation {V : Type*} [NormedAddCommGroup V] + [InnerProductSpace ℝ V] {a b s : ℝ} {E F : V} + (hab : a ≤ b) (hs : s ∈ Set.Icc a b) (hF : F = s • E) : + commonScalar a E F ∈ Set.Icc a b ∧ F = commonScalar a E F • E := by + subst F + by_cases hE : E = 0 + · simp [commonScalar, hE, hab] + · have hn : ‖E‖ ^ 2 ≠ 0 := pow_ne_zero _ (norm_ne_zero_iff.mpr hE) + have hval : commonScalar a E (s • E) = s := by + simp only [commonScalar, ite_eq_right hE, inner_smul_right, real_inner_self_eq_norm_sq] + exact mul_div_cancel_right₀ s hn + simpa only [hval, and_true] using hs + +theorem measurable_commonScalar + {X V : Type*} [MeasurableSpace X] [NormedAddCommGroup V] + [InnerProductSpace ℝ V] [MeasurableSpace V] [BorelSpace V] + [SecondCountableTopology V] {E F : X → V} (a : ℝ) + (hE : Measurable E) (hF : Measurable F) : + Measurable (fun x => commonScalar a (E x) (F x)) := by + classical + exact Measurable.ite (measurableSet_eq_fun hE measurable_const) measurable_const + ((hE.inner hF).div (hE.norm.pow_const 2)) + +theorem scalar_relation_ae_strong_closed + {X V : Type*} [MeasurableSpace X] {μ : Measure X} + [NormedAddCommGroup V] [InnerProductSpace ℝ V] + [MeasurableSpace V] [BorelSpace V] [SecondCountableTopology V] + {a b : ℝ} (hab : a ≤ b) {E F : X → V} + (hEm : Measurable E) (hFm : Measurable F) + {En Fn : ℕ → X → V} {sn : ℕ → X → ℝ} + (hs : ∀ n, ∀ᵐ x ∂μ, sn n x ∈ Set.Icc a b) + (hE : ∀ᵐ x ∂μ, Tendsto (fun n => En n x) atTop (𝓝 (E x))) + (hF : ∀ᵐ x ∂μ, Tendsto (fun n => Fn n x) atTop (𝓝 (F x))) + (hres : ∀ᵐ x ∂μ, + Tendsto (fun n => Fn n x - sn n x • En n x) atTop (𝓝 0)) : + ∃ s : X → ℝ, Measurable s ∧ + (∀ᵐ x ∂μ, s x ∈ Set.Icc a b ∧ F x = s x • E x) := by + refine ⟨fun x => commonScalar a (E x) (F x), + measurable_commonScalar a hEm hFm, ?_⟩ + filter_upwards [ae_all_iff.mpr hs, hE, hF, hres] with x hsx hEx hFx hrx + obtain ⟨s, hs', hrel⟩ := scalar_relation_strong_closed hsx hEx hFx hrx + exact commonScalar_of_relation hab hs' hrel + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/ScalarizationAffineLimit.lean b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarizationAffineLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..5a7fded85d6a74814ff81b8169fd382638dc159b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/ScalarizationAffineLimit.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.DenseClosureApprox +import OAI.Analysis.Conductivity.Sobolev.VoltageJetCompletion +import OAI.Analysis.Conductivity.Variational.AffineWeakConstraints +import OAI.Analysis.Conductivity.Flux.VoltageFluxConstraints + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology TopologicalSpace +open scoped ENNReal + +lemma CompactGlobalUpdate.gradientCorrection_mem_range + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + (R.memLp_gradient_correction μ).toLp _ ∈ (zeroVoltageGradientMap μ U).range := by + let hv : MemLp R.du 2 (μ.restrict U) := + (R.smooth_du.continuous.memLp_of_hasCompactSupport R.compact_du).restrict U + let z : VoltageJetSpace μ U := (hv.toLp _,(R.memLp_gradient_correction μ).toLp _) + have hz : z ∈ compactVoltageJetModule μ U := + ⟨R.du,R.smooth_du,R.compact_du,R.support_du,hv,R.memLp_gradient_correction μ,rfl⟩ + exact ⟨⟨z,(compactVoltageJetModule μ U).le_topologicalClosure hz⟩,rfl⟩ + +lemma finiteUpdateClosure_affine_constraints + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUb : Bornology.IsBounded U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) {a b : ℝ} + {Z : Lp FieldVector 2 (μ.restrict U) × Lp FieldVector 2 (μ.restrict U)} + (hZ : toWeakSpace ℝ _ Z ∈ closure (toWeakSpace ℝ _ '' finiteUpdatePairs μ U u A hE hF a b)) : + (∃ v : zeroVoltageJets μ U, Z.1 = hE.toLp _ + v.val.2) ∧ + Z.2-hF.toLp _ ∈ (allVoltageGradients μ U)ᗮ := by + constructor + · have hg := submodule_constraint_of_mem_weak_closure + (zeroVoltageGradientMap μ U).range (zeroVoltageGradientMap_closed_range μ hUb) + (ContinuousLinearMap.fst ℝ _ _) (hE.toLp _) + (S := finiteUpdatePairs μ U u A hE hF a b) (z := Z) ?_ hZ + · obtain ⟨v,hv⟩ := hg + refine ⟨v,?_⟩ + change v.val.2 = Z.1 - hE.toLp _ at hv + rw [hv,add_sub_cancel] + · rintro _ ⟨R,hreg,hgraph,rfl⟩ + change hE.toLp _ + (R.memLp_gradient_correction μ).toLp _ - hE.toLp _ ∈ _ + rw [add_sub_cancel_left] + exact R.gradientCorrection_mem_range μ + · apply submodule_constraint_of_mem_weak_closure + ((allVoltageGradients μ U)ᗮ) (Submodule.isClosed_orthogonal _) + (ContinuousLinearMap.snd ℝ _ _) (hF.toLp _) (S := finiteUpdatePairs μ U u A hE hF a b) ?_ hZ + rintro _ ⟨R,hreg,hgraph,rfl⟩ + change hF.toLp _ + (R.memLp_flux_correction μ).toLp _ - hF.toLp _ ∈ _ + rw [add_sub_cancel_left] + exact R.fluxCorrection_mem_orthogonal μ + +theorem exact_scalarization_Cauchy_flux + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + [SeparableSpace (Lp FieldVector 2 (μ.restrict U))] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) : + ∃ (v : zeroVoltageJets μ U) (F : Lp FieldVector 2 (μ.restrict U)) (s : Coord3 → ℝ), + Measurable s ∧ + (∀ᵐ x ∂μ.restrict U, s x ∈ Icc a b ∧ F x = s x • ((hE.toLp _ + v.val.2) x)) ∧ + (∀ W ∈ allVoltageGradients μ U, inner ℝ W F = inner ℝ W (hF.toLp _)) := by + obtain ⟨Z,s,hZ,hsm,hs⟩ := exact_scalar_in_finiteUpdateClosure μ ha hab hUb hUm u A hAm + hE hF hint hdiv hreg hgraph + obtain ⟨⟨v,hv⟩,hFv⟩ := finiteUpdateClosure_affine_constraints μ hUb hE hF hZ + refine ⟨v,Z.2,s,hsm,?_,?_⟩ + · simpa only [hv] using hs + · intro W hW + have he := (Submodule.mem_orthogonal _ _).mp hFv W hW + rw [inner_sub_right] at he + exact sub_eq_zero.mp he + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/SmoothScalarAlgebra.lean b/lean/OAI/Analysis/Conductivity/Scalarization/SmoothScalarAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..339865e415e0e603572aad4fa542230a9846763e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/SmoothScalarAlgebra.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity +open scoped ContDiff + +def smoothScalarAlgebra (E : Type*) [NormedAddCommGroup E] [NormedSpace ℝ E] : + Subalgebra ℝ (E → ℝ) where + carrier := {f | ContDiff ℝ (↑(⊤ : ℕ∞)) f} + algebraMap_mem' r := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun _ : E => r) + exact contDiff_const + zero_mem' := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun _ : E => 0) + exact contDiff_const + one_mem' := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun _ : E => 1) + exact contDiff_const + add_mem' hf hg := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) _ at hf hg ⊢ + exact hf.add hg + mul_mem' hf hg := by + change ContDiff ℝ (↑(⊤ : ℕ∞)) _ at hf hg ⊢ + exact hf.mul hg + +abbrev SmoothScalar (E : Type*) [NormedAddCommGroup E] [NormedSpace ℝ E] := + smoothScalarAlgebra E + +theorem smoothScalar_contDiff {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (f : SmoothScalar E) : ContDiff ℝ (↑(⊤ : ℕ∞)) f.val := by + exact f.property + +def smoothDirection {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (v : E) : SmoothScalar E →ₗ[ℝ] SmoothScalar E where + toFun f := ⟨fun x => fderiv ℝ f.val x v, by + change ContDiff ℝ (↑(⊤ : ℕ∞)) _ + exact ((smoothScalar_contDiff f).fderiv_right + (m := ↑(⊤ : ℕ∞)) (by simp)).clm_apply contDiff_const⟩ + map_add' f g := by + apply Subtype.ext + funext x + change fderiv ℝ (f.val + g.val) x v = fderiv ℝ f.val x v + fderiv ℝ g.val x v + rw [fderiv_add ((smoothScalar_contDiff f).differentiable (by simp) x) + ((smoothScalar_contDiff g).differentiable (by simp) x)] + rfl + map_smul' c f := by + apply Subtype.ext + funext x + change fderiv ℝ (c • f.val) x v = c • fderiv ℝ f.val x v + rw [fderiv_const_smul ((smoothScalar_contDiff f).differentiable (by simp) x)] + rfl + +@[simp] theorem smoothDirection_apply {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] (v : E) (f : SmoothScalar E) (x : E) : + (smoothDirection v f).val x = fderiv ℝ f.val x v := rfl + +theorem smoothDirection_comm {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] (v w : E) (f : SmoothScalar E) : + smoothDirection v (smoothDirection w f) = + smoothDirection w (smoothDirection v f) := by + apply Subtype.ext + funext x + change fderiv ℝ (fun y => fderiv ℝ f.val y w) x v = + fderiv ℝ (fun y => fderiv ℝ f.val y v) x w + have hd : DifferentiableAt ℝ (fderiv ℝ f.val) x := + ((smoothScalar_contDiff f).fderiv_right (m := ↑(⊤ : ℕ∞)) (by simp)).differentiable (by simp) x + rw [fderiv_clm_apply hd (differentiableAt_const w), + fderiv_clm_apply hd (differentiableAt_const v)] + simpa using ((smoothScalar_contDiff f).contDiffAt.isSymmSndFDerivAt (by simp) v w) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/UniformMatrixScalarization.lean b/lean/OAI/Analysis/Conductivity/Scalarization/UniformMatrixScalarization.lean new file mode 100644 index 0000000000000000000000000000000000000000..8abb72eec49686c147130a962f21cf51bd48d3d4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/UniformMatrixScalarization.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.VoltageH1Completion + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology TopologicalSpace Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +lemma uniform_matrix_laminate_coverage {c C : ℝ} (hc : 0 < c) (hcC : c ≤ C) + (A : Symmetric3) + (hA : ∀ v : Coord3, c * (v ⬝ᵥ v) ≤ v ⬝ᵥ (A.val *ᵥ v) ∧ + v ⬝ᵥ (A.val *ᵥ v) ≤ C * (v ⬝ᵥ v)) : + A ∈ matrixFiniteLaminate (laminateLower c C) (laminateUpper C) := by + obtain ⟨Q,hQ,α,he⟩ := exists_orthogonal_diagonalization A.property + refine ⟨Q,hQ,α,(uniform_laminate_coverage hc hcC).2.2 α ?_,he⟩ + intro i + let v : Coord3 := Pi.single i 1 + have hnorm : (Q *ᵥ v) ⬝ᵥ (Q *ᵥ v) = 1 := by + rw [orthogonal_dotProduct hQ] + simp [v,dotProduct,Pi.single_apply] + have hback : Qᵀ *ᵥ (Q *ᵥ v) = v := by + rw [mulVec_mulVec,hQ.1,one_mulVec] + have hval : (Q *ᵥ v) ⬝ᵥ (A.val *ᵥ (Q *ᵥ v)) = α i := by + rw [he,conjugateDiagonal_quadratic,hback] + simp [v,Pi.single_apply] + simpa only [hnorm,hval,mul_one] using hA (Q *ᵥ v) + +theorem finite_field_scalarization + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {c C : ℝ} (hc : 0 < c) (hcC : c ≤ C) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + [SeparableSpace (Lp FieldVector 2 (μ.restrict U))] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hu : MemLp u 2 (μ.restrict U)) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (huH1 : (hu.toLp _,hE.toLp _) ∈ voltageH1Jets μ U) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hbound : ∀ᵐ x ∂μ, x ∈ U → ∀ v : Coord3, + c * (v ⬝ᵥ v) ≤ v ⬝ᵥ ((A x).val *ᵥ v) ∧ + v ⬝ᵥ ((A x).val *ᵥ v) ≤ C * (v ⬝ᵥ v)) : + ∃ (z : voltageH1Jets μ U) (F : Lp FieldVector 2 (μ.restrict U)) (s : Coord3 → ℝ), + Measurable s ∧ MemLp s ∞ (μ.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _) ∈ zeroVoltageJets μ U ∧ + (∀ᵐ x ∂μ.restrict U, s x ∈ Icc (laminateLower c C) (laminateUpper C) ∧ + F x = s x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets μ U, inner ℝ W.val.2 F = inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets μ U, inner ℝ W.val.2 F = 0) := by + apply exact_scalarization_H1 μ (uniform_laminate_coverage hc hcC).1 + (uniform_laminate_coverage hc hcC).2.1 hUb hUm u A hAm hu hE hF huH1 hint hdiv hreg + filter_upwards [hbound] with x hx hxU + exact uniform_matrix_laminate_coverage hc hcC (A x) (hx hxU) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/UpdateFieldPair.lean b/lean/OAI/Analysis/Conductivity/Scalarization/UpdateFieldPair.lean new file mode 100644 index 0000000000000000000000000000000000000000..027f76dab5169bb88a48053a04f941970e365ed1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/UpdateFieldPair.lean @@ -0,0 +1,171 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CompactUpdateLp + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology + +def CompactGlobalUpdate.fieldPair + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) : + Lp FieldVector 2 (μ.restrict U) × Lp FieldVector 2 (μ.restrict U) := + (hE.toLp _ + (R.memLp_gradient_correction μ).toLp _, + hF.toLp _ + (R.memLp_flux_correction μ).toLp _) + +lemma CompactGlobalUpdate.fieldPair_eq + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) (hreg : μ (U \ regularRegion u A U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hE' : MemLp (voltageGradient (fun x => u x+R.du x)) 2 (μ.restrict U)) + (hF' : MemLp (voltageFlux (fun x => u x+R.du x) R.tensor) 2 (μ.restrict U)) : + R.fieldPair μ hE hF = (hE'.toLp _,hF'.toLp _) := by + exact Prod.ext (R.gradient_toLp_eq μ hUm hreg hE hE').symm + (R.flux_toLp_eq μ hF hF').symm + +lemma CompactGlobalUpdate.fieldPair_ae + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) (hreg : μ (U \ regularRegion u A U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) : + ∀ᵐ x ∂μ.restrict U, + (R.fieldPair μ hE hF).1 x = voltageGradient (fun y => u y+R.du y) x ∧ + (R.fieldPair μ hE hF).2 x = voltageFlux (fun y => u y+R.du y) R.tensor x := by + obtain ⟨hE',hF'⟩ := R.fields_memLp μ hUm hreg hE hF + rw [R.fieldPair_eq μ hUm hreg hE hF hE' hF'] + exact hE'.coeFn_toLp.and hF'.coeFn_toLp + +lemma CompactGlobalUpdate.fieldPair_energy_bound + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) (hreg : μ (U \ regularRegion u A U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + {a b : ℝ} (ha : 0 < a) (hab : a < b) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → R.tensor x ∈ matrixFiniteLaminate a b) : + ‖(R.fieldPair μ hE hF).1‖ ≤ (b/a)*‖hE.toLp _‖ ∧ + ‖(R.fieldPair μ hE hF).2‖ ≤ (b^2/a)*‖hE.toLp _‖ := by + obtain ⟨hE',hF'⟩ := R.fields_memLp μ hUm hreg hE hF + rw [R.fieldPair_eq μ hUm hreg hE hF hE' hF'] + exact R.Lp_energy_bound μ hUm hreg hE hE' hF' hint hdiv ha hab hgraph + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Matrix Set MeasureTheory +open scoped Matrix.Norms.Elementwise + +lemma diagonal_conjugate_smul_sub {Q : Mat3} (hQ : Q ∈ orthogonalFrames) + (d : DiagonalTriple) (s : ℝ) : + Q * diagonal d * Qᵀ - s • (1 : Mat3) = Q * diagonal (d - fun _ => s) * Qᵀ := by + change Q * diagonal d * Qᵀ - s • (1 : Mat3) = Q * diagonal (fun i => d i - s) * Qᵀ + rw [← diagonal_sub, Matrix.mul_sub, Matrix.sub_mul] + have he : diagonal (fun _ : Fin 3 => s) = s • (1 : Mat3) := by + ext i j + change (if i = j then s else 0) = s * (if i = j then 1 else 0) + split_ifs <;> simp + rw [he, Matrix.mul_smul, Matrix.smul_mul, Matrix.mul_one, hQ.2] + +lemma diagonal_conjugate_dot_bound {Q : Mat3} (hQ : Q ∈ orthogonalFrames) + {d : DiagonalTriple} {c : ℝ} (hc : 0 ≤ c) (hd : ∀ i, |d i| ≤ c) (v : Coord3) : + ((Q * diagonal d * Qᵀ) *ᵥ v) ⬝ᵥ ((Q * diagonal d * Qᵀ) *ᵥ v) ≤ + c^2 * (v ⬝ᵥ v) := by + rw [← mulVec_mulVec,← mulVec_mulVec,orthogonal_dotProduct hQ] + have hv := orthogonal_dotProduct (Q := Qᵀ) ⟨by simpa using hQ.2,by simpa using hQ.1⟩ v v + rw [← hv] + simp only [dotProduct,mulVec_diagonal,Finset.mul_sum] + apply Finset.sum_le_sum + intro i _ + have hs : (d i)^2 ≤ c^2 := by + simpa only [sq_abs] using (sq_le_sq₀ (abs_nonneg _) hc).mpr (hd i) + nlinarith [mul_le_mul_of_nonneg_right hs (sq_nonneg ((Qᵀ *ᵥ v) i))] + +lemma diagonal_conjugate_field_bound {Q : Mat3} (hQ : Q ∈ orthogonalFrames) + {d : DiagonalTriple} {c : ℝ} (hc : 0 ≤ c) (hd : ∀ i, |d i| ≤ c) + (E : Matrix (Fin 3) (Fin 2) ℝ) : + ‖fieldVector ((Q * diagonal d * Qᵀ)*E)‖ ≤ c * ‖fieldVector E‖ := by + have hs : ‖fieldVector ((Q * diagonal d * Qᵀ)*E)‖^2 ≤ c^2 * ‖fieldVector E‖^2 := by + rw [← real_inner_self_eq_norm_sq,← real_inner_self_eq_norm_sq,fieldVector_inner,fieldVector_inner] + change (∑ j, ((Q * diagonal d * Qᵀ) *ᵥ E.col j) ⬝ᵥ ((Q * diagonal d * Qᵀ) *ᵥ E.col j)) ≤ + c^2 * (∑ j, E.col j ⬝ᵥ E.col j) + rw [Finset.mul_sum] + exact Finset.sum_le_sum fun j _ => diagonal_conjugate_dot_bound hQ hc hd (E.col j) + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hc (norm_nonneg _))).mp + simpa only [mul_pow] using hs + +lemma matrixFiniteLaminate_diagonal_bounds {a b : ℝ} (ha : 0 < a) + {A : Symmetric3} (hA : A ∈ matrixFiniteLaminate a b) (i : Fin 3) : + A.val i i ∈ Icc a b := by + have h := matrixFiniteLaminate_quadratic_bounds ha hA (Pi.single i 1) + simpa [dotProduct, Matrix.mulVec, Pi.single_apply] using h + +lemma scalarNeighbourhood_defect_bound {a b η : ℝ} (hη : 0 ≤ η) + {A : Symmetric3} (hA : A ∈ spectralExtension (scalarNeighbourhood a b η)) + (E : Matrix (Fin 3) (Fin 2) ℝ) : + ‖fieldVector (A.val*E) - (A.val 0 0) • fieldVector E‖ ≤ (2*η) * ‖fieldVector E‖ := by + obtain ⟨Q,hQ,d,⟨hd,s,hs⟩,he⟩ := hA + have hds : ∀ i, |d i - s| ≤ η := by + intro i + exact (norm_le_pi_norm (d - fun _ => s) i).trans hs.le + have hshift : A.val - s • (1 : Mat3) = Q * diagonal (d - fun _ => s) * Qᵀ := by + rw [he] + exact diagonal_conjugate_smul_sub hQ d s + have hnorm : ∀ F : Matrix (Fin 3) (Fin 2) ℝ, + ‖fieldVector (A.val*F) - s • fieldVector F‖ ≤ η * ‖fieldVector F‖ := by + intro F + have hb := diagonal_conjugate_field_bound (d := d - fun _ => s) hQ hη hds F + rw [← hshift, Matrix.sub_mul, Matrix.smul_mul, Matrix.one_mul] at hb + exact hb + have hssq : |A.val 0 0 - s| ≤ η := by + have hb := diagonal_conjugate_dot_bound (d := d - fun _ => s) hQ hη hds (Pi.single 0 1) + rw [← hshift] at hb + have hl : (A.val 0 0 - s)^2 ≤ + ((A.val - s • (1 : Mat3)) *ᵥ Pi.single 0 1) ⬝ᵥ + ((A.val - s • (1 : Mat3)) *ᵥ Pi.single 0 1) := by + have he0 : ((A.val - s • (1 : Mat3)) *ᵥ Pi.single 0 1) 0 = A.val 0 0 - s := by + simp [Matrix.mulVec, dotProduct, Pi.single_apply] + rw [← he0] + simpa only [dotProduct,pow_two] using + Finset.single_le_sum (fun i _ => mul_self_nonneg (((A.val - s • (1 : Mat3)) *ᵥ Pi.single 0 1) i)) + (Finset.mem_univ (0 : Fin 3)) + have hr : (A.val 0 0 - s)^2 ≤ η^2 := hl.trans (by simpa [dotProduct, Pi.single_apply] using hb) + exact (sq_le_sq₀ (abs_nonneg _) hη).mp (by simpa only [sq_abs] using hr) + have hsplit : fieldVector (A.val*E) - A.val 0 0 • fieldVector E = + (fieldVector (A.val*E) - s • fieldVector E) + (s-A.val 0 0) • fieldVector E := by + rw [sub_smul] + abel + rw [hsplit] + calc + _ ≤ ‖fieldVector (A.val*E) - s • fieldVector E‖ + ‖(s-A.val 0 0) • fieldVector E‖ := norm_add_le _ _ + _ ≤ η * ‖fieldVector E‖ + η * ‖fieldVector E‖ := add_le_add (hnorm E) (by + rw [norm_smul,Real.norm_eq_abs,abs_sub_comm] + exact mul_le_mul_of_nonneg_right hssq (norm_nonneg _)) + _ = _ := by ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/WeakCellFast.lean b/lean/OAI/Analysis/Conductivity/Scalarization/WeakCellFast.lean new file mode 100644 index 0000000000000000000000000000000000000000..001c15e647123980557036e72b46c8ef4859ff1e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/WeakCellFast.lean @@ -0,0 +1,234 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +section +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal + +lemma integral_norm_le_L2_const + {X V : Type*} [MeasurableSpace X] [NormedAddCommGroup V] + (μ : Measure X) [IsFiniteMeasure μ] {f : X → V} (hf : MemLp f 2 μ) : + (∫ x, ‖f x‖ ∂μ) ≤ ‖(memLp_const (p := 2) (μ := μ) (1 : ℝ)).toLp _‖ * ‖hf.toLp _‖ := by + let oneLp := (memLp_const (p := 2) (μ := μ) (1 : ℝ)).toLp _ + let nLp := hf.norm.toLp _ + have heq : (∫ x, ‖f x‖ ∂μ) = inner ℝ oneLp nLp := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [(memLp_const (p := 2) (μ := μ) (1 : ℝ)).coeFn_toLp,hf.norm.coeFn_toLp] with x hx hy + change ‖f x‖ = inner ℝ (oneLp x) (nLp x) + rw [hx,hy,real_inner_comm] + simp + rw [heq] + calc + _ ≤ |inner ℝ oneLp nLp| := le_abs_self _ + _ ≤ ‖oneLp‖ * ‖nLp‖ := abs_real_inner_le_norm _ _ + _ = _ := by + rw [show ‖nLp‖ = ‖hf.toLp _‖ by + simp only [nLp, Lp.norm_toLp, eLpNorm_norm f hf.aestronglyMeasurable]] + +lemma compact_inner_right + {X V : Type*} [TopologicalSpace X] [NormedAddCommGroup V] [InnerProductSpace ℝ V] + {f : X → V} (hc : HasCompactSupport f) (φ : X → V) : + HasCompactSupport (fun x => inner ℝ (φ x) (f x)) := by + apply hc.mono + intro x hx hn + exact hx (by change inner ℝ (φ x) (f x) = 0; rw [hn,inner_zero_right]) + +lemma vector_pairing_bound_of_zero_mean + {X V : Type*} [TopologicalSpace X] [MeasurableSpace X] [BorelSpace X] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (μ : Measure X) [IsFiniteMeasureOnCompacts μ] + (f φ : X → V) (hf : Continuous f) (hc : HasCompactSupport f) + (hφ : Continuous φ) (hmean : (∫ x, f x ∂μ) = 0) + {c : V} {ω : ℝ} (hosc : ∀ x ∈ tsupport f, ‖φ x-c‖ ≤ ω) : + |∫ x, inner ℝ (φ x) (f x) ∂μ| ≤ ω * ∫ x, ‖f x‖ ∂μ := by + have hfi : Integrable f μ := hf.integrable_of_hasCompactSupport hc + have h1 : Integrable (fun x => inner ℝ (φ x) (f x)) μ := + (hφ.inner hf).integrable_of_hasCompactSupport (compact_inner_right hc _) + have h2 : Integrable (fun x => inner ℝ (φ x-c) (f x)) μ := + ((hφ.sub continuous_const).inner hf).integrable_of_hasCompactSupport (compact_inner_right hc _) + have he : (∫ x, inner ℝ (φ x) (f x) ∂μ) = ∫ x, inner ℝ (φ x-c) (f x) ∂μ := by + simp_rw [inner_sub_left] + rw [integral_sub h1 (hfi.const_inner c),integral_inner hfi c,hmean,inner_zero_right,sub_zero] + rw [he] + calc + _ ≤ ∫ x, |inner ℝ (φ x-c) (f x)| ∂μ := abs_integral_le_integral_abs + _ ≤ ∫ x, ω * ‖f x‖ ∂μ := by + apply integral_mono_ae h2.abs (hfi.norm.const_mul ω) + exact Eventually.of_forall fun x => by + change |inner ℝ (φ x-c) (f x)| ≤ ω * ‖f x‖ + by_cases hx : x ∈ tsupport f + · exact (abs_real_inner_le_norm _ _).trans (mul_le_mul_of_nonneg_right (hosc x hx) (norm_nonneg _)) + · rw [image_eq_zero_of_notMem_tsupport hx,inner_zero_right,norm_zero,abs_zero,mul_zero] + _ = _ := integral_const_mul _ _ + +lemma norm_finite_disjoint_sum + {ι X V : Type*} [Fintype ι] [TopologicalSpace X] [NormedAddCommGroup V] + (f : ι → X → V) (hd : Pairwise (fun i j => Disjoint (tsupport (f i)) (tsupport (f j)))) (x : X) : + ‖∑ i, f i x‖ = ∑ i, ‖f i x‖ := by + classical + by_cases h : ∃ i, f i x ≠ 0 + · obtain ⟨i,hi⟩ := h + have hz : ∀ j, j ≠ i → f j x = 0 := by + intro j hji + by_contra hj + exact Set.disjoint_left.mp (hd hji) (subset_closure hj) (subset_closure hi) + rw [Finset.sum_eq_single i,Finset.sum_eq_single i] + · intro j _ hji; rw [hz j hji,norm_zero] + · simp + · intro j _ hji; exact hz j hji + · simp + · push Not at h + simp only [h,Finset.sum_const_zero,norm_zero] + +lemma finite_cell_pairing_bound + {ι X V : Type*} [Fintype ι] [TopologicalSpace X] [MeasurableSpace X] [BorelSpace X] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (μ : Measure X) [IsFiniteMeasureOnCompacts μ] + (f : ι → X → V) (φ : X → V) + (hf : ∀ i, Continuous (f i)) (hc : ∀ i, HasCompactSupport (f i)) + (hφ : Continuous φ) (hmean : ∀ i, (∫ x, f i x ∂μ) = 0) + (hd : Pairwise (fun i j => Disjoint (tsupport (f i)) (tsupport (f j)))) + (c : ι → V) {ω : ℝ} (hosc : ∀ i x, x ∈ tsupport (f i) → ‖φ x-c i‖ ≤ ω) : + |∫ x, inner ℝ (φ x) (∑ i, f i x) ∂μ| ≤ ω * ∫ x, ‖∑ i, f i x‖ ∂μ := by + classical + simp_rw [inner_sum] + rw [integral_finsetSum _ (fun i _ => (hφ.inner (hf i)).integrable_of_hasCompactSupport (compact_inner_right (hc i) _))] + calc + _ ≤ ∑ i, |∫ x, inner ℝ (φ x) (f i x) ∂μ| := Finset.abs_sum_le_sum_abs _ _ + _ ≤ ∑ i, ω * ∫ x, ‖f i x‖ ∂μ := Finset.sum_le_sum fun i _ => + vector_pairing_bound_of_zero_mean μ (f i) φ (hf i) (hc i) hφ (hmean i) (hosc i) + _ = _ := by + rw [← Finset.mul_sum,← integral_finsetSum _ (fun i _ => ((hf i).integrable_of_hasCompactSupport (hc i)).norm)] + simp_rw [norm_finite_disjoint_sum f hd] + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal + +lemma fine_cell_pairing_bound + {X V : Type*} [MetricSpace X] [MeasurableSpace X] [BorelSpace X] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (μ : Measure X) [IsFiniteMeasureOnCompacts μ] + {K : Set X} (hK : IsCompact K) (φ : X → V) (hφ : Continuous φ) + {ω : ℝ} (hω : 0 < ω) : + ∃ δ > 0, ∀ (N : ℕ) (f : Fin N → X → V) (center : Fin N → X), + (∀ i, Continuous (f i)) → (∀ i, HasCompactSupport (f i)) → + (∀ i, (∫ x, f i x ∂μ) = 0) → + Pairwise (fun i j => Disjoint (tsupport (f i)) (tsupport (f j))) → + (∀ i, tsupport (f i) ⊆ K) → + (∀ i, tsupport (f i) ⊆ Metric.ball (center i) δ) → + |∫ x, inner ℝ (φ x) (∑ i, f i x) ∂μ| ≤ ω * ∫ x, ‖∑ i, f i x‖ ∂μ := by + classical + obtain ⟨d,hd,hcont⟩ := Metric.uniformContinuousOn_iff.mp + (hK.uniformContinuousOn_of_continuous hφ.continuousOn) ω hω + refine ⟨d/2,by positivity,?_⟩ + intro N f center hf hc hmean hdis hsK hsball + have hex : ∀ i, ∃ c : V, ∀ x ∈ tsupport (f i), ‖φ x-c‖ ≤ ω := by + intro i + by_cases hi : (tsupport (f i)).Nonempty + · obtain ⟨z,hz⟩ := hi + refine ⟨φ z,fun x hx => ?_⟩ + have hdist : dist x z < d := by + have h1 := hsball i hx + have h2 := hsball i hz + rw [Metric.mem_ball] at h1 h2 + have hh := dist_triangle_right x z (center i) + linarith + have hh : ‖φ x - φ z‖ < ω := by + simpa only [dist_eq_norm] using hcont x (hsK i hx) z (hsK i hz) hdist + exact hh.le + · exact ⟨0,fun x hx => (hi ⟨x,hx⟩).elim⟩ + choose c hc' using hex + exact finite_cell_pairing_bound μ f φ hf hc hφ hmean hdis c hc' + +lemma inner_tendsto_zero_of_dense_tests + {V W : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] + (T : W → V) (hT : DenseRange T) (z : ℕ → V) + {C : ℝ} (hC : 0 ≤ C) (hz : ∀ n, ‖z n‖ ≤ C) + (ht : ∀ w, Tendsto (fun n => inner ℝ (T w) (z n)) atTop (𝓝 0)) : + ∀ v, Tendsto (fun n => inner ℝ v (z n)) atTop (𝓝 0) := by + intro v + rw [Metric.tendsto_atTop] + intro ε hε + obtain ⟨w,hw⟩ := hT.exists_dist_lt v (show 0 < ε/(2*(C+1)) by positivity) + obtain ⟨N,hN⟩ := Metric.tendsto_atTop.mp (ht w) (ε/2) (by positivity) + refine ⟨N,fun n hn => ?_⟩ + have he : inner ℝ v (z n) = inner ℝ (v-T w) (z n) + inner ℝ (T w) (z n) := by + rw [inner_sub_left]; ring + rw [Real.dist_eq, sub_zero, he] + calc + _ ≤ |inner ℝ (v-T w) (z n)| + |inner ℝ (T w) (z n)| := abs_add_le _ _ + _ ≤ ‖v-T w‖ * C + |inner ℝ (T w) (z n)| := by + gcongr + exact (abs_real_inner_le_norm _ _).trans + (mul_le_mul_of_nonneg_left (hz n) (norm_nonneg _)) + _ < ε := by + have htest : |inner ℝ (T w) (z n)| < ε/2 := by + simpa only [Real.dist_eq,sub_zero] using hN n hn + rw [dist_eq_norm] at hw + have hmul := mul_le_mul_of_nonneg_right hw.le hC + have hd : ε/(2*(C+1))*C < ε/2 := by + have hpos : 0 < 2*(C+1) := by positivity + have hdiv := (div_lt_iff₀ hpos).mpr (show ε*C < (ε/2)*(2*(C+1)) by nlinarith) + simpa only [div_mul_eq_mul_div] using hdiv + linarith + +lemma fine_cells_continuous_pairing_tendsto_zero + {X V : Type*} [MetricSpace X] [MeasurableSpace X] [BorelSpace X] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (μ : Measure X) [IsFiniteMeasure μ] + {K : Set X} (hK : IsCompact K) + (N : ℕ → ℕ) (f : (n : ℕ) → Fin (N n) → X → V) + (center : (n : ℕ) → Fin (N n) → X) + (δ : ℕ → ℝ) (hδ : Tendsto δ atTop (𝓝 0)) + (hf : ∀ n i, Continuous (f n i)) (hc : ∀ n i, HasCompactSupport (f n i)) + (hmean : ∀ n i, (∫ x, f n i x ∂μ) = 0) + (hdis : ∀ n, Pairwise (fun i j => Disjoint (tsupport (f n i)) (tsupport (f n j)))) + (hsK : ∀ n i, tsupport (f n i) ⊆ K) + (hsball : ∀ n i, tsupport (f n i) ⊆ Metric.ball (center n i) (δ n)) + (hLp : ∀ n, MemLp (fun x => ∑ i, f n i x) 2 μ) + {C : ℝ} (hC : 0 ≤ C) (hbound : ∀ n, ‖(hLp n).toLp _‖ ≤ C) + (φ : X → V) (hφ : Continuous φ) : + Tendsto (fun n => ∫ x, inner ℝ (φ x) (∑ i, f n i x) ∂μ) atTop (𝓝 0) := by + let M : ℝ := ‖(memLp_const (p := 2) (μ := μ) (1 : ℝ)).toLp _‖ + have hM : 0 ≤ M := norm_nonneg _ + rw [Metric.tendsto_atTop] + intro ε hε + let ω := ε/(M*C+1) + have hω : 0 < ω := div_pos hε (by positivity) + obtain ⟨d,hd,hfine⟩ := fine_cell_pairing_bound μ hK φ hφ hω + obtain ⟨n₀,hn₀⟩ := eventually_atTop.mp ((tendsto_order.mp hδ).2 d hd) + refine ⟨n₀,fun n hn => ?_⟩ + have hs : ∀ i, tsupport (f n i) ⊆ Metric.ball (center n i) d := fun i x hx => + (Metric.ball_subset_ball (hn₀ n hn).le) (hsball n i hx) + have hp := hfine (N n) (f n) (center n) (hf n) (hc n) (hmean n) (hdis n) (hsK n) hs + have hl : (∫ x, ‖∑ i, f n i x‖ ∂μ) ≤ M*C := + (integral_norm_le_L2_const μ (hLp n)).trans + (mul_le_mul_of_nonneg_left (hbound n) hM) + rw [Real.dist_eq,sub_zero] + apply lt_of_le_of_lt (hp.trans (mul_le_mul_of_nonneg_left hl hω.le)) + change ε/(M*C+1)*(M*C) < ε + have hpos : 0 < M*C+1 := by positivity + have hdiv := (div_lt_iff₀ hpos).mpr (show ε*(M*C) < ε*(M*C+1) by nlinarith) + simpa only [div_mul_eq_mul_div] using hdiv + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Scalarization/WeakDensityLp.lean b/lean/OAI/Analysis/Conductivity/Scalarization/WeakDensityLp.lean new file mode 100644 index 0000000000000000000000000000000000000000..c61eda4d0b5eabf45561e7b43840ff9b225ffefa --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Scalarization/WeakDensityLp.lean @@ -0,0 +1,168 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CompactUpdateLp +import OAI.Analysis.Conductivity.Scalarization.WeakCellFast + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal BoundedContinuousFunction + +lemma weak_tendsto_zero_of_inner_tendsto_zero + {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (z : ℕ → V) (hz : ∀ v, Tendsto (fun n => inner ℝ v (z n)) atTop (𝓝 0)) : + Tendsto (fun n => toWeakSpace ℝ V (z n)) atTop (𝓝 0) := by + have hB : Function.Injective ((topDualPairing ℝ V).flip) := by + intro x y h + apply (SeparatingDual.eq_iff_forall_dual_eq (R := ℝ)).mpr + intro L + exact LinearMap.congr_fun h L + apply (WeakBilin.tendsto_iff_forall_eval_tendsto (topDualPairing ℝ V).flip hB).mpr + intro L + change Tendsto (fun n => L (z n)) atTop (𝓝 (L 0)) + simpa only [InnerProductSpace.toDual_symm_apply, map_zero] + using hz ((InnerProductSpace.toDual ℝ V).symm L) + +lemma fine_cells_weak_L2_tendsto_zero + {X V : Type*} [MetricSpace X] [MeasurableSpace X] [BorelSpace X] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + [SecondCountableTopologyEither X V] + (μ : Measure X) [IsFiniteMeasure μ] [μ.WeaklyRegular] + {K : Set X} (hK : IsCompact K) + (N : ℕ → ℕ) (f : (n : ℕ) → Fin (N n) → X → V) + (center : (n : ℕ) → Fin (N n) → X) + (δ : ℕ → ℝ) (hδ : Tendsto δ atTop (𝓝 0)) + (hf : ∀ n i, Continuous (f n i)) (hc : ∀ n i, HasCompactSupport (f n i)) + (hmean : ∀ n i, (∫ x, f n i x ∂μ) = 0) + (hdis : ∀ n, Pairwise (fun i j => Disjoint (tsupport (f n i)) (tsupport (f n j)))) + (hsK : ∀ n i, tsupport (f n i) ⊆ K) + (hsball : ∀ n i, tsupport (f n i) ⊆ Metric.ball (center n i) (δ n)) + (hLp : ∀ n, MemLp (fun x => ∑ i, f n i x) 2 μ) + {C : ℝ} (hC : 0 ≤ C) (hbound : ∀ n, ‖(hLp n).toLp _‖ ≤ C) : + Tendsto (fun n => toWeakSpace ℝ (Lp V 2 μ) ((hLp n).toLp _)) atTop (𝓝 0) := by + apply weak_tendsto_zero_of_inner_tendsto_zero + apply inner_tendsto_zero_of_dense_tests + (BoundedContinuousFunction.toLp 2 μ ℝ : (X →ᵇ V) →L[ℝ] Lp V 2 μ) + (BoundedContinuousFunction.toLp_denseRange V μ ℝ (by simp)) _ hC hbound + intro φ + have h := fine_cells_continuous_pairing_tendsto_zero μ hK N f center δ hδ + hf hc hmean hdis hsK hsball hLp hC hbound φ φ.continuous + convert h using 1 + ext n + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [φ.coeFn_toLp 2 μ ℝ, (hLp n).coeFn_toLp] with x hx hy + rw [hx,hy] + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +lemma CompactGlobalUpdate.gradient_mean_zero_on_superset + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {O U : Set Coord3} (hOU : O ⊆ U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ O u A) : + (∫ x, voltageGradient R.du x ∂μ.restrict U) = 0 := by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero] + · exact voltageGradient_mean_zero μ R.smooth_du R.compact_du + · intro x hx + exact image_eq_zero_of_notMem_tsupport + (fun hs => hx (hOU (R.support_du (tsupport_voltageGradient hs)))) + +lemma CompactGlobalUpdate.flux_mean_zero_on_superset + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {O U : Set Coord3} (hOU : O ⊆ U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ O u A) : + (∫ x, fieldVector (R.dF x) ∂μ.restrict U) = 0 := by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero] + · exact R.flux_mean_zero μ + · intro x hx + rw [image_eq_zero_of_notMem_tsupport (fun hs => hx (hOU (R.support_dF hs)))] + exact map_zero fieldVectorCLM + +lemma fine_updates_weak_tendsto_zero + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUb : Bornology.IsBounded U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (N : ℕ → ℕ) (O : (n : ℕ) → Fin (N n) → Set Coord3) + (center : (n : ℕ) → Fin (N n) → Coord3) + (R : ∀ n i, CompactGlobalUpdate μ (O n i) u A) + (S : ℕ → CompactGlobalUpdate μ U u A) + (δ : ℕ → ℝ) (hδ : Tendsto δ atTop (𝓝 0)) + (hOU : ∀ n i, O n i ⊆ U) + (hsmall : ∀ n i, O n i ⊆ Metric.ball (center n i) (δ n)) + (hdis : ∀ n, Pairwise (fun i j => Disjoint (O n i) (O n j))) + (hsu : ∀ n, (S n).du = fun x => ∑ i, (R n i).du x) + (hsF : ∀ n, (S n).dF = fun x => ∑ i, (R n i).dF x) + {CE CF : ℝ} (hCE : 0 ≤ CE) (hCF : 0 ≤ CF) + (hbE : ∀ n, ‖((S n).memLp_gradient_correction μ).toLp _‖ ≤ CE) + (hbF : ∀ n, ‖((S n).memLp_flux_correction μ).toLp _‖ ≤ CF) : + Tendsto (fun n => toWeakSpace ℝ (Lp FieldVector 2 (μ.restrict U)) + (((S n).memLp_gradient_correction μ).toLp _)) atTop (𝓝 0) ∧ + Tendsto (fun n => toWeakSpace ℝ (Lp FieldVector 2 (μ.restrict U)) + (((S n).memLp_flux_correction μ).toLp _)) atTop (𝓝 0) := by + classical + have heq : ∀ n, voltageGradient (S n).du = fun x => ∑ i, voltageGradient (R n i).du x := by + intro n + rw [hsu n] + exact funext (voltageGradient_sum _ (fun i => (R n i).smooth_du.differentiable (by simp))) + have hfq : ∀ n, (fun x => fieldVector ((S n).dF x)) = + fun x => ∑ i, fieldVector ((R n i).dF x) := by + intro n + funext x + rw [hsF n] + exact map_sum fieldVectorCLM _ _ + have hsE : ∀ n i, tsupport (voltageGradient (R n i).du) ⊆ O n i := + fun n i => tsupport_voltageGradient.trans (R n i).support_du + have hsF' : ∀ n i, tsupport (fun x => fieldVector ((R n i).dF x)) ⊆ O n i := + fun n i => (tsupport_comp_subset (map_zero fieldVectorCLM) _).trans (R n i).support_dF + constructor + · have hLp : ∀ n, MemLp (fun x => ∑ i, voltageGradient (R n i).du x) 2 (μ.restrict U) := by + intro n + rw [← heq n] + exact (S n).memLp_gradient_correction μ + have ht := fine_cells_weak_L2_tendsto_zero (μ.restrict U) hUb.isCompact_closure + N (fun n i => voltageGradient (R n i).du) center δ hδ + (fun n i => continuous_voltageGradient (R n i).smooth_du) + (fun n i => compact_voltageGradient (R n i).compact_du) + (fun n i => (R n i).gradient_mean_zero_on_superset μ (hOU n i)) + (fun n i j hij => (hdis n hij).mono (hsE n i) (hsE n j)) + (fun n i => (hsE n i).trans ((hOU n i).trans subset_closure)) + (fun n i => (hsE n i).trans (hsmall n i)) hLp hCE + (fun n => by simpa only [← heq n] using hbE n) + simpa only [← heq] using ht + · have hLp : ∀ n, MemLp (fun x => ∑ i, fieldVector ((R n i).dF x)) 2 (μ.restrict U) := by + intro n + rw [← hfq n] + exact (S n).memLp_flux_correction μ + have ht := fine_cells_weak_L2_tendsto_zero (μ.restrict U) hUb.isCompact_closure + N (fun n i x => fieldVector ((R n i).dF x)) center δ hδ + (fun n i => fieldVectorCLM.continuous.comp (R n i).smooth_dF.continuous) + (fun n i => (R n i).compact_dF.comp_left (map_zero fieldVectorCLM)) + (fun n i => (R n i).flux_mean_zero_on_superset μ (hOU n i)) + (fun n i j hij => (hdis n hij).mono (hsF' n i) (hsF' n j)) + (fun n i => (hsF' n i).trans ((hOU n i).trans subset_closure)) + (fun n i => (hsF' n i).trans (hsmall n i)) hLp hCF + (fun n => by simpa only [← hfq n] using hbF n) + simpa only [← hfq] using ht + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/AttachedEndMatchedH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/AttachedEndMatchedH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..66c53992e2cacc1265cf887fa0e41f9de13a18e2 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/AttachedEndMatchedH1.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.AttachedEndGradientL2 +import OAI.Analysis.Conductivity.Geometry.CollarLip +import OAI.Analysis.Conductivity.Branching.AttachedCutLayer +import OAI.Analysis.Conductivity.Geometry.CollarInteriorFacts + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal + +theorem smooth_attachedEnd_matched_H1 {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) {q χ : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {a b η : ℝ} (ha : a≠0) (hη : 0<η) (hl : -(1:ℝ)/100≤b-η) (hr : b+η≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand (b-η) (b+η)) + (htrace : ∀ h,f.val 0 h=mFourierCoeff (fun θ => (q (sourceAngularCollar b θ):ℂ)) h) + (g : SpectralL2 TorusModes) (hg : ∀ h,g h=(torusRate s h:ℂ)*f.val 0 h) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=cutMatchedValue (fun y => a*(sourceCollarTime y-b)) χ + (fun y => (attachedEndPoissonField s f a b 0 y).re-q y) (WithLp.ofLp x) ∧ + ∀ i,weakGradient w x i=cutMatchedGradient (fun y => a*(sourceCollarTime y-b)) χ + (fun y => (attachedEndPoissonField s f a b 0 y).re-q y) + (fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y-fderiv ℝ q y) + i (WithLp.ofLp x)) := by + let τ : (Fin 3 → ℝ) → ℝ := fun y => a*(sourceCollarTime y-b) + let p : (Fin 3 → ℝ) → ℝ := fun y => (attachedEndPoissonField s f a b 0 y).re-q y + let F : (Fin 3 → ℝ) → (Fin 3 → ℝ) →L[ℝ] ℝ := + fun y => fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y-fderiv ℝ q y + let R := |a| *η + let l := min b (b+R/a) + let r := max b (b+R/a) + let D := sourceClosedCollarBand l r + have hR : 0≤R := (mul_pos (abs_pos.mpr ha) hη).le + have hdiv : R/|a|=η := by dsimp [R]; field_simp + obtain ⟨hlen,hleft,hright,hiff,hnear⟩ := affine_layer_interval (b:=b) ha hR + have hl' : -(1:ℝ)/100≤l := by dsimp only [l]; rw [hdiv] at hleft; linarith + have hr' : r≤(1:ℝ)/100 := by dsimp only [r]; rw [hdiv] at hright; linarith + have hb : b∈Icc (-(1:ℝ)/100) (1/100) := ⟨by linarith,by linarith⟩ + have hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R := fun t ht => (hiff t).mp ht + have hD : MeasurableSet D := (isCompact_sourceClosedCollarBand hl' hr').measurableSet + have hDfull : D⊆sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := + fun y hy => ⟨hl'.trans hy.1,hy.2.trans hr'⟩ + have hχfull : tsupport χ⊆sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := + fun y hy => ⟨hl.trans (hχs hy).1,(hχs hy).2.trans hr⟩ + have htD : ∀ y∈tsupport χ,0<τ y → y∈D := by + intro y hy ht + apply (hiff _).mpr + have hbound : |sourceCollarTime y-b|≤η := by + apply abs_le.mpr + constructor <;> linarith [(hχs hy).1,(hχs hy).2] + refine ⟨ht.le,?_⟩ + calc + a*(sourceCollarTime y-b) ≤ |a*(sourceCollarTime y-b)| := le_abs_self _ + _ = |a| *|sourceCollarTime y-b| := abs_mul _ _ + _ ≤ R := mul_le_mul_of_nonneg_left hbound (abs_nonneg a) + have hp : MemLp p 2 (volume.restrict D) := + (attachedEndPoissonField_memLp s hs f ha hR min_le_max hl' hr' hT 0).re.sub + (continuous_sourceBand_memLp hq.continuous hl' hr') + obtain ⟨K,hK⟩ := attachedEndTime_lipschitz a b + have hu := cutMatchedValue_memLp hK.continuous hχ.continuous hc hD hp htD + apply localized_matched_seam_H1_pi hK hχ hc hD hp htD _ F _ _ (by norm_num : (5:ℝ)/2<3) + (fun y hy => sourceBand_euclidean_bound (hχfull hy)) + (smooth_attachedEnd_cut_thin hs f hq hχb ha hη hl hr htrace g hg hu) + · intro y hy ht + exact (attachedEndPoissonField_localLip s hs f a b ht + (sourceDirections_ne_zero_on_band (hχfull hy))).sub + (localLipAt_of_contDiffAt (hq.of_le (by simp)).contDiffAt) + · intro i + exact (attachedEndPoisson_grad_memLp s hs f ha hR hb min_le_max hl' hr' hT i).sub + (continuous_sourceBand_memLp ((hq.continuous_fderiv (by simp)).clm_apply continuous_const) hl' hr') + · filter_upwards [ae_restrict_of_ae (attachedEndPoisson_real_differentiable_ae s hs f a b), + ae_restrict_mem hD] with y hy hyD ht + exact (hy (hDfull hyD) ht).hasFDerivAt.sub + ((hq.differentiable (by simp)) y).hasFDerivAt + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/AxialExtension.lean b/lean/OAI/Analysis/Conductivity/Sobolev/AxialExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..9b0668e65561a91461638c6f4a9605c792554046 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/AxialExtension.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Conductivity.Flux.TorusBoxFlux + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def axialZeroExtension (d e : ℝ) (f : Coord3 → E) (x : Coord3) : E := + if d+e/2 0) := by + filter_upwards [(isOpen_lt (continuous_apply 0) continuous_const).mem_nhds hx] with y hy + dsimp only [axialZeroExtension] + split_ifs with hh + · exact hf y ⟨by linarith only [he,hh],hy.le⟩ + · rfl + +lemma axialZeroExtension_contDiff {n : WithTop ℕ∞} {d e : ℝ} (he : 0 axialPair f x j) x := by + fin_cases j + · exact (differentiable_apply 0).differentiableAt + · exact hf + simp only [gradientColumns,Matrix.col,transpose_apply,LinearMap.toMatrix'_apply, + ContinuousLinearMap.coe_coe,fderiv_pi hd,ContinuousLinearMap.pi_apply] + exact direction_coord i 0 x + +lemma axialPair_gradient_one {f : Coord3 → ℝ} {x : Coord3} + (hf : DifferentiableAt ℝ f x) (i : Fin 3) : + (gradientColumns (fderiv ℝ (axialPair f) x)).col 1 i=direction (Pi.single i 1) f x := by + have hd (j : Fin 2) : DifferentiableAt ℝ (fun x => axialPair f x j) x := by + fin_cases j + · exact (differentiable_apply 0).differentiableAt + · exact hf + simp only [gradientColumns,Matrix.col,transpose_apply,LinearMap.toMatrix'_apply, + ContinuousLinearMap.coe_coe,fderiv_pi hd,ContinuousLinearMap.pi_apply] + rfl + +lemma axialPair_gradient_independent {f : Coord3 → ℝ} {x : Coord3} + (hf : DifferentiableAt ℝ f x) {i : Fin 3} (hi : i≠0) + (hfi : direction (Pi.single i 1) f x≠0) : + LinearIndependent ℝ (gradientColumns (fderiv ℝ (axialPair f) x)).col := by + apply linearIndependent_fin2.mpr + constructor + · intro hz + apply hfi + have hh := congrFun hz i + simpa only [axialPair_gradient_one hf,Pi.zero_apply] using hh + · intro a he + have hh := congrFun he i + simp only [Pi.smul_apply,smul_eq_mul,axialPair_gradient_one hf, + axialPair_gradient_zero hf,Ne.symm hi,ite_false] at hh + have ha : a=0 := (mul_eq_zero.mp hh).resolve_right hfi + have hh0 := congrFun he 0 + simp only [ha,Pi.smul_apply,zero_smul,axialPair_gradient_zero hf, + ite_true] at hh0 + norm_num at hh0 + +lemma ae_sin_coord_ne_zero {r : ℝ} (hr : r≠0) (i : Fin 3) : + ∀ᵐ x : Coord3,sin (r*x i)≠0 := by + have h := ae_all_iff.mpr (fun n : ℤ => ae_coord3_ne i ((n:ℝ)*Real.pi/r)) + filter_upwards [h] with x hx + intro hz + obtain ⟨n,hn⟩ := sin_eq_zero_iff.mp hz + exact hx n ((eq_div_iff hr).mpr (by linarith)) + +lemma axialPair_regularPatch {f : Coord3 → ℝ} (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) + {A : Coord3 → Symmetric3} (hA : ContDiff ℝ (↑(⊤:ℕ∞)) (fun x => (A x).val)) + {i : Fin 3} (hi : i≠0) {O : Set Coord3} (hO : IsOpen O) + (hn : ∀ x∈O,direction (Pi.single i 1) f x≠0) : + RegularPatch (axialPair f) A O := by + exact ⟨hO,(axialPair_smooth hf).contDiffOn,hA.contDiffOn, + Or.inl (fun x hx => axialPair_gradient_independent (hf.differentiable (by simp) x) hi (hn x hx))⟩ + +lemma axialPair_zero_rank (O : Set Coord3) : TwoFieldRankRegular (axialPair (fun _ => 0)) O := by + refine Or.inr (Or.inl ⟨fun x : Coord3 => x 0,![1,0],0,(contDiff_apply ℝ ℝ (0:Fin 3)).contDiffOn, + ⟨0,by norm_num⟩,?_,?_⟩) + · intro x _ he + have hh := congrArg (fun D : Coord3 →L[ℝ] ℝ => D (Pi.single 0 1)) he + have hd := direction_coord 0 0 x + change fderiv ℝ (fun y : Coord3 => y 0) x (Pi.single 0 1)=1 at hd + simp only [he,_root_.zero_apply] at hd + norm_num at hd + · intro x _ j + fin_cases j <;> simp [axialPair] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/BoundedMultiplier.lean b/lean/OAI/Analysis/Conductivity/Sobolev/BoundedMultiplier.lean new file mode 100644 index 0000000000000000000000000000000000000000..802b2e0a4eae29d393f5030d4fded6ccf7599b01 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/BoundedMultiplier.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +namespace ScalarConductivity + +theorem boundedMultiplier_memLp {α E : Type*} [MeasurableSpace α] + [NormedAddCommGroup E] [NormedSpace ℝ E] (μ : Measure α) + (a : α → ℝ) (ha : AEStronglyMeasurable a μ) + (C : ℝ) (haC : ∀ᵐ x ∂μ, |a x| ≤ C) (f : Lp E 2 μ) : + MemLp (fun x => a x • f x) 2 μ := + (Lp.memLp f).of_le_mul (ha.smul (Lp.aestronglyMeasurable f)) (by + filter_upwards [haC] with x hx + simpa only [norm_smul, Real.norm_eq_abs] using + mul_le_mul_of_nonneg_right hx (norm_nonneg (f x))) + +def boundedMultiplier {α E : Type*} [MeasurableSpace α] + [NormedAddCommGroup E] [NormedSpace ℝ E] (μ : Measure α) + (a : α → ℝ) (ha : AEStronglyMeasurable a μ) + (C : ℝ) (_hC : 0 ≤ C) (haC : ∀ᵐ x ∂μ, |a x| ≤ C) : + Lp E 2 μ →L[ℝ] Lp E 2 μ := by + let hmem := boundedMultiplier_memLp (E := E) μ a ha C haC + let T : Lp E 2 μ →ₗ[ℝ] Lp E 2 μ := { + toFun := fun f => (hmem f).toLp _ + map_add' := by + intro f g + apply Lp.ext + filter_upwards [(hmem (f + g)).coeFn_toLp, (hmem f).coeFn_toLp, + (hmem g).coeFn_toLp, Lp.coeFn_add f g, + Lp.coeFn_add ((hmem f).toLp _) ((hmem g).toLp _)] with x hfg hf hg hsum hsum' + simp only [Pi.add_apply] at hsum hsum' + rw [hfg, hsum', hf, hg, hsum, smul_add] + map_smul' := by + intro c f + apply Lp.ext + filter_upwards [(hmem (c • f)).coeFn_toLp, (hmem f).coeFn_toLp, + Lp.coeFn_smul c f, Lp.coeFn_smul c ((hmem f).toLp _)] with x hcf hf hc hc' + change ((hmem (c • f)).toLp _) x = (c • ((hmem f).toLp _)) x + simp only [Pi.smul_apply] at hc hc' + rw [hcf, hc', hf, hc] + exact smul_comm _ _ _ } + exact T.mkContinuous C (fun f => Lp.norm_le_mul_norm_of_ae_le_mul (by + filter_upwards [(hmem f).coeFn_toLp, haC] with x hx hxC + change ‖((hmem f).toLp _) x‖ ≤ C * ‖f x‖ + rw [hx, norm_smul, Real.norm_eq_abs] + exact mul_le_mul_of_nonneg_right hxC (norm_nonneg _))) + +theorem boundedMultiplier_apply_ae {α E : Type*} [MeasurableSpace α] + [NormedAddCommGroup E] [NormedSpace ℝ E] (μ : Measure α) + (a : α → ℝ) (ha : AEStronglyMeasurable a μ) + (C : ℝ) (hC : 0 ≤ C) (haC : ∀ᵐ x ∂μ, |a x| ≤ C) (f : Lp E 2 μ) : + (boundedMultiplier μ a ha C hC haC f : α → E) =ᵐ[μ] fun x => a x • f x := by + change (((boundedMultiplier_memLp μ a ha C haC f).toLp _) : α → E) =ᵐ[μ] _ + exact MemLp.coeFn_toLp _ + +def jetGradient : JetFiber →L[ℝ] R3 := + LinearMap.toContinuousLinearMap { + toFun := fun z => WithLp.toLp 2 (fun i => z i.succ) + map_add' := by intro x y; rfl + map_smul' := by intro c x; rfl } + +def weakGradientL : H1 →L[ℝ] Lp R3 2 ballMeasure := + (jetGradient.compLpL 2 ballMeasure).comp H1Space.subtypeL + +theorem weakGradientL_apply_ae (u : H1) : + (weakGradientL u : R3 → R3) =ᵐ[ballMeasure] weakGradient u := + jetGradient.coeFn_compLp u.val + +def energyForm (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0 ≤ C) (haC : ∀ᵐ x ∂ballMeasure, |a x| ≤ C) : + H1 →L[ℝ] H1 →L[ℝ] ℝ := + ((innerSL ℝ).comp (boundedMultiplier ballMeasure a ha C hC haC |>.comp weakGradientL)) + |>.flip.comp weakGradientL |>.flip + +theorem energyForm_apply (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0 ≤ C) (haC : ∀ᵐ x ∂ballMeasure, |a x| ≤ C) (u v : H1) : + energyForm a ha C hC haC u v = energy a u v := by + change inner ℝ (boundedMultiplier ballMeasure a ha C hC haC (weakGradientL u)) + (weakGradientL v) = _ + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [boundedMultiplier_apply_ae ballMeasure a ha C hC haC (weakGradientL u), + weakGradientL_apply_ae u, weakGradientL_apply_ae v] with x hx hu hv + rw [hx, hu, hv, real_inner_smul_left] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralNeighborhoodCompletion.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralNeighborhoodCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..aad6018b86ab7c4343e8ebe45c22311836244e2a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralNeighborhoodCompletion.lean @@ -0,0 +1,40 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildH10Transport +import OAI.Analysis.Conductivity.Branching.CentralJoinCover + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : Fin 3 → ℝ} (ha₀ : a 0<0) (ha : ∀ k : Fin 2,0 centralPhysical_subset_ball (centralJoinPartition_interior_support hy))+ + parentCompletionJoin s hs ha₀ (centralJoinPartition_smooth 1) + centralJoinPartition_parent_compact (centralJoinPartition_bound 1) + centralJoinPartition_parent_support+ + ∑ k : Fin 2,physicalChildCompletionJoin s hs (ha k) k (centralJoinChildCutoff_smooth k) + (centralJoinChildCutoff_compact k) (centralJoinChildCutoff_bound k) (centralJoinChildCutoff_support k) + +lemma centralNeighborhoodCompletion_mem_H10 (u : centralEnergySpace s) : + centralNeighborhoodCompletion s hs ha₀ ha u∈H10 := by + apply Submodule.add_mem + · apply Submodule.add_mem + · exact centralInteriorCompletion_mem_H10 s _ _ _ _ u + · exact parentCompletionJoin_mem_H10 s hs ha₀ _ _ _ _ u + · rw [Fin.sum_univ_two] + exact H10.add_mem + (physicalChildCompletionJoin_mem_H10 s hs (ha 0) 0 _ _ _ _ u) + (physicalChildCompletionJoin_mem_H10 s hs (ha 1) 1 _ _ _ _ u) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPairRegularity.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPairRegularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..1c2f280a9a560e1133691ce40e186ad3482b57f7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPairRegularity.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.WeakHarmonicClassical +import OAI.Analysis.Conductivity.Variational.CentralEuclideanBridge + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def centralBasisSlopes (j : Fin 2) : Fin 3 → ℝ := + ![![-1,1,0],![-1,0,1]] j + +lemma centralBasisSlopes_sum (j : Fin 2) : ∑ i,centralBasisSlopes j i=0 := by + fin_cases j <;> norm_num [centralBasisSlopes,Fin.sum_univ_three,Matrix.cons_val_zero,Matrix.cons_val_one,Matrix.cons_val_two] + +theorem central_pair_regular_exists (s : Fin 3 → ℝ) : + ∃ p : Fin 2 → centralEnergySpace s, + (∀ j,centralM s (p j)=0) ∧ + (∀ j,CentralVariationalEquation s (centralBasisSlopes j) (p j)) ∧ + (∀ j,WeaklyHarmonicOn (centralWholeL2 (centralAmbientComponent s 0 (p j).val)) centralHarmonicRegion) ∧ + ∀ (a : R3) (R : ℝ),00, + Metric.ball x r⊆Metric.ball a (R/4) ∧ + HarmonicPairRegularOn + (radialMollify (centralWholeL2 (centralAmbientComponent s 0 (p 0).val)) (R/4)) + (radialMollify (centralWholeL2 (centralAmbientComponent s 0 (p 1).val)) (R/4)) + (Metric.ball x r) := by + classical + have hp (j : Fin 2) := central_variational_euclidean_weak s (centralBasisSlopes j) + (centralBasisSlopes_sum j) + choose p hm hv hw using hp + refine ⟨p,hm,hv,hw,?_⟩ + intro a R hR hball + exact ⟨fun j => weakWeyl_analytic_local (hw j) hR hball, + weakWeyl_pair_ae_regular (hw 0) (hw 1) hR hball⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalEnergy.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..af7bab982211c6d38d7db59580d9808db665d4e9 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalEnergy.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.PhysicalChildIntegral +import OAI.Analysis.Conductivity.Branching.PhysicalAttachedAssembly + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +lemma centralPhysicalWholeCLM_norm (f : CentralL2) : + ‖centralPhysicalWholeCLM f‖=‖f‖ := by + change ‖(Lp.compMeasurePreservingₗᵢ ℝ sourcePairMeasurable sourcePair_volume) + (lpZeroExtensionCLM centralClosed_compact.measurableSet f)‖=‖f‖ + rw [LinearIsometry.norm_map] + exact lpZeroExtensionL_norm centralClosed_compact.measurableSet f + +def centralPhysicalWholeLI : CentralL2 →ₗᵢ[ℝ] Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) where + toLinearMap := centralPhysicalWholeCLM.toLinearMap + norm_map' := centralPhysicalWholeCLM_norm + +lemma centralPhysicalWholeCLM_ae (f : CentralL2) : + centralPhysicalWholeCLM f=ᵐ[volume] + (fun y => centralPhysical.indicator (fun y => f (sourcePairCoordinates y)) y) := by + apply (Lp.coeFn_compMeasurePreserving _ sourcePair_volume).trans + have he := sourcePair_volume.quasiMeasurePreserving.ae_eq_comp + (lpZeroExtensionCLM_ae centralClosed_compact.measurableSet f) + apply he.trans + filter_upwards [] with y + by_cases h : sourcePairCoordinates y∈centralClosed <;> + simp [sourcePairMeasurable_apply,centralPhysical,h] + rfl + +lemma centralPhysicalWholeCLM_integral (f g : CentralL2) : + IntegrableOn (fun y => centralPhysicalWholeCLM f y*centralPhysicalWholeCLM g y) + centralPhysical volume ∧ + (∫ y in centralPhysical,centralPhysicalWholeCLM f y*centralPhysicalWholeCLM g y)= + inner ℝ f g := by + have hi := (Lp.memLp (centralPhysicalWholeCLM f)).integrable_mul + (Lp.memLp (centralPhysicalWholeCLM g)) + refine ⟨hi.integrableOn,?_⟩ + rw [←centralPhysicalWholeLI.inner_map_map f g,L2.inner_def, + ←integral_indicator centralPhysical_compact.measurableSet] + apply integral_congr_ae + filter_upwards [centralPhysicalWholeCLM_ae f,centralPhysicalWholeCLM_ae g] with y hf hg + change centralPhysical.indicator + (fun y => centralPhysicalWholeCLM f y*centralPhysicalWholeCLM g y) y= + inner ℝ (centralPhysicalWholeCLM f y) (centralPhysicalWholeCLM g y) + rw [Real.inner_apply] + by_cases hy : y∈centralPhysical + · rw [indicator_of_mem hy] + · rw [indicator_of_notMem hy,hf,hg,indicator_of_notMem hy,indicator_of_notMem hy]; ring + +lemma H1JetOn.central_gradient {s : Fin 3 → ℝ} {p : centralEnergySpace s} {w : H1} + (hw : H1JetOn w centralPhysical (centralFullJetCLM s p.val)) : + ∀ᵐ y : Fin 3 → ℝ,y∈centralPhysical → originalPiGradient w y= + (fun i : Fin 3 => centralPhysicalWholeCLM (centralAmbientComponent s i.succ p.val) y) := by + apply originalPiGradient_eq_on_ball (fun _ => centralPhysical_subset_ball) w _ + filter_upwards [hw,physicalFourJetCLM_ae + (fun i => centralPhysicalWholeCLM (centralAmbientComponent s i p.val))] with x hx he hy + have h := (hx hy).trans he + intro i + exact congrArg (fun v : JetFiber => v i.succ) h + +lemma central_physical_energy {s : Fin 3 → ℝ} (p q : centralEnergySpace s) (w v : H1) + (hw : H1JetOn w centralPhysical (centralFullJetCLM s p.val)) + (hv : H1JetOn v centralPhysical (centralFullJetCLM s q.val)) : + (∫ y in centralPhysical,originalPiGradient w y ⬝ᵥ originalPiGradient v y)= + inner ℝ (centralD s p) (centralD s q) := by + calc + _ = ∫ y in centralPhysical,∑ i : Fin 3, + centralPhysicalWholeCLM (centralAmbientComponent s i.succ p.val) y* + centralPhysicalWholeCLM (centralAmbientComponent s i.succ q.val) y := by + apply integral_congr_ae + filter_upwards [ae_restrict_of_ae hw.central_gradient,ae_restrict_of_ae hv.central_gradient, + ae_restrict_mem centralPhysical_compact.measurableSet] with y hp hq hy + rw [hp hy,hq hy] + rfl + _ = ∑ i : Fin 3,inner ℝ (centralAmbientComponent s i.succ p.val) + (centralAmbientComponent s i.succ q.val) := by + rw [integral_finsetSum (f:=fun i : Fin 3 => fun y => + centralPhysicalWholeCLM (centralAmbientComponent s i.succ p.val) y* + centralPhysicalWholeCLM (centralAmbientComponent s i.succ q.val) y) Finset.univ (fun i _ => + (centralPhysicalWholeCLM_integral (centralAmbientComponent s i.succ p.val) + (centralAmbientComponent s i.succ q.val)).1)] + exact Finset.sum_congr rfl (fun i _ => + (centralPhysicalWholeCLM_integral (centralAmbientComponent s i.succ p.val) + (centralAmbientComponent s i.succ q.val)).2) + _ = _ := by rw [PiLp.inner_apply]; rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalRegion.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalRegion.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1a876f8d86cd95049a179f69512f43231f0731b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalRegion.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ChildCentralL2 + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma sourceCollarTime_ge_iff (y : Fin 3 → ℝ) (b : ℝ) : + b ≤ sourceCollarTime y ↔ + |y 2| ≤ 1-b ∧ sourceHole+sourceRadialWidth*b ≤ sourceRadial y ∧ + sourceRadial y ≤ 1-sourceRadialWidth*b := by + have hw : 0 nlinarith + +lemma sourceCollarTime_le_iff (y : Fin 3 → ℝ) (b : ℝ) : + sourceCollarTime y ≤ b ↔ + 1-b ≤ |y 2| ∨ sourceRadial y ≤ sourceHole+sourceRadialWidth*b ∨ + 1-sourceRadialWidth*b ≤ sourceRadial y := by + have hw : 0 by nlinarith [h]) id⟩,hz⟩ + · rintro ⟨⟨hx,hy,hi⟩,hz⟩ + exact ⟨hz,hi.imp (fun h => by nlinarith [h]) id,⟨by nlinarith [hx],hy⟩⟩ + +lemma centralChild_time_iff (σ : ℝ) (y : Fin 3 → ℝ) : + sourceCollarTime ((sourceChildHomeomorph σ).symm y) ≤ -centralThickness ↔ + centralChildHeight ≤ |y 2| ∨ centralAvoidChild σ (sourcePairCoordinates y).1 := by + change sourceCollarTime ![y 1/sourceScale,(y 0-σ*sourceOffset)/sourceScale,y 2/sourceScale] ≤ -centralThickness ↔ _ + rw [sourceCollarTime_le_iff] + have hs : 0 nlinarith + · right; right; left; nlinarith + · right; left; nlinarith + · rintro (hz|hx|hy|⟨hx,hy⟩) + · left; nlinarith + · right; right; right; nlinarith + · right; right; left; nlinarith + · right; left; constructor <;> nlinarith + +theorem centralPhysical_time_iff (y : Fin 3 → ℝ) : + y∈centralPhysical ↔ centralThickness ≤ sourceCollarTime y ∧ + (∀ k : Fin 2,sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)).symm y) ≤ -centralThickness) := by + simp only [centralParent_time_iff,centralChild_time_iff,centralPhysical,mem_preimage, + centralClosed,mem_ofPred_eq,sourcePairCoordinates,actualChildSign,Fin.forall_fin_two, + ite_true,Fin.isValue,one_ne_zero,ite_false] + tauto + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalTrace.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..622e3c354d4d111aeb23e3aa80d27df942074eea --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalTrace.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.PhysicalCollarTrace +import OAI.Analysis.Conductivity.Branching.ChildCoordinateAnalysis + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory UnitAddTorus + +def centralTraceConstant : ℝ := ((1+1/centralThickness)*physicalRayConstant)*(sourceScale^3)⁻¹ + +lemma centralTraceConstant_pos : 0 by + obtain ⟨x,hx,rfl⟩ := hy + apply sourceParentCollar_central i j + simpa [two_mul] using hx) + have hn : 0≤∫ y in centralPhysical,sourcePhysicalEnergy f y := integral_nonneg (sourcePhysicalEnergy_nonneg f) + exact hh.trans (mul_le_mul_of_nonneg_right centralTraceConstant_parent hn) + +lemma central_child_trace {f : (Fin 3 → ℝ) → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + {σ : ℝ} (hσ : σ=1 ∨ σ= -1) : + (∫ x : UnitAddTorus (Fin 2),(f (sourceChildCoordinates σ (sourceAngularCollar (-centralThickness) x)))^2)≤ + centralTraceConstant*(∫ y in centralPhysical,sourcePhysicalEnergy f y) := by + let K := sourceChildCoordinates σ ⁻¹' centralPhysical + have hK : IsCompact K := (sourceChildHomeomorph σ).isCompact_preimage.mpr centralPhysical_compact + have hfc := hf.comp (sourceChildCoordinates_contDiff σ) + have hh := sourceAngular_physical_trace_backward hfc hK (-centralThickness) + (η:=centralThickness) (by norm_num [centralThickness]) (by norm_num [centralThickness]) + (by norm_num [centralThickness]) (fun i j y hy => by + obtain ⟨x,hx,rfl⟩ := hy + apply sourceChildCollar_central i j hσ + convert hx using 1; ring_nf) + have hmono : (∫ y in K,sourcePhysicalEnergy (f ∘ sourceChildCoordinates σ) y)≤ + ∫ y in K,sourcePhysicalEnergy f (sourceChildCoordinates σ y) := by + apply integral_mono + ((continuous_sourcePhysicalEnergy hfc).continuousOn.integrableOn_compact hK) + (((continuous_sourcePhysicalEnergy hf).comp (sourceChildCoordinates_contDiff σ).continuous).continuousOn.integrableOn_compact hK) + (sourceChild_energy hf σ) + have he := integral_sourceChild_preimage σ centralPhysical_compact (sourcePhysicalEnergy f) + change (∫ y in K,sourcePhysicalEnergy f (sourceChildCoordinates σ y))=_ at he + rw [he] at hmono + exact hh.trans (by + have hm := mul_le_mul_of_nonneg_left hmono (show 0≤(1+1/centralThickness)*physicalRayConstant by + have := physicalRayConstant_pos; norm_num [centralThickness]; positivity) + simpa [centralTraceConstant,mul_assoc] using hm) + +def centralBoundary (i : Fin 3) (x : UnitAddTorus (Fin 2)) : Box3 := + sourcePairCoordinates (![sourceAngularCollar centralThickness x, + sourceChildCoordinates 1 (sourceAngularCollar (-centralThickness) x), + sourceChildCoordinates (-1) (sourceAngularCollar (-centralThickness) x)] i) + +lemma continuous_centralBoundary (i : Fin 3) : Continuous (centralBoundary i) := by + fin_cases i <;> apply sourcePairCLE.continuous.comp + · exact continuous_sourceAngularCollar _ + · exact (sourceChildCoordinates_contDiff 1).continuous.comp (continuous_sourceAngularCollar _) + · exact (sourceChildCoordinates_contDiff (-1)).continuous.comp (continuous_sourceAngularCollar _) + +lemma central_physical_trace {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (i : Fin 3) : + (∫ x : UnitAddTorus (Fin 2),(f (centralBoundary i x))^2)≤ + centralTraceConstant*(∫ z in centralClosed,192*cubeEnergyDensity f z+2*(f z)^2) := by + have hfc : ContDiff ℝ (↑(⊤ : ℕ∞)) (f ∘ sourcePairCoordinates) := hf.comp sourcePairCLE.contDiff + have ht : (∫ x : UnitAddTorus (Fin 2),(f (centralBoundary i x))^2)≤ + centralTraceConstant*(∫ y in centralPhysical,sourcePhysicalEnergy (f ∘ sourcePairCoordinates) y) := by + fin_cases i + · exact central_parent_trace hfc + · exact central_child_trace hfc (Or.inl rfl) + · exact central_child_trace hfc (Or.inr rfl) + have hm : (∫ y in centralPhysical,sourcePhysicalEnergy (f ∘ sourcePairCoordinates) y)≤ + ∫ y in centralPhysical,192*cubeEnergyDensity f (sourcePairCoordinates y)+2*(f (sourcePairCoordinates y))^2 := by + apply integral_mono + ((continuous_sourcePhysicalEnergy hfc).continuousOn.integrableOn_compact centralPhysical_compact) + (((continuous_const.mul ((continuous_cubeEnergyDensity hf).comp sourcePairCLE.continuous)).add + (continuous_const.mul ((hf.continuous.comp sourcePairCLE.continuous).pow 2))).continuousOn.integrableOn_compact centralPhysical_compact) + (sourcePair_energy hf) + rw [integral_centralPhysical (fun z => 192*cubeEnergyDensity f z+2*(f z)^2)] at hm + exact ht.trans (mul_le_mul_of_nonneg_left hm centralTraceConstant_pos.le) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalVariational.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalVariational.lean new file mode 100644 index 0000000000000000000000000000000000000000..4d63fa2b40baa18219b1408403467dc5bf8845c7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPhysicalVariational.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralCoercivitySmooth + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +@[instance_reducible] def centralEnergy_inner (s : Fin 3 → ℝ) : InnerProductSpace ℝ (centralEnergySpace s) := + Submodule.innerProductSpace (centralEnergySpace s) + +def centralCoercivityConstant (s : Fin 3 → ℝ) : ℝ := + 1+‖centralAmbientQ s‖^2*centralCoercivityBase + +lemma centralCoercivityConstant_pos (s : Fin 3 → ℝ) : 00, + Metric.ball x r⊆Metric.ball a (R/4) ∧ HarmonicPairRegularOn (g 0) (g 1) (Metric.ball x r) := by + obtain ⟨p,hm,hv,hw,hreg⟩ := central_pair_regular_exists s + refine ⟨p,hm,hv,?_⟩ + intro a R hR hball + obtain ⟨ha,hr⟩ := hreg a R hR hball + let g : Fin 2 → R3 → ℝ := fun j => radialMollify (centralWholeL2 (centralAmbientComponent s 0 (p j).val)) (R/4) + have hgs (j : Fin 2) : ContDiff ℝ (↑(⊤ : ℕ∞)) (g j) := (weakWeyl_local (hw j) hR hball).1 + have hU : Metric.ball a (R/4)⊆centralEuclideanCLE ⁻¹' centralClosed := by + intro x hx + exact (hball (Metric.ball_subset_closedBall + (Metric.ball_subset_ball (by linarith : R/4≤R) hx))).1 + exact ⟨g,fun j => ⟨hgs j,(ha j).1⟩,fun j => (ha j).2, + fun j => central_smooth_representative_jets s (p j) Metric.isOpen_ball hU (g j) (hgs j) (ha j).2,hr⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CentralPoincare.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPoincare.lean new file mode 100644 index 0000000000000000000000000000000000000000..971119bc51720f793bccf4e67a341cbabbbefeb3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CentralPoincare.lean @@ -0,0 +1,278 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralAnchor + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory + +lemma centralTop_subset_anchor (i : Fin 4) : centralTop i ⊆ centralAnchor := by + have h : centralTop i=centralAnchorPiece i.val := by fin_cases i <;> rfl + rw [h] + exact (subset_patchCluster centralAnchorPiece i.val).trans (patchCluster_mono _ (by omega)) + +lemma centralBottom_subset_anchor (i : Fin 4) : centralBottom i ⊆ centralAnchor := by + have h : centralBottom i=centralAnchorPiece (i.val+5) := by fin_cases i <;> rfl + rw [h] + exact (subset_patchCluster centralAnchorPiece (i.val+5)).trans (patchCluster_mono _ (by omega)) + +lemma centralColumn_overlaps_anchor (i : Fin 4) (j k : Fin 5) + (hx : (centralColumn i j k).xl < (centralColumn i j k).xu) + (hy : (centralColumn i j k).yl < (centralColumn i j k).yu) : + 0 < volume.real (centralAnchor ∩ (centralColumn i j k).prism (-centralHeight) centralHeight) := by + have hh : centralChildHeight < centralHeight := by + norm_num [centralChildHeight,centralHeight,sourceScale,centralThickness] + apply ((centralColumn i j k).prism_real_pos _ _ hx hy hh).trans_le + refine measureReal_mono ?_ ?_ + · rintro z ⟨hz,ht⟩ + refine ⟨centralTop_subset_anchor i ⟨?_,ht⟩,hz,?_,ht.2⟩ + · have hh := hz + simp only [centralColumn,RectFootprint.inter_carrier,mem_inter_iff] at hh + exact hh.1.1 + · have hp : 0 ≤ centralChildHeight+centralHeight := by + norm_num [centralChildHeight,centralHeight,sourceScale,centralThickness] + linarith [ht.1] + · exact ((centralCluster_compact 8).inter ((centralColumn i j k).prism_compact _ _)).measure_ne_top + +def centralColumnConstant (i : Fin 4) (j k : Fin 5) : ℝ := + let B := (centralColumn i j k).poincareConstant (-centralHeight) centralHeight + let R := (centralColumn i j k).prism (-centralHeight) centralHeight + centralAnchorConstant+2*B+4*volume.real R/(volume.real (centralAnchor∩R))*(centralAnchorConstant+B) + +lemma centralColumnConstant_nonneg (i : Fin 4) (j k : Fin 5) : 0 ≤ centralColumnConstant i j k := by + have hA := centralAnchorConstant_nonneg + have hB := (centralColumn i j k).poincareConstant_nonneg (-centralHeight) centralHeight + dsimp [centralColumnConstant] + positivity + +lemma centralColumn_poincare (i : Fin 4) (j k : Fin 5) {f : Box3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + localVariance volume ((centralColumn i j k).prism (-centralHeight) centralHeight) f + (centralAnchorAverage 0 f) ≤ centralColumnConstant i j k*(∫ z in centralClosed,cubeEnergyDensity f z) := by + let R := (centralColumn i j k).prism (-centralHeight) centralHeight + have hc : IsCompact R := (centralColumn i j k).prism_compact _ _ + have hint : ∀ c : ℝ, IntegrableOn (fun z => (f z-c)^2) R := fun c => + ((hf.continuous.sub continuous_const).pow 2).continuousOn.integrableOn_compact hc + by_cases h : (centralColumn i j k).xl<(centralColumn i j k).xu ∧ + (centralColumn i j k).yl<(centralColumn i j k).yu + · have hiA : IntegrableOn (fun z => (f z-centralAnchorAverage 0 f)^2) centralAnchor := + ((hf.continuous.sub continuous_const).pow 2).continuousOn.integrableOn_compact (centralCluster_compact 8) + have hglue := overlap_poincare_glue volume (integral_nonneg (cubeEnergyDensity_nonneg f)) + centralAnchorConstant_nonneg ((centralColumn i j k).poincareConstant_nonneg (-centralHeight) centralHeight) + (centralCluster_compact 8).measure_ne_top hc.measure_ne_top (centralColumn_overlaps_anchor i j k h.1 h.2) + hiA (hint _) (hint _) (centralAnchor_poincare hf) + ((centralColumn i j k).poincare_in _ _ centralClosed_compact (centralColumn_subset i j k) hf) + exact (localVariance_mono volume (hiA.union (hint _)) (subset_union_right : R⊆centralAnchor∪R)).trans hglue + · have hz : volume R=0 := by + apply nonpos_iff_eq_zero.mp + apply le_of_not_gt + intro hp + have hh := ((centralColumn i j k).prism_volume_pos _ _).mp hp + exact h ⟨hh.1,hh.2.1⟩ + have hv : localVariance volume R f (centralAnchorAverage 0 f)=0 := by + simp [localVariance,Measure.restrict_eq_zero.mpr hz] + change localVariance volume R f (centralAnchorAverage 0 f) ≤ _ + rw [hv] + exact mul_nonneg (centralColumnConstant_nonneg i j k) (integral_nonneg (cubeEnergyDensity_nonneg f)) + +lemma localVariance_finset_union_le {X ι : Type*} [MeasurableSpace X] (μ : Measure X) + (s : Finset ι) (Q : ι → Set X) {f : X → ℝ} {a : ℝ} + (hi : ∀ i∈s,IntegrableOn (fun z => (f z-a)^2) (Q i) μ) : + localVariance μ (⋃ i∈s,Q i) f a ≤ ∑ i∈s,localVariance μ (Q i) f a := by + classical + induction s using Finset.induction_on with + | empty => simp [localVariance] + | @insert i s hin ih => + have his : ∀ j∈s,IntegrableOn (fun z => (f z-a)^2) (Q j) μ := fun j hj => hi j (Finset.mem_insert_of_mem hj) + have h_union : IntegrableOn (fun z => (f z-a)^2) (⋃ j∈s,Q j) μ := by + exact integrableOn_finset_iUnion.mpr his + simpa only [Finset.set_biUnion_insert,Finset.sum_insert hin] using + (localVariance_union_le μ (hi i (Finset.mem_insert_self _ _)) h_union).trans + (add_le_add_right (ih his) _) + +def centralPoincareConstant : ℝ := centralAnchorConstant+ + ∑ i : Fin 4,∑ j : Fin 5,∑ k : Fin 5,centralColumnConstant i j k + +lemma centralPoincareConstant_nonneg : 0 ≤ centralPoincareConstant := by + apply add_nonneg centralAnchorConstant_nonneg + exact Finset.sum_nonneg (fun i _ => Finset.sum_nonneg (fun j _ => + Finset.sum_nonneg (fun k _ => centralColumnConstant_nonneg i j k))) + +theorem central_physical_poincare {f : Box3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + localVariance volume centralClosed f (centralAnchorAverage 0 f) ≤ + centralPoincareConstant*(∫ z in centralClosed,cubeEnergyDensity f z) := by + let Q : (Fin 4×Fin 5×Fin 5) → Set Box3 := fun p => + (centralColumn p.1 p.2.1 p.2.2).prism (-centralHeight) centralHeight + let U := ⋃ p,Q p + have hu : IsCompact U := isCompact_iUnion (fun p => (centralColumn p.1 p.2.1 p.2.2).prism_compact _ _) + have hiu : IntegrableOn (fun z => (f z-centralAnchorAverage 0 f)^2) U := + ((hf.continuous.sub continuous_const).pow 2).continuousOn.integrableOn_compact hu + have hia : IntegrableOn (fun z => (f z-centralAnchorAverage 0 f)^2) centralAnchor := + ((hf.continuous.sub continuous_const).pow 2).continuousOn.integrableOn_compact (centralCluster_compact 8) + have hsub : centralClosed⊆centralAnchor∪U := by + rw [centralClosed_cover] + rintro z ((ht|hb)|hc) + · obtain ⟨i,hi⟩ := mem_iUnion.mp ht + exact Or.inl (centralTop_subset_anchor i hi) + · obtain ⟨i,hi⟩ := mem_iUnion.mp hb + exact Or.inl (centralBottom_subset_anchor i hi) + · obtain ⟨i,hi⟩ := mem_iUnion.mp hc + obtain ⟨j,hj⟩ := mem_iUnion.mp hi + obtain ⟨k,hk⟩ := mem_iUnion.mp hj + exact Or.inr (mem_iUnion.mpr ⟨(i,j,k),hk⟩) + have hv := localVariance_finset_union_le volume Finset.univ Q + (fun p _ => ((hf.continuous.sub continuous_const).pow 2).continuousOn.integrableOn_compact + ((centralColumn p.1 p.2.1 p.2.2).prism_compact _ _)) (a := centralAnchorAverage 0 f) + simp only [Finset.mem_univ,iUnion_true, Fintype.sum_prod_type] at hv + have hb := Finset.sum_le_sum (s := Finset.univ) (fun i _ => + Finset.sum_le_sum (s := Finset.univ) (fun j _ => + Finset.sum_le_sum (s := Finset.univ) (fun k _ => centralColumn_poincare i j k hf))) + calc localVariance volume centralClosed f (centralAnchorAverage 0 f) + ≤ localVariance volume centralAnchor f (centralAnchorAverage 0 f)+localVariance volume U f (centralAnchorAverage 0 f) := + (localVariance_mono volume (hia.union hiu) hsub).trans (localVariance_union_le volume hia hiu) + _ ≤ centralAnchorConstant*(∫ z in centralClosed,cubeEnergyDensity f z)+ + (∑ i : Fin 4,∑ j : Fin 5,∑ k : Fin 5,centralColumnConstant i j k*(∫ z in centralClosed,cubeEnergyDensity f z)) := + add_le_add (centralAnchor_poincare hf) (hv.trans hb) + _ = centralPoincareConstant*(∫ z in centralClosed,cubeEnergyDensity f z) := by + simp only [centralPoincareConstant,add_mul,Finset.sum_mul] + +open Set MeasureTheory +open scoped ENNReal + +def centralMeasure : Measure Box3 := volume.restrict centralClosed + +instance centralMeasure_finite : IsFiniteMeasure centralMeasure := by + constructor + simpa [centralMeasure] using centralClosed_compact.measure_lt_top + +def centralSmoothFunctions : Submodule ℝ (Box3 → ℝ) where + carrier := {f | ContDiff ℝ (↑(⊤ : ℕ∞)) f} + zero_mem' := by change ContDiff ℝ (↑(⊤ : ℕ∞)) (fun _ : Box3 => (0 : ℝ)); exact contDiff_const + add_mem' := by + intro f g hf hg + exact (show ContDiff ℝ (↑(⊤ : ℕ∞)) f from hf).add (show ContDiff ℝ (↑(⊤ : ℕ∞)) g from hg) + smul_mem' := by + intro c f hf + exact (show ContDiff ℝ (↑(⊤ : ℕ∞)) f from hf).const_smul c + +instance : CoeFun centralSmoothFunctions (fun _ => Box3 → ℝ) := ⟨fun f => f.val⟩ + +lemma central_smooth (f : centralSmoothFunctions) : ContDiff ℝ (↑(⊤ : ℕ∞)) f := f.property + +abbrev CentralL2 := Lp ℝ 2 centralMeasure +abbrev CentralJets := PiLp 2 (fun _ : Fin 4 => CentralL2) +abbrev CentralGradients := PiLp 2 (fun _ : Fin 3 => CentralL2) + +lemma central_continuous_memLp {f : Box3 → ℝ} (hf : Continuous f) : MemLp f 2 centralMeasure := by + exact (memLp_two_iff_integrable_sq hf.aestronglyMeasurable).mpr + ((hf.pow 2).continuousOn.integrableOn_compact centralClosed_compact) + +def centralJetField (f : Box3 → ℝ) (i : Fin 4) : Box3 → ℝ := + ![f,cubePartial f ((1,0),0),cubePartial f ((0,1),0),cubePartial f ((0,0),1)] i + +lemma centralJetField_continuous (f : centralSmoothFunctions) (i : Fin 4) : + Continuous (centralJetField f i) := by + fin_cases i + · exact (central_smooth f).continuous + · exact continuous_cubePartial (central_smooth f) _ + · exact continuous_cubePartial (central_smooth f) _ + · exact continuous_cubePartial (central_smooth f) _ + +def centralSmoothJet (f : centralSmoothFunctions) : CentralJets := + WithLp.toLp 2 (fun i => (central_continuous_memLp (centralJetField_continuous f i)).toLp (centralJetField f i)) + +lemma centralSmoothJet_ae (f : centralSmoothFunctions) (i : Fin 4) : + centralSmoothJet f i=ᵐ[centralMeasure] centralJetField f i := (central_continuous_memLp (centralJetField_continuous f i)).coeFn_toLp + +lemma centralJetField_add (f g : centralSmoothFunctions) (i : Fin 4) : + centralJetField (f+g) i=centralJetField f i+centralJetField g i := by + funext z + have he := fderiv_add ((central_smooth f).differentiable (by simp) z) ((central_smooth g).differentiable (by simp) z) + change fderiv ℝ (fun y => f y+g y) z=_ at he + fin_cases i + · rfl + · change (fderiv ℝ (fun y => f y+g y) z) ((1,0),0)=_ + rw [he]; rfl + · change (fderiv ℝ (fun y => f y+g y) z) ((0,1),0)=_ + rw [he]; rfl + · change (fderiv ℝ (fun y => f y+g y) z) ((0,0),1)=_ + rw [he]; rfl + +lemma centralJetField_smul (c : ℝ) (f : centralSmoothFunctions) (i : Fin 4) : + centralJetField (c•f) i=c•centralJetField f i := by + funext z + have he := fderiv_const_smul ((central_smooth f).differentiable (by simp) z) c + change fderiv ℝ (fun y => c • f y) z=_ at he + fin_cases i + · rfl + · change (fderiv ℝ (fun y => c • f y) z) ((1,0),0)=_ + rw [he]; rfl + · change (fderiv ℝ (fun y => c • f y) z) ((0,1),0)=_ + rw [he]; rfl + · change (fderiv ℝ (fun y => c • f y) z) ((0,0),1)=_ + rw [he]; rfl + +def centralSmoothJetL : centralSmoothFunctions →ₗ[ℝ] CentralJets where + toFun := centralSmoothJet + map_add' := by + intro f g + apply PiLp.ext; intro i; apply Lp.ext + filter_upwards [centralSmoothJet_ae (f+g) i,centralSmoothJet_ae f i,centralSmoothJet_ae g i, + Lp.coeFn_add (centralSmoothJet f i) (centralSmoothJet g i)] with z hz hf hg ha + change (centralSmoothJet (f+g) i) z=((centralSmoothJet f i)+(centralSmoothJet g i)) z + rw [hz,ha] + simp only [Pi.add_apply,hf,hg] + exact congrFun (centralJetField_add f g i) z + map_smul' := by + intro c f + apply PiLp.ext; intro i; apply Lp.ext + filter_upwards [centralSmoothJet_ae (c•f) i,centralSmoothJet_ae f i, + Lp.coeFn_smul c (centralSmoothJet f i)] with z hz hf ha + change (centralSmoothJet (c•f) i) z=(c•(centralSmoothJet f i)) z + rw [hz,ha] + simp only [Pi.smul_apply,hf] + exact congrFun (centralJetField_smul c f i) z + +def centralJetD : CentralJets →L[ℝ] CentralGradients := + (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => CentralL2)).symm.toContinuousLinearMap.comp + (ContinuousLinearMap.pi (fun i : Fin 3 => PiLp.proj 2 (fun _ : Fin 4 => CentralL2) i.succ)) + +lemma centralSmoothJet_norm_coordinate (f : centralSmoothFunctions) (i : Fin 4) : + ‖centralSmoothJet f i‖^2=∫ z in centralClosed,(centralJetField f i z)^2 := by + rw [←real_inner_self_eq_norm_sq,L2.inner_def] + apply integral_congr_ae + filter_upwards [centralSmoothJet_ae f i] with z hz + simp [hz,pow_two] + +lemma centralSmoothJet_gradient_norm (f : centralSmoothFunctions) : + ‖centralJetD (centralSmoothJet f)‖^2=∫ z in centralClosed,cubeEnergyDensity f z := by + rw [PiLp.norm_sq_eq_of_L2] + change (∑ i : Fin 3,‖centralSmoothJet f i.succ‖^2)=_ + simp only [centralSmoothJet_norm_coordinate] + have h0 := (central_continuous_memLp (continuous_cubePartial (central_smooth f) ((1,0),0))).integrable_sq + have h1 := (central_continuous_memLp (continuous_cubePartial (central_smooth f) ((0,1),0))).integrable_sq + have h2 := (central_continuous_memLp (continuous_cubePartial (central_smooth f) ((0,0),1))).integrable_sq + dsimp [centralMeasure] at h0 h1 h2 + simp only [Fin.sum_univ_succ,Fin.isValue,centralJetField,Matrix.cons_val_zero,Matrix.cons_val_succ, + Fin.sum_univ_zero,add_zero] + unfold cubeEnergyDensity + have ha := integral_add h0 h1 + have hb := integral_add (h0.add h1) h2 + simp only [Pi.add_apply] at ha hb + rw [hb,ha] + ring + +lemma centralSmoothJet_norm (f : centralSmoothFunctions) : + ‖centralSmoothJet f‖^2=(∫ z in centralClosed,(f z)^2)+‖centralJetD (centralSmoothJet f)‖^2 := by + rw [PiLp.norm_sq_eq_of_L2,Fin.sum_univ_succ] + rw [centralSmoothJet_norm_coordinate] + congr 1 + exact (PiLp.norm_sq_eq_of_L2 _ (centralJetD (centralSmoothJet f))).symm + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ChildCompletionJoin.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ChildCompletionJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..dec33283b74f54b716bfc74c9e1e50d4fa910c00 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ChildCompletionJoin.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ChildLocalizedJet + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 ring) + dsimp only at hwe + rw [central_child_trace_eq s k f] at hwe + have he : childLocalJetCLM s hs ha k hχ hc (centralEmbedL s f)=w.val := by + apply Lp.ext + filter_upwards [childLocalJetCLM_smooth_ae s hs ha k hχ hc hχs f,hwe] with x hx hwx + rw [hx] + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact hwx.1.symm + · exact (hwx.2 j).symm + rw [he] + exact hw + +include hχb hχs in + +theorem childLocalJetCLM_central_H10 (u : centralEnergySpace s) : + childLocalJetCLM s hs ha k hχ hc u.val∈zeroTraceAmbient := by + let T := (zeroTraceAmbient.comap (childLocalJetCLM s hs ha k hχ hc).toLinearMap) + have ht : IsClosed (T : Set (CentralAmbient s)) := + (Submodule.isClosed_topologicalClosure (Submodule.span ℝ compactSmoothJets)).preimage + (childLocalJetCLM s hs ha k hχ hc).continuous + have hr : LinearMap.range (centralEmbedL s)≤T := by + rintro z ⟨f,rfl⟩ + exact childLocalJetCLM_smooth_H10 s hs ha k hχ hc hχb hχs f + exact (Submodule.topologicalClosure_minimal _ hr ht) u.property + +def childCompletionJoin : centralEnergySpace s →L[ℝ] H1 := + ((childLocalJetCLM s hs ha k hχ hc).comp (centralEnergySpace s).subtypeL).codRestrict H1Space + (fun u => zeroTraceAmbient_le_H1Space (childLocalJetCLM_central_H10 s hs ha k hχ hc hχb hχs u)) + +lemma childCompletionJoin_mem_H10 (u : centralEnergySpace s) : + childCompletionJoin s hs ha k hχ hc hχb hχs u∈H10 := + childLocalJetCLM_central_H10 s hs ha k hχ hc hχb hχs u + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ChildFullEndH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ChildFullEndH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..38ce6e7c52bb2ad37e85b197e379ceec1225c0e0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ChildFullEndH1.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentFullEndEnergy +import OAI.Analysis.Conductivity.Branching.ChildEndPartition + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem childFullEnd_H10 (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 + if WithLp.toLp 2 y∈ball then u.val.val (WithLp.toLp 2 y) else 0 + have hj := childTransportJetCLM_ae_of_ae k u.val.val f + (ballWholePiJetCLM_ae_of_ae u.val.val + (fun y => u.val.val (WithLp.toLp 2 y)) (by filter_upwards [] with x; rfl)) + have he₀ := (ae_restrict_iff' (show MeasurableSet ball from + Metric.isOpen_ball.measurableSet)).mp he + have he₁ := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae he₀ + have he₂ := (sourceChildInverse_quasi (actualChildSign k)).ae he₁ + have he₃ := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae he₂) + filter_upwards [hj,he₃] with x hj hx hm + have hb := hD _ hm + have hloc := hx hb hm + constructor + · change (childTransportJetCLM k u.val.val x) 0=_ + rw [hj] + change (f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))) 0=_ + rw [show f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))= + u.val.val (WithLp.toLp 2 ((sourceChildHomeomorph (actualChildSign k)).symm + (WithLp.ofLp x))) from ite_eq_left hb] + exact hloc.1 + · intro i + change (childTransportJetCLM k u.val.val x) i.succ=_ + rw [hj] + change sourceScale⁻¹*(f ((sourceChildHomeomorph (actualChildSign k)).symm + (WithLp.ofLp x))) (childAxis i).succ=_ + rw [show f ((sourceChildHomeomorph (actualChildSign k)).symm (WithLp.ofLp x))= + u.val.val (WithLp.toLp 2 ((sourceChildHomeomorph (actualChildSign k)).symm + (WithLp.ofLp x))) from ite_eq_left hb] + exact congrArg (fun q : ℝ => sourceScale⁻¹*q) (hloc.2 (childAxis i)) + +theorem physicalChildFullEnd_H10 (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 dsimp [centralThickness] at * <;> linarith [hy.1,hy.2] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ChildH10Transport.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ChildH10Transport.lean new file mode 100644 index 0000000000000000000000000000000000000000..0e7f72d6ec2a2dbe1dec26528b1b1dbc2ca6fb80 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ChildH10Transport.lean @@ -0,0 +1,246 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.ChildCompletionJoin +import OAI.Analysis.Conductivity.Branching.ChildInverse +import OAI.Analysis.Conductivity.Variational.WholeBallJet + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology + +lemma gradient_apply_single (f : R3 → ℝ) (x : R3) (i : Fin 3) : + gradient f x i=fderiv ℝ f x (EuclideanSpace.single i 1) := by + rw [←toDual_gradient,InnerProductSpace.toDual_apply_apply,EuclideanSpace.inner_single_right] + simp + +lemma sourceChildEuclidean_symm_gradient (σ : ℝ) {f : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (x : R3) (i : Fin 3) : + gradient (f ∘ (sourceChildEuclidean σ).symm) x i= + sourceScale⁻¹*gradient f ((sourceChildEuclidean σ).symm x) (childAxis i) := by + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hD := E.symm.hasFDerivAt.comp (E x) (sourceChildInverse_hasFDeriv σ (E x)) + have hC := (hf.differentiable (by simp) ((sourceChildEuclidean σ).symm x)).hasFDerivAt.comp x + (hD.comp x E.hasFDerivAt) + have hi : E.toContinuousLinearMap (EuclideanSpace.single i 1)=Pi.single i 1 := rfl + have hj : E.symm.toContinuousLinearMap (Pi.single (childAxis i) 1)=EuclideanSpace.single (childAxis i) 1 := rfl + rw [gradient_apply_single,gradient_apply_single] + rw [hC.fderiv,ContinuousLinearMap.comp_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.comp_apply,hi,sourceChildInverse_single,map_smul,hj,map_smul,smul_eq_mul] + +def childTransportComponentCLM (k : Fin 2) (i : Fin 4) : JetSpace →L[ℝ] + Lp ℝ 2 (volume : Measure (Fin 3 → ℝ)) := + Fin.cases ((sourceChildPushforwardCLM (actualChildSign k)).comp (ballWholePiComponentCLM 0)) + (fun j => sourceScale⁻¹ • ((sourceChildPushforwardCLM (actualChildSign k)).comp + (ballWholePiComponentCLM (childAxis j).succ))) i + +def childTransportJetCLM (k : Fin 2) : JetSpace →L[ℝ] JetSpace := + physicalFourJetCLM.comp (ContinuousLinearMap.pi (childTransportComponentCLM k)) + +lemma childTransportComponentCLM_smooth_ae (k : Fin 2) (f : R3 → ℝ) + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hs : tsupport f⊆ball) (i : Fin 4) : + childTransportComponentCLM k i (smoothH1 f hf).val=ᵐ[volume] + (fun y => smoothJet (f ∘ (sourceChildEuclidean (actualChildSign k)).symm) (WithLp.toLp 2 y) i) := by + refine Fin.cases ?_ (fun j => ?_) i + · change sourceChildPushforwardCLM (actualChildSign k) (ballWholePiComponentCLM 0 (smoothH1 f hf).val)=ᵐ[volume] _ + apply (sourceChildPushforwardCLM_ae _ _).trans + apply ((sourceChildInverse_quasi _).ae_eq_comp (ballWholePiComponentCLM_smooth_ae f hf hs 0)).trans + exact Filter.Eventually.of_forall (fun y => rfl) + · simp only [childTransportComponentCLM,Fin.cases_succ,smul_apply, + ContinuousLinearMap.comp_apply] + apply (Lp.coeFn_smul _ _).trans + have he := (sourceChildPushforwardCLM_ae (actualChildSign k) + (ballWholePiComponentCLM (childAxis j).succ (smoothH1 f hf).val)).trans + ((sourceChildInverse_quasi _).ae_eq_comp (ballWholePiComponentCLM_smooth_ae f hf hs (childAxis j).succ)) + filter_upwards [he] with y hy + simp only [Pi.smul_apply,smul_eq_mul,hy,smoothJet,Fin.cases_succ,WithLp.ofLp_toLp] + exact (sourceChildEuclidean_symm_gradient (actualChildSign k) hf (WithLp.toLp 2 y) j).symm + +lemma childTransportJetCLM_smooth (k : Fin 2) (f : R3 → ℝ) + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (hs : tsupport f⊆ball) : + childTransportJetCLM k (smoothH1 f hf).val= + (smoothH1 (f ∘ (sourceChildEuclidean (actualChildSign k)).symm) + (hf.comp (sourceChildEuclidean_symm_contDiff _))).val := by + apply Lp.ext + have he (i : Fin 4) := ae_restrict_of_ae (s:=ball) + ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (childTransportComponentCLM_smooth_ae k f hf hs i)) + filter_upwards [physicalFourJetCLM_ae (fun i => childTransportComponentCLM k i (smoothH1 f hf).val), + ae_all_iff.mpr he,(smoothJet_memLp (hf.comp (sourceChildEuclidean_symm_contDiff (actualChildSign k)))).coeFn_toLp] with x hx hi hf' + change physicalFourJetCLM (fun i => childTransportComponentCLM k i (smoothH1 f hf).val) x=_ + change (smoothH1 (f ∘ (sourceChildEuclidean (actualChildSign k)).symm) + (hf.comp (sourceChildEuclidean_symm_contDiff _))).val x=_ at hf' + rw [hx,hf'] + ext i + exact hi i + +lemma childTransportJetCLM_H10 (k : Fin 2) {z : JetSpace} (hz : z∈zeroTraceAmbient) : + childTransportJetCLM k z∈zeroTraceAmbient := by + let T := zeroTraceAmbient.comap (childTransportJetCLM k).toLinearMap + have ht : IsClosed (T : Set JetSpace) := + (Submodule.isClosed_topologicalClosure (Submodule.span ℝ compactSmoothJets)).preimage + (childTransportJetCLM k).continuous + have hs : Submodule.span ℝ compactSmoothJets≤T := by + apply Submodule.span_le.mpr + rintro z ⟨f,hf,hc,hs,hL,rfl⟩ + have he : hL.toLp (smoothJet f)=(smoothH1 f hf).val := by apply Lp.ext; exact hL.coeFn_toLp.trans (smoothJet_memLp hf).coeFn_toLp.symm + change childTransportJetCLM k (hL.toLp (smoothJet f))∈zeroTraceAmbient + rw [he,childTransportJetCLM_smooth k f hf hs] + exact smoothH1_mem_H10 _ (hf.comp (sourceChildEuclidean_symm_contDiff _)) (hc.comp_homeomorph (sourceChildEuclidean (actualChildSign k)).symm) + (sourceChildEuclidean_comp_support k hs) + exact (Submodule.topologicalClosure_minimal _ hs ht) hz + +def childH10Transport (k : Fin 2) : H10 →L[ℝ] H1 := + ((childTransportJetCLM k).comp (H1Space.subtypeL.comp H10.subtypeL)).codRestrict H1Space + (fun u => zeroTraceAmbient_le_H1Space (childTransportJetCLM_H10 k u.property)) + +lemma childH10Transport_mem_H10 (k : Fin 2) (u : H10) : childH10Transport k u∈H10 := + childTransportJetCLM_H10 k u.property + +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : 0 ((compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single j 1))).comp + (centralPhysicalWholeCLM.comp (centralAmbientComponent s 0)))+ + ((compactMultiplierCLM hχ.continuous hc).comp + (centralPhysicalWholeCLM.comp (centralAmbientComponent s j.succ)))) i + +def centralInteriorJetCLM : CentralAmbient s →L[ℝ] JetSpace := + physicalFourJetCLM.comp (ContinuousLinearMap.pi (centralInteriorComponentCLM s hχ hc)) + +lemma centralInteriorComponentCLM_smooth_value + (hχs : tsupport χ⊆centralPhysical) (f : centralSmoothFunctions) : + centralInteriorComponentCLM s hχ hc 0 (centralEmbedL s f)=ᵐ[volume] + (fun y => χ y*f (sourcePairCoordinates y)) := by + have he := compactMultiplierCLM_ae hχ.continuous hc + (centralPhysicalWholeCLM (centralSmoothJet f 0)) + filter_upwards [he,centralPhysicalWholeCLM_smooth_ae f 0] with y hy hv + change (compactMultiplierCLM hχ.continuous hc + (centralPhysicalWholeCLM (centralSmoothJet f 0))) y=_ + rw [hy,hv] + by_cases hs : y∈tsupport χ + · rw [indicator_of_mem (hχs hs)] + rfl + · rw [image_eq_zero_of_notMem_tsupport hs] + simp + +lemma centralInteriorComponentCLM_smooth_gradient + (hχs : tsupport χ⊆centralPhysical) (f : centralSmoothFunctions) (i : Fin 3) : + centralInteriorComponentCLM s hχ hc i.succ (centralEmbedL s f)=ᵐ[volume] + (fun y => fderiv ℝ (fun y => χ y*f (sourcePairCoordinates y)) y (Pi.single i 1)) := by + have hq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => f (sourcePairCoordinates y)) := + (central_smooth f).comp sourcePairCLE.contDiff + have he₀ := compactMultiplierCLM_ae ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (centralPhysicalWholeCLM (centralSmoothJet f 0)) + have he₁ := compactMultiplierCLM_ae hχ.continuous hc (centralPhysicalWholeCLM (centralSmoothJet f i.succ)) + apply (Lp.coeFn_add _ _).trans + filter_upwards [he₀,he₁,centralPhysicalWholeCLM_smooth_ae f 0, + centralPhysicalWholeCLM_smooth_ae f i.succ] with y h₀ h₁ hv hg + change (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (Pi.single i 1)) (centralPhysicalWholeCLM (centralSmoothJet f 0))) y+ + (compactMultiplierCLM hχ.continuous hc (centralPhysicalWholeCLM (centralSmoothJet f i.succ))) y=_ + rw [h₀,h₁,hv,hg] + change _=fderiv ℝ (χ*(fun y => f (sourcePairCoordinates y))) y (Pi.single i 1) + rw [fderiv_mul ((hχ.differentiable (by simp)) _) ((hq.differentiable (by simp)) _)] + simp only [add_apply,smul_apply,smul_eq_mul] + by_cases hs : y∈tsupport χ + · rw [indicator_of_mem (hχs hs),indicator_of_mem (hχs hs),central_parent_partial] + change fderiv ℝ χ y (Pi.single i 1)*f (sourcePairCoordinates y)+χ y*_ = + χ y*_+f (sourcePairCoordinates y)*fderiv ℝ χ y (Pi.single i 1) + ring + · rw [image_eq_zero_of_notMem_tsupport hs,fderiv_of_notMem_tsupport ℝ hs] + simp + +lemma centralInteriorJetCLM_smooth_H10 + (hχs : tsupport χ⊆centralPhysical) + (hχB : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) (f : centralSmoothFunctions) : + centralInteriorJetCLM s hχ hc (centralEmbedL s f)∈zeroTraceAmbient := by + let q := fun y => χ y*f (sourcePairCoordinates y) + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hq : ContDiff ℝ (↑(⊤:ℕ∞)) q := hχ.mul ((central_smooth f).comp sourcePairCLE.contDiff) + have hqe : ContDiff ℝ (↑(⊤:ℕ∞)) (q ∘ E) := hq.comp E.contDiff + have ht : tsupport (q ∘ E)⊆E ⁻¹' tsupport χ := + closure_minimal (fun y hy => subset_tsupport χ (fun hc => hy (by simp [q,hc]))) + ((isClosed_tsupport χ).preimage E.continuous) + have htB : tsupport (q ∘ E)⊆ball := fun x hx => hχB (E x) (ht hx) + have hmem := smoothH1_mem_H10 (q ∘ E) hqe ((hc.mul_right (f':=fun y => f (sourcePairCoordinates y))).comp_homeomorph E.toHomeomorph) htB + have he : centralInteriorJetCLM s hχ hc (centralEmbedL s f)=(smoothH1 (q ∘ E) hqe).val := by + apply Lp.ext + have ha₀ := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (centralInteriorComponentCLM_smooth_value s hχ hc hχs f)) + have ha₁ (i : Fin 3) := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (centralInteriorComponentCLM_smooth_gradient s hχ hc hχs f i)) + filter_upwards [physicalFourJetCLM_ae (fun i => centralInteriorComponentCLM s hχ hc i (centralEmbedL s f)), + ha₀,ae_all_iff.mpr ha₁,(smoothJet_memLp hqe).coeFn_toLp] with x hj hv hg hs + change (smoothH1 (q ∘ E) hqe).val x=smoothJet (q ∘ E) x at hs + rw [hs] + ext i + refine Fin.cases ?_ (fun j => ?_) i + · exact (congrArg (fun z : JetFiber => z 0) hj).trans hv + · exact (congrArg (fun z : JetFiber => z j.succ) hj).trans + ((hg j).trans (gradient_of_pi_function q x j ((hq.differentiable (by simp)) _)).symm) + rw [he] + exact hmem + +theorem centralInteriorJetCLM_central_H10 + (hχs : tsupport χ⊆centralPhysical) + (hχB : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) (u : centralEnergySpace s) : + centralInteriorJetCLM s hχ hc u.val∈zeroTraceAmbient := by + let T := zeroTraceAmbient.comap (centralInteriorJetCLM s hχ hc).toLinearMap + have ht : IsClosed (T : Set (CentralAmbient s)) := + (Submodule.isClosed_topologicalClosure (Submodule.span ℝ compactSmoothJets)).preimage + (centralInteriorJetCLM s hχ hc).continuous + have hr : LinearMap.range (centralEmbedL s)≤T := by + rintro z ⟨f,rfl⟩ + exact centralInteriorJetCLM_smooth_H10 s hχ hc hχs hχB f + exact (Submodule.topologicalClosure_minimal _ hr ht) u.property + +def centralInteriorCompletion (hχs : tsupport χ⊆centralPhysical) + (hχB : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) : centralEnergySpace s →L[ℝ] H1 := + ((centralInteriorJetCLM s hχ hc).comp (centralEnergySpace s).subtypeL).codRestrict H1Space + (fun u => zeroTraceAmbient_le_H1Space (centralInteriorJetCLM_central_H10 s hχ hc hχs hχB u)) + +lemma centralInteriorCompletion_mem_H10 (hχs : tsupport χ⊆centralPhysical) + (hχB : ∀ y∈tsupport χ,WithLp.toLp 2 y∈ball) (u : centralEnergySpace s) : + centralInteriorCompletion s hχ hc hχs hχB u∈H10 := + centralInteriorJetCLM_central_H10 s hχ hc hχs hχB u + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ChildH1Pullback.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ChildH1Pullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..eead43434ae8b8fbacfacae015d7e72628a7ca59 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ChildH1Pullback.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.WholeBallJetFormula +import OAI.Analysis.Conductivity.Branching.ChildTransportFormula + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +attribute [local instance] Classical.propDecidable + +lemma sourceChildEuclidean_contDiff (σ : ℝ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (sourceChildEuclidean σ : R3 → R3) := + (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).symm.contDiff.comp + ((sourceChildCoordinates_contDiff σ).comp (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).contDiff) + +lemma sourceChildEuclidean_gradient (σ : ℝ) {f : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (x : R3) (i : Fin 3) : + gradient (f ∘ sourceChildEuclidean σ) x i= + sourceScale*gradient f (sourceChildEuclidean σ x) (childAxis i) := by + let E : R3 ≃L[ℝ] Coord3 := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hD := E.symm.hasFDerivAt.comp (E x) (sourceChildCoordinates_hasFDeriv σ (E x)) + have hC := (hf.differentiable (by simp) (sourceChildEuclidean σ x)).hasFDerivAt.comp x + (hD.comp x E.hasFDerivAt) + have hi : E.toContinuousLinearMap (EuclideanSpace.single i 1)=Pi.single i 1 := rfl + have hj : E.symm.toContinuousLinearMap (Pi.single (childAxis i) 1)=EuclideanSpace.single (childAxis i) 1 := rfl + rw [gradient_apply_single,gradient_apply_single] + rw [hC.fderiv,ContinuousLinearMap.comp_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.comp_apply,hi,sourceChildDerivative_single,map_smul,hj,map_smul,smul_eq_mul] + +def childPullbackComponentCLM (k : Fin 2) (i : Fin 4) : JetSpace →L[ℝ] Lp ℝ 2 (volume : Measure Coord3) := + Fin.cases ((sourceChildPullbackCLM (actualChildSign k)).comp (ballWholePiComponentCLM 0)) + (fun j => sourceScale • ((sourceChildPullbackCLM (actualChildSign k)).comp + (ballWholePiComponentCLM (childAxis j).succ))) i + +def childPullbackJetCLM (k : Fin 2) : JetSpace →L[ℝ] JetSpace := + physicalFourJetCLM.comp (ContinuousLinearMap.pi (childPullbackComponentCLM k)) + +lemma childPullbackComponentCLM_ae (k : Fin 2) (z : JetSpace) (i : Fin 4) : + childPullbackComponentCLM k i z=ᵐ[volume] fun y => Fin.cases + (if WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) y)∈ball then + z (WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) y)) 0 else 0) + (fun j => sourceScale*(if WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) y)∈ball then + z (WithLp.toLp 2 (sourceChildCoordinates (actualChildSign k) y)) (childAxis j).succ else 0)) i := by + have he (i : Fin 4) := ballWholePiComponentCLM_ae_of_ae i z + (fun y => z (WithLp.toLp 2 y)) (by filter_upwards [] with x; rfl) + have hp (i : Fin 4) := (sourceChildPullbackCLM_ae (actualChildSign k) (ballWholePiComponentCLM i z)).trans + ((sourceChildCoordinates_quasi _).ae_eq_comp (he i)) + refine Fin.cases (hp 0) (fun j => ?_) i + apply (Lp.coeFn_smul _ _).trans + filter_upwards [hp (childAxis j).succ] with y hy + exact congrArg (fun t : ℝ => sourceScale*t) hy + +lemma childPullbackJetCLM_ae (k : Fin 2) (z : JetSpace) : + childPullbackJetCLM k z=ᵐ[ballMeasure] fun x => WithLp.toLp 2 (Fin.cases + (z (sourceChildEuclidean (actualChildSign k) x) 0) + (fun j => sourceScale*z (sourceChildEuclidean (actualChildSign k) x) (childAxis j).succ)) := by + have hi (i : Fin 4) := ae_restrict_of_ae (s:=ball) ((PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp + (childPullbackComponentCLM_ae k z i)) + filter_upwards [physicalFourJetCLM_ae (fun i => childPullbackComponentCLM k i z),ae_all_iff.mpr hi, + ae_restrict_mem Metric.isOpen_ball.measurableSet] with x hx hi hxb + change physicalFourJetCLM (fun i => childPullbackComponentCLM k i z) x=_ + rw [hx] + have hb : sourceChildEuclidean (actualChildSign k) x∈ball := sourceChildEuclidean_ball k ⟨x,hxb,rfl⟩ + ext i + have hh := hi i + change childPullbackComponentCLM k i z (WithLp.ofLp x)=Fin.cases + (if sourceChildEuclidean (actualChildSign k) x∈ball then z (sourceChildEuclidean (actualChildSign k) x) 0 else 0) + (fun j => sourceScale*(if sourceChildEuclidean (actualChildSign k) x∈ball then + z (sourceChildEuclidean (actualChildSign k) x) (childAxis j).succ else 0)) i at hh + simpa only [ite_eq_left hb] using hh + +lemma sourceChildEuclidean_quasi (σ : ℝ) : + Measure.QuasiMeasurePreserving (sourceChildEuclidean σ) volume volume := + (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.comp + ((sourceChildCoordinates_quasi σ).comp (PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving) + +lemma sourceChildEuclidean_ball_quasi (k : Fin 2) : + Measure.QuasiMeasurePreserving (sourceChildEuclidean (actualChildSign k)) ballMeasure ballMeasure := by + exact (sourceChildEuclidean_quasi _).restrict fun x hx => sourceChildEuclidean_ball k ⟨x,hx,rfl⟩ + +lemma childPullbackJetCLM_smooth (k : Fin 2) (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) : + childPullbackJetCLM k (smoothH1 f hf).val= + (smoothH1 (f ∘ sourceChildEuclidean (actualChildSign k)) (hf.comp (sourceChildEuclidean_contDiff _))).val := by + apply Lp.ext + have hh := (sourceChildEuclidean_ball_quasi k).ae_eq_comp (smoothJet_memLp hf).coeFn_toLp + filter_upwards [childPullbackJetCLM_ae k (smoothH1 f hf).val,hh, + (smoothJet_memLp (hf.comp (sourceChildEuclidean_contDiff (actualChildSign k)))).coeFn_toLp] with x hx hh hg + change (smoothH1 (f ∘ sourceChildEuclidean (actualChildSign k)) (hf.comp (sourceChildEuclidean_contDiff _))).val x=_ at hg + rw [hx,hg] + ext i + cases i using Fin.cases with + | zero => + change (smoothH1 f hf).val (sourceChildEuclidean (actualChildSign k) x) 0=f (sourceChildEuclidean (actualChildSign k) x) + exact congrArg (fun v : JetFiber => v 0) hh + | succ j => + change sourceScale*(smoothH1 f hf).val (sourceChildEuclidean (actualChildSign k) x) (childAxis j).succ=_ + change (smoothH1 f hf).val (sourceChildEuclidean (actualChildSign k) x)=_ at hh + rw [hh] + exact (sourceChildEuclidean_gradient _ hf x j).symm + +lemma childPullbackJetCLM_H1 (k : Fin 2) {z : JetSpace} (hz : z∈H1Space) : + childPullbackJetCLM k z∈H1Space := by + let T := H1Space.comap (childPullbackJetCLM k).toLinearMap + have ht : IsClosed (T : Set JetSpace) := H1_isClosed.preimage (childPullbackJetCLM k).continuous + have hs : Submodule.span ℝ smoothJets≤T := by + apply Submodule.span_le.mpr + rintro z ⟨f,hf,hm,rfl⟩ + have he : hm.toLp (smoothJet f)=(smoothH1 f hf).val := by + apply Lp.ext; exact hm.coeFn_toLp.trans (smoothJet_memLp hf).coeFn_toLp.symm + change childPullbackJetCLM k (hm.toLp (smoothJet f))∈H1Space + rw [he,childPullbackJetCLM_smooth k f hf] + exact (smoothH1 _ _).property + exact (Submodule.topologicalClosure_minimal _ hs ht) hz + +def childH1Pullback (k : Fin 2) : H1 →L[ℝ] H1 := + ((childPullbackJetCLM k).comp H1Space.subtypeL).codRestrict H1Space + (fun u => childPullbackJetCLM_H1 k u.property) + +lemma childH1Pullback_smooth (k : Fin 2) (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) : + childH1Pullback k (smoothH1 f hf)= + smoothH1 (f ∘ sourceChildEuclidean (actualChildSign k)) (hf.comp (sourceChildEuclidean_contDiff _)) := + Subtype.ext (childPullbackJetCLM_smooth k f hf) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CollarLpPullback.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CollarLpPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..1e13dc8beb14699351cd9e74857b0d0b644f8658 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CollarLpPullback.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.CollarMeasureTransport +import OAI.Analysis.Conductivity.Fourier.CollarAngularInverse + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +abbrev sourceCylinderMeasure (l r : ℝ) : Measure (ℝ×UnitAddTorus (Fin 2)) := + (volume.restrict (Ioc l r)).prod + (Measure.pi (fun _ : Fin 2 => (AddCircle.haarAddCircle : Measure UnitAddCircle))) + +lemma sourceCylinderMeasure_eq (l r : ℝ) : sourceCylinderMeasure l r = + (volume.restrict (Ioc l r)).prod (volume : Measure (UnitAddTorus (Fin 2))) := by + apply congrArg (Measure.prod (volume.restrict (Ioc l r))) + change Measure.pi (fun _ : Fin 2 => AddCircle.haarAddCircle)= + Measure.pi (fun _ : Fin 2 => (volume : Measure UnitAddCircle)) + simp_rw [AddCircle.volume_eq_smul_haarAddCircle] + simp + +def sourcePhysicalCoordinates (y : Fin 3 → ℝ) : ℝ×UnitAddTorus (Fin 2) := + (sourceCollarTime y,sourcePhysicalAngles y) + +lemma measurable_sourcePhysicalCoordinates : Measurable sourcePhysicalCoordinates := by + have ht : Continuous sourceCollarTime := by + unfold sourceCollarTime sourceCrossCoordinates sourceRadial + fun_prop + exact ht.measurable.prodMk measurable_sourcePhysicalAngles + +lemma sourcePhysicalCoordinates_angular {t : ℝ} (ht : t∈Icc (-(1:ℝ)/100) (1/100)) + (θ : UnitAddTorus (Fin 2)) : + sourcePhysicalCoordinates (sourceAngularCollar t θ)=(t,θ) := by + exact Prod.ext (sourceAngular_time ht θ) (sourcePhysicalAngles_angular ht θ) + +lemma sourcePhysicalCoordinates_measurePreserving {l r : ℝ} + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + MeasurePreserving sourcePhysicalCoordinates (sourceAngularCollarMeasure l r) + (sourceCylinderMeasure l r) := by + refine ⟨measurable_sourcePhysicalCoordinates,?_⟩ + unfold sourceAngularCollarMeasure + rw [←sourceCylinderMeasure_eq] + rw [Measure.map_map measurable_sourcePhysicalCoordinates continuous_uncurry_sourceAngularCollar.measurable] + have he : sourcePhysicalCoordinates ∘ Function.uncurry sourceAngularCollar=ᵐ[sourceCylinderMeasure l r] id := by + have ht : ∀ᵐ z∂sourceCylinderMeasure l r,z.1∈Ioc l r := + Measure.quasiMeasurePreserving_fst.ae (ae_restrict_mem measurableSet_Ioc) + filter_upwards [ht] with z hz + exact sourcePhysicalCoordinates_angular ⟨hl.trans hz.1.le,hz.2.trans hr⟩ z.2 + rw [Measure.map_congr he,Measure.map_id] + +def sourceCollarPullback {l r : ℝ} (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) : + Lp ℂ 2 (sourceCylinderMeasure l r) →L[ℝ] + Lp ℂ 2 (sourcePhysicalCollarMeasure l r) := + (Lp.LpToLpOfMeasureLeSMul ENNReal.ofReal_ne_top (sourcePhysicalCollarMeasure_le hlr hl hr)).comp + (Lp.compMeasurePreservingₗᵢ ℝ sourcePhysicalCoordinates + (sourcePhysicalCoordinates_measurePreserving hl hr)).toContinuousLinearMap + +lemma sourceCollarPullback_ae {l r : ℝ} (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) (f : Lp ℂ 2 (sourceCylinderMeasure l r)) : + sourceCollarPullback hlr hl hr f=ᵐ[sourcePhysicalCollarMeasure l r] + f ∘ sourcePhysicalCoordinates := by + have h0 := Lp.coeFn_LpToLpOfMeasureLeSMul ENNReal.ofReal_ne_top + (sourcePhysicalCollarMeasure_le hlr hl hr) + ((Lp.compMeasurePreservingₗᵢ ℝ sourcePhysicalCoordinates + (sourcePhysicalCoordinates_measurePreserving hl hr)) f) + have h1 := Lp.coeFn_compMeasurePreserving f (sourcePhysicalCoordinates_measurePreserving hl hr) + exact h0.trans ((Measure.absolutelyContinuous_of_le_smul + (sourcePhysicalCollarMeasure_le hlr hl hr)).ae_eq h1) + +lemma sourceCollarPullback_ae_of_ae {l r : ℝ} (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) (f : Lp ℂ 2 (sourceCylinderMeasure l r)) + {g : (ℝ×UnitAddTorus (Fin 2)) → ℂ} (hg : f=ᵐ[sourceCylinderMeasure l r] g) : + sourceCollarPullback hlr hl hr f=ᵐ[sourcePhysicalCollarMeasure l r] + g ∘ sourcePhysicalCoordinates := by + apply (sourceCollarPullback_ae hlr hl hr f).trans + exact (Measure.absolutelyContinuous_of_le_smul (sourcePhysicalCollarMeasure_le hlr hl hr)).ae_eq + ((sourcePhysicalCoordinates_measurePreserving hl hr).quasiMeasurePreserving.ae_eq_comp hg) + +lemma sourceCollarPullback_hasSum {l r : ℝ} (hlr : l≤r) + (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) {ι : Type*} + {F : ι → Lp ℂ 2 (sourceCylinderMeasure l r)} {f : Lp ℂ 2 (sourceCylinderMeasure l r)} + (hf : HasSum F f) : + HasSum (fun i => sourceCollarPullback hlr hl hr (F i)) + (sourceCollarPullback hlr hl hr f) := + (sourceCollarPullback hlr hl hr).hasSum hf + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CompactLipschitzH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CompactLipschitzH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..58270dc760b555cb36df52285a494c388a2e0c8c --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CompactLipschitzH1.lean @@ -0,0 +1,179 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CompactBridge + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped NNReal + +lemma lipschitz_weakDirection {C : ℝ≥0} {f : R3 → ℝ} + (hf : LipschitzWith C f) (v : R3) : + WeakL2Direction f (fun x => lineDeriv ℝ f x v) v := by + intro ψ hψ hc + obtain ⟨D,hD⟩ := ContDiff.lipschitzWith_of_hasCompactSupport hc hψ (by simp) + have he := hf.integral_lineDeriv_mul_eq (μ := volume) hD hc v + have hd (x : R3) : lineDeriv ℝ ψ x (-v)= -(fderiv ℝ ψ x v) := by + rw [(hψ.differentiable (by simp)).differentiableAt.lineDeriv_eq_fderiv,map_neg] + simp_rw [hd,neg_mul,integral_neg,mul_comm (fderiv ℝ ψ _ v)] at he + linarith + +lemma WeakL2Direction.congr {f g f' g' : R3 → ℝ} {v : R3} + (hw : WeakL2Direction f g v) (hf : f'=ᵐ[volume] f) (hg : g'=ᵐ[volume] g) : + WeakL2Direction f' g' v := by + intro ψ hψ hc + calc + _ = ∫ x, f x*fderiv ℝ ψ x v := integral_congr_ae (by + filter_upwards [hf] with x hx; rw [hx]) + _ = -(∫ x, g x*ψ x) := hw ψ hψ hc + _ = _ := congrArg Neg.neg (integral_congr_ae (by + filter_upwards [hg] with x hx; rw [hx])) + +lemma lineDeriv_zero_outside {f : R3 → ℝ} {R : ℝ} + (hs : ∀ x, R<‖x‖ → f x=0) {x : R3} (hx : R<‖x‖) (v : R3) : + lineDeriv ℝ f x v=0 := by + have he : f=ᶠ[𝓝 x] (fun _ => 0) := by + filter_upwards [isOpen_lt continuous_const continuous_norm |>.mem_nhds hx] with y hy + exact hs y hy + rw [he.lineDeriv_eq] + rw [(differentiableAt_const (0:ℝ)).lineDeriv_eq_fderiv] + simp + +lemma bounded_support_compact {f : R3 → ℝ} {R : ℝ} + (hs : ∀ x, R<‖x‖ → f x=0) : HasCompactSupport f := by + apply (isCompact_closedBall (0:R3) R).of_isClosed_subset (isClosed_tsupport _) + apply closure_minimal _ Metric.isClosed_closedBall + intro x hx + simp only [Metric.mem_closedBall,dist_zero_right] + exact le_of_not_gt (fun hn => hx (hs x hn)) + +lemma lipschitz_lineDeriv_memLp {C : ℝ≥0} {f : R3 → ℝ} + (hf : LipschitzWith C f) {R : ℝ} (hs : ∀ x, R<‖x‖ → f x=0) (v : R3) : + MemLp (fun x => lineDeriv ℝ f x v) 2 volume := by + apply (hf.memLp_lineDeriv v).mono_exponent_of_measure_support_ne_top + (s := Metric.closedBall 0 R) _ (measure_closedBall_lt_top.ne) le_top + intro x hx + apply lineDeriv_zero_outside hs _ v + simpa only [Metric.mem_closedBall,dist_zero_right,not_le] using hx + +theorem compact_lipschitz_H1 {C : ℝ≥0} {f : R3 → ℝ} + (hf : LipschitzWith C f) {R : ℝ} (hR : R<3) + (hs : ∀ x, R<‖x‖ → f x=0) : + ∃ u : H1, u∈H10 ∧ (∀ᵐ x ∂ballMeasure, + weakValue u x=f x ∧ ∀ i : Fin 3, + weakGradient u x i=lineDeriv ℝ f x (EuclideanSpace.single i 1)) := by + have hm : MemLp f 2 volume := hf.continuous.memLp_of_hasCompactSupport (bounded_support_compact hs) + have hd (i : Fin 3) := lipschitz_lineDeriv_memLp hf hs (EuclideanSpace.single i 1) + let F : Fin 4 → WholeL2 := Fin.cases (hm.toLp f) + (fun i => (hd i).toLp (fun x => lineDeriv ℝ f x (EuclideanSpace.single i 1))) + have hv : (F 0 : R3 → ℝ)=ᵐ[volume] f := hm.coeFn_toLp + have hg (i : Fin 3) : (F i.succ : R3 → ℝ)=ᵐ[volume] + (fun x => lineDeriv ℝ f x (EuclideanSpace.single i 1)) := (hd i).coeFn_toLp + have hw (i : Fin 3) : WeakL2Direction (F 0) (F i.succ) (EuclideanSpace.single i 1) := + (lipschitz_weakDirection hf _).congr hv (hg i) + obtain ⟨u,hu,he⟩ := compact_weak_H1 F hw hR (by + filter_upwards [hv] with x hx + intro hn + exact hx.trans (hs x hn)) + refine ⟨u,hu,?_⟩ + have hv' := hv.filter_mono (ae_mono (Measure.restrict_le_self (s := ball))) + have hg' := (ae_all_iff.mpr hg).filter_mono (ae_mono (Measure.restrict_le_self (s := ball))) + filter_upwards [he,hv',hg'] with x hx hy hz + exact ⟨hx.1.trans hy,fun i => (hx.2 i).trans (hz i)⟩ + +lemma segment_meets_frontier {s : Set R3} {x y : R3} (hx : x∈s) (hy : y∉s) : + ∃ z∈segment ℝ x y,z∈frontier s := by + have hc : segment ℝ x y⊆closure s∪closure sᶜ := by + intro z _ + by_cases hz : z∈s + · exact Or.inl (subset_closure hz) + · exact Or.inr (subset_closure hz) + obtain ⟨z,hz,hb⟩ := isPreconnected_closed_iff.mp (convex_segment x y).isPreconnected + (closure s) (closure sᶜ) isClosed_closure isClosed_closure hc + ⟨x,left_mem_segment ℝ x y,subset_closure hx⟩ + ⟨y,right_mem_segment ℝ x y,subset_closure hy⟩ + exact ⟨z,hz,by rwa [frontier_eq_closure_inter_closure]⟩ + +lemma lipschitz_piecewise_frontier (s : Set R3) [DecidablePred (·∈s)] + {f g : R3 → ℝ} {K L : ℝ≥0} + (hf : LipschitzOnWith K f (closure s)) + (hg : LipschitzOnWith L g (closure sᶜ)) + (he : EqOn f g (frontier s)) : + LipschitzWith (max K L) (s.piecewise f g) := by + have hcross {x y : R3} (hx : x∈s) (hy : y∉s) : + dist (f x) (g y) ≤ (max K L:ℝ≥0)*dist x y := by + obtain ⟨z,hz,hb⟩ := segment_meets_frontier hx hy + have hb' := frontier_eq_closure_inter_closure (s := s) ▸ hb + calc + dist (f x) (g y) ≤ dist (f x) (f z)+dist (f z) (g y) := dist_triangle _ _ _ + _ = dist (f x) (f z)+dist (g z) (g y) := by rw [he hb] + _ ≤ K*dist x z+L*dist z y := add_le_add + (hf.dist_le_mul x (subset_closure hx) z hb'.1) + (hg.dist_le_mul z hb'.2 y (subset_closure hy)) + _ ≤ (max K L:ℝ≥0)*dist x z+(max K L:ℝ≥0)*dist z y := by + apply add_le_add + · exact mul_le_mul_of_nonneg_right (by exact_mod_cast le_max_left K L) dist_nonneg + · exact mul_le_mul_of_nonneg_right (by exact_mod_cast le_max_right K L) dist_nonneg + _ = (max K L:ℝ≥0)*dist x y := by rw [←mul_add,dist_add_dist_of_mem_segment hz] + apply LipschitzWith.of_dist_le_mul + intro x y + by_cases hx : x∈s <;> by_cases hy : y∈s + · simp only [piecewise_eq_of_mem s f g hx,piecewise_eq_of_mem s f g hy] + exact (hf.dist_le_mul x (subset_closure hx) y (subset_closure hy)).trans + (mul_le_mul_of_nonneg_right (by exact_mod_cast le_max_left K L) dist_nonneg) + · simpa only [piecewise_eq_of_mem s f g hx,piecewise_eq_of_notMem s f g hy] using hcross hx hy + · rw [dist_comm,dist_comm x y] + simpa only [piecewise_eq_of_mem s f g hy,piecewise_eq_of_notMem s f g hx] using hcross hy hx + · simp only [piecewise_eq_of_notMem s f g hx,piecewise_eq_of_notMem s f g hy] + exact (hg.dist_le_mul x (subset_closure hx) y (subset_closure hy)).trans + (mul_le_mul_of_nonneg_right (by exact_mod_cast le_max_right K L) dist_nonneg) + +lemma piecewise_lineDeriv_off_frontier (s : Set R3) [DecidablePred (·∈s)] + (f g : R3 → ℝ) {x : R3} (hx : x∉frontier s) (v : R3) : + lineDeriv ℝ (s.piecewise f g) x v= + s.piecewise (fun x => lineDeriv ℝ f x v) (fun x => lineDeriv ℝ g x v) x := by + by_cases hs : x∈s + · have hi : x∈interior s := by + by_contra hn + exact hx ⟨subset_closure hs,hn⟩ + have he : s.piecewise f g=ᶠ[𝓝 x] f := by + filter_upwards [mem_interior_iff_mem_nhds.mp hi] with y hy + exact piecewise_eq_of_mem s f g hy + rw [he.lineDeriv_eq,piecewise_eq_of_mem s _ _ hs] + · have hi : x∈interior sᶜ := by + by_contra hn + have hb : x∈frontier sᶜ := ⟨subset_closure hs,hn⟩ + rw [frontier_compl] at hb + exact hx hb + have he : s.piecewise f g=ᶠ[𝓝 x] g := by + filter_upwards [mem_interior_iff_mem_nhds.mp hi] with y hy + exact piecewise_eq_of_notMem s f g hy + rw [he.lineDeriv_eq,piecewise_eq_of_notMem s _ _ hs] + +theorem compact_lipschitz_seam_H1 (s : Set R3) [DecidablePred (·∈s)] + {f g : R3 → ℝ} {K L : ℝ≥0} + (hf : LipschitzOnWith K f (closure s)) + (hg : LipschitzOnWith L g (closure sᶜ)) + (he : EqOn f g (frontier s)) (hn : volume (frontier s)=0) + {R : ℝ} (hR : R<3) (hs : ∀ x,R<‖x‖ → s.piecewise f g x=0) : + ∃ u : H1,u∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue u x=s.piecewise f g x ∧ ∀ i : Fin 3, + weakGradient u x i=s.piecewise + (fun x => lineDeriv ℝ f x (EuclideanSpace.single i 1)) + (fun x => lineDeriv ℝ g x (EuclideanSpace.single i 1)) x) := by + obtain ⟨u,hu,hj⟩ := compact_lipschitz_H1 (lipschitz_piecewise_frontier s hf hg he) hR hs + refine ⟨u,hu,?_⟩ + have hb : ∀ᵐ x∂volume,x∉frontier s := by + rw [ae_iff] + simpa using hn + have hb' := hb.filter_mono (ae_mono (Measure.restrict_le_self (s := ball))) + filter_upwards [hj,hb'] with x hx hxb + exact ⟨hx.1,fun i => (hx.2 i).trans (piecewise_lineDeriv_off_frontier s f g hxb _)⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CompactUpdateLp.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CompactUpdateLp.lean new file mode 100644 index 0000000000000000000000000000000000000000..ac48e5baf8577739c820347627efe500220e72a6 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CompactUpdateLp.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.FieldMean + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +lemma voltageGradient_sum + {I : Type*} [Fintype I] (u : I → Coord3 → Fin 2 → ℝ) + (hu : ∀ i, Differentiable ℝ (u i)) (x : Coord3) : + voltageGradient (fun y => ∑ i, u i y) x = ∑ i, voltageGradient (u i) x := by + classical + unfold voltageGradient + rw [fderiv_fun_sum (fun i _ => hu i x),map_sum] + +lemma CompactGlobalUpdate.gradient_mean_zero_restrict + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + (∫ x, voltageGradient R.du x ∂μ.restrict U) = 0 := by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero] + · exact voltageGradient_mean_zero μ R.smooth_du R.compact_du + · intro x hx + exact image_eq_zero_of_notMem_tsupport (fun hs => hx (R.support_du (tsupport_voltageGradient hs))) + +lemma CompactGlobalUpdate.flux_mean_zero_restrict + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + (∫ x, fieldVector (R.dF x) ∂μ.restrict U) = 0 := by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero] + · exact R.flux_mean_zero μ + · intro x hx + rw [image_eq_zero_of_notMem_tsupport (fun hs => hx (R.support_dF hs))] + exact map_zero fieldVectorCLM + +lemma CompactGlobalUpdate.memLp_gradient_correction + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + MemLp (voltageGradient R.du) 2 (μ.restrict U) := + (memLp_voltageGradient_smooth_compact μ R.smooth_du R.compact_du).restrict U + +lemma CompactGlobalUpdate.memLp_flux_correction + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) : + MemLp (fun x => fieldVector (R.dF x)) 2 (μ.restrict U) := + ((R.smooth_dF.continuous.memLp_of_hasCompactSupport R.compact_dF).continuousLinearMap_comp fieldVectorCLM).restrict U + +lemma CompactGlobalUpdate.gradient_toLp_eq + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) (hreg : μ (U \ regularRegion u A U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hE' : MemLp (voltageGradient (fun x => u x+R.du x)) 2 (μ.restrict U)) : + hE'.toLp _ = hE.toLp _ + (R.memLp_gradient_correction μ).toLp _ := by + rw [← MemLp.toLp_add] + exact hE'.toLp_congr _ (R.gradient_add_ae μ hUm hreg) + +lemma CompactGlobalUpdate.flux_toLp_eq + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hF' : MemLp (voltageFlux (fun x => u x+R.du x) R.tensor) 2 (μ.restrict U)) : + hF'.toLp _ = hF.toLp _ + (R.memLp_flux_correction μ).toLp _ := by + rw [← MemLp.toLp_add] + apply hF'.toLp_congr + exact Eventually.of_forall fun x => by + simp only [voltageFlux,R.constitutive x,fieldVector_add,Pi.add_apply] + +lemma norm_correction_bound_of_add + {V : Type*} [NormedAddCommGroup V] (E E₀ dE : V) (M : ℝ) + (he : E = E₀ + dE) (hbound : ‖E‖ ≤ M) : ‖dE‖ ≤ M + ‖E₀‖ := by + have hd : dE = E - E₀ := by rw [he, add_sub_cancel_left] + rw [hd] + exact (norm_sub_le _ _).trans (add_le_add hbound le_rfl) + +lemma CompactGlobalUpdate.correction_energy_bound + (μ : Measure Coord3) [μ.IsAddHaarMeasure] + {U : Set Coord3} (hUm : MeasurableSet U) + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (R : CompactGlobalUpdate μ U u A) (hreg : μ (U \ regularRegion u A U) = 0) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + {a b : ℝ} (ha : 0 < a) (hab : a < b) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → R.tensor x ∈ matrixFiniteLaminate a b) : + ‖(R.memLp_gradient_correction μ).toLp _‖ ≤ (b/a+1)*‖hE.toLp _‖ ∧ + ‖(R.memLp_flux_correction μ).toLp _‖ ≤ (b^2/a)*‖hE.toLp _‖+‖hF.toLp _‖ := by + obtain ⟨hE',hF'⟩ := R.fields_memLp μ hUm hreg hE hF + obtain ⟨hEB,hFB⟩ := R.Lp_energy_bound μ hUm hreg hE hE' hF' hint hdiv ha hab hgraph + have he := R.gradient_toLp_eq μ hUm hreg hE hE' + have hf := R.flux_toLp_eq μ hF hF' + constructor + · have h := norm_correction_bound_of_add _ _ _ _ he hEB + simpa only [add_mul, one_mul] using h + · exact norm_correction_bound_of_add _ _ _ _ hf hFB + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CriticalWallParticularC0.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CriticalWallParticularC0.lean new file mode 100644 index 0000000000000000000000000000000000000000..23225f850dee4da537be9ad41abb46f60fa8e729 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CriticalWallParticularC0.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.WallParticularBounds +import OAI.Analysis.Conductivity.Walls.CriticalWallBounds + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +theorem wallParticularTensor_C0 {χ v r₁ r₂ : Box3 → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) + (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) + {ε M δ κ : ℝ} (hε : 0≤ε) (hM : 0≤M) (hδ : 0≤δ) (hκ : 0<κ) + (hχ : ∀ p,|χ p|≤1) (hz : ∀ p∈tsupport χ,|p.2|≤δ) + (hr₁ : ∀ p,|r₁ p|≤ε) (hr₂ : ∀ p,|r₂ p|≤ε) + (hder : ∀ p,|wallAlong (1,0) r₁ p|≤ε) + (hvz : ∀ p∈tsupport χ,∀ t∈Icc (0:ℝ) 1,|wallDerivative v (p.1,t*p.2)|≤M) + (hvs : ∀ p∈tsupport χ,∀ t∈Icc (0:ℝ) 1,|wallAlong (1,0) v (p.1,t*p.2)|≤M) + (hvsz : ∀ p∈tsupport χ,∀ t∈Icc (0:ℝ) 1,|wallAlong (1,0) (wallDerivative v) (p.1,t*p.2)|≤M) + (hden : ∀ p∈tsupport χ,κ≤|wallQuotient (wallDerivative v) p|) (x : Coord3) : + ‖wallParticularTensor χ v r₁ r₂ x‖≤(δ+(1+M+3*δ*M)/κ)*ε := by + let p := boxCoordinates x + have hK : 0≤(δ+(1+M+3*δ*M)/κ)*ε := by positivity + by_cases hp : p∈tsupport χ + · have hA : |wallPrimitive r₁ p|≤δ*ε := + (wallPrimitive_abs_bound (fun t _ => hr₁ _)).trans (mul_le_mul_of_nonneg_right (hz p hp) hε) + have hnum : |wallQuotient (wallParticularNumerator (1,0) v r₁ r₂) p|≤ε*(1+M+3*δ*M) := + wallQuotient_abs_bound (wallParticularNumerator_derivative_bound (1,0) hv h₁ h₂ hε hM + (hz p hp) (fun _ _ => hr₁ _) (fun _ _ => hr₂ _) (fun _ _ => hder _) + (hvz p hp) (hvs p hp) (hvsz p hp)) + have hB : |wallQuotient (wallParticularNumerator (1,0) v r₁ r₂) p/ + wallQuotient (wallDerivative v) p|≤ε*(1+M+3*δ*M)/κ := by + rw [abs_div] + exact div_le_div₀ (by positivity) hnum hκ (hden p hp) + apply wallMatrix_norm_le hK + · change |χ p*wallPrimitive r₁ p|≤_ + rw [abs_mul] + calc + _ ≤ 1*(δ*ε) := mul_le_mul (hχ p) hA (abs_nonneg _) (by norm_num) + _ ≤ _ := by + have hh : 0≤(1+M+3*δ*M)/κ := by positivity + nlinarith + · change |χ p*(_ / _)|≤_ + rw [abs_mul] + calc + _ ≤ 1*(ε*(1+M+3*δ*M)/κ) := mul_le_mul (hχ p) hB (abs_nonneg _) (by norm_num) + _ ≤ _ := by nlinarith [show ε*(1+M+3*δ*M)/κ=((1+M+3*δ*M)/κ)*ε by ring] + · have hzero : χ p=0 := image_eq_zero_of_notMem_tsupport hp + apply wallMatrix_norm_le hK <;> change |χ p*_|≤_ <;> + rw [hzero,zero_mul,abs_zero] <;> exact hK + +variable {P : Type*} [TopologicalSpace P] + +theorem compact_wall_particular_bound {χ : Box3 → ℝ} (hsχ : HasCompactSupport χ) + (hχ : ∀ p,|χ p|≤1) {v : P → Box3 → ℝ} {p₀ : P} + (hvsmooth : ∀ p,ContDiff ℝ (↑(⊤ : ℕ∞)) (v p)) + (hvs : Continuous (fun px : P×Box3 => wallAlong (1,0) (v px.1) px.2)) + (hvz : Continuous (fun px : P×Box3 => wallDerivative (v px.1) px.2)) + (hvsz : Continuous (fun px : P×Box3 => wallAlong (1,0) (wallDerivative (v px.1)) px.2)) + (hD : Continuous (fun px : P×Box3 => wallQuotient (wallDerivative (v px.1)) px.2)) + (hne : ∀ x∈tsupport χ,wallQuotient (wallDerivative (v p₀)) x≠0) : + ∃ L : ℝ,0 wallAlong (1,0) (v p) x) + (p₀:=p₀) (wallNormalHull_compact hsχ) hvs + obtain ⟨δ,hδb⟩ := hsχ.exists_bound_of_continuousOn (continuous_snd : Continuous (fun p : Box3 => p.2)).continuousOn + have hδ (p) (hp : p∈tsupport χ) : |p.2|≤|δ| := by + have hh := hδb p hp + rw [Real.norm_eq_abs] at hh + exact hh.trans (le_abs_self δ) + let L := |δ|+(1+(M+M₁)+3*|δ| *(M+M₁))/κ + have hL : 0 (attachedEndPoissonField s f a b 0 y).re) + (WithLp.ofLp x) (Pi.single i 1)) := by + let D := sourceClosedCollarBand l r + have hD : MeasurableSet D := measurableSet_Icc.preimage measurable_sourcePhysicalCoordinates.fst + have hband {x : Fin 3 → ℝ} (hx : x∈D) : + x∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := ⟨hl.trans hx.1,hx.2.trans hr⟩ + let p := fun y => (attachedEndPoissonField s f a b 0 y).re + have hp : MemLp p 2 (volume.restrict D) := + (attachedEndPoissonField_memLp s hs f ha hR hlr hl hr hT 0).re + have hd : ∀ᵐ x∂volume.restrict D,0<(1:ℝ) → HasFDerivAt p (fderiv ℝ p x) x := by + filter_upwards [ae_restrict_mem hD, + ae_restrict_of_ae (attachedEndPoisson_real_differentiable_ae s hs f a b)] with x hx hdx _ + exact (hdx (hband hx) (hpos _ hx)).hasFDerivAt + have hthin : Tendsto (fun n : ℕ => ((n:ℝ)+1)^2* + ∫ x in {x | 0<(1:ℝ) ∧ ((n:ℝ)+1)*(1:ℝ)≤2}, + (cutMatchedValue (fun _ => 1) χ p x)^2) atTop (𝓝 0) := by + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop (3:ℕ)] with n hn + have hn' : (3:ℝ)≤n := by exact_mod_cast hn + have he : {x : Fin 3 → ℝ | 0<(1:ℝ) ∧ ((n:ℝ)+1)*(1:ℝ)≤2}=∅ := by + ext x + simp only [Set.mem_ofPred_eq,Set.mem_empty_iff_false,iff_false,not_and] + intro _ + linarith + simp only [he,Measure.restrict_empty,integral_zero_measure,mul_zero] + obtain ⟨w,hw,he⟩ := localized_matched_seam_H1_pi + (LipschitzWith.const (1:ℝ)) hχ hc hD hp + (fun x hx _ => hχs hx) + (fun x hx _ => attachedEndPoissonField_localLip s hs f a b + (hpos _ (hχs hx)) (sourceDirections_ne_zero_on_band (hband (hχs hx)))) + (fderiv ℝ p) (attachedEndPoisson_grad_memLp s hs f ha hR hb hlr hl hr hT) + hd (show (5:ℝ)/2<3 by norm_num) + (fun x hx => sourceBand_euclidean_bound (hband (hχs hx))) hthin + refine ⟨w,hw,?_⟩ + simpa only [cutMatchedValue,cutMatchedGradient,show (0:ℝ)<1 by norm_num,ite_true,p] using he + +end ScalarConductivity + + + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +def fullAttachedEndValue (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (a b κ : ℝ) (y : Fin 3 → ℝ) : ℝ := + (attachedEndPoissonField s f a b 0 y).re+κ*(a*(sourceCollarTime y-b)) + +def fullAttachedEndGradient (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (a b κ : ℝ) (y : Fin 3 → ℝ) (i : Fin 3) : ℝ := + fderiv ℝ (fun y => (attachedEndPoissonField s f a b 0 y).re) y (Pi.single i 1)+ + κ*fderiv ℝ (fun y => a*(sourceCollarTime y-b)) y (Pi.single i 1) + +theorem cut_fullAttachedEnd_H10 (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) + {a b l r R : ℝ} (ha : a≠0) (hR : 0≤R) + (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (hlr : l≤r) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hT : ∀ t∈Icc l r,affineEndTime a b t∈Icc 0 R) + (hpos : ∀ t∈Icc l r,0 fderiv ℝ χ y (Pi.single i 1)) + (fun hh => h (tsupport_fderiv_apply_subset ℝ _ hh)) + simp only [image_eq_zero_of_notMem_tsupport h,hd,zero_mul,mul_zero,add_zero] + +lemma exists_band_cutoff {l₀ l r r₀ : ℝ} (hl : l₀ 1)) := by + have hbig := isCompact_sourceClosedCollarBand hl₀ hr₀ + have hsmall := isCompact_sourceClosedCollarBand (hl₀.trans hl.le) (hr.le.trans hr₀) + have hi : sourceClosedCollarBand l r⊆interior (sourceClosedCollarBand l₀ r₀) := by + intro x hx + apply mem_interior_iff_mem_nhds.mpr + have hm := locallyLipschitz_sourceCollarTime.continuous.continuousAt + (isOpen_Ioo.mem_nhds (show sourceCollarTime x∈Ioo l₀ r₀ from + ⟨hl.trans_le hx.1,hx.2.trans_lt hr⟩)) + exact mem_of_superset hm (fun y hy => ⟨hy.1.le,hy.2.le⟩) + obtain ⟨χ,hχ1,hχ0,hχb⟩ := exists_contMDiffMap_one_nhds_of_subset_interior + (modelWithCornersSelf ℝ (Fin 3 → ℝ)) hsmall.isClosed hi (n:=↑(⊤:ℕ∞)) + refine ⟨χ,χ.contMDiff.contDiff,HasCompactSupport.intro hbig hχ0,?_,?_,?_⟩ + · intro x + rw [abs_of_nonneg (hχb x).1] + exact (hχb x).2 + · apply closure_minimal _ hbig.isClosed + intro x hx + by_contra hn + exact hx (hχ0 x hn) + · intro x hx + exact hχ1.filter_mono (nhds_le_nhdsSet hx) + +theorem fullAttachedEnd_neighborhood_H10 (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) + {a b l₀ l r r₀ R : ℝ} (ha : a≠0) (hR : 0≤R) + (hb : b∈Icc (-(1:ℝ)/100) (1/100)) + (hlr : l≤r) (hl : l₀ f x*g x) := by + apply LipschitzWith.of_dist_le_mul + intro x y + rw [Real.dist_eq] + have he : f x*g x-f y*g y=(f x-f y)*g x+f y*(g x-g y) := by ring + rw [he] + calc + _ ≤ |(f x-f y)*g x|+|f y*(g x-g y)| := abs_add_le _ _ + _ = |f x-f y| *|g x|+|f y| *|g x-g y| := by rw [abs_mul,abs_mul] + _ ≤ (K*dist x y)*B+A*(L*dist x y) := add_le_add + (mul_le_mul (by simpa only [Real.dist_eq] using hf.dist_le_mul x y) (hB x) (abs_nonneg _) (by positivity)) + (mul_le_mul (hA y) (by simpa only [Real.dist_eq] using hg.dist_le_mul x y) (abs_nonneg _) (by positivity)) + _ = _ := by push_cast; ring + +lemma compact_cut_positive_lipschitz {τ χ : (Fin 3 → ℝ) → ℝ} {K : ℝ≥0} + (hτ : LipschitzWith K τ) (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {M : ℝ} (hM : 0≤M) (hb : ∀ x∈tsupport χ,τ x≤M) : + ∃ C,LipschitzWith C (fun x => χ x*max 0 (τ x)) := by + obtain ⟨C,hC⟩ := hχ.lipschitzWith_of_hasCompactSupport hc (by simp) + have hr := (LipschitzWith.const (0:ℝ)).max (hτ.min (LipschitzWith.const M)) + have hbound (x : Fin 3 → ℝ) : |max 0 (min (τ x) M)|≤(⟨M,hM⟩:ℝ≥0) := by + rw [abs_of_nonneg (le_max_left _ _)] + exact max_le hM (min_le_right _ _) + have H := lipschitz_mul_real_bounded hC hr (A:=1) (B:=(⟨M,hM⟩ : ℝ≥0)) (by simpa using hχb) hbound + have he : (fun x => χ x*max 0 (τ x))=(fun x => χ x*max 0 (min (τ x) M)) := by + funext x + by_cases hx : x∈tsupport χ + · rw [min_eq_left (hb x hx)] + · rw [image_eq_zero_of_notMem_tsupport hx] + simp + have H' : ∃ D,LipschitzWith D (fun x => χ x*max 0 (min (τ x) M)) := ⟨_,H⟩ + rwa [←he] at H' + +theorem compact_collar_slope_H1 {χ : (Fin 3 → ℝ) → ℝ} + (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + (a b κ l r : ℝ) (hl : -(1:ℝ)/100≤l) (hr : r≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand l r) : + let f := fun x : R3 => κ*(χ (WithLp.ofLp x)*max 0 (a*(sourceCollarTime (WithLp.ofLp x)-b))) + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=f x ∧ ∀ i,weakGradient w x i=lineDeriv ℝ f x (EuclideanSpace.single i 1)) := by + obtain ⟨K,hK⟩ := attachedEndTime_lipschitz a b + have hb (x : Fin 3 → ℝ) (hx : x∈tsupport χ) : + a*(sourceCollarTime x-b)≤|a| *(|l|+|r|+|b|) := by + have ht := hχs hx + have hav : |sourceCollarTime x|≤|l|+|r| := by + apply abs_le.mpr + constructor + · linarith [(neg_abs_le l).trans ht.1,abs_nonneg r] + · linarith [ht.2.trans (le_abs_self r),abs_nonneg l] + exact (le_abs_self _).trans (by + rw [abs_mul] + exact mul_le_mul_of_nonneg_left ((abs_sub _ _).trans (show |sourceCollarTime x| + |b| ≤ |l|+|r|+|b| by linarith)) (abs_nonneg _)) + obtain ⟨C,hC⟩ := compact_cut_positive_lipschitz hK hχ hc hχb (by positivity) hb + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have H := (ContinuousLinearMap.toSpanSingleton ℝ κ).lipschitzWith.comp (hC.comp E.lipschitzWith) + have hF : LipschitzWith (‖ContinuousLinearMap.toSpanSingleton ℝ κ‖₊ * (C * ‖E.toContinuousLinearMap‖₊)) + (fun x : R3 => κ*(χ (WithLp.ofLp x)*max 0 (a*(sourceCollarTime (WithLp.ofLp x)-b)))) := by + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [Function.comp_apply,ContinuousLinearMap.toSpanSingleton_apply,E, + PiLp.coe_continuousLinearEquiv,smul_eq_mul,mul_comm] using H.dist_le_mul x y + apply compact_lipschitz_H1 hF (by norm_num : (5:ℝ)/2<3) + intro x hx + have hn : WithLp.ofLp x∉tsupport χ := by + intro hs + have hh := sourceBand_euclidean_bound (show WithLp.ofLp x∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) from + ⟨hl.trans (hχs hs).1,(hχs hs).2.trans hr⟩) + exact not_le_of_gt hx hh + simp [image_eq_zero_of_notMem_tsupport hn] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CylinderPoissonH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CylinderPoissonH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..d40360c9e9649ce58e57d57ee84c5f4e2ab44e82 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CylinderPoissonH1.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.CylinderSobolevGraph + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma axialDecayField_smooth (m : ℝ) (a : ℂ) : + ContDiff ℝ (↑(⊤:ℕ∞)) (axialDecayField m a) := by + unfold axialDecayField + exact (Complex.ofRealCLM.contDiff.comp ((contDiff_const.mul contDiff_id).exp)).mul contDiff_const + +lemma axialDecayField_deriv (m : ℝ) (a : ℂ) : + deriv (axialDecayField m a)=axialDecayField m (-(m:ℂ)*a) := by + funext t + have he : HasDerivAt (fun t : ℝ => (Real.exp (-m*t):ℂ)) + ((Real.exp (-m*t)*(-m):ℝ):ℂ) t := by + simpa only [id_eq,mul_one] using (((hasDerivAt_id t).const_mul (-m)).exp).ofReal_comp + have H := (he.mul_const a).deriv + change deriv (fun t : ℝ => (Real.exp (-m*t):ℂ)*a) t=_ + rw [H] + simp only [axialDecayField,Complex.ofReal_mul,Complex.ofReal_neg] + ring + +lemma axialDecayField_smoothLp (m R : ℝ) (a : ℂ) : + smoothFiniteAxisLp (axialDecayField_smooth m a).continuous R=finiteDecayLp m R a := by + apply Lp.ext + exact (smoothFiniteAxisLp_ae (axialDecayField_smooth m a).continuous R).trans + (finiteDecayLp_ae m R a).symm + +lemma axialDecayField_derivLp (m R : ℝ) (a : ℂ) : + smoothFiniteAxisLp ((axialDecayField_smooth m a).continuous_deriv (by simp)) R= + finiteDecayLp m R (-(m:ℂ)*a) := by + apply Lp.ext + filter_upwards [smoothFiniteAxisLp_ae ((axialDecayField_smooth m a).continuous_deriv (by simp)) R, + finiteDecayLp_ae m R (-(m:ℂ)*a)] with t ht hu + rw [ht,hu,axialDecayField_deriv] + +lemma endPoissonModeJet_smooth (s : Fin 3 → ℝ) (R : ℝ) (h : TorusModes) (a : ℂ) : + endPoissonModeJet s R h a= + smoothCylinderModeJet (axialDecayField_smooth (torusRate s h) a) R h := by + apply PiLp.ext + intro j + fin_cases j + · change cylinderMode _ _ (finiteDecayLp _ _ a)=cylinderMode _ _ (smoothFiniteAxisLp _ _) + rw [axialDecayField_smoothLp] + · change cylinderMode _ _ (finiteDecayLp _ _ (-(torusRate s h:ℂ)*a))= + cylinderMode _ _ (smoothFiniteAxisLp _ _) + rw [axialDecayField_derivLp] + · change cylinderMode _ _ (finiteDecayLp _ _ ((Complex.I*(h 0:ℂ))*a))= + cylinderMode _ _ ((Complex.I*(h 0:ℂ))•smoothFiniteAxisLp _ _) + rw [axialDecayField_smoothLp,finiteDecayLp_smul] + · change cylinderMode _ _ (finiteDecayLp _ _ ((Complex.I*(h 1:ℂ))*a))= + cylinderMode _ _ ((Complex.I*(h 1:ℂ))•smoothFiniteAxisLp _ _) + rw [axialDecayField_smoothLp,finiteDecayLp_smul] + +lemma smoothCylinderModeJet_mem_H1 {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) : smoothCylinderModeJet hq R h∈cylinderH1Space R := by + apply Submodule.le_topologicalClosure + refine ⟨Finsupp.single h (⟨q,hq⟩ : smoothComplexAxis),?_⟩ + rw [cylinderPolynomialJetL,Finsupp.lsum_single] + exact cylinderJetMode_smooth hq R h + +theorem endPoissonJet_mem_cylinderH1 (s : Fin 3 → ℝ) + (hs : ∀ x y : ℝ,(1/2)*(x^2+y^2)≤ s 0*x^2+2*s 1*x*y+s 2*y^2) + (R : ℝ) (hR : 0≤R) (f : spectralTraceGraph (torusRate s)) : + endPoissonJet s hs R hR f∈cylinderH1Space R := by + apply (Submodule.isClosed_topologicalClosure _).mem_of_tendsto + (endPoissonJet_hasSum s hs R hR f) + apply Filter.Eventually.of_forall + intro F + apply Submodule.sum_mem + intro h _ + rw [endPoissonModeJet_smooth] + exact smoothCylinderModeJet_mem_H1 _ R h + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/CylinderSobolevGraph.lean b/lean/OAI/Analysis/Conductivity/Sobolev/CylinderSobolevGraph.lean new file mode 100644 index 0000000000000000000000000000000000000000..b7b9a41f1b25cc81809e68d8d744cb26bc5a7dc3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/CylinderSobolevGraph.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.CylinderPolynomial + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +abbrev CylinderTraceAmbient (s : Fin 3 → ℝ) (R : ℝ) := + FiniteCylinderJets R × (spectralTraceGraph (torusRate s) × spectralTraceGraph (torusRate s)) + +def cylinderPolynomialGraphL (s : Fin 3 → ℝ) (R : ℝ) : + (TorusModes →₀ smoothComplexAxis) →ₗ[ℂ] CylinderTraceAmbient s R := + (cylinderPolynomialJetL R).prod + ((cylinderPolynomialTraceL s 0).prod (cylinderPolynomialTraceL s R)) + +def cylinderSobolevGraph (s : Fin 3 → ℝ) (R : ℝ) : Submodule ℂ (CylinderTraceAmbient s R) := + (LinearMap.range (cylinderPolynomialGraphL s R)).topologicalClosure + +def cylinderH1Space (R : ℝ) : Submodule ℂ (FiniteCylinderJets R) := + (LinearMap.range (cylinderPolynomialJetL R)).topologicalClosure + +instance cylinderSobolevGraph_complete (s : Fin 3 → ℝ) (R : ℝ) : + CompleteSpace (cylinderSobolevGraph s R) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +instance cylinderH1Space_complete (R : ℝ) : CompleteSpace (cylinderH1Space R) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +lemma cylinderSobolevGraph_trace_bound (s : Fin 3 → ℝ) {R : ℝ} (hR : 0 (cylinderSobolevJet_antilipschitz s hR).injective (hy.trans hz.symm)⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/FiniteEndPhysicalH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/FiniteEndPhysicalH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..04a51df7e1be9b080b602bb67a06fffa6c1261e4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/FiniteEndPhysicalH1.lean @@ -0,0 +1,152 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentEndPartition +import OAI.Analysis.Conductivity.Variational.FiniteEndPhysicalDescent +import OAI.Analysis.Conductivity.Sources.FacePasting + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix + +theorem compact_localLip_H1_pi {u : Coord3 → ℝ} + (hu : ∀ x,LocalLipAt u x) {R : ℝ} (hR : R<3) + (hs : ∀ x,R<‖WithLp.toLp 2 x‖ → u x=0) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=u (WithLp.ofLp x) ∧ ∀ i, + weakGradient w x i=lineDeriv ℝ u (WithLp.ofLp x) (Pi.single i 1)) := by + let E : R3 ≃L[ℝ] Coord3 := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hh (x : R3) : LocalLipAt (u ∘ E) x := + (hu (E x)).comp (E.toContinuousLinearMap.lipschitzWith.locallyLipschitz x) + have hz (x : R3) (hx : R<‖x‖) : (u ∘ E) x=0 := hs (E x) hx + obtain ⟨K,hK⟩ := compact_locallyLipschitz hh (bounded_support_compact hz) + obtain ⟨w,hw,he⟩ := compact_lipschitz_H1 hK hR hz + refine ⟨w,hw,?_⟩ + filter_upwards [he] with x hx + refine ⟨hx.1,fun i => (hx.2 i).trans ?_⟩ + unfold lineDeriv + congr 1 + +theorem cut_physicalPeriodicField_H10 {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : ContDiff ℝ 1 f) + {χ : Coord3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (_ : HasCompactSupport χ) + (hs : tsupport χ⊆sourceClosedCollarBand (-(1:ℝ)/100) (1/100)) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=χ (WithLp.ofLp x)*physicalPeriodicField f (WithLp.ofLp x) ∧ ∀ i, + weakGradient w x i=lineDeriv ℝ (fun y => χ y*physicalPeriodicField f y) + (WithLp.ofLp x) (Pi.single i 1)) := by + refine compact_localLip_H1_pi (u:=fun y => χ y*physicalPeriodicField f y) (R:=5/2) ?_ (by norm_num) ?_ + · intro x + by_cases hx : x∈tsupport χ + · exact (localLipAt_of_contDiffAt (hχ.of_le (by simp)).contDiffAt).mul + (physicalPeriodicField_localLip hp hf (sourceDirections_ne_zero_on_band (hs hx))) + · apply (localLipAt_of_contDiffAt (contDiffAt_const (c:=(0:ℝ)))).congr + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + change χ y=0 at hy + simp [hy] + · intro x hx + have hn : x∉tsupport χ := fun h => hx.not_ge (sourceBand_euclidean_bound (hs h)) + simp [image_eq_zero_of_notMem_tsupport hn] + +lemma cut_physicalPeriodicField_lineDeriv {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : Differentiable ℝ f) + {χ : Coord3 → ℝ} (hχ : Differentiable ℝ χ) + (i j : Fin 4) {x : Coord3} (hx : x∈sourceCollarOpenBox) (k : Fin 3) : + lineDeriv ℝ (fun y => χ y*physicalPeriodicField f y) + (sourceCollarPiece i j x) (Pi.single k 1)= + fderiv ℝ χ (sourceCollarPiece i j x) (Pi.single k 1)*f (sourceFaceAngles i j x)+ + χ (sourceCollarPiece i j x)* + ((sourceCartesianGradientMatrix i j x)*ᵥ + (fun l => direction (Pi.single l 1) f (sourceFaceAngles i j x))) k := by + have hd := physicalPeriodicField_hasFDeriv hp hf i j hx + have hh := (hχ _).hasFDerivAt.mul hd + change lineDeriv ℝ (χ * physicalPeriodicField f) _ _ = _ + rw [hh.differentiableAt.lineDeriv_eq_fderiv,hh.fderiv] + simp only [_root_.add_apply,_root_.smul_apply,smul_eq_mul] + have he := physicalPeriodicField_fderiv hp hf i j hx (Pi.single k 1) + rw [hd.fderiv] at he + rw [he,physicalPeriodicField_piece hp i j (sourceCollarOpenBox_subset hx)] + simp only [dotProduct_single_one] + ring + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix + +lemma flatEndCoordinates_shift (a b T : ℝ) (n : Fin 2 → ℤ) (x : Coord3) : + flatEndCoordinates a b (x+angularShift T n)=flatEndCoordinates a b x+angularShift T n := by + ext i + fin_cases i <;> simp [flatEndCoordinates,angularShift] + +lemma AngularPeriodic.flatEnd {E : Type*} {f : Coord3 → E} {T : ℝ} + (hp : AngularPeriodic T f) (a b : ℝ) : + AngularPeriodic T (fun x => f (flatEndCoordinates a b x)) := by + intro n x + change f (flatEndCoordinates a b (x+angularShift T n))=f (flatEndCoordinates a b x) + rw [flatEndCoordinates_shift,hp n (flatEndCoordinates a b x)] + +def attachedPeriodicField (f : Coord3 → ℝ) (a b : ℝ) : Coord3 → ℝ := + physicalPeriodicField (fun x => f (flatEndCoordinates a b x)) + +lemma attachedPeriodicField_zero_nhds {f : Coord3 → ℝ} {τ a b : ℝ} (hτ : 0<τ) + (hz : ∀ x,x 0<τ → f x=0) {y : Coord3} + (hy : a*(sourceCollarTime y-b)≤0) : + attachedPeriodicField f a b=ᶠ[𝓝 y] (fun _ => 0) := by + have hc : Continuous (fun y : Coord3 => a*(sourceCollarTime y-b)) := + continuous_const.mul (locallyLipschitz_sourceCollarTime.continuous.sub continuous_const) + filter_upwards [(isOpen_lt hc continuous_const).mem_nhds (hy.trans_lt hτ)] with z hz' + exact hz _ hz' + +theorem attachedPeriodicCorrection_H10 {f : Coord3 → ℝ} + (hp : AngularPeriodic (2*Real.pi) f) (hf : ContDiff ℝ 1 f) + {τ a b l₀ l r r₀ : ℝ} (hτ : 0<τ) (hz : ∀ x,x 0<τ → f x=0) + (hl : l₀ f (flatEndCoordinates a b x)) := + hf.comp ((contDiff_flatEndCoordinates a b).of_le (WithTop.coe_le_coe.mpr le_top)) + have hs : tsupport χ⊆sourceClosedCollarBand (-(1:ℝ)/100) (1/100) := by + intro x hx + exact ⟨hl₀.trans (hχs hx).1,(hχs hx).2.trans hr₀⟩ + obtain ⟨d,hd,hde⟩ := cut_physicalPeriodicField_H10 (hp.flatEnd a b) hc hχ hχc hs + refine ⟨d,hd,?_,?_⟩ + · filter_upwards [hde] with x hx hy + have he := attachedPeriodicField_zero_nhds hτ hz hy + have he' : (fun y => χ y*attachedPeriodicField f a b y)=ᶠ[𝓝 (WithLp.ofLp x)] + (fun _ => 0) := by + filter_upwards [he] with y hy + rw [hy,mul_zero] + refine ⟨hx.1.trans ?_,fun i => (hx.2 i).trans ?_⟩ + · exact he'.eq_of_nhds + · change lineDeriv ℝ (fun y => χ y*attachedPeriodicField f a b y) _ _=0 + rw [he'.lineDeriv_eq (𝕜:=ℝ)] + simp [lineDeriv] + · filter_upwards [hde] with x hx hy + have he : (fun y => χ y*attachedPeriodicField f a b y)=ᶠ[𝓝 (WithLp.ofLp x)] + attachedPeriodicField f a b := by + filter_upwards [hχ1 _ hy] with y hy + rw [hy,one_mul] + exact ⟨hx.1.trans he.eq_of_nhds,fun i => (hx.2 i).trans he.lineDeriv_eq⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/IntervalTraceEnergy.lean b/lean/OAI/Analysis/Conductivity/Sobolev/IntervalTraceEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce2df94341fefa18d2a7d77d55d9d271cb1e2cdf --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/IntervalTraceEnergy.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +lemma integral_sq_le_mass_mul {X : Type*} [MeasurableSpace X] {μ : Measure X} + [IsFiniteMeasure μ] {f : X → ℝ} (hf : Integrable f μ) + (hf2 : Integrable (fun x => f x^2) μ) : + (∫ x, f x ∂μ)^2≤(μ univ).toReal*(∫ x, f x^2 ∂μ) := by + by_cases h0 : μ univ=0 + · have : μ=0 := Measure.measure_univ_eq_zero.mp h0 + simp [this] + have hm : 0<(μ univ).toReal := ENNReal.toReal_pos h0 (measure_ne_top _ _) + let m := (∫ x, f x ∂μ)/(μ univ).toReal + have hi : Integrable (fun x => f x^2-2*m*f x+m^2) μ := + (hf2.sub (hf.const_mul _)).add (integrable_const _) + have hpos : 0≤∫ x, (f x^2-2*m*f x+m^2) ∂μ := + integral_nonneg (fun x => by change 0 ≤ f x^2-2*m*f x+m^2; nlinarith [sq_nonneg (f x-m)]) + rw [integral_add (f := fun x => f x^2-2*m*f x) (g := fun _ => m^2) (hf2.sub (hf.const_mul _)) (integrable_const _), + integral_sub (f := fun x => f x^2) (g := fun x => 2*m*f x) hf2 (hf.const_mul _),integral_const_mul,integral_const,smul_eq_mul] at hpos + have he : m*(μ univ).toReal=∫ x, f x ∂μ := by dsimp [m]; exact div_mul_cancel₀ _ hm.ne' + dsimp [Measure.real] at hpos + rw [←he] at hpos ⊢ + nlinarith [mul_nonneg hm.le hpos] + +lemma interval_integral_sq_le {a b : ℝ} (hab : a≤b) {f : ℝ → ℝ} (hf : Continuous f) : + (∫ t in a..b, f t)^2≤(b-a)*(∫ t in a..b, f t^2) := by + have h := integral_sq_le_mass_mul + (μ := volume.restrict (Ioc a b)) (hf.integrableOn_Icc.mono_set Ioc_subset_Icc_self) + ((hf.pow 2).integrableOn_Icc.mono_set Ioc_subset_Icc_self) + simpa only [intervalIntegral.integral_of_le hab,Measure.restrict_apply_univ, + Real.volume_Ioc,ENNReal.toReal_ofReal (sub_nonneg.mpr hab)] using h + +lemma smooth_interval_poincare_point {q : ℝ → ℝ} + (hq : ContDiff ℝ (↑(⊤ : ℕ∞)) q) {a b : ℝ} (hab : a≤b) : + (q b-q a)^2≤(b-a)*(∫ t in a..b, (deriv q t)^2) := by + have hd : Continuous (deriv q) := hq.continuous_deriv (by simp) + have hFTC := intervalIntegral.integral_deriv_eq_sub + (fun x _ => hq.differentiable (by simp) x) (hd.intervalIntegrable a b) + rw [←hFTC] + exact interval_integral_sq_le hab hd + +theorem fourier_mode_trace_energy {q : ℝ → ℝ} + (hq : ContDiff ℝ (↑(⊤ : ℕ∞)) q) {η m : ℝ} (hη : 0<η) (_ : 0 ≤ m) : + m*(q 0)^2≤(1+1/η)*(∫ t in (0:ℝ)..η, + (deriv q t)^2+(1+m^2)*(q t)^2) := by + let e := fun t => (deriv q t)^2+m^2*(q t)^2 + have hd : Continuous (deriv q) := hq.continuous_deriv (by simp) + have he : Continuous e := (hd.pow 2).add (continuous_const.mul (hq.continuous.pow 2)) + have hpoint (t : ℝ) (ht : t∈Icc 0 η) : + m*(q 0)^2≤ m*(q t)^2+∫ s in (0:ℝ)..η, e s := by + have hder : ∀ s, HasDerivAt (fun x => m*(q x)^2) (2*m*q s*deriv q s) s := by + intro s + convert! ((hq.differentiable (by simp) s).hasDerivAt.pow 2).const_mul m using 1 + ring + have hFTC := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun s _ => hder s) + ((continuous_const.mul hq.continuous |>.mul hd).intervalIntegrable 0 t) + have hi : ∫ s in (0:ℝ)..t, -(2*m*q s*deriv q s) ≤∫ s in (0:ℝ)..t, e s := by + apply intervalIntegral.integral_mono_on ht.1 + ((continuous_const.mul hq.continuous |>.mul hd).neg.intervalIntegrable 0 t) + (he.intervalIntegrable 0 t) + intro s _ + dsimp [e] + nlinarith [sq_nonneg (deriv q s+m*q s)] + rw [intervalIntegral.integral_neg,hFTC] at hi + have hi' : ∫ s in (0:ℝ)..t, e s ≤∫ s in (0:ℝ)..η, e s := by + apply intervalIntegral.integral_mono_interval (le_refl 0) ht.1 ht.2 + _ (he.intervalIntegrable 0 η) + exact Filter.Eventually.of_forall (fun s => by dsimp [e]; positivity) + linarith + have hav := intervalIntegral.integral_mono_on (μ := volume) (f := fun _ => m*(q 0)^2) + (g := fun t => m*(q t)^2+∫ s in (0:ℝ)..η, e s) hη.le + (continuous_const.intervalIntegrable 0 η) + ((continuous_const.mul (hq.continuous.pow 2) |>.add continuous_const).intervalIntegrable 0 η) + hpoint + rw [intervalIntegral.integral_const,sub_zero,smul_eq_mul, + intervalIntegral.integral_add (f := fun t => m*(q t)^2) (g := fun _ => ∫ s in (0:ℝ)..η, e s) + ((continuous_const.mul (hq.continuous.pow 2)).intervalIntegrable 0 η) + (continuous_const.intervalIntegrable 0 η), + intervalIntegral.integral_const_mul,intervalIntegral.integral_const,sub_zero,smul_eq_mul] at hav + have hI : 0≤∫ t in (0:ℝ)..η, (q t)^2 := intervalIntegral.integral_nonneg hη.le (fun _ _ => sq_nonneg _) + have heI : 0≤∫ t in (0:ℝ)..η, e t := intervalIntegral.integral_nonneg hη.le (fun t _ => by dsimp [e]; positivity) + have hE : (∫ t in (0:ℝ)..η, (deriv q t)^2+(1+m^2)*(q t)^2)= + (∫ t in (0:ℝ)..η, e t)+(∫ t in (0:ℝ)..η, (q t)^2) := by + rw [←intervalIntegral.integral_add (f := e) (g := fun t => (q t)^2) (he.intervalIntegrable 0 η) ((hq.continuous.pow 2).intervalIntegrable 0 η)] + apply intervalIntegral.integral_congr + intro t _ + dsimp [e]; ring + rw [hE] + have hmI : m*(∫ t in (0:ℝ)..η, (q t)^2)≤ + (∫ t in (0:ℝ)..η, e t)+(∫ t in (0:ℝ)..η, (q t)^2) := by + rw [←intervalIntegral.integral_const_mul,←intervalIntegral.integral_add (f := e) (g := fun t => (q t)^2) (he.intervalIntegrable 0 η) ((hq.continuous.pow 2).intervalIntegrable 0 η)] + apply intervalIntegral.integral_mono_on hη.le + ((continuous_const.mul (hq.continuous.pow 2)).intervalIntegrable 0 η) + ((he.add (hq.continuous.pow 2)).intervalIntegrable 0 η) + intro t _ + dsimp [e] + have hmm : m≤1+m^2 := by nlinarith [sq_nonneg (m-1/2)] + nlinarith [mul_nonneg (sub_nonneg.mpr hmm) (sq_nonneg (q t)),sq_nonneg (deriv q t)] + apply (mul_le_mul_iff_right₀ hη).mp + have hfac : η*(1+1/η)=η+1 := by field_simp + rw [←mul_assoc η (1+1/η),hfac] + nlinarith [mul_nonneg hη.le hI] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/KernelParamDerivative.lean b/lean/OAI/Analysis/Conductivity/Sobolev/KernelParamDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..655e263cf9d941d65e11a9084bfa4d77e2c03b56 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/KernelParamDerivative.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory +open scoped Convolution + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [MeasureSpace E] [BorelSpace E] + +theorem convolution_param_hasDerivAt [FiniteDimensional ℝ E] + [Measure.IsAddHaarMeasure (volume : Measure E)] {f : E → ℝ} (hf : LocallyIntegrable f) + {K : ℝ → E → ℝ} {S : Set ℝ} {C : Set E} (hS : IsOpen S) (hC : IsCompact C) + (hK : ContDiffOn ℝ 1 (Function.uncurry K) (S ×ˢ univ)) + (hzero : ∀ s y, s∈S → y∉C → K s y=0) + {s : ℝ} (hs : s∈S) {D : E → ℝ} (hD : ∀ y, HasDerivAt (fun r => K r y) (D y) s) + (x : E) : + HasDerivAt (fun r => (f ⋆[ContinuousLinearMap.lsmul ℝ ℝ,volume] K r) x) + ((f ⋆[ContinuousLinearMap.lsmul ℝ ℝ,volume] D) x) s := by + let L : ℝ →L[ℝ] ℝ →L[ℝ] ℝ := ContinuousLinearMap.lsmul ℝ ℝ + let J : E → (ℝ × E →L[ℝ] ℝ) := fun y => fderiv ℝ (Function.uncurry K) (s,y) + have hJ : Continuous J := by + apply (hK.continuousOn_fderiv_of_isOpen (hS.prod isOpen_univ) le_rfl).comp_continuous + (continuous_const.prodMk continuous_id) + intro y + exact ⟨hs,mem_univ _⟩ + have hJzero {y : E} (hy : y∉C) : J y=0 := by + apply (hasFDerivAt_zero_of_eventually_const 0 ?_).fderiv + have he : S ×ˢ Cᶜ ∈ 𝓝 (s,y) := + (hS.prod hC.isClosed.isOpen_compl).mem_nhds ⟨hs,hy⟩ + filter_upwards [he] with z hz + exact hzero z.1 z.2 hz.1 hz.2 + have hJc : HasCompactSupport J := + HasCompactSupport.of_support_subset_isCompact hC (by + intro y hy + by_contra hn + exact hy (hJzero hn)) + have hi : Integrable (fun y => L.precompR (ℝ × E) (f y) (J (x-y))) := + hJc.convolutionExists_right (L.precompR (ℝ × E)) hf hJ x + have hdiff := hasFDerivAt_convolution_right_with_param L hS hC hzero hf hK (s,x) hs + have hcurve := ((hasDerivAt_id s).prodMk (hasDerivAt_const s x)) + have hout := hdiff.comp_hasDerivAt s hcurve + have hJval (y : E) : J y (1,0)=D y := by + have ha : DifferentiableAt ℝ (Function.uncurry K) (s,y) := (hK.contDiffAt ((hS.prod isOpen_univ).mem_nhds ⟨hs,mem_univ y⟩)).differentiableAt (by norm_num) + have he := ha.hasFDerivAt.comp_hasDerivAt s + ((hasDerivAt_id s).prodMk (hasDerivAt_const s y)) + exact (he.unique (hD y)) + convert hout using 1 <;> try rfl + change (∫ y, f y*D (x-y))=(∫ y, L.precompR (ℝ × E) (f y) (J (x-y))) (1,0) + rw [ContinuousLinearMap.integral_apply hi] + apply integral_congr_ae + exact ae_of_all _ (fun y => by simp [L,hJval]) +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/L2SpectralMultiplier.lean b/lean/OAI/Analysis/Conductivity/Sobolev/L2SpectralMultiplier.lean new file mode 100644 index 0000000000000000000000000000000000000000..d3dade93e037d5b41f3933d163757b8852f248b1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/L2SpectralMultiplier.lean @@ -0,0 +1,80 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Filter Topology +open scoped ENNReal + +variable {ι : Type*} + +def sequenceMultiplier (m : ι → ℂ) (C : ℝ) (hC : 0≤C) (hm : ∀ i, ‖m i‖≤C) : + lp (fun _ : ι => ℂ) 2 →L[ℂ] lp (fun _ : ι => ℂ) 2 := + LinearMap.mkContinuous + { toFun := fun f => ⟨fun i => m i*f i, + ((lp.memℓp f).norm.const_smul C).mono (fun i => by + simpa only [Pi.smul_apply,smul_eq_mul,Real.norm_eq_abs,abs_mul,abs_of_nonneg hC, + abs_of_nonneg (norm_nonneg _),norm_mul] using mul_le_mul_of_nonneg_right (hm i) (norm_nonneg (f i)))⟩ + map_add' := fun f g => by ext i; change m i*(f i+g i)=_; exact mul_add _ _ _ + map_smul' := fun r f => by ext i; change m i*(r*f i)=r*(m i*f i); ring } + C (fun f => by + have hh := lp.norm_mono (p:=(2:ℝ≥0∞)) (show (2:ℝ≥0∞)≠0 by norm_num) + (x:=⟨fun i => m i*f i, by + exact ((lp.memℓp f).norm.const_smul C).mono (fun i => by + simpa only [Pi.smul_apply,smul_eq_mul,Real.norm_eq_abs,abs_mul,abs_of_nonneg hC, + abs_of_nonneg (norm_nonneg _),norm_mul] using mul_le_mul_of_nonneg_right (hm i) (norm_nonneg (f i)))⟩) + (y:=C • f) (fun i => by + change ‖m i*f i‖≤‖C • f i‖ + rw [norm_mul,norm_smul,Real.norm_eq_abs,abs_of_nonneg hC] + exact mul_le_mul_of_nonneg_right (hm i) (norm_nonneg _)) + change ‖(⟨fun i => m i*f i, _⟩ : lp (fun _ : ι => ℂ) 2)‖≤_ + simpa only [norm_smul,Real.norm_eq_abs,abs_of_nonneg hC] using hh) + +@[simp] lemma sequenceMultiplier_apply (m : ι → ℂ) (C : ℝ) (hC : 0≤C) + (hm : ∀ i, ‖m i‖≤C) (f : lp (fun _ : ι => ℂ) 2) (i : ι) : + sequenceMultiplier m C hC hm f i=m i*f i := rfl + +lemma sequenceMultiplier_norm (m : ι → ℂ) (C : ℝ) (hC : 0≤C) + (hm : ∀ i, ‖m i‖≤C) : ‖sequenceMultiplier m C hC hm‖≤C := + LinearMap.mkContinuous_norm_le _ hC _ + +lemma sequenceMultiplier_one (f : lp (fun _ : ι => ℂ) 2) : + sequenceMultiplier (fun _ => 1) 1 zero_le_one (fun _ => by simp) f=f := by + ext i; simp + +lemma sequenceMultiplier_coeff_tendsto {α : Type*} {l : Filter α} + (m : α → ι → ℂ) (C : ℝ) (hC : 0≤C) (hm : ∀ t i, ‖m t i‖≤C) + (ht : ∀ i, Tendsto (fun t => m t i) l (𝓝 1)) (f : lp (fun _ : ι => ℂ) 2) : + Tendsto (fun t => sequenceMultiplier (m t) C hC (hm t) f) l (𝓝 f) := by + have hs : Summable (fun i => ‖f i‖^2) := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two] using (lp.memℓp f).summable (by norm_num : 0<(2:ℝ≥0∞).toReal) + have hd : ∀ t i, ‖‖m t i*f i-f i‖^2‖≤(C+1)^2*‖f i‖^2 := by + intro t i + rw [Real.norm_eq_abs,abs_of_nonneg (sq_nonneg _)] + calc + _ = (‖m t i-1‖*‖f i‖)^2 := by rw [←norm_mul,sub_mul,one_mul] + _ ≤ ((C+1)*‖f i‖)^2 := by + gcongr + exact (norm_sub_le _ _).trans (by simpa using add_le_add_right (hm t i) 1) + _ = _ := mul_pow _ _ _ + have ht' : Tendsto (fun t => ∑' i, ‖m t i*f i-f i‖^2) l (𝓝 0) := by + simpa only [tsum_zero] using tendsto_tsum_of_dominated_convergence (g:=fun _ : ι => (0:ℝ)) (hs.mul_left ((C+1)^2)) + (fun i => by simpa using (((ht i).mul_const (f i)).sub_const (f i)).norm.pow 2) + (Filter.Eventually.of_forall hd) + have he (t : α) : ∑' i, ‖m t i*f i-f i‖^2 = + ‖sequenceMultiplier (m t) C hC (hm t) f-f‖^2 := by + simpa only [ENNReal.toReal_ofNat,Real.rpow_two,lp.coeFn_sub,Pi.sub_apply, + sequenceMultiplier_apply] using (lp.norm_rpow_eq_tsum + (by norm_num : 0<(2:ℝ≥0∞).toReal) (sequenceMultiplier (m t) C hC (hm t) f-f)).symm + simp only [he] at ht' + apply tendsto_iff_norm_sub_tendsto_zero.mpr + have hh := Real.continuous_sqrt.continuousAt.tendsto.comp ht' + simpa only [Function.comp_def,Real.sqrt_sq (norm_nonneg _),Real.sqrt_zero] using hh + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalJoinedH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalJoinedH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..6200a3fade731c6e235dc58dcae215c621fb7a8a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalJoinedH1.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.SmoothCollarTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma gradient_of_pi_function (q : (Fin 3 → ℝ) → ℝ) (x : R3) (i : Fin 3) + (hq : DifferentiableAt ℝ q (WithLp.ofLp x)) : + gradient (fun x : R3 => q (WithLp.ofLp x)) x i = + fderiv ℝ q (WithLp.ofLp x) (Pi.single i 1) := by + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have he := (hq.hasFDerivAt.comp x E.hasFDerivAt).fderiv + have hi := congrArg (fun F : R3 →L[ℝ] ℝ => F (EuclideanSpace.single i 1)) he + rw [←toDual_gradient,InnerProductSpace.toDual_apply_apply,EuclideanSpace.inner_single_right] at hi + have hEi : E.toContinuousLinearMap (EuclideanSpace.single i 1)=Pi.single i 1 := rfl + simpa only [Function.comp_def,ContinuousLinearMap.comp_apply,hEi,mul_one,one_mul,starRingEnd_apply,star_trivial] using hi + +lemma compact_smooth_pi_H1 {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (hc : HasCompactSupport q) + {R : ℝ} (hR : R<3) (hs : ∀ x∈tsupport q,‖WithLp.toLp 2 x‖≤R) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=q (WithLp.ofLp x) ∧ ∀ i, + weakGradient w x i=fderiv ℝ q (WithLp.ofLp x) (Pi.single i 1)) := by + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hd : ContDiff ℝ (↑(⊤:ℕ∞)) (q ∘ E) := hq.comp E.contDiff + refine ⟨smoothH1 (q ∘ E) hd,smoothH1_mem_H10 _ hd ?_ ?_,?_⟩ + · exact hc.comp_homeomorph E.toHomeomorph + · intro x hx + have hh : tsupport (q ∘ E)⊆E ⁻¹' tsupport q := + closure_minimal (fun y hy => subset_tsupport q hy) ((isClosed_tsupport q).preimage E.continuous) + have hx' : E x∈tsupport q := hh hx + have hnorm := (hs (E x) hx').trans_lt hR + have he : WithLp.toLp 2 (E x)=x := rfl + rw [he] at hnorm + simpa only [ball,Metric.mem_ball,dist_zero_right] using hnorm + · filter_upwards [smoothH1_value (q ∘ E) hd,smoothH1_gradient (q ∘ E) hd] with x hx hg + refine ⟨hx,fun i => ?_⟩ + rw [hg] + exact gradient_of_pi_function q x i ((hq.differentiable (by simp)) _) + +def localJoinedValue (τ χ q p : (Fin 3 → ℝ) → ℝ) (x : Fin 3 → ℝ) : ℝ := + χ x*(if 0<τ x then p x else q x) + +def localJoinedGradient (τ χ q p : (Fin 3 → ℝ) → ℝ) + (i : Fin 3) (x : Fin 3 → ℝ) : ℝ := + fderiv ℝ χ x (Pi.single i 1)*(if 0<τ x then p x else q x)+ + χ x*(if 0<τ x then fderiv ℝ p x (Pi.single i 1) else fderiv ℝ q x (Pi.single i 1)) + +theorem smoothCollarTrace_localJoined_H1 {s : Fin 3 → ℝ} + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {q χ : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hc : HasCompactSupport χ) (hχb : ∀ x,|χ x|≤1) + {a b η : ℝ} (ha : a≠0) (hη : 0<η) (hl : -(1:ℝ)/100≤b-η) (hr : b+η≤1/100) + (hχs : tsupport χ⊆sourceClosedCollarBand (b-η) (b+η)) : + let p := fun y => (attachedEndPoissonField s (smoothCollarTrace s b hq) a b 0 y).re + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=localJoinedValue (fun y => a*(sourceCollarTime y-b)) χ q p (WithLp.ofLp x) ∧ + ∀ i,weakGradient w x i=localJoinedGradient (fun y => a*(sourceCollarTime y-b)) χ q p i (WithLp.ofLp x)) := by + obtain ⟨w,hw,hwe⟩ := smoothCollarTrace_matched_H1 hs hq hχ hc hχb ha hη hl hr hχs + obtain ⟨z,hz,hze⟩ := compact_smooth_pi_H1 (hχ.mul hq) (hc.mul_right (f':=q)) + (by norm_num : (5:ℝ)/2<3) (fun x hx => sourceBand_euclidean_bound + (show x∈sourceClosedCollarBand (-(1:ℝ)/100) (1/100) from + ⟨hl.trans (hχs (tsupport_mul_subset_left hx)).1, + (hχs (tsupport_mul_subset_left hx)).2.trans hr⟩)) + refine ⟨w+z,H10.add_mem hw hz,?_⟩ + filter_upwards [hwe,hze,weakValue_add w z,weakGradient_add w z] with x hx hz hv hg + refine ⟨?_,fun i => ?_⟩ + · rw [hv] + change weakValue w x+weakValue z x=_ + rw [hx.1,hz.1] + dsimp only [Pi.add_apply,localJoinedValue,cutMatchedValue] + split_ifs <;> ring + · rw [hg] + change weakGradient w x i+weakGradient z x i=_ + rw [hx.2 i,hz.2 i] + change _+fderiv ℝ (χ*q) (WithLp.ofLp x) (Pi.single i 1)=_ + rw [fderiv_mul ((hχ.differentiable (by simp)) _) ((hq.differentiable (by simp)) _)] + simp only [cutMatchedGradient,localJoinedGradient,sub_apply, + add_apply,smul_apply,smul_eq_mul] + split_ifs <;> ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPhysicalCorrectionBound.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPhysicalCorrectionBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..bda871edd79896ca85ec2575d7aa7b5afa53d7b8 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPhysicalCorrectionBound.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalCorrectionC0 +import OAI.Analysis.Conductivity.Variational.CompactPhysicalCorrections +import OAI.Analysis.Conductivity.Sources.PhysicalC1Pullback + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +def closedCorrectionBox (a b : Coord3) : Set Coord3 := + boxCoordinates ⁻¹' ((Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1)) ×ˢ Icc (a 2) (b 2)) + +lemma closedCorrectionBox_compact (a b : Coord3) : IsCompact (closedCorrectionBox a b) := by + have hc : IsCompact ((Icc (a 0) (b 0) ×ˢ Icc (a 1) (b 1)) ×ˢ Icc (a 2) (b 2)) := + (isCompact_Icc.prod isCompact_Icc).prod isCompact_Icc + convert hc.image boxCoordinates.symm.continuous using 1 + ext x + constructor + · intro hx + exact ⟨boxCoordinates x,hx,boxCoordinates.symm_apply_apply x⟩ + · rintro ⟨p,hp,rfl⟩ + simpa only [closedCorrectionBox,mem_preimage,boxCoordinates.apply_symm_apply] using hp + +lemma correctionBox_subset_closed {a b c d : Coord3} + (hca : ∀ i,c i≤a i) (hbd : ∀ i,b i≤d i) : + correctionBox a b⊆closedCorrectionBox c d := by + intro x hx + have h := mem_correctionBox.mp hx + exact ⟨⟨⟨(hca 0).trans (h 0).1.le,(h 0).2.le.trans (hbd 0)⟩, + ⟨(hca 1).trans (h 1).1.le,(h 1).2.le.trans (hbd 1)⟩⟩, + ⟨(hca 2).trans (h 2).1.le,(h 2).2.le.trans (hbd 2)⟩⟩ + +lemma boxCoordinates_symm_norm_le : ‖boxCoordinates.symm.toContinuousLinearMap‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro p + simp only [one_mul] + apply pi_norm_le_iff_of_nonneg (norm_nonneg p) |>.mpr + intro i + fin_cases i + · exact (norm_fst_le p.1).trans (norm_fst_le p) + · exact (norm_snd_le p.1).trans (norm_fst_le p) + · exact norm_snd_le p + +theorem local_physical_symmetric_correction_C0 + (X : OpenPartialHomeomorph Coord3 Coord3) + (hX : ContDiffOn ℝ (↑(⊤:ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤:ℕ∞)) X.symm X.target) + {a b c d : Coord3} (hab : ∀ i,a i (hca i).le) (fun i => (hbd i).le) + have hbox := hiK.trans houter + obtain ⟨P,hP,hPsolve⟩ := localPiolaSource_inverse_C1 X hX hXi + (closedCorrectionBox_compact c d) houter + obtain ⟨L,hL,solve⟩ := physical_box_symmetric_correction_C0 X hX hXi hab hca hbd houter + refine ⟨L*P,mul_pos hL hP,?_⟩ + intro r hr hc hs hz ht M hM hb + let p : Fin 2 → Coord3 → ℝ := fun j => localPiolaSource X.symm (r j) + have hst (j) : tsupport (r j)⊆X.target := + (hs j).trans (by rintro y ⟨x,hx,rfl⟩; exact X.map_source (hbox hx)) + have hp (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (p j) := + localPiolaSource_smooth X.symm hXi hX (r j) (hr j) (hc j) (hst j) + have hpc (j) : HasCompactSupport (p j) := + (localPiolaSource_compact X.symm (r j) (hc j) (hst j)).1 + have hps (j) : tsupport (p j)⊆correctionBox a b := + localPiolaSource_inverse_support X (r j) (hc j) hbox (hs j) + let q : Fin 2 → Box3 → ℝ := fun j => p j∘boxCoordinates.symm + have hq (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (q j) := (hp j).comp boxCoordinates.symm.contDiff + have hqc (j) : HasCompactSupport (q j) := (hpc j).comp_homeomorph boxCoordinates.symm.toHomeomorph + have hqs (j) : tsupport (q j)⊆ + (Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2) := by + intro z hz + have h := hps j ((tsupport_comp_subset_preimage (p j) boxCoordinates.symm.continuous) hz) + simpa only [correctionBox,mem_preimage,boxCoordinates.apply_symm_apply] using h + have hd := hX.differentiableOn (by simp) + have hdi := hXi.differentiableOn (by simp) + have hback (j) : localPiolaSource X (p j)=r j := + localPiolaSource_inverse X hd hdi (r j) ((subset_tsupport _).trans (hst j)) + have hqz (j) : (∫ z,q j z)=0 := by + rw [←boxCoordinates_integral (q j)] + simp only [q,Function.comp_apply,boxCoordinates.symm_apply_apply] + have he := localPiolaSource_pairing volume X.symm hdi + (fun _ hy => local_fderiv_det_ne_zero X.symm hdi hd hy) (r j) + ((subset_tsupport _).trans (hst j)) (fun _ => 1) + simpa only [one_mul] using he.trans (by simpa only [one_mul] using hz j) + have hqt : (∫ z : Box3,z.1.2*q 0 z-z.1.1*q 1 z)=0 := by + rw [←boxCoordinates_integral (fun z : Box3 => z.1.2*q 0 z-z.1.1*q 1 z)] + have he := localPiolaSource_torque X hd hdi (p 0) (p 1) + ((subset_tsupport _).trans ((hps 0).trans hbox)) + ((subset_tsupport _).trans ((hps 1).trans hbox)) + rw [hback 0,hback 1] at he + simp only [q,Function.comp_apply,boxCoordinates.symm_apply_apply] + change (∫ x,x 1*p 0 x-x 0*p 1 x)=0 + rw [←he] + refine (integral_congr_ae ?_).trans ht + filter_upwards [] with y + by_cases hy : y∈X.target + · rw [hu hy]; rfl + · rw [image_eq_zero_of_notMem_tsupport (fun h => hy (hst 0 h)), + image_eq_zero_of_notMem_tsupport (fun h => hy (hst 1 h)),mul_zero,mul_zero,mul_zero,mul_zero] + have hpb (j) : UniformC1Bound (p j) (P*M) := + hPsolve (r j) (hr j) (hc j) ((hs j).trans (image_mono hiK)) M hM (hb j) + have hqb (j) : UniformC1Bound (q j) (P*M) := + (hpb j).comp_linear ((hp j).differentiable (by simp)) (mul_nonneg hP.le hM) + boxCoordinates.symm.toContinuousLinearMap boxCoordinates_symm_norm_le + obtain ⟨H,hH,hHc,hHs,hsy,hweak,hHb⟩ := solve (q 0) (q 1) + (hq 0) (hq 1) (hqc 0) (hqc 1) (hqs 0) (hqs 1) (hqz 0) (hqz 1) hqt + (P*M) (mul_nonneg hP.le hM) (hqb 0) (hqb 1) + refine ⟨H,hH,hHc,hHs,hsy,?_,fun y => (hHb y).trans_eq (by ring)⟩ + apply symmetricSource_eq_of_weak huu hH hHc (fun j => ⟨hr j,hc j⟩) + intro j ψ hψ + have he := hweak j ψ hψ + have hpsource : (fun x => ![q 0 (boxCoordinates x),q 1 (boxCoordinates x)] j)=p j := by + funext x + fin_cases j <;> simp [q] + rw [hpsource,hback j] at he + refine (integral_congr_ae ?_).trans he + filter_upwards [] with y + by_cases hy : y∈X.target + · have hf : u =ᶠ[𝓝 y] coordinatePair∘X.symm := + Filter.eventuallyEq_of_mem (X.open_target.mem_nhds hy) (fun z hz => hu hz) + rw [hf.fderiv_eq] + · rw [image_eq_zero_of_notMem_tsupport (fun h => hy (hHs h)),Matrix.zero_mul,Matrix.zero_mul] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFlux.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFlux.lean new file mode 100644 index 0000000000000000000000000000000000000000..ac427f2dd4ba210e21aba960e42b9846e4585c81 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFlux.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +namespace ScalarConductivity + +def localPiolaFlux {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F : E → E) (y : E) : E := by + classical + exact if y ∈ X.target then + |(fderiv ℝ X (X.symm y)).det|⁻¹ • fderiv ℝ X (X.symm y) (F (X.symm y)) + else 0 + +lemma localPiolaFlux_support {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F : E → E) : + Function.support (localPiolaFlux X F) ⊆ X '' (Function.support F ∩ X.source) := by + intro y hy + by_cases hyt : y ∈ X.target + · refine ⟨X.symm y, ⟨?_, X.map_target hyt⟩, X.right_inv hyt⟩ + intro hz + exact hy (by simp [localPiolaFlux, hyt, hz]) + · exact False.elim (hy (by simp [localPiolaFlux, hyt])) + +lemma localPiolaFlux_hasCompactSupport {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F : E → E) (hF : HasCompactSupport F) + (hs : tsupport F ⊆ X.source) : HasCompactSupport (localPiolaFlux X F) := by + apply HasCompactSupport.of_support_subset_isCompact + (hF.image_of_continuousOn (X.continuousOn.mono hs)) + exact (localPiolaFlux_support X F).trans (image_mono (fun _ hx => subset_closure hx.1)) + +lemma localPiolaFlux_tsupport {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F : E → E) (hF : HasCompactSupport F) + (hs : tsupport F ⊆ X.source) : tsupport (localPiolaFlux X F) ⊆ X.target := by + have hc : IsClosed (X '' tsupport F) := + (hF.image_of_continuousOn (X.continuousOn.mono hs)).isClosed + exact (closure_minimal ((localPiolaFlux_support X F).trans + (image_mono (fun _ hx => subset_closure hx.1))) hc).trans + (by rintro y ⟨x, hx, rfl⟩; exact X.map_source (hs hx)) + +lemma local_fderiv_symm_comp {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (hX : DifferentiableOn ℝ X X.source) + (hXi : DifferentiableOn ℝ X.symm X.target) {x : E} (hx : x ∈ X.source) : + (fderiv ℝ X.symm (X x)).comp (fderiv ℝ X x) = ContinuousLinearMap.id ℝ E := by + have hd := (hX x hx).differentiableAt (X.open_source.mem_nhds hx) + have hdi := (hXi _ (X.map_source hx)).differentiableAt + (X.open_target.mem_nhds (X.map_source hx)) + rw [← fderiv_comp x hdi hd] + have he : (X.symm ∘ X) =ᶠ[𝓝 x] id := by + filter_upwards [X.open_source.mem_nhds hx] with y hy + exact X.left_inv hy + rw [he.fderiv_eq, fderiv_id] + +lemma local_fderiv_det_ne_zero {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (hX : DifferentiableOn ℝ X X.source) + (hXi : DifferentiableOn ℝ X.symm X.target) {x : E} (hx : x ∈ X.source) : + (fderiv ℝ X x).det ≠ 0 := by + have he := congrArg (fun L : E →L[ℝ] E => L.det) (local_fderiv_symm_comp X hX hXi hx) + simp only [ContinuousLinearMap.det, ContinuousLinearMap.toLinearMap_comp, + ContinuousLinearMap.coe_id, LinearMap.det_comp, LinearMap.det_id] at he + exact right_ne_zero_of_mul_eq_one he + +lemma integral_eq_setIntegral_of_zero_off {E V : Type*} [MeasurableSpace E] + [NormedAddCommGroup V] [NormedSpace ℝ V] (μ : Measure E) (s : Set E) + (f : E → V) (hf : ∀ x ∉ s, f x = 0) : (∫ x, f x ∂μ) = ∫ x in s, f x ∂μ := by + rw [← setIntegral_univ] + exact (setIntegral_eq_of_subset_of_forall_sdiff_eq_zero MeasurableSet.univ + (subset_univ s) (fun x hx => hf x hx.2)) + +theorem localPiolaFlux_pairing + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + (X : OpenPartialHomeomorph E E) (hX : DifferentiableOn ℝ X X.source) + (hdet : ∀ x ∈ X.source, (fderiv ℝ X x).det ≠ 0) + (F : E → E) (hF : Function.support F ⊆ X.source) + (ψ : E → ℝ) (hψ : Differentiable ℝ ψ) : + (∫ y, fderiv ℝ ψ y (localPiolaFlux X F y) ∂μ) = + ∫ x, fderiv ℝ (ψ ∘ X) x (F x) ∂μ := by + rw [integral_eq_setIntegral_of_zero_off μ X.target _ (by + intro y hy; simp [localPiolaFlux, hy])] + have hs : X '' X.source = X.target := X.image_source_eq_target + rw [← hs, integral_image_eq_integral_abs_det_fderiv_smul μ + X.open_source.measurableSet + (fun x hx => ((hX x hx).differentiableAt (X.open_source.mem_nhds hx)).hasFDerivAt.hasFDerivWithinAt) + X.injOn] + rw [integral_eq_setIntegral_of_zero_off μ X.source + (fun x => fderiv ℝ (ψ ∘ X) x (F x)) (by + intro x hx + have hz : F x = 0 := Function.notMem_support.mp (notMem_subset hF hx) + simp [hz])] + apply setIntegral_congr_fun X.open_source.measurableSet + intro x hx + simp only [localPiolaFlux, ite_eq_left (X.map_source hx), X.left_inv hx, + map_smul, smul_eq_mul] + rw [← mul_assoc, mul_inv_cancel₀ (abs_ne_zero.mpr (hdet x hx)), one_mul] + rw [fderiv_comp x (hψ _) ((hX x hx).differentiableAt (X.open_source.mem_nhds hx))] + rfl + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxPotentialPairing.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxPotentialPairing.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1360feb0a96c4426207668d6821f1c862cedc84 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxPotentialPairing.lean @@ -0,0 +1,51 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.LocalPiolaFlux + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +namespace ScalarConductivity + +theorem localPiolaFlux_potential_pairing + {E V : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup V] [NormedSpace ℝ V] + (X : OpenPartialHomeomorph E E) (hX : DifferentiableOn ℝ X X.source) + (hXi : DifferentiableOn ℝ X.symm X.target) + (D : E →L[ℝ] V) (u : E → V) + (hu : ∀ y ∈ X.source, D (X y) = u y) (F : E → E) + {y : E} (hy : y ∈ X.source) : + fderiv ℝ u y (localPiolaFlux X.symm F y) = + |(fderiv ℝ X.symm (X y)).det|⁻¹ • D (F (X y)) := by + classical + have hxy := X.map_source hy + have he : u =ᶠ[𝓝 y] D ∘ X := by + filter_upwards [X.open_source.mem_nhds hy] with z hz + exact (hu z hz).symm + have hd := (hX y hy).differentiableAt (X.open_source.mem_nhds hy) + have hinv := local_fderiv_symm_comp X.symm hXi hX hxy + simp only [OpenPartialHomeomorph.symm_symm, X.left_inv hy] at hinv + rw [he.fderiv_eq, fderiv_comp y D.differentiableAt hd, D.fderiv] + have hflux : localPiolaFlux X.symm F y = + |(fderiv ℝ X.symm (X y)).det|⁻¹ • (fderiv ℝ X.symm (X y)) (F (X y)) := by + simp [localPiolaFlux, hy] + rw [ContinuousLinearMap.comp_apply, hflux, map_smul, map_smul] + congr 1 + exact congrArg D (congrArg (fun T : E →L[ℝ] E => T (F (X y))) hinv) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxSub.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxSub.lean new file mode 100644 index 0000000000000000000000000000000000000000..f9ac2bc055b06df69e743edd786164ae2d51d4fd --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPiolaFluxSub.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ContDiffClmDet +import OAI.Analysis.Conductivity.Sobolev.LocalPiolaFluxPotentialPairing +import OAI.Analysis.Conductivity.Variational.AdaptedSpatialBasis + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set Filter Topology MeasureTheory + +lemma localPiolaFlux_sub {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (X : OpenPartialHomeomorph E E) (F G : E → E) : + localPiolaFlux X (fun x => F x - G x) = + fun x => localPiolaFlux X F x - localPiolaFlux X G x := by + classical + funext x + by_cases hx : x ∈ X.target <;> simp [localPiolaFlux, hx, map_sub, smul_sub] + +lemma localPiolaFlux_linear_bound {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {K : Set E} (hK : IsCompact K) (hKs : K ⊆ X.source) : + ∃ B : ℝ, 0 < B ∧ ∀ (F : E → E), Function.support F ⊆ K → ∀ y, + ‖localPiolaFlux X F y‖ ≤ B * ‖F (X.symm y)‖ := by + classical + let T : E → E →L[ℝ] E := fun x => |(fderiv ℝ X x).det|⁻¹ • fderiv ℝ X x + have hT : ContinuousOn T X.source := by + intro x hx + have hd : ContDiffAt ℝ (↑(⊤ : ℕ∞)) (fderiv ℝ X) x := + (hX.contDiffAt (X.open_source.mem_nhds hx)).fderiv_right (by simp) + have hdet0 := local_fderiv_det_ne_zero X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) hx + have hdet := ((contDiff_clm_det (E := E) (↑(⊤ : ℕ∞))).contDiffAt.comp x hd).abs hdet0 + exact ((hdet.inv (abs_ne_zero.mpr hdet0)).smul hd).continuousAt.continuousWithinAt + obtain ⟨C, hC⟩ := (hK.image_of_continuousOn (hT.mono hKs)).isBounded.exists_norm_le + refine ⟨max C 1, lt_of_lt_of_le zero_lt_one (le_max_right _ _), ?_⟩ + intro F hF y + by_cases hy : y ∈ X.target + · by_cases hxy : X.symm y ∈ K + · change ‖(if y ∈ X.target then _ else 0)‖ ≤ _ + simp only [ite_eq_left hy] + change ‖T (X.symm y) (F (X.symm y))‖ ≤ _ + exact (ContinuousLinearMap.le_opNorm _ _).trans + (mul_le_mul_of_nonneg_right ((hC _ (mem_image_of_mem _ hxy)).trans (le_max_left _ _)) + (norm_nonneg _)) + · have hz : F (X.symm y) = 0 := by + by_contra hn + exact hxy (hF hn) + simp [localPiolaFlux, hy, hz] + · simp [localPiolaFlux, hy, mul_nonneg (le_trans zero_le_one (le_max_right C 1)) + (norm_nonneg (F (X.symm y)))] + +lemma localPiolaFlux_uniform_error + {E I : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + {l : Filter I} + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + {K : Set E} (hK : IsCompact K) (hKs : K ⊆ X.source) + (F G : I → E → E) (hs : ∀ i, Function.support (fun x => F i x - G i x) ⊆ K) + (he : TendstoUniformly (fun i x => F i x - G i x) (fun _ => 0) l) : + TendstoUniformly (fun i x => localPiolaFlux X (F i) x - localPiolaFlux X (G i) x) + (fun _ => 0) l := by + obtain ⟨B, hB, hb⟩ := localPiolaFlux_linear_bound X hX hXi hK hKs + rw [Metric.tendstoUniformly_iff] at he ⊢ + intro ε hε + filter_upwards [he (ε / B) (div_pos hε hB)] with i hi x + have hix : ‖F i (X.symm x) - G i (X.symm x)‖ < ε / B := by + simpa only [dist_zero_left] using hi (X.symm x) + have hii := hb (fun y => F i y - G i y) (hs i) x + rw [localPiolaFlux_sub] at hii + simpa only [dist_zero_left] using hii.trans_lt ((lt_div_iff₀' hB).mp hix) + +theorem exists_chart_two_flux + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (hdim : Module.finrank ℝ E = 3) (μ : Measure E) [μ.IsAddHaarMeasure] + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (hXi : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X.symm X.target) + (D : E →L[ℝ] (Fin 2 → ℝ)) (hD : Function.Surjective D) + (u : E → Fin 2 → ℝ) (hu : ∀ y ∈ X.source, D (X y) = u y) + (χ : SmoothScalar E) (hχ : HasCompactSupport χ.val) (hχs : tsupport χ.val ⊆ X.target) + (L : E →L[ℝ] ℝ) (hL : L ≠ 0) + (h : SmoothScalar ℝ) (hp : Function.Periodic h.val 1) + (hm : ∫ t in (0 : ℝ)..1, h.val t = 0) + (R : Fin 2 → E) (hRs : D (R 0) 1 = D (R 1) 0) (hRn : ∀ j, L (R j) = 0) : + ∃ F : ℝ → Fin 2 → E → E, + (∀ k j, ContDiff ℝ (↑(⊤ : ℕ∞)) (F k j)) ∧ + (∀ k j, HasCompactSupport (F k j) ∧ tsupport (F k j) ⊆ X.source) ∧ + (∀ k y, fderiv ℝ u y (F k 0 y) 1 = fderiv ℝ u y (F k 1 y) 0) ∧ + (∀ k j (ψ : E → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → + (∫ y, fderiv ℝ ψ y (F k j y) ∂μ) = 0) ∧ + ∀ j, TendstoUniformly + (fun k y => F k j y - localPiolaFlux X.symm + (fun x => (χ.val x * h.val (k * L x)) • R j) y) (fun _ => 0) atTop := by + classical + obtain ⟨G, hg, hs, hsym, hdiv, he⟩ := exists_physical_two_flux hdim μ D hD + χ hχ L hL h hp hm R hRs hRn + have hc (k : ℝ) (j : Fin 2) : HasCompactSupport (G k j) := + hχ.of_isClosed_subset (isClosed_tsupport _) (hs k j) + have hgs (k : ℝ) (j : Fin 2) : tsupport (G k j) ⊆ X.target := (hs k j).trans hχs + refine ⟨fun k j => localPiolaFlux X.symm (G k j), ?_, ?_, ?_, ?_, ?_⟩ + · intro k j + exact localPiolaFlux_smooth X.symm hXi hX (G k j) (hg k j) (hc k j) (hgs k j) + · intro k j + exact ⟨localPiolaFlux_hasCompactSupport X.symm _ (hc k j) (hgs k j), + localPiolaFlux_tsupport X.symm _ (hc k j) (hgs k j)⟩ + · intro k y + by_cases hy : y ∈ X.source + · rw [localPiolaFlux_potential_pairing X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) D u hu (G k 0) hy, + localPiolaFlux_potential_pairing X (hX.differentiableOn (by simp)) + (hXi.differentiableOn (by simp)) D u hu (G k 1) hy] + simp only [Pi.smul_apply, smul_eq_mul, hsym] + · simp [localPiolaFlux, hy] + · intro k j ψ hψ + exact localPiolaFlux_zero_pairing μ X.symm hXi hX _ (hc k j) (hgs k j) (hdiv k j) ψ hψ + · intro j + apply localPiolaFlux_uniform_error X.symm hXi hX hχ hχs + (fun k => G k j) (fun k x => (χ.val x * h.val (k * L x)) • R j) _ (he j) + intro k x hx + by_contra hn + have hz : χ.val x = 0 := image_eq_zero_of_notMem_tsupport hn + have hgz : G k j x = 0 := image_eq_zero_of_notMem_tsupport (fun hx => hn (hs k j hx)) + apply hx + simp [hz, hgz] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullback.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..bca862032b32045ee036f88a5252eeecca2f9527 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullback.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.ContDiffClmDet + +namespace OAI + +noncomputable section + +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Set Filter Topology + +def localPullback {E V : Type*} [TopologicalSpace E] [Zero V] + (X : OpenPartialHomeomorph E E) (f : E → V) (x : E) : V := by + classical + exact if x ∈ X.source then f (X x) else 0 + +lemma localPullback_support {E V : Type*} [TopologicalSpace E] [Zero V] + (X : OpenPartialHomeomorph E E) (f : E → V) : + Function.support (localPullback X f) ⊆ X.symm '' (Function.support f ∩ X.target) := by + intro x hx + have hxs : x ∈ X.source := by + by_contra hn + exact hx (by simp [localPullback, hn]) + refine ⟨X x, ⟨?_, X.map_source hxs⟩, X.left_inv hxs⟩ + simpa only [Function.mem_support, localPullback, ite_eq_left hxs] using hx + +lemma localPullback_tsupport {E V : Type*} [TopologicalSpace E] [T2Space E] [Zero V] + (X : OpenPartialHomeomorph E E) (f : E → V) (hf : HasCompactSupport f) + (hs : tsupport f ⊆ X.target) : + HasCompactSupport (localPullback X f) ∧ + tsupport (localPullback X f) ⊆ X.symm '' tsupport f ∧ + tsupport (localPullback X f) ⊆ X.source := by + have hK := hf.image_of_continuousOn (X.symm.continuousOn.mono hs) + have hsub : Function.support (localPullback X f) ⊆ X.symm '' tsupport f := + (localPullback_support X f).trans (image_mono (fun _ hx => subset_closure hx.1)) + have ht : tsupport (localPullback X f) ⊆ X.symm '' tsupport f := + closure_minimal hsub hK.isClosed + refine ⟨HasCompactSupport.of_support_subset_isCompact hK hsub, ht, ?_⟩ + rintro x hx + obtain ⟨y, hy, rfl⟩ := ht hx + exact X.map_target (hs hy) + +lemma localPullback_contDiff {E V : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] [NormedAddCommGroup V] [NormedSpace ℝ V] + (X : OpenPartialHomeomorph E E) (hX : ContDiffOn ℝ (↑(⊤ : ℕ∞)) X X.source) + (f : E → V) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hfc : HasCompactSupport f) + (hfs : tsupport f ⊆ X.target) : ContDiff ℝ (↑(⊤ : ℕ∞)) (localPullback X f) := by + apply contDiff_of_contDiffOn_tsupport X.open_source _ + (localPullback_tsupport X f hfc hfs).2.2 + intro x hx + have hxs := hx + have heq : localPullback X f =ᶠ[𝓝 x] f ∘ X := by + filter_upwards [X.open_source.mem_nhds hxs] with y hy + simp only [localPullback, ite_eq_left hy, Function.comp_apply] + exact ((hf.contDiffAt.comp x ((hX x hxs).contDiffAt + (X.open_source.mem_nhds hxs))).congr_of_eventuallyEq heq).contDiffWithinAt + +lemma localPullback_comp {E V : Type*} [TopologicalSpace E] [Zero V] + (X : OpenPartialHomeomorph E E) (f : E → V) {z : E} (hz : z ∈ X.target) : + localPullback X f (X.symm z) = f z := by + simp only [localPullback, ite_eq_left (X.map_target hz), X.right_inv hz] + +lemma localPullback_bounds {E : Type*} [TopologicalSpace E] + (X : OpenPartialHomeomorph E E) (f : E → ℝ) (hf : ∀ x, 0 ≤ f x ∧ f x ≤ 1) : + ∀ x, 0 ≤ localPullback X f x ∧ localPullback X f x ≤ 1 := by + intro x + by_cases hx : x ∈ X.source + · simpa only [localPullback, ite_eq_left hx] using hf (X x) + · simp only [localPullback, ite_eq_right hx, le_refl, zero_le_one, and_self] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullbackTsupportInside.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullbackTsupportInside.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ff50ef1d6e0d15390989009ccc4e3633c3e5429 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LocalPullbackTsupportInside.lean @@ -0,0 +1,63 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.NormalStretch + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open Matrix Set MeasureTheory Filter Topology +open scoped ENNReal Matrix.Norms.Elementwise + +lemma localPullback_tsupport_inside + {E V : Type*} [TopologicalSpace E] [T2Space E] [Zero V] + (X : OpenPartialHomeomorph E E) (f : E → V) (hf : HasCompactSupport f) + {U : Set E} (hU : U ⊆ X.source) (hfs : tsupport f ⊆ X '' U) : + tsupport (localPullback X f) ⊆ U := by + have ht : tsupport f ⊆ X.target := hfs.trans (by + rintro y ⟨x, hx, rfl⟩; exact X.map_source (hU hx)) + intro x hx + obtain ⟨y, hy, rfl⟩ := (localPullback_tsupport X f hf ht).2.1 hx + obtain ⟨z, hz, rfl⟩ := hfs hy + simpa only [X.left_inv (hU hz)] using hz + +lemma pushed_exception_measure_le + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + [MeasurableSpace E] [BorelSpace E] (μ : Measure E) [μ.IsAddHaarMeasure] + (Y : E ≃ E) (hY : Differentiable ℝ Y) {U : Set E} (hU : MeasurableSet U) + (hYU : Y '' U = U) (z : E → ℝ) (hz : Continuous z) (a b : ℝ) + {C : ℝ} (hC : ∀ x, |(fderiv ℝ Y x).det| ≤ C) : + μ {x | x ∈ U ∧ z (Y.symm x) ≠ a ∧ z (Y.symm x) ≠ b} ≤ + ENNReal.ofReal C * μ {x | x ∈ U ∧ z x ≠ a ∧ z x ≠ b} := by + let S := {x | x ∈ U ∧ z x ≠ a ∧ z x ≠ b} + have hS : MeasurableSet S := hU.inter + (((isOpen_ne.preimage hz).measurableSet).inter ((isOpen_ne.preimage hz).measurableSet)) + have he : Y '' S = {x | x ∈ U ∧ z (Y.symm x) ≠ a ∧ z (Y.symm x) ≠ b} := by + ext x + constructor + · rintro ⟨y, hy, rfl⟩ + exact ⟨hYU ▸ mem_image_of_mem Y hy.1, by simpa only [Y.symm_apply_apply] using hy.2⟩ + · intro hx + have hxU : Y.symm x ∈ U := by + obtain ⟨y, hy, he⟩ := (show x ∈ Y '' U from hYU.symm ▸ hx.1) + simpa only [← he, Y.symm_apply_apply] using hy + exact ⟨Y.symm x, ⟨hxU, hx.2⟩, Y.apply_symm_apply x⟩ + rw [← he] + exact measure_image_le_det μ hS (fun x _ => hY x) Y.injective.injOn (fun x _ => hC x) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LpEllipticBounds.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LpEllipticBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d3c274ae991d0f22e264dd47381953aeaf1e7ae --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LpEllipticBounds.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +open MeasureTheory +open scoped ENNReal +open Matrix Filter Topology +open Set MeasureTheory Filter Topology +open scoped BigOperators +open Set MeasureTheory Filter Topology +open scoped Manifold +open Set Filter +open scoped Topology +open Set Filter MeasureTheory +open scoped Topology Manifold ENNReal +open Set +namespace ScalarConductivity +open MeasureTheory Set Filter Topology +open scoped ENNReal + +lemma Lp_elliptic_bounds + {X V : Type*} [MeasurableSpace X] [NormedAddCommGroup V] + [InnerProductSpace ℝ V] [MeasurableSpace V] [BorelSpace V] + (μ : Measure X) (E F : Lp V 2 μ) {a b : ℝ} (_ha : 0 < a) (hb : 0 ≤ b) + (h : ∀ᵐ x ∂μ, a * ‖E x‖^2 ≤ inner ℝ (E x) (F x) ∧ + ‖F x‖^2 ≤ b^2 * ‖E x‖^2) : + a * ‖E‖^2 ≤ inner ℝ E F ∧ ‖F‖ ≤ b * ‖E‖ := by + constructor + · rw [← real_inner_self_eq_norm_sq,L2.inner_def,L2.inner_def,← integral_const_mul] + apply integral_mono_ae ((L2.integrable_inner E E).const_mul a) (L2.integrable_inner E F) + filter_upwards [h] with x hx + simpa only [real_inner_self_eq_norm_sq] using hx.1 + · have hn : ∀ᵐ x ∂μ, ‖F x‖ ≤ ‖b • E x‖ := by + filter_upwards [h] with x hx + rw [norm_smul,Real.norm_of_nonneg hb] + nlinarith [norm_nonneg (F x), norm_nonneg (E x),mul_nonneg hb (norm_nonneg (E x))] + have hLp : ∀ᵐ x ∂μ, ‖F x‖ ≤ ‖(b • E : Lp V 2 μ) x‖ := by + filter_upwards [hn,Lp.coeFn_smul b E] with x hx hy + simpa only [hy,Pi.smul_apply] using hx + have hp := Lp.norm_le_norm_of_ae_le hLp + simpa only [norm_smul,Real.norm_of_nonneg hb] using hp + +lemma elliptic_energy_bound + {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] + (E F E₀ : H) {a b : ℝ} (ha : 0 < a) (hb : 0 ≤ b) + (hell : a * ‖E‖^2 ≤ inner ℝ E F) (hflux : ‖F‖ ≤ b * ‖E‖) + (horth : inner ℝ (E-E₀) F = 0) : + ‖E‖ ≤ (b/a) * ‖E₀‖ ∧ ‖F‖ ≤ (b^2/a) * ‖E₀‖ := by + have he : inner ℝ E F = inner ℝ E₀ F := by + rw [inner_sub_left] at horth + linarith + have hi : a * ‖E‖^2 ≤ ‖E₀‖ * (b * ‖E‖) := by + calc + _ ≤ inner ℝ E₀ F := he ▸ hell + _ ≤ ‖E₀‖ * ‖F‖ := real_inner_le_norm _ _ + _ ≤ _ := mul_le_mul_of_nonneg_left hflux (norm_nonneg _) + have hbound : ‖E‖ ≤ (b/a) * ‖E₀‖ := by + by_cases hz : ‖E‖ = 0 + · rw [hz]; positivity + · have hp : 0 < ‖E‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hz) + have hh : a * ‖E‖ ≤ b * ‖E₀‖ := by nlinarith + have hd : ‖E‖ ≤ (b * ‖E₀‖) / a := (le_div_iff₀ ha).mpr (by nlinarith) + convert hd using 1; ring + refine ⟨hbound,hflux.trans ?_⟩ + calc + _ ≤ b * ((b/a)*‖E₀‖) := mul_le_mul_of_nonneg_left hbound hb + _ = (b^2/a)*‖E₀‖ := by ring + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LpExtension.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LpExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0d3a373c9c57888ee6c67d02b9d0c23c32c517d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LpExtension.lean @@ -0,0 +1,138 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology +open scoped ENNReal + +variable {X E : Type*} [MeasurableSpace X] [NormedAddCommGroup E] [NormedSpace ℝ E] + {μ : Measure X} {D : Set X} + +def lpZeroExtensionL (hD : MeasurableSet D) : Lp E 2 (μ.restrict D) →ₗ[ℝ] Lp E 2 μ where + toFun f := ((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).toLp (D.indicator f) + map_add' f g := by + apply Lp.ext + filter_upwards [((memLp_indicator_iff_restrict hD).mpr (Lp.memLp (f+g))).coeFn_toLp, + ((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).coeFn_toLp, + ((memLp_indicator_iff_restrict hD).mpr (Lp.memLp g)).coeFn_toLp, + Lp.coeFn_add (((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).toLp (D.indicator f)) + (((memLp_indicator_iff_restrict hD).mpr (Lp.memLp g)).toLp (D.indicator g)), + (ae_restrict_iff' hD).mp (Lp.coeFn_add f g)] with x hfg hf hg he hadd + rw [hfg,he] + simp only [Pi.add_apply,hf,hg] + by_cases hx : x∈D + · simp only [indicator_of_mem hx,hadd hx,Pi.add_apply] + · simp [hx] + map_smul' c f := by + apply Lp.ext + filter_upwards [((memLp_indicator_iff_restrict hD).mpr (Lp.memLp (c•f))).coeFn_toLp, + ((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).coeFn_toLp, + Lp.coeFn_smul c (((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).toLp (D.indicator f)), + (ae_restrict_iff' hD).mp (Lp.coeFn_smul c f)] with x hcf hf he hsmul + change _=(c • _ : Lp E 2 μ) x + rw [hcf,he] + simp only [Pi.smul_apply,hf] + by_cases hx : x∈D + · simp only [indicator_of_mem hx,hsmul hx,Pi.smul_apply] + · simp [hx] + +lemma lpZeroExtensionL_ae (hD : MeasurableSet D) (f : Lp E 2 (μ.restrict D)) : + lpZeroExtensionL hD f=ᵐ[μ] D.indicator f := + ((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).coeFn_toLp + +lemma lpZeroExtensionL_norm (hD : MeasurableSet D) (f : Lp E 2 (μ.restrict D)) : + ‖lpZeroExtensionL hD f‖=‖f‖ := by + change ‖((memLp_indicator_iff_restrict hD).mpr (Lp.memLp f)).toLp (D.indicator f)‖=_ + rw [Lp.norm_toLp,eLpNorm_indicator_eq_eLpNorm_restrict hD,Lp.norm_def] + +def lpZeroExtensionCLM (hD : MeasurableSet D) : Lp E 2 (μ.restrict D) →L[ℝ] Lp E 2 μ := + (lpZeroExtensionL hD).mkContinuous 1 (by intro f; rw [lpZeroExtensionL_norm,one_mul]) + +lemma lpZeroExtensionCLM_ae (hD : MeasurableSet D) (f : Lp E 2 (μ.restrict D)) : + lpZeroExtensionCLM hD f=ᵐ[μ] D.indicator f := lpZeroExtensionL_ae hD f + +lemma lpZeroExtensionCLM_ae_of_ae (hD : MeasurableSet D) (f : Lp E 2 (μ.restrict D)) + {g : X → E} (hg : f=ᵐ[μ.restrict D] g) : + lpZeroExtensionCLM hD f=ᵐ[μ] D.indicator g := by + filter_upwards [lpZeroExtensionCLM_ae hD f,(ae_restrict_iff' hD).mp hg] with x hx hg + rw [hx] + by_cases h : x∈D + · simp only [indicator_of_mem h,hg h] + · simp [h] + +def lpRestrictionCLM (D : Set X) : Lp E 2 μ →L[ℝ] Lp E 2 (μ.restrict D) := + Lp.LpToLpOfMeasureLeSMul (c:=1) (by simp) (by simpa using Measure.restrict_le_self (μ:=μ) (s:=D)) + +lemma lpRestrictionCLM_ae (D : Set X) (f : Lp E 2 μ) : + lpRestrictionCLM D f=ᵐ[μ.restrict D] f := + Lp.coeFn_LpToLpOfMeasureLeSMul (c:=1) (by simp) (by simpa using Measure.restrict_le_self (μ:=μ) (s:=D)) f + +end + +open Set MeasureTheory Filter Topology + +variable {X : Type*} [MeasurableSpace X] {μ : Measure X} + {χ : X → ℝ} {C : ℝ} (hχ : AEStronglyMeasurable χ μ) (hb : ∀ᵐ x∂μ,‖χ x‖≤C) + +include hχ hb in +lemma lpMultiplier_mem (f : Lp ℝ 2 μ) : MemLp (fun x => χ x*f x) 2 μ := by + apply (Lp.memLp f).of_le_mul (c:=C) (hχ.mul (Lp.memLp f).aestronglyMeasurable) + filter_upwards [hb] with x hx + change ‖χ x*f x‖≤C*‖f x‖ + rw [norm_mul] + exact mul_le_mul_of_nonneg_right hx (norm_nonneg _) + +def lpMultiplierL : Lp ℝ 2 μ →ₗ[ℝ] Lp ℝ 2 μ where + toFun f := (lpMultiplier_mem hχ hb f).toLp _ + map_add' f g := by + apply Lp.ext + filter_upwards [(lpMultiplier_mem hχ hb (f+g)).coeFn_toLp, + (lpMultiplier_mem hχ hb f).coeFn_toLp,(lpMultiplier_mem hχ hb g).coeFn_toLp, + Lp.coeFn_add f g,Lp.coeFn_add ((lpMultiplier_mem hχ hb f).toLp _) + ((lpMultiplier_mem hχ hb g).toLp _)] with x hfg hf hg hi he + rw [hfg,he] + simp only [Pi.add_apply,hf,hg,hi,mul_add] + map_smul' c f := by + apply Lp.ext + filter_upwards [(lpMultiplier_mem hχ hb (c•f)).coeFn_toLp, + (lpMultiplier_mem hχ hb f).coeFn_toLp,Lp.coeFn_smul c f, + Lp.coeFn_smul c ((lpMultiplier_mem hχ hb f).toLp _)] with x hcf hf hi he + change _=(c • _ : Lp ℝ 2 μ) x + rw [hcf,he] + simp only [Pi.smul_apply,smul_eq_mul,hf,hi] + ring + +def lpMultiplierCLM : Lp ℝ 2 μ →L[ℝ] Lp ℝ 2 μ := + (lpMultiplierL hχ hb).mkContinuous C (by + intro f + change ‖(lpMultiplier_mem hχ hb f).toLp _‖≤C*‖f‖ + apply Lp.norm_le_mul_norm_of_ae_le_mul + filter_upwards [(lpMultiplier_mem hχ hb f).coeFn_toLp,hb] with x hx hb + rw [hx,norm_mul] + exact mul_le_mul_of_nonneg_right hb (norm_nonneg _)) + +lemma lpMultiplierCLM_ae (f : Lp ℝ 2 μ) : + lpMultiplierCLM hχ hb f=ᵐ[μ] (fun x => χ x*f x) := + (lpMultiplier_mem hχ hb f).coeFn_toLp + +def compactMultiplierCLM [TopologicalSpace X] [BorelSpace X] + (hχ : Continuous χ) (hc : HasCompactSupport χ) : Lp ℝ 2 μ →L[ℝ] Lp ℝ 2 μ := + lpMultiplierCLM hχ.aestronglyMeasurable + (Eventually.of_forall (hc.exists_bound_of_continuous hχ).choose_spec) + +lemma compactMultiplierCLM_ae [TopologicalSpace X] [BorelSpace X] + (hχ : Continuous χ) (hc : HasCompactSupport χ) (f : Lp ℝ 2 μ) : + compactMultiplierCLM hχ hc f=ᵐ[μ] (fun x => χ x*f x) := + lpMultiplierCLM_ae _ _ f + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/LpFourJet.lean b/lean/OAI/Analysis/Conductivity/Sobolev/LpFourJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..13cf2c46ce5e51b20ce536ee8a44c27f312f7586 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/LpFourJet.lean @@ -0,0 +1,32 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable {X : Type*} [MeasurableSpace X] (μ : Measure X) + +def lpFourJetCLM : (Fin 4 → Lp ℝ 2 μ) →L[ℝ] Lp JetFiber 2 μ := + ∑ i : Fin 4, (((ContinuousLinearMap.id ℝ ℝ).smulRight (EuclideanSpace.single i (1:ℝ))).compLpL 2 μ).comp + (ContinuousLinearMap.proj i) + +lemma lpFourJetCLM_ae (f : Fin 4 → Lp ℝ 2 μ) : + lpFourJetCLM μ f=ᵐ[μ] (fun x => WithLp.toLp 2 (fun i => f i x)) := by + have he (i : Fin 4) := (((ContinuousLinearMap.id ℝ ℝ).smulRight (EuclideanSpace.single i (1:ℝ))).coeFn_compLpL (p:=2) (μ:=μ) (f i)) + simp only [lpFourJetCLM,sum_apply,ContinuousLinearMap.comp_apply,ContinuousLinearMap.proj_apply] + filter_upwards [Lp.coeFn_fun_finsetSum Finset.univ + (fun i : Fin 4 => (((ContinuousLinearMap.id ℝ ℝ).smulRight (EuclideanSpace.single i (1:ℝ))).compLpL 2 μ) (f i)), + ae_all_iff.mpr he] with x hx hi + rw [hx] + simp only [hi,ContinuousLinearMap.smulRight_apply,ContinuousLinearMap.id_apply] + ext j + simp [Pi.single_apply] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/MatchedSeamH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/MatchedSeamH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ea73874b0cddd9578662d410682d0208441e866 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/MatchedSeamH1.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.WholeWeakClosure +import OAI.Analysis.Conductivity.Walls.SeamL2 + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped NNReal + +theorem compact_matched_seam_H1 {τ u : R3 → ℝ} {K : ℝ≥0} + (hτ : LipschitzWith K τ) (hu : MemLp u 2 volume) + (hlocal : ∀ x,0<τ x → LocalLipAt u x) + (g : Fin 3 → R3 → ℝ) (hg : ∀ i,MemLp (g i) 2 volume) + (hd : ∀ i,∀ᵐ x,0<τ x → HasLineDerivAt ℝ u (g i x) x (EuclideanSpace.single i 1)) + (hz : ∀ᵐ x,τ x≤0 → u x=0 ∧ ∀ i,g i x=0) + {R : ℝ} (hR : R<3) (hs : ∀ x,R<‖x‖ → u x=0) + (hthin : Tendsto (fun n : ℕ => ((n:ℝ)+1)^2*∫ x in seamLayer τ n,u x^2) atTop (𝓝 0)) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=u x ∧ ∀ i,weakGradient w x i=g i x) := by + let f : ℕ → R3 → ℝ := fun n x => seamCutoff n (τ x)*u x + have hfs (n : ℕ) (x : R3) (hx : R<‖x‖) : f n x=0 := by + dsimp [f]; rw [hs x hx,mul_zero] + have hfl (n : ℕ) : ∃ L,LipschitzWith L (f n) := + seamCutoff_mul_lipschitz hτ.locallyLipschitz hlocal (bounded_support_compact hs) n + choose L hL using hfl + have hfm (n : ℕ) : MemLp (f n) 2 volume := + (hL n).continuous.memLp_of_hasCompactSupport (bounded_support_compact (hfs n)) + let d : ℕ → Fin 3 → R3 → ℝ := fun n i x => lineDeriv ℝ (f n) x (EuclideanSpace.single i 1) + have hdm (n : ℕ) (i : Fin 3) : MemLp (d n i) 2 volume := + lipschitz_lineDeriv_memLp (hL n) (hfs n) _ + have hv : Tendsto (fun n => (hfm n).toLp (f n)) atTop (𝓝 (hu.toLp u)) := by + apply memLp_toLp_tendsto_of_sq hfm hu + exact seamCutoff_L2_approx hτ.continuous hu (hz.mono (fun x hx ht => (hx ht).1)) + have hgrad (i : Fin 3) : Tendsto (fun n => (hdm n i).toLp (d n i)) atTop (𝓝 ((hg i).toLp (g i))) := by + apply memLp_toLp_tendsto_of_sq (fun n => hdm n i) (hg i) + exact seamCutoff_gradient_L2_approx hτ _ hu (hg i) (hd i) + (hz.mono (fun x hx ht => ⟨(hx ht).1,(hx ht).2 i⟩)) (fun n => hdm n i) hthin + have hw (i : Fin 3) : WeakL2Direction (hu.toLp u) ((hg i).toLp (g i)) (EuclideanSpace.single i 1) := by + apply WeakL2Direction.closed hv (hgrad i) + intro n + exact (lipschitz_weakDirection (hL n) _).congr (hfm n).coeFn_toLp (hdm n i).coeFn_toLp + let F : Fin 4 → WholeL2 := Fin.cases (hu.toLp u) (fun i => (hg i).toLp (g i)) + obtain ⟨w,hw₀,he⟩ := compact_weak_H1 F hw hR (by + filter_upwards [hu.coeFn_toLp] with x hx + intro hn + exact hx.trans (hs x hn)) + refine ⟨w,hw₀,?_⟩ + have hv' := hu.coeFn_toLp.filter_mono (ae_mono (Measure.restrict_le_self (s:=ball))) + have hg' := (ae_all_iff.mpr (fun i => (hg i).coeFn_toLp)).filter_mono + (ae_mono (Measure.restrict_le_self (s:=ball))) + filter_upwards [he,hv',hg'] with x hx hy hz + exact ⟨hx.1.trans hy,fun i => (hx.2 i).trans (hz i)⟩ + +theorem compact_matched_seam_H1_pi {τ u : (Fin 3 → ℝ) → ℝ} {K : ℝ≥0} + (hτ : LipschitzWith K τ) (hu : MemLp u 2 volume) + (hlocal : ∀ x,0<τ x → LocalLipAt u x) + (g : Fin 3 → (Fin 3 → ℝ) → ℝ) (hg : ∀ i,MemLp (g i) 2 volume) + (hd : ∀ i,∀ᵐ x,0<τ x → HasLineDerivAt ℝ u (g i x) x (Pi.single i 1)) + (hz : ∀ᵐ x,τ x≤0 → u x=0 ∧ ∀ i,g i x=0) + {R : ℝ} (hR : R<3) (hs : ∀ x,R<‖WithLp.toLp 2 x‖ → u x=0) + (hthin : Tendsto (fun n : ℕ => ((n:ℝ)+1)^2* + ∫ x in {x | 0<τ x ∧ ((n:ℝ)+1)*τ x≤2},u x^2) atTop (𝓝 0)) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + weakValue w x=u (WithLp.ofLp x) ∧ ∀ i,weakGradient w x i=g i (WithLp.ofLp x)) := by + let E : R3 ≃L[ℝ] (Fin 3 → ℝ) := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hm : MeasurePreserving E volume volume := PiLp.volume_preserving_ofLp (Fin 3) + have hd' (i : Fin 3) : ∀ᵐ x : R3,0<τ (E x) → + HasLineDerivAt ℝ (u ∘ E) (g i (E x)) x (EuclideanSpace.single i 1) := by + filter_upwards [hm.quasiMeasurePreserving.ae (hd i)] with x hx ht + have hh := hx ht + have he : E (EuclideanSpace.single i 1)=Pi.single i 1 := rfl + simpa only [HasLineDerivAt,Function.comp_apply,map_add,map_smul,he] + using hh + have hthin' : Tendsto (fun n : ℕ => ((n:ℝ)+1)^2* + ∫ x in seamLayer (τ ∘ E) n,(u (E x))^2) atTop (𝓝 0) := by + convert hthin using 1 + ext n + congr 1 + have hs' : MeasurableSet {x : Fin 3 → ℝ | 0<τ x ∧ ((n:ℝ)+1)*τ x≤2} := + (measurableSet_lt measurable_const hτ.continuous.measurable).inter + (measurableSet_le (measurable_const.mul hτ.continuous.measurable) measurable_const) + exact (hm.restrict_preimage hs').integral_comp E.toHomeomorph.measurableEmbedding (fun x => u x^2) + apply compact_matched_seam_H1 (hτ.comp E.lipschitzWith) (hu.comp_measurePreserving hm) + (fun x ht => (hlocal (E x) ht).comp (E.lipschitzWith.locallyLipschitz x)) + (fun i => g i ∘ E) (fun i => (hg i).comp_measurePreserving hm) hd' + (hm.quasiMeasurePreserving.ae hz) hR _ hthin' + intro x hx + exact hs (E x) hx + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/NonlinearLp.lean b/lean/OAI/Analysis/Conductivity/Sobolev/NonlinearLp.lean new file mode 100644 index 0000000000000000000000000000000000000000..35b06d80caecee33803e2ec23c0d7e438ea0d0b5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/NonlinearLp.lean @@ -0,0 +1,210 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.MatrixFiniteLaminate + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal + +lemma unifIntegrable_of_norm_domination + {X E F ι : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedAddCommGroup F] + {μ : Measure X} {p : ℝ≥0∞} {f : ι → X → E} {g : ι → X → F} + (hf : UnifIntegrable f p μ) (hg : ∀ i, AEStronglyMeasurable (g i) μ) + (hfg : ∀ i, ∀ᵐ x ∂μ, ‖g i x‖≤‖f i x‖) : + UnifIntegrable g p μ := by + apply unifIntegrable_iff.mpr + intro ε hε + obtain ⟨δ,hδ,hb⟩ := unifIntegrable_iff.mp hf ε hε + refine ⟨δ,hδ,fun index region hregion => ?_⟩ + exact (eLpNorm_mono_ae (hg index).restrict + ((hfg index).filter_mono ae_restrict_le)).trans (hb index region hregion) + +lemma continuous_comp_tendstoInMeasure + {X E F : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedAddCommGroup F] + {μ : Measure X} [IsFiniteMeasure μ] + {f : ℕ → X → E} {g : X → E} (hf : ∀ n, AEStronglyMeasurable (f n) μ) + (hfg : TendstoInMeasure μ f atTop g) {T : E → F} (hT : Continuous T) : + TendstoInMeasure μ (fun n x => T (f n x)) atTop (fun x => T (g x)) := by + apply (exists_seq_tendstoInMeasure_atTop_iff (fun n => hT.comp_aestronglyMeasurable (hf n))).mpr + intro ns hns + obtain ⟨ms,hms,hlim⟩ := (hfg.comp hns.tendsto_atTop).exists_seq_tendsto_ae + refine ⟨ms,hms,?_⟩ + filter_upwards [hlim] with x hx + exact hT.continuousAt.tendsto.comp hx + +lemma nonlinear_memLp + {X E F : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + (μ : Measure X) {T : E → F} (hT : Continuous T) {C : ℝ} + (hC : 0≤C) (hb : ∀ z, ‖T z‖≤C*‖z‖) (f : Lp E 2 μ) : + MemLp (fun x => T (f x)) 2 μ := by + apply ((Lp.memLp f).const_smul C).mono (hT.comp_aestronglyMeasurable (Lp.aestronglyMeasurable f)) + filter_upwards [] with x + simpa only [Pi.smul_apply,norm_smul,Real.norm_of_nonneg hC] using hb (f x) + +def nonlinearLp + {X E F : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + (μ : Measure X) (T : E → F) (hT : Continuous T) (C : ℝ) + (hC : 0≤C) (hb : ∀ z, ‖T z‖≤C*‖z‖) (f : Lp E 2 μ) : Lp F 2 μ := + (nonlinear_memLp μ hT hC hb f).toLp _ + +lemma nonlinearLp_coe_ae + {X E F : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + (μ : Measure X) (T : E → F) (hT : Continuous T) (C : ℝ) + (hC : 0≤C) (hb : ∀ z, ‖T z‖≤C*‖z‖) (f : Lp E 2 μ) : + nonlinearLp μ T hT C hC hb f =ᵐ[μ] fun x => T (f x) := + MemLp.coeFn_toLp _ + +theorem nonlinearLp_continuous + {X E F : Type*} [MeasurableSpace X] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + (μ : Measure X) [IsFiniteMeasure μ] (T : E → F) (hT : Continuous T) (C : ℝ) + (hC : 0≤C) (hb : ∀ z, ‖T z‖≤C*‖z‖) : + Continuous (nonlinearLp μ T hT C hC hb) := by + apply continuous_iff_seqContinuous.mpr + intro f g hfg + have hfI := continuous_comp_tendstoInMeasure (fun n => Lp.aestronglyMeasurable (f n)) + (tendstoInMeasure_of_tendsto_Lp hfg) hT + have hCseq : Tendsto (fun n => C • f n) atTop (𝓝 (C • g)) := hfg.const_smul C + have hUI := unifIntegrable_of_tendsto_Lp (p := (2:ℝ≥0∞)) (by norm_num) (by norm_num) + (fun n => Lp.memLp (C • f n)) (Lp.memLp (C • g)) + ((Lp.tendsto_Lp_iff_tendsto_eLpNorm' _ _).mp hCseq) + have hUI' : UnifIntegrable (fun n x => T (f n x)) 2 μ := by + apply unifIntegrable_of_norm_domination hUI + (fun n => hT.comp_aestronglyMeasurable (Lp.aestronglyMeasurable (f n))) + intro n + filter_upwards [Lp.coeFn_smul C (f n)] with x hx + rw [hx,Pi.smul_apply,norm_smul,Real.norm_of_nonneg hC] + exact hb (f n x) + have hnorm := tendsto_Lp_finite_of_tendstoInMeasure (p := (2:ℝ≥0∞)) (by norm_num) (by norm_num) + (fun n => hT.comp_aestronglyMeasurable (Lp.aestronglyMeasurable (f n))) + (nonlinear_memLp μ hT hC hb g) hUI' hfI + apply (Lp.tendsto_Lp_iff_tendsto_eLpNorm' _ _).mpr + apply hnorm.congr + intro n + apply eLpNorm_congr_ae + filter_upwards [nonlinearLp_coe_ae μ T hT C hC hb (f n), + nonlinearLp_coe_ae μ T hT C hC hb g] with x hx hy + simp only [Function.comp_apply,Pi.sub_apply,hx,hy] + +instance ballMeasure_finite : IsFiniteMeasure ballMeasure := by + exact isFiniteMeasure_restrict.mpr Metric.isBounded_ball.measure_lt_top.ne + +lemma smoothJets_zero : (0 : JetSpace) ∈ smoothJets := by + obtain ⟨f,hf,_,_,hm,he⟩ := compactSmoothJets_zero + exact ⟨f,hf,hm,he⟩ + +lemma smoothJets_add {z w : JetSpace} (hz : z∈smoothJets) (hw : w∈smoothJets) : + z+w∈smoothJets := by + obtain ⟨f,hf,hfm,rfl⟩ := hz + obtain ⟨g,hg,hgm,rfl⟩ := hw + have hj := smoothJet_add (hf.differentiable (by simp)) (hg.differentiable (by simp)) + have hm : MemLp (smoothJet (f+g)) 2 ballMeasure := by rw [hj]; exact hfm.add hgm + refine ⟨f+g,hf.add hg,hm,?_⟩ + apply Lp.ext + filter_upwards [Lp.coeFn_add (hfm.toLp _) (hgm.toLp _),hfm.coeFn_toLp, + hgm.coeFn_toLp,hm.coeFn_toLp] with x ha hx hy hz + rw [ha,hz,hj] + simp only [Pi.add_apply,hx,hy] + +lemma smoothJets_smul (c : ℝ) {z : JetSpace} (hz : z∈smoothJets) : + c • z∈smoothJets := by + obtain ⟨f,hf,hfm,rfl⟩ := hz + have hj := smoothJet_smul c (hf.differentiable (by simp)) + have hm : MemLp (smoothJet (c • f)) 2 ballMeasure := by rw [hj]; exact hfm.const_smul c + refine ⟨c • f,hf.const_smul c,hm,?_⟩ + apply Lp.ext + filter_upwards [Lp.coeFn_smul c (hfm.toLp _),hfm.coeFn_toLp,hm.coeFn_toLp] with x ha hx hy + rw [ha,hy,hj] + simp only [Pi.smul_apply,hx] + +lemma span_smoothJets : (Submodule.span ℝ smoothJets : Set JetSpace)=smoothJets := by + let K : Submodule ℝ JetSpace := { + carrier := smoothJets + zero_mem' := smoothJets_zero + add_mem' := smoothJets_add + smul_mem' := smoothJets_smul } + exact congrArg SetLike.coe (Submodule.span_eq K) + +lemma H1Space_eq_closure : (H1Space : Set JetSpace)=closure smoothJets := by + change closure (Submodule.span ℝ smoothJets : Set JetSpace)=closure smoothJets + rw [span_smoothJets] + +lemma zeroTraceAmbient_eq_closure : (zeroTraceAmbient : Set JetSpace)=closure compactSmoothJets := by + change closure (Submodule.span ℝ compactSmoothJets : Set JetSpace)=closure compactSmoothJets + rw [span_compactSmoothJets] + +lemma nonlinear_closure_preservation {X : Type*} [TopologicalSpace X] + {T : X → X} (hT : Continuous T) {S : Set X} (hS : MapsTo T S S) : + MapsTo T (closure S) (closure S) := by + intro x hx + exact (image_closure_subset_closure_image hT).trans (closure_mono hS.image_subset) ⟨x,hx,rfl⟩ + +def jetSuperposition (g dg : ℝ → ℝ) (z : JetFiber) : JetFiber := + jetLiftValue (g (jetValue z)) + jetLiftGradient (dg (jetValue z) • jetGradient z) + +lemma jetSuperposition_continuous {g dg : ℝ → ℝ} (hg : Continuous g) (hdg : Continuous dg) : + Continuous (jetSuperposition g dg) := by + exact (jetLiftValue.continuous.comp (hg.comp jetValue.continuous)).add + (jetLiftGradient.continuous.comp ((hdg.comp jetValue.continuous).smul jetGradient.continuous)) + +def jetSuperpositionBound (C : ℝ) : ℝ := + ‖jetLiftValue‖*C*‖jetValue‖ + ‖jetLiftGradient‖*C*‖jetGradient‖ + +lemma jetSuperpositionBound_nonneg {C : ℝ} (hC : 0≤C) : 0≤jetSuperpositionBound C := by + unfold jetSuperpositionBound + positivity + +lemma jetSuperposition_bound {g dg : ℝ → ℝ} {C : ℝ} (hC : 0≤C) + (hg : ∀ r, ‖g r‖≤C*‖r‖) (hdg : ∀ r, ‖dg r‖≤C) (z : JetFiber) : + ‖jetSuperposition g dg z‖≤jetSuperpositionBound C*‖z‖ := by + have hval := jetValue.le_opNorm z + have hgrad := jetGradient.le_opNorm z + have h1 := jetLiftValue.le_opNorm (g (jetValue z)) + have h2 := jetLiftGradient.le_opNorm (dg (jetValue z) • jetGradient z) + rw [norm_smul] at h2 + calc + _ ≤ ‖jetLiftValue (g (jetValue z))‖ + + ‖jetLiftGradient (dg (jetValue z) • jetGradient z)‖ := norm_add_le _ _ + _ ≤ ‖jetLiftValue‖*(C*(‖jetValue‖*‖z‖)) + + ‖jetLiftGradient‖*(C*(‖jetGradient‖*‖z‖)) := by + apply add_le_add + · exact h1.trans (mul_le_mul_of_nonneg_left ((hg _).trans + (mul_le_mul_of_nonneg_left hval hC)) (norm_nonneg _)) + · exact h2.trans (mul_le_mul_of_nonneg_left + (mul_le_mul (hdg _) hgrad (norm_nonneg _) hC) (norm_nonneg _)) + _ = _ := by unfold jetSuperpositionBound; ring + +lemma gradient_comp_scalar {g dg : ℝ → ℝ} (hdg : ∀ r, HasDerivAt g (dg r) r) + {f : R3 → ℝ} (hf : Differentiable ℝ f) (x : R3) : + gradient (g ∘ f) x = dg (f x) • gradient f x := by + unfold gradient + rw [((hdg (f x)).comp_hasFDerivAt x (hf x).hasFDerivAt).fderiv] + simp + +lemma smoothJet_comp {g dg : ℝ → ℝ} (hdg : ∀ r, HasDerivAt g (dg r) r) + {f : R3 → ℝ} (hf : Differentiable ℝ f) (x : R3) : + smoothJet (g ∘ f) x = jetSuperposition g dg (smoothJet f x) := by + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change g (f x)=g (f x)+0; simp + · change gradient (g ∘ f) x j = 0 + (dg (f x) • gradient f x) j + rw [gradient_comp_scalar hdg hf] + simp + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/OriginalH1VoltageRestriction.lean b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalH1VoltageRestriction.lean new file mode 100644 index 0000000000000000000000000000000000000000..a2182cbf9bec6d1a1ecf6851b65f2f684e19fcc1 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalH1VoltageRestriction.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.C1VoltageApproximation +import OAI.Analysis.Conductivity.Variational.OriginalVoltageRestriction + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal Classical + +lemma original_voltage_potential_smooth (f : R3 → ℝ) + (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) (j : Fin 2) : + ContDiff ℝ (↑(⊤:ℕ∞)) (fun y : Coord3 => fun k : Fin 2 => if k=j then f (WithLp.toLp 2 y) else 0) := by + let P : Coord3 ≃L[ℝ] R3 := (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).symm + apply contDiff_pi.mpr + intro k + by_cases hk : k=j + · simpa only [hk,ite_true,Function.comp_def,show (P : Coord3 → R3)=WithLp.toLp 2 from rfl] + using hf.comp P.contDiff + · simpa only [hk,ite_false] using + (contDiff_const : ContDiff ℝ (↑(⊤:ℕ∞)) (fun _ : Coord3 => (0:ℝ))) + +lemma originalVoltageJetCLM_smooth {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) + (j : Fin 2) {z : JetSpace} (hz : z∈smoothJets) : + originalVoltageJetCLM U j z∈smoothVoltageJets volume U := by + obtain ⟨f,hf,hm,rfl⟩ := hz + let v : Coord3 → Fin 2 → ℝ := fun y k => if k=j then f (WithLp.toLp 2 y) else 0 + have hv := original_voltage_potential_smooth f hf j + obtain ⟨hu,hg,hh⟩ := C1_voltageJet_mem (hv.of_le (by simp)) hbounded hU + refine ⟨v,hv,hu,hg,?_⟩ + have hm' := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae + ((ae_restrict_iff' (show MeasurableSet ball from Metric.isOpen_ball.measurableSet)).1 hm.coeFn_toLp) + have hae := originalVoltageJetCLM_ae U hU hUb j (hm.toLp _) + apply Prod.ext + · apply Lp.ext + filter_upwards [hae.1,ae_restrict_of_ae hm',ae_restrict_mem hU,hu.coeFn_toLp] + with x hx hm hxU hu + rw [hx,hu] + funext k + rw [hm (hUb x hxU)] + rfl + · apply Lp.ext + filter_upwards [hae.2,ae_restrict_of_ae hm',ae_restrict_mem hU,hg.coeFn_toLp] + with x hx hm hxU hg + rw [hx,hg] + have he := original_voltage_smooth_gradient f hf j x + rw [he] + congr 1 + funext ik + rw [hm (hUb x hxU)] + +theorem originalVoltageJetCLM_H1 {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) + (j : Fin 2) (u : H1) : + originalVoltageJetCLM U j u.val∈voltageH1Jets volume U := by + have hs : H1Space ≤ (voltageH1Jets volume U).comap (originalVoltageJetCLM U j).toLinearMap := by + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + intro z hz + exact (Submodule.span ℝ (smoothVoltageJets volume U)).le_topologicalClosure + (Submodule.subset_span (originalVoltageJetCLM_smooth hU hUb hbounded j hz)) + · exact (Submodule.isClosed_topologicalClosure _).preimage (originalVoltageJetCLM U j).continuous + exact hs u.property + +theorem scalarization_original_H1_test_bridge {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) + {F G : Lp FieldVector 2 (volume.restrict U)} + (hF : ∀ W : voltageH1Jets volume U,inner ℝ W.val.2 F=inner ℝ W.val.2 G) + (u : H1) (j : Fin 2) : + inner ℝ (originalVoltageJetCLM U j u.val).2 F= + inner ℝ (originalVoltageJetCLM U j u.val).2 G := by + exact hF ⟨originalVoltageJetCLM U j u.val,originalVoltageJetCLM_H1 hU hUb hbounded j u⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/OriginalMultiplierOperator.lean b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalMultiplierOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..a48a25ee8ddef9039531dc04ca3695846058b83f --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalMultiplierOperator.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.OriginalSmoothMultiplier + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable {χ : R3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + +lemma originalMulJetCLM_mem_H1 (u : H1) : originalMulJetCLM hχ hc u∈H1Space := by + have hclosed : IsClosed {u : H1 | originalMulJetCLM hχ hc u∈H1Space} := + H1_isClosed.preimage (originalMulJetCLM hχ hc).continuous + apply (closure_minimal (s:={u : H1 | u.val∈smoothJets}) ?_ hclosed) (smoothH1_dense u) + rintro v ⟨f,hf,hm,he⟩ + have hv : v=smoothH1 f hf := Subtype.ext he + change originalMulJetCLM hχ hc v∈H1Space + rw [hv,originalMulJetCLM_smooth] + exact (smoothH1 (χ*f) (hχ.mul hf)).property + +def originalMulH1CLM : H1 →L[ℝ] H1 := + (originalMulJetCLM hχ hc).codRestrict H1Space (originalMulJetCLM_mem_H1 hχ hc) + +lemma originalMulH1_smooth {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) : + originalMulH1CLM hχ hc (smoothH1 f hf)=smoothH1 (χ*f) (hχ.mul hf) := + Subtype.ext (originalMulJetCLM_smooth hχ hc hf) + +lemma originalMulH1_value (u : H1) : + weakValue (originalMulH1CLM hχ hc u)=ᵐ[ballMeasure] (fun x => χ x*weakValue u x) := by + filter_upwards [originalMulJetCLM_ae hχ hc u] with x hx + exact congrArg (fun z : JetFiber => z 0) hx + +lemma originalMulH1_gradient (u : H1) : + weakGradient (originalMulH1CLM hχ hc u)=ᵐ[ballMeasure] + (fun x => weakValue u x • gradient χ x+χ x • weakGradient u x) := by + filter_upwards [originalMulJetCLM_ae hχ hc u] with x hx + change jetGradient (originalMulJetCLM hχ hc u x)=_ + rw [hx] + ext j + change fderiv ℝ χ x (EuclideanSpace.single j 1)*weakValue u x+χ x*weakGradient u x j= + weakValue u x*gradient χ x j+χ x*weakGradient u x j + rw [gradient_apply_single] + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/OriginalPairVoltage.lean b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalPairVoltage.lean new file mode 100644 index 0000000000000000000000000000000000000000..400f86822b75714b579d50da5bea3c9979262a13 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalPairVoltage.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.OriginalH1VoltageRestriction + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +def originalPairVoltageJet (U : Set Coord3) (w : Fin 2 → H1) : VoltageJetSpace volume U := + originalVoltageJetCLM U 0 (w 0).val + originalVoltageJetCLM U 1 (w 1).val + +lemma originalPairVoltageJet_H1 {U : Set Coord3} (hU : MeasurableSet U) + (hb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) (w : Fin 2 → H1) : + originalPairVoltageJet U w∈voltageH1Jets volume U := + (voltageH1Jets volume U).add_mem + (originalVoltageJetCLM_H1 hU hb hbounded 0 (w 0)) + (originalVoltageJetCLM_H1 hU hb hbounded 1 (w 1)) + +lemma originalPairVoltageJet_ae {U : Set Coord3} (hU : MeasurableSet U) + (hb : ∀ y∈U,WithLp.toLp 2 y∈ball) (w : Fin 2 → H1) : + (originalPairVoltageJet U w).1=ᵐ[volume.restrict U] + (fun y j => weakValue (w j) (WithLp.toLp 2 y)) ∧ + (originalPairVoltageJet U w).2=ᵐ[volume.restrict U] + (fun y => WithLp.toLp 2 (fun ij => originalPiGradient (w ij.2) y ij.1)) := by + have h0 := originalVoltageJetCLM_ae U hU hb 0 (w 0).val + have h1 := originalVoltageJetCLM_ae U hU hb 1 (w 1).val + constructor + · filter_upwards [Lp.coeFn_add (originalVoltageJetCLM U 0 (w 0).val).1 + (originalVoltageJetCLM U 1 (w 1).val).1,h0.1,h1.1] with y he h0 h1 + change ((originalVoltageJetCLM U 0 (w 0).val).1+(originalVoltageJetCLM U 1 (w 1).val).1) y=_ + rw [he,Pi.add_apply,h0,h1] + ext j + fin_cases j <;> simp [weakValue,jetValue] <;> rfl + · filter_upwards [Lp.coeFn_add (originalVoltageJetCLM U 0 (w 0).val).2 + (originalVoltageJetCLM U 1 (w 1).val).2,h0.2,h1.2] with y he h0 h1 + change ((originalVoltageJetCLM U 0 (w 0).val).2+(originalVoltageJetCLM U 1 (w 1).val).2) y=_ + rw [he,Pi.add_apply,h0,h1] + ext ⟨i,j⟩ + fin_cases j <;> simp [originalPiGradient,weakGradient] + +lemma voltageGradient_component {v : Coord3 → Fin 2 → ℝ} {y : Coord3} + (hv : DifferentiableAt ℝ v y) (i : Fin 3) (j : Fin 2) : + (voltageGradient v y) (i,j)=fderiv ℝ (fun x => v x j) y (Pi.single i 1) := by + have he : fderiv ℝ (fun x => v x j) y=(ContinuousLinearMap.proj j).comp (fderiv ℝ v y) := + ((ContinuousLinearMap.proj j : (Fin 2 → ℝ) →L[ℝ] ℝ).hasFDerivAt.comp y hv.hasFDerivAt).fderiv + rw [he] + rfl + +theorem original_pair_voltageH1 {U : Set Coord3} (hU : MeasurableSet U) + (hb : ∀ y∈U,WithLp.toLp 2 y∈ball) (hbounded : Bornology.IsBounded U) + (w : Fin 2 → H1) (v : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) + (hv : ∀ᵐ y : Coord3,y∈U → v y=fun j => weakValue (w j) (WithLp.toLp 2 y)) + (hd : ∀ᵐ y : Coord3,y∈U → ∀ i : Fin 3,∀ j : Fin 2, + fderiv ℝ (fun x => v x j) y (Pi.single i 1)=weakGradient (w j) (WithLp.toLp 2 y) i) + (hr : volume (U \ regularRegion v A U)=0) : + ∃ (hu : MemLp v 2 (volume.restrict U)) (hE : MemLp (voltageGradient v) 2 (volume.restrict U)), + (hu.toLp _,hE.toLp _)=originalPairVoltageJet U w ∧ + (hu.toLp _,hE.toLp _)∈voltageH1Jets volume U := by + have hp := originalPairVoltageJet_ae hU hb w + have he : voltageGradient v=ᵐ[volume.restrict U] + (fun y => WithLp.toLp 2 (fun ij => originalPiGradient (w ij.2) y ij.1)) := by + filter_upwards [ae_restrict_of_ae hd,ae_restrict_of_ae (measure_eq_zero_iff_ae_notMem.mp hr), + ae_restrict_mem hU] with y hd hr hy + have hyR : y∈regularRegion v A U := by simpa only [Set.mem_sdiff,hy,true_and,not_not] using hr + ext ⟨i,j⟩ + rw [voltageGradient_component (regularRegion_differentiable hyR),hd hy i j] + rfl + have hv' : v=ᵐ[volume.restrict U] (originalPairVoltageJet U w).1 := by + filter_upwards [ae_restrict_of_ae hv,ae_restrict_mem hU,hp.1] with y hv hy hp + exact (hv hy).trans hp.symm + have hg' := he.trans hp.2.symm + let hu := (Lp.memLp (originalPairVoltageJet U w).1).ae_eq hv'.symm + let hE := (Lp.memLp (originalPairVoltageJet U w).2).ae_eq hg'.symm + have hh : (hu.toLp _,hE.toLp _)=originalPairVoltageJet U w := by + apply Prod.ext + · exact Lp.ext (hu.coeFn_toLp.trans hv') + · exact Lp.ext (hE.coeFn_toLp.trans hg') + exact ⟨hu,hE,hh,hh ▸ originalPairVoltageJet_H1 hU hb hbounded w⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/OriginalSmoothMultiplier.lean b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalSmoothMultiplier.lean new file mode 100644 index 0000000000000000000000000000000000000000..a5dd11f00ecb63cea03990ac5fa5a146d8047801 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/OriginalSmoothMultiplier.lean @@ -0,0 +1,249 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.PhysicalBlockDomain +import OAI.Analysis.Conductivity.Variational.PhysicalTerminalBands + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable {χ : R3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + +def originalMulComponentCLM (i : Fin 4) : H1 →L[ℝ] Lp ℝ 2 ballMeasure := + Fin.cases ((compactMultiplierCLM hχ.continuous hc).comp weakValueL) + (fun j => ((compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (EuclideanSpace.single j 1))).comp weakValueL)+ + ((compactMultiplierCLM hχ.continuous hc).comp (weakDirectionL (EuclideanSpace.single j 1)))) i + +def originalMulJetCLM : H1 →L[ℝ] JetSpace := + (lpFourJetCLM ballMeasure).comp (ContinuousLinearMap.pi (originalMulComponentCLM hχ hc)) + +lemma originalMulComponentCLM_value (u : H1) : + originalMulComponentCLM hχ hc 0 u=ᵐ[ballMeasure] fun x => χ x*weakValue u x := by + filter_upwards [compactMultiplierCLM_ae hχ.continuous hc (weakValueL u),weakValueL_apply_ae u] + with x hx hu + exact hx.trans (congrArg (χ x*·) hu) + +lemma originalMulComponentCLM_gradient (u : H1) (j : Fin 3) : + originalMulComponentCLM hχ hc j.succ u=ᵐ[ballMeasure] fun x => + fderiv ℝ χ x (EuclideanSpace.single j 1)*weakValue u x+χ x*weakGradient u x j := by + have h0 := compactMultiplierCLM_ae ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (EuclideanSpace.single j 1)) (weakValueL u) + have h1 := compactMultiplierCLM_ae hχ.continuous hc (weakDirectionL (EuclideanSpace.single j 1) u) + filter_upwards [h0,h1,weakValueL_apply_ae u,weakDirectionL_apply_ae u (EuclideanSpace.single j 1), + Lp.coeFn_add + (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (EuclideanSpace.single j 1)) (weakValueL u)) + (compactMultiplierCLM hχ.continuous hc (weakDirectionL (EuclideanSpace.single j 1) u))] + with x h0 h1 hu hd ha + change (compactMultiplierCLM ((hχ.continuous_fderiv (by simp)).clm_apply continuous_const) + (hc.fderiv_apply ℝ (EuclideanSpace.single j 1)) (weakValueL u)+ + compactMultiplierCLM hχ.continuous hc (weakDirectionL (EuclideanSpace.single j 1) u)) x=_ + rw [ha] + simp only [Pi.add_apply,h0,h1,hu,hd,EuclideanSpace.inner_single_left,RCLike.conj_to_real,one_mul] + +lemma originalMulJetCLM_ae (u : H1) : + originalMulJetCLM hχ hc u=ᵐ[ballMeasure] fun x => + WithLp.toLp 2 (Fin.cases (χ x*weakValue u x) + (fun j => fderiv ℝ χ x (EuclideanSpace.single j 1)*weakValue u x+χ x*weakGradient u x j)) := by + filter_upwards [lpFourJetCLM_ae ballMeasure (fun i => originalMulComponentCLM hχ hc i u), + originalMulComponentCLM_value hχ hc u,ae_all_iff.mpr (originalMulComponentCLM_gradient hχ hc u)] + with x hj hv hg + change lpFourJetCLM ballMeasure (fun i => originalMulComponentCLM hχ hc i u) x=_ + rw [hj] + ext i + exact Fin.cases hv hg i + +lemma originalMulJetCLM_smooth {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤:ℕ∞)) f) : + originalMulJetCLM hχ hc (smoothH1 f hf)=(smoothH1 (χ*f) (hχ.mul hf)).val := by + apply Lp.ext + filter_upwards [originalMulJetCLM_ae hχ hc (smoothH1 f hf),smoothH1_value f hf,smoothH1_gradient f hf, + (smoothJet_memLp (hχ.mul hf)).coeFn_toLp] with x hm hv hg hs + change (smoothH1 (χ*f) (hχ.mul hf)).val x=smoothJet (χ*f) x at hs + rw [hm,hs] + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change χ x*weakValue (smoothH1 f hf) x=χ x*f x + rw [hv] + · change fderiv ℝ χ x (EuclideanSpace.single j 1)*weakValue (smoothH1 f hf) x+ + χ x*weakGradient (smoothH1 f hf) x j=gradient (χ*f) x j + rw [hv,hg] + have hj (g : R3 → ℝ) : gradient g x j=fderiv ℝ g x (EuclideanSpace.single j 1) := by + have h : inner ℝ (EuclideanSpace.single j 1) (gradient g x)= + (starRingEnd ℝ) (fderiv ℝ g x (EuclideanSpace.single j 1)) := inner_gradient_right + simpa only [EuclideanSpace.inner_single_left,RCLike.conj_to_real,one_mul] using h + rw [hj,hj,fderiv_mul (hχ.differentiable (by simp) x) (hf.differentiable (by simp) x)] + simp only [add_apply,smul_apply,smul_eq_mul] + ring + +lemma originalMulJetCLM_mem_zero (hs : tsupport χ⊆ball) (u : H1) : + originalMulJetCLM hχ hc u∈zeroTraceAmbient := by + have hclosed : IsClosed {u : H1 | originalMulJetCLM hχ hc u∈zeroTraceAmbient} := + (Submodule.isClosed_topologicalClosure _).preimage (originalMulJetCLM hχ hc).continuous + apply (closure_minimal (s:={u : H1 | u.val∈smoothJets}) ?_ hclosed) (smoothH1_dense u) + rintro v ⟨f,hf,hm,he⟩ + have hv : v=smoothH1 f hf := Subtype.ext he + rw [hv] + change originalMulJetCLM hχ hc (smoothH1 f hf)∈zeroTraceAmbient + rw [originalMulJetCLM_smooth] + exact smoothH1_mem_H10 (χ*f) (hχ.mul hf) (hc.mul_right) ((tsupport_mul_subset_left).trans hs) + +include hχ hc in + +theorem original_smooth_mul_exists (hs : tsupport χ⊆ball) (u : H1) : + ∃ v : H1,v∈H10 ∧ weakValue v=ᵐ[ballMeasure] fun x => χ x*weakValue u x := by + have hz := originalMulJetCLM_mem_zero hχ hc hs u + refine ⟨⟨originalMulJetCLM hχ hc u,zeroTraceAmbient_le_H1Space hz⟩,hz,?_⟩ + filter_upwards [originalMulJetCLM_ae hχ hc u] with x hx + exact congrArg (fun z : JetFiber => z 0) hx + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology MeasureTheory Matrix UnitAddTorus +lemma LocalLipAt.add {E : Type*} [PseudoMetricSpace E] {f g : E → ℝ} {x : E} + (hf : LocalLipAt f x) (hg : LocalLipAt g x) : LocalLipAt (fun y => f y+g y) x := by + exact (localLipAt_of_contDiffAt + (show ContDiffAt ℝ 1 (fun p : ℝ×ℝ => p.1+p.2) (f x,g x) by fun_prop)).comp + (f:=fun y => (f y,g y)) (x:=x) (hf.prodMk hg) + +namespace PhysicalFiniteEndingData +variable {s : Fin 3 → ℝ} (z : PhysicalFiniteEndingData s) + +def terminalProfileParent (η : ℝ) (j : Fin 2) (y : Coord3) : ℝ := + centralBasisSlopes j 0*z.compression 0*max (terminalTime 0 y) 0* + (1-Real.smoothTransition (terminalTime 0 y/η-1)) + +def terminalProfileChild (η : ℝ) (j : Fin 2) (k : Fin 2) (y : Coord3) : ℝ := + (z.terminalValue k.succ j-z.terminalValue 0 j+ + centralBasisSlopes j k.succ*z.compression k.succ*min (terminalTime k.succ y) 0)* + Real.smoothTransition (terminalTime k.succ y/η+2) + +def terminalProfile (η : ℝ) (j : Fin 2) (y : Coord3) : ℝ := + z.terminalProfileParent η j y+∑ k : Fin 2,z.terminalProfileChild η j k y + +lemma terminalTime_locallyLipschitz (i : Fin 3) : LocallyLipschitz (terminalTime i) := by + refine Fin.cases locallyLipschitz_sourceCollarTime (fun k => ?_) i + exact locallyLipschitz_sourceCollarTime.comp + ((sourceChildInverse_contDiff (actualChildSign k)).of_le (show (1:WithTop ℕ∞)≤↑(⊤:ℕ∞) by simp)).locallyLipschitz + +lemma terminalProfileParent_localLip (η : ℝ) (j : Fin 2) (y : Coord3) : + LocalLipAt (z.terminalProfileParent η j) y := by + have hmax : LocallyLipschitz (fun x => max (terminalTime 0 x) 0) := + (terminalTime_locallyLipschitz 0).max (LipschitzWith.const (0:ℝ)).locallyLipschitz + have hcut : ContDiff ℝ 1 (fun t : ℝ => 1-Real.smoothTransition (t/η-1)) := + contDiff_const.sub ((Real.smoothTransition.contDiff (n:=1)).comp (by fun_prop)) + exact ((localLipAt_of_contDiffAt (contDiffAt_const (c:=centralBasisSlopes j 0*z.compression 0))).mul + (hmax y)).mul (hcut.locallyLipschitz.comp (terminalTime_locallyLipschitz 0) y) + +lemma terminalProfileChild_localLip (η : ℝ) (j : Fin 2) (k : Fin 2) (y : Coord3) : + LocalLipAt (z.terminalProfileChild η j k) y := by + have hmin : LocallyLipschitz (fun x => min (terminalTime k.succ x) 0) := + (terminalTime_locallyLipschitz k.succ).min (LipschitzWith.const (0:ℝ)).locallyLipschitz + have ha : ContDiff ℝ 1 (fun t : ℝ => z.terminalValue k.succ j-z.terminalValue 0 j+ + centralBasisSlopes j k.succ*z.compression k.succ*t) := by fun_prop + have hb : ContDiff ℝ 1 (fun t : ℝ => Real.smoothTransition (t/η+2)) := + (Real.smoothTransition.contDiff (n:=1)).comp (by fun_prop) + exact LocalLipAt.mul (ha.locallyLipschitz.comp hmin y) + (hb.locallyLipschitz.comp (terminalTime_locallyLipschitz k.succ) y) + +lemma terminalProfile_localLip (η : ℝ) (j : Fin 2) (y : Coord3) : + LocalLipAt (z.terminalProfile η j) y := by + change LocalLipAt (fun x => z.terminalProfileParent η j x+∑ k : Fin 2,z.terminalProfileChild η j k x) y + simp only [Fin.sum_univ_two] + exact (z.terminalProfileParent_localLip η j y).add + ((z.terminalProfileChild_localLip η j 0 y).add (z.terminalProfileChild_localLip η j 1 y)) + +lemma terminalProfileParent_zero_left (η : ℝ) (j : Fin 2) {y : Coord3} + (hy : terminalTime 0 y≤0) : z.terminalProfileParent η j y=0 := by + simp [terminalProfileParent,max_eq_right hy] + +lemma terminalProfileParent_zero_right {η : ℝ} (hη : 0<η) (j : Fin 2) {y : Coord3} + (hy : 2*η≤terminalTime 0 y) : z.terminalProfileParent η j y=0 := by + have hh : 1≤terminalTime 0 y/η-1 := by rw [le_sub_iff_add_le,le_div_iff₀ hη]; linarith + simp [terminalProfileParent,Real.smoothTransition.one_of_one_le hh] + +lemma terminalProfileChild_zero {η : ℝ} (hη : 0<η) (j : Fin 2) (k : Fin 2) {y : Coord3} + (hy : terminalTime k.succ y≤-2*η) : z.terminalProfileChild η j k y=0 := by + have hh : terminalTime k.succ y/η+2≤0 := by have hh : terminalTime k.succ y/η≤ -2 := (div_le_iff₀ hη).mpr (by linarith); linarith + simp [terminalProfileChild,Real.smoothTransition.zero_of_nonpos hh] + +lemma terminalTime_far_parent (k : Fin 2) {y : Coord3} + (hy : -centralThickness≤terminalTime k.succ y) : 2*centralThickness≤terminalTime 0 y := by + have hh := sourceExpandedChild_far_parent k hy + change 2*centralThickness≤ sourceCollarTime ((sourceChildHomeomorph (actualChildSign k)) + ((sourceChildHomeomorph (actualChildSign k)).symm y)) at hh + simpa only [Homeomorph.apply_symm_apply,terminalTime,Fin.cases_zero] using hh + +lemma terminalProfile_zero_outside {η : ℝ} (hη : 0<η) (hηc : 2*η z.terminalProfile η j (WithLp.ofLp x) := by + have hz (y : Coord3) (hy : 5/2<‖WithLp.toLp 2 y‖) : z.terminalProfile η j y=0 := by + apply z.terminalProfile_zero_outside hη hηc j + by_contra hn + have hd := (sourceCollarTime_pos_iff_domain y).mp (lt_of_not_ge hn) + have hb := sourceClosure_subset_ball (subset_closure hd) + simp only [Metric.mem_ball,dist_zero_right] at hb + linarith + obtain ⟨w,hw,he⟩ := compact_localLip_H1_pi (z.terminalProfile_localLip η j) + (R:=5/2) (by norm_num) hz + exact ⟨w,hw,he.mono (fun _ h => h.1)⟩ + +lemma terminalProfile_parent_band {η : ℝ} (hη : 0<η) (hηc : 2*η ho l hl + · simp + +end PhysicalFiniteEndingData +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ParentCompletionJoin.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ParentCompletionJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..355fdea0fce3201f88c7bba5e61294e4dfe50397 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ParentCompletionJoin.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.Conductivity.Branching.ParentLocalizedJet + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology + +variable (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) + {χ : (Fin 3 → ℝ) → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hc : HasCompactSupport χ) + (hχb : ∀ x,|χ x|≤1) + (hχs : tsupport χ⊆sourceClosedCollarBand 0 (2*centralThickness)) + +include hχb hχs in +lemma parentLocalJetCLM_smooth_H10 (f : centralSmoothFunctions) : + parentLocalJetCLM s hs ha hχ hc (centralEmbedL s f)∈zeroTraceAmbient := by + have hq := (central_smooth f).comp sourcePairCLE.contDiff + obtain ⟨w,hw,hwe⟩ := smoothCollarTrace_localJoined_H1 hs hq hχ hc hχb ha.ne + (show (0:ℝ) ?_) i + · exact hwx.1.symm + · exact (hwx.2 j).symm + rw [he] + exact hw + +include hχb hχs in + +theorem parentLocalJetCLM_central_H10 (u : centralEnergySpace s) : + parentLocalJetCLM s hs ha hχ hc u.val∈zeroTraceAmbient := by + let T := (zeroTraceAmbient.comap (parentLocalJetCLM s hs ha hχ hc).toLinearMap) + have ht : IsClosed (T : Set (CentralAmbient s)) := + (Submodule.isClosed_topologicalClosure (Submodule.span ℝ compactSmoothJets)).preimage + (parentLocalJetCLM s hs ha hχ hc).continuous + have hr : LinearMap.range (centralEmbedL s)≤T := by + rintro z ⟨f,rfl⟩ + exact parentLocalJetCLM_smooth_H10 s hs ha hχ hc hχb hχs f + exact (Submodule.topologicalClosure_minimal _ hr ht) u.property + +def parentCompletionJoin : centralEnergySpace s →L[ℝ] H1 := + ((parentLocalJetCLM s hs ha hχ hc).comp (centralEnergySpace s).subtypeL).codRestrict H1Space + (fun u => zeroTraceAmbient_le_H1Space (parentLocalJetCLM_central_H10 s hs ha hχ hc hχb hχs u)) + +lemma parentCompletionJoin_mem_H10 (u : centralEnergySpace s) : + parentCompletionJoin s hs ha hχ hc hχb hχs u∈H10 := + parentLocalJetCLM_central_H10 s hs ha hχ hc hχb hχs u + +end + +open Set MeasureTheory Filter Topology +open scoped ENNReal + +variable {X Y E : Type*} [MeasurableSpace X] [MeasurableSpace Y] + [NormedAddCommGroup E] [NormedSpace ℝ E] + {μ : Measure X} {ν : Measure Y} (e : X ≃ᵐ Y) {c : ℝ≥0∞} + (hc : c≠∞) (hmap : Measure.map e μ≤c • ν) + +def lpBoundedPullbackCLM : Lp E 2 ν →L[ℝ] Lp E 2 μ := + (Lp.compMeasurePreservingₗᵢ ℝ e (show MeasurePreserving e μ (Measure.map e μ) from ⟨e.measurable,rfl⟩)).toContinuousLinearMap.comp + (Lp.LpToLpOfMeasureLeSMul (c:=c) hc hmap) + +lemma lpBoundedPullbackCLM_ae (f : Lp E 2 ν) : + lpBoundedPullbackCLM e hc hmap f=ᵐ[μ] (fun x => f (e x)) := by + apply (Lp.coeFn_compMeasurePreserving _ (show MeasurePreserving e μ (Measure.map e μ) from ⟨e.measurable,rfl⟩)).trans + exact (show MeasurePreserving e μ (Measure.map e μ) from ⟨e.measurable,rfl⟩).quasiMeasurePreserving.ae_eq_comp + (Lp.coeFn_LpToLpOfMeasureLeSMul hc hmap f) + +lemma lpBoundedPullbackCLM_ae_of_ae (hq : Measure.QuasiMeasurePreserving e μ ν) + (f : Lp E 2 ν) {g : Y → E} (hg : f=ᵐ[ν] g) : + lpBoundedPullbackCLM e hc hmap f=ᵐ[μ] (fun x => g (e x)) := + (lpBoundedPullbackCLM_ae e hc hmap f).trans (hq.ae_eq_comp hg) + +lemma sourceChildCoordinates_translate (σ : ℝ) : + sourceChildCoordinates σ=(fun y : Fin 3 → ℝ => y+![σ*sourceOffset,0,0]) ∘ sourceChildDerivative := by + funext y + rw [Function.comp_apply,sourceChildDerivative_apply] + ext i + fin_cases i <;> simp [sourceChildCoordinates] + +lemma sourceChildCoordinates_map_volume (σ : ℝ) : + Measure.map (sourceChildCoordinates σ) volume=ENNReal.ofReal ((sourceScale^3)⁻¹) • volume := by + have hd : sourceChildDerivative.det≠0 := by rw [sourceChildDerivative_det]; norm_num [sourceScale] + rw [sourceChildCoordinates_translate] + rw [←Measure.map_map (g:=fun y : Fin 3 → ℝ => y+![σ*sourceOffset,0,0]) + (f:=sourceChildDerivative) (continuous_id.add continuous_const).measurable sourceChildDerivative.continuous.measurable] + have hm := Measure.map_linearMap_addHaar_eq_smul_addHaar (volume : Measure (Fin 3 → ℝ)) hd + change Measure.map sourceChildDerivative volume=ENNReal.ofReal |sourceChildDerivative.det⁻¹| • volume at hm + rw [hm,Measure.map_smul _ (measurePreserving_add_right volume ![σ*sourceOffset,0,0]).measurable.aemeasurable, + (measurePreserving_add_right volume ![σ*sourceOffset,0,0]).map_eq] + congr 2 + rw [sourceChildDerivative_det,inv_neg,abs_neg,abs_of_nonneg] + exact inv_nonneg.mpr (by norm_num [sourceScale]) + +lemma sourceChildCoordinates_quasi (σ : ℝ) : + Measure.QuasiMeasurePreserving (sourceChildCoordinates σ) volume volume := by + refine ⟨(sourceChildHomeomorph σ).measurable,?_⟩ + rw [sourceChildCoordinates_map_volume] + exact Measure.smul_absolutelyContinuous + +def sourceChildPullbackCLM (σ : ℝ) : Lp E 2 (volume : Measure (Fin 3 → ℝ)) →L[ℝ] + Lp E 2 (volume : Measure (Fin 3 → ℝ)) := + lpBoundedPullbackCLM (sourceChildHomeomorph σ).toMeasurableEquiv ENNReal.ofReal_ne_top + (le_of_eq (sourceChildCoordinates_map_volume σ)) + +lemma sourceChildPullbackCLM_ae (σ : ℝ) (f : Lp E 2 (volume : Measure (Fin 3 → ℝ))) : + sourceChildPullbackCLM σ f=ᵐ[volume] (fun y => f (sourceChildCoordinates σ y)) := + lpBoundedPullbackCLM_ae _ _ _ f + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/ParentFullEndH1.lean b/lean/OAI/Analysis/Conductivity/Sobolev/ParentFullEndH1.lean new file mode 100644 index 0000000000000000000000000000000000000000..1edecee0516b3ecb061b58c13690ec241eee45e5 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/ParentFullEndH1.lean @@ -0,0 +1,203 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalTestEnergy +import OAI.Analysis.Conductivity.Branching.ParentCompletedEndJet +import OAI.Analysis.Conductivity.Branching.ParentEndPartition +import OAI.Analysis.Conductivity.Variational.EndPartitionJet + +namespace OAI + + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem parentFullEnd_H10 (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + {a : ℝ} (ha : a<0) (κ : ℝ) (p : centralEnergySpace s) : + ∃ w : H1,w∈H10 ∧ (∀ᵐ x∂ballMeasure, + WithLp.ofLp x∈sourceClosedCollarBand 0 centralThickness → + weakValue w x=fullAttachedEndValue s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) ∧ + ∀ i,weakGradient w x i= + fullAttachedEndGradient s (centralT s 0 p) a centralThickness κ (WithLp.ofLp x) i) := by + obtain ⟨χ,η,hχ,hχc,hχb,hχs,hη,hηc,hηb,hηs,hpart⟩ := parent_end_partition_exists + generalize hU : parentCompletionJoin s hs ha hχ hχc hχb hχs p = u + have hu : u∈H10 := by + rw [←hU] + exact parentCompletionJoin_mem_H10 s hs ha hχ hχc hχb hχs p + have hue := parentCompletionJoin_end_ae s hs ha hχ hχc hχb hχs p + rw [hU] at hue + obtain ⟨v,hv,hve⟩ := compact_collar_slope_value_gradient hχ hχc hχb ha.ne + (show centralThickness∈Icc (-(1:ℝ)/100) (1/100) by norm_num [centralThickness]) + κ 0 (2*centralThickness) (by norm_num) (by norm_num [centralThickness]) hχs + have hR : 0≤-a*(3*centralThickness/2) := + mul_nonneg (neg_nonneg.mpr ha.le) (by norm_num [centralThickness]) + have hT : ∀ t∈Icc (-centralThickness/2) (3*centralThickness/4), + affineEndTime a centralThickness t∈Icc 0 (-a*(3*centralThickness/2)) := by + intro t ht + dsimp only [affineEndTime] + constructor + · apply mul_nonneg_of_nonpos_of_nonpos ha.le + dsimp [centralThickness] at * + linarith [ht.2] + · have hm := mul_nonpos_of_nonpos_of_nonneg ha.le + (sub_nonneg.mpr ht.1) + nlinarith + have hpos : ∀ t∈Icc (-centralThickness/2) (3*centralThickness/4), + 0 sourceCollarInverse i j y 0) := by + change ∀ᶠ y in 𝓝 (sourceCollarPiece i j x),sourceCollarTime y=sourceCollarInverse i j y 0 + rw [←sourceCollarPiece_map_nhds i j hx,Filter.eventually_map] + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx, + sourceCollarInverse_eventually_left i j hx] with y hy hi + rw [hi,sourceCollarPiece_time_open hy] + +lemma sourceCollarTime_differentiable_open (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) : + DifferentiableAt ℝ sourceCollarTime (sourceCollarPiece i j x) := by + have hd := (sourceCollarInverse_hasStrictFDeriv i j hx).hasFDerivAt.differentiableAt + exact ((differentiableAt_pi.mp hd) 0).congr_of_eventuallyEq + (sourceCollarTime_local_inverse i j hx) + +lemma attachedCartesianMatrix_axial_derivative (a b : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceCollarOpenBox) : + physicalTestCovector (fun y => a*(sourceCollarTime y-b)) (sourceCollarPiece i j x)= + attachedCartesianMatrix a i j x*ᵥPi.single 0 1 := by + let F : (Fin 3 → ℝ) → ℝ := fun y => a*(sourceCollarTime y-b) + have hd : DifferentiableAt ℝ F (sourceCollarPiece i j x) := + ((sourceCollarTime_differentiable_open i j hx).sub_const b).const_mul a + have he : (F ∘ sourceCollarPiece i j)=ᶠ[𝓝 x] (fun y => a*(y 0-b)) := by + filter_upwards [isOpen_sourceCollarOpenBox.mem_nhds hx] with y hy + simp only [Function.comp_apply,F,sourceCollarPiece_time_open hy] + have hf : physicalTestCovector (F ∘ sourceCollarPiece i j) x=Pi.single 0 a := by + ext k + rw [physicalTestCovector,he.fderiv_eq, + (((hasFDerivAt_apply (𝕜:=ℝ) (0:Fin 3) x).sub_const b).const_mul a).fderiv] + fin_cases k <;> simp + have hc := physicalTestCovector_chain F i j x hd + have ht : (sourceCollarJacobian i j x)ᵀ *ᵥ + (attachedCartesianMatrix a i j x*ᵥPi.single 0 1)=Pi.single 0 a := by + rw [attachedCartesianMatrix,←Matrix.mulVec_mulVec, + sourceCartesianGradient_chain i j (sourceCollarOpenBox_subset hx)] + ext k + fin_cases k <;> simp [sourceFaceAngleMatrix,endAxialMatrix,Matrix.mulVec_diagonal] + have hn : IsUnit (sourceCollarJacobian i j x)ᵀ.det := by + rw [Matrix.det_transpose] + exact isUnit_iff_ne_zero.mpr (sourceCollarJacobian_extended_ne_zero i j (sourceCollarOpenBox_subset hx)) + have hh := congrArg (fun v => (sourceCollarJacobian i j x)ᵀ⁻¹*ᵥv) + (hc.symm.trans (hf.trans ht.symm)) + simpa only [Matrix.mulVec_mulVec,←Matrix.mul_assoc,Matrix.nonsing_inv_mul _ hn, + Matrix.one_mulVec,Matrix.one_mul] using hh + +def fullEndFlatCovector (s : Fin 3 → ℝ) (f : spectralTraceGraph (torusRate s)) + (κ : ℝ) (t : ℝ) (θ : (Fin 2 → UnitAddCircle)) : Fin 3 → ℝ := + (fun k => (endPoissonField s f k.succ (t,θ)).re)+κ • Pi.single 0 1 + +lemma fullAttachedEnd_covector (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b κ : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceCollarOpenBox) (ht : 0 (attachedEndPoissonField s f a b 0 y).re) + (sourceCollarPiece i j x) at hp + have hq := ((sourceCollarTime_differentiable_open i j hx).sub_const b).const_mul a + ext k + change fderiv ℝ ((fun y => (attachedEndPoissonField s f a b 0 y).re)+ + (fun y => κ*(a*(sourceCollarTime y-b)))) (sourceCollarPiece i j x) (Pi.single k 1)=_ + rw [(hp.hasFDerivAt.add (hq.hasFDerivAt.const_mul κ)).fderiv] + rfl + +lemma fullAttachedEndGradient_transport (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (a b κ : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceCollarOpenBox) (ht : 0 (attachedEndPoissonField s f a b 0 y).re) + (sourceCollarPiece i j x)=attachedCartesianMatrix a i j x*ᵥ + (fun k : Fin 3 => (endPoissonField s f k.succ + (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re) := by + ext k + simp only [physicalTestCovector,attachedCartesianMatrix_poisson_derivative s hs f a b i j hx ht, + dotProduct_single,mul_one] + change physicalTestCovector (fun y => (attachedEndPoissonField s f a b 0 y).re) + (sourceCollarPiece i j x)+κ • + physicalTestCovector (fun y => a*(sourceCollarTime y-b)) (sourceCollarPiece i j x)=_ + rw [hp,attachedCartesianMatrix_axial_derivative a b i j hx,fullEndFlatCovector, + Matrix.mulVec_add,Matrix.mulVec_smul] + +theorem fullAttachedEnd_test_energy (s : Fin 3 → ℝ) + (hs : ∀ u v : ℝ,(1/2)*(u^2+v^2) ≤ s 0*u^2+2*s 1*u*v+s 2*v^2) + (f : spectralTraceGraph (torusRate s)) (κ : ℝ) (φ : (Fin 3 → ℝ) → ℝ) + {a b : ℝ} (ha : a≠0) (i j : Fin 4) {x : Fin 3 → ℝ} + (hx : x∈sourceCollarOpenBox) (ht : 0 fderiv ℝ q y (Pi.single j 1))) + +lemma localJoinedJet_eq_piSmoothJet {τ χ q p : (Fin 3 → ℝ) → ℝ} {y : Fin 3 → ℝ} + (hτ : τ y ≤ 0) (hχ : DifferentiableAt ℝ χ y) (hq : DifferentiableAt ℝ q y) : + WithLp.toLp 2 (Fin.cases (localJoinedValue τ χ q p y) + (fun i => localJoinedGradient τ χ q p i y))=piSmoothJet (χ*q) y := by + have hn : ¬0<τ y := not_lt_of_ge hτ + ext i + refine Fin.cases ?_ (fun j => ?_) i + · simp [localJoinedValue,piSmoothJet,hn] + · simp only [localJoinedGradient,hn,ite_false,PiLp.toLp_apply,Fin.cases_succ, + piSmoothJet,fderiv_mul hχ hq,add_apply,smul_apply, + smul_eq_mul,Pi.mul_apply] + ring + +lemma sourceChild_piSmoothJet_cancel (q : (Fin 3 → ℝ) → ℝ) + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (σ : ℝ) (y : Fin 3 → ℝ) : + WithLp.toLp 2 (Fin.cases + (piSmoothJet (q ∘ sourceChildCoordinates σ) ((sourceChildHomeomorph σ).symm y) 0) + (fun j => sourceScale⁻¹*piSmoothJet (q ∘ sourceChildCoordinates σ) + ((sourceChildHomeomorph σ).symm y) (childAxis j).succ))=piSmoothJet q y := by + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change q ((sourceChildHomeomorph σ) ((sourceChildHomeomorph σ).symm y))=q y + rw [Homeomorph.apply_symm_apply] + · exact physical_child_partial_cancel hq σ y j + +lemma piSmoothJet_partition {ρ : Fin 4 → (Fin 3 → ℝ) → ℝ} + (hρ : ∀ i,ContDiff ℝ (↑(⊤:ℕ∞)) (ρ i)) {q : (Fin 3 → ℝ) → ℝ} + (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) (y : Fin 3 → ℝ) + (hv : ∑ i : Fin 4,ρ i y=1) + (hg : ∀ j : Fin 3,∑ i : Fin 4,fderiv ℝ (ρ i) y (Pi.single j 1)=0) : + ∑ i : Fin 4,piSmoothJet (ρ i*q) y=piSmoothJet q y := by + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change (∑ i : Fin 4,piSmoothJet (ρ i*q) y) 0=q y + simp only [WithLp.ofLp_sum,Finset.sum_apply,piSmoothJet,Fin.cases_zero,Pi.mul_apply] + rw [←Finset.sum_mul,hv,one_mul] + · change (∑ i : Fin 4,piSmoothJet (ρ i*q) y) j.succ=fderiv ℝ q y (Pi.single j 1) + simp only [WithLp.ofLp_sum,Finset.sum_apply,piSmoothJet,Fin.cases_succ, + fderiv_mul ((hρ _).differentiable (by simp) y) (hq.differentiable (by simp) y), + add_apply,smul_apply,smul_eq_mul, + Finset.sum_add_distrib,←Finset.sum_mul,←Finset.mul_sum,hv,hg,one_mul,mul_zero,add_zero] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevChain.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevChain.lean new file mode 100644 index 0000000000000000000000000000000000000000..7946aea3d8806e2ec32f14f22cf54348522764a3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevChain.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.NonlinearLp + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +variable {g dg : ℝ → ℝ} (hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g) (hdg : Continuous dg) + (hderiv : ∀ r, HasDerivAt g (dg r) r) {C : ℝ} (hC : 0≤C) + (hgb : ∀ r, ‖g r‖≤C*‖r‖) (hdgb : ∀ r, ‖dg r‖≤C) + +def sobolevChainLp : JetSpace → JetSpace := + nonlinearLp ballMeasure (jetSuperposition g dg) + (jetSuperposition_continuous hg.continuous hdg) (jetSuperpositionBound C) + (jetSuperpositionBound_nonneg hC) (jetSuperposition_bound hC hgb hdgb) + +lemma sobolevChainLp_continuous : Continuous (sobolevChainLp hg hdg hC hgb hdgb) := + nonlinearLp_continuous _ _ _ _ _ _ + +lemma sobolevChainLp_coe_ae (z : JetSpace) : + sobolevChainLp hg hdg hC hgb hdgb z =ᵐ[ballMeasure] + fun x => jetSuperposition g dg (z x) := nonlinearLp_coe_ae _ _ _ _ _ _ _ + +include hderiv + +lemma sobolevChainLp_smooth {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hm : MemLp (smoothJet f) 2 ballMeasure) : + ∃ hgm : MemLp (smoothJet (g ∘ f)) 2 ballMeasure, + sobolevChainLp hg hdg hC hgb hdgb (hm.toLp _) = hgm.toLp _ := by + have he : sobolevChainLp hg hdg hC hgb hdgb (hm.toLp _) =ᵐ[ballMeasure] + smoothJet (g ∘ f) := by + filter_upwards [sobolevChainLp_coe_ae hg hdg hC hgb hdgb (hm.toLp _),hm.coeFn_toLp] with x hx hy + rw [hx,hy,←smoothJet_comp hderiv (hf.differentiable (by simp))] + have hgm := MemLp.ae_eq he (Lp.memLp (sobolevChainLp hg hdg hC hgb hdgb (hm.toLp _))) + refine ⟨hgm,?_⟩ + apply Lp.ext + exact he.trans hgm.coeFn_toLp.symm + +lemma sobolevChainLp_preserves_H1 {z : JetSpace} (hz : z∈H1Space) : + sobolevChainLp hg hdg hC hgb hdgb z ∈ H1Space := by + change z ∈ (H1Space : Set JetSpace) at hz + change _ ∈ (H1Space : Set JetSpace) + rw [H1Space_eq_closure] at hz ⊢ + apply nonlinear_closure_preservation (sobolevChainLp_continuous hg hdg hC hgb hdgb) _ hz + rintro w ⟨f,hf,hm,rfl⟩ + obtain ⟨hgm,he⟩ := sobolevChainLp_smooth hg hdg hderiv hC hgb hdgb hf hm + exact ⟨g ∘ f,hg.comp hf,hgm,he⟩ + +lemma sobolevChainLp_preserves_H10 (hg0 : g 0=0) {z : JetSpace} (hz : z∈zeroTraceAmbient) : + sobolevChainLp hg hdg hC hgb hdgb z ∈ zeroTraceAmbient := by + change z ∈ (zeroTraceAmbient : Set JetSpace) at hz + change _ ∈ (zeroTraceAmbient : Set JetSpace) + rw [zeroTraceAmbient_eq_closure] at hz ⊢ + apply nonlinear_closure_preservation (sobolevChainLp_continuous hg hdg hC hgb hdgb) _ hz + rintro w ⟨f,hf,hfc,hfs,hm,rfl⟩ + obtain ⟨hgm,he⟩ := sobolevChainLp_smooth hg hdg hderiv hC hgb hdgb hf hm + refine ⟨g ∘ f,hg.comp hf,hfc.comp_left hg0,?_,hgm,he⟩ + exact (closure_mono (Function.support_comp_subset hg0 f)).trans hfs + +def sobolevChain (u : H1) : H1 := + ⟨sobolevChainLp hg hdg hC hgb hdgb u.val, + sobolevChainLp_preserves_H1 hg hdg hderiv hC hgb hdgb u.property⟩ + +lemma sobolevChain_value (u : H1) : + (fun x => jetValue ((sobolevChain hg hdg hderiv hC hgb hdgb u).val x)) =ᵐ[ballMeasure] + fun x => g (jetValue (u.val x)) := by + filter_upwards [sobolevChainLp_coe_ae hg hdg hC hgb hdgb u.val] with x hx + change jetValue (sobolevChainLp hg hdg hC hgb hdgb u.val x) = _ + rw [hx] + change g (jetValue (u.val x))+0=g (jetValue (u.val x)) + simp + +lemma sobolevChain_gradient (u : H1) : + weakGradient (sobolevChain hg hdg hderiv hC hgb hdgb u) =ᵐ[ballMeasure] + fun x => dg (jetValue (u.val x)) • weakGradient u x := by + filter_upwards [sobolevChainLp_coe_ae hg hdg hC hgb hdgb u.val] with x hx + change jetGradient (sobolevChainLp hg hdg hC hgb hdgb u.val x)=_ + rw [hx] + ext i + change 0+(dg (jetValue (u.val x)) • weakGradient u x) i=_ + simp + +lemma sobolevChain_H10 (hg0 : g 0=0) {u : H1} (hu : u∈H10) : + sobolevChain hg hdg hderiv hC hgb hdgb u∈H10 := + sobolevChainLp_preserves_H10 hg hdg hderiv hC hgb hdgb hg0 hu + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevDistribution.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevDistribution.lean new file mode 100644 index 0000000000000000000000000000000000000000..f34c0bef5eb0b726d2d264439d6b704c12bd2939 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevDistribution.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.SobolevSmoothTests + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma smooth_ball_integration_by_parts {f ψ : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) + (hc : HasCompactSupport ψ) (hs : tsupport ψ⊆ball) (v : R3) : + (∫ x, ψ x*fderiv ℝ f x v ∂ballMeasure)= + -(∫ x, fderiv ℝ ψ x v*f x ∂ballMeasure) := by + have hdf : Continuous (fun x => fderiv ℝ f x v) := + (hf.continuous_fderiv (by simp)).clm_apply continuous_const + have hdψ : Continuous (fun x => fderiv ℝ ψ x v) := + (hψ.continuous_fderiv (by simp)).clm_apply continuous_const + have he := integral_mul_fderiv_eq_neg_fderiv_mul_of_integrable (μ := volume) + (f := ψ) (g := f) (v := v) + ((hdψ.mul hf.continuous).integrable_of_hasCompactSupport (hc.fderiv_apply ℝ v).mul_right) + ((hψ.continuous.mul hdf).integrable_of_hasCompactSupport hc.mul_right) + ((hψ.continuous.mul hf.continuous).integrable_of_hasCompactSupport hc.mul_right) + (fun x _ => hψ.differentiable (by simp) x) + (fun x _ => hf.differentiable (by simp) x) + have hl : (∫ x, ψ x*fderiv ℝ f x v ∂ballMeasure)=∫ x, ψ x*fderiv ℝ f x v := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + rw [image_eq_zero_of_notMem_tsupport (fun hh => hx (hs hh)),zero_mul] + have hr : (∫ x, fderiv ℝ ψ x v*f x ∂ballMeasure)=∫ x, fderiv ℝ ψ x v*f x := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro x hx + rw [fderiv_of_notMem_tsupport ℝ (fun hh => hx (hs hh))] + simp + rw [hl,hr]; exact he + +def weakValueL : H1 →L[ℝ] Lp ℝ 2 ballMeasure := + (jetValue.compLpL 2 ballMeasure).comp H1Space.subtypeL + +lemma weakValueL_apply_ae (u : H1) : + (weakValueL u : R3 → ℝ) =ᵐ[ballMeasure] weakValue u := jetValue.coeFn_compLp u.val + +def weakDirectionL (v : R3) : H1 →L[ℝ] Lp ℝ 2 ballMeasure := + ((innerSL ℝ v).compLpL 2 ballMeasure).comp weakGradientL + +lemma weakDirectionL_apply_ae (u : H1) (v : R3) : + (weakDirectionL v u : R3 → ℝ) =ᵐ[ballMeasure] fun x => inner ℝ v (weakGradient u x) := by + filter_upwards [(innerSL ℝ v).coeFn_compLp (weakGradientL u),weakGradientL_apply_ae u] + with x hx hy + exact hx.trans (congrArg (inner ℝ v) hy) + +lemma weak_integration_by_parts (u : H1) {ψ : R3 → ℝ} + (hψ : ContDiff ℝ (↑(⊤ : ℕ∞)) ψ) (hc : HasCompactSupport ψ) + (hs : tsupport ψ⊆ball) (v : R3) : + inner ℝ (weakValueL (smoothH1 ψ hψ)) (weakDirectionL v u)= + -inner ℝ (weakDirectionL v (smoothH1 ψ hψ)) (weakValueL u) := by + have hd {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + (weakDirectionL v (smoothH1 f hf) : R3 → ℝ) =ᵐ[ballMeasure] + fun x => fderiv ℝ f x v := by + filter_upwards [weakDirectionL_apply_ae (smoothH1 f hf) v,smoothH1_gradient f hf] + with x hx hy + simp only [hx,hy,inner_gradient_right,RCLike.conj_to_real] + have hv {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + (weakValueL (smoothH1 f hf) : R3 → ℝ) =ᵐ[ballMeasure] f := + (weakValueL_apply_ae _).trans (smoothH1_value f hf) + have hsmooth : {z : H1 | z.val∈smoothJets} ⊆ + {z | inner ℝ (weakValueL (smoothH1 ψ hψ)) (weakDirectionL v z)= + -inner ℝ (weakDirectionL v (smoothH1 ψ hψ)) (weakValueL z)} := by + rintro z ⟨f,hf,hm,he⟩ + have hz : z=smoothH1 f hf := Subtype.ext he + change inner ℝ (weakValueL (smoothH1 ψ hψ)) (weakDirectionL v z)= + -inner ℝ (weakDirectionL v (smoothH1 ψ hψ)) (weakValueL z) + rw [hz,L2.inner_def,L2.inner_def] + have hl : (∫ x, inner ℝ (weakValueL (smoothH1 ψ hψ) x) + (weakDirectionL v (smoothH1 f hf) x) ∂ballMeasure)= + ∫ x, ψ x*fderiv ℝ f x v ∂ballMeasure := by + apply integral_congr_ae + filter_upwards [hv hψ,hd hf] with x hx hy + simp only [hx,hy,Real.inner_apply] + have hr : (∫ x, inner ℝ (weakDirectionL v (smoothH1 ψ hψ) x) + (weakValueL (smoothH1 f hf) x) ∂ballMeasure)= + ∫ x, fderiv ℝ ψ x v*f x ∂ballMeasure := by + apply integral_congr_ae + filter_upwards [hd hψ,hv hf] with x hx hy + simp only [hx,hy,Real.inner_apply] + rw [hl,hr] + exact smooth_ball_integration_by_parts hf hψ hc hs v + + exact (closure_minimal hsmooth (isClosed_eq + (continuous_const.inner (weakDirectionL v).continuous) + ((continuous_const.inner weakValueL.continuous).neg))) (smoothH1_dense u) + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma weakDirection_zero_of_value_zero (u : H1) + (hu : weakValue u =ᵐ[ballMeasure] 0) (v : R3) : weakDirectionL v u=0 := by + have huv : weakValueL u=0 := Lp.ext (((weakValueL_apply_ae u).trans hu).trans (Lp.coeFn_zero ℝ 2 ballMeasure).symm) + have hi : Integrable (weakDirectionL v u : R3 → ℝ) ballMeasure := + (Lp.memLp _).integrable (by norm_num) + have hz := (Metric.isOpen_ball : IsOpen ball).ae_eq_zero_of_integral_contDiff_smul_eq_zero + (hi.locallyIntegrable.locallyIntegrableOn ball) (fun ψ hψ hc hs => ?_) + · apply Lp.ext + filter_upwards [hz,ae_restrict_mem (Metric.isOpen_ball.measurableSet : MeasurableSet ball), + Lp.coeFn_zero ℝ 2 ballMeasure] with x hx hb hzero + exact (hx hb).trans hzero.symm + · have h := weak_integration_by_parts u hψ hc hs v + rw [huv,inner_zero_right,neg_zero,L2.inner_def] at h + rw [←h] + apply integral_congr_ae + filter_upwards [(weakValueL_apply_ae _).trans (smoothH1_value ψ hψ)] with x hx + simp only [hx,Real.inner_apply,smul_eq_mul] + +lemma h1_eq_zero_of_value_zero (u : H1) (hu : weakValue u =ᵐ[ballMeasure] 0) : u=0 := by + have hg (i : Fin 3) : ∀ᵐ x ∂ballMeasure, weakGradient u x i=0 := by + have he := weakDirection_zero_of_value_zero u hu (EuclideanSpace.single i 1) + filter_upwards [weakDirectionL_apply_ae u (EuclideanSpace.single i 1), + ((Lp.ext_iff.mp he).trans (Lp.coeFn_zero ℝ 2 ballMeasure))] with x hx hy + have hh : inner ℝ (EuclideanSpace.single i 1) (weakGradient u x)=0 := hx.symm.trans hy + simpa only [EuclideanSpace.inner_single_left,RCLike.conj_to_real,one_mul] using hh + apply Subtype.ext + apply Lp.ext + filter_upwards [hu,ae_all_iff.mpr hg,Lp.coeFn_zero JetFiber 2 ballMeasure] with x hx hy hzero + change weakValue u x=0 at hx + change (0 : JetSpace) x=0 at hzero + have hwg : weakGradient u x=0 := by ext i; exact hy i + calc + u.val x = jetLiftValue (jetValue (u.val x)) + jetLiftGradient (jetGradient (u.val x)) := + jetFiber_decomposition _ + _ = 0 := by change jetLiftValue (weakValue u x)+jetLiftGradient (weakGradient u x)=0 + rw [hx,hwg,map_zero,map_zero,add_zero] + _ = (0 : JetSpace) x := hzero.symm + +lemma weakValueL_injective : Function.Injective weakValueL := by + intro u v huv + have he : weakValueL (u-v)=0 := by rw [map_sub,huv,sub_self] + have hz : weakValue (u-v) =ᵐ[ballMeasure] 0 := + (weakValueL_apply_ae _).symm.trans ((Lp.ext_iff.mp he).trans (Lp.coeFn_zero ℝ 2 ballMeasure)) + exact sub_eq_zero.mp (h1_eq_zero_of_value_zero _ hz) + +lemma nonzero_h1_positive_value_measure {u : H1} (hu : u≠0) : + 0 a x*inner ℝ (weakGradient u x) (weakGradient v x)) ballMeasure := by + apply (L2.integrable_inner (boundedMultiplier ballMeasure a ha C hC hb (weakGradientL u)) + (weakGradientL v)).congr + filter_upwards [boundedMultiplier_apply_ae ballMeasure a ha C hC hb (weakGradientL u), + weakGradientL_apply_ae u,weakGradientL_apply_ae v] with x hx hy hz + rw [hx,hy,hz,real_inner_smul_left] + +lemma zero_of_weakGradient_zero {u : H1} (hu : u∈H10) + (hg : weakGradient u =ᵐ[ballMeasure] 0) : u=0 := by + have he : weakGradientL u=0 := by + apply Lp.ext + filter_upwards [weakGradientL_apply_ae u,hg,Lp.coeFn_zero R3 2 ballMeasure] with x hx hy hz + rw [hx,hy,hz] + have hn := H10_norm_le_weakGradientL (⟨u,hu⟩ : H10) + rw [he,norm_zero,mul_zero] at hn + exact norm_eq_zero.mp (le_antisymm hn (norm_nonneg u)) + +lemma chain_zero (F : SmoothLipZero) {v : H1} + (hv : ∀ᵐ x ∂ballMeasure, F (weakValue v x)=0) + (hd : ∀ᵐ x ∂ballMeasure, deriv F (weakValue v x)=0) : F.onH1 v=0 := by + apply Subtype.ext + apply Lp.ext + filter_upwards [F.onLp_ae v.val,hv,hd,Lp.coeFn_zero JetFiber 2 ballMeasure] with x hx hy hd hz + change F.onLp v.val x=(0:JetSpace) x + rw [hx,hz] + unfold jetSuperposition + rw [hy,hd,zero_smul,map_zero,map_zero,add_zero] + rfl + +def upperTransitionFun (M r : ℝ) : ℝ := smoothTransition (r-M) + +lemma upperTransitionFun_smooth (M : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (upperTransitionFun M) := + smoothTransition.contDiff.comp (contDiff_id.sub contDiff_const) + +lemma upperTransitionFun_deriv (M r : ℝ) : + deriv (upperTransitionFun M) r=deriv smoothTransition (r-M) := by + change deriv (fun s => smoothTransition (s-M)) r=_ + have hs : ContDiff ℝ (1:ℕ) smoothTransition := smoothTransition.contDiff + simpa only [mul_one,upperTransitionFun,Function.comp_def,id_eq] using (((hs.differentiable (by simp) (r-M)).hasDerivAt).comp r + ((hasDerivAt_id r).sub_const M)).deriv + +def upperTransition (M : ℝ) (hM : 0≤M) : SmoothLipZero := by + let C := Classical.choose exists_transition_derivative_bound + have hc := Classical.choose_spec exists_transition_derivative_bound + refine ⟨upperTransitionFun M,upperTransitionFun_smooth M,?_,C,by linarith [hc.1],?_⟩ + · exact smoothTransition.zero_of_nonpos (by linarith) + · intro r + rw [upperTransitionFun_deriv,Real.norm_eq_abs] + exact (hc.2 (r-M)).1 + +lemma upperTransition_nonneg (M : ℝ) (hM : 0≤M) (r : ℝ) : 0≤upperTransition M hM r := + smoothTransition.nonneg _ + +lemma upperTransition_zero_iff (M : ℝ) (hM : 0≤M) (r : ℝ) : + upperTransition M hM r=0 ↔ r≤M := by + change smoothTransition (r-M)=0 ↔ r≤M + rw [smoothTransition.zero_iff_nonpos,sub_nonpos] + +lemma upperTransition_deriv_nonneg (M : ℝ) (hM : 0≤M) (r : ℝ) : + 0≤deriv (upperTransition M hM) r := by + apply Monotone.deriv_nonneg + intro x y hxy + exact smoothTransition.monotone (sub_le_sub_right hxy M) + +lemma upperTransition_deriv_zero {M r : ℝ} (hM : 0≤M) (hr : r≤M) : + deriv (upperTransition M hM) r=0 := by + apply IsLocalMin.deriv_eq_zero + apply Filter.Eventually.of_forall + intro s + rw [(upperTransition_zero_iff M hM r).mpr hr] + exact upperTransition_nonneg M hM s + +theorem harmonic_le_of_trace_le (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0≤C) (hb : ∀ᵐ x ∂ballMeasure, |a x|≤C) + (hp : ∀ᵐ x ∂ballMeasure, 0 a x*inner ℝ (weakGradient u x) (weakGradient (F.onH1 u) x) := by + filter_upwards [hp,hg] with x ha hx + rw [hx,real_inner_smul_right] + exact mul_nonneg ha.le (mul_nonneg (upperTransition_deriv_nonneg M hM _) real_inner_self_nonneg) + have hzero := (integral_eq_zero_iff_of_nonneg_ae hnonneg + (energy_integrable a ha C hC hb u (F.onH1 u))).mp he + have hhg : weakGradient (F.onH1 u) =ᵐ[ballMeasure] 0 := by + filter_upwards [hp,hg,hzero] with x ha hx hz + rw [hx,real_inner_smul_right] at hz + have hh : deriv F (weakValue u x)*inner ℝ (weakGradient u x) (weakGradient u x)=0 := + (mul_eq_zero.mp hz).resolve_left ha.ne' + rcases mul_eq_zero.mp hh with hd | hd + · rw [hx,hd,zero_smul]; rfl + · rw [hx,inner_self_eq_zero.mp hd,smul_zero]; rfl + have hF0 := zero_of_weakGradient_zero hh0 hhg + have hval := F.onH1_value u + filter_upwards [hval,Lp.coeFn_zero JetFiber 2 ballMeasure] with x hx hz + apply (upperTransition_zero_iff M hM _).mp + rw [←hx,hF0] + change jetValue ((0:JetSpace) x)=0 + rw [hz]; rfl + +lemma harmonic_neg (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0≤C) (hb : ∀ᵐ x ∂ballMeasure, |a x|≤C) + {u : H1} (hu : Harmonic a u) : Harmonic a (-u) := by + intro h hh + rw [←energyForm_apply a ha C hC hb,map_neg,neg_apply, + energyForm_apply a ha C hC hb,hu h hh,neg_zero] + +lemma weakValue_neg (u : H1) : weakValue (-u) =ᵐ[ballMeasure] -weakValue u := by + filter_upwards [Lp.coeFn_neg u.val] with point hneg + change jetValue ((-u.val) point) = -jetValue (u.val point) + rw [hneg,Pi.neg_apply,map_neg] + +theorem harmonic_bounded_of_trace_bounded (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0≤C) (hb : ∀ᵐ x ∂ballMeasure, |a x|≤C) + (hp : ∀ᵐ x ∂ballMeasure, 0 (abs_le.mp hx).2)) + have hvneg : ∀ᵐ x ∂ballMeasure, weakValue (-v) x≤M := by + filter_upwards [hv,weakValue_neg v] with x hx hy + rw [hy]; exact (neg_le_iff_add_nonneg).mpr (by linarith [(abs_le.mp hx).1]) + have htneg : trace (-u)=trace (-v) := by + change H10.mkQ (-u)=H10.mkQ (-v) + simpa only [map_neg,trace] using congrArg Neg.neg ht + have hlo := harmonic_le_of_trace_le a ha C hC hb hp + (harmonic_neg a ha C hC hb hu) htneg hM hvneg + filter_upwards [hup,hlo,weakValue_neg u] with x hx hy hz + apply abs_le.mpr + rw [hz,Pi.neg_apply] at hy + exact ⟨by linarith,hx⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevOuterTests.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevOuterTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..fe59167493d62d392a7b55d1a7b75f351b5241a7 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevOuterTests.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.SobolevSmoothTests + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +theorem exists_outer_test {g : H1} {M : ℝ} + (hg : ∀ᵐ x ∂ballMeasure, |weakValue g x|≤M) + {r : ℝ} (hr : 0 hsm hu hz) (isClosed_eq + ((Λ₀ (trace u)).continuous.comp H10.continuous_mkQ) + ((Λ₁ (trace u)).continuous.comp H10.continuous_mkQ))) (smoothH1_dense v) + have hall (u v : H1) : Λ₀ (trace u) (trace v)=Λ₁ (trace u) (trace v) := by + apply (closure_minimal (fun z hz => hfirst z hz v) (isClosed_eq + ((ContinuousLinearMap.apply ℝ ℝ (trace v)).continuous.comp (Λ₀.continuous.comp H10.continuous_mkQ)) + ((ContinuousLinearMap.apply ℝ ℝ (trace v)).continuous.comp (Λ₁.continuous.comp H10.continuous_mkQ)))) (smoothH1_dense u) + ext f g + obtain ⟨u,rfl⟩ := H10.mkQ_surjective f + obtain ⟨v,rfl⟩ := H10.mkQ_surjective g + exact hall u v + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothOperations.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothOperations.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d2a6799fe896cfcc6d13ee5a097662b1e836c91 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothOperations.lean @@ -0,0 +1,296 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.SobolevChain +import OAI.Analysis.Conductivity.Variational.CrossingProfiles + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Real + +structure SmoothLipZero where + toFun : ℝ → ℝ + smooth : ContDiff ℝ (↑(⊤ : ℕ∞)) toFun + at_zero : toFun 0=0 + bound : ℝ + bound_nonneg : 0≤bound + deriv_bound : ∀ r, ‖deriv toFun r‖≤bound + +instance : CoeFun SmoothLipZero (fun _ => ℝ → ℝ) := ⟨SmoothLipZero.toFun⟩ + +namespace SmoothLipZero + +lemma growth (F : SmoothLipZero) (r : ℝ) : ‖F r‖≤F.bound*‖r‖ := by + have hh := (convex_univ : Convex ℝ (univ : Set ℝ)).norm_image_sub_le_of_norm_deriv_le + (fun x _ => F.smooth.differentiable (by simp) x) (fun x _ => F.deriv_bound x) + (mem_univ (0:ℝ)) (mem_univ r) + simpa [F.at_zero] using hh + +lemma derivative (F : SmoothLipZero) (r : ℝ) : HasDerivAt F (deriv F r) r := + (F.smooth.differentiable (by simp) r).hasDerivAt + +def onLp (F : SmoothLipZero) : JetSpace → JetSpace := + sobolevChainLp F.smooth (smooth_deriv_infty F.smooth).continuous F.bound_nonneg F.growth F.deriv_bound + +lemma onLp_continuous (F : SmoothLipZero) : Continuous F.onLp := + sobolevChainLp_continuous _ _ _ _ _ + +lemma onLp_ae (F : SmoothLipZero) (z : JetSpace) : + F.onLp z =ᵐ[ballMeasure] fun x => jetSuperposition F (deriv F) (z x) := + sobolevChainLp_coe_ae _ _ _ _ _ _ + +lemma preserves_H1 (F : SmoothLipZero) {z : JetSpace} (hz : z∈H1Space) : + F.onLp z∈H1Space := + sobolevChainLp_preserves_H1 _ _ F.derivative _ _ _ hz + +lemma preserves_H10 (F : SmoothLipZero) {z : JetSpace} (hz : z∈zeroTraceAmbient) : + F.onLp z∈zeroTraceAmbient := + sobolevChainLp_preserves_H10 _ _ F.derivative _ _ _ F.at_zero hz + +def onH1 (F : SmoothLipZero) (u : H1) : H1 := ⟨F.onLp u.val,F.preserves_H1 u.property⟩ + +lemma onH1_continuous (F : SmoothLipZero) : Continuous F.onH1 := + (F.onLp_continuous.comp continuous_subtype_val).subtype_mk _ + +lemma onH1_value (F : SmoothLipZero) (u : H1) : + (fun x => jetValue ((F.onH1 u).val x)) =ᵐ[ballMeasure] fun x => F (jetValue (u.val x)) := + sobolevChain_value _ _ F.derivative _ _ _ _ + +lemma onH1_gradient (F : SmoothLipZero) (u : H1) : + weakGradient (F.onH1 u) =ᵐ[ballMeasure] fun x => deriv F (jetValue (u.val x)) • weakGradient u x := + sobolevChain_gradient _ _ F.derivative _ _ _ _ + +lemma fixes_of_eq (F : SmoothLipZero) {u : H1} + (hv : ∀ᵐ x ∂ballMeasure, F (jetValue (u.val x))=jetValue (u.val x)) + (hd : ∀ᵐ x ∂ballMeasure, deriv F (jetValue (u.val x))=1) : F.onH1 u=u := by + apply Subtype.ext + apply Lp.ext + filter_upwards [F.onLp_ae u.val,hv,hd] with x hx hv hd + change F.onLp u.val x=u.val x + rw [hx] + unfold jetSuperposition + rw [hv,hd,one_smul,←jetFiber_decomposition] + +def ofCompact (g : ℝ → ℝ) (hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g) + (hc : HasCompactSupport g) (hg0 : g 0=0) : SmoothLipZero := by + let he := hc.deriv.exists_bound_of_continuous (smooth_deriv_infty hg).continuous + let C := Classical.choose he + have hC : ∀ r, ‖deriv g r‖ ≤ C := Classical.choose_spec he + exact ⟨g,hg,hg0,max 0 C,le_max_left _ _,fun r => (hC r).trans (le_max_right _ _)⟩ + +lemma ofCompact_apply (g : ℝ → ℝ) (hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g) + (hc : HasCompactSupport g) (hg0 : g 0=0) (r : ℝ) : + ofCompact g hg hc hg0 r=g r := by + rfl + +end SmoothLipZero + +def valueBump (M : ℝ) : ContDiffBump (0:ℝ) := + ⟨|M|+1,|M|+2,by positivity,by linarith⟩ + +def clippedValue (M r : ℝ) : ℝ := valueBump M r*r + +lemma clippedValue_smooth (M : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (clippedValue M) := + (valueBump M).contDiff.mul contDiff_id + +lemma clippedValue_compact (M : ℝ) : HasCompactSupport (clippedValue M) := + (valueBump M).hasCompactSupport.mul_right + +lemma clippedValue_zero (M : ℝ) : clippedValue M 0=0 := by simp [clippedValue] + +lemma clippedValue_eventually {M r : ℝ} (hr : |r|≤M) : clippedValue M =ᶠ[𝓝 r] id := by + have hb : r ∈ Metric.ball 0 (valueBump M).rIn := by + change dist r 0 < |M|+1 + rw [dist_zero_right,Real.norm_eq_abs] + linarith [le_abs_self M] + filter_upwards [(valueBump M).eventuallyEq_one_of_mem_ball hb] with s hs + simp only [clippedValue,hs,Pi.one_apply,one_mul,id_eq] + +lemma clippedValue_eq {M r : ℝ} (hr : |r|≤M) : clippedValue M r=r := + (clippedValue_eventually hr).eq_of_nhds + +lemma clippedValue_deriv {M r : ℝ} (hr : |r|≤M) : deriv (clippedValue M) r=1 := by + rw [(clippedValue_eventually hr).deriv_eq] + exact deriv_id r + +lemma exists_clippedValue_bound (M : ℝ) : ∃ C : ℝ, 0 ?_⟩ + exact (show |clippedValue M r|≤C from hC r).trans (le_max_right _ _) + +def squaredValue (M r : ℝ) : ℝ := valueBump M r * r^2 + +lemma squaredValue_smooth (M : ℝ) : ContDiff ℝ (↑(⊤ : ℕ∞)) (squaredValue M) := + (valueBump M).contDiff.mul (contDiff_id.pow 2) + +lemma squaredValue_compact (M : ℝ) : HasCompactSupport (squaredValue M) := + (valueBump M).hasCompactSupport.mul_right + +lemma squaredValue_zero (M : ℝ) : squaredValue M 0=0 := by simp [squaredValue] + +lemma squaredValue_eventually {M r : ℝ} (hr : |r|≤M) : + squaredValue M =ᶠ[𝓝 r] fun s => s^2 := by + have hb : r ∈ Metric.ball 0 (valueBump M).rIn := by + change dist r 0 < |M|+1 + rw [dist_zero_right,Real.norm_eq_abs] + linarith [le_abs_self M] + filter_upwards [(valueBump M).eventuallyEq_one_of_mem_ball hb] with s hs + simp only [squaredValue,hs,Pi.one_apply,one_mul] + +lemma squaredValue_eq {M r : ℝ} (hr : |r|≤M) : squaredValue M r=r^2 := + (squaredValue_eventually hr).eq_of_nhds + +lemma squaredValue_deriv {M r : ℝ} (hr : |r|≤M) : deriv (squaredValue M) r=2*r := by + rw [(squaredValue_eventually hr).deriv_eq] + simp + +def squareOperation (M : ℝ) : SmoothLipZero := + SmoothLipZero.ofCompact (squaredValue M) (squaredValue_smooth M) + (squaredValue_compact M) (squaredValue_zero M) + +def clipOperation (M : ℝ) : SmoothLipZero := + SmoothLipZero.ofCompact (clippedValue M) (clippedValue_smooth M) + (clippedValue_compact M) (clippedValue_zero M) + +lemma jet_squareOperation {M : ℝ} {z : JetFiber} (hz : |jetValue z|≤M) : + jetSuperposition (squareOperation M) (deriv (squareOperation M)) z = + jetLiftValue (jetValue z ^ 2) + jetLiftGradient ((2*jetValue z) • jetGradient z) := by + change jetLiftValue (squaredValue M (jetValue z)) + + jetLiftGradient (deriv (squaredValue M) (jetValue z) • jetGradient z)=_ + rw [squaredValue_eq hz,squaredValue_deriv hz] + +def jetProduct (z w : JetFiber) : JetFiber := + jetLiftValue (jetValue z*jetValue w) + + jetLiftGradient (jetValue z • jetGradient w + jetValue w • jetGradient z) + +lemma gradient_product {f g : R3 → ℝ} (hf : Differentiable ℝ f) + (hg : Differentiable ℝ g) (x : R3) : + gradient (f*g) x = f x • gradient g x + g x • gradient f x := by + unfold gradient + rw [fderiv_mul (hf x) (hg x)] + simp + +lemma smoothJet_product {f g : R3 → ℝ} (hf : Differentiable ℝ f) + (hg : Differentiable ℝ g) (x : R3) : + smoothJet (f*g) x=jetProduct (smoothJet f x) (smoothJet g x) := by + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change f x*g x=f x*g x+0; simp + · change gradient (f*g) x j=0+(f x • gradient g x+g x • gradient f x) j + rw [gradient_product hf hg]; simp + +lemma square_polarization {A B : ℝ} (hA : 0≤A) (hB : 0≤B) + {z w : JetFiber} (hz : |jetValue z|≤A) (hw : |jetValue w|≤B) : + (1/2:ℝ) • (jetSuperposition (squareOperation (A+B)) (deriv (squareOperation (A+B))) (z+w) - + jetSuperposition (squareOperation (A+B)) (deriv (squareOperation (A+B))) z - + jetSuperposition (squareOperation (A+B)) (deriv (squareOperation (A+B))) w) = + jetProduct z w := by + have hzw : |jetValue (z+w)|≤A+B := by + rw [map_add]; exact (abs_add_le _ _).trans (add_le_add hz hw) + rw [jet_squareOperation hzw,jet_squareOperation (hz.trans (le_add_of_nonneg_right hB)), + jet_squareOperation (hw.trans (le_add_of_nonneg_left hA))] + ext i + refine Fin.cases ?_ (fun j => ?_) i + · change (1/2:ℝ)*(((jetValue z+jetValue w)^2+0)-(jetValue z^2+0)-(jetValue w^2+0))= + jetValue z*jetValue w+0 + ring + · change (1/2:ℝ)*((0+(2*(jetValue z+jetValue w))*((jetGradient z) j+(jetGradient w) j))- + (0+(2*jetValue z)*(jetGradient z) j)-(0+(2*jetValue w)*(jetGradient w) j))= + 0+((jetValue z)*(jetGradient w) j+(jetValue w)*(jetGradient z) j) + ring + +variable (F G : SmoothLipZero) (A B : ℝ) + +def clippedProductLp (z w : JetSpace) : JetSpace := + (1/2:ℝ) • ((squareOperation (A+B)).onLp (F.onLp z+G.onLp w) - + (squareOperation (A+B)).onLp (F.onLp z) - + (squareOperation (A+B)).onLp (G.onLp w)) + +lemma clippedProductLp_continuous : Continuous (fun p : JetSpace × JetSpace => + clippedProductLp F G A B p.1 p.2) := by + exact (((squareOperation (A+B)).onLp_continuous.comp + ((F.onLp_continuous.comp continuous_fst).add (G.onLp_continuous.comp continuous_snd))).sub + ((squareOperation (A+B)).onLp_continuous.comp (F.onLp_continuous.comp continuous_fst)) |>.sub + ((squareOperation (A+B)).onLp_continuous.comp (G.onLp_continuous.comp continuous_snd))).const_smul (1/2:ℝ) + +lemma clippedProductLp_preserves_H1 {z w : JetSpace} (hz : z∈H1Space) (hw : w∈H1Space) : + clippedProductLp F G A B z w∈H1Space := by + apply H1Space.smul_mem + apply H1Space.sub_mem + · apply H1Space.sub_mem + · exact (squareOperation (A+B)).preserves_H1 + (H1Space.add_mem (F.preserves_H1 hz) (G.preserves_H1 hw)) + · exact (squareOperation (A+B)).preserves_H1 (F.preserves_H1 hz) + · exact (squareOperation (A+B)).preserves_H1 (G.preserves_H1 hw) + +variable (hA : 0≤A) (hB : 0≤B) (hF : ∀ r, |F r|≤A) (hG : ∀ r, |G r|≤B) +include hA hB hF hG + +lemma clippedProductLp_ae (z w : JetSpace) : + clippedProductLp F G A B z w =ᵐ[ballMeasure] fun x => + jetProduct (jetSuperposition F (deriv F) (z x)) (jetSuperposition G (deriv G) (w x)) := by + let S := squareOperation (A+B) + filter_upwards [Lp.coeFn_smul (1/2:ℝ) (S.onLp (F.onLp z+G.onLp w)-S.onLp (F.onLp z)-S.onLp (G.onLp w)), + Lp.coeFn_sub (S.onLp (F.onLp z+G.onLp w)-S.onLp (F.onLp z)) (S.onLp (G.onLp w)), + Lp.coeFn_sub (S.onLp (F.onLp z+G.onLp w)) (S.onLp (F.onLp z)), + S.onLp_ae (F.onLp z+G.onLp w),S.onLp_ae (F.onLp z),S.onLp_ae (G.onLp w), + Lp.coeFn_add (F.onLp z) (G.onLp w),F.onLp_ae z,G.onLp_ae w] with x hs hsub hsub' hsum h1 h2 ha hf hg + change ((1/2:ℝ) • (S.onLp (F.onLp z+G.onLp w)-S.onLp (F.onLp z)-S.onLp (G.onLp w))) x=_ + rw [hs,Pi.smul_apply,hsub,Pi.sub_apply,hsub',Pi.sub_apply,hsum,h1,h2,ha,Pi.add_apply,hf,hg] + apply square_polarization hA hB + · change |F (jetValue (z x))+0|≤A; simpa using hF (jetValue (z x)) + · change |G (jetValue (w x))+0|≤B; simpa using hG (jetValue (w x)) + +lemma clippedProductLp_smooth {f g : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g) + (hfm : MemLp (smoothJet f) 2 ballMeasure) (hgm : MemLp (smoothJet g) 2 ballMeasure) : + ∃ hm : MemLp (smoothJet ((F ∘ f)*(G ∘ g))) 2 ballMeasure, + clippedProductLp F G A B (hfm.toLp _) (hgm.toLp _) = hm.toLp _ := by + have he : clippedProductLp F G A B (hfm.toLp _) (hgm.toLp _) =ᵐ[ballMeasure] + smoothJet ((F ∘ f)*(G ∘ g)) := by + filter_upwards [clippedProductLp_ae F G A B hA hB hF hG (hfm.toLp _) (hgm.toLp _), + hfm.coeFn_toLp,hgm.coeFn_toLp] with x hx hy hz + rw [hx,hy,hz,←smoothJet_comp F.derivative (hf.differentiable (by simp)), + ←smoothJet_comp G.derivative (hg.differentiable (by simp)), + ←smoothJet_product ((F.smooth.comp hf).differentiable (by simp)) + ((G.smooth.comp hg).differentiable (by simp))] + have hm := MemLp.ae_eq he (Lp.memLp (clippedProductLp F G A B (hfm.toLp _) (hgm.toLp _))) + exact ⟨hm,Lp.ext (he.trans hm.coeFn_toLp.symm)⟩ + +lemma clippedProductLp_smooth_compact {z w : JetSpace} (hz : z∈smoothJets) (hw : w∈compactSmoothJets) : + clippedProductLp F G A B z w∈compactSmoothJets := by + obtain ⟨f,hf,hfm,rfl⟩ := hz + obtain ⟨g,hg,hgc,hgs,hgm,rfl⟩ := hw + obtain ⟨hm,he⟩ := clippedProductLp_smooth F G A B hA hB hF hG hf hg hfm hgm + refine ⟨(F ∘ f)*(G ∘ g),(F.smooth.comp hf).mul (G.smooth.comp hg), + (hgc.comp_left G.at_zero).mul_left,?_,hm,he⟩ + exact (closure_mono (Function.support_mul_subset_right _ _)).trans + ((closure_mono (Function.support_comp_subset G.at_zero g)).trans hgs) + +lemma clippedProductLp_preserves_H10 {z w : JetSpace} (hz : z∈H1Space) (hw : w∈zeroTraceAmbient) : + clippedProductLp F G A B z w∈zeroTraceAmbient := by + have hc := clippedProductLp_continuous F G A B + have hb {z : JetSpace} (hz : z∈smoothJets) {w : JetSpace} (hw : w∈closure compactSmoothJets) : + clippedProductLp F G A B z w∈closure compactSmoothJets := by + apply (image_closure_subset_closure_image (hc.comp (continuous_const.prodMk continuous_id))).trans + (closure_mono (show (fun w => clippedProductLp F G A B z w) '' compactSmoothJets ⊆ compactSmoothJets from ?_)) + ⟨w,hw,rfl⟩ + rintro _ ⟨w,hw,rfl⟩ + exact clippedProductLp_smooth_compact F G A B hA hB hF hG hz hw + change z∈(H1Space : Set JetSpace) at hz + change w∈(zeroTraceAmbient : Set JetSpace) at hw + change _∈(zeroTraceAmbient : Set JetSpace) + rw [H1Space_eq_closure] at hz + rw [zeroTraceAmbient_eq_closure] at hw ⊢ + have ht : (fun z => clippedProductLp F G A B z w) '' smoothJets ⊆ closure compactSmoothJets := by + rintro _ ⟨z,hz,rfl⟩; exact hb hz hw + have hh := (image_closure_subset_closure_image (hc.comp (continuous_id.prodMk continuous_const))).trans + (closure_mono ht) + simpa only [closure_closure,Function.comp_apply,id_eq] using hh ⟨z,hz,rfl⟩ + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothTests.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothTests.lean new file mode 100644 index 0000000000000000000000000000000000000000..5474e384927100d2e1f80822fa42e5e823b37105 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevSmoothTests.lean @@ -0,0 +1,196 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.SobolevTraceChain + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +open Set MeasureTheory Filter Topology + +lemma continuous_gradient_of_smooth {f : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : Continuous (gradient f) := by + unfold gradient + exact (InnerProductSpace.toDual ℝ R3).symm.continuous.comp + (hf.continuous_fderiv (by simp)) + +lemma smoothJet_continuous {f : R3 → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : Continuous (smoothJet f) := by + have he : smoothJet f = fun x => jetLiftValue (f x)+jetLiftGradient (gradient f x) := by + ext x i + refine Fin.cases ?_ (fun j => ?_) i <;> simp [smoothJet,jetLiftValue,jetLiftGradient] + rw [he] + exact (jetLiftValue.continuous.comp hf.continuous).add + (jetLiftGradient.continuous.comp (continuous_gradient_of_smooth hf)) + +lemma continuous_bound_ball {E : Type*} [NormedAddCommGroup E] {f : R3 → E} + (hf : Continuous f) : ∃ M : ℝ, 0≤M ∧ ∀ᵐ x ∂ballMeasure, ‖f x‖≤M := by + obtain ⟨M,hM⟩ := (isCompact_closedBall (0:R3) 3).exists_bound_of_continuousOn hf.continuousOn + refine ⟨max M 0,le_max_right _ _,?_⟩ + filter_upwards [ae_restrict_mem (s := ball) measurableSet_ball] with x hx + exact (hM x (Metric.ball_subset_closedBall hx)).trans (le_max_left _ _) + +lemma smoothJet_memLp {f : R3 → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + MemLp (smoothJet f) 2 ballMeasure := by + obtain ⟨M,_,hM⟩ := continuous_bound_ball (smoothJet_continuous hf) + exact MemLp.of_bound (smoothJet_continuous hf).aestronglyMeasurable M hM + +def smoothH1 (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : H1 := + ⟨(smoothJet_memLp hf).toLp _, (Submodule.le_topologicalClosure _) + (Submodule.subset_span ⟨f,hf,smoothJet_memLp hf,rfl⟩)⟩ + +lemma smoothH1_value (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + weakValue (smoothH1 f hf) =ᵐ[ballMeasure] f := by + filter_upwards [(smoothJet_memLp hf).coeFn_toLp] with x hx + exact congrArg jetValue hx + +lemma smoothH1_gradient (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + weakGradient (smoothH1 f hf) =ᵐ[ballMeasure] gradient f := by + filter_upwards [(smoothJet_memLp hf).coeFn_toLp] with x hx + exact congrArg jetGradient hx + +lemma smoothH1_bounded (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + ∃ M : ℝ, 0≤M ∧ ∀ᵐ x ∂ballMeasure, |weakValue (smoothH1 f hf) x|≤M := by + obtain ⟨M,hM,hb⟩ := continuous_bound_ball hf.continuous + refine ⟨M,hM,?_⟩ + filter_upwards [hb,smoothH1_value f hf] with x hx hy + simpa only [hy,Real.norm_eq_abs] using hx + +lemma smoothH1_mem_H10 (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) + (hc : HasCompactSupport f) (hs : tsupport f⊆ball) : smoothH1 f hf∈H10 := + (Submodule.le_topologicalClosure _) (Submodule.subset_span + ⟨f,hf,hc,hs,smoothJet_memLp hf,rfl⟩) + +lemma smoothH1_dense : Dense {u : H1 | u.val∈smoothJets} := by + intro u + rw [closure_subtype] + have he : Subtype.val '' {u : H1 | u.val∈smoothJets}=smoothJets := by + apply Set.ext; intro z; constructor + · rintro ⟨u,hu,rfl⟩; exact hu + · intro hz + exact ⟨⟨z,(Submodule.le_topologicalClosure _) (Submodule.subset_span hz)⟩,hz,rfl⟩ + rw [he,←H1Space_eq_closure] + exact u.property + +lemma compactH1_dense_H10 {u : H1} (hu : u∈H10) : + u∈closure {v : H1 | v.val∈compactSmoothJets} := by + rw [closure_subtype] + have he : Subtype.val '' {v : H1 | v.val∈compactSmoothJets}=compactSmoothJets := by + apply Set.ext; intro z; constructor + · rintro ⟨v,hv,rfl⟩; exact hv + · intro hz + rcases hz with ⟨f,hf,hc,hs,hm,rfl⟩ + exact ⟨⟨hm.toLp _, (Submodule.le_topologicalClosure _) + (Submodule.subset_span ⟨f,hf,hm,rfl⟩)⟩,⟨f,hf,hc,hs,hm,rfl⟩,rfl⟩ + rw [he,←zeroTraceAmbient_eq_closure] + exact hu + +lemma harmonic_of_compact_tests (a : R3 → ℝ) (ha : AEStronglyMeasurable a ballMeasure) + (C : ℝ) (hC : 0≤C) (hb : ∀ᵐ x ∂ballMeasure, |a x|≤C) (u : H1) + (h : ∀ (f : R3 → ℝ) (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f), + HasCompactSupport f → tsupport f⊆ball → energy a u (smoothH1 f hf)=0) : + Harmonic a u := by + intro v hv + have hs : {v : H1 | v.val∈compactSmoothJets} ⊆ {v | energyForm a ha C hC hb u v=0} := by + rintro v ⟨f,hf,hc,hs,hm,he⟩ + have hev : v=smoothH1 f hf := Subtype.ext he + change energyForm a ha C hC hb u v=0 + rw [hev,energyForm_apply] + exact h f hf hc hs + have hc : IsClosed {v | energyForm a ha C hC hb u v=0} := + isClosed_eq (energyForm a ha C hC hb u).continuous continuous_const + rw [←energyForm_apply a ha C hC hb] + exact (closure_minimal hs hc) (compactH1_dense_H10 hv) + +open Set MeasureTheory Filter Topology Real + +def inverseBump : ContDiffBump (0:ℝ) := ⟨3/5,3/4,by norm_num,by norm_num⟩ +def inverseClip (r : ℝ) : ℝ := inverseBump r*r + +def inverseCorrection (r : ℝ) : ℝ := (1+inverseClip r)⁻¹-1 + +lemma inverseClip_smooth : ContDiff ℝ (↑(⊤ : ℕ∞)) inverseClip := + inverseBump.contDiff.mul contDiff_id + +lemma inverseClip_bound (r : ℝ) : |inverseClip r|≤3/4 := by + by_cases hr : |r|<3/4 + · calc + |inverseClip r|=inverseBump r*|r| := by + rw [inverseClip,abs_mul,abs_of_nonneg inverseBump.nonneg] + _ ≤ 1*|r| := mul_le_mul_of_nonneg_right inverseBump.le_one (abs_nonneg _) + _ ≤ 3/4 := by simpa only [one_mul] using hr.le + · have hb : inverseBump r=0 := inverseBump.zero_of_le_dist (by + change (3/4:ℝ)≤dist r 0; simpa only [dist_zero_right,Real.norm_eq_abs] using le_of_not_gt hr) + norm_num [inverseClip,hb] + +lemma inverseClip_denominator_pos (r : ℝ) : 0<1+inverseClip r := by + have h := (abs_le.mp (inverseClip_bound r)).1 + linarith + +lemma inverseCorrection_smooth : ContDiff ℝ (↑(⊤ : ℕ∞)) inverseCorrection := + ((contDiff_const.add inverseClip_smooth).inv (fun r => (inverseClip_denominator_pos r).ne')).sub contDiff_const + +lemma inverseCorrection_compact : HasCompactSupport inverseCorrection := by + apply inverseBump.hasCompactSupport.mono + intro r hr + contrapose! hr + simp only [Function.mem_support,not_not] at hr ⊢ + simp [inverseCorrection,inverseClip,hr] + +lemma inverseCorrection_zero : inverseCorrection 0=0 := by + simp [inverseCorrection,inverseClip] + +def inverseOperation : SmoothLipZero := SmoothLipZero.ofCompact inverseCorrection + inverseCorrection_smooth inverseCorrection_compact inverseCorrection_zero + +lemma inverseCorrection_eventually {r : ℝ} (hr : |r|≤1/2) : + inverseCorrection =ᶠ[𝓝 r] fun s => (1+s)⁻¹-1 := by + have hb : r ∈ Metric.ball 0 inverseBump.rIn := by + change dist r 0 < (3/5:ℝ) + rw [dist_zero_right,Real.norm_eq_abs] + linarith + filter_upwards [inverseBump.eventuallyEq_one_of_mem_ball hb] with s hs + simp only [inverseCorrection,inverseClip,hs,Pi.one_apply,one_mul] + +lemma inverseCorrection_eq {r : ℝ} (hr : |r|≤1/2) : inverseCorrection r=(1+r)⁻¹-1 := + (inverseCorrection_eventually hr).eq_of_nhds + +lemma inverseCorrection_deriv {r : ℝ} (hr : |r|≤1/2) : + deriv inverseCorrection r= -((1+r)^2)⁻¹ := by + rw [(inverseCorrection_eventually hr).deriv_eq] + have hn : (1:ℝ)+r≠0 := by have := (abs_le.mp hr).1; linarith + simpa only [one_div,neg_div,pow_two,id_eq,Pi.inv_apply] using + ((((hasDerivAt_id r).const_add 1).inv hn).sub_const 1).deriv + +lemma inverseCorrection_bound {r : ℝ} (hr : |r|≤1/2) : |inverseCorrection r|≤1 := by + rw [inverseCorrection_eq hr] + have hlo := (abs_le.mp hr).1 + have hpos : 0<1+r := by linarith + rw [abs_le] + constructor + · have h := inv_pos.mpr hpos; linarith + · have hle : (1+r)⁻¹≤2 := (inv_le_comm₀ hpos (by norm_num)).mpr (by norm_num; linarith) + linarith + +theorem inverseOperation_spec {w : H1} (hw : ∀ᵐ x ∂ballMeasure, |weakValue w x|≤1/2) : + (∀ᵐ x ∂ballMeasure, weakValue (inverseOperation.onH1 w) x=(1+weakValue w x)⁻¹-1) ∧ + (∀ᵐ x ∂ballMeasure, weakGradient (inverseOperation.onH1 w) x= + (-((1+weakValue w x)^2)⁻¹) • weakGradient w x) ∧ + (∀ᵐ x ∂ballMeasure, |weakValue (inverseOperation.onH1 w) x|≤1) ∧ + (w∈H10 → inverseOperation.onH1 w∈H10) := by + refine ⟨?_,?_,?_,fun h => inverseOperation.preserves_H10 h⟩ + · filter_upwards [inverseOperation.onH1_value w,hw] with x hx h + exact hx.trans (inverseCorrection_eq h) + · filter_upwards [inverseOperation.onH1_gradient w,hw] with x hx h + exact hx.trans (by rw [show deriv inverseOperation (weakValue w x)= -((1+weakValue w x)^2)⁻¹ from + inverseCorrection_deriv h]) + · filter_upwards [inverseOperation.onH1_value w,hw] with x hx h + change |jetValue ((inverseOperation.onH1 w).val x)|≤1 + rw [hx]; exact inverseCorrection_bound h + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/SobolevTraceChain.lean b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevTraceChain.lean new file mode 100644 index 0000000000000000000000000000000000000000..608bcd6b7499c9791aaa2dae0394579dc4af210b --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/SobolevTraceChain.lean @@ -0,0 +1,187 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.SobolevSmoothOperations + +namespace OAI + +noncomputable section + +namespace ScalarConductivity +open Set MeasureTheory Filter Topology + +lemma continuous_binary_closure {X Y Z : Type*} [TopologicalSpace X] [TopologicalSpace Y] + [TopologicalSpace Z] {T : X → Y → Z} (hT : Continuous (fun p : X × Y => T p.1 p.2)) + {S : Set X} {U : Set Y} {V : Set Z} (h : ∀ x∈S, ∀ y∈U, T x y∈V) + {x : X} (hx : x∈closure S) {y : Y} (hy : y∈closure U) : T x y∈closure V := by + have hb {x : X} (hx : x∈S) : T x y∈closure V := by + have ht : (fun y => T x y) '' U ⊆ V := by + rintro _ ⟨y,hy,rfl⟩; exact h x hx y hy + exact (image_closure_subset_closure_image (hT.comp (continuous_const.prodMk continuous_id))).trans + (closure_mono ht) ⟨y,hy,rfl⟩ + have ht : (fun x => T x y) '' S ⊆ closure V := by + rintro _ ⟨x,hx,rfl⟩; exact hb hx + have hh := (image_closure_subset_closure_image (hT.comp (continuous_id.prodMk continuous_const))).trans + (closure_mono ht) + simpa only [closure_closure,Function.comp_apply,id_eq] using hh ⟨x,hx,rfl⟩ + +lemma smoothJet_sub {f g : R3 → ℝ} (hf : Differentiable ℝ f) (hg : Differentiable ℝ g) : + smoothJet (f-g)=smoothJet f-smoothJet g := by + ext x i + refine Fin.cases ?_ (fun j => ?_) i + · rfl + · simp [smoothJet,gradient,fderiv_sub (hf x) (hg x)] + +lemma chainDifference_smooth_compact (F : SmoothLipZero) {z w : JetSpace} + (hz : z∈smoothJets) (hw : w∈compactSmoothJets) : + F.onLp (z+w)-F.onLp z ∈ compactSmoothJets := by + obtain ⟨f,hf,hfm,rfl⟩ := hz + obtain ⟨g,hg,hgc,hgs,hgm,rfl⟩ := hw + let d : R3 → ℝ := F ∘ (f+g)-F ∘ f + have hd : ContDiff ℝ (↑(⊤ : ℕ∞)) d := (F.smooth.comp (hf.add hg)).sub (F.smooth.comp hf) + have hs : Function.support d ⊆ Function.support g := by + intro x hx + contrapose! hx + simp only [Function.mem_support,not_not] at hx ⊢ + simp [d,hx] + have hdc : HasCompactSupport d := hgc.of_isClosed_subset isClosed_closure (closure_mono hs) + have hdm : tsupport d ⊆ ball := (closure_mono hs).trans hgs + have he : F.onLp (hfm.toLp _+hgm.toLp _)-F.onLp (hfm.toLp _) =ᵐ[ballMeasure] smoothJet d := by + filter_upwards [Lp.coeFn_sub (F.onLp (hfm.toLp _+hgm.toLp _)) (F.onLp (hfm.toLp _)), + F.onLp_ae (hfm.toLp _+hgm.toLp _),F.onLp_ae (hfm.toLp _), + Lp.coeFn_add (hfm.toLp _) (hgm.toLp _),hfm.coeFn_toLp,hgm.coeFn_toLp] with x hs h1 h2 ha hf' hg' + rw [hs,Pi.sub_apply,h1,h2,ha,Pi.add_apply,hf',hg'] + have haJet := congrFun (smoothJet_add (hf.differentiable (by simp)) + (hg.differentiable (by simp))) x + simp only [Pi.add_apply] at haJet + rw [←haJet] + rw [←smoothJet_comp (f := f+g) F.derivative ((hf.add hg).differentiable (by simp)) x, + ←smoothJet_comp (f := f) F.derivative (hf.differentiable (by simp)) x] + exact (congrFun (smoothJet_sub ((F.smooth.comp (hf.add hg)).differentiable (by simp)) + ((F.smooth.comp hf).differentiable (by simp))) x).symm + have hm := MemLp.ae_eq he (Lp.memLp (F.onLp (hfm.toLp _+hgm.toLp _)-F.onLp (hfm.toLp _))) + exact ⟨d,hd,hdc,hdm,hm,Lp.ext (he.trans hm.coeFn_toLp.symm)⟩ + +lemma chainDifference_H10 (F : SmoothLipZero) {z w : JetSpace} + (hz : z∈H1Space) (hw : w∈zeroTraceAmbient) : + F.onLp (z+w)-F.onLp z ∈ zeroTraceAmbient := by + change z∈(H1Space : Set JetSpace) at hz + change w∈(zeroTraceAmbient : Set JetSpace) at hw + change _∈(zeroTraceAmbient : Set JetSpace) + rw [H1Space_eq_closure] at hz + rw [zeroTraceAmbient_eq_closure] at hw ⊢ + exact continuous_binary_closure + ((F.onLp_continuous.comp (continuous_fst.add continuous_snd)).sub + (F.onLp_continuous.comp continuous_fst)) + (fun _ hz _ hw => chainDifference_smooth_compact F hz hw) hz hw + +lemma chain_trace_eq (F : SmoothLipZero) {u v : H1} (h : trace u=trace v) : + trace (F.onH1 u)=trace (F.onH1 v) := by + have hw : u-v∈H10 := (Submodule.Quotient.eq H10).mp h + apply (Submodule.Quotient.eq H10).mpr + change F.onLp u.val-F.onLp v.val∈zeroTraceAmbient + have hh := chainDifference_H10 F v.property (show u.val-v.val∈zeroTraceAmbient from hw) + simpa only [add_sub_cancel] using hh + +abbrev weakValue (u : H1) (x : R3) : ℝ := jetValue (u.val x) + +lemma jet_clipped_of_bound {M : ℝ} {z : JetFiber} (hz : |jetValue z|≤M) : + jetSuperposition (clipOperation M) (deriv (clipOperation M)) z=z := by + change jetLiftValue (clippedValue M (jetValue z)) + + jetLiftGradient (deriv (clippedValue M) (jetValue z) • jetGradient z)=z + rw [clippedValue_eq hz,clippedValue_deriv hz,one_smul,←jetFiber_decomposition] + +lemma jetValue_product (z w : JetFiber) : jetValue (jetProduct z w)=jetValue z*jetValue w := by + change jetValue z*jetValue w+0=_; simp + +lemma jetGradient_product (z w : JetFiber) : + jetGradient (jetProduct z w)=jetValue z • jetGradient w+jetValue w • jetGradient z := by + ext i + change 0+(jetValue z • jetGradient w+jetValue w • jetGradient z) i= + (jetValue z • jetGradient w+jetValue w • jetGradient z) i + simp + +theorem exists_H1_product {u v : H1} {M N : ℝ} + (hu : ∀ᵐ x ∂ballMeasure, |weakValue u x|≤M) + (hv : ∀ᵐ x ∂ballMeasure, |weakValue v x|≤N) : + ∃ p : H1, + (∀ᵐ x ∂ballMeasure, weakValue p x=weakValue u x*weakValue v x) ∧ + (∀ᵐ x ∂ballMeasure, weakGradient p x= + weakValue u x • weakGradient v x+weakValue v x • weakGradient u x) ∧ + (v∈H10 → p∈H10) := by + obtain ⟨A,hA,hca⟩ := exists_clippedValue_bound M + obtain ⟨B,hB,hcb⟩ := exists_clippedValue_bound N + let F := clipOperation M + let G := clipOperation N + let p : H1 := ⟨clippedProductLp F G A B u.val v.val, + clippedProductLp_preserves_H1 F G A B u.property v.property⟩ + have he : p.val =ᵐ[ballMeasure] fun x => jetProduct (u.val x) (v.val x) := by + filter_upwards [clippedProductLp_ae F G A B hA.le hB.le hca hcb u.val v.val,hu,hv] + with x hx hy hz + exact hx.trans (by rw [jet_clipped_of_bound hy,jet_clipped_of_bound hz]) + refine ⟨p,?_,?_,?_⟩ + · filter_upwards [he] with x hx + exact congrArg jetValue hx |>.trans (jetValue_product _ _) + · filter_upwards [he] with x hx + exact congrArg jetGradient hx |>.trans (jetGradient_product _ _) + · intro hv0 + exact clippedProductLp_preserves_H10 F G A B hA.le hB.le hca hcb u.property hv0 + +lemma smoothJet_constant (r : ℝ) : smoothJet (fun _ : R3 => r)=fun _ => jetLiftValue r := by + ext x i + refine Fin.cases ?_ (fun j => ?_) i + · rfl + · simp [smoothJet,gradient,jetLiftValue] + +lemma constantJet_memLp (r : ℝ) : MemLp (smoothJet (fun _ : R3 => r)) 2 ballMeasure := by + rw [smoothJet_constant] + exact memLp_const _ + +def constantH1 (r : ℝ) : H1 := + ⟨(constantJet_memLp r).toLp _,(Submodule.le_topologicalClosure _) + (Submodule.subset_span ⟨fun _ => r,contDiff_const,constantJet_memLp r,rfl⟩)⟩ + +lemma constantH1_value (r : ℝ) : weakValue (constantH1 r) =ᵐ[ballMeasure] fun _ => r := by + filter_upwards [(constantJet_memLp r).coeFn_toLp] with x hx + change jetValue ((constantJet_memLp r).toLp _ x)=r + rw [hx]; rfl + +lemma constantH1_gradient (r : ℝ) : weakGradient (constantH1 r) =ᵐ[ballMeasure] 0 := by + filter_upwards [(constantJet_memLp r).coeFn_toLp] with x hx + change jetGradient ((constantJet_memLp r).toLp _ x)=0 + rw [hx,smoothJet_constant] + ext i; rfl + +lemma weakValue_add (u v : H1) : weakValue (u+v) =ᵐ[ballMeasure] weakValue u+weakValue v := by + filter_upwards [Lp.coeFn_add u.val v.val] with x hx + change jetValue ((u.val+v.val) x)=jetValue (u.val x)+jetValue (v.val x) + rw [hx,Pi.add_apply,map_add] + +lemma weakValue_sub (u v : H1) : weakValue (u-v) =ᵐ[ballMeasure] weakValue u-weakValue v := by + filter_upwards [Lp.coeFn_sub u.val v.val] with x hx + change jetValue ((u.val-v.val) x)=jetValue (u.val x)-jetValue (v.val x) + rw [hx,Pi.sub_apply,map_sub] + +lemma weakValue_smul (r : ℝ) (u : H1) : weakValue (r • u) =ᵐ[ballMeasure] r • weakValue u := by + filter_upwards [Lp.coeFn_smul r u.val] with x hx + change jetValue ((r • u.val) x)=r*jetValue (u.val x) + rw [hx,Pi.smul_apply,map_smul]; rfl + +lemma weakGradient_add (u v : H1) : weakGradient (u+v) =ᵐ[ballMeasure] weakGradient u+weakGradient v := by + filter_upwards [Lp.coeFn_add u.val v.val] with x hx + change jetGradient ((u.val+v.val) x)=jetGradient (u.val x)+jetGradient (v.val x) + rw [hx,Pi.add_apply,map_add] + +lemma weakGradient_sub (u v : H1) : weakGradient (u-v) =ᵐ[ballMeasure] weakGradient u-weakGradient v := by + filter_upwards [Lp.coeFn_sub u.val v.val] with x hx + change jetGradient ((u.val-v.val) x)=jetGradient (u.val x)-jetGradient (v.val x) + rw [hx,Pi.sub_apply,map_sub] + +lemma weakGradient_smul (r : ℝ) (u : H1) : weakGradient (r • u) =ᵐ[ballMeasure] r • weakGradient u := by + filter_upwards [Lp.coeFn_smul r u.val] with x hx + change jetGradient ((r • u.val) x)=r • jetGradient (u.val x) + rw [hx,Pi.smul_apply,map_smul] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/UniformLocalPhysicalCorrection.lean b/lean/OAI/Analysis/Conductivity/Sobolev/UniformLocalPhysicalCorrection.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1a3de4757f400261f25919bbe3dbd7ea931a581 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/UniformLocalPhysicalCorrection.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ControlledCorrectionBoxes +import OAI.Analysis.Conductivity.Geometry.UniformPhysicalBoxCorrection + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise + +theorem uniform_local_physical_symmetric_correction_C0 + {I : Type*} (Xs : I → OpenPartialHomeomorph Coord3 Coord3) + (hXs : ∀ i,ContDiffOn ℝ (↑(⊤:ℕ∞)) (Xs i) (Xs i).source) + (hXis : ∀ i,ContDiffOn ℝ (↑(⊤:ℕ∞)) (Xs i).symm (Xs i).target) + {a b c d : Coord3} (hab : ∀ i,a i (hca i).le) (fun i => (hbd i).le) + let P := B*(B+1) + have hP : 0

(hmetric i x hx).2.2.2) + refine ⟨L*P,mul_pos hL hP,?_⟩ + intro i r hrc hs hm M hM hb + have hr := fun j => (hrc j).1 + have hc := fun j => (hrc j).2 + have hz (j : Fin 2) : (∫ x,r j x)=0 := by + fin_cases j + · exact congrFun hm 0 + · exact congrFun hm 1 + have ht : (∫ x,us i x 1*r 0 x-us i x 0*r 1 x)=0 := congrFun hm 2 + let X := Xs i + let u := us i + have hX := hXs i + have hXi := hXis i + have huu := hus i + have hu := hpot i + have houter := hboxes i + have hbox := hiK.trans houter + have hPsolve := localPiolaSource_inverse_C1_of_bounds X hX hXi houter hB + (fun x hx => ⟨(hmetric i x hx).1,(hmetric i x hx).2.1⟩) + (fun x hx => (hmetric i x hx).2.2.1) + + let p : Fin 2 → Coord3 → ℝ := fun j => localPiolaSource X.symm (r j) + have hst (j) : tsupport (r j)⊆X.target := + (hs j).trans (by rintro y ⟨x,hx,rfl⟩; exact X.map_source (hbox hx)) + have hp (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (p j) := + localPiolaSource_smooth X.symm hXi hX (r j) (hr j) (hc j) (hst j) + have hpc (j) : HasCompactSupport (p j) := + (localPiolaSource_compact X.symm (r j) (hc j) (hst j)).1 + have hps (j) : tsupport (p j)⊆correctionBox a b := + localPiolaSource_inverse_support X (r j) (hc j) hbox (hs j) + let q : Fin 2 → Box3 → ℝ := fun j => p j∘boxCoordinates.symm + have hq (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (q j) := (hp j).comp boxCoordinates.symm.contDiff + have hqc (j) : HasCompactSupport (q j) := (hpc j).comp_homeomorph boxCoordinates.symm.toHomeomorph + have hqs (j) : tsupport (q j)⊆ + (Ioo (a 0) (b 0) ×ˢ Ioo (a 1) (b 1)) ×ˢ Ioo (a 2) (b 2) := by + intro z hz + have h := hps j ((tsupport_comp_subset_preimage (p j) boxCoordinates.symm.continuous) hz) + simpa only [correctionBox,mem_preimage,boxCoordinates.apply_symm_apply] using h + have hd := hX.differentiableOn (by simp) + have hdi := hXi.differentiableOn (by simp) + have hback (j) : localPiolaSource X (p j)=r j := + localPiolaSource_inverse X hd hdi (r j) ((subset_tsupport _).trans (hst j)) + have hqz (j) : (∫ z,q j z)=0 := by + rw [←boxCoordinates_integral (q j)] + simp only [q,Function.comp_apply,boxCoordinates.symm_apply_apply] + have he := localPiolaSource_pairing volume X.symm hdi + (fun _ hy => local_fderiv_det_ne_zero X.symm hdi hd hy) (r j) + ((subset_tsupport _).trans (hst j)) (fun _ => 1) + simpa only [one_mul] using he.trans (by simpa only [one_mul] using hz j) + have hqt : (∫ z : Box3,z.1.2*q 0 z-z.1.1*q 1 z)=0 := by + rw [←boxCoordinates_integral (fun z : Box3 => z.1.2*q 0 z-z.1.1*q 1 z)] + have he := localPiolaSource_torque X hd hdi (p 0) (p 1) + ((subset_tsupport _).trans ((hps 0).trans hbox)) + ((subset_tsupport _).trans ((hps 1).trans hbox)) + rw [hback 0,hback 1] at he + simp only [q,Function.comp_apply,boxCoordinates.symm_apply_apply] + change (∫ x,x 1*p 0 x-x 0*p 1 x)=0 + rw [←he] + refine (integral_congr_ae ?_).trans ht + filter_upwards [] with y + by_cases hy : y∈X.target + · rw [hu hy]; rfl + · rw [image_eq_zero_of_notMem_tsupport (fun h => hy (hst 0 h)), + image_eq_zero_of_notMem_tsupport (fun h => hy (hst 1 h)),mul_zero,mul_zero,mul_zero,mul_zero] + have hpb (j) : UniformC1Bound (p j) (P*M) := + hPsolve (r j) (hr j) (hc j) ((hs j).trans (image_mono hiK)) M hM (hb j) + have hqb (j) : UniformC1Bound (q j) (P*M) := + (hpb j).comp_linear ((hp j).differentiable (by simp)) (mul_nonneg hP.le hM) + boxCoordinates.symm.toContinuousLinearMap boxCoordinates_symm_norm_le + obtain ⟨H,hH,hHc,hHs,hsy,hweak,hHb⟩ := solve i (q 0) (q 1) + (hq 0) (hq 1) (hqc 0) (hqc 1) (hqs 0) (hqs 1) (hqz 0) (hqz 1) hqt + (P*M) (mul_nonneg hP.le hM) (hqb 0) (hqb 1) + refine ⟨H,hH,hHc,hHs,hsy,?_,fun y => (hHb y).trans_eq (by ring)⟩ + apply symmetricSource_eq_of_weak huu hH hHc (fun j => ⟨hr j,hc j⟩) + intro j ψ hψ + have he := hweak j ψ hψ + have hpsource : (fun x => ![q 0 (boxCoordinates x),q 1 (boxCoordinates x)] j)=p j := by + funext x + fin_cases j <;> simp [q] + rw [hpsource,hback j] at he + refine (integral_congr_ae ?_).trans he + filter_upwards [] with y + by_cases hy : y∈X.target + · have hf : u =ᶠ[𝓝 y] coordinatePair∘X.symm := + Filter.eventuallyEq_of_mem (X.open_target.mem_nhds hy) (fun z hz => hu hz) + rw [hf.fderiv_eq] + · rw [image_eq_zero_of_notMem_tsupport (fun h => hy (hHs h)),Matrix.zero_mul,Matrix.zero_mul] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/VoltageH1Completion.lean b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageH1Completion.lean new file mode 100644 index 0000000000000000000000000000000000000000..e046b83641dfea5cbe3d1803ff96cff700726e85 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageH1Completion.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Conductivity.Scalarization.ScalarizationAffineLimit + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology TopologicalSpace Matrix +open scoped ENNReal Matrix.Norms.Elementwise + +def smoothVoltageJets (μ : Measure Coord3) (U : Set Coord3) : Set (VoltageJetSpace μ U) := + {z | ∃ (v : Coord3 → Fin 2 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) v ∧ + ∃ (hm : MemLp v 2 (μ.restrict U)) (hg : MemLp (voltageGradient v) 2 (μ.restrict U)), + z = (hm.toLp _,hg.toLp _)} + +def voltageH1Jets (μ : Measure Coord3) (U : Set Coord3) : + Submodule ℝ (VoltageJetSpace μ U) := + (Submodule.span ℝ (smoothVoltageJets μ U)).topologicalClosure + +lemma zeroVoltageJets_le_H1 (μ : Measure Coord3) (U : Set Coord3) : + zeroVoltageJets μ U ≤ voltageH1Jets μ U := by + apply Submodule.topologicalClosure_minimal + · rintro _ ⟨v,hv,hvc,hvs,hvm,hvg,rfl⟩ + apply (Submodule.span ℝ (smoothVoltageJets μ U)).le_topologicalClosure + exact Submodule.subset_span ⟨v,hv,hvm,hvg,rfl⟩ + · exact Submodule.isClosed_topologicalClosure _ + +lemma voltageH1_gradient_mem (μ : Measure Coord3) (U : Set Coord3) + {z : VoltageJetSpace μ U} (hz : z ∈ voltageH1Jets μ U) : + z.2 ∈ allVoltageGradients μ U := by + have hs : voltageH1Jets μ U ≤ + (allVoltageGradients μ U).comap (ContinuousLinearMap.snd ℝ _ _).toLinearMap := by + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro _ ⟨v,hv,hvm,hvg,rfl⟩ + apply (Submodule.span ℝ (smoothVoltageGradients μ U)).le_topologicalClosure + exact Submodule.subset_span ⟨v,hv,hvg,rfl⟩ + · exact (Submodule.isClosed_topologicalClosure _).preimage continuous_snd + exact hs hz + +lemma divergence_pairing_compact_voltage + (μ : Measure Coord3) {U : Set Coord3} + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + {z : VoltageJetSpace μ U} (hz : z ∈ compactVoltageJets μ U) : + inner ℝ z.2 (hF.toLp _) = 0 := by + obtain ⟨v,hv,hvc,hvs,hvm,hvg,rfl⟩ := hz + rw [L2.inner_def] + have he : (∫ x, inner ℝ ((hvg.toLp _) x) ((hF.toLp _) x) ∂μ.restrict U) = + ∫ x, inner ℝ (voltageGradient v x) (voltageFlux u A x) ∂μ.restrict U := by + apply integral_congr_ae + filter_upwards [hvg.coeFn_toLp,hF.coeFn_toLp] with x hx hy + rw [hx,hy] + rw [he,setIntegral_eq_integral_of_forall_compl_eq_zero] + · have hvc' (j) : HasCompactSupport (fun x => v x j) := + hvc.comp_left (g := fun v : Fin 2 → ℝ => v j) rfl + have hvs' (j) : tsupport (fun x => v x j) ⊆ U := + (tsupport_comp_subset (g := fun v : Fin 2 → ℝ => v j) rfl v).trans hvs + have hv' (j) : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun x => v x j) := + (contDiff_apply ℝ ℝ j).comp hv + simp_rw [voltageFlux,voltageGradient_pairing v (hv.differentiable (by simp))] + rw [integral_finsetSum _ (fun j _ => hint j _ (hv' j) (hvc' j) (hvs' j))] + simp only [hdiv _ _ (hv' _) (hvc' _) (hvs' _),Finset.sum_const_zero] + · intro x hx + have hg : voltageGradient v x = 0 := image_eq_zero_of_notMem_tsupport + (fun hs => hx (hvs (tsupport_voltageGradient hs))) + rw [hg,inner_zero_left] + +lemma divergence_pairing_zeroVoltageJets + (μ : Measure Coord3) {U : Set Coord3} + {u : Coord3 → Fin 2 → ℝ} {A : Coord3 → Symmetric3} + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + {z : VoltageJetSpace μ U} (hz : z ∈ zeroVoltageJets μ U) : + inner ℝ z.2 (hF.toLp _) = 0 := by + apply closure_minimal (s := compactVoltageJets μ U) ?_ ?_ hz + · exact fun z hz => divergence_pairing_compact_voltage μ hF hint hdiv hz + · exact isClosed_eq (continuous_snd.inner continuous_const) continuous_const + +theorem exact_scalarization_H1 + (μ : Measure Coord3) [μ.IsAddHaarMeasure] [Measure.InnerRegularCompactLTTop μ] + {a b : ℝ} (ha : 0 < a) (hab : a < b) + {U : Set Coord3} (hUb : Bornology.IsBounded U) (hUm : MeasurableSet U) + [IsFiniteMeasure (μ.restrict U)] [(μ.restrict U).WeaklyRegular] + [SeparableSpace (Lp FieldVector 2 (μ.restrict U))] + (u : Coord3 → Fin 2 → ℝ) (A : Coord3 → Symmetric3) (hAm : Measurable A) + (hu : MemLp u 2 (μ.restrict U)) + (hE : MemLp (voltageGradient u) 2 (μ.restrict U)) + (hF : MemLp (voltageFlux u A) 2 (μ.restrict U)) + (huH1 : (hu.toLp _,hE.toLp _) ∈ voltageH1Jets μ U) + (hint : SmoothFluxIntegrable μ U (conductivityFlux u A)) + (hdiv : ∀ j (ψ : Coord3 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) ψ → HasCompactSupport ψ → + tsupport ψ ⊆ U → (∫ x, fderiv ℝ ψ x ((conductivityFlux u A x).col j) ∂μ) = 0) + (hreg : μ (U \ regularRegion u A U) = 0) + (hgraph : ∀ᵐ x ∂μ, x ∈ U → A x ∈ matrixFiniteLaminate a b) : + ∃ (z : voltageH1Jets μ U) (F : Lp FieldVector 2 (μ.restrict U)) (s : Coord3 → ℝ), + Measurable s ∧ MemLp s ∞ (μ.restrict U) ∧ + z.val-(hu.toLp _,hE.toLp _) ∈ zeroVoltageJets μ U ∧ + (∀ᵐ x ∂μ.restrict U, s x ∈ Icc a b ∧ F x = s x • (z.val.2 x)) ∧ + (∀ W : voltageH1Jets μ U, inner ℝ W.val.2 F = inner ℝ W.val.2 (hF.toLp _)) ∧ + (∀ W : zeroVoltageJets μ U, inner ℝ W.val.2 F = 0) := by + obtain ⟨v,F,s,hsm,hs,hC⟩ := exact_scalarization_Cauchy_flux μ ha hab hUb hUm u A hAm + hE hF hint hdiv hreg hgraph + let z : voltageH1Jets μ U := ⟨(hu.toLp _,hE.toLp _) + v.val, + (voltageH1Jets μ U).add_mem huH1 (zeroVoltageJets_le_H1 μ U v.property)⟩ + refine ⟨z,F,s,hsm,?_,?_,hs,?_,?_⟩ + · apply memLp_top_of_bound hsm.aestronglyMeasurable b + filter_upwards [hs] with x hx + rw [Real.norm_eq_abs,abs_of_nonneg (ha.le.trans hx.1.1)] + exact hx.1.2 + · change (hu.toLp _,hE.toLp _) + v.val - (hu.toLp _,hE.toLp _) ∈ _ + rw [add_sub_cancel_left] + exact v.property + · intro W + exact hC _ (voltageH1_gradient_mem μ U W.property) + · intro W + rw [hC _ (voltageH1_gradient_mem μ U (zeroVoltageJets_le_H1 μ U W.property))] + exact divergence_pairing_zeroVoltageJets μ hF hint hdiv W.property + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/VoltageJetCompletion.lean b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageJetCompletion.lean new file mode 100644 index 0000000000000000000000000000000000000000..c51dd408e43f6a18549d68442807198ffa58b5f3 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageJetCompletion.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.VoltagePoincare + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open MeasureTheory Set Filter Topology +open scoped ENNReal NNReal + +abbrev VoltageJetSpace (μ : Measure Coord3) (U : Set Coord3) := + Lp (Fin 2 → ℝ) 2 (μ.restrict U) × Lp FieldVector 2 (μ.restrict U) + +def compactVoltageJets (μ : Measure Coord3) (U : Set Coord3) : Set (VoltageJetSpace μ U) := + {z | ∃ (v : Coord3 → Fin 2 → ℝ), ContDiff ℝ (↑(⊤ : ℕ∞)) v ∧ + HasCompactSupport v ∧ tsupport v ⊆ U ∧ + ∃ (hm : MemLp v 2 (μ.restrict U)) (hg : MemLp (voltageGradient v) 2 (μ.restrict U)), + z = (hm.toLp _,hg.toLp _)} + +lemma voltageGradient_zero : voltageGradient (0 : Coord3 → Fin 2 → ℝ) = 0 := by + funext x + change gradientVectorCLM (fderiv ℝ (0 : Coord3 → Fin 2 → ℝ) x) = 0 + simp only [fderiv_zero,Pi.zero_apply,map_zero] + +lemma voltageGradient_smul (c : ℝ) {v : Coord3 → Fin 2 → ℝ} (hv : Differentiable ℝ v) : + voltageGradient (c • v) = c • voltageGradient v := by + funext x + simp only [voltageGradient,fderiv_const_smul (hv x),map_smul,Pi.smul_apply] + +lemma compactVoltageJets_zero (μ : Measure Coord3) (U : Set Coord3) : + (0 : VoltageJetSpace μ U) ∈ compactVoltageJets μ U := by + refine ⟨0,contDiff_const,HasCompactSupport.zero,?_,MemLp.zero,?_,?_⟩ + · simp + · rw [voltageGradient_zero]; exact MemLp.zero + · simp only [voltageGradient_zero,MemLp.toLp_zero,Prod.zero_eq_mk] + +lemma compactVoltageJets_add (μ : Measure Coord3) (U : Set Coord3) + {z w : VoltageJetSpace μ U} (hz : z ∈ compactVoltageJets μ U) + (hw : w ∈ compactVoltageJets μ U) : z+w ∈ compactVoltageJets μ U := by + obtain ⟨v,hv,hvc,hvs,hvm,hvg,rfl⟩ := hz + obtain ⟨f,hf,hfc,hfs,hfm,hfg,rfl⟩ := hw + have he : voltageGradient (v+f) = voltageGradient v+voltageGradient f := + funext fun x => voltageGradient_add (hv.differentiable (by simp) x) (hf.differentiable (by simp) x) + have hmg : MemLp (voltageGradient (v+f)) 2 (μ.restrict U) := by rw [he]; exact hvg.add hfg + refine ⟨v+f,hv.add hf,hvc.add hfc,(tsupport_add v f).trans (union_subset hvs hfs), + hvm.add hfm,hmg,?_⟩ + apply Prod.ext + · exact (MemLp.toLp_add hvm hfm).symm + · change hvg.toLp _ + hfg.toLp _ = hmg.toLp _ + rw [← MemLp.toLp_add] + exact MemLp.toLp_congr _ _ (Eventually.of_forall fun x => congrFun he x |>.symm) + +lemma compactVoltageJets_smul (μ : Measure Coord3) (U : Set Coord3) + (c : ℝ) {z : VoltageJetSpace μ U} (hz : z ∈ compactVoltageJets μ U) : + c • z ∈ compactVoltageJets μ U := by + obtain ⟨v,hv,hvc,hvs,hvm,hvg,rfl⟩ := hz + have he := voltageGradient_smul c (hv.differentiable (by simp)) + have hmg : MemLp (voltageGradient (c • v)) 2 (μ.restrict U) := by + rw [he]; exact hvg.const_smul c + refine ⟨c • v,hv.const_smul c,hvc.smul_left, + (tsupport_smul_subset_right (fun _ : Coord3 => c) v).trans hvs, + hvm.const_smul c,hmg,?_⟩ + apply Prod.ext + · exact (MemLp.toLp_const_smul c hvm).symm + · change c • hvg.toLp _ = hmg.toLp _ + rw [← MemLp.toLp_const_smul] + exact MemLp.toLp_congr _ _ (Eventually.of_forall fun x => congrFun he x |>.symm) + +def compactVoltageJetModule (μ : Measure Coord3) (U : Set Coord3) : + Submodule ℝ (VoltageJetSpace μ U) where + carrier := compactVoltageJets μ U + zero_mem' := compactVoltageJets_zero μ U + add_mem' := compactVoltageJets_add μ U + smul_mem' := compactVoltageJets_smul μ U + +def zeroVoltageJets (μ : Measure Coord3) (U : Set Coord3) : + Submodule ℝ (VoltageJetSpace μ U) := + (compactVoltageJetModule μ U).topologicalClosure + +instance zeroVoltageJets_complete (μ : Measure Coord3) (U : Set Coord3) : + CompleteSpace (zeroVoltageJets μ U) := + (Submodule.isClosed_topologicalClosure _).completeSpace_coe + +lemma zeroVoltageJets_poincare + (μ : Measure Coord3) [μ.IsAddHaarMeasure] {U : Set Coord3} + (hUb : Bornology.IsBounded U) {z : VoltageJetSpace μ U} (hz : z ∈ zeroVoltageJets μ U) : + ‖z.1‖ ≤ (eLpNormLESNormFDerivOfLeConst (Fin 2 → ℝ) μ U 2 2 * + gradientCoordinateConstant : ℝ≥0) * ‖z.2‖ := by + apply closure_minimal (s := compactVoltageJets μ U) ?_ ?_ hz + · rintro _ ⟨v,hv,hvc,hvs,hvm,hvg,rfl⟩ + change ‖hvm.toLp _‖ ≤ _ * ‖hvg.toLp _‖ + rw [Lp.norm_toLp,Lp.norm_toLp] + exact compact_voltage_poincare μ hUb hv hvc hvs + · exact isClosed_le continuous_fst.norm (continuous_const.mul continuous_snd.norm) + +def zeroVoltageGradientMap (μ : Measure Coord3) (U : Set Coord3) : + zeroVoltageJets μ U →L[ℝ] Lp FieldVector 2 (μ.restrict U) := + (ContinuousLinearMap.snd ℝ _ _).comp (zeroVoltageJets μ U).subtypeL + +lemma zeroVoltageGradientMap_closed_range + (μ : Measure Coord3) [μ.IsAddHaarMeasure] {U : Set Coord3} + (hUb : Bornology.IsBounded U) : IsClosed (Set.range (zeroVoltageGradientMap μ U)) := by + let C : ℝ≥0 := eLpNormLESNormFDerivOfLeConst (Fin 2 → ℝ) μ U 2 2 * gradientCoordinateConstant + apply ((zeroVoltageGradientMap μ U).antilipschitz_of_bound (K := C+1) ?_).isClosed_range + (zeroVoltageGradientMap μ U).uniformContinuous + intro z + change ‖z.val‖ ≤ ((C+1 : ℝ≥0) : ℝ) * ‖z.val.2‖ + rw [Prod.norm_def,max_le_iff] + constructor + · exact (zeroVoltageJets_poincare μ hUb z.property).trans + (by change (C : ℝ) * _ ≤ _; push_cast; nlinarith [norm_nonneg z.val.2]) + · have hC : 0 ≤ (C : ℝ) := C.coe_nonneg + push_cast + nlinarith [norm_nonneg z.val.2] + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/VoltageOriginalH10.lean b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageOriginalH10.lean new file mode 100644 index 0000000000000000000000000000000000000000..c9694fd043f90821cec7f3cc33c6d402d0e91b47 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/VoltageOriginalH10.lean @@ -0,0 +1,193 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.VoltageJetCompletion +import OAI.Analysis.Conductivity.Variational.CompactBridge +import OAI.Analysis.Conductivity.Variational.WholeBallJet + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +open scoped ENNReal Classical + +def voltageValueComponentJet (j : Fin 2) : (Fin 2 → ℝ) →L[ℝ] JetFiber := + ({ toFun := fun v => WithLp.toLp 2 (Fin.cases (v j) (fun _ => 0)) + map_add' := by intro v w; ext i; refine Fin.cases ?_ (fun k => ?_) i <;> simp + map_smul' := by intro c v; ext i; refine Fin.cases ?_ (fun k => ?_) i <;> simp } : + (Fin 2 → ℝ) →ₗ[ℝ] JetFiber).toContinuousLinearMap + +def voltageGradientComponentJet (j : Fin 2) : FieldVector →L[ℝ] JetFiber := + ({ toFun := fun v => WithLp.toLp 2 (Fin.cases 0 (fun i => v (i,j))) + map_add' := by intro v w; ext i; refine Fin.cases ?_ (fun k => ?_) i <;> simp + map_smul' := by intro c v; ext i; refine Fin.cases ?_ (fun k => ?_) i <;> simp } : + FieldVector →ₗ[ℝ] JetFiber).toContinuousLinearMap + +def voltageComponentJetCLM (μ : Measure Coord3) (U : Set Coord3) (j : Fin 2) : + VoltageJetSpace μ U →L[ℝ] Lp JetFiber 2 (μ.restrict U) := + ((voltageValueComponentJet j).compLpL 2 (μ.restrict U)).comp + (ContinuousLinearMap.fst ℝ _ _)+ + ((voltageGradientComponentJet j).compLpL 2 (μ.restrict U)).comp + (ContinuousLinearMap.snd ℝ _ _) + +lemma voltageComponentJetCLM_ae (μ : Measure Coord3) (U : Set Coord3) (j : Fin 2) + (z : VoltageJetSpace μ U) : + voltageComponentJetCLM μ U j z=ᵐ[μ.restrict U] + fun x => WithLp.toLp 2 (Fin.cases (z.1 x j) (fun i => z.2 x (i,j))) := by + have h1 := (voltageValueComponentJet j).coeFn_compLpL (p:=2) (μ:=μ.restrict U) z.1 + have h2 := (voltageGradientComponentJet j).coeFn_compLpL (p:=2) (μ:=μ.restrict U) z.2 + have ha := Lp.coeFn_add ((voltageValueComponentJet j).compLpL 2 (μ.restrict U) z.1) + ((voltageGradientComponentJet j).compLpL 2 (μ.restrict U) z.2) + filter_upwards [h1,h2,ha] with x h1 h2 ha + change (((voltageValueComponentJet j).compLpL 2 (μ.restrict U) z.1)+ + ((voltageGradientComponentJet j).compLpL 2 (μ.restrict U) z.2)) x=_ + rw [ha,Pi.add_apply,h1,h2] + ext i + refine Fin.cases ?_ (fun k => ?_) i <;> + simp [voltageValueComponentJet,voltageGradientComponentJet] + +def voltageOriginalJetCLM {U : Set Coord3} (hU : MeasurableSet U) (j : Fin 2) : + VoltageJetSpace volume U →L[ℝ] JetSpace := + (lpRestrictionCLM ball).comp + (((Lp.compMeasurePreservingₗᵢ ℝ + (WithLp.ofLp : R3 → Coord3) + (PiLp.volume_preserving_ofLp (Fin 3))).toContinuousLinearMap).comp + ((lpZeroExtensionCLM hU).comp (voltageComponentJetCLM volume U j))) + +lemma voltageOriginalJetCLM_ae {U : Set Coord3} (hU : MeasurableSet U) (j : Fin 2) + (z : VoltageJetSpace volume U) : + voltageOriginalJetCLM hU j z=ᵐ[ballMeasure] fun x => + if WithLp.ofLp x∈U then WithLp.toLp 2 + (Fin.cases (z.1 (WithLp.ofLp x) j) (fun i => z.2 (WithLp.ofLp x) (i,j))) else 0 := by + have he := lpZeroExtensionCLM_ae_of_ae hU + (voltageComponentJetCLM volume U j z) (voltageComponentJetCLM_ae volume U j z) + have hp := (PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae_eq_comp he + have hc := Lp.coeFn_compMeasurePreserving + (lpZeroExtensionCLM hU (voltageComponentJetCLM volume U j z)) + (PiLp.volume_preserving_ofLp (Fin 3)) + have hr := lpRestrictionCLM_ae ball + ((Lp.compMeasurePreservingₗᵢ ℝ + (WithLp.ofLp : R3 → Coord3) + (PiLp.volume_preserving_ofLp (Fin 3))) + (lpZeroExtensionCLM hU (voltageComponentJetCLM volume U j z))) + apply hr.trans + apply ae_restrict_of_ae + filter_upwards [hc,hp] with x hc hp + apply hc.trans + rw [hp] + by_cases hx : WithLp.ofLp x∈U <;> simp [hx] + +lemma voltage_component_smoothJet {v : Coord3 → Fin 2 → ℝ} + (hv : Differentiable ℝ v) (j : Fin 2) (x : R3) : + smoothJet (fun x : R3 => v (WithLp.ofLp x) j) x= + WithLp.toLp 2 (Fin.cases (v (WithLp.ofLp x) j) + (fun i => voltageGradient v (WithLp.ofLp x) (i,j))) := by + ext k + refine Fin.cases rfl (fun i => ?_) k + change gradient (fun x : R3 => v (WithLp.ofLp x) j) x i=_ + have herr : gradient (fun x : R3 => v (WithLp.ofLp x) j) x i= + fderiv ℝ (fun x : R3 => v (WithLp.ofLp x) j) x (EuclideanSpace.single i 1) := by + have h : inner ℝ (EuclideanSpace.single i 1) + (gradient (fun x : R3 => v (WithLp.ofLp x) j) x)= + fderiv ℝ (fun x : R3 => v (WithLp.ofLp x) j) x (EuclideanSpace.single i 1) := by + simp only [inner_gradient_right,RCLike.conj_to_real] + simpa only [EuclideanSpace.inner_single_left,RCLike.conj_to_real,one_mul] using h + rw [herr] + let P : R3 ≃L[ℝ] Coord3 := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hd := ((ContinuousLinearMap.proj j : (Fin 2 → ℝ) →L[ℝ] ℝ).hasFDerivAt.comp (P x) + (hv (P x)).hasFDerivAt).comp x P.hasFDerivAt + have hP : (P : R3 → Coord3)=WithLp.ofLp := rfl + rw [show fderiv ℝ (fun x : R3 => v (WithLp.ofLp x) j) x= + (ContinuousLinearMap.proj j).comp ((fderiv ℝ v (P x)).comp P.toContinuousLinearMap) from by + simpa only [Function.comp_def,ContinuousLinearMap.comp_assoc,ContinuousLinearMap.proj_apply,hP] using hd.fderiv] + rfl + +lemma voltageOriginalJetCLM_compact {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (j : Fin 2) + {z : VoltageJetSpace volume U} (hz : z∈compactVoltageJets volume U) : + voltageOriginalJetCLM hU j z∈zeroTraceAmbient := by + obtain ⟨v,hv,hvc,hvs,hm,hg,rfl⟩ := hz + let P : R3 ≃L[ℝ] Coord3 := PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ) + have hP : (P : R3 → Coord3)=WithLp.ofLp := rfl + let f : R3 → ℝ := fun x => v (WithLp.ofLp x) j + have hf : ContDiff ℝ (↑(⊤:ℕ∞)) f := by + simpa only [Function.comp_def,hP] using + (((contDiff_apply ℝ ℝ j).comp hv).comp P.contDiff) + have hfc : HasCompactSupport f := by + simpa only [Function.comp_def,show (P.toHomeomorph : R3 → Coord3)=WithLp.ofLp from rfl] using + (hvc.comp_left (g:=fun w : Fin 2 → ℝ => w j) rfl).comp_homeomorph P.toHomeomorph + have hfsU : tsupport f⊆(WithLp.ofLp : R3 → Coord3)⁻¹' U := by + intro x hx + have hs := tsupport_comp_subset_preimage (fun y : Coord3 => v y j) P.continuous + have hm : P x∈tsupport (fun y : Coord3 => v y j) := hs hx + exact hvs ((tsupport_comp_subset (g:=fun w : Fin 2 → ℝ => w j) rfl v) hm) + have hfs : tsupport f⊆ball := by + intro x hx + simpa only [WithLp.toLp_ofLp] using hUb (WithLp.ofLp x) (hfsU hx) + have hm' := (PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + ((ae_restrict_iff' hU).1 hm.coeFn_toLp) + have hg' := (PiLp.volume_preserving_ofLp (Fin 3)).quasiMeasurePreserving.ae + ((ae_restrict_iff' hU).1 hg.coeFn_toLp) + have he : voltageOriginalJetCLM hU j (hm.toLp _,hg.toLp _)=(smoothH1 f hf).val := by + apply Lp.ext + filter_upwards [voltageOriginalJetCLM_ae hU j (hm.toLp _,hg.toLp _), + ae_restrict_of_ae hm',ae_restrict_of_ae hg',(smoothJet_memLp hf).coeFn_toLp] + with x hx hm hg hfx + change _=(smoothJet_memLp hf).toLp _ x + rw [hfx,hx] + by_cases hu : WithLp.ofLp x∈U + · rw [ite_eq_left hu,hm hu,hg hu] + exact (voltage_component_smoothJet (hv.differentiable (by simp)) j x).symm + · rw [ite_eq_right hu] + exact (smoothJet_zero_of_notMem_support (fun hh => hu (hfsU hh))).symm + rw [he] + exact smoothH1_mem_H10 f hf hfc hfs + +theorem voltageOriginalJetCLM_zeroTrace {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (j : Fin 2) + {z : VoltageJetSpace volume U} (hz : z∈zeroVoltageJets volume U) : + voltageOriginalJetCLM hU j z∈zeroTraceAmbient := by + exact closure_minimal + (fun z hz => voltageOriginalJetCLM_compact hU hUb j hz) + ((Submodule.isClosed_topologicalClosure _).preimage + (voltageOriginalJetCLM hU j).continuous) hz + +theorem voltage_original_H10_extension {U : Set Coord3} (hU : MeasurableSet U) + (hUb : ∀ y∈U,WithLp.toLp 2 y∈ball) (j : Fin 2) + {z : VoltageJetSpace volume U} (hz : z∈zeroVoltageJets volume U) : + ∃ w : H1,w∈H10 ∧ w.val=voltageOriginalJetCLM hU j z ∧ + ∀ᵐ x∂ballMeasure, + weakValue w x=(if WithLp.ofLp x∈U then z.1 (WithLp.ofLp x) j else 0) ∧ + ∀ i,weakGradient w x i=(if WithLp.ofLp x∈U then z.2 (WithLp.ofLp x) (i,j) else 0) := by + have hzero := voltageOriginalJetCLM_zeroTrace hU hUb j hz + let w : H1 := ⟨voltageOriginalJetCLM hU j z,zeroTraceAmbient_le_H1Space hzero⟩ + refine ⟨w,hzero,rfl,?_⟩ + filter_upwards [voltageOriginalJetCLM_ae hU j z] with x hx + change w.val x=_ at hx + by_cases hm : WithLp.ofLp x∈U + · rw [ite_eq_left hm] at hx + constructor + · change w.val x 0=_ + rw [hx,ite_eq_left hm] + rfl + · intro i + change (w.val x) i.succ=_ + rw [hx,ite_eq_left hm] + rfl + · rw [ite_eq_right hm] at hx + constructor + · change w.val x 0=_ + rw [hx,ite_eq_right hm] + rfl + · intro i + change (w.val x) i.succ=_ + rw [hx,ite_eq_right hm] + rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WallParticular.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticular.lean new file mode 100644 index 0000000000000000000000000000000000000000..d27d8247013da0e00c7d29a951de28e4159d3c03 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticular.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sobolev.WallPrimitive + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def wallAlong (d : E) (f : E × ℝ → ℝ) (p : E × ℝ) : ℝ := + fderiv ℝ f p (d,0) + +lemma wallAlong_smooth [ProperSpace E] (d : E) {f : E × ℝ → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (wallAlong d f) := + (hf.fderiv_right (by simp)).clm_apply contDiff_const + +lemma wallDerivative_add [ProperSpace E] {f g : E × ℝ → ℝ} (hf : Differentiable ℝ f) + (hg : Differentiable ℝ g) (p : E × ℝ) : + wallDerivative (fun q => f q+g q) p=wallDerivative f p+wallDerivative g p := by + simp only [wallDerivative,fderiv_fun_add (hf p) (hg p),add_apply] + +lemma wallDerivative_sub [ProperSpace E] {f g : E × ℝ → ℝ} (hf : Differentiable ℝ f) + (hg : Differentiable ℝ g) (p : E × ℝ) : + wallDerivative (fun q => f q-g q) p=wallDerivative f p-wallDerivative g p := by + simp only [wallDerivative,fderiv_fun_sub (hf p) (hg p),sub_apply] + +lemma wallDerivative_mul [ProperSpace E] {f g : E × ℝ → ℝ} (hf : Differentiable ℝ f) + (hg : Differentiable ℝ g) (p : E × ℝ) : + wallDerivative (fun q => f q*g q) p=wallDerivative f p*g p+f p*wallDerivative g p := by + simp only [wallDerivative,fderiv_fun_mul (hf p) (hg p),add_apply, + smul_apply,smul_eq_mul] + ring + +def wallParticularNumerator (d : E) (v r₁ r₂ : E × ℝ → ℝ) (p : E × ℝ) : ℝ := + wallPrimitive (fun q => r₂ q-wallAlong d (fun q => wallPrimitive r₁ q*wallDerivative v q) q) p + -wallPrimitive r₁ p*wallAlong d v p + +lemma wallParticularNumerator_smooth [ProperSpace E] (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (wallParticularNumerator d v r₁ r₂) := by + exact (wallPrimitive_smooth (h₂.sub (wallAlong_smooth d + ((wallPrimitive_smooth h₁).mul (wallDerivative_smooth hv))))).sub + ((wallPrimitive_smooth h₁).mul (wallAlong_smooth d hv)) + +lemma wallParticularNumerator_zero [ProperSpace E] (d : E) (v r₁ r₂ : E × ℝ → ℝ) (x : E) : + wallParticularNumerator d v r₁ r₂ (x,0)=0 := by + simp only [wallParticularNumerator,wallPrimitive_zero,zero_mul,sub_zero] + +theorem wall_particular_flux_equations [ProperSpace E] (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) (p : E × ℝ) : + wallDerivative (wallPrimitive r₁) p=r₁ p ∧ + wallAlong d (fun q => wallPrimitive r₁ q*wallDerivative v q) p+ + wallDerivative (fun q => wallPrimitive r₁ q*wallAlong d v q+ + wallParticularNumerator d v r₁ r₂ q) p=r₂ p := by + refine ⟨wallDerivative_primitive h₁ p,?_⟩ + let B : E × ℝ → ℝ := fun q => + r₂ q-wallAlong d (fun q => wallPrimitive r₁ q*wallDerivative v q) q + have hB : ContDiff ℝ (↑(⊤ : ℕ∞)) B := h₂.sub (wallAlong_smooth d + ((wallPrimitive_smooth h₁).mul (wallDerivative_smooth hv))) + have he : (fun q => wallPrimitive r₁ q*wallAlong d v q+ + wallParticularNumerator d v r₁ r₂ q)=wallPrimitive B := by + funext q; simp only [wallParticularNumerator,B]; ring + rw [he,wallDerivative_primitive hB] + dsimp [B]; ring + +lemma wall_ratio_multiply [ProperSpace E] {f g : E × ℝ → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (hg : ContDiff ℝ (↑(⊤ : ℕ∞)) g) + (hf0 : ∀ x, f (x,0)=0) (hg0 : ∀ x, g (x,0)=0) + (p : E × ℝ) (hq : wallQuotient g p≠0) : + (wallQuotient f p/wallQuotient g p)*g p=f p := by + rw [(smooth_wall_division hg hg0).2 p,(smooth_wall_division hf hf0).2 p] + field_simp + +theorem wall_particular_extension [ProperSpace E] (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) + (hz : ∀ x, wallDerivative v (x,0)=0) (x : E) + (hzz : wallDerivative (wallDerivative v) (x,0)≠0) : + let H := fun p => wallQuotient (wallParticularNumerator d v r₁ r₂) p/ + wallQuotient (wallDerivative v) p + ContDiffAt ℝ (↑(⊤ : ℕ∞)) H (x,0) ∧ + (∀ᶠ p in 𝓝 (x,0), H p*wallDerivative v p=wallParticularNumerator d v r₁ r₂ p) ∧ + H (x,0)=(r₂ (x,0)-r₁ (x,0)*wallAlong d v (x,0))/ + wallDerivative (wallDerivative v) (x,0) := by + let G := wallParticularNumerator d v r₁ r₂ + have hG := wallParticularNumerator_smooth d hv h₁ h₂ + have hG0 := wallParticularNumerator_zero d v r₁ r₂ + have hvz := wallDerivative_smooth hv + have hq : wallQuotient (wallDerivative v) (x,0)≠0 := by + simpa only [wallQuotient_zero] using hzz + refine ⟨(wall_ratio_extension hG hvz hG0 hz x hzz).1,?_,?_⟩ + · filter_upwards [(wallQuotient_smooth hvz).continuous.continuousAt.eventually_ne hq] with p hp + exact wall_ratio_multiply hG hvz hG0 hz p hp + · dsimp + rw [wallQuotient_zero,wallQuotient_zero] + congr 1 + let B : E × ℝ → ℝ := fun q => + r₂ q-wallAlong d (fun q => wallPrimitive r₁ q*wallDerivative v q) q + have hB : ContDiff ℝ (↑(⊤ : ℕ∞)) B := h₂.sub (wallAlong_smooth d + ((wallPrimitive_smooth h₁).mul hvz)) + change wallDerivative (fun q => wallPrimitive B q-wallPrimitive r₁ q*wallAlong d v q) (x,0)=_ + rw [wallDerivative_sub ((wallPrimitive_smooth hB).differentiable (by simp)) + (((wallPrimitive_smooth h₁).mul (wallAlong_smooth d hv)).differentiable (by simp)), + wallDerivative_primitive hB, + wallDerivative_mul ((wallPrimitive_smooth h₁).differentiable (by simp)) + ((wallAlong_smooth d hv).differentiable (by simp)), + wallDerivative_primitive h₁,wallPrimitive_zero,zero_mul,add_zero] + suffices he : wallAlong d (fun q => wallPrimitive r₁ q*wallDerivative v q) (x,0)=0 by + simp only [B,he,sub_zero] + simp only [wallAlong,fderiv_fun_mul + ((wallPrimitive_smooth h₁).differentiable (by simp) (x,0)) + (hvz.differentiable (by simp) (x,0)),wallPrimitive_zero,hz, + zero_smul,add_zero,zero_apply] + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularBounds.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..d656a43b72fd2561d335399917a8ac0d14955035 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularBounds.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.WallHomogeneous + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + +lemma wallParticularNumerator_derivative (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) (p : E × ℝ) : + wallDerivative (wallParticularNumerator d v r₁ r₂) p= + r₂ p-wallAlong d (wallPrimitive r₁) p*wallDerivative v p- + 2*wallPrimitive r₁ p*wallAlong d (wallDerivative v) p-r₁ p*wallAlong d v p := by + have hA := wallPrimitive_smooth h₁ + have hG := wallParticularNumerator_smooth d hv h₁ h₂ + have hh := (wall_particular_flux_equations d hv h₁ h₂ p).2 + rw [wallAlong_mul d (hA.differentiable (by simp)) + ((wallDerivative_smooth hv).differentiable (by simp)), + wallDerivative_add ((hA.mul (wallAlong_smooth d hv)).differentiable (by simp)) + (hG.differentiable (by simp)), + wallDerivative_mul (hA.differentiable (by simp)) + ((wallAlong_smooth d hv).differentiable (by simp)), + wallDerivative_primitive h₁,wall_mixed_commute d hv] at hh + linarith + +lemma wall_segment_mul {t u : ℝ} (ht : t∈Icc (0:ℝ) 1) (hu : u∈Icc (0:ℝ) 1) : + u*t∈Icc (0:ℝ) 1 := ⟨mul_nonneg hu.1 ht.1,by + calc u*t ≤ 1*t := mul_le_mul_of_nonneg_right hu.2 ht.1 + _ ≤ 1 := by simpa only [one_mul] using ht.2⟩ + +lemma wallParticularNumerator_derivative_bound (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) {p : E × ℝ} {ε M δ : ℝ} + (hε : 0≤ε) (hM : 0≤M) (hδ : |p.2|≤δ) + (hr₁ : ∀ t∈Icc (0:ℝ) 1, |r₁ (p.1,t*p.2)|≤ε) + (hr₂ : ∀ t∈Icc (0:ℝ) 1, |r₂ (p.1,t*p.2)|≤ε) + (hder : ∀ t∈Icc (0:ℝ) 1, |wallAlong d r₁ (p.1,t*p.2)|≤ε) + (hvz : ∀ t∈Icc (0:ℝ) 1, |wallDerivative v (p.1,t*p.2)|≤M) + (hvs : ∀ t∈Icc (0:ℝ) 1, |wallAlong d v (p.1,t*p.2)|≤M) + (hvsz : ∀ t∈Icc (0:ℝ) 1, |wallAlong d (wallDerivative v) (p.1,t*p.2)|≤M) : + ∀ t∈Icc (0:ℝ) 1, |wallDerivative (wallParticularNumerator d v r₁ r₂) (p.1,t*p.2)| + ≤ε*(1+M+3*δ*M) := by + intro t ht + have hδ0 : 0≤δ := (abs_nonneg _).trans hδ + have htδ : |t*p.2|≤δ := by + rw [abs_mul,abs_of_nonneg ht.1] + calc t*|p.2|≤1*|p.2| := mul_le_mul_of_nonneg_right ht.2 (abs_nonneg _) + _ ≤δ := by simpa only [one_mul] using hδ + have hA : |wallPrimitive r₁ (p.1,t*p.2)|≤δ*ε := by + apply (wallPrimitive_abs_bound (fun u hu => ?_)).trans + (mul_le_mul_of_nonneg_right htδ hε) + simpa only [←mul_assoc] using hr₁ (u*t) (wall_segment_mul ht hu) + have hAs : |wallAlong d (wallPrimitive r₁) (p.1,t*p.2)|≤δ*ε := by + rw [wallAlong_primitive d h₁] + apply (wallPrimitive_abs_bound (fun u hu => ?_)).trans + (mul_le_mul_of_nonneg_right htδ hε) + simpa only [←mul_assoc] using hder (u*t) (wall_segment_mul ht hu) + rw [wallParticularNumerator_derivative d hv h₁ h₂] + calc + _ ≤ |r₂ (p.1,t*p.2)|+ + |wallAlong d (wallPrimitive r₁) (p.1,t*p.2)*wallDerivative v (p.1,t*p.2)|+ + |2*wallPrimitive r₁ (p.1,t*p.2)*wallAlong d (wallDerivative v) (p.1,t*p.2)|+ + |r₁ (p.1,t*p.2)*wallAlong d v (p.1,t*p.2)| := by + have h₀ := abs_sub (r₂ (p.1,t*p.2)) + (wallAlong d (wallPrimitive r₁) (p.1,t*p.2)*wallDerivative v (p.1,t*p.2)) + have h₁ := abs_sub + (r₂ (p.1,t*p.2)-wallAlong d (wallPrimitive r₁) (p.1,t*p.2)*wallDerivative v (p.1,t*p.2)) + (2*wallPrimitive r₁ (p.1,t*p.2)*wallAlong d (wallDerivative v) (p.1,t*p.2)) + have h₂ := abs_sub + (r₂ (p.1,t*p.2)-wallAlong d (wallPrimitive r₁) (p.1,t*p.2)*wallDerivative v (p.1,t*p.2)- + 2*wallPrimitive r₁ (p.1,t*p.2)*wallAlong d (wallDerivative v) (p.1,t*p.2)) + (r₁ (p.1,t*p.2)*wallAlong d v (p.1,t*p.2)) + linarith + _ ≤ ε+δ*ε*M+2*(δ*ε)*M+ε*M := by + simp only [abs_mul,show |(2:ℝ)|=2 by norm_num] + apply add_le_add + · apply add_le_add + · exact add_le_add (hr₂ t ht) (mul_le_mul hAs (hvz t ht) (abs_nonneg _) (by positivity)) + · exact mul_le_mul (mul_le_mul_of_nonneg_left hA (show (0:ℝ)≤2 by norm_num)) (hvsz t ht) (abs_nonneg _) (by positivity) + · exact (mul_le_mul_of_nonneg_left (hvs t ht) (abs_nonneg _)).trans + (mul_le_mul_of_nonneg_right (hr₁ t ht) hM) + _ = ε*(1+M+3*δ*M) := by ring + +theorem wall_particular_coefficient_bound (d : E) {v r₁ r₂ : E × ℝ → ℝ} + (hv : ContDiff ℝ (↑(⊤ : ℕ∞)) v) (h₁ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₁) + (h₂ : ContDiff ℝ (↑(⊤ : ℕ∞)) r₂) {p : E × ℝ} {ε M δ c : ℝ} + (hε : 0≤ε) (hM : 0≤M) (hδ : |p.2|≤δ) (hc : 0 r j (p,boxCoordinates x) + +def wallParticularFamily (χ : Box3 → ℝ) (v : P×Box3 → ℝ) + (r : Fin 2 → P×Box3 → ℝ) (q : P×Coord3) : Mat3 := + wallParticularTensor χ (fun y => v (q.1,y)) + (fun y => r 0 (q.1,y)) (fun y => r 1 (q.1,y)) q.2 + +def wallResidualFamily (χ : Box3 → ℝ) (v : P×Box3 → ℝ) + (r : Fin 2 → P×Box3 → ℝ) (j : Fin 2) (q : P×Coord3) : ℝ := + wallParticularResidual χ (fun y => v (q.1,y)) + (fun y => r 0 (q.1,y)) (fun y => r 1 (q.1,y)) j q.2 + +omit [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] in +lemma wallResidualFamily_eq (χ : Box3 → ℝ) (v : P×Box3 → ℝ) + (r : Fin 2 → P×Box3 → ℝ) (p : P) : + (fun j x => wallResidualFamily χ v r j (p,x))= + wallInputPair r p-symmetricSource (fun x => wallParticularFamily χ v r (p,x)) + (wallCoordinatePair (fun y => v (p,y))) := by + ext j x + fin_cases j <;> rfl + +omit [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] in +lemma wallResidualFamily_zero {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} {p : P} (hz : ∀ j y,r j (p,y)=0) (j x) : + wallResidualFamily χ v r j (p,x)=0 := by + have he (j) : (fun y => r j (p,y))=fun _ => 0 := funext (hz j) + dsimp [wallResidualFamily,wallParticularResidual] + rw [he 0,he 1,wallParticularTensor_zero,symmetricSource_zero] + fin_cases j <;> simp [hz] + +omit [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] in +lemma wallParticularFamily_zero {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} {p : P} (hz : ∀ j y,r j (p,y)=0) (x) : + wallParticularFamily χ v r (p,x)=0 := by + have he (j) : (fun y => r j (p,y))=fun _ => 0 := funext (hz j) + dsimp [wallParticularFamily] + rw [he 0,he 1,wallParticularTensor_zero] + rfl + +omit [FiniteDimensional ℝ P] in +lemma wallInputPair_compactSmooth {r : Fin 2 → P×Box3 → ℝ} + (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) {S : Set Box3} (hS : IsCompact S) + {p : P} (hs : ∀ j,tsupport (fun y => r j (p,y))⊆S) : + CompactSmoothPair (wallInputPair r p) := by + intro j + refine ⟨(hr j).comp (contDiff_const.prodMk boxCoordinates.contDiff),?_⟩ + have hc : HasCompactSupport (fun y => r j (p,y)) := hS.of_isClosed_subset (isClosed_tsupport _) (hs j) + exact hc.comp_homeomorph boxCoordinates.toHomeomorph + +omit [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] in +lemma wallResidualFamily_tsupport {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} {S : Set Box3} {p : P} + (hχc : HasCompactSupport χ) (hs : ∀ j,tsupport (fun y => r j (p,y))⊆S) (j : Fin 2) : + tsupport (fun x => wallResidualFamily χ v r j (p,x))⊆boxCoordinates ⁻¹' (S∪tsupport χ) := by + have he := congrFun (wallResidualFamily_eq χ v r p) j + rw [he] + apply (tsupport_sub _ _).trans + apply union_subset + · exact (tsupport_comp_subset_preimage (fun y => r j (p,y)) boxCoordinates.continuous).trans + ((preimage_mono (hs j)).trans (preimage_mono subset_union_left)) + · exact (symmetricSource_tsupport _ _ j).trans + ((wallParticularTensor_compact (χ:=χ) (v:=fun y => v (p,y)) + (r₁:=fun y => r 0 (p,y)) (r₂:=fun y => r 1 (p,y)) + hχc).2.trans (preimage_mono subset_union_right)) + +lemma wallParticularFamily_smoothOn {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) + {V : Set P} (hV : IsOpen V) + (hne : ∀ p∈V,∀ x∈tsupport χ,wallQuotient (wallDerivative (fun y => v (p,y))) x≠0) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (wallParticularFamily χ v r) (V×ˢuniv) := + wallParticularTensor_parametric_smoothOn hχ hv (hr 0) (hr 1) hV hne + +lemma wallResidualFamily_smoothOn {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) + {V : Set P} (hV : IsOpen V) + (hne : ∀ p∈V,∀ x∈tsupport χ,wallQuotient (wallDerivative (fun y => v (p,y))) x≠0) (j) : + ContDiffOn ℝ (↑(⊤:ℕ∞)) (wallResidualFamily χ v r j) (V×ˢuniv) := + wallParticularResidual_parametric_smoothOn hχ hv (hr 0) (hr 1) hV hne j + +lemma wallParticularFamily_small {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hχc : HasCompactSupport χ) (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) + (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) {p : P} {V : Set P} + (hV : IsOpen V) (hp : p∈V) + (hne : ∀ p∈V,∀ x∈tsupport χ,wallQuotient (wallDerivative (fun y => v (p,y))) x≠0) + (hz : ∀ j y,r j (p,y)=0) {ε : ℝ} (hε : 0<ε) : + ∀ᶠ q in 𝓝 p,∀ x,‖wallParticularFamily χ v r (q,x)‖≤ε := by + apply compact_parametric_norm_small_global (f:=wallParticularFamily χ v r) (p:=p) + (boxCoordinates.toHomeomorph.isCompact_preimage.mpr hχc) + · intro x _ + exact ((wallParticularFamily_smoothOn hχ hv hr hV hne).contDiffAt + ((hV.prod isOpen_univ).mem_nhds ⟨hp,mem_univ x⟩)).continuousAt + · exact wallParticularFamily_zero hz + · apply Eventually.of_forall + intro q + exact (wallParticularTensor_compact (χ:=χ) (v:=fun y => v (q,y)) + (r₁:=fun y => r 0 (q,y)) (r₂:=fun y => r 1 (q,y)) hχc).2 + · exact hε + +omit [FiniteDimensional ℝ P] in +lemma wallResidualFamily_moment {χ : Box3 → ℝ} {v : P×Box3 → ℝ} + {r : Fin 2 → P×Box3 → ℝ} (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) + (hχc : HasCompactSupport χ) (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) + (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) {p : P} + (hrs : ∀ j,HasCompactSupport (fun y => r j (p,y))) + (hne : ∀ x∈tsupport χ,wallQuotient (wallDerivative (fun y => v (p,y))) x≠0) : + physicalSourceMoment (wallCoordinatePair (fun y => v (p,y))) + (fun j x => wallResidualFamily χ v r j (p,x))= + physicalSourceMoment (wallCoordinatePair (fun y => v (p,y))) (wallInputPair r p) := by + have hvp : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => v (p,y)) := hv.comp (contDiff_const.prodMk contDiff_id) + have hrp (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => r j (p,y)) := (hr j).comp (contDiff_const.prodMk contDiff_id) + have hh := wallParticularResidual_moments hχ hχc hvp (hrp 0) (hrp 1) (hrs 0) (hrs 1) hne + ext i + fin_cases i + · exact hh.2.2.1 + · exact hh.2.2.2.1 + · exact hh.2.2.2.2 + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularFinish.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularFinish.lean new file mode 100644 index 0000000000000000000000000000000000000000..73421d0752259063fc7f95c11f928272196f43a0 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WallParticularFinish.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Conductivity.Geometry.ControlledCorrectionBoxes +import OAI.Analysis.Conductivity.Sobolev.WallParticularFamily + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Matrix MeasureTheory Filter Topology +open scoped Matrix.Norms.Elementwise +variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] + +omit [FiniteDimensional ℝ P] in +lemma wall_particular_family_finishes + {χ : Box3 → ℝ} {v : P×Box3 → ℝ} {r : Fin 2 → P×Box3 → ℝ} + (hχ : ContDiff ℝ (↑(⊤:ℕ∞)) χ) (hχc : HasCompactSupport χ) + (hv : ContDiff ℝ (↑(⊤:ℕ∞)) v) (hr : ∀ j,ContDiff ℝ (↑(⊤:ℕ∞)) (r j)) + (q : P) {U : Set Coord3} (hχU : boxCoordinates ⁻¹' tsupport χ⊆U) + (hrs : ∀ j,HasCompactSupport (fun y => r j (q,y))) + (hne : ∀ z∈tsupport χ,wallQuotient (wallDerivative (fun y => v (q,y))) z≠0) + (hm : physicalSourceMoment (wallCoordinatePair (fun y => v (q,y))) (wallInputPair r q)=0) + {ε : ℝ} (small : ∀ x,‖wallParticularFamily χ v r (q,x)‖≤ε/2) + (solve : physicalSourceMoment (wallCoordinatePair (fun y => v (q,y))) + (fun j x => wallResidualFamily χ v r j (q,x))=0 → + BoundedPhysicallyCorrectable (wallCoordinatePair (fun y => v (q,y))) U + (fun j x => wallResidualFamily χ v r j (q,x)) (ε/2)) : + BoundedPhysicallyCorrectable (wallCoordinatePair (fun y => v (q,y))) U (wallInputPair r q) ε := by + have hvq : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => v (q,y)) := hv.comp (contDiff_const.prodMk contDiff_id) + have hrq (j) : ContDiff ℝ (↑(⊤:ℕ∞)) (fun y => r j (q,y)) := (hr j).comp (contDiff_const.prodMk contDiff_id) + have hRm := (wallResidualFamily_moment hχ hχc hv hr hrs hne).trans hm + let H : Coord3 → Mat3 := fun x => wallParticularFamily χ v r (q,x) + have hHs : ContDiff ℝ (↑(⊤:ℕ∞)) H := by + change ContDiff ℝ (↑(⊤:ℕ∞)) (wallParticularTensor χ (fun y => v (q,y)) + (fun y => r 0 (q,y)) (fun y => r 1 (q,y))) + exact wallParticularTensor_smooth hχ hvq (hrq 0) (hrq 1) hne + have hc := wallParticularTensor_compact (χ:=χ) (v:=fun y => v (q,y)) + (r₁:=fun y => r 0 (q,y)) (r₂:=fun y => r 1 (q,y)) hχc + have hHsolve : BoundedPhysicallyCorrectable (wallCoordinatePair (fun y => v (q,y))) U + (symmetricSource H (wallCoordinatePair (fun y => v (q,y)))) (ε/2) := + ⟨H,hHs,hc.1,hc.2.trans hχU,by + unfold H wallParticularFamily wallParticularTensor + intro x + exact wallMatrix_symmetric _ _ x,fun _ => rfl,small⟩ + have hh := hHsolve.add (wallCoordinatePair_smooth hvq) (solve hRm) + rw [wallResidualFamily_eq,add_sub_cancel] at hh + convert hh using 1; ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WallPrimitive.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WallPrimitive.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d6594e0897c65c64f874e00e89ffb63e67fe45e --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WallPrimitive.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.Conductivity.Walls.HadamardWall + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology +variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + +def wallPrimitive (f : E × ℝ → ℝ) (p : E × ℝ) : ℝ := + p.2 * ∫ t in Icc (0:ℝ) 1, f (p.1,t*p.2) + +lemma wallPrimitive_smooth {f : E × ℝ → ℝ} (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (wallPrimitive f) := by + apply contDiff_snd.mul + apply contDiff_compact_integral (μ := volume) + (F := fun p : (E × ℝ) × ℝ => f (p.1.1,p.2*p.1.2)) + (K := Icc (0:ℝ) 1) _ isCompact_Icc + exact hf.comp (contDiff_fst.fst.prodMk (contDiff_snd.mul contDiff_fst.snd)) + +omit [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] in +lemma wallPrimitive_eq_intervalIntegral (f : E × ℝ → ℝ) (x : E) (z : ℝ) : + wallPrimitive f (x,z)=∫ t in (0:ℝ)..z, f (x,t) := by + have he := intervalIntegral.smul_integral_comp_mul_right + (fun t : ℝ => f (x,t)) z (a := 0) (b := 1) + simpa only [smul_eq_mul,zero_mul,one_mul, + intervalIntegral.integral_of_le (by norm_num : (0:ℝ)≤1), + ←integral_Icc_eq_integral_Ioc,wallPrimitive] using he + +omit [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] in +lemma wallPrimitive_zero (f : E × ℝ → ℝ) (x : E) : wallPrimitive f (x,0)=0 := by + simp [wallPrimitive] + +omit [NormedSpace ℝ E] [ProperSpace E] in +lemma wallPrimitive_hasDerivAt {f : E × ℝ → ℝ} (hf : Continuous f) (x : E) (z : ℝ) : + HasDerivAt (fun t : ℝ => wallPrimitive f (x,t)) (f (x,z)) z := by + simp_rw [wallPrimitive_eq_intervalIntegral] + have hc : Continuous (fun t : ℝ => f (x,t)) := + hf.comp (continuous_const.prodMk continuous_id) + exact intervalIntegral.integral_hasDerivAt_right (hc.intervalIntegrable _ _) + (hc.stronglyMeasurableAtFilter _ _) hc.continuousAt + +lemma wallDerivative_primitive {f : E × ℝ → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (p : E × ℝ) : + wallDerivative (wallPrimitive f) p=f p := by + have h := ((wallPrimitive_smooth hf).differentiable (by simp) p).hasFDerivAt.comp_hasDerivAt p.2 + ((hasDerivAt_const p.2 p.1).prodMk (hasDerivAt_id p.2)) + exact h.unique (wallPrimitive_hasDerivAt hf.continuous p.1 p.2) + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WeakCompactHilbert.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WeakCompactHilbert.lean new file mode 100644 index 0000000000000000000000000000000000000000..1223cec0af503efc587f6ad91942f6e0c31b1287 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WeakCompactHilbert.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.Conductivity.Model + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology + +lemma continuous_weakDual_to_weakHilbert + {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] : + Continuous (fun L : WeakDual ℝ V => + toWeakSpace ℝ V ((InnerProductSpace.toDual ℝ V).symm (WeakDual.toStrongDual L))) := by + apply WeakBilin.continuous_of_continuous_eval + intro T + have h := WeakDual.eval_continuous (𝕜 := ℝ) + ((InnerProductSpace.toDual ℝ V).symm T) + convert h using 1 + ext L + change T ((InnerProductSpace.toDual ℝ V).symm (WeakDual.toStrongDual L)) = + (WeakDual.toStrongDual L) ((InnerProductSpace.toDual ℝ V).symm T) + rw [← InnerProductSpace.toDual_symm_apply,real_inner_comm, + InnerProductSpace.toDual_symm_apply] + +lemma isCompact_weak_closedBall + {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + (x : V) (r : ℝ) : + IsCompact (toWeakSpace ℝ V '' Metric.closedBall x r) := by + have hc := (WeakDual.isCompact_closedBall (InnerProductSpace.toDual ℝ V x) r).image + (continuous_weakDual_to_weakHilbert (V := V)) + convert hc using 1 + ext y + constructor + · rintro ⟨z,hz,rfl⟩ + refine ⟨StrongDual.toWeakDual (InnerProductSpace.toDual ℝ V z),?_,?_⟩ + · change dist ((InnerProductSpace.toDual ℝ V) z) ((InnerProductSpace.toDual ℝ V) x) ≤ r + simpa only [LinearIsometryEquiv.dist_map] using (Metric.mem_closedBall.mp hz) + · exact congrArg (toWeakSpace ℝ V) ((InnerProductSpace.toDual ℝ V).symm_apply_apply z) + · rintro ⟨L,hL,rfl⟩ + refine ⟨(InnerProductSpace.toDual ℝ V).symm (WeakDual.toStrongDual L),?_,rfl⟩ + change dist ((InnerProductSpace.toDual ℝ V).symm (WeakDual.toStrongDual L)) x ≤ r + rw [← (InnerProductSpace.toDual ℝ V).symm_apply_apply x, + LinearIsometryEquiv.dist_map] + exact hL + +lemma continuous_weak_pair + {V W : Type*} [NormedAddCommGroup V] [NormedSpace ℝ V] + [NormedAddCommGroup W] [NormedSpace ℝ W] : + Continuous (fun p : WeakSpace ℝ V × WeakSpace ℝ W => + toWeakSpace ℝ (V × W) ((toWeakSpace ℝ V).symm p.1,(toWeakSpace ℝ W).symm p.2)) := by + apply WeakBilin.continuous_of_continuous_eval + intro L + let LV := L.comp (ContinuousLinearMap.inl ℝ V W) + let LW := L.comp (ContinuousLinearMap.inr ℝ V W) + have hV := (WeakBilin.eval_continuous (topDualPairing ℝ V).flip LV).comp (continuous_fst : Continuous (Prod.fst : WeakSpace ℝ V × WeakSpace ℝ W → WeakSpace ℝ V)) + have hW := (WeakBilin.eval_continuous (topDualPairing ℝ W).flip LW).comp (continuous_snd : Continuous (Prod.snd : WeakSpace ℝ V × WeakSpace ℝ W → WeakSpace ℝ W)) + convert hV.add hW using 1 + ext p + change L ((toWeakSpace ℝ V).symm p.1,(toWeakSpace ℝ W).symm p.2) = + L ((toWeakSpace ℝ V).symm p.1,0) + L (0,(toWeakSpace ℝ W).symm p.2) + rw [← map_add] + simp + +lemma isCompact_weak_product_closedBalls + {V W : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + [NormedAddCommGroup W] [InnerProductSpace ℝ W] [CompleteSpace W] + (r s : ℝ) : + IsCompact (toWeakSpace ℝ (V × W) '' + (Metric.closedBall (0 : V) r ×ˢ Metric.closedBall (0 : W) s)) := by + have h := ((isCompact_weak_closedBall (0 : V) r).prod + (isCompact_weak_closedBall (0 : W) s)).image (continuous_weak_pair (V := V) (W := W)) + convert h using 1 + ext p + constructor + · rintro ⟨⟨x,y⟩,⟨hx,hy⟩,rfl⟩ + exact ⟨(toWeakSpace ℝ V x,toWeakSpace ℝ W y),⟨⟨x,hx,rfl⟩,⟨y,hy,rfl⟩⟩,rfl⟩ + · rintro ⟨⟨x,y⟩,⟨⟨a,ha,rfl⟩,⟨b,hb,rfl⟩⟩,rfl⟩ + exact ⟨(a,b),⟨ha,hb⟩,rfl⟩ + +lemma isCompact_weak_closure_of_pair_bounds + {V W : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] [CompleteSpace V] + [NormedAddCommGroup W] [InnerProductSpace ℝ W] [CompleteSpace W] + (S : Set (V × W)) {r s : ℝ} + (hS : ∀ z ∈ S, ‖z.1‖ ≤ r ∧ ‖z.2‖ ≤ s) : + IsCompact (closure (toWeakSpace ℝ (V × W) '' S)) := by + let K := toWeakSpace ℝ (V × W) '' + (Metric.closedBall (0 : V) r ×ˢ Metric.closedBall (0 : W) s) + have hk : IsCompact K := isCompact_weak_product_closedBalls r s + apply hk.of_isClosed_subset isClosed_closure + apply closure_minimal _ hk.isClosed + rintro _ ⟨z,hz,rfl⟩ + exact ⟨z,by simpa only [mem_prod,Metric.mem_closedBall,dist_zero_right] using hS z hz,rfl⟩ + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sobolev/WeylPairGluing.lean b/lean/OAI/Analysis/Conductivity/Sobolev/WeylPairGluing.lean new file mode 100644 index 0000000000000000000000000000000000000000..10d432898d4a98b3de91204a5aa02b3bffa16e6d --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sobolev/WeylPairGluing.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.WeakHarmonicClassical +import OAI.Analysis.Conductivity.Variational.SmoothRepresentativeGluing + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology Matrix +open scoped Matrix.Norms.Elementwise + +theorem weakWeyl_pair_cartesian_representative (f : Fin 2 → WholeL2) {U : Set R3} + (hU : IsOpen U) (hf : ∀ j,WeaklyHarmonicOn (f j) U) : + ∃ u : Coord3 → Fin 2 → ℝ, + ContDiffOn ℝ (↑(⊤:ℕ∞)) u ((WithLp.toLp 2 : Coord3 → R3) ⁻¹' U) ∧ + (∀ᵐ y : Coord3,y∈(WithLp.toLp 2 : Coord3 → R3) ⁻¹' U → + u y=fun j => f j (WithLp.toLp 2 y)) ∧ + ∀ᵐ y : Coord3,y∈(WithLp.toLp 2 : Coord3 → R3) ⁻¹' U → + y∈regularRegion u (fun _ => ⟨1,Matrix.transpose_one⟩) + ((WithLp.toLp 2 : Coord3 → R3) ⁻¹' U) := by + classical + let I := {p : R3×ℝ // 0 Metric.ball i.val.1 (i.val.2/4) + let g : I → R3 → Fin 2 → ℝ := fun i x j => radialMollify (f j) (i.val.2/4) x + have hO (i : I) : IsOpen (O i) := Metric.isOpen_ball + have hOU (i : I) : O i⊆U := by + have hh : i.val.2 / 4 ≤ i.val.2 := by linarith [i.property.1] + exact ((Metric.ball_subset_ball hh).trans Metric.ball_subset_closedBall).trans i.property.2 + have hcover : (⋃ i : I,O i)=U := by + apply Subset.antisymm (iUnion_subset hOU) + intro x hx + obtain ⟨r,hr,hball⟩ := Metric.nhds_basis_closedBall.mem_iff.mp (hU.mem_nhds hx) + exact mem_iUnion.mpr ⟨⟨(x,r),hr,hball⟩,Metric.mem_ball_self (by change 0 f j x)=ᵐ[volume.restrict (O i)] g i := by + have hh (j : Fin 2) := (weakWeyl_local (hf j) i.property.1 i.property.2).2 + filter_upwards [ae_all_iff.mpr hh] with x hx + exact funext hx + obtain ⟨v,hvg,hve,hvs⟩ := smooth_representatives_glue volume O hO + (fun x j => f j x) g (fun i => (hgs i).contDiffOn) hge + rw [hcover] at hve hvs + let P : Coord3 ≃L[ℝ] R3 := (PiLp.continuousLinearEquiv 2 ℝ (fun _ : Fin 3 => ℝ)).symm + let V : Set Coord3 := P ⁻¹' U + let u : Coord3 → Fin 2 → ℝ := v ∘ P + have hus : ContDiffOn ℝ (↑(⊤:ℕ∞)) u V := + hvs.comp P.contDiff.contDiffOn (fun _ hx => hx) + have he : ∀ᵐ y : Coord3,y∈V → u y=fun j => f j (P y) := by + have hh := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae + ((ae_restrict_iff' hU.measurableSet).mp hve) + filter_upwards [hh] with y hy hyV + exact (hy hyV).symm + refine ⟨u,hus,he,?_⟩ + let A : Coord3 → Symmetric3 := fun _ => ⟨1,Matrix.transpose_one⟩ + have hp (i : I) : ∀ᵐ x∂volume.restrict (O i),P.symm x∈regularRegion u A V := by + have hh := weakWeyl_pair_ae_regular (hf 0) (hf 1) i.property.1 i.property.2 + filter_upwards [ae_restrict_of_ae hh,ae_restrict_mem (hO i).measurableSet] with x hx hxO + obtain ⟨r,hr,hball,hreg⟩ := hx hxO + let W : Set Coord3 := P ⁻¹' Metric.ball x r + have hW : IsOpen W := Metric.isOpen_ball.preimage P.continuous + have hWV : W⊆V := preimage_mono (hball.trans (hOU i)) + have hg (j : Fin 2) : ContDiffOn ℝ (↑(⊤:ℕ∞)) (fun x => g i x j) (Metric.ball x r) := + ((weakWeyl_local (hf j) i.property.1 i.property.2).1).contDiffOn + have hrr := HarmonicPairRegularOn.toCartesian Metric.isOpen_ball hg hreg + have heW : EqOn u (fun y j => g i (P y) j) W := by + intro y hy + exact hvg i (hball hy) + refine mem_regularRegion_iff.mpr ⟨W,hWV,⟨hW,hus.mono hWV,contDiff_const.contDiffOn, + hrr.congr hW heW⟩,?_⟩ + change P (P.symm x)∈Metric.ball x r + rw [P.apply_symm_apply] + exact Metric.mem_ball_self hr + have hpU := ae_on_open_cover volume O hO + (fun x => P.symm x∈regularRegion u A V) hp + rw [hcover] at hpU + have hh := (PiLp.volume_preserving_toLp (Fin 3)).quasiMeasurePreserving.ae + ((ae_restrict_iff' hU.measurableSet).mp hpU) + filter_upwards [hh] with y hy hyV + exact hy hyV + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularCoefficient.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularCoefficient.lean new file mode 100644 index 0000000000000000000000000000000000000000..a0e789c979aedb2ba0f92b1fc917556fa126b5ff --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularCoefficient.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralSmoothTrace +import OAI.Analysis.Conductivity.Variational.SmoothCompactParameter + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal + +local instance angularCoefficientMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance angularCoefficientProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma contDiff_sourceAngularPolynomial_joint : + ContDiff ℝ (↑(⊤ : ℕ∞)) (fun z : ℝ × (Fin 4 → ℝ) => sourceAngularPolynomial z.1 z.2) := by + apply contDiff_pi.mpr + intro i + fin_cases i <;> dsimp [sourceAngularPolynomial] <;> fun_prop + +def sourceAngularCoefficient (f : (Fin 3 → ℝ) → ℝ) (a b : ℝ) + (h : TorusModes) (t : ℝ) : ℂ := + mFourierCoeff (fun θ => (f (sourceAngularCollar (a*t+b) θ) : ℂ)) h + +lemma sourceAngularCoefficient_smooth {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b : ℝ) (h : TorusModes) : + ContDiff ℝ (↑(⊤ : ℕ∞)) (sourceAngularCoefficient f a b h) := by + let F : ℝ × ((Fin 4 → ℝ) × ℂ) → ℂ := fun z => + z.2.2 * (f (sourceAngularPolynomial (a*z.1+b) z.2.1) : ℂ) + have hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F := by + apply ContDiff.mul (contDiff_snd.comp contDiff_snd) + exact Complex.ofRealCLM.contDiff.comp (hf.comp + (contDiff_sourceAngularPolynomial_joint.comp + ((contDiff_const.mul contDiff_fst |>.add contDiff_const).prodMk + (contDiff_fst.comp contDiff_snd)))) + have hr : Continuous (fun θ : UnitAddTorus (Fin 2) => + (sourceRayCoordinates θ,mFourier (-h) θ)) := + continuous_sourceRayCoordinates.prodMk (mFourier (-h)).continuous + exact contDiff_compact_parameter hF hr + +def sourceAngularAxial (f : (Fin 3 → ℝ) → ℝ) (a b t : ℝ) + (θ : UnitAddTorus (Fin 2)) : ℂ := + ((deriv (fun u => f (sourceAngularCollar (a*u+b) θ)) t : ℝ) : ℂ) + +lemma continuous_sourceAngularAxial {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b : ℝ) : + Continuous (fun z : ℝ × UnitAddTorus (Fin 2) => sourceAngularAxial f a b z.1 z.2) := by + let F : ℝ × (Fin 4 → ℝ) → ℝ := fun z => + f (sourceAngularPolynomial (a*z.1+b) z.2) + have hF : ContDiff ℝ (↑(⊤ : ℕ∞)) F := + hf.comp (contDiff_sourceAngularPolynomial_joint.comp + ((contDiff_const.mul contDiff_fst |>.add contDiff_const).prodMk contDiff_snd)) + have he (t : ℝ) (θ : UnitAddTorus (Fin 2)) : + sourceAngularAxial f a b t θ = + (fderiv ℝ F (t,sourceRayCoordinates θ) (1,0) : ℂ) := by + have h := (hF.differentiable (by simp)).differentiableAt.hasFDerivAt + (x:=(t,sourceRayCoordinates θ)) + have hg := h.comp_hasDerivAt t ((hasDerivAt_id t).prodMk + (hasDerivAt_const t (sourceRayCoordinates θ))) + simpa only [sourceAngularAxial,sourceAngularCollar,F,Function.comp_def,id_eq] using + congrArg (fun u : ℝ => (u:ℂ)) hg.deriv + simp_rw [he] + exact Complex.continuous_ofReal.comp + ((hF.continuous_fderiv (by simp)).comp + (continuous_fst.prodMk (continuous_sourceRayCoordinates.comp continuous_snd)) + |>.clm_apply continuous_const) + +lemma sourceAngularCoefficient_hasDerivAt {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b : ℝ) (h : TorusModes) (t : ℝ) : + HasDerivAt (sourceAngularCoefficient f a b h) + (mFourierCoeff (sourceAngularAxial f a b t) h) t := by + have hF : Continuous (fun z : ℝ × UnitAddTorus (Fin 2) => + mFourier (-h) z.2 * (f (sourceAngularCollar (a*z.1+b) z.2) : ℂ)) := by + apply ((mFourier (-h)).continuous.comp continuous_snd).mul + exact Complex.continuous_ofReal.comp (hf.continuous.comp + (contDiff_sourceAngularPolynomial_joint.continuous.comp + ((continuous_const.mul continuous_fst |>.add continuous_const).prodMk + (continuous_sourceRayCoordinates.comp continuous_snd)))) + have hD := ((mFourier (-h)).continuous.comp continuous_snd).mul + (continuous_sourceAngularAxial hf a b) + apply hasDerivAt_compact_parameter hF hD + intro u θ + have hg : ContDiff ℝ (↑(⊤ : ℕ∞)) (fun v => f (sourceAngularCollar (a*v+b) θ)) := + hf.comp (contDiff_sourceAngularPolynomial_joint.comp + ((contDiff_const.mul contDiff_id |>.add contDiff_const).prodMk contDiff_const)) + simpa only [sourceAngularAxial,Function.comp_def,Pi.mul_apply] using + (((hg.differentiable (by simp)).differentiableAt (x:=u)).hasDerivAt.ofReal_comp).const_mul + (mFourier (-h) θ) + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularGraph.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularGraph.lean new file mode 100644 index 0000000000000000000000000000000000000000..a16eea312dba0dc24deb42abd8b53fc9c77a90a4 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularGraph.lean @@ -0,0 +1,246 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.PhysicalTestEnergy +import OAI.Analysis.Conductivity.Fourier.CylinderFourierGraph +import OAI.Analysis.Conductivity.Sources.AngularJet + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal +local instance angularGraphMeasureSpace : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance angularGraphIsProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma smoothAxisModeJet_ae {q : ℝ → ℂ} (hq : ContDiff ℝ (↑(⊤:ℕ∞)) q) + (R : ℝ) (h : TorusModes) (j : Fin 4) : + (smoothAxisModeJet hq R h) j =ᵐ[FiniteAxisMeasure R] + fun t => ![q t,deriv q t,(Complex.I*(h 0))*q t,(Complex.I*(h 1))*q t] j := by + have hq₀ := smoothFiniteAxisLp_ae hq.continuous R + have hq₁ := smoothFiniteAxisLp_ae (hq.continuous_deriv (by simp)) R + have hq₂ := Lp.coeFn_smul (Complex.I*(h 0:ℂ)) (smoothFiniteAxisLp hq.continuous R) + have hq₃ := Lp.coeFn_smul (Complex.I*(h 1:ℂ)) (smoothFiniteAxisLp hq.continuous R) + fin_cases j + · exact hq₀ + · exact hq₁ + · exact hq₂.trans (hq₀.mono fun t ht => by simp [ht,smul_eq_mul]) + · exact hq₃.trans (hq₀.mono fun t ht => by simp [ht,smul_eq_mul]) + +lemma sourceAngularLpJet_coefficient {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) (h : TorusModes) : + cylinderJetCoefficient R (sourceAngularLpJet hf a b R) h= + smoothAxisModeJet (sourceAngularCoefficient_smooth hf a b h) R h := by + apply PiLp.ext + intro j + apply Lp.ext + filter_upwards [cylinderCoefficientLp_ae (sourceAngularLpJet hf a b R j) h, + Measure.ae_ae_of_ae_prod (sourceAngularLpJet_ae hf a b R j), + smoothAxisModeJet_ae (sourceAngularCoefficient_smooth hf a b h) R h j, + ae_restrict_mem measurableSet_Ioc] with t ht₁ ht₂ ht₃ htm + change cylinderCoefficientLp (sourceAngularLpJet hf a b R j) h t=_ + rw [ht₁,ht₃] + calc + cylinderCoefficient (sourceAngularLpJet hf a b R j) h t= + mFourierCoeff (fun θ => sourceAngularJet f a b j (t,θ)) h := by + unfold cylinderCoefficient mFourierCoeff + apply integral_congr_ae + filter_upwards [ht₂] with θ hθ + rw [hθ] + _=_ := sourceAngularJet_fourier hf a b R h (Ioc_subset_Icc_self htm) j + +theorem sourceAngularLpJet_graph (s : Fin 3 → ℝ) {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) : + (sourceAngularLpJet hf a b R, + (smoothCollarTrace s b hf,smoothCollarTrace s (a*R+b) hf))∈cylinderSobolevGraph s R := by + let q : TorusModes → smoothComplexAxis := fun h => + ⟨sourceAngularCoefficient f a b h,sourceAngularCoefficient_smooth hf a b h⟩ + apply cylinderGraph_of_smooth_coefficients s R _ q + (sourceAngularLpJet_coefficient hf a b R) _ _ + · intro h + rw [smoothCollarTrace_fst] + simp [q,sourceAngularCoefficient] + · intro h + rw [smoothCollarTrace_fst] + rfl + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix +open scoped ENNReal + +lemma hasDerivAt_outer_of_strict_comp {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {F : ℝ → E} {g : ℝ → ℝ} {x d : ℝ} {v : E} + (hg : HasStrictDerivAt g d x) (hd : d≠0) + (hF : HasDerivAt (F ∘ g) v x) : HasDerivAt F (d⁻¹ • v) (g x) := by + let q := hg.localInverse g d x hd + have hq : q (g x)=x := hg.eventually_left_inverse hd |>.self_of_nhds + have h := hF.scomp_of_eq (g x) (hg.to_localInverse hd).hasDerivAt hq.symm + apply h.congr_of_eventuallyEq + filter_upwards [hg.eventually_right_inverse hd] with y hy + exact congrArg F hy.symm + +lemma hasStrictDerivAt_faceRayAngle (w : ℝ) (j : Fin 4) (b : ℝ) : + HasStrictDerivAt (faceRayAngle w j) (faceRayDensity w j b) b := + hasStrictDerivAt_of_hasDerivAt_of_continuousAt + (Filter.Eventually.of_forall fun x => hasDerivAt_faceRayAngle w j x) + (continuous_faceRayDensity w j).continuousAt + +lemma faceRayDensity_pos' {w : ℝ} (hw : 0 dsimp [faceRayDensity] <;> positivity + +lemma torusDirectionalDerivative_of_face (F : UnitAddTorus (Fin 2) → ℂ) + (θ : UnitAddTorus (Fin 2)) (k : Fin 2) {w : ℝ} (hw : 0 F (θ+torusCoordinateShift k + (faceRayAngle w i u-faceRayAngle w i b))) v b) : + torusDirectionalDerivative F k θ=(faceRayDensity w i b)⁻¹ • v := by + have h := hasDerivAt_outer_of_strict_comp (F:=fun t => F (θ+torusCoordinateShift k t)) + ((hasStrictDerivAt_faceRayAngle w i b).sub_const (faceRayAngle w i b)) + (faceRayDensity_pos' hw i b).ne' hF + simpa only [sub_self,torusDirectionalDerivative_eq] using h.deriv + +lemma hasDerivAt_coordinate_update (x : Fin 3 → ℝ) (k : Fin 3) : + HasDerivAt (fun u => Function.update x k u) (Pi.single k 1) (x k) := by + apply hasDerivAt_pi.mpr + intro l + by_cases hl : l=k + · subst l + simp only [Function.update_self,Pi.single_eq_same] + exact hasDerivAt_id' (x k) + · simpa [Function.update_of_ne hl,Pi.single_apply,hl] using hasDerivAt_const (x k) (x l) + +lemma physicalTestCovector_update {f : (Fin 3 → ℝ) → ℝ} {point : Fin 3 → ℝ} + (hf : DifferentiableAt ℝ f point) (k : Fin 3) : + HasDerivAt (fun u => f (Function.update point k u)) (physicalTestCovector f point k) (point k) := by + simpa only [Function.update_eq_self,Function.comp_def,physicalTestCovector] using + hf.hasFDerivAt.comp_hasDerivAt_of_eq (point k) (hasDerivAt_coordinate_update point k) + (Function.update_eq_self k point).symm + +lemma sourceAngularTest_face0 {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b t : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : a*t+b=x 0) (h1 : |x 1|<1) (h2 : |x 2|≤1) : + torusDirectionalDerivative (fun θ => sourceAngularTest f a b (t,θ)) 0 + (torusAngles (sourceFaceAngles i j x))= + (faceRayDensity 1 i (x 1))⁻¹ • + (physicalTestCovector (f ∘ sourceCollarPiece i j) x 1 : ℂ) := by + apply torusDirectionalDerivative_of_face _ _ _ (by norm_num) i (x 1) + have hd := (physicalTestCovector_update + ((hf.differentiable (by simp)).differentiableAt.comp x + (sourceCollarPiece_hasFDeriv i j x).differentiableAt) 1).ofReal_comp + apply hd.congr_of_eventuallyEq + have hn : ∀ᶠ u in 𝓝 (x 1), |u|<1 := + (isOpen_lt continuous_abs continuous_const).mem_nhds h1 + filter_upwards [hn] with u hu + dsimp only [Function.comp_def,sourceAngularTest] + congr 1 + rw [sourceFaceAngles_torus,hx] + have he : ![((faceRayAngle 1 i (x 1):ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j (x 2):ℝ):UnitAddCircle)]+ + torusCoordinateShift 0 (faceRayAngle 1 i u-faceRayAngle 1 i (x 1))= + ![((faceRayAngle 1 i u:ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j (x 2):ℝ):UnitAddCircle)] := by + ext k + fin_cases k <;> simp [torusCoordinateShift] + rw [he,sourceAngular_face _ _ _ _ _ hu.le h2] + congr 2 + ext k + fin_cases k <;> simp + +lemma sourceAngularTest_face1 {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b t : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : a*t+b=x 0) (h1 : |x 1|≤1) (h2 : |x 2|<1) : + torusDirectionalDerivative (fun θ => sourceAngularTest f a b (t,θ)) 1 + (torusAngles (sourceFaceAngles i j x))= + (faceRayDensity sourceRadialWidth j (x 2))⁻¹ • + (physicalTestCovector (f ∘ sourceCollarPiece i j) x 2 : ℂ) := by + apply torusDirectionalDerivative_of_face _ _ _ (by norm_num [sourceRadialWidth,sourceHole]) j (x 2) + have hd := (physicalTestCovector_update + ((hf.differentiable (by simp)).differentiableAt.comp x + (sourceCollarPiece_hasFDeriv i j x).differentiableAt) 2).ofReal_comp + apply hd.congr_of_eventuallyEq + have hn : ∀ᶠ u in 𝓝 (x 2), |u|<1 := + (isOpen_lt continuous_abs continuous_const).mem_nhds h2 + filter_upwards [hn] with u hu + dsimp only [Function.comp_def,sourceAngularTest] + congr 1 + rw [sourceFaceAngles_torus,hx] + have he : ![((faceRayAngle 1 i (x 1):ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j (x 2):ℝ):UnitAddCircle)]+ + torusCoordinateShift 1 (faceRayAngle sourceRadialWidth j u-faceRayAngle sourceRadialWidth j (x 2))= + ![((faceRayAngle 1 i (x 1):ℝ):UnitAddCircle), + ((faceRayAngle sourceRadialWidth j u:ℝ):UnitAddCircle)] := by + ext k + fin_cases k <;> simp [torusCoordinateShift] + rw [he,sourceAngular_face _ _ _ _ _ h1 hu.le] + congr 2 + ext k + fin_cases k <;> simp + +lemma sourceAngularAxial_face {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b t : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : a*t+b=x 0) (h1 : |x 1|≤1) (h2 : |x 2|≤1) : + sourceAngularAxial f a b t (torusAngles (sourceFaceAngles i j x))= + (a*physicalTestCovector (f ∘ sourceCollarPiece i j) x 0 : ℝ) := by + have hd := (physicalTestCovector_update + ((hf.differentiable (by simp)).differentiableAt.comp x + (sourceCollarPiece_hasFDeriv i j x).differentiableAt) 0).comp_of_eq t + (((hasDerivAt_id t).const_mul a).add_const b) hx.symm + have he : (fun u => f (sourceAngularCollar (a*u+b) (torusAngles (sourceFaceAngles i j x))))= + (fun u => (f ∘ sourceCollarPiece i j) (Function.update x 0 (a*u+b))) := by + funext u + dsimp only [Function.comp_def] + rw [sourceFaceAngles_torus,sourceAngular_face _ _ _ _ _ h1 h2] + congr 2 + ext k + fin_cases k <;> simp + unfold sourceAngularAxial + rw [he] + change ((deriv ((fun u => (f ∘ sourceCollarPiece i j) (Function.update x 0 u)) ∘ + (fun u => a*u+b)) t : ℝ) : ℂ)=_ + have hd' := hd.deriv + simpa only [id_eq,mul_one,mul_comm] using congrArg Complex.ofReal hd' + +theorem sourceAngularJet_face {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b t : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : a*t+b=x 0) (h1 : |x 1|<1) (h2 : |x 2|<1) : + (fun k : Fin 3 => (sourceAngularJet f a b k.succ + (t,torusAngles (sourceFaceAngles i j x))).re)= + ![a*physicalTestCovector (f ∘ sourceCollarPiece i j) x 0, + physicalTestCovector (f ∘ sourceCollarPiece i j) x 1/(2*Real.pi*faceRayDensity 1 i (x 1)), + physicalTestCovector (f ∘ sourceCollarPiece i j) x 2/(2*Real.pi*faceRayDensity sourceRadialWidth j (x 2))] := by + ext k + fin_cases k + · change (sourceAngularAxial f a b t (torusAngles (sourceFaceAngles i j x))).re=_ + exact congrArg Complex.re (sourceAngularAxial_face hf a b t i j hx h1.le h2.le) + · change (torusDirectionalDerivative (fun θ => sourceAngularTest f a b (t,θ)) 0 + (torusAngles (sourceFaceAngles i j x))/(2*Real.pi)).re= + physicalTestCovector (f ∘ sourceCollarPiece i j) x 1/(2*Real.pi*faceRayDensity 1 i (x 1)) + rw [sourceAngularTest_face0 hf a b t i j hx h1 h2.le] + rw [Complex.real_smul] + norm_cast + ring + · change (torusDirectionalDerivative (fun θ => sourceAngularTest f a b (t,θ)) 1 + (torusAngles (sourceFaceAngles i j x))/(2*Real.pi)).re= + physicalTestCovector (f ∘ sourceCollarPiece i j) x 2/(2*Real.pi*faceRayDensity sourceRadialWidth j (x 2)) + rw [sourceAngularTest_face1 hf a b t i j hx h1.le h2] + rw [Complex.real_smul] + norm_cast + ring + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularJet.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..e5e6e6a4ea78762ee8ac61ab98f6ce14402481df --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularJet.lean @@ -0,0 +1,185 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.EndPoissonJets +import OAI.Analysis.Conductivity.Sources.AngularCoefficient +import OAI.Analysis.Conductivity.Geometry.TorusDirectionalDerivative + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal +local instance angularJetMeasureSpaceUnitAddCircle : MeasureSpace UnitAddCircle := ⟨AddCircle.haarAddCircle⟩ +local instance angularJetIsProbabilityMeasure : IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma measurable_torusDirectionalDerivative_joint + {f : ℝ × UnitAddTorus (Fin 2) → ℂ} (hf : Continuous f) (j : Fin 2) : + Measurable (fun z : ℝ × UnitAddTorus (Fin 2) => + torusDirectionalDerivative (fun θ => f (z.1,θ)) j z.2) := by + let F : ℝ × TorusRealPlane → ℂ := fun z => f (z.1,torusRealProjection z.2) + have hc : Continuous F := hf.comp + (continuous_fst.prodMk (continuous_torusRealProjection.comp continuous_snd)) + have hm := (measurable_lineDeriv (𝕜:=ℝ) hc (v:=(0,Pi.single j 1))).comp + (measurable_fst.prodMk (measurable_torusRealRepresentative.comp measurable_snd)) + convert hm using 1 + funext z + unfold torusDirectionalDerivative lineDeriv + congr 2 + ext t + simp [F] + +def sourceAngularTest (f : (Fin 3 → ℝ) → ℝ) (a b : ℝ) + (z : ℝ × UnitAddTorus (Fin 2)) : ℂ := + (f (sourceAngularCollar (a*z.1+b) z.2) : ℂ) + +lemma continuous_sourceAngularTest {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b : ℝ) : + Continuous (sourceAngularTest f a b) := + Complex.continuous_ofReal.comp (hf.continuous.comp + (contDiff_sourceAngularPolynomial_joint.continuous.comp + ((continuous_const.mul continuous_fst |>.add continuous_const).prodMk + (continuous_sourceRayCoordinates.comp continuous_snd)))) + +theorem sourceAngularTest_lipschitz {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) : + ∃ K : ℝ≥0, ∀ t∈Icc (0:ℝ) R, ∀ j u θ, + ‖sourceAngularTest f a b (t,θ+torusCoordinateShift j u)- + sourceAngularTest f a b (t,θ)‖≤(K:ℝ)*|u| := by + let G : ℝ × (Fin 4 → ℝ) → ℂ := fun z => + (f (sourceAngularPolynomial (a*z.1+b) z.2) : ℂ) + have hG : ContDiff ℝ (↑(⊤ : ℕ∞)) G := + Complex.ofRealCLM.contDiff.comp (hf.comp + (contDiff_sourceAngularPolynomial_joint.comp + ((contDiff_const.mul contDiff_fst |>.add contDiff_const).prodMk contDiff_snd))) + obtain ⟨K,hK⟩ := hG.contDiffOn.exists_lipschitzOnWith (by simp) + ((convex_Icc (0:ℝ) R).prod (convex_Icc _ _)) + (isCompact_Icc.prod (isCompact_Icc (a:=(fun _ : Fin 4 => (-2:ℝ))) (b:=fun _ => (2:ℝ)))) + refine ⟨K*⟨sourceRayConstant,sourceRayConstant_nonneg⟩,?_⟩ + intro t ht j u θ + have hh := hK.dist_le_mul (t,sourceRayCoordinates (θ+torusCoordinateShift j u)) + ⟨ht,sourceRayCoordinates_mem _⟩ (t,sourceRayCoordinates θ) ⟨ht,sourceRayCoordinates_mem _⟩ + rw [Prod.dist_eq,dist_self,max_eq_right (dist_nonneg),dist_eq_norm,dist_eq_norm] at hh + apply hh.trans + change _ ≤ (K:ℝ)*sourceRayConstant*|u| + simpa only [mul_assoc] using + mul_le_mul_of_nonneg_left (sourceRayCoordinates_difference j u θ) K.coe_nonneg + +def sourceAngularJet (f : (Fin 3 → ℝ) → ℝ) (a b : ℝ) + (j : Fin 4) (z : ℝ × UnitAddTorus (Fin 2)) : ℂ := + ![sourceAngularTest f a b z,sourceAngularAxial f a b z.1 z.2, + torusDirectionalDerivative (fun θ => sourceAngularTest f a b (z.1,θ)) 0 z.2/(2*Real.pi), + torusDirectionalDerivative (fun θ => sourceAngularTest f a b (z.1,θ)) 1 z.2/(2*Real.pi)] j + +lemma measurable_sourceAngularJet {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b : ℝ) (j : Fin 4) : + Measurable (sourceAngularJet f a b j) := by + fin_cases j + · exact (continuous_sourceAngularTest hf a b).measurable + · exact (continuous_sourceAngularAxial hf a b).measurable + · exact (measurable_torusDirectionalDerivative_joint (continuous_sourceAngularTest hf a b) 0).div_const _ + · exact (measurable_torusDirectionalDerivative_joint (continuous_sourceAngularTest hf a b) 1).div_const _ + +end ScalarConductivity + +end +end + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped ENNReal NNReal +local instance angularJetFiniteCylinderMeasureSpace : MeasureSpace UnitAddCircle := + ⟨AddCircle.haarAddCircle⟩ +local instance angularJetFiniteCylinderProbabilityMeasure : + IsProbabilityMeasure (volume : Measure UnitAddCircle) := + inferInstanceAs (IsProbabilityMeasure AddCircle.haarAddCircle) + +lemma finiteCylinder_ae_mem (R : ℝ) : + ∀ᵐ z ∂(FiniteAxisMeasure R).prod (volume : Measure (UnitAddTorus (Fin 2))), + z.1∈Icc (0:ℝ) R := + Measure.quasiMeasurePreserving_fst.ae + ((ae_restrict_mem measurableSet_Ioc).mono fun _ ht => Ioc_subset_Icc_self ht) + +lemma continuous_memLp_finiteCylinder {f : ℝ × UnitAddTorus (Fin 2) → ℂ} + (hf : Continuous f) (R : ℝ) : + MemLp f 2 ((FiniteAxisMeasure R).prod volume) := by + obtain ⟨C,hC⟩ := ((isCompact_Icc (a:=(0:ℝ)) (b:=R)).prod + (isCompact_univ : IsCompact (univ : Set (UnitAddTorus (Fin 2))))).exists_bound_of_continuousOn hf.continuousOn + apply MemLp.of_bound hf.aestronglyMeasurable C + filter_upwards [finiteCylinder_ae_mem R] with z hz + exact hC z ⟨hz,mem_univ _⟩ + +lemma sourceAngularJet_memLp {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) (j : Fin 4) : + MemLp (sourceAngularJet f a b j) 2 ((FiniteAxisMeasure R).prod volume) := by + obtain ⟨K,hK⟩ := sourceAngularTest_lipschitz hf a b R + have hang (k : Fin 2) : MemLp (fun z : ℝ × UnitAddTorus (Fin 2) => + torusDirectionalDerivative (fun θ => sourceAngularTest f a b (z.1,θ)) k z.2/(2*Real.pi)) + 2 ((FiniteAxisMeasure R).prod volume) := by + apply MemLp.of_bound + (((measurable_torusDirectionalDerivative_joint (continuous_sourceAngularTest hf a b) k).div_const _).aestronglyMeasurable) ((2:ℝ)*K/‖(2*Real.pi:ℂ)‖) + filter_upwards [finiteCylinder_ae_mem R] with z hz + rw [norm_div] + apply div_le_div_of_nonneg_right _ (norm_nonneg _) + exact torusDirectionalDerivative_norm + ⟨fun θ => sourceAngularTest f a b (z.1,θ), + (continuous_sourceAngularTest hf a b).comp (continuous_const.prodMk continuous_id)⟩ + K (hK z.1 hz) k z.2 + fin_cases j + · exact continuous_memLp_finiteCylinder (continuous_sourceAngularTest hf a b) R + · exact continuous_memLp_finiteCylinder (continuous_sourceAngularAxial hf a b) R + · exact hang 0 + · exact hang 1 + +def sourceAngularLpJet {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) : FiniteCylinderJets R := + WithLp.toLp 2 (fun j => (sourceAngularJet_memLp hf a b R j).toLp _) + +lemma sourceAngularLpJet_ae {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) (j : Fin 4) : + sourceAngularLpJet hf a b R j =ᵐ[(FiniteAxisMeasure R).prod volume] + sourceAngularJet f a b j := + (sourceAngularJet_memLp hf a b R j).coeFn_toLp + +lemma mFourierCoeff_div_const (f : UnitAddTorus (Fin 2) → ℂ) (h : TorusModes) (c : ℂ) : + mFourierCoeff (fun θ => f θ/c) h=mFourierCoeff f h/c := by + simp only [mFourierCoeff,smul_eq_mul,←mul_div_assoc,integral_div] + +lemma torusDirectionalDerivative_scaled_fourier (f : C(UnitAddTorus (Fin 2),ℂ)) (K : ℝ≥0) + (hLip : ∀ j t θ, ‖f (θ+torusCoordinateShift j t)-f θ‖≤(K:ℝ)*|t|) + (j : Fin 2) (h : TorusModes) : + mFourierCoeff (fun θ => torusDirectionalDerivative f j θ/(2*Real.pi)) h= + (Complex.I*(h j))*mFourierCoeff f h := by + rw [mFourierCoeff_div_const,torusDirectionalDerivative_fourier f K hLip] + have hp : (Real.pi:ℂ)≠0 := Complex.ofReal_ne_zero.mpr Real.pi_ne_zero + field_simp + +lemma sourceAngularJet_fourier {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) (a b R : ℝ) (h : TorusModes) + {t : ℝ} (ht : t∈Icc (0:ℝ) R) (j : Fin 4) : + mFourierCoeff (fun θ => sourceAngularJet f a b j (t,θ)) h= + ![sourceAngularCoefficient f a b h t,deriv (sourceAngularCoefficient f a b h) t, + (Complex.I*(h 0))*sourceAngularCoefficient f a b h t, + (Complex.I*(h 1))*sourceAngularCoefficient f a b h t] j := by + obtain ⟨K,hK⟩ := sourceAngularTest_lipschitz hf a b R + have ha (k : Fin 2) := torusDirectionalDerivative_scaled_fourier + ⟨fun θ => sourceAngularTest f a b (t,θ), + (continuous_sourceAngularTest hf a b).comp (continuous_const.prodMk continuous_id)⟩ + K (hK t ht) k h + fin_cases j + · rfl + · exact (sourceAngularCoefficient_hasDerivAt hf a b h t).deriv.symm + · exact ha 0 + · exact ha 1 + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularLocalizedSources.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularLocalizedSources.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b6f68b0b42804372d517792070fff090452caea --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularLocalizedSources.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.AngularPeriodization +import OAI.Analysis.Conductivity.Fourier.SmoothAngularCutoff + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set Filter Topology Real MeasureTheory + +def angularCutoff (T : ℝ) (x : Coord3) : ℝ := periodCutoff T (x 1)*periodCutoff T (x 2) + +lemma angularCutoff_smooth (T : ℝ) : ContDiff ℝ (↑(⊤:ℕ∞)) (angularCutoff T) := + ((periodCutoff_smooth T).comp (by fun_prop)).mul + ((periodCutoff_smooth T).comp (by fun_prop)) + +lemma angularCutoff_support {T : ℝ} (hT : 0 hx (by simp [angularCutoff,h]) + have hb : periodCutoff T (x 2)≠0 := fun h => hx (by simp [angularCutoff,h]) + exact ⟨periodCutoff_support hT (subset_tsupport _ ha),periodCutoff_support hT (subset_tsupport _ hb)⟩ + +lemma angularCutoff_finsum {T : ℝ} (hT : 0 periodCutoff T (x 1+T*n) + let b : ℤ → ℝ := fun n => periodCutoff T (x 2+T*n) + have ha : (∑ᶠ n,a n)=1 := periodCutoff_finsum hT _ + have hb : (∑ᶠ n,b n)=1 := periodCutoff_finsum hT _ + have hf : Function.HasFiniteSupport (fun z : ℤ×ℤ => a z.1*b z.2) := by + apply ((hasFiniteSupport_of_finsum_eq_one ha).prod (hasFiniteSupport_of_finsum_eq_one hb)).subset + intro z hz + exact ⟨fun h => hz (by simp [h]),fun h => hz (by simp [h])⟩ + change (∑ᶠ n : Fin 2 → ℤ,a (n 0)*b (n 1))=1 + have he := finsum_comp_equiv (MeasurableEquiv.finTwoArrow (α:=ℤ)).symm.toEquiv + (f:=fun n : Fin 2 → ℤ => a (n 0)*b (n 1)) + change (∑ᶠ z : ℤ×ℤ,a z.1*b z.2)=(∑ᶠ n : Fin 2 → ℤ,a (n 0)*b (n 1)) at he + rw [←he,finsum_curry _ hf] + simp_rw [←mul_finsum,hb,mul_one] + exact ha + +lemma angularCutoff_periodize {T : ℝ} (hT : 0 angularCutoff T x*f x)=f := by + funext x + unfold angularPeriodize + have he : (fun n : Fin 2 → ℤ => angularCutoff T (x+angularShift T n)*f (x+angularShift T n))= + (fun n => angularCutoff T (x+angularShift T n)*f x) := by + funext n; rw [hp n x] + rw [he] + rw [←finsum_mul,angularCutoff_finsum hT,one_mul] + +lemma angularCutoff_compact_support {T a b : ℝ} (hT : 0 angularCutoff T x*f x)⊆Icc ![a,-T,-T] ![b,T,T] := by + intro x hx + have h0 := hf ((tsupport_mul_subset_right (f:=angularCutoff T) (g:=f)) hx) + have hθ := angularCutoff_support hT ((tsupport_mul_subset_left (f:=angularCutoff T) (g:=f)) hx) + constructor <;> intro i <;> fin_cases i + · exact h0.1 + · exact hθ.1.1 + · exact hθ.2.1 + · exact h0.2 + · exact hθ.1.2 + · exact hθ.2.2 + +lemma angularCutoff_compact {T a b : ℝ} (hT : 0 angularCutoff T x*f x) := + isCompact_Icc.of_isClosed_subset (isClosed_tsupport _) (angularCutoff_compact_support hT hf) + +lemma AngularPeriodic.coordinate_one {T : ℝ} {f : Coord3 → ℝ} (hp : AngularPeriodic T f) + (t z : ℝ) : Function.Periodic (fun y => f ![t,y,z]) T := by + intro y + have hh := hp ![1,0] ![t,y,z] + have he : ![t,y,z]+angularShift T ![1,0]=![t,y+T,z] := by + ext i; fin_cases i <;> simp [angularShift] + rw [he] at hh + exact hh + +lemma AngularPeriodic.coordinate_two {T : ℝ} {f : Coord3 → ℝ} (hp : AngularPeriodic T f) + (t y : ℝ) : Function.Periodic (fun z => f ![t,y,z]) T := by + intro z + have hh := hp ![0,1] ![t,y,z] + have he : ![t,y,z]+angularShift T ![0,1]=![t,y,z+T] := by + ext i; fin_cases i <;> simp [angularShift] + rw [he] at hh + exact hh + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularPhysicalTest.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularPhysicalTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c4f7f8d092b2f77083705248bba0afb49a9dc7a --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularPhysicalTest.lean @@ -0,0 +1,51 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.AngularGraph + +namespace OAI + +section + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus Matrix +open scoped ENNReal + +theorem sourceAngularJet_attachedCovector {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) {a : ℝ} (ha : a≠0) (b : ℝ) (i j : Fin 4) + {x : Fin 3 → ℝ} (hx : x∈sourceCollarOpenBox) : + (fun k : Fin 3 => (sourceAngularJet f a⁻¹ b k.succ + (a*(x 0-b),torusAngles (sourceFaceAngles i j x))).re)= + attachedFlatTestCovector f a i j x := by + have h1 : |x 1|<1 := by exact hx.2.1 + have h2 : |x 2|<1 := by exact hx.2.2 + have ht : a⁻¹*(a*(x 0-b))+b=x 0 := by field_simp; ring + rw [sourceAngularJet_face hf a⁻¹ b (a*(x 0-b)) i j ht h1 h2] + have h := attachedFlatTestCovector_chain f ha i j (sourceCollarOpenBox_subset hx) + ((hf.differentiable (by simp)).differentiableAt) + have h0 := congrFun h 0 + have h1' := congrFun h 1 + have h2' := congrFun h 2 + simp only [sourceFaceAngleMatrix,endAxialMatrix,mulVec_diagonal] at h0 h1' h2' + change physicalTestCovector (f ∘ sourceCollarPiece i j) x 0= + 1*(a*attachedFlatTestCovector f a i j x 0) at h0 + change physicalTestCovector (f ∘ sourceCollarPiece i j) x 1= + (2*Real.pi*faceRayDensity 1 i (x 1))*(1*attachedFlatTestCovector f a i j x 1) at h1' + change physicalTestCovector (f ∘ sourceCollarPiece i j) x 2= + (2*Real.pi*faceRayDensity sourceRadialWidth j (x 2))*(1*attachedFlatTestCovector f a i j x 2) at h2' + ext k + fin_cases k + · change a⁻¹*physicalTestCovector (f ∘ sourceCollarPiece i j) x 0=_ + rw [h0]; field_simp [ha]; rfl + · change physicalTestCovector (f ∘ sourceCollarPiece i j) x 1/(2*Real.pi*faceRayDensity 1 i (x 1))=_ + rw [h1'] + field_simp [(faceRayDensity_pos' (w:=1) (by norm_num) i (x 1)).ne',Real.pi_ne_zero]; rfl + · change physicalTestCovector (f ∘ sourceCollarPiece i j) x 2/(2*Real.pi*faceRayDensity sourceRadialWidth j (x 2))=_ + rw [h2'] + field_simp [(faceRayDensity_pos' (w:=sourceRadialWidth) (by norm_num [sourceRadialWidth,sourceHole]) j (x 2)).ne',Real.pi_ne_zero]; rfl + +end ScalarConductivity + +end +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/AngularTrace.lean b/lean/OAI/Analysis/Conductivity/Sources/AngularTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..16461e904ce1befbb7fe58f7b6a5d372289e58ec --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/AngularTrace.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.Conductivity.Fourier.RectangularTorusAtlas +import OAI.Analysis.Conductivity.Geometry.TorusLipschitzTrace +import OAI.Analysis.Conductivity.Fourier.RectangularRayTrace + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory Filter Topology UnitAddTorus +open scoped NNReal ENNReal + +lemma rectangularRay_abs {w : ℝ} (hw : 0 -2) (fun _ => 2) + +lemma sourceRayCoordinates_mem (x : UnitAddTorus (Fin 2)) : sourceRayCoordinates x∈sourceRayBox := by + have hw : 0 (abs_le.mp (h i)).1,fun i => (abs_le.mp (h i)).2⟩ + +lemma continuous_sourceRayCoordinates : Continuous sourceRayCoordinates := by + have hc1 := continuous_rectangularRay (w:=1) (by norm_num) (by norm_num) + have hcw := continuous_rectangularRay (w:=sourceRadialWidth) + (by norm_num [sourceRadialWidth,sourceHole]) (by norm_num [sourceRadialWidth,sourceHole]) + apply continuous_pi + intro i + fin_cases i <;> dsimp [sourceRayCoordinates] + · exact (continuous_apply (0 : Fin 2)).comp (hc1.comp (continuous_apply (0 : Fin 2))) + · exact (continuous_apply (1 : Fin 2)).comp (hc1.comp (continuous_apply (0 : Fin 2))) + · exact (continuous_apply (0 : Fin 2)).comp (hcw.comp (continuous_apply (1 : Fin 2))) + · exact (continuous_apply (1 : Fin 2)).comp (hcw.comp (continuous_apply (1 : Fin 2))) + +def sourceRayConstant : ℝ := 6*(2*Real.pi)+(2+4/sourceRadialWidth)*(2*Real.pi) + +lemma sourceRayConstant_nonneg : 0≤ sourceRayConstant := by + have hw : 0 dsimp [sourceAngularPolynomial] <;> fun_prop + +lemma continuous_sourceAngularCollar (t : ℝ) : Continuous (sourceAngularCollar t) := + (contDiff_sourceAngularPolynomial t).continuous.comp continuous_sourceRayCoordinates + +theorem sourceAngularTrace_summable (s : Fin 3 → ℝ) (t : ℝ) {f : (Fin 3 → ℝ) → ℝ} + (hf : ContDiff ℝ (↑(⊤ : ℕ∞)) f) : + Summable (fun h : Fin 2 → ℤ => torusRate s h* + ‖mFourierCoeff (fun x => (f (sourceAngularCollar t x):ℂ)) h‖^2) := by + let G : (Fin 4 → ℝ) → ℂ := fun z => (f (sourceAngularPolynomial t z):ℂ) + have hG : ContDiff ℝ (↑(⊤ : ℕ∞)) G := by + exact Complex.ofRealCLM.contDiff.comp (hf.comp (contDiff_sourceAngularPolynomial t)) + obtain ⟨K,hK⟩ := hG.contDiffOn.exists_lipschitzOnWith (by simp) + (convex_Icc _ _) isCompact_Icc + let F : C(UnitAddTorus (Fin 2),ℂ) := + ⟨fun x => G (sourceRayCoordinates x),hG.continuous.comp continuous_sourceRayCoordinates⟩ + have hdiff (j : Fin 2) (u : ℝ) (x : UnitAddTorus (Fin 2)) : + ‖F (x+torusCoordinateShift j u)-F x‖≤((K:ℝ)*sourceRayConstant)*|u| := by + have hh := hK.dist_le_mul _ (sourceRayCoordinates_mem (x+torusCoordinateShift j u)) + _ (sourceRayCoordinates_mem x) + rw [dist_eq_norm,dist_eq_norm] at hh + apply hh.trans + simpa only [mul_assoc] using mul_le_mul_of_nonneg_left (sourceRayCoordinates_difference j u x) K.coe_nonneg + exact torus_coordinate_trace_summable s F (fun _ => (K:ℝ)*sourceRayConstant) + (fun _ => mul_nonneg K.coe_nonneg sourceRayConstant_nonneg) hdiff + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/BranchCombine.lean b/lean/OAI/Analysis/Conductivity/Sources/BranchCombine.lean new file mode 100644 index 0000000000000000000000000000000000000000..8b6714fbf0b325e3b1d30ec580424a949bd85fad --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/BranchCombine.lean @@ -0,0 +1,235 @@ +import Mathlib +import OAI.Analysis.Conductivity.Sources.CopiedScalarCoefficient + +namespace OAI + +noncomputable section + +namespace ScalarConductivity + +section +open Set MeasureTheory Filter Topology +attribute [local instance] Classical.propDecidable + +lemma source_child_push_inner_zero (v w : H10) + (hv : SourceSupported v.val) (hw : SourceSupported w.val) : + inner ℝ (weakGradientL (childZeroTransport 0 v).val) + (weakGradientL (childZeroTransport 1 w).val)=0 := by + rw [L2.inner_def] + apply (integral_congr_ae ?_).trans (integral_zero _ _) + filter_upwards [weakGradientL_apply_ae (childZeroTransport 0 v).val, + weakGradientL_apply_ae (childZeroTransport 1 w).val, + childH10Transport_support 0 v hv,childH10Transport_support 1 w hw] with x h0 h1 hs0 hs1 + rw [h0,h1] + have hd := source_child_closed_disjoint (show (0:Fin 2)≠1 by decide) + by_cases hx : x∈sourceChildEuclidean (actualChildSign 0) '' closure sourceDomain + · have hn := Set.disjoint_left.mp hd hx + have he := congrArg jetGradient (hs1 hn) + change weakGradient (childZeroTransport 1 w).val x=0 at he + rw [he,inner_zero_right] + · have he := congrArg jetGradient (hs0 hx) + change weakGradient (childZeroTransport 0 v).val x=0 at he + rw [he,inner_zero_left] + +def sourceBranchCombine (α β : ℝ) (v w : H10) : H10 := + α • childZeroTransport 0 v+β • childZeroTransport 1 w + +lemma sourceBranchCombine_support {v w : H10} (hv : SourceSupported v.val) + (hw : SourceSupported w.val) (α β : ℝ) : + SourceSupported (sourceBranchCombine α β v w).val := + ((hv.child 0).smul α).add ((hw.child 1).smul β) + +private lemma norm_smul_sq_real {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] + (a : ℝ) (x : E) : ‖a • x‖ ^ 2 = a ^ 2 * ‖x‖ ^ 2 := by + rw [norm_smul, Real.norm_eq_abs, mul_pow, sq_abs] + +lemma sourceBranchCombine_energy (α β : ℝ) (v w : H10) + (hv : SourceSupported v.val) (hw : SourceSupported w.val) : + ‖weakGradientL (sourceBranchCombine α β v w).val‖^2= + sourceScale*(α^2*‖weakGradientL v.val‖^2+β^2*‖weakGradientL w.val‖^2) := by + have horth : inner ℝ (α • weakGradientL (childZeroTransport 0 v).val) + (β • weakGradientL (childZeroTransport 1 w).val) = 0 := by + rw [real_inner_smul_left, real_inner_smul_right, + source_child_push_inner_zero v w hv hw, mul_zero, mul_zero] + have hnorm := norm_add_sq_eq_norm_sq_add_norm_sq_real horth + simp only [← pow_two] at hnorm + change ‖weakGradientL (α • (childZeroTransport 0 v).val+β • (childZeroTransport 1 w).val)‖^2=_ + rw [map_add,map_smul,map_smul,hnorm] + rw [norm_smul_sq_real, norm_smul_sq_real] + change α^2*‖weakGradientL (childH10Transport 0 v)‖^2+β^2*‖weakGradientL (childH10Transport 1 w)‖^2=_ + calc + _ = α^2*(sourceScale*‖weakGradientL v.val‖^2)+β^2*(sourceScale*‖weakGradientL w.val‖^2) := + congrArg₂ (fun r t : ℝ => α^2*r+β^2*t) (child_gradient_norm_sq 0 v) (child_gradient_norm_sq 1 w) + _ = _ := by ring + +lemma sourceBranchCombine_bound (α β : ℝ) (v w : H10) + (hv : SourceSupported v.val) (hw : SourceSupported w.val) {M N : ℝ} + (hM : 0≤M) (hN : 0≤N) + (hvM : ∀ᵐ x∂ballMeasure,abs (weakValue v.val x) ≤ M) + (hwN : ∀ᵐ x∂ballMeasure,abs (weakValue w.val x) ≤ N) : + ∀ᵐ x∂ballMeasure,abs (weakValue (sourceBranchCombine α β v w).val x) ≤ max (abs α * M) (abs β * N) := by + filter_upwards [weakValue_add (α • (childZeroTransport 0 v).val) (β • (childZeroTransport 1 w).val), + weakValue_smul α (childZeroTransport 0 v).val,weakValue_smul β (childZeroTransport 1 w).val, + childH10Transport_support 0 v hv,childH10Transport_support 1 w hw, + childH10Transport_bounded 0 v hM hvM,childH10Transport_bounded 1 w hN hwN] with x ha hα hβ hs0 hs1 hb0 hb1 + change abs (weakValue (α • (childZeroTransport 0 v).val+β • (childZeroTransport 1 w).val) x) ≤ _ + rw [ha,Pi.add_apply,hα,hβ,Pi.smul_apply,Pi.smul_apply,smul_eq_mul,smul_eq_mul] + by_cases hx : x∈sourceChildEuclidean (actualChildSign 0) '' closure sourceDomain + · have hn := Set.disjoint_left.mp (source_child_closed_disjoint (show (0:Fin 2)≠1 by decide)) hx + have he := congrArg jetValue (hs1 hn) + change weakValue (childZeroTransport 1 w).val x=0 at he + rw [he,mul_zero,add_zero,abs_mul] + exact (mul_le_mul_of_nonneg_left hb0 (abs_nonneg α)).trans (le_max_left _ _) + · have he := congrArg jetValue (hs0 hx) + change weakValue (childZeroTransport 0 v).val x=0 at he + rw [he,mul_zero,zero_add,abs_mul] + exact (mul_le_mul_of_nonneg_left hb1 (abs_nonneg β)).trans (le_max_right _ _) + +local instance branchCombinePushAddCommGroup : AddCommGroup (H10 →L[ℝ] H10) := + ContinuousLinearMap.addCommGroup (R := ℝ) (R₂ := ℝ) (M := H10) (M₂ := H10) + +def sourceAveragePush : H10 →L[ℝ] H10 := + (2*sourceScale)⁻¹ • (childZeroTransport 0+childZeroTransport 1) + +def sourceDifferencePush : H10 →L[ℝ] H10 := + sourceScale⁻¹ • (childZeroTransport 0-childZeroTransport 1) + +def sourceAveragePull : H1 →L[ℝ] H1 := (1/2:ℝ) • (childH1Pullback 0+childH1Pullback 1) +def sourceDifferencePull : H1 →L[ℝ] H1 := childH1Pullback 0-childH1Pullback 1 + +def sourceRatio : ℝ := (2*sourceScale)⁻¹ + +lemma sourceAveragePush_eq (v : H10) : sourceAveragePush v=sourceBranchCombine sourceRatio sourceRatio v v := by + change sourceRatio • (childZeroTransport 0 v+childZeroTransport 1 v)=_ + exact smul_add _ _ _ + +lemma sourceDifferencePush_eq (v : H10) : sourceDifferencePush v=sourceBranchCombine sourceScale⁻¹ (-(sourceScale⁻¹)) v v := by + change sourceScale⁻¹ • (childZeroTransport 0 v-childZeroTransport 1 v)=_ + change sourceScale⁻¹ • (childZeroTransport 0 v-childZeroTransport 1 v)=sourceScale⁻¹ • childZeroTransport 0 v+(-(sourceScale⁻¹)) • childZeroTransport 1 v + norm_num [sourceScale] + module + +lemma sourceRatio_pos : 0 simpa only [Finset.sum_empty] using sourceSupported_zero + | @insert a s ha ih => + rw [Finset.sum_insert ha] + exact (hf a (Finset.mem_insert_self a s)).add (ih (fun i hi => hf i (Finset.mem_insert_of_mem hi))) + +lemma sourceSupported_limit {u : ℕ → H1} {w : H1} (hu : Tendsto u atTop (𝓝 w)) + (hs : ∀ n,SourceSupported (u n)) : SourceSupported w := by + apply h1_limit_ae_closed hu (fun x => {z : JetFiber | x∉closure sourceDomain → z=0}) _ hs + intro x + by_cases hx : x∈closure sourceDomain + · simpa only [hx,not_true_eq_false,false_implies,Set.ofPred_true] using isClosed_univ (X:=JetFiber) + · simpa only [hx,not_false_eq_true,true_implies] using (isClosed_eq continuous_id continuous_const : IsClosed {z : JetFiber | z = 0}) + +lemma sourceSupported_collar {u : H1} (hu : SourceSupported u) : + ∀ᵐ x∂ballMeasure, (5/2:ℝ)<‖x‖ → weakValue u x=0 ∧ weakGradient u x=0 := by + filter_upwards [(sourceSupported_iff u).mp hu] with x hx hn + apply hx + intro hd + have hd' := sourceClosure_subset_ball hd + simp only [Metric.mem_ball,dist_zero_right] at hd' + linarith + +def sourceAverageIter (v : H10) : ℕ → H10 + | 0 => v + | n+1 => sourceAveragePush (sourceAverageIter v n) + +lemma sourceAverageIter_support {v : H10} (hv : SourceSupported v.val) (n : ℕ) : + SourceSupported (sourceAverageIter v n).val := by + induction n with + | zero => exact hv + | succ n ih => exact sourceAveragePush_support ih + +lemma sourceAverageIter_energy {v : H10} (hv : SourceSupported v.val) (n : ℕ) : + ‖weakGradientL (sourceAverageIter v n).val‖^2=sourceRatio^n*‖weakGradientL v.val‖^2 := by + induction n with + | zero => simp [sourceAverageIter] + | succ n ih => + change ‖weakGradientL (sourceAveragePush (sourceAverageIter v n)).val‖^2=_ + rw [sourceAveragePush_energy (sourceAverageIter_support hv n),ih,pow_succ] + ring + +lemma sourceAverageIter_bound {v : H10} (hv : SourceSupported v.val) {M : ℝ} (hM : 0≤M) + (hb : ∀ᵐ x∂ballMeasure,abs (weakValue v.val x)≤M) (n : ℕ) : + ∀ᵐ x∂ballMeasure,abs (weakValue (sourceAverageIter v n).val x)≤M*sourceRatio^n := by + induction n with + | zero => simpa [sourceAverageIter] using hb + | succ n ih => + have hh := sourceAveragePush_bound (sourceAverageIter_support hv n) + (mul_nonneg hM (pow_nonneg sourceRatio_pos.le n)) ih + have he : sourceRatio*(M*sourceRatio^n)=M*sourceRatio^(n+1) := by rw [pow_succ]; ring + simpa only [he,sourceAverageIter] using hh + +theorem sourceAverage_series_exists (v : H10) (hv : SourceSupported v.val) {M : ℝ} (hM : 0≤M) + (hb : ∀ᵐ x∂ballMeasure,abs (weakValue v.val x)≤M) : + ∃ w : H10,SourceSupported w.val ∧ + Tendsto (fun N => ∑ n∈Finset.range N,sourceAverageIter v n) atTop (𝓝 w) ∧ + (∀ᵐ x∂ballMeasure,abs (weakValue w.val x)≤(M+‖weakGradientL v.val‖^2)/(1-sourceRatio)) := by + let K := M+‖weakGradientL v.val‖^2 + have hK : 0≤K := add_nonneg hM (sq_nonneg _) + obtain ⟨w,hw,ht,hb',hs⟩ := geometric_source_series (fun n => (sourceAverageIter v n).val) + hK sourceRatio_pos.le sourceRatio_lt_one (fun n => (sourceAverageIter v n).property) + (fun n => (sourceAverageIter_bound hv hM hb n).mono (fun x hx => hx.trans + (mul_le_mul_of_nonneg_right (le_add_of_nonneg_right (sq_nonneg _)) (pow_nonneg sourceRatio_pos.le n)))) + (fun n => by rw [sourceAverageIter_energy hv n]; dsimp [K]; nlinarith [pow_nonneg sourceRatio_pos.le n]) + (5/2) (fun n => sourceSupported_collar (sourceAverageIter_support hv n)) + refine ⟨⟨w,hw⟩,sourceSupported_limit ht (fun n => SourceSupported.sum _ _ (fun i _ => sourceAverageIter_support hv i)),?_,hb'⟩ + apply tendsto_subtype_rng.mpr + simpa only [Submodule.coe_sum] using ht + +end ScalarConductivity + +end + +end OAI diff --git a/lean/OAI/Analysis/Conductivity/Sources/CentralWeightedVariational.lean b/lean/OAI/Analysis/Conductivity/Sources/CentralWeightedVariational.lean new file mode 100644 index 0000000000000000000000000000000000000000..9743ff7e12b5a45e326cdce7ac869b61487cfa13 --- /dev/null +++ b/lean/OAI/Analysis/Conductivity/Sources/CentralWeightedVariational.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.Conductivity.Variational.CentralVariational + +namespace OAI + +noncomputable section +namespace ScalarConductivity +open Set MeasureTheory + +variable {V G : Type*} [NormedAddCommGroup V] [InnerProductSpace ℝ V] + [NormedAddCommGroup G] [InnerProductSpace ℝ G] + +def centralWeightedForm {ι : Type*} (κ : ℝ) (w : ι → ℝ) (D : V →L[ℝ] G) + (T : Fin 3 → V →L[ℝ] spectralTraceGraph w) : V →L[ℝ] V →L[ℝ] ℝ := + (((innerSL ℝ).comp D).flip.comp D).flip + κ • ∑ i : Fin 3, + (((innerSL ℝ).comp ((spectralGraphWeight w).comp (T i))).flip.comp + ((spectralGraphWeight w).comp (T i))).flip + +lemma centralWeightedForm_apply {ι : Type*} (κ : ℝ) (w : ι → ℝ) (D : V →L[ℝ] G) + (T : Fin 3 → V →L[ℝ] spectralTraceGraph w) (u v : V) : + centralWeightedForm κ w D T u v=inner ℝ (D u) (D v)+ + κ*(∑ i : Fin 3,inner ℝ (spectralGraphWeight w (T i u)) (spectralGraphWeight w (T i v))) := by + simp [centralWeightedForm,smul_eq_mul] + +theorem central_variational_exists_graph_weighted [CompleteSpace V] {ι : Type*} [Zero ι] + (κ : ℝ) (hκ : 1≤κ) (w : ι → ℝ) (D : V →L[ℝ] G) + (T : Fin 3 → V →L[ℝ] spectralTraceGraph w) + (M : V →L[ℝ] ℝ) (oneV : V) (hM : M oneV=1) (hD : D oneV=0) + (hT : ∀ i,spectralGraphWeight w (T i oneV)=0) + (havg : ∀ i,spectralGraphMean w (T i oneV)=1) + {C : ℝ} (hC : 0 sq_nonneg _) + have hb : ‖D u.val‖^2+∑ i : Fin 3,‖spectralGraphWeight w (T i u.val)‖^2≤B u.val u.val := by + simp only [B,centralWeightedForm_apply,real_inner_self_eq_norm_sq] + nlinarith [mul_le_mul_of_nonneg_right hκ hn] + have hh := (hP u).trans (mul_le_mul_of_nonneg_left hb hC.le) + calc + _=‖u‖^2/C := by ring + _≤B u.val u.val := (div_le_iff₀ hC).mpr (by simpa only [mul_comm] using hh) + obtain ⟨p,hp,hfull,huniq⟩ := solve_form_mod_constants B M F oneV hM hF hB hB' hcoer + refine ⟨p,hp,?_,?_⟩ + · intro v + exact (centralWeightedForm_apply κ w D T p v).symm.trans ((hfull v).trans (hFa v)) + · intro q hq + apply huniq q + intro v + exact (centralWeightedForm_apply κ w D T q v).trans ((hq v).trans (hFa v).symm) + +end ScalarConductivity + +end + +end OAI