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

Merge remote-tracking branch 'origin/main' into s1-euler-angle-9
Browse files main maintainer-statement s1-euler-angle-9 s1-ns-weighted-10 s1-ns-weighted-12 s2-instances-1 s2-ns-periodic-1 s2-ns-smooth-1 s5-euler-all-1 s5-euler-base-1 s5-euler-bounded-1 s5-euler-canonical-1 s5-euler-coefficient-1 s5-euler-compact-1 s5-euler-continuous-1 s5-euler-correction-1 s5-euler-cylinder-1 s5-euler-drift-1 s5-euler-duhamel-1 s5-euler-elapsed-1 s5-euler-euler-1 s5-euler-external-1 s5-euler-field-1 s5-euler-fixed-1 s5-euler-gained-1 s5-euler-gaussian-1 s5-euler-gevrey-1 s5-euler-graph-1 s5-euler-h5-1 s5-euler-h6-1 s5-euler-heat-1 s5-euler-inviscid-1 s5-euler-lifted-1 s5-euler-linear-1 s5-euler-lp-1 s5-euler-mean-1 s5-euler-mixed-1 s5-euler-ordinary-1 s5-euler-packet-1 s5-euler-parameter-1 s5-euler-parent-1 s5-euler-physical-1 s5-euler-projected-1 s5-euler-quadratic-1 s5-euler-regularized-1 s5-euler-small-1 s5-euler-smooth-1 s5-euler-sobolev-1 s5-euler-source-1 s5-euler-stage-1 s5-euler-static-1 s5-euler-terminal-1 s5-euler-time-1 s5-euler-top-1 s5-euler-transverse-1 s5-euler-weighted-1 s5-euler-whole-1 s5-ns-actual-1 s5-ns-axis-1 s5-ns-generic-1 s5-ns-label-1 s5-ns-local-1 s5-ns-particular-1 s5-ns-periodic-1 s5-ns-periodize-1
+1 −1 Euler/BaseEulerGevrey.lean View file
| @@ -22,7 +22,7 @@ theorem coordinate_norm_le (i : Fin 3) : ‖(EuclideanSpace.proj i : Space →L[ | ||
| 22 | 22 | theorem coordinate_bound_on_ball (i : Fin 3) (x : Space) (hx : ‖x‖ ≤ 2) (n : ℕ) : |
| 23 | 23 | ‖iteratedFDeriv ℝ n (fun y : Space => y i) x‖ ≤ 2*majorant 256 0 n := by |
| 24 | 24 | apply (linear_bound_on_ball (EuclideanSpace.proj i) 2 256 (by norm_num) (by norm_num) x hx n).trans |
| 25 | - exact mul_le_mul_of_nonneg_right (by nlinarith [coordinate_norm_le i]) | |
| 25 | + exact mul_le_mul_of_nonneg_right (by linarith [coordinate_norm_le i]) | |
| 26 | 26 | (majorant_nonneg 256 (by norm_num) 0 n) |
| 27 | 27 | |
| 28 | 28 | theorem linear_coordinate_bound_on_ball (L : Space →L[ℝ] Space) (i : Fin 3) |
+3 −3 Euler/BaseEulerGuards.lean View file
| @@ -52,11 +52,11 @@ theorem guardTime_small (T K : ℝ) : | ||
| 52 | 52 | have hc' : C*(1/(4*(1+C+R))) ≤ 1/4 := by |
| 53 | 53 | rw [mul_one_div] |
| 54 | 54 | apply (div_le_iff₀ hd).mpr |
| 55 | - nlinarith | |
| 55 | + linarith | |
| 56 | 56 | have hr' : R*(1/(4*(1+C+R))) ≤ 1/4 := by |
| 57 | 57 | rw [mul_one_div] |
| 58 | 58 | apply (div_le_iff₀ hd).mpr |
| 59 | - nlinarith | |
| 59 | + linarith | |
| 60 | 60 | exact ⟨hc.trans hc',hr.trans hr'⟩ |
| 61 | 61 | |
| 62 | 62 | theorem inner_bounds_of_norm (A : Space →L[ℝ] Space) (C : ℝ) |
| @@ -71,7 +71,7 @@ theorem inner_bounds_of_norm (A : Space →L[ℝ] Space) (C : ℝ) | ||
| 71 | 71 | _ ≤ (C*‖v‖)*‖v‖ := mul_le_mul_of_nonneg_right hn (norm_nonneg _) |
| 72 | 72 | _ = _ := by ring |
| 73 | 73 | constructor |
| 74 | - · nlinarith [(abs_le.mp hi).1] | |
| 74 | + · linarith [(abs_le.mp hi).1] | |
| 75 | 75 | · exact (abs_le.mp hi).2 |
| 76 | 76 | |
| 77 | 77 | variable {G : Parent} (L : LabelData G) |
+1 −1 Euler/BaseEulerParent.lean View file
| @@ -154,7 +154,7 @@ theorem horizon_small (T B R : ℝ) (hT : 0 < T) (hB : 0 ≤ B) (hR : 0 ≤ R) : | ||
| 154 | 154 | have hd : 0 < 8*(1+B*R) := by positivity |
| 155 | 155 | have he := (le_div_iff₀ hd).1 (min_le_right T (1/(8*(1+B*R)))) |
| 156 | 156 | change horizon T B R*(8*(1+B*R)) ≤ 1 at he |
| 157 | - nlinarith | |
| 157 | + linarith | |
| 158 | 158 | |
| 159 | 159 | def ofInterval (T : ℝ) (hT : 0 < T) |
| 160 | 160 | (A A₁ : SmoothTimeField (Icc (0 : ℝ) T) Space Space) |
+1 −1 Euler/BasePacketFrequencyCost.lean View file
| @@ -33,7 +33,7 @@ theorem firstParameterSize_literal (J : ℕ) (hJ : 1 ≤ J) (X : ℝ) (hX : 1 | ||
| 33 | 33 | simpa only [mul_one] using mul_le_mul_of_nonneg_left hone (by linarith : 0 ≤ 4+solutionLabelConstant) |
| 34 | 34 | unfold firstParameterSize |
| 35 | 35 | rw [hd] |
| 36 | - nlinarith only [hT.trans ht,hh,hc] | |
| 36 | + linarith only [hT.trans ht,hh,hc] | |
| 37 | 37 | |
| 38 | 38 | def firstFrequencyConstant : ℝ := frequencyConstant*(7+solutionLabelConstant)^frequencyPower |
| 39 | 39 | def firstFrequencyPower : ℕ := 1010*frequencyPower |
+1 −1 Euler/BasePacketSetup.lean View file
| @@ -98,7 +98,7 @@ theorem packetBase_initialStrain (x : Space) (hx : x ∈ support) : | ||
| 98 | 98 | rw [norm_smul,Real.norm_eq_abs,abs_of_pos hell] |
| 99 | 99 | have hb := mul_le_mul_of_nonneg_right hell1 (norm_nonneg x) |
| 100 | 100 | have hx' := norm_lt x hx |
| 101 | - nlinarith only [hb,hx'] | |
| 101 | + linarith only [hb,hx'] | |
| 102 | 102 | |
| 103 | 103 | def firstPacketInputs : |
| 104 | 104 | ForwardInputs |
+1 −1 Euler/BoundedInverseGevrey.lean View file
| @@ -62,6 +62,6 @@ theorem solution_gevrey | ||
| 62 | 62 | have ha := mul_le_mul_of_nonneg_right hMC hS |
| 63 | 63 | have hf' := mul_le_mul_of_nonneg_right hMD (majorant_nonneg R hR0 d k) |
| 64 | 64 | change ‖iteratedFDeriv ℝ k u x‖ ≤ M*(majorant R d k+S) |
| 65 | - nlinarith | |
| 65 | + linarith | |
| 66 | 66 | |
| 67 | 67 | end EulerBoundedInverseGevrey |
+1 −1 Euler/BoundedMildContinuation.lean View file
| @@ -27,7 +27,7 @@ theorem advance_grid (S δ a : ℝ) (hδ : 0 ≤ δ) (n : ℕ) | ||
| 27 | 27 | · have hna : (n : ℝ)*δ ≤ a := by simpa only [min_eq_left hn] using hgrid |
| 28 | 28 | apply (min_le_left _ _).trans |
| 29 | 29 | push_cast |
| 30 | - nlinarith only [hna] | |
| 30 | + linarith only [hna] | |
| 31 | 31 | · have hSa : S ≤ a := by simpa only [min_eq_right (le_of_not_ge hn)] using hgrid |
| 32 | 32 | exact (min_le_right _ _).trans (by linarith) |
| 33 | 33 | · exact min_le_right _ _ |
+8 −8 Euler/ChildParticleFieldBounds.lean View file
| @@ -98,7 +98,7 @@ theorem parentComposed_bound (U : SmoothL2Field Space) (hU : HasLabelBound G.K U | ||
| 98 | 98 | (by linarith [G.amp_nonneg]) (by linarith [G.rad_nonneg]) G.inner_positive |
| 99 | 99 | U G.K G.K G.K_nonneg G.K_nonneg (hasJetBound_of_labelBound U G.K hU) |
| 100 | 100 | exact h.mono G.K_nonneg (G.compositionRadius_nonneg G.K G.K_nonneg) le_rfl |
| 101 | - (G.compositionRadius_le_radius G.K (by nlinarith [G.K_nonneg])) | |
| 101 | + (G.compositionRadius_le_radius G.K (by linarith [G.K_nonneg])) | |
| 102 | 102 | |
| 103 | 103 | def firstCoefficient (U : SmoothL2Field Space) (x : Space) : Space →L[ℝ] Space := |
| 104 | 104 | fderiv ℝ U.field (G.inner x) |
| @@ -117,8 +117,8 @@ theorem firstCoefficient_bound (U : SmoothL2Field Space) (hU : HasLabelBound G.K | ||
| 117 | 117 | have hc := hd.comp G.inner_smooth (U.smooth.fderiv_right (m := ∞) (by simp)) |
| 118 | 118 | G.firstAmplitude_nonneg (by linarith [G.amp_nonneg]) (by linarith [G.rad_nonneg]) |
| 119 | 119 | (mul_nonneg (by norm_num) G.K_nonneg) G.inner_positive |
| 120 | - exact hc.mono G.firstAmplitude_nonneg (G.compositionRadius_nonneg _ (by nlinarith [G.K_nonneg])) | |
| 121 | - le_rfl (G.compositionRadius_le_radius (4*G.K) (by nlinarith [G.K_nonneg])) | |
| 120 | + exact hc.mono G.firstAmplitude_nonneg (G.compositionRadius_nonneg _ (by linarith [G.K_nonneg])) | |
| 121 | + le_rfl (G.compositionRadius_le_radius (4*G.K) (by linarith [G.K_nonneg])) | |
| 122 | 122 | |
| 123 | 123 | theorem secondCoefficient_bound (U : SmoothL2Field Space) (hU : HasLabelBound G.K U) : |
| 124 | 124 | HasSupBound (G.secondCoefficient U) G.secondAmplitude G.radius := by |
| @@ -128,10 +128,10 @@ theorem secondCoefficient_bound (U : SmoothL2Field Space) (hU : HasLabelBound G. | ||
| 128 | 128 | have hc := hd.comp G.inner_smooth |
| 129 | 129 | ((U.smooth.fderiv_right (m := ∞) (by simp)).fderiv_right (m := ∞) (by simp)) |
| 130 | 130 | G.secondAmplitude_nonneg (by linarith [G.amp_nonneg]) (by linarith [G.rad_nonneg]) |
| 131 | - (by nlinarith [G.K_nonneg]) G.inner_positive | |
| 131 | + (by linarith [G.K_nonneg]) G.inner_positive | |
| 132 | 132 | have he : (4 : ℝ)*(4*G.K)=16*G.K := by ring |
| 133 | 133 | rw [he] at hc |
| 134 | - exact hc.mono G.secondAmplitude_nonneg (G.compositionRadius_nonneg _ (by nlinarith [G.K_nonneg])) | |
| 134 | + exact hc.mono G.secondAmplitude_nonneg (G.compositionRadius_nonneg _ (by linarith [G.K_nonneg])) | |
| 135 | 135 | le_rfl (G.compositionRadius_le_radius (16*G.K) le_rfl) |
| 136 | 136 | |
| 137 | 137 | theorem velocity_bound_radius : G.velocity.HasJetBound G.amp G.radius := |
| @@ -210,16 +210,16 @@ theorem childDisplacement_bound : G.childDisplacement.HasJetBound G.amplitude G. | ||
| 210 | 210 | have h₁ := mul_nonneg G.firstAmplitude_nonneg G.amp_nonneg |
| 211 | 211 | have h₂ := mul_nonneg G.secondAmplitude_nonneg (sq_nonneg G.amp) |
| 212 | 212 | unfold amplitude |
| 213 | - nlinarith | |
| 213 | + linarith | |
| 214 | 214 | |
| 215 | 215 | theorem childVelocity_bound : G.childVelocity.HasJetBound G.amplitude G.radius := by |
| 216 | 216 | have h := ((G.parentComposed_bound G.parentVelocity G.parentVelocity_bound).add G.velocity_bound_radius).add |
| 217 | 217 | (G.firstTerm_bound G.parentDisplacement G.parentDisplacement_bound) |
| 218 | 218 | have h₁ := mul_nonneg G.firstAmplitude_nonneg G.amp_nonneg |
| 219 | 219 | have h₂ := mul_nonneg G.secondAmplitude_nonneg (sq_nonneg G.amp) |
| 220 | - apply h.mono (by nlinarith [G.K_nonneg,G.amp_nonneg]) G.radius_nonneg _ le_rfl | |
| 220 | + apply h.mono (by linarith [G.K_nonneg,G.amp_nonneg]) G.radius_nonneg _ le_rfl | |
| 221 | 221 | unfold amplitude |
| 222 | - nlinarith | |
| 222 | + linarith | |
| 223 | 223 | |
| 224 | 224 | theorem childAcceleration_bound : G.childAcceleration.HasJetBound G.amplitude G.radius := by |
| 225 | 225 | have h := (((((G.parentComposed_bound G.parentAcceleration G.parentAcceleration_bound).add |
+3 −3 Euler/ChildParticleSourceBound.lean View file
| @@ -36,7 +36,7 @@ theorem amplitude_le_power (k : ℝ) (hk1 : 1 ≤ k) | ||
| 36 | 36 | unfold amplitude secondAmplitude firstAmplitude |
| 37 | 37 | ring |
| 38 | 38 | calc |
| 39 | - G.amplitude ≤ (2+45*embeddingCost)*k^5 := by rw [he]; nlinarith [hs] | |
| 39 | + G.amplitude ≤ (2+45*embeddingCost)*k^5 := by rw [he]; linarith [hs] | |
| 40 | 40 | _ ≤ k*k^5 := mul_le_mul_of_nonneg_right hbig (pow_nonneg hk0 5) |
| 41 | 41 | _ = k^6 := by ring |
| 42 | 42 | |
| @@ -49,7 +49,7 @@ theorem radius_le_power (k : ℝ) (hk : 69 ≤ k) | ||
| 49 | 49 | have hamp : 1+G.amp ≤ 2*k := by linarith |
| 50 | 50 | have h16 : 16*G.K ≤ 16*k := mul_le_mul_of_nonneg_left hK (by norm_num) |
| 51 | 51 | have hm := mul_le_mul hamp h16 (mul_nonneg (by norm_num) G.K_nonneg) (mul_nonneg (by norm_num) hk0) |
| 52 | - have hinner : (1+G.amp)*(16*G.K)+2 ≤ 34*k^2 := by nlinarith [hm] | |
| 52 | + have hinner : (1+G.amp)*(16*G.K)+2 ≤ 34*k^2 := by linarith [hm] | |
| 53 | 53 | have hinner0 : 0 ≤ (1+G.amp)*(16*G.K)+2 := by |
| 54 | 54 | have := G.amp_nonneg |
| 55 | 55 | have := G.K_nonneg |
| @@ -58,7 +58,7 @@ theorem radius_le_power (k : ℝ) (hk : 69 ≤ k) | ||
| 58 | 58 | have hk24 : k^2 ≤ k^4 := pow_le_pow_right₀ hk1 (by omega) |
| 59 | 59 | have hsum := add_le_add hprod (hR.trans hk24) |
| 60 | 60 | calc |
| 61 | - G.radius ≤ 69*k^4 := by unfold radius compositionRadius; nlinarith [hsum] | |
| 61 | + G.radius ≤ 69*k^4 := by unfold radius compositionRadius; linarith [hsum] | |
| 62 | 62 | _ ≤ k*k^4 := mul_le_mul_of_nonneg_right hk (pow_nonneg hk0 4) |
| 63 | 63 | _ = k^5 := by ring |
| 64 | 64 | |
+2 −2 Euler/CoefficientPathBounds.lean View file
| @@ -53,7 +53,7 @@ theorem coefficientJet_boundLevel_le_words (s n : ℕ) (t : K) : | ||
| 53 | 53 | cases n with |
| 54 | 54 | | zero => |
| 55 | 55 | rw [wordSum_zero,translateCoefficientPath_zero] |
| 56 | - simp only [coefficientJet,boundLevel,smoothCoefficient] | |
| 56 | + simp only [coefficientJet,boundLevel] | |
| 57 | 57 | exact A.norm_coe_le_norm t |
| 58 | 58 | | succ n => |
| 59 | 59 | simp only [coefficientJet,boundLevel] |
| @@ -62,7 +62,7 @@ theorem coefficientJet_boundLevel_le_words (s n : ℕ) (t : K) : | ||
| 62 | 62 | cases n with |
| 63 | 63 | | zero => |
| 64 | 64 | rw [wordSum_zero,translateCoefficientPath_zero] |
| 65 | - simp only [coefficientJet,boundLevel,smoothCoefficient] | |
| 65 | + simp only [coefficientJet,boundLevel] | |
| 66 | 66 | exact A.norm_coe_le_norm t |
| 67 | 67 | | succ n => |
| 68 | 68 | rw [wordSum_succ coefficientDirections (translateCoefficientPath A) hA n 0] |
+0 −31 Euler/CorrectionParity.lean View file
| @@ -52,17 +52,6 @@ theorem coefficient_oddReflection {q : ℕ} {A : SmoothCoefficient period} | ||
| 52 | 52 | simp only [oddReflection_apply, map_neg] |
| 53 | 53 | exact congrArg Neg.neg (coefficient_reflection period K hA u) |
| 54 | 54 | |
| 55 | -/-- The actual pressure inverse commutes with signed reflection for an even metric. -/ | |
| 56 | -theorem pressure_oddReflection {q : ℕ} {A : SmoothCoefficient period} | |
| 57 | - (K : CoefficientJet period standardDirection q A) | |
| 58 | - (hA : ∀ x, A.coefficient (-x) = A.coefficient x) | |
| 59 | - (κ : ℝ) (m : Vector3) (c : ℝ) (hc : 0 < c) | |
| 60 | - (hpos : ∀ x v, c * ‖v‖ ^ 2 ≤ ⟪A.coefficient x v,v⟫_ℝ) (u : SobolevSpace period q) : | |
| 61 | - oddReflection period q (pressureSobolevOperator period K κ m c hc hpos u) = | |
| 62 | - pressureSobolevOperator period K κ m c hc hpos (oddReflection period q u) := by | |
| 63 | - simp only [oddReflection_apply, map_neg] | |
| 64 | - exact congrArg Neg.neg (pressureSobolev_reflection period K hA κ m c hc hpos u) | |
| 65 | - | |
| 66 | 55 | /-- The actual pressure-corrected source commutes with signed reflection. -/ |
| 67 | 56 | theorem projectedSource_oddReflection {q : ℕ} {A : SmoothCoefficient period} |
| 68 | 57 | (K : CoefficientJet period standardDirection q A) |
| @@ -99,26 +88,6 @@ theorem rawSource_oddReflection {q : ℕ} (hq : 6 ≤ q) {T : Type*} [Topologica | ||
| 99 | 88 | exact linearized_source_equivariant (oddReflection period (q+1)) (oddReflection period q) F C |
| 100 | 89 | (D.approximation t) (D.residual t) hF hC hz hr e |
| 101 | 90 | |
| 102 | -/-- The genuine correction pressure transforms by signed reflection, | |
| 103 | -with its sign fixed by the actual pressure definition. -/ | |
| 104 | -theorem correction_pressure_oddReflection {q : ℕ} (hq : 6 ≤ q) {T : Type*} [TopologicalSpace T] | |
| 105 | - (D : CorrectionData period q T) (t : T) | |
| 106 | - (hG : ∀ x, (D.metric.coefficient t).coefficient (-x) = (D.metric.coefficient t).coefficient x) | |
| 107 | - (hL : ∀ x, (D.linear.coefficient t).coefficient (-x) = (D.linear.coefficient t).coefficient x) | |
| 108 | - (hQ : ∀ i x, ((D.quadratic i).coefficient t).coefficient (-x) = -((D.quadratic i).coefficient t).coefficient x) | |
| 109 | - (hz : oddReflection period (q+1) (D.approximation t) = D.approximation t) | |
| 110 | - (hr : oddReflection period q (D.residual t) = D.residual t) | |
| 111 | - (e : SobolevSpace period (q+1)) : | |
| 112 | - oddReflection period q (D.pressure period hq t e) = | |
| 113 | - D.pressure period hq t (oddReflection period (q+1) e) := by | |
| 114 | - change oddReflection period q (-(pressureSobolevOperator period (D.metric.jet t) D.κ D.direction | |
| 115 | - D.coercivity D.coercivity_pos (D.metric_pos t) (D.rawSource period hq t e))) = _ | |
| 116 | - rw [map_neg] | |
| 117 | - exact congrArg Neg.neg ((pressure_oddReflection period (D.metric.jet t) hG D.κ D.direction | |
| 118 | - D.coercivity D.coercivity_pos (D.metric_pos t) (D.rawSource period hq t e)).trans | |
| 119 | - (congrArg (pressureSobolevOperator period (D.metric.jet t) D.κ D.direction D.coercivity D.coercivity_pos | |
| 120 | - (D.metric_pos t)) (rawSource_oddReflection period hq D t hL hQ hz hr e))) | |
| 121 | - | |
| 122 | 91 | /-- The literal projected nonlinear correction equation has the required |
| 123 | 92 | odd symmetry, derived from the concrete parity of its prescribed fields. -/ |
| 124 | 93 | theorem correction_source_oddReflection {q : ℕ} (hq : 6 ≤ q) {T : Type*} [TopologicalSpace T] |
+2 −2 Euler/DivCurlRecovery.lean View file
| @@ -118,7 +118,7 @@ theorem gradient_energy_recovery (M : ℝ) | ||
| 118 | 118 | intro x |
| 119 | 119 | have hp := mul_le_mul_of_nonneg_left |
| 120 | 120 | (pow_le_pow_left₀ (norm_nonneg _) (hgrad n x) 2) (sq_nonneg (h x)) |
| 121 | - nlinarith | |
| 121 | + linarith | |
| 122 | 122 | have hp : -(∫ x, cutoff n x ^ 2 * (h x * Δ h x)) ≤ ∫ x, |h x * Δ h x| := by |
| 123 | 123 | rw [← integral_neg] |
| 124 | 124 | apply integral_mono hsource.neg hs |
| @@ -190,7 +190,7 @@ theorem exists_gradient_energy_square_bound : ∃ C : ℝ, 0 ≤ C ∧ | ||
| 190 | 190 | intro x |
| 191 | 191 | change |h x * Δ h x| ≤ h x ^ 2 + (Δ h x) ^ 2 |
| 192 | 192 | apply abs_le.mpr |
| 193 | - constructor <;> nlinarith [sq_nonneg (h x - Δ h x), sq_nonneg (h x + Δ h x)] | |
| 193 | + constructor <;> linarith [sq_nonneg (h x - Δ h x), sq_nonneg (h x + Δ h x)] | |
| 194 | 194 | linarith [(hM h hh hL2 hcΔ).2] |
| 195 | 195 | |
| 196 | 196 | /-- Compact vorticity forces the Laplacian to be compactly supported. No |
+1 −1 Euler/DriftCorrectionForcing.lean View file
| @@ -115,7 +115,7 @@ theorem correctionForcing_bound {s : ℕ} (hs : 6 ≤ s) {A : SmoothCoefficient | ||
| 115 | 115 | change externalPressureNorm period K N ρ p0 + basePressureNorm period K0 N hN ρ p0 ≤ _ at hp0 |
| 116 | 116 | change externalPressureNorm period K N ρ p1 ≤ _ at hp1e |
| 117 | 117 | change basePressureNorm period K0 N hN ρ p1 ≤ _ at hp1b |
| 118 | - nlinarith only [h, hp0, hp1e, hp1b] | |
| 118 | + linarith only [h, hp0, hp1e, hp1b] | |
| 119 | 119 | |
| 120 | 120 | /-- Uniform fixed-base constants preserve the separate drift norm. -/ |
| 121 | 121 | theorem correctionForcing_uniform_bound {s : ℕ} (hs : 6 ≤ s) {A : SmoothCoefficient period} |
+1 −1 Euler/DriftMetricForcing.lean View file
| @@ -81,6 +81,6 @@ theorem correctionForcing_metric {s : ℕ} (hs : 6 ≤ s) {A : SmoothCoefficient | ||
| 81 | 81 | |
| 82 | 82 | simpa only [EulerDriftEnergyConstants.forcingPolynomial, |
| 83 | 83 | EulerNonlinearEnergyConstants.linearCoefficient, EulerNonlinearEnergyConstants.quadraticCoefficient, |
| 84 | - EulerNonlinearEnergyConstants.lossCoefficient, mul_assoc, mul_left_comm, mul_comm] using hconv | |
| 84 | + EulerNonlinearEnergyConstants.lossCoefficient, mul_assoc, mul_left_comm] using hconv | |
| 85 | 85 | |
| 86 | 86 | end EulerDriftMetricForcing |
+2 −2 Euler/DriftNonlinearEstimate.lean View file
| @@ -22,7 +22,7 @@ theorem drift_loss_absorption (P M Rc ρ B E Y D : ℝ) | ||
| 22 | 22 | have hc : 4*(P*ρ⁻¹+8*Rc*M*P) ≤ ((4+32*M)*P)*(ρ⁻¹+Rc) := by |
| 23 | 23 | have h1 := mul_nonneg hP hRc |
| 24 | 24 | have h2 := mul_nonneg (mul_nonneg hM hP) (inv_nonneg.mpr hρ.le) |
| 25 | - nlinarith only [h1,h2] | |
| 25 | + linarith only [h1,h2] | |
| 26 | 26 | calc |
| 27 | 27 | _ ≤ (P*ρ⁻¹+8*Rc*M*P)*(4*(B+E))*Y := |
| 28 | 28 | mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hD ha) hY |
| @@ -87,7 +87,7 @@ theorem correctionForcing_polynomial {s : ℕ} (hs : 6 ≤ s) {A : SmoothCoeffic | ||
| 87 | 87 | 4*(B0+weightedNorm period 6 N ρ e) := by |
| 88 | 88 | have h := (weightedDriftNorm_add_le period 6 N (by omega : N+6 ≤ s+1) ρ hρ (velocityMap L) z e).trans |
| 89 | 89 | (add_le_add hb heD) |
| 90 | - nlinarith only [h,hB0] | |
| 90 | + linarith only [h,hB0] | |
| 91 | 91 | have hraw := EulerDriftCorrectionForcing.correctionForcing_uniform_bound period hs KG KG0 κ m c hc hpos |
| 92 | 92 | N hN ρ Rc M B hρ hRc hM hbase5 hbase6 hsmall hcoeff hG hG0 L hL (z+e) e f |
| 93 | 93 | have hloss : (productConstant period 3*ρ⁻¹+8*Rc*M*productConstant period 3)* |
+1 −1 Euler/FieldTowerPhysicalL2.lean View file
| @@ -23,7 +23,7 @@ theorem frequencyFactor_le_linear (k : ℝ) (hk : 1 ≤ k) (m : Vector3) : | ||
| 23 | 23 | (‖coordinateEquiv.symm.toContinuousLinearMap‖*(1+‖m‖))*k := by |
| 24 | 24 | unfold frequencyFactor |
| 25 | 25 | rw [abs_of_nonneg (by linarith)] |
| 26 | - have h := mul_le_mul_of_nonneg_left (by nlinarith : 1+k*‖m‖ ≤ (1+‖m‖)*k) | |
| 26 | + have h := mul_le_mul_of_nonneg_left (by linarith : 1+k*‖m‖ ≤ (1+‖m‖)*k) | |
| 27 | 27 | (norm_nonneg coordinateEquiv.symm.toContinuousLinearMap) |
| 28 | 28 | exact h.trans_eq (mul_assoc _ _ _).symm |
| 29 | 29 | |
+1 −1 Euler/FlowEscapeBound.lean View file
| @@ -163,7 +163,7 @@ theorem escape_measure_le_of_action | ||
| 163 | 163 | _ = T * (∫ x, action x ∂μ) := integral_const_mul _ _ |
| 164 | 164 | apply (le_div_iff₀ (sq_pos_of_pos (sub_pos.mpr hKR))).mpr |
| 165 | 165 | have hc := mul_le_mul_of_nonneg_left haenergy hT |
| 166 | - nlinarith | |
| 166 | + linarith | |
| 167 | 167 | |
| 168 | 168 | /-- A finite-energy measure-preserving flow can carry at most |
| 169 | 169 | `energy * T^2 / (R-K)^2` measure of points from radius `K` to radius `R`. |
+1 −1 Euler/GaussianHeatGenerator.lean View file
| @@ -54,7 +54,7 @@ theorem realLineHeat_hasDerivAt_moment (a : LiftTangent) (f g : LiftL2 period) | ||
| 54 | 54 | have hbound : ∀ x s : ℝ, s ∈ Set.Ioi (t/2) → ‖F' s x‖ ≤ B x := by |
| 55 | 55 | intro x s hs |
| 56 | 56 | have hspos : 0 < s := hhalf.trans hs |
| 57 | - dsimp [F', B] | |
| 57 | + dsimp [F'] | |
| 58 | 58 | rw [norm_smul, lineOrbit_norm, Real.norm_eq_abs, abs_div, |
| 59 | 59 | abs_of_pos (mul_pos (by norm_num) (Real.sqrt_pos.mpr hspos))] |
| 60 | 60 | exact mul_le_mul_of_nonneg_right |
+1 −1 Euler/GevreyCompactProduct.lean View file
| @@ -23,7 +23,7 @@ theorem product_bound_at (f g : E → ℝ) (hf : ContDiff ℝ ∞ f) (hg : ContD | ||
| 23 | 23 | (fun k => by simpa only [abs_norm] using hb₁ k) |
| 24 | 24 | (fun k => by simpa only [abs_norm] using hb₂ k) n |
| 25 | 25 | exact (norm_iteratedFDeriv_mul_le hf hg x (by simp)).trans |
| 26 | - ((le_abs_self _).trans (by simpa using hp)) | |
| 26 | + ((le_abs_self _).trans (hp)) | |
| 27 | 27 | |
| 28 | 28 | theorem majorant_one_le (R : ℝ) (hR : 1 ≤ R) (n : ℕ) : 1 ≤ majorant R 0 n := by |
| 29 | 29 | have hf : (1 : ℝ) ≤ n.factorial := by exact_mod_cast Nat.succ_le_of_lt (Nat.factorial_pos n) |
+2 −2 Euler/GevreyCompositionPartitions.lean View file
| @@ -35,7 +35,7 @@ lemma sum_partSize_succ_sq_le (c : OrderedFinpartition n) : | ||
| 35 | 35 | apply Finset.sum_le_sum |
| 36 | 36 | intro i _ |
| 37 | 37 | have hi : (c.partSize i : ℝ) ≤ n := by exact_mod_cast c.partSize_le i |
| 38 | - nlinarith [mul_nonneg (sub_nonneg.mpr hi) (show 0 ≤ (c.partSize i : ℝ) + 1 by positivity)] | |
| 38 | + linarith [mul_nonneg (sub_nonneg.mpr hi) (show 0 ≤ (c.partSize i : ℝ) + 1 by positivity)] | |
| 39 | 39 | _ = ((n : ℝ) + 1) * ((n : ℝ) + c.length) := by |
| 40 | 40 | rw [← Finset.mul_sum, Finset.sum_add_distrib, sum_partSize_real] |
| 41 | 41 | simp |
| @@ -86,7 +86,7 @@ lemma partitionWeight_extendLeft (x : ℝ) (c : OrderedFinpartition n) : | ||
| 86 | 86 | (x * ((c.length : ℝ) + 1)^2) * partitionWeight x c := by |
| 87 | 87 | simp only [partitionWeight, OrderedFinpartition.extendLeft_length, |
| 88 | 88 | factorialProduct_extendLeft, Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, |
| 89 | - Nat.cast_one, pow_succ] | |
| 89 | + Nat.cast_one] | |
| 90 | 90 | ring |
| 91 | 91 | |
| 92 | 92 | lemma partitionWeight_extendMiddle (x : ℝ) (c : OrderedFinpartition n) (i : Fin c.length) : |
+3 −3 Euler/GevreyFixedShift.lean View file
| @@ -16,7 +16,7 @@ theorem succ_le_two_pow_real (n : ℕ) : (n : ℝ)+1 ≤ (2 : ℝ)^n := by | ||
| 16 | 16 | | zero => norm_num |
| 17 | 17 | | succ n ih => |
| 18 | 18 | rw [Nat.cast_add, Nat.cast_one, pow_succ] |
| 19 | - nlinarith [show (0 : ℝ) ≤ n by positivity] | |
| 19 | + linarith [show (0 : ℝ) ≤ n by positivity] | |
| 20 | 20 | |
| 21 | 21 | /-- One fixed factorial shift is a fixed radius enlargement for coefficients. -/ |
| 22 | 22 | theorem majorant_one_le_radius_four (R : ℝ) (hR : 0 ≤ R) (n : ℕ) : |
| @@ -28,12 +28,12 @@ theorem majorant_one_le_radius_four (R : ℝ) (hR : 0 ≤ R) (n : ℕ) : | ||
| 28 | 28 | _ = (4 : ℝ)^n := by rw [← pow_mul, Nat.mul_comm, pow_mul]; norm_num |
| 29 | 29 | calc |
| 30 | 30 | majorant R 1 n = (R*(R^n*(n.factorial : ℝ)^2))*((n : ℝ)+1)^2 := by |
| 31 | - simp only [majorant, Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, Nat.cast_one, pow_succ] | |
| 31 | + simp only [majorant, Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, Nat.cast_one] | |
| 32 | 32 | ring |
| 33 | 33 | _ ≤ (R*(R^n*(n.factorial : ℝ)^2))*(4 : ℝ)^n := |
| 34 | 34 | mul_le_mul_of_nonneg_left hs (by positivity) |
| 35 | 35 | _ = R*majorant (4*R) 0 n := by |
| 36 | - simp only [majorant, Nat.add_zero, mul_pow] | |
| 36 | + simp only [majorant, Nat.add_zero] | |
| 37 | 37 | ring |
| 38 | 38 | |
| 39 | 39 | end EulerGevrey |
+4 −4 Euler/GevreyFlowBootstrap.lean View file
| @@ -61,7 +61,7 @@ theorem rationalRate_le (B R a u : ℝ) (hB : 0 ≤ B) | ||
| 61 | 61 | have hd : 0 < 1-R*(a+u) := by linarith |
| 62 | 62 | unfold rationalRate |
| 63 | 63 | apply (div_le_iff₀ hd).2 |
| 64 | - nlinarith [mul_le_mul_of_nonneg_left hu hB] | |
| 64 | + linarith [mul_le_mul_of_nonneg_left hu hB] | |
| 65 | 65 | |
| 66 | 66 | /-- The nonlinear generating-sum inequality closes at BRT≤1/8. The bound |
| 67 | 67 | is linear in the velocity size B and time, with no exponential factor. -/ |
| @@ -78,14 +78,14 @@ theorem rational_integral_bootstrap (f : ℝ → ℝ) (T B R : ℝ) | ||
| 78 | 78 | by_contra h |
| 79 | 79 | have hm := mul_le_mul_of_nonneg_left (le_of_not_gt h) hR.le |
| 80 | 80 | rw [hRa] at hm |
| 81 | - nlinarith | |
| 81 | + linarith | |
| 82 | 82 | have hb : ∀ t ∈ Icc 0 T, f t ≤ B*t := by |
| 83 | 83 | apply continuous_barrier f T B ((4*R)⁻¹) hT hB ha hBT hf hf0 |
| 84 | 84 | intro t ht hbefore |
| 85 | 85 | have hhalf : ∀ s ∈ Icc 0 t, R*((4*R)⁻¹+f s) ≤ 1/2 := by |
| 86 | 86 | intro s hs |
| 87 | 87 | have hm := mul_le_mul_of_nonneg_left (hbefore s hs) hR.le |
| 88 | - nlinarith | |
| 88 | + linarith | |
| 89 | 89 | have hden : ∀ s ∈ Icc 0 t, 1-R*((4*R)⁻¹+f s) ≠ 0 := by |
| 90 | 90 | intro s hs |
| 91 | 91 | have hh := hhalf s hs |
| @@ -105,6 +105,6 @@ theorem rational_integral_bootstrap (f : ℝ → ℝ) (T B R : ℝ) | ||
| 105 | 105 | refine ⟨hb t ht,?_⟩ |
| 106 | 106 | have hm := mul_le_mul_of_nonneg_left (hb t ht) hR.le |
| 107 | 107 | have htB := mul_le_mul_of_nonneg_left ht.2 (mul_nonneg hB hR.le) |
| 108 | - nlinarith | |
| 108 | + linarith | |
| 109 | 109 | |
| 110 | 110 | end EulerGevreyFlowBootstrap |
+1 −1 Euler/GevreyGeneratingDerivatives.lean View file
| @@ -106,7 +106,7 @@ theorem rational_fraction_mono (B x y : ℝ) (hB : 0 ≤ B) | ||
| 106 | 106 | have hx : 0 < 1-x := by linarith |
| 107 | 107 | have hy' : 0 < 1-y := by linarith |
| 108 | 108 | apply (div_le_div_iff₀ hx hy').2 |
| 109 | - nlinarith [mul_le_mul_of_nonneg_left hxy hB] | |
| 109 | + linarith [mul_le_mul_of_nonneg_left hxy hB] | |
| 110 | 110 | |
| 111 | 111 | /-- The identity part of a flow costs exactly z in its generating sum. -/ |
| 112 | 112 | theorem derivativeSum_comp_id_add_le (f : E → E) (g : E → F) (N : ℕ) |
+1 −1 Euler/GevreyGrowthBudget.lean View file
| @@ -38,7 +38,7 @@ theorem growthSlope_budget (K : SmoothCoefficient period) (κ : ℝ) (m : Vector | ||
| 38 | 38 | have h := mul_le_mul hL (add_le_add hκ hm) (add_nonneg (abs_nonneg κ) (norm_nonneg m)) hL0 |
| 39 | 39 | unfold growthSlope growthBudgetSlope |
| 40 | 40 | apply div_le_div_of_nonneg_right _ (mul_nonneg (by norm_num) (sq_nonneg c)) |
| 41 | - nlinarith only [h] | |
| 41 | + linarith only [h] | |
| 42 | 42 | |
| 43 | 43 | /-- Uniform actual coefficient budgets majorize the complete viscous growth coefficient. -/ |
| 44 | 44 | theorem viscousGrowth_budget (K : SmoothCoefficient period) (K' : LiftL2 period →L[ℝ] LiftL2 period) |
+2 −2 Euler/GevreyGrowthCoefficient.lean View file
| @@ -27,7 +27,7 @@ theorem viscousGrowth_uniform (K : SmoothCoefficient period) (K' : LiftL2 period | ||
| 27 | 27 | have hheat : 0 ≤ heatEnergyConstant period K c := by unfold heatEnergyConstant; positivity |
| 28 | 28 | have hv := mul_le_mul_of_nonneg_right hν hheat |
| 29 | 29 | have hn : ‖K'‖+2*transportEnergyConstant period K κ m B+2*ν*heatEnergyConstant period K c ≤ |
| 30 | - ‖K'‖+2*transportEnergyConstant period K κ m B+2*heatEnergyConstant period K c := by nlinarith only [hv] | |
| 30 | + ‖K'‖+2*transportEnergyConstant period K κ m B+2*heatEnergyConstant period K c := by linarith only [hv] | |
| 31 | 31 | have h := div_le_div_of_nonneg_right hn (mul_nonneg (by norm_num : (0 : ℝ) ≤ 2) (sq_nonneg c)) |
| 32 | 32 | exact h.trans_eq (by unfold growthBase growthSlope transportEnergyConstant; ring) |
| 33 | 33 | |
| @@ -52,6 +52,6 @@ theorem absorb_scalar_coefficients (g0 g1 f0 f1 f2 d r X Y B R C : ℝ) | ||
| 52 | 52 | have h1 := mul_le_mul_of_nonneg_right hc1 hX |
| 53 | 53 | have h2 := mul_le_mul_of_nonneg_right hc2 (sq_nonneg X) |
| 54 | 54 | have h3 := mul_le_mul_of_nonneg_right hcd (mul_nonneg (mul_nonneg hR (add_nonneg hB hX)) hY) |
| 55 | - nlinarith only [h0,h1,h2,h3] | |
| 55 | + linarith only [h0,h1,h2,h3] | |
| 56 | 56 | |
| 57 | 57 | end EulerGevreyGrowthCoefficient |
+3 −4 Euler/GevreyInverseMap.lean View file
| @@ -88,7 +88,7 @@ def inverseMapRadius (C R : ℝ) : ℝ := 1 + 2*C*R | ||
| 88 | 88 | lemma inverseMapRadius_ge_one (C R : ℝ) (hC : 0 ≤ C) (hR : 0 ≤ R) : |
| 89 | 89 | 1 ≤ inverseMapRadius C R := by |
| 90 | 90 | unfold inverseMapRadius |
| 91 | - nlinarith [mul_nonneg hC hR] | |
| 91 | + linarith [mul_nonneg hC hR] | |
| 92 | 92 | |
| 93 | 93 | lemma inverseMapRadius_pos (C R : ℝ) (hC : 0 ≤ C) (hR : 0 ≤ R) : |
| 94 | 94 | 0 < inverseMapRadius C R := lt_of_lt_of_le zero_lt_one (inverseMapRadius_ge_one C R hC hR) |
| @@ -110,7 +110,7 @@ theorem norm_iteratedFDeriv_of_fderiv_eq_comp | ||
| 110 | 110 | have hhalf : (C/L)*R ≤ 1/2 := by |
| 111 | 111 | rw [div_mul_eq_mul_div, div_le_iff₀ hL] |
| 112 | 112 | dsimp [L, inverseMapRadius] |
| 113 | - nlinarith | |
| 113 | + linarith | |
| 114 | 114 | change ‖iteratedFDeriv ℝ (n+1) Y x‖ ≤ C * L^n * (n.factorial : ℝ)^2 |
| 115 | 115 | induction n using Nat.strong_induction_on generalizing x with |
| 116 | 116 | | h n ih => |
| @@ -118,8 +118,7 @@ theorem norm_iteratedFDeriv_of_fderiv_eq_comp | ||
| 118 | 118 | · subst n |
| 119 | 119 | change ‖iteratedFDeriv ℝ 1 Y x‖ ≤ C * L^0 * (Nat.factorial 0 : ℝ)^2 |
| 120 | 120 | rw [norm_iteratedFDeriv_one, hDY] |
| 121 | - simpa only [norm_iteratedFDeriv_zero, pow_zero, Nat.factorial_zero, | |
| 122 | - Nat.cast_one, one_pow, mul_one] using hAjet 0 (Y x) | |
| 121 | + simpa only [norm_iteratedFDeriv_zero, pow_zero, Nat.cast_one, one_pow, mul_one] using hAjet 0 (Y x) | |
| 123 | 122 | · have hnpos : 0 < n := Nat.pos_of_ne_zero hn |
| 124 | 123 | have hinner (j : ℕ) (hj : 0 < j) (hjn : j ≤ n) : |
| 125 | 124 | ‖iteratedFDeriv ℝ j Y x‖ ≤ (C/L) * L^j * ((j-1).factorial : ℝ)^2 := by |
+4 −5 Euler/GevreyInversePartitions.lean View file
| @@ -40,7 +40,7 @@ lemma sum_partSize_sq_le (c : OrderedFinpartition n) : | ||
| 40 | 40 | have hmul := mul_le_mul_of_nonneg_right |
| 41 | 41 | (show (c.partSize i : ℝ) ≤ (n : ℝ) - c.length + 1 by linarith) |
| 42 | 42 | (show 0 ≤ (c.partSize i : ℝ) by positivity) |
| 43 | - nlinarith | |
| 43 | + linarith | |
| 44 | 44 | _ = _ := by rw [← Finset.mul_sum, sum_partSize_real] |
| 45 | 45 | |
| 46 | 46 | def predecessorFactorialProduct (c : OrderedFinpartition n) : ℝ := |
| @@ -90,7 +90,7 @@ lemma predecessorPartitionWeight_extendLeft (x : ℝ) (c : OrderedFinpartition n | ||
| 90 | 90 | (x * ((c.length : ℝ) + 1)^2) * predecessorPartitionWeight x c := by |
| 91 | 91 | simp only [predecessorPartitionWeight, OrderedFinpartition.extendLeft_length, |
| 92 | 92 | predecessorFactorialProduct_extendLeft, Nat.factorial_succ, Nat.cast_mul, |
| 93 | - Nat.cast_add, Nat.cast_one, pow_succ] | |
| 93 | + Nat.cast_add, Nat.cast_one] | |
| 94 | 94 | ring |
| 95 | 95 | |
| 96 | 96 | lemma predecessorPartitionWeight_extendMiddle (x : ℝ) (c : OrderedFinpartition n) |
| @@ -131,7 +131,7 @@ lemma predecessorPartitionSum_succ_le (n : ℕ) (hn : 0 < n) | ||
| 131 | 131 | (show 0 ≤ (c.length : ℝ)+1 by positivity) |
| 132 | 132 | have hscalar := mul_le_mul_of_nonneg_right hxhalf (sq_nonneg ((c.length : ℝ)+1)) |
| 133 | 133 | have hs := sum_partSize_sq_le c |
| 134 | - nlinarith | |
| 134 | + linarith | |
| 135 | 135 | |
| 136 | 136 | /-- Unlike the unshifted weights, these weights have a uniformly bounded |
| 137 | 137 | normalized sum on the scalar interval `[0, 1/2]`. -/ |
| @@ -147,8 +147,7 @@ theorem predecessorPartitionSum_le (n : ℕ) (hn : 0 < n) | ||
| 147 | 147 | calc |
| 148 | 148 | _ ≤ ((m+1 : ℕ) + 1 : ℝ)^2 * predecessorPartitionSum (m+1) x := |
| 149 | 149 | predecessorPartitionSum_succ_le (m+1) (by omega) x hx hxhalf |
| 150 | - _ ≤ ((m+1 : ℕ) + 1 : ℝ)^2 * (x * ((m+1).factorial : ℝ)^2) := by | |
| 151 | - exact mul_le_mul_of_nonneg_left (ih (by omega)) (sq_nonneg _) | |
| 150 | + _ ≤ ((m+1 : ℕ) + 1 : ℝ)^2 * (x * ((m+1).factorial : ℝ)^2) := mul_le_mul_of_nonneg_left (ih (by omega)) (sq_nonneg _) | |
| 152 | 151 | _ = _ := by |
| 153 | 152 | change ((m+1 : ℕ) + 1 : ℝ)^2 * (x * ((m+1).factorial : ℝ)^2) = |
| 154 | 153 | x * (((m+1)+1).factorial : ℝ)^2 |
+4 −4 Euler/GevreyMetricEstimate.lean View file
| @@ -49,7 +49,7 @@ theorem weightedNorm_le_energy {s : ℕ} (N : ℕ) (hN : N+6 ≤ s) (ρ : ℝ) ( | ||
| 49 | 49 | have he := energyNorm_nonneg period N hN ρ hρ K u |
| 50 | 50 | change weightedNorm period 6 N ρ u ≤ (Real.sqrt 5461/c)*energyNorm period N hN ρ K u at h |
| 51 | 51 | unfold metricAmplification |
| 52 | - nlinarith only [h,he] | |
| 52 | + linarith only [h,he] | |
| 53 | 53 | |
| 54 | 54 | /-- The actual radius-loss sum obeys the identical fixed metric conversion. -/ |
| 55 | 55 | theorem weightedLoss_le_energy {s : ℕ} (N : ℕ) (hN : N+6 ≤ s) (ρ : ℝ) (hρ : 0 < ρ) |
| @@ -61,7 +61,7 @@ theorem weightedLoss_le_energy {s : ℕ} (N : ℕ) (hN : N+6 ≤ s) (ρ : ℝ) ( | ||
| 61 | 61 | have he := energyLoss_nonneg period N hN ρ hρ K u |
| 62 | 62 | change weightedLoss period 6 N ρ u ≤ (Real.sqrt 5461/c)*energyLoss period N hN ρ K u at h |
| 63 | 63 | unfold metricAmplification |
| 64 | - nlinarith only [h,he] | |
| 64 | + linarith only [h,he] | |
| 65 | 65 | |
| 66 | 66 | /-- Exact scalar conversion of a Sobolev forcing polynomial to metric energy and metric radius loss. -/ |
| 67 | 67 | theorem metric_polynomial_conversion (S0 S1 S2 D R B a E Y X Z H : ℝ) |
| @@ -72,8 +72,8 @@ theorem metric_polynomial_conversion (S0 S1 S2 D R B a E Y X Z H : ℝ) | ||
| 72 | 72 | H ≤ S0*R+(S1*a)*X+(S2*a^2)*X^2+(D*a^2)*(B+X)*Z := by |
| 73 | 73 | have ha0 : 0 ≤ a := by linarith |
| 74 | 74 | have hsq : E^2 ≤ a^2*X^2 := by |
| 75 | - simpa only [pow_two, mul_assoc, mul_left_comm, mul_comm] using mul_le_mul hE hE hE0 (mul_nonneg ha0 hX0) | |
| 76 | - have hBE : B+E ≤ a*(B+X) := by nlinarith only [hE, mul_le_mul_of_nonneg_right ha hB] | |
| 75 | + simpa only [pow_two, mul_assoc, mul_left_comm] using mul_le_mul hE hE hE0 (mul_nonneg ha0 hX0) | |
| 76 | + have hBE : B+E ≤ a*(B+X) := by linarith only [hE, mul_le_mul_of_nonneg_right ha hB] | |
| 77 | 77 | have hBY : (B+E)*Y ≤ a^2*(B+X)*Z := by |
| 78 | 78 | have h := mul_le_mul hBE hY hY0 (mul_nonneg ha0 (add_nonneg hB hX0)) |
| 79 | 79 | exact h.trans_eq (by ring) |
+1 −1 Euler/GevreyNonlinearEstimate.lean View file
| @@ -44,7 +44,7 @@ theorem orderZeroSource_uniform {s : ℕ} (hs : 6 ≤ s) (N : ℕ) (hN : N+6 ≤ | ||
| 44 | 44 | weightedCoefficient period K0 6 N ρ+ |
| 45 | 45 | 2*(∑ i : Fin 3, weightedCoefficient period (K i) 6 N ρ)*productConstant period 3*weightedNorm period 6 N ρ z ≤ |
| 46 | 46 | productConstant period 3*B1+A0+2*A2*productConstant period 3*B0 := by |
| 47 | - nlinarith only [hlin] | |
| 47 | + linarith only [hlin] | |
| 48 | 48 | exact h.trans (add_le_add (add_le_add hR (mul_le_mul_of_nonneg_right hlin' hE)) |
| 49 | 49 | (mul_le_mul_of_nonneg_right hquad (sq_nonneg _))) |
| 50 | 50 | |
+2 −2 Euler/GevreyRadiusReduction.lean View file
| @@ -82,7 +82,7 @@ theorem successor_square_le_four_two_pow (n : ℕ) : | ||
| 82 | 82 | have hn : (2 : ℝ) ≤ n := by exact_mod_cast (show 2 ≤ n by omega) |
| 83 | 83 | have hs : ((n+1+1 : ℕ) : ℝ)^2 ≤ 2*((n+1 : ℕ) : ℝ)^2 := by |
| 84 | 84 | push_cast |
| 85 | - nlinarith [sq_nonneg ((n : ℝ)-2)] | |
| 85 | + linarith [sq_nonneg ((n : ℝ)-2)] | |
| 86 | 86 | calc |
| 87 | 87 | _ ≤ 2*((n+1 : ℕ) : ℝ)^2 := hs |
| 88 | 88 | _ ≤ 2*(4*(2 : ℝ)^n) := mul_le_mul_of_nonneg_left ih (by norm_num) |
| @@ -102,7 +102,7 @@ theorem weight_half_le_shift (R : ℝ) (hR : 0 < R) (n : ℕ) : | ||
| 102 | 102 | rw [he, div_div] |
| 103 | 103 | apply (div_le_div_iff₀ (mul_pos hp (sq_pos_of_pos hf)) (by positivity)).mpr |
| 104 | 104 | have hm := mul_le_mul_of_nonneg_left hn (mul_nonneg (pow_nonneg hR.le n) (sq_nonneg (n.factorial : ℝ))) |
| 105 | - nlinarith only [hm] | |
| 105 | + linarith only [hm] | |
| 106 | 106 | |
| 107 | 107 | /-- Halving the positive radius pays for one full spatial/angular derivative, |
| 108 | 108 | with no dependence on the external cutoff. -/ |
+1 −1 Euler/GevreyStabilityBudget.lean View file
| @@ -29,7 +29,7 @@ theorem coefficient_bound_le_block {s : ℕ} {A : SmoothCoefficient period} | ||
| 29 | 29 | rw [hzero] at hsingle |
| 30 | 30 | unfold coefficientBlock |
| 31 | 31 | norm_num only [Nat.reduceAdd,zero_add,pow_succ,pow_zero,one_mul] |
| 32 | - nlinarith only [hsum,hsingle] | |
| 32 | + linarith only [hsum,hsingle] | |
| 33 | 33 | |
| 34 | 34 | omit [Fact (0 < period)] in |
| 35 | 35 | /-- The actual uniform coefficient bound is contained in every positive-radius truncated Gevrey coefficient sum. -/ |
+2 −2 Euler/H6PressureConstants.lean View file
| @@ -82,7 +82,7 @@ theorem productConstant_polynomial {q : ℕ} {A : SmoothCoefficient period} | ||
| 82 | 82 | _ ≤ L + ∑ _i : Fin 4, ((9 : ℝ) ^ q * L + (9 : ℝ) ^ q * L) := |
| 83 | 83 | add_le_add hzero (Finset.sum_le_sum (fun i _ => add_le_add hbase (hchild i))) |
| 84 | 84 | _ = L + 8 * ((9 : ℝ) ^ q * L) := by simp; ring |
| 85 | - _ ≤ (9 : ℝ) ^ (q + 1) * L := by rw [pow_succ]; nlinarith only [hpower] | |
| 85 | + _ ≤ (9 : ℝ) ^ (q + 1) * L := by rw [pow_succ]; linarith only [hpower] | |
| 86 | 86 | |
| 87 | 87 | /-- A simple bound used to keep the inverse majorant polynomial at each fixed order. -/ |
| 88 | 88 | theorem succ_le_three_pow (q : ℕ) : q + 1 ≤ 3 ^ q := by |
| @@ -114,7 +114,7 @@ theorem inverse_majorant_step {L B M : ℝ} (hL : 1 ≤ L) (hB : L ≤ B) (hM : | ||
| 114 | 114 | have hcube := mul_le_mul_of_nonneg_right hM2 hM0 |
| 115 | 115 | have hprod := mul_le_mul_of_nonneg_right hM (sq_nonneg M) |
| 116 | 116 | have hcubepos : 0 ≤ M ^ 3 := by positivity |
| 117 | - nlinarith only [hLleM, hcube, hprod, hcubepos] | |
| 117 | + linarith only [hLleM, hcube, hprod, hcubepos] | |
| 118 | 118 | |
| 119 | 119 | omit [Fact (0 < period)] in |
| 120 | 120 | /-- Every fixed-order coercive inverse constant is bounded by an explicit polynomial in L. |
+1 −1 Euler/H6TransportSource.lean View file
| @@ -184,6 +184,6 @@ theorem transport_shifted_weighted_bound (q N : ℕ) (ρ : ℝ) (hρ : 0 < ρ) | ||
| 184 | 184 | (fun l => wordSobolevNorm period 6 l b) (fun l => wordSobolevNorm period 6 l e) |
| 185 | 185 | (fun l => wordSobolevNorm_nonneg period 6 l b) (fun l => wordSobolevNorm_nonneg period 6 l e)) |
| 186 | 186 | (productConstant_nonneg period q) |
| 187 | - simpa only [mul_assoc, mul_left_comm, mul_comm] using h | |
| 187 | + simpa only [mul_assoc, mul_left_comm] using h | |
| 188 | 188 | |
| 189 | 189 | end EulerH6Nonlinear |
+1 −1 Euler/InitialDataBridge.lean View file
| @@ -27,6 +27,6 @@ theorem initialVelocityConditionDecay_of_compact | ||
| 27 | 27 | have hgc : HasCompactSupport g := (hc.iteratedFDeriv m).norm.mul_left |
| 28 | 28 | obtain ⟨x₀, hx₀⟩ := hg.exists_forall_ge_of_hasCompactSupport hgc |
| 29 | 29 | refine ⟨g x₀, fun x => (le_div_iff₀ (Real.rpow_pos_of_pos (hpos x) K)).mpr ?_⟩ |
| 30 | - simpa only [g, mul_comm] using hx₀ x | |
| 30 | + simpa only [mul_comm] using hx₀ x | |
| 31 | 31 | |
| 32 | 32 | end Euler |
+1 −1 Euler/IntegralEnergyBootstrap.lean View file
| @@ -92,7 +92,7 @@ theorem close_integral_energy_estimate | ||
| 92 | 92 | have hCsq := mul_le_mul_of_nonneg_left hFsq hC.le |
| 93 | 93 | have hCr := mul_le_mul_of_nonneg_left hFr hC.le |
| 94 | 94 | have hpos := mul_pos hC hFt |
| 95 | - nlinarith | |
| 95 | + linarith | |
| 96 | 96 | intro t ht |
| 97 | 97 | exact ⟨hbound t ht, (hbound t ht).trans (hFle t ht)⟩ |
| 98 | 98 | |
+2 −2 Euler/LinearDuhamelSobolevGevrey.lean View file
| @@ -79,10 +79,10 @@ theorem weightedSolution_block_gevrey_at | ||
| 79 | 79 | exact le_add_of_nonneg_right (mul_nonneg hcost (add_nonneg hCF hDF)) |
| 80 | 80 | have hMC : sobolevInverseCost 1 CF q*CF ≤ M := by |
| 81 | 81 | rw [hMeq] |
| 82 | - nlinarith [mul_nonneg hcost hDF] | |
| 82 | + linarith [mul_nonneg hcost hDF] | |
| 83 | 83 | have hMD : sobolevInverseCost 1 CF q*DF ≤ M := by |
| 84 | 84 | rw [hMeq] |
| 85 | - nlinarith [mul_nonneg hcost hCF] | |
| 85 | + linarith [mul_nonneg hcost hCF] | |
| 86 | 86 | have hAₓ : ContDiff ℝ ∞ Aₓ := frozenOperator_contDiff T hT B U g hg hB x |
| 87 | 87 | have hFₓ : ContDiff ℝ ∞ Fₓ := frozenForcing_contDiff T hT B U g hg f a₀ hf ha₀ x |
| 88 | 88 | have hu : ContDiff ℝ ∞ u := weightedSolution_contDiff T hT B U g hg f a₀ hB hf ha₀ |
+1 −1 Euler/LinearDuhamelWeighted.lean View file
| @@ -58,7 +58,7 @@ theorem weightedForcing_norm (hg₀ : g ⟨0,le_rfl,hT⟩ = 1) (C : ℝ) (hC : 0 | ||
| 58 | 58 | (fun s => (weight_pointwise_bound g (fun s => (hg s).le) f s).trans_eq (mul_comm _ _)) t |
| 59 | 59 | have ht := mul_le_mul_of_nonneg_right t.property.2 |
| 60 | 60 | (mul_nonneg (mul_nonneg hC (hg t).le) (norm_nonneg f)) |
| 61 | - nlinarith | |
| 61 | + linarith | |
| 62 | 62 | |
| 63 | 63 | /-- The normalized constructed path, with normalized forcing as input. -/ |
| 64 | 64 | def weightedSolution (f : C(Icc (0 : ℝ) T,E)) (a₀ : E) : C(Icc (0 : ℝ) T,E) := |
+1 −1 Euler/LocalFlowTrap.lean View file
| @@ -74,6 +74,6 @@ theorem norm_lt_of_local_speed_bound (X : ℝ → E) (V : ℝ → E → E) | ||
| 74 | 74 | _ ≤ ‖X s - X 0‖ + ‖X 0‖ := norm_add_le _ _ |
| 75 | 75 | _ ≤ M * s + A := add_le_add hdisplacement hinitial |
| 76 | 76 | have hbudget : M * s ≤ M * δ := mul_le_mul_of_nonneg_left hsI.2 hM |
| 77 | - nlinarith | |
| 77 | + linarith | |
| 78 | 78 | |
| 79 | 79 | end EulerComparatorLocalFlow |
+3 −3 Euler/LogarithmicCutoffOptimization.lean View file
| @@ -24,7 +24,7 @@ theorem optimize (X c L W H : ℝ) (hc : 0 ≤ c) (hL : 0 ≤ L) (hH : 0 ≤ H) | ||
| 24 | 24 | have he0 : 0 < ε := exp_pos _ |
| 25 | 25 | have he1 : ε < 1 := by |
| 26 | 26 | have hneg : -4*log A < 0 := by linarith |
| 27 | - simpa only [ε,exp_zero] using exp_lt_exp.mpr hneg | |
| 27 | + simpa only [exp_zero] using exp_lt_exp.mpr hneg | |
| 28 | 28 | have heLog : -log ε=4*log A := by simp only [ε,log_exp]; ring |
| 29 | 29 | have hePow : ε^(1/4 : ℝ)=A⁻¹ := by |
| 30 | 30 | dsimp [ε] |
| @@ -39,9 +39,9 @@ theorem optimize (X c L W H : ℝ) (hc : 0 ≤ c) (hL : 0 ≤ L) (hH : 0 ≤ H) | ||
| 39 | 39 | have hmid : X ≤ c*(L+4*(W*log A)+1) := by |
| 40 | 40 | apply h.trans |
| 41 | 41 | apply mul_le_mul_of_nonneg_left _ hc |
| 42 | - nlinarith only [hsmall] | |
| 42 | + linarith only [hsmall] | |
| 43 | 43 | have hdiff : 0 ≤ c*(3+3*L) := mul_nonneg hc (by linarith) |
| 44 | 44 | change X ≤ 4*c*(1+L+W*log A) |
| 45 | - nlinarith only [hmid,hdiff] | |
| 45 | + linarith only [hmid,hdiff] | |
| 46 | 46 | |
| 47 | 47 | end EulerLogarithmicCutoff |
+1 −1 Euler/MetricRootLimit.lean View file
| @@ -16,7 +16,7 @@ theorem regularized_root_le (q δ : ℝ) (hq : 0 ≤ q) (hδ : 0 ≤ δ) : | ||
| 16 | 16 | refine ⟨add_nonneg (sqrt_nonneg q) hδ, ?_⟩ |
| 17 | 17 | have hsq := sq_sqrt hq |
| 18 | 18 | have hp := mul_nonneg (sqrt_nonneg q) hδ |
| 19 | - nlinarith | |
| 19 | + linarith | |
| 20 | 20 | |
| 21 | 21 | /-- The canonical positive regularization sequence converges at every quadratic energy value. -/ |
| 22 | 22 | theorem regularized_root_tendsto (q : ℝ) : |
+1 −1 Euler/MixedH5Product.lean View file
| @@ -34,7 +34,7 @@ theorem scalar_word_pointwise {k : ℕ} (hk : k ≤ 2) (w : Fin k → Fin 4) | ||
| 34 | 34 | apply h.trans (h2.trans _) |
| 35 | 35 | unfold mixedConstant |
| 36 | 36 | have hpos := mul_nonneg (cylinderEmbeddingConstant_nonneg period) (liftSobolevNorm_nonneg period 5 f) |
| 37 | - nlinarith | |
| 37 | + linarith | |
| 38 | 38 | |
| 39 | 39 | /-- Low vector derivatives are bounded by the original H⁵ norm. -/ |
| 40 | 40 | theorem vector_word_pointwise {k : ℕ} (hk : k ≤ 2) (w : Fin k → Fin 4) |
+2 −3 Euler/OperatorGevreyCalculus.lean View file
| @@ -19,8 +19,7 @@ open ContinuousLinearMap EulerGevrey EulerTransverseGramInverse | ||
| 19 | 19 | |
| 20 | 20 | /-- Enlarging the radius enlarges the factorial majorant. -/ |
| 21 | 21 | theorem majorant_radius_mono (R S : ℝ) (hR : 0 ≤ R) (hRS : R ≤ S) (d n : ℕ) : |
| 22 | - majorant R d n ≤ majorant S d n := by | |
| 23 | - exact mul_le_mul_of_nonneg_right (pow_le_pow_left₀ hR hRS (n+d)) (sq_nonneg _) | |
| 22 | + majorant R d n ≤ majorant S d n := mul_le_mul_of_nonneg_right (pow_le_pow_left₀ hR hRS (n+d)) (sq_nonneg _) | |
| 24 | 23 | |
| 25 | 24 | section Normed |
| 26 | 25 | |
| @@ -75,7 +74,7 @@ theorem bilinear_bound (B : E →L[ℝ] F →L[ℝ] G) (hB : ‖B‖ ≤ 1) | ||
| 75 | 74 | (fun k => by simpa only [abs_norm] using hb k x) |
| 76 | 75 | (fun k => by simpa only [abs_norm] using hc k x) n |
| 77 | 76 | exact (B.norm_iteratedFDeriv_le_of_bilinear_of_le_one hf hg x (by simp) hB).trans |
| 78 | - ((le_abs_self _).trans (by simpa using hp)) | |
| 77 | + ((le_abs_self _).trans (hp)) | |
| 79 | 78 | |
| 80 | 79 | /-- Actual operator application has the shifted factorial product bound. -/ |
| 81 | 80 | theorem clm_apply_bound (A : P → E →L[ℝ] F) (u : P → E) |
+1 −1 Euler/OrdinaryEulerLocalCauchy.lean View file
| @@ -42,7 +42,7 @@ theorem short_uniform_h3 (V : ℕ → Evolution T hT) (hpos : 0 < T) | ||
| 42 | 42 | have hLT : L ≤ T := min_le_left _ _ |
| 43 | 43 | have hLe : 3*C*L ≤ log 2 := by |
| 44 | 44 | have h := (le_div_iff₀ (show 0 < 3*C by positivity)).mp (min_le_right T (log 2/(3*C))) |
| 45 | - nlinarith only [h] | |
| 45 | + linarith only [h] | |
| 46 | 46 | have hexp : exp (3*C*L) ≤ 2 := by |
| 47 | 47 | have h := exp_le_exp.mpr hLe |
| 48 | 48 | rwa [exp_log (by norm_num : (0 : ℝ) < 2)] at h |
+2 −2 Euler/OrdinaryGradientProducts.lean View file
| @@ -68,7 +68,7 @@ theorem secondWord_product_gradient (A : SmoothL2Field Space) (K N : ℝ) | ||
| 68 | 68 | (wordField (mapField (EuclideanSpace.proj i) A) w) |
| 69 | 69 | (wordField (mapField (EuclideanSpace.proj j) A) v) |
| 70 | 70 | have hc (j : Fin 3) (x : Space) : (C j).field x=(B.field x) j := by |
| 71 | - simp only [C,B,wordField_map,mapField_field,scalarProduct_field, | |
| 71 | + simp only [C,B,wordField_map,scalarProduct_field, | |
| 72 | 72 | coordinateProduct_field,PiLp.smul_apply,smul_eq_mul] |
| 73 | 73 | rfl |
| 74 | 74 | have hn (j : Fin 3) : |
| @@ -95,7 +95,7 @@ theorem coordinateProduct_gradient (A : SmoothL2Field Space) (K N : ℝ) | ||
| 95 | 95 | ‖(coordinateProduct i (wordField A w) (wordField A v)).toLp‖ ≤ 9*K*N := by |
| 96 | 96 | have hK0 : 0 ≤ K := (norm_nonneg (fderiv ℝ A.field 0)).trans (hK 0) |
| 97 | 97 | have hN0 := wordBound_nonneg hN |
| 98 | - have hc : K*N ≤ 9*K*N := by nlinarith [mul_nonneg hK0 hN0] | |
| 98 | + have hc : K*N ≤ 9*K*N := by linarith [mul_nonneg hK0 hN0] | |
| 99 | 99 | by_cases hk1 : k=1 |
| 100 | 100 | · subst k |
| 101 | 101 | have hs (x : Space) : |
+5 −5 Euler/OrdinaryH3Envelope.lean View file
| @@ -28,9 +28,9 @@ theorem regularized_energy_bound (e ep M δ : ℝ) (he : 0 ≤ e) (hM : 0 ≤ M) | ||
| 28 | 28 | let s := sqrt (e+δ^2) |
| 29 | 29 | have hs : 0 < s := sqrt_pos.mpr (by nlinarith) |
| 30 | 30 | have hs2 : s^2=e+δ^2 := sq_sqrt (by positivity) |
| 31 | - have he2 : e ≤ s^2 := by nlinarith [sq_nonneg δ] | |
| 31 | + have he2 : e ≤ s^2 := by linarith [sq_nonneg δ] | |
| 32 | 32 | have hse : sqrt e ≤ 40*s := by |
| 33 | - have hl : sqrt e ≤ s := sqrt_le_sqrt (by nlinarith [sq_nonneg δ]) | |
| 33 | + have hl : sqrt e ≤ s := sqrt_le_sqrt (by linarith [sq_nonneg δ]) | |
| 34 | 34 | linarith |
| 35 | 35 | have hC := h3ProductConstant_nonneg |
| 36 | 36 | have hb : ep ≤ 3600*h3ProductConstant*(M+40*s)*s^2 := by |
| @@ -43,7 +43,7 @@ theorem regularized_energy_bound (e ep M δ : ℝ) (he : 0 ≤ e) (hM : 0 ≤ M) | ||
| 43 | 43 | apply hd.trans |
| 44 | 44 | have hx : 0 ≤ 40*s := by positivity |
| 45 | 45 | have ha : (M+40*s)*(40*s) ≤ (1+M)*(40*s+(40*s)^2) := by |
| 46 | - nlinarith [mul_nonneg hM (sq_nonneg (40*s))] | |
| 46 | + linarith [mul_nonneg hM (sq_nonneg (40*s))] | |
| 47 | 47 | calc |
| 48 | 48 | _ = (1800*h3ProductConstant)*((M+40*s)*(40*s)) := by ring |
| 49 | 49 | _ ≤ (1800*h3ProductConstant)*((1+M)*(40*s+(40*s)^2)) := |
| @@ -109,7 +109,7 @@ theorem normEnvelope_initial (U V : Evolution T hT) (ε : ℝ) (hε : 0 < ε) | ||
| 109 | 109 | change U.energyPath V ⟨0,le_rfl,hT⟩ ≤ _ at hb |
| 110 | 110 | nlinarith [sqrt_nonneg (U.energyPath V ⟨0,le_rfl,hT⟩+ε^2)] |
| 111 | 111 | change 40*sqrt _ ≤ 320*ε |
| 112 | - nlinarith | |
| 112 | + linarith | |
| 113 | 113 | |
| 114 | 114 | theorem h3_stability (U V : Evolution T hT) (M ε : ℝ) |
| 115 | 115 | (hM : ∀ t, WordBound 4 M (U.velocity t)) (hε : 0 < ε) |
| @@ -122,7 +122,7 @@ theorem h3_stability (U V : Evolution T hT) (M ε : ℝ) | ||
| 122 | 122 | (extendPath T hT (U.normEnvelope V ε)) |
| 123 | 123 | (fun r => U.envelopeDerivative V ε (projIcc 0 T hT r)) |
| 124 | 124 | (stabilityConstant M) (320*ε) T hMp (by positivity) hT |
| 125 | - (by nlinarith [hsmall]) (extendPath_continuous T hT (U.normEnvelope V ε)).continuousOn | |
| 125 | + (by linarith [hsmall]) (extendPath_continuous T hT (U.normEnvelope V ε)).continuousOn | |
| 126 | 126 | (by simpa only [extendPath,projIcc_of_mem hT ⟨le_rfl,hT⟩] using U.normEnvelope_initial V ε hε hinit) |
| 127 | 127 | (fun r hr => by |
| 128 | 128 | have h := U.normEnvelope_hasDerivWithinAt V ε hε ⟨r,hr.1,hr.2.le⟩ |
+2 −2 Euler/OrdinaryH3Products.lean View file
| @@ -23,11 +23,11 @@ theorem h3ProductConstant_nonneg : 0 ≤ h3ProductConstant := by | ||
| 23 | 23 | |
| 24 | 24 | theorem h3ProductConstant_left : 13*smoothEmbeddingConstant ≤ h3ProductConstant := by |
| 25 | 25 | unfold h3ProductConstant |
| 26 | - nlinarith [sq_nonneg (1+3*(sobolevConstant : ℝ))] | |
| 26 | + linarith [sq_nonneg (1+3*(sobolevConstant : ℝ))] | |
| 27 | 27 | |
| 28 | 28 | theorem h3ProductConstant_middle : 4*(1+3*(sobolevConstant : ℝ))^2 ≤ h3ProductConstant := by |
| 29 | 29 | unfold h3ProductConstant |
| 30 | - nlinarith [smoothEmbeddingConstant_nonneg] | |
| 30 | + linarith [smoothEmbeddingConstant_nonneg] | |
| 31 | 31 | |
| 32 | 32 | theorem scalarProduct_h1_bound (A : SmoothL2Field ℝ) (B : SmoothL2Field Space) : |
| 33 | 33 | ‖(scalarProduct A B).toLp‖ ≤ |
+1 −1 Euler/OrdinaryPerturbedEnergy.lean View file
| @@ -59,7 +59,7 @@ theorem perturbed_difference_energy (A B : SmoothL2Field Space) | ||
| 59 | 59 | have hpair : 2*⟪W,e⟫_ℝ ≤ ‖W‖^2+(ea+eb)^2 := by |
| 60 | 60 | have hi : ⟪W,e⟫_ℝ ≤ ‖W‖*(ea+eb) := |
| 61 | 61 | (real_inner_le_norm _ _).trans (mul_le_mul_of_nonneg_left hn (norm_nonneg W)) |
| 62 | - nlinarith [sq_nonneg (‖W‖-(ea+eb))] | |
| 62 | + linarith [sq_nonneg (‖W‖-(ea+eb))] | |
| 63 | 63 | rw [he,inner_add_right,mul_add] |
| 64 | 64 | exact (add_le_add (projected_difference_energy A B hA hB K hK) hpair).trans_eq (by dsimp [W]; ring) |
| 65 | 65 | |
+1 −1 Euler/OrdinaryPressureCancellation.lean View file
| @@ -69,7 +69,7 @@ theorem gradient_mem_of_symmetric (A : SmoothL2Field Space) | ||
| 69 | 69 | rw [hcurl,hdiv] at h |
| 70 | 70 | have hc : vectorCurl (0 : Space → Space) x=0 := by |
| 71 | 71 | ext i |
| 72 | - simp [vectorCurl,curl,partialDerivative] | |
| 72 | + simp [vectorCurl,partialDerivative] | |
| 73 | 73 | have hg : gradient (0 : Space → ℝ) x=0 := by simp [gradient] |
| 74 | 74 | simp only [hc,hg,Pi.sub_apply,zero_sub] at h |
| 75 | 75 | exact neg_eq_zero.mp h.symm |
+1 −1 Euler/OrdinaryQuadraticStability.lean View file
| @@ -36,7 +36,7 @@ theorem quadratic_stability_within (X X' : ℝ → ℝ) (C ε T : ℝ) | ||
| 36 | 36 | rw [he] at hb |
| 37 | 37 | have hfsq : (F t)^2 ≤ F t := by nlinarith [hFp t] |
| 38 | 38 | have hh := mul_le_mul_of_nonneg_left hfsq hC.le |
| 39 | - nlinarith [mul_pos hC (hFp t)] | |
| 39 | + linarith [mul_pos hC (hFp t)] | |
| 40 | 40 | intro t ht |
| 41 | 41 | apply (hbound t ht).trans |
| 42 | 42 | dsimp [F] |
+2 −2 Euler/OrdinaryRegularizedCauchy.lean View file
| @@ -55,7 +55,7 @@ theorem regularized_l2_comparison {T : ℝ} {hT : 0 ≤ T} {j k : ℕ} | ||
| 55 | 55 | (wordBound_gradient (wordBound_mono (hU _) (by omega))) |
| 56 | 56 | (regularized_rhs_error j _ (U.solenoidal _) M (hU _)) |
| 57 | 57 | (regularized_rhs_error k _ (V.solenoidal _) M (hV _)) |
| 58 | - simpa only [X,X',C,E,add_mul] using h | |
| 58 | + simpa only [X,C,E,add_mul] using h | |
| 59 | 59 | have hnorm (t : Icc (0 : ℝ) T) : |
| 60 | 60 | ‖(V.velocity t).toLp-(U.velocity t).toLp‖ ≤ E*Real.sqrt (Real.exp (C*T)) := by |
| 61 | 61 | have h := forced_linear_zero_bound T C E hC X X' hc hx0 hd hb t t.property |
| @@ -86,6 +86,6 @@ theorem regularized_cauchy {T : ℝ} {hT : 0 ≤ T} | ||
| 86 | 86 | apply (regularized_l2_comparison (U j) (U k) M (hM j) (hM k) (hinit j k)).trans_lt |
| 87 | 87 | have hj' := hN j hj |
| 88 | 88 | have hk' := hN k hk |
| 89 | - nlinarith | |
| 89 | + linarith | |
| 90 | 90 | |
| 91 | 91 | end EulerOrdinarySobolev |
+2 −2 Euler/OrdinaryRegularizedEnergy.lean View file
| @@ -82,7 +82,7 @@ theorem energy_quadratic (t : Icc (0 : ℝ) T) : | ||
| 82 | 82 | have hs := Real.sq_sqrt hx |
| 83 | 83 | have hsq : Real.sqrt (U.energy 3 t)*U.energy 3 t ≤ (1+U.energy 3 t)^2 := by |
| 84 | 84 | have hl : Real.sqrt (U.energy 3 t) ≤ 1+U.energy 3 t := by nlinarith |
| 85 | - nlinarith [mul_le_mul_of_nonneg_right hl hx] | |
| 85 | + linarith [mul_le_mul_of_nonneg_right hl hx] | |
| 86 | 86 | simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hsq (tameEnergyConstant_nonneg 3) |
| 87 | 87 | |
| 88 | 88 | theorem short_energy (hsmall : tameEnergyConstant 3*T ≤ (1+U.energy 3 ⟨0,le_rfl,hT⟩)⁻¹/2) |
| @@ -143,7 +143,7 @@ theorem regularized_h3 (A : SmoothL2Field Space) {S : SmoothingOperator} | ||
| 143 | 143 | have hs : tameEnergyConstant 3*regularizedTime A ≤ (1+wordEnergy 3 A)⁻¹/2 := by |
| 144 | 144 | calc |
| 145 | 145 | _ ≤ (1+tameEnergyConstant 3)*regularizedTime A := by |
| 146 | - nlinarith [regularizedTime_pos A] | |
| 146 | + linarith [regularizedTime_pos A] | |
| 147 | 147 | _ = _ := by unfold regularizedTime; field_simp [hc.ne',ha.ne'] |
| 148 | 148 | have hu := U.short_energy (by simpa only [he] using hs) t |
| 149 | 149 | rw [he] at hu |
+1 −1 Euler/OrdinarySobolevL4.lean View file
| @@ -83,7 +83,7 @@ private theorem square_domination (a z : ℝ) (ha : 0 < a) (hz : 0 ≤ z) : | ||
| 83 | 83 | have he : a*z+a⁻¹*z^3=(a^2*z+z^3)/a := by field_simp |
| 84 | 84 | rw [he] |
| 85 | 85 | apply (le_div_iff₀ ha).mpr |
| 86 | - nlinarith | |
| 86 | + linarith | |
| 87 | 87 | |
| 88 | 88 | theorem square_memLp {f : Space → E} (h2 : MemLp f 2 volume) (h6 : MemLp f 6 volume) : |
| 89 | 89 | MemLp (fun x => ‖f x‖^2) 2 volume := by |
+1 −1 Euler/ParameterSobolevGevrey.lean View file
| @@ -119,6 +119,6 @@ theorem block_inverse_gevrey (directions : ι → P) (q : ℕ) | ||
| 119 | 119 | have h₁ := mul_le_mul_of_nonneg_right hMC hS |
| 120 | 120 | have h₂ := mul_le_mul_of_nonneg_right hMD (majorant_nonneg R hR0 d k) |
| 121 | 121 | change block directions q u k x ≤ M*(majorant R d k+S) |
| 122 | - nlinarith | |
| 122 | + linarith | |
| 123 | 123 | |
| 124 | 124 | end EulerParameterWordGevrey |
+1 −1 Euler/ParameterSobolevGevreyAt.lean View file
| @@ -61,6 +61,6 @@ theorem block_inverse_gevrey_at (directions : ι → P) (q : ℕ) | ||
| 61 | 61 | have h₁ := mul_le_mul_of_nonneg_right hMC hS |
| 62 | 62 | have h₂ := mul_le_mul_of_nonneg_right hMD (majorant_nonneg R hR0 d k) |
| 63 | 63 | change block directions q u k x ≤ M*(majorant R d k+S) |
| 64 | - nlinarith | |
| 64 | + linarith | |
| 65 | 65 | |
| 66 | 66 | end EulerParameterWordGevrey |
+1 −1 Euler/ParentEulerLowBounds.lean View file
| @@ -23,7 +23,7 @@ theorem quadratic_lower_of_difference (M N : Matrix) (C e : ℝ) | ||
| 23 | 23 | -(C+e)*‖z‖^2 ≤ ⟪N z,z⟫_ℝ := by |
| 24 | 24 | have h := quadratic_lower_of_norm (N-M) e he z |
| 25 | 25 | simp only [sub_apply,inner_sub_left] at h |
| 26 | - nlinarith only [h,hC z] | |
| 26 | + linarith only [h,hC z] | |
| 27 | 27 | |
| 28 | 28 | end EulerPacketPhysicalLowBounds |
| 29 | 29 | |
+2 −2 Euler/ParentHistoryFrequencyGuard.lean View file
| @@ -28,7 +28,7 @@ theorem frequency_monotone (J : ℕ) (hJ : 2 ≤ J) (X : ℝ) (hX : 0 ≤ X) : | ||
| 28 | 28 | dsimp [j] |
| 29 | 29 | push_cast |
| 30 | 30 | ring |
| 31 | - have hstep : j+1 ≤ j^2 := by nlinarith only [hj2,sq_nonneg (j-2)] | |
| 31 | + have hstep : j+1 ≤ j^2 := by linarith only [hj2,sq_nonneg (j-2)] | |
| 32 | 32 | have hsq : (j+1)^2 ≤ (j^2)^2 := pow_le_pow_left₀ (by positivity) hstep 2 |
| 33 | 33 | apply exp_le_exp.mpr |
| 34 | 34 | change scaleSequence J X n/j^2 ≤ scaleSequence J X (n+1)/((J+(n+1) : ℕ) : ℝ)^2 |
| @@ -50,7 +50,7 @@ theorem initial_frequency_le_first (J D : ℕ) (hJ : 3 ≤ J) (X : ℝ) (hX : 0 | ||
| 50 | 50 | have hadd : (J : ℝ)=j+1 := by |
| 51 | 51 | dsimp [j] |
| 52 | 52 | exact_mod_cast (show J=J-1+1 by omega) |
| 53 | - have hstep : j+1 ≤ j^2 := by nlinarith only [hj2,sq_nonneg (j-2)] | |
| 53 | + have hstep : j+1 ≤ j^2 := by linarith only [hj2,sq_nonneg (j-2)] | |
| 54 | 54 | have hsq : (J : ℝ)^2 ≤ j^4 := by |
| 55 | 55 | rw [hadd] |
| 56 | 56 | simpa only [← pow_mul] using pow_le_pow_left₀ (by positivity) hstep 2 |
+3 −3 Euler/ParentInitializedRadiusPolynomial.lean View file
| @@ -41,12 +41,12 @@ theorem inputEnvelope_bounds (K X : ℝ) (hK : 1 ≤ K) (hKX : K ≤ X) : | ||
| 41 | 41 | have hf : EulerPacketParentLabelBounds.frameAmplitude K ≤ a := (leaf_bounds K hK0).2.2.2.1.trans hl |
| 42 | 42 | have ha : a ≤ inputEnvelope X := by |
| 43 | 43 | change a ≤ 1+X+a+3*a^3*X |
| 44 | - nlinarith only [hX0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 44 | + linarith only [hX0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 45 | 45 | refine ⟨?_,?_,hl.trans ha,hp.trans ha,?_⟩ |
| 46 | 46 | · change 1 ≤ 1+X+a+3*a^3*X |
| 47 | - nlinarith only [hX0,ha0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 47 | + linarith only [hX0,ha0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 48 | 48 | · change X ≤ 1+X+a+3*a^3*X |
| 49 | - nlinarith only [ha0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 49 | + linarith only [ha0,mul_nonneg (pow_nonneg ha0 3) hX0] | |
| 50 | 50 | · intro Cp hCp hCpX |
| 51 | 51 | have hprod : physicalCost K Cp ≤ 3*a^3*X := by |
| 52 | 52 | unfold physicalCost |
+2 −2 Euler/ParentPacketBadRatioPolynomial.lean View file
| @@ -61,7 +61,7 @@ theorem initial_history_size_le_difference : | ||
| 61 | 61 | have hx : ‖D.frame.field‖ ≤ L.frameDifferenceCost := by |
| 62 | 62 | apply hq.trans |
| 63 | 63 | unfold frameDifferenceCost |
| 64 | - nlinarith only [mul_le_mul_of_nonneg_left hR (frameAmplitude_nonneg L.K)] | |
| 64 | + linarith only [mul_le_mul_of_nonneg_left hR (frameAmplitude_nonneg L.K)] | |
| 65 | 65 | apply historyCost_le_differenceCost τ D.frameLower _ _ _ _ _ _ _ _ hτ.le D.frameLower_pos.le |
| 66 | 66 | (norm_nonneg _) (norm_nonneg _) (by positivity) (by positivity) |
| 67 | 67 | (historyTransportCost_nonneg (D := D)) hx |
| @@ -216,7 +216,7 @@ theorem badRatio_polynomial : | ||
| 216 | 216 | have hX : 1 ≤ 1+L.K+Ti+P.shear⁻¹+A.CM+A.CH := by |
| 217 | 217 | have ht := (inv_pos.mpr hτ).le.trans hTi |
| 218 | 218 | have hi := (inv_pos.mpr A.shear_pos).le |
| 219 | - nlinarith only [L.K_one,ht,hi,A.CM_nonneg,A.CH_nonneg] | |
| 219 | + linarith only [L.K_one,ht,hi,A.CM_nonneg,A.CH_nonneg] | |
| 220 | 220 | have hh := L.historySizeRatio_polynomial m hm R S hS H τ hτ hτT P A Ti hτ1 hTi |
| 221 | 221 | rw [A.badRatio_formula] |
| 222 | 222 | calc |
+1 −1 Euler/ParentPacketInitialLowBounds.lean View file
| @@ -17,7 +17,7 @@ theorem norm_le_of_shear_error (V : Matrix) (amp δ θ ev size : ℝ) (r w : Spa | ||
| 17 | 17 | (herr : ‖V-shearTerm amp (deriv (profile δ) θ) r w‖ ≤ ev) : ‖V‖ ≤ size+ev := by |
| 18 | 18 | have hshear : ‖shearTerm amp (deriv (profile δ) θ) r w‖ ≤ size := |
| 19 | 19 | (shearTerm_norm_le amp _ δ r w hamp (profile_deriv_abs δ hδ hδ1 θ)).trans |
| 20 | - ((div_le_iff₀ hδ).2 (by nlinarith only [hsize])) | |
| 20 | + ((div_le_iff₀ hδ).2 (by linarith only [hsize])) | |
| 21 | 21 | have h := norm_of_remainder V 0 (shearTerm amp (deriv (profile δ) θ) r w) ev |
| 22 | 22 | (by simpa only [sub_zero] using herr) |
| 23 | 23 | simp only [norm_zero,zero_add] at h |
+3 −3 Euler/ParentPacketNeighborPolynomial.lean View file
| @@ -102,9 +102,9 @@ theorem epsilon_inv_le_twice_shear (ha : 1/2 ≤ P.a) (hH : 1 ≤ P.shear) : | ||
| 102 | 102 | rw [epsilon,← Real.sqrt_inv,inv_div] |
| 103 | 103 | calc |
| 104 | 104 | _ ≤ Real.sqrt (2*P.shear) := Real.sqrt_le_sqrt ((div_le_iff₀ ha0).2 |
| 105 | - (by nlinarith only [mul_le_mul_of_nonneg_left ha hH0])) | |
| 105 | + (by linarith only [mul_le_mul_of_nonneg_left ha hH0])) | |
| 106 | 106 | _ ≤ 2*P.shear := Real.sqrt_le_iff.mpr ⟨by positivity, |
| 107 | - by nlinarith only [hH,sq_nonneg (P.shear-1)]⟩ | |
| 107 | + by linarith only [hH,sq_nonneg (P.shear-1)]⟩ | |
| 108 | 108 | |
| 109 | 109 | end EulerPacketSourceGeometry.ParentFrame |
| 110 | 110 | |
| @@ -204,7 +204,7 @@ theorem neighborScaleCost_low_polynomial (ha : 1/2 ≤ P.a) (hH : 1 ≤ P.shear) | ||
| 204 | 204 | have hab : 1+L.K+Ti+P.epsilon⁻¹+P.shear⁻¹+CM+CH ≤ |
| 205 | 205 | 2*(1+CM+CH)*(1+L.K+Ti+P.shear) := by |
| 206 | 206 | have hc := mul_le_mul_of_nonneg_left hbase (show 0 ≤ CM+CH by positivity) |
| 207 | - nlinarith only [hEi,hHi,hK,hTi0,hc,hCM,hCH] | |
| 207 | + linarith only [hEi,hHi,hK,hTi0,hc,hCM,hCH] | |
| 208 | 208 | have hA0 : 0 ≤ 1+L.K+Ti+P.epsilon⁻¹+P.shear⁻¹+CM+CH := by positivity |
| 209 | 209 | have hC := EulerParentNeighborCost.constant_pos |
| 210 | 210 | calc |
+2 −2 Euler/ParentPacketNeighborScaleGuard.lean View file
| @@ -22,10 +22,10 @@ theorem polynomial_le_monomial (A K Ti H k h : ℝ) (n q c : ℕ) | ||
| 22 | 22 | have hkk : k^q ≤ k^q*h := le_mul_of_one_le_right hkq0 hh |
| 23 | 23 | have hhh : h ≤ k^q*h := le_mul_of_one_le_left hh0 hkq |
| 24 | 24 | have hb : 1+K+Ti+H ≤ 4*k^q*h := by |
| 25 | - nlinarith only [hkh,hKk.trans hkk,hTik.trans hkk,hHh.trans hhh] | |
| 25 | + linarith only [hkh,hKk.trans hkk,hTik.trans hkk,hHh.trans hhh] | |
| 26 | 26 | calc |
| 27 | 27 | _ ≤ A*(4*k^q*h)^n := mul_le_mul_of_nonneg_left (pow_le_pow_left₀ (by positivity) hb n) hA |
| 28 | - _ = (A*4^n)*(k^(q*n)*h^n) := by simp only [mul_pow,← pow_mul]; ring | |
| 28 | + _ = (A*4^n)*(k^(q*n)*h^n) := by simp only [mul_pow]; ring | |
| 29 | 29 | _ ≤ k*(k^(q*n)*h^n) := mul_le_mul_of_nonneg_right hcost (by positivity) |
| 30 | 30 | _ = k^(q*n+1)*h^n := by rw [pow_succ]; ring |
| 31 | 31 | _ ≤ k^c*h^c := mul_le_mul (pow_le_pow_right₀ hk hc) (pow_le_pow_right₀ hh hn) |
+4 −4 Euler/ParentPacketParameterCaps.lean View file
| @@ -29,11 +29,11 @@ theorem boundary_parameter_bound (CM Bc L X : ℝ) (hX : 1 ≤ X) | ||
| 29 | 29 | (hBc : Bc ≤ CM*X^1000+2) (hL : L=boundaryLocalizationC1*Bc+1) : |
| 30 | 30 | L ≤ boundaryConstant CM*X^1000 := by |
| 31 | 31 | have hp : 1 ≤ X^1000 := one_le_pow₀ hX |
| 32 | - have hb : Bc ≤ (CM+2)*X^1000 := by nlinarith only [hBc,hp] | |
| 32 | + have hb : Bc ≤ (CM+2)*X^1000 := by linarith only [hBc,hp] | |
| 33 | 33 | have h := mul_le_mul_of_nonneg_left hb boundaryLocalizationC1_nonneg |
| 34 | 34 | rw [hL] |
| 35 | 35 | unfold boundaryConstant |
| 36 | - nlinarith only [h,hp] | |
| 36 | + linarith only [h,hp] | |
| 37 | 37 | |
| 38 | 38 | end EulerParentPacketParameterCaps |
| 39 | 39 | |
| @@ -69,10 +69,10 @@ theorem selected_terminal_bound (hH : 1 ≤ P.shear) : | ||
| 69 | 69 | have hEmb := embeddingCost_nonneg |
| 70 | 70 | have hFcap : frameAmplitude L.K ≤ (1+embeddingCost)*L.K^2 := by |
| 71 | 71 | unfold frameAmplitude gradientAmplitude |
| 72 | - nlinarith only [hK2] | |
| 72 | + linarith only [hK2] | |
| 73 | 73 | have hFsquare := pow_le_pow_left₀ (frameAmplitude_nonneg L.K) hFcap 2 |
| 74 | 74 | have hIcap : D.inverseBound ≤ (1+3*(1+embeddingCost)^2)*L.K^4 := by |
| 75 | - nlinarith only [hInv,hFsquare,hK4] | |
| 75 | + linarith only [hInv,hFsquare,hK4] | |
| 76 | 76 | have hAct : 0 ≤ 8*(activationConstant G.CM G.CH+1) := by |
| 77 | 77 | unfold activationConstant |
| 78 | 78 | positivity [G.CH_nonneg] |
+4 −4 Euler/ParentRenewalParameters.lean View file
| @@ -46,12 +46,12 @@ theorem compression_margin {e : ℝ} (he : e ≤ 1) : | ||
| 46 | 46 | have hn : 0 ≤ G.ε*G.Θ*G.G^2 := by positivity [G.epsilon_pos,G.Theta_pos] |
| 47 | 47 | have hd : G.d ≤ 1/16 := by |
| 48 | 48 | unfold error at hbound |
| 49 | - nlinarith only [hbound,hn] | |
| 49 | + linarith only [hbound,hn] | |
| 50 | 50 | have hsmall : G.ε*G.Θ*G.G^2 ≤ 1/256 := by |
| 51 | 51 | unfold error at hbound |
| 52 | - nlinarith only [hbound,G.d_nonneg] | |
| 52 | + linarith only [hbound,G.d_nonneg] | |
| 53 | 53 | have hg : 3*(G.G+G.d)+1 ≤ 5*G.G^2 := by |
| 54 | - nlinarith only [hd,G.G_lower,sq_nonneg (G.G-1)] | |
| 54 | + linarith only [hd,G.G_lower,sq_nonneg (G.G-1)] | |
| 55 | 55 | have hprod := mul_le_mul_of_nonneg_right hg |
| 56 | 56 | (mul_nonneg G.epsilon_pos.le G.Theta_pos.le) |
| 57 | 57 | have htime := mul_le_mul_of_nonneg_left G.target_le_Theta G.epsilon_pos.le |
| @@ -60,7 +60,7 @@ theorem compression_margin {e : ℝ} (he : e ≤ 1) : | ||
| 60 | 60 | have hstrong : 3*(G.G+G.d)+1 < G.compressionScale := by |
| 61 | 61 | unfold compressionScale |
| 62 | 62 | apply (lt_div_iff₀ (show 0 < 20*G.ε*G.target by positivity [G.epsilon_pos,G.target_pos])).mpr |
| 63 | - nlinarith only [hprod,htarget,hsmall,G.a_lower] | |
| 63 | + linarith only [hprod,htarget,hsmall,G.a_lower] | |
| 64 | 64 | linarith only [he,hstrong] |
| 65 | 65 | |
| 66 | 66 | theorem nextCompression_le : G.nextCompression ≤ -G.compressionScale+3*(G.G+G.d) := by |
+2 −2 Euler/ParentRenewalScaleApplication.lean View file
| @@ -13,7 +13,7 @@ namespace EulerParentRenewalScale | ||
| 13 | 13 | open EulerPacketMovingFrame EulerPacketSourceScaleChoice |
| 14 | 14 | |
| 15 | 15 | theorem sigma_mul_le_two {σ x : ℝ} (h : σ^2*x^2 ≤ 2) : σ*x ≤ 2 := by |
| 16 | - nlinarith only [h,sq_nonneg (σ*x-2)] | |
| 16 | + linarith only [h,sq_nonneg (σ*x-2)] | |
| 17 | 17 | |
| 18 | 18 | theorem tilt_small_of_cost {ι : Type*} (G : PhysicalGeometryData ι) |
| 19 | 19 | {cost : ℕ → ℝ} {η : ℝ} (n : ℕ) (hs : SmallSeries cost η) |
| @@ -36,7 +36,7 @@ theorem literal_step {ι : Type*} {V : Type} [NormedAddCommGroup V] [InnerProduc | ||
| 36 | 36 | have ht := tilt_small_of_cost G n hs hη hcost.2 |
| 37 | 37 | have hi := H.tilt_interval ht |
| 38 | 38 | rw [hy,inv_inv] at hi |
| 39 | - refine ⟨H.coupling_error.trans hcost.1,?_,?_⟩ <;> nlinarith only [hi.1,hi.2] | |
| 39 | + refine ⟨H.coupling_error.trans hcost.1,?_,?_⟩ <;> linarith only [hi.1,hi.2] | |
| 40 | 40 | |
| 41 | 41 | end EulerParentRenewalScale |
| 42 | 42 | |
+9 −9 Euler/ParentRenewalScaleCosts.lean View file
| @@ -88,8 +88,8 @@ theorem renewal_series_small {J D : ℕ} (hJ : 2 ≤ J) {C c CF X δ η : ℝ} | ||
| 88 | 88 | (hfloor : 12000/η ≤ X) (hsmall : 2*(1+errorConstant CF)*δ ≤ η) : |
| 89 | 89 | SmallSeries (renewalCost J D C c CF X) η := by |
| 90 | 90 | have hf := (div_le_iff₀ hη).mp hfloor |
| 91 | - have hfirst : 6000/X ≤ η/2 := (div_le_iff₀ hX).mpr (by nlinarith only [hf]) | |
| 92 | - have hc : errorConstant CF*δ ≤ η/2 := by nlinarith only [hsmall,hδ] | |
| 91 | + have hfirst : 6000/X ≤ η/2 := (div_le_iff₀ hX).mpr (by linarith only [hf]) | |
| 92 | + have hc : errorConstant CF*δ ≤ η/2 := by linarith only [hsmall,hδ] | |
| 93 | 93 | exact (renewal_series hJ hX hb).weaken (by linarith only [hfirst,hc]) |
| 94 | 94 | |
| 95 | 95 | /-- This uses only the coupling at the present stage. -/ |
| @@ -126,7 +126,7 @@ theorem physical_error_le_maximum {ι : Type*} (G : PhysicalGeometryData ι) | ||
| 126 | 126 | have herr : G.error ≤ CF^2*geometryError J D C c X (fun _ => 2) n := by |
| 127 | 127 | unfold PhysicalGeometryData.error geometryError |
| 128 | 128 | dsimp only |
| 129 | - nlinarith only [hmain,hds] | |
| 129 | + linarith only [hmain,hds] | |
| 130 | 130 | have hpow : G.Θ^40 ≤ sourceTheta J C (scaleSequence J X) n^60 := |
| 131 | 131 | (pow_le_pow_left₀ G.Theta_pos.le htheta 40).trans (pow_le_pow_right₀ hthetaOne (by omega)) |
| 132 | 132 | have hmax0 := geometryError_nonneg J D C c X (fun _ => 2) n (zero_le_one.trans hC) hXp |
| @@ -147,7 +147,7 @@ theorem coupling_polynomial_le {ι : Type*} (G : PhysicalGeometryData ι) : | ||
| 147 | 147 | have hs2 : G.σ^2 ≤ 1 := pow_le_one₀ G.sigma_pos.le hs1 |
| 148 | 148 | have h2 := mul_le_mul hs2 hy2 (sq_nonneg G.y) (by norm_num : (0 : ℝ) ≤ 1) |
| 149 | 149 | have h3 := mul_le_mul hs1 hy3 (pow_nonneg G.y_pos.le 3) (by norm_num : (0 : ℝ) ≤ 1) |
| 150 | - nlinarith only [hy4,h2,h3] | |
| 150 | + linarith only [hy4,h2,h3] | |
| 151 | 151 | |
| 152 | 152 | theorem actual_errors_le_cost {ι : Type*} (G : PhysicalGeometryData ι) |
| 153 | 153 | (J D : ℕ) (hJ : 2 ≤ J) (C c CF X a : ℝ) (hC : 1 ≤ C) (hCF : 1 ≤ CF) |
| @@ -176,7 +176,7 @@ theorem actual_errors_le_cost {ι : Type*} (G : PhysicalGeometryData ι) | ||
| 176 | 176 | have hnorm : 30000000*neighborStabilityConstant*G.error*G.Θ^40 ≤ |
| 177 | 177 | errorConstant CF*maximumError J D C c X n := by |
| 178 | 178 | unfold errorConstant |
| 179 | - nlinarith only [hm] | |
| 179 | + linarith only [hm] | |
| 180 | 180 | have hp := coupling_polynomial_le G |
| 181 | 181 | have hyp := mul_le_mul_of_nonneg_left hy' (by norm_num : (0 : ℝ) ≤ 10) |
| 182 | 182 | have hsp := mul_le_mul_of_nonneg_left hs (by norm_num : (0 : ℝ) ≤ 1500) |
| @@ -184,10 +184,10 @@ theorem actual_errors_le_cost {ι : Type*} (G : PhysicalGeometryData ι) | ||
| 184 | 184 | constructor |
| 185 | 185 | · unfold PhysicalGeometryData.couplingError renewalCost |
| 186 | 186 | simp only [div_eq_mul_inv,one_mul] at hyp hi ⊢ |
| 187 | - nlinarith only [hp,hyp,hnorm,hi] | |
| 187 | + linarith only [hp,hyp,hnorm,hi] | |
| 188 | 188 | · unfold PhysicalGeometryData.tiltError renewalCost |
| 189 | 189 | simp only [div_eq_mul_inv] at hsp ⊢ |
| 190 | - nlinarith only [hsp,hnorm] | |
| 190 | + linarith only [hsp,hnorm] | |
| 191 | 191 | |
| 192 | 192 | /-- Optional explicit extra cost for the next activation. The existing |
| 193 | 193 | parent-square cost also controls it after multiplication by 2*CF+1. -/ |
| @@ -230,11 +230,11 @@ theorem activation_ratio_le {J D : ℕ} (hJ : 1 ≤ J) {C c CF X δ : ℝ} | ||
| 230 | 230 | (activationCostSpec CF hCF).cost J (scaleSequence J X) n := by |
| 231 | 231 | have hp := previousShear_one_le J hJ X hX n |
| 232 | 232 | have h1 : 1+previousShear J X n ≤ 2*(previousShear J X n)^2 := by |
| 233 | - nlinarith only [hp,sq_nonneg (previousShear J X n-1)] | |
| 233 | + linarith only [hp,sq_nonneg (previousShear J X n-1)] | |
| 234 | 234 | have h2 := mul_le_mul_of_nonneg_left h1 (zero_le_one.trans hCF) |
| 235 | 235 | have he' : e ≤ (previousShear J X n)^2 := he.trans (one_le_pow₀ hp) |
| 236 | 236 | have hn : CF*(1+previousShear J X n)+e ≤ (2*CF+1)*(previousShear J X n)^2 := by |
| 237 | - nlinarith only [h2,he'] | |
| 237 | + linarith only [h2,he'] | |
| 238 | 238 | have hd := div_le_div_of_nonneg_right hn (show 0 ≤ shear J X n from (Real.exp_pos _).le) |
| 239 | 239 | have hb' := mul_le_mul_of_nonneg_left |
| 240 | 240 | (actualParentRatio_le J hJ X (zero_lt_one.trans_le hX) hb.initial_shear n) |
+1 −1 Euler/RadialPotentialL2.lean View file
| @@ -107,7 +107,7 @@ theorem radial_average_sq_le_action (u : Space → Space) (hu : Continuous u) (x | ||
| 107 | 107 | have h := norm_integral_sq_le_action (volume.restrict (Ioc (0 : ℝ) 1)) W hmem |
| 108 | 108 | rw [radial_average_eq_quadratic u hu x, |
| 109 | 109 | intervalIntegral.integral_of_le (by norm_num : (0 : ℝ) ≤ 1)] |
| 110 | - simpa [W] using h | |
| 110 | + simpa using h | |
| 111 | 111 | |
| 112 | 112 | /-- The radial homotopy average preserves L², with operator norm at most two. -/ |
| 113 | 113 | theorem radial_average_memLp_and_energy (u : Space → Space) (hu : Continuous u) |
+1 −1 Euler/SmallCorrectionBounds.lean View file
| @@ -64,6 +64,6 @@ theorem residual_weighted {C R : ℝ} (hG : G.WordBound 6 R C 0) | ||
| 64 | 64 | hR (by positivity) s N hN ρ hρ hsmall t |
| 65 | 65 | apply hh.trans |
| 66 | 66 | unfold residualCost |
| 67 | - nlinarith only [sq_nonneg ε] | |
| 67 | + linarith only [sq_nonneg ε] | |
| 68 | 68 | |
| 69 | 69 | end EulerSmallCorrection |
+1 −1 Euler/SobolevDifferenceEnergy.lean View file
| @@ -58,7 +58,7 @@ theorem difference_transport_bound {q : ℕ} {T : Type*} [TopologicalSpace T] | ||
| 58 | 58 | have hβ : (1/2 : ℝ)*K.firstBound*((|D.κ|+‖D.direction‖)*velocityBound period q Z R) ≤ |
| 59 | 59 | Kx*velocityBound period q Z R := by |
| 60 | 60 | have hh := mul_le_mul_of_nonneg_right hprod hV |
| 61 | - nlinarith | |
| 61 | + linarith | |
| 62 | 62 | exact mul_le_mul_of_nonneg_right hβ (sq_nonneg _) |
| 63 | 63 | |
| 64 | 64 | /-- The actual Sobolev Laplacian has the fixed metric heat bound obtained by integration by parts. -/ |
+1 −1 Euler/SobolevHeatGenerator.lean View file
| @@ -22,7 +22,7 @@ def laplacianEvaluation (q : ℕ) (hq : 2 ≤ q) : SobolevSpace period q →L[ | ||
| 22 | 22 | theorem laplacianEvaluation_apply {q : ℕ} (hq : 2 ≤ q) (u : SobolevSpace period q) : |
| 23 | 23 | laplacianEvaluation period q hq u = |
| 24 | 24 | ∑ i : Fin 4, word period u hq (fun _ : Fin 2 => i) := by |
| 25 | - simp only [laplacianEvaluation, sum_apply] | |
| 25 | + simp only [laplacianEvaluation] | |
| 26 | 26 | rfl |
| 27 | 27 | |
| 28 | 28 | /-- The actual Laplacian is bounded by four times the complete Sobolev norm. -/ |
+1 −1 Euler/SobolevReflection.lean View file
| @@ -32,7 +32,7 @@ theorem reflectionArray_mem (q : ℕ) (u : SobolevSpace period q) : | ||
| 32 | 32 | · funext t |
| 33 | 33 | rw [map_smul] |
| 34 | 34 | rfl |
| 35 | - · simp only [pow_succ, mul_smul, neg_one_smul, smul_neg] | |
| 35 | + · simp only [pow_succ, mul_smul, neg_one_smul] | |
| 36 | 36 | rfl |
| 37 | 37 | |
| 38 | 38 | /-- Joint pullback reflection as a genuine bounded map of the complete Sobolev space. -/ |
+1 −1 Euler/SobolevSmoothProduct.lean View file
| @@ -103,7 +103,7 @@ theorem productHighLow_sub {q : ℕ} (L : Vector3 →L[ℝ] ℝ) | ||
| 103 | 103 | apply value_injective period |
| 104 | 104 | change value period (productHighLow period L u v) - value period (productHighLow period L w z) = |
| 105 | 105 | value period (productHighLow period L (u-w) v) + value period (productHighLow period L w (v-z)) |
| 106 | - simp only [productHighLow_value, map_sub] | |
| 106 | + simp only [productHighLow_value] | |
| 107 | 107 | rw [show value period (v-z) = value period v - value period z from map_sub (valueOperator period q) v z] |
| 108 | 108 | change scalarProductBilinear period (le_refl 3) L _ _ - scalarProductBilinear period (le_refl 3) L _ _ = |
| 109 | 109 | scalarProductBilinear period (le_refl 3) L _ _ + scalarProductBilinear period (le_refl 3) L _ _ |
+3 −3 Euler/SquaredMetricStability.lean View file
| @@ -36,8 +36,8 @@ theorem metric_derivative_bound (K : ℝ → H →L[ℝ] H) (e : ℝ → H) | ||
| 36 | 36 | have hraw : ⟪K' (e t),e t⟫_ℝ+2*⟪K t (e t),forcing+ν • lap⟫_ℝ-2*⟪K t (e t),transport⟫_ℝ ≤ |
| 37 | 37 | (‖K'‖+2*β+2*ν*h+2*‖K t‖*L+1)*‖e t‖^2+(‖K t‖*M)^2*ε^2 := by |
| 38 | 38 | rw [inner_add_right,real_inner_smul_right] |
| 39 | - nlinarith | |
| 40 | - have hn : ‖e t‖^2 ≤ ⟪K t (e t),e t⟫_ℝ/c^2 := (le_div_iff₀ (sq_pos_of_pos hc)).mpr (by nlinarith [hcoer]) | |
| 39 | + linarith | |
| 40 | + have hn : ‖e t‖^2 ≤ ⟪K t (e t),e t⟫_ℝ/c^2 := (le_div_iff₀ (sq_pos_of_pos hc)).mpr (by linarith [hcoer]) | |
| 41 | 41 | have ha : 0 ≤ ‖K'‖+2*β+2*ν*h+2*‖K t‖*L+1 := by positivity |
| 42 | 42 | calc |
| 43 | 43 | _ ≤ (‖K'‖+2*β+2*ν*h+2*‖K t‖*L+1)*‖e t‖^2+(‖K t‖*M)^2*ε^2 := hraw |
| @@ -73,7 +73,7 @@ theorem linear_growth_bound (E E' : ℝ → ℝ) (A B T : ℝ) (hA : 0 ≤ A) (h | ||
| 73 | 73 | have h := mul_le_mul_of_nonneg_left (hineq t ht) (exp_pos (-A*t)).le |
| 74 | 74 | have hexp : exp (-A*t) ≤ 1 := exp_le_one_iff.mpr (by nlinarith [ht.1]) |
| 75 | 75 | have hBexp := mul_le_mul_of_nonneg_right hexp hB |
| 76 | - nlinarith | |
| 76 | + linarith | |
| 77 | 77 | intro t ht |
| 78 | 78 | have hF := hanti ⟨le_rfl,hT⟩ ht ht.1 |
| 79 | 79 | have hscaled : exp (-A*t)*E t ≤ B*t := by |
+1 −1 Euler/StaticEulerWeightedBounds.lean View file
| @@ -28,7 +28,7 @@ theorem retainedRadius_small (R : ℝ) (hR : 0 ≤ R) : | ||
| 28 | 28 | have hn := mul_nonneg (EulerSmallCorrection.initialRadius_pos _ (mixedRadius_nonneg R hR)).le |
| 29 | 29 | (mixedRadius_nonneg R hR) |
| 30 | 30 | dsimp [retainedRadius] |
| 31 | - nlinarith | |
| 31 | + linarith | |
| 32 | 32 | |
| 33 | 33 | theorem baseErrorFactor_nonneg : 0 ≤ baseErrorFactor := |
| 34 | 34 | div_nonneg (zero_le_one.trans (metricAmplification_one_le (by norm_num : (0 : ℝ) < 1))) (by norm_num) |
+4 −4 Euler/TerminalLayerRamp.lean View file
| @@ -28,7 +28,7 @@ theorem denominator_lower {T L : ℝ} (hLT : 1 ≤ L * T) : | ||
| 28 | 28 | rw [← Real.exp_add] |
| 29 | 29 | rw [show L * T + -L * T = 0 by ring, Real.exp_zero] |
| 30 | 30 | have hm := mul_le_mul_of_nonneg_right he (Real.exp_nonneg (-L * T)) |
| 31 | - nlinarith only [hp, hm] | |
| 31 | + linarith only [hp, hm] | |
| 32 | 32 | |
| 33 | 33 | theorem denominator_pos {T L : ℝ} (hLT : 1 ≤ L * T) : |
| 34 | 34 | 0 < 1 - Real.exp (-L * T) := lt_of_lt_of_le (by norm_num) (denominator_lower hLT) |
| @@ -59,14 +59,14 @@ theorem ramp_nonneg {T L t : ℝ} (hL : 0 ≤ L) (hLT : 1 ≤ L * T) | ||
| 59 | 59 | (ht : 0 ≤ t) : 0 ≤ ramp T L t := by |
| 60 | 60 | apply div_nonneg _ (denominator_pos hLT).le |
| 61 | 61 | apply sub_nonneg.mpr (Real.exp_le_exp.mpr _) |
| 62 | - nlinarith only [mul_nonneg hL ht] | |
| 62 | + linarith only [mul_nonneg hL ht] | |
| 63 | 63 | |
| 64 | 64 | theorem ramp_le_exp {T L t : ℝ} (hLT : 1 ≤ L * T) : |
| 65 | 65 | ramp T L t ≤ 2 * Real.exp (L * (t - T)) := by |
| 66 | 66 | apply (div_le_iff₀ (denominator_pos hLT)).2 |
| 67 | 67 | have hm := mul_le_mul_of_nonneg_right (denominator_lower hLT) |
| 68 | 68 | (Real.exp_nonneg (L * (t - T))) |
| 69 | - nlinarith only [hm, Real.exp_nonneg (-L * T)] | |
| 69 | + linarith only [hm, Real.exp_nonneg (-L * T)] | |
| 70 | 70 | |
| 71 | 71 | theorem rampDerivative_nonneg {T L t : ℝ} (hL : 0 ≤ L) (hLT : 1 ≤ L * T) : |
| 72 | 72 | 0 ≤ rampDerivative T L t := |
| @@ -77,7 +77,7 @@ theorem rampDerivative_le_exp {T L t : ℝ} (hL : 0 ≤ L) (hLT : 1 ≤ L * T) : | ||
| 77 | 77 | apply (div_le_iff₀ (denominator_pos hLT)).2 |
| 78 | 78 | have hm := mul_le_mul_of_nonneg_right (denominator_lower hLT) |
| 79 | 79 | (mul_nonneg hL (Real.exp_nonneg (L * (t - T)))) |
| 80 | - nlinarith only [hm] | |
| 80 | + linarith only [hm] | |
| 81 | 81 | |
| 82 | 82 | theorem ramp_sq_le {T L t : ℝ} (hL : 0 ≤ L) (hLT : 1 ≤ L * T) (ht : 0 ≤ t) : |
| 83 | 83 | ramp T L t ^ 2 ≤ 4 * Real.exp (2 * L * (t - T)) := by |
+1 −1 Euler/TerminalProjectionTrial.lean View file
| @@ -141,7 +141,7 @@ theorem initialPrimitiveTimeLp_trialDerivative (Y : U) : | ||
| 141 | 141 | omit [CompleteSpace E] [InnerProductSpace ℝ E] in |
| 142 | 142 | theorem norm_add_sq_le (a b : E) : ‖a + b‖ ^ 2 ≤ 2 * ‖a‖ ^ 2 + 2 * ‖b‖ ^ 2 := by |
| 143 | 143 | have hs := pow_le_pow_left₀ (norm_nonneg (a + b)) (norm_add_le a b) 2 |
| 144 | - nlinarith only [hs, sq_nonneg (‖a‖ - ‖b‖)] | |
| 144 | + linarith only [hs, sq_nonneg (‖a‖ - ‖b‖)] | |
| 145 | 145 | |
| 146 | 146 | omit [CompleteSpace E] in |
| 147 | 147 | theorem trialFrameDerivative_apply_sq_le (M : ℝ) (_hM : 0 ≤ M) |
+1 −1 Euler/TimeH1FrameTransport.lean View file
| @@ -70,7 +70,7 @@ theorem norm_le_transportCost_productDerivative (v : TimeLp T U) : | ||
| 70 | 70 | coordinateDerivative_norm T Q Q₁ c hc hQ hT _ |
| 71 | 71 | _ ≤ transportCost T Q Q₁ c * ‖productDerivative T hT Q Q₁ v‖ := by |
| 72 | 72 | unfold transportCost |
| 73 | - nlinarith only [norm_nonneg (productDerivative T hT Q Q₁ v)] | |
| 73 | + linarith only [norm_nonneg (productDerivative T hT Q Q₁ v)] | |
| 74 | 74 | |
| 75 | 75 | include hc hQ hd in |
| 76 | 76 | /-- A quantitative lower bound for the transported kinetic energy. -/ |
+1 −1 Euler/TimeH1GeneratorBounds.lean View file
| @@ -29,7 +29,7 @@ def generatorTrace (B : C(Icc (0 : ℝ) T, U →L[ℝ] U)) : | ||
| 29 | 29 | def traceCost (T b : ℝ) : ℝ := (1+T) * (T⁻¹ + 2*b) |
| 30 | 30 | |
| 31 | 31 | theorem sqrt_le_one_add (hT : 0 ≤ T) : Real.sqrt T ≤ 1+T := by |
| 32 | - nlinarith only [Real.sq_sqrt hT, Real.sqrt_nonneg T, sq_nonneg (Real.sqrt T-1)] | |
| 32 | + linarith only [Real.sq_sqrt hT, Real.sqrt_nonneg T, sq_nonneg (Real.sqrt T-1)] | |
| 33 | 33 | |
| 34 | 34 | theorem generatorTrace_norm_le (hTpos : 0 < T) |
| 35 | 35 | (B : C(Icc (0 : ℝ) T, U →L[ℝ] U)) (b : ℝ) (hB : ‖B‖ ≤ b) : |
+1 −1 Euler/TimeLpCoefficientGevrey.lean View file
| @@ -51,7 +51,7 @@ theorem primitive_norm_le_time : ‖primitiveTimeLp (E := E) T hT‖ ≤ T := by | ||
| 51 | 51 | have h := (sq_le_sq₀ (norm_nonneg _) (Real.sqrt_nonneg (T^2/2))).2 |
| 52 | 52 | (primitiveTimeLp_norm_le (E := E) T hT) |
| 53 | 53 | rw [Real.sq_sqrt (by positivity)] at h |
| 54 | - nlinarith [sq_nonneg T] | |
| 54 | + linarith [sq_nonneg T] | |
| 55 | 55 | |
| 56 | 56 | /-- Actual multiplier derivatives retain the coefficient factorial bounds. -/ |
| 57 | 57 | theorem timeMultiplier_bound |
+1 −1 Euler/TransportL2Bilinear.lean View file
| @@ -26,7 +26,7 @@ theorem transportL2Bilinear_apply {q : ℕ} (hq : 3 ≤ q) (L : Fin 4 → Vector | ||
| 26 | 26 | transportL2Bilinear period hq L u e = ∑ i : Fin 4, |
| 27 | 27 | scalarProduct period hq (L i) u (value period (derivativeOperator period 0 i e)) := by |
| 28 | 28 | simp only [transportL2Bilinear, sum_apply, ContinuousLinearMap.bilinearComp_apply, |
| 29 | - ContinuousLinearMap.id_apply, ContinuousLinearMap.comp_apply, scalarProductBilinear_apply] | |
| 29 | + ContinuousLinearMap.id_apply, scalarProductBilinear_apply] | |
| 30 | 30 | rfl |
| 31 | 31 | |
| 32 | 32 | /-- On the actual lifted velocity coefficients, this is exactly the operator used in metric transport cancellation. -/ |
+0 −8 Euler/TransverseFixedClassical.lean View file
| @@ -43,14 +43,6 @@ def physicalDerivativePath (f : C(Icc (0 : ℝ) T,E)) : C(Icc (0 : ℝ) T,E) := | ||
| 43 | 43 | multiplier Q₁ (velocityPath T hT Q Q₁ H c hc hQ hd K hK hH hsmall (pathLp T hT f))+ |
| 44 | 44 | multiplier Q (classicalAcceleration T hT Q Q₁ H c hc hQ hd K hK hH hsmall f) |
| 45 | 45 | |
| 46 | -theorem displacementPath_initial (f : TimeLp T E) : | |
| 47 | - displacementPath T hT Q Q₁ H c hc hQ hd K hK hH hsmall f ⟨0,le_rfl,hT⟩ = 0 := | |
| 48 | - velocityLp_zero_trace T hT Q Q₁ H c hc hQ hd K hK hH hsmall f | |
| 49 | - | |
| 50 | -theorem displacementPath_terminal (f : TimeLp T E) : | |
| 51 | - displacementPath T hT Q Q₁ H c hc hQ hd K hK hH hsmall f ⟨T,hT,le_rfl⟩ = 0 := | |
| 52 | - terminalPrimitive_terminal T hT _ | |
| 53 | - | |
| 54 | 46 | theorem classicalAcceleration_equation (f : C(Icc (0 : ℝ) T,E)) (t : Icc (0 : ℝ) T) : |
| 55 | 47 | gram (Q t) (classicalAcceleration T hT Q Q₁ H c hc hQ hd K hK hH hsmall f t) = |
| 56 | 48 | (Q t).adjoint (f t-(2 : ℝ) • Q₁ t |
+0 −4 Euler/TransverseFixedEvolution.lean View file
| @@ -47,10 +47,6 @@ def velocityPath : TimeLp T E →L[ℝ] C(Icc (0 : ℝ) T,U) := | ||
| 47 | 47 | (valuePart T hT).comp (velocityLp T hT Q Q₁ H c hc hQ hd K hK hH hsmall)+ |
| 48 | 48 | (derivativePart T hT).comp (accelerationLp T hT Q Q₁ H c hc hQ hd K hK hH hsmall) |
| 49 | 49 | |
| 50 | -theorem velocityLp_zero_trace (f : TimeLp T E) : | |
| 51 | - initialTrace T hT (velocityLp T hT Q Q₁ H c hc hQ hd K hK hH hsmall f) = 0 := | |
| 52 | - (fixedFrameSolver T hT Q Q₁ H c hc hQ hd K hK hH hsmall f).property | |
| 53 | - | |
| 54 | 50 | theorem accelerationLp_ae (f : TimeLp T E) : |
| 55 | 51 | (accelerationLp T hT Q Q₁ H c hc hQ hd K hK hH hsmall f : ℝ → U) =ᵐ[timeMeasure T] |
| 56 | 52 | fun t => gramInverse (Q (projIcc 0 T hT t)) c hc (hQ (projIcc 0 T hT t)) |
+2 −2 Euler/UnshiftedPressure.lean View file
| @@ -72,14 +72,14 @@ theorem unshifted_weighted_inverse (ρ Rc M : ℝ) (hρ : 0 < ρ) (hRc : 0 ≤ R | ||
| 72 | 72 | M * ((∑ n ∈ range (N + 1), v n * F n) + |
| 73 | 73 | ∑ n ∈ range (N + 1), v n * ∑ l ∈ range n, |
| 74 | 74 | (n.choose (l + 1) : ℝ) * A (l + 1) * Z (n - (l + 1))) := by |
| 75 | - simp only [mul_add, sum_add_distrib, mul_sum, mul_left_comm, mul_comm] | |
| 75 | + simp only [mul_add, sum_add_distrib, mul_sum, mul_left_comm] | |
| 76 | 76 | rw [hsumid] at hs |
| 77 | 77 | have hzsum : 0 ≤ ∑ n ∈ range (N + 1), v n * Z n := |
| 78 | 78 | sum_nonneg (fun n _ => mul_nonneg (hv n) (hZ n)) |
| 79 | 79 | have hsmall' := mul_le_mul_of_nonneg_right hsmall hzsum |
| 80 | 80 | have hcomm' := mul_le_mul_of_nonneg_left hcomm (show 0 ≤ M by linarith) |
| 81 | 81 | change (∑ n ∈ range (N + 1), v n * Z n) ≤ 2 * M * ∑ n ∈ range (N + 1), v n * F n |
| 82 | - nlinarith | |
| 82 | + linarith | |
| 83 | 83 | |
| 84 | 84 | end EulerWeightedPressure |
| 85 | 85 | |
+2 −3 Euler/VorticityTransport.lean View file
| @@ -56,13 +56,12 @@ theorem linearODE_eq_zero (w : ℝ → E) (B : ℝ → E →L[ℝ] E) (T : ℝ) | ||
| 56 | 56 | (norm_nonneg _)) |
| 57 | 57 | have hi := (real_inner_le_norm (w r) (B r (w r))).trans |
| 58 | 58 | (mul_le_mul_of_nonneg_left hnorm (norm_nonneg _)) |
| 59 | - nlinarith | |
| 59 | + linarith | |
| 60 | 60 | have hqt : q t ≤ 0 := by |
| 61 | 61 | have hz : (0 : ℝ) ∈ Icc 0 T := ⟨le_rfl, ht.1.trans ht.2⟩ |
| 62 | 62 | simpa only [q, hzero, norm_zero, zero_pow (by norm_num : 2 ≠ 0), mul_zero] using |
| 63 | 63 | hanti hz ht ht.1 |
| 64 | - have hsq : ‖w t‖ ^ 2 ≤ 0 := by | |
| 65 | - exact nonpos_of_mul_nonpos_right hqt (Real.exp_pos _) | |
| 64 | + have hsq : ‖w t‖ ^ 2 ≤ 0 := nonpos_of_mul_nonpos_right hqt (Real.exp_pos _) | |
| 66 | 65 | have hn : ‖w t‖ = 0 := by nlinarith [norm_nonneg (w t)] |
| 67 | 66 | exact norm_eq_zero.mp hn |
| 68 | 67 | |
+1 −1 Euler/WeightedForcingAlgebra.lean View file
| @@ -27,7 +27,7 @@ theorem familyNorm_add_le (v w : β → H) : familyNorm (v+w) ≤ familyNorm v + | ||
| 27 | 27 | have hcs := family_cauchy_schwarz v w |
| 28 | 28 | have hv := familyNorm_sq v |
| 29 | 29 | have hw := familyNorm_sq w |
| 30 | - nlinarith | |
| 30 | + linarith | |
| 31 | 31 | |
| 32 | 32 | /-- Signs do not change the genuine Hilbert family norm. -/ |
| 33 | 33 | theorem familyNorm_neg (v : β → H) : familyNorm (-v) = familyNorm v := by |
+1 −1 Euler/WeightedRootLimit.lean View file
| @@ -91,6 +91,6 @@ theorem weighted_root_integral_of_deriv_bound (Q a F w w' : ℝ → ℝ) (s t : | ||
| 91 | 91 | · intro u hu |
| 92 | 92 | rw [((hwd u hu).fun_mul (hregd δ hδ u hu).hasDerivAt).deriv] |
| 93 | 93 | have h := mul_le_mul_of_nonneg_left (hreg δ hδ u hu) (hw u hu) |
| 94 | - nlinarith | |
| 94 | + linarith | |
| 95 | 95 | |
| 96 | 96 | end EulerWeightedRootLimit |
+1 −1 Euler/WeightedSobolevMajorant.lean View file
| @@ -113,7 +113,7 @@ theorem weighted_sobolev_energy_majorized {α β : Type*} [Fintype α] [Fintype | ||
| 113 | 113 | multiplier u * weightedForcingSum (ρ u) order (fun i j => forcing i j u) := by |
| 114 | 114 | simp only [Ψ, A, w, w', F, Q, weightedMetricSum, weightedMetricLoss, weightedForcingSum, |
| 115 | 115 | familyMetricNorm, add_mul, Finset.sum_add_distrib, Finset.mul_sum] |
| 116 | - simp only [mul_comm, mul_left_comm, mul_assoc] | |
| 116 | + simp only [mul_left_comm, mul_assoc] | |
| 117 | 117 | simpa only [halg, w, Q, a, weightedMetricSum, familyMetricNorm] using hsum |
| 118 | 118 | |
| 119 | 119 | end EulerWeightedSobolevMajorant |
+6 −5 KNOWN.md View file
| @@ -16,12 +16,13 @@ What is established about this problem, one fact a line, each with where it come | ||
| 16 | 16 | |
| 17 | 17 | ## Mind |
| 18 | 18 | |
| 19 | -- A build that starts at once can run more than an hour: 32 jobs submitted 01:58–02:59 all started within a minute and were still running at 03:04, and 50 submitted 03:26–04:13 started at once and were all still running at 04:20 (job 5121, job 5296, job 5414). | |
| 19 | +- Main's builds start in the minute they are submitted while experiment heads wait: 20 builds on main submitted 05:26–05:32 all began at once, while 30 `s1-*`/`s2-*` builds submitted 04:20–04:25 started 52–61 minutes later (job 5663, job 5655, job 5568). | |
| 20 | +- A build that starts at once can run more than an hour: 32 jobs submitted 01:58–02:59 started within a minute and were still running at 03:04, and the 50 submitted 04:12–04:22 were all still running at 05:31, the oldest 1h19m (job 5121, job 5418, job 5375). | |
| 20 | 21 | - Build queue waits follow the backlog: build jobs submitted 21:59–22:47 waited up to 43 minutes to start (job 4706, submitted 21:59, started 22:42), while those submitted 23:16–23:41 started within a minute (job 4795, job 4817). |
| 21 | -- Checks can arrive in one batch: 35 `s1-*-3` heads took challenge passes 00:24–00:28, 26 main heads and 14 builds passed 01:22–01:33, and 40 verdicts landed 04:14–04:19, mostly challenge successes reading 497,428–498,114 lines at 2,588 files (commit 4c91414, commit bed76de, commit 2dd39c6). | |
| 22 | -- Main advances several commits a minute: builds passed at 42d34c8 04:15 and ac4dd55 04:17 while bed76de and e7f8c53 both passed challenge at 04:18, and earlier 25 challenge successes landed 22:45–22:50, so a named tip already trails them (commit a716ddf, commit 42d34c8, commit bed76de). | |
| 23 | -- [mind, checked] A pending build is a queue, not a failure: 50 builds submitted 21:32–22:25 waited 21–43 minutes to start and 50 submitted 16:13–16:43 on 12-04 were still queued at 17:21, while the 50 submitted 02:13–03:12 started within a minute (job 4751, job 2940, job 5148, job 5283). | |
| 24 | -- [mind, checked] A challenge verdict counts its own head's tree, so line counts drift: twelve main heads 02:16–02:21 read 500,728→499,461, fifteen at 04:05–04:10 read 499,257→498,348, and 28 `s1-*-8` heads read 499,017→499,418 at 2,588 files (commit 6383aee, commit 21c8ecb). | |
| 22 | +- Checks can arrive in one batch: 35 `s1-*-3` heads took challenge passes 00:24–00:28, and 40 verdicts landed 05:37–06:06, 27 challenge successes on main and 13 build successes on experiment heads (commit 4c91414, commit 3325955, commit 67c70f8). | |
| 23 | +- Main advances several commits a minute: builds passed on main at dad3bad 05:29, 705252a, e442887 and 45dea90 05:30, and challenge passed at 9313602, a2dbfea and 94e881f 05:31 (commit dad3bad, commit 705252a, commit 9313602). | |
| 24 | +- A pending build is a queue, not a failure: 50 builds submitted 21:32–22:25 waited 21–43 minutes and 50 submitted 16:13–16:43 on 12-04 were still queued at 17:21, while 23 of 50 submitted 04:12–04:22 waited 7–58 minutes (job 4751, job 2940, job 5536, job 5597). | |
| 25 | +- A challenge verdict counts its own head's tree, so line counts drift: twelve main heads 02:16–02:21 read 500,728→499,461, and 27 main heads at 05:37–06:06 read between 497,301 and 497,315 at 2,588 files (commit 6383aee, commit 3baf79e, commit 3325955). | |
| 25 | 26 | - A challenge pass says nothing about the build: 509d828 passed challenge at 17:35 and failed its build at 17:39 (`Invalid field angularContinuous`); c4c7f0b passed challenge at 22:50 and its build is still queued (commit 509d828, commit c4c7f0b, job 4792). |
| 26 | 27 | - ~~Build has filed no verdict since 12-02 14:50, so a challenge success after that has no build behind it: six build jobs were submitted at 12-04 02:56, two each on main, p4-euler-section-6 and maintainer-statement, and all six are still pending (job 2168, job 2176, job 2181).~~ Build has since filed verdicts, on 12-04 03:09–03:52, for all six heads submitted at 02:56 (main 530a644 and 0bbf0b4, maintainer-statement 7131c8c, p4-euler-section-6 e86853a, plus p5-h3-approximation-doc 828caff, p2-correction-covariance 642c67e, p2-correction-full-residual d4072c4), so none is left pending (commit 530a644, commit 0bbf0b4, commit 7131c8c, commit 642c67e) |
| 27 | 28 | - Checks repeat for one head across rounds, not only at a submission: 7131c8c and e86853a got two challenge successes at 02:56, builds at 03:11–03:14 and builds again at 06:38, and 642c67e was re-challenged at 07:16 after 03:23 (commit 7131c8c, commit e86853a, commit 642c67e). |
+4 −5 NavierStokes/ActivationBounds.lean View file
| @@ -29,7 +29,7 @@ noncomputable def parameterFactor (B : E × Point → ℝ) (q : E × Point) : | ||
| 29 | 29 | omit [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] in |
| 30 | 30 | theorem parameterFactor_eq (B : E × Point → ℝ) (q : E) (p : Point) : |
| 31 | 31 | parameterFactor B (q, p) = primitiveFactor 1 (fun z => B (q, z)) p := by |
| 32 | - simp only [parameterFactor, primitiveFactor, one_pow] | |
| 32 | + simp only [primitiveFactor, one_pow] | |
| 33 | 33 | rfl |
| 34 | 34 | |
| 35 | 35 | theorem parameterFactor_smooth {S : Set E} (hS : IsOpen S) {J : Set ℝ} (hJ : IsOpen J) |
| @@ -277,7 +277,7 @@ theorem width_uniform_jet_bound {J K : Set ℝ} (hJ : IsOpen J) (hK : IsCompact | ||
| 277 | 277 | have hm := mul_le_mul_of_nonneg_left |
| 278 | 278 | (hb (κ, T) ⟨hκ, hT.1.le, hT.2⟩ u hu η hη) |
| 279 | 279 | (mul_nonneg hy.1 (activation_nonneg T κ y hκ.2)) |
| 280 | - nlinarith | |
| 280 | + linarith | |
| 281 | 281 | |
| 282 | 282 | /-! ## Width-uniform factors for the actual five histories -/ |
| 283 | 283 | |
| @@ -419,7 +419,7 @@ theorem etaLinear_hasDerivAt {J : Set ℝ} (hJ : IsOpen J) {H : ScaledPoint → | ||
| 419 | 419 | have h := hd.hasFDerivAt.comp_hasDerivAt q.2.2 |
| 420 | 420 | ((hasDerivAt_const q.2.2 q.1).prodMk |
| 421 | 421 | ((hasDerivAt_const q.2.2 q.2.1).prodMk (hasDerivAt_id q.2.2))) |
| 422 | - simp only [Function.comp_def, id_eq] at h | |
| 422 | + simp only [Function.comp_def] at h | |
| 423 | 423 | exact h |
| 424 | 424 | |
| 425 | 425 | theorem etaD_eq_etaLinear {J : Set ℝ} (hJ : IsOpen J) {H : ScaledPoint → ℝ} |
| @@ -440,8 +440,7 @@ theorem etaD_hasDerivAt {J : Set ℝ} (hJ : IsOpen J) {H : ScaledPoint → ℝ} | ||
| 440 | 440 | exact etaLinear_hasDerivAt hJ hH hq |
| 441 | 441 | |
| 442 | 442 | theorem etaD_scaledDistance_mul (H : ScaledPoint → ℝ) (q : ScaledPoint) : |
| 443 | - etaD (fun z => scaledDistance z * H z) q = scaledDistance q * etaD H q := by | |
| 444 | - exact deriv_const_mul_field (scaledDistance q) | |
| 443 | + etaD (fun z => scaledDistance z * H z) q = scaledDistance q * etaD H q := deriv_const_mul_field (scaledDistance q) | |
| 445 | 444 | |
| 446 | 445 | theorem etaD_congr {J : Set ℝ} (hJ : IsOpen J) {H G : ScaledPoint → ℝ} |
| 447 | 446 | (h : ∀ q ∈ scaledDomain J, H q = G q) {q : ScaledPoint} (hq : q ∈ scaledDomain J) : |
+17 −17 NavierStokes/ActivationCone.lean View file
| @@ -83,26 +83,26 @@ theorem ramp_cone_of_errors {c B r e s P J v : ℝ} | ||
| 83 | 83 | have hrgap : 1 ≤ r - 2 * s := by linarith |
| 84 | 84 | have hgap : e ≤ P - v := by |
| 85 | 85 | have h := mul_le_mul_of_nonneg_left hrgap he.le |
| 86 | - nlinarith | |
| 86 | + linarith | |
| 87 | 87 | have hPgt : 2 + c / 4 < P := by linarith |
| 88 | 88 | have hvB : v - 2 ≤ B := by |
| 89 | 89 | have h := mul_nonneg he.le hrpos.le |
| 90 | - nlinarith | |
| 90 | + linarith | |
| 91 | 91 | have hJsq : J ^ 2 ≤ s ^ 2 * e ^ 2 := by |
| 92 | 92 | have h := mul_nonneg (show 0 ≤ s * e - J by linarith) |
| 93 | 93 | (show 0 ≤ s * e + J by linarith) |
| 94 | - nlinarith | |
| 95 | - have hBs : B * s ≤ 1 / 4 := by nlinarith | |
| 94 | + linarith | |
| 95 | + have hBs : B * s ≤ 1 / 4 := by linarith | |
| 96 | 96 | have hBss : B * s ^ 2 ≤ 1 / 16 := by |
| 97 | 97 | have h := mul_le_mul_of_nonneg_right hBs hs |
| 98 | - nlinarith | |
| 98 | + linarith | |
| 99 | 99 | have he2 : 0 < e ^ 2 := sq_pos_of_pos he |
| 100 | 100 | have hquad : (v - 2) * J ^ 2 < 2 * (P - v) ^ 2 := calc |
| 101 | 101 | (v - 2) * J ^ 2 ≤ B * J ^ 2 := mul_le_mul_of_nonneg_right hvB (sq_nonneg J) |
| 102 | 102 | _ ≤ B * (s ^ 2 * e ^ 2) := mul_le_mul_of_nonneg_left hJsq hBpos.le |
| 103 | 103 | _ = (B * s ^ 2) * e ^ 2 := by ring |
| 104 | 104 | _ ≤ (1 / 16 : ℝ) * e ^ 2 := mul_le_mul_of_nonneg_right hBss he2.le |
| 105 | - _ < 2 * e ^ 2 := by nlinarith | |
| 105 | + _ < 2 * e ^ 2 := by linarith | |
| 106 | 106 | _ ≤ 2 * (P - v) ^ 2 := by nlinarith |
| 107 | 107 | exact ⟨hgap, hPgt, hquad⟩ |
| 108 | 108 | |
| @@ -115,7 +115,7 @@ theorem collar_lower_of_errors {c B r e s v : ℝ} | ||
| 115 | 115 | 2 + c / 2 < v := by |
| 116 | 116 | have hl := (abs_le.mp hv).1 |
| 117 | 117 | have hm := mul_le_mul_of_nonneg_left (show r + s ≤ B + 1 by linarith) he |
| 118 | - nlinarith | |
| 118 | + linarith | |
| 119 | 119 | |
| 120 | 120 | /-- A single error tolerance is chosen from the fixed reference bounds. -/ |
| 121 | 121 | noncomputable def errorTolerance (c B : ℝ) : ℝ := |
| @@ -135,7 +135,7 @@ theorem errorTolerance_bounds {c B s : ℝ} (hB : 0 ≤ B) (hs : s ≤ errorTole | ||
| 135 | 135 | have hp : 0 < 4 * (B + 1) := by positivity |
| 136 | 136 | have hm := (le_div_iff₀ hp).mp h3 |
| 137 | 137 | refine ⟨h1, h2, ?_⟩ |
| 138 | - nlinarith | |
| 138 | + linarith | |
| 139 | 139 | |
| 140 | 140 | /-- Positivity of the actual flat activation on the nonzero ramp. -/ |
| 141 | 141 | theorem activation_pos {T κ y : ℝ} (hT : 0 < T) (hκ : κ < 1) (hy : 0 < y) : |
| @@ -224,7 +224,7 @@ theorem uniform_ramp_from_comparison {K : Set ℝ} {r : Field} | ||
| 224 | 224 | have hsmall := hsmallactivation T hT.1 κ ⟨hκ.1.le, hκ.2.le⟩ y ⟨hy.1.le, hycollar⟩ |
| 225 | 225 | have heB : activation T κ y * (B + 1) ≤ c / 4 := by |
| 226 | 226 | have h := (lt_div_iff₀ hBp).mp hsmall |
| 227 | - nlinarith | |
| 227 | + linarith | |
| 228 | 228 | exact collar_lower_of_errors hc hr.1 hr.2 he.le (by linarith) heB hve |
| 229 | 229 | |
| 230 | 230 | /-- Exact stress factorization when stock and shear-ratio errors carry the |
| @@ -327,7 +327,7 @@ theorem cone_error_bounds {κ A B z dA dB dR M : ℝ} | ||
| 327 | 327 | |sizeError κ A B z dR| = |κ| * |B ^ 2 / A| * |dR| * |2 + z * dR| := by |
| 328 | 328 | simp only [sizeError, abs_mul] |
| 329 | 329 | _ ≤ 1 * M * M * (2 + M) := by gcongr |
| 330 | - _ ≤ comparisonConstant M := by unfold comparisonConstant; nlinarith | |
| 330 | + _ ≤ comparisonConstant M := by unfold comparisonConstant; linarith | |
| 331 | 331 | |
| 332 | 332 | private theorem bounded_error_factor {M z x : ℝ} (hM : 0 ≤ M) (hz : 0 ≤ z) |
| 333 | 333 | (hx : |x| ≤ M * z) : ∃ d : ℝ, |d| ≤ M ∧ x = z * d := by |
| @@ -362,9 +362,9 @@ theorem cone_comparison_from_stock_bounds {κ A B z p q R M : ℝ} | ||
| 362 | 362 | (by simpa only [abs_of_nonneg hz] using hz1) hB hBA hB2A hdA hdB hdR |
| 363 | 363 | rw [hfP, hfJ, hfv] |
| 364 | 364 | simp only [abs_mul, abs_of_nonneg hz] |
| 365 | - exact ⟨by nlinarith [mul_le_mul_of_nonneg_left hbP hz], | |
| 366 | - by nlinarith [mul_le_mul_of_nonneg_left hbv hz], | |
| 367 | - by nlinarith [mul_le_mul_of_nonneg_left hbJ hz]⟩ | |
| 365 | + exact ⟨by linarith [mul_le_mul_of_nonneg_left hbP hz], | |
| 366 | + by linarith [mul_le_mul_of_nonneg_left hbv hz], | |
| 367 | + by linarith [mul_le_mul_of_nonneg_left hbJ hz]⟩ | |
| 368 | 368 | |
| 369 | 369 | /-- The genuine derivative-defined shear size has the cancellation form used |
| 370 | 370 | in the error transport. -/ |
| @@ -378,7 +378,7 @@ theorem shearSize_eq (T : ℝ) {κ X0 : ℝ} (hκ : κ ∈ Ioc (0 : ℝ) 1) (hX0 | ||
| 378 | 378 | (referenceAngular L (y, η) / activatedAngular T κ L (y, η)) ^ 2) := by |
| 379 | 379 | have h := shearSize_error T hκ hX0 hJ hL hU y hη hA |
| 380 | 380 | unfold referenceSize at h |
| 381 | - nlinarith | |
| 381 | + linarith | |
| 382 | 382 | |
| 383 | 383 | noncomputable def activatedStockOne (h X0 : ℝ) (initial : HistoryRow → ℝ → ℝ) |
| 384 | 384 | (L U : Field) (T κ : ℝ) : Field := |
| @@ -554,15 +554,15 @@ theorem actual_comparisons (h : ℝ) {X0 : ℝ} (hX0 : 0 < X0) | ||
| 554 | 554 | simp only [iteratedDeriv_zero, hm1, hm2] at hsval |
| 555 | 555 | have hpbound : |activatedStockOne h X0 initial L U T κ (y, η) - referenceP1 L (y, η)| ≤ |
| 556 | 556 | M * (y * activation T κ y) := by |
| 557 | - exact hsval.1.trans (by nlinarith [mul_le_mul_of_nonneg_right hsM hz]) | |
| 557 | + exact hsval.1.trans (by linarith [mul_le_mul_of_nonneg_right hsM hz]) | |
| 558 | 558 | have hqbound : |activatedStockTwo h X0 initial L U T κ (y, η) - referenceP2 X0 L U (y, η)| ≤ |
| 559 | 559 | M * (y * activation T κ y) := by |
| 560 | - exact hsval.2.trans (by nlinarith [mul_le_mul_of_nonneg_right hsM hz]) | |
| 560 | + exact hsval.2.trans (by linarith [mul_le_mul_of_nonneg_right hsM hz]) | |
| 561 | 561 | have hrval := hr T hT κ hκcc y hy η hη |
| 562 | 562 | simp only [iteratedDeriv_zero] at hrval |
| 563 | 563 | have hrbound : |referenceAngular L (y, η) / activatedAngular T κ L (y, η) - 1| ≤ |
| 564 | 564 | M * (y * activation T κ y) := |
| 565 | - hrval.trans (by nlinarith [mul_le_mul_of_nonneg_right hrM hz]) | |
| 565 | + hrval.trans (by linarith [mul_le_mul_of_nonneg_right hrM hz]) | |
| 566 | 566 | have hcomp := cone_comparison_from_stock_bounds hM ha hdamp hz hz1 |
| 567 | 567 | (hb.trans hrefM) (hba.trans hrefM) (hb2.trans hrefM) hpbound hqbound hrbound |
| 568 | 568 | unfold activatedProjection activatedCross |
+8 −8 NavierStokes/ActivationContinuation.lean View file
| @@ -319,10 +319,10 @@ theorem holdModel_uniform_lower {h j σ : ℝ} (hsmall : NaturalAxisData.SmallPa | ||
| 319 | 319 | have hnorm : ‖1 / Λ‖ < τ := by |
| 320 | 320 | rw [Real.norm_eq_abs, abs_of_pos (one_div_pos.mpr hΛ0), div_lt_iff₀ hΛ0] |
| 321 | 321 | have hm := (div_lt_iff₀ hτ).mp (show 1 / τ < Λ by linarith) |
| 322 | - nlinarith | |
| 322 | + linarith | |
| 323 | 323 | have hp := (abs_lt.mp (hpert p (1 / Λ) hnorm)).1 |
| 324 | 324 | have hm := habsorb Λ ((le_max_left _ _).trans hΛ) p |
| 325 | - nlinarith | |
| 325 | + linarith | |
| 326 | 326 | |
| 327 | 327 | theorem hold_source_identity {D : RadialDomain} (P : Profiles D) (h j σ : ℝ) |
| 328 | 328 | {Λ : ℝ} (hΛ : Λ ≠ 0) (p : Point) |
| @@ -702,7 +702,7 @@ theorem stockJet_uniform_bound {B B0 : ℝ} (hB : 0 ≤ B) (hB0 : 0 ≤ B0) : | ||
| 702 | 702 | obtain ⟨K0, hK0, hb⟩ := uniform_density_bound B |
| 703 | 703 | let K := 1 + B + B0 + 110 * K0 |
| 704 | 704 | have hK : 0 < K := by dsimp [K]; positivity |
| 705 | - have hBK : B ≤ K := by dsimp [K]; nlinarith | |
| 705 | + have hBK : B ≤ K := by dsimp [K]; linarith | |
| 706 | 706 | have hHK : B0 + 110 * K0 ≤ K := by dsimp [K]; linarith |
| 707 | 707 | refine ⟨K, hK, ?_⟩ |
| 708 | 708 | intro D P p hp hX hp0 hp0' hfield |
| @@ -712,7 +712,7 @@ theorem stockJet_uniform_bound {B B0 : ℝ} (hB : 0 ≤ B) (hB0 : 0 ≤ B0) : | ||
| 712 | 712 | have hini : |profileInitial P r p.2| ≤ B0 := by |
| 713 | 713 | cases r <;> simpa only [profileInitial, abs_zero] using (by assumption) |
| 714 | 714 | have hini' : |deriv (profileInitial P r) p.2| ≤ B0 := by |
| 715 | - cases r <;> simpa only [profileInitial, deriv_const, abs_zero] using (by assumption) | |
| 715 | + cases r <;> simpa only [profileInitial, deriv_const] using (by assumption) | |
| 716 | 716 | have hv : |primitive (profileDensity P r) p| ≤ 110 * K0 := by |
| 717 | 717 | apply integral_bounded_length hX hK0 |
| 718 | 718 | intro t ht |
| @@ -837,12 +837,12 @@ theorem comparison_tolerances {M : ℝ} (hM : 0 ≤ M) : | ||
| 837 | 837 | exact one_div_mul_cancel hkden.ne' |
| 838 | 838 | refine ⟨ε, κstar, lt_min zero_lt_one (one_div_pos.mpr (mul_pos (by norm_num) hp)), |
| 839 | 839 | min_le_left _ _, hk, ?_, ?_, ?_, ?_⟩ |
| 840 | - · nlinarith [mul_nonneg hk.le hv, mul_nonneg hk.le hM] | |
| 840 | + · linarith [mul_nonneg hk.le hv, mul_nonneg hk.le hM] | |
| 841 | 841 | · have hh := (le_div_iff₀ (mul_pos (by norm_num : (0 : ℝ) < 8) hp)).mp (min_le_right 1 (1 / (8 * projectionConstant M))) |
| 842 | 842 | dsimp [ε] |
| 843 | 843 | nlinarith |
| 844 | - · nlinarith [mul_nonneg hk.le hM] | |
| 845 | - · nlinarith [mul_nonneg hk.le hv] | |
| 844 | + · linarith [mul_nonneg hk.le hM] | |
| 845 | + · linarith [mul_nonneg hk.le hv] | |
| 846 | 846 | |
| 847 | 847 | theorem reference_fieldJet_bound {D : RadialDomain} (P : Profiles D) |
| 848 | 848 | {h j σ Λ C B K : ℝ} (hsmall : NaturalAxisData.SmallParameters h j) |
| @@ -1742,7 +1742,7 @@ theorem exists_comparable_ramp {h j σ Λ C B K r0 : ℝ} {P0 : ℝ → ℝ} | ||
| 1742 | 1742 | have hu : εU ≤ 1 / (4 * Λ) := min_le_right _ _ |
| 1743 | 1743 | have hid : 1 / (4 * Λ) = (1 / Λ) / 4 := by ring |
| 1744 | 1744 | rw [hid] at hu |
| 1745 | - nlinarith [one_div_pos.mpr hΛ] | |
| 1745 | + linarith [one_div_pos.mpr hΛ] | |
| 1746 | 1746 | have hUraw : εU + εU < c.fieldTolerance := by |
| 1747 | 1747 | have hu : εU ≤ εF := min_le_left _ _ |
| 1748 | 1748 | dsimp [εF] at hu |
+1 −1 NavierStokes/ActivationStocks.lean View file
| @@ -709,7 +709,7 @@ theorem log_stocks_uniform_jets {K : Set ℝ} (hK : IsCompact K) (hKJ : K ⊆ J) | ||
| 709 | 709 | have ha : 0 ≤ y * activation T κ y := mul_nonneg hy.1 (activation_nonneg T κ y hκ.2) |
| 710 | 710 | have hinc1 := mul_nonneg (sub_nonneg.mpr (le_max_left M₁ M₂)) ha |
| 711 | 711 | have hinc2 := mul_nonneg (sub_nonneg.mpr (le_max_right M₁ M₂)) ha |
| 712 | - constructor <;> nlinarith | |
| 712 | + constructor <;> linarith | |
| 713 | 713 | |
| 714 | 714 | end ConstructedFactors |
| 715 | 715 | |
+2 −3 NavierStokes/AlignedProfileSpectralCone.lean View file
| @@ -234,7 +234,7 @@ private theorem referenceCone_of_speed {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 234 | 234 | have he : a * (a * (1 + (c / a) ^ 2)) = a ^ 2 + c ^ 2 := by |
| 235 | 235 | field_simp |
| 236 | 236 | have hm := mul_lt_mul_of_pos_left hv ha |
| 237 | - nlinarith | |
| 237 | + linarith | |
| 238 | 238 | |
| 239 | 239 | private theorem normalized_target_of_tilt {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) |
| 240 | 240 | (hv : 2 < a * (1 + (c / a) ^ 2)) (B : ℝ × ℝ) (hB : 0 < B.1) |
| @@ -323,8 +323,7 @@ theorem exists_closed_direction (hcone : LeadingStressWeights.FullTrueCone v) : | ||
| 323 | 323 | have hin := her.trans_le hm.1 |
| 324 | 324 | have hgap := her.trans_le hm.2 |
| 325 | 325 | simp only [ActiveAnnulusWeight.rightChart, sub_zero, |
| 326 | - ActiveAnnulusWeight.directionProjection, ActiveAnnulusWeight.directionGap, | |
| 327 | - ActiveAnnulusWeight.tilt, LeadingStressWeights.logSlope, | |
| 326 | + ActiveAnnulusWeight.directionProjection, ActiveAnnulusWeight.tilt, LeadingStressWeights.logSlope, | |
| 328 | 327 | LeadingStressWeights.logSpeed, ActivationContinuation.shearSize] at hin hgap |
| 329 | 328 | have ht := normalized_target_of_tilt homega hspeed.1 hspeed.2 |
| 330 | 329 | (FR.coefficient (eta, 0)) (hFR eta heta) hin hgap |
+2 −2 NavierStokes/AngularMomentReset.lean View file
| @@ -119,7 +119,7 @@ def linearMatrix (lam : ℝ) : Matrix (Fin 2) (Fin 2) ℝ := | ||
| 119 | 119 | theorem linearMatrix_det (lam : ℝ) : |
| 120 | 120 | (linearMatrix lam).det = 2 * moment (angularSlope lam) * moment (pressureSlope lam) * |
| 121 | 121 | (Real.exp (2 * pressureSlope lam) - Real.exp (2 * angularSlope lam)) := by |
| 122 | - simp [linearMatrix, Matrix.det_fin_two] | |
| 122 | + simp [linearMatrix] | |
| 123 | 123 | ring |
| 124 | 124 | |
| 125 | 125 | theorem linearMatrix_det_ne_zero (lam : ℝ) (hlam : 0 < lam) : |
| @@ -312,7 +312,7 @@ theorem relative_first_jet_bound : | ||
| 312 | 312 | _ ≤ ‖c‖ * D0 + ‖c‖ * D1 := add_le_add |
| 313 | 313 | (mul_le_mul hc0 (hb0 y) (abs_nonneg _) (norm_nonneg _)) |
| 314 | 314 | (mul_le_mul hc1 (hb1 y) (abs_nonneg _) (norm_nonneg _)) |
| 315 | - _ ≤ (2 + D0 + D1) * ‖c‖ := by nlinarith [norm_nonneg c] | |
| 315 | + _ ≤ (2 + D0 + D1) * ‖c‖ := by linarith [norm_nonneg c] | |
| 316 | 316 | |
| 317 | 317 | theorem positive_and_slope_of_small (lam : ℝ) (hlam : 0 < lam) (c : Coeff) (y : ℝ) |
| 318 | 318 | (h0 : |relative c y| ≤ 1 / 2) (h1 : |deriv (relative c) y| ≤ lam / 4) : |
+1 −1 NavierStokes/AxisContraction.lean View file
| @@ -279,7 +279,7 @@ theorem exists_fixedPoint_of_controlled [CompleteSpace E] | ||
| 279 | 279 | have h := hdiff hym hx |
| 280 | 280 | change ‖F y - F x‖ ≤ (1 / 2 : ℝ) * ‖y - x‖ at h |
| 281 | 281 | rw [show F y = y from hyfix, hfix.eq] at h |
| 282 | - have : ‖y - x‖ = 0 := by nlinarith [norm_nonneg (y - x)] | |
| 282 | + have : ‖y - x‖ = 0 := by linarith [norm_nonneg (y - x)] | |
| 283 | 283 | exact sub_eq_zero.mp (norm_eq_zero.mp this) |
| 284 | 284 | |
| 285 | 285 | /-- Actual bounded coefficient operators, later instantiated by AxisOperators. |
+4 −4 NavierStokes/AxisHolomorphic.lean View file
| @@ -87,7 +87,7 @@ theorem term_factorial_bound (I : Window) {ε R s : ℝ} (hε : 0 < ε) | ||
| 87 | 87 | ((1 / (1 - s) ^ (m + 1)) * (R / 20 / s) ^ n) := by |
| 88 | 88 | gcongr |
| 89 | 89 | _ = _ := by |
| 90 | - simp only [mul_inv_rev, mul_pow, pow_succ, div_eq_mul_inv, mul_inv_rev] | |
| 90 | + simp only [mul_inv_rev, pow_succ, div_eq_mul_inv, mul_inv_rev] | |
| 91 | 91 | ring |
| 92 | 92 | |
| 93 | 93 | /-- Uniform genuine factorial bounds for all evaluated parameter derivatives. |
| @@ -202,7 +202,7 @@ theorem verticalTerm_hasFDerivAt {c : ℕ → ℝ → ℝ} {z : ℂ} (m : ℕ) | ||
| 202 | 202 | cases m with |
| 203 | 203 | | zero => simp [verticalX, verticalY, verticalTerm, complexLinearForm, mul_comm] |
| 204 | 204 | | succ m => |
| 205 | - simp [verticalX, verticalY, verticalTerm, complexLinearForm, pow_succ] | |
| 205 | + simp [verticalX, verticalTerm, complexLinearForm, pow_succ] | |
| 206 | 206 | ring |
| 207 | 207 | |
| 208 | 208 | theorem verticalTerm_bound {c : ℕ → ℝ → ℝ} {C a : ℝ} (hC : 0 ≤ C) (ha : 0 < a) |
| @@ -247,7 +247,7 @@ theorem verticalY_bound {c : ℕ → ℝ → ℝ} {C a : ℝ} (hC : 0 ≤ C) (ha | ||
| 247 | 247 | simp only [verticalY_succ, norm_mul, Complex.norm_I, one_mul] |
| 248 | 248 | refine (verticalX_bound hC ha hz hc m).trans ?_ |
| 249 | 249 | simp only [Nat.cast_add, Nat.cast_one, pow_succ] |
| 250 | - nlinarith [mul_nonneg (div_nonneg hC ha.le) (pow_nonneg (by norm_num : (0 : ℝ) ≤ 1 / 2) m)] | |
| 250 | + linarith [mul_nonneg (div_nonneg hC ha.le) (pow_nonneg (by norm_num : (0 : ℝ) ≤ 1 / 2) m)] | |
| 251 | 251 | |
| 252 | 252 | theorem summable_verticalTerm {c : ℕ → ℝ → ℝ} {C a : ℝ} (hC : 0 ≤ C) (ha : 0 < a) |
| 253 | 253 | {z : ℂ} (hz : |z.im| ≤ a / 2) |
| @@ -296,7 +296,7 @@ theorem verticalExtension_hasDerivAt (I : Window) {c : ℕ → ℝ → ℝ} {C a | ||
| 296 | 296 | have hC' : 0 ≤ C / a := div_nonneg hC ha.le |
| 297 | 297 | have hgeom := (summable_geometricMoment (by norm_num : (0 : ℝ) < 1 / 2) |
| 298 | 298 | (by norm_num : (1 / 2 : ℝ) < 1) 1).mul_left (C / a) |
| 299 | - simp only [pow_one, ← mul_assoc] at hgeom | |
| 299 | + simp only [pow_one] at hgeom | |
| 300 | 300 | have hu := hgeom.mul_left 3 |
| 301 | 301 | have hX := summable_verticalX hC ha hz.2.le (fun m => hbound m z.re hz.1) |
| 302 | 302 | have hY := summable_verticalY hC ha hz.2.le (fun m => hbound m z.re hz.1) |
+1 −1 NavierStokes/AxisPreservation.lean View file
| @@ -57,7 +57,7 @@ theorem physicalQ_origin {h : ℝ} (hh : 0 < h) (hh1 : h < 1 / 2) | ||
| 57 | 57 | change SimilarityCoordinates.coordinateQ (2 * h) (1 - t, 0) = 1 - t |
| 58 | 58 | have hq := SimilarityCoordinates.coordinateQ_spec |
| 59 | 59 | (by linarith : 0 < 2 * h) (by linarith : 2 * h < 1) |
| 60 | - (p := (1 - t, 0)) (by simpa using sub_pos.mpr ht) | |
| 60 | + (p := (1 - t, 0)) (sub_pos.mpr ht) | |
| 61 | 61 | simpa only [SimilarityCoordinates.forwardScalar, zero_pow (by norm_num : 2 ≠ 0), |
| 62 | 62 | zero_mul, sub_zero] using hq.2 |
| 63 | 63 | |
+2 −2 NavierStokes/AxisProfile.lean View file
| @@ -59,7 +59,7 @@ theorem cubicLower_gt_quarter (t : ℝ) (ht : t ≤ 41 / 20) : | ||
| 59 | 59 | ring |
| 60 | 60 | norm_num [cubicLower] at hidentity |
| 61 | 61 | unfold cubicLower |
| 62 | - nlinarith | |
| 62 | + linarith | |
| 63 | 63 | |
| 64 | 64 | /-- A direct rational verification of the numerical strict inequality |
| 65 | 65 | used for the initial cone margin. -/ |
| @@ -74,7 +74,7 @@ theorem quarticUpper_lt_neg_eighteen_hundredths | ||
| 74 | 74 | have hfour := pow_le_pow_left₀ ht hhi 4 |
| 75 | 75 | norm_num at hsquare hcube hfour |
| 76 | 76 | unfold quarticUpper |
| 77 | - nlinarith | |
| 77 | + linarith | |
| 78 | 78 | |
| 79 | 79 | /-- The leading axial profile displayed in the scaled construction. -/ |
| 80 | 80 | def leadingAxial (Z L Y : ℝ) : ℝ := -Y * Z / (2 * L) |
+4 −4 NavierStokes/AxisReference.lean View file
| @@ -101,7 +101,7 @@ theorem reference_coefficient (I : Window) {ε : ℝ} (hε : 0 < ε) | ||
| 101 | 101 | have hn1 : (n : ℝ) + 1 ≠ 0 := by positivity |
| 102 | 102 | have hn2 : (n : ℝ) + 2 ≠ 0 := by positivity |
| 103 | 103 | simp only [Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, Nat.cast_one, |
| 104 | - radialDivisor, Nat.cast_ofNat, pow_succ] | |
| 104 | + radialDivisor, Nat.cast_ofNat] | |
| 105 | 105 | field_simp ; ring |
| 106 | 106 | |
| 107 | 107 | /-- Evaluation of the actual coefficient-space reference equals the |
| @@ -179,7 +179,7 @@ theorem log_slope_stability {v₀ v d₀ d : ℝ} | ||
| 179 | 179 | rw [lt_div_iff₀ hv₀pos] at hslope |
| 180 | 180 | have he0 := (abs_le.mp hvalue).2 |
| 181 | 181 | have he1 := (abs_le.mp hderiv).2 |
| 182 | - nlinarith | |
| 182 | + linarith | |
| 183 | 183 | |
| 184 | 184 | /-- A single lower bound on the scale makes both evaluation constants |
| 185 | 185 | small enough for positivity and logarithmic-slope stability. -/ |
| @@ -188,9 +188,9 @@ theorem scaled_error_le {C C₀ C₁ K Λ : ℝ} | ||
| 188 | 188 | (hK : 0 ≤ K) (hΛ : 1 + 500 * (C₀ + C₁) * K ≤ Λ) : |
| 189 | 189 | C * (K / (2 * Λ)) ≤ 1 / 1000 := by |
| 190 | 190 | have hsum : 0 ≤ C₀ + C₁ := add_nonneg hC₀ hC₁ |
| 191 | - have hΛpos : 0 < Λ := by nlinarith [mul_nonneg hsum hK] | |
| 191 | + have hΛpos : 0 < Λ := by linarith [mul_nonneg hsum hK] | |
| 192 | 192 | rw [← mul_div_assoc, div_le_iff₀ (by positivity : 0 < 2 * Λ)] |
| 193 | - nlinarith [mul_le_mul_of_nonneg_right hCsum hK] | |
| 193 | + linarith [mul_le_mul_of_nonneg_right hCsum hK] | |
| 194 | 194 | |
| 195 | 195 | /-- This explicit threshold controls both values and first radial derivatives |
| 196 | 196 | on `|Y|≤5`, uniformly over the parameter interval. -/ |
+1 −1 NavierStokes/AxisResolvent.lean View file
| @@ -60,7 +60,7 @@ theorem factorialMajorant_succ (K : ℝ) (k : ℕ) : | ||
| 60 | 60 | have h₁ : (k : ℝ) + 1 ≠ 0 := by positivity |
| 61 | 61 | have h₂ : (k : ℝ) + 2 ≠ 0 := by positivity |
| 62 | 62 | simp only [factorialMajorant, Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, |
| 63 | - Nat.cast_one, pow_succ] | |
| 63 | + Nat.cast_one] | |
| 64 | 64 | field_simp ; ring |
| 65 | 65 | |
| 66 | 66 | section RadialJets |
+4 −4 NavierStokes/AxisSeries.lean View file
| @@ -127,7 +127,7 @@ theorem term_contiguous (k n : ℕ) (t : ℝ) : | ||
| 127 | 127 | simp only [term, show n + 1 + k = (n + k) + 1 by omega, |
| 128 | 128 | show n + 1 + (k + 1) = (n + k) + 1 + 1 by omega, |
| 129 | 129 | show n + (k + 2) = (n + k) + 1 + 1 by omega, |
| 130 | - Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, Nat.cast_one, pow_succ] | |
| 130 | + Nat.factorial_succ, Nat.cast_mul, Nat.cast_add, Nat.cast_one] | |
| 131 | 131 | field_simp; ring |
| 132 | 132 | |
| 133 | 133 | theorem factorial_reciprocal (k : ℕ) : |
| @@ -265,7 +265,7 @@ theorem profile_gt_quarter (χ Y : ℝ) (hχ0 : 0 ≤ χ) (hχ1 : χ ≤ 1) | ||
| 265 | 265 | (hY0 : 0 ≤ Y) (hY1 : Y ≤ 41 / 10) : 1 / 4 < profile χ Y := by |
| 266 | 266 | apply bessel_one_gt_quarter |
| 267 | 267 | · positivity |
| 268 | - · nlinarith [mul_nonneg (sub_nonneg.mpr hχ1) hY0] | |
| 268 | + · linarith [mul_nonneg (sub_nonneg.mpr hχ1) hY0] | |
| 269 | 269 | |
| 270 | 270 | /-- A convergent alternating tail beginning with its positive sign has |
| 271 | 271 | nonnegative total, for every offset starting after at least one term. -/ |
| @@ -279,7 +279,7 @@ theorem alternating_tail_nonneg (k j : ℕ) (hj : 1 ≤ j) | ||
| 279 | 279 | simp |
| 280 | 280 | have hb := Antitone.alternating_series_le_tendsto hs.hasSum.tendsto_sum_nat |
| 281 | 281 | (magnitude_tail_antitone k j hj t ht0 ht) 0 |
| 282 | - simpa using hb | |
| 282 | + exact hb | |
| 283 | 283 | |
| 284 | 284 | /-- Every odd-length truncation with at least one term is an upper bound |
| 285 | 285 | on the actual series on this interval. -/ |
| @@ -335,7 +335,7 @@ theorem bessel_one_log_slope_gt (t : ℝ) (ht0 : 99 / 50 ≤ t) (ht1 : t ≤ 2) | ||
| 335 | 335 | have hsign := bessel_zero_lt_neg_eighteen_hundredths t ht0 ht1 |
| 336 | 336 | rw [← bessel_one_add_mul_deriv t] at hsign |
| 337 | 337 | apply (lt_div_iff₀ hpos).mpr |
| 338 | - nlinarith | |
| 338 | + linarith | |
| 339 | 339 | |
| 340 | 340 | /-- The exact leading profile has the stated `2.36` slope margin at `Y=4` |
| 341 | 341 | when `χ≥0.99`. No perturbation estimate is asserted. -/ |
+3 −3 NavierStokes/AxisWeightEstimates.lean View file
| @@ -60,7 +60,7 @@ theorem squareDecay_succ_le (n : ℕ) : squareDecay (n + 1) ≤ squareDecay n := | ||
| 60 | 60 | unfold squareDecay |
| 61 | 61 | apply one_div_le_one_div_of_le (by positivity) |
| 62 | 62 | push_cast |
| 63 | - nlinarith [show (0 : ℝ) ≤ n by positivity] | |
| 63 | + linarith [show (0 : ℝ) ≤ n by positivity] | |
| 64 | 64 | |
| 65 | 65 | theorem squareDecay_le_four_succ (n : ℕ) : squareDecay n ≤ 4 * squareDecay (n + 1) := by |
| 66 | 66 | unfold squareDecay |
| @@ -92,7 +92,7 @@ theorem sum_squareDecay_le (n : ℕ) : | ||
| 92 | 92 | have hn : (0 : ℝ) ≤ n := by positivity |
| 93 | 93 | have htel := reciprocal_square_telescope ((n : ℝ) + 2) (by linarith) |
| 94 | 94 | have hid : squareDecay (n + 1) = 1 / ((n : ℝ) + 2) ^ 2 := by |
| 95 | - simp [squareDecay, Nat.cast_add, Nat.cast_one] | |
| 95 | + simp [squareDecay, Nat.cast_one] | |
| 96 | 96 | ring |
| 97 | 97 | rw [hid] |
| 98 | 98 | push_cast |
| @@ -114,7 +114,7 @@ theorem squareDecay_product_le (i j : ℕ) : | ||
| 114 | 114 | have hpoly : (((i + j : ℕ) : ℝ) + 1) ^ 2 ≤ |
| 115 | 115 | 2 * (((i : ℝ) + 1) ^ 2 + ((j : ℝ) + 1) ^ 2) := by |
| 116 | 116 | push_cast |
| 117 | - nlinarith [sq_nonneg ((i : ℝ) - (j : ℝ))] | |
| 117 | + linarith [sq_nonneg ((i : ℝ) - (j : ℝ))] | |
| 118 | 118 | have hh := div_le_div_of_nonneg_right hpoly (le_of_lt |
| 119 | 119 | (mul_pos (mul_pos (sq_pos_of_pos hi) (sq_pos_of_pos hj)) (sq_pos_of_pos hij))) |
| 120 | 120 | convert! hh using 1 <;> unfold squareDecay <;> |
+3 −3 NavierStokes/ChartScales.lean View file
| @@ -70,7 +70,7 @@ theorem radialExponent_pos (h : ℝ) (hh : 0 ≤ h) : 0 < radialExponent h := by | ||
| 70 | 70 | have hk : kappa < rho := by unfold kappa; linarith [rho_lower] |
| 71 | 71 | have hm := mul_nonneg hh (sub_nonneg.mpr hk.le) |
| 72 | 72 | unfold radialExponent |
| 73 | - nlinarith [rho_pos] | |
| 73 | + linarith [rho_pos] | |
| 74 | 74 | |
| 75 | 75 | theorem Q_pos (n : ℕ) : 0 < Q n := Real.rpow_pos_of_pos (by norm_num) _ |
| 76 | 76 | |
| @@ -188,7 +188,7 @@ private theorem one_div_TS_rpow {n : ℕ} (hn : 1 ≤ n) : | ||
| 188 | 188 | (1 / (Tg * S n)) ^ rho = S n ^ (-rho) / Lambda := by |
| 189 | 189 | rw [Real.div_rpow zero_le_one (mul_pos Tg_pos (S_pos hn)).le, Real.one_rpow, |
| 190 | 190 | Real.mul_rpow Tg_pos.le (S_pos hn).le, Tg_rpow_rho, Real.rpow_neg (S_pos hn).le] |
| 191 | - simp [div_eq_mul_inv, mul_comm] | |
| 191 | + simp [div_eq_mul_inv] | |
| 192 | 192 | |
| 193 | 193 | /-- The full `M_i` comparison in (25), obtained from the actual native index. -/ |
| 194 | 194 | theorem radialCoefficient_bounds (h : ℝ) (hh : 0 ≤ h) {n : ℕ} (hn : 4 ≤ n) : |
| @@ -221,7 +221,7 @@ theorem radialCoefficient_inv_upper (h : ℝ) (hh : 0 ≤ h) {n : ℕ} (hn : 4 | ||
| 221 | 221 | have hi := one_div_le_one_div_of_le hpos hl |
| 222 | 222 | have hS : 0 < S n := S_pos (by omega) |
| 223 | 223 | simpa [Real.rpow_neg (epsilon_pos h n).le, Real.rpow_neg hS.le, |
| 224 | - div_eq_mul_inv, mul_assoc, mul_comm, mul_left_comm] using hi | |
| 224 | + div_eq_mul_inv, mul_comm, mul_left_comm] using hi | |
| 225 | 225 | |
| 226 | 226 | theorem timeCoefficient_inv_lower (h : ℝ) (hh : 0 ≤ h) {n : ℕ} (hn : 4 ≤ n) : |
| 227 | 227 | S n ≤ (timeCoefficient h n)⁻¹ := by |
+2 −2 NavierStokes/ClosedNativeWaveIdentities.lean View file
| @@ -115,7 +115,7 @@ theorem cylindricalLaplacian_phase_at (R : D → ℝ) (Vr Vθ Vz : D → D) | ||
| 115 | 115 | along Vr (fun y => phaseNormal R Vr Vθ Vz Φ y 0) x + |
| 116 | 116 | phaseNormal R Vr Vθ Vz Φ x 0 / R x + |
| 117 | 117 | along Vz (fun y => phaseNormal R Vr Vθ Vz Φ y 2) x := by |
| 118 | - simp [cylindricalLaplacian, along_along_const_germ hΦθ, phaseNormal, smul_eq_mul, div_eq_mul_inv] | |
| 118 | + simp [cylindricalLaplacian, along_along_const_germ hΦθ, phaseNormal, smul_eq_mul] | |
| 119 | 119 | ring |
| 120 | 120 | |
| 121 | 121 | theorem cylindricalVectorLaplacian_mode_at (R : D → ℝ) {Vr Vθ Vz : D → D} (κ : ℝ) |
| @@ -141,7 +141,7 @@ theorem cylindricalVectorLaplacian_mode_at (R : D → ℝ) {Vr Vθ Vz : D → D} | ||
| 141 | 141 | rw [hL i] |
| 142 | 142 | fin_cases i <;> |
| 143 | 143 | simp [cylindricalVectorLaplacian, angularGenerator, vectorMode, hD 0, hD 1, |
| 144 | - mode, phaseNormal, Complex.real_smul, div_eq_mul_inv, pow_two] <;> ring | |
| 144 | + mode, phaseNormal, Complex.real_smul, pow_two] <;> ring | |
| 145 | 145 | |
| 146 | 146 | theorem cylindricalVectorLaplacian_angular_independent_at (R : D → ℝ) (Vr Vθ Vz : D → D) |
| 147 | 147 | {a : D → ComplexVector} {x : D} |
+6 −7 NavierStokes/ConeAlgebra.lean View file
| @@ -21,12 +21,11 @@ noncomputable def coneBound (P J : ℝ) : ℝ := | ||
| 21 | 21 | noncomputable def rootTerm (P J : ℝ) : ℝ := |
| 22 | 22 | |J| * Real.sqrt ((P - 2) / 2 + J ^ 2 / 16) |
| 23 | 23 | |
| 24 | -theorem rootTerm_nonneg (P J : ℝ) : 0 ≤ rootTerm P J := by | |
| 25 | - exact mul_nonneg (abs_nonneg _) (Real.sqrt_nonneg _) | |
| 24 | +theorem rootTerm_nonneg (P J : ℝ) : 0 ≤ rootTerm P J := mul_nonneg (abs_nonneg _) (Real.sqrt_nonneg _) | |
| 26 | 25 | |
| 27 | 26 | theorem rootTerm_sq {P J : ℝ} (hP : 2 < P) : |
| 28 | 27 | rootTerm P J ^ 2 = J ^ 2 * ((P - 2) / 2 + J ^ 2 / 16) := by |
| 29 | - have hrad : 0 ≤ (P - 2) / 2 + J ^ 2 / 16 := by nlinarith [sq_nonneg J] | |
| 28 | + have hrad : 0 ≤ (P - 2) / 2 + J ^ 2 / 16 := by linarith [sq_nonneg J] | |
| 30 | 29 | unfold rootTerm |
| 31 | 30 | rw [mul_pow, sq_abs, Real.sq_sqrt hrad] |
| 32 | 31 | |
| @@ -76,14 +75,14 @@ theorem true_cone_iff {P J v : ℝ} (hv : 2 < v) : | ||
| 76 | 75 | linarith |
| 77 | 76 | have hdiff := mul_pos (sub_pos.mpr hlt) |
| 78 | 77 | (show 0 < P + J ^ 2 / 4 - v + rootTerm P J by linarith) |
| 79 | - nlinarith | |
| 78 | + linarith | |
| 80 | 79 | · rintro ⟨hvP, hquad⟩ |
| 81 | 80 | have hP : 2 < P := lt_trans hv hvP |
| 82 | 81 | refine ⟨hP, ?_⟩ |
| 83 | 82 | have hsq := rootTerm_sq (J := J) hP |
| 84 | 83 | have hr := rootTerm_nonneg P J |
| 85 | 84 | have hid := square_difference P J v |
| 86 | - have hpos : 0 < P + J ^ 2 / 4 - v := by nlinarith [sq_nonneg J] | |
| 85 | + have hpos : 0 < P + J ^ 2 / 4 - v := by linarith [sq_nonneg J] | |
| 87 | 86 | have hlt : rootTerm P J < P + J ^ 2 / 4 - v := by nlinarith |
| 88 | 87 | change v < P + J ^ 2 / 4 - rootTerm P J |
| 89 | 88 | linarith |
| @@ -105,7 +104,7 @@ theorem normalized_test_negative {a b w : ℝ} (ha : 0 < a) | ||
| 105 | 104 | (a * (1 + (b / a) ^ 2) - 2) * (w + b / a) ^ 2 - |
| 106 | 105 | 2 * (1 - b * w / a) ^ 2 < 0 := by |
| 107 | 106 | rw [normalized_factorization a b w (ne_of_gt ha)] |
| 108 | - exact mul_neg_of_pos_of_neg (by nlinarith [sq_nonneg (b / a)]) (by linarith) | |
| 107 | + exact mul_neg_of_pos_of_neg (by linarith [sq_nonneg (b / a)]) (by linarith) | |
| 109 | 108 | |
| 110 | 109 | /-- An explicit finite-amplitude sufficient condition, prior to taking any limit. -/ |
| 111 | 110 | theorem finite_amplitude_cone {c j v p : ℝ} (hp : 0 < p) |
| @@ -119,7 +118,7 @@ theorem finite_amplitude_cone {c j v p : ℝ} (hp : 0 < p) | ||
| 119 | 118 | have hid : 2 * (p * c - v) ^ 2 - (v - 2) * (p * j) ^ 2 = |
| 120 | 119 | p * (p * (2 * c ^ 2 - (v - 2) * j ^ 2) - 4 * c * v) + 2 * v ^ 2 := by |
| 121 | 120 | ring |
| 122 | - nlinarith [sq_nonneg v] | |
| 121 | + linarith [sq_nonneg v] | |
| 123 | 122 | · exact relaxed_cone_of_le_two hP (le_of_not_gt hv) |
| 124 | 123 | |
| 125 | 124 | /-- For fixed normalized parameters, a positive leading coefficient and strict |
+1 −1 NavierStokes/CoordinateAlgebra.lean View file
| @@ -24,7 +24,7 @@ def L (h η : ℝ) : ℝ := 1 - 2 * h * η ^ 2 | ||
| 24 | 24 | theorem L_pos {h η : ℝ} (hh₀ : 0 ≤ h) (hh : h < 1 / 2) |
| 25 | 25 | (hη : η ^ 2 ≤ 1) : 0 < L h η := by |
| 26 | 26 | unfold L |
| 27 | - nlinarith [mul_nonneg hh₀ (sub_nonneg.mpr hη)] | |
| 27 | + linarith [mul_nonneg hh₀ (sub_nonneg.mpr hη)] | |
| 28 | 28 | |
| 29 | 29 | def qTime (h η : ℝ) : ℝ := -1 / L h η |
| 30 | 30 | def etaTime (q h η : ℝ) : ℝ := D h * η / (q * L h η) |
+4 −4 NavierStokes/CorrectedPressureBounds.lean View file
| @@ -183,7 +183,7 @@ theorem editDensityEta_abs_le {d : TailData} {K : ℝ} | ||
| 183 | 183 | have h2 := mul_le_mul h1 ha (abs_nonneg _) (by positivity : 0 ≤ 2 * (Real.exp 5 * releaseSquare d)) |
| 184 | 184 | have h3 := mul_le_mul h2 hr (abs_nonneg _) |
| 185 | 185 | (by positivity : 0 ≤ 2 * (Real.exp 5 * releaseSquare d) * (3 / 2)) |
| 186 | - nlinarith | |
| 186 | + linarith | |
| 187 | 187 | · rw [editDensityEta_zero_outside w eta ht, abs_zero] |
| 188 | 188 | exact mul_nonneg (mul_nonneg (mul_nonneg (by norm_num) (editSize_nonneg w)) |
| 189 | 189 | (Real.exp_pos _).le) (releaseSquare_pos d).le |
| @@ -342,7 +342,7 @@ theorem half_partial_integral_abs_le {f : ℝ → ℝ} {B r y : ℝ} | ||
| 342 | 342 | rw [Real.norm_eq_abs] at hi |
| 343 | 343 | rw [abs_mul] |
| 344 | 344 | rw [abs_of_nonneg (by norm_num : (0 : ℝ) ≤ 1 / 2)] |
| 345 | - nlinarith [mul_le_mul_of_nonneg_left hlen hB] | |
| 345 | + linarith [mul_le_mul_of_nonneg_left hlen hB] | |
| 346 | 346 | |
| 347 | 347 | theorem pressureChange_deriv_abs_le {d : TailData} {K : ℝ} |
| 348 | 348 | (w : ResetWitness d K) (y eta : ℝ) : |
| @@ -460,13 +460,13 @@ theorem corrected_bounds_of_small {d : TailData} {K : ℝ} | ||
| 460 | 460 | have he := Real.exp_pos (5 : ℝ) |
| 461 | 461 | have hfirst : (9 / 2 : ℝ) * envelopeConstant ≤ correctedConstant := by |
| 462 | 462 | unfold correctedConstant |
| 463 | - nlinarith | |
| 463 | + linarith | |
| 464 | 464 | have hderiv : 8 * envelopeConstant * |eta| + 48 * Real.exp 5 * editSize d K ≤ |
| 465 | 465 | correctedConstant := by |
| 466 | 466 | have hη := mul_le_mul_of_nonneg_left heta (show 0 ≤ 8 * envelopeConstant by positivity) |
| 467 | 467 | have hs := mul_le_mul_of_nonneg_left hsmall (show 0 ≤ 48 * Real.exp 5 by positivity) |
| 468 | 468 | unfold correctedConstant |
| 469 | - nlinarith | |
| 469 | + linarith | |
| 470 | 470 | exact ⟨(correctedPi_abs_le w hy heta).trans |
| 471 | 471 | (mul_le_mul_of_nonneg_right hfirst (sq_nonneg _)), |
| 472 | 472 | (correctedPi_deriv_abs_le w hy heta).trans |
+10 −11 NavierStokes/CorrectedPulseAmplitude.lean View file
| @@ -80,7 +80,7 @@ theorem discriminant_pos (d : TailData) (c : ℝ → Coeff) (eta : ℝ) : 0 < di | ||
| 80 | 80 | unfold discriminant |
| 81 | 81 | have ha := PulseAmplitude.quadraticCoefficient_pos d.core |
| 82 | 82 | have hc := PulseAmplitude.negativeClamp_neg (constantTerm d c eta) |
| 83 | - nlinarith [sq_nonneg (PulseAmplitude.linearTerm d.core eta), mul_neg_of_pos_of_neg ha hc] | |
| 83 | + linarith [sq_nonneg (PulseAmplitude.linearTerm d.core eta), mul_neg_of_pos_of_neg ha hc] | |
| 84 | 84 | |
| 85 | 85 | def amplitude (d : TailData) (c : ℝ → Coeff) (eta : ℝ) : ℝ := |
| 86 | 86 | (-PulseAmplitude.linearTerm d.core eta + Real.sqrt (discriminant d c eta)) / |
| @@ -153,7 +153,7 @@ theorem power29_le_lambda (d : TailData) : d.core.lam ^ (29 : ℕ) ≤ d.core.la | ||
| 153 | 153 | pow_le_one₀ d.core.lam_pos.le (by linarith [d.core.lam_lt]) |
| 154 | 154 | calc |
| 155 | 155 | _ = d.core.lam * d.core.lam ^ (28 : ℕ) := by ring |
| 156 | - _ ≤ _ := by nlinarith [mul_le_mul_of_nonneg_left hpow d.core.lam_pos.le] | |
| 156 | + _ ≤ _ := by linarith [mul_le_mul_of_nonneg_left hpow d.core.lam_pos.le] | |
| 157 | 157 | |
| 158 | 158 | theorem energyShift_bounds {d : TailData} {K : ℝ} (w : ResetWitness d K) (hK : 0 < K) (eta : ℝ) |
| 159 | 159 | (heta : eta ^ 2 ≤ 1) : |
| @@ -176,10 +176,10 @@ theorem energyShift_bounds {d : TailData} {K : ℝ} (w : ResetWitness d K) (hK : | ||
| 176 | 176 | constructor |
| 177 | 177 | · unfold energyShift |
| 178 | 178 | rw [abs_div, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 179 | - nlinarith [mul_nonneg hK.le (pow_nonneg d.core.lam_pos.le (29 : ℕ))] | |
| 179 | + linarith [mul_nonneg hK.le (pow_nonneg d.core.lam_pos.le (29 : ℕ))] | |
| 180 | 180 | · change |deriv (fun t => ResetEnergyBounds.normalizedResetEnergy d w.coefficients t / 2) eta| ≤ _ |
| 181 | 181 | rw [hd, abs_div, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 182 | - nlinarith | |
| 182 | + linarith | |
| 183 | 183 | |
| 184 | 184 | theorem old_error_bounds (d : TailData) (K : ℝ) (hK : 0 < K) |
| 185 | 185 | (hsmall : d.core.lam ≤ 1 / 120) (hwait : d.core.wait = 60 * Real.log (1 / d.core.lam)) |
| @@ -210,7 +210,7 @@ theorem numerical_coefficient_bounds (d : TailData) (c : ℝ → Coeff) (eta e : | ||
| 210 | 210 | PulseAmplitude.etaPolynomial eta ^ 2 ≤ 8 * e := by |
| 211 | 211 | have hm := mul_le_mul (add_le_add h.correction_error h.prefix_axial_error) hq2 |
| 212 | 212 | (sq_nonneg (PulseAmplitude.etaPolynomial eta)) (by linarith [h.scale_nonneg]) |
| 213 | - nlinarith | |
| 213 | + linarith | |
| 214 | 214 | have hD := RadialSchedule.pulse_energy_debt_bounds |
| 215 | 215 | obtain ⟨hsl, hsu⟩ := abs_le.mp hshift |
| 216 | 216 | refine ⟨ha, ha', hb, ?_, ?_⟩ |
| @@ -278,7 +278,7 @@ theorem amplitude_derivative_bound (d : TailData) {c : ℝ → Coeff} | ||
| 278 | 278 | PulseAmplitude.linearTerm d.core eta := by |
| 279 | 279 | have hm := mul_le_mul_of_nonneg_right ha (amplitude_pos d c eta).le |
| 280 | 280 | have hbl := (abs_le.mp hb).1 |
| 281 | - nlinarith | |
| 281 | + linarith | |
| 282 | 282 | have hid := amplitude_derivative_identity d hc eta (by linarith) |
| 283 | 283 | have heq : (2 * PulseAmplitude.quadraticCoefficient d.core * amplitude d c eta + |
| 284 | 284 | PulseAmplitude.linearTerm d.core eta) * deriv (amplitude d c) eta = |
| @@ -301,7 +301,7 @@ theorem amplitude_derivative_bound (d : TailData) {c : ℝ → Coeff} | ||
| 301 | 301 | have hupper := mul_le_mul hdb hr'.le (amplitude_pos d c eta).le |
| 302 | 302 | (by linarith [h.scale_nonneg] : 0 ≤ 4 * e) |
| 303 | 303 | have hlower := mul_le_mul_of_nonneg_right hden (abs_nonneg (deriv (amplitude d c) eta)) |
| 304 | - nlinarith [h.scale_nonneg] | |
| 304 | + linarith [h.scale_nonneg] | |
| 305 | 305 | |
| 306 | 306 | theorem energyPolynomial_strictMonoOn (d : TailData) (c : ℝ → Coeff) (eta e : ℝ) |
| 307 | 307 | (heta : eta ^ 2 ≤ 1) (h : PulseAmplitude.EnergyErrorBounds d eta e) |
| @@ -315,13 +315,13 @@ theorem energyPolynomial_strictMonoOn (d : TailData) (c : ℝ → Coeff) (eta e | ||
| 315 | 315 | PulseAmplitude.linearTerm d.core eta := by |
| 316 | 316 | have hbl := (abs_le.mp hb).1 |
| 317 | 317 | simp only [mem_Ici] at hA hB |
| 318 | - nlinarith | |
| 318 | + linarith | |
| 319 | 319 | have hp := mul_pos (sub_pos.mpr hAB) hcoef |
| 320 | 320 | change PulseAmplitude.quadraticCoefficient d.core * A ^ 2 + |
| 321 | 321 | PulseAmplitude.linearTerm d.core eta * A + constantTerm d c eta < |
| 322 | 322 | PulseAmplitude.quadraticCoefficient d.core * B ^ 2 + |
| 323 | 323 | PulseAmplitude.linearTerm d.core eta * B + constantTerm d c eta |
| 324 | - nlinarith only [hp] | |
| 324 | + linarith only [hp] | |
| 325 | 325 | |
| 326 | 326 | theorem amplitude_unique (d : TailData) (c : ℝ → Coeff) (eta e : ℝ) |
| 327 | 327 | (heta : eta ^ 2 ≤ 1) (h : PulseAmplitude.EnergyErrorBounds d eta e) |
| @@ -358,8 +358,7 @@ private theorem radialCoordinate_transform (d : TailData) (c : ℝ → Coeff) (a | ||
| 358 | 358 | funext y |
| 359 | 359 | have hlog : Real.log (XR * Real.exp y / XR) = y := by |
| 360 | 360 | rw [mul_comm XR, mul_div_cancel_right₀ _ hXR.ne', Real.log_exp] |
| 361 | - simp only [radialEnergyIntegrand, hlog, abs_of_pos (mul_pos hXR (Real.exp_pos _)), smul_eq_mul, | |
| 362 | - energyIntegrand] | |
| 361 | + simp only [radialEnergyIntegrand, hlog, abs_of_pos (mul_pos hXR (Real.exp_pos _)), energyIntegrand] | |
| 363 | 362 | rw [PulseAmplitude.axial_eq_of_amplitude_eq d.core amp (fun _ => amp eta) eta y rfl] |
| 364 | 363 | ring |
| 365 | 364 | |
+4 −5 NavierStokes/Covariance.lean View file
| @@ -41,7 +41,7 @@ def coefficients (a b scaleMinus scalePlus m t : ℝ) : Fin 2 → ℝ := | ||
| 41 | 41 | theorem determinant_formula (a b scaleMinus scalePlus : ℝ) : |
| 42 | 42 | (signedMatrix a b scaleMinus scalePlus).det = |
| 43 | 43 | -(2 * a * b * scaleMinus * scalePlus) := by |
| 44 | - simp [signedMatrix, Matrix.det_fin_two] | |
| 44 | + simp [signedMatrix] | |
| 45 | 45 | ring |
| 46 | 46 | |
| 47 | 47 | theorem determinant_neg {a b scaleMinus scalePlus : ℝ} |
| @@ -66,8 +66,7 @@ theorem reconstruct {a b scaleMinus scalePlus : ℝ} (m t : ℝ) | ||
| 66 | 66 | (coefficients a b scaleMinus scalePlus m t) = target m t := by |
| 67 | 67 | ext i |
| 68 | 68 | fin_cases i <;> |
| 69 | - simp [signedMatrix, coefficients, target, Matrix.mulVec, dotProduct, | |
| 70 | - Fin.sum_univ_two] <;> | |
| 69 | + simp [signedMatrix, coefficients, target, Matrix.mulVec, dotProduct] <;> | |
| 71 | 70 | field_simp <;> ring |
| 72 | 71 | |
| 73 | 72 | /-- Thus the explicit formula is the matrix inverse applied to the stress. -/ |
| @@ -150,14 +149,14 @@ def normalMagnitude (c u : ℝ) : ℝ := -c * Real.sqrt (1 + u ^ 2) | ||
| 150 | 149 | |
| 151 | 150 | theorem normalMagnitude_pos {c u : ℝ} (hc : c < 0) : 0 < normalMagnitude c u := by |
| 152 | 151 | unfold normalMagnitude |
| 153 | - exact mul_pos (neg_pos.mpr hc) (Real.sqrt_pos.mpr (by nlinarith [sq_nonneg u])) | |
| 152 | + exact mul_pos (neg_pos.mpr hc) (Real.sqrt_pos.mpr (by linarith [sq_nonneg u])) | |
| 154 | 153 | |
| 155 | 154 | /-- The manuscript's strict ratio choice for `u_*` implies the exact cone test. -/ |
| 156 | 155 | theorem cone_of_ratio {c u m t : ℝ} (hm : 0 < m) |
| 157 | 156 | (hratio : |c * t / m| < u / Real.sqrt (1 + u ^ 2)) : |
| 158 | 157 | |normalMagnitude c u * t| < u * m := by |
| 159 | 158 | have hs : 0 < Real.sqrt (1 + u ^ 2) := |
| 160 | - Real.sqrt_pos.mpr (by nlinarith [sq_nonneg u]) | |
| 159 | + Real.sqrt_pos.mpr (by linarith [sq_nonneg u]) | |
| 161 | 160 | have hr : |c * t| / m < u / Real.sqrt (1 + u ^ 2) := by |
| 162 | 161 | simpa only [abs_div, abs_of_pos hm] using hratio |
| 163 | 162 | have hcross : |c * t| * Real.sqrt (1 + u ^ 2) < u * m := |
+6 −8 NavierStokes/CylindricalResidual.lean View file
| @@ -46,8 +46,7 @@ theorem frame_apply (θ : ℝ) (v : Space) : | ||
| 46 | 46 | frame θ v = pack (Real.cos θ * v 0 - Real.sin θ * v 1) |
| 47 | 47 | (Real.sin θ * v 0 + Real.cos θ * v 1) (v 2) := by |
| 48 | 48 | ext i |
| 49 | - fin_cases i <;> simp [frame, horizontal, connection, vertical, packDerivative, | |
| 50 | - pack, coordinateVector] <;> ring | |
| 49 | + fin_cases i <;> simp [frame, horizontal, connection, vertical, pack, coordinateVector] <;> ring | |
| 51 | 50 | |
| 52 | 51 | theorem connection_apply (v : Space) : connection v = pack (-v 1) (v 0) 0 := by |
| 53 | 52 | simp [connection, packDerivative_apply] |
| @@ -55,7 +54,7 @@ theorem connection_apply (v : Space) : connection v = pack (-v 1) (v 0) 0 := by | ||
| 55 | 54 | theorem frame_inverse (θ : ℝ) (v : Space) : frame (-θ) (frame θ v) = v := by |
| 56 | 55 | ext i |
| 57 | 56 | fin_cases i |
| 58 | - · simp [frame_apply, Real.cos_neg, Real.sin_neg] | |
| 57 | + · simp [frame_apply, Real.cos_neg] | |
| 59 | 58 | linear_combination (v 0) * Real.cos_sq_add_sin_sq θ |
| 60 | 59 | · simp [frame_apply, Real.cos_neg, Real.sin_neg] |
| 61 | 60 | linear_combination (v 1) * Real.cos_sq_add_sin_sq θ |
| @@ -77,7 +76,7 @@ theorem hasFDerivAt_chart (q : Space) : HasFDerivAt chart (chartJacobian q) q := | ||
| 77 | 76 | have h2 := (projection 2).hasFDerivAt (x := q) |
| 78 | 77 | convert! hasFDerivAt_pack (h0.mul h1.cos) (h0.mul h1.sin) h2 using 1 |
| 79 | 78 | ext v i |
| 80 | - fin_cases i <;> simp [chartJacobian_apply, frame_apply, packDerivative_apply] <;> ring | |
| 79 | + fin_cases i <;> simp [chartJacobian_apply, frame_apply] <;> ring | |
| 81 | 80 | |
| 82 | 81 | theorem contDiff_chart {n : WithTop ℕ∞} : ContDiff ℝ n chart := by |
| 83 | 82 | unfold chart pack |
| @@ -253,7 +252,7 @@ theorem scalarLaplacian_pullback {f : Space → E} {q : Space} | ||
| 253 | 252 | dCoord_chart_one, dCoord_chart_two, hessian, pack, map_add, map_smul, |
| 254 | 253 | map_zero, _root_.add_apply, _root_.smul_apply, |
| 255 | 254 | zero_smul, add_zero] |
| 256 | - match_scalars <;> field_simp [hr] <;> nlinarith [Real.cos_sq_add_sin_sq (q 1)] | |
| 255 | + match_scalars <;> field_simp [hr] <;> linarith [Real.cos_sq_add_sin_sq (q 1)] | |
| 257 | 256 | |
| 258 | 257 | theorem contDiff_frame {n : WithTop ℕ∞} : ContDiff ℝ n frame := by |
| 259 | 258 | unfold frame |
| @@ -268,8 +267,7 @@ theorem hasFDerivAt_frameField (q : Space) : | ||
| 268 | 267 | convert! ((h1.cos.smul_const horizontal).add (h1.sin.smul_const connection)).add_const |
| 269 | 268 | vertical using 1 |
| 270 | 269 | ext v w i |
| 271 | - fin_cases i <;> simp [ frame_apply, horizontal, connection, packDerivative, | |
| 272 | - pack, coordinateVector] <;> ring | |
| 270 | + fin_cases i <;> simp [ frame_apply, horizontal, connection, pack, coordinateVector] <;> ring | |
| 273 | 271 | |
| 274 | 272 | /-- Cartesian representation of cylindrical vector components. -/ |
| 275 | 273 | noncomputable def encode (w : Space → Space) (q : Space) : Space := frame (q 1) (w q) |
| @@ -435,7 +433,7 @@ theorem cartesianGradient_pullback {f : Space → ℝ} {q : Space} | ||
| 435 | 433 | linear_combination -(fderiv ℝ f (chart q) (EuclideanSpace.single 1 1)) * |
| 436 | 434 | Real.cos_sq_add_sin_sq (q 1) |
| 437 | 435 | · simp [euclideanGradient, Fin.sum_univ_three, frame_apply, |
| 438 | - pack, dCoord, coordinateVector] | |
| 436 | + dCoord, coordinateVector] | |
| 439 | 437 | |
| 440 | 438 | /-- Pullback of a time-dependent velocity into the moving cylindrical frame. -/ |
| 441 | 439 | noncomputable def velocityComponents (u : VelocityField) : VelocityField := |
+3 −3 NavierStokes/DiophantineGraph.lean View file
| @@ -40,7 +40,7 @@ theorem conjugate_product (p q : ℤ) : | ||
| 40 | 40 | quadraticForm p q * quadraticForm p (-q) = (integerNorm p q : ℝ) := by |
| 41 | 41 | simp only [quadraticForm, integerNorm, Int.cast_neg, Int.cast_sub, |
| 42 | 42 | Int.cast_pow, Int.cast_mul, Int.cast_ofNat] |
| 43 | - nlinarith [congrArg (fun x : ℝ => x * (q : ℝ) ^ 2) sqrt_two_square] | |
| 43 | + linarith [congrArg (fun x : ℝ => x * (q : ℝ) ^ 2) sqrt_two_square] | |
| 44 | 44 | |
| 45 | 45 | theorem integerNorm_ne_zero (p q : ℤ) (hpq : p ≠ 0 ∨ q ≠ 0) : |
| 46 | 46 | integerNorm p q ≠ 0 := by |
| @@ -151,11 +151,11 @@ theorem frequencyL1_le_twice_length (m n : ℤ) : | ||
| 151 | 151 | have hm : |(m : ℝ)| ≤ frequencyLength m n := by |
| 152 | 152 | apply (sq_le_sq₀ (abs_nonneg _) (frequencyLength_nonneg m n)).mp |
| 153 | 153 | rw [sq_abs, hs] |
| 154 | - nlinarith [sq_nonneg (n : ℝ)] | |
| 154 | + linarith [sq_nonneg (n : ℝ)] | |
| 155 | 155 | have hn : |(n : ℝ)| ≤ frequencyLength m n := by |
| 156 | 156 | apply (sq_le_sq₀ (abs_nonneg _) (frequencyLength_nonneg m n)).mp |
| 157 | 157 | rw [sq_abs, hs] |
| 158 | - nlinarith [sq_nonneg (m : ℝ)] | |
| 158 | + linarith [sq_nonneg (m : ℝ)] | |
| 159 | 159 | unfold frequencyL1 |
| 160 | 160 | linarith |
| 161 | 161 | |
+1 −1 NavierStokes/DirectAngularDiagonal.lean View file
| @@ -102,7 +102,7 @@ theorem divergence_rotationField {F : AxisymmetricFields.Profile} {w : SpaceTime | ||
| 102 | 102 | rw [show fderiv ℝ (fun x => rotationField F (w.1, x)) w.2 = _ from hd.fderiv, |
| 103 | 103 | Fin.sum_univ_three] |
| 104 | 104 | simp [AxisymmetricResidual.packDerivative_apply, AxisymmetricFields.profileDerivative_apply, |
| 105 | - AxisymmetricFields.projection, coordinateVector] | |
| 105 | + coordinateVector] | |
| 106 | 106 | ring |
| 107 | 107 | |
| 108 | 108 | theorem rotationField_smoothAt {F : AxisymmetricFields.Profile} {w : SpaceTime} |
+2 −2 NavierStokes/ExtendedHeatDebts.lean View file
| @@ -516,7 +516,7 @@ theorem enlargedBand_diffusion_bound {η : ℝ} (hη : η ∈ enlargedBand) : |d | ||
| 516 | 516 | mul_nonneg (by linarith) (by linarith) |
| 517 | 517 | rw [abs_le] |
| 518 | 518 | dsimp [diffusion] |
| 519 | - constructor <;> nlinarith [sq_nonneg η] | |
| 519 | + constructor <;> linarith [sq_nonneg η] | |
| 520 | 520 | |
| 521 | 521 | theorem enlargedBand_diffusion_derivative_bound {η : ℝ} (hη : η ∈ enlargedBand) |
| 522 | 522 | (n : ℕ) (hn : 1 ≤ n) : ‖iteratedFDeriv ℝ n diffusion η‖ ≤ (3 : ℝ) ^ n := by |
| @@ -824,7 +824,7 @@ theorem diffusion_abs_bound {L η : ℝ} (hη : |η| ≤ L) : |diffusion η| ≤ | ||
| 824 | 824 | mul_nonneg (by linarith [(abs_le.mp hη).2]) (by linarith [(abs_le.mp hη).1]) |
| 825 | 825 | rw [abs_le] |
| 826 | 826 | dsimp [diffusion] |
| 827 | - constructor <;> nlinarith [sq_nonneg η, sq_nonneg L] | |
| 827 | + constructor <;> linarith [sq_nonneg η, sq_nonneg L] | |
| 828 | 828 | |
| 829 | 829 | theorem diffusion_iterated_bound {L η : ℝ} (hL : 0 ≤ L) (hη : |η| ≤ L) |
| 830 | 830 | (n : ℕ) (hn : 1 ≤ n) : ‖iteratedFDeriv ℝ n diffusion η‖ ≤ (2 * (L + 1)) ^ n := by |
+4 −4 NavierStokes/FuturePressureBounds.lean View file
| @@ -184,9 +184,9 @@ theorem clock_le_four_angular_square (d : TailData) (y : ℝ) {eta : ℝ} | ||
| 184 | 184 | have hdiv : (1 : ℝ) / 2 ≤ 1 / (1 + eta ^ 2) := |
| 185 | 185 | one_div_le_one_div_of_le (by positivity) (by linarith) |
| 186 | 186 | simpa only [one_div] using hdiv |
| 187 | - nlinarith [sq_nonneg ((1 + eta ^ 2)⁻¹ - 1 / 2)] | |
| 187 | + linarith [sq_nonneg ((1 + eta ^ 2)⁻¹ - 1 / 2)] | |
| 188 | 188 | rw [angular_square_factorization] |
| 189 | - nlinarith [mul_le_mul_of_nonneg_left hk (clockWeight_pos d y).le] | |
| 189 | + linarith [mul_le_mul_of_nonneg_left hk (clockWeight_pos d y).le] | |
| 190 | 190 | |
| 191 | 191 | /-- A single numerical constant, independent of every schedule parameter. -/ |
| 192 | 192 | noncomputable def envelopeConstant : ℝ := 5 * Real.exp (6 / 5) |
| @@ -405,11 +405,11 @@ theorem Pi_second_deriv_abs_le_pressure (d : TailData) (y : ℝ) {eta : ℝ} | ||
| 405 | 405 | have h1 : |2 * (1 - eta ^ 2) / (1 + eta ^ 2) ^ 2| ≤ 2 := by |
| 406 | 406 | rw [abs_of_nonneg (by positivity : 0 ≤ 2 * (1 - eta ^ 2) / (1 + eta ^ 2) ^ 2)] |
| 407 | 407 | apply (div_le_iff₀ hpos).mpr |
| 408 | - nlinarith [sq_nonneg eta] | |
| 408 | + linarith [sq_nonneg eta] | |
| 409 | 409 | have h2 : |8 * eta ^ 2 / (1 + eta ^ 2) ^ 2| ≤ 8 := by |
| 410 | 410 | rw [abs_of_nonneg (by positivity : 0 ≤ 8 * eta ^ 2 / (1 + eta ^ 2) ^ 2)] |
| 411 | 411 | apply (div_le_iff₀ hpos).mpr |
| 412 | - nlinarith | |
| 412 | + linarith | |
| 413 | 413 | rw [Pi_second_deriv_eta] |
| 414 | 414 | calc |
| 415 | 415 | _ ≤ |(2 * (1 - eta ^ 2) / (1 + eta ^ 2) ^ 2) * futureMass d y 1 eta| + |
+1 −1 NavierStokes/GaugeAliasDecay.lean View file
| @@ -341,7 +341,7 @@ theorem localBandJets_compactAlias_gain {coord a b d α κ B : ℝ} (U : SlowReg | ||
| 341 | 341 | obtain ⟨p, hpnat⟩ := exists_nat_gt ((β - α) / κ) |
| 342 | 342 | have horder : β ≤ α + κ * (p : ℝ) := by |
| 343 | 343 | have hh := (div_lt_iff₀ hκ).mp hpnat |
| 344 | - nlinarith | |
| 344 | + linarith | |
| 345 | 345 | intro m |
| 346 | 346 | obtain ⟨K, hK, hbK⟩ := compactAlias_finiteJets_local U ha hab hd direction m p |
| 347 | 347 | obtain ⟨C, hC, k, hbC⟩ := hsource (m + 6 * p + 4) |
+6 −6 NavierStokes/GaussianEnvelope.lean View file
| @@ -78,7 +78,7 @@ theorem integral_quadratic_bounds {D : Set ℝ} {rate : ℝ → ℝ} | ||
| 78 | 78 | intro x hx |
| 79 | 79 | have h := hhi x (hsub hx) midpoint hm hx.2 |
| 80 | 80 | rw [hzero] at h |
| 81 | - nlinarith | |
| 81 | + linarith | |
| 82 | 82 | have hu : (∫ x in time..midpoint, rate x) ≤ |
| 83 | 83 | ∫ x in time..midpoint, lower * (x - midpoint) := by |
| 84 | 84 | apply intervalIntegral.integral_mono_on htm hint |
| @@ -86,10 +86,10 @@ theorem integral_quadratic_bounds {D : Set ℝ} {rate : ℝ → ℝ} | ||
| 86 | 86 | intro x hx |
| 87 | 87 | have h := hlo x (hsub hx) midpoint hm hx.2 |
| 88 | 88 | rw [hzero] at h |
| 89 | - nlinarith | |
| 89 | + linarith | |
| 90 | 90 | rw [integral_centered_linear] at hl hu |
| 91 | 91 | rw [intervalIntegral.integral_symm time midpoint] |
| 92 | - constructor <;> nlinarith | |
| 92 | + constructor <;> linarith | |
| 93 | 93 | |
| 94 | 94 | /-- Gaussian upper and lower bounds with the manuscript's slot-length normalization. -/ |
| 95 | 95 | theorem gaussian_envelope_bounds {D : Set ℝ} {rate : ℝ → ℝ} |
| @@ -164,7 +164,7 @@ theorem referenceSlope_bounds {lam u s : ℝ} (hlam : 0 < lam) (hu : 0 < u) | ||
| 164 | 164 | referenceSlope lam u s ≤ -referenceMinSlope lam u := by |
| 165 | 165 | have hspos : 0 < s := by linarith [hs.1] |
| 166 | 166 | have hn : 0 ≤ lam * s := le_of_lt (mul_pos hlam hspos) |
| 167 | - have hS : 1 ≤ 1 + s ^ 2 := by nlinarith [sq_nonneg s] | |
| 167 | + have hS : 1 ≤ 1 + s ^ 2 := by linarith [sq_nonneg s] | |
| 168 | 168 | have hroot : 1 ≤ Real.sqrt (1 + s ^ 2) := Real.one_le_sqrt.2 hS |
| 169 | 169 | have hden : 1 ≤ (1 + s ^ 2) * Real.sqrt (1 + s ^ 2) := by |
| 170 | 170 | calc |
| @@ -173,14 +173,14 @@ theorem referenceSlope_bounds {lam u s : ℝ} (hlam : 0 < lam) (hu : 0 < u) | ||
| 173 | 173 | mul_le_mul hS hroot (by norm_num) (le_of_lt (PulseGrowth.one_add_sq_pos s)) |
| 174 | 174 | have hfirst : lam * s / ((1 + s ^ 2) * Real.sqrt (1 + s ^ 2)) ≤ lam * s := by |
| 175 | 175 | apply (div_le_iff₀ (PulseGrowth.dampingDenominator_pos s)).2 |
| 176 | - nlinarith [mul_le_mul_of_nonneg_left hden hn] | |
| 176 | + linarith [mul_le_mul_of_nonneg_left hden hn] | |
| 177 | 177 | have hfirst0 : 0 ≤ lam * s / ((1 + s ^ 2) * Real.sqrt (1 + s ^ 2)) := |
| 178 | 178 | div_nonneg hn (le_of_lt (PulseGrowth.dampingDenominator_pos s)) |
| 179 | 179 | have hfirstUpper : lam * s ≤ 3 * lam * u / 2 := by nlinarith [hs.2] |
| 180 | 180 | have hsecondUpper : 2 * lam * s / ((1 + u ^ 2) * Real.sqrt (1 + u ^ 2)) ≤ |
| 181 | 181 | 3 * lam * u / ((1 + u ^ 2) * Real.sqrt (1 + u ^ 2)) := by |
| 182 | 182 | apply (div_le_div_iff_of_pos_right (PulseGrowth.dampingDenominator_pos u)).2 |
| 183 | - nlinarith [hs.2] | |
| 183 | + linarith [hs.2] | |
| 184 | 184 | have hsecondLower : lam * u / ((1 + u ^ 2) * Real.sqrt (1 + u ^ 2)) ≤ |
| 185 | 185 | 2 * lam * s / ((1 + u ^ 2) * Real.sqrt (1 + u ^ 2)) := by |
| 186 | 186 | apply (div_le_div_iff_of_pos_right (PulseGrowth.dampingDenominator_pos u)).2 |
+5 −5 NavierStokes/GaussianTailFlat.lean View file
| @@ -54,7 +54,7 @@ theorem profile_eventually_zero {v : ℝ} (hv : 1 / 3 < |v - 1 / 2|) : | ||
| 54 | 54 | apply notMem_tsupport_iff_eventuallyEq.mp |
| 55 | 55 | change v ∉ tsupport (profileBump : ℝ → ℝ) |
| 56 | 56 | rw [profileBump.tsupport_eq] |
| 57 | - simpa [Metric.mem_closedBall, Real.dist_eq, profileBump] using (not_le.mpr hv) | |
| 57 | + simpa [Real.dist_eq, profileBump] using (not_le.mpr hv) | |
| 58 | 58 | |
| 59 | 59 | theorem profile_iteratedDeriv_compact (m : ℕ) : |
| 60 | 60 | HasCompactSupport (iteratedDeriv m profile) := by |
| @@ -175,12 +175,12 @@ theorem gaussian_beats_Q_power {c : ℝ} (hc : 0 < c) (p : ℕ) (N : ℝ) : | ||
| 175 | 175 | suffices A * (n : ℝ) - c / 2 * (n : ℝ) ^ 2 ≤ K by linarith |
| 176 | 176 | dsimp [K] |
| 177 | 177 | apply (le_div_iff₀ hc2).2 |
| 178 | - nlinarith | |
| 178 | + linarith | |
| 179 | 179 | have hexp : Real.exp (-c * ChartScales.S n) ≤ |
| 180 | 180 | Real.exp (-(c / 2) * ChartScales.S n) * Real.exp K * ChartScales.Q n ^ N := by |
| 181 | 181 | rw [Q_rpow_eq_exp, ← Real.exp_add, ← Real.exp_add] |
| 182 | 182 | apply Real.exp_le_exp.2 |
| 183 | - dsimp [ChartScales.S, A] at * | |
| 183 | + dsimp [ChartScales.S] at * | |
| 184 | 184 | linarith |
| 185 | 185 | calc |
| 186 | 186 | _ ≤ (1 + ChartScales.S n) ^ p * |
| @@ -197,7 +197,7 @@ theorem gaussian_beats_Q_power {c : ℝ} (hc : 0 < c) (p : ℕ) (N : ℝ) : | ||
| 197 | 197 | theorem gaussian_length_comparison {c κ L S : ℝ} (hc : 0 ≤ c) (hL : κ * S ≤ L) : |
| 198 | 198 | Real.exp (-(c / 25) * L) ≤ Real.exp (-(c * κ / 25) * S) := by |
| 199 | 199 | apply Real.exp_le_exp.2 |
| 200 | - nlinarith [mul_le_mul_of_nonneg_left hL hc] | |
| 200 | + linarith [mul_le_mul_of_nonneg_left hL hc] | |
| 201 | 201 | |
| 202 | 202 | /-- A fixed power loss consumes only half of a Gaussian tail. -/ |
| 203 | 203 | theorem fixed_power_gaussian_bound {c : ℝ} (hc : 0 < c) (r : ℝ) : |
| @@ -581,7 +581,7 @@ theorem native_slot_length_lower (r0 h : ℝ) (hr0 : 0 < r0) (hh : 0 ≤ h) : | ||
| 581 | 581 | have hS (n : ℕ) : 0 < 1 + ChartScales.S n := by unfold ChartScales.S; positivity |
| 582 | 582 | obtain ⟨i, hi, hmin⟩ := (Finset.range 4).exists_min_image |
| 583 | 583 | (fun n => ChartScales.slotLength r0 h n / (1 + ChartScales.S n)) |
| 584 | - (by exact ⟨0, by decide⟩) | |
| 584 | + (⟨0, by decide⟩) | |
| 585 | 585 | refine ⟨min r0 (ChartScales.slotLength r0 h i / (1 + ChartScales.S i)), |
| 586 | 586 | lt_min hr0 (div_pos (hL i) (hS i)), ?_⟩ |
| 587 | 587 | intro n |
+1 −1 NavierStokes/GluedStageEstimates.lean View file
| @@ -580,7 +580,7 @@ theorem current_loss_le_wave (degree : ℝ) (m : ℕ) : | ||
| 580 | 580 | have hh : 0 ≤ 2 - 3 * h := by linarith [outgoing.data.h_lt_half] |
| 581 | 581 | have hb := mul_nonneg hh hm |
| 582 | 582 | unfold PhysicalGraphBounds.waveLoss |
| 583 | - nlinarith | |
| 583 | + linarith | |
| 584 | 584 | |
| 585 | 585 | omit R in |
| 586 | 586 | theorem current_potential_loss_le (m : ℕ) : |
+12 −12 NavierStokes/GrowingMode.lean View file
| @@ -78,9 +78,9 @@ theorem upper_edge_factor_negative | ||
| 78 | 78 | mul_le_mul_of_nonneg_left (by linarith [(abs_le.mp he11).1, (abs_le.mp he22).2]) hr.le |
| 79 | 79 | have hquad : -(r ^ 2 * e12) ≤ r ^ 2 * eps := by |
| 80 | 80 | have h := mul_le_mul_of_nonneg_left (abs_le.mp he12).1 (sq_nonneg r) |
| 81 | - nlinarith | |
| 81 | + linarith | |
| 82 | 82 | have hrate : lamMin * r ≤ lam * r := mul_le_mul_of_nonneg_right hlam hr.le |
| 83 | - nlinarith [(abs_le.mp he21).2] | |
| 83 | + linarith [(abs_le.mp he21).2] | |
| 84 | 84 | |
| 85 | 85 | /-- The inward algebra at the lower edge follows by reversing the off-diagonal signs. -/ |
| 86 | 86 | theorem lower_edge_factor_negative |
| @@ -93,7 +93,7 @@ theorem lower_edge_factor_negative | ||
| 93 | 93 | have h := upper_edge_factor_negative (e12 := -e12) (e21 := -e21) |
| 94 | 94 | hr hlam he11 (by simpa only [abs_neg] using he12) |
| 95 | 95 | (by simpa only [abs_neg] using he21) he22 hgap |
| 96 | - nlinarith | |
| 96 | + linarith | |
| 97 | 97 | |
| 98 | 98 | /-- The quadratic cone boundary has strictly negative derivative at every |
| 99 | 99 | nonzero boundary point. Scalar damping cancels from this computation. -/ |
| @@ -106,17 +106,17 @@ theorem cone_boundary_derivative_negative | ||
| 106 | 106 | (hgap : eps * (1 + r) ^ 2 < 2 * lamMin * r) : |
| 107 | 107 | 2 * q * (e21 * p + (-lam - damping + e22) * q) - |
| 108 | 108 | r ^ 2 * (2 * p * ((lam - damping + e11) * p + e12 * q)) < 0 := by |
| 109 | - have hsq : q ^ 2 = (r * p) ^ 2 := by nlinarith [hboundary] | |
| 109 | + have hsq : q ^ 2 = (r * p) ^ 2 := by linarith [hboundary] | |
| 110 | 110 | have hpos : 0 < 2 * r * p ^ 2 := mul_pos (by linarith) (sq_pos_of_ne_zero hp) |
| 111 | 111 | rcases sq_eq_sq_iff_eq_or_eq_neg.mp hsq with hq | hq |
| 112 | 112 | · rw [hq] |
| 113 | 113 | have h := mul_neg_of_pos_of_neg hpos |
| 114 | 114 | (upper_edge_factor_negative hr hlam he11 he12 he21 he22 hgap) |
| 115 | - nlinarith [h] | |
| 115 | + linarith [h] | |
| 116 | 116 | · rw [hq] |
| 117 | 117 | have h := mul_neg_of_pos_of_neg hpos |
| 118 | 118 | (lower_edge_factor_negative hr hlam he11 he12 he21 he22 hgap) |
| 119 | - nlinarith [h] | |
| 119 | + linarith [h] | |
| 120 | 120 | |
| 121 | 121 | theorem hasDerivAt_coordinate {z : ℝ → State} {z' : State} {t : ℝ} |
| 122 | 122 | (hz : HasDerivAt z z' t) (i : Fin 2) : |
| @@ -163,7 +163,7 @@ theorem positive_invariant_cone | ||
| 163 | 163 | (B := fun _ => (0 : ℝ)) (B' := fun _ => (0 : ℝ)) |
| 164 | 164 | · dsimp [barrier] |
| 165 | 165 | rw [hminus] |
| 166 | - nlinarith [mul_nonneg (sq_nonneg r) (sq_nonneg (z a 0))] | |
| 166 | + linarith [mul_nonneg (sq_nonneg r) (sq_nonneg (z a 0))] | |
| 167 | 167 | · exact continuousOn_const |
| 168 | 168 | · exact fun t _ => (hasDerivAt_const t (0 : ℝ)).hasDerivWithinAt |
| 169 | 169 | · intro t ht heq |
| @@ -201,7 +201,7 @@ theorem positive_invariant_cone | ||
| 201 | 201 | refine ⟨hppos, abs_le_of_sq_le_sq ?_ (mul_nonneg hr.le hppos.le)⟩ |
| 202 | 202 | have hb := hbarrier t ht |
| 203 | 203 | dsimp [barrier] at hb |
| 204 | - nlinarith | |
| 204 | + linarith | |
| 205 | 205 | |
| 206 | 206 | /-- A fixed constant for the manuscript's `O(1/S)` cone width. The added one |
| 207 | 207 | allows the same statement when the perturbation bound is zero. -/ |
| @@ -235,7 +235,7 @@ theorem scaled_cone_conditions {lamMin C S : ℝ} | ||
| 235 | 235 | convert! h using 1 |
| 236 | 236 | ring |
| 237 | 237 | refine ⟨hr, hrhalf, ?_⟩ |
| 238 | - nlinarith [mul_pos hlamMin hr] | |
| 238 | + linarith [mul_pos hlamMin hr] | |
| 239 | 239 | |
| 240 | 240 | /-- The fixed-width result in the exact `K/S` form used in (28). -/ |
| 241 | 241 | theorem scaled_positive_invariant_cone |
| @@ -392,7 +392,7 @@ theorem scaled_growing_mode_bounds | ||
| 392 | 392 | simpa only [mul_one] using h |
| 393 | 393 | calc |
| 394 | 394 | D / S + (C / S) * (1 + coneConstant lamMin C / S) ≤ D / S + 2 * (C / S) := by |
| 395 | - nlinarith | |
| 395 | + linarith | |
| 396 | 396 | _ = (D + 2 * C) / S := by ring |
| 397 | 397 | let p' : ℝ → ℝ := fun t => (lam t - damping t + e11 t) * z t 0 + e12 t * z t 1 |
| 398 | 398 | have hp (t : ℝ) (ht : t ∈ Icc a b) : HasDerivAt (fun s => z s 0) (p' t) t := |
| @@ -415,7 +415,7 @@ theorem scaled_growing_mode_bounds | ||
| 415 | 415 | have hlo : Real.exp (-(D + 2 * C) * L) ≤ |
| 416 | 416 | Real.exp (-((D + 2 * C) / S) * (t - a)) := by |
| 417 | 417 | apply Real.exp_le_exp.mpr |
| 418 | - nlinarith | |
| 418 | + linarith | |
| 419 | 419 | have hhi : Real.exp (((D + 2 * C) / S) * (t - a)) ≤ |
| 420 | 420 | Real.exp ((D + 2 * C) * L) := Real.exp_le_exp.mpr hexponent |
| 421 | 421 | have hratio : 0 ≤ z a 0 / P a := div_nonneg hplus.le (hPpos a ⟨le_rfl, hab⟩).le |
| @@ -447,6 +447,6 @@ theorem original_coordinate_bounds {p q h r : ℝ} | ||
| 447 | 447 | mul_le_mul_of_nonneg_left hxlower (by positivity) |
| 448 | 448 | simp only [abs_mul, abs_neg] |
| 449 | 449 | rw [abs_of_pos (show (0 : ℝ) < 2 by norm_num)] |
| 450 | - nlinarith | |
| 450 | + linarith | |
| 451 | 451 | |
| 452 | 452 | end NavierStokes.GrowingMode |
+2 −2 NavierStokes/InitialPhysicalData.lean View file
| @@ -691,7 +691,7 @@ theorem cut_pair_annulus (l : SignedLabel B N0) (L : PhysicalWaveSum.BandLabel) | ||
| 691 | 691 | have hq : 0 < q := lt_trans (by norm_num) hqlo |
| 692 | 692 | have hs := Real.sqrt_pos.mpr hq |
| 693 | 693 | have hslo : (1 / 2 : ℝ) ≤ Real.sqrt q := |
| 694 | - (Real.le_sqrt (by norm_num) hq.le).mpr (by nlinarith) | |
| 694 | + (Real.le_sqrt (by norm_num) hq.le).mpr (by linarith) | |
| 695 | 695 | have hshi : Real.sqrt q ≤ 2 := |
| 696 | 696 | (Real.sqrt_le_left (by norm_num)).mpr (by linarith) |
| 697 | 697 | have hradius : WaveEdgeExtension.nativeRadius ActualPrimary.h (nativeAt L k x) = |
| @@ -1703,7 +1703,7 @@ theorem cut_pair_physicalX (l : SignedLabel B N0) (L : PhysicalWaveSum.BandLabel | ||
| 1703 | 1703 | have hlo := mul_pos (sub_pos.mpr hd.1.1) (add_pos hrad ha) |
| 1704 | 1704 | have hhi := mul_pos (sub_pos.mpr hd.1.2) (add_pos hb hrad) |
| 1705 | 1705 | rw [he] |
| 1706 | - constructor <;> nlinarith | |
| 1706 | + constructor <;> linarith | |
| 1707 | 1707 | |
| 1708 | 1708 | theorem potential_amplitude_zero_exterior (B N0 : ℕ) (i : Fin 3) (k : Frequency) |
| 1709 | 1709 | (I : PhysicalWaveSum.WaveIndex 1) {w : ProblemStatement.SpaceTime} |
+2 −2 NavierStokes/LabelSupportPreservation.lean View file
| @@ -98,7 +98,7 @@ theorem nativeCutoff_source_time_zero_germ {r L c : ℝ} | ||
| 98 | 98 | have hhigh : z.2 / (L / c) ≤ (5 / 6 : ℝ) := by linarith |
| 99 | 99 | have hl := (le_div_iff₀ hlen).mp hlow |
| 100 | 100 | have hh := (div_le_iff₀ hlen).mp hhigh |
| 101 | - exact hz ⟨by nlinarith, by nlinarith⟩ | |
| 101 | + exact hz ⟨by linarith, by linarith⟩ | |
| 102 | 102 | have hd' : 1 / 3 < |c * z.2 / L - 1 / 2| := by |
| 103 | 103 | simpa only [ActualGaussianCoverage.normalized_clock hL.ne' hc.ne'] using hd |
| 104 | 104 | have ht : Continuous (fun y : Plane => c * y.2 / L) := |
| @@ -209,7 +209,7 @@ theorem modeBlock_inputSupport {U : Set D} {K : ℕ → Set D} | ||
| 209 | 209 | intro x hx hn |
| 210 | 210 | simp only [hg n x hx hn, Pi.zero_apply] |
| 211 | 211 | · intro n i m hm x hx hn |
| 212 | - simp [realCoefficients_apply] | |
| 212 | + simp | |
| 213 | 213 | |
| 214 | 214 | omit [NormedAddCommGroup D] [NormedSpace ℝ D] in |
| 215 | 215 | /-- The actual carrier-retaining update preserves the very same support |
+3 −4 NavierStokes/LocalSignedRequest.lean View file
| @@ -267,10 +267,10 @@ theorem moving_radial_bounds {coord a b : ℝ} (U : SlowRegion coord) (ha : 0 < | ||
| 267 | 267 | · calc |
| 268 | 268 | Real.sqrt U.qlo * a ≤ Real.sqrt (MeanRankUpdate.chartQ coord x) * a := |
| 269 | 269 | mul_le_mul_of_nonneg_right hL ha.le |
| 270 | - _ ≤ x.1 := by nlinarith [(lt_div_iff₀ hs).mp hr.1] | |
| 270 | + _ ≤ x.1 := by linarith [(lt_div_iff₀ hs).mp hr.1] | |
| 271 | 271 | · calc |
| 272 | 272 | x.1 ≤ Real.sqrt (MeanRankUpdate.chartQ coord x) * b := |
| 273 | - by nlinarith [(div_lt_iff₀ hs).mp hr.2] | |
| 273 | + by linarith [(div_lt_iff₀ hs).mp hr.2] | |
| 274 | 274 | _ ≤ Real.sqrt U.qhi * b := mul_le_mul_of_nonneg_right hR (ha.trans hab).le |
| 275 | 275 | |
| 276 | 276 | section ClassMaps |
| @@ -868,8 +868,7 @@ theorem physicalDensity_meanClass {coord : ℝ} (U : SlowRegion coord) | ||
| 868 | 868 | exact (((contDiffAt_fst.sqrt (ne_of_gt hx)).pow (e + 1)).inv |
| 869 | 869 | (pow_ne_zero _ (Real.sqrt_pos.mpr hx).ne')).contDiffWithinAt |
| 870 | 870 | have h := MeanIncrementBounds.Class.coefficient_mul hm hp |
| 871 | - simp only [zero_add, SignedStressPrimitive.physicalDensity, SignedStressPrimitive.lengthScale, | |
| 872 | - profileMap, MeanRankUpdate.chartQ, MeanRankUpdate.chartInput_apply, PhysicalCoordinateBounds.qCoord, | |
| 871 | + simp only [zero_add, SignedStressPrimitive.physicalDensity, profileMap, MeanRankUpdate.chartQ, MeanRankUpdate.chartInput_apply, PhysicalCoordinateBounds.qCoord, | |
| 873 | 872 | div_eq_mul_inv, mul_comm] at h ⊢ |
| 874 | 873 | exact h |
| 875 | 874 | |
+3 −5 NavierStokes/LoopMoments.lean View file
| @@ -43,14 +43,12 @@ def loopA (v t : ℝ) : ℝ := v / (1 + t ^ 2) | ||
| 43 | 43 | def loopC (v t : ℝ) : ℝ := v * t / (1 + t ^ 2) |
| 44 | 44 | |
| 45 | 45 | theorem one_add_sq_pos (t : ℝ) : 0 < 1 + t ^ 2 := by |
| 46 | - nlinarith [sq_nonneg t] | |
| 46 | + linarith [sq_nonneg t] | |
| 47 | 47 | |
| 48 | -theorem loopA_pos (v t : ℝ) (hv : 0 < v) : 0 < loopA v t := by | |
| 49 | - exact div_pos hv (one_add_sq_pos t) | |
| 48 | +theorem loopA_pos (v t : ℝ) (hv : 0 < v) : 0 < loopA v t := div_pos hv (one_add_sq_pos t) | |
| 50 | 49 | |
| 51 | 50 | theorem phaseDensity_pos (a v t : ℝ) (ha : 0 < a) (hv : 0 < v) : |
| 52 | - 0 < phaseDensity a v t := by | |
| 53 | - exact div_pos (mul_pos ha (one_add_sq_pos t)) hv | |
| 51 | + 0 < phaseDensity a v t := div_pos (mul_pos ha (one_add_sq_pos t)) hv | |
| 54 | 52 | |
| 55 | 53 | theorem loop_speed (v t : ℝ) : loopA v t * (1 + t ^ 2) = v := by |
| 56 | 54 | unfold loopA |
+4 −4 NavierStokes/LoopVariance.lean View file
| @@ -275,7 +275,7 @@ theorem quadraticFactor_identity (s : ℝ) : baseVariance s = s ^ 2 * quadraticF | ||
| 275 | 275 | have h₂ := sub_smul_dslope (dslope baseVariance 0) (0 : ℝ) s |
| 276 | 276 | simp only [sub_zero, smul_eq_mul, baseVariance_zero, dslope_same, baseVariance_deriv_zero] at h₁ h₂ |
| 277 | 277 | change baseVariance s = s ^ 2 * dslope (dslope baseVariance 0) 0 s |
| 278 | - nlinarith [congrArg (fun z : ℝ => s * z) h₂] | |
| 278 | + linarith [congrArg (fun z : ℝ => s * z) h₂] | |
| 279 | 279 | |
| 280 | 280 | theorem quadraticFactor_analyticAt (s : ℝ) : AnalyticAt ℝ quadraticFactor s := by |
| 281 | 281 | by_cases hs : s = 0 |
| @@ -424,7 +424,7 @@ theorem normalizer_double_square_lower (t : ℝ) (ht : 1 ≤ t) : | ||
| 424 | 424 | apply Real.exp_le_exp.mpr |
| 425 | 425 | have hc := Real.one_sub_sq_div_two_le_cos (x := x) |
| 426 | 426 | have hm := mul_le_mul_of_nonneg_left hc (show 0 ≤ 2 * t ^ 2 by positivity) |
| 427 | - nlinarith | |
| 427 | + linarith | |
| 428 | 428 | have hloc := intervalIntegral.integral_mono_on (μ := volume) hab |
| 429 | 429 | (continuous_const.intervalIntegrable _ _) (he.intervalIntegrable _ _) hbound |
| 430 | 430 | rw [intervalIntegral.integral_const] at hloc |
| @@ -558,7 +558,7 @@ theorem inverseRoot_deriv_zero : deriv inverseRoot 0 = 1 / Real.sqrt (1 / 2) := | ||
| 558 | 558 | have hprod := hcomp.unique (hasDerivAt_id 0) |
| 559 | 559 | have hroot : Real.sqrt (1 / 2) ≠ 0 := ne_of_gt (Real.sqrt_pos.mpr (by norm_num)) |
| 560 | 560 | apply (eq_div_iff hroot).mpr |
| 561 | - nlinarith | |
| 561 | + linarith | |
| 562 | 562 | |
| 563 | 563 | /-- An analytic divided difference of the actual inverse, which removes the |
| 564 | 564 | apparent `1/p` singularity in the parameter-dependent variance solve. -/ |
| @@ -741,7 +741,7 @@ theorem regularizedDensitySlope_identity (s θ : ℝ) : | ||
| 741 | 741 | have hnz := ne_of_gt (expNormalizer_pos s) |
| 742 | 742 | field_simp |
| 743 | 743 | dsimp [expDivided, normalizerDivided] |
| 744 | - nlinarith | |
| 744 | + linarith | |
| 745 | 745 | |
| 746 | 746 | theorem regularizedDensitySlope_joint_contDiff : |
| 747 | 747 | ContDiff ℝ ω (fun x : ℝ × ℝ => regularizedDensitySlope x.1 x.2) := by |
+12 −12 NavierStokes/MatchingConeBounds.lean View file
| @@ -35,7 +35,7 @@ theorem shape_axis_lower {h j eta ell theta : ℝ} | ||
| 35 | 35 | theta * H h j eta * OutgoingEntranceCone.shapeGradient eta := by |
| 36 | 36 | have heta : |eta| ≤ 1 := abs_le.mpr hη |
| 37 | 37 | have hd0 := d_nonneg hη |
| 38 | - have hd1 : d eta ≤ 1 := by unfold d; nlinarith [sq_nonneg eta] | |
| 38 | + have hd1 : d eta ≤ 1 := by unfold d; linarith [sq_nonneg eta] | |
| 39 | 39 | have hD := D_pos hs |
| 40 | 40 | have hu : |U j eta| ≤ 4001 / 1000 := by |
| 41 | 41 | calc |
| @@ -62,7 +62,7 @@ theorem shape_axis_lower {h j eta ell theta : ℝ} | ||
| 62 | 62 | (mul_le_of_le_one_left hs.j_pos.le hd1).trans hs.j_le |
| 63 | 63 | have herr : -(1 / 500 : ℝ) ≤ d eta * j * OutgoingEntranceCone.shapeGradient eta := by |
| 64 | 64 | have hm := mul_le_mul_of_nonneg_left (abs_le.mp hgabs).1 hdj |
| 65 | - nlinarith | |
| 65 | + linarith | |
| 66 | 66 | have hid : H h j eta * OutgoingEntranceCone.shapeGradient eta = |
| 67 | 67 | (D h + 4 * d eta) * (eta * OutgoingEntranceCone.shapeGradient eta) + |
| 68 | 68 | d eta * j * OutgoingEntranceCone.shapeGradient eta := by |
| @@ -73,7 +73,7 @@ theorem shape_axis_lower {h j eta ell theta : ℝ} | ||
| 73 | 73 | linarith |
| 74 | 74 | have htheta : -(1 / 500 : ℝ) ≤ theta * H h j eta * OutgoingEntranceCone.shapeGradient eta := by |
| 75 | 75 | have hm := mul_le_mul_of_nonneg_left hH ht.1 |
| 76 | - nlinarith [ht.2] | |
| 76 | + linarith [ht.2] | |
| 77 | 77 | have hW := neg_W_lower_bound hs hη |
| 78 | 78 | have hbase : (2991 / 1000 : ℝ) * (11 / 20) ≤ -W h j eta * ell := |
| 79 | 79 | mul_le_mul hW hl (by norm_num) (by linarith) |
| @@ -153,7 +153,7 @@ theorem shapeModel_uniform_lower {h j sigma : ℝ} (hs : SmallParameters h j) | ||
| 153 | 153 | have hm := (div_lt_iff₀ htau).mp (show 1 / tau < Λ by |
| 154 | 154 | have := (le_max_right M0 (1 + 1 / tau)).trans hΛ |
| 155 | 155 | linarith) |
| 156 | - nlinarith | |
| 156 | + linarith | |
| 157 | 157 | have he := (abs_lt.mp (hpert p (1 / Λ) ht)).1 |
| 158 | 158 | have hm := hmain Λ ((le_max_left _ _).trans hΛ) p |
| 159 | 159 | linarith |
| @@ -258,7 +258,7 @@ theorem angular_barrier {D : RadialDomain} (P : Profiles D) {h eta a X : ℝ} | ||
| 258 | 258 | have he := ReferenceBounds.angularSource_eq P (hmem s hs) (hf s hs).ne' h |
| 259 | 259 | have hterm : 2 * L h eta * ReferenceBounds.logSlope P (s, eta) ≤ 2 := by |
| 260 | 260 | have hh := mul_le_mul_of_nonneg_left (hl s hs) (show 0 ≤ 2 * L h eta by positivity) |
| 261 | - nlinarith | |
| 261 | + linarith | |
| 262 | 262 | have hsq : 2 < s * ReferenceBounds.sourceQ P h (s, eta) := by |
| 263 | 263 | have hh := mul_lt_mul_of_pos_left (hq s hs) (hspos s hs) |
| 264 | 264 | linarith [hs.1] |
| @@ -279,12 +279,12 @@ theorem angular_barrier {D : RadialDomain} (P : Profiles D) {h eta a X : ℝ} | ||
| 279 | 279 | rw [ReferenceBounds.p1_primitive P (hspos a ⟨le_rfl, haX⟩).ne' h] at hinit |
| 280 | 280 | have hi := (lt_div_iff₀ (mul_pos hL (hHpos a ⟨le_rfl, haX⟩))).mp hinit |
| 281 | 281 | unfold angularGap |
| 282 | - nlinarith | |
| 282 | + linarith | |
| 283 | 283 | have hout : 0 < angularGap P h eta X := hini.trans_le (hm ⟨le_rfl, haX⟩ ⟨haX, le_rfl⟩ haX) |
| 284 | 284 | rw [ReferenceBounds.p1_primitive P (hspos X ⟨haX, le_rfl⟩).ne' h] |
| 285 | 285 | apply (lt_div_iff₀ (mul_pos hL (hHpos X ⟨haX, le_rfl⟩))).mpr |
| 286 | 286 | unfold angularGap at hout |
| 287 | - nlinarith | |
| 287 | + linarith | |
| 288 | 288 | |
| 289 | 289 | theorem axial_error_jet {J K : Set ℝ} (R : TransitionRamp.StockReference J) |
| 290 | 290 | (hJ : IsOpen J) (hKJ : K ⊆ J) {N : ℕ} {eps T kappa wU wE y eta : ℝ} |
| @@ -320,7 +320,7 @@ theorem seedU_error_jets {N : ℕ} {eps X eta : ℝ} | ||
| 320 | 320 | · have hxn : X ≤ 4 / A.scale := by simpa only [c.reference_radius] using hx |
| 321 | 321 | have hY : A.scale * X ∈ Ioo (-20 : ℝ) 20 := by |
| 322 | 322 | have hb := (le_div_iff₀ A.scale_pos).mp hxn |
| 323 | - constructor <;> nlinarith [mul_nonneg A.scale_pos.le hX] | |
| 323 | + constructor <;> linarith [mul_nonneg A.scale_pos.le hX] | |
| 324 | 324 | have he : (fun e => c.seedU (X, e) - U A.j e) = |
| 325 | 325 | (fun e => A.natural.profile.family.U (X, e) - U A.j e) := by |
| 326 | 326 | funext e |
| @@ -330,7 +330,7 @@ theorem seedU_error_jets {N : ℕ} {eps X eta : ℝ} | ||
| 330 | 330 | have hY5 : |A.scale * X| ≤ 5 := by |
| 331 | 331 | rw [abs_of_nonneg (mul_nonneg A.scale_pos.le hX)] |
| 332 | 332 | have hb := (le_div_iff₀ A.scale_pos).mp hxn |
| 333 | - nlinarith | |
| 333 | + linarith | |
| 334 | 334 | have hb := (ReferenceJetBounds.coefficient_jet_bound A.preparation.inputs.coefficients |
| 335 | 335 | A.natural.profile.coefficients A.natural.profile.norm_ball 0 n (p := (A.scale * X, eta)) hY5).2 |
| 336 | 336 | have hh := mul_le_mul_of_nonneg_left hb (one_div_nonneg.mpr A.scale_pos.le) |
| @@ -566,7 +566,7 @@ theorem shapeValue_hasDerivAt_x (C T : ℝ) (li : ℝ → ℝ) {X : ℝ} (hX : 0 | ||
| 566 | 566 | have hroot := Real.sqrt_pos.mpr (show 0 < 2 * X by positivity) |
| 567 | 567 | have hsq := Real.sq_sqrt (show 0 ≤ 2 * X by positivity) |
| 568 | 568 | convert! ha.div hr hroot.ne' using 1 |
| 569 | - dsimp only [shapeValue, ShapeTransition.angular, Function.comp_def, Function.comp_apply] | |
| 569 | + dsimp only [shapeValue, ShapeTransition.angular, Function.comp_def] | |
| 570 | 570 | generalize hk : Real.exp (ShapeTransition.logProfile C T li |
| 571 | 571 | (Real.log (X / NominalProfile.Xi), eta)) = k |
| 572 | 572 | generalize hr' : Real.sqrt (2 * X) = r at hroot hsq ⊢ |
| @@ -861,7 +861,7 @@ theorem exists_ordered_prepared_continuation (F : OutgoingProfile.Profile) (N : | ||
| 861 | 861 | have hm := (le_div_iff₀ (show 0 < 2 * K by positivity)).mp (min_le_right |
| 862 | 862 | (min 1 (NominalProfile.resetSolver.radius / 2)) (delta / (2 * K))) |
| 863 | 863 | change tau * (2 * K) ≤ delta at hm |
| 864 | - nlinarith [mul_nonneg hK.le htau.le] | |
| 864 | + linarith [mul_nonneg hK.le htau.le] | |
| 865 | 865 | let rho := tau ^ (N + 1) |
| 866 | 866 | have hrho : 0 < rho := pow_pos htau _ |
| 867 | 867 | have hpow : rho ≤ tau := by |
| @@ -891,7 +891,7 @@ theorem exists_ordered_prepared_continuation (F : OutgoingProfile.Profile) (N : | ||
| 891 | 891 | ReferenceJetBounds.jetConstant prep.inputs.coefficients 0 n / Λ ≤ delta / 3 := by |
| 892 | 892 | apply (div_le_iff₀ hΛ).mpr |
| 893 | 893 | have hmul := (div_le_iff₀ hdelta).mp hLD |
| 894 | - nlinarith [hDb n hn] | |
| 894 | + linarith [hDb n hn] | |
| 895 | 895 | obtain ⟨T, hT, Cmatch, hCmatch, hnorm⟩ := hmatch Λ hΛ hLm |
| 896 | 896 | obtain ⟨Cgeo, hgeo⟩ := eventually_atTop.mp |
| 897 | 897 | (NominalProfile.eventually_matching_geometry F T radiusFloor Cmatch) |
+6 −6 NavierStokes/MatchingDebtBounds.lean View file
| @@ -90,7 +90,7 @@ theorem radialClamp_mem {scale : ℝ} (hscale : 0 < scale) (X : ℝ) : | ||
| 90 | 90 | have hm : scale * X ≤ scale * X * OutgoingSchedule.sigma (scale * X + 2) := by |
| 91 | 91 | nlinarith [mul_nonpos_of_nonneg_of_nonpos hscale.le hXn] |
| 92 | 92 | dsimp [radialClamp] |
| 93 | - nlinarith | |
| 93 | + linarith | |
| 94 | 94 | |
| 95 | 95 | noncomputable def strip (scale : ℝ) : Set Point := |
| 96 | 96 | {p | -20 < scale * p.1 ∧ p.2 ∈ ReferencePath.parameterInterval} |
| @@ -172,7 +172,7 @@ theorem iteratedDeriv_component {d : ℝ → Debt} (hd : ContDiff ℝ ∞ d) | ||
| 172 | 172 | have he := (ContinuousLinearMap.proj i : Debt →L[ℝ] ℝ).iteratedFDeriv_comp_left (x := eta) |
| 173 | 173 | hd.contDiffAt (nat_le_infty n) |
| 174 | 174 | have h := (congrArg (fun L => L (fun _ : Fin n => (1 : ℝ))) he).symm |
| 175 | - simp only [ContinuousLinearMap.compContinuousMultilinearMap_coe, Function.comp_def] at h | |
| 175 | + simp only [Function.comp_def] at h | |
| 176 | 176 | exact h |
| 177 | 177 | |
| 178 | 178 | theorem vector_jet_le_sum {d : ℝ → Debt} (hd : ContDiff ℝ ∞ d) (n : ℕ) (eta : ℝ) : |
| @@ -554,7 +554,7 @@ theorem driftBudget_weighted {F : OutgoingProfile.Profile} {N : ℕ} | ||
| 554 | 554 | have hm := (le_div_iff₀ (mul_pos (by norm_num : (0 : ℝ) < 4) (mul_pos q.normalizer_pos hd))).mp |
| 555 | 555 | (min_le_right 1 (rho / (4 * (q.normalizer * driftFactor N q.axial q.angular)))) |
| 556 | 556 | change driftBudget q rho * (4 * (q.normalizer * driftFactor N q.axial q.angular)) ≤ rho at hm |
| 557 | - nlinarith | |
| 557 | + linarith | |
| 558 | 558 | |
| 559 | 559 | theorem normalized_debt_small_of_budgets {F : OutgoingProfile.Profile} {A : NominalProfile.AxisStage F} |
| 560 | 560 | (c : NominalProfile.Controls A) {N : ℕ} (q : FixedBounds F N) {B K BJ rho : ℝ} |
| @@ -570,10 +570,10 @@ theorem normalized_debt_small_of_budgets {F : OutgoingProfile.Profile} {A : Nomi | ||
| 570 | 570 | (driftBudget_pos q hrho).le (driftBudget_le_one q rho) hC hsep hdef |
| 571 | 571 | have hpre : q.normalizer * prefixBudget q B K BJ c.shapeTime A.normalization < rho / 4 := by |
| 572 | 572 | have hh := (lt_div_iff₀ (mul_pos (by norm_num : (0 : ℝ) < 4) q.normalizer_pos)).mp hp |
| 573 | - nlinarith | |
| 573 | + linarith | |
| 574 | 574 | have hrest := driftBudget_weighted q rho |
| 575 | 575 | intro n hn eta hη |
| 576 | - exact (hb n hn eta hη).trans_lt (by nlinarith) | |
| 576 | + exact (hb n hn eta hη).trans_lt (by linarith) | |
| 577 | 577 | |
| 578 | 578 | structure MatchingBounds {F : OutgoingProfile.Profile} {A : NominalProfile.AxisStage F} |
| 579 | 579 | (c : NominalProfile.Controls A) (N : ℕ) (rho : ℝ) : Prop where |
| @@ -688,7 +688,7 @@ theorem exists_ordered_matching_threshold (F : OutgoingProfile.Profile) (N : ℕ | ||
| 688 | 688 | ReferenceJetBounds.jetConstant prep.inputs.coefficients 0 n / Λ ≤ delta / 3 := by |
| 689 | 689 | apply (div_le_iff₀ hΛ).mpr |
| 690 | 690 | have hm := (div_le_iff₀ hd).mp hLD |
| 691 | - nlinarith [hDb n hn] | |
| 691 | + linarith [hDb n hn] | |
| 692 | 692 | obtain ⟨B, hB, K, hK, BJ0, hBJ0, hseed⟩ := TransitionRamp.ordered_seed_bounds |
| 693 | 693 | prep.inputs hΛ hj prep.sigma_pos hnatural F.axisDatum_contDiff N |
| 694 | 694 | let BJ := max BJ0 q.logarithm |
+15 −16 NavierStokes/MovingFrameODE.lean View file
| @@ -55,7 +55,7 @@ theorem inner_pack (a b : ℝ) (u v : Plane) : | ||
| 55 | 55 | |
| 56 | 56 | theorem inner_pack_left (a : ℝ) (u : Plane) (v : Space) : |
| 57 | 57 | ⟪pack a u, v⟫_ℝ = a * v 0 + ⟪u, tail v⟫_ℝ := by |
| 58 | - simp [pack, tail, PiLp.inner_apply, Fin.sum_univ_three, Fin.sum_univ_two] | |
| 58 | + simp [tail, PiLp.inner_apply, Fin.sum_univ_three, Fin.sum_univ_two] | |
| 59 | 59 | ring |
| 60 | 60 | |
| 61 | 61 | @[simp] theorem inner_unitTheta (w : Plane) : ⟪w, unitTheta⟫_ℝ = w 0 := by |
| @@ -274,7 +274,7 @@ theorem hasDerivAt_normal {β ρ : ℝ → ℝ} {B : ℝ → Frame} | ||
| 274 | 274 | (normalMotion (β v) β' (ρ v) ρ' rot (B v)) v := by |
| 275 | 275 | convert! hasDerivAt_pack (hβ.mul hρ) (hβ.smul hK) using 1 |
| 276 | 276 | ext i |
| 277 | - fin_cases i <;> simp [normalMotion, pack] <;> ring | |
| 277 | + fin_cases i <;> simp [normalMotion] <;> ring | |
| 278 | 278 | |
| 279 | 279 | /-- Differentiation of the actual tangent parametrization. -/ |
| 280 | 280 | theorem hasDerivAt_tangent {ρ x y : ℝ → ℝ} {B : ℝ → Frame} |
| @@ -286,7 +286,7 @@ theorem hasDerivAt_tangent {ρ x y : ℝ → ℝ} {B : ℝ → Frame} | ||
| 286 | 286 | (tangentMotion (ρ v) ρ' rot (B v) (x v) (y v) x' y') v := by |
| 287 | 287 | convert! hasDerivAt_pack hx (((hρ.neg.mul hx).smul hK).add (hy.smul hN)) using 1 |
| 288 | 288 | ext i |
| 289 | - fin_cases i <;> simp [tangentMotion, pack] <;> ring | |
| 289 | + fin_cases i <;> simp [tangentMotion] <;> ring | |
| 290 | 290 | |
| 291 | 291 | /-- The ambient ODE is equivalent to the two explicit coordinate ODEs, using |
| 292 | 292 | actual derivatives of the curve and the moving frame. -/ |
| @@ -405,8 +405,7 @@ variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] | ||
| 405 | 405 | variable {m : WithTop ℕ∞} {n : E → Space} {q : E} |
| 406 | 406 | |
| 407 | 407 | theorem contDiffAt_normalScale (hn : ContDiffAt ℝ m n q) (hne : tail (n q) ≠ 0) : |
| 408 | - ContDiffAt ℝ m (fun p => normalScale (n p)) q := by | |
| 409 | - exact (tailCLM.contDiff.contDiffAt.comp q hn).norm ℝ hne | |
| 408 | + ContDiffAt ℝ m (fun p => normalScale (n p)) q := (tailCLM.contDiff.contDiffAt.comp q hn).norm ℝ hne | |
| 410 | 409 | |
| 411 | 410 | theorem contDiffAt_radialSlope (hn : ContDiffAt ℝ m n q) (hne : tail (n q) ≠ 0) : |
| 412 | 411 | ContDiffAt ℝ m (fun p => radialSlope (n p)) q := by |
| @@ -463,7 +462,7 @@ theorem reciprocal_quadratic_difference (r s : ℝ) : | ||
| 463 | 462 | calc |
| 464 | 463 | |(s - r) * (s + r) / ((1 + r ^ 2) * (1 + s ^ 2))| ≤ |(s - r) * (s + r)| := |
| 465 | 464 | abs_div_le_of_one_le _ _ (by |
| 466 | - nlinarith only [sq_nonneg r, sq_nonneg s, mul_nonneg (sq_nonneg r) (sq_nonneg s)]) | |
| 465 | + linarith only [sq_nonneg r, sq_nonneg s, mul_nonneg (sq_nonneg r) (sq_nonneg s)]) | |
| 467 | 466 | _ ≤ |r - s| * (|r| + |s|) := by |
| 468 | 467 | rw [abs_mul, abs_sub_comm s r] |
| 469 | 468 | exact mul_le_mul_of_nonneg_left (by linarith [abs_add_le s r]) (abs_nonneg _) |
| @@ -530,13 +529,13 @@ theorem scalar_coefficients_close | ||
| 530 | 529 | _ = _ := mul_one _ |
| 531 | 530 | constructor |
| 532 | 531 | · calc |
| 533 | - |coeff11 ρ ρ' gK| ≤ |ρ * (gK - ρ')| := abs_div_le_of_one_le _ _ (by nlinarith only [sq_nonneg ρ]) | |
| 532 | + |coeff11 ρ ρ' gK| ≤ |ρ * (gK - ρ')| := abs_div_le_of_one_le _ _ (by linarith only [sq_nonneg ρ]) | |
| 534 | 533 | _ = |ρ| * |gK - ρ'| := abs_mul _ _ |
| 535 | 534 | _ ≤ M * (η + η) := mul_le_mul hρ ((abs_sub _ _).trans (add_le_add hgK hρ')) |
| 536 | 535 | (abs_nonneg _) hM0 |
| 537 | 536 | _ ≤ 16 * M ^ 2 * η := by |
| 538 | - have h := mul_le_mul_of_nonneg_right (show 2 * M ≤ 16 * M ^ 2 by nlinarith only [hM, sq_nonneg (M - 1)]) hη | |
| 539 | - nlinarith only [h] | |
| 537 | + have h := mul_le_mul_of_nonneg_right (show 2 * M ≤ 16 * M ^ 2 by linarith only [hM, sq_nonneg (M - 1)]) hη | |
| 538 | + linarith only [h] | |
| 540 | 539 | constructor |
| 541 | 540 | · have hρden : 1 + ρ ^ 2 ≠ 0 := by positivity |
| 542 | 541 | have hsden : 1 + s ^ 2 ≠ 0 := by positivity |
| @@ -550,12 +549,12 @@ theorem scalar_coefficients_close | ||
| 550 | 549 | _ ≤ |(2 * F * N - ρ * rot - 2 * F0 * N0) / (1 + ρ ^ 2)| + |
| 551 | 550 | |(2 * F0 * N0) * (1 / (1 + ρ ^ 2) - 1 / (1 + s ^ 2))| := abs_add_le _ _ |
| 552 | 551 | _ ≤ (2 + 3 * M) * η + (2 * M) * (2 * M * η) := add_le_add |
| 553 | - ((abs_div_le_of_one_le _ _ (by nlinarith only [sq_nonneg ρ])).trans hnum) | |
| 552 | + ((abs_div_le_of_one_le _ _ (by linarith only [sq_nonneg ρ])).trans hnum) | |
| 554 | 553 | (by rw [abs_mul]; exact mul_le_mul hreference hinv (abs_nonneg _) (by positivity)) |
| 555 | 554 | _ ≤ 16 * M ^ 2 * η := by |
| 556 | 555 | have h := mul_le_mul_of_nonneg_right |
| 557 | - (show 2 + 3 * M + 4 * M ^ 2 ≤ 16 * M ^ 2 by nlinarith only [hM, sq_nonneg (M - 1)]) hη | |
| 558 | - nlinarith only [h] | |
| 556 | + (show 2 + 3 * M + 4 * M ^ 2 ≤ 16 * M ^ 2 by linarith only [hM, sq_nonneg (M - 1)]) hη | |
| 557 | + linarith only [h] | |
| 559 | 558 | · calc |
| 560 | 559 | |coeff21 F N gN ρ rot - (-(2 * F0 * N0 + g0))| = |
| 561 | 560 | |-(2 * F * N - 2 * F0 * N0) - (gN - g0) + ρ * rot| := by |
| @@ -568,8 +567,8 @@ theorem scalar_coefficients_close | ||
| 568 | 567 | simpa only [abs_neg] using abs_sub (-(2 * F * N - 2 * F0 * N0)) (gN - g0)) _ |
| 569 | 568 | _ ≤ (2 * (1 + M) * η + η) + M * η := add_le_add (add_le_add htwoprod hgN) hrotation |
| 570 | 569 | _ ≤ 16 * M ^ 2 * η := by |
| 571 | - have h := mul_le_mul_of_nonneg_right (show 3 + 3 * M ≤ 16 * M ^ 2 by nlinarith only [hM, sq_nonneg (M - 1)]) hη | |
| 572 | - nlinarith only [h] | |
| 570 | + have h := mul_le_mul_of_nonneg_right (show 3 + 3 * M ≤ 16 * M ^ 2 by linarith only [hM, sq_nonneg (M - 1)]) hη | |
| 571 | + linarith only [h] | |
| 573 | 572 | |
| 574 | 573 | theorem inner_perturbation_le {K K0 g g0 : Plane} {M η : ℝ} |
| 575 | 574 | (hK : ‖K‖ ≤ 1) (hg0 : ‖g0‖ ≤ M) |
| @@ -614,7 +613,7 @@ theorem frame_coefficients_close {B B0 : Frame} {g g0 : Plane} | ||
| 614 | 613 | |coeff21 F ((B 1) 0) ⟪B 1, g⟫_ℝ ρ rot - (-(2 * F0 * ((B0 1) 0) + ⟪B0 1, g0⟫_ℝ))| ≤ |
| 615 | 614 | (16 * M ^ 2 * (1 + M)) * η := by |
| 616 | 615 | have hM0 : 0 ≤ M := le_trans zero_le_one hM |
| 617 | - have henlarge : η ≤ (1 + M) * η := by nlinarith only [mul_nonneg hM0 hη] | |
| 616 | + have henlarge : η ≤ (1 + M) * η := by linarith only [mul_nonneg hM0 hη] | |
| 618 | 617 | have hgK := inner_perturbation_le (le_of_eq (B.norm_eq_one 0)) hg0 hK hg |
| 619 | 618 | rw [horth, sub_zero] at hgK |
| 620 | 619 | have hgN := inner_perturbation_le (le_of_eq (B.norm_eq_one 1)) hg0 hN hg |
| @@ -712,7 +711,7 @@ theorem modalOperator_eq_coefficient (lam damping e11 e12 e21 e22 : ℝ) : | ||
| 712 | 711 | ViscousPropagator.coefficient lam damping |
| 713 | 712 | (GrowingMode.modalOperator 0 0 e11 e12 e21 e22) := by |
| 714 | 713 | ext z i |
| 715 | - fin_cases i <;> simp [GrowingMode.modalOperator, ViscousPropagator.coefficient, | |
| 714 | + fin_cases i <;> simp [ViscousPropagator.coefficient, | |
| 716 | 715 | ViscousPropagator.diagonal, ViscousPropagator.reflection] <;> ring |
| 717 | 716 | |
| 718 | 717 | theorem plane_norm_le_coordinate_sum (z : Plane) : ‖z‖ ≤ |z 0| + |z 1| := by |
+2 −2 NavierStokes/NativeBandExtension.lean View file
| @@ -381,8 +381,8 @@ theorem radialInterior_spec {F : OutgoingProfile.Profile} (W : NominalProfile.Wi | ||
| 381 | 381 | (WaveEdgeExtension.nativeRadius F.data.h x) ^ 2 / 2 < |
| 382 | 382 | (PrimaryTargetBounds.rightRadius W) ^ 2 / 2 |
| 383 | 383 | constructor |
| 384 | - · nlinarith [mul_pos (sub_pos.mpr hx.2.1) (add_pos hr ha)] | |
| 385 | - · nlinarith [mul_pos (sub_pos.mpr hx.2.2) (add_pos (hr.trans hx.2.2) hr)] | |
| 384 | + · linarith [mul_pos (sub_pos.mpr hx.2.1) (add_pos hr ha)] | |
| 385 | + · linarith [mul_pos (sub_pos.mpr hx.2.2) (add_pos (hr.trans hx.2.2) hr)] | |
| 386 | 386 | refine ⟨ht, hR, hX, ?_⟩ |
| 387 | 387 | exact WeightedRadialPrimitive.zeta_pos _ _ (WeightedRadialPrimitive.logPosition_mem ha hx.2) |
| 388 | 388 | |
+2 −2 NavierStokes/NaturalAxisBridge.lean View file
| @@ -580,7 +580,7 @@ theorem integrated_solution (I : Window) {ε : ℝ} (hε : 0 < ε) | ||
| 580 | 580 | (2 * s) * angularRemainder (parameters I ε χ d) t |
| 581 | 581 | (AxisEvaluation.profile I ε x.1) (AxisEvaluation.profile I ε x.2) |
| 582 | 582 | (AxisEvaluation.profile I ε (AxisOperators.average I hε x.2)) p := by |
| 583 | - nlinarith only [he] | |
| 583 | + linarith only [he] | |
| 584 | 584 | _ = _ := by rw [hst] |
| 585 | 585 | · intro p hp |
| 586 | 586 | have hY : |p.1| < 20 := abs_lt.mpr hp.1 |
| @@ -602,7 +602,7 @@ theorem integrated_solution (I : Window) {ε : ℝ} (hε : 0 < ε) | ||
| 602 | 602 | (AxisEvaluation.profile I ε x.2) |
| 603 | 603 | (AxisEvaluation.profile I ε (AxisOperators.average I hε x.2)) |
| 604 | 604 | (AxisEvaluation.profile I ε (pressureCoefficient I hε a x.1)) p := by |
| 605 | - nlinarith only [he] | |
| 605 | + linarith only [he] | |
| 606 | 606 | _ = _ := by rw [hst] |
| 607 | 607 | |
| 608 | 608 | /-- The leading pair defined using the proved angular resolvent. -/ |
+3 −3 NavierStokes/NaturalAxisCoefficients.lean View file
| @@ -74,10 +74,10 @@ theorem L_pos_on_window {h j : ℝ} (hp : NaturalAxisRange.Parameters h j) | ||
| 74 | 74 | have hx' : -(11 / 10 : ℝ) ≤ x ∧ x ≤ 11 / 10 := by |
| 75 | 75 | simpa [window, Window.interval, neg_div] using hx |
| 76 | 76 | have hs : x ^ 2 ≤ 2 := by |
| 77 | - nlinarith [mul_nonneg (sub_nonneg.mpr hx'.2) (show 0 ≤ x + 11 / 10 by linarith [hx'.1])] | |
| 77 | + linarith [mul_nonneg (sub_nonneg.mpr hx'.2) (show 0 ≤ x + 11 / 10 by linarith [hx'.1])] | |
| 78 | 78 | have hh := mul_le_mul_of_nonneg_left hs hp.h_pos.le |
| 79 | 79 | dsimp [NaturalAxisData.L] |
| 80 | - nlinarith [hp.h_le] | |
| 80 | + linarith [hp.h_le] | |
| 81 | 81 | |
| 82 | 82 | theorem denominator_ne_zero_on_real (h j : ℝ) {σ : ℝ} (hσ : 0 < σ) (x : ℝ) : |
| 83 | 83 | denominator h j σ (x : ℂ) ≠ 0 := by |
| @@ -165,7 +165,7 @@ theorem complexField_ofReal {g a : ℝ → ℝ} {cap : ℝ} | ||
| 165 | 165 | (realField h j σ (PressureDatum.pressure g a) k x : ℂ) := by |
| 166 | 166 | cases k <;> |
| 167 | 167 | simp [complexField, realField, complexD, complexL, complexU, complexH, complexW, |
| 168 | - complexZ, complexChi, complexGradient, denominator, realGradient, | |
| 168 | + complexZ, complexChi, denominator, realGradient, | |
| 169 | 169 | NaturalAxisData.d, NaturalAxisData.L, NaturalAxisData.U, NaturalAxisData.H, |
| 170 | 170 | NaturalAxisData.W, NaturalAxisData.Z, NaturalAxisData.chi, |
| 171 | 171 | deriv_complexPressure_ofReal hp] |
+9 −9 NavierStokes/NaturalAxisData.lean View file
| @@ -64,13 +64,13 @@ theorem d_nonneg {η : ℝ} (hη : η ∈ Icc (-1 : ℝ) 1) : 0 ≤ d η := by | ||
| 64 | 64 | have hp := mul_nonneg (sub_nonneg.mpr hη.2) |
| 65 | 65 | (show 0 ≤ η + 1 by linarith [hη.1]) |
| 66 | 66 | unfold d |
| 67 | - nlinarith | |
| 67 | + linarith | |
| 68 | 68 | |
| 69 | 69 | theorem L_lower_bound {h j η : ℝ} (p : SmallParameters h j) |
| 70 | 70 | (hη : η ∈ Icc (-1 : ℝ) 1) : 499 / 500 ≤ L h η := by |
| 71 | 71 | have hp := mul_nonneg p.h_pos.le (d_nonneg hη) |
| 72 | 72 | dsimp [d, L] at * |
| 73 | - nlinarith [p.h_le] | |
| 73 | + linarith [p.h_le] | |
| 74 | 74 | |
| 75 | 75 | theorem L_pos {h j η : ℝ} (p : SmallParameters h j) |
| 76 | 76 | (hη : η ∈ Icc (-1 : ℝ) 1) : 0 < L h η := by |
| @@ -87,15 +87,15 @@ theorem neg_W_lower_bound {h j η : ℝ} (p : SmallParameters h j) | ||
| 87 | 87 | have hDj : 0 ≤ 2 * D h * j := |
| 88 | 88 | mul_nonneg (mul_nonneg (by norm_num) (D_pos p).le) p.j_pos.le |
| 89 | 89 | have hDjle : 2 * D h * j ≤ j := by |
| 90 | - nlinarith [mul_nonneg (show 0 ≤ 1 - 2 * D h by linarith [(D_bounds p).2]) p.j_pos.le] | |
| 90 | + linarith [mul_nonneg (show 0 ≤ 1 - 2 * D h by linarith [(D_bounds p).2]) p.j_pos.le] | |
| 91 | 91 | have hηDj : -(2 * D h * j) ≤ 2 * D h * j * η := by |
| 92 | - nlinarith [mul_nonneg hDj (show 0 ≤ η + 1 by linarith [hη.1])] | |
| 92 | + linarith [mul_nonneg hDj (show 0 ≤ η + 1 by linarith [hη.1])] | |
| 93 | 93 | have hhη : h * η ^ 2 ≤ h := by |
| 94 | 94 | have hp := mul_nonneg p.h_pos.le (d_nonneg hη) |
| 95 | 95 | dsimp [d] at hp |
| 96 | - nlinarith | |
| 96 | + linarith | |
| 97 | 97 | rw [neg_W_formula] |
| 98 | - nlinarith [p.h_le, p.j_le] | |
| 98 | + linarith [p.h_le, p.j_le] | |
| 99 | 99 | |
| 100 | 100 | theorem H_contDiff (h j : ℝ) : ContDiff ℝ ∞ (H h j) := by |
| 101 | 101 | unfold H U d |
| @@ -330,13 +330,13 @@ theorem pressureData_of_ideal_prefix {g a : ℝ → ℝ} {cap B : ℝ} | ||
| 330 | 330 | apply (le_div_iff₀ hden).mpr |
| 331 | 331 | linarith |
| 332 | 332 | have hisq : (1 / 4 : ℝ) ≤ ((1 + η ^ 2)⁻¹) ^ 2 := by |
| 333 | - nlinarith [sq_nonneg ((1 + η ^ 2)⁻¹ - 1 / 2)] | |
| 333 | + linarith [sq_nonneg ((1 + η ^ 2)⁻¹ - 1 / 2)] | |
| 334 | 334 | have hBsq : (4 : ℝ) ≤ B ^ 2 := by nlinarith |
| 335 | 335 | have hprod : (1 : ℝ) ≤ B ^ 2 * ((1 + η ^ 2)⁻¹) ^ 2 := by |
| 336 | 336 | have hm := mul_le_mul hBsq hisq (by norm_num : (0 : ℝ) ≤ 1 / 4) (sq_nonneg B) |
| 337 | - nlinarith | |
| 337 | + linarith | |
| 338 | 338 | have hpressure := PressureDatum.pressure_le_of_ideal_prefix hp hg ha η |
| 339 | - nlinarith | |
| 339 | + linarith | |
| 340 | 340 | · intro η hη |
| 341 | 341 | rcases lt_trichotomy η 0 with hn | rfl | hpη |
| 342 | 342 | · exact (mul_pos_of_neg_of_neg hn (PressureDatum.deriv_pressure_neg hp hmass hn)).le |
+10 −10 NavierStokes/NaturalAxisRange.lean View file
| @@ -42,7 +42,7 @@ theorem L_lower_bound {h j η : ℝ} (p : Parameters h j) | ||
| 42 | 42 | (hη : η ∈ Icc (-1 : ℝ) 1) : 49 / 50 ≤ L h η := by |
| 43 | 43 | have hp := mul_nonneg p.h_pos.le (d_nonneg hη) |
| 44 | 44 | dsimp [d, L] at * |
| 45 | - nlinarith [p.h_le] | |
| 45 | + linarith [p.h_le] | |
| 46 | 46 | |
| 47 | 47 | theorem L_pos {h j η : ℝ} (p : Parameters h j) |
| 48 | 48 | (hη : η ∈ Icc (-1 : ℝ) 1) : 0 < L h η := by |
| @@ -58,8 +58,8 @@ theorem H_right_pos {h j : ℝ} (p : Parameters h j) : 0 < H h j (-j / 5) := by | ||
| 58 | 58 | apply mul_pos (div_pos p.j_pos (by norm_num)) |
| 59 | 59 | have hj1 : j ≤ 1 := by linarith [p.j_le] |
| 60 | 60 | have hj2 : j ^ 2 ≤ 1 := by |
| 61 | - nlinarith [mul_nonneg (sub_nonneg.mpr hj1) (show 0 ≤ j + 1 by linarith [p.j_pos])] | |
| 62 | - nlinarith [(D_bounds p).2] | |
| 61 | + linarith [mul_nonneg (sub_nonneg.mpr hj1) (show 0 ≤ j + 1 by linarith [p.j_pos])] | |
| 62 | + linarith [(D_bounds p).2] | |
| 63 | 63 | |
| 64 | 64 | theorem H_pos_of_nonneg {h j η : ℝ} (p : Parameters h j) |
| 65 | 65 | (hη : η ∈ Icc (-1 : ℝ) 1) (hη0 : 0 ≤ η) : 0 < H h j η := by |
| @@ -114,23 +114,23 @@ theorem Z_at_root_lower {h j η : ℝ} {P : ℝ → ℝ} (p : Parameters h j) | ||
| 114 | 114 | have hUj : U j η < j / 5 := by dsimp [U]; linarith [hη.2] |
| 115 | 115 | have hrU : -η * U j η ≤ U j η := by |
| 116 | 116 | simpa using mul_le_mul_of_nonneg_right (show -η ≤ 1 by linarith [hI.1]) hU.le |
| 117 | - have hfactor : 1 - 2 * η * U j η ≤ 2 := by nlinarith [p.j_le] | |
| 117 | + have hfactor : 1 - 2 * η * U j η ≤ 2 := by linarith [p.j_le] | |
| 118 | 118 | have hadverse : (1 - 2 * η * U j η) * U j η < 2 * j / 5 := |
| 119 | 119 | lt_of_le_of_lt (mul_le_mul_of_nonneg_right hfactor hU.le) (by linarith) |
| 120 | 120 | have hpressure := mul_le_mul_of_nonpos_left hP hηn.le |
| 121 | 121 | have hcore : 2 * j / 5 < -(1 - 2 * η * U j η) * U j η + 4 * η * P η := by |
| 122 | - nlinarith [hη.2] | |
| 122 | + linarith [hη.2] | |
| 123 | 123 | have hderiv : d η * deriv P η ≤ 0 := |
| 124 | 124 | mul_nonpos_of_nonneg_of_nonpos (d_nonneg hI) hP' |
| 125 | 125 | calc |
| 126 | 126 | j / 5 ≤ A h * (2 * j / 5) := by |
| 127 | - nlinarith [mul_nonneg (show 0 ≤ A h - 1 / 2 by linarith [(A_bounds p).1]) p.j_pos.le] | |
| 127 | + linarith [mul_nonneg (show 0 ≤ A h - 1 / 2 by linarith [(A_bounds p).1]) p.j_pos.le] | |
| 128 | 128 | _ < A h * (-(1 - 2 * η * U j η) * U j η + 4 * η * P η) := |
| 129 | 129 | mul_lt_mul_of_pos_left hcore (A_pos p) |
| 130 | 130 | _ ≤ Z h j P η := by |
| 131 | 131 | unfold Z |
| 132 | 132 | rw [hz] |
| 133 | - nlinarith | |
| 133 | + linarith | |
| 134 | 134 | |
| 135 | 135 | theorem exists_root_with_positive_Z {h j : ℝ} {P : ℝ → ℝ} |
| 136 | 136 | (p : Parameters h j) (pP : PressureData P) : |
| @@ -178,10 +178,10 @@ theorem exists_sigma {h j : ℝ} {P : ℝ → ℝ} | ||
| 178 | 178 | refine ⟨σ, hσ, ?_⟩ |
| 179 | 179 | intro η hη hZ |
| 180 | 180 | have hH := hbound η hη hZ |
| 181 | - have hden : 0 < (H h j η) ^ 2 + σ ^ 2 := by nlinarith [sq_nonneg σ] | |
| 181 | + have hden : 0 < (H h j η) ^ 2 + σ ^ 2 := by linarith [sq_nonneg σ] | |
| 182 | 182 | unfold chi |
| 183 | 183 | apply (lt_div_iff₀ hden).mpr |
| 184 | - nlinarith | |
| 184 | + linarith | |
| 185 | 185 | |
| 186 | 186 | theorem exists_cutoff_parameters {h j : ℝ} {P : ℝ → ℝ} |
| 187 | 187 | (p : Parameters h j) (pP : PressureData P) : |
| @@ -211,6 +211,6 @@ theorem base_source_lower {h j η : ℝ} (p : Parameters h j) | ||
| 211 | 211 | ring |
| 212 | 212 | rw [he] |
| 213 | 213 | have hm := mul_nonneg p.j_pos.le (show 0 ≤ η + 1 by linarith [hη.1]) |
| 214 | - nlinarith [p.h_le, p.j_le] | |
| 214 | + linarith [p.h_le, p.j_le] | |
| 215 | 215 | |
| 216 | 216 | end NavierStokes.NaturalAxisRange |
+3 −3 NavierStokes/NaturalCoefficientBridge.lean View file
| @@ -99,7 +99,7 @@ theorem angular_zero_formula (h : ℝ) (f : SlowProfiles) (w : InnerPoint) : | ||
| 99 | 99 | (f.flux 0 w * (partialX (f.phi 0) w + f.phi 0 w / w.1) + |
| 100 | 100 | f.axial 0 w * Z h (angularExponent h) (f.phi 0) w) := by |
| 101 | 101 | simp [angularCoefficient, transportCoefficient, recurrence, transportLinear, transportPair, |
| 102 | - slowOrder, convolution, previous] | |
| 102 | + convolution, previous] | |
| 103 | 103 | |
| 104 | 104 | theorem axial_zero_formula (h : ℝ) (f : SlowProfiles) (w : InnerPoint) : |
| 105 | 105 | axialCoefficient h f 0 w = |
| @@ -109,7 +109,7 @@ theorem axial_zero_formula (h : ℝ) (f : SlowProfiles) (w : InnerPoint) : | ||
| 109 | 109 | (f.flux 0 w * partialX (f.axial 0) w + |
| 110 | 110 | f.axial 0 w * Z h (axialExponent h) (f.axial 0) w) := by |
| 111 | 111 | simp [axialCoefficient, transportCoefficient, recurrence, transportLinear, transportPair, |
| 112 | - slowOrder, convolution, previous, axialPressureSource] | |
| 112 | + convolution, previous, axialPressureSource] | |
| 113 | 113 | |
| 114 | 114 | theorem natural_angular_zero {h j Λ : ℝ} {P0 a0 : ℝ → ℝ} {f U V P : InnerProfile} |
| 115 | 115 | (hs : NaturalProfile.IsNaturalSolution h j Λ P0 a0 f U V P) |
| @@ -260,7 +260,7 @@ theorem initialBand_mem_domain {Λ : ℝ} (hΛ : 0 < Λ) {w : InnerPoint} | ||
| 260 | 260 | have hlo := mul_nonneg hΛ.le hw.1.1 |
| 261 | 261 | have hhi : Λ * w.1 ≤ 4 := by |
| 262 | 262 | have ht := (le_div_iff₀ hΛ).mp hw.1.2 |
| 263 | - nlinarith | |
| 263 | + linarith | |
| 264 | 264 | exact ⟨⟨by linarith, by linarith⟩, hw.2⟩ |
| 265 | 265 | |
| 266 | 266 | theorem radialFlux_congr_germ (h lam : ℝ) {U V : InnerProfile} {w : InnerPoint} |
+11 −11 NavierStokes/NaturalEntrance.lean View file
| @@ -78,7 +78,7 @@ theorem cone_size_of_second_large {a b : ℝ} (ha : 0 < a) (hb : (6 / 5 : ℝ) ^ | ||
| 78 | 78 | calc |
| 79 | 79 | 12 / 5 < (a ^ 2 + b ^ 2) / a := by |
| 80 | 80 | apply (lt_div_iff₀ ha).mpr |
| 81 | - nlinarith [sq_nonneg (a - 6 / 5)] | |
| 81 | + linarith [sq_nonneg (a - 6 / 5)] | |
| 82 | 82 | _ = _ := by field_simp |
| 83 | 83 | |
| 84 | 84 | /-- Compactness supplies one absorption scale when the limiting remainder |
| @@ -419,13 +419,13 @@ theorem sourceRemainder_uniform_limit {h j σ : ℝ} {P0 : ℝ → ℝ} | ||
| 419 | 419 | have hmul := (div_lt_iff₀ hδ).mp hratio |
| 420 | 420 | have htime : |1 / Λ| < δ := by |
| 421 | 421 | rw [abs_of_pos (one_div_pos.mpr hΛpos), div_lt_iff₀ hΛpos] |
| 422 | - nlinarith [mul_nonneg hJ.le hK] | |
| 422 | + linarith [mul_nonneg hJ.le hK] | |
| 423 | 423 | have hjets : ‖sourceJets v.epsilon_pos x p - |
| 424 | 424 | sourceJets v.epsilon_pos (referencePair v) p‖ < δ := by |
| 425 | 425 | apply (sourceJets_sub_bound v.epsilon_pos x (referencePair v) p.property).trans_lt |
| 426 | 426 | apply (mul_le_mul_of_nonneg_left hx hJ.le).trans_lt |
| 427 | 427 | rw [← mul_div_assoc, div_lt_iff₀ (by positivity : 0 < 2 * Λ)] |
| 428 | - nlinarith [mul_nonneg hJ.le hK] | |
| 428 | + linarith [mul_nonneg hJ.le hK] | |
| 429 | 429 | have hpert : ‖((1 / Λ), sourceJets v.epsilon_pos x p - |
| 430 | 430 | sourceJets v.epsilon_pos (referencePair v) p)‖ < δ := by |
| 431 | 431 | simpa only [Prod.norm_def, Real.norm_eq_abs, max_lt_iff] using And.intro htime hjets |
| @@ -451,7 +451,7 @@ theorem source_uniform_lower {h j σ : ℝ} {P0 : ℝ → ℝ} | ||
| 451 | 451 | intro Λ hΛ x hx p |
| 452 | 452 | have hbase := hmain Λ ((le_max_left _ _).trans hΛ) p |
| 453 | 453 | have he := (abs_lt.mp (herr Λ ((le_max_right _ _).trans hΛ) x hx p)).1 |
| 454 | - nlinarith | |
| 454 | + linarith | |
| 455 | 455 | |
| 456 | 456 | theorem angularProfile_radial_log_derivative {a : ℝ → ℝ} {Λ : ℝ} |
| 457 | 457 | {Φ : ℝ × ℝ → ℝ} (hΦ : ContDiffOn ℝ ∞ Φ (AxisEvaluation.strip window 20)) |
| @@ -593,7 +593,7 @@ theorem p1_pos_of_source {h j Λ R η : ℝ} {P0 a : ℝ → ℝ} | ||
| 593 | 593 | simpa only [radialDifferential, partialY, iteratedDeriv_succ, |
| 594 | 594 | iteratedDeriv_zero, Nat.cast_ofNat] using hsrc |
| 595 | 595 | unfold p1 partialY |
| 596 | - exact div_pos (mul_pos_of_neg_of_neg (by nlinarith) hneg) (hpos R ⟨hR.le, le_rfl⟩) | |
| 596 | + exact div_pos (mul_pos_of_neg_of_neg (by linarith) hneg) (hpos R ⟨hR.le, le_rfl⟩) | |
| 597 | 597 | |
| 598 | 598 | /-- Applying the actual regular inverse to radially constant data gives |
| 599 | 599 | exactly its degree-one polynomial. -/ |
| @@ -749,7 +749,7 @@ theorem ns_error {h j σ Λ K : ℝ} {P0 : ℝ → ℝ} | ||
| 749 | 749 | theorem L_le_one {h j : ℝ} (hsmall : NaturalAxisRange.Parameters h j) (η : ℝ) : |
| 750 | 750 | NaturalAxisData.L h η ≤ 1 := by |
| 751 | 751 | unfold NaturalAxisData.L |
| 752 | - nlinarith [mul_nonneg hsmall.h_pos.le (sq_nonneg η)] | |
| 752 | + linarith [mul_nonneg hsmall.h_pos.le (sq_nonneg η)] | |
| 753 | 753 | |
| 754 | 754 | /-- Where `Z*` is separated from zero, the actual axial shear is separated |
| 755 | 755 | from zero uniformly in the normalization. -/ |
| @@ -774,7 +774,7 @@ theorem ns_separated {h j σ Λ K δ : ℝ} {P0 : ℝ → ℝ} | ||
| 774 | 774 | apply he.trans_lt |
| 775 | 775 | rw [div_lt_iff₀ hΛ] |
| 776 | 776 | have ht := (div_lt_iff₀ hδ).mp hΛ' |
| 777 | - nlinarith | |
| 777 | + linarith | |
| 778 | 778 | have hratio : δ < |NaturalAxisData.Z h j P0 p.2 / NaturalAxisData.L h p.2| := by |
| 779 | 779 | rw [abs_div, abs_of_pos hL] |
| 780 | 780 | apply hZ.trans_le |
| @@ -873,7 +873,7 @@ theorem angularField_small {h j σ Λ C δ : ℝ} {P0 : ℝ → ℝ} | ||
| 873 | 873 | unfold entranceNormalization |
| 874 | 874 | field_simp |
| 875 | 875 | rwa [hid] at hh |
| 876 | - nlinarith [mul_pos hT hδ] | |
| 876 | + linarith [mul_pos hT hδ] | |
| 877 | 877 | |
| 878 | 878 | theorem second_coordinate_large {Λ δ f n : ℝ} |
| 879 | 879 | (hΛ : 1 ≤ Λ) (hδ : 0 < δ) (hf : 0 < f) |
| @@ -892,13 +892,13 @@ theorem second_coordinate_large {Λ δ f n : ℝ} | ||
| 892 | 892 | have hEb : Λ * (Real.sqrt (2 * (4 / Λ)) * f) ≤ 3 * δ / 100 := by |
| 893 | 893 | have hm := mul_le_mul_of_nonneg_right hsqrt hf.le |
| 894 | 894 | have hm' := mul_le_mul_of_nonneg_left hm hΛpos.le |
| 895 | - nlinarith | |
| 895 | + linarith | |
| 896 | 896 | have hn' : 2 * δ < Λ * ((4 / Λ) * |n|) := by |
| 897 | 897 | rw [← mul_assoc, hprod] |
| 898 | 898 | linarith |
| 899 | 899 | have hlarge : (6 / 5 : ℝ) * (Real.sqrt (2 * (4 / Λ)) * f) < (4 / Λ) * |n| := by |
| 900 | 900 | apply (mul_lt_mul_iff_of_pos_left hΛpos).mp |
| 901 | - nlinarith | |
| 901 | + linarith | |
| 902 | 902 | have habs : |(4 / Λ) * n / (Real.sqrt (2 * (4 / Λ)) * f)| = |
| 903 | 903 | (4 / Λ) * |n| / (Real.sqrt (2 * (4 / Λ)) * f) := by |
| 904 | 904 | rw [abs_div, abs_mul, abs_of_pos hX, abs_of_pos hE] |
| @@ -1213,7 +1213,7 @@ theorem angular_source_integral {h j Λ : ℝ} {P0 a : ℝ → ℝ} | ||
| 1213 | 1213 | intro x hx |
| 1214 | 1214 | dsimp only |
| 1215 | 1215 | rw [Sq_eq_radial hs (hmem x hx) (hf x hx)] |
| 1216 | - simp only [radialDifferential, partialY, iteratedDeriv_succ, iteratedDeriv_zero, Nat.cast_ofNat] | |
| 1216 | + simp only [radialDifferential, partialY, iteratedDeriv_succ, iteratedDeriv_zero] | |
| 1217 | 1217 | field_simp [hf x hx] ; ring |
| 1218 | 1218 | _ = _ := angular_flux_integral (NaturalAxisData.L h p.2) p.1 hreg |
| 1219 | 1219 | |
+1 −1 NavierStokes/NormalScaling.lean View file
| @@ -22,7 +22,7 @@ variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℝ H] | ||
| 22 | 22 | theorem tangentProj_smul_normal (n f : H) {s : ℝ} (hs : s ≠ 0) : |
| 23 | 23 | tangentProj (s • n) f = tangentProj n f := by |
| 24 | 24 | by_cases hn : n = 0 |
| 25 | - · simp [hn, tangentProj] | |
| 25 | + · simp [hn] | |
| 26 | 26 | have hn2 : ⟪n, n⟫_ℝ ≠ 0 := inner_self_ne_zero.mpr hn |
| 27 | 27 | simp only [tangentProj, real_inner_smul_left, real_inner_smul_right, smul_smul] |
| 28 | 28 | congr 2 |
+9 −9 NavierStokes/OutgoingCone.lean View file
| @@ -48,7 +48,7 @@ theorem hold_Qs_pos {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 48 | 48 | have hl := ShapedWaitBounds.canonical_Qs_hold_lower w ha hh1 hhlam hhT heta ht htw |
| 49 | 49 | have hp : 0 < ShapedWaitBounds.holdFloor d.core.m * |
| 50 | 50 | (eta ^ 2 + d.core.lam + Real.exp (-(1 - d.core.lam) * t)) := by |
| 51 | - exact mul_pos hf (by nlinarith [sq_nonneg eta, d.core.lam_pos, Real.exp_pos (-(1 - d.core.lam) * t)]) | |
| 51 | + exact mul_pos hf (by linarith [sq_nonneg eta, d.core.lam_pos, Real.exp_pos (-(1 - d.core.lam) * t)]) | |
| 52 | 52 | exact hp.trans_le hl |
| 53 | 53 | |
| 54 | 54 | noncomputable def holdRatioConstant (P m : ℝ) : ℝ := |
| @@ -80,11 +80,11 @@ theorem hold_ratio_bound {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 80 | 80 | ring |
| 81 | 81 | have hsq : 2 * |eta| * s ≤ eta ^ 2 + Real.exp (-(1 - d.core.lam) * t) := by |
| 82 | 82 | have hb := sq_nonneg (|eta| - s) |
| 83 | - nlinarith [hs, sq_abs eta] | |
| 83 | + linarith [hs, sq_abs eta] | |
| 84 | 84 | have hmul := mul_le_mul_of_nonneg_left hsq hc.le |
| 85 | 85 | have hqeta : 2 * ShapedWaitBounds.holdFloor d.core.m * |eta| * s ≤ |
| 86 | 86 | OutgoingHistories.Qs w Amp (d.core.holdStart + t, eta) := by |
| 87 | - nlinarith [mul_pos hc d.core.lam_pos] | |
| 87 | + linarith [mul_pos hc d.core.lam_pos] | |
| 88 | 88 | have hfac : 0 ≤ holdRatioConstant d.core.P d.core.m * (1 + t) * Real.exp (d.core.lam * t / 2) := |
| 89 | 89 | mul_nonneg (mul_nonneg (holdRatioConstant_pos d.core.P_pos d.core.m).le (by linarith)) (Real.exp_pos _).le |
| 90 | 90 | have hb := mul_le_mul_of_nonneg_left hqeta hfac |
| @@ -124,7 +124,7 @@ theorem hold_sqrt_ratio_bound {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 124 | 124 | have htlog : t ≤ 60 * Real.log (1 / d.core.lam) := by rwa [hwait] at htw |
| 125 | 125 | have hlin : 1 + t ≤ 60 * (1 + Real.log (1 / d.core.lam)) := by linarith |
| 126 | 126 | have hlambda := mul_le_mul_of_nonneg_left htlog d.core.lam_pos.le |
| 127 | - have harg : d.core.lam * t / 2 ≤ 30 := by nlinarith [TailCone.lambda_log_bound d] | |
| 127 | + have harg : d.core.lam * t / 2 ≤ 30 := by linarith [TailCone.lambda_log_bound d] | |
| 128 | 128 | have hex := Real.exp_le_exp.mpr harg |
| 129 | 129 | have hb := hold_ratio_bound w ha hh1 hhlam hhT heta ht htw |
| 130 | 130 | have hC := (holdRatioConstant_pos d.core.P_pos d.core.m).le |
| @@ -133,11 +133,11 @@ theorem hold_sqrt_ratio_bound {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 133 | 133 | have hraw : |coneRatio w Amp (d.core.holdStart + t, eta)| ≤ |
| 134 | 134 | holdSmallConstant d.core.P d.core.m * (1 + Real.log (1 / d.core.lam)) := by |
| 135 | 135 | dsimp [holdSmallConstant] |
| 136 | - nlinarith | |
| 136 | + linarith | |
| 137 | 137 | have hs := mul_le_mul_of_nonneg_left hraw (Real.sqrt_nonneg d.core.lam) |
| 138 | 138 | have hr := (PulseCone.coneRate_parts d.core.lam_pos (by linarith [d.core.lam_lt])).2.2 |
| 139 | 139 | have hr' := mul_le_mul_of_nonneg_left hr (holdSmallConstant_pos d.core.P_pos d.core.m).le |
| 140 | - nlinarith | |
| 140 | + linarith | |
| 141 | 141 | |
| 142 | 142 | theorem exists_hold_threshold (P m : ℝ) : |
| 143 | 143 | ∃ lam0 : ℝ, 0 < lam0 ∧ ∀ lam : ℝ, 0 < lam → lam < lam0 → |
| @@ -207,7 +207,7 @@ theorem hold_source_criterion {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 207 | 207 | · simp only [zero_mul, sub_zero] |
| 208 | 208 | linarith [d.core.lam_pos] |
| 209 | 209 | · norm_num only [zero_mul, mul_zero, zero_pow, zero_div, zero_add, add_zero] |
| 210 | - nlinarith | |
| 210 | + linarith | |
| 211 | 211 | · linarith [d.core.lam_pos] |
| 212 | 212 | |
| 213 | 213 | /-! ## Common actual cone coordinates and source tests -/ |
| @@ -247,7 +247,7 @@ theorem normalV_gt_two_of_radial {d : TailData} {K : ℝ} (w : ResetWitness d K) | ||
| 247 | 247 | (Amp : ℝ → ℝ) (p : ℝ × ℝ) (ha : 2 < coneA w p) : 2 < normalV w Amp p := by |
| 248 | 248 | have hm := mul_nonneg (show 0 ≤ coneA w p by linarith) (sq_nonneg (coneB w Amp p / coneA w p)) |
| 249 | 249 | unfold normalV |
| 250 | - nlinarith | |
| 250 | + linarith | |
| 251 | 251 | |
| 252 | 252 | theorem sourceCriterion_before_endpoint {d : TailData} {K : ℝ} (w : ResetWitness d K) |
| 253 | 253 | {Amp : ℝ → ℝ} (ha : ContDiff ℝ ∞ Amp) |
| @@ -544,7 +544,7 @@ theorem leading_gap_of_finite {s c j v : ℝ} (hs : 0 < s) (hv : 2 < v) | ||
| 544 | 544 | apply (sq_lt_sq₀ (by linarith : 0 ≤ s * c - v) (mul_pos hs hc).le).mpr |
| 545 | 545 | linarith |
| 546 | 546 | have hgap : s ^ 2 * ((v - 2) * j ^ 2) < s ^ 2 * (2 * c ^ 2) := by |
| 547 | - nlinarith only [hquad, hd] | |
| 547 | + linarith only [hquad, hd] | |
| 548 | 548 | exact ⟨hc, sub_pos.mpr ((mul_lt_mul_iff_right₀ (sq_pos_of_pos hs)).mp hgap)⟩ |
| 549 | 549 | |
| 550 | 550 | theorem clean_true_source_positive {d : TailData} {K : ℝ} (w : ResetWitness d K) |
+41 −42 NavierStokes/OutgoingEntranceCone.lean View file
| @@ -173,14 +173,14 @@ theorem eta_shapeGradient_bounds {η : ℝ} (hη : |η| ≤ 1) : | ||
| 173 | 173 | rw [← mul_div_assoc] |
| 174 | 174 | constructor |
| 175 | 175 | · apply (le_div_iff₀ hp).mpr |
| 176 | - nlinarith [sq_nonneg η, mul_nonneg (sq_nonneg η) (sub_nonneg.mpr hsq)] | |
| 176 | + linarith [sq_nonneg η, mul_nonneg (sq_nonneg η) (sub_nonneg.mpr hsq)] | |
| 177 | 177 | · apply (div_le_one hp).mpr |
| 178 | - nlinarith | |
| 178 | + linarith | |
| 179 | 179 | |
| 180 | 180 | theorem abs_shapeGradient_le (η : ℝ) : |shapeGradient η| ≤ 2 * |η| := by |
| 181 | 181 | rw [shapeGradient, abs_div, abs_mul, abs_of_nonneg (by norm_num : (0 : ℝ) ≤ 2), |
| 182 | 182 | abs_of_pos (by positivity : 0 < 1 + η ^ 2)] |
| 183 | - exact div_le_self (by positivity) (by nlinarith [sq_nonneg η]) | |
| 183 | + exact div_le_self (by positivity) (by linarith [sq_nonneg η]) | |
| 184 | 184 | |
| 185 | 185 | theorem dropCoefficient_hasDerivAt {m y : ℝ} (hm : 0 < m) (hy : 0 < y) : |
| 186 | 186 | HasDerivAt (dropCoefficient m) |
| @@ -287,7 +287,7 @@ theorem idealAngularLag_lower {h η : ℝ} (hh : 0 ≤ h) (hh1 : h ≤ 1 / 100) | ||
| 287 | 287 | exact mul_nonneg (by positivity) (le_trans (sq_nonneg η) hJ) |
| 288 | 288 | unfold idealAngularLag idealAngularSource |
| 289 | 289 | apply (le_div_iff₀ (by norm_num : (0 : ℝ) < 8 / 5)).mpr |
| 290 | - nlinarith [mul_nonneg hh (sq_nonneg η)] | |
| 290 | + linarith [mul_nonneg hh (sq_nonneg η)] | |
| 291 | 291 | |
| 292 | 292 | theorem angularRate_bounds (c : Parameters) (y : ℝ) : |
| 293 | 293 | 9 / 10 ≤ angularRate c y ∧ angularRate c y ≤ 8 / 5 := by |
| @@ -321,7 +321,7 @@ theorem transportW_second_ramp (c : Parameters) {h y η : ℝ} (hh : 0 ≤ h) | ||
| 321 | 321 | have hk0 := (averagedDrop_bounds c (y := y) (by linarith [c.dropLength_pos])).1 |
| 322 | 322 | have hk := averagedDrop_small_on_second_ramp c hy |
| 323 | 323 | unfold transportW |
| 324 | - nlinarith [mul_le_mul_of_nonneg_right hL hk0] | |
| 324 | + linarith [mul_le_mul_of_nonneg_right hL hk0] | |
| 325 | 325 | |
| 326 | 326 | theorem angularSource_lower (c : Parameters) {h η y : ℝ} (hh : 0 ≤ h) |
| 327 | 327 | (hh1 : h ≤ 1 / 100) (_hy : 0 ≤ y) (hη : |η| ≤ 1) : |
| @@ -342,10 +342,10 @@ theorem angularSource_lower (c : Parameters) {h η y : ℝ} (hh : 0 ≤ h) | ||
| 342 | 342 | have hJ := (eta_shapeGradient_bounds hη).1 |
| 343 | 343 | have hD : 49 / 100 ≤ D h := by unfold D; linarith |
| 344 | 344 | have hDJ : (49 / 100) * η ^ 2 ≤ (D h + d η * dropCoefficient c.m y) * (η * shapeGradient η) := |
| 345 | - mul_le_mul (by nlinarith [mul_nonneg hd hk.1]) hJ (sq_nonneg η) | |
| 346 | - (by nlinarith [mul_nonneg hd hk.1]) | |
| 345 | + mul_le_mul (by linarith [mul_nonneg hd hk.1]) hJ (sq_nonneg η) | |
| 346 | + (by linarith [mul_nonneg hd hk.1]) | |
| 347 | 347 | unfold angularSource |
| 348 | - nlinarith [mul_nonneg hh (mul_nonneg hk.1 (sq_nonneg η))] | |
| 348 | + linarith [mul_nonneg hh (mul_nonneg hk.1 (sq_nonneg η))] | |
| 349 | 349 | |
| 350 | 350 | theorem primitive_continuous_of_continuous {r : ℝ → ℝ} (hr : Continuous r) : |
| 351 | 351 | Continuous (OutgoingSchedule.primitive r) := |
| @@ -415,7 +415,7 @@ theorem linearLag_lower_barrier {r b : ℝ → ℝ} (hr : Continuous r) (hb : Co | ||
| 415 | 415 | calc |
| 416 | 416 | _ = Real.exp (-OutgoingSchedule.primitive r y) * |
| 417 | 417 | (β + κ + (Real.exp (OutgoingSchedule.primitive r y) - 1) * β) := by |
| 418 | - nlinarith [congrArg (fun t : ℝ => t * β) hc] | |
| 418 | + linarith [congrArg (fun t : ℝ => t * β) hc] | |
| 419 | 419 | _ ≤ _ := mul_le_mul_of_nonneg_left (add_le_add hq hi) (Real.exp_pos _).le |
| 420 | 420 | |
| 421 | 421 | theorem slope_integral_upper (c : Parameters) {y : ℝ} (hy : 0 ≤ y) : |
| @@ -462,7 +462,7 @@ theorem angularSource_barrier (c : Parameters) {h η y : ℝ} (hh : 0 ≤ h) | ||
| 462 | 462 | have hs := angularSource_lower c hh hh1 hy hη |
| 463 | 463 | have h₁ := mul_le_mul_of_nonneg_right hr.2 (sq_nonneg η) |
| 464 | 464 | have h₂ := mul_le_mul_of_nonneg_right hr.1 hh |
| 465 | - nlinarith [sq_nonneg η] | |
| 465 | + linarith [sq_nonneg η] | |
| 466 | 466 | |
| 467 | 467 | theorem angularLag_barrier (c : Parameters) {h η y : ℝ} (hh : 0 ≤ h) |
| 468 | 468 | (hh1 : h ≤ 1 / 100) (hy : 0 ≤ y) (hη : |η| ≤ 1) : |
| @@ -503,7 +503,7 @@ theorem angularLag_lower (c : Parameters) {h η y T : ℝ} (hh : 0 ≤ h) | ||
| 503 | 503 | have hηc := mul_le_mul_of_nonneg_right coneFloor_le_quarter (sq_nonneg η) |
| 504 | 504 | rw [he] at hq hT |
| 505 | 505 | unfold coneFloor at hηc ⊢ |
| 506 | - nlinarith | |
| 506 | + linarith | |
| 507 | 507 | |
| 508 | 508 | theorem angularLag_pos (c : Parameters) {h η y T : ℝ} (hh : 0 ≤ h) |
| 509 | 509 | (hh1 : h ≤ 1 / 100) (hy : 0 ≤ y) (hyT : y ≤ T) (hη : |η| ≤ 1) |
| @@ -566,7 +566,7 @@ theorem clockEnergy_lower (c : Parameters) {y : ℝ} (hy : 0 ≤ y) | ||
| 566 | 566 | simp only [weightedClockEnergy, Real.exp_zero, one_mul, clockEnergy_initial] at hm |
| 567 | 567 | have he : Real.exp (-y) * Real.exp y = 1 := by rw [← Real.exp_add]; simp |
| 568 | 568 | have hh := mul_le_mul_of_nonneg_left hm (Real.exp_pos (-y)).le |
| 569 | - nlinarith [congrArg (fun t : ℝ => t * clockEnergy c y) he] | |
| 569 | + linarith [congrArg (fun t : ℝ => t * clockEnergy c y) he] | |
| 570 | 570 | |
| 571 | 571 | theorem averagedClockEnergy_nonneg (c : Parameters) {y : ℝ} (hy : 0 ≤ y) : |
| 572 | 572 | 0 ≤ averagedClockEnergy c y := |
| @@ -807,15 +807,15 @@ theorem geometricAxialLag_bound (c : Parameters) {h y η : ℝ} (hh : 0 ≤ h) | ||
| 807 | 807 | have hW : |transportW c h y η| ≤ 3 := by |
| 808 | 808 | exact abs_le.mpr (transportW_bounds c hh hh1 hy hη |>.imp_right (fun h => h.trans (by norm_num))) |
| 809 | 809 | have hsq := parameter_square_le_one hη |
| 810 | - have hd : 0 ≤ d η ∧ d η ≤ 1 := by unfold d; constructor <;> nlinarith [sq_nonneg η] | |
| 810 | + have hd : 0 ≤ d η ∧ d η ≤ 1 := by unfold d; constructor <;> linarith [sq_nonneg η] | |
| 811 | 811 | have hc : |4 * h * η ^ 2 - 2 * d η| ≤ 3 := by |
| 812 | 812 | apply abs_le.mpr |
| 813 | 813 | have hm := mul_le_mul_of_nonneg_left hsq hh |
| 814 | - constructor <;> nlinarith [mul_nonneg hh (sq_nonneg η)] | |
| 814 | + constructor <;> linarith [mul_nonneg hh (sq_nonneg η)] | |
| 815 | 815 | have hfirst : |-(transportW c h y η) * dropCoefficient c.m y * η| ≤ 12 * |η| := by |
| 816 | 816 | rw [abs_mul, abs_mul, abs_neg, abs_of_nonneg hk.1] |
| 817 | 817 | have hm := mul_le_mul hW hk.2 hk.1 (by norm_num : (0 : ℝ) ≤ 3) |
| 818 | - nlinarith [mul_le_mul_of_nonneg_right hm (abs_nonneg η)] | |
| 818 | + linarith [mul_le_mul_of_nonneg_right hm (abs_nonneg η)] | |
| 819 | 819 | have hsecond : |(4 * h * η ^ 3 - 2 * d η * η) * averagedDropSquare c y| ≤ 48 * |η| := by |
| 820 | 820 | have he : 4 * h * η ^ 3 - 2 * d η * η = (4 * h * η ^ 2 - 2 * d η) * η := by ring |
| 821 | 821 | rw [he, abs_mul, abs_mul, abs_of_nonneg hK.1] |
| @@ -825,13 +825,13 @@ theorem geometricAxialLag_bound (c : Parameters) {h y η : ℝ} (hh : 0 ≤ h) | ||
| 825 | 825 | _ = _ := by ring |
| 826 | 826 | exact (abs_add_le _ _).trans (by |
| 827 | 827 | change _ ≤ 64 * |η| |
| 828 | - nlinarith [abs_nonneg η]) | |
| 828 | + linarith [abs_nonneg η]) | |
| 829 | 829 | |
| 830 | 830 | theorem pressure_coefficient_bound {h η : ℝ} (hh : 0 ≤ h) (hh1 : h ≤ 1 / 100) |
| 831 | 831 | (hη : |η| ≤ 1) : |2 * h * η + d η * shapeGradient η| ≤ 3 * |η| := by |
| 832 | 832 | have hd : 0 ≤ d η ∧ d η ≤ 1 := by |
| 833 | 833 | unfold d |
| 834 | - constructor <;> nlinarith [parameter_square_le_one hη, sq_nonneg η] | |
| 834 | + constructor <;> linarith [parameter_square_le_one hη, sq_nonneg η] | |
| 835 | 835 | calc |
| 836 | 836 | _ ≤ |2 * h * η| + |d η * shapeGradient η| := abs_add_le _ _ |
| 837 | 837 | _ = 2 * h * |η| + d η * |shapeGradient η| := by |
| @@ -841,7 +841,7 @@ theorem pressure_coefficient_bound {h η : ℝ} (hh : 0 ≤ h) (hh1 : h ≤ 1 / | ||
| 841 | 841 | apply add_le_add_right |
| 842 | 842 | simpa only [one_mul] using |
| 843 | 843 | mul_le_mul hd.2 (abs_shapeGradient_le η) (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 1) |
| 844 | - _ ≤ _ := by nlinarith [abs_nonneg η, mul_le_mul_of_nonneg_right hh1 (abs_nonneg η)] | |
| 844 | + _ ≤ _ := by linarith [abs_nonneg η, mul_le_mul_of_nonneg_right hh1 (abs_nonneg η)] | |
| 845 | 845 | |
| 846 | 846 | theorem pressureAxialLag_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / 100) |
| 847 | 847 | (hy : 0 ≤ y) (hy' : y ≤ v.core.dropLength + 1) (hη : |η| ≤ 1) : |
| @@ -855,7 +855,7 @@ theorem pressureAxialLag_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / 10 | ||
| 855 | 855 | have hp := actual_pressure_bounds v hy hend hη |
| 856 | 856 | have hd : 0 ≤ d η ∧ d η ≤ 1 := by |
| 857 | 857 | unfold d |
| 858 | - constructor <;> nlinarith [parameter_square_le_one hη, sq_nonneg η] | |
| 858 | + constructor <;> linarith [parameter_square_le_one hη, sq_nonneg η] | |
| 859 | 859 | have hA : 0 ≤ 4 * A v.h ∧ 4 * A v.h ≤ 3 := by |
| 860 | 860 | unfold A |
| 861 | 861 | constructor <;> linarith [v.h_pos] |
| @@ -902,13 +902,13 @@ theorem axialLag_drop_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / 100) | ||
| 902 | 902 | have hmul := mul_le_mul_of_nonneg_right hP' (Real.exp_pos (-y)).le |
| 903 | 903 | rw [he] at hmul |
| 904 | 904 | have hlow := angular_square_lower v.core hy hy' hη |
| 905 | - nlinarith | |
| 905 | + linarith | |
| 906 | 906 | have hg := geometricAxialLag_bound v.core v.h_pos.le hh1 hy hη |
| 907 | 907 | have hp := pressureAxialLag_bound v hh1 hy hy' hη |
| 908 | 908 | have hg' : |geometricAxialLag v.core v.h y η| ≤ |
| 909 | 909 | 256 * |η| * angular v.core.P v.core.dropLength v.core.lam (y, η) ^ 2 := by |
| 910 | 910 | apply hg.trans |
| 911 | - nlinarith [mul_le_mul_of_nonneg_left hEp (show 0 ≤ 256 * |η| by positivity)] | |
| 911 | + linarith [mul_le_mul_of_nonneg_left hEp (show 0 ≤ 256 * |η| by positivity)] | |
| 912 | 912 | unfold axialLag |
| 913 | 913 | apply (abs_add_le _ _).trans |
| 914 | 914 | apply (add_le_add hg' hp).trans |
| @@ -917,7 +917,7 @@ theorem axialLag_drop_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / 100) | ||
| 917 | 917 | angular v.core.P v.core.dropLength v.core.lam (y, η) ^ 2 := by |
| 918 | 918 | have := pressureBound_pos |
| 919 | 919 | positivity |
| 920 | - nlinarith | |
| 920 | + linarith | |
| 921 | 921 | |
| 922 | 922 | /-! ## The two small shear quantities in the cone test -/ |
| 923 | 923 | |
| @@ -952,7 +952,7 @@ theorem angular_square_ge_quarter (c : Parameters) {y η : ℝ} (hy : 0 ≤ y) | ||
| 952 | 952 | have hm := mul_le_mul_of_nonneg_right hP' (Real.exp_pos (-y)).le |
| 953 | 953 | rw [he] at hm |
| 954 | 954 | have hlow := angular_square_lower c hy hy' hη |
| 955 | - nlinarith | |
| 955 | + linarith | |
| 956 | 956 | |
| 957 | 957 | theorem shear_drop_abs (c : Parameters) {y η : ℝ} (hy : 1 ≤ y) |
| 958 | 958 | (hy' : y ≤ c.dropLength + 1) (hη : |η| ≤ 1) |
| @@ -972,7 +972,7 @@ theorem shear_drop_abs (c : Parameters) {y η : ℝ} (hy : 1 ≤ y) | ||
| 972 | 972 | have hprod := mul_le_mul hd' hη (abs_nonneg η) (dropSpeed_pos c.m_pos).le |
| 973 | 973 | have hden := mul_le_mul_of_nonneg_left hhalf |
| 974 | 974 | (mul_nonneg (by norm_num : (0 : ℝ) ≤ 4) (dropSpeed_pos c.m_pos).le) |
| 975 | - nlinarith | |
| 975 | + linarith | |
| 976 | 976 | |
| 977 | 977 | theorem shear_drop_square (c : Parameters) {y η : ℝ} (hy : 1 ≤ y) |
| 978 | 978 | (hy' : y ≤ c.dropLength + 1) (hη : |η| ≤ 1) |
| @@ -990,7 +990,7 @@ theorem shear_direction_identity (v : TailData) (y η : ℝ) | ||
| 990 | 990 | have hE := angular_pos v.core.P_pos v.core.dropLength v.core.lam (y, η) |
| 991 | 991 | simp only [shear, directionRatio, abs_mul, abs_div, abs_of_pos hE, abs_of_pos hQ] |
| 992 | 992 | norm_num |
| 993 | - simp only [div_eq_mul_inv, mul_inv_rev, pow_two] | |
| 993 | + simp only [div_eq_mul_inv, pow_two] | |
| 994 | 994 | ring |
| 995 | 995 | |
| 996 | 996 | theorem shear_direction_drop_bound (v : TailData) {y η : ℝ} |
| @@ -1005,7 +1005,7 @@ theorem shear_direction_drop_bound (v : TailData) {y η : ℝ} | ||
| 1005 | 1005 | have hQ := angularLag_pos v.core v.h_pos.le hh1 hy0.le hyT hη hhT |
| 1006 | 1006 | have hQb := angularLag_lower v.core v.h_pos.le hh1 hy0.le hyT hη hhT |
| 1007 | 1007 | have hQη : coneFloor * η ^ 2 ≤ angularLag v.core v.h η y := by |
| 1008 | - nlinarith [mul_pos coneFloor_pos (Real.exp_pos (-y))] | |
| 1008 | + linarith [mul_pos coneFloor_pos (Real.exp_pos (-y))] | |
| 1009 | 1009 | have hd := dropCoefficient_deriv_bound v.core.m_pos hy0 |
| 1010 | 1010 | have hdy : |deriv (dropCoefficient v.core.m) y| * (1 + y) ≤ 2 * dropSpeed v.core.m := by |
| 1011 | 1011 | have hmul := (le_div_iff₀ hy0).mp hd |
| @@ -1064,13 +1064,13 @@ theorem drop_cone_margins (v : TailData) {y η : ℝ} | ||
| 1064 | 1064 | have hmul := (le_div_iff₀ (mul_pos (by norm_num) axialBound_pos)).mp he2 |
| 1065 | 1065 | calc |
| 1066 | 1066 | _ = 4 * axialBound * dropSpeed v.core.m / coneFloor := by ring |
| 1067 | - _ ≤ 1 / 4 := (div_le_iff₀ coneFloor_pos).mpr (by nlinarith) | |
| 1067 | + _ ≤ 1 / 4 := (div_le_iff₀ coneFloor_pos).mpr (by linarith) | |
| 1068 | 1068 | exact (le_abs_self _).trans (hsw.trans hc) |
| 1069 | 1069 | have hsq' : shear v.core y η ^ 2 ≤ 1 / 4 := by |
| 1070 | 1070 | have he0 := (dropSpeed_pos v.core.m_pos).le |
| 1071 | 1071 | nlinarith |
| 1072 | 1072 | rw [radialA_drop v.core hy hy'] |
| 1073 | - constructor <;> nlinarith | |
| 1073 | + constructor <;> linarith | |
| 1074 | 1074 | |
| 1075 | 1075 | theorem linearLag_pos_after {r b : ℝ → ℝ} (hr : Continuous r) (hb : Continuous b) |
| 1076 | 1076 | {q₀ a y : ℝ} (hay : a ≤ y) (ha : 0 < linearLag r b q₀ a) |
| @@ -1102,7 +1102,7 @@ theorem angularSource_hold_lower (v : TailData) {y η : ℝ} | ||
| 1102 | 1102 | have hJ : 0 ≤ η * shapeGradient η := (sq_nonneg η).trans (eta_shapeGradient_bounds hη).1 |
| 1103 | 1103 | rw [angularSource, hl, hk] |
| 1104 | 1104 | simp only [mul_zero, add_zero, neg_neg] |
| 1105 | - nlinarith [mul_le_mul_of_nonneg_left hW v.core.lam_pos.le, mul_nonneg hD hJ] | |
| 1105 | + linarith [mul_le_mul_of_nonneg_left hW v.core.lam_pos.le, mul_nonneg hD hJ] | |
| 1106 | 1106 | |
| 1107 | 1107 | /-- Positive incoming angular lag at every point of the unedited shaped hold. -/ |
| 1108 | 1108 | theorem angularLag_pos_on_hold (v : TailData) {y η : ℝ} |
| @@ -1130,7 +1130,7 @@ theorem shape_interval {η : ℝ} (hη : |η| ≤ 1) : (1 / 2 : ℝ) ≤ shape | ||
| 1130 | 1130 | constructor |
| 1131 | 1131 | · apply (le_div_iff₀ (by positivity : 0 < 1 + η ^ 2)).mpr |
| 1132 | 1132 | linarith |
| 1133 | - · exact div_le_self (by norm_num) (by nlinarith [sq_nonneg η]) | |
| 1133 | + · exact div_le_self (by norm_num) (by linarith [sq_nonneg η]) | |
| 1134 | 1134 | |
| 1135 | 1135 | noncomputable def entranceTime (m : ℝ) : ℝ := Real.exp m + 12 |
| 1136 | 1136 | |
| @@ -1165,7 +1165,7 @@ theorem averagedEnergy_le_envelope (c : Parameters) {y T η : ℝ} (hy : 0 ≤ y | ||
| 1165 | 1165 | have he : 1 ≤ Real.exp (2 * T) := Real.one_le_exp_iff.mpr (by linarith) |
| 1166 | 1166 | have hinit : (5 / 6 : ℝ) * c.P ^ 2 ≤ energyEnvelope c.P T := by |
| 1167 | 1167 | unfold energyEnvelope |
| 1168 | - nlinarith [sq_nonneg c.P, mul_le_mul_of_nonneg_left he (sq_nonneg c.P)] | |
| 1168 | + linarith [sq_nonneg c.P, mul_le_mul_of_nonneg_left he (sq_nonneg c.P)] | |
| 1169 | 1169 | have hb := historyAverage_le (clockEnergy_contDiff c).continuous hinit hy |
| 1170 | 1170 | (fun t ht => clockEnergy_le_envelope c ht.1 (ht.2.trans hyT)) |
| 1171 | 1171 | have hs := shape_interval hη |
| @@ -1196,7 +1196,7 @@ theorem pressureAxialLag_le_envelope (v : TailData) {y T η : ℝ} (hh1 : v.h | ||
| 1196 | 1196 | have hC := pressureBound_pos.le |
| 1197 | 1197 | have hd : 0 ≤ d η ∧ d η ≤ 1 := by |
| 1198 | 1198 | unfold d |
| 1199 | - constructor <;> nlinarith [parameter_square_le_one hη, sq_nonneg η] | |
| 1199 | + constructor <;> linarith [parameter_square_le_one hη, sq_nonneg η] | |
| 1200 | 1200 | have hA : 0 ≤ 4 * A v.h ∧ 4 * A v.h ≤ 3 := by |
| 1201 | 1201 | unfold A |
| 1202 | 1202 | constructor <;> linarith [v.h_pos] |
| @@ -1236,7 +1236,7 @@ theorem axialLag_le_envelope (v : TailData) {y T η : ℝ} (hh1 : v.h ≤ 1 / 10 | ||
| 1236 | 1236 | have hsum := add_le_add hg hp |
| 1237 | 1237 | have hg1 := mul_le_mul_of_nonneg_left hη (by norm_num : (0 : ℝ) ≤ 64) |
| 1238 | 1238 | have hp1 := mul_le_mul_of_nonneg_left hη hK |
| 1239 | - nlinarith | |
| 1239 | + linarith | |
| 1240 | 1240 | |
| 1241 | 1241 | noncomputable def entranceRatioBound (P m : ℝ) : ℝ := |
| 1242 | 1242 | (64 + (3 + 4 * pressureBound) * energyEnvelope P (entranceTime m)) / |
| @@ -1258,7 +1258,7 @@ theorem directionRatio_entrance_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ | ||
| 1258 | 1258 | have hQ := angularLag_lower v.core v.h_pos.le hh1 hy hyT hη hhT |
| 1259 | 1259 | have hQ' : coneFloor * Real.exp (-v.core.holdStart) ≤ angularLag v.core v.h η y := by |
| 1260 | 1260 | have he := mul_le_mul_of_nonneg_left (Real.exp_le_exp.mpr (neg_le_neg hyT)) coneFloor_pos.le |
| 1261 | - nlinarith [mul_nonneg coneFloor_pos.le (sq_nonneg η)] | |
| 1261 | + linarith [mul_nonneg coneFloor_pos.le (sq_nonneg η)] | |
| 1262 | 1262 | have hden := mul_le_mul hE hQ' (mul_pos coneFloor_pos (Real.exp_pos _)).le |
| 1263 | 1263 | (angular_pos v.core.P_pos v.core.dropLength v.core.lam (y, η)).le |
| 1264 | 1264 | have hlo : 0 < (v.core.P * Real.exp (-v.core.holdStart) / 2) * |
| @@ -1505,8 +1505,7 @@ theorem canonical_Ns_before {v : TailData} {K : ℝ} | ||
| 1505 | 1505 | OutgoingHistories.U_before_pulse v Amp η hy, canonical_M_before v Amp hy, |
| 1506 | 1506 | hMd, congrFun hS η, hSd, canonical_Pi_before w hyend, hPd, |
| 1507 | 1507 | axialLag_integrated_history] |
| 1508 | - simp only [OutgoingHistories.X, StressAlgebra.axialExponent, | |
| 1509 | - StressAlgebra.coordinateFactor, StressAlgebra.velocityExponent, d, A] | |
| 1508 | + simp only [OutgoingHistories.X, StressAlgebra.coordinateFactor, StressAlgebra.velocityExponent, d, A] | |
| 1510 | 1509 | field_simp [(Real.exp_pos y).ne'] ; ring |
| 1511 | 1510 | |
| 1512 | 1511 | /-! ## The first and last preliminary ramps -/ |
| @@ -1583,7 +1582,7 @@ theorem second_ramp_cone_margins (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / | ||
| 1583 | 1582 | refine ⟨ha, ?_⟩ |
| 1584 | 1583 | have hmul := mul_le_mul (show radialA v.core y - 2 ≤ 2 * v.core.lam by linarith) |
| 1585 | 1584 | hw2 (sq_nonneg _) (by linarith [v.core.lam_pos]) |
| 1586 | - nlinarith | |
| 1585 | + linarith | |
| 1587 | 1586 | |
| 1588 | 1587 | /-! ## Uniform pressure-source estimates -/ |
| 1589 | 1588 | |
| @@ -1627,7 +1626,7 @@ theorem pressureAxialSource_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / | ||
| 1627 | 1626 | have hp := actual_pressure_bounds v hy hyend hη |
| 1628 | 1627 | have hd : 0 ≤ d η ∧ d η ≤ 1 := by |
| 1629 | 1628 | unfold d |
| 1630 | - constructor <;> nlinarith [sq_nonneg η, parameter_square_le_one hη] | |
| 1629 | + constructor <;> linarith [sq_nonneg η, parameter_square_le_one hη] | |
| 1631 | 1630 | have hA : 0 ≤ 4 * A v.h ∧ 4 * A v.h ≤ 3 := by |
| 1632 | 1631 | unfold A |
| 1633 | 1632 | constructor <;> linarith [v.h_pos] |
| @@ -1640,7 +1639,7 @@ theorem pressureAxialSource_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / | ||
| 1640 | 1639 | rw [abs_mul, abs_mul, abs_of_nonneg hA.1] |
| 1641 | 1640 | have hb := mul_le_mul (mul_le_mul_of_nonneg_right hA.2 (abs_nonneg η)) hp.1 |
| 1642 | 1641 | (abs_nonneg _) (by positivity : 0 ≤ 3 * |η|) |
| 1643 | - nlinarith | |
| 1642 | + linarith | |
| 1644 | 1643 | have hthird : |η * angular v.core.P v.core.dropLength v.core.lam (y, η) ^ 2| = |
| 1645 | 1644 | |η| * angular v.core.P v.core.dropLength v.core.lam (y, η) ^ 2 := by |
| 1646 | 1645 | simp only [abs_mul, abs_pow, sq_abs] |
| @@ -1653,7 +1652,7 @@ theorem pressureAxialSource_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / | ||
| 1653 | 1652 | rw [hthird] at hs |
| 1654 | 1653 | unfold pressureSourceBound |
| 1655 | 1654 | have hn := mul_nonneg (abs_nonneg η) (sq_nonneg (angular v.core.P v.core.dropLength v.core.lam (y, η))) |
| 1656 | - nlinarith [mul_nonneg pressureBound_pos.le hn] | |
| 1655 | + linarith [mul_nonneg pressureBound_pos.le hn] | |
| 1657 | 1656 | |
| 1658 | 1657 | theorem pressureAxialSource_deriv_bound (v : TailData) {y η : ℝ} (hh1 : v.h ≤ 1 / 100) |
| 1659 | 1658 | (hy : 0 ≤ y) (hyend : y ≤ v.core.endpoint) (hη : |η| ≤ 1) : |
| @@ -1763,7 +1762,7 @@ theorem chosen_parameters_bounds (v : TailData) | ||
| 1763 | 1762 | have hl : v.core.lam ≤ 1 / (4 * (entranceRatioBound v.core.P v.core.m ^ 2 + 1)) := |
| 1764 | 1763 | hlam.trans (min_le_right _ _) |
| 1765 | 1764 | have hl' := (le_div_iff₀ (show 0 < 4 * (entranceRatioBound v.core.P v.core.m ^ 2 + 1) by positivity)).mp hl |
| 1766 | - refine ⟨hp', (by nlinarith [v.core.lam_pos]), hh.trans (min_le_left _ _), ?_⟩ | |
| 1765 | + refine ⟨hp', (by linarith [v.core.lam_pos]), hh.trans (min_le_left _ _), ?_⟩ | |
| 1767 | 1766 | rw [holdStart_eq_entranceTime] |
| 1768 | 1767 | exact hh.trans ((min_le_right _ _).trans (min_le_right _ _)) |
| 1769 | 1768 | |
| @@ -1913,7 +1912,7 @@ theorem actual_ideal_cone_margins {v : TailData} {K : ℝ} | ||
| 1913 | 1912 | rw [coneB_before w ha hpulse, shear_early v.core (by linarith)] |
| 1914 | 1913 | rw [hA, hB] |
| 1915 | 1914 | norm_num |
| 1916 | - nlinarith [sq_nonneg (coneRatio w Amp (y, η))] | |
| 1915 | + linarith [sq_nonneg (coneRatio w Amp (y, η))] | |
| 1917 | 1916 | |
| 1918 | 1917 | /-- The radial normal coefficient agrees with the logarithmic derivative of |
| 1919 | 1918 | the true angular field `E`, rather than a declared slope proxy. -/ |
+16 −16 NavierStokes/OutgoingPulseBounds.lean View file
| @@ -29,7 +29,7 @@ theorem slope_bounds (c : Parameters) (y : ℝ) : | ||
| 29 | 29 | have ha := mul_nonneg c.lam_pos.le h2 |
| 30 | 30 | have hb := mul_nonneg c.lam_pos.le (sub_nonneg.mpr h3) |
| 31 | 31 | dsimp [OutgoingSchedule.slope] |
| 32 | - constructor <;> nlinarith | |
| 32 | + constructor <;> linarith | |
| 33 | 33 | |
| 34 | 34 | theorem logAmplitude_bounds (c : Parameters) {y : ℝ} (hy : 0 ≤ y) : |
| 35 | 35 | -y ≤ logAmplitude c.dropLength c.lam y ∧ |
| @@ -125,7 +125,7 @@ theorem prefixM_bounds (c : Parameters) : | ||
| 125 | 125 | (dropCoefficient_bounds c.m y).1 (Real.exp_pos _).le |
| 126 | 126 | _ = _ := by ring) |
| 127 | 127 | simp only [intervalIntegral.integral_const, sub_zero, smul_eq_mul] at hup |
| 128 | - constructor <;> nlinarith | |
| 128 | + constructor <;> linarith | |
| 129 | 129 | |
| 130 | 130 | theorem prefixJ_bounds (c : Parameters) : |
| 131 | 131 | 0 ≤ prefixJ c ∧ |
| @@ -171,7 +171,7 @@ theorem prefixJ_bounds (c : Parameters) : | ||
| 171 | 171 | · have hP := c.P_pos |
| 172 | 172 | exact add_nonneg (by positivity) hpos |
| 173 | 173 | · dsimp [K] at hup |
| 174 | - nlinarith | |
| 174 | + linarith | |
| 175 | 175 | |
| 176 | 176 | /-! ## Decay along the explicitly timed shaped wait -/ |
| 177 | 177 | |
| @@ -279,7 +279,7 @@ theorem wait_decay (c : Parameters) (hwait : c.wait = 60 * Real.log (1 / c.lam)) | ||
| 279 | 279 | apply Real.exp_le_exp.mpr |
| 280 | 280 | rw [hwait] |
| 281 | 281 | have h := mul_le_mul_of_nonneg_right (beta_small_bounds c hsmall i).2 hlog |
| 282 | - nlinarith | |
| 282 | + linarith | |
| 283 | 283 | |
| 284 | 284 | theorem pulseAmplitude_small (c : Parameters) |
| 285 | 285 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) : |
| @@ -293,7 +293,7 @@ theorem pulseAmplitude_small (c : Parameters) | ||
| 293 | 293 | apply Real.exp_le_exp.mpr |
| 294 | 294 | have hprod := mul_nonneg c.lam_pos.le hw |
| 295 | 295 | rw [hwait] at hprod ⊢ |
| 296 | - nlinarith | |
| 296 | + linarith | |
| 297 | 297 | have h := mul_le_mul hhold hdec (Real.exp_pos _).le |
| 298 | 298 | (mul_nonneg c.P_pos.le (Real.exp_pos _).le) |
| 299 | 299 | convert! h using 1 ; dsimp [Parameters.holdStart, Parameters.dropLength] ; congr 2 ; ring_nf |
| @@ -375,7 +375,7 @@ theorem parameterPolynomial_derivative_bound {eta : ℝ} (heta : |eta| ≤ 1) : | ||
| 375 | 375 | have hs : eta ^ 2 ≤ 1 := by |
| 376 | 376 | have h := sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta |
| 377 | 377 | simpa using h |
| 378 | - nlinarith | |
| 378 | + linarith | |
| 379 | 379 | |
| 380 | 380 | theorem normalized_mass_prefix (c : Parameters) (amp : ℝ → ℝ) (eta : ℝ) : |
| 381 | 381 | massMoment c amp eta c.pulseStart / |
| @@ -612,15 +612,15 @@ theorem two_row_solution_bound {k lam A0 A1 r0 r1 x0 x1 d0 d1 : ℝ} | ||
| 612 | 612 | lam * |x1| ≤ ((1 + Real.exp 1) / k) * (|d0| + |d1|) := by |
| 613 | 613 | have hA0p := hk.trans_le hA0 |
| 614 | 614 | have hA1p := hk.trans_le hA1 |
| 615 | - have h0' : x0 + r0 * x1 = d0 / A0 := (eq_div_iff hA0p.ne').mpr (by nlinarith [h0]) | |
| 616 | - have h1' : x0 + r1 * x1 = d1 / A1 := (eq_div_iff hA1p.ne').mpr (by nlinarith [h1]) | |
| 615 | + have h0' : x0 + r0 * x1 = d0 / A0 := (eq_div_iff hA0p.ne').mpr (by linarith [h0]) | |
| 616 | + have h1' : x0 + r1 * x1 = d1 / A1 := (eq_div_iff hA1p.ne').mpr (by linarith [h1]) | |
| 617 | 617 | have ha0 : |d0 / A0| ≤ |d0| / k := by |
| 618 | 618 | rw [abs_div, abs_of_pos hA0p] |
| 619 | 619 | exact div_le_div_of_nonneg_left (abs_nonneg _) hk hA0 |
| 620 | 620 | have ha1 : |d1 / A1| ≤ |d1| / k := by |
| 621 | 621 | rw [abs_div, abs_of_pos hA1p] |
| 622 | 622 | exact div_le_div_of_nonneg_left (abs_nonneg _) hk hA1 |
| 623 | - have hdx : (r0 - r1) * x1 = d0 / A0 - d1 / A1 := by nlinarith [h0', h1'] | |
| 623 | + have hdx : (r0 - r1) * x1 = d0 / A0 - d1 / A1 := by linarith [h0', h1'] | |
| 624 | 624 | have hdiff := abs_sub (d0 / A0) (d1 / A1) |
| 625 | 625 | rw [← hdx, abs_mul, abs_of_pos (hlam.trans_le hgap)] at hdiff |
| 626 | 626 | have hx1 : lam * |x1| ≤ (|d0| + |d1|) / k := by |
| @@ -644,7 +644,7 @@ theorem two_row_solution_bound {k lam A0 A1 r0 r1 x0 x1 d0 d1 : ℝ} | ||
| 644 | 644 | have hid : ((1 + Real.exp 1) / k) * (|d0| + |d1|) = |
| 645 | 645 | (|d0| + |d1|) / k + Real.exp 1 * ((|d0| + |d1|) / k) := by ring |
| 646 | 646 | constructor <;> rw [hid] |
| 647 | - · nlinarith | |
| 647 | + · linarith | |
| 648 | 648 | · nlinarith |
| 649 | 649 | |
| 650 | 650 | theorem normalized_solution_bound (c : Parameters) (x d : Fin 2 → ℝ) |
| @@ -660,9 +660,9 @@ theorem normalized_solution_bound (c : Parameters) (x d : Fin 2 → ℝ) | ||
| 660 | 660 | (show c.lam ≤ Real.exp (2 * beta c 0) - Real.exp (2 * beta c 1) by |
| 661 | 661 | linarith [separation_exponential_gap c, c.lam_pos]) |
| 662 | 662 | (show rowMoment (c.exponents 0) * (x 0 + Real.exp (2 * beta c 0) * x 1) = d 0 by |
| 663 | - nlinarith [h0]) | |
| 663 | + linarith [h0]) | |
| 664 | 664 | (show rowMoment (c.exponents 1) * (x 0 + Real.exp (2 * beta c 1) * x 1) = d 1 by |
| 665 | - nlinarith [h1]) | |
| 665 | + linarith [h1]) | |
| 666 | 666 | fin_cases j |
| 667 | 667 | · exact hb.1 |
| 668 | 668 | · exact hb.2 |
| @@ -738,7 +738,7 @@ theorem mainMoment_log_short (c : Parameters) (i : Fin 2) : | ||
| 738 | 738 | intro y hy |
| 739 | 739 | have hp : 11 ≤ c.lam * y := by |
| 740 | 740 | have h := (div_le_iff₀ c.lam_pos).mp hy |
| 741 | - nlinarith | |
| 741 | + linarith | |
| 742 | 742 | simp only [Pi.mul_apply, Function.comp_apply, id_eq] |
| 743 | 743 | rw [mainPulse_zero_right hp, mul_zero] |
| 744 | 744 | |
| @@ -747,7 +747,7 @@ theorem center_gap_bound (c : Parameters) (hsmall : c.lam ≤ 1 / 120) (i : Fin | ||
| 747 | 747 | have hb := (beta_small_bounds c hsmall i).1 |
| 748 | 748 | have hp : 0 ≤ 2 - 3 * c.lam := by linarith [c.lam_pos] |
| 749 | 749 | have hm := mul_le_mul_of_nonneg_right hb hp |
| 750 | - have hnum : (1 / 2 : ℝ) ≤ beta c i * (2 - 3 * c.lam) := by nlinarith | |
| 750 | + have hnum : (1 / 2 : ℝ) ≤ beta c i * (2 - 3 * c.lam) := by linarith | |
| 751 | 751 | have hdiv := div_le_div_of_nonneg_right hnum c.lam_pos.le |
| 752 | 752 | have he : beta c i * (center c 0 - 11 / c.lam) = |
| 753 | 753 | (beta c i * (2 - 3 * c.lam)) / c.lam := by |
| @@ -808,7 +808,7 @@ theorem normalized_prefixCoefficient_bound (c : Parameters) (hsmall : c.lam ≤ | ||
| 808 | 808 | mul_nonneg (beta_bounds c i).1.le (div_nonneg (by norm_num) c.lam_pos.le) |
| 809 | 809 | have he : Real.exp (-(beta c i * center c 0)) ≤ Real.exp (-(1 / (2 * c.lam))) := by |
| 810 | 810 | apply Real.exp_le_exp.mpr |
| 811 | - nlinarith | |
| 811 | + linarith | |
| 812 | 812 | rw [abs_mul, abs_of_pos (Real.exp_pos _)] |
| 813 | 813 | calc |
| 814 | 814 | _ ≤ Real.exp (-(1 / (2 * c.lam))) * prefixBound c.P c.m i := |
| @@ -879,7 +879,7 @@ theorem inverse_square_exp_absorption {lam : ℝ} (hlam : 0 < lam) : | ||
| 879 | 879 | norm_num only [Nat.cast_ofNat] at hsq |
| 880 | 880 | rw [ht', he'] at hsq |
| 881 | 881 | have h := (div_le_iff₀ (by positivity : 0 < 64 * lam ^ 2)).mp hsq |
| 882 | - nlinarith | |
| 882 | + linarith | |
| 883 | 883 | have hprod := mul_le_mul_of_nonneg_right hfac (Real.exp_pos (-(1 / (2 * lam)))).le |
| 884 | 884 | have hsum : 1 / (4 * lam) + -(1 / (2 * lam)) = -(1 / (4 * lam)) := by ring |
| 885 | 885 | calc |
+4 −4 NavierStokes/OutgoingSchedule.lean View file
| @@ -73,7 +73,7 @@ theorem sigma_monotone : Monotone sigma := by | ||
| 73 | 73 | have ha := edge_monotone hxy |
| 74 | 74 | have hb := edge_monotone (show 1 - y ≤ 1 - x by linarith) |
| 75 | 75 | have hcross := mul_le_mul ha hb (FlatCutoff.edge_nonneg 1 _) (FlatCutoff.edge_nonneg 1 _) |
| 76 | - nlinarith | |
| 76 | + linarith | |
| 77 | 77 | |
| 78 | 78 | /-! ## Smooth primitives and the single global slope -/ |
| 79 | 79 | |
| @@ -354,7 +354,7 @@ theorem intervals_separated (c : Parameters) (i j : Fin 2) (hij : i < j) : | ||
| 354 | 354 | theorem one_lt_lower (c : Parameters) (i : Fin 2) : 1 < c.lower i := by |
| 355 | 355 | have hL : 4 < c.pulseLength := by |
| 356 | 356 | apply (lt_div_iff₀ c.lam_pos).mpr |
| 357 | - nlinarith [c.lam_lt] | |
| 357 | + linarith [c.lam_lt] | |
| 358 | 358 | change 1 < Real.exp _ |
| 359 | 359 | rw [← Real.exp_zero] |
| 360 | 360 | apply Real.exp_lt_exp.mpr |
| @@ -368,7 +368,7 @@ theorem upper_lt_end (c : Parameters) (i : Fin 2) : | ||
| 368 | 368 | theorem main_end_lt_lower (c : Parameters) (i : Fin 2) : |
| 369 | 369 | Real.exp (11 / c.lam) < c.lower i := by |
| 370 | 370 | apply Real.exp_lt_exp.mpr |
| 371 | - have hgap : (63 / 20 : ℝ) * c.lam < 2 := by nlinarith [c.lam_lt] | |
| 371 | + have hgap : (63 / 20 : ℝ) * c.lam < 2 := by linarith [c.lam_lt] | |
| 372 | 372 | have hgap' := (lt_div_iff₀ c.lam_pos).mpr hgap |
| 373 | 373 | have hid : 13 / c.lam - 11 / c.lam = 2 / c.lam := by ring |
| 374 | 374 | dsimp [lower, pulseLength] |
| @@ -488,7 +488,7 @@ theorem pulseRatio_zero_late (c : Parameters) (amp : ℝ → ℝ) (eta : ℝ) {y | ||
| 488 | 488 | (hy : c.pulseLength ≤ y) : pulseRatio c amp (y, eta) = 0 := by |
| 489 | 489 | have h13 : 13 ≤ c.lam * y := by |
| 490 | 490 | have h := (div_le_iff₀ c.lam_pos).mp hy |
| 491 | - nlinarith | |
| 491 | + linarith | |
| 492 | 492 | simp only [pulseRatio] |
| 493 | 493 | rw [mainPulse_zero_right (by linarith : 11 ≤ c.lam * y), |
| 494 | 494 | correction_zero_late c amp eta hy] |
+20 −20 NavierStokes/OutgoingTail.lean View file
| @@ -61,7 +61,7 @@ theorem exists_sigma_derivative_bound : | ||
| 61 | 61 | (sigma_contDiff.continuous_deriv (by simp)).continuousOn |
| 62 | 62 | refine ⟨max C 1, le_max_right _ _, fun x => ?_⟩ |
| 63 | 63 | by_cases hx : x ∈ Icc (0 : ℝ) 1 |
| 64 | - · exact (le_abs_self _).trans ((by simpa using hC x hx : |deriv sigma x| ≤ C).trans | |
| 64 | + · exact (le_abs_self _).trans ((hC x hx : |deriv sigma x| ≤ C).trans | |
| 65 | 65 | (le_max_left _ _)) |
| 66 | 66 | · have hx' : x < 0 ∨ 1 < x := by simpa only [mem_Icc, not_and_or, not_le] using hx |
| 67 | 67 | rcases hx' with hx' | hx' |
| @@ -89,12 +89,12 @@ def tailCoefficient : ℝ := Real.exp (-5) / (16 * (stepBound + 1)) | ||
| 89 | 89 | |
| 90 | 90 | theorem tailCoefficient_pos : 0 < tailCoefficient := by |
| 91 | 91 | apply div_pos (Real.exp_pos _) |
| 92 | - nlinarith [stepBound_ge_one] | |
| 92 | + linarith [stepBound_ge_one] | |
| 93 | 93 | |
| 94 | 94 | theorem tailCoefficient_le : tailCoefficient ≤ Real.exp (-5) / 16 := by |
| 95 | 95 | unfold tailCoefficient |
| 96 | 96 | apply div_le_div_of_nonneg_left (Real.exp_pos _).le (by norm_num) |
| 97 | - nlinarith [stepBound_ge_one] | |
| 97 | + linarith [stepBound_ge_one] | |
| 98 | 98 | |
| 99 | 99 | theorem tailCoefficient_lt_one : tailCoefficient < 1 := by |
| 100 | 100 | have he : Real.exp (-5 : ℝ) ≤ 1 := Real.exp_le_one_iff.mpr (by norm_num) |
| @@ -235,7 +235,7 @@ theorem tailDebt_bounds (d : TailData) : | ||
| 235 | 235 | exact mul_le_mul_of_nonneg_right he (tailShapeDeriv_nonneg d t) |
| 236 | 236 | · have he : 1 ≤ Real.exp ((1 - d.h) * t) := |
| 237 | 237 | Real.one_le_exp_iff.mpr (mul_nonneg d.one_sub_h_pos.le ht.1) |
| 238 | - nlinarith [mul_le_mul_of_nonneg_right he (tailShapeDeriv_nonneg d t)] | |
| 238 | + linarith [mul_le_mul_of_nonneg_right he (tailShapeDeriv_nonneg d t)] | |
| 239 | 239 | |
| 240 | 240 | theorem tailDebt_pos (d : TailData) : 0 < tailDebt d := |
| 241 | 241 | (div_pos d.rho_pos (by linarith [d.rho_lt_half])).trans_le (tailDebt_bounds d).1 |
| @@ -245,7 +245,7 @@ theorem tailDebt_small (d : TailData) : tailDebt d < Real.exp (-2) * d.h := by | ||
| 245 | 245 | have hp : 0 ≤ Real.exp 3 * d.rho := mul_nonneg (Real.exp_pos _).le d.rho_pos.le |
| 246 | 246 | have hdiv : Real.exp 3 * d.rho / (1 - d.rho) ≤ 2 * Real.exp 3 * d.rho := by |
| 247 | 247 | apply (div_le_iff₀ hden).mpr |
| 248 | - nlinarith [mul_nonneg hp (show 0 ≤ 1 - 2 * d.rho by linarith [d.rho_lt_half])] | |
| 248 | + linarith [mul_nonneg hp (show 0 ≤ 1 - 2 * d.rho by linarith [d.rho_lt_half])] | |
| 249 | 249 | have hr : d.rho ≤ (Real.exp (-5) / 16) * d.h := |
| 250 | 250 | mul_le_mul_of_nonneg_right tailCoefficient_le d.h_pos.le |
| 251 | 251 | have hb : tailDebt d ≤ Real.exp (-2) * d.h / 8 := by |
| @@ -256,7 +256,7 @@ theorem tailDebt_small (d : TailData) : tailDebt d < Real.exp (-2) * d.h := by | ||
| 256 | 256 | mul_le_mul_of_nonneg_left hr (by positivity) |
| 257 | 257 | _ = (Real.exp 3 * Real.exp (-5)) * d.h / 8 := by ring |
| 258 | 258 | _ = Real.exp (-2) * d.h / 8 := by rw [← Real.exp_add]; norm_num |
| 259 | - exact hb.trans_lt (by nlinarith [mul_pos (Real.exp_pos (-2)) d.h_pos]) | |
| 259 | + exact hb.trans_lt (by linarith [mul_pos (Real.exp_pos (-2)) d.h_pos]) | |
| 260 | 260 | |
| 261 | 261 | theorem tail_taper_log_derivative (d : TailData) (t : ℝ) : |
| 262 | 262 | 0 ≤ tailShapeDeriv d t / tailShape d t ∧ |
| @@ -265,20 +265,20 @@ theorem tail_taper_log_derivative (d : TailData) (t : ℝ) : | ||
| 265 | 265 | have hcoef : tailCoefficient * stepBound ≤ 1 / 16 := by |
| 266 | 266 | unfold tailCoefficient |
| 267 | 267 | rw [div_mul_eq_mul_div] |
| 268 | - apply (div_le_iff₀ (show 0 < 16 * (stepBound + 1) by nlinarith)).mpr | |
| 268 | + apply (div_le_iff₀ (show 0 < 16 * (stepBound + 1) by linarith)).mpr | |
| 269 | 269 | have he : Real.exp (-5 : ℝ) ≤ 1 := Real.exp_le_one_iff.mpr (by norm_num) |
| 270 | - nlinarith [mul_le_mul_of_nonneg_right he hS] | |
| 270 | + linarith [mul_le_mul_of_nonneg_right he hS] | |
| 271 | 271 | have hder : tailShapeDeriv d t ≤ d.rho / 2 * stepBound := |
| 272 | - mul_le_mul_of_nonneg_left (sigma_derivative_le _) (by exact div_nonneg d.rho_pos.le (by norm_num)) | |
| 272 | + mul_le_mul_of_nonneg_left (sigma_derivative_le _) (div_nonneg d.rho_pos.le (by norm_num)) | |
| 273 | 273 | have hrS : d.rho * stepBound ≤ d.h / 16 := by |
| 274 | 274 | have h := mul_le_mul_of_nonneg_right hcoef d.h_pos.le |
| 275 | 275 | unfold TailData.rho |
| 276 | - nlinarith | |
| 276 | + linarith | |
| 277 | 277 | have hhalf : 1 / 2 ≤ tailShape d t := by |
| 278 | 278 | linarith [(tailShape_bounds d t).1, d.rho_lt_half] |
| 279 | 279 | have hratio : tailShapeDeriv d t / tailShape d t ≤ d.rho * stepBound := by |
| 280 | 280 | apply (div_le_iff₀ (tailShape_pos d t)).mpr |
| 281 | - nlinarith [mul_le_mul_of_nonneg_left hhalf (mul_nonneg d.rho_pos.le hS)] | |
| 281 | + linarith [mul_le_mul_of_nonneg_left hhalf (mul_nonneg d.rho_pos.le hS)] | |
| 282 | 282 | exact ⟨div_nonneg (tailShapeDeriv_nonneg d t) (tailShape_pos d t).le, |
| 283 | 283 | hratio.trans_lt (by linarith [d.h_pos])⟩ |
| 284 | 284 | |
| @@ -329,7 +329,7 @@ theorem releaseSlope_bounds (d : TailData) (t : ℝ) : | ||
| 329 | 329 | have hba := mul_le_mul_of_nonneg_left hab hh |
| 330 | 330 | have hgap := mul_le_mul_of_nonneg_left ha1 (sub_nonneg.mpr d.h_lt_lam.le) |
| 331 | 331 | unfold releaseSlope |
| 332 | - constructor <;> nlinarith | |
| 332 | + constructor <;> linarith | |
| 333 | 333 | |
| 334 | 334 | def releaseRate (d : TailData) (t : ℝ) : ℝ := 1 + releaseSlope d t |
| 335 | 335 | def releaseSource (d : TailData) (t : ℝ) : ℝ := -releaseSlope d t - d.h |
| @@ -337,7 +337,7 @@ def initialLag (d : TailData) : ℝ := (d.core.lam - d.h) / (1 - d.core.lam) | ||
| 337 | 337 | |
| 338 | 338 | theorem initialLag_gt_h (d : TailData) : d.h < initialLag d := by |
| 339 | 339 | apply (lt_div_iff₀ (show 0 < 1 - d.core.lam by linarith [d.core.lam_lt])).mpr |
| 340 | - nlinarith [d.h_small, mul_pos d.h_pos d.core.lam_pos] | |
| 340 | + linarith [d.h_small, mul_pos d.h_pos d.core.lam_pos] | |
| 341 | 341 | |
| 342 | 342 | theorem releaseRate_contDiff (d : TailData) : ContDiff ℝ ∞ (releaseRate d) := |
| 343 | 343 | contDiff_const.add (releaseSlope_contDiff d) |
| @@ -369,7 +369,7 @@ theorem linearLag_hasDerivAt {a b : ℝ → ℝ} (ha : Continuous a) (hb : Conti | ||
| 369 | 369 | simp |
| 370 | 370 | convert! h using 1 |
| 371 | 371 | dsimp [linearLag] |
| 372 | - nlinarith [congrArg (fun v : ℝ => v * b t) he] | |
| 372 | + linarith [congrArg (fun v : ℝ => v * b t) he] | |
| 373 | 373 | |
| 374 | 374 | def releaseLag (d : TailData) : ℝ → ℝ := |
| 375 | 375 | linearLag (releaseRate d) (releaseSource d) (initialLag d) |
| @@ -682,7 +682,7 @@ theorem tailNumerator_hasDerivAt (d : TailData) (t : ℝ) : | ||
| 682 | 682 | convert! Real.exp_zero using 1 ; ring_nf |
| 683 | 683 | convert! h using 1 |
| 684 | 684 | dsimp [tailNumerator, weightedTailDerivative] |
| 685 | - nlinarith [congrArg (fun x : ℝ => x * tailShapeDeriv d t) he] | |
| 685 | + linarith [congrArg (fun x : ℝ => x * tailShapeDeriv d t) he] | |
| 686 | 686 | |
| 687 | 687 | theorem tailLag_hasDerivAt (d : TailData) (t : ℝ) : |
| 688 | 688 | HasDerivAt (tailLag d) |
| @@ -722,9 +722,9 @@ def flatteningSlope (d : TailData) (y eta : ℝ) : ℝ := | ||
| 722 | 722 | theorem flatteningSlope_bounds (d : TailData) (y eta : ℝ) (heta : eta ^ 2 ≤ 1) : |
| 723 | 723 | -d.core.lam - 1 / 10 ≤ flatteningSlope d y eta ∧ |
| 724 | 724 | flatteningSlope d y eta ≤ -d.core.lam := by |
| 725 | - have hJ0 : 0 ≤ logShape eta := Real.log_nonneg (by nlinarith [sq_nonneg eta]) | |
| 725 | + have hJ0 : 0 ≤ logShape eta := Real.log_nonneg (by linarith [sq_nonneg eta]) | |
| 726 | 726 | have hJ1 : logShape eta ≤ Real.log 2 := |
| 727 | - Real.log_le_log (by positivity) (by nlinarith) | |
| 727 | + Real.log_le_log (by positivity) (by linarith) | |
| 728 | 728 | have hD0 := sigma_derivative_nonneg ((y - d.core.endpoint) / flattenLength) |
| 729 | 729 | have hD1 := sigma_derivative_le ((y - d.core.endpoint) / flattenLength) |
| 730 | 730 | have hS : 0 ≤ stepBound := le_trans (by norm_num) stepBound_ge_one |
| @@ -732,10 +732,10 @@ theorem flatteningSlope_bounds (d : TailData) (y eta : ℝ) (heta : eta ^ 2 ≤ | ||
| 732 | 732 | have hprod : deriv sigma ((y - d.core.endpoint) / flattenLength) * |
| 733 | 733 | (Real.log 2 - logShape eta) ≤ stepBound * Real.log 2 := by |
| 734 | 734 | have h := mul_le_mul_of_nonneg_right hD1 (sub_nonneg.mpr hJ1) |
| 735 | - nlinarith [mul_nonneg hS hJ0] | |
| 735 | + linarith [mul_nonneg hS hJ0] | |
| 736 | 736 | have hlen : stepBound * Real.log 2 ≤ flattenLength / 10 := by |
| 737 | 737 | unfold flattenLength |
| 738 | - nlinarith | |
| 738 | + linarith | |
| 739 | 739 | have hquot : (deriv sigma ((y - d.core.endpoint) / flattenLength) * |
| 740 | 740 | (Real.log 2 - logShape eta)) / flattenLength ≤ 1 / 10 := by |
| 741 | 741 | apply (div_le_iff₀ flattenLength_pos).mpr |
| @@ -831,7 +831,7 @@ theorem uniformWait_gt_twentyseven (d : TailData) : 27 < d.uniformWait := by | ||
| 831 | 831 | simp only [one_div, inv_inv] at h |
| 832 | 832 | dsimp [TailData.uniformWait] |
| 833 | 833 | simp only [one_div] |
| 834 | - nlinarith [d.core.lam_lt] | |
| 834 | + linarith [d.core.lam_lt] | |
| 835 | 835 | |
| 836 | 836 | |
| 837 | 837 | end NavierStokes.OutgoingTail |
+1 −1 NavierStokes/ParametricHeatTail.lean View file
| @@ -599,7 +599,7 @@ theorem diffusion_mem {eta : ℝ} (hη : eta ∈ Icc (-1 : ℝ) 1) : | ||
| 599 | 599 | have hp := mul_nonneg (show 0 ≤ 1 - eta by linarith [hη.2]) |
| 600 | 600 | (show 0 ≤ 1 + eta by linarith [hη.1]) |
| 601 | 601 | dsimp [diffusion] |
| 602 | - constructor <;> nlinarith [sq_nonneg eta] | |
| 602 | + constructor <;> linarith [sq_nonneg eta] | |
| 603 | 603 | |
| 604 | 604 | theorem diffusion_hasDerivAt (eta : ℝ) : HasDerivAt diffusion (-2 * eta) eta := by |
| 605 | 605 | convert! (hasDerivAt_const eta (1 : ℝ)).sub ((hasDerivAt_id eta).pow 2) using 1 ; |
+4 −6 NavierStokes/ParametricKernelBounds.lean View file
| @@ -198,14 +198,13 @@ theorem transform_derivative_bound (n : ℕ) {R : ℝ} (hR : 0 ≤ R) : | ||
| 198 | 198 | intro y t hy ht |
| 199 | 199 | have hcoord : |y.2| ≤ R := by |
| 200 | 200 | simpa only [Real.norm_eq_abs] using (norm_snd_le y).trans hy |
| 201 | - have hpow : 1 ≤ (1 + t) ^ N := by | |
| 202 | - simpa using pow_le_pow_right₀ (by linarith : 1 ≤ 1 + t) (Nat.zero_le N) | |
| 201 | + have hpow : 1 ≤ (1 + t) ^ N := pow_le_pow_right₀ (by linarith : 1 ≤ 1 + t) (Nat.zero_le N) | |
| 203 | 202 | calc |
| 204 | 203 | ‖iteratedFDeriv ℝ n (transform t) y‖ ≤ |
| 205 | 204 | 1 + |iteratedDeriv n (fun x => coordinate x t) y.2| := |
| 206 | 205 | norm_iteratedFDeriv_transform_le n hn ht y |
| 207 | 206 | _ ≤ 1 + C * (1 + t) ^ N := add_le_add_right (hbound y.2 t hcoord ht) 1 |
| 208 | - _ ≤ (C + 1) * (1 + t) ^ N := by nlinarith | |
| 207 | + _ ≤ (C + 1) * (1 + t) ^ N := by linarith | |
| 209 | 208 | |
| 210 | 209 | def amplitude (j : ℕ) (x t : ℝ) : ℝ := denominator x t ^ j / denominator x t ^ 3 |
| 211 | 210 | |
| @@ -263,8 +262,7 @@ theorem profile_comp_derivative_bound {b : E × ℝ → ℝ} (hb : ContDiff ℝ | ||
| 263 | 262 | refine ⟨(n.factorial : ℝ) * B * (1 + A) ^ n, M * n, by positivity, ?_⟩ |
| 264 | 263 | intro y t hy ht |
| 265 | 264 | have ht1 : 1 ≤ 1 + t := by linarith |
| 266 | - have hpow : 1 ≤ (1 + t) ^ M := by | |
| 267 | - simpa using pow_le_pow_right₀ ht1 (Nat.zero_le M) | |
| 265 | + have hpow : 1 ≤ (1 + t) ^ M := pow_le_pow_right₀ ht1 (Nat.zero_le M) | |
| 268 | 266 | have hD : 1 ≤ (1 + A) * (1 + t) ^ M := by nlinarith |
| 269 | 267 | have hcomp := norm_iteratedFDeriv_comp_le hb (transform_contDiff ht) |
| 270 | 268 | (nat_le_smooth n) y |
| @@ -279,7 +277,7 @@ theorem profile_comp_derivative_bound {b : E × ℝ → ℝ} (hb : ContDiff ℝ | ||
| 279 | 277 | · calc |
| 280 | 278 | ‖iteratedFDeriv ℝ k (transform t) y‖ ≤ A * (1 + t) ^ M := |
| 281 | 279 | htransform k hkn y t hy ht |
| 282 | - _ ≤ (1 + A) * (1 + t) ^ M := by nlinarith | |
| 280 | + _ ≤ (1 + A) * (1 + t) ^ M := by linarith | |
| 283 | 281 | _ ≤ ((1 + A) * (1 + t) ^ M) ^ k := by |
| 284 | 282 | simpa only [pow_one] using pow_le_pow_right₀ hD hk1 |
| 285 | 283 | |
+1 −1 NavierStokes/ParametricRadialExtension.lean View file
| @@ -233,7 +233,7 @@ theorem extension_zero_exterior {S : Set ℝ} (w : ParameterWindow S) {F : Plane | ||
| 233 | 233 | {B : ℝ} (hB : 0 ≤ B) |
| 234 | 234 | (hzero : ∀ eta ∈ S, ∀ r, B ≤ r → F (r, eta) = 0) |
| 235 | 235 | {p : Plane} (hX : B ^ 2 / 2 ≤ p.1) : extension w F hF he p = 0 := by |
| 236 | - have hX0 : 0 ≤ p.1 := by nlinarith [sq_nonneg B] | |
| 236 | + have hX0 : 0 ≤ p.1 := by linarith [sq_nonneg B] | |
| 237 | 237 | have hsqrt : B ≤ Real.sqrt (2 * p.1) := by |
| 238 | 238 | apply (Real.le_sqrt hB (mul_nonneg (by norm_num : (0 : ℝ) ≤ 2) hX0)).mpr |
| 239 | 239 | linarith |
+1 −1 NavierStokes/ParametricTerminalCompensation.lean View file
| @@ -132,7 +132,7 @@ theorem exists_variable_compensation (P : Patch) (lam : ℝ) (hlam : 0 ≤ lam) | ||
| 132 | 132 | have hC : 0 < C := by dsimp [C]; positivity |
| 133 | 133 | have hBC : B ≤ C := by dsimp [C]; linarith |
| 134 | 134 | have hTC : T ≤ C := by dsimp [C]; linarith |
| 135 | - have hDBC : D * B ≤ C := by dsimp [T] at hTC; nlinarith [mul_pos hD (mul_pos hJ hB)] | |
| 135 | + have hDBC : D * B ≤ C := by dsimp [T] at hTC; linarith [mul_pos hD (mul_pos hJ hB)] | |
| 136 | 136 | refine ⟨ε₀ / D, C, div_pos hε₀ hD, hC, ?_⟩ |
| 137 | 137 | intro v hv hvsmall |
| 138 | 138 | let d : ℝ → Coeff := fun η => amplitudeDebt (a η) (v η) |
+14 −14 NavierStokes/PhaseEstimates.lean View file
| @@ -280,8 +280,8 @@ theorem representative_coordinate_errors | ||
| 280 | 280 | have h (i : Fin 2) := PiLp.norm_apply_le (representativeFrequency B sigma u L K g - B • K) i |
| 281 | 281 | rw [representative_tilt, ← hfreq] at h |
| 282 | 282 | constructor |
| 283 | - · simpa using h 0 | |
| 284 | - · simpa using h 1 | |
| 283 | + · exact h 0 | |
| 284 | + · exact h 1 | |
| 285 | 285 | |
| 286 | 286 | /-- The complete finite estimate starts from the chosen representative and |
| 287 | 287 | the local derivatives of the actual base. -/ |
| @@ -332,7 +332,7 @@ theorem inverse_cube_bounds {S : ℝ} (hS : 1 ≤ S) : | ||
| 332 | 332 | have h2 : S ≤ S ^ 2 := by nlinarith only [hS] |
| 333 | 333 | have h3 : S ^ 2 ≤ S ^ 3 := by |
| 334 | 334 | have h := mul_le_mul_of_nonneg_left hS (sq_nonneg S) |
| 335 | - nlinarith only [h] | |
| 335 | + linarith only [h] | |
| 336 | 336 | constructor |
| 337 | 337 | · exact one_div_le_one_div_of_le hS0 (h2.trans h3) |
| 338 | 338 | · have heq : S * (1 / S ^ 3) = 1 / S ^ 2 := by field_simp |
| @@ -403,20 +403,20 @@ theorem assembled_error_scaled {M S ε k v tilt : ℝ} | ||
| 403 | 403 | have h2 : M ≤ M ^ 2 := by nlinarith only [hM] |
| 404 | 404 | have h3 : M ^ 2 ≤ M ^ 3 := by |
| 405 | 405 | have h := mul_le_mul_of_nonneg_left hM (sq_nonneg M) |
| 406 | - nlinarith only [h] | |
| 406 | + linarith only [h] | |
| 407 | 407 | have hcoeff : M ^ 2 + M ≤ 2 * M ^ 3 := by linarith only [h2, h3] |
| 408 | 408 | have hlast := mul_le_mul_of_nonneg_right hcoeff hE |
| 409 | 409 | unfold phaseConstant |
| 410 | - nlinarith only [hround, hbase, hangle, hdiam, htilt', haxial, hlast] | |
| 410 | + linarith only [hround, hbase, hangle, hdiam, htilt', haxial, hlast] | |
| 411 | 411 | |
| 412 | 412 | theorem phaseError_le_four_div {S ε k : ℝ} (hS : 0 < S) |
| 413 | 413 | (hε2 : S ^ 2 * ε ^ 2 ≤ 1) (hk2 : S ^ 2 / k ≤ 1) (hε1 : ε * S ^ 2 ≤ 1) : |
| 414 | 414 | phaseError S ε k ≤ 4 / S := by |
| 415 | - have h1 : S * ε ^ 2 ≤ 1 / S := (le_div_iff₀ hS).2 (by nlinarith only [hε2]) | |
| 415 | + have h1 : S * ε ^ 2 ≤ 1 / S := (le_div_iff₀ hS).2 (by linarith only [hε2]) | |
| 416 | 416 | have h2 : S / k ≤ 1 / S := (le_div_iff₀ hS).2 (by |
| 417 | 417 | have heq : S / k * S = S ^ 2 / k := by ring |
| 418 | 418 | rwa [heq]) |
| 419 | - have h3 : ε * S ≤ 1 / S := (le_div_iff₀ hS).2 (by nlinarith only [hε1]) | |
| 419 | + have h3 : ε * S ≤ 1 / S := (le_div_iff₀ hS).2 (by linarith only [hε1]) | |
| 420 | 420 | unfold phaseError |
| 421 | 421 | rw [show 4 / S = 4 * (1 / S) by ring] |
| 422 | 422 | linarith only [h1, h2, h3] |
| @@ -481,20 +481,20 @@ theorem velocity_error_scaled {M S ε k : ℝ} | ||
| 481 | 481 | (add_le_add (inverse_cube_bounds hS).1 |
| 482 | 482 | (by simpa only [one_mul] using mul_le_mul_of_nonneg_right hS (sq_nonneg ε))).trans h1 |
| 483 | 483 | have hh' := mul_le_mul_of_nonneg_left hh (show 0 ≤ 2 * M ^ 2 by positivity) |
| 484 | - nlinarith only [hh'] | |
| 484 | + linarith only [hh'] | |
| 485 | 485 | have hd : |ε| * (3 * M ^ 2) ≤ 3 * M ^ 2 * phaseError S ε k := by |
| 486 | 486 | rw [abs_of_nonneg hε] |
| 487 | 487 | have hεle : ε ≤ ε * S := by simpa only [mul_one] using mul_le_mul_of_nonneg_left hS hε |
| 488 | 488 | have hh : ε ≤ phaseError S ε k := hεle.trans h3 |
| 489 | - nlinarith only [mul_le_mul_of_nonneg_left hh (show 0 ≤ 3 * M ^ 2 by positivity)] | |
| 489 | + linarith only [mul_le_mul_of_nonneg_left hh (show 0 ≤ 3 * M ^ 2 by positivity)] | |
| 490 | 490 | have hm2 : M ≤ M ^ 2 := by nlinarith only [hM] |
| 491 | 491 | have hm3 : M ^ 2 ≤ M ^ 3 := by |
| 492 | - nlinarith only [mul_le_mul_of_nonneg_left hM (sq_nonneg M)] | |
| 492 | + linarith only [mul_le_mul_of_nonneg_left hM (sq_nonneg M)] | |
| 493 | 493 | have hm4 : 0 ≤ M ^ 4 := pow_nonneg hM0 _ |
| 494 | 494 | have hcoeff : M ^ 3 + M + 5 * M ^ 2 ≤ phaseConstant M := by |
| 495 | 495 | unfold phaseConstant |
| 496 | 496 | linarith only [hm2, hm3, hm4, pow_nonneg hM0 3] |
| 497 | - nlinarith only [ha, hb, hc, hd, mul_le_mul_of_nonneg_right hcoeff hE] | |
| 497 | + linarith only [ha, hb, hc, hd, mul_le_mul_of_nonneg_right hcoeff hE] | |
| 498 | 498 | |
| 499 | 499 | /-- Quantitative estimates for the actual rounded phase. The C2 comparison |
| 500 | 500 | lemma above supplies the two `M (S⁻³ + ε²)` derivative hypotheses. -/ |
| @@ -860,7 +860,7 @@ theorem localBase_shear_error {F G F0 G0 : Slow → ℝ} {U : Set Slow} | ||
| 860 | 860 | have hh := mul_le_mul_of_nonneg_right hm2 he0 |
| 861 | 861 | have hd' : M * diameter ≤ M * (diameter + ε ^ 2) := |
| 862 | 862 | mul_le_mul_of_nonneg_left (le_add_of_nonneg_right (sq_nonneg _)) hM0 |
| 863 | - nlinarith only [hn, ha, hG, hh, hd', mul_nonneg (sq_nonneg M) he0] | |
| 863 | + linarith only [hn, ha, hG, hh, hd', mul_nonneg (sq_nonneg M) he0] | |
| 864 | 864 | |
| 865 | 865 | /-- The principal estimate stated for the actual PhaseCalculus normal, with |
| 866 | 866 | local C1/C2 hypotheses and the actual punctured-lattice rounded frequency. -/ |
| @@ -900,7 +900,7 @@ theorem radialSlope_uniform_bound {n : Space} {K : Plane} {B s δ A : ℝ} | ||
| 900 | 900 | have hscale : 2 * (1 + |s|) * δ / B ≤ 1 + |s| := by |
| 901 | 901 | apply (div_le_iff₀ hB).2 |
| 902 | 902 | have h := mul_le_mul_of_nonneg_left hδ (show 0 ≤ 2 * (1 + |s|) by positivity) |
| 903 | - nlinarith only [h] | |
| 903 | + linarith only [h] | |
| 904 | 904 | have h := abs_add_le (MovingFrameODE.radialSlope n - s) s |
| 905 | 905 | rw [sub_add_cancel] at h |
| 906 | 906 | linarith only [hc, hscale, h, hs] |
| @@ -931,7 +931,7 @@ theorem representative_uniform_frequency_bounds | ||
| 931 | 931 | calc |
| 932 | 932 | |target| = |R0| * |target / R0| := by nth_rw 1 [heq]; rw [abs_mul] |
| 933 | 933 | _ ≤ M * (M + M ^ 4) := mul_le_mul hRbound htarget (abs_nonneg _) hM |
| 934 | - · simpa using h1 | |
| 934 | + · exact h1 | |
| 935 | 935 | |
| 936 | 936 | theorem chart_carrier_ge_one (h : ℝ) (n : ℕ) : 1 ≤ (ChartScales.carrier h n : ℝ) := by |
| 937 | 937 | have hk : 0 < (ChartScales.carrier h n : ℝ) := |
+23 −27 NavierStokes/PhaseJetBounds.lean View file
| @@ -117,8 +117,7 @@ theorem PolynomialJets.add {f g : ι → E → F} | ||
| 117 | 117 | nlinarith |
| 118 | 118 | |
| 119 | 119 | theorem PolynomialJets.neg {f : ι → E → F} (hf : PolynomialJets D f) : |
| 120 | - PolynomialJets D (fun i x => -f i x) := by | |
| 121 | - simpa using hf.clm (-ContinuousLinearMap.id ℝ F) | |
| 120 | + PolynomialJets D (fun i x => -f i x) := hf.clm (-ContinuousLinearMap.id ℝ F) | |
| 122 | 121 | |
| 123 | 122 | theorem PolynomialJets.sub {f g : ι → E → F} |
| 124 | 123 | (hf : PolynomialJets D f) (hg : PolynomialJets D g) : |
| @@ -142,7 +141,7 @@ theorem PolynomialJets.bilinear {f : ι → E → F} {g : ι → E → G} | ||
| 142 | 141 | obtain ⟨C, hC, c, hc⟩ := hg.bound N |
| 143 | 142 | refine ⟨(‖B‖ + 1) * 2 ^ N * A * C, ?_, a + c, ?_⟩ |
| 144 | 143 | · have hpow : (1 : ℝ) ≤ 2 ^ N := one_le_pow₀ (by norm_num) |
| 145 | - have hba : 1 ≤ (‖B‖ + 1) * 2 ^ N := one_le_mul' (by nlinarith [norm_nonneg B]) hpow | |
| 144 | + have hba : 1 ≤ (‖B‖ + 1) * 2 ^ N := one_le_mul' (by linarith [norm_nonneg B]) hpow | |
| 146 | 145 | exact one_le_mul' (one_le_mul' hba hA) hC |
| 147 | 146 | intro i |
| 148 | 147 | apply (JetBounds.FiniteJetBound.bilinear B (D.isOpen i) |
| @@ -157,13 +156,11 @@ theorem PolynomialJets.bilinear {f : ι → E → F} {g : ι → E → G} | ||
| 157 | 156 | |
| 158 | 157 | theorem PolynomialJets.mul {f g : ι → E → ℝ} |
| 159 | 158 | (hf : PolynomialJets D f) (hg : PolynomialJets D g) : |
| 160 | - PolynomialJets D (fun i x => f i x * g i x) := by | |
| 161 | - simpa using hf.bilinear hg (ContinuousLinearMap.mul ℝ ℝ) | |
| 159 | + PolynomialJets D (fun i x => f i x * g i x) := hf.bilinear hg (ContinuousLinearMap.mul ℝ ℝ) | |
| 162 | 160 | |
| 163 | 161 | theorem PolynomialJets.smul {f : ι → E → ℝ} {g : ι → E → F} |
| 164 | 162 | (hf : PolynomialJets D f) (hg : PolynomialJets D g) : |
| 165 | - PolynomialJets D (fun i x => f i x • g i x) := by | |
| 166 | - simpa using hf.bilinear hg (ContinuousLinearMap.lsmul ℝ ℝ) | |
| 163 | + PolynomialJets D (fun i x => f i x • g i x) := hf.bilinear hg (ContinuousLinearMap.lsmul ℝ ℝ) | |
| 167 | 164 | |
| 168 | 165 | theorem PolynomialJets.fderiv {f : ι → E → F} (hf : PolynomialJets D f) : |
| 169 | 166 | PolynomialJets D (fun i => fderiv ℝ (f i)) := by |
| @@ -182,7 +179,7 @@ theorem PolynomialJets.affine (L : E →L[ℝ] F) (c : ι → F) {C : ℝ} {m : | ||
| 182 | 179 | PolynomialJets D (fun i x => L x + c i) := by |
| 183 | 180 | refine ⟨fun _ => L.contDiff.contDiffOn.add contDiffOn_const, ?_⟩ |
| 184 | 181 | intro N |
| 185 | - refine ⟨C + ‖L‖, by nlinarith [norm_nonneg L], m, ?_⟩ | |
| 182 | + refine ⟨C + ‖L‖, by linarith [norm_nonneg L], m, ?_⟩ | |
| 186 | 183 | intro i n hn x hx |
| 187 | 184 | have hs : 1 ≤ D.scale i ^ m := one_le_pow₀ (D.one_le_scale i) |
| 188 | 185 | have hfd : _root_.fderiv ℝ (fun y => L y + c i) = fun _ => L := by |
| @@ -237,11 +234,11 @@ theorem PolynomialJets.precomp_affine {D' : Domain ι F} {f : ι → F → G} | ||
| 237 | 234 | (L.contDiff.contDiffOn.add contDiffOn_const) (hmap i), ?_⟩ |
| 238 | 235 | intro N |
| 239 | 236 | obtain ⟨C, hC, m, hm⟩ := hf.bound N |
| 240 | - refine ⟨C * (‖L‖ + 1) ^ N, one_le_mul' hC (one_le_pow₀ (by nlinarith [norm_nonneg L])), m, ?_⟩ | |
| 237 | + refine ⟨C * (‖L‖ + 1) ^ N, one_le_mul' hC (one_le_pow₀ (by linarith [norm_nonneg L])), m, ?_⟩ | |
| 241 | 238 | intro i n hn x hx |
| 242 | 239 | have hp : ‖L‖ ^ n ≤ (‖L‖ + 1) ^ N := |
| 243 | 240 | (pow_le_pow_left₀ (norm_nonneg L) (by linarith) n).trans |
| 244 | - (pow_le_pow_right₀ (by nlinarith [norm_nonneg L]) hn) | |
| 241 | + (pow_le_pow_right₀ (by linarith [norm_nonneg L]) hn) | |
| 245 | 242 | calc |
| 246 | 243 | _ ≤ ‖iteratedFDeriv ℝ n (f i) (L x + c i)‖ * ‖L‖ ^ n := |
| 247 | 244 | norm_jet_comp_affine (D'.isOpen i) (hf.smooth i) L (c i) (hmap i x hx) n |
| @@ -550,13 +547,13 @@ theorem PhaseFamily.polynomial_jets (a : PhaseFamily ι) (D : Domain ι Slow) | ||
| 550 | 547 | PolynomialJets (D.slot V hV) a.velocity ∧ |
| 551 | 548 | PolynomialJets (D.slot V hV) a.shear := by |
| 552 | 549 | have hpε : PolynomialJets (D.slot V hV) (fun i _ => a.epsilon i) := |
| 553 | - PolynomialJets.const_uniform _ hM (fun i => by simpa using (hconstant i).1) | |
| 550 | + PolynomialJets.const_uniform _ hM (fun i => (hconstant i).1) | |
| 554 | 551 | have hpp : PolynomialJets (D.slot V hV) (fun i _ => a.p i) := |
| 555 | - PolynomialJets.const_uniform _ hM (fun i => by simpa using (hconstant i).2.1) | |
| 552 | + PolynomialJets.const_uniform _ hM (fun i => (hconstant i).2.1) | |
| 556 | 553 | have hppz : PolynomialJets (D.slot V hV) (fun i _ => a.pz i) := |
| 557 | - PolynomialJets.const_uniform _ hM (fun i => by simpa using (hconstant i).2.2.1) | |
| 554 | + PolynomialJets.const_uniform _ hM (fun i => (hconstant i).2.2.1) | |
| 558 | 555 | have hpx : PolynomialJets (D.slot V hV) (fun i _ => a.x0 i) := |
| 559 | - PolynomialJets.const_uniform _ hM (fun i => by simpa using (hconstant i).2.2.2) | |
| 556 | + PolynomialJets.const_uniform _ hM (fun i => (hconstant i).2.2.2) | |
| 560 | 557 | have hpR : PolynomialJets D (fun _ q => q.1) := by |
| 561 | 558 | simpa only [ContinuousLinearMap.coe_fst', add_zero] using |
| 562 | 559 | (PolynomialJets.affine (D := D) (ContinuousLinearMap.fst ℝ ℝ (ℝ × ℝ)) |
| @@ -658,13 +655,13 @@ theorem FrameJets.modal_errors {d : ι → PrimaryODE.FrameData Q} (h : FrameJet | ||
| 658 | 655 | simpa only [PrimaryODE.FrameData.error11, MovingFrameODE.modal11, div_eq_mul_inv] using |
| 659 | 656 | (((h.errorA.add hb).add hc).sub h.eigenRate).div_const 2 |
| 660 | 657 | · unfold PrimaryODE.FrameData.error12 |
| 661 | - simpa only [PrimaryODE.FrameData.error12, MovingFrameODE.modal12, div_eq_mul_inv] using | |
| 658 | + simpa only [MovingFrameODE.modal12, div_eq_mul_inv] using | |
| 662 | 659 | (((h.errorA.sub hb).add hc).add h.eigenRate).div_const 2 |
| 663 | 660 | · unfold PrimaryODE.FrameData.error21 |
| 664 | - simpa only [PrimaryODE.FrameData.error21, MovingFrameODE.modal21, div_eq_mul_inv] using | |
| 661 | + simpa only [MovingFrameODE.modal21, div_eq_mul_inv] using | |
| 665 | 662 | (((h.errorA.add hb).sub hc).add h.eigenRate).div_const 2 |
| 666 | 663 | · unfold PrimaryODE.FrameData.error22 |
| 667 | - simpa only [PrimaryODE.FrameData.error22, MovingFrameODE.modal22, div_eq_mul_inv] using | |
| 664 | + simpa only [MovingFrameODE.modal22, div_eq_mul_inv] using | |
| 668 | 665 | (((h.errorA.sub hb).sub hc).sub h.eigenRate).div_const 2 |
| 669 | 666 | |
| 670 | 667 | theorem FrameJets.coefficient {d : ι → PrimaryODE.FrameData Q} (h : FrameJets D d) (j : ℤ) : |
| @@ -680,8 +677,7 @@ theorem FrameJets.coefficient {d : ι → PrimaryODE.FrameData Q} (h : FrameJets | ||
| 680 | 677 | apply hh.congr |
| 681 | 678 | intro i z _ |
| 682 | 679 | ext w k |
| 683 | - fin_cases k <;> simp [PrimaryODE.FrameData.coefficient, PrimaryODE.FrameData.damping, | |
| 684 | - GrowingMode.modalOperator] | |
| 680 | + fin_cases k <;> simp [PrimaryODE.FrameData.coefficient, PrimaryODE.FrameData.damping] | |
| 685 | 681 | |
| 686 | 682 | /-- The actual projection and eigenbasis conversion of a supplied source |
| 687 | 683 | preserve polynomial jets. A scalar weight on the source can be carried |
| @@ -746,13 +742,13 @@ theorem PolynomialJets.parameter_bound {F : Type*} [NormedAddCommGroup F] [Norme | ||
| 746 | 742 | obtain ⟨C, hC, m, hm⟩ := hf.bound N |
| 747 | 743 | let L := ContinuousLinearMap.inl ℝ Q ℝ |
| 748 | 744 | refine ⟨C * (‖L‖ + 1) ^ N, |
| 749 | - one_le_mul' hC (one_le_pow₀ (by nlinarith [norm_nonneg L])), m, ?_⟩ | |
| 745 | + one_le_mul' hC (one_le_pow₀ (by linarith [norm_nonneg L])), m, ?_⟩ | |
| 750 | 746 | intro i p v hp k hk |
| 751 | 747 | have hmap : L p + (0, v) ∈ D.carrier i := by simpa [L] using hp |
| 752 | 748 | have hjet := norm_jet_comp_affine (D.isOpen i) (hf.smooth i) L (0, v) hmap k |
| 753 | 749 | have hfac : ‖L‖ ^ k ≤ (‖L‖ + 1) ^ N := |
| 754 | 750 | (pow_le_pow_left₀ (norm_nonneg L) (by linarith) k).trans |
| 755 | - (pow_le_pow_right₀ (by nlinarith [norm_nonneg L]) hk) | |
| 751 | + (pow_le_pow_right₀ (by linarith [norm_nonneg L]) hk) | |
| 756 | 752 | calc |
| 757 | 753 | _ ≤ ‖iteratedFDeriv ℝ k (f i) (p, v)‖ * ‖L‖ ^ k := by simpa [L] using hjet |
| 758 | 754 | _ ≤ (C * D.scale i ^ m) * (‖L‖ + 1) ^ N := |
| @@ -797,7 +793,7 @@ theorem normal_range_of_reference_close {n : ι → E → Space} | ||
| 797 | 793 | have h1 := mul_le_mul (hB i).2 (hs i z hz) (abs_nonneg _) (by linarith : 0 ≤ M) |
| 798 | 794 | have h2 := mul_le_mul (hB i).2 (hc 0) (abs_nonneg _) (by linarith : 0 ≤ M) |
| 799 | 795 | have h3 := mul_le_mul (hB i).2 (hc 1) (abs_nonneg _) (by linarith : 0 ≤ M) |
| 800 | - nlinarith | |
| 796 | + linarith | |
| 801 | 797 | have hh := norm_sub_le_norm_sub_add_norm_sub (n i z) |
| 802 | 798 | (MovingFrameODE.pack (B i * s i z) (B i • K i)) 0 |
| 803 | 799 | simp only [sub_zero] at hh |
| @@ -849,11 +845,11 @@ theorem reference_jets (lam c0 u ell : ι → ℝ) | ||
| 849 | 845 | |PrimaryODE.referenceProfile (c0 i) (u i) (ell i) z.2| ≤ M * (1 + M + M ^ 2)) := by |
| 850 | 846 | have hq (i) : |u i / ell i| ≤ M := by |
| 851 | 847 | nlinarith [hrate i, D.one_le_scale i, abs_nonneg (u i / ell i)] |
| 852 | - have pu := PolynomialJets.const_uniform (D := D) u hM (fun i => by simpa using hu i) | |
| 848 | + have pu := PolynomialJets.const_uniform (D := D) u hM (fun i => hu i) | |
| 853 | 849 | have pq := PolynomialJets.const_uniform (D := D) (fun i => u i / ell i) hM |
| 854 | 850 | (fun i => by simpa only [Real.norm_eq_abs] using hq i) |
| 855 | - have plam := PolynomialJets.const_uniform (D := D) lam hM (fun i => by simpa using hlam i) | |
| 856 | - have pc := PolynomialJets.const_uniform (D := D) c0 hM (fun i => by simpa using (hc i).2) | |
| 851 | + have plam := PolynomialJets.const_uniform (D := D) lam hM (fun i => hlam i) | |
| 852 | + have pc := PolynomialJets.const_uniform (D := D) c0 hM (fun i => (hc i).2) | |
| 857 | 853 | have pv : PolynomialJets D (fun _ z => z.2) := by |
| 858 | 854 | simpa only [ContinuousLinearMap.coe_snd', add_zero] using |
| 859 | 855 | (PolynomialJets.affine (D := D) (ContinuousLinearMap.snd ℝ Q ℝ) |
| @@ -872,7 +868,7 @@ theorem reference_jets (lam c0 u ell : ι → ℝ) | ||
| 872 | 868 | rw [abs_mul] |
| 873 | 869 | have hh := mul_le_mul_of_nonneg_left (hslot i z hz) (abs_nonneg (u i / ell i)) |
| 874 | 870 | have hh' := mul_le_mul_of_nonneg_right (hrate i) (show 0 ≤ M by linarith) |
| 875 | - nlinarith | |
| 871 | + linarith | |
| 876 | 872 | exact (abs_add_le _ _).trans (by linarith) |
| 877 | 873 | obtain ⟨pr, pri, pdi⟩ := ps.radius hsb |
| 878 | 874 | refine ⟨?_, ?_, ?_, ?_, ?_⟩ |
| @@ -888,7 +884,7 @@ theorem reference_jets (lam c0 u ell : ι → ℝ) | ||
| 888 | 884 | (add_le_add_right (hsb i z hz) 1) |
| 889 | 885 | simp only [PrimaryODE.referenceProfile, abs_mul, abs_of_nonneg (Real.sqrt_nonneg _)] |
| 890 | 886 | have hh := mul_le_mul (hc i).2 h (Real.sqrt_nonneg _) (show 0 ≤ M by linarith) |
| 891 | - nlinarith | |
| 887 | + linarith | |
| 892 | 888 | |
| 893 | 889 | end ReferenceJets |
| 894 | 890 | |
+3 −3 NavierStokes/PolarCharts.lean View file
| @@ -292,7 +292,7 @@ noncomputable def physicalChart (a : ℝ) (j : Index) (Q : ℝ) : Plane → Plan | ||
| 292 | 292 | chart a j ∘ scalePlane Q |
| 293 | 293 | |
| 294 | 294 | theorem rotate_smul (j : Index) (c : ℝ) (p : Plane) : rotate j (c • p) = c • rotate j p := by |
| 295 | - fin_cases j <;> ext <;> simp [rotate, mul_neg] | |
| 295 | + fin_cases j <;> ext <;> simp [rotate] | |
| 296 | 296 | |
| 297 | 297 | theorem radius_smul {c : ℝ} (hc : 0 < c) (p : Plane) : radius (c • p) = c * radius p := by |
| 298 | 298 | simp only [radius, Prod.smul_fst, Prod.smul_snd, smul_eq_mul] |
| @@ -315,7 +315,7 @@ theorem localChart_angle_difference (i j : Index) {p : Plane} | ||
| 315 | 315 | have hxj := congrArg Prod.fst (polar_localChart j hj) |
| 316 | 316 | have hyi := congrArg Prod.snd (polar_localChart i hi) |
| 317 | 317 | have hyj := congrArg Prod.snd (polar_localChart j hj) |
| 318 | - simp only [polar, localChart_apply] at hxi hxj hyi hyj | |
| 318 | + simp only [localChart_apply] at hxi hxj hyi hyj | |
| 319 | 319 | have hcos : Real.cos (localChart i p).2 = Real.cos (localChart j p).2 := by |
| 320 | 320 | apply mul_left_cancel₀ hr |
| 321 | 321 | exact hxi.trans hxj.symm |
| @@ -332,7 +332,7 @@ theorem localChart_periodic_agree {V : Type*} (f : Plane → V) | ||
| 332 | 332 | f (localChart i p) = f (localChart j p) := by |
| 333 | 333 | obtain ⟨n, hn⟩ := localChart_angle_difference i j hi hj |
| 334 | 334 | have he : (localChart i p).2 = (localChart j p).2 + n * (2 * Real.pi) := by |
| 335 | - nlinarith [hn] | |
| 335 | + linarith [hn] | |
| 336 | 336 | have hv := ((hf (radius p)).int_mul n) (localChart j p).2 |
| 337 | 337 | have hri : (localChart i p).1 = radius p := by simp only [localChart_apply] |
| 338 | 338 | have hrj : (localChart j p).1 = radius p := by simp only [localChart_apply] |
+8 −8 NavierStokes/ProfileSpectralCone.lean View file
| @@ -33,7 +33,7 @@ theorem referenceCone_of_trueCone {F p₁ p₂ a c : ℝ} (hF : 0 < F) | ||
| 33 | 33 | apply PrimaryRepresentatives.referenceCone_of_shear_coordinates hF h.1 |
| 34 | 34 | have he := shear_size_mul (c := c) h.1.ne' |
| 35 | 35 | have hm := mul_lt_mul_of_pos_left h.2.1 h.1 |
| 36 | - nlinarith | |
| 36 | + linarith | |
| 37 | 37 | |
| 38 | 38 | /-- The square of the actual unstable eigenvector slope. -/ |
| 39 | 39 | theorem c0_sq_signedShear {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) |
| @@ -42,7 +42,7 @@ theorem c0_sq_signedShear {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 42 | 42 | have ho : 2 * a < a ^ 2 + (-c) ^ 2 := by |
| 43 | 43 | have he := shear_size_mul (c := c) ha.ne' |
| 44 | 44 | have hm := mul_lt_mul_of_pos_left hv ha |
| 45 | - nlinarith | |
| 45 | + linarith | |
| 46 | 46 | have hr := PrimaryRepresentatives.referenceCone_of_shear_coordinates hF ha ho |
| 47 | 47 | have hn0 : ‖F • !₂[-a, -c]‖ ≠ 0 := norm_ne_zero_iff.mpr hr.shear_ne_zero |
| 48 | 48 | have hn : ‖F • !₂[-a, -c]‖ ^ 2 = F ^ 2 * (a ^ 2 + c ^ 2) := by |
| @@ -59,7 +59,7 @@ theorem c0_sq_signedShear {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 59 | 59 | change -((2 * F * (F * -a)) / ‖F • !₂[-a, -c]‖ + ‖F • !₂[-a, -c]‖) / |
| 60 | 60 | ((2 * F * (F * -a)) / ‖F • !₂[-a, -c]‖) = _ |
| 61 | 61 | field_simp [hF.ne', ha.ne', hn0] |
| 62 | - nlinarith [hn] | |
| 62 | + linarith [hn] | |
| 63 | 63 | |
| 64 | 64 | /-- Projection of the actual stress coordinates onto the normal. -/ |
| 65 | 65 | theorem stress_inner_normal (F τ p₁ p₂ a c : ℝ) (ha : a ≠ 0) : |
| @@ -85,7 +85,7 @@ theorem stress_inner_transverse (F τ p₁ p₂ a c : ℝ) (ha : a ≠ 0) : | ||
| 85 | 85 | calc |
| 86 | 86 | _ = (τ * F / ‖F • !₂[-a, -c]‖) * (a * p₂ - c * p₁) := by |
| 87 | 87 | simp [PrimaryRepresentatives.transverseDirection, PrimaryRepresentatives.normalDirection, |
| 88 | - MovingFrameODE.quarterTurn, PiLp.inner_apply, Fin.sum_univ_two] | |
| 88 | + MovingFrameODE.quarterTurn, PiLp.inner_apply] | |
| 89 | 89 | ring |
| 90 | 90 | _ = _ := by rw [← he]; ring |
| 91 | 91 | |
| @@ -113,7 +113,7 @@ theorem spectral_cones_of_trueCone {F τ p₁ p₂ a c : ℝ} (hF : 0 < F) (hτ | ||
| 113 | 113 | have hsq : (PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (p₂ - p₁ * (c / a))) ^ 2 < |
| 114 | 114 | (p₁ + p₂ * (c / a) - a * (1 + (c / a) ^ 2)) ^ 2 := by |
| 115 | 115 | rw [mul_pow, hc] |
| 116 | - nlinarith [hq.2] | |
| 116 | + linarith [hq.2] | |
| 117 | 117 | have habs : |PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (p₂ - p₁ * (c / a))| < |
| 118 | 118 | p₁ + p₂ * (c / a) - a * (1 + (c / a) ^ 2) := by |
| 119 | 119 | nlinarith [sq_abs (PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (p₂ - p₁ * (c / a))), |
| @@ -137,7 +137,7 @@ theorem targetCone_of_signedShear {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 137 | 137 | have ho : 2 * a < a ^ 2 + (-c) ^ 2 := by |
| 138 | 138 | have he := shear_size_mul (c := c) ha.ne' |
| 139 | 139 | have hm := mul_lt_mul_of_pos_left hv ha |
| 140 | - nlinarith | |
| 140 | + linarith | |
| 141 | 141 | have hr := PrimaryRepresentatives.referenceCone_of_shear_coordinates hF ha ho |
| 142 | 142 | have hk : 0 < F / ‖F • !₂[-a, -c]‖ := |
| 143 | 143 | div_pos hF (norm_pos_iff.mpr hr.shear_ne_zero) |
| @@ -153,7 +153,7 @@ theorem targetCone_of_signedShear {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 153 | 153 | have hsq : (PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (a * T 1 - c * T 0)) ^ 2 < |
| 154 | 154 | (a * T 0 + c * T 1) ^ 2 := by |
| 155 | 155 | rw [mul_pow, c0_sq_signedShear hF ha hv] |
| 156 | - nlinarith only [hquad] | |
| 156 | + linarith only [hquad] | |
| 157 | 157 | have habs : |PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (a * T 1 - c * T 0)| < |
| 158 | 158 | a * T 0 + c * T 1 := by |
| 159 | 159 | nlinarith [sq_abs (PrimaryRepresentatives.c0 F (F • !₂[-a, -c]) * (a * T 1 - c * T 0)), |
| @@ -183,7 +183,7 @@ theorem targetCone_of_tilt {F a c : ℝ} (hF : 0 < F) (ha : 0 < a) | ||
| 183 | 183 | exact mul_pos (mul_pos ha hT) hin |
| 184 | 184 | · rw [hi, ht] |
| 185 | 185 | have hm := mul_pos (sq_pos_of_pos (mul_pos ha hT)) hgap |
| 186 | - nlinarith only [hm] | |
| 186 | + linarith only [hm] | |
| 187 | 187 | |
| 188 | 188 | /-! ## The actual profile histories and stresses -/ |
| 189 | 189 | |
+21 −21 NavierStokes/PulseAmplitude.lean View file
| @@ -208,7 +208,7 @@ theorem mainPulse_mul_prefixRepair (c : Parameters) (y : ℝ) : | ||
| 208 | 208 | mainPulse (c.lam * y) * prefixRepair c y = 0 := by |
| 209 | 209 | have he := mainPulse_mul_correction c (fun _ => 0) 1 y |
| 210 | 210 | rw [← prefixRepair_eq_correction] at he |
| 211 | - nlinarith | |
| 211 | + linarith | |
| 212 | 212 | |
| 213 | 213 | def pulseWeight (c : Parameters) (y : ℝ) : ℝ := Real.exp (-2 * c.lam * y) |
| 214 | 214 | |
| @@ -266,7 +266,7 @@ theorem quadraticCoefficient_eq (c : Parameters) : | ||
| 266 | 266 | funext y |
| 267 | 267 | unfold amplitudeShape |
| 268 | 268 | have hz := mainPulse_mul_amplitudeRepair c y |
| 269 | - nlinarith [congrArg (fun x : ℝ => pulseWeight c y * x) hz] | |
| 269 | + linarith [congrArg (fun x : ℝ => pulseWeight c y * x) hz] | |
| 270 | 270 | unfold quadraticCoefficient |
| 271 | 271 | rw [he, intervalIntegral.integral_add (hp.intervalIntegrable _ _) (hr.intervalIntegrable _ _), |
| 272 | 272 | mul_add, normalized_main_energy] |
| @@ -312,7 +312,7 @@ theorem scaledPulseEnergy_eq (c : Parameters) (A eta : ℝ) : | ||
| 312 | 312 | have hn' := normalized_negative_energy c |
| 313 | 313 | simp only [intervalIntegral.integral_const_mul] at hn' |
| 314 | 314 | unfold quadraticCoefficient linearCoefficient constantCorrection |
| 315 | - nlinarith | |
| 315 | + linarith | |
| 316 | 316 | |
| 317 | 317 | /-! ## Exact prefix coefficients and uniform bounds -/ |
| 318 | 318 | |
| @@ -390,7 +390,7 @@ theorem prefixAngularEnergy_bound (c : Parameters) : | ||
| 390 | 390 | (fun y hy => div_le_div_of_nonneg_right (prefix_weight_bound c hy.1 hy.2) (by norm_num)) |
| 391 | 391 | simp only [intervalIntegral.integral_const, sub_zero, smul_eq_mul] at hm |
| 392 | 392 | unfold prefixAngularEnergy |
| 393 | - nlinarith [initial_weight_bound c] | |
| 393 | + linarith [initial_weight_bound c] | |
| 394 | 394 | |
| 395 | 395 | theorem prefixAxialEnergy_bound (c : Parameters) : |
| 396 | 396 | prefixAxialEnergy c ≤ 16 * Real.exp (Real.exp c.m) := by |
| @@ -696,7 +696,7 @@ theorem negativeClamp_le (x : ℝ) : negativeClamp x ≤ -(1 / 10) := by | ||
| 696 | 696 | · have h0 := sigma_nonneg (10 * (x + 1 / 5)) |
| 697 | 697 | have h1 := sigma_le_one (10 * (x + 1 / 5)) |
| 698 | 698 | unfold negativeClamp |
| 699 | - nlinarith [mul_nonneg (sub_nonneg.mpr h1) (show 0 ≤ -(1 / 10) - x by linarith)] | |
| 699 | + linarith [mul_nonneg (sub_nonneg.mpr h1) (show 0 ≤ -(1 / 10) - x by linarith)] | |
| 700 | 700 | · simp only [negativeClamp, sigma_one (by linarith : 1 ≤ 10 * (x + 1 / 5))] |
| 701 | 701 | norm_num |
| 702 | 702 | |
| @@ -780,7 +780,7 @@ theorem logarithmicRate_pos (c : Parameters) : 0 < logarithmicRate c.lam := | ||
| 780 | 780 | |
| 781 | 781 | theorem lambda_le_logarithmicRate (c : Parameters) : c.lam ≤ logarithmicRate c.lam := by |
| 782 | 782 | unfold logarithmicRate |
| 783 | - nlinarith [mul_nonneg c.lam_pos.le (log_inverse_nonneg c)] | |
| 783 | + linarith [mul_nonneg c.lam_pos.le (log_inverse_nonneg c)] | |
| 784 | 784 | |
| 785 | 785 | theorem prefixAxialEnergy_nonneg (c : Parameters) : 0 ≤ prefixAxialEnergy c := by |
| 786 | 786 | have hi := intervalIntegral.integral_nonneg_of_forall (μ := volume) c.pulseStart_pos.le |
| @@ -792,7 +792,7 @@ theorem prefixAngularEnergy_nonneg (c : Parameters) : 0 ≤ prefixAngularEnergy | ||
| 792 | 792 | have hi := intervalIntegral.integral_nonneg_of_forall (μ := volume) c.pulseStart_pos.le |
| 793 | 793 | (fun y => div_nonneg (coreEnergyWeight_nonneg c y) (by norm_num : (0 : ℝ) ≤ 2)) |
| 794 | 794 | unfold prefixAngularEnergy |
| 795 | - nlinarith [sq_nonneg c.P] | |
| 795 | + linarith [sq_nonneg c.P] | |
| 796 | 796 | |
| 797 | 797 | theorem normalizedPrefix_nonneg (c : Parameters) : |
| 798 | 798 | 0 ≤ normalizedPrefixAxial c ∧ 0 ≤ normalizedPrefixAngular c := |
| @@ -897,7 +897,7 @@ theorem normalizedTail_bound (d : OutgoingTail.TailData) (eta : ℝ) (heta : eta | ||
| 897 | 897 | |
| 898 | 898 | theorem pulseWeight_le_one (c : Parameters) {y : ℝ} (hy : 0 ≤ y) : pulseWeight c y ≤ 1 := by |
| 899 | 899 | apply Real.exp_le_one_iff.mpr |
| 900 | - nlinarith [mul_nonneg c.lam_pos.le hy] | |
| 900 | + linarith [mul_nonneg c.lam_pos.le hy] | |
| 901 | 901 | |
| 902 | 902 | theorem weighted_square_bound (c : Parameters) (f : ℝ → ℝ) (hf : Continuous f) |
| 903 | 903 | (M : ℝ) (hM : 0 ≤ M) (hbound : ∀ y, |f y| ≤ M) : |
| @@ -955,7 +955,7 @@ theorem etaPolynomial_bounds {eta : ℝ} (heta : eta ^ 2 ≤ 1) : | ||
| 955 | 955 | have he : |eta| ≤ 1 := abs_le.mpr ⟨by nlinarith, by nlinarith⟩ |
| 956 | 956 | constructor |
| 957 | 957 | · rw [etaPolynomial, abs_mul, abs_of_nonneg (by positivity : 0 ≤ 1 + eta ^ 2)] |
| 958 | - nlinarith [mul_nonneg (show 0 ≤ 1 - |eta| by linarith) (show 0 ≤ 1 + eta ^ 2 by positivity)] | |
| 958 | + linarith [mul_nonneg (show 0 ≤ 1 - |eta| by linarith) (show 0 ≤ 1 + eta ^ 2 by positivity)] | |
| 959 | 959 | · rw [(etaPolynomial_hasDerivAt eta).deriv, abs_of_nonneg (by positivity : 0 ≤ 1 + 3 * eta ^ 2)] |
| 960 | 960 | linarith |
| 961 | 961 | |
| @@ -969,16 +969,16 @@ theorem quadratic_root_bracket {a b c r : ℝ} | ||
| 969 | 969 | · by_contra h |
| 970 | 970 | have hrl : r ≤ 9 / 10 := le_of_not_gt h |
| 971 | 971 | have hs : r ^ 2 ≤ (9 / 10 : ℝ) ^ 2 := by |
| 972 | - nlinarith [mul_nonneg (show 0 ≤ 9 / 10 - r by linarith) (show 0 ≤ 9 / 10 + r by linarith)] | |
| 972 | + linarith [mul_nonneg (show 0 ≤ 9 / 10 - r by linarith) (show 0 ≤ 9 / 10 + r by linarith)] | |
| 973 | 973 | have haR := mul_le_mul_of_nonneg_right ha' (sq_nonneg r) |
| 974 | 974 | have hbR := mul_le_mul_of_nonneg_right hbu hr.le |
| 975 | - nlinarith | |
| 975 | + linarith | |
| 976 | 976 | · by_contra h |
| 977 | 977 | have hru : 6 / 5 ≤ r := le_of_not_gt h |
| 978 | 978 | have hs := mul_nonneg (show 0 ≤ r - 6 / 5 by linarith) hr.le |
| 979 | 979 | have haR := mul_le_mul_of_nonneg_right ha (sq_nonneg r) |
| 980 | 980 | have hbR := mul_le_mul_of_nonneg_right hbl hr.le |
| 981 | - nlinarith | |
| 981 | + linarith | |
| 982 | 982 | |
| 983 | 983 | theorem amplitude_derivative_identity (d : OutgoingTail.TailData) (eta : ℝ) |
| 984 | 984 | (hc : constantTerm d eta < -(1 / 5)) : |
| @@ -1039,7 +1039,7 @@ theorem exp_inverse_bound {lam : ℝ} (hlam : 0 < lam) : | ||
| 1039 | 1039 | simpa only [one_div, inv_inv] using hinv |
| 1040 | 1040 | have hu : Real.exp (-(1 / (4 * lam))) ≤ 1 := Real.exp_le_one_iff.mpr (by linarith) |
| 1041 | 1041 | have hm := mul_le_mul hlin hu (Real.exp_pos _).le (by positivity : 0 ≤ 4 * lam) |
| 1042 | - nlinarith | |
| 1042 | + linarith | |
| 1043 | 1043 | |
| 1044 | 1044 | def correctionEnergyConstant (P m : ℝ) : ℝ := |
| 1045 | 1045 | 104 * OutgoingPulseBounds.correctionJetBound P m 0 ^ 2 |
| @@ -1083,13 +1083,13 @@ theorem correctionEnergy_bounds (c : Parameters) (hsmall : c.lam ≤ 1 / 120) : | ||
| 1083 | 1083 | have hlarge : 26 * M ^ 2 ≤ correctionEnergyConstant c.P c.m * c.lam := by |
| 1084 | 1084 | have he := mul_le_mul_of_nonneg_left (exp_inverse_bound c.lam_pos) |
| 1085 | 1085 | (sq_nonneg (OutgoingPulseBounds.correctionJetBound c.P c.m 0)) |
| 1086 | - dsimp [M, correctionEnergyConstant] | |
| 1087 | - nlinarith | |
| 1088 | - have hq : 13 * M ^ 2 ≤ 26 * M ^ 2 := by nlinarith [sq_nonneg M] | |
| 1086 | + dsimp [correctionEnergyConstant] | |
| 1087 | + linarith | |
| 1088 | + have hq : 13 * M ^ 2 ≤ 26 * M ^ 2 := by linarith [sq_nonneg M] | |
| 1089 | 1089 | refine ⟨hb1.1, hb1.2.trans (hq.trans hlarge), ?_, hb0.1, hb0.2.trans (hq.trans hlarge)⟩ |
| 1090 | 1090 | rw [hlin, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 1091 | 1091 | exact (mul_le_mul_of_nonneg_left hcross (by norm_num : (0 : ℝ) ≤ 2)).trans |
| 1092 | - (by nlinarith [hlarge]) | |
| 1092 | + (by linarith [hlarge]) | |
| 1093 | 1093 | |
| 1094 | 1094 | def errorConstant (P m : ℝ) : ℝ := |
| 1095 | 1095 | 1 + prefixBoundConstant P m + correctionEnergyConstant P m + |
| @@ -1167,7 +1167,7 @@ theorem numerical_coefficient_bounds (d : OutgoingTail.TailData) (eta e : ℝ) | ||
| 1167 | 1167 | have hprod : (constantCorrection d.core + normalizedPrefixAxial d.core) * etaPolynomial eta ^ 2 ≤ 8 * e := by |
| 1168 | 1168 | have hm := mul_le_mul (add_le_add h.correction_error h.prefix_axial_error) hq2 |
| 1169 | 1169 | (sq_nonneg (etaPolynomial eta)) (by linarith [h.scale_nonneg]) |
| 1170 | - nlinarith | |
| 1170 | + linarith | |
| 1171 | 1171 | have hb : |linearTerm d.core eta| ≤ e * 2 := by |
| 1172 | 1172 | unfold linearTerm |
| 1173 | 1173 | rw [abs_mul] |
| @@ -1207,7 +1207,7 @@ theorem normalizedTail_derivative_bound (d : OutgoingTail.TailData) (eta : ℝ) | ||
| 1207 | 1207 | _ ≤ (OutgoingTail.flattenLength + 2 * TailEnergyBounds.tailConstant) * |
| 1208 | 1208 | logarithmicRate d.core.lam := by |
| 1209 | 1209 | unfold logarithmicRate |
| 1210 | - nlinarith | |
| 1210 | + linarith | |
| 1211 | 1211 | _ ≤ errorScale d.core := mul_le_mul_of_nonneg_right hC (logarithmicRate_pos d.core).le |
| 1212 | 1212 | |
| 1213 | 1213 | theorem linearTerm_hasDerivAt (c : Parameters) (eta : ℝ) : |
| @@ -1239,7 +1239,7 @@ theorem coefficient_derivative_bounds (d : OutgoingTail.TailData) (eta e : ℝ) | ||
| 1239 | 1239 | constructor |
| 1240 | 1240 | · rw [(linearTerm_hasDerivAt d.core eta).deriv, abs_mul, abs_of_nonneg hq'] |
| 1241 | 1241 | have hm := mul_le_mul h.linear_error hq4 hq' h.scale_nonneg |
| 1242 | - nlinarith | |
| 1242 | + linarith | |
| 1243 | 1243 | · rw [(constantTerm_hasDerivAt d eta).deriv] |
| 1244 | 1244 | calc |
| 1245 | 1245 | _ ≤ |2 * (constantCorrection d.core + normalizedPrefixAxial d.core) * |
| @@ -1252,7 +1252,7 @@ theorem coefficient_derivative_bounds (d : OutgoingTail.TailData) (eta e : ℝ) | ||
| 1252 | 1252 | (mul_le_mul (mul_le_mul_of_nonneg_left hsum' (by norm_num : (0 : ℝ) ≤ 2)) hq.1 |
| 1253 | 1253 | (abs_nonneg _) (by linarith [h.scale_nonneg])) hq4 hq' |
| 1254 | 1254 | (by linarith [h.scale_nonneg]) |
| 1255 | - nlinarith | |
| 1255 | + linarith | |
| 1256 | 1256 | _ = 33 * e := by ring |
| 1257 | 1257 | |
| 1258 | 1258 | theorem amplitude_derivative_bound_of_error (d : OutgoingTail.TailData) (eta e : ℝ) |
+59 −60 NavierStokes/PulseCone.lean View file
| @@ -38,11 +38,11 @@ theorem forcing_abs_le (c : Parameters) (hsmall : c.lam ≤ 1 / 120) (q A y : | ||
| 38 | 38 | simpa only [mul_one] using h |
| 39 | 39 | have hm : |A * mainPulse (c.lam * y)| ≤ mainBound * |A| := by |
| 40 | 40 | rw [abs_mul] |
| 41 | - nlinarith [mul_le_mul_of_nonneg_left (mainPulse_abs_le (c.lam * y)) (abs_nonneg A)] | |
| 41 | + linarith [mul_le_mul_of_nonneg_left (mainPulse_abs_le (c.lam * y)) (abs_nonneg A)] | |
| 42 | 42 | calc |
| 43 | 43 | _ ≤ |A * mainPulse (c.lam * y)| + |affineProfile c q A y| := abs_add_le _ _ |
| 44 | 44 | _ ≤ mainBound * |A| + correctionJetBound c.P c.m 0 * (|q| + |A|) := add_le_add hm hc' |
| 45 | - _ ≤ _ := by dsimp [forceConstant]; nlinarith [mul_nonneg mainBound_pos.le (abs_nonneg q)] | |
| 45 | + _ ≤ _ := by dsimp [forceConstant]; linarith [mul_nonneg mainBound_pos.le (abs_nonneg q)] | |
| 46 | 46 | |
| 47 | 47 | theorem initial_coefficient_le (c : Parameters) |
| 48 | 48 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) (hsmall : c.lam ≤ 1 / 120) : |
| @@ -55,7 +55,7 @@ theorem decay_div_le_three (c : Parameters) {M : ℝ} (hM : 0 ≤ M) : | ||
| 55 | 55 | M / decay c ≤ 3 * M := by |
| 56 | 56 | have hd : (2 / 5 : ℝ) ≤ decay c := by dsimp [decay]; linarith [c.lam_lt] |
| 57 | 57 | apply (div_le_iff₀ (decay_pos c)).mpr |
| 58 | - nlinarith [mul_nonneg hM (show 0 ≤ 3 * decay c - 1 by linarith)] | |
| 58 | + linarith [mul_nonneg hM (show 0 ≤ 3 * decay c - 1 by linarith)] | |
| 59 | 59 | |
| 60 | 60 | theorem affineLag_abs_le (c : Parameters) |
| 61 | 61 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) (hsmall : c.lam ≤ 1 / 120) |
| @@ -108,18 +108,18 @@ theorem pulse_data_bounds (c : Parameters) | ||
| 108 | 108 | constructor |
| 109 | 109 | · rw [← forcing_eq_pulseRatio c amp eta y] |
| 110 | 110 | apply (forcing_abs_le c hsmall _ _ y).trans |
| 111 | - nlinarith [mul_le_mul_of_nonneg_left (show |parameterPolynomial eta| + |amp eta| ≤ 6 by linarith) hf.le] | |
| 111 | + linarith [mul_le_mul_of_nonneg_left (show |parameterPolynomial eta| + |amp eta| ≤ 6 by linarith) hf.le] | |
| 112 | 112 | constructor |
| 113 | 113 | · rw [normalizedLag_eq_affineLag c amp eta hy] |
| 114 | 114 | apply (affineLag_abs_le c hwait hsmall _ _ hy).trans |
| 115 | 115 | dsimp [averageConstant] |
| 116 | 116 | have hs : |parameterPolynomial eta| + |amp eta| ≤ 6 := by linarith |
| 117 | - nlinarith [mul_le_mul_of_nonneg_left hq hp.le, mul_le_mul_of_nonneg_left hs hf.le] | |
| 117 | + linarith [mul_le_mul_of_nonneg_left hq hp.le, mul_le_mul_of_nonneg_left hs hf.le] | |
| 118 | 118 | · rw [(normalizedLag_eta_hasDerivAt c ha hy).deriv] |
| 119 | 119 | apply (affineLag_abs_le c hwait hsmall _ _ hy).trans |
| 120 | 120 | dsimp [averageConstant] |
| 121 | 121 | have hs : |1 + 3 * eta ^ 2| + |amp'| ≤ 6 := by linarith |
| 122 | - nlinarith [mul_le_mul_of_nonneg_left hq' hp.le, mul_le_mul_of_nonneg_left hs hf.le] | |
| 122 | + linarith [mul_le_mul_of_nonneg_left hq' hp.le, mul_le_mul_of_nonneg_left hs hf.le] | |
| 123 | 123 | |
| 124 | 124 | noncomputable def energyConstant (P m : ℝ) : ℝ := P * Real.exp (Real.exp m + 12) |
| 125 | 125 | |
| @@ -130,7 +130,7 @@ theorem shape_le_one (eta : ℝ) : shape eta ≤ 1 := by | ||
| 130 | 130 | unfold shape |
| 131 | 131 | rw [← one_div] |
| 132 | 132 | apply (div_le_one (by positivity : 0 < 1 + eta ^ 2)).mpr |
| 133 | - nlinarith [sq_nonneg eta] | |
| 133 | + linarith [sq_nonneg eta] | |
| 134 | 134 | |
| 135 | 135 | theorem pulse_angular_small (c : Parameters) |
| 136 | 136 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) (eta : ℝ) {y : ℝ} (hy : 0 ≤ y) : |
| @@ -182,8 +182,8 @@ theorem geometric_coefficient_bounds {h eta : ℝ} (hh : 0 ≤ h) (hh' : h ≤ 1 | ||
| 182 | 182 | (heta : |eta| ≤ 1) : |
| 183 | 183 | |2 * (1 / 2 - h) * eta - (1 - eta ^ 2) * shapeGradient eta| ≤ 3 ∧ |
| 184 | 184 | |1 - eta ^ 2| ≤ 1 ∧ |2 * h * eta + (1 - eta ^ 2) * shapeGradient eta| ≤ 3 := by |
| 185 | - have hs : eta ^ 2 ≤ 1 := by nlinarith [sq_abs eta, sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta] | |
| 186 | - have hd : |1 - eta ^ 2| ≤ 1 := by rw [abs_of_nonneg (by linarith)]; nlinarith [sq_nonneg eta] | |
| 185 | + have hs : eta ^ 2 ≤ 1 := by linarith [sq_abs eta, sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta] | |
| 186 | + have hd : |1 - eta ^ 2| ≤ 1 := by rw [abs_of_nonneg (by linarith)]; linarith [sq_nonneg eta] | |
| 187 | 187 | have hD : |1 / 2 - h| ≤ 1 / 2 := by rw [abs_of_nonneg (by linarith)]; linarith |
| 188 | 188 | have hg : |(1 - eta ^ 2) * shapeGradient eta| ≤ 2 := by |
| 189 | 189 | rw [abs_mul] |
| @@ -192,10 +192,10 @@ theorem geometric_coefficient_bounds {h eta : ℝ} (hh : 0 ≤ h) (hh' : h ≤ 1 | ||
| 192 | 192 | exact hm |
| 193 | 193 | have hDeta : |2 * (1 / 2 - h) * eta| ≤ 1 := by |
| 194 | 194 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 195 | - nlinarith [mul_le_mul hD heta (abs_nonneg eta) (by norm_num)] | |
| 195 | + linarith [mul_le_mul hD heta (abs_nonneg eta) (by norm_num)] | |
| 196 | 196 | have heta' : |2 * h * eta| ≤ 1 := by |
| 197 | 197 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2), abs_of_nonneg hh] |
| 198 | - nlinarith [mul_le_mul hh' heta (abs_nonneg eta) (by norm_num)] | |
| 198 | + linarith [mul_le_mul hh' heta (abs_nonneg eta) (by norm_num)] | |
| 199 | 199 | exact ⟨(abs_sub _ _).trans (by linarith), hd, (abs_add_le _ _).trans (by linarith)⟩ |
| 200 | 200 | |
| 201 | 201 | noncomputable def pulseAngularSource (c : Parameters) (h : ℝ) (amp : ℝ → ℝ) (eta y : ℝ) : ℝ := |
| @@ -249,7 +249,7 @@ theorem pulseAngularSource_error_bound (c : Parameters) | ||
| 249 | 249 | positivity |
| 250 | 250 | have he := mul_le_mul_of_nonneg_right (pulse_angular_small c hwait eta hy) hp |
| 251 | 251 | dsimp [sourceConstant] |
| 252 | - nlinarith | |
| 252 | + linarith | |
| 253 | 253 | |
| 254 | 254 | theorem pulseAngularSource_lower (d : OutgoingTail.TailData) |
| 255 | 255 | (hwait : d.core.wait = 60 * Real.log (1 / d.core.lam)) (hsmall : d.core.lam ≤ 1 / 120) |
| @@ -271,7 +271,7 @@ theorem pulseAngularSource_lower (d : OutgoingTail.TailData) | ||
| 271 | 271 | positivity |
| 272 | 272 | have hc := mul_nonneg (show 0 ≤ 1 / 2 - d.h by linarith [d.h_lt_half]) hg |
| 273 | 273 | have hlo := (abs_le.mp he).1 |
| 274 | - nlinarith [d.h_small] | |
| 274 | + linarith [d.h_small] | |
| 275 | 275 | |
| 276 | 276 | /-- A lower barrier for the exact scalar lag equation on a finite interval. |
| 277 | 277 | Only the differential equation and a lower source bound are used. -/ |
| @@ -339,7 +339,7 @@ theorem pulse_endpoint_lower (c : Parameters) {Q S : ℝ → ℝ} (hQ₀ : 0 ≤ | ||
| 339 | 339 | have hmain := mul_le_mul hdiv (show (2 / 3 : ℝ) ≤ 1 - Real.exp (-(1 - c.lam) * c.pulseLength) by linarith) |
| 340 | 340 | (by norm_num : (0 : ℝ) ≤ 2 / 3) hpos |
| 341 | 341 | have hini := mul_nonneg hQ₀ he.le |
| 342 | - nlinarith | |
| 342 | + linarith | |
| 343 | 343 | |
| 344 | 344 | /-! ## Binding the pulse formulas to the actual corrected histories -/ |
| 345 | 345 | |
| @@ -512,9 +512,9 @@ theorem ode_equilibrium_error {r s δ L : ℝ} (hr : 0 < r) (hδ : 0 ≤ δ) (hL | ||
| 512 | 512 | rw [abs_le] |
| 513 | 513 | constructor |
| 514 | 514 | · rw [sub_div] at hlo |
| 515 | - nlinarith | |
| 515 | + linarith | |
| 516 | 516 | · rw [neg_div, add_div] at hhi |
| 517 | - nlinarith | |
| 517 | + linarith | |
| 518 | 518 | |
| 519 | 519 | /-- Uniform angular-lag error throughout the actual pulse; the incoming |
| 520 | 520 | error is retained explicitly for the shaped-wait theorem to supply. -/ |
| @@ -567,7 +567,7 @@ theorem corrected_Qs_endpoint_lower (w : ResetWitness d K) (hK : 0 < K) | ||
| 567 | 567 | have hs := CorrectedPulseAmplitude.amplitude_spec w hK hsmall hwait hscale |
| 568 | 568 | have heta₂ : eta ^ 2 ≤ 1 := by |
| 569 | 569 | have h := (sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1)).mpr heta |
| 570 | - nlinarith [sq_abs eta] | |
| 570 | + linarith [sq_abs eta] | |
| 571 | 571 | have hb := hs.2 eta heta₂ |
| 572 | 572 | apply Qs_endpoint_lower w hwait hsmall hpulse hh₁ hhT hs.1 heta |
| 573 | 573 | · rw [abs_of_pos (CorrectedPulseAmplitude.amplitude_pos d w.coefficients eta)] |
| @@ -743,7 +743,7 @@ theorem mainPulse_deriv_le_one {z : ℝ} (hz : 0 ≤ z) : deriv mainPulse z ≤ | ||
| 743 | 743 | (sub_nonneg.mpr (sigma_le_one (z - 10))) zero_le_one |
| 744 | 744 | have hcut := mul_nonneg (PulseAmplitude.pulseRamp_nonneg hz) |
| 745 | 745 | (OutgoingTail.sigma_derivative_nonneg (z - 10)) |
| 746 | - nlinarith | |
| 746 | + linarith | |
| 747 | 747 | |
| 748 | 748 | noncomputable def mainFirstBound : ℝ := 1 + Classical.choose |
| 749 | 749 | (LocalizedMomentRepair.smooth_compact_derivative_bound mainPulse |
| @@ -832,14 +832,14 @@ theorem scaledPulse_deriv_abs_le (c : Parameters) (hsmall : c.lam ≤ 1 / 120) | ||
| 832 | 832 | have hm : |amp eta * deriv mainPulse (c.lam * y)| ≤ 2 * mainFirstBound := by |
| 833 | 833 | rw [abs_mul] |
| 834 | 834 | exact (mul_le_mul hamp (main_first_le _) (abs_nonneg _) (by norm_num)).trans |
| 835 | - (by nlinarith [mainFirstBound_pos]) | |
| 835 | + (by linarith [mainFirstBound_pos]) | |
| 836 | 836 | have hc := mul_le_mul_of_nonneg_left (show c.lam ≤ 1 by linarith [c.lam_lt]) |
| 837 | 837 | (derivativeRepairConstant_pos c.P_pos c.m).le |
| 838 | 838 | have htriangle := abs_add_le (deriv (scaledPulse c amp eta) (c.lam * y) - |
| 839 | 839 | amp eta * deriv mainPulse (c.lam * y)) (amp eta * deriv mainPulse (c.lam * y)) |
| 840 | 840 | rw [sub_add_cancel] at htriangle |
| 841 | 841 | dsimp [derivativeConstant] |
| 842 | - nlinarith | |
| 842 | + linarith | |
| 843 | 843 | |
| 844 | 844 | theorem forcing_fine_abs_le (c : Parameters) (hsmall : c.lam ≤ 1 / 120) (q A y : ℝ) : |
| 845 | 845 | |forcing c q A y| ≤ mainBound * |A| + |
| @@ -851,10 +851,10 @@ theorem forcing_fine_abs_le (c : Parameters) (hsmall : c.lam ≤ 1 / 120) (q A y | ||
| 851 | 851 | (correctionJetBound_pos c.P_pos c.m 0).le) (by positivity : 0 ≤ |q| + |A|) |
| 852 | 852 | have hm : |A * mainPulse (c.lam * y)| ≤ mainBound * |A| := by |
| 853 | 853 | rw [abs_mul] |
| 854 | - nlinarith [mul_le_mul_of_nonneg_left (mainPulse_abs_le (c.lam * y)) (abs_nonneg A)] | |
| 854 | + linarith [mul_le_mul_of_nonneg_left (mainPulse_abs_le (c.lam * y)) (abs_nonneg A)] | |
| 855 | 855 | apply (abs_add_le _ _).trans |
| 856 | 856 | change |A * mainPulse (c.lam * y)| + |affineProfile c q A y| ≤ _ |
| 857 | - nlinarith | |
| 857 | + linarith | |
| 858 | 858 | |
| 859 | 859 | theorem affineLag_fine_abs_le (c : Parameters) |
| 860 | 860 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) (hsmall : c.lam ≤ 1 / 120) |
| @@ -871,7 +871,7 @@ theorem affineLag_fine_abs_le (c : Parameters) | ||
| 871 | 871 | have ht := abs_add_le ((prefixCoefficient c 0 * q) * Real.exp (-decay c * y)) |
| 872 | 872 | (convolution (decay c) (forcing c q A) y) |
| 873 | 873 | change |affineLag c q A y| ≤ _ at ht |
| 874 | - nlinarith | |
| 874 | + linarith | |
| 875 | 875 | |
| 876 | 876 | noncomputable def parameterLagConstant (P m : ℝ) : ℝ := |
| 877 | 877 | 4 * prefixBound P m 0 + 960 * correctionJetBound P m 0 |
| @@ -901,7 +901,7 @@ theorem normalizedLag_parameter_fine_bound (c : Parameters) | ||
| 901 | 901 | have hcoeff : prefixBound c.P c.m 0 * |1 + 3 * eta ^ 2| + |
| 902 | 902 | 192 * correctionJetBound c.P c.m 0 * (|1 + 3 * eta ^ 2| + |amp'|) ≤ parameterLagConstant c.P c.m := by |
| 903 | 903 | dsimp [parameterLagConstant] |
| 904 | - nlinarith | |
| 904 | + linarith | |
| 905 | 905 | exact add_le_add_right (mul_le_mul_of_nonneg_right hcoeff (sq_nonneg c.lam)) _ |
| 906 | 906 | |
| 907 | 907 | /-! ## The coefficient in the pulse-direction expansion -/ |
| @@ -933,11 +933,11 @@ theorem eta_shapeGradient_bounds {eta : ℝ} (heta : |eta| ≤ 1) : | ||
| 933 | 933 | ring |
| 934 | 934 | have hs : eta ^ 2 ≤ 1 := by |
| 935 | 935 | have h := (sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1)).mpr heta |
| 936 | - nlinarith [sq_abs eta] | |
| 936 | + linarith [sq_abs eta] | |
| 937 | 937 | rw [he] |
| 938 | 938 | constructor |
| 939 | 939 | · apply (le_div_iff₀ (by positivity : 0 < 1 + eta ^ 2)).mpr |
| 940 | - nlinarith [mul_nonneg (sq_nonneg eta) (sub_nonneg.mpr hs)] | |
| 940 | + linarith [mul_nonneg (sq_nonneg eta) (sub_nonneg.mpr hs)] | |
| 941 | 941 | · apply (div_le_iff₀ (by positivity : 0 < 1 + eta ^ 2)).mpr |
| 942 | 942 | linarith |
| 943 | 943 | |
| @@ -960,7 +960,7 @@ theorem pulse_geometric_bounds (d : TailData) {eta : ℝ} (heta : |eta| ≤ 1) : | ||
| 960 | 960 | have hc₂ := mul_le_mul_of_nonneg_left hg₂ (show 0 ≤ 1 / 2 - d.h by linarith) |
| 961 | 961 | have hc₃ := mul_le_mul_of_nonneg_right hD (sq_nonneg eta) |
| 962 | 962 | dsimp [geometricSource, equilibriumNumerator] at * |
| 963 | - constructor <;> nlinarith [d.h_pos, d.h_small] | |
| 963 | + constructor <;> linarith [d.h_pos, d.h_small] | |
| 964 | 964 | |
| 965 | 965 | theorem derivativeCoefficient_nonneg (d : TailData) (eta : ℝ) : |
| 966 | 966 | 0 ≤ derivativeCoefficient d eta := by |
| @@ -979,7 +979,7 @@ theorem derivativeCoefficient_le (d : TailData) | ||
| 979 | 979 | have hb : (49999 / 100000 : ℝ) ≤ decay d.core := by dsimp [decay]; linarith |
| 980 | 980 | have hb₂ := pow_le_pow_left₀ (by norm_num : (0 : ℝ) ≤ 49999 / 100000) hb 2 |
| 981 | 981 | have hbase : (1 / 2 : ℝ) ≤ (2001 / 1000) * decay d.core ^ 2 * (99999 / 100000) := by |
| 982 | - nlinarith | |
| 982 | + linarith | |
| 983 | 983 | have hg := geometricSource_nonneg d eta |
| 984 | 984 | have hD : 0 ≤ 1 / 2 - d.h := by linarith [d.h_lt_half] |
| 985 | 985 | have hA : (99999 / 100000) * d.core.lam + geometricSource d eta ≤ equilibriumNumerator d eta := by |
| @@ -990,15 +990,15 @@ theorem derivativeCoefficient_le (d : TailData) | ||
| 990 | 990 | have hm := mul_le_mul_of_nonneg_left (show 1 - d.core.lam ≤ 1 by linarith [d.core.lam_pos]) |
| 991 | 991 | (mul_nonneg d.core.lam_pos.le (add_nonneg hD hg)) |
| 992 | 992 | have hh' := mul_le_mul_of_nonneg_left d.h_pos.le d.core.lam_pos.le |
| 993 | - nlinarith | |
| 993 | + linarith | |
| 994 | 994 | have hbase' := mul_le_mul_of_nonneg_right hbase d.core.lam_pos.le |
| 995 | - have hc : d.core.lam ≤ (2001 / 1000) * decay d.core ^ 2 := by nlinarith [d.core.lam_pos] | |
| 995 | + have hc : d.core.lam ≤ (2001 / 1000) * decay d.core ^ 2 := by linarith [d.core.lam_pos] | |
| 996 | 996 | have hc' := mul_le_mul_of_nonneg_right hc hg |
| 997 | 997 | have hA' := mul_le_mul_of_nonneg_left hA |
| 998 | 998 | (show 0 ≤ (2001 / 1000) * decay d.core ^ 2 by positivity) |
| 999 | 999 | unfold derivativeCoefficient |
| 1000 | 1000 | apply (div_le_iff₀ (mul_pos (sq_pos_of_pos (decay_pos d.core)) (equilibriumNumerator_pos d eta))).mpr |
| 1001 | - nlinarith | |
| 1001 | + linarith | |
| 1002 | 1002 | |
| 1003 | 1003 | noncomputable def mainDirection (d : TailData) (amp : ℝ → ℝ) (eta y : ℝ) : ℝ := |
| 1004 | 1004 | ((1 - d.core.lam) / decay d.core) * pulseRatio d.core amp (y, eta) - |
| @@ -1041,19 +1041,19 @@ theorem Ns_pulse_expansion (w : ResetWitness d K) {amp : ℝ → ℝ} | ||
| 1041 | 1041 | |
| 1042 | 1042 | theorem first_quadratic_margin (R : ℝ) : |
| 1043 | 1043 | -2 * R ^ 2 + (241 / 100) * R ≤ 73 / 100 := by |
| 1044 | - nlinarith [sq_nonneg (R - 241 / 400)] | |
| 1044 | + linarith [sq_nonneg (R - 241 / 400)] | |
| 1045 | 1045 | |
| 1046 | 1046 | theorem second_quadratic_margin (R : ℝ) : |
| 1047 | 1047 | -(7 / 2) * R ^ 2 + (241 / 50) * R ≤ 167 / 100 := by |
| 1048 | - nlinarith [sq_nonneg (R - 241 / 350)] | |
| 1048 | + linarith [sq_nonneg (R - 241 / 350)] | |
| 1049 | 1049 | |
| 1050 | 1050 | theorem ideal_cross_bound {R C Z : ℝ} (hR : 0 ≤ R) (hC : 0 ≤ C) |
| 1051 | 1051 | (hC' : C ≤ 2001 / 1000) (hZ : Z ≤ 6 / 5) : |
| 1052 | 1052 | -R * (2 * R - C * Z) ≤ -2 * R ^ 2 + (241 / 100) * R := by |
| 1053 | 1053 | have hc := mul_le_mul_of_nonneg_left hZ hC |
| 1054 | - have hcz : C * Z ≤ 241 / 100 := by nlinarith | |
| 1054 | + have hcz : C * Z ≤ 241 / 100 := by linarith | |
| 1055 | 1055 | have hm := mul_le_mul_of_nonneg_left hcz hR |
| 1056 | - nlinarith | |
| 1056 | + linarith | |
| 1057 | 1057 | |
| 1058 | 1058 | noncomputable def coneErrorBudget (F M eps lam : ℝ) : ℝ := |
| 1059 | 1059 | 2 * eps * (M + F + 1) + eps * (2 * F + 1) / 2 + 2 * lam * (M + 1) ^ 2 |
| @@ -1086,7 +1086,7 @@ theorem perturbed_cone_margins {lam R C Z b v eps F M : ℝ} | ||
| 1086 | 1086 | rw [abs_mul, abs_mul, abs_of_nonneg hR] |
| 1087 | 1087 | have h₁ := mul_le_mul hb hvabs (abs_nonneg v) heps |
| 1088 | 1088 | have h₂ := mul_le_mul hR' hv (abs_nonneg _) hF |
| 1089 | - nlinarith | |
| 1089 | + linarith | |
| 1090 | 1090 | have hdiff : |b - R| ≤ 2 * F + 1 := by |
| 1091 | 1091 | have h := abs_sub b R |
| 1092 | 1092 | rw [abs_of_nonneg hR] at h |
| @@ -1117,7 +1117,7 @@ theorem perturbed_cone_margins {lam R C Z b v eps F M : ℝ} | ||
| 1117 | 1117 | _ = _ := by ring |
| 1118 | 1118 | constructor |
| 1119 | 1119 | · have herr : eps * (M + F + 1) ≤ 1 / 200 := by |
| 1120 | - nlinarith only [hbudget, hnonneg₁, hnonneg₂] | |
| 1120 | + linarith only [hbudget, hnonneg₁, hnonneg₂] | |
| 1121 | 1121 | calc |
| 1122 | 1122 | _ ≤ -2 * R ^ 2 + (241 / 100) * R + eps * (M + F + 1) := hcrossBound |
| 1123 | 1123 | _ ≤ 73 / 100 + 1 / 200 := add_le_add (first_quadratic_margin R) herr |
| @@ -1219,12 +1219,12 @@ theorem axialHistoryError_bound (w : ResetWitness d K) | ||
| 1219 | 1219 | have ha' : |4 * d.h * eta| ≤ 2 := by |
| 1220 | 1220 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 4), abs_of_pos d.h_pos] |
| 1221 | 1221 | have h := mul_le_mul d.h_lt_half.le heta (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1 / 2) |
| 1222 | - nlinarith | |
| 1222 | + linarith | |
| 1223 | 1223 | have hc' : |4 * (1 / 2 + d.h) * eta| ≤ 4 := by |
| 1224 | 1224 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 4), |
| 1225 | 1225 | abs_of_pos (by linarith [d.h_pos] : 0 < 1 / 2 + d.h)] |
| 1226 | 1226 | have h := mul_le_mul (show 1 / 2 + d.h ≤ 1 by linarith [d.h_lt_half]) heta (abs_nonneg eta) zero_le_one |
| 1227 | - nlinarith | |
| 1227 | + linarith | |
| 1228 | 1228 | have hw' : |(1 - W d amp p) / E w p| ≤ 4 * averageConstant d.core.P d.core.m := by |
| 1229 | 1229 | rw [abs_div, abs_of_pos hE] |
| 1230 | 1230 | exact (div_le_iff₀ hE).mpr hW |
| @@ -1287,8 +1287,7 @@ theorem axialHistoryError_bound (w : ResetWitness d K) | ||
| 1287 | 1287 | calc |
| 1288 | 1288 | _ ≤ E w p * (A + B) / d.core.lam := by |
| 1289 | 1289 | simpa only [mul_div_assoc] using hb'.trans (mul_le_mul_of_nonneg_left hAB hE.le) |
| 1290 | - _ ≤ (energyConstant d.core.P d.core.m * d.core.lam ^ 30) * (A + B) / d.core.lam := by | |
| 1291 | - exact div_le_div_of_nonneg_right (mul_le_mul_of_nonneg_right he (add_nonneg hA hB)) d.core.lam_pos.le | |
| 1290 | + _ ≤ (energyConstant d.core.P d.core.m * d.core.lam ^ 30) * (A + B) / d.core.lam := div_le_div_of_nonneg_right (mul_le_mul_of_nonneg_right he (add_nonneg hA hB)) d.core.lam_pos.le | |
| 1292 | 1291 | _ = axialErrorConstant d.core.P d.core.m * d.core.lam ^ 29 := by |
| 1293 | 1292 | have hc : axialErrorConstant d.core.P d.core.m = energyConstant d.core.P d.core.m * (A + B) := by |
| 1294 | 1293 | dsimp [axialErrorConstant, A, B] |
| @@ -1303,12 +1302,12 @@ theorem denominator_bounds (d : TailData) {eta Q : ℝ} (heta : |eta| ≤ 1) | ||
| 1303 | 1302 | 0 < Q ∧ 1 / Q ≤ 4 / d.core.lam ∧ |eta| / Q ≤ 4 / Real.sqrt d.core.lam := by |
| 1304 | 1303 | have hA := (pulse_geometric_bounds d heta).2 |
| 1305 | 1304 | have hq : d.core.lam / 4 + eta ^ 2 / 5 ≤ Q := by linarith |
| 1306 | - have hQpos : 0 < Q := by nlinarith [d.core.lam_pos, sq_nonneg eta] | |
| 1305 | + have hQpos : 0 < Q := by linarith [d.core.lam_pos, sq_nonneg eta] | |
| 1307 | 1306 | have hs := Real.sqrt_pos.mpr d.core.lam_pos |
| 1308 | 1307 | have hs₂ := Real.sq_sqrt d.core.lam_pos.le |
| 1309 | 1308 | refine ⟨hQpos, ?_, ?_⟩ |
| 1310 | 1309 | · apply (div_le_div_iff₀ hQpos d.core.lam_pos).mpr |
| 1311 | - nlinarith [sq_nonneg eta] | |
| 1310 | + linarith [sq_nonneg eta] | |
| 1312 | 1311 | · apply (div_le_div_iff₀ hQpos hs).mpr |
| 1313 | 1312 | nlinarith [sq_nonneg (Real.sqrt d.core.lam - |eta| / 2), sq_abs eta] |
| 1314 | 1313 | |
| @@ -1348,7 +1347,7 @@ theorem mainDirection_abs_le (d : TailData) | ||
| 1348 | 1347 | apply (abs_sub _ _).trans |
| 1349 | 1348 | rw [abs_mul, abs_mul, abs_of_nonneg hr₀, abs_of_nonneg hc₀] |
| 1350 | 1349 | dsimp [mainDirectionBound] |
| 1351 | - nlinarith | |
| 1350 | + linarith | |
| 1352 | 1351 | |
| 1353 | 1352 | private theorem quotient_remainder_bound |
| 1354 | 1353 | {N Q q B C D eta e m H eQ eE eM eH BM I J : ℝ} |
| @@ -1449,11 +1448,11 @@ theorem main_profile_bounds (d : TailData) | ||
| 1449 | 1448 | rw [mainRatio, abs_mul] |
| 1450 | 1449 | have h := mul_le_mul hamp (mainPulse_abs_le (d.core.lam * y)) (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 6 / 5) |
| 1451 | 1450 | dsimp [mainRatioBound] |
| 1452 | - nlinarith [mainBound_pos] | |
| 1451 | + linarith [mainBound_pos] | |
| 1453 | 1452 | have hZ : |mainSlope d.core amp eta y| ≤ 2 * mainFirstBound := by |
| 1454 | 1453 | rw [mainSlope, abs_mul] |
| 1455 | 1454 | have h := mul_le_mul hamp (main_first_le (d.core.lam * y)) (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 6 / 5) |
| 1456 | - nlinarith [mainFirstBound_pos] | |
| 1455 | + linarith [mainFirstBound_pos] | |
| 1457 | 1456 | have hZup := mul_le_mul_of_nonneg_left |
| 1458 | 1457 | (mainPulse_deriv_le_one (mul_nonneg d.core.lam_pos.le hy)) hamp₀ |
| 1459 | 1458 | have hCd : |derivativeCoefficient d eta| ≤ 3 := by |
| @@ -1468,7 +1467,7 @@ theorem main_profile_bounds (d : TailData) | ||
| 1468 | 1467 | apply (abs_sub _ _).trans |
| 1469 | 1468 | rw [abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2), abs_mul] |
| 1470 | 1469 | dsimp [idealDirectionBound, mainRatioBound] at * |
| 1471 | - nlinarith | |
| 1470 | + linarith | |
| 1472 | 1471 | |
| 1473 | 1472 | theorem pulseRatio_abs_le (c : Parameters) (hsmall : c.lam ≤ 1 / 120) |
| 1474 | 1473 | (amp : ℝ → ℝ) {eta : ℝ} (heta : |eta| ≤ 1) (hamp : |amp eta| ≤ 6 / 5) (y : ℝ) : |
| @@ -1523,7 +1522,7 @@ theorem shearB_main_error (w : ResetWitness d K) (hsmall : d.core.lam ≤ 1 / 12 | ||
| 1523 | 1522 | have hm := mul_le_mul_of_nonneg_left hdiff (show 0 ≤ 2 * d.core.lam by linarith [d.core.lam_pos]) |
| 1524 | 1523 | dsimp only [mainRatio] at * |
| 1525 | 1524 | dsimp [shearErrorConstant] |
| 1526 | - nlinarith | |
| 1525 | + linarith | |
| 1527 | 1526 | |
| 1528 | 1527 | theorem mainDirection_ideal_error (d : TailData) |
| 1529 | 1528 | (hsmall : d.core.lam ≤ 1 / 100000) (hh : d.h ≤ d.core.lam / 100000) |
| @@ -1556,7 +1555,7 @@ theorem mainDirection_ideal_error (d : TailData) | ||
| 1556 | 1555 | apply (add_le_add_left (abs_add_le _ _) _).trans |
| 1557 | 1556 | rw [abs_mul, abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 1558 | 1557 | dsimp [directionMainErrorConstant, mainRatio, mainSlope] at * |
| 1559 | - nlinarith | |
| 1558 | + linarith | |
| 1560 | 1559 | |
| 1561 | 1560 | /-! ## The shaped wait supplies the actual angular equilibrium error -/ |
| 1562 | 1561 | |
| @@ -1572,7 +1571,7 @@ theorem canonical_wait_for_power28 (c : Parameters) | ||
| 1572 | 1571 | have h := PulseAmplitude.log_inverse_nonneg c |
| 1573 | 1572 | simpa only [one_div, Real.log_inv] using h |
| 1574 | 1573 | have hm := mul_nonneg hl (show 0 ≤ (1 : ℝ) / 10 - c.lam by linarith [c.lam_lt]) |
| 1575 | - nlinarith | |
| 1574 | + linarith | |
| 1576 | 1575 | |
| 1577 | 1576 | noncomputable def angularErrorConstant (P m : ℝ) : ℝ := 19 + 2 * sourceConstant P m |
| 1578 | 1577 | |
| @@ -1613,7 +1612,7 @@ theorem actual_Qs_pulse_error (w : ResetWitness d K) | ||
| 1613 | 1612 | apply (div_le_iff₀ hr).mpr |
| 1614 | 1613 | nlinarith only [hs, hfac'] |
| 1615 | 1614 | dsimp [angularErrorConstant] |
| 1616 | - nlinarith only [hb, hiprod, hc] | |
| 1615 | + linarith only [hb, hiprod, hc] | |
| 1617 | 1616 | |
| 1618 | 1617 | theorem actual_Qs_pulse_lower (w : ResetWitness d K) |
| 1619 | 1618 | (hwait : d.core.wait = 60 * Real.log (1 / d.core.lam)) (hsmall : d.core.lam ≤ 1 / 120) |
| @@ -1630,9 +1629,9 @@ theorem actual_Qs_pulse_lower (w : ResetWitness d K) | ||
| 1630 | 1629 | have hA := (pulse_geometric_bounds d heta).2 |
| 1631 | 1630 | have heq : equilibriumNumerator d eta ≤ angularEquilibrium d eta := by |
| 1632 | 1631 | apply (le_div_iff₀ (show 0 < 1 - d.core.lam by linarith [d.core.lam_lt])).mpr |
| 1633 | - nlinarith [mul_nonneg (equilibriumNumerator_pos d eta).le d.core.lam_pos.le] | |
| 1632 | + linarith [mul_nonneg (equilibriumNumerator_pos d eta).le d.core.lam_pos.le] | |
| 1634 | 1633 | have hlo := (abs_le.mp he).1 |
| 1635 | - nlinarith [sq_nonneg eta] | |
| 1634 | + linarith [sq_nonneg eta] | |
| 1636 | 1635 | |
| 1637 | 1636 | /-! ## A single explicit vanishing rate for the cone errors -/ |
| 1638 | 1637 | |
| @@ -1682,7 +1681,7 @@ private theorem raw_error_le_rate {lam Q B M H P A F v : ℝ} | ||
| 1682 | 1681 | (Q * B + M + H) * lam ^ 2 := by |
| 1683 | 1682 | have h₁ := mul_le_mul_of_nonneg_left hp28 (mul_nonneg hQ hB) |
| 1684 | 1683 | have h₂ := mul_le_mul_of_nonneg_left hp29 hH |
| 1685 | - nlinarith only [h₁, h₂] | |
| 1684 | + linarith only [h₁, h₂] | |
| 1686 | 1685 | have hfirst : (4 / lam) * (Q * lam ^ 28 * B + M * lam ^ 2 + H * lam ^ 29) ≤ |
| 1687 | 1686 | 4 * (Q * B + M + H) * lam := by |
| 1688 | 1687 | have h := mul_le_mul_of_nonneg_left hfirstInside (by positivity : 0 ≤ 4 / lam) |
| @@ -1699,7 +1698,7 @@ private theorem raw_error_le_rate {lam Q B M H P A F v : ℝ} | ||
| 1699 | 1698 | have hp2 : lam ^ 2 / Real.sqrt lam ≤ lam := by |
| 1700 | 1699 | apply (div_le_iff₀ hs).mpr |
| 1701 | 1700 | have hl : lam ≤ Real.sqrt lam := Real.le_sqrt_of_sq_le (by nlinarith only [hlam, hsmall]) |
| 1702 | - nlinarith only [mul_le_mul_of_nonneg_left hl hlam.le] | |
| 1701 | + linarith only [mul_le_mul_of_nonneg_left hl hlam.le] | |
| 1703 | 1702 | have hsecond : (4 / Real.sqrt lam) * (3 * F * v + P * lam ^ 2) ≤ |
| 1704 | 1703 | 12 * F * A * (Real.sqrt lam * (1 + Real.log (1 / lam))) + 4 * P * lam := by |
| 1705 | 1704 | have h₁ := mul_le_mul_of_nonneg_left hv' (mul_nonneg (by norm_num : (0 : ℝ) ≤ 12) hF) |
| @@ -1714,7 +1713,7 @@ private theorem raw_error_le_rate {lam Q B M H P A F v : ℝ} | ||
| 1714 | 1713 | (show 0 ≤ 4 * (Q * B + M + H + P) by positivity) |
| 1715 | 1714 | have hparameter := mul_le_mul_of_nonneg_left hr.2.2 |
| 1716 | 1715 | (show 0 ≤ 12 * F * A by positivity) |
| 1717 | - nlinarith only [hfirst, hsecond, hlinear, hparameter] | |
| 1716 | + linarith only [hfirst, hsecond, hlinear, hparameter] | |
| 1718 | 1717 | |
| 1719 | 1718 | noncomputable def directionErrorConstant (P m A : ℝ) : ℝ := |
| 1720 | 1719 | 4 * (angularErrorConstant P m * mainDirectionBound P m + fullLagBound P m + |
| @@ -1801,7 +1800,7 @@ private theorem cone_budget_eps_le_one {F M eps lam : ℝ} | ||
| 1801 | 1800 | have h₂ : 0 ≤ eps * (2 * F + 1) / 2 := by positivity |
| 1802 | 1801 | have h₃ : 0 ≤ 2 * lam * (M + 1) ^ 2 := by positivity |
| 1803 | 1802 | dsimp [coneErrorBudget] at hb |
| 1804 | - nlinarith only [h₁, h₂, h₃, hb] | |
| 1803 | + linarith only [h₁, h₂, h₃, hb] | |
| 1805 | 1804 | |
| 1806 | 1805 | /-- The numerical margins refer only to the actual global stress histories |
| 1807 | 1806 | and the actual first radial derivatives of the corrected fields. -/ |
| @@ -1824,7 +1823,7 @@ theorem PulseConeAt.true_criterion {w : ResetWitness d K} {amp : ℝ → ℝ} {p | ||
| 1824 | 1823 | refine ⟨?_, ?_, ?_⟩ |
| 1825 | 1824 | · linarith [h.first_margin] |
| 1826 | 1825 | · linarith [h.second_margin] |
| 1827 | - · nlinarith only [ha, hmul] | |
| 1826 | + · linarith only [ha, hmul] | |
| 1828 | 1827 | |
| 1829 | 1828 | /-- The full pulse cone for any smooth amplitude with the proved size and |
| 1830 | 1829 | first-derivative rate. Every further hypothesis is a scalar parameter bound. -/ |
| @@ -1881,7 +1880,7 @@ theorem corrected_pulse_cone (w : ResetWitness d K) (hK : 0 < K) | ||
| 1881 | 1880 | have hs := CorrectedPulseAmplitude.amplitude_spec w hK (by linarith) hwait hscale |
| 1882 | 1881 | have heta₂ : eta ^ 2 ≤ 1 := by |
| 1883 | 1882 | have h := (sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1)).mpr heta |
| 1884 | - nlinarith [sq_abs eta] | |
| 1883 | + linarith [sq_abs eta] | |
| 1885 | 1884 | have hb := hs.2 eta heta₂ |
| 1886 | 1885 | have hamp : |CorrectedPulseAmplitude.amplitude d w.coefficients eta| ≤ 6 / 5 := by |
| 1887 | 1886 | rw [abs_of_pos (CorrectedPulseAmplitude.amplitude_pos d w.coefficients eta)] |
| @@ -1951,7 +1950,7 @@ theorem exists_corrected_pulse_threshold (P m K : ℝ) (hP : 0 < P) (hK : 0 < K) | ||
| 1951 | 1950 | (show d.core.lam ≤ 1 by linarith) (show 1 ≤ 27 by norm_num) |
| 1952 | 1951 | have hm := mul_le_mul_of_nonneg_left hp hC.le |
| 1953 | 1952 | have hd := (le_div_iff₀ (show 0 < 4 * angularErrorConstant P m by positivity)).mp hCsmall |
| 1954 | - nlinarith only [hm, hd] | |
| 1953 | + linarith only [hm, hd] | |
| 1955 | 1954 | have hscale' : CorrectedPulseAmplitude.combinedScale d K ≤ 1 / 1000 := by |
| 1956 | 1955 | dsimp [CorrectedPulseAmplitude.combinedScale] |
| 1957 | 1956 | rw [hdP, hdm] |
+13 −13 NavierStokes/PulseCovariance.lean View file
| @@ -169,7 +169,7 @@ theorem weight_gaussian_upper (v : ℝ) : | ||
| 169 | 169 | weight ψ x v ≤ A ^ 2 * gaussian (2 * b) (r ^ 2 / 2) r v := by |
| 170 | 170 | by_cases hv : v ∈ Icc (r ^ 2 / 6) (5 * r ^ 2 / 6) |
| 171 | 171 | · have hslot : v ∈ Icc 0 (r ^ 2) := by |
| 172 | - constructor <;> nlinarith [hv.1, hv.2, sq_nonneg r] | |
| 172 | + constructor <;> linarith [hv.1, hv.2, sq_nonneg r] | |
| 173 | 173 | have hx := h.component_upper v hslot |
| 174 | 174 | have hx0 := (h.component_pos hslot).le |
| 175 | 175 | have hg := (gaussian_pos b (r ^ 2 / 2) r v).le |
| @@ -185,7 +185,7 @@ theorem weight_gaussian_upper (v : ℝ) : | ||
| 185 | 185 | calc |
| 186 | 186 | weight ψ x v ≤ x v ^ 2 := by |
| 187 | 187 | unfold weight |
| 188 | - nlinarith [mul_le_mul_of_nonneg_right hψ (sq_nonneg (x v))] | |
| 188 | + linarith [mul_le_mul_of_nonneg_right hψ (sq_nonneg (x v))] | |
| 189 | 189 | _ ≤ (A * gaussian b (r ^ 2 / 2) r v) ^ 2 := |
| 190 | 190 | pow_le_pow_left₀ hx0 hx 2 |
| 191 | 191 | _ = A ^ 2 * gaussian (2 * b) (r ^ 2 / 2) r v := by rw [mul_pow, he] |
| @@ -208,7 +208,7 @@ theorem moment_integrable : | ||
| 208 | 208 | rw [Real.norm_eq_abs, abs_of_nonneg |
| 209 | 209 | (mul_nonneg (abs_nonneg _) (weight_nonneg v))] |
| 210 | 210 | simp only [id_eq] |
| 211 | - nlinarith [mul_le_mul_of_nonneg_left (h.weight_gaussian_upper v) (abs_nonneg (v - r ^ 2 / 2))] | |
| 211 | + linarith [mul_le_mul_of_nonneg_left (h.weight_gaussian_upper v) (abs_nonneg (v - r ^ 2 / 2))] | |
| 212 | 212 | |
| 213 | 213 | theorem mass_upper : mass ψ x ≤ A ^ 2 * Real.sqrt (Real.pi / (2 * b)) * r := by |
| 214 | 214 | have hi := integral_mono h.weight_integrable |
| @@ -231,8 +231,8 @@ theorem core_mem_middle {v : ℝ} | ||
| 231 | 231 | (hv : v ∈ Icc (r ^ 2 / 2 - r / 6) (r ^ 2 / 2 + r / 6)) : |
| 232 | 232 | v ∈ Icc (r ^ 2 / 3) (2 * r ^ 2 / 3) := by |
| 233 | 233 | have hr := h.radius_one_le |
| 234 | - have hrr : r ≤ r ^ 2 := by nlinarith [mul_nonneg (sub_nonneg.mpr hr) h.radius_pos.le] | |
| 235 | - constructor <;> nlinarith [hv.1, hv.2] | |
| 234 | + have hrr : r ≤ r ^ 2 := by linarith [mul_nonneg (sub_nonneg.mpr hr) h.radius_pos.le] | |
| 235 | + constructor <;> linarith [hv.1, hv.2] | |
| 236 | 236 | |
| 237 | 237 | theorem core_scaled_sq {v : ℝ} |
| 238 | 238 | (hv : v ∈ Icc (r ^ 2 / 2 - r / 6) (r ^ 2 / 2 + r / 6)) : |
| @@ -250,13 +250,13 @@ theorem core_weight_lower {v : ℝ} | ||
| 250 | 250 | a ^ 2 * Real.exp (-B / 18) ≤ weight ψ x v := by |
| 251 | 251 | have hmid := h.core_mem_middle hv |
| 252 | 252 | have hslot : v ∈ Icc 0 (r ^ 2) := by |
| 253 | - constructor <;> nlinarith [hmid.1, hmid.2, sq_nonneg r] | |
| 253 | + constructor <;> linarith [hmid.1, hmid.2, sq_nonneg r] | |
| 254 | 254 | have hx := h.component_lower v hslot |
| 255 | 255 | have he : Real.exp (-B / 18) ≤ gaussian B (r ^ 2 / 2) r v ^ 2 := by |
| 256 | 256 | unfold gaussian |
| 257 | 257 | rw [pow_two, ← Real.exp_add] |
| 258 | 258 | apply Real.exp_le_exp.mpr |
| 259 | - nlinarith [mul_le_mul_of_nonneg_left (h.core_scaled_sq hv) h.lower_decay_pos.le] | |
| 259 | + linarith [mul_le_mul_of_nonneg_left (h.core_scaled_sq hv) h.lower_decay_pos.le] | |
| 260 | 260 | rw [weight, h.cutoff_one v hmid] |
| 261 | 261 | simp only [one_pow, one_mul] |
| 262 | 262 | calc |
| @@ -303,7 +303,7 @@ theorem weight_direction_integrable {q : ℝ → ℝ} | ||
| 303 | 303 | have hout : v ∉ Icc (r ^ 2 / 6) (5 * r ^ 2 / 6) := by |
| 304 | 304 | intro hin |
| 305 | 305 | apply hv' |
| 306 | - constructor <;> nlinarith [hin.1, hin.2, sq_nonneg r] | |
| 306 | + constructor <;> linarith [hin.1, hin.2, sq_nonneg r] | |
| 307 | 307 | exact hv (by simp [weight, h.cutoff_zero v hout]) |
| 308 | 308 | apply (integrableOn_iff_integrable_of_support_subset hs).mp |
| 309 | 309 | exact (h.weight_continuous.continuousOn.mul hq).integrableOn_Icc |
| @@ -366,7 +366,7 @@ theorem averagedDirection_error {q : ℝ → ℝ} (hq : ContinuousOn q (Icc 0 (r | ||
| 366 | 366 | ε * weight ψ x v + (K / r ^ 2) * (|v - r ^ 2 / 2| * weight ψ x v) := by |
| 367 | 367 | by_cases hv : v ∈ Icc (r ^ 2 / 6) (5 * r ^ 2 / 6) |
| 368 | 368 | · have hslot : v ∈ Icc 0 (r ^ 2) := by |
| 369 | - constructor <;> nlinarith [hv.1, hv.2, sq_nonneg r] | |
| 369 | + constructor <;> linarith [hv.1, hv.2, sq_nonneg r] | |
| 370 | 370 | rw [abs_mul, abs_of_nonneg (weight_nonneg v)] |
| 371 | 371 | convert! mul_le_mul_of_nonneg_left (hqbound v hslot) (weight_nonneg v) using 1 |
| 372 | 372 | ring |
| @@ -403,7 +403,7 @@ theorem averagedDirection_error_order {q : ℝ → ℝ} | ||
| 403 | 403 | have hi := h.averagedDirection_error hq hK hqbound |
| 404 | 404 | have hEr : E / r ^ 2 ≤ E / r := by |
| 405 | 405 | apply div_le_div_of_nonneg_left hE h.radius_pos |
| 406 | - nlinarith [mul_nonneg (sub_nonneg.mpr h.radius_one_le) h.radius_pos.le] | |
| 406 | + linarith [mul_nonneg (sub_nonneg.mpr h.radius_one_le) h.radius_pos.le] | |
| 407 | 407 | apply hi.trans |
| 408 | 408 | rw [add_div] |
| 409 | 409 | exact add_le_add_left hEr _ |
| @@ -435,13 +435,13 @@ theorem radiusProfile_lipschitz (s t : ℝ) : | ||
| 435 | 435 | add_pos (radiusProfile_pos s) (radiusProfile_pos t) |
| 436 | 436 | have he : (radiusProfile s - radiusProfile t) * (radiusProfile s + radiusProfile t) = |
| 437 | 437 | (s - t) * (s + t) := by |
| 438 | - nlinarith [radiusProfile_sq s, radiusProfile_sq t] | |
| 438 | + linarith [radiusProfile_sq s, radiusProfile_sq t] | |
| 439 | 439 | have ha := congrArg abs he |
| 440 | 440 | rw [abs_mul, abs_mul, abs_of_pos hp] at ha |
| 441 | 441 | have hst : |s + t| ≤ radiusProfile s + radiusProfile t := |
| 442 | 442 | (abs_add_le s t).trans (add_le_add (abs_le_radiusProfile s) (abs_le_radiusProfile t)) |
| 443 | 443 | exact (mul_le_mul_iff_left₀ hp).mp (by |
| 444 | - nlinarith [mul_le_mul_of_nonneg_left hst (abs_nonneg (s - t))]) | |
| 444 | + linarith [mul_le_mul_of_nonneg_left hst (abs_nonneg (s - t))]) | |
| 445 | 445 | |
| 446 | 446 | /-- Coordinates in the fixed tangent frame `(N,K)` of `h N - s K`, where |
| 447 | 447 | `h = c₀ sqrt(1+s²)`. -/ |
| @@ -471,7 +471,7 @@ theorem raw_integrand_eq {t : ℝ → Vec2} (v : ℝ) (i : Fin 2) : | ||
| 471 | 471 | · have hout : v ∉ Icc (r ^ 2 / 6) (5 * r ^ 2 / 6) := by |
| 472 | 472 | intro hin |
| 473 | 473 | apply hv |
| 474 | - constructor <;> nlinarith [hin.1, hin.2, sq_nonneg r] | |
| 474 | + constructor <;> linarith [hin.1, hin.2, sq_nonneg r] | |
| 475 | 475 | simp [weight, h.cutoff_zero v hout] |
| 476 | 476 | |
| 477 | 477 | /-- Exact factorization of the actual covariance integral into its positive |
+13 −13 NavierStokes/PulseEnergyHistory.lean View file
| @@ -142,7 +142,7 @@ theorem logarithmicRate_le_one (c : Parameters) : PulseAmplitude.logarithmicRate | ||
| 142 | 142 | have he : c.lam * (1 / c.lam - 1) = 1 - c.lam := by field_simp [c.lam_pos.ne'] |
| 143 | 143 | rw [he] at hm |
| 144 | 144 | unfold PulseAmplitude.logarithmicRate |
| 145 | - nlinarith | |
| 145 | + linarith | |
| 146 | 146 | |
| 147 | 147 | theorem prefix_sum_bound (c : Parameters) |
| 148 | 148 | (hwait : c.wait = 60 * Real.log (1 / c.lam)) : |
| @@ -159,12 +159,12 @@ theorem prefix_sum_bound (c : Parameters) | ||
| 159 | 159 | rw [he] at hb |
| 160 | 160 | have h := (div_le_iff₀ (PulseAmplitude.normalization_pos c)).mp hb |
| 161 | 161 | apply (le_div_iff₀ c.lam_pos).mpr |
| 162 | - nlinarith | |
| 162 | + linarith | |
| 163 | 163 | |
| 164 | 164 | theorem shape_bounds {eta : ℝ} (heta : |eta| ≤ 1) : |
| 165 | 165 | (1 / 4 : ℝ) ≤ shape eta ^ 2 ∧ shape eta ^ 2 ≤ 1 ∧ |shapeRate eta| ≤ 2 := by |
| 166 | 166 | have hs : eta ^ 2 ≤ 1 := by |
| 167 | - nlinarith [sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta, sq_abs eta] | |
| 167 | + linarith [sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta, sq_abs eta] | |
| 168 | 168 | have hlo : (1 / 2 : ℝ) ≤ shape eta := by |
| 169 | 169 | change 1 / 2 ≤ (1 + eta ^ 2)⁻¹ |
| 170 | 170 | rw [← one_div] |
| @@ -174,7 +174,7 @@ theorem shape_bounds {eta : ℝ} (heta : |eta| ≤ 1) : | ||
| 174 | 174 | rw [shapeRate, abs_div, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2), |
| 175 | 175 | abs_of_pos (by positivity : 0 < 1 + eta ^ 2)] |
| 176 | 176 | apply (div_le_iff₀ (by positivity : 0 < 1 + eta ^ 2)).mpr |
| 177 | - nlinarith [sq_nonneg eta] | |
| 177 | + linarith [sq_nonneg eta] | |
| 178 | 178 | |
| 179 | 179 | /-- One bound covers both normalized source factors. -/ |
| 180 | 180 | theorem source_factor_bounds {R Reta rate B : ℝ} (hB : 0 ≤ B) |
| @@ -182,7 +182,7 @@ theorem source_factor_bounds {R Reta rate B : ℝ} (hB : 0 ≤ B) | ||
| 182 | 182 | |R ^ 2 - 1 / 2| ≤ 6 * B ^ 2 + 2 ∧ |
| 183 | 183 | |2 * R * Reta - 2 * rate * (R ^ 2 - 1 / 2)| ≤ 6 * B ^ 2 + 2 := by |
| 184 | 184 | have hRsq : R ^ 2 ≤ B ^ 2 := by |
| 185 | - nlinarith [sq_le_sq₀ (abs_nonneg R) hB |>.mpr hR, sq_abs R] | |
| 185 | + linarith [sq_le_sq₀ (abs_nonneg R) hB |>.mpr hR, sq_abs R] | |
| 186 | 186 | have hbase : |R ^ 2 - 1 / 2| ≤ B ^ 2 + 1 / 2 := by |
| 187 | 187 | apply (abs_sub _ _).trans |
| 188 | 188 | rw [abs_of_nonneg (sq_nonneg R), abs_of_pos (by norm_num : (0 : ℝ) < 1 / 2)] |
| @@ -196,8 +196,8 @@ theorem source_factor_bounds {R Reta rate B : ℝ} (hB : 0 ≤ B) | ||
| 196 | 196 | linarith |
| 197 | 197 | have hsecond : |2 * rate * (R ^ 2 - 1 / 2)| ≤ 4 * (B ^ 2 + 1 / 2) := by |
| 198 | 198 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 199 | - nlinarith [mul_le_mul hrate hbase (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 2)] | |
| 200 | - exact ⟨hbase.trans (by nlinarith [sq_nonneg B]), | |
| 199 | + linarith [mul_le_mul hrate hbase (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 2)] | |
| 200 | + exact ⟨hbase.trans (by linarith [sq_nonneg B]), | |
| 201 | 201 | (abs_sub _ _).trans (by linarith)⟩ |
| 202 | 202 | |
| 203 | 203 | /-- The actual energy source and its actual parameter derivative have a common bound. -/ |
| @@ -239,25 +239,25 @@ theorem initial_history_bounds (w : ResetWitness d K) {amp : ℝ → ℝ} | ||
| 239 | 239 | have hG : 0 ≤ G := PulseAmplitude.prefixAngularEnergy_nonneg d.core |
| 240 | 240 | have hs := shape_bounds heta |
| 241 | 241 | have heta2 : eta ^ 2 ≤ 1 := by |
| 242 | - nlinarith [sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta, sq_abs eta] | |
| 242 | + linarith [sq_le_sq₀ (abs_nonneg eta) (by norm_num : (0 : ℝ) ≤ 1) |>.mpr heta, sq_abs eta] | |
| 243 | 243 | have hval : |S w amp (d.core.pulseStart, eta)| ≤ 4 * (A + G) := by |
| 244 | 244 | rw [S_at_pulseStart w ha] |
| 245 | 245 | change |A * eta ^ 2 - G * shape eta ^ 2| ≤ _ |
| 246 | 246 | apply (abs_sub _ _).trans |
| 247 | 247 | rw [abs_of_nonneg (mul_nonneg hA (sq_nonneg _)), |
| 248 | 248 | abs_of_nonneg (mul_nonneg hG (sq_nonneg _))] |
| 249 | - nlinarith [mul_le_of_le_one_right hA heta2, mul_le_of_le_one_right hG hs.2.1] | |
| 249 | + linarith [mul_le_of_le_one_right hA heta2, mul_le_of_le_one_right hG hs.2.1] | |
| 250 | 250 | have hder : |dEta (S w amp) (d.core.pulseStart, eta)| ≤ 4 * (A + G) := by |
| 251 | 251 | rw [dEta_S_at_pulseStart w ha] |
| 252 | 252 | change |2 * A * eta + 2 * G * shape eta ^ 2 * shapeRate eta| ≤ _ |
| 253 | 253 | apply (abs_add_le _ _).trans |
| 254 | 254 | have hfirst : |2 * A * eta| ≤ 2 * A := by |
| 255 | 255 | rw [abs_mul, abs_of_nonneg (mul_nonneg (by norm_num) hA)] |
| 256 | - nlinarith [mul_le_of_le_one_right (show 0 ≤ 2 * A by positivity) heta] | |
| 256 | + linarith [mul_le_of_le_one_right (show 0 ≤ 2 * A by positivity) heta] | |
| 257 | 257 | have hsecond : |2 * G * shape eta ^ 2 * shapeRate eta| ≤ 4 * G := by |
| 258 | 258 | rw [abs_mul, abs_of_nonneg (by positivity : 0 ≤ 2 * G * shape eta ^ 2)] |
| 259 | 259 | have hh := mul_le_mul hs.2.1 hs.2.2 (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 1) |
| 260 | - nlinarith [mul_le_mul_of_nonneg_left hh (show 0 ≤ 2 * G by positivity)] | |
| 260 | + linarith [mul_le_mul_of_nonneg_left hh (show 0 ≤ 2 * G by positivity)] | |
| 261 | 261 | linarith |
| 262 | 262 | have hscale : 4 * (A + G) ≤ |
| 263 | 263 | pulseNormalization d.core eta * (16 * PulseAmplitude.prefixBoundConstant d.core.P d.core.m) / |
| @@ -306,7 +306,7 @@ theorem normalized_history_bound {H g : ℝ → ℝ} {lam N C M y : ℝ} | ||
| 306 | 306 | have hfactor : 1 ≤ Real.exp 26 * Real.exp (-2 * lam * y) := by |
| 307 | 307 | rw [← Real.exp_add] |
| 308 | 308 | apply Real.one_le_exp |
| 309 | - nlinarith [(le_div_iff₀ hlam).mp hy'] | |
| 309 | + linarith [(le_div_iff₀ hlam).mp hy'] | |
| 310 | 310 | apply (div_le_iff₀ (mul_pos hN (Real.exp_pos _))).mpr |
| 311 | 311 | calc |
| 312 | 312 | _ ≤ N * (C + 13 * M) / lam := hvalue |
| @@ -396,7 +396,7 @@ theorem forcing_abs_bound (c : Parameters) (hsmall : c.lam ≤ 1 / 120) (q A y : | ||
| 396 | 396 | OutgoingPulseBounds.correctionJetBound c.P c.m 0 * (|q| + |A|) := add_le_add hm hc' |
| 397 | 397 | _ ≤ _ := by |
| 398 | 398 | unfold forceConstant |
| 399 | - nlinarith [mul_nonneg OutgoingPulseBounds.mainBound_pos.le (abs_nonneg q)] | |
| 399 | + linarith [mul_nonneg OutgoingPulseBounds.mainBound_pos.le (abs_nonneg q)] | |
| 400 | 400 | |
| 401 | 401 | /-- The parameter derivative includes the derivative of the actual moment repair. -/ |
| 402 | 402 | theorem pulseRatio_eta_hasDerivAt (c : Parameters) {amp : ℝ → ℝ} {eta amp' : ℝ} |
+8 −8 NavierStokes/PulseLag.lean View file
| @@ -156,7 +156,7 @@ theorem decay_inv_cube_le (c : Parameters) {M : ℝ} (hM : 0 ≤ M) : | ||
| 156 | 156 | have hp := pow_le_pow_left₀ (by norm_num : (0 : ℝ) ≤ 2 / 5) hd 3 |
| 157 | 157 | have hb : 1 ≤ 16 * decay c ^ 3 := by norm_num at hp; linarith |
| 158 | 158 | apply (div_le_iff₀ (pow_pos (decay_pos c) 3)).mpr |
| 159 | - nlinarith [mul_le_mul_of_nonneg_right hb hM] | |
| 159 | + linarith [mul_le_mul_of_nonneg_right hb hM] | |
| 160 | 160 | |
| 161 | 161 | /-- The exponential correction is smaller than a fixed quadratic rate, |
| 162 | 162 | uniformly for every positive lambda. -/ |
| @@ -269,7 +269,7 @@ theorem forcing_second_bound (c : Parameters) (hsmall : c.lam ≤ 1 / 120) | ||
| 269 | 269 | |iteratedDeriv 2 (affineProfile c q A) y| := abs_add_le _ _ |
| 270 | 270 | _ ≤ |A| * c.lam ^ 2 * mainSecondBound + |
| 271 | 271 | correctionJetBound c.P c.m 2 * (64 * c.lam ^ 2) * (|q| + |A|) := add_le_add hm hc' |
| 272 | - _ ≤ _ := by dsimp [forcingBound]; nlinarith | |
| 272 | + _ ≤ _ := by dsimp [forcingBound]; linarith | |
| 273 | 273 | |
| 274 | 274 | noncomputable def affineLag (c : Parameters) (q A y : ℝ) : ℝ := |
| 275 | 275 | lag (decay c) (prefixCoefficient c 0 * q) (forcing c q A) y |
| @@ -372,7 +372,7 @@ theorem normalizedLag_eq_affineLag (c : Parameters) (amp : ℝ → ℝ) (eta : | ||
| 372 | 372 | have hpre' : massMoment c amp eta c.pulseStart = |
| 373 | 373 | (prefixCoefficient c 0 * parameterPolynomial eta) * (momentScale c 0 * shape eta) := by |
| 374 | 374 | apply (div_eq_iff hs).mp |
| 375 | - simpa only [parameterPolynomial, mul_assoc] using hpre | |
| 375 | + simpa only [mul_assoc] using hpre | |
| 376 | 376 | rw [normalizedLag, massMoment_pulse c amp eta hy, pulse_denominator c eta hy, hpre', |
| 377 | 377 | affineLag, lag, convolution_eq_weighted] |
| 378 | 378 | have he : Real.exp (-decay c * y) = (Real.exp (decay c * y))⁻¹ := by |
| @@ -556,7 +556,7 @@ theorem initial_memory_bound (c : Parameters) | ||
| 556 | 556 | _ ≤ prefixBound c.P c.m 0 * |q| * c.lam ^ 2 := by |
| 557 | 557 | have h := mul_le_mul_of_nonneg_left hpow |
| 558 | 558 | (mul_nonneg (prefixBound_pos c.P_pos c.m 0).le (abs_nonneg q)) |
| 559 | - nlinarith | |
| 559 | + linarith | |
| 560 | 560 | |
| 561 | 561 | noncomputable def fullLagBound (P m : ℝ) : ℝ := 5 * lagBound P m + 4 * prefixBound P m 0 |
| 562 | 562 | |
| @@ -586,13 +586,13 @@ theorem fullError_bounds_of_amplitude_bounds (c : Parameters) | ||
| 586 | 586 | have ht : 2 + |amp eta| ≤ 4 := by linarith |
| 587 | 587 | have h := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left ht hL.le) |
| 588 | 588 | (sq_nonneg c.lam) |
| 589 | - nlinarith | |
| 589 | + linarith | |
| 590 | 590 | have hmemory : |(prefixCoefficient c 0 * parameterPolynomial eta) * Real.exp (-decay c * y)| ≤ |
| 591 | 591 | 2 * prefixBound c.P c.m 0 * c.lam ^ 2 := by |
| 592 | 592 | apply (initial_memory_bound c hwait hsmall _ hy).trans |
| 593 | 593 | have h := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hq hP.le) |
| 594 | 594 | (sq_nonneg c.lam) |
| 595 | - nlinarith | |
| 595 | + linarith | |
| 596 | 596 | rw [fullError_eq] |
| 597 | 597 | refine (abs_add_le _ _).trans ((add_le_add hmain hmemory).trans ?_) |
| 598 | 598 | dsimp [fullLagBound] |
| @@ -604,13 +604,13 @@ theorem fullError_bounds_of_amplitude_bounds (c : Parameters) | ||
| 604 | 604 | have hs : |1 + 3 * eta ^ 2| + |amp'| ≤ 5 := by linarith |
| 605 | 605 | have h := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hs hL.le) |
| 606 | 606 | (sq_nonneg c.lam) |
| 607 | - nlinarith | |
| 607 | + linarith | |
| 608 | 608 | have hmemory : |(prefixCoefficient c 0 * (1 + 3 * eta ^ 2)) * Real.exp (-decay c * y)| ≤ |
| 609 | 609 | 4 * prefixBound c.P c.m 0 * c.lam ^ 2 := by |
| 610 | 610 | apply (initial_memory_bound c hwait hsmall _ hy).trans |
| 611 | 611 | have h := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hq' hP.le) |
| 612 | 612 | (sq_nonneg c.lam) |
| 613 | - nlinarith | |
| 613 | + linarith | |
| 614 | 614 | refine (abs_add_le _ _).trans ((add_le_add hmain hmemory).trans_eq ?_) |
| 615 | 615 | dsimp [fullLagBound] |
| 616 | 616 | ring |
+1 −1 NavierStokes/R3/CompactEnergy.lean View file
| @@ -266,7 +266,7 @@ theorem energy_rate_le {u f : VelocityField} {p : PressureField} {t : ℝ} | ||
| 266 | 266 | 2 * ⟪u (t, x), f (t, x)⟫_ℝ ≤ ‖u (t, x)‖ ^ 2 + ‖f (t, x)‖ ^ 2 := by |
| 267 | 267 | have hinner := (le_abs_self ⟪u (t, x), f (t, x)⟫_ℝ).trans |
| 268 | 268 | (abs_real_inner_le_norm (u (t, x)) (f (t, x))) |
| 269 | - nlinarith [sq_nonneg (‖u (t, x)‖ - ‖f (t, x)‖)] | |
| 269 | + linarith [sq_nonneg (‖u (t, x)‖ - ‖f (t, x)‖)] | |
| 270 | 270 | have hforce : 2 * (∫ x, ⟪u (t, x), f (t, x)⟫_ℝ) ≤ l2Sq u t + l2Sq f t := by |
| 271 | 271 | rw [← integral_const_mul] |
| 272 | 272 | unfold l2Sq |
+1 −1 NavierStokes/R3/ComparisonFiniteEnergy.lean View file
| @@ -41,7 +41,7 @@ theorem continuous_slice_of_continuousOn {times : Set ℝ} {u : VelocityField} | ||
| 41 | 41 | theorem norm_sub_sq_le_twice {E : Type*} [SeminormedAddCommGroup E] (a b : E) : |
| 42 | 42 | ‖a - b‖ ^ 2 ≤ 2 * (‖a‖ ^ 2 + ‖b‖ ^ 2) := by |
| 43 | 43 | have h := mul_self_le_mul_self (norm_nonneg (a - b)) (norm_sub_le a b) |
| 44 | - nlinarith [sq_nonneg (‖a‖ - ‖b‖)] | |
| 44 | + linarith [sq_nonneg (‖a‖ - ‖b‖)] | |
| 45 | 45 | |
| 46 | 46 | /-- A difference of square-integrable slices remains square integrable. -/ |
| 47 | 47 | theorem squareIntegrableAtTime_sub {u v : VelocityField} {t : ℝ} |
+4 −4 NavierStokes/R3/ComparisonRateBound.lean View file
| @@ -45,7 +45,7 @@ theorem exists_uniform_flux_absorption {C1 C2 S M δ : ℝ} | ||
| 45 | 45 | have hSMQ : S * M ≤ Q := |
| 46 | 46 | (mul_le_mul_of_nonneg_left (le_max_right 1 M) hS).trans (le_max_right _ _) |
| 47 | 47 | have hQ0 : 0 ≤ Q := (mul_nonneg hS hM).trans hSMQ |
| 48 | - have hQsq1 : 1 ≤ Q ^ 2 := by nlinarith [sq_nonneg (Q - 1)] | |
| 48 | + have hQsq1 : 1 ≤ Q ^ 2 := by linarith [sq_nonneg (Q - 1)] | |
| 49 | 49 | let C : ℝ := (C1 + C2) * Q ^ 2 |
| 50 | 50 | have hC : 0 ≤ C := mul_nonneg (add_nonneg hC1 hC2) (sq_nonneg _) |
| 51 | 51 | have hC1Q : C1 * Q ^ 2 ≤ C := |
| @@ -119,7 +119,7 @@ theorem exists_uniform_flux_absorption {C1 C2 S M δ : ℝ} | ||
| 119 | 119 | C * (x ^ (1 / 2 : ℝ) + 1) * (R⁻¹ * A + R ^ (-2 : ℝ)) + |
| 120 | 120 | C * R ^ (-7 / 4 : ℝ) * x ^ (3 / 4 : ℝ) + |
| 121 | 121 | C * R⁻¹ * x ^ (3 / 2 : ℝ) := by |
| 122 | - nlinarith only [hpressure, hcommutator, htransport] | |
| 122 | + linarith only [hpressure, hcommutator, htransport] | |
| 123 | 123 | exact hsum.trans (hD_bound A hA R hR) |
| 124 | 124 | |
| 125 | 125 | /-- One radius-independent constant turns the full localized energy inequality |
| @@ -139,12 +139,12 @@ theorem exists_uniform_rate_bound {C0 C1 C2 S M : ℝ} | ||
| 139 | 139 | refine ⟨2 * (C0 + D), by positivity, ?_⟩ |
| 140 | 140 | intro R hR A hA B hB hSobolev E E' G henergy |
| 141 | 141 | have hRpos : 0 < R := zero_lt_one.trans_le hR |
| 142 | - have hRsq : R ≤ R ^ 2 := by nlinarith [sq_nonneg (R - 1)] | |
| 142 | + have hRsq : R ≤ R ^ 2 := by linarith [sq_nonneg (R - 1)] | |
| 143 | 143 | have hC0radius : C0 / R ^ 2 ≤ C0 / R := |
| 144 | 144 | div_le_div_of_nonneg_left hC0 hRpos hRsq |
| 145 | 145 | have hbound := hflux R hR A hA B hB hSobolev |
| 146 | 146 | have hdivide : 2 * (C0 + D) / R = 2 * (C0 / R + D / R) := by ring |
| 147 | 147 | rw [hdivide] |
| 148 | - nlinarith only [henergy, hbound, hC0radius, sq_nonneg A] | |
| 148 | + linarith only [henergy, hbound, hC0radius, sq_nonneg A] | |
| 149 | 149 | |
| 150 | 150 | end NavierStokesR3.ComparisonRateBound |
+1 −1 NavierStokes/R3/ComparisonTimeAverages.lean View file
| @@ -325,7 +325,7 @@ theorem l2_complex_mul_integrable_and_norm_integral_le {f : Space → ℝ} {ψ : | ||
| 325 | 325 | have hψ_sq := (memLp_two_iff_integrable_sq_norm hψ.1).1 hψ |
| 326 | 326 | have hpoint (x : Space) : ‖(f x : ℂ) * ψ x‖ ≤ ‖f x‖ ^ 2 + ‖ψ x‖ ^ 2 := by |
| 327 | 327 | rw [norm_mul, Complex.norm_real] |
| 328 | - nlinarith [sq_nonneg (‖f x‖ - ‖ψ x‖), mul_nonneg (norm_nonneg (f x)) (norm_nonneg (ψ x))] | |
| 328 | + linarith [sq_nonneg (‖f x‖ - ‖ψ x‖), mul_nonneg (norm_nonneg (f x)) (norm_nonneg (ψ x))] | |
| 329 | 329 | have hmeas := (Complex.continuous_ofReal.comp_aestronglyMeasurable hf.1).mul hψ.1 |
| 330 | 330 | have hint := (hf_sq.add hψ_sq).mono' hmeas (Filter.Eventually.of_forall hpoint) |
| 331 | 331 | refine ⟨hint, ?_⟩ |
+5 −5 NavierStokes/R3/ComparisonYoung.lean View file
| @@ -62,9 +62,9 @@ theorem exists_shifted_rpow_absorption {C δ p : ℝ} | ||
| 62 | 62 | intro A hA |
| 63 | 63 | have hboundA := hbound (A + 1) (by linarith) |
| 64 | 64 | have hsquare : (A + 1) ^ 2 ≤ 2 * A ^ 2 + 2 := by |
| 65 | - nlinarith [sq_nonneg (A - 1)] | |
| 65 | + linarith [sq_nonneg (A - 1)] | |
| 66 | 66 | have hscaled := mul_le_mul_of_nonneg_left hsquare (half_pos hδ).le |
| 67 | - nlinarith | |
| 67 | + linarith | |
| 68 | 68 | |
| 69 | 69 | /-- Dividing the shifted estimate by a radius at least one preserves the |
| 70 | 70 | arbitrarily small square coefficient and makes the constant decay as `1 / R`. -/ |
| @@ -82,7 +82,7 @@ theorem exists_scaled_shifted_rpow_absorption {C δ p : ℝ} | ||
| 82 | 82 | have hquadratic := mul_le_mul_of_nonneg_left hInv1 |
| 83 | 83 | (mul_nonneg hδ.le (sq_nonneg A)) |
| 84 | 84 | simp only [div_eq_mul_inv] |
| 85 | - nlinarith | |
| 85 | + linarith | |
| 86 | 86 | |
| 87 | 87 | /-- The pressure and transport cutoff remainders are controlled by one shifted |
| 88 | 88 | subquadratic power. The estimate retains the full factor `1 / R`. -/ |
| @@ -112,7 +112,7 @@ theorem cutoff_expression_le {C A R : ℝ} | ||
| 112 | 112 | have hone := Real.one_le_rpow hB1 (by norm_num : (0 : ℝ) ≤ 1 / 2) |
| 113 | 113 | linarith |
| 114 | 114 | have hlinear : R⁻¹ * A + R ^ (-2 : ℝ) ≤ R⁻¹ * (A + 1) := by |
| 115 | - nlinarith | |
| 115 | + linarith | |
| 116 | 116 | have hlinear0 : 0 ≤ R⁻¹ * A + R ^ (-2 : ℝ) := |
| 117 | 117 | add_nonneg (mul_nonneg hInv hA) (Real.rpow_nonneg hRpos.le _) |
| 118 | 118 | have hprod : (A + 1) ^ (1 / 2 : ℝ) * (A + 1) = |
| @@ -140,7 +140,7 @@ theorem cutoff_expression_le {C A R : ℝ} | ||
| 140 | 140 | (mul_le_mul hR74 hthreeQuarters (Real.rpow_nonneg hx _) hInv) hC |
| 141 | 141 | have hterm3 := mul_le_mul_of_nonneg_left hthreeHalves (mul_nonneg hC hInv) |
| 142 | 142 | simp only [div_eq_mul_inv] |
| 143 | - nlinarith only [hterm1, hterm2, hterm3] | |
| 143 | + linarith only [hterm1, hterm2, hterm3] | |
| 144 | 144 | |
| 145 | 145 | /-- Scalar Young absorption of all cutoff remainders. The same nonnegative |
| 146 | 146 | constant works for every nonnegative gradient norm and every radius at least |
+3 −4 NavierStokes/R3/FourierTestDerivatives.lean View file
| @@ -34,7 +34,7 @@ def laplacianCLM : ComplexTest →L[ℂ] ComplexTest := | ||
| 34 | 34 | laplacianCLM ψ x = |
| 35 | 35 | ∑ i : Fin 3, NavierStokes.PeriodicIntegration.spatialPartial i |
| 36 | 36 | (fun y => NavierStokes.PeriodicIntegration.spatialPartial i (ψ : Space → ℂ) y) x := by |
| 37 | - simp [laplacianCLM, Fin.sum_univ_succ, partialCLM, | |
| 37 | + simp [laplacianCLM, partialCLM, | |
| 38 | 38 | NavierStokes.PeriodicIntegration.spatialPartial, SchwartzMap.lineDerivOp_apply_eq_fderiv] |
| 39 | 39 | rfl |
| 40 | 40 | |
| @@ -43,13 +43,12 @@ theorem fourier_partialCLM_apply (i : Fin 3) (ψ : ComplexTest) (ξ : Space) : | ||
| 43 | 43 | FourierTransform.fourierCLE ℂ ComplexTest (partialCLM i ψ) ξ = |
| 44 | 44 | (2 * (Real.pi : ℂ) * Complex.I * (ξ i : ℂ)) * |
| 45 | 45 | FourierTransform.fourierCLE ℂ ComplexTest ψ ξ := by |
| 46 | - have hd : Integrable (fderiv ℝ (ψ : Space → ℂ)) := by | |
| 47 | - exact (SchwartzMap.fderivCLM ℂ Space ℂ ψ).integrable | |
| 46 | + have hd : Integrable (fderiv ℝ (ψ : Space → ℂ)) := (SchwartzMap.fderivCLM ℂ Space ℂ ψ).integrable | |
| 48 | 47 | change 𝓕 (fun x => fderiv ℝ (ψ : Space → ℂ) x |
| 49 | 48 | (NavierStokes.ProblemStatement.coordinateVector i)) ξ = _ |
| 50 | 49 | rw [← Real.fourier_continuousLinearMap_apply hd, |
| 51 | 50 | Real.fourier_fderiv ψ.integrable ψ.differentiable hd] |
| 52 | - simp [VectorFourier.fourierSMulRight_apply, SchwartzMap.fourier_coe, | |
| 51 | + simp [SchwartzMap.fourier_coe, | |
| 53 | 52 | NavierStokes.ProblemStatement.coordinateVector, |
| 54 | 53 | smul_eq_mul, mul_assoc] |
| 55 | 54 | left |
+1 −1 NavierStokes/R3/GaussianMoments.lean View file
| @@ -77,7 +77,7 @@ theorem integrable_norm_gaussian {a : ℝ} (ha : 0 < a) : | ||
| 77 | 77 | ‖x‖ * Real.exp (-a * ‖x‖ ^ 2) ≤ |
| 78 | 78 | (1 + ‖x‖ ^ 2) * Real.exp (-a * ‖x‖ ^ 2) := by |
| 79 | 79 | apply mul_le_mul_of_nonneg_right _ (Real.exp_nonneg _) |
| 80 | - nlinarith [sq_nonneg (‖x‖ - 1 / 2)] | |
| 80 | + linarith [sq_nonneg (‖x‖ - 1 / 2)] | |
| 81 | 81 | _ = Real.exp (-a * ‖x‖ ^ 2) + ‖x‖ ^ 2 * Real.exp (-a * ‖x‖ ^ 2) := by ring |
| 82 | 82 | |
| 83 | 83 | end NavierStokesR3.Comparison |
+2 −3 NavierStokes/R3/HeatKernelCancellation.lean View file
| @@ -44,7 +44,7 @@ theorem abs_sq_sub_sq_le_one {a b : ℝ} | ||
| 44 | 44 | rw [abs_le] |
| 45 | 45 | have ha2 : a * a ≤ 1 * 1 := mul_le_mul ha.2 ha.2 ha.1 (by norm_num) |
| 46 | 46 | have hb2 : b * b ≤ 1 * 1 := mul_le_mul hb.2 hb.2 hb.1 (by norm_num) |
| 47 | - constructor <;> nlinarith [sq_nonneg a, sq_nonneg b] | |
| 47 | + constructor <;> linarith [sq_nonneg a, sq_nonneg b] | |
| 48 | 48 | |
| 49 | 49 | theorem cutoffSquareDifference_abs_le_one {φ : Space → ℝ} |
| 50 | 50 | (hφ : ∀ x, φ x ∈ Icc (0 : ℝ) 1) (x y : Space) : |
| @@ -157,8 +157,7 @@ theorem cancelledTimeIntegrand_measurable {K : ℝ → Space → ℝ} | ||
| 157 | 157 | theorem cancelledTimeKernel_measurable {K : ℝ → Space → ℝ} |
| 158 | 158 | {φ : Space → ℝ} (hK : Measurable (Function.uncurry K)) |
| 159 | 159 | (hφ : Measurable φ) : |
| 160 | - Measurable (Function.uncurry (cancelledTimeKernel K φ)) := by | |
| 161 | - exact (cancelledTimeIntegrand_measurable hK hφ).stronglyMeasurable.integral_prod_right'.measurable | |
| 160 | + Measurable (Function.uncurry (cancelledTimeKernel K φ)) := (cancelledTimeIntegrand_measurable hK hφ).stronglyMeasurable.integral_prod_right'.measurable | |
| 162 | 161 | |
| 163 | 162 | theorem absoluteCancelledTimeKernel_measurable {K : ℝ → Space → ℝ} |
| 164 | 163 | {φ : Space → ℝ} (hK : Measurable (Function.uncurry K)) |
+1 −1 NavierStokes/R3/LocalizedFluxEstimates.lean View file
| @@ -53,7 +53,7 @@ theorem neg_coupling_le_weightedEnergy {χ : Space → ℝ} {u w : VelocityField | ||
| 53 | 53 | G * (χ x * ‖w (t, x)‖ ^ 2) |
| 54 | 54 | have h := NavierStokes.PeriodicUniqueness.nonlinear_energy_bound |
| 55 | 55 | (spatialDerivative u t x) (w (t, x)) (hG x) |
| 56 | - nlinarith [mul_le_mul_of_nonneg_left h (hχ0 x)] | |
| 56 | + linarith [mul_le_mul_of_nonneg_left h (hχ0 x)] | |
| 57 | 57 | |
| 58 | 58 | /-- Derivative of the energy weight. -/ |
| 59 | 59 | theorem fderiv_cutoff_eight {φ : Space → ℝ} {x : Space} |
+4 −5 NavierStokes/R3/LocalizedTensorBounds.lean View file
| @@ -84,8 +84,7 @@ theorem quadratic_cutoff_bound {φ : Space → ℝ} {w : Space → Space} | ||
| 84 | 84 | calc |
| 85 | 85 | comparisonLpNorm (12 / 5) (fun x => φ x • w x) ^ 2 ≤ |
| 86 | 86 | (comparisonLpNorm 2 w ^ (3 / 4 : ℝ) * |
| 87 | - comparisonLpNorm 6 (fun x => φ x ^ 4 • w x) ^ (1 / 4 : ℝ)) ^ 2 := by | |
| 88 | - exact pow_le_pow_left₀ hA hb 2 | |
| 87 | + comparisonLpNorm 6 (fun x => φ x ^ 4 • w x) ^ (1 / 4 : ℝ)) ^ 2 := pow_le_pow_left₀ hA hb 2 | |
| 89 | 88 | _ = comparisonLpNorm 2 w ^ (3 / 2 : ℝ) * |
| 90 | 89 | comparisonLpNorm 6 (fun x => φ x ^ 4 • w x) ^ (1 / 2 : ℝ) := by |
| 91 | 90 | rw [← Real.rpow_natCast _ 2, |
| @@ -152,7 +151,7 @@ theorem norm_weighted_tensorDiff_le (u v : VelocityField) (t : ℝ) (i j : Fin 3 | ||
| 152 | 151 | mul_le_mul_of_nonneg_left ht (sq_nonneg s) |
| 153 | 152 | _ ≤ 2 * (‖a‖ * ‖w‖) + ‖s • w‖ ^ 2 := by |
| 154 | 153 | rw [norm_smul, Real.norm_eq_abs, abs_of_nonneg hs0] |
| 155 | - nlinarith [mul_nonneg (sub_nonneg.mpr hs2) (mul_nonneg (norm_nonneg a) (norm_nonneg w))] | |
| 154 | + linarith [mul_nonneg (sub_nonneg.mpr hs2) (mul_nonneg (norm_nonneg a) (norm_nonneg w))] | |
| 156 | 155 | |
| 157 | 156 | /-- Compactness supplies finite weighted tensor norms without any growth |
| 158 | 157 | assumption on either velocity. -/ |
| @@ -198,7 +197,7 @@ theorem weighted_tensorDiff_bound {φ : Space → ℝ} {u v : VelocityField} {t | ||
| 198 | 197 | change ‖φ x ^ 2 * tensorDiff u v t i j x‖ ≤ ‖2 * P x + Q x‖ |
| 199 | 198 | have hn : ‖2 * P x + Q x‖ = 2 * P x + Q x := by |
| 200 | 199 | rw [Real.norm_eq_abs, abs_of_nonneg] |
| 201 | - dsimp [P, Q] | |
| 200 | + dsimp [P] | |
| 202 | 201 | positivity |
| 203 | 202 | rw [hn] |
| 204 | 203 | exact norm_weighted_tensorDiff_le u v t i j x (hφ0 x) (hφ1 x) |
| @@ -214,6 +213,6 @@ theorem weighted_tensorDiff_bound {φ : Space → ℝ} {u v : VelocityField} {t | ||
| 214 | 213 | comparisonLpNorm 2 (fun x => (u - v) (t, x)) ^ (3 / 2 : ℝ) * |
| 215 | 214 | comparisonLpNorm 6 (fun x => φ x ^ 4 • (u - v) (t, x)) ^ (1 / 2 : ℝ) + |
| 216 | 215 | 2 * comparisonLpNorm 2 (fun x => (u - v) (t, x)) * comparisonLpNorm 3 (fun x => u (t, x)) |
| 217 | - nlinarith | |
| 216 | + linarith | |
| 218 | 217 | |
| 219 | 218 | end NavierStokesR3.LocalizedTensorBounds |
+2 −3 NavierStokes/R3/LocalizedTransport.lean View file
| @@ -34,13 +34,12 @@ theorem divergence_weighted {χ : Space → ℝ} {v : Space → Space} | ||
| 34 | 34 | (fderiv ℝ (fun y => χ y • v y) x (coordinateVector i)) = _ |
| 35 | 35 | rw [fderiv_fun_smul (hχ.differentiable (by simp) x) |
| 36 | 36 | (hv.differentiable (by simp) x)] |
| 37 | - simp only [_root_.add_apply, _root_.smul_apply, | |
| 38 | - ContinuousLinearMap.smulRight_apply, map_add, map_smul, smul_eq_mul, | |
| 37 | + simp only [_root_.add_apply, ContinuousLinearMap.smulRight_apply, map_add, map_smul, smul_eq_mul, | |
| 39 | 38 | spatialPartial] |
| 40 | 39 | rfl |
| 41 | 40 | simp_rw [hpartial] |
| 42 | 41 | rw [Finset.sum_add_distrib, ← Finset.mul_sum, fderiv_apply_eq_sum] |
| 43 | - simp only [spatialPartial] | |
| 42 | + simp only | |
| 44 | 43 | rw [add_comm] |
| 45 | 44 | congr 1 |
| 46 | 45 | apply Finset.sum_congr rfl |
+1 −1 NavierStokes/R3/ParabolicEnergy.lean View file
| @@ -47,7 +47,7 @@ theorem velocity_speed_unbounded {u : VelocityField} {l : ℝ} | ||
| 47 | 47 | have hts : t ≤ s := by |
| 48 | 48 | have hprod : (t - 1) * (l ^ 2 - 1) ≤ 0 := |
| 49 | 49 | mul_nonpos_of_nonpos_of_nonneg (by linarith [ht.2]) (by linarith) |
| 50 | - have hd : t - 1 ≤ (t - 1) / l ^ 2 := (le_div_iff₀ hq).2 (by nlinarith) | |
| 50 | + have hd : t - 1 ≤ (t - 1) / l ^ 2 := (le_div_iff₀ hq).2 (by linarith) | |
| 51 | 51 | dsimp [s] |
| 52 | 52 | linarith |
| 53 | 53 | have hclock : clock l s = t := by |
+1 −1 NavierStokes/R3/PositiveTimeForce.lean View file
| @@ -29,7 +29,7 @@ theorem timeCutoff_eq_one {t : ℝ} (ht : t ∈ Icc (3 / 8 : ℝ) 1) : | ||
| 29 | 29 | timeCutoff t = 1 := by |
| 30 | 30 | apply NavierStokes.SmoothCutoffs.cutoff_one_of_abs_le |
| 31 | 31 | rw [abs_le] |
| 32 | - constructor <;> nlinarith [ht.1, ht.2] | |
| 32 | + constructor <;> linarith [ht.1, ht.2] | |
| 33 | 33 | |
| 34 | 34 | theorem timeCutoff_eq_zero {t : ℝ} (ht : t ∉ Icc (1 / 16 : ℝ) (21 / 16)) : |
| 35 | 35 | timeCutoff t = 0 := by |
+4 −4 NavierStokes/R3/PressureFlux.lean View file
| @@ -89,7 +89,7 @@ theorem norm_holder_pair_le {f : Space → ℝ} {g : Space → ℂ} | ||
| 89 | 89 | simpa only [ENNReal.coe_one, one_mul] using |
| 90 | 90 | eLpNorm_le_eLpNorm_mul_eLpNorm_of_nnnorm hfc.1 hg.1 |
| 91 | 91 | (fun a b : ℂ => a * b) 1 |
| 92 | - (Eventually.of_forall fun x => by simp [nnnorm_mul]) | |
| 92 | + (Eventually.of_forall fun x => by simp) | |
| 93 | 93 | have ht := ENNReal.toReal_mono (ENNReal.mul_ne_top hfc.eLpNorm_ne_top hg.eLpNorm_ne_top) he |
| 94 | 94 | change comparisonLpNorm 1 (fun x => (f x : ℂ) * g x) ≤ |
| 95 | 95 | (eLpNorm (fun x => (f x : ℂ)) (6 / 5) volume * eLpNorm g 6 volume).toReal at ht |
| @@ -375,13 +375,13 @@ theorem uniform_expression_bound {C₁ C₂ M₀ U₀ G₀ M U G A B R : ℝ} | ||
| 375 | 375 | (M₀ ^ (3 / 2 : ℝ) + 2 * M₀ * U₀) * (B ^ (1 / 2 : ℝ) + 1) := by |
| 376 | 376 | have h := add_le_add (mul_le_mul_of_nonneg_right hMp hB₁) hMU |
| 377 | 377 | have hm0u0 : 0 ≤ 2 * M₀ * U₀ := by positivity |
| 378 | - exact h.trans (by nlinarith only [hM₀p, mul_nonneg hm0u0 hB₁]) | |
| 378 | + exact h.trans (by linarith only [hM₀p, mul_nonneg hm0u0 hB₁]) | |
| 379 | 379 | have hAR : 0 ≤ A / R := div_nonneg hA hR.le |
| 380 | 380 | have hInv : 0 ≤ 1 / R ^ 2 := by positivity |
| 381 | 381 | have hD : A / R + M / R ^ 2 ≤ (M₀ + 1) * (A / R + 1 / R ^ 2) := by |
| 382 | 382 | have hdiv := (div_le_div_iff_of_pos_right (sq_pos_of_pos hR)).2 hMM |
| 383 | 383 | have hdiv' : M / R ^ 2 ≤ M₀ * (1 / R ^ 2) := by simpa only [mul_one_div] using hdiv |
| 384 | - nlinarith only [hdiv', mul_nonneg hM₀ hAR, hInv] | |
| 384 | + linarith only [hdiv', mul_nonneg hM₀ hAR, hInv] | |
| 385 | 385 | have hlocal : |
| 386 | 386 | C₁ * (M ^ (3 / 2 : ℝ) * B ^ (1 / 2 : ℝ) + 2 * M * U) * (A / R + M / R ^ 2) ≤ |
| 387 | 387 | (C₁ * (M₀ ^ (3 / 2 : ℝ) + 2 * M₀ * U₀) * (M₀ + 1)) * |
| @@ -404,7 +404,7 @@ theorem uniform_expression_bound {C₁ C₂ M₀ U₀ G₀ M U G A B R : ℝ} | ||
| 404 | 404 | have hE₁ : 0 ≤ (B ^ (1 / 2 : ℝ) + 1) * (A / R + 1 / R ^ 2) := by positivity |
| 405 | 405 | have hE₂ : 0 ≤ R ^ (-(7 / 4 : ℝ)) * B ^ (3 / 4 : ℝ) := mul_nonneg hRp hB₃ |
| 406 | 406 | unfold uniformCoefficient |
| 407 | - nlinarith only [add_le_add hlocal hcomm, mul_nonneg hK₁ hE₂, mul_nonneg hK₂ hE₁] | |
| 407 | + linarith only [add_le_add hlocal hcomm, mul_nonneg hK₁ hE₂, mul_nonneg hK₂ hE₁] | |
| 408 | 408 | |
| 409 | 409 | theorem rpow_three_fourths_div {R : ℝ} (hR : 0 < R) : |
| 410 | 410 | R ^ (-(3 / 4 : ℝ)) / R = R ^ (-(7 / 4 : ℝ)) := by |
+3 −3 NavierStokes/R3/PressureFluxTest.lean View file
| @@ -64,7 +64,7 @@ theorem norm_r_le {φ : Space → ℝ} {w : Space → Space} {x : Space} | ||
| 64 | 64 | ‖r φ w x‖ ≤ (8 * L) * ‖(φ x ^ 3) • w x‖ := by |
| 65 | 65 | have hp2 : φ x ^ 2 ≤ 1 := pow_le_one₀ hφ0 hφ1 |
| 66 | 66 | have hp : φ x ^ 5 ≤ φ x ^ 3 := by |
| 67 | - nlinarith [mul_le_mul_of_nonneg_left hp2 (pow_nonneg hφ0 3)] | |
| 67 | + linarith [mul_le_mul_of_nonneg_left hp2 (pow_nonneg hφ0 3)] | |
| 68 | 68 | have happly : ‖fderiv ℝ φ x (w x)‖ ≤ L * ‖w x‖ := |
| 69 | 69 | ((fderiv ℝ φ x).le_opNorm (w x)).trans |
| 70 | 70 | (mul_le_mul_of_nonneg_right hL (norm_nonneg _)) |
| @@ -74,7 +74,7 @@ theorem norm_r_le {φ : Space → ℝ} {w : Space → Space} {x : Space} | ||
| 74 | 74 | _ ≤ 8 * φ x ^ 5 * (L * ‖w x‖) := |
| 75 | 75 | mul_le_mul_of_nonneg_left happly (by positivity) |
| 76 | 76 | _ ≤ (8 * L) * (φ x ^ 3 * ‖w x‖) := by |
| 77 | - nlinarith [mul_le_mul_of_nonneg_right hp (mul_nonneg hL0 (norm_nonneg (w x)))] | |
| 77 | + linarith [mul_le_mul_of_nonneg_right hp (mul_nonneg hL0 (norm_nonneg (w x)))] | |
| 78 | 78 | _ = (8 * L) * ‖(φ x ^ 3) • w x‖ := by |
| 79 | 79 | rw [norm_smul, Real.norm_eq_abs, abs_of_nonneg (pow_nonneg hφ0 3)] |
| 80 | 80 | |
| @@ -194,7 +194,7 @@ theorem norm_fderiv_r_le_amplitude {φ : Space → ℝ} {w : Space → Space} | ||
| 194 | 194 | have hp4 : φ x ^ 4 ≤ 1 := pow_le_one₀ hφ0 hφ1 |
| 195 | 195 | have hp5 : φ x ^ 5 ≤ 1 := pow_le_one₀ hφ0 hφ1 |
| 196 | 196 | have hp54 : φ x ^ 5 ≤ φ x ^ 4 := by |
| 197 | - nlinarith [mul_le_mul_of_nonneg_left hφ1 (pow_nonneg hφ0 4)] | |
| 197 | + linarith [mul_le_mul_of_nonneg_left hφ1 (pow_nonneg hφ0 4)] | |
| 198 | 198 | have hgrad := GradientOperator.norm_fderiv_le_three_mul_sqrt_gradientSq w x |
| 199 | 199 | have h1 : φ x ^ 5 * ‖fderiv ℝ φ x‖ * ‖fderiv ℝ w x‖ ≤ |
| 200 | 200 | 3 * L * WeightedSobolev.cutoffGradientAmplitude φ w x := by |
+4 −5 NavierStokes/R3/WeightedInterpolation.lean View file
| @@ -142,8 +142,8 @@ theorem cutoff_interpolation | ||
| 142 | 142 | comparisonLpNorm 6 (fun x => (φ x ^ 4) • w x) ^ ((k : ℝ) / 4) := by |
| 143 | 143 | apply memLp_and_lpNorm_le_rpow_mul hw hweighted ((hφm.pow k).smul hw.1) |
| 144 | 144 | (by norm_num) (by norm_num) hr ha hb |
| 145 | - · simpa using hra | |
| 146 | - · simpa using hab | |
| 145 | + · exact hra | |
| 146 | + · exact hab | |
| 147 | 147 | · exact Filter.Eventually.of_forall fun x => (norm_weight_pow_eq (hφ x) (w x) k).le |
| 148 | 148 | |
| 149 | 149 | /-- `φ w` belongs to `L^(12/5)` with the exact endpoint interpolation bound. -/ |
| @@ -209,12 +209,11 @@ theorem cutoff_transport_bound | ||
| 209 | 209 | ring |
| 210 | 210 | have hint : Integrable (fun x => φ x ^ 6 * ‖w x‖ ^ 3) volume := by |
| 211 | 211 | have hi := hmem.integrable_norm_rpow (by norm_num) (by norm_num) |
| 212 | - exact hi.congr (Filter.Eventually.of_forall fun x => by simpa using hid x) | |
| 212 | + exact hi.congr (Filter.Eventually.of_forall fun x => hid x) | |
| 213 | 213 | refine ⟨hint, ?_⟩ |
| 214 | 214 | calc |
| 215 | 215 | (∫ x : Space, φ x ^ 6 * ‖w x‖ ^ 3) = |
| 216 | - (∫ x : Space, ‖(φ x ^ 2) • w x‖ ^ (3 : ℝ)) := by | |
| 217 | - exact integral_congr_ae (Filter.Eventually.of_forall fun x => (hid x).symm) | |
| 216 | + (∫ x : Space, ‖(φ x ^ 2) • w x‖ ^ (3 : ℝ)) := integral_congr_ae (Filter.Eventually.of_forall fun x => (hid x).symm) | |
| 218 | 217 | _ = comparisonLpNorm 3 (fun x => (φ x ^ 2) • w x) ^ (3 : ℝ) := by |
| 219 | 218 | simpa using integral_norm_rpow_eq_lpNorm_rpow (by norm_num) hmem |
| 220 | 219 | _ ≤ (comparisonLpNorm 2 w ^ (1 / 2 : ℝ) * |
+2 −2 NavierStokes/R3/WeightedSobolev.lean View file
| @@ -153,7 +153,7 @@ theorem norm_fderiv_cutoff_four_le_amplitude {φ : Space → ℝ} {w : Space → | ||
| 153 | 153 | (4 * L) * ‖w x‖ := by |
| 154 | 154 | apply add_le_add |
| 155 | 155 | · exact mul_le_mul_of_nonneg_left hg (by positivity) |
| 156 | - · nlinarith [mul_le_mul_of_nonneg_right hd (norm_nonneg (w x))] | |
| 156 | + · linarith [mul_le_mul_of_nonneg_right hd (norm_nonneg (w x))] | |
| 157 | 157 | _ = _ := by unfold cutoffGradientAmplitude; ring |
| 158 | 158 | |
| 159 | 159 | /-- The derivative of the cutoff velocity has a finite `L²` bound involving |
| @@ -215,7 +215,7 @@ theorem weighted_sobolev {φ : Space → ℝ} {w : Space → Space} | ||
| 215 | 215 | apply hSob.trans |
| 216 | 216 | apply (mul_le_mul_of_nonneg_left hDer hS).trans |
| 217 | 217 | unfold weightedSobolevConstant |
| 218 | - nlinarith [mul_nonneg hS hA, mul_nonneg hL0 hM] | |
| 218 | + linarith [mul_nonneg hS hA, mul_nonneg hL0 hM] | |
| 219 | 219 | |
| 220 | 220 | /-- Time-slice form using precisely the common comparison definitions. -/ |
| 221 | 221 | theorem cutoffL6_le {φ : Space → ℝ} {w : VelocityField} {t : ℝ} |
+1 −1 NavierStokes/R3CompactCandidate.lean View file
| @@ -53,7 +53,7 @@ theorem outerCutoff_one {x : Space} (hx : x ∈ supportCylinder) : outerCutoff x | ||
| 53 | 53 | have hrad : |16 * radialSquare ((1 / 2 : ℝ) • x)| ≤ 1 / 2 := by |
| 54 | 54 | rw [abs_of_nonneg (mul_nonneg (by norm_num) (radialSquare_nonneg _))] |
| 55 | 55 | simp only [radialSquare, PiLp.smul_apply, smul_eq_mul] at hr ⊢ |
| 56 | - nlinarith | |
| 56 | + linarith | |
| 57 | 57 | have hax : |4 * ((1 / 2 : ℝ) • x) 2| ≤ 1 / 2 := by |
| 58 | 58 | simp only [PiLp.smul_apply, smul_eq_mul, ← mul_assoc] |
| 59 | 59 | norm_num |
+14 −14 NavierStokes/ReferenceBounds.lean View file
| @@ -288,14 +288,14 @@ theorem lower_comparison_preserves {X a L b q : ℝ} | ||
| 288 | 288 | have hX : 0 < X := ha.trans_le haX |
| 289 | 289 | have hfac : 0 ≤ q * (X + a) - 2 * b * L := by |
| 290 | 290 | have hm := mul_le_mul_of_nonneg_left haX hq |
| 291 | - nlinarith | |
| 291 | + linarith | |
| 292 | 292 | have hprod := mul_nonneg (sub_nonneg.mpr haX) hfac |
| 293 | 293 | have heq : b * a / X + q / (2 * L) * (X - a ^ 2 / X) = |
| 294 | 294 | (2 * L * b * a + q * (X ^ 2 - a ^ 2)) / (2 * L * X) := by |
| 295 | 295 | field_simp |
| 296 | 296 | rw [heq] |
| 297 | 297 | apply (le_div_iff₀ (by positivity : 0 < 2 * L * X)).mpr |
| 298 | - nlinarith | |
| 298 | + linarith | |
| 299 | 299 | |
| 300 | 300 | theorem p1_preserves_lower {p : Point} (hp : p ∈ D.carrier) (hX : 0 < p.1) |
| 301 | 301 | (h : ℝ) (hL : 0 < NaturalAxisData.L h p.2) {a b q : ℝ} |
| @@ -318,7 +318,7 @@ theorem p1_at_hundred_gt_three {η h : ℝ} (hp : (100, η) ∈ D.carrier) | ||
| 318 | 318 | (by norm_num : (0 : ℝ) ≤ 12 / 5) hf hmono hsource |
| 319 | 319 | have hn : (3 : ℝ) < (12 / 5) * 100 / (2 * NaturalAxisData.L h η) := by |
| 320 | 320 | apply (lt_div_iff₀ (mul_pos (by norm_num) hL)).mpr |
| 321 | - nlinarith | |
| 321 | + linarith | |
| 322 | 322 | exact hn.trans_le hb |
| 323 | 323 | |
| 324 | 324 | theorem p2_large_of_small_f {p : Point} (hX : 0 < p.1) (hX110 : p.1 ≤ 110) |
| @@ -328,7 +328,7 @@ theorem p2_large_of_small_f {p : Point} (hX : 0 < p.1) (hX110 : p.1 ≤ 110) | ||
| 328 | 328 | (hn : ν ≤ |ns P h p|) (hlarge : 18 * K / (a * ν) < C) : |
| 329 | 329 | (6 / 5 : ℝ) < |p2 P h p| := by |
| 330 | 330 | have hs : Real.sqrt (2 * p.1) ≤ 15 := |
| 331 | - (Real.sqrt_le_iff).mpr ⟨by norm_num, by nlinarith⟩ | |
| 331 | + (Real.sqrt_le_iff).mpr ⟨by norm_num, by linarith⟩ | |
| 332 | 332 | have hE : 0 < P.E p := mul_pos (Real.sqrt_pos.mpr (by positivity)) hf |
| 333 | 333 | have hEb : P.E p ≤ 15 * K / C := by |
| 334 | 334 | change Real.sqrt (2 * p.1) * P.f p ≤ _ |
| @@ -338,7 +338,7 @@ theorem p2_large_of_small_f {p : Point} (hX : 0 < p.1) (hX110 : p.1 ≤ 110) | ||
| 338 | 338 | have hc : 18 * K / C < a * ν := by |
| 339 | 339 | apply (div_lt_iff₀ hC).mpr |
| 340 | 340 | have hh := (div_lt_iff₀ (mul_pos ha hν)).mp hlarge |
| 341 | - nlinarith | |
| 341 | + linarith | |
| 342 | 342 | have hnprod : a * ν ≤ p.1 * |ns P h p| := |
| 343 | 343 | mul_le_mul haX hn hν.le hX.le |
| 344 | 344 | rw [p2, abs_div, abs_mul, abs_of_pos hX, abs_of_pos hE] |
| @@ -358,7 +358,7 @@ theorem cone_margin_of_dichotomy {a b : ℝ} (ha : 0 < a) | ||
| 358 | 358 | have habs := sq_lt_sq₀ (by norm_num : (0 : ℝ) ≤ 6 / 5) (abs_nonneg b) |>.mpr hsecond |
| 359 | 359 | simpa only [sq_abs] using habs |
| 360 | 360 | have hm : (12 / 5 : ℝ) * a < a ^ 2 + b ^ 2 := by |
| 361 | - nlinarith [sq_nonneg (a - 6 / 5)] | |
| 361 | + linarith [sq_nonneg (a - 6 / 5)] | |
| 362 | 362 | have hd : (12 / 5 : ℝ) < a + b ^ 2 / a := by |
| 363 | 363 | calc |
| 364 | 364 | (12 / 5 : ℝ) < (a ^ 2 + b ^ 2) / a := (lt_div_iff₀ ha).mpr hm |
| @@ -483,15 +483,15 @@ theorem qModel_uniform_lower {h j σ : ℝ} {P0 : ℝ → ℝ} | ||
| 483 | 483 | have hmul := (div_lt_iff₀ hδ).mp hΛ' |
| 484 | 484 | have ht : |1 / Λ| < δ := by |
| 485 | 485 | rw [abs_of_pos (one_div_pos.mpr hΛ0), div_lt_iff₀ hΛ0] |
| 486 | - nlinarith | |
| 486 | + linarith | |
| 487 | 487 | have he' : |e| < δ := he.trans_lt (by |
| 488 | 488 | apply (div_lt_iff₀ hΛ0).mpr |
| 489 | - nlinarith) | |
| 489 | + linarith) | |
| 490 | 490 | have hnorm : ‖((1 / Λ), e)‖ < δ := by |
| 491 | 491 | simpa only [Prod.norm_def, Real.norm_eq_abs, max_lt_iff] using And.intro ht he' |
| 492 | 492 | have herror := (abs_lt.mp (hpert p ((1 / Λ), e) hnorm)).1 |
| 493 | 493 | have hb := hmain Λ ((le_max_left _ _).trans hΛ) p |
| 494 | - nlinarith | |
| 494 | + linarith | |
| 495 | 495 | |
| 496 | 496 | abbrev AxialSourceParameter (B : ℝ) := Icc (-1 : ℝ) 1 × BoundedJets B |
| 497 | 497 | |
| @@ -595,7 +595,7 @@ theorem sourceQ_model (h j σ : ℝ) {Λ φ Y θ r : ℝ} (hΛ : Λ ≠ 0) | ||
| 595 | 595 | qRemainder h j σ (Y, p.2) θ (qJets P j σ h Λ φ p) (1 / Λ) r := by |
| 596 | 596 | have hg := NaturalProfile.gradient_identity h j σ p.2 |
| 597 | 597 | simp only [qRemainder, qJets, Matrix.cons_val_zero, Matrix.cons_val_one, |
| 598 | - Matrix.cons_val, Fin.isValue, max_eq_right hφ] | |
| 598 | + Matrix.cons_val, max_eq_right hφ] | |
| 599 | 599 | rw [← hrad] |
| 600 | 600 | unfold sourceQ logSlope Profiles.W |
| 601 | 601 | unfold NaturalAxisData.W NaturalAxisData.H at hg ⊢ |
| @@ -792,7 +792,7 @@ theorem reference_p1_natural {δ : ℝ} (hδ : 0 < δ) (hδT : 2 * δ < rampLimi | ||
| 792 | 792 | p1 (referenceProfiles F hΛ hδ hδT hP0) h p = NaturalEntrance.p1 F.family.f p := by |
| 793 | 793 | let N := Input.ofNatural hΛ F.family |
| 794 | 794 | let P := referenceProfiles F hΛ hδ hδT hP0 |
| 795 | - have hY : Λ * p.1 ≤ 4 := by nlinarith [(le_div_iff₀ hΛ).mp ha] | |
| 795 | + have hY : Λ * p.1 ≤ 4 := by linarith [(le_div_iff₀ hΛ).mp ha] | |
| 796 | 796 | have hpoint : rescalePoint Λ p ∈ NaturalEntrance.entranceSet := |
| 797 | 797 | ⟨⟨mul_nonneg hΛ.le hX.le, by change Λ * p.1 ≤ 41 / 10; linarith⟩, hη⟩ |
| 798 | 798 | have hp := NaturalEntrance.entrance_mem_strip hpoint |
| @@ -951,7 +951,7 @@ theorem pressureJets_small {p : Point} (hp : p ∈ D.carrier) | ||
| 951 | 951 | have hinv : |1 / Λ| < ε := by |
| 952 | 952 | rw [abs_of_pos (one_div_pos.mpr hΛ0), div_lt_iff₀ hΛ0] |
| 953 | 953 | have hmul := (div_lt_iff₀ hε).mp (show 1 / ε < Λ by linarith) |
| 954 | - nlinarith | |
| 954 | + linarith | |
| 955 | 955 | have hsize : 220 * K ^ 2 / C ^ 2 < ε := by |
| 956 | 956 | apply (div_lt_iff₀ (sq_pos_of_pos hC0)).mpr |
| 957 | 957 | have hb := (div_lt_iff₀ hε).mp (show 220 * K ^ 2 / ε < C by linarith) |
| @@ -1224,7 +1224,7 @@ theorem exists_reference_bounds {h j σ ν : ℝ} {P0 : ℝ → ℝ} | ||
| 1224 | 1224 | (47 / 50 : ℝ) * NaturalAxisData.L h p.2 * Λ * NaturalAxisData.chi h j σ p.2 + 12 / 5 < |
| 1225 | 1225 | sourceQ P h p := by |
| 1226 | 1226 | by_cases hnat : p.1 ≤ 4 / Λ |
| 1227 | - · have hY : Λ * p.1 ≤ 4 := by nlinarith [(le_div_iff₀ hΛ).mp hnat] | |
| 1227 | + · have hY : Λ * p.1 ≤ 4 := by linarith [(le_div_iff₀ hΛ).mp hnat] | |
| 1228 | 1228 | have hpoint : NaturalProfile.rescalePoint Λ p ∈ NaturalEntrance.entranceSet := |
| 1229 | 1229 | ⟨⟨mul_nonneg hΛ.le hp.1.1, by change Λ * p.1 ≤ 41 / 10; linarith⟩, hp.2⟩ |
| 1230 | 1230 | have he := reference_sourceQ_natural E.profile hΛ hδ hc.length_bound hP0 |
| @@ -1235,7 +1235,7 @@ theorem exists_reference_bounds {h j σ ν : ℝ} {P0 : ℝ → ℝ} | ||
| 1235 | 1235 | have hnonneg : 0 ≤ NaturalAxisData.L h p.2 * Λ * NaturalAxisData.chi h j σ p.2 := |
| 1236 | 1236 | mul_nonneg (mul_nonneg (NaturalAxisData.L_pos hsmall hp.2).le hΛ.le) |
| 1237 | 1237 | (NaturalAxisData.chi_bounds h j hσ p.2).1 |
| 1238 | - nlinarith | |
| 1238 | + linarith | |
| 1239 | 1239 | · obtain ⟨s⟩ := hsamples p hp (le_of_lt (lt_of_not_ge hnat)) |
| 1240 | 1240 | exact hqmodel Λ hscaleq P p s.Y s.theta s.phi s.error s.point_mem s.theta_mem |
| 1241 | 1241 | s.phi_lower s.phi_upper s.error_bound (hJ.axial_value p hp) |
+2 −2 NavierStokes/ReferenceJetBounds.lean View file
| @@ -218,13 +218,13 @@ theorem natural_amplitude_bounds (hσ : 0 < σ) (hΛ : 0 < Λ) (hC : 0 < C) | ||
| 218 | 218 | · apply hf0.trans |
| 219 | 219 | have hb := mul_le_mul_of_nonneg_left |
| 220 | 220 | (show (1 : ℝ) ≤ 1 + Λ * G + 8 * jetConstant d.coefficients 0 1 by |
| 221 | - nlinarith [mul_nonneg hΛ.le hG]) hbase | |
| 221 | + linarith [mul_nonneg hΛ.le hG]) hbase | |
| 222 | 222 | simpa only [mul_one, amplitudeConstant, mul_div_assoc, div_mul_eq_mul_div, mul_assoc] using hb |
| 223 | 223 | · apply hfη.trans |
| 224 | 224 | have hb := mul_le_mul_of_nonneg_left |
| 225 | 225 | (show Λ * G + 8 * jetConstant d.coefficients 0 1 ≤ |
| 226 | 226 | 1 + Λ * G + 8 * jetConstant d.coefficients 0 1 by linarith) hbase |
| 227 | - simpa only [amplitudeConstant, mul_div_assoc, div_mul_eq_mul_div, mul_assoc] using hb | |
| 227 | + simpa only [amplitudeConstant, div_mul_eq_mul_div, mul_assoc] using hb | |
| 228 | 228 | |
| 229 | 229 | end Natural |
| 230 | 230 | |
+3 −3 NavierStokes/ReferencePath.lean View file
| @@ -225,11 +225,11 @@ theorem continuation_eq_master_hold {T δ : ℝ} (hT : 0 < T) (hδ : 0 < δ) (h | ||
| 225 | 225 | {t η : ℝ} (hη : η ∈ J) (_ : 0 ≤ t) : |
| 226 | 226 | continuation δ G (t, η) = master G ((δ, holdTime δ t), η) := by |
| 227 | 227 | by_cases hsmall : t ≤ 2 * δ |
| 228 | - · have htdiv : t / δ ≤ 2 := (div_le_iff₀ hδ).2 (by nlinarith) | |
| 228 | + · have htdiv : t / δ ≤ 2 := (div_le_iff₀ hδ).2 (by linarith) | |
| 229 | 229 | rw [holdTime, min_eq_left htdiv, ← continuation_rescaled G hδ.ne'] |
| 230 | 230 | rw [mul_div_cancel₀ _ hδ.ne'] |
| 231 | 231 | · have hbig : 2 * δ ≤ t := (lt_of_not_ge hsmall).le |
| 232 | - have htdiv : 2 ≤ t / δ := (le_div_iff₀ hδ).2 (by nlinarith) | |
| 232 | + have htdiv : 2 ≤ t / δ := (le_div_iff₀ hδ).2 (by linarith) | |
| 233 | 233 | rw [continuation_frozen hT hδ hδT hJ hG hη hbig, |
| 234 | 234 | holdTime, min_eq_right htdiv, ← continuation_rescaled G hδ.ne'] |
| 235 | 235 | rw [mul_comm δ 2] |
| @@ -389,7 +389,7 @@ theorem fromLog_mem {p : Point} | ||
| 389 | 389 | rw [N.fromLog_scaled] |
| 390 | 390 | have hupper : Real.exp p.1 < 41 / 40 := by |
| 391 | 391 | simpa only [rampLimit, Real.exp_log (by norm_num : (0 : ℝ) < 41 / 40)] using Real.exp_lt_exp.mpr hp.1 |
| 392 | - refine ⟨⟨?_, ?_⟩, hp.2⟩ <;> nlinarith [Real.exp_pos p.1] | |
| 392 | + refine ⟨⟨?_, ?_⟩, hp.2⟩ <;> linarith [Real.exp_pos p.1] | |
| 393 | 393 | |
| 394 | 394 | theorem fromLog_f_pos {p : Point} |
| 395 | 395 | (hp : p ∈ (earlyStrip rampLimit rampLimit_pos parameterInterval parameterInterval_open).carrier) : |
+4 −4 NavierStokes/RenormalizedHeatMoment.lean View file
| @@ -221,7 +221,7 @@ theorem normalized_coordinates {h e : ℝ} (hh : 0 < h) (hh1 : h < 1 / 2) | ||
| 221 | 221 | have hτ : 0 < 1 - e ^ 2 := by |
| 222 | 222 | have hp := mul_pos (show 0 < 1 - e by linarith [he.2]) |
| 223 | 223 | (show 0 < 1 + e by linarith [he.1]) |
| 224 | - nlinarith | |
| 224 | + linarith | |
| 225 | 225 | have hq : Q h (1 - e ^ 2) e = 1 := |
| 226 | 226 | (SimilarityCoordinates.eq_coordinateQ (by linarith : 0 < 2 * h) |
| 227 | 227 | (by linarith : 2 * h < 1) (p := (1 - e ^ 2, e)) hτ zero_lt_one |
| @@ -382,7 +382,7 @@ theorem weighted_referencePower_nonneg_radius {h : ℝ} (hh1 : h < 1 / 2) | ||
| 382 | 382 | (C : ℝ) {r : ℝ} (hr : 0 ≤ r) : |
| 383 | 383 | r ^ 2 * referencePower h C r = C * (2 : ℝ) ^ A h * r ^ (1 - 2 * h) := by |
| 384 | 384 | rcases eq_or_lt_of_le hr with rfl | hr |
| 385 | - · simp [referencePower, Real.zero_rpow (by linarith : 1 - 2 * h ≠ 0)] | |
| 385 | + · simp [Real.zero_rpow (by linarith : 1 - 2 * h ≠ 0)] | |
| 386 | 386 | · exact weighted_referencePower h C hr |
| 387 | 387 | |
| 388 | 388 | theorem radialDifference_continuousOn {h C : ℝ} {F : ℝ × ℝ → ℝ} |
| @@ -574,7 +574,7 @@ theorem radial_exterior_of_X_exterior {h C T : ℝ} (hT : 0 < T) {F E : ℝ × | ||
| 574 | 574 | have hXT : T ≤ R ^ 2 / 2 := by |
| 575 | 575 | have hs := Real.sq_sqrt (show 0 ≤ 2 * T from mul_nonneg (by norm_num) hT.le) |
| 576 | 576 | have hsq := sq_le_sq₀ (Real.sqrt_nonneg (2 * T)) hRp.le |
| 577 | - nlinarith [(hsq.mpr hR)] | |
| 577 | + linarith [(hsq.mpr hR)] | |
| 578 | 578 | rw [hFE R hRp eta hη, he eta hη _ hXT] |
| 579 | 579 | have hexp : RadialHeatProfile.spatialExponent (1 + h) = -A h := by |
| 580 | 580 | unfold RadialHeatProfile.spatialExponent A |
| @@ -716,7 +716,7 @@ theorem heated_nominal_axial_viscosity (P : OutgoingProfile.Profile) | ||
| 716 | 716 | rw [xMoment_eq_outgoing_reference P w.radius_pos, hreset eta hη] |
| 717 | 717 | exact w.renormalized_zero eta ⟨hη.1.le, hη.2.le⟩ |
| 718 | 718 | unfold uTheta |
| 719 | - simpa only [show 2 = 1 + 1 from rfl, iteratedDeriv_succ, iteratedDeriv_one, iteratedDeriv_zero] using | |
| 719 | + simpa only [iteratedDeriv_succ, iteratedDeriv_one, iteratedDeriv_zero] using | |
| 720 | 720 | physical_axial_viscosity_zero_of_X_profile P.data.h_pos hh1 (sub_pos.mpr ht) |
| 721 | 721 | hT hF hFE he hm z |
| 722 | 722 | |
+6 −6 NavierStokes/RepairConeBounds.lean View file
| @@ -698,7 +698,7 @@ noncomputable def observations (F : Profile) (z : Control × Point) : Fin 22 → | ||
| 698 | 698 | theorem observations_contDiffOn (F : Profile) : ContDiffOn ℝ ∞ (observations F) (regular F) := by |
| 699 | 699 | apply contDiffOn_pi.mpr |
| 700 | 700 | intro i |
| 701 | - fin_cases i <;> dsimp only [observations, Matrix.cons_val_zero, Matrix.cons_val_succ] | |
| 701 | + fin_cases i <;> dsimp only [Matrix.cons_val_zero, Matrix.cons_val_succ] | |
| 702 | 702 | · exact (value_contDiff (freeE_contDiff F)).contDiffOn |
| 703 | 703 | · exact (value_contDiff (freeU_contDiff F)).contDiffOn |
| 704 | 704 | · exact (radialJet_contDiff (freeE_contDiff F)).contDiffOn |
| @@ -749,7 +749,7 @@ theorem model_margins (F : Profile) (hh : F.data.h ≤ 1 / 100) : | ||
| 749 | 749 | have he := (hb v (hv.trans (min_le_left _ _)) p hp).2 |
| 750 | 750 | have hn : L * ‖v‖ ≤ m := by |
| 751 | 751 | have hd := (le_div_iff₀ (by linarith : 0 < L + 1)).mp (hv.trans (min_le_right _ _)) |
| 752 | - nlinarith [norm_nonneg v] | |
| 752 | + linarith [norm_nonneg v] | |
| 753 | 753 | have hcomp (i : Fin 22) : |observations F (v, p) i - observations F (0, p) i| ≤ m := by |
| 754 | 754 | have hi := norm_le_pi_norm (observations F (v, p) - observations F (0, p)) i |
| 755 | 755 | exact hi.trans (he.trans hn) |
| @@ -940,7 +940,7 @@ theorem physical_transport {F : Profile} {A : NominalProfile.AxisStage F} | ||
| 940 | 940 | apply (eq_div_iff (Real.exp_ne_zero p.1)).mpr |
| 941 | 941 | apply (mul_left_cancel₀ c.radius_pos.ne') |
| 942 | 942 | dsimp only [chart] |
| 943 | - nlinarith [hw] | |
| 943 | + linarith [hw] | |
| 944 | 944 | |
| 945 | 945 | theorem physical_lags {F : Profile} {A : NominalProfile.AxisStage F} |
| 946 | 946 | (c : NominalProfile.Controls A) (hsep : c.separation ≤ Real.exp (-8)) |
| @@ -1142,7 +1142,7 @@ theorem exists_repair_cone_log (F : Profile) : | ||
| 1142 | 1142 | (ActivationContinuation.shearB (c.profiles hsep) (chart c.radius p)) := by |
| 1143 | 1143 | rw [physical_projection c hsep hp.1 heta hs] |
| 1144 | 1144 | have hl := mul_le_mul_of_nonneg_left hb.2.2 c.radius_pos.le |
| 1145 | - nlinarith | |
| 1145 | + linarith | |
| 1146 | 1146 | refine ⟨?_, hproj, ConeAlgebra.relaxed_cone_of_le_two hproj (hspeed.trans (by norm_num))⟩ |
| 1147 | 1147 | rw [ha] |
| 1148 | 1148 | exact lt_of_lt_of_le (by norm_num : (0 : ℝ) < 3 / 5) hb.1 |
| @@ -1168,9 +1168,9 @@ theorem exists_repair_cone (F : Profile) : | ||
| 1168 | 1168 | have hx : 0 < p.1 := (mul_pos c.radius_pos (Real.exp_pos (-8))).trans_le hp.1 |
| 1169 | 1169 | have hxR : 0 < p.1 / c.radius := div_pos hx c.radius_pos |
| 1170 | 1170 | have hlo : Real.exp (-8) ≤ p.1 / c.radius := |
| 1171 | - (le_div_iff₀ c.radius_pos).mpr (by nlinarith [hp.1]) | |
| 1171 | + (le_div_iff₀ c.radius_pos).mpr (by linarith [hp.1]) | |
| 1172 | 1172 | have hhi : p.1 / c.radius ≤ Real.exp (-5) := |
| 1173 | - (div_le_iff₀ c.radius_pos).mpr (by nlinarith [hp.2]) | |
| 1173 | + (div_le_iff₀ c.radius_pos).mpr (by linarith [hp.2]) | |
| 1174 | 1174 | have hy : Real.log (p.1 / c.radius) ∈ Icc (-8) (-5) := by |
| 1175 | 1175 | constructor |
| 1176 | 1176 | · simpa only [Real.log_exp] using Real.log_le_log (Real.exp_pos (-8)) hlo |
+7 −7 NavierStokes/ResetEnergyBounds.lean View file
| @@ -200,14 +200,14 @@ theorem resetDensity_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) {y : ℝ} | ||
| 200 | 200 | have hq : |(1 + r) ^ 2 - 1| ≤ 6 * (K * d.core.lam ^ (28 : ℕ)) := by |
| 201 | 201 | rw [show (1 + r) ^ 2 - 1 = r * (2 + r) by ring, abs_mul] |
| 202 | 202 | have h := mul_le_mul_of_nonneg_left h2 (abs_nonneg r) |
| 203 | - nlinarith | |
| 203 | + linarith | |
| 204 | 204 | have hS : d.core.endpoint ≤ y := |
| 205 | 205 | (flattenEnd_gt_core d).le.trans ((last_four_after_flatten d).le.trans hy.1) |
| 206 | 206 | have hE := energyDensity_prefix_le d eta heta hS hy.2 |
| 207 | 207 | rw [resetDensity_eq, abs_mul, abs_of_pos (energyDensity_pos d eta y)] |
| 208 | 208 | change energyDensity d eta y * |(1 + r) ^ 2 - 1| ≤ _ |
| 209 | 209 | have h := mul_le_mul hE hq (abs_nonneg _) (energyDensity_pos d eta d.core.endpoint).le |
| 210 | - nlinarith | |
| 210 | + linarith | |
| 211 | 211 | |
| 212 | 212 | theorem resetDensityEta_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) {y : ℝ} |
| 213 | 213 | (hy : y ∈ Icc (d.releaseStart - 4) d.releaseStart) : |
| @@ -224,16 +224,16 @@ theorem resetDensityEta_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) {y : ℝ} | ||
| 224 | 224 | have hq : |2 * (1 + r) * r'| ≤ 6 * (K * d.core.lam ^ (28 : ℕ)) := by |
| 225 | 225 | rw [abs_mul, abs_mul, abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 226 | 226 | have h := mul_le_mul_of_nonneg_right h1 (abs_nonneg r') |
| 227 | - nlinarith | |
| 227 | + linarith | |
| 228 | 228 | have hS : d.core.endpoint ≤ y := |
| 229 | 229 | (flattenEnd_gt_core d).le.trans ((last_four_after_flatten d).le.trans hy.1) |
| 230 | 230 | have hE := energyDensity_prefix_le d eta heta hS hy.2 |
| 231 | 231 | have hid : resetDensityEta d w.coefficients eta y = energyDensity d eta y * (2 * (1 + r) * r') := by |
| 232 | - dsimp [resetDensityEta, energyDensity, r, r'] | |
| 232 | + dsimp [resetDensityEta, energyDensity, r] | |
| 233 | 233 | rw [original_matches_reference d eta hy] |
| 234 | 234 | rw [hid, abs_mul, abs_of_pos (energyDensity_pos d eta y)] |
| 235 | 235 | have h := mul_le_mul hE hq (abs_nonneg _) (energyDensity_pos d eta d.core.endpoint).le |
| 236 | - nlinarith | |
| 236 | + linarith | |
| 237 | 237 | |
| 238 | 238 | theorem resetEnergy_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) : |
| 239 | 239 | |resetEnergy d w.coefficients eta| ≤ |
| @@ -247,7 +247,7 @@ theorem resetEnergy_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) : | ||
| 247 | 247 | simpa only [Real.norm_eq_abs] using resetDensity_abs_le w eta heta ⟨hy'.1.le, hy'.2⟩) |
| 248 | 248 | rw [Real.norm_eq_abs, show d.releaseStart - (d.releaseStart - 4) = 4 by ring] at h |
| 249 | 249 | norm_num at h |
| 250 | - nlinarith | |
| 250 | + linarith | |
| 251 | 251 | |
| 252 | 252 | theorem resetEnergy_deriv_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) : |
| 253 | 253 | |deriv (resetEnergy d w.coefficients) eta| ≤ |
| @@ -261,7 +261,7 @@ theorem resetEnergy_deriv_abs_le (eta : ℝ) (heta : eta ^ 2 ≤ 1) : | ||
| 261 | 261 | simpa only [Real.norm_eq_abs] using resetDensityEta_abs_le w eta heta ⟨hy'.1.le, hy'.2⟩) |
| 262 | 262 | rw [Real.norm_eq_abs, show d.releaseStart - (d.releaseStart - 4) = 4 by ring] at h |
| 263 | 263 | norm_num at h |
| 264 | - nlinarith | |
| 264 | + linarith | |
| 265 | 265 | |
| 266 | 266 | end Bounds |
| 267 | 267 | |
+6 −6 NavierStokes/ScaledActualParticularControl.lean View file
| @@ -399,7 +399,7 @@ theorem geometry_cost (clock : ActualSignedControl.PositiveScale Label) | ||
| 399 | 399 | nlinarith [clock.upper_one, coveringBound_pos budget, |
| 400 | 400 | mul_nonneg (coveringBound_pos budget).le (sub_nonneg.mpr hinv)] |
| 401 | 401 | have hU2 : H*(1+|clock.value l n|) ≤ U := by |
| 402 | - dsimp [U,geometryFactor,H] | |
| 402 | + dsimp [U,geometryFactor] | |
| 403 | 403 | nlinarith [inv_pos.mpr clock.lower_pos, coveringBound_pos budget, |
| 404 | 404 | mul_nonneg (coveringBound_pos budget).le (sub_nonneg.mpr hrate)] |
| 405 | 405 | have hcoord : ‖G.coordinateLinear‖ ≤ U*‖g.coordinateLinear‖ := by |
| @@ -442,11 +442,11 @@ theorem geometry_cost (clock : ActualSignedControl.PositiveScale Label) | ||
| 442 | 442 | have hcx := hcoord.trans (mul_le_mul_of_nonneg_left hc (zero_le_one.trans hU)) |
| 443 | 443 | have hpx := hpoint.trans (mul_le_mul_of_nonneg_left hp (zero_le_one.trans hU)) |
| 444 | 444 | have hB : 1 ≤ U*CommonCoverClass.argumentCost g := by |
| 445 | - nlinarith [mul_nonneg (sub_nonneg.mpr hU) (sub_nonneg.mpr hcost)] | |
| 445 | + linarith [mul_nonneg (sub_nonneg.mpr hU) (sub_nonneg.mpr hcost)] | |
| 446 | 446 | change 1+‖G.coordinateLinear‖+‖G.pointLinear‖*(1+‖G.coordinateLinear‖) ≤ _ |
| 447 | 447 | have hproduct := mul_le_mul hpx (add_le_add_right hcx 1) |
| 448 | 448 | (by positivity : 0 ≤ 1+‖G.coordinateLinear‖) (by positivity : 0 ≤ U*CommonCoverClass.argumentCost g) |
| 449 | - nlinarith [sq_nonneg (U*CommonCoverClass.argumentCost g-1)] | |
| 449 | + linarith [sq_nonneg (U*CommonCoverClass.argumentCost g-1)] | |
| 450 | 450 | |
| 451 | 451 | theorem geometry_cost_uniform (s : StripData P) (clock : ActualSignedControl.PositiveScale Label) |
| 452 | 452 | (reference : Label → ℕ → Geometry) (gap : Label → ℕ → ℕ) (budget : ℕ) |
| @@ -467,7 +467,7 @@ theorem geometry_cost_constant_one (clock : ActualSignedControl.PositiveScale La | ||
| 467 | 467 | (budget : ℕ) {C : ℝ} (hC : 1 ≤ C) : 1 ≤ 4*(geometryFactor clock budget)^2*C^2 := by |
| 468 | 468 | have hU := one_le_pow₀ (n := 2) (geometryFactor_one clock budget) |
| 469 | 469 | have hC2 := one_le_pow₀ (n := 2) hC |
| 470 | - nlinarith [mul_nonneg (sub_nonneg.mpr hU) (sub_nonneg.mpr hC2)] | |
| 470 | + linarith [mul_nonneg (sub_nonneg.mpr hU) (sub_nonneg.mpr hC2)] | |
| 471 | 471 | |
| 472 | 472 | /-! ## The actual active-window parameter and frequency scales -/ |
| 473 | 473 | |
| @@ -536,7 +536,7 @@ theorem slotCost_one (clock : ActualSignedControl.PositiveScale Label) (budget : | ||
| 536 | 536 | 1 ≤ slotCost hdet clock budget := |
| 537 | 537 | geometry_cost_constant_one clock budget (by |
| 538 | 538 | have hc := CommonCoverClass.bandArgumentCost_one_le (TorusAverages.slotChart vr vt hdet) 0 |
| 539 | - nlinarith) | |
| 539 | + linarith) | |
| 540 | 540 | |
| 541 | 541 | theorem slot_geometry_cost (s : StripData P) (hh : 0 ≤ h) |
| 542 | 542 | (clock : ActualSignedControl.PositiveScale Label) (gap : Label → ℕ → ℕ) (budget : ℕ) |
| @@ -552,7 +552,7 @@ theorem slot_geometry_cost (s : StripData P) (hh : 0 ≤ h) | ||
| 552 | 552 | (zero_le_one.trans (CommonCoverClass.bandArgumentCost_one_le (TorusAverages.slotChart vr vt hdet) 0)) |
| 553 | 553 | convert! hm using 1 |
| 554 | 554 | ring |
| 555 | - simpa only [slotCost, Nat.mul_one] using geometry_cost_uniform s clock | |
| 555 | + simpa only [slotCost] using geometry_cost_uniform s clock | |
| 556 | 556 | (slotReference sys hdet slot) gap budget hgap hr |
| 557 | 557 | |
| 558 | 558 | theorem actualSlot_tangent_eq |
+2 −2 NavierStokes/Scaling.lean View file
| @@ -92,8 +92,8 @@ theorem reciprocal_frequency_bounds {ε : ℝ} (hε : 0 < ε) (hε₁ : ε ≤ 1 | ||
| 92 | 92 | have hs : Real.sqrt ε ≤ 1 := Real.sqrt_le_one.mpr hε₁ |
| 93 | 93 | constructor |
| 94 | 94 | · apply (le_div_iff₀ hk).mpr |
| 95 | - nlinarith | |
| 95 | + linarith | |
| 96 | 96 | · apply (div_le_iff₀ hk).mpr |
| 97 | - nlinarith | |
| 97 | + linarith | |
| 98 | 98 | |
| 99 | 99 | end NavierStokes.Scaling |
+25 −25 NavierStokes/ShapedWaitBounds.lean View file
| @@ -26,7 +26,7 @@ theorem linearLag_le_constant {r b : ℝ → ℝ} (hr : Continuous r) (hb : Cont | ||
| 26 | 26 | {q₀ B y : ℝ} (hy : 0 ≤ y) (hq : q₀ ≤ B) |
| 27 | 27 | (hs : ∀ t ∈ Icc (0 : ℝ) y, b t ≤ r t * B) : linearLag r b q₀ y ≤ B := by |
| 28 | 28 | have h := linearLag_lower_barrier hr hb.fun_neg (q₀ := -q₀) (β := -B) (κ := 0) hy |
| 29 | - (by linarith) (fun t ht => by have := hs t ht; nlinarith) | |
| 29 | + (by linarith) (fun t ht => by have := hs t ht; linarith) | |
| 30 | 30 | rw [linearLag_neg] at h |
| 31 | 31 | linarith |
| 32 | 32 | |
| @@ -39,7 +39,7 @@ theorem linearLag_abs_le {r b : ℝ → ℝ} (hr : Continuous r) (hb : Continuou | ||
| 39 | 39 | have h := linearLag_lower_barrier hr hb (β := -B) (κ := 0) hy |
| 40 | 40 | (by have := (abs_le.mp hq).1; linarith) (fun t ht => by |
| 41 | 41 | have := (abs_le.mp (hs t ht)).1 |
| 42 | - nlinarith) | |
| 42 | + linarith) | |
| 43 | 43 | linarith |
| 44 | 44 | |
| 45 | 45 | theorem angularSource_abs_bound (c : Parameters) {h y η : ℝ} (hh : 0 ≤ h) |
| @@ -54,26 +54,26 @@ theorem angularSource_abs_bound (c : Parameters) {h y η : ℝ} (hh : 0 ≤ h) | ||
| 54 | 54 | (transportW_bounds c hh hh1 hy hη).2.trans (by norm_num)⟩ |
| 55 | 55 | have hk := dropCoefficient_bounds c.m y |
| 56 | 56 | have hsq := parameter_square_le_one hη |
| 57 | - have hd : 0 ≤ d η ∧ d η ≤ 1 := by unfold d; constructor <;> nlinarith [sq_nonneg η] | |
| 57 | + have hd : 0 ≤ d η ∧ d η ≤ 1 := by unfold d; constructor <;> linarith [sq_nonneg η] | |
| 58 | 58 | have hD : 0 ≤ D h ∧ D h ≤ 1 / 2 := by unfold D; constructor <;> linarith |
| 59 | 59 | have hJ := eta_shapeGradient_bounds hη |
| 60 | 60 | have hcoef : |1 - 2 * dropCoefficient c.m y * η ^ 2| ≤ 9 := by |
| 61 | 61 | have hp := mul_le_mul hk.2 hsq (sq_nonneg η) (by norm_num : (0 : ℝ) ≤ 4) |
| 62 | 62 | apply abs_le.mpr |
| 63 | - constructor <;> nlinarith [mul_nonneg hk.1 (sq_nonneg η)] | |
| 63 | + constructor <;> linarith [mul_nonneg hk.1 (sq_nonneg η)] | |
| 64 | 64 | have hfirst : |-slope c.dropLength c.lam y * transportW c h y η| ≤ 3 := by |
| 65 | 65 | rw [abs_mul, abs_neg] |
| 66 | 66 | exact (mul_le_mul hl hW (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 1)).trans_eq (by ring) |
| 67 | 67 | have hsecond : |h * (1 - 2 * dropCoefficient c.m y * η ^ 2)| ≤ 9 / 100 := by |
| 68 | 68 | rw [abs_mul, abs_of_nonneg hh] |
| 69 | 69 | have hb := mul_le_mul hh1 hcoef (abs_nonneg _) (by norm_num : (0 : ℝ) ≤ 1 / 100) |
| 70 | - nlinarith | |
| 70 | + linarith | |
| 71 | 71 | have hbase : 0 ≤ D h + d η * dropCoefficient c.m y ∧ D h + d η * dropCoefficient c.m y ≤ 9 / 2 := by |
| 72 | 72 | have hb := mul_le_mul hd.2 hk.2 hk.1 (by norm_num : (0 : ℝ) ≤ 1) |
| 73 | - constructor <;> nlinarith [mul_nonneg hd.1 hk.1] | |
| 73 | + constructor <;> linarith [mul_nonneg hd.1 hk.1] | |
| 74 | 74 | have hthird : |(D h + d η * dropCoefficient c.m y) * η * shapeGradient η| ≤ 9 / 2 := by |
| 75 | - rw [mul_assoc, abs_mul, abs_of_nonneg hbase.1, abs_of_nonneg (by nlinarith [sq_nonneg η] : 0 ≤ η * shapeGradient η)] | |
| 76 | - exact (mul_le_mul hbase.2 hJ.2 (by nlinarith [sq_nonneg η]) (by norm_num : (0 : ℝ) ≤ 9 / 2)).trans_eq (by ring) | |
| 75 | + rw [mul_assoc, abs_mul, abs_of_nonneg hbase.1, abs_of_nonneg (by linarith [sq_nonneg η] : 0 ≤ η * shapeGradient η)] | |
| 76 | + exact (mul_le_mul hbase.2 hJ.2 (by linarith [sq_nonneg η]) (by norm_num : (0 : ℝ) ≤ 9 / 2)).trans_eq (by ring) | |
| 77 | 77 | unfold angularSource |
| 78 | 78 | have hs : |-slope c.dropLength c.lam y * transportW c h y η - |
| 79 | 79 | h * (1 - 2 * dropCoefficient c.m y * η ^ 2) + |
| @@ -190,13 +190,13 @@ theorem equilibrium_bounds (v : TailData) {η : ℝ} (hh1 : v.h ≤ 1 / 100) (h | ||
| 190 | 190 | have hr := hold_rate_pos v.core |
| 191 | 191 | have hj := eta_shapeGradient_bounds hη |
| 192 | 192 | have hD : 0 ≤ D v.h ∧ D v.h ≤ 1 / 2 := by unfold D; constructor <;> linarith [v.h_pos] |
| 193 | - have hprod := mul_le_mul hD.2 hj.2 (by nlinarith [sq_nonneg η]) (by norm_num : (0 : ℝ) ≤ 1 / 2) | |
| 194 | - have hprod0 := mul_nonneg hD.1 (show 0 ≤ η * shapeGradient η by nlinarith [sq_nonneg η]) | |
| 193 | + have hprod := mul_le_mul hD.2 hj.2 (by linarith [sq_nonneg η]) (by norm_num : (0 : ℝ) ≤ 1 / 2) | |
| 194 | + have hprod0 := mul_nonneg hD.1 (show 0 ≤ η * shapeGradient η by linarith [sq_nonneg η]) | |
| 195 | 195 | unfold equilibrium |
| 196 | 196 | constructor |
| 197 | - · exact div_nonneg (by nlinarith [v.h_small, v.h_pos]) hr.le | |
| 197 | + · exact div_nonneg (by linarith [v.h_small, v.h_pos]) hr.le | |
| 198 | 198 | · apply (div_le_iff₀ hr).mpr |
| 199 | - nlinarith [v.core.lam_lt, v.h_pos] | |
| 199 | + linarith [v.core.lam_lt, v.h_pos] | |
| 200 | 200 | |
| 201 | 201 | theorem holdCoefficient_bounds (c : Parameters) {h η : ℝ} (hh : 0 ≤ h) |
| 202 | 202 | (hh1 : h ≤ 1 / 100) (hη : |η| ≤ 1) : 0 ≤ holdCoefficient c h η ∧ holdCoefficient c h η ≤ 4 := by |
| @@ -221,7 +221,7 @@ theorem angularLag_hold_error (v : TailData) {η t : ℝ} (hh1 : v.h ≤ 1 / 100 | ||
| 221 | 221 | (holdCoefficient v.core v.h η)).trans (add_le_add_left (abs_sub _ _) _) |
| 222 | 222 | linarith |
| 223 | 223 | have hex : Real.exp (-t) ≤ Real.exp (-(1 - v.core.lam) * t) := |
| 224 | - Real.exp_le_exp.mpr (by nlinarith [mul_nonneg v.core.lam_pos.le ht]) | |
| 224 | + Real.exp_le_exp.mpr (by linarith [mul_nonneg v.core.lam_pos.le ht]) | |
| 225 | 225 | rw [angularLag_hold_formula v.core v.h η ht] |
| 226 | 226 | have hf : holdFormula v.core v.h η t - equilibrium v.core v.h η = |
| 227 | 227 | (angularLag v.core v.h η v.core.holdStart - equilibrium v.core v.h η - holdCoefficient v.core v.h η) * |
| @@ -253,7 +253,7 @@ theorem decay_le_power (c : Parameters) (n : ℕ) (ht : waitForPower c n ≤ c.w | ||
| 253 | 253 | Real.exp (-(1 - c.lam) * c.wait) ≤ c.lam ^ n := by |
| 254 | 254 | have hmul := (div_le_iff₀ (hold_rate_pos c)).mp ht |
| 255 | 255 | calc |
| 256 | - _ ≤ Real.exp ((n : ℝ) * Real.log c.lam) := Real.exp_le_exp.mpr (by nlinarith) | |
| 256 | + _ ≤ Real.exp ((n : ℝ) * Real.log c.lam) := Real.exp_le_exp.mpr (by linarith) | |
| 257 | 257 | _ = _ := by rw [Real.exp_nat_mul, Real.exp_log c.lam_pos] |
| 258 | 258 | |
| 259 | 259 | theorem canonical_Qs_pulseStart_power_error {v : TailData} {K : ℝ} |
| @@ -283,7 +283,7 @@ theorem holdFloor_bounds (m : ℝ) : holdFloor m ≤ coneFloor ∧ holdFloor m | ||
| 283 | 283 | linarith) |
| 284 | 284 | have hc := coneFloor_pos |
| 285 | 285 | refine ⟨?_, min_le_right _ _, by linarith⟩ |
| 286 | - nlinarith [mul_le_mul_of_nonneg_left he hc.le] | |
| 286 | + linarith [mul_le_mul_of_nonneg_left he hc.le] | |
| 287 | 287 | |
| 288 | 288 | theorem holdSource_lower (v : TailData) {η t : ℝ} (hh1 : v.h ≤ 1 / 100) |
| 289 | 289 | (hhlam : v.h ≤ v.core.lam / 4) (hη : |η| ≤ 1) (ht : 0 ≤ t) : |
| @@ -298,14 +298,14 @@ theorem holdSource_lower (v : TailData) {η t : ℝ} (hh1 : v.h ≤ 1 / 100) | ||
| 298 | 298 | rw [← angularSource_hold v.core v.h η ht, angularSource, |
| 299 | 299 | slope_hold v.core.dropLength_pos.le hy, dropCoefficient_hold v.core ht] |
| 300 | 300 | simp only [mul_zero, add_zero, neg_neg] |
| 301 | - nlinarith [mul_le_mul_of_nonneg_left hW v.core.lam_pos.le] | |
| 301 | + linarith [mul_le_mul_of_nonneg_left hW v.core.lam_pos.le] | |
| 302 | 302 | |
| 303 | 303 | theorem holdFormula_eq_linearLag (c : Parameters) (h η t : ℝ) : |
| 304 | 304 | holdFormula c h η t = |
| 305 | 305 | linearLag (fun _ => 1 - c.lam) (holdSource c h η) (angularLag c h η c.holdStart) t := by |
| 306 | 306 | apply linearLag_eq_of_solution continuous_const |
| 307 | 307 | (continuous_const.sub (continuous_const.mul (Real.continuous_exp.comp continuous_neg))) |
| 308 | - · simp only [holdFormula, mul_zero, neg_zero, Real.exp_zero, mul_one] | |
| 308 | + · simp only [holdFormula, mul_zero, neg_zero, Real.exp_zero] | |
| 309 | 309 | ring |
| 310 | 310 | · intro u _ |
| 311 | 311 | exact holdFormula_hasDerivAt c h η u |
| @@ -325,7 +325,7 @@ theorem angularLag_hold_lower (v : TailData) {η t : ℝ} (hh1 : v.h ≤ 1 / 100 | ||
| 325 | 325 | angularLag v.core v.h η v.core.holdStart := by |
| 326 | 326 | have hs := mul_le_mul_of_nonneg_right hb.1 (sq_nonneg η) |
| 327 | 327 | have hl := mul_le_mul_of_nonneg_left v.core.lam_lt.le hc.le |
| 328 | - nlinarith | |
| 328 | + linarith | |
| 329 | 329 | have hsource : ∀ u ∈ Icc (0 : ℝ) t, |
| 330 | 330 | (1 - v.core.lam) * (holdFloor v.core.m * (η ^ 2 + v.core.lam)) ≤ holdSource v.core v.h η u := by |
| 331 | 331 | intro u hu |
| @@ -334,16 +334,16 @@ theorem angularLag_hold_lower (v : TailData) {η t : ℝ} (hh1 : v.h ≤ 1 / 100 | ||
| 334 | 334 | v.core.lam / 4 + (49 / 100) * η ^ 2 := by |
| 335 | 335 | have hbη := mul_le_mul_of_nonneg_right hb.2.1 (sq_nonneg η) |
| 336 | 336 | have hbLam := mul_le_mul_of_nonneg_right hb.2.1 v.core.lam_pos.le |
| 337 | - nlinarith [sq_nonneg η, v.core.lam_pos] | |
| 337 | + linarith [sq_nonneg η, v.core.lam_pos] | |
| 338 | 338 | have hn : 0 ≤ holdFloor v.core.m * (η ^ 2 + v.core.lam) := |
| 339 | 339 | mul_nonneg hc.le (add_nonneg (sq_nonneg η) v.core.lam_pos.le) |
| 340 | - nlinarith [mul_nonneg v.core.lam_pos.le hn] | |
| 340 | + linarith [mul_nonneg v.core.lam_pos.le hn] | |
| 341 | 341 | have hlo := linearLag_lower_barrier continuous_const |
| 342 | 342 | (continuous_const.sub (continuous_const.mul (Real.continuous_exp.comp continuous_neg))) |
| 343 | 343 | ht hinit hsource |
| 344 | 344 | rw [angularLag_hold_formula v.core v.h η ht, holdFormula_eq_linearLag] |
| 345 | 345 | have hp : -OutgoingSchedule.primitive (fun _ : ℝ => 1 - v.core.lam) t = -(1 - v.core.lam) * t := by |
| 346 | - simp only [OutgoingSchedule.primitive, intervalIntegral.integral_const, sub_zero, smul_eq_mul] | |
| 346 | + simp only [OutgoingSchedule.primitive, intervalIntegral.integral_const, sub_zero] | |
| 347 | 347 | ring |
| 348 | 348 | rw [hp] at hlo |
| 349 | 349 | convert! hlo using 1 |
| @@ -393,7 +393,7 @@ theorem axialLag_hold_history (v : TailData) (η : ℝ) {t : ℝ} (ht : 0 ≤ t) | ||
| 393 | 393 | have hu0 := (uIcc_of_le ht ▸ hu).1 |
| 394 | 394 | have hd := (axialLag_hasDerivAt v (v.core.holdStart + u) η).comp u |
| 395 | 395 | ((hasDerivAt_id u).const_add v.core.holdStart) |
| 396 | - simp only [Function.comp_def, mul_one, one_mul, axialSource, | |
| 396 | + simp only [mul_one, one_mul, axialSource, | |
| 397 | 397 | geometricAxialSource_hold v.core v.h η hu0, zero_add] at hd ⊢ |
| 398 | 398 | exact hd |
| 399 | 399 | |
| @@ -501,12 +501,12 @@ theorem weighted_pressure_source_bound (v : TailData) {η t : ℝ} | ||
| 501 | 501 | Real.exp (-2 * v.core.lam * t)) := by rw [weighted_angular_square_hold v.core η ht] |
| 502 | 502 | _ ≤ _ := by |
| 503 | 503 | have he : Real.exp (-2 * v.core.lam * t) ≤ 1 := |
| 504 | - Real.exp_le_one_iff.mpr (by nlinarith [mul_nonneg v.core.lam_pos.le ht]) | |
| 504 | + Real.exp_le_one_iff.mpr (by linarith [mul_nonneg v.core.lam_pos.le ht]) | |
| 505 | 505 | have hp := mul_le_mul_of_nonneg_left he |
| 506 | 506 | (show 0 ≤ pressureSourceBound * |η| * angular v.core.P v.core.dropLength v.core.lam (v.core.holdStart, η) ^ 2 by |
| 507 | 507 | have := pressureSourceBound_pos |
| 508 | 508 | positivity) |
| 509 | - nlinarith | |
| 509 | + linarith | |
| 510 | 510 | |
| 511 | 511 | theorem axialLag_hold_bound (v : TailData) {η t : ℝ} |
| 512 | 512 | (hh1 : v.h ≤ 1 / 100) (hη : |η| ≤ 1) (ht : 0 ≤ t) (htw : t ≤ v.core.wait) : |
| @@ -537,7 +537,7 @@ theorem axialLag_hold_ratio_bound (v : TailData) {η t : ℝ} | ||
| 537 | 537 | have hsecond : pressureSourceBound * E₀ ^ 2 ≤ |
| 538 | 538 | (pressureSourceBound * initialEnergyUpper v.core.P v.core.m) * E₀ := by |
| 539 | 539 | have hp := mul_le_mul_of_nonneg_right hE.2 (mul_pos hC hE₀).le |
| 540 | - nlinarith | |
| 540 | + linarith | |
| 541 | 541 | have hinside : initialAxialBound v.core.P v.core.m + t * (pressureSourceBound * E₀ ^ 2) ≤ |
| 542 | 542 | axialWaitConstant v.core.P v.core.m * (1 + t) * E₀ := by |
| 543 | 543 | have hm := mul_le_mul_of_nonneg_left hsecond ht |
+3 −3 NavierStokes/SquaredPartition.lean View file
| @@ -58,7 +58,7 @@ theorem translatedBump_support (k : ℤ) : | ||
| 58 | 58 | ext x |
| 59 | 59 | change bump (x - k) ≠ 0 ↔ _ |
| 60 | 60 | rw [← mem_support, bump.support_eq] |
| 61 | - simp only [Metric.mem_ball, Real.dist_eq, sub_zero, bump, abs_lt, mem_Ioo] | |
| 61 | + simp only [Metric.mem_ball, Real.dist_eq, sub_zero, bump, abs_lt] | |
| 62 | 62 | constructor <;> intro h <;> constructor <;> linarith [h.1, h.2] |
| 63 | 63 | |
| 64 | 64 | theorem integer_intervals_locallyFinite : |
| @@ -177,7 +177,7 @@ theorem gridMask_support (δ : ℝ) (hδ : 0 < δ) (k : ℤ) : | ||
| 177 | 177 | rw [lineMask_support] |
| 178 | 178 | simp only [mem_Ioo] |
| 179 | 179 | rw [lt_div_iff₀ hδ, div_lt_iff₀ hδ] |
| 180 | - constructor <;> intro h <;> constructor <;> nlinarith [h.1, h.2] | |
| 180 | + constructor <;> intro h <;> constructor <;> linarith [h.1, h.2] | |
| 181 | 181 | |
| 182 | 182 | theorem gridMask_tsupport (δ : ℝ) (hδ : 0 < δ) (k : ℤ) : |
| 183 | 183 | tsupport (gridMask δ k) = Icc (δ * k - δ) (δ * k + δ) := by |
| @@ -589,7 +589,7 @@ theorem physicalSlowMask_tsupport_smallBox (D : ℝ) {n : ℕ} (hn : 1 ≤ n) | ||
| 589 | 589 | change x j ∈ Icc (SlotColoring.width D j n * k j - SlotColoring.width D j n) |
| 590 | 590 | (SlotColoring.width D j n * k j + SlotColoring.width D j n) |
| 591 | 591 | rw [hw] |
| 592 | - constructor <;> nlinarith | |
| 592 | + constructor <;> linarith | |
| 593 | 593 | · exact (isCompact_univ_pi fun _ => isCompact_Icc).isClosed |
| 594 | 594 | |
| 595 | 595 | /-- The constructed masks fit inside the exact enlarged boxes already colored |
+10 −10 NavierStokes/TransitionRamp.lean View file
| @@ -492,7 +492,7 @@ theorem damped_integral_bound {F : ℝ → ℝ} (hF : Continuous F) {T κ y M : | ||
| 492 | 492 | by_cases hyt : y ≤ T |
| 493 | 493 | · have hi : |∫ t in (0 : ℝ)..y, F t| ≤ M * y := by |
| 494 | 494 | simpa only [sub_zero] using integral_norm_bound hy hbM |
| 495 | - exact hi.trans (mul_le_mul_of_nonneg_left (by nlinarith [mul_nonneg hκ.1 hy]) hM) | |
| 495 | + exact hi.trans (mul_le_mul_of_nonneg_left (by linarith [mul_nonneg hκ.1 hy]) hM) | |
| 496 | 496 | · have hTy : T ≤ y := (lt_of_not_ge hyt).le |
| 497 | 497 | have hsplit := intervalIntegral.integral_add_adjacent_intervals (μ := volume) |
| 498 | 498 | (hF.intervalIntegrable 0 T) (hF.intervalIntegrable T y) |
| @@ -507,7 +507,7 @@ theorem damped_integral_bound {F : ℝ → ℝ} (hF : Continuous F) {T κ y M : | ||
| 507 | 507 | calc |
| 508 | 508 | _ ≤ |∫ t in (0 : ℝ)..T, F t| + |∫ t in T..y, F t| := abs_add_le _ _ |
| 509 | 509 | _ ≤ M * T + (κ * M) * (y - T) := add_le_add hfirst hlast |
| 510 | - _ ≤ M * (T + κ * y) := by nlinarith [mul_nonneg (mul_nonneg hκ.1 hM) hT.le] | |
| 510 | + _ ≤ M * (T + κ * y) := by linarith [mul_nonneg (mul_nonneg hκ.1 hM) hT.le] | |
| 511 | 511 | |
| 512 | 512 | theorem jet_slice_continuous {J : Set ℝ} (hJ : IsOpen J) {F : Field} |
| 513 | 513 | (hF : ContDiffOn ℝ ∞ F (logDomain J hJ).carrier) (n : ℕ) {η : ℝ} (hη : η ∈ J) : |
| @@ -552,7 +552,7 @@ theorem controlled_product_bound {a d z M : ℝ} (ha : a ∈ Icc (0 : ℝ) 1) | ||
| 552 | 552 | rw [abs_of_pos (by norm_num : (0 : ℝ) < 2)] |
| 553 | 553 | have hza : a * |z| ≤ M := |
| 554 | 554 | (mul_le_mul_of_nonneg_left hz ha.1).trans (mul_le_of_le_one_left hM ha.2) |
| 555 | - nlinarith [mul_le_mul_of_nonneg_left hza hd, mul_nonneg hd hM] | |
| 555 | + linarith [mul_le_mul_of_nonneg_left hza hd, mul_nonneg hd hM] | |
| 556 | 556 | |
| 557 | 557 | theorem axialField_jet_error_bound {J : Set ℝ} (hJ : IsOpen J) {stock : Field} |
| 558 | 558 | (hs : ContDiffOn ℝ ∞ stock (logDomain J hJ).carrier) (initial : ℝ → ℝ) |
| @@ -611,7 +611,7 @@ theorem logField_value_error_bound {J : Set ℝ} (hJ : IsOpen J) {stock : Field} | ||
| 611 | 611 | dsimp [B] |
| 612 | 612 | rw [abs_mul, abs_of_nonneg (step_mem (b + w₁) w₂ t).1, |
| 613 | 613 | abs_of_pos (by norm_num : (0 : ℝ) < 2 / 5)] |
| 614 | - nlinarith [(step_mem (b + w₁) w₂ t).2] | |
| 614 | + linarith [(step_mem (b + w₁) w₂ t).2] | |
| 615 | 615 | · intro t ht |
| 616 | 616 | dsimp [B] |
| 617 | 617 | rw [step_zero hw₂ (show t ≤ b + w₁ by linarith [ht.2]), mul_zero] |
| @@ -691,7 +691,7 @@ theorem L_pos_parameterInterval {h j η : ℝ} (hs : NaturalAxisData.SmallParame | ||
| 691 | 691 | (show 0 ≤ 11 / 10 - η by linarith [hη'.2])] |
| 692 | 692 | have hm := mul_le_mul hs.h_le hsquare (sq_nonneg η) (by norm_num : (0 : ℝ) ≤ 1 / 1000) |
| 693 | 693 | unfold NaturalAxisData.L |
| 694 | - nlinarith | |
| 694 | + linarith | |
| 695 | 695 | |
| 696 | 696 | /-- No stock or differential equation is postulated in this constructor: |
| 697 | 697 | the underlying profiles and all five histories are the completed REF path. -/ |
| @@ -1256,7 +1256,7 @@ theorem exists_small_log_control (hJ : IsOpen J) {K : Set ℝ} (hK : IsCompact K | ||
| 1256 | 1256 | linarith [hw₁.2, hw₂.2] |
| 1257 | 1257 | have hcontrol (y : ℝ) (hy : y ∈ Icc (0 : ℝ) R.finalTime) : M * (T + κ * y) < ε / 4 := by |
| 1258 | 1258 | have hky : κ * y ≤ s * R.finalTime := mul_le_mul hκs.le hy.2 hy.1 hs.le |
| 1259 | - have hsum : T + κ * y < s * (1 + R.finalTime) := by nlinarith | |
| 1259 | + have hsum : T + κ * y < s * (1 + R.finalTime) := by linarith | |
| 1260 | 1260 | have hm := mul_lt_mul_of_pos_left hsum hM |
| 1261 | 1261 | have he : M * (s * (1 + R.finalTime)) = ε / 4 := by |
| 1262 | 1262 | dsimp [s] |
| @@ -1278,7 +1278,7 @@ theorem exists_small_log_control (hJ : IsOpen J) {K : Set ℝ} (hK : IsCompact K | ||
| 1278 | 1278 | have hv := logField_value_error_bound hJ (R.angularStock_smooth hJ) R.initialLog |
| 1279 | 1279 | hT.1 hκ1 hb hw₁.1.le hw₂.1 hy.1 hy.2 (hKJ hη) hM.le |
| 1280 | 1280 | (fun t ht => (ha 0 (Nat.zero_le N) t ⟨ht.1, ht.2.trans hyf.2⟩ η hη).trans haM) |
| 1281 | - exact hv.trans_lt (by nlinarith [hcontrol y hyf]) | |
| 1281 | + exact hv.trans_lt (by linarith [hcontrol y hyf]) | |
| 1282 | 1282 | |
| 1283 | 1283 | /-- The same estimates stated directly for the actual physical fields. -/ |
| 1284 | 1284 | structure SmallPhysicalControl (K : Set ℝ) (N : ℕ) (ε T κ w₁ w₂ : ℝ) : Prop where |
| @@ -1585,7 +1585,7 @@ theorem exists_normalized_natural_jets (hΛ : 0 < Λ) (hσ : 0 < σ) | ||
| 1585 | 1585 | obtain ⟨A, hA, ha⟩ := compact_scalar_jets parameterInterval_open isCompact_Icc |
| 1586 | 1586 | original_interval_interior (phase_smooth d) N |
| 1587 | 1587 | obtain ⟨L, hL, hl⟩ := exists_uniform_logPhi_jets d hσ hscale N |
| 1588 | - refine ⟨1 + Λ * A + L, by nlinarith [mul_nonneg hΛ.le hA], ?_⟩ | |
| 1588 | + refine ⟨1 + Λ * A + L, by linarith [mul_nonneg hΛ.le hA], ?_⟩ | |
| 1589 | 1589 | intro C E Y hY n hn η hη |
| 1590 | 1590 | have hηJ := original_interval_interior hη |
| 1591 | 1591 | have hphase := ((phase_smooth d).contDiffAt (parameterInterval_open.mem_nhds hηJ)).of_le (nat_le_infty n) |
| @@ -1793,7 +1793,7 @@ theorem endpointLog_jets_of_control (hJ : IsOpen J) {K : Set ℝ} (hKJ : K ⊆ J | ||
| 1793 | 1793 | ring |
| 1794 | 1794 | rw [heq, iteratedDeriv_const_add hnpos] |
| 1795 | 1795 | exact ((hbound R.finalTime (ha0.trans ha) η hη).2 n hn hnpos).trans |
| 1796 | - (by nlinarith [abs_nonneg (Real.log 220 / 2)]) | |
| 1796 | + (by linarith [abs_nonneg (Real.log 220 / 2)]) | |
| 1797 | 1797 | |
| 1798 | 1798 | theorem SmallLogControl.mono_tolerance {K : Set ℝ} {N : ℕ} {ε ε' T κ w₁ w₂ : ℝ} |
| 1799 | 1799 | (hc : R.SmallLogControl K N ε T κ w₁ w₂) (hε : ε ≤ ε') : |
| @@ -2056,7 +2056,7 @@ theorem ordered_seed_bounds (hΛ : 0 < Λ) (hsmall : NaturalAxisData.SmallParame | ||
| 2056 | 2056 | have hBJ : 1 ≤ BJ := by |
| 2057 | 2057 | dsimp [BJ] |
| 2058 | 2058 | have hg : 0 < Real.log (11 / 10 : ℝ) := Real.log_pos (by norm_num) |
| 2059 | - nlinarith [abs_nonneg (Real.log 220 / 2)] | |
| 2059 | + linarith [abs_nonneg (Real.log 220 / 2)] | |
| 2060 | 2060 | refine ⟨U + 1, by linarith, K, hK, BJ, hBJ, ?_⟩ |
| 2061 | 2061 | intro C hC E δ hδ hδT R T κ w₁ w₂ hb hw₁ hw₂ hc |
| 2062 | 2062 | let A := Input.ofNatural hΛ E.family |
+0 −20 NavierStokes/WeightedClasses.lean View file
| @@ -359,26 +359,6 @@ theorem bandBound_rpow (s : StripData D) (β : ℝ) : | ||
| 359 | 359 | intro n |
| 360 | 360 | simp [Real.norm_eq_abs, abs_of_pos (Real.rpow_pos_of_pos (s.epsilon_pos n) β)] |
| 361 | 361 | |
| 362 | -/-- Wave products have the mean weight. This uses the actual Leibniz estimate | |
| 363 | -on coefficients, followed by `(sqrt ζ * P)^2 ≤ ζ`; no derivative identity for | |
| 364 | -the envelope `P` is postulated. -/ | |
| 365 | -theorem WaveClass.bilinear_mean {s : StripData D} {P : ℕ → D → ℝ} | |
| 366 | - {α β : ℝ} {f : ℕ → D → E} {g : ℕ → D → F} | |
| 367 | - (hf : WaveClass s P α f) (hg : WaveClass s P β g) | |
| 368 | - (hP0 : ∀ n x, x ∈ s.domain → 0 ≤ P n x) | |
| 369 | - (hP1 : ∀ n x, x ∈ s.domain → P n x ≤ 1) | |
| 370 | - (L : E →L[ℝ] F →L[ℝ] G) : | |
| 371 | - MeanClass s (α + β) (fun n x => L (f n x) (g n x)) := by | |
| 372 | - apply (MemClass.bilinear hf hg L).mono_weight (fun _ x hx => s.zeta_nonneg x hx) | |
| 373 | - intro n x hx | |
| 374 | - have hP2 : P n x * P n x ≤ 1 := by | |
| 375 | - nlinarith [hP0 n x hx, hP1 n x hx] | |
| 376 | - calc | |
| 377 | - _ = (Real.sqrt (s.zeta x)) ^ 2 * (P n x * P n x) := by ring | |
| 378 | - _ = s.zeta x * (P n x * P n x) := by rw [Real.sq_sqrt (s.zeta_nonneg x hx)] | |
| 379 | - _ ≤ s.zeta x * 1 := mul_le_mul_of_nonneg_left hP2 (s.zeta_nonneg x hx) | |
| 380 | - _ = _ := mul_one _ | |
| 381 | - | |
| 382 | 362 | /-- A normalized bounded radial weight makes the mean class an algebra. -/ |
| 383 | 363 | theorem MeanClass.bilinear {s : StripData D} {α β : ℝ} |
| 384 | 364 | {f : ℕ → D → E} {g : ℕ → D → F} |
+28 −13 README.md View file
| @@ -12,7 +12,7 @@ been settled" and that its process "is deliberately unhurried"; nothing since, a | ||
| 12 | 12 | This project is a community effort to make those proofs smaller, faster to build and readable, and to tie them to the |
| 13 | 13 | papers. |
| 14 | 14 | |
| 15 | -## Where it stands (as of 2026-12-02) | |
| 15 | +## Where it stands (as of 2026-12-05) | |
| 16 | 16 | |
| 17 | 17 | | Step | State | Who, when, where it is written | |
| 18 | 18 | |---|---|---| |
| @@ -24,6 +24,20 @@ papers. | ||
| 24 | 24 | | Published | No | The papers are on OpenAI's server only: not on arXiv, no journal. | |
| 25 | 25 | | Recognised by Clay | No ruling | Clay, 2026-09-11: "we contemplate the announcement that the Navier-Stokes problem has apparently been settled" and "The process is deliberately unhurried, but we will provide updates" ([its notice](https://www.claymath.org/news/navier-stokes-announcement/)). Nothing since; the problem is listed under "Active problems" (read 2026-12-02). Its rules ask for publication, two years, and its own judgement that the official description is answered. | |
| 26 | 26 | |
| 27 | +The proof's size, measured with `tools/measure.py` at two commits: | |
| 28 | + | |
| 29 | +| Measure | First commit `c7e5ae8` (2026-12-02) | `f0bbc9f` (2026-12-05) | | |
| 30 | +|---|---:|---:| | |
| 31 | +| Lean files | 2,646 | 2,588 | | |
| 32 | +| Lines | 634,024 | 499,461 | | |
| 33 | +| Declarations | 50,533 | 39,385 | | |
| 34 | +| Docstrings | 12,626 | 9,510 | | |
| 35 | +| Files over 1,000 lines | 118 | 67 | | |
| 36 | +| Longest file | 20,755 lines (`Euler/EulerProof.lean`) | 16,605 lines (`Euler/EulerProof.lean`) | | |
| 37 | + | |
| 38 | +The `build` check's time is on its jobs: `f0bbc9f`'s `build` (job 5184) ran from 2026-12-05 02:21 to 03:20 UTC, | |
| 39 | +59 minutes 33 seconds. | |
| 40 | + | |
| 27 | 41 | What to keep in mind when you read that table: |
| 28 | 42 | |
| 29 | 43 | - **The force is the point.** Fefferman's [official description](https://www.claymath.org/wp-content/uploads/2022/06/navierstokes.pdf) |
| @@ -67,11 +81,11 @@ Thanks to OpenAI for publishing the proofs and the papers, and to the Formal Con | ||
| 67 | 81 | |
| 68 | 82 | To make the proof: |
| 69 | 83 | |
| 70 | -- **readable**: every file tied to the section and the numbered result of the paper it formalises (29 of 2,646 files | |
| 71 | - are today); the two giant files split along the paper (`Euler/EulerProof.lean`, 20,755 lines; | |
| 72 | - `NavierStokes/CorrectionStep.lean`, 9,849); the proof's own words explained; no linter warnings (P-1 to P-7); | |
| 84 | +- **readable**: every file tied to the section and the numbered result of the paper it formalises (a start; the rest | |
| 85 | + is P-4); the two giant files split along the paper (`Euler/EulerProof.lean`, 16,605 lines at `f0bbc9f`; | |
| 86 | + `NavierStokes/CorrectionStep.lean`, 5,069); the proof's own words explained; no linter warnings (P-1 to P-7); | |
| 73 | 87 | - **accessible**: imports trimmed, one proof where the two halves each carry their own, nothing kept that no theorem |
| 74 | - uses, a folder plan for 2,646 files that sit in two flat folders (S-1 to S-5, P-7); | |
| 88 | + uses, a folder plan for the 2,588 files at `f0bbc9f` that sit in two flat folders (S-1 to S-5, P-7); | |
| 75 | 89 | - **integrated with the community**: Mathlib's lemmas in place of ours, and the general analysis here (heat kernel, |
| 76 | 90 | Sobolev spaces, Fourier weights) stated so that Mathlib could take it (M-1, M-2); |
| 77 | 91 | - **checked by reading**: the formal statements against Fefferman's text, the paper's theorems against the Lean that |
| @@ -168,17 +182,18 @@ Expect an hour or more on a laptop. Changing one file rebuilds it and everything | ||
| 168 | 182 | |
| 169 | 183 | ## Layout |
| 170 | 184 | |
| 171 | -2,646 Lean files, about 634,000 lines; about 37,300 theorems and lemmas and 12,500 docstrings. | |
| 185 | +At `f0bbc9f` (2026-12-05): 2,588 Lean files, 499,461 lines, 39,385 declarations and 9,510 docstrings. The first | |
| 186 | +commit `c7e5ae8` (2026-12-02) had 2,646 files, 634,024 lines, 50,533 declarations and 12,626 docstrings. | |
| 172 | 187 | |
| 173 | -- `NavierStokes/` (813 files, 423,000 lines): the Navier–Stokes blowup. 704 files sit directly in the folder, in | |
| 174 | - families by the first word of their names (`Actual*` 93 files, `Local*` 22, `Axis*` 21, `Sharp*` 20 …); | |
| 175 | - `NavierStokes/R3/` (109 files) is the whole-space case and holds the general analysis: the heat kernel, the Sobolev | |
| 188 | +- `NavierStokes/` (754 files, 312,108 lines): the Navier–Stokes blowup. 646 files sit directly in the folder, in | |
| 189 | + families by the first word of their names (`Actual*` 93 files, `Local*` 32, `Axis*` 24, `Sharp*` 21 …); | |
| 190 | + `NavierStokes/R3/` (108 files) is the whole-space case and holds the general analysis: the heat kernel, the Sobolev | |
| 176 | 191 | space H³, Fourier weights. `ComparatorSolution.lean` is the proof's face to Comparator; `PaperResults.lean` |
| 177 | - collects the paper's results. The largest files are `CorrectionStep.lean` (9,849 lines) and | |
| 178 | - `CorrectionInitialization.lean` (5,562). | |
| 179 | -- `Euler/` (1,829 files in one folder, 210,000 lines): the Euler blowup, in families too (`Packet*` 527 files, | |
| 192 | + collects the paper's results. The largest files are `CorrectionStep.lean` (5,069 lines) and | |
| 193 | + `CorrectionInitialization.lean` (3,692). | |
| 194 | +- `Euler/` (1,829 files in one folder, 186,850 lines): the Euler blowup, in families too (`Packet*` 527 files, | |
| 180 | 195 | `Mean*` 149, `Transverse*` 120, `Cylinder*` 112 …). `Solution.lean` faces Comparator, `EulerSingularity.lean` is |
| 181 | - the theorem, and `EulerProof.lean` (20,755 lines, 983 theorems and lemmas) holds most of the argument. | |
| 196 | + the theorem, and `EulerProof.lean` (16,605 lines, 741 theorems and lemmas) holds most of the argument. | |
| 182 | 197 | - `ComparatorChallenges/`: the fixed statements and Comparator's configuration. |
| 183 | 198 | - `docs/`: what this project writes about the proof: `guide/` (paper to Lean), `statements/`, `exposition/`, |
| 184 | 199 | `mathlib-map/`. |
+24 −10 README.zh.md View file
| @@ -9,7 +9,7 @@ Lean 内核和 nanoda 复跑过,Sébastien Gouëzel 2026-09-11 读过陈述, | ||
| 9 | 9 | |
| 10 | 10 | 本项目把这份证明改得更小、编译更快、更好读,并把它和论文一处一处对上。 |
| 11 | 11 | |
| 12 | -## 现状(截至 2026-12-02) | |
| 12 | +## 现状(截至 2026-12-05) | |
| 13 | 13 | |
| 14 | 14 | | 步骤 | 状态 | 谁、何时、写在哪 | |
| 15 | 15 | |---|---|---| |
| @@ -21,6 +21,19 @@ Lean 内核和 nanoda 复跑过,Sébastien Gouëzel 2026-09-11 读过陈述, | ||
| 21 | 21 | | 发表 | 没有 | 论文只在 OpenAI 的服务器上:不在 arXiv,没有投期刊。 | |
| 22 | 22 | | 克雷认定 | 没有裁定 | 克雷 2026-09-11:“we contemplate the announcement that the Navier-Stokes problem has apparently been settled”,以及“The process is deliberately unhurried, but we will provide updates”([公告](https://www.claymath.org/news/navier-stokes-announcement/))。此后没有新消息;这道题列在“Active problems”下(2026-12-02 读)。它的规则要求发表、两年,并由它自己判断官方表述是否已被回答。 | |
| 23 | 23 | |
| 24 | +用 `tools/measure.py` 在两个提交上量出的证明规模: | |
| 25 | + | |
| 26 | +| 项目 | 第一个提交 `c7e5ae8`(2026-12-02) | `f0bbc9f`(2026-12-05) | | |
| 27 | +|---|---:|---:| | |
| 28 | +| Lean 文件 | 2,646 | 2,588 | | |
| 29 | +| 行数 | 634,024 | 499,461 | | |
| 30 | +| 声明 | 50,533 | 39,385 | | |
| 31 | +| 文档字符串 | 12,626 | 9,510 | | |
| 32 | +| 超过 1,000 行的文件 | 118 | 67 | | |
| 33 | +| 最长的文件 | 20,755 行(`Euler/EulerProof.lean`) | 16,605 行(`Euler/EulerProof.lean`) | | |
| 34 | + | |
| 35 | +`build` 检查的时间在它的作业上:`f0bbc9f` 的 `build`(job 5184)于 2026-12-05 02:21 UTC 开始,03:20 UTC 结束,用时 59 分 33 秒。 | |
| 36 | + | |
| 24 | 37 | 读这张表时要记住: |
| 25 | 38 | |
| 26 | 39 | - **关键在外力。** Fefferman 的[官方表述](https://www.claymath.org/wp-content/uploads/2022/06/navierstokes.pdf)要求证明四个 |
| @@ -60,10 +73,10 @@ Ilin 的 PR 405 和 570,2026 年 9 月、10 月),模块更少、import 更 | ||
| 60 | 73 | |
| 61 | 74 | 把证明改成: |
| 62 | 75 | |
| 63 | -- **读得懂**:每个文件都标明它形式化的是论文的哪一节、哪条编号结果(现在 2,646 个文件里只有 29 个标了);两个巨型文件 | |
| 64 | - 按论文拆开(`Euler/EulerProof.lean` 20,755 行,`NavierStokes/CorrectionStep.lean` 9,849 行);把证明自己的用词解释清楚; | |
| 76 | +- **读得懂**:每个文件都标明它形式化的是论文的哪一节、哪条编号结果(才刚开始,其余是 P-4);两个巨型文件 | |
| 77 | + 按论文拆开(`Euler/EulerProof.lean` 16,605 行,`NavierStokes/CorrectionStep.lean` 5,069 行,按 `f0bbc9f`);把证明自己的用词解释清楚; | |
| 65 | 78 | 没有 linter 警告(P-1 到 P-7); |
| 66 | -- **用得起**:精简 import,两半各证一遍的只证一遍,没有定理用到的东西不留,给平铺在两个文件夹里的 2,646 个文件一个 | |
| 79 | +- **用得起**:精简 import,两半各证一遍的只证一遍,没有定理用到的东西不留,给平铺在两个文件夹里的 2,588 个文件一个 | |
| 67 | 80 | 目录方案(S-1 到 S-5、P-7); |
| 68 | 81 | - **和社区接上**:Mathlib 已有的引理用它的;这里的一般性分析(热核、Sobolev 空间、Fourier 权)写成 Mathlib 能收的样子 |
| 69 | 82 | (M-1、M-2); |
| @@ -149,15 +162,16 @@ Lean 镜像对起点提交自己做的 `lake build` 用了 18 分 30 秒(11,41 | ||
| 149 | 162 | |
| 150 | 163 | ## 目录 |
| 151 | 164 | |
| 152 | -2,646 个 Lean 文件,约 63.4 万行;约 37,300 条定理和引理,12,500 条文档字符串。 | |
| 165 | +在 `f0bbc9f`(2026-12-05):2,588 个 Lean 文件,499,461 行,39,385 条声明,9,510 条文档字符串。第一个提交 | |
| 166 | +`c7e5ae8`(2026-12-02)有 2,646 个文件、634,024 行、50,533 条声明、12,626 条文档字符串。 | |
| 153 | 167 | |
| 154 | -- `NavierStokes/`(813 个文件,42.3 万行):纳维–斯托克斯的爆破。704 个文件直接放在这个文件夹里,按文件名的第一个词成族 | |
| 155 | - (`Actual*` 93 个、`Local*` 22、`Axis*` 21、`Sharp*` 20……);`NavierStokes/R3/`(109 个文件)是全空间情形,放着一般性的 | |
| 168 | +- `NavierStokes/`(754 个文件,312,108 行):纳维–斯托克斯的爆破。646 个文件直接放在这个文件夹里,按文件名的第一个词成族 | |
| 169 | + (`Actual*` 93 个、`Local*` 32、`Axis*` 24、`Sharp*` 21……);`NavierStokes/R3/`(108 个文件)是全空间情形,放着一般性的 | |
| 156 | 170 | 分析:热核、Sobolev 空间 H³、Fourier 权。`ComparatorSolution.lean` 是证明面向 Comparator 的那一面;`PaperResults.lean` |
| 157 | - 汇集论文的结果。最大的文件是 `CorrectionStep.lean`(9,849 行)和 `CorrectionInitialization.lean`(5,562 行)。 | |
| 158 | -- `Euler/`(1,829 个文件全在一个文件夹里,21 万行):欧拉方程的爆破,同样成族(`Packet*` 527 个、`Mean*` 149、 | |
| 171 | + 汇集论文的结果。最大的文件是 `CorrectionStep.lean`(5,069 行)和 `CorrectionInitialization.lean`(3,692 行)。 | |
| 172 | +- `Euler/`(1,829 个文件全在一个文件夹里,186,850 行):欧拉方程的爆破,同样成族(`Packet*` 527 个、`Mean*` 149、 | |
| 159 | 173 | `Transverse*` 120、`Cylinder*` 112……)。`Solution.lean` 面向 Comparator,`EulerSingularity.lean` 是定理, |
| 160 | - `EulerProof.lean`(20,755 行,983 条定理和引理)装着大部分论证。 | |
| 174 | + `EulerProof.lean`(16,605 行,741 条定理和引理)装着大部分论证。 | |
| 161 | 175 | - `ComparatorChallenges/`:固定的陈述和 Comparator 的配置。 |
| 162 | 176 | - `docs/`:本项目关于这份证明写下的东西:`guide/`(从论文到 Lean)、`statements/`、`exposition/`、`mathlib-map/`。 |
| 163 | 177 | - `checks/`:本项目的 CI;`docker/`:`build` 所用的 Lean 镜像。`KNOWN.md`:已知的事,带日期。 |
+1 −1 docs/build-profile.md View file
| @@ -1,6 +1,6 @@ | ||
| 1 | 1 | # Build profile |
| 2 | 2 | |
| 3 | -Where the cost of elaborating the tree goes, at main `57f8d38`. 2,587 Lean files were counted; together they take 56.82 T instructions (T is 10¹², G is 10⁹). | |
| 3 | +Where the cost of elaborating the tree goes, at main `57f8d38`. The 2,587 Lean files that the build compiles were counted (the libraries `NavierStokes`, `Euler` and `ComparatorChallenges`); together they take 56.82 T instructions (T is 10¹², G is 10⁹). The tree has one more `.lean` file at that commit, `docs/s1-dead-code/tools/Graph.lean`: it is the script that exported the declaration graph for S-1, no library's globs include it, and it is not counted. | |
| 4 | 4 | |
| 5 | 5 | ## The ten costliest files |
| 6 | 6 | |
+15 −0 routes/maintainer-statement/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 418 | |
| 3 | +status: done | |
| 4 | +--- | |
| 5 | + | |
| 6 | +# maintainer-statement | |
| 7 | + | |
| 8 | +The statement update of 2026-12-05: the README's "Layout" numbers and the new size table in "Where it stands" (and | |
| 9 | +their Chinese twins), measured with `tools/measure.py` at the first commit `c7e5ae8` and at `f0bbc9f`. No rule, no | |
| 10 | +check, no Lean file. | |
| 11 | + | |
| 12 | +## Next | |
| 13 | + | |
| 14 | +Nothing: #418 closes with this pull request. `f0bbc9f`'s `build` (job 5184) ran from 02:21 to 03:20 UTC on | |
| 15 | +2026-12-05, 59 minutes 33 seconds, and its time is in the table. | |
+27 −0 routes/s1-euler-correction-9/README.md added View file
| @@ -0,0 +1,27 @@ | ||
| 1 | +--- | |
| 2 | +issue: 10 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s1-euler-correction-9 | |
| 6 | + | |
| 7 | +One unit of S-1 (issue #10, "Delete declarations that nothing uses"), the family `Euler/Correction*`: | |
| 8 | +2 declarations, 31 lines, in `Euler/CorrectionParity.lean`. | |
| 9 | + | |
| 10 | +- `EulerCorrectionParity.pressure_oddReflection` | |
| 11 | +- `EulerCorrectionParity.correction_pressure_oddReflection` | |
| 12 | + | |
| 13 | +The diff is deletions only: no statement and no proof that stays is changed, and the file keeps its imports, | |
| 14 | +module docstring and namespace. The unit comes from Treant's run of 2026-12-03 (TitiSkywalker/NavierStokesAndEuler, | |
| 15 | +upstream `f9e8bc5`) and was cut again on this project's `main` at `601f584`, under the rule that the paper's | |
| 16 | +results stay. | |
| 17 | + | |
| 18 | +What I checked against the tree left by the patch: `git grep -n -w` finds neither short name anywhere in | |
| 19 | +`*.lean`. The only user of `correction_pressure_oddReflection` was the wrapper `inviscid_correction_pressure_odd` | |
| 20 | +in `Euler/InviscidCorrectionParity.lean`, which went in wave 8 (`s1-euler-inviscid-8`, now on `main`). Neither | |
| 21 | +deleted docstring names the paper — no lemma, theorem, proposition, corollary, section or equation number — and | |
| 22 | +neither declaration is in `docs/s1-dead-code/kept.md`. | |
| 23 | + | |
| 24 | +## Next | |
| 25 | + | |
| 26 | +Push and open the pull request into `main`; the maintainer's review comes after `challenge` and `build`. The rest | |
| 27 | +of the family and the other units of #10 are separate. | |
+40 −0 routes/s1-euler-transverse-9/README.md added View file
| @@ -0,0 +1,40 @@ | ||
| 1 | +--- | |
| 2 | +issue: 10 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s1-euler-transverse-9 | |
| 6 | + | |
| 7 | +One unit of #10 (S-1, "Delete declarations that nothing uses"), family `Euler/Transverse*`: the | |
| 8 | +ninth cut of the family. It deletes 3 declarations that nothing uses, 12 lines in 2 files, and | |
| 9 | +touches nothing else: the diff is deletions only, with no `import`, `namespace` or `end` line in it. | |
| 10 | + | |
| 11 | +- `EulerTransverseFixedEvolution.displacementPath_initial` | |
| 12 | + (`Euler/TransverseFixedClassical.lean`) | |
| 13 | +- `EulerTransverseFixedEvolution.displacementPath_terminal` | |
| 14 | + (`Euler/TransverseFixedClassical.lean`) | |
| 15 | +- `EulerTransverseFixedEvolution.velocityLp_zero_trace` | |
| 16 | + (`Euler/TransverseFixedEvolution.lean`) | |
| 17 | + | |
| 18 | +How they were found. Treant (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03 at upstream | |
| 19 | +`f9e8bc5`) found them unreachable from the four Comparator theorems; `docs/s1-dead-code/README.md` is | |
| 20 | +the plan. This wave was cut again on this project's `main` (`06169a4`) under the keep rule: a | |
| 21 | +declaration stays when the paper's results reach it, when its docstring names the paper, when it is | |
| 22 | +an existence result with a docstring, when it sits in a file that states results or must match the | |
| 23 | +challenge word for word, when an earlier pull request was made to keep it, or when a declaration | |
| 24 | +that stays refers to it or names it. None of the three is in that kept set. | |
| 25 | + | |
| 26 | +Checked as a reviewer, after the deletion: | |
| 27 | + | |
| 28 | +- `displacementPath_initial`, `displacementPath_terminal` and `velocityLp_zero_trace` are named | |
| 29 | + nowhere in the tree (`git grep -n -w` over all files: no hits for any of the three); | |
| 30 | +- no deleted docstring cites the paper (the deleted blocks have no docstring at all, and no Lemma, | |
| 31 | + Theorem, Proposition, Corollary, Section or Equation number); | |
| 32 | +- `python3 checks/challenge.py .` ends with | |
| 33 | + `ok: 4 challenge files and the build configuration as approved; 2588 Lean files, 498776 lines, …`. | |
| 34 | + | |
| 35 | +What it does not show: that every remaining declaration is needed. | |
| 36 | + | |
| 37 | +## Next | |
| 38 | + | |
| 39 | +Push and open the pull request into `main`; the `build` check says whether it builds, and the | |
| 40 | +maintainer's review comes after it. The other units of #10 are separate branches. | |
+26 −0 routes/s1-ns-weighted-9/README.md added View file
| @@ -0,0 +1,26 @@ | ||
| 1 | +--- | |
| 2 | +issue: 10 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s1-ns-weighted-9 | |
| 6 | + | |
| 7 | +One unit of #10 (S-1), family `NavierStokes/Weighted*`: deletes 1 declaration | |
| 8 | +that nothing uses, 20 lines in 1 file (`NavierStokes/WeightedClasses.lean`): | |
| 9 | +`WaveClass.bilinear_mean`. The diff is deletions only, so no statement or proof | |
| 10 | +that stays changes. | |
| 11 | + | |
| 12 | +The list is Treant's (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at | |
| 13 | +upstream `f9e8bc5`), re-read from main's declaration graph under this project's | |
| 14 | +keep rule. The deleted declaration has no numbered result in its docstring | |
| 15 | +(nothing about a Lemma, Theorem, Proposition, Corollary, Section or Equation), | |
| 16 | +and nothing that stays names it: `git grep -n -w 'bilinear_mean'` finds no hit | |
| 17 | +anywhere in the tree. `MeanClass.bilinear` and `MeanClass.bilinear_wave`, which | |
| 18 | +remain, are different declarations and are untouched. | |
| 19 | + | |
| 20 | +`python3 checks/challenge.py .` ends with | |
| 21 | +`ok: 4 challenge files and the build configuration as approved; …`. | |
| 22 | + | |
| 23 | +## Next | |
| 24 | + | |
| 25 | +The maintainer's review after `challenge` and `build`; the remaining family | |
| 26 | +units follow in pull requests of their own once this wave is in. | |
+13 −0 routes/s2-build-profile-files/README.md added View file
| @@ -0,0 +1,13 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-build-profile-files | |
| 6 | + | |
| 7 | +The page `docs/build-profile.md` itself (not a Lean family): its first paragraph says 2,587 Lean files were counted at `57f8d38`, where the tree has 2,588. The maintainer's review of #488 asked the page to name the one it leaves out. It is `docs/s1-dead-code/tools/Graph.lean`, the script that exported the declaration graph for S-1; no library's globs in `lakefile.toml` include it, so the build never compiles it and the instructions-retired count does not see it. No file failed to elaborate alone. I add that sentence to the paragraph and change no number and no Lean file. | |
| 8 | + | |
| 9 | +What I checked: `git ls-tree -r --name-only 57f8d38 | grep -c '\.lean$'` is 2588; aside from `NavierStokes/`, `Euler/`, `ComparatorChallenges/` and the two root modules `NavierStokes.lean` and `Euler.lean`, the only `.lean` file is `docs/s1-dead-code/tools/Graph.lean`; and the three `globs` lines of `lakefile.toml` are `["NavierStokes", "NavierStokes.+"]`, `["Euler", "Euler.+"]` and `["ComparatorChallenges.+"]`, none of which matches `docs/`. | |
| 10 | + | |
| 11 | +## Next | |
| 12 | + | |
| 13 | +Push the branch and open the pull request into `main` with the description at `/work/unit/PR.md`; then let `challenge` and `build` answer. | |
+21 −0 routes/s2-euler-base-1/README.md added View file
| @@ -0,0 +1,21 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-base-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Base*` family: `Euler/BaseEulerGevrey.lean`, `Euler/BaseEulerGuards.lean`, | |
| 8 | +`Euler/BaseEulerParent.lean`, `Euler/BasePacketFrequencyCost.lean` and | |
| 9 | +`Euler/BasePacketSetup.lean`. Each was among the costlier files to elaborate in the tree. In | |
| 10 | +each, a closing `nlinarith` of a theorem's proof becomes `linarith`; nothing else changes — no | |
| 11 | +statement, import, docstring or `maxHeartbeats`. The edits are Treant's `speedup_trials` edits | |
| 12 | +from upstream `f9e8bc5` (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto | |
| 13 | +main `d956c7c` and counted there; a file is kept only if it is at least 0.5% cheaper. | |
| 14 | +`docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 15 | + | |
| 16 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +The pull request is open; let the `challenge` and `build` checks run, and reply to the | |
| 21 | +maintainer's review. | |
+22 −0 routes/s2-euler-bounded-1/README.md added View file
| @@ -0,0 +1,22 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-bounded-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11): two files of the `Euler/Bounded*` family made cheaper to elaborate. | |
| 8 | +`Euler/BoundedInverseGevrey.lean` and `Euler/BoundedMildContinuation.lean` each swap one | |
| 9 | +tactic inside a proof for a weaker one that suffices — `nlinarith` becomes `linarith`, and | |
| 10 | +`nlinarith only [hna]` becomes `linarith only [hna]`. No statement, import line or docstring | |
| 11 | +changes, and there is no `maxHeartbeats`. | |
| 12 | + | |
| 13 | +The edits come from Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, | |
| 14 | +the run of 2026-12-03 at upstream `f9e8bc5`), carried onto main at `d956c7c` and counted | |
| 15 | +again there. Instructions retired, one file alone on one thread with `lean -j1 -DElab.async=false` | |
| 16 | +under `perf stat -e instructions:u`: 10.93 G → 9.18 G for `BoundedInverseGevrey`, 16.53 G → 16.44 G | |
| 17 | +for `BoundedMildContinuation`; 27.46 G → 25.62 G for the two together (−6.7%). | |
| 18 | + | |
| 19 | +## Next | |
| 20 | + | |
| 21 | +Push and open the pull request into main; let `challenge` and `build` report, then reply to the | |
| 22 | +maintainer's review. | |
+15 −0 routes/s2-euler-child-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-child-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11), the family `Euler/Child*`: two files, `Euler/ChildParticleFieldBounds.lean` | |
| 8 | +and `Euler/ChildParticleSourceBound.lean`, made cheaper to elaborate. The edits are `nlinarith` | |
| 9 | +become `linarith` inside proofs only, with the same hypotheses (11 lines out, 11 in); no statement, | |
| 10 | +import line or docstring changes, and no `maxHeartbeats`. The counts and how they were taken are in | |
| 11 | +the pull request's description: −2.7% and −39.8% on the two files, −17.1% on the two together. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+19 −0 routes/s2-euler-coefficient-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-coefficient-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Coefficient*` family: `Euler/CoefficientPathBounds.lean`. | |
| 8 | +In `coefficientJet_boundLevel_le_words`, the `simp only` list in the `case n zero` branches of both | |
| 9 | +induction cases loses `smoothCoefficient`, which does not change those goals; the sibling `succ` | |
| 10 | +branch already omitted it. Nothing else changes — no statement, import, docstring or | |
| 11 | +`maxHeartbeats`. The edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 12 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 13 | +there. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 14 | + | |
| 15 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+16 −0 routes/s2-euler-div-1/README.md added View file
| @@ -0,0 +1,16 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-div-1 | |
| 6 | + | |
| 7 | +Unit `s2-euler-div-1` of S-2 (#11): the family `Euler/Div*`, one file, | |
| 8 | +`Euler/DivCurlRecovery.lean`. Two `nlinarith` calls inside proofs become `linarith` | |
| 9 | +(2 lines out, 2 in, at lines 121 and 193); no statement, import or docstring changes, | |
| 10 | +and no `maxHeartbeats`. Per unit.json, the file retires 24.91 G user-space | |
| 11 | +instructions against 25.78 G before (−3.4%), counted at main `d956c7c`, where the file | |
| 12 | +is unchanged from the current main. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+34 −0 routes/s2-euler-drift-1/README.md added View file
| @@ -0,0 +1,34 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-drift-1 | |
| 6 | + | |
| 7 | +One unit of #11 (S-2, "Find the slowest files and make one faster"), wave 1, family `Euler/Drift*`: three files of | |
| 8 | +the family made cheaper to elaborate by edits inside proofs only (4 lines out, 4 in). | |
| 9 | + | |
| 10 | +- `Euler/DriftCorrectionForcing.lean`: `nlinarith only [h, hp0, hp1e, hp1b]` → `linarith only [...]`. | |
| 11 | +- `Euler/DriftNonlinearEstimate.lean`: the same `nlinarith` → `linarith`, twice, in `drift_loss_absorption` and | |
| 12 | + `correctionForcing_polynomial`. | |
| 13 | +- `Euler/DriftMetricForcing.lean`: `mul_comm` dropped from one `simpa only [...]` list in | |
| 14 | + `correctionForcing_metric`. | |
| 15 | + | |
| 16 | +No statement, no `import` line and no docstring is touched, and there is no `maxHeartbeats`. | |
| 17 | + | |
| 18 | +The unit comes from Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03 at | |
| 19 | +upstream `f9e8bc5`), carried onto this project's main and counted there file by file. The counts in the pull | |
| 20 | +request (instructions retired in user space by `lean` on the one file alone, `lean -j1 -DElab.async=false` under | |
| 21 | +`perf stat -e instructions:u`, before and after, one machine, against main at `d956c7c`; G is 10⁹) are: | |
| 22 | + | |
| 23 | +- `Euler/DriftCorrectionForcing.lean`: 16.58 G → 14.41 G (−13.1%) | |
| 24 | +- `Euler/DriftMetricForcing.lean`: 15.51 G → 13.31 G (−14.2%) | |
| 25 | +- `Euler/DriftNonlinearEstimate.lean`: 16.71 G → 14.96 G (−10.4%) | |
| 26 | +- the three together: 48.80 G → 42.68 G (−12.5%) | |
| 27 | + | |
| 28 | +What it does not show: that the build as a whole is faster (the profile is flat), wall-clock time, or that these | |
| 29 | +proofs cannot be made cheaper still. | |
| 30 | + | |
| 31 | +## Next | |
| 32 | + | |
| 33 | +Push, open the pull request against `main`, let the `challenge` and `build` checks run, and reply to the | |
| 34 | +maintainer's review. | |
+17 −0 routes/s2-euler-field-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-field-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11): one file of the family `Euler/Field*` made cheaper to elaborate. | |
| 8 | +In `Euler/FieldTowerPhysicalL2.lean`, inside the proof of `frequencyFactor_le_linear`, | |
| 9 | +`nlinarith` becomes `linarith` (1 line out, 1 in; the goal is `1+k*‖m‖ ≤ (1+‖m‖)*k`, whose | |
| 10 | +two sides differ by `k-1`). No statement, import or docstring changes, and no | |
| 11 | +`maxHeartbeats`. Measured per file in instructions retired (unit.json's `timing`): | |
| 12 | +10.81 G before, 10.74 G after, −0.6%. The edit is Treant's `speedup_trials` run of 2026-12-03, | |
| 13 | +carried onto main at `d956c7c` and counted there. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Push, open the pull request into `main`, and let `challenge` and `build` report. | |
+17 −0 routes/s2-euler-flow-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-flow-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11), in the family `Euler/Flow*`: `Euler/FlowEscapeBound.lean` gets cheaper to elaborate by one | |
| 8 | +tactic change inside the proof of `escape_measure_le_of_action`, where `nlinarith` becomes `linarith` (1 line out, | |
| 9 | +1 in). No statement, import line or docstring changes, and there is no `maxHeartbeats`. The count is instructions | |
| 10 | +retired by `lean` on the file alone at `d956c7c`: 11.35 G before, 10.86 G after (−4.3%), measured as the pull | |
| 11 | +request's description says. The edit is Treant's (`speedup_trials`, run of 2026-12-03) carried onto this project's | |
| 12 | +main and counted there. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Push, open the pull request against `main`, and let `challenge` and `build` report; reply to the maintainer's | |
| 17 | +review. | |
+20 −0 routes/s2-euler-gaussian-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-gaussian-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Gaussian*` family: `Euler/GaussianHeatGenerator.lean`. In the proof of | |
| 8 | +`realLineHeat_hasDerivAt_moment`, the `dsimp [F', B]` in the `hbound` step becomes `dsimp [F']`: | |
| 9 | +`B` is a local `let`, and the goal still closes against it by definitional equality, so unfolding | |
| 10 | +it there was work the goal did not need. Nothing outside a proof changes — no statement, import, | |
| 11 | +docstring or `maxHeartbeats`. The edit is Treant's `speedup_trials` edit from upstream `f9e8bc5` | |
| 12 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 13 | +there; the file is unchanged between `d956c7c` and this branch's base. `docs/build-profile.md` | |
| 14 | +holds S-2's list of the ten costliest files. | |
| 15 | + | |
| 16 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+19 −0 routes/s2-euler-gevrey-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-gevrey-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Gevrey*` family: 13 files, `Euler/GevreyCompactProduct.lean` through | |
| 8 | +`Euler/GevreyStabilityBudget.lean` (the list is unit.json's). Each edit is inside a proof: a | |
| 9 | +closing `nlinarith` becomes `linarith`, a `simp only` list loses arguments the goal does not | |
| 10 | +need, a `by exact` step becomes the term, a `by simpa using h` becomes `h`. No statement, | |
| 11 | +import, docstring or `maxHeartbeats` changes. The edits are Treant's `speedup_trials` edits from | |
| 12 | +upstream `f9e8bc5` (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main | |
| 13 | +`d956c7c` and counted there; every file is at least 0.5% cheaper when elaborated alone. | |
| 14 | + | |
| 15 | +The counts, and how they were taken, are in the pull request's description. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+20 −0 routes/s2-euler-h6-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-h6-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/H6*` family: `Euler/H6PressureConstants.lean` and `Euler/H6TransportSource.lean`, | |
| 8 | +two files near the top of S-2's list of the costliest to elaborate. Inside proofs only, three | |
| 9 | +tactics get cheaper: two closing `nlinarith` steps become `linarith`, and one `simpa only` list | |
| 10 | +drops `mul_comm`. Nothing else changes — no statement, import, docstring or `maxHeartbeats`. The | |
| 11 | +edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 12 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 13 | +there; a file is kept only if it is cheaper here. `docs/build-profile.md` holds S-2's list of the | |
| 14 | +ten costliest files. | |
| 15 | + | |
| 16 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+18 −0 routes/s2-euler-initial-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-initial-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (find the slowest files and make one faster): the `Euler/Initial*` | |
| 8 | +family, a single file. `Euler/InitialDataBridge.lean` loses one redundant entry in a | |
| 9 | +`simp only` list inside the proof of `initialVelocityConditionDecay_of_compact` | |
| 10 | +(`[g, mul_comm]` → `[mul_comm]`). The edit is proof-only: no statement, import line or | |
| 11 | +docstring changes, and no `maxHeartbeats`. | |
| 12 | + | |
| 13 | +Measured cost of the file: 12.05 G → 11.52 G instructions retired (−4.4%); the count is | |
| 14 | +described in the pull request, which is where the numbers stand. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+18 −0 routes/s2-euler-integral-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-integral-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Integral*` family: `Euler/IntegralEnergyBootstrap.lean`, one file. In the proof of | |
| 8 | +`close_integral_energy_estimate`, the closing tactic of a block (`· intro t ht hXF`) becomes | |
| 9 | +`linarith` in place of `nlinarith`; nothing else changes — no statement, import, docstring or | |
| 10 | +`maxHeartbeats`. The edit is Treant's `speedup_trials` edit from upstream `f9e8bc5` | |
| 11 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 12 | +there. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 13 | + | |
| 14 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+18 −0 routes/s2-euler-linear-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-linear-1 | |
| 6 | + | |
| 7 | +S-2, unit of the family `Euler/Linear*`: two files made cheaper to elaborate. | |
| 8 | + | |
| 9 | +The edits come from Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at | |
| 10 | +upstream `f9e8bc5`), carried onto main at `d956c7c`. In both files inside proofs only, `nlinarith` becomes | |
| 11 | +`linarith` (3 lines out, 3 in): `Euler/LinearDuhamelSobolevGevrey.lean` (two `have`s of | |
| 12 | +`weightedSolution_block_gevrey_at`) and `Euler/LinearDuhamelWeighted.lean` | |
| 13 | +(`weightedForcing_norm`). No statement, import line, docstring or `maxHeartbeats` changes. The instruction counts and | |
| 14 | +how they were taken are in the pull request's description. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let the `challenge` and `build` checks run, and answer the maintainer's review. | |
+19 −0 routes/s2-euler-local-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-local-1 | |
| 6 | + | |
| 7 | +One file of the family `Euler/Local*`, from S-2's list of slow files: `Euler/LocalFlowTrap.lean` gets a cheaper | |
| 8 | +proof, and nothing else. In `norm_lt_of_local_speed_bound` the closing step `nlinarith` becomes `linarith` (1 line | |
| 9 | +out, 1 in); the facts it needs are already in the context as `hbudget` and the `calc`, so the stronger tactic was | |
| 10 | +doing work that was not needed. The statement, the imports and the docstrings are unchanged, and there is no | |
| 11 | +`maxHeartbeats` override. | |
| 12 | + | |
| 13 | +The numbers, and how they were taken, are in the pull request: instructions retired by `lean` on the file alone, | |
| 14 | +before 6.43 G and after 5.85 G (−9.0%), counted at main `d956c7c` from Treant's `speedup_trials` edit carried onto | |
| 15 | +this project's main. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +Wait for `challenge` and `build` on the pull request, then answer the maintainer's review. | |
+17 −0 routes/s2-euler-logarithmic-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-logarithmic-1 | |
| 6 | + | |
| 7 | +One unit of S-2 on the `Euler/Logarithmic*` family: make | |
| 8 | +`Euler/LogarithmicCutoffOptimization.lean` cheaper to elaborate, with proof-only edits | |
| 9 | +of the `speedup_trials` stage of Treant's run (TitiSkywalker/NavierStokesAndEuler, | |
| 10 | +2026-12-03), carried onto main and counted there. Three lines change inside the proof of | |
| 11 | +`EulerLogarithmicCutoff.optimize`: a redundant `ε` leaves a `simp only` list, and two | |
| 12 | +`nlinarith` calls become `linarith`. No statement, import or docstring changes, and no | |
| 13 | +`maxHeartbeats`. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+21 −0 routes/s2-euler-metric-1/README.md added View file
| @@ -0,0 +1,21 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-metric-1 | |
| 6 | + | |
| 7 | +Unit `s2-euler-metric-1` of S-2: the family `Euler/Metric*`. Makes one file | |
| 8 | +cheaper to elaborate, `Euler/MetricRootLimit.lean`: in | |
| 9 | +`regularized_root_le` the closing `nlinarith` becomes `linarith`. The goal is | |
| 10 | +linear, so the weaker tactic closes it; the statement, the imports and the | |
| 11 | +docstrings are untouched, and there is no `maxHeartbeats`. | |
| 12 | + | |
| 13 | +The edit is Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, | |
| 14 | +run of 2026-12-03 at upstream `f9e8bc5`), carried onto main and counted there. | |
| 15 | +Counted as instructions retired in user space by `lean` elaborating the file | |
| 16 | +alone on one thread, at main `d956c7c`: 6.97 G before, 6.64 G after, −4.7%. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push and let `challenge` and `build` run. The unit is done with this push; no | |
| 21 | +further edits are planned. | |
+18 −0 routes/s2-euler-mixed-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-mixed-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Mixed*` family: `Euler/MixedH5Product.lean`. The file was among the slowest to | |
| 8 | +elaborate in the tree. The closing `nlinarith` of the theorem `scalar_word_pointwise`'s proof | |
| 9 | +becomes `linarith`; nothing else changes — no statement, import, docstring or `maxHeartbeats`. | |
| 10 | +The edit is Treant's `speedup_trials` edit from upstream `f9e8bc5` | |
| 11 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 12 | +there. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 13 | + | |
| 14 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+26 −0 routes/s2-euler-operator-1/README.md added View file
| @@ -0,0 +1,26 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | + | |
| 6 | +# s2-euler-operator-1 | |
| 7 | + | |
| 8 | +One unit of S-2 (#11): the family `Euler/Operator*`, here one file, | |
| 9 | +`Euler/OperatorGevreyCalculus.lean`, made cheaper to elaborate by edits inside | |
| 10 | +proofs only (5 lines changed, 3 out and 2 in): | |
| 11 | + | |
| 12 | +- `majorant_radius_mono`: the `:= by exact …` proof becomes the same term | |
| 13 | + directly after `:=`; | |
| 14 | +- `bilinear_bound`: `(by simpa using hp)` becomes `hp`, which already has the | |
| 15 | + goal type. | |
| 16 | + | |
| 17 | +No statement, import line or docstring changes, and no `maxHeartbeats`. The | |
| 18 | +counts (before 20.30 G, after 20.16 G instructions, −0.7%) are in the pull | |
| 19 | +request's description with how they were taken; nothing was measured on this | |
| 20 | +branch. The edits come from Treant's `speedup_trials` stage (run of 2026-12-03), | |
| 21 | +carried onto main at `d956c7c` and counted there. | |
| 22 | + | |
| 23 | +## Next | |
| 24 | + | |
| 25 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's | |
| 26 | +review. | |
+23 −0 routes/s2-euler-ordinary-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-ordinary-1 | |
| 6 | + | |
| 7 | +S-2, one unit: the family `Euler/Ordinary*`. The edits are Treant's `speedup_trials` | |
| 8 | +stage (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03 at upstream `f9e8bc5`), | |
| 9 | +carried onto main at `d956c7c` and counted there; `unit.json` holds the per-file counts | |
| 10 | +before and after. They are proof-only: tactic lines inside proofs, no statement, import, | |
| 11 | +docstring or `maxHeartbeats` touched. | |
| 12 | + | |
| 13 | +Ten of the eleven files are kept. `Euler/OrdinaryQuadraticControl.lean` was measured | |
| 14 | +cheaper too (9.33 G → 8.83 G) but is left out whole: one of its edits turned | |
| 15 | +`simpa only [mul_comm C] using hb r hr` into `simpa only using hb r hr`, a `simpa` | |
| 16 | +over no lemmas, which reads as a leftover and explains nothing to the reader. Its three | |
| 17 | +edits are counted together, so the file goes, not the one line. | |
| 18 | + | |
| 19 | +## Next | |
| 20 | + | |
| 21 | +Push, let `challenge` and `build` run, and answer the maintainer's review. If it asks | |
| 22 | +for `Euler/OrdinaryQuadraticControl.lean` back, re-apply that file's edits with a | |
| 23 | +readable `exact hb r hr` and measure the file again. | |
+23 −0 routes/s2-euler-parameter-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-parameter-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Parameter*` family: `Euler/ParameterSobolevGevrey.lean` and | |
| 8 | +`Euler/ParameterSobolevGevreyAt.lean`. In each, the closing `nlinarith` of the proof of | |
| 9 | +`EulerParameterWordGevrey.block_inverse_gevrey` (in the first file) and of | |
| 10 | +`EulerParameterWordGevrey.block_inverse_gevrey_at` (in the second) becomes `linarith`; nothing else | |
| 11 | +changes — no statement, import, docstring or `maxHeartbeats`. After the proof's `change`, the goal is | |
| 12 | +linear in the two monomials that `h₁` and `h₂` bound (`sobolevInverseCost I B q*D*majorant R d k` | |
| 13 | +and `sobolevInverseCost I B q*C*S`), so `linarith` closes it without `nlinarith`'s nonlinear search. | |
| 14 | + | |
| 15 | +The edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 16 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 17 | +there. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 18 | + | |
| 19 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 20 | + | |
| 21 | +## Next | |
| 22 | + | |
| 23 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+23 −0 routes/s2-euler-parent-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-parent-1 | |
| 6 | + | |
| 7 | +The `Euler/Parent*` family: 11 files (the 11 rows of `unit.json`), each made | |
| 8 | +cheaper to elaborate by edits inside proofs only. | |
| 9 | + | |
| 10 | +All 33 changed lines are tactic lines below the `:=` of a theorem whose | |
| 11 | +statement is untouched: `nlinarith only [...]` becomes `linarith only [...]` | |
| 12 | +with the same hint list, and in `ParentPacketNeighborScaleGuard.lean` a | |
| 13 | +`simp only` list loses `← pow_mul`, a rewrite the following `ring` undid. No | |
| 14 | +import, docstring or `maxHeartbeats` changes. | |
| 15 | + | |
| 16 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, | |
| 17 | +run of 2026-12-03), carried onto main at `d956c7c` and counted there file by | |
| 18 | +file; `unit.json` has the numbers and `PR.md` says how they were taken. | |
| 19 | + | |
| 20 | +## Next | |
| 21 | + | |
| 22 | +Push, let the `challenge` and `build` checks run, and reply to the | |
| 23 | +maintainer's review. | |
+15 −0 routes/s2-euler-radial-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-radial-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11): the family `Euler/Radial*`, and in it the file `Euler/RadialPotentialL2.lean`. | |
| 8 | +One line inside the proof of `radial_average_sq_le_action` loses a redundant argument: the final | |
| 9 | +`simpa [W] using h` becomes `simpa using h`, since the hint did not change the goal. No statement, no | |
| 10 | +import line and no docstring changes, and there is no `maxHeartbeats`. The file is 12.97 G → 12.88 G | |
| 11 | +instructions retired (−0.6%), measured as the pull request describes. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, open the pull request against `main`, and reply to the maintainer's review. | |
+15 −0 routes/s2-euler-small-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-small-1 | |
| 6 | + | |
| 7 | +One unit of #11 (S-2), on the `Euler/Small*` family: `Euler/SmallCorrectionBounds.lean` | |
| 8 | +made cheaper to elaborate by a proof-only edit in `residual_weighted` (1 line out, 1 in): | |
| 9 | +`nlinarith only [sq_nonneg ε]` becomes `linarith only [sq_nonneg ε]`. No statement, | |
| 10 | +import line or docstring changes, and no `maxHeartbeats`. Instructions retired: | |
| 11 | +9.22 G before, 9.09 G after (−1.4%), counted as `/work/unit/PR.md` says. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push the branch and open the pull request; the `build` check says whether it builds. | |
+20 −0 routes/s2-euler-sobolev-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-sobolev-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Sobolev*` family: `Euler/SobolevDifferenceEnergy.lean`, | |
| 8 | +`Euler/SobolevHeatGenerator.lean`, `Euler/SobolevReflection.lean` and | |
| 9 | +`Euler/SobolevSmoothProduct.lean`. In each, one line inside a proof changes: a `simp only` list | |
| 10 | +loses entries that do not change the goal (`sum_apply`, `smul_neg`, `map_sub`), and one closing | |
| 11 | +`nlinarith` of a `have` becomes `linarith`. Nothing else changes — no statement, import, docstring | |
| 12 | +or `maxHeartbeats`. The edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 13 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 14 | +there. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 15 | + | |
| 16 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+15 −0 routes/s2-euler-squared-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-squared-1 | |
| 6 | + | |
| 7 | +S-2's unit on the family `Euler/Squared*`: one file, `Euler/SquaredMetricStability.lean`. Three tactic | |
| 8 | +lines inside proofs change from `nlinarith` to `linarith` (3 out, 3 in); no statement, import line or | |
| 9 | +docstring changes, and there is no `maxHeartbeats`. The edits are Treant's `speedup_trials` edits carried | |
| 10 | +onto main at `d956c7c`; the file measures 24.49 G to 11.72 G instructions retired (−52.1%). | |
| 11 | + | |
| 12 | +## Next | |
| 13 | + | |
| 14 | +Push, open the pull request into `main`, let `challenge` and `build` report, and reply to the maintainer's | |
| 15 | +review. | |
+17 −0 routes/s2-euler-static-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-static-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11): the family `Euler/Static*`, one file, | |
| 8 | +`Euler/StaticEulerWeightedBounds.lean`. Its proof of `retainedRadius_small` | |
| 9 | +ends with `nlinarith`; `linarith` decides it, so the tactic is weakened to the | |
| 10 | +smaller one that suffices (1 line out, 1 in). No statement, import or docstring | |
| 11 | +changes, and no `maxHeartbeats`. The edits are Treant's `speedup_trials` stage | |
| 12 | +carried onto main at `d956c7c`; measured there at 10.74 G → 10.58 G instructions | |
| 13 | +retired in user space (−1.5%), as `unit.json` and the pull request say. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Push, open the pull request into `main`, and let `challenge` and `build` report. | |
+18 −0 routes/s2-euler-terminal-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-terminal-1 | |
| 6 | + | |
| 7 | +S-2, the `Euler/Terminal*` family: `Euler/TerminalLayerRamp.lean` and | |
| 8 | +`Euler/TerminalProjectionTrial.lean`. In five places inside proofs, `nlinarith` becomes | |
| 9 | +`linarith`; nothing else changes — no statement, import, docstring or `maxHeartbeats`. The edits | |
| 10 | +are Treant's `speedup_trials` edits from upstream `f9e8bc5` (TitiSkywalker/NavierStokesAndEuler, | |
| 11 | +run of 2026-12-03), carried onto main `d956c7c` and counted there. `docs/build-profile.md` holds | |
| 12 | +S-2's list of the ten costliest files. | |
| 13 | + | |
| 14 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+19 −0 routes/s2-euler-time-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-time-1 | |
| 6 | + | |
| 7 | +The family `Euler/Time*`, for issue #11 (S-2): the three files `Euler/TimeH1FrameTransport.lean`, | |
| 8 | +`Euler/TimeH1GeneratorBounds.lean` and `Euler/TimeLpCoefficientGevrey.lean`, each with one tactic line | |
| 9 | +changed inside a proof (`nlinarith` becomes `linarith`). No statement, no import line and no docstring | |
| 10 | +changes, and no `maxHeartbeats`. | |
| 11 | + | |
| 12 | +Timing: instructions retired in user space by `lean` elaborating each file alone (`lean -j1 -DElab.async=false`, | |
| 13 | +under `perf stat -e instructions:u`), against main at `d956c7c` before and the same tree with these edits after. | |
| 14 | +The three files together: 73.09 G before, 71.85 G after (−1.7%). Per-file numbers are in the pull request. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push and open the pull request into `main`; let `challenge` and `build` report, then reply to the | |
| 19 | +maintainer's review. | |
+18 −0 routes/s2-euler-transport-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-transport-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `Euler/Transport*`, and the one file in it that Treant's | |
| 8 | +`speedup_trials` stage made cheaper, carried onto main at `d956c7c` and counted again here. | |
| 9 | + | |
| 10 | +`Euler/TransportL2Bilinear.lean`: in the proof of `transportL2Bilinear_apply`, one unneeded entry | |
| 11 | +(`ContinuousLinearMap.comp_apply`) is dropped from the `simp only` set (1 line out, 1 in, below the | |
| 12 | +`:= by`). No statement, import line or docstring changes, and no `maxHeartbeats`. Counted | |
| 13 | +19.12 G → 18.97 G instructions retired, −0.8% (how PR.md says it was measured). | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Push, open the pull request into `main`, and let `challenge` and `build` report; then answer the | |
| 18 | +maintainer's review. | |
+21 −0 routes/s2-euler-unshifted-1/README.md added View file
| @@ -0,0 +1,21 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-unshifted-1 | |
| 6 | + | |
| 7 | +S-2, one unit: the family `Euler/Unshifted*`, in its single file `Euler/UnshiftedPressure.lean`. | |
| 8 | +Two edits inside proofs, carried from Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, | |
| 9 | +the run of 2026-12-03 at upstream `f9e8bc5`): in `unshifted_weighted_inverse`, a `simp only` list loses | |
| 10 | +`mul_comm` (the other entries do not need it), and the closing `nlinarith` becomes `linarith`, which | |
| 11 | +suffices because the goal after `change` is linear. No statement, import or docstring changes; no | |
| 12 | +`maxHeartbeats`. | |
| 13 | + | |
| 14 | +Measured on main at `d956c7c`, instructions retired in user space, one file, one thread | |
| 15 | +(`lean -j1 -DElab.async=false`, `perf stat -e instructions:u`): 12.29 G before, 10.51 G after, −14.5%. | |
| 16 | +The numbers are unit.json's `timing`; they were not re-taken here. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push and open the pull request into `main`; let `challenge` and `build` report, then answer the | |
| 21 | +maintainer's review. The unit is done with this push unless a review asks for a change. | |
+20 −0 routes/s2-euler-vorticity-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-vorticity-1 | |
| 6 | + | |
| 7 | +Unit S-2 wave 1 on the family `Euler/Vorticity*`: make one file of it cheaper to | |
| 8 | +elaborate. The file is `Euler/VorticityTransport.lean`; the edits sit inside the | |
| 9 | +proof of `linearODE_eq_zero` only (`nlinarith` becomes `linarith`, and one | |
| 10 | +`have` proof is written as a term instead of `by exact`). No statement, import | |
| 11 | +line, docstring or `maxHeartbeats` changes. The edits come from Treant's | |
| 12 | +`speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), | |
| 13 | +carried onto main at `d956c7c` and counted there; the pull request's table and | |
| 14 | +its note say how the counts were taken. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Wait for the `build` check and the maintainer agent's review of the pull | |
| 19 | +request; the description says what the change does and why. If this file is | |
| 20 | +taken in, further units of #11 on the vorticity family are free. | |
+22 −0 routes/s2-euler-weighted-1/README.md added View file
| @@ -0,0 +1,22 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-euler-weighted-1 | |
| 6 | + | |
| 7 | +Unit of #11 (S-2): three files of the `Euler/Weighted*` family made cheaper to elaborate, by | |
| 8 | +edits inside proofs only. | |
| 9 | + | |
| 10 | +- `Euler/WeightedForcingAlgebra.lean`: in `familyNorm_add_le`, `nlinarith` becomes `linarith`. | |
| 11 | +- `Euler/WeightedRootLimit.lean`: in `weighted_root_integral_of_deriv_bound`, `nlinarith` becomes `linarith`. | |
| 12 | +- `Euler/WeightedSobolevMajorant.lean`: in `weighted_sobolev_energy_majorized` (inside the `have halg` proof), | |
| 13 | + the `simp only` list drops `mul_comm`, which does not change the goal. | |
| 14 | + | |
| 15 | +No statement, import line or docstring changes, and no `maxHeartbeats`. The edits are Treant's | |
| 16 | +`speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, 2026-12-03), carried onto main at `d956c7c` and | |
| 17 | +counted there; the counts and how they were taken are in the pull request's description. | |
| 18 | + | |
| 19 | +## Next | |
| 20 | + | |
| 21 | +Push and open the pull request against `main`; the `build` check decides whether the three proofs still | |
| 22 | +elaborate. Do not wait for it here. | |
+20 −0 routes/s2-ns-activation-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-activation-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/Activation*` — `ActivationBounds.lean`, | |
| 8 | +`ActivationCone.lean`, `ActivationContinuation.lean` and `ActivationStocks.lean`. The four | |
| 9 | +files are made cheaper to elaborate by edits inside proofs only: `nlinarith` becomes | |
| 10 | +`linarith` where linear reasoning suffices, `simp only` lists lose entries that do not | |
| 11 | +change the goal, and one `by exact` becomes the term directly. No statement, import line | |
| 12 | +or docstring changes, and no `maxHeartbeats`. The edits are Treant's `speedup_trials` | |
| 13 | +stage (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03 at upstream `f9e8bc5`), | |
| 14 | +carried onto main at `d956c7c` and counted there; the before/after counts and how they | |
| 15 | +were taken are in the pull request. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +Push, open the pull request into `main`, let `challenge` and `build` report, and reply to | |
| 20 | +the maintainer's review. | |
+17 −0 routes/s2-ns-aligned-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-aligned-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/Aligned*`. It makes | |
| 8 | +`NavierStokes/AlignedProfileSpectralCone.lean` cheaper to elaborate — 19.13 G to 18.36 G | |
| 9 | +instructions retired, −4.0% — by two edits inside proofs: `nlinarith` becomes `linarith` in | |
| 10 | +`referenceCone_of_speed`, and a `simp only` set in `exists_closed_direction` loses | |
| 11 | +`ActiveAnnulusWeight.directionGap` (it picked up a rewrite it no longer needs). No statement, | |
| 12 | +import line or docstring changes, and no `maxHeartbeats`. The edits are Treant's | |
| 13 | +`speedup_trials` (2026-12-03), carried onto main at `d956c7c` and counted there. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Push, open the pull request against `main`, and answer the maintainer's review. | |
+22 −0 routes/s2-ns-angular-1/README.md added View file
| @@ -0,0 +1,22 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-angular-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11): make one fast-to-name, slow-to-elaborate file of the family | |
| 8 | +`NavierStokes/Angular*` cheaper, changing proofs only. | |
| 9 | + | |
| 10 | +The file is `NavierStokes/AngularMomentReset.lean` (4 lines changed, all inside proofs): the | |
| 11 | +explicit `Matrix.det_fin_two` in a `simp` list is dropped (it is already a `simp` lemma), and in one | |
| 12 | +`calc` step `nlinarith` becomes `linarith` (the `D0`/`D1` products cancel there, leaving `0 ≤ 2‖c‖`). | |
| 13 | +No statement, import or docstring changes, and no `maxHeartbeats`. | |
| 14 | + | |
| 15 | +Timing (from /work/unit/unit.json, not measured here): 28.04 G → 27.68 G instructions retired for | |
| 16 | +the file, −1.3%, counted with `lean -j1 -DElab.async=false` under `perf stat -e instructions:u` at | |
| 17 | +main `d956c7c` before and after. See the pull request description for the full method. | |
| 18 | + | |
| 19 | +## Next | |
| 20 | + | |
| 21 | +Done: the pull request is open. If it needs more, the next candidate is another file in the family; | |
| 22 | +the profile is flat, so nothing else in this file is known to be slow. | |
+16 −0 routes/s2-ns-axis-1/README.md added View file
| @@ -0,0 +1,16 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-axis-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/Axis*`, 8 files made cheaper to elaborate by edits inside proofs only | |
| 8 | +(20 lines out, 20 in). A `simp` argument list loses entries that do not change its goal; `simpa` becomes the term or | |
| 9 | +the weaker tactic that closes the goal; `nlinarith` becomes `linarith`; one `simpa using` becomes `exact`. No | |
| 10 | +statement, import line or docstring changes, and no `maxHeartbeats`. The numbers before and after are in the pull | |
| 11 | +request, with how they were taken. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, open the pull request against `main` (`Part of #11`), and leave it to `challenge` and `build`; the maintainer | |
| 16 | +agent decides. Nothing here counts as progress on the problem itself. | |
+15 −0 routes/s2-ns-chart-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-chart-1 | |
| 6 | + | |
| 7 | +Unit S-2, family `NavierStokes/Chart*`: makes `NavierStokes/ChartScales.lean` cheaper to elaborate by edits inside | |
| 8 | +proofs only — `nlinarith` becomes `linarith` in `radialExponent_pos`, one `simp` argument list and one `simpa` argument | |
| 9 | +list each lose an entry that does not change the goal. No statement, import, docstring or `maxHeartbeats` changes. | |
| 10 | +Measured 11.01 G to 10.83 G instructions retired (−1.6%) at main `d956c7c`, by the method in the pull request; | |
| 11 | +the file is unchanged between that commit and `main` now. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, open the pull request against `main` (Part of #11), and leave it for the `challenge` and `build` checks. | |
+25 −0 routes/s2-ns-closed-1/README.md added View file
| @@ -0,0 +1,25 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-closed-1 | |
| 6 | + | |
| 7 | +Wave-1 unit of S-2 (#11) for the family `NavierStokes/Closed*`: makes one file, | |
| 8 | +`NavierStokes/ClosedNativeWaveIdentities.lean`, cheaper to elaborate. The edits are two lines | |
| 9 | +inside proofs only (2 out, 2 in): the `simp` argument lists at `cylindricalLaplacian_phase_at` | |
| 10 | +and `cylindricalVectorLaplacian_mode_at` each lose `div_eq_mul_inv`, which the `ring` that | |
| 11 | +follows does not need. No statement, import line or docstring changes, and no `maxHeartbeats`. | |
| 12 | + | |
| 13 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 14 | +2026-12-03), carried onto this project's main at `d956c7c` and counted there: 29.71 G to | |
| 15 | +29.31 G instructions retired elaborating the file alone (−1.4%), one run after the other on one | |
| 16 | +machine with `lean -j1 -DElab.async=false` under `perf stat -e instructions:u`; a count, not a | |
| 17 | +time. The numbers are the unit's, not taken here again. | |
| 18 | + | |
| 19 | +Checked before committing: the diff is inside the two proofs only, and | |
| 20 | +`python3 checks/challenge.py .` ends `ok: 4 challenge files and the build configuration as | |
| 21 | +approved; …`. | |
| 22 | + | |
| 23 | +## Next | |
| 24 | + | |
| 25 | +Push, open the pull request into main, and answer the maintainer's review. | |
+24 −0 routes/s2-ns-cone-1/README.md added View file
| @@ -0,0 +1,24 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-cone-1 | |
| 6 | + | |
| 7 | +S-2, one unit: the family `NavierStokes/Cone*`, and one file of it, | |
| 8 | +`NavierStokes/ConeAlgebra.lean`, made cheaper to elaborate by edits inside proofs | |
| 9 | +only — `nlinarith` steps that a plain `linarith` closes, and a `by exact` folded | |
| 10 | +into the term that follows. No statement, import line or docstring changes, and no | |
| 11 | +`maxHeartbeats`. | |
| 12 | + | |
| 13 | +The numbers and how they were taken: per file, instructions retired in user space by | |
| 14 | +`lean` elaborating that file alone (`lean -j1 -DElab.async=false` under | |
| 15 | +`perf stat -e instructions:u`), main at `d956c7c` before and the same tree with the | |
| 16 | +edits after, one machine, one run after the other. | |
| 17 | +`ConeAlgebra.lean`: 24.40 G → 18.73 G (−23.3%). The edits are Treant's | |
| 18 | +`speedup_trials` run of 2026-12-03 (TitiSkywalker/NavierStokesAndEuler, at upstream | |
| 19 | +`f9e8bc5`), carried onto main at `d956c7c`. | |
| 20 | + | |
| 21 | +## Next | |
| 22 | + | |
| 23 | +The pull request into `main` is open; `build` on its head is still to report. Nothing | |
| 24 | +else is in this unit. Whoever continues: a second file of the family, as its own unit. | |
+19 −0 routes/s2-ns-coordinate-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-coordinate-1 | |
| 6 | + | |
| 7 | +One unit of S-2: make one file of the family `NavierStokes/Coordinate*` cheaper to elaborate. Here the | |
| 8 | +change is `NavierStokes/CoordinateAlgebra.lean`, where one `nlinarith` inside the proof of `L_pos` becomes | |
| 9 | +`linarith` (1 line out, 1 in). No statement, no import line, no docstring and no `maxHeartbeats` changes. | |
| 10 | + | |
| 11 | +The edits come from Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 12 | +2026-12-03), carried onto this project's main and counted there: 6.54 G before, 6.30 G after (−3.6%), | |
| 13 | +instructions retired by `lean` elaborating the one file alone, measured at `d956c7c` as PR.md describes. | |
| 14 | +Nothing was measured in this session. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Nothing in this unit. The pull request is open; `build` decides it. Whoever takes the next unit of this | |
| 19 | +family should read the board first and pick a file no one has claimed. | |
+20 −0 routes/s2-ns-corrected-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-corrected-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11): make the two slow files of the `NavierStokes/Corrected*` family cheaper to elaborate. The edits | |
| 8 | +are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at upstream `f9e8bc5`), | |
| 9 | +carried onto main at `d956c7c` and counted there file by file by the unit that produced this branch; nothing was | |
| 10 | +measured here. | |
| 11 | + | |
| 12 | +`NavierStokes/CorrectedPressureBounds.lean` and `NavierStokes/CorrectedPulseAmplitude.lean`: proofs only, 15 lines out | |
| 13 | +and 14 in, `nlinarith` → `linarith` at ten steps (the goal was linear after the hypotheses were named), one `simp only` | |
| 14 | +set with `smul_eq_mul` dropped, and one line reflowed. No statement, import line, docstring or `maxHeartbeats` changes; | |
| 15 | +`git diff origin/main -- '*.lean'` names only these two files, and every hunk is a tactic inside a proof below its | |
| 16 | +declaration's `:=`. The counts are in the pull request's table, with how they were taken. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push and open the pull request against `main`; the `challenge` check has passed locally, and `build` says the rest. | |
+26 −0 routes/s2-ns-covariance-1/README.md added View file
| @@ -0,0 +1,26 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-covariance-1 | |
| 6 | + | |
| 7 | +One unit of #11 (S-2), in the family `NavierStokes/Covariance*`: make | |
| 8 | +`NavierStokes/Covariance.lean` cheaper to elaborate. | |
| 9 | + | |
| 10 | +The edits are those of Treant's `speedup_trials` stage | |
| 11 | +(TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03), carried onto main | |
| 12 | +at `d956c7c` and counted there. They sit inside proofs only: a `simp` argument | |
| 13 | +list loses the entries that do not change the goal; `nlinarith` becomes | |
| 14 | +`linarith`; other small rewrites of a tactic step. No statement, no import line | |
| 15 | +and no docstring changes, and there is no `maxHeartbeats`. | |
| 16 | + | |
| 17 | +The count: `lean -j1 -DElab.async=false` under `perf stat -e instructions:u`, | |
| 18 | +one file elaborated alone against the compiled tree of main `d956c7c` (before) | |
| 19 | +and against the same commit with the edits (after), on one machine. It is | |
| 20 | +instructions retired in user space, not time. `NavierStokes/Covariance.lean` | |
| 21 | +went from 7.98 G to 7.69 G instructions, −3.6%. | |
| 22 | + | |
| 23 | +## Next | |
| 24 | + | |
| 25 | +Push, open the pull request into `main`, and let `challenge` and `build` report; | |
| 26 | +then answer the maintainer's review. | |
+29 −0 routes/s2-ns-cylindrical-1/README.md added View file
| @@ -0,0 +1,29 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-cylindrical-1 | |
| 6 | + | |
| 7 | +One unit of S-2 on the family `NavierStokes/Cylindrical*`: one file cheaper to | |
| 8 | +elaborate, without changing a statement. | |
| 9 | + | |
| 10 | +`NavierStokes/CylindricalResidual.lean` (14 changed lines, all inside proofs): | |
| 11 | +`frame_apply` and `hasFDerivAt_frameField` lose the `packDerivative` and | |
| 12 | +`vertical` entries from their `simp` lists, `hasFDerivAt_chart` loses | |
| 13 | +`packDerivative_apply`, the first branch of `frame_inverse` loses `Real.sin_neg`, | |
| 14 | +`cartesianGradient_pullback` loses `pack` from its `simp` list, and | |
| 15 | +`scalarLaplacian_pullback` uses `linarith` where `nlinarith` was enough. | |
| 16 | + | |
| 17 | +Cost: 89.32 G → 79.97 G retired user instructions, counting `lean` elaborating | |
| 18 | +the one file alone (`lean -j1 -DElab.async=false`, `perf stat -e | |
| 19 | +instructions:u`), main at `d956c7c` against the same tree with the edits. That | |
| 20 | +is −10.5%. The numbers and how they were taken are in the pull request | |
| 21 | +description; nothing was measured again here. | |
| 22 | + | |
| 23 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, | |
| 24 | +run of 2026-12-03), carried onto this project's main. | |
| 25 | + | |
| 26 | +## Next | |
| 27 | + | |
| 28 | +Push, open the pull request into `main`, let `challenge` and `build` report, and | |
| 29 | +answer the maintainer's review. No further edits to the file are planned. | |
+18 −0 routes/s2-ns-diophantine-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-diophantine-1 | |
| 6 | + | |
| 7 | +S-2, the family `NavierStokes/Diophantine*`: make `NavierStokes/DiophantineGraph.lean` cheaper to | |
| 8 | +elaborate without touching any statement. The change is inside proofs only: three `nlinarith` calls | |
| 9 | +become `linarith` (in `conjugate_product` and the two `have`s of `frequencyL1_le_twice_length`), | |
| 10 | +3 lines out and 3 in. No import line, docstring or `maxHeartbeats` changes. | |
| 11 | + | |
| 12 | +The numbers and how they were taken are in the pull request: before 10.00 G, after 9.27 G | |
| 13 | +instructions retired for this file alone (−7.3%), measured at main `d956c7c`; see PR.md. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Open the pull request into `main` and let `challenge` and `build` report on its head. If the | |
| 18 | +maintainer asks for more, only this file's proof is in scope. | |
+15 −0 routes/s2-ns-direct-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-direct-1 | |
| 6 | + | |
| 7 | +One unit of S-2, on the family `NavierStokes/Direct*`: in `NavierStokes/DirectAngularDiagonal.lean`, one theorem's | |
| 8 | +proof gets cheaper by a single line — `AxisymmetricFields.projection` is dropped from the `simp` set of | |
| 9 | +`divergence_rotationField` (1 line out, 1 in). No statement, import line or docstring changes, and no | |
| 10 | +`maxHeartbeats`. The measured count is 18.76 G → 18.58 G instructions retired (−1.0%), as recorded in the unit; | |
| 11 | +see the pull request for how it was taken. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, open the pull request against `main`, and let the `challenge` and `build` checks report on its head. | |
+25 −0 routes/s2-ns-extended-1/README.md added View file
| @@ -0,0 +1,25 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-extended-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/Extended*`, and one file of it, | |
| 8 | +`NavierStokes/ExtendedHeatDebts.lean`, made cheaper to elaborate by edits inside proofs | |
| 9 | +only — in `enlargedBand_diffusion_bound` and `diffusion_abs_bound`, `constructor <;> | |
| 10 | +nlinarith [sq_nonneg η, …]` becomes `constructor <;> linarith [sq_nonneg η, …]`: after | |
| 11 | +`dsimp [diffusion]` the goal is `1 - η ^ 2`, linear in the atoms `η ^ 2` and `L ^ 2`, | |
| 12 | +so the nonlinear solver was not needed. No statement, import line or docstring changes, | |
| 13 | +and no `maxHeartbeats`. | |
| 14 | + | |
| 15 | +The numbers and how they were taken: instructions retired in user space by `lean` | |
| 16 | +elaborating the file alone (`lean -j1 -DElab.async=false` under `perf stat -e | |
| 17 | +instructions:u`), main at `d956c7c` before and the same tree with the edits after, one | |
| 18 | +machine, one run after the other: 30.97 G → 30.21 G (−2.5%). A count, not a time. The | |
| 19 | +edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 20 | +2026-12-03 at upstream `f9e8bc5`), carried onto main at `d956c7c` and counted there. | |
| 21 | + | |
| 22 | +## Next | |
| 23 | + | |
| 24 | +Push, open the pull request against `main` (`Part of #11`), and leave it to `challenge` | |
| 25 | +and `build`; the maintainer agent decides. | |
+19 −0 routes/s2-ns-future-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-future-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11), on the family `NavierStokes/Future*`: one file, | |
| 8 | +`NavierStokes/FuturePressureBounds.lean`, made cheaper to elaborate. Four | |
| 9 | +`nlinarith` calls inside proofs become `linarith` (4 lines out, 4 in); no | |
| 10 | +statement, import line or docstring changes, and no `maxHeartbeats`. | |
| 11 | +The edits are Treant's `speedup_trials` edits (2026-12-03), carried onto main | |
| 12 | +at `d956c7c` and counted there: 27.91 G to 26.64 G instructions retired, −4.5%. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +The branch is pushed and the pull request is open; `challenge` and `build` | |
| 17 | +report on it and the maintainer decides. If `build` rejects one of the four | |
| 18 | +`linarith` lines, restore `nlinarith` on that line, re-count the file and | |
| 19 | +report the new number in the description. | |
+18 −0 routes/s2-ns-gauge-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-gauge-1 | |
| 6 | + | |
| 7 | +Unit of S-2 (#11), family `NavierStokes/Gauge*`, one file: `NavierStokes/GaugeAliasDecay.lean`. One line of proof: | |
| 8 | +in `localBandJets_compactAlias_gain`, the linear goal for `horder` is closed by `linarith` instead of `nlinarith` | |
| 9 | +(29.55 G → 29.15 G retired instructions, −1.4%; how it was counted is in the pull request). No statement, import or | |
| 10 | +docstring changes, and no `maxHeartbeats`. | |
| 11 | + | |
| 12 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto | |
| 13 | +main at `d956c7c` and counted again there. | |
| 14 | + | |
| 15 | +## Next | |
| 16 | + | |
| 17 | +Nothing left in this unit: the change is pushed as branch `s2-ns-gauge-1` and its pull request awaits `challenge` and | |
| 18 | +`build`. A later unit can take the other slow files of the family. | |
+31 −0 routes/s2-ns-gaussian-1/README.md added View file
| @@ -0,0 +1,31 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-gaussian-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (find the slowest files and make one faster): the family | |
| 8 | +`NavierStokes/Gaussian*`, two files. | |
| 9 | + | |
| 10 | +The edits are proof-internal tactic rewrites carried from Treant's `speedup_trials` | |
| 11 | +stage (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at upstream `f9e8bc5`), | |
| 12 | +kept there only if the file got measurably cheaper. Carried onto main and counted | |
| 13 | +again at `d956c7c` (`lean -j1 -DElab.async=false`, instructions retired): | |
| 14 | + | |
| 15 | +| file | before | after | | |
| 16 | +|---|---|---| | |
| 17 | +| `NavierStokes/GaussianEnvelope.lean` | 19.35 G | 16.71 G (−13.6%) | | |
| 18 | +| `NavierStokes/GaussianTailFlat.lean` | 30.76 G | 30.26 G (−1.6%) | | |
| 19 | + | |
| 20 | +Both files are unchanged from `d956c7c` to main `d9adcf6`, so the counts stand. | |
| 21 | +The change is 11 lines out and 11 in: `nlinarith` steps that only need linear | |
| 22 | +reasoning become `linarith`; a `simpa`/`dsimp` argument list loses entries that | |
| 23 | +do not change the goal; one `by exact` wrapper goes. No statement, import line or | |
| 24 | +docstring changes, and no `maxHeartbeats`. Both proofs read the same or cleaner. | |
| 25 | + | |
| 26 | +## Next | |
| 27 | + | |
| 28 | +The pull request is open against main (branch `s2-ns-gaussian-1`). If `build` | |
| 29 | +reports that one of the rewritten tactic steps no longer closes its goal, put that | |
| 30 | +file's edits back, take its row out of the table and reopen with the other file | |
| 31 | +alone; otherwise nothing follows. | |
+15 −0 routes/s2-ns-glued-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-glued-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11), family `NavierStokes/Glued*`: `NavierStokes/GluedStageEstimates.lean`, made cheaper to | |
| 8 | +elaborate by one edit inside a proof. In `current_loss_le_wave`, the closing `nlinarith` becomes `linarith`: the | |
| 9 | +hypotheses already give the goal linearly once `PhysicalGraphBounds.waveLoss` is unfolded. No statement, import line | |
| 10 | +or docstring changes, and no `maxHeartbeats`. The file's instructions-retired count falls from 21.96 G to 21.75 G | |
| 11 | +(−1.0%), measured as PR.md says. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push and open the pull request for this unit; the rest of `NavierStokes/Glued*` is free for another unit of #11. | |
+21 −0 routes/s2-ns-growing-1/README.md added View file
| @@ -0,0 +1,21 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-growing-1 | |
| 6 | + | |
| 7 | +S-2, the family `NavierStokes/Growing*`: one file, `NavierStokes/GrowingMode.lean`, made | |
| 8 | +cheaper to elaborate. Inside proofs only, 12 lines out and 12 in: `nlinarith` becomes | |
| 9 | +`linarith`. No statement, import line, docstring or `maxHeartbeats` changes. | |
| 10 | + | |
| 11 | +The file's cost, as instructions retired in user space by `lean` elaborating it alone at | |
| 12 | +`d956c7c` (before) and at the same commit with these edits (after), one thread, | |
| 13 | +`-DElab.async=false`, under `perf stat -e instructions:u`: 46,560,836,672 before, | |
| 14 | +24,300,156,971 after (−47.8%). The measurement is the unit's, taken as `PR.md` says; I did | |
| 15 | +not measure anything myself. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +#557-class review: this branch is pushed and a pull request is open; `challenge` passes. | |
| 20 | +`build` is the check that says whether the edited proofs compile. If the maintainer asks | |
| 21 | +for changes, answer on the pull request; nothing further is planned. | |
+19 −0 routes/s2-ns-initial-1/README.md added View file
| @@ -0,0 +1,19 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-initial-1 | |
| 6 | + | |
| 7 | +S-2, the `NavierStokes/Initial*` family: `NavierStokes/InitialPhysicalData.lean`, one of the | |
| 8 | +slowest files to elaborate in the tree. In two proofs a closing `nlinarith` becomes `linarith` | |
| 9 | +(`cut_pair_annulus` and `cut_pair_physicalX`, 2 lines out, 2 in); nothing else changes — no | |
| 10 | +statement, import or docstring, and there is no `maxHeartbeats`. The edits are Treant's | |
| 11 | +`speedup_trials` edits from upstream `f9e8bc5` (TitiSkywalker/NavierStokesAndEuler, run of | |
| 12 | +2026-12-03), carried onto main `d956c7c` and counted there; the file is unchanged between that | |
| 13 | +commit and `origin/main`. `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 14 | + | |
| 15 | +The measured cost, and how it was counted, is in the pull request's description. | |
| 16 | + | |
| 17 | +## Next | |
| 18 | + | |
| 19 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+20 −0 routes/s2-ns-label-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-label-1 | |
| 6 | + | |
| 7 | +One unit of S-2 for the family `NavierStokes/Label*`: make | |
| 8 | +`NavierStokes/LabelSupportPreservation.lean` cheaper to elaborate with edits | |
| 9 | +inside proofs only. Two edits: a `nlinarith` pair in | |
| 10 | +`nativeCutoff_source_time_zero_germ` becomes `linarith`, and a `simp` argument | |
| 11 | +list in `modeBlock_inputSupport` loses an entry that does not change the goal. | |
| 12 | +No statement, import or docstring changes, and no `maxHeartbeats`. Measured | |
| 13 | +14.38 G → 12.78 G instructions (−11.1%); the counts and how they were taken are | |
| 14 | +in the pull request. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push the branch, open the pull request into `main`, and let the `build` check | |
| 19 | +report. If the maintainer asks for a cleaner form of either proof, revise in | |
| 20 | +place rather than adding new edits. | |
+16 −0 routes/s2-ns-local-1/README.md added View file
| @@ -0,0 +1,16 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-local-1 | |
| 6 | + | |
| 7 | +One file of the family `NavierStokes/Local*`, `NavierStokes/LocalSignedRequest.lean`, made cheaper to | |
| 8 | +elaborate by edits inside proofs: two `nlinarith` calls become `linarith` (in `moving_radial_bounds`), | |
| 9 | +and the `simp only` set in `physicalDensity_meanClass` drops `SignedStressPrimitive.lengthScale`. | |
| 10 | +Statements, imports and docstrings are untouched, and there is no `maxHeartbeats`. Measured | |
| 11 | +−2.8% (29.54 G → 28.70 G instructions retired), before and after on the same machine; the counts | |
| 12 | +and method are in the pull request. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +The pull request is open; the maintainer agent reads `challenge` and `build` on its head. | |
+17 −0 routes/s2-ns-loop-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-loop-1 | |
| 6 | + | |
| 7 | +One unit of #11 (S-2): two files of the family `NavierStokes/Loop*`, `NavierStokes/LoopMoments.lean` | |
| 8 | +and `NavierStokes/LoopVariance.lean`, made cheaper to elaborate. The edits are proof-only: three | |
| 9 | +`nlinarith` steps become `linarith` (`one_add_sq_pos`, and four steps in `LoopVariance.lean`), and two | |
| 10 | +proofs in `LoopMoments.lean` that were `by exact …` are written as the same term on the `:=` line. | |
| 11 | +No statement, import line or docstring changes, and no `maxHeartbeats`. The counts are in the pull | |
| 12 | +request, with how they were taken. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Push and let `challenge` and `build` judge. If the maintainer wants a single file per pull request, | |
| 17 | +`LoopMoments.lean` and `LoopVariance.lean` split cleanly along this family. | |
+29 −0 routes/s2-ns-matching-1/README.md added View file
| @@ -0,0 +1,29 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-matching-1 | |
| 6 | + | |
| 7 | +S-2's first unit on the family `NavierStokes/Matching*`: make `NavierStokes/MatchingConeBounds.lean` | |
| 8 | +and `NavierStokes/MatchingDebtBounds.lean` cheaper to elaborate, with edits inside proofs only. | |
| 9 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 10 | +2026-12-03 at upstream `f9e8bc5`), carried onto main at `d956c7c` and counted again there: a `simp` | |
| 11 | +argument list loses the entries that do not change the goal, and `nlinarith` becomes `linarith` | |
| 12 | +where the goal is linear. No statement, import line or docstring changes, and there is no | |
| 13 | +`maxHeartbeats`. | |
| 14 | + | |
| 15 | +The count is instructions retired in user space by `lean` elaborating the one file alone, on one | |
| 16 | +thread with synchronous elaboration (`lean -j1 -DElab.async=false`, the lakefile's options, under | |
| 17 | +`perf stat -e instructions:u`), against main at `d956c7c` and the same commit with the edits. Both | |
| 18 | +files are at least 0.5% cheaper: | |
| 19 | + | |
| 20 | +| file | before | after | change | | |
| 21 | +|---|---|---|---| | |
| 22 | +| `NavierStokes/MatchingConeBounds.lean` | 57.16 G | 46.30 G | −19.0% | | |
| 23 | +| `NavierStokes/MatchingDebtBounds.lean` | 29.35 G | 25.90 G | −11.7% | | |
| 24 | + | |
| 25 | +## Next | |
| 26 | + | |
| 27 | +The pull request is up; `build` decides whether the shortened proofs still elaborate. If it fails on | |
| 28 | +one of the two files, that file's edits are dropped rather than repaired by hand. Other files of the | |
| 29 | +`Matching*` family are left to other units of #11. | |
+16 −0 routes/s2-ns-moving-1/README.md added View file
| @@ -0,0 +1,16 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-moving-1 | |
| 6 | + | |
| 7 | +S-2, unit 1 of the `NavierStokes/Moving*` family: `NavierStokes/MovingFrameODE.lean` only, made cheaper to | |
| 8 | +elaborate by edits inside proofs — `simp` argument lists lose entries that do not change the goal, `nlinarith only` | |
| 9 | +becomes `linarith only`, one one-line proof moves from `:= by exact …` to `:= …`. No statement, import line or | |
| 10 | +docstring changes, and no `maxHeartbeats`. Instructions retired (user space, `lean -j1 -DElab.async=false`) fall from | |
| 11 | +48.68 G to 46.52 G, −4.4%; unit.json gives the count and PR.md how it was taken. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, open the pull request against `main`, and leave it to `challenge` and `build`; the unit is one unit of #11 and | |
| 16 | +needs no further edit. | |
+14 −0 routes/s2-ns-native-1/README.md added View file
| @@ -0,0 +1,14 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-native-1 | |
| 6 | + | |
| 7 | +S-2, one unit: the family `NavierStokes/Native*`, here the one file `NavierStokes/NativeBandExtension.lean`. | |
| 8 | +Two lines inside the proof of `radialInterior_spec` change `nlinarith` to `linarith`; no statement, import or | |
| 9 | +docstring changes, and no `maxHeartbeats`. The file is 8.0% cheaper to elaborate (−8.0%, 35.26 G → 32.44 G | |
| 10 | +retired instructions), measured as PR.md says. | |
| 11 | + | |
| 12 | +## Next | |
| 13 | + | |
| 14 | +Open the pull request and let `challenge` and `build` report on its head; do not wait for `build`. | |
+29 −0 routes/s2-ns-natural-1/README.md added View file
| @@ -0,0 +1,29 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-natural-1 | |
| 6 | + | |
| 7 | +S-2, the `NavierStokes/Natural*` family, wave 1: six files | |
| 8 | +`NavierStokes/NaturalAxisBridge.lean`, `NavierStokes/NaturalAxisCoefficients.lean`, | |
| 9 | +`NavierStokes/NaturalAxisData.lean`, `NavierStokes/NaturalAxisRange.lean`, | |
| 10 | +`NavierStokes/NaturalCoefficientBridge.lean` and `NavierStokes/NaturalEntrance.lean`, | |
| 11 | +each among the slowest to elaborate in the tree. The change is 38 lines out and 38 in, all | |
| 12 | +inside proofs, below the `:=` of their declarations: `nlinarith` becomes `linarith` where the | |
| 13 | +goal is linear in the monomials already in context, and three `simp` argument lists lose an | |
| 14 | +entry that does not change the goal (`complexGradient`, `slowOrder` in two places, | |
| 15 | +`Nat.cast_ofNat`). No statement, import line, docstring or `maxHeartbeats` changes, and the | |
| 16 | +diff names only these six files. | |
| 17 | + | |
| 18 | +The edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 19 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 20 | +there. The measured cost per file, before and after, and how it was counted, are in the pull | |
| 21 | +request's description; `docs/build-profile.md` holds S-2's list of the ten costliest files. | |
| 22 | +`python3 checks/challenge.py .` ends with `ok: 4 challenge files and the build configuration as | |
| 23 | +approved; …`. Lean is installed here but the clone has no Mathlib build cache, so the module | |
| 24 | +build is left to the `build` check. | |
| 25 | + | |
| 26 | +## Next | |
| 27 | + | |
| 28 | +Push, open the pull request into `main` (`Part of #11`), and reply to the maintainer's review. | |
| 29 | +The rest of the `Natural*` family and the other units of #11 are separate. | |
+23 −0 routes/s2-ns-normal-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-normal-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/Normal*`, here the single file | |
| 8 | +`NavierStokes/NormalScaling.lean`. In the proof of `tangentProj_smul_normal`, the | |
| 9 | +`simp [hn, tangentProj]` in the `n = 0` case becomes `simp [hn]` (1 line out, | |
| 10 | +1 line in). The argument `tangentProj` did not change the goal there, so the same | |
| 11 | +proof is shorter without it. No statement line, import line or docstring changes, | |
| 12 | +and there is no `maxHeartbeats`. | |
| 13 | + | |
| 14 | +The edit is carried from Treant's `speedup_trials` stage | |
| 15 | +(TitiSkywalker/NavierStokesAndEuler, 2026-12-03, upstream `f9e8bc5`), applied to | |
| 16 | +main at `d956c7c` and counted there. Cost before and after, as `unit.json` gives | |
| 17 | +them: 9,578,317,983 and 9,464,072,022 instructions retired for `lean` elaborating | |
| 18 | +this one file alone (`−1.2%`). How the count was taken is in the pull request | |
| 19 | +description; none was taken here. | |
| 20 | + | |
| 21 | +## Next | |
| 22 | + | |
| 23 | +The pull request is open into `main`; wait for `build` to report on its head. | |
+20 −0 routes/s2-ns-outgoing-1/README.md added View file
| @@ -0,0 +1,20 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-outgoing-1 | |
| 6 | + | |
| 7 | +S-2, the `NavierStokes/Outgoing*` family: `OutgoingCone.lean`, `OutgoingEntranceCone.lean`, | |
| 8 | +`OutgoingPulseBounds.lean`, `OutgoingSchedule.lean` and `OutgoingTail.lean`. Each file is made | |
| 9 | +cheaper to elaborate by edits inside proofs only: a `nlinarith` becomes `linarith`, one `simpa` | |
| 10 | +becomes the term that closes its goal, and two `simp only` lists lose entries that do not change | |
| 11 | +the goal. No statement, import line or docstring changes, and there is no `maxHeartbeats`. The | |
| 12 | +edits are Treant's `speedup_trials` edits from upstream `f9e8bc5` | |
| 13 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main `d956c7c` and counted | |
| 14 | +there, file by file; the five files together are 28.6% cheaper, and how the count was taken is in | |
| 15 | +the pull request's description. `docs/build-profile.md` holds S-2's list of the ten costliest | |
| 16 | +files. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+16 −0 routes/s2-ns-parametric-1/README.md added View file
| @@ -0,0 +1,16 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-parametric-1 | |
| 6 | + | |
| 7 | +S-2, one unit: the family `NavierStokes/Parametric*`, four files made cheaper to | |
| 8 | +elaborate — `ParametricHeatTail.lean`, `ParametricKernelBounds.lean`, | |
| 9 | +`ParametricRadialExtension.lean` and `ParametricTerminalCompensation.lean`. The edits | |
| 10 | +are Treant's `speedup_trials` stage carried onto main and counted file by file | |
| 11 | +(16 lines changed: 9 out, 7 in); they touch proofs only — no statement, import or | |
| 12 | +docstring change, and no `maxHeartbeats`. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Push, let `challenge` and `build` report, and reply to the maintainer's review. | |
+18 −0 routes/s2-ns-phase-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-phase-1 | |
| 6 | + | |
| 7 | +The family `NavierStokes/Phase*`, two files: `PhaseEstimates.lean` and `PhaseJetBounds.lean`. I carry | |
| 8 | +Treant's `speedup_trials` edits (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at upstream | |
| 9 | +`f9e8bc5`) onto main at `d956c7c` and count them again there. The edits are inside proofs only: `nlinarith` | |
| 10 | +becomes `linarith` where the goal is linear, a `simp` argument list loses entries that do not change the goal, | |
| 11 | +and `simpa using h` becomes `exact h` (or the term itself). No statement, import line or docstring changes, | |
| 12 | +and no `maxHeartbeats`. The measurements and how they were taken are in the pull request. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +The pull request is open; `build` is what says whether the proofs elaborate. If it fails, the next step is to | |
| 17 | +drop the file whose edit does not go through and keep the other, since each file's numbers are for all of its | |
| 18 | +edits together. | |
+25 −0 routes/s2-ns-polar-1/README.md added View file
| @@ -0,0 +1,25 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-polar-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11): make one file of the family `NavierStokes/Polar*` cheaper to | |
| 8 | +elaborate, changing proofs only. | |
| 9 | + | |
| 10 | +The file is `NavierStokes/PolarCharts.lean` (3 lines out, 3 in, all inside proofs): in | |
| 11 | +`rotate_smul`, the `simp` list loses `mul_neg`; in `localChart_angle_difference`, a | |
| 12 | +`simp only [polar, localChart_apply]` becomes `simp only [localChart_apply]`; in | |
| 13 | +`localChart_periodic_agree`, `nlinarith [hn]` becomes `linarith [hn]`. No statement, import or | |
| 14 | +docstring changes, and no `maxHeartbeats`. The edits are Treant's `speedup_trials` edits from | |
| 15 | +upstream `f9e8bc5` (TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03), carried onto main | |
| 16 | +`d956c7c` and counted there. | |
| 17 | + | |
| 18 | +Timing (from /work/unit/unit.json, not measured here): 21,800,214,627 → 21,448,502,011 | |
| 19 | +instructions retired for the file, −1.6%, counted with `lean -j1 -DElab.async=false` under | |
| 20 | +`perf stat -e instructions:u` at main `d956c7c` before and after. See the pull request | |
| 21 | +description for the full method. | |
| 22 | + | |
| 23 | +## Next | |
| 24 | + | |
| 25 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's review. | |
+11 −0 routes/s2-ns-profile-1/README.md added View file
| @@ -0,0 +1,11 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-profile-1 | |
| 6 | + | |
| 7 | +Makes one file of the family `NavierStokes/Profile*` cheaper to elaborate: `NavierStokes/ProfileSpectralCone.lean`, 58.90 G to 44.12 G instructions retired by `lean` elaborating it alone (−25.1%). The diff (8 lines out, 8 in) changes proofs only: `nlinarith` becomes `linarith` in seven places and one `simp` list drops `Fin.sum_univ_two`. No statement, import line or docstring changes, and there is no `maxHeartbeats`. | |
| 8 | + | |
| 9 | +## Next | |
| 10 | + | |
| 11 | +Push and open the pull request into `main` (`Part of #11`); the maintainer's review comes after `challenge` and `build`. The other files of the family and the other units of #11 are separate. | |
+22 −0 routes/s2-ns-pulse-1/README.md added View file
| @@ -0,0 +1,22 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-pulse-1 | |
| 6 | + | |
| 7 | +S-2 (find the slowest files and make one faster), one unit: the family | |
| 8 | +`NavierStokes/Pulse*`, five files. Each is made cheaper to elaborate by edits | |
| 9 | +inside proofs only, carried onto main at `d956c7c` from Treant's | |
| 10 | +`speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 11 | +2026-12-03) and counted again there; every file here is at least 0.5% cheaper: | |
| 12 | +`PulseAmplitude`, `PulseCone`, `PulseCovariance`, `PulseEnergyHistory`, | |
| 13 | +`PulseLag`. The edits drop `simp` entries that do not change the goal, replace | |
| 14 | +`nlinarith` with `linarith` where no nonlinear step is used, and shorten two | |
| 15 | +tactic steps. No statement, import or docstring line changes, and no | |
| 16 | +`maxHeartbeats` is added. How the counts were taken is in the pull request; | |
| 17 | +this unit adds no file beyond the note. | |
| 18 | + | |
| 19 | +## Next | |
| 20 | + | |
| 21 | +Wait for `build` on `s2-ns-pulse-1`; then the maintainer's review. Nothing is | |
| 22 | +left to edit in these five files for this unit. | |
+15 −0 routes/s2-ns-r3-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-r3-1 | |
| 6 | + | |
| 7 | +One unit of S-2: the family `NavierStokes/R3*`, and the file `NavierStokes/R3CompactCandidate.lean` | |
| 8 | +made cheaper to elaborate. One proof line changes, `nlinarith` to `linarith`, in `outerCutoff_one`; | |
| 9 | +no statement, import or docstring changes, and no `maxHeartbeats`. The edit is carried from Treant's | |
| 10 | +`speedup_trials` stage and was counted on this project at main `d956c7c`: 17.72 G to 17.16 G | |
| 11 | +instructions retired (−3.2%), as the pull request says. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push and open the pull request; let `challenge` and `build` report, then answer the maintainer's review. | |
+21 −0 routes/s2-ns-r3-folder-1/README.md added View file
| @@ -0,0 +1,21 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-r3-folder-1 | |
| 6 | + | |
| 7 | +Makes 17 files of the family `NavierStokes/R3` cheaper to elaborate, 45 lines out and 40 in, all inside proofs: | |
| 8 | +`nlinarith` becomes `linarith`, a `simp` argument list loses the entries that do not change the goal, a | |
| 9 | +`simpa`/`by exact` becomes the term that closes its goal, and a few small tactic rewrites. No statement, import | |
| 10 | +line or docstring changes, and there is no `maxHeartbeats`. | |
| 11 | + | |
| 12 | +The edits are those of Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03), | |
| 13 | +carried onto main at `d956c7c` and counted there file by file: instructions retired in user space by `lean` on one | |
| 14 | +file alone, before and after, against that commit. Over the 17 files the count falls from 288.70 G to 264.10 G | |
| 15 | +(−8.5%). The table and the method are in the pull request. `git diff --stat` names only these 17 files, and every | |
| 16 | +changed line is in a proof body below the `:=`. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push and open the pull request into `main`; `challenge` and `build` then decide, and the maintainer's review comes | |
| 21 | +after them. The other units of #11 are separate. | |
+18 −0 routes/s2-ns-reference-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-reference-1 | |
| 6 | + | |
| 7 | +The family `NavierStokes/Reference*` — `ReferenceBounds.lean`, `ReferenceJetBounds.lean`, | |
| 8 | +`ReferencePath.lean`. I make these three files cheaper to elaborate with proof-only edits: | |
| 9 | +`nlinarith` becomes `linarith` where the goal is linear, a `simp only` list loses the entries | |
| 10 | +that do not change the goal (19 lines out, 19 in). No statement, import or docstring changes, | |
| 11 | +and no `maxHeartbeats`. The edits are Treant's `speedup_trials` stage carried onto main at | |
| 12 | +`d956c7c`, with the per-file counts in the pull request. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Open the pull request for the unit and let the `build` check say whether the three files | |
| 17 | +elaborate. After it lands, the next unit of S-2 would be another family from | |
| 18 | +`docs/build-profile.md`'s list of ten. | |
+17 −0 routes/s2-ns-renormalized-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-renormalized-1 | |
| 6 | + | |
| 7 | +Unit 1 of S-2 for the family `NavierStokes/Renormalized*`: `NavierStokes/RenormalizedHeatMoment.lean`. | |
| 8 | +Inside four proofs only — `normalized_coordinates`, `weighted_referencePower_nonneg_radius`, | |
| 9 | +`radial_exterior_of_X_exterior` and `heated_nominal_axial_viscosity` — an argument `referencePower` drops out | |
| 10 | +of a `simp` list, a `show 2 = 1 + 1 from rfl` drops out of a `simpa only` list, and two `nlinarith` calls | |
| 11 | +become `linarith`; no statement, import or docstring changes, and no `maxHeartbeats`. The file is 2.3% cheaper | |
| 12 | +to elaborate (26.51 G to 25.91 G instructions retired, measured as PR.md says). | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Nothing; the change is made and the pull request is open. A reviewer would check that the two `linarith` calls | |
| 17 | +still close their goals in the `build` check. | |
+23 −0 routes/s2-ns-repair-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-repair-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (#11): make `NavierStokes/RepairConeBounds.lean` of the family | |
| 8 | +`NavierStokes/Repair*` cheaper to elaborate, with edits inside proofs only (6 lines out, 6 in). | |
| 9 | +In `observations_contDiffOn` the `dsimp only` list loses `observations` (an entry that does not | |
| 10 | +change the goal); in `model_margins`, `physical_transport`, `exists_repair_cone_log` and the two | |
| 11 | +`have`s of `exists_repair_cone`, `nlinarith` becomes `linarith` where linear reasoning closes the | |
| 12 | +goal. No statement, import line or docstring changes, and there is no `maxHeartbeats`. | |
| 13 | + | |
| 14 | +The edits are Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of | |
| 15 | +2026-12-03 at upstream `f9e8bc5`), carried onto main and counted there file by file: 69.90 G | |
| 16 | +before, 64.18 G after instructions retired (−8.2%), at main `d956c7c`. The file is unchanged | |
| 17 | +between `d956c7c` and this branch's base, so the count applies here; how it was taken is in the | |
| 18 | +pull request. | |
| 19 | + | |
| 20 | +## Next | |
| 21 | + | |
| 22 | +Nothing is left for this unit. Read the `build` check's verdict on the pull request; if it fails, | |
| 23 | +the failing edit is the place to look, and if the maintainer asks for more, add it here. | |
+15 −0 routes/s2-ns-reset-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-reset-1 | |
| 6 | + | |
| 7 | +S-2, the family `NavierStokes/Reset*`: one file, `NavierStokes/ResetEnergyBounds.lean`, made | |
| 8 | +cheaper to elaborate with proof-only edits (7 lines out, 7 in: six `nlinarith` calls become | |
| 9 | +`linarith`, and one `dsimp` argument list loses the entry that does not change the goal). No | |
| 10 | +statement, import line or docstring changes, and there is no `maxHeartbeats`. The file's measured | |
| 11 | +cost alone is 20.71 G → 17.58 G instructions retired (−15.1%), as the pull request says. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Open the pull request into `main`; `build` is the remaining gate (not waited on here). | |
+18 −0 routes/s2-ns-scaled-1/README.md added View file
| @@ -0,0 +1,18 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | + | |
| 6 | +# s2-ns-scaled-1 | |
| 7 | + | |
| 8 | +S-2 on the family `NavierStokes/Scaled*`: make a slow file cheaper to elaborate. This unit carries the edits of Treant's `speedup_trials` stage (TitiSkywalker/NavierStokesAndEuler, the run of 2026-12-03 at upstream `f9e8bc5`) onto main and re-counts them file by file. | |
| 9 | + | |
| 10 | +`NavierStokes/ScaledActualParticularControl.lean` is kept: 37.42 G → 30.51 G instructions retired (−18.5%), from six tactic-line edits inside proofs — four `nlinarith` steps become `linarith`, one `dsimp` list drops `H`, one `simpa only` list drops `Nat.mul_one`. Statements, imports and docstrings are untouched, and there is no `maxHeartbeats`. | |
| 11 | + | |
| 12 | +`NavierStokes/ScaledParticularFrameJets.lean` is left out, though the unit measured it at −1.6% (16.98 G → 16.71 G, all its edits together). Its first edit rewrites the statement line of `frame_normal_jets` (`:= by exact …` → `:= …`), which is not inside the proof and leaves one long, uneven declaration beside its neighbours; so the whole file stays as main has it, and its row is not in the pull request. | |
| 13 | + | |
| 14 | +Measurement: instructions retired in user space by `lean -j1 -DElab.async=false …` under `perf stat -e instructions:u`, before and after on one machine; the pull request gives the method and the agreement between runs. Nothing was measured here. | |
| 15 | + | |
| 16 | +## Next | |
| 17 | + | |
| 18 | +Push, let `challenge` and `build` run on the head, and answer the maintainer's review. | |
+15 −0 routes/s2-ns-scaling-1/README.md added View file
| @@ -0,0 +1,15 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-scaling-1 | |
| 6 | + | |
| 7 | +S-2, unit `NavierStokes/Scaling*`: `NavierStokes/Scaling.lean` made cheaper to | |
| 8 | +elaborate by two proof edits inside `reciprocal_frequency_bounds` | |
| 9 | +(`nlinarith` → `linarith`, 2 lines out, 2 in). No statement, import line or | |
| 10 | +docstring changes, and no `maxHeartbeats`. The note in the pull request gives | |
| 11 | +the instruction counts before and after and how they were taken. | |
| 12 | + | |
| 13 | +## Next | |
| 14 | + | |
| 15 | +Push, let `challenge` and `build` run, and reply to the maintainer's review. | |
+23 −0 routes/s2-ns-shaped-1/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-shaped-1 | |
| 6 | + | |
| 7 | +One unit of S-2 (issue #11), on the family `NavierStokes/Shaped*`: one file, | |
| 8 | +`NavierStokes/ShapedWaitBounds.lean`, made cheaper to elaborate. The edits are | |
| 9 | +inside proofs only (25 lines out, 25 in): `nlinarith` becomes `linarith`, and | |
| 10 | +several `simp only` argument lists lose entries that do not change the goal. | |
| 11 | +No statement, import line or docstring changes, and there is no | |
| 12 | +`maxHeartbeats`. The edits are Treant's `speedup_trials` edits | |
| 13 | +(TitiSkywalker/NavierStokesAndEuler, run of 2026-12-03 at upstream `f9e8bc5`), | |
| 14 | +carried onto main at `d956c7c` and counted there: 187.90 G to 149.17 G | |
| 15 | +instructions retired, −20.6%. The count and how it was taken are in the pull | |
| 16 | +request's description. | |
| 17 | + | |
| 18 | +## Next | |
| 19 | + | |
| 20 | +Push, let the `challenge` and `build` checks run, and reply to the maintainer's | |
| 21 | +review. If `build` rejects one of the `linarith` or `simp only` lines, restore | |
| 22 | +that line's original form, re-count the file and report the new number in the | |
| 23 | +description. | |
+13 −0 routes/s2-ns-squared-1/README.md added View file
| @@ -0,0 +1,13 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-squared-1 | |
| 6 | + | |
| 7 | +Unit of S-2 (issue #11): make one of the slowest-elaborating files cheaper to elaborate, without changing a statement and without a `maxHeartbeats`. | |
| 8 | + | |
| 9 | +The file is `NavierStokes/SquaredPartition.lean`, of the family `NavierStokes/Squared*`. The change is three edits inside proofs only: a `simp only` argument list drops the one entry that does not change the goal, and two `nlinarith` calls become `linarith`. The measured cost is 21.82 G → 20.62 G instructions retired (−5.5%), counted as the pull request's description says; no statement, import line or docstring changes. | |
| 10 | + | |
| 11 | +## Next | |
| 12 | + | |
| 13 | +Push, let `challenge` and `build` report, and reply to the maintainer's review. If `build` rejects an edit, drop that file from the pull request (its numbers belong to all three edits), take its row out of the table and say so. | |
+17 −0 routes/s2-ns-transition-1/README.md added View file
| @@ -0,0 +1,17 @@ | ||
| 1 | +--- | |
| 2 | +issue: 11 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# s2-ns-transition-1 | |
| 6 | + | |
| 7 | +S-2, unit `s2-ns-transition-1`: the family `NavierStokes/Transition*`, one file, | |
| 8 | +`NavierStokes/TransitionRamp.lean`. Ten `nlinarith` calls whose goals are linear in the atoms | |
| 9 | +their hypotheses already bound become `linarith`; every edit is inside a proof, below the `:=` | |
| 10 | +of its declaration, and no statement, import line or docstring changes. There is no | |
| 11 | +`maxHeartbeats`. The file is measured cheaper to elaborate (68.28 G → 60.64 G instructions | |
| 12 | +retired in user space, −11.2%); the pull request gives the numbers and how they were taken. | |
| 13 | + | |
| 14 | +## Next | |
| 15 | + | |
| 16 | +Push, let `challenge` and `build` report on the pull request, and reply to the maintainer's | |
| 17 | +review. Nothing else is planned on this branch. | |