import Euler.PacketKnownTermBounds import Euler.PacketKnownTermFields import Euler.PacketCylinderFieldUnique import Mathlib.Algebra.BigOperators.Option /-! Actual mean and high forcing estimates at one fixed radius, uniform in the packet grade. -/ /-! ## From `Euler/PacketKnownTermSums.lean` The text of `Euler/PacketKnownTermSums.lean`, folded into this file, which was its only importer. -/ section /-! Exact mean and high forcing sums. Periodic BA/BC terms are absent from the mean force, and the angle-constant BB term is absent from the high force. Every summand is the genuine continuous cylinder L² path already constructed. -/ noncomputable section namespace EulerPacketCylinderField open Set MeasureTheory Finset EulerSmoothLimit EulerPacketPointJets EulerPacketProfileRecursion variable {P T : ℝ} [Fact (0 < P)] theorem angleMean_congr_at (P : ℝ) (f g : VectorField) (t : ℝ) (x : Space) (h : ∀ θ : ℝ, f (t,(x,θ)) = g (t,(x,θ))) (θ : ℝ) : angleMean P f (t,(x,θ)) = angleMean P g (t,(x,θ)) := by unfold angleMean congr 1 apply intervalIntegral.integral_congr intro s _ exact h s theorem angleMean_neg_finsetSum {ι : Type*} (s : Finset ι) (raw : ι → VectorField) (G : ∀ i, Field P T (raw i)) (t : Icc (0 : ℝ) T) (x : Space) (θ : ℝ) : angleMean P (fun z => -(∑ i ∈ s, raw i z)) (t,(x,θ)) = -(∑ i ∈ s, angleMean P (raw i) (t,(x,θ))) := by unfold angleMean rw [intervalIntegral.integral_neg, intervalIntegral.integral_finsetSum (fun i _ => ((G i).raw_angle_continuous t x).intervalIntegrable 0 P)] simp only [smul_neg, Finset.smul_sum] variable {O : Operators} {p : ℕ} {a : ℕ → Profile} theorem PrefixFields.knownForce_decomposition (F : PrefixFields P T p a) (hp : 2 ≤ p) (hc : (a 0).corrector = 0) (hB₁ : (a 1).mean = 0) (hA : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, inner ℝ (O.normal (t,(x,θ))) ((a i).high (t,(x,θ))) = 0) (hB : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, (a i).mean (t,(x,θ)) = (a i).mean (t,(x,0))) (t : Icc (0 : ℝ) T) (x : Space) (θ : ℝ) : EulerPacketProfileRecursion.knownForce O p a (t,(x,θ)) = -(∑ q ∈ knownTermIndices p, q.1.raw O p a q.2.1 q.2.2 (t,(x,θ))) := knownForce_eq_term_sum O p hp a hc hB₁ (t,(x,θ)) (fun i => KnownPiece.high_tangent hA i t x θ) (fun i => (F.meanPiece_angleIndependent hB i t x).angular θ) variable (F : PrefixFields P T p a) (C : CoefficientData P T O) (hp : 2 ≤ p) (hT : 0 < T) {corrector_t : VectorField} (Ct : Field P T corrector_t) (hCt : TimeDerivative hT.le (F.corrector (p-1) (by omega)) Ct) (pressure : Field P T (pressureGradient (a (p-1)).highPressure)) (hc : (a 0).corrector = 0) (hB₁ : (a 1).mean = 0) (hA : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, inner ℝ (O.normal (t,(x,θ))) ((a i).high (t,(x,θ))) = 0) (hB : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, (a i).mean (t,(x,θ)) = (a i).mean (t,(x,0))) include C hp hT Ct hCt pressure hc hB₁ hA hB in theorem PrefixFields.meanForce_decomposition (t : Icc (0 : ℝ) T) (x : Space) (θ : ℝ) : EulerPacketProfileRecursion.meanForce O p a (t,(x,θ)) = -(∑ q ∈ knownTermIndices p, q.1.meanRaw O p a q.2.1 q.2.2 (t,(x,θ))) := by calc _ = angleMean P (fun z => -(∑ q ∈ knownTermIndices p, q.1.raw O p a q.2.1 q.2.2 z)) (t,(x,θ)) := by unfold EulerPacketProfileRecursion.meanForce rw [C.period_eq] exact angleMean_congr_at P _ _ t x (F.knownForce_decomposition hp hc hB₁ hA hB t x) θ _ = -(∑ q ∈ knownTermIndices p, angleMean P (q.1.raw O p a q.2.1 q.2.2) (t,(x,θ))) := angleMean_neg_finsetSum (knownTermIndices p) (fun q => q.1.raw O p a q.2.1 q.2.2) (fun q => F.termField C (by omega) hT Ct hCt pressure q.1 q.2.1 q.2.2) t x θ _ = _ := by congr 1 apply sum_congr rfl intro q _ rw [KnownTerm.meanRaw_eq F C hB, C.period_eq] include C hp hT Ct hCt pressure hc hB₁ hA hB in theorem PrefixFields.highForce_decomposition (t : Icc (0 : ℝ) T) (x : Space) (θ : ℝ) : EulerPacketProfileRecursion.highForce O p a (t,(x,θ)) = -(∑ q ∈ knownTermIndices p, q.1.highRaw O p a q.2.1 q.2.2 (t,(x,θ))) - fastAdvection (O.normal (t,(x,θ))) (slicedJet O.interval (meanResult O p a).1 (t,(x,θ))) (slicedJet O.interval (a 1).high (t,(x,θ))) := by have he : (∑ q ∈ knownTermIndices p, q.1.highRaw O p a q.2.1 q.2.2 (t,(x,θ))) = (∑ q ∈ knownTermIndices p, q.1.raw O p a q.2.1 q.2.2 (t,(x,θ))) - (∑ q ∈ knownTermIndices p, q.1.meanRaw O p a q.2.1 q.2.2 (t,(x,θ))) := by rw [← sum_sub_distrib] apply sum_congr rfl intro q _ rw [KnownTerm.highRaw_eq F C hB, KnownTerm.meanRaw_eq F C hB] unfold EulerPacketProfileRecursion.highForce rw [F.knownForce_decomposition hp hc hB₁ hA hB, F.meanForce_decomposition C hp hT Ct hCt pressure hc hB₁ hA hB, he] abel end EulerPacketCylinderField end end noncomputable section namespace EulerPacketCylinderField.PrefixBound open Set Finset EulerSmoothLimit EulerPacketPointJets EulerPacketProfileRecursion EulerPacketTimeProfile EulerPacketShiftArithmetic EulerParameterWordGevrey variable {P T : ℝ} [Fact (0 < P)] {p : ℕ} {a : ℕ → Profile} {F : PrefixFields P T p a} {O : Operators} {C : CoefficientData P T O} (hp : 2 ≤ p) (hT : 0 < T) {corrector_t : VectorField} (Ct : Field P T corrector_t) (hCt : TimeDerivative hT.le (F.corrector (p-1) (by omega)) Ct) (pressure : Field P T (pressureGradient (a (p-1)).highPressure)) {S : Scales (Icc (0 : ℝ) T)} {R : ℝ} (BF : PrefixBound F hT.le S R) (BC : CoefficientBudget C) (hCtBound : (Ct.normalized hT.le (S.high (p-1)) (S.high_pos (p-1))).WordBound 6 R 1 (highShift (p-1))) (hPressureBound : (pressure.normalized hT.le (S.high (p-1)) (S.high_pos (p-1))).WordBound 6 R 1 (highShift (p-1))) (hR : 1 ≤ R) (hRc : sobolevCoefficientRadius (Fin 4) BC.Rc ≤ R) (hcost : BC.termCost ≤ R) (hc : (a 0).corrector = 0) (hB₁ : (a 1).mean = 0) (hA : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, inner ℝ (O.normal (t,(x,θ))) ((a i).high (t,(x,θ))) = 0) (hB : ∀ i, i < p → ∀ (t : Icc (0 : ℝ) T) x θ, (a i).mean (t,(x,θ)) = (a i).mean (t,(x,0))) include BF hCtBound hPressureBound hR hRc hcost hc hB₁ hA hB theorem meanForce_bound : ((F.meanForce C (by omega) hT Ct hCt pressure).normalized hT.le (S.mean p) (S.mean_pos p)).WordBound 6 R 1 (meanForceShift p) := by let f : KnownTermIndex → VectorField := fun q => q.1.meanRaw O p a q.2.1 q.2.2 let W : ∀ q, Field P T (f q) := fun q => F.meanTermField C (by omega) hT Ct hCt pressure q.1 q.2.1 q.2.2 let G := Field.finsetSum (knownTermIndices p) f W have hd : 0 < meanForceShift p := by have h := force_shift_dominates_grade p hp; omega have hcount : (knownTermIndices p).card ≤ (meanForceShift p)^2 := by have hc0 := knownTermIndices_card_room p have hc1 := (padded_grade_count p hp).1 omega have hs : (G.normalized hT.le (S.mean p) (S.mean_pos p)).WordBound 6 R 1 (meanForceShift p) := Field.wordBound_normalized_finset_absorb hT.le (S.mean p) (S.mean_pos p) (knownTermIndices p) f W 6 R BC.termCost (meanForceShift p) (fun q => q.1.meanBudgetShift p q.2.1 q.2.2) hR BC.termCost_nonneg hcost hd hcount (fun q _ => q.1.meanBudgetShift_lt p q.2.1 q.2.2 hp) (fun q _ => mean_term_bound hp hT Ct hCt pressure BF BC hCtBound hPressureBound (zero_le_one.trans hR) hRc q.1 q.2.1 q.2.2) exact (hs.normalized_neg hT.le).normalized_of_raw_eq (F.meanForce C (by omega) hT Ct hCt pressure) hT.le (S.mean p) (S.mean_pos p) (fun t x θ => by simpa only [Pi.neg_apply,Finset.sum_apply,f] using F.meanForce_decomposition C hp hT Ct hCt pressure hc hB₁ hA hB t x θ) theorem highForce_bound (newMean : Field P T (meanResult O p a).1) (hnew : (newMean.normalized hT.le (S.mean p) (S.mean_pos p)).WordBound 6 R 1 (meanShift p)) : ((F.highForce C hp hT Ct hCt pressure newMean).normalized hT.le (S.high p) (S.high_pos p)).WordBound 6 R 1 (highForceShift p) := by let A := SpatialJetField.fastAdvection C.normal (SpatialJetField.ofField O.interval newMean) (SpatialJetField.ofField O.interval (F.high 1 (by omega))) have hA0 : (A.normalized hT.le (S.high p) (S.high_pos p)).WordBound 6 R BC.fastCost (meanShift p+highShift 1+1) := BC.fast_bound (SpatialJetField.ofField O.interval newMean) (SpatialJetField.ofField O.interval (F.high 1 (by omega))) hT.le (S.mean p) (S.high 1) (S.high p) (S.mean_pos p) (S.high_pos 1) (S.high_pos p) hnew (BF.high 1 (by omega) (by omega)) (zero_le_one.trans hR) hRc (fun t => (S.fast_mean_high_bound p 1 p (by omega) (by omega) rfl t).le) have hA1 := hA0.mono_amplitude (zero_le_one.trans hR) BC.fastCost_le let f : Option KnownTermIndex → VectorField := fun q => match q with | none => fun z => fastAdvection (O.normal z) (slicedJet O.interval (meanResult O p a).1 z) (slicedJet O.interval (a 1).high z) | some q => q.1.highRaw O p a q.2.1 q.2.2 let W : ∀ q, Field P T (f q) := fun q => match q with | none => A | some q => F.highTermField C (by omega) hT Ct hCt pressure q.1 q.2.1 q.2.2 let shift : Option KnownTermIndex → ℕ := fun q => match q with | none => meanShift p+highShift 1+1 | some q => q.1.budgetShift p q.2.1 q.2.2 let G := Field.finsetSum (knownTermIndices p).insertNone f W have hd : 0 < highForceShift p := by have h := force_shift_dominates_grade p hp; omega have hcount : (knownTermIndices p).insertNone.card ≤ (highForceShift p)^2 := by rw [card_insertNone] exact (knownTermIndices_card_room p).trans (padded_grade_count p hp).2 have hshift : ∀ q ∈ (knownTermIndices p).insertNone, shift q < highForceShift p := by intro q _ cases q with | none => change meanShift p+highShift 1+1 < highForceShift p have hh := fast_mean_high_room p 1 p hp (by omega) rfl omega | some q => exact q.1.budgetShift_lt_high p q.2.1 q.2.2 hp have hblocks : ∀ q ∈ (knownTermIndices p).insertNone, ((W q).normalized hT.le (S.high p) (S.high_pos p)).WordBound 6 R BC.termCost (shift q) := by intro q _ cases q with | none => exact hA1 | some q => exact high_term_bound hp hT Ct hCt pressure BF BC hCtBound hPressureBound (zero_le_one.trans hR) hRc q.1 q.2.1 q.2.2 have hs : (G.normalized hT.le (S.high p) (S.high_pos p)).WordBound 6 R 1 (highForceShift p) := Field.wordBound_normalized_finset_absorb hT.le (S.high p) (S.high_pos p) (knownTermIndices p).insertNone f W 6 R BC.termCost (highForceShift p) shift hR BC.termCost_nonneg hcost hd hcount hshift hblocks apply (hs.normalized_neg hT.le).normalized_of_raw_eq (F.highForce C hp hT Ct hCt pressure newMean) hT.le (S.high p) (S.high_pos p) intro t x θ simp only [Pi.neg_apply,Finset.sum_apply] change highForce O p a (t,(x,θ)) = -(∑ q ∈ (knownTermIndices p).insertNone, f q (t,(x,θ))) rw [F.highForce_decomposition C hp hT Ct hCt pressure hc hB₁ hA hB,Finset.sum_insertNone] dsimp only [f] abel end EulerPacketCylinderField.PrefixBound