Navier–Stokes: the Lean blow-up proof, cleaned up together
OpenAI's 2026 Lean proofs of blowup for forced Navier–Stokes and Euler, rerun by others, not refereed, no ruling from Clay; cleaned up together: more readable, faster to build

| 1 | import NavierStokes.ParticularCopyBounds |
| 2 | import NavierStokes.ParticularWaveAssembly |
| 3 | import NavierStokes.WaveEnvelopeTransport |
| 4 | import NavierStokes.ScaledTangentTransport |
| 5 | |
| 6 | /-! |
| 7 | # Modal inputs for the actual residual inverse |
| 8 | |
| 9 | The frame is the selected `PhaseConstruction.frame`. Its modal energy |
| 10 | estimate is derived from `FrameData.energy_bound`, including every nonzero |
| 11 | harmonic. The source is differentiated along the genuine shifted copy path; |
| 12 | geometric separation identifies its grouped Gaussian at every integration |
| 13 | time. All finite-jet constants precede the external label and lattice copy. |
| 14 | -/ |
| 15 | |
| 16 | noncomputable section |
| 17 | |
| 18 | namespace NavierStokes.ActualParticularControl |
| 19 | |
| 20 | open Set Function Filter WeightedClasses PhaseJetBounds PrimaryPulseBounds |
| 21 | open CommonCoverSolve TorusInverse ParticularWaveBounds LabelSumBounds |
| 22 | open scoped Topology ContDiff InnerProductSpace BigOperators |
| 23 | |
| 24 | abbrev Plane := TorusInverse.Plane |
| 25 | |
| 26 | |
| 27 | private theorem nat_le_infty (n : ℕ) : (n : WithTop ℕ∞) ≤ ∞ := |
| 28 | ENat.natCast_le_of_coe_top_le_withTop le_rfl n |
| 29 | |
| 30 | section SelectedFrame |
| 31 | |
| 32 | variable {ι : Type*} {D : PhaseJetBounds.Domain ι PhaseCalculus.Slow} |
| 33 | |
| 34 | /-- Actual frame jets, directly from the base and phase data of the selected |
| 35 | construction. No regularity of a solved amplitude is an input. -/ |
| 36 | theorem selected_frame_jets (F : PhaseConstruction D) : |
| 37 | FrameJets (D.slot F.V F.openV) F.frame := |
| 38 | F.phase.frameData_jets_of_phase_comparison D F.V F.openV |
| 39 | F.lam F.c0 F.u F.L F.viscosity F.B F.K F.slope F.error |
| 40 | F.baseF F.baseG F.r_pos F.b_pos F.one_le_M F.constants F.epsilon_ne |
| 41 | F.radius F.slot F.lam_bound F.c0_bound F.u_bound F.rate_bound F.viscosity_bound |
| 42 | F.B_bound F.K_unit F.slope_bound F.error_small F.normal_close |
| 43 | |
| 44 | /-- The extra `j²` damping is dissipative. The same Gaussian rate and |
| 45 | error constant work for all nonzero harmonics, without a bound on `j`. -/ |
| 46 | theorem selected_energy (F : PhaseConstruction D) (i : ι) |
| 47 | {p : PhaseCalculus.Slow} (hp : p ∈ D.carrier i) {v : ℝ} |
| 48 | (hv : v ∈ Icc 0 (F.L i)) {j : ℤ} (hj : j ≠ 0) (z : PrimaryODE.State) : |
| 49 | ⟪z, (F.frame i).coefficient j (p,v) z⟫_ℝ ≤ |
| 50 | (GaussianEnvelope.referenceRate (F.lam i) (F.u i) (F.L i) v + |
| 51 | (F.E + 4 * F.C) / D.scale i) * ‖z‖^2 := by |
| 52 | have hlam : 0 ≤ (F.frame i).eigenvalue (p,v) := |
| 53 | ViscousPropagator.referenceEigenvalue_nonneg (F.lam_pos i).le _ _ _ |
| 54 | have hvisc : 0 ≤ (F.frame i).viscosity (p,v) := |
| 55 | mul_nonneg (F.viscosity_nonneg i) (sq_nonneg _) |
| 56 | exact (F.frame i).energy_bound (p,v) hj hlam hvisc |
| 57 | (F.damping_error i p hp v hv) (F.modal_errors i p hp v hv) z |
| 58 | |
| 59 | /-- The same selected frame satisfies its actual slot kinematics. -/ |
| 60 | theorem selected_kinematics (F : PhaseConstruction D) (i : ι) |
| 61 | {p : PhaseCalculus.Slow} (hp : p ∈ D.carrier i) : |
| 62 | (F.frame i).Kinematics p (Icc 0 (F.L i)) := by |
| 63 | have htail := (normal_range_of_reference_close F.B F.K F.slope F.error |
| 64 | F.b_pos F.one_le_M F.B_bound F.K_unit F.slope_bound F.error_small F.normal_close).1 |
| 65 | apply PrimaryODE.FrameData.ofNormalLocal_kinematics |
| 66 | · intro v _ |
| 67 | exact PhaseCalculus.hasDerivAt_phaseNormal_slot _ _ _ _ _ _ _ _ _ (F.epsilon_ne i) |
| 68 | (((F.baseF.smooth i).contDiffAt ((D.isOpen i).mem_nhds hp)).differentiableAt (by simp)) |
| 69 | (((F.baseG.smooth i).contDiffAt ((D.isOpen i).mem_nhds hp)).differentiableAt (by simp)) |
| 70 | · intro v hv |
| 71 | exact norm_pos_iff.mp (F.b_pos.trans_le (htail i (p,v) ⟨hp,F.interval i hv⟩)) |
| 72 | · intro v _ |
| 73 | exact mul_ne_zero (abs_pos.mp (F.b_pos.trans_le (F.c0_bound i).1)) |
| 74 | (by positivity : Real.sqrt (1 + PulseGrowth.slotMagnitude (F.u i) (F.L i) v^2) ≠ 0) |
| 75 | · intro v _ |
| 76 | exact PrimaryODE.hasDerivAt_referenceProfile (F.c0 i) (F.u i) (F.L i) v |
| 77 | |
| 78 | /-- A finite harmonic range introduces only a finite coefficient constant; |
| 79 | the index type may already include every spatial label and band. -/ |
| 80 | theorem frame_coefficient_jets_bounded |
| 81 | {Q : Type} [NormedAddCommGroup Q] [NormedSpace ℝ Q] |
| 82 | {U : PhaseJetBounds.Domain ι (Q × ℝ)} {d : ι → PrimaryODE.FrameData Q} |
| 83 | (hd : FrameJets U d) (j : ι → ℤ) {J : ℝ} (hJ : 1 ≤ J) |
| 84 | (hj : ∀ i, |(j i : ℝ)| ≤ J) : |
| 85 | PolynomialJets U (fun i => (d i).coefficient (j i)) := by |
| 86 | obtain ⟨h11, h12, h21, h22⟩ := hd.modal_errors |
| 87 | have hjets : PolynomialJets U (fun i _ => (j i : ℝ)^2) := |
| 88 | PolynomialJets.const_uniform _ (one_le_pow₀ hJ) (fun i => by |
| 89 | rw [Real.norm_eq_abs, abs_of_nonneg (sq_nonneg _)] |
| 90 | simpa only [sq_abs] using pow_le_pow_left₀ (abs_nonneg _) (hj i) 2) |
| 91 | have hν := hjets.mul hd.viscosity |
| 92 | have hh := (((((hd.eigenvalue.sub hν).add h11).smul |
| 93 | (PolynomialJets.const_fixed (GrowingMode.modalOperator 0 0 1 0 0 0))).add |
| 94 | (h12.smul (PolynomialJets.const_fixed (GrowingMode.modalOperator 0 0 0 1 0 0)))).add |
| 95 | (h21.smul (PolynomialJets.const_fixed (GrowingMode.modalOperator 0 0 0 0 1 0)))).add |
| 96 | (((hd.eigenvalue.neg.sub hν).add h22).smul |
| 97 | (PolynomialJets.const_fixed (GrowingMode.modalOperator 0 0 0 0 0 1))) |
| 98 | apply hh.congr |
| 99 | intro i z _ |
| 100 | ext w k |
| 101 | fin_cases k <;> simp [PrimaryODE.FrameData.coefficient, PrimaryODE.FrameData.damping, |
| 102 | GrowingMode.modalOperator] |
| 103 | |
| 104 | end SelectedFrame |
| 105 | |
| 106 | section Projection |
| 107 | |
| 108 | variable {ι : Type*} {Q : Type} [NormedAddCommGroup Q] [NormedSpace ℝ Q] |
| 109 | {U : PhaseJetBounds.Domain ι (Q × ℝ)} {d : ι → PrimaryODE.FrameData Q} |
| 110 | |
| 111 | /-- The source projection is built from its three actual frame columns. -/ |
| 112 | theorem frame_forcingLinear_jets (hd : FrameJets U d) : |
| 113 | PolynomialJets U (fun i => frameForcingLinear (d i)) := by |
| 114 | have hc (k : Fin 3) := |
| 115 | (hd.forcing (PolynomialJets.const_fixed (ProblemStatement.coordinateVector k))).clm |
| 116 | (ContinuousLinearMap.smulRightL ℝ ProblemStatement.Space PrimaryODE.State |
| 117 | (EuclideanSpace.proj k)) |
| 118 | apply ((hc 0).add (hc 1) |>.add (hc 2)).congr |
| 119 | intro i z hz |
| 120 | apply ContinuousLinearMap.ext |
| 121 | intro f |
| 122 | change f 0 • (d i).forcing (fun _ => ProblemStatement.coordinateVector 0) z + |
| 123 | f 1 • (d i).forcing (fun _ => ProblemStatement.coordinateVector 1) z + |
| 124 | f 2 • (d i).forcing (fun _ => ProblemStatement.coordinateVector 2) z = |
| 125 | (d i).forcing (fun _ => f) z |
| 126 | symm |
| 127 | simpa only [Fin.sum_univ_three] using |
| 128 | ParticularWaveBounds.forcing_eq_columns (d i) (fun _ => f) z |
| 129 | |
| 130 | end Projection |
| 131 | |
| 132 | section FrameReindex |
| 133 | |
| 134 | variable {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 135 | |
| 136 | /-- The transverse copy coordinate is not a slow variable of the selected |
| 137 | frame. The linear map also permits forgetting the auxiliary angle. -/ |
| 138 | noncomputable def nativeFrame (d : PrimaryODE.FrameData PhaseCalculus.Slow) |
| 139 | (χ : P →L[ℝ] PhaseCalculus.Slow) : PrimaryODE.FrameData (P × ℝ) := |
| 140 | PrimaryCopyBridge.reindex d (fun q => χ q.1) |
| 141 | |
| 142 | noncomputable def frameArgument (χ : P →L[ℝ] PhaseCalculus.Slow) : |
| 143 | ((P × Plane) × ℝ) →L[ℝ] (PhaseCalculus.Slow × ℝ) := |
| 144 | (χ.comp ((ContinuousLinearMap.fst ℝ P Plane).comp |
| 145 | (ContinuousLinearMap.fst ℝ (P × Plane) ℝ))).prod |
| 146 | (ContinuousLinearMap.snd ℝ (P × Plane) ℝ) |
| 147 | |
| 148 | @[simp] theorem frameArgument_apply (χ : P →L[ℝ] PhaseCalculus.Slow) |
| 149 | (z : (P × Plane) × ℝ) : frameArgument χ z = (χ z.1.1,z.2) := rfl |
| 150 | |
| 151 | @[simp] theorem copyFrame_coefficient (d : PrimaryODE.FrameData PhaseCalculus.Slow) |
| 152 | (χ : P →L[ℝ] PhaseCalculus.Slow) (g : Geometry) (k : Frequency) (j : ℤ) |
| 153 | (z : (P × Plane) × ℝ) : |
| 154 | (PrimaryCopyBridge.copyFrame (nativeFrame d χ) g k).coefficient j z = |
| 155 | d.coefficient j (frameArgument χ z) := rfl |
| 156 | |
| 157 | @[simp] theorem copyFrame_synthesis (d : PrimaryODE.FrameData PhaseCalculus.Slow) |
| 158 | (χ : P →L[ℝ] PhaseCalculus.Slow) (g : Geometry) (k : Frequency) (i : Fin 2) |
| 159 | (z : (P × Plane) × ℝ) : |
| 160 | synthesisColumn (PrimaryCopyBridge.copyFrame (nativeFrame d χ) g k) i z = |
| 161 | synthesisColumn d i (frameArgument χ z) := rfl |
| 162 | |
| 163 | @[simp] theorem copyFrame_forcingLinear (d : PrimaryODE.FrameData PhaseCalculus.Slow) |
| 164 | (χ : P →L[ℝ] PhaseCalculus.Slow) (g : Geometry) (k : Frequency) |
| 165 | (z : (P × Plane) × ℝ) : |
| 166 | frameForcingLinear (PrimaryCopyBridge.copyFrame (nativeFrame d χ) g k) z = |
| 167 | frameForcingLinear d (frameArgument χ z) := rfl |
| 168 | |
| 169 | noncomputable def frameDomain {ι : Type*} |
| 170 | (U : PhaseJetBounds.Domain ι (PhaseCalculus.Slow × ℝ)) |
| 171 | (χ : P →L[ℝ] PhaseCalculus.Slow) : PhaseJetBounds.Domain ι ((P × Plane) × ℝ) where |
| 172 | scale := U.scale |
| 173 | carrier i := frameArgument χ ⁻¹' U.carrier i |
| 174 | isOpen i := (U.isOpen i).preimage (frameArgument χ).continuous |
| 175 | one_le_scale := U.one_le_scale |
| 176 | |
| 177 | theorem pull_frame_jets {ι V : Type*} [NormedAddCommGroup V] [NormedSpace ℝ V] |
| 178 | {U : PhaseJetBounds.Domain ι (PhaseCalculus.Slow × ℝ)} |
| 179 | {f : ι → PhaseCalculus.Slow × ℝ → V} (hf : PolynomialJets U f) |
| 180 | (χ : P →L[ℝ] PhaseCalculus.Slow) : |
| 181 | PolynomialJets (frameDomain U χ) (fun i z => f i (frameArgument χ z)) := by |
| 182 | simpa only [add_zero] using hf.precomp_affine (D := frameDomain U χ) |
| 183 | (frameArgument χ) (fun _ => 0) (fun _ => rfl) (fun _ _ hz => by simp only [add_zero]; exact hz) |
| 184 | |
| 185 | end FrameReindex |
| 186 | |
| 187 | section SourcePath |
| 188 | |
| 189 | variable {Label : Type*} {P V : Type} |
| 190 | [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 191 | [NormedAddCommGroup V] [NormedSpace ℝ V] |
| 192 | |
| 193 | /-- The grouped Gaussian of this label, built from its actual copy |
| 194 | geometry and its full padded integration rectangle. -/ |
| 195 | noncomputable def groupedEnvelope (g : Label → ℕ → Geometry) |
| 196 | (r L : Label → ℕ → ℝ) (W : Label → ℕ → ℝ → ℝ) : |
| 197 | Label → ℕ → P × Plane → ℝ := |
| 198 | fun l n x => WaveEnvelopeTransport.copyEnvelope (g l n) (r l n) (L l n) (W l n) x.2 |
| 199 | |
| 200 | /-- Uniform full jets of the actual shifted source. The source class is |
| 201 | an input on the current residual, not on the solution or projected forcing. |
| 202 | The Gaussian at an earlier integration time is derived by separation. -/ |
| 203 | theorem source_path_bounds |
| 204 | (s : StripData P) (g : Label → ℕ → Geometry) (r L : Label → ℕ → ℝ) |
| 205 | (W : Label → ℕ → ℝ → ℝ) (hW : ∀ l n v, 0 ≤ W l n v) |
| 206 | (hsep : ∀ l n, WaveEnvelopeTransport.Separated (g l n) (r l n) (L l n)) |
| 207 | {A : ℝ} {a : ℕ} (hA : 1 ≤ A) |
| 208 | (hgeometry : ∀ l n, CommonCoverClass.argumentCost (g l n) ≤ A * s.slow n^a) |
| 209 | {α : ℝ} {f : Label → ℕ → P × Plane → V} |
| 210 | (hf : UniformWaveClass (CommonCoverClass.sourceStrip s) (groupedEnvelope g r L W) α f) |
| 211 | (N : ℕ) : |
| 212 | ∃ C : ℝ, 0 ≤ C ∧ ∃ m : ℕ, ∀ l n k (x : P × Plane), x.1 ∈ s.domain → |
| 213 | ((g l n).coordinates k x.2).1 ∈ Icc (-(r l n)) (r l n) → |
| 214 | ∀ v ∈ Icc 0 (L l n), ∀ j ≤ N, |
| 215 | ‖iteratedFDeriv ℝ j (fun z : (P × Plane) × ℝ => |
| 216 | f l n (CommonCoverClass.sourceArgument (g l n) k z)) (x,v)‖ ≤ |
| 217 | C * s.growth n x.1^m * (s.epsilon n^α * Real.sqrt (s.zeta x.1)) * W l n v := by |
| 218 | obtain ⟨B, hB, b, hb⟩ := hf.bounds N |
| 219 | refine ⟨B * A^N, by positivity, b+a*N, ?_⟩ |
| 220 | intro l n k x hx hξ v hv j hj |
| 221 | let G := g l n |
| 222 | have hmap : CommonCoverClass.sourceArgument G k (x,v) ∈ |
| 223 | (CommonCoverClass.sourceStrip s).domain := hx |
| 224 | have hlocal : CommonCoverClass.sourceArgument G k 0 + |
| 225 | CommonCoverClass.sourceLinear P G (x,v) ∈ (CommonCoverClass.sourceStrip s).domain := by |
| 226 | rw [← CommonCoverClass.sourceArgument_affine] |
| 227 | exact hmap |
| 228 | have hjet := CommonCoverClass.norm_affine_jet_le_on |
| 229 | (CommonCoverClass.sourceStrip s).isOpen_domain (hf.smooth l n) |
| 230 | (CommonCoverClass.sourceLinear P G) (CommonCoverClass.sourceArgument G k 0) hlocal j |
| 231 | simp_rw [← CommonCoverClass.sourceArgument_affine] at hjet |
| 232 | have hs := hb l n (CommonCoverClass.sourceArgument G k (x,v)) hmap j hj |
| 233 | change ‖iteratedFDeriv ℝ j (f l n) (CommonCoverClass.sourceArgument G k (x,v))‖ ≤ |
| 234 | B * s.epsilon n^α * s.growth n x.1^b * (Real.sqrt (s.zeta x.1) * |
| 235 | WaveEnvelopeTransport.copyEnvelope G (r l n) (L l n) (W l n) (G.path k x.2 v)) at hs |
| 236 | rw [WaveEnvelopeTransport.copyEnvelope_path (hsep l n) (W l n) k x.2 hξ hv] at hs |
| 237 | have hG := s.one_le_growth n x.1 |
| 238 | have hG0 := s.growth_nonneg n x.1 |
| 239 | have hlin : ‖CommonCoverClass.sourceLinear P G‖ ≤ A * s.growth n x.1^a := |
| 240 | (CommonCoverClass.norm_sourceLinear_le G).trans ((hgeometry l n).trans |
| 241 | (mul_le_mul_of_nonneg_left (pow_le_pow_left₀ |
| 242 | (zero_le_one.trans (s.one_le_slow n)) (s.slow_le_growth n x.1) a) |
| 243 | (zero_le_one.trans hA))) |
| 244 | have hpow : ‖CommonCoverClass.sourceLinear P G‖^j ≤ A^N * s.growth n x.1^(a*N) := by |
| 245 | rw [pow_mul, ← mul_pow] |
| 246 | exact (pow_le_pow_left₀ (norm_nonneg _) hlin j).trans |
| 247 | (pow_le_pow_right₀ (one_le_mul_of_one_le_of_one_le hA (one_le_pow₀ hG)) hj) |
| 248 | have hw := hW l n v |
| 249 | have he := s.epsilon_pos n |
| 250 | calc |
| 251 | _ ≤ ‖iteratedFDeriv ℝ j (f l n) (CommonCoverClass.sourceArgument G k (x,v))‖ * |
| 252 | ‖CommonCoverClass.sourceLinear P G‖^j := hjet |
| 253 | _ ≤ (B * s.epsilon n^α * s.growth n x.1^b * (Real.sqrt (s.zeta x.1) * W l n v)) * |
| 254 | (A^N * s.growth n x.1^(a*N)) := |
| 255 | mul_le_mul hs hpow (pow_nonneg (norm_nonneg _) _) (by positivity) |
| 256 | _ = _ := by rw [pow_add]; ring |
| 257 | |
| 258 | end SourcePath |
| 259 | |
| 260 | section NativeInputs |
| 261 | |
| 262 | variable {Label : Type*} {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 263 | {D : PhaseJetBounds.Domain (Label × ℕ) PhaseCalculus.Slow} |
| 264 | |
| 265 | private theorem raise_polynomial_bound {A B S G : ℝ} {p q : ℕ} |
| 266 | (hA : 0 ≤ A) (hAB : A ≤ B) (hS : 0 ≤ S) (hSG : S ≤ G) |
| 267 | (hG : 1 ≤ G) (hpq : p ≤ q) : A*S^p ≤ B*G^q := by |
| 268 | exact mul_le_mul hAB ((pow_le_pow_left₀ hS hSG p).trans |
| 269 | (pow_le_pow_right₀ hG hpq)) (pow_nonneg hS p) (hA.trans hAB) |
| 270 | |
| 271 | /-- Joint coefficient, source-projection, and synthesis bounds of the |
| 272 | literal copy frame. The full source path is used at every derivative order. |
| 273 | No modal energy or projected forcing bound is supplied. -/ |
| 274 | theorem frame_input_jets |
| 275 | (s : StripData P) (V : (Label × ℕ) → Set ℝ) (hV : ∀ i, IsOpen (V i)) |
| 276 | (d : (Label × ℕ) → PrimaryODE.FrameData PhaseCalculus.Slow) |
| 277 | (L : (Label × ℕ) → ℝ) (W : Label → ℕ → ℝ → ℝ) |
| 278 | (hd : FrameJets (D.slot V hV) d) (hinterval : ∀ i, Icc 0 (L i) ⊆ V i) |
| 279 | (hW : ∀ l n v, 0 ≤ W l n v) (χ : P →L[ℝ] PhaseCalculus.Slow) |
| 280 | (g : Label → ℕ → Geometry) (r : Label → ℕ → ℝ) |
| 281 | (hscale : ∀ l n, D.scale (l,n) = s.slow n) |
| 282 | (hsep : ∀ l n, WaveEnvelopeTransport.Separated (g l n) (r l n) (L (l,n))) |
| 283 | {A : ℝ} {a : ℕ} (hA : 1 ≤ A) |
| 284 | (hgeometry : ∀ l n, CommonCoverClass.argumentCost (g l n) ≤ A*s.slow n^a) |
| 285 | (harmonic : Label → ℤ) {J : ℝ} (hJ : 1 ≤ J) (hj : ∀ l, |(harmonic l : ℝ)| ≤ J) |
| 286 | {α : ℝ} {f : Label → ℕ → P × Plane → ProblemStatement.Space} |
| 287 | (hf : UniformWaveClass (CommonCoverClass.sourceStrip s) |
| 288 | (groupedEnvelope g r (fun l n => L (l,n)) |
| 289 | (fun l n => W l n)) α f) |
| 290 | (N : ℕ) : |
| 291 | ∃ C : ℝ, 0 ≤ C ∧ ∃ m : ℕ, ∀ l n k (x : P × Plane), x.1 ∈ s.domain → |
| 292 | χ x.1 ∈ D.carrier (l,n) → |
| 293 | ((g l n).coordinates k x.2).1 ∈ Icc (-(r l n)) (r l n) → |
| 294 | ∀ j ≤ N, ∀ v ∈ Icc 0 (L (l,n)), |
| 295 | ‖iteratedFDeriv ℝ j |
| 296 | ((PrimaryCopyBridge.copyFrame (nativeFrame (d (l,n)) χ) (g l n) k).coefficient |
| 297 | (harmonic l)) (x,v)‖ ≤ C*s.growth n x.1^m ∧ |
| 298 | ‖iteratedFDeriv ℝ j |
| 299 | ((PrimaryCopyBridge.copyFrame (nativeFrame (d (l,n)) χ) (g l n) k).forcing |
| 300 | (PrimaryCopyBridge.copySource (f l n) (g l n) k)) (x,v)‖ ≤ |
| 301 | (s.epsilon n^α * Real.sqrt (s.zeta x.1))*C*s.growth n x.1^m * |
| 302 | W l n v ∧ |
| 303 | ∀ i : Fin 2, ‖iteratedFDeriv ℝ j |
| 304 | (synthesisColumn (PrimaryCopyBridge.copyFrame (nativeFrame (d (l,n)) χ) (g l n) k) i) |
| 305 | (x,v)‖ ≤ C*s.growth n x.1^m := by |
| 306 | have hc := pull_frame_jets (frame_coefficient_jets_bounded hd |
| 307 | (fun i => harmonic i.1) hJ (fun i => hj i.1)) χ |
| 308 | have hp := pull_frame_jets (frame_forcingLinear_jets hd) χ |
| 309 | have h0 := pull_frame_jets (synthesisColumn_polynomial hd 0) χ |
| 310 | have h1 := pull_frame_jets (synthesisColumn_polynomial hd 1) χ |
| 311 | obtain ⟨Cc, hCc, mc, hCcj⟩ := hc.bound N |
| 312 | obtain ⟨Cp, hCp, mp, hCpj⟩ := hp.bound N |
| 313 | obtain ⟨C0, hC0, m0, hC0j⟩ := h0.bound N |
| 314 | obtain ⟨C1, hC1, m1, hC1j⟩ := h1.bound N |
| 315 | obtain ⟨Cs, hCs, ms, hCsj⟩ := source_path_bounds s g r (fun l n => L (l,n)) |
| 316 | (fun l n => W l n) |
| 317 | hW hsep hA hgeometry hf N |
| 318 | let B := Cc + Cp + C0 + C1 |
| 319 | let q := mc + mp + m0 + m1 |
| 320 | have hB : 0 ≤ B := by dsimp [B]; linarith |
| 321 | have hbc : Cc ≤ B := by dsimp [B]; linarith |
| 322 | have hbp : Cp ≤ B := by dsimp [B]; linarith |
| 323 | have hb0 : C0 ≤ B := by dsimp [B]; linarith |
| 324 | have hb1 : C1 ≤ B := by dsimp [B]; linarith |
| 325 | let C := B + 2^N * B * Cs |
| 326 | have hC : 0 ≤ C := by dsimp [C]; positivity |
| 327 | have hBC : B ≤ C := by dsimp [C]; exact le_add_of_nonneg_right (by positivity) |
| 328 | have hprodC : 2^N * B * Cs ≤ C := by dsimp [C]; linarith |
| 329 | refine ⟨C, hC, q+ms, ?_⟩ |
| 330 | intro l n k x hx hχ hξ j hjN v hv |
| 331 | have hz : (x,v) ∈ (frameDomain (D.slot V hV) χ).carrier (l,n) := |
| 332 | ⟨hχ, hinterval (l,n) hv⟩ |
| 333 | have hG := s.one_le_growth n x.1 |
| 334 | have hG0 := s.growth_nonneg n x.1 |
| 335 | have hS0 : 0 ≤ D.scale (l,n) := zero_le_one.trans (D.one_le_scale _) |
| 336 | have hSG : D.scale (l,n) ≤ s.growth n x.1 := by |
| 337 | rw [hscale] |
| 338 | exact s.slow_le_growth n x.1 |
| 339 | have hcj (i : ℕ) (hi : i ≤ N) : |
| 340 | ‖iteratedFDeriv ℝ i (fun z => (d (l,n)).coefficient (harmonic l) (frameArgument χ z)) |
| 341 | (x,v)‖ ≤ B*s.growth n x.1^q := |
| 342 | (hCcj (l,n) i hi (x,v) hz).trans (raise_polynomial_bound |
| 343 | (zero_le_one.trans hCc) hbc hS0 hSG hG (by dsimp [q]; omega)) |
| 344 | have hpj (i : ℕ) (hi : i ≤ N) : |
| 345 | ‖iteratedFDeriv ℝ i (fun z => frameForcingLinear (d (l,n)) (frameArgument χ z)) |
| 346 | (x,v)‖ ≤ B*s.growth n x.1^q := |
| 347 | (hCpj (l,n) i hi (x,v) hz).trans (raise_polynomial_bound |
| 348 | (zero_le_one.trans hCp) hbp hS0 hSG hG (by dsimp [q]; omega)) |
| 349 | have hsynth (i : Fin 2) : |
| 350 | ‖iteratedFDeriv ℝ j (fun z => synthesisColumn (d (l,n)) i (frameArgument χ z)) |
| 351 | (x,v)‖ ≤ B*s.growth n x.1^q := by |
| 352 | fin_cases i |
| 353 | · exact (hC0j (l,n) j hjN (x,v) hz).trans (raise_polynomial_bound |
| 354 | (zero_le_one.trans hC0) hb0 hS0 hSG hG (by dsimp [q]; omega)) |
| 355 | · exact (hC1j (l,n) j hjN (x,v) hz).trans (raise_polynomial_bound |
| 356 | (zero_le_one.trans hC1) hb1 hS0 hSG hG (by dsimp [q]; omega)) |
| 357 | have hra : B*s.growth n x.1^q ≤ C*s.growth n x.1^(q+ms) := |
| 358 | raise_polynomial_bound hB hBC hG0 le_rfl hG (Nat.le_add_right _ _) |
| 359 | refine ⟨(hcj j hjN).trans hra, ?_, fun i => (hsynth i).trans hra⟩ |
| 360 | let U := (frameDomain (D.slot V hV) χ).carrier (l,n) ∩ |
| 361 | {z : (P × Plane) × ℝ | z.1.1 ∈ s.domain} |
| 362 | have hU : IsOpen U := (frameDomain (D.slot V hV) χ).isOpen (l,n) |>.inter |
| 363 | (s.isOpen_domain.preimage (continuous_fst.comp continuous_fst)) |
| 364 | have hxs : (x,v) ∈ U := ⟨hz,hx⟩ |
| 365 | have hpSmooth := (hp.smooth (l,n)).mono (inter_subset_left : U ⊆ _) |
| 366 | have hsSmooth : ContDiffOn ℝ ∞ |
| 367 | (fun z : (P × Plane) × ℝ => f l n (CommonCoverClass.sourceArgument (g l n) k z)) U := |
| 368 | (hf.smooth l n).comp (CommonCoverClass.sourceArgument_smooth (g l n) k).contDiffOn |
| 369 | (fun z hz => hz.2) |
| 370 | have hweight : 0 ≤ s.epsilon n^α * Real.sqrt (s.zeta x.1) := |
| 371 | mul_nonneg (Real.rpow_pos_of_pos (s.epsilon_pos n) α).le (Real.sqrt_nonneg _) |
| 372 | have hen : 0 ≤ W l n v := |
| 373 | hW l n v |
| 374 | have ht := WaveEnvelopeTransport.clm_apply_jet_bound_on hU hpSmooth hsSmooth hxs N |
| 375 | (show 0 ≤ B*s.growth n x.1^q by positivity) |
| 376 | (show 0 ≤ Cs*s.growth n x.1^ms*(s.epsilon n^α*Real.sqrt (s.zeta x.1))* |
| 377 | W l n v by positivity) |
| 378 | hpj (fun i hi => hCsj l n k x hx hξ v hv i hi) j hjN |
| 379 | change ‖iteratedFDeriv ℝ j |
| 380 | ((PrimaryCopyBridge.copyFrame (nativeFrame (d (l,n)) χ) (g l n) k).forcing |
| 381 | (PrimaryCopyBridge.copySource (f l n) (g l n) k)) (x,v)‖ ≤ _ at ht |
| 382 | calc |
| 383 | _ ≤ 2^N*(B*s.growth n x.1^q)*(Cs*s.growth n x.1^ms* |
| 384 | (s.epsilon n^α*Real.sqrt (s.zeta x.1))* |
| 385 | W l n v) := ht |
| 386 | _ = (s.epsilon n^α*Real.sqrt (s.zeta x.1))*(2^N*B*Cs)*s.growth n x.1^(q+ms)* |
| 387 | W l n v := by rw [pow_add]; ring |
| 388 | _ ≤ _ := by gcongr |
| 389 | |
| 390 | end NativeInputs |
| 391 | |
| 392 | section CurrentResidual |
| 393 | |
| 394 | variable {Label : Type*} {P E V : Type} |
| 395 | [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 396 | [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 397 | [NormedAddCommGroup V] [NormedSpace ℝ V] |
| 398 | |
| 399 | /-- A fixed linear pullback preserves the order of all uniform quantifiers. -/ |
| 400 | theorem uniform_parameter_pull {s : StripData P} {w : Label → ℕ → P → ℝ} |
| 401 | {α : ℝ} {f : Label → ℕ → P → V} (hf : UniformClass s w α f) (L : E →L[ℝ] P) : |
| 402 | UniformClass (CommonCoverClass.parameterStrip s L) |
| 403 | (fun l n x => w l n (L x)) α (fun l n x => f l n (L x)) := by |
| 404 | refine ⟨fun l n x hx => hf.weight_nonneg l n (L x) hx, |
| 405 | fun l n => (hf.smooth l n).comp_continuousLinearMap L, ?_⟩ |
| 406 | intro N |
| 407 | obtain ⟨C,hC,m,hb⟩ := hf.bounds N |
| 408 | refine ⟨C*(‖L‖+1)^N, by positivity, m, ?_⟩ |
| 409 | intro l n x hx j hj |
| 410 | have ht := PhaseJetBounds.norm_jet_comp_linear s.isOpen_domain (hf.smooth l n) L hx j |
| 411 | have hpow : ‖L‖^j ≤ (‖L‖+1)^N := |
| 412 | (pow_le_pow_left₀ (norm_nonneg _) (by linarith) j).trans |
| 413 | (pow_le_pow_right₀ (by linarith [norm_nonneg L]) hj) |
| 414 | calc |
| 415 | _ ≤ ‖iteratedFDeriv ℝ j (f l n) (L x)‖*‖L‖^j := ht |
| 416 | _ ≤ majorant s (w l) α C m n (L x)*(‖L‖+1)^N := |
| 417 | mul_le_mul (hb l n (L x) hx j hj) hpow (pow_nonneg (norm_nonneg _) _) |
| 418 | (majorant_nonneg _ _ _ hC _ _ _ (hf.weight_nonneg l n (L x) hx)) |
| 419 | _ = _ := by dsimp [majorant, CommonCoverClass.parameterStrip, StripData.growth]; ring |
| 420 | |
| 421 | /-- The actual three residual coefficients form one uniformly bounded |
| 422 | source vector. No property of the inverse is assumed here. -/ |
| 423 | theorem residualSource_uniform |
| 424 | (s : StripData (P × Plane)) (W : Label → ℕ → P × Plane → ℝ) (α : ℝ) |
| 425 | (c : CorrectionState.Context (P × Plane)) (u : CorrectionState.State (P × Plane)) |
| 426 | (b : Label → CorrectionState.HarmonicBlock (P × Plane)) |
| 427 | (G A : Label → HarmonicResidual.BlockCoefficients (P × Plane)) (j : Label → ℤ) |
| 428 | (h : ∀ i : Fin 3, UniformWaveClass s W α (fun l n x => |
| 429 | (HarmonicResidual.residualBlock c u (b l) (G l) (A l)).velocity n i (j l) x)) : |
| 430 | UniformWaveClass s W α (fun l n => |
| 431 | ParticularWaveAssembly.residualSource c u (b l) (G l) (A l) (j l) n) := by |
| 432 | have hc (i : Fin 3) := (h i).map (ContinuousLinearMap.single ℝ (fun _ : Fin 3 => ℂ) i) |
| 433 | apply ((hc 0).add (hc 1) |>.add (hc 2)).congr |
| 434 | intro l n x hx |
| 435 | funext i |
| 436 | fin_cases i <;> simp [ParticularWaveAssembly.residualSource] |
| 437 | |
| 438 | noncomputable def angleStrip (s : StripData P) : StripData (P × ℝ) := |
| 439 | CommonCoverClass.parameterStrip s (ContinuousLinearMap.fst ℝ P ℝ) |
| 440 | |
| 441 | noncomputable def forgetAngle : ((P × ℝ) × Plane) →L[ℝ] (P × Plane) := |
| 442 | ((ContinuousLinearMap.fst ℝ P ℝ).comp (ContinuousLinearMap.fst ℝ (P × ℝ) Plane)).prod |
| 443 | (ContinuousLinearMap.snd ℝ (P × ℝ) Plane) |
| 444 | |
| 445 | /-- The additional angular variable is genuinely absent from the current |
| 446 | source. Its introduction preserves the same moving strip weight. -/ |
| 447 | theorem sourceFamily_uniform |
| 448 | (s : StripData P) (g : Label → ℕ → Geometry) (r L : Label → ℕ → ℝ) |
| 449 | (W : Label → ℕ → ℝ → ℝ) (α : ℝ) |
| 450 | (c : CorrectionState.Context (P × Plane)) (u : CorrectionState.State (P × Plane)) |
| 451 | (b : Label → CorrectionState.HarmonicBlock (P × Plane)) |
| 452 | (G A : Label → HarmonicResidual.BlockCoefficients (P × Plane)) (j : Label → ℤ) |
| 453 | (h : ∀ i : Fin 3, UniformWaveClass (CommonCoverClass.sourceStrip s) |
| 454 | (groupedEnvelope g r L W) α (fun l n x => |
| 455 | (HarmonicResidual.residualBlock c u (b l) (G l) (A l)).velocity n i (j l) x)) : |
| 456 | UniformWaveClass (CommonCoverClass.sourceStrip (angleStrip s)) |
| 457 | (groupedEnvelope g r L W) α (fun l => |
| 458 | ParticularWaveAssembly.sourceFamily c u (b l) (G l) (A l) (j l)) := by |
| 459 | exact uniform_parameter_pull |
| 460 | (residualSource_uniform (CommonCoverClass.sourceStrip s) (groupedEnvelope g r L W) α c u b G A j h) |
| 461 | (forgetAngle (P := P)) |
| 462 | |
| 463 | end CurrentResidual |
| 464 | |
| 465 | section FiniteHarmonics |
| 466 | |
| 467 | variable {Label : Type*} {E V : Type} |
| 468 | [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 469 | [NormedAddCommGroup V] [NormedSpace ℝ V] |
| 470 | |
| 471 | private theorem majorant_enlarge (s : StripData E) (w : ℕ → E → ℝ) (α : ℝ) |
| 472 | {C B : ℝ} {p q : ℕ} (hC : 0 ≤ C) (hCB : C ≤ B) (hpq : p ≤ q) |
| 473 | (n : ℕ) (x : E) (hw : 0 ≤ w n x) : |
| 474 | majorant s w α C p n x ≤ majorant s w α B q n x := by |
| 475 | have hp := raise_polynomial_bound hC hCB (s.growth_nonneg n x) le_rfl |
| 476 | (s.one_le_growth n x) hpq |
| 477 | have ht := mul_le_mul_of_nonneg_right hp |
| 478 | (mul_nonneg (Real.rpow_pos_of_pos (s.epsilon_pos n) α).le hw) |
| 479 | unfold majorant |
| 480 | nlinarith only [ht] |
| 481 | |
| 482 | end FiniteHarmonics |
| 483 | |
| 484 | section ReferenceControl |
| 485 | |
| 486 | variable {Label : Type} {P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 487 | {D : PhaseJetBounds.Domain (Label × ℕ) PhaseCalculus.Slow} |
| 488 | |
| 489 | private theorem frame_smooth_mono {Q : Type} [NormedAddCommGroup Q] [NormedSpace ℝ Q] |
| 490 | {d : PrimaryODE.FrameData Q} {U V : Set (Q × ℝ)} (h : d.SmoothOn U) (hVU : V ⊆ U) : |
| 491 | d.SmoothOn V := |
| 492 | ⟨h.beta.mono hVU, h.betaDot.mono hVU, h.rho.mono hVU, h.rhoDot.mono hVU, |
| 493 | h.rotation.mono hVU, h.F.mono hVU, h.shear.mono hVU, fun i => (h.frame i).mono hVU, |
| 494 | h.eigenvalue.mono hVU, h.eigenvector.mono hVU, h.eigenRate.mono hVU, |
| 495 | h.viscosity.mono hVU, fun x hx => h.eigenvector_ne_zero x (hVU hx)⟩ |
| 496 | |
| 497 | noncomputable def phaseNeighborhood (s : StripData P) (F : PhaseConstruction D) |
| 498 | (χ : P →L[ℝ] PhaseCalculus.Slow) (g : Label → ℕ → Geometry) |
| 499 | (l : Label) (n : ℕ) (k : Frequency) : Set (P × Plane) := |
| 500 | {x | x.1 ∈ s.domain ∧ χ x.1 ∈ D.carrier (l,n) ∧ |
| 501 | ((g l n).coordinates k x.2).2 ∈ Ioo 0 (F.L (l,n))} |
| 502 | |
| 503 | noncomputable def phasePatch (s : StripData P) (F : PhaseConstruction D) |
| 504 | (χ : P →L[ℝ] PhaseCalculus.Slow) (g : Label → ℕ → Geometry) |
| 505 | (r : Label → ℕ → ℝ) (l : Label) (n : ℕ) (k : Frequency) : Set (P × Plane) := |
| 506 | phaseNeighborhood s F χ g l n k ∩ |
| 507 | {x | ((g l n).coordinates k x.2).1 ∈ Icc (-(r l n)) (r l n)} |
| 508 | |
| 509 | end ReferenceControl |
| 510 | |
| 511 | section ActualSourceControl |
| 512 | |
| 513 | variable {Label P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 514 | {D : PhaseJetBounds.Domain (Label × ℕ) PhaseCalculus.Slow} |
| 515 | |
| 516 | end ActualSourceControl |
| 517 | |
| 518 | section ClockTransport |
| 519 | |
| 520 | variable {P Q : Type} |
| 521 | |
| 522 | noncomputable def transportArgument [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 523 | [NormedAddCommGroup Q] [NormedSpace ℝ Q] (φ : Q →L[ℝ] P) (rate : ℝ) : |
| 524 | (Q × ℝ) →L[ℝ] (P × ℝ) := |
| 525 | (φ.comp (ContinuousLinearMap.fst ℝ Q ℝ)).prod (rate • ContinuousLinearMap.snd ℝ Q ℝ) |
| 526 | |
| 527 | @[simp] theorem transportArgument_apply [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 528 | [NormedAddCommGroup Q] [NormedSpace ℝ Q] (φ : Q →L[ℝ] P) (rate : ℝ) (z : Q × ℝ) : |
| 529 | transportArgument φ rate z = (φ z.1,rate*z.2) := rfl |
| 530 | |
| 531 | theorem norm_transportArgument_le [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 532 | [NormedAddCommGroup Q] [NormedSpace ℝ Q] (φ : Q →L[ℝ] P) (rate : ℝ) : |
| 533 | ‖transportArgument φ rate‖ ≤ ‖φ‖+|rate| := by |
| 534 | apply ContinuousLinearMap.opNorm_le_bound _ (add_nonneg (norm_nonneg _) (abs_nonneg _)) |
| 535 | intro z |
| 536 | rw [transportArgument_apply, Prod.norm_def, Real.norm_eq_abs, abs_mul] |
| 537 | apply max_le |
| 538 | · exact (φ.le_opNorm z.1).trans ((mul_le_mul_of_nonneg_left (norm_fst_le z) (norm_nonneg _)).trans |
| 539 | (mul_le_mul_of_nonneg_right (le_add_of_nonneg_right (abs_nonneg _)) (norm_nonneg z))) |
| 540 | · exact (mul_le_mul_of_nonneg_left (norm_snd_le z) (abs_nonneg _)).trans |
| 541 | (mul_le_mul_of_nonneg_right (le_add_of_nonneg_left (norm_nonneg _)) (norm_nonneg z)) |
| 542 | |
| 543 | /-- Indexed affine parameter/clock changes, with a single polynomial cost |
| 544 | before every label. Translation centers have no derivative cost. -/ |
| 545 | theorem polynomial_affine_family {ι E V : Type*} |
| 546 | [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 547 | [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 548 | [NormedAddCommGroup V] [NormedSpace ℝ V] |
| 549 | {U : PhaseJetBounds.Domain ι P} {T : PhaseJetBounds.Domain ι E} |
| 550 | {f : ι → P → V} (hf : PolynomialJets U f) |
| 551 | (L : ι → E →L[ℝ] P) (c : ι → P) |
| 552 | {A B : ℝ} {a b : ℕ} (hA : 1 ≤ A) (hB : 1 ≤ B) |
| 553 | (hlin : ∀ i, ‖L i‖ ≤ A*T.scale i^a) |
| 554 | (hscale : ∀ i, U.scale i ≤ B*T.scale i^b) |
| 555 | (hmap : ∀ i, MapsTo (fun x => L i x+c i) (T.carrier i) (U.carrier i)) : |
| 556 | PolynomialJets T (fun i x => f i (L i x+c i)) := by |
| 557 | refine ⟨fun i => (hf.smooth i).comp ((L i).contDiff.contDiffOn.add contDiffOn_const) (hmap i), ?_⟩ |
| 558 | intro N |
| 559 | obtain ⟨C,hC,m,hb⟩ := hf.bound N |
| 560 | refine ⟨C*B^m*A^N, one_le_mul_of_one_le_of_one_le |
| 561 | (one_le_mul_of_one_le_of_one_le hC (one_le_pow₀ hB)) (one_le_pow₀ hA), b*m+a*N, ?_⟩ |
| 562 | intro i j hj x hx |
| 563 | have hS := T.one_le_scale i |
| 564 | have hS0 := zero_le_one.trans hS |
| 565 | have hs : U.scale i^m ≤ B^m*T.scale i^(b*m) := by |
| 566 | simpa only [mul_pow,pow_mul] using pow_le_pow_left₀ |
| 567 | (zero_le_one.trans (U.one_le_scale i)) (hscale i) m |
| 568 | have hl : ‖L i‖^j ≤ A^N*T.scale i^(a*N) := by |
| 569 | rw [pow_mul, ← mul_pow] |
| 570 | exact (pow_le_pow_left₀ (norm_nonneg _) (hlin i) j).trans |
| 571 | (pow_le_pow_right₀ (one_le_mul_of_one_le_of_one_le hA (one_le_pow₀ hS)) hj) |
| 572 | calc |
| 573 | _ ≤ ‖iteratedFDeriv ℝ j (f i) (L i x+c i)‖*‖L i‖^j := |
| 574 | PhaseJetBounds.norm_jet_comp_affine (U.isOpen i) (hf.smooth i) (L i) (c i) (hmap i hx) j |
| 575 | _ ≤ (C*U.scale i^m)*(A^N*T.scale i^(a*N)) := mul_le_mul |
| 576 | (hb i j hj _ (hmap i hx)) hl (pow_nonneg (norm_nonneg _) _) |
| 577 | (mul_nonneg (zero_le_one.trans hC) (pow_nonneg (zero_le_one.trans (U.one_le_scale i)) _)) |
| 578 | _ ≤ (C*(B^m*T.scale i^(b*m)))*(A^N*T.scale i^(a*N)) := by gcongr |
| 579 | _ = _ := by rw [pow_add]; ring |
| 580 | |
| 581 | /-- Transport all primitive frame fields with the same clock and normal |
| 582 | factors as `ScaledTangentTransport.transportTangent`. -/ |
| 583 | noncomputable def transportedFrame (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 584 | (shift rate normalScale : ℝ) : PrimaryODE.FrameData Q where |
| 585 | beta z := normalScale * d.beta (φ z.1,shift+rate*z.2) |
| 586 | betaDot z := (normalScale*rate) * d.betaDot (φ z.1,shift+rate*z.2) |
| 587 | rho z := d.rho (φ z.1,shift+rate*z.2) |
| 588 | rhoDot z := rate * d.rhoDot (φ z.1,shift+rate*z.2) |
| 589 | rotation z := rate * d.rotation (φ z.1,shift+rate*z.2) |
| 590 | F z := rate * d.F (φ z.1,shift+rate*z.2) |
| 591 | shear z := rate • d.shear (φ z.1,shift+rate*z.2) |
| 592 | frame z := d.frame (φ z.1,shift+rate*z.2) |
| 593 | eigenvalue z := rate * d.eigenvalue (φ z.1,shift+rate*z.2) |
| 594 | eigenvector z := d.eigenvector (φ z.1,shift+rate*z.2) |
| 595 | eigenRate z := rate * d.eigenRate (φ z.1,shift+rate*z.2) |
| 596 | viscosity z := rate * d.viscosity (φ z.1,shift+rate*z.2) |
| 597 | |
| 598 | /-- Actual primitive jets after the same affine parameter and clock |
| 599 | transport. The scalar bounds precede every index; the normal multiplier |
| 600 | appears only in the two normal-scale fields. -/ |
| 601 | theorem transported_frame_jets {ι : Type*} |
| 602 | [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 603 | [NormedAddCommGroup Q] [NormedSpace ℝ Q] |
| 604 | {U : PhaseJetBounds.Domain ι (P × ℝ)} {T : PhaseJetBounds.Domain ι (Q × ℝ)} |
| 605 | {d : ι → PrimaryODE.FrameData P} (hd : FrameJets U d) |
| 606 | (φ : ι → Q →L[ℝ] P) (c : ι → P) (shift rate normalScale : ι → ℝ) |
| 607 | {A B R : ℝ} {a b : ℕ} (hA : 1 ≤ A) (hB : 1 ≤ B) (hR : 1 ≤ R) |
| 608 | (hrate : ∀ i, |rate i| ≤ R) (hnormal : ∀ i, |normalScale i| ≤ R) |
| 609 | (hlin : ∀ i, ‖transportArgument (φ i) (rate i)‖ ≤ A*T.scale i^a) |
| 610 | (hscale : ∀ i, U.scale i ≤ B*T.scale i^b) |
| 611 | (hmap : ∀ i, MapsTo (fun z : Q × ℝ => (φ i z.1+c i,shift i+rate i*z.2)) |
| 612 | (T.carrier i) (U.carrier i)) : |
| 613 | FrameJets T (fun i => transportedFrame (d i) (fun q => φ i q+c i) |
| 614 | (shift i) (rate i) (normalScale i)) := by |
| 615 | have pull {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 616 | {f : ι → P × ℝ → E} (hf : PolynomialJets U f) : |
| 617 | PolynomialJets T (fun i z => f i (φ i z.1+c i,shift i+rate i*z.2)) := by |
| 618 | simpa only [transportArgument_apply, Prod.mk_add_mk, add_comm] using |
| 619 | polynomial_affine_family hf (fun i => transportArgument (φ i) (rate i)) |
| 620 | (fun i => (c i,shift i)) hA hB hlin hscale |
| 621 | (by simpa only [transportArgument_apply,Prod.mk_add_mk,add_comm] using hmap) |
| 622 | have hr : PolynomialJets T (fun i _ => rate i) := |
| 623 | PolynomialJets.const_uniform rate hR (fun i => by simpa only [Real.norm_eq_abs] using hrate i) |
| 624 | have hn : PolynomialJets T (fun i _ => normalScale i) := |
| 625 | PolynomialJets.const_uniform normalScale hR (fun i => by simpa only [Real.norm_eq_abs] using hnormal i) |
| 626 | exact { |
| 627 | beta := hn.mul (pull hd.beta) |
| 628 | betaDot := (hn.mul hr).mul (pull hd.betaDot) |
| 629 | rho := pull hd.rho |
| 630 | rhoDot := hr.mul (pull hd.rhoDot) |
| 631 | rotation := hr.mul (pull hd.rotation) |
| 632 | F := hr.mul (pull hd.F) |
| 633 | shear := hr.smul (pull hd.shear) |
| 634 | K := pull hd.K |
| 635 | N := pull hd.N |
| 636 | invDenom := pull hd.invDenom |
| 637 | eigenvalue := hr.mul (pull hd.eigenvalue) |
| 638 | eigenvector := pull hd.eigenvector |
| 639 | invEigenvector := pull hd.invEigenvector |
| 640 | eigenRate := hr.mul (pull hd.eigenRate) |
| 641 | viscosity := hr.mul (pull hd.viscosity) |
| 642 | eigenvector_ne_zero := fun i z hz => hd.eigenvector_ne_zero i _ (hmap i hz) } |
| 643 | |
| 644 | theorem transported_errors (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 645 | (shift rate normalScale : ℝ) (z : Q × ℝ) : |
| 646 | (transportedFrame d φ shift rate normalScale).error11 z = |
| 647 | rate*d.error11 (φ z.1,shift+rate*z.2) ∧ |
| 648 | (transportedFrame d φ shift rate normalScale).error12 z = |
| 649 | rate*d.error12 (φ z.1,shift+rate*z.2) ∧ |
| 650 | (transportedFrame d φ shift rate normalScale).error21 z = |
| 651 | rate*d.error21 (φ z.1,shift+rate*z.2) ∧ |
| 652 | (transportedFrame d φ shift rate normalScale).error22 z = |
| 653 | rate*d.error22 (φ z.1,shift+rate*z.2) := by |
| 654 | simp only [transportedFrame, PrimaryODE.FrameData.error11, PrimaryODE.FrameData.error12, |
| 655 | PrimaryODE.FrameData.error21, PrimaryODE.FrameData.error22, PrimaryODE.FrameData.errorA, |
| 656 | PrimaryODE.FrameData.errorB, PrimaryODE.FrameData.errorC, |
| 657 | MovingFrameODE.modal11, MovingFrameODE.modal12, MovingFrameODE.modal21, MovingFrameODE.modal22, |
| 658 | MovingFrameODE.coeff11, MovingFrameODE.coeff12, MovingFrameODE.coeff21, inner_smul_right] |
| 659 | constructor |
| 660 | · ring |
| 661 | constructor |
| 662 | · ring |
| 663 | constructor <;> ring |
| 664 | |
| 665 | theorem transported_coefficient (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 666 | (shift rate normalScale : ℝ) (j : ℤ) (z : Q × ℝ) : |
| 667 | (transportedFrame d φ shift rate normalScale).coefficient j z = |
| 668 | rate • d.coefficient j (φ z.1,shift+rate*z.2) := by |
| 669 | obtain ⟨h11,h12,h21,h22⟩ := transported_errors d φ shift rate normalScale z |
| 670 | simp only [PrimaryODE.FrameData.coefficient,h11,h12,h21,h22,PrimaryODE.FrameData.damping] |
| 671 | ext x i |
| 672 | fin_cases i <;> |
| 673 | simp [transportedFrame, GrowingMode.modalOperator] <;> ring |
| 674 | |
| 675 | theorem transported_energy {ι : Type*} {D : PhaseJetBounds.Domain ι PhaseCalculus.Slow} |
| 676 | (F : PhaseConstruction D) (i : ι) (φ : Q → PhaseCalculus.Slow) |
| 677 | (shift rate normalScale : ℝ) (hrate : 0 ≤ rate) {q : Q} |
| 678 | (hq : φ q ∈ D.carrier i) {v : ℝ} (hv : shift+rate*v ∈ Icc 0 (F.L i)) |
| 679 | {j : ℤ} (hj : j ≠ 0) (z : PrimaryODE.State) : |
| 680 | ⟪z, (transportedFrame (F.frame i) φ shift rate normalScale).coefficient j (q,v) z⟫_ℝ ≤ |
| 681 | (rate*GaussianEnvelope.referenceRate (F.lam i) (F.u i) (F.L i) (shift+rate*v) + |
| 682 | rate*((F.E+4*F.C)/D.scale i))*‖z‖^2 := by |
| 683 | rw [transported_coefficient, _root_.smul_apply, inner_smul_right] |
| 684 | exact (mul_le_mul_of_nonneg_left (selected_energy F i hq hv hj z) hrate).trans_eq (by ring) |
| 685 | |
| 686 | theorem transported_envelope_deriv (lam u L shift rate v : ℝ) : |
| 687 | HasDerivAt (fun t => referenceP lam u L (shift+rate*t)) |
| 688 | ((rate*GaussianEnvelope.referenceRate lam u L (shift+rate*v))* |
| 689 | referenceP lam u L (shift+rate*v)) v := by |
| 690 | have ht : HasDerivAt (fun t : ℝ => shift+rate*t) rate v := by |
| 691 | simpa using ((hasDerivAt_id v).const_mul rate).const_add shift |
| 692 | simpa only [Function.comp_def, smul_eq_mul, mul_assoc, mul_left_comm, mul_comm] using |
| 693 | (referenceP_hasDerivAt lam u L (shift+rate*v)).scomp v ht |
| 694 | |
| 695 | /-- Clock shortening exactly compensates the rescaling of the modal error |
| 696 | rate. No lower bound on the clock rate is lost inside the exponential. -/ |
| 697 | theorem transported_exponential (rate mu L : ℝ) (hrate : rate ≠ 0) : |
| 698 | Real.exp ((rate*mu)*(L/rate)) = Real.exp (mu*L) := by |
| 699 | congr 1 |
| 700 | field_simp |
| 701 | |
| 702 | @[simp] theorem transported_synthesis (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 703 | (shift rate normalScale : ℝ) (i : Fin 2) (z : Q × ℝ) : |
| 704 | synthesisColumn (transportedFrame d φ shift rate normalScale) i z = |
| 705 | synthesisColumn d i (φ z.1,shift+rate*z.2) := rfl |
| 706 | |
| 707 | theorem transported_normal (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 708 | (shift rate normalScale : ℝ) (z : Q × ℝ) : |
| 709 | (transportedFrame d φ shift rate normalScale).normal z = |
| 710 | normalScale • d.normal (φ z.1,shift+rate*z.2) := by |
| 711 | ext i |
| 712 | fin_cases i <;> |
| 713 | simp [transportedFrame, PrimaryODE.FrameData.normal, MovingFrameODE.normal, MovingFrameODE.pack] <;> ring |
| 714 | |
| 715 | theorem transported_normalMotion (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 716 | (shift rate normalScale : ℝ) (z : Q × ℝ) : |
| 717 | (transportedFrame d φ shift rate normalScale).normalMotion z = |
| 718 | (normalScale*rate) • d.normalMotion (φ z.1,shift+rate*z.2) := by |
| 719 | ext i |
| 720 | fin_cases i <;> |
| 721 | simp [transportedFrame, PrimaryODE.FrameData.normalMotion, MovingFrameODE.normalMotion, |
| 722 | MovingFrameODE.pack] <;> ring |
| 723 | |
| 724 | theorem transported_kinematics (d : PrimaryODE.FrameData P) (φ : Q → P) |
| 725 | (shift rate normalScale : ℝ) (hnormal : normalScale ≠ 0) |
| 726 | (q : Q) (I J : Set ℝ) (hmap : MapsTo (fun t => shift+rate*t) I J) |
| 727 | (hd : d.Kinematics (φ q) J) : |
| 728 | (transportedFrame d φ shift rate normalScale).Kinematics q I := by |
| 729 | have ht (v : ℝ) : HasDerivAt (fun t : ℝ => shift+rate*t) rate v := by |
| 730 | simpa using ((hasDerivAt_id v).const_mul rate).const_add shift |
| 731 | refine ⟨fun v hv => mul_ne_zero hnormal (hd.beta_ne_zero _ (hmap hv)), |
| 732 | fun v hv => hd.eigenvector_ne_zero _ (hmap hv), ?_, ?_, ?_, ?_, ?_⟩ |
| 733 | · intro v hv |
| 734 | have he := ((hd.beta_deriv _ (hmap hv)).scomp v (ht v)).const_mul normalScale |
| 735 | simpa only [transportedFrame,Function.comp_def,smul_eq_mul,mul_assoc,mul_left_comm,mul_comm] using he |
| 736 | · intro v hv |
| 737 | have he := (hd.rho_deriv _ (hmap hv)).scomp v (ht v) |
| 738 | simp only [transportedFrame, Function.comp_def, smul_eq_mul, mul_comm] at he ⊢ |
| 739 | exact he |
| 740 | · intro v hv |
| 741 | have he := (hd.eigenvector_deriv _ (hmap hv)).scomp v (ht v) |
| 742 | simp only [transportedFrame, Function.comp_def, smul_eq_mul, mul_assoc,mul_left_comm,mul_comm] at he ⊢ |
| 743 | exact he |
| 744 | · intro v hv |
| 745 | have he := (hd.frameK_deriv _ (hmap hv)).scomp v (ht v) |
| 746 | simp only [transportedFrame, Function.comp_def, smul_smul, mul_comm] at he ⊢ |
| 747 | exact he |
| 748 | · intro v hv |
| 749 | have he := (hd.frameN_deriv _ (hmap hv)).scomp v (ht v) |
| 750 | simp only [transportedFrame, Function.comp_def, smul_smul, mul_neg, mul_comm] at he ⊢ |
| 751 | exact he |
| 752 | |
| 753 | /-- The transformed frame is precisely the tangent transport already used |
| 754 | by the physical particular inverse, including its normal derivative. -/ |
| 755 | theorem frameTangentData_transport |
| 756 | (d : PrimaryODE.FrameData (P × ℝ)) (φ : Q → P) |
| 757 | (f : P × Plane → ProblemStatement.Space) (j : ℤ) (gap : ℕ) |
| 758 | (shift rate amplitude normalScale : ℝ) : |
| 759 | PrimaryCopyBridge.frameTangentData |
| 760 | (transportedFrame d (fun q : Q × ℝ => (φ q.1,q.2)) shift rate normalScale) j |
| 761 | (fun z => (rate*amplitude) • f (φ z.1,coverPower gap z.2)) = |
| 762 | ScaledTangentTransport.transportTangent (PrimaryCopyBridge.frameTangentData d j f) |
| 763 | φ gap shift rate amplitude normalScale := by |
| 764 | unfold PrimaryCopyBridge.frameTangentData ScaledTangentTransport.transportTangent |
| 765 | congr 1 |
| 766 | · funext z |
| 767 | exact transported_normal d _ shift rate normalScale (PrimaryCopyBridge.nativePoint z) |
| 768 | · funext z |
| 769 | exact transported_normalMotion d _ shift rate normalScale (PrimaryCopyBridge.nativePoint z) |
| 770 | · funext z |
| 771 | apply ContinuousLinearMap.ext |
| 772 | intro x |
| 773 | ext i |
| 774 | fin_cases i <;> |
| 775 | simp [ transportedFrame, |
| 776 | PrimaryCopyBridge.baseOperator_apply, MovingFrameODE.baseAction, MovingFrameODE.pack, |
| 777 | PrimaryCopyBridge.nativePoint, CopySolveCompatibility.nativeTimeMap] <;> ring |
| 778 | · funext z |
| 779 | simp [ transportedFrame, |
| 780 | PrimaryODE.FrameData.damping, PrimaryCopyBridge.nativePoint, CopySolveCompatibility.nativeTimeMap] |
| 781 | ring |
| 782 | |
| 783 | end ClockTransport |
| 784 | |
| 785 | /-- The complete integration rectangle remains separated after the actual |
| 786 | clock shortening and any covering refinement. -/ |
| 787 | theorem separated_transport {g : Geometry} {r L rate : ℝ} |
| 788 | (hsep : WaveEnvelopeTransport.Separated g r L) (hrate : 0 < rate) (gap : ℕ) : |
| 789 | WaveEnvelopeTransport.Separated |
| 790 | (CopySolveCompatibility.transportGeometry g gap 0 rate hrate.ne') r (L/rate) := by |
| 791 | apply hsep.mono |
| 792 | rintro Y ⟨z,hz,rfl⟩ |
| 793 | refine ⟨(z.1,rate*z.2), ⟨hz.1, mul_nonneg hrate.le hz.2.1, ?_⟩, ?_⟩ |
| 794 | · simpa only [mul_comm] using (le_div_iff₀ hrate).mp hz.2.2 |
| 795 | · simp [CopySolveCompatibility.transportGeometry, CopySolveCompatibility.refineGeometry, |
| 796 | CopySolveCompatibility.timeGeometry, CommonCoverClass.scaledBasis_apply] |
| 797 | |
| 798 | section TransportedSelectedInputs |
| 799 | |
| 800 | variable {Label P : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] |
| 801 | {D T : PhaseJetBounds.Domain (Label × ℕ) PhaseCalculus.Slow} |
| 802 | |
| 803 | /-- The literal selected frame after the zero-entry physical clock change. -/ |
| 804 | noncomputable def scaledSelectedFrame (F : PhaseConstruction D) |
| 805 | (φ : (Label × ℕ) → PhaseCalculus.Slow →L[ℝ] PhaseCalculus.Slow) |
| 806 | (rate normalScale : (Label × ℕ) → ℝ) (i : Label × ℕ) : |
| 807 | PrimaryODE.FrameData PhaseCalculus.Slow := |
| 808 | transportedFrame (F.frame i) (φ i) 0 (rate i) (normalScale i) |
| 809 | |
| 810 | theorem scaled_selected_copy_energy |
| 811 | (F : PhaseConstruction D) |
| 812 | (φ : (Label × ℕ) → PhaseCalculus.Slow →L[ℝ] PhaseCalculus.Slow) |
| 813 | (rate normalScale : (Label × ℕ) → ℝ) (χ : P →L[ℝ] PhaseCalculus.Slow) |
| 814 | (g : Label → ℕ → Geometry) (l : Label) (n : ℕ) (k : Frequency) |
| 815 | (hrate : 0 < rate (l,n)) (x : P × Plane) |
| 816 | (hx : φ (l,n) (χ x.1) ∈ D.carrier (l,n)) |
| 817 | {v : ℝ} (hv : v ∈ Icc 0 (F.L (l,n)/rate (l,n))) {j : ℤ} (hj : j ≠ 0) |
| 818 | (z : PrimaryODE.State) : |
| 819 | ⟪z, (PrimaryCopyBridge.copyFrame (nativeFrame |
| 820 | (scaledSelectedFrame F φ rate normalScale (l,n)) χ) (g l n) k).coefficient j (x,v) z⟫_ℝ ≤ |
| 821 | (rate (l,n)*GaussianEnvelope.referenceRate (F.lam (l,n)) (F.u (l,n)) |
| 822 | (F.L (l,n)) (rate (l,n)*v) + |
| 823 | rate (l,n)*((F.E+4*F.C)/D.scale (l,n)))*‖z‖^2 := by |
| 824 | have htime : 0+rate (l,n)*v ∈ Icc 0 (F.L (l,n)) := by |
| 825 | constructor |
| 826 | · simpa only [zero_add] using mul_nonneg hrate.le hv.1 |
| 827 | · simpa only [zero_add,mul_comm] using (le_div_iff₀ hrate).mp hv.2 |
| 828 | have he := transported_energy F (l,n) (φ (l,n)) 0 |
| 829 | (rate (l,n)) (normalScale (l,n)) hrate.le hx htime hj z |
| 830 | simp only [zero_add] at he |
| 831 | exact he |
| 832 | |
| 833 | end TransportedSelectedInputs |
| 834 | |
| 835 | end NavierStokes.ActualParticularControl |