import NavierStokes.JointResidualLimits import NavierStokes.DiagonalResidual import Mathlib.Analysis.SpecialFunctions.Pow.Continuity import NavierStokes.PhysicalStageBounds /-! ## From `NavierStokes/WholeDomainCompactBounds.lean` The text of `NavierStokes/WholeDomainCompactBounds.lean`, folded into this file, which was its only importer. -/ section /-! # Uniform bounds on the common finite-stage domain Local endpoint estimates are upgraded on a fixed compact set without changing the domain with the requested derivative order. The compactness argument uses the actual derivatives, and allows a different local constant at every point. -/ noncomputable section namespace NavierStokes.WholeDomainStageBounds open Set Filter Function ProblemStatement open scoped Topology ContDiff BigOperators section CompactBounds variable {D V : Type*} [NormedAddCommGroup D] [NormedSpace ℝ D] [NormedAddCommGroup V] [NormedSpace ℝ V] end CompactBounds section LocalRates variable {D V : Type*} [NormedAddCommGroup D] [NormedSpace ℝ D] [NormedAddCommGroup V] [NormedSpace ℝ V] /-- A finite jet limit at a positive limiting scale gives every power rate. -/ theorem rate_of_jet_limit {l : Filter D} {f : D → V} {q : D → ℝ} {m : ℕ} {J : D [×m]→L[ℝ] V} {q₀ : ℝ} (hJ : Tendsto (iteratedFDeriv ℝ m f) l (𝓝 J)) (hq : Tendsto q l (𝓝 q₀)) (hq₀ : 0 < q₀) (r : ℝ) : DiagonalResidual.JetRate l q f m r := by have hb := (hJ.norm.mul (hq.rpow_const (Or.inl hq₀.ne'))).eventually (gt_mem_nhds (lt_add_one (‖J‖ * q₀ ^ (-r)))) refine ⟨‖J‖ * q₀ ^ (-r) + 1, by positivity, ?_⟩ filter_upwards [hb, hq.eventually (lt_mem_nhds hq₀)] with x hx hqx have he : (‖iteratedFDeriv ℝ m f x‖ * q x ^ (-r)) * q x ^ r = ‖iteratedFDeriv ℝ m f x‖ := by rw [mul_assoc, ← Real.rpow_add hqx, neg_add_cancel, Real.rpow_zero, mul_one] exact he ▸ mul_le_mul_of_nonneg_right hx.le (Real.rpow_nonneg hqx.le r) end LocalRates /-- Smooth one-sided velocity and pressure extensions extend the actual residual, including the derivatives occurring in its definition. -/ noncomputable def residualExtension {u : VelocityField} {p : PressureField} {x : Space} (U : JointResidualLimits.OneSidedExtension u x) (P : JointResidualLimits.OneSidedExtension p x) : JointResidualLimits.OneSidedExtension (fun w => navierStokesResidual u p w.1 w.2) x where value := fun w => navierStokesResidual U.value P.value w.1 w.2 domain := U.domain ∩ P.domain isOpen := U.isOpen.inter P.isOpen mem := ⟨U.mem, P.mem⟩ smooth := ResidualRegularity.contDiffOn_residual (U.isOpen.inter P.isOpen) (U.smooth.mono inter_subset_left) (P.smooth.mono inter_subset_right) agrees := by intro w hw have hU : U.value =ᶠ[𝓝 w] u := Filter.eventuallyEq_of_mem ((U.isOpen.inter (SpacetimeEndpoint.openPast_isOpen 1)).mem_nhds ⟨hw.1.1, hw.2⟩) U.agrees have hP : P.value =ᶠ[𝓝 w] p := Filter.eventuallyEq_of_mem ((P.isOpen.inter (SpacetimeEndpoint.openPast_isOpen 1)).mem_nhds ⟨hw.1.2, hw.2⟩) P.agrees exact (ResidualRegularity.residual_eventuallyEq hU hP).self_of_nhds end NavierStokes.WholeDomainStageBounds end end noncomputable section namespace NavierStokes.WholeDomainStageBounds open Set Filter Function ProblemStatement open scoped Topology ContDiff BigOperators open PhysicalWaveSum end NavierStokes.WholeDomainStageBounds