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

| 1 | import NavierStokes.GenericJetRateAlgebra |
| 2 | |
| 3 | noncomputable section |
| 4 | |
| 5 | namespace NavierStokes.GenericDifferentialPolynomial |
| 6 | |
| 7 | open Set Filter DiagonalResidual |
| 8 | open scoped Topology ContDiff |
| 9 | |
| 10 | variable {D : Type*} [NormedAddCommGroup D] [NormedSpace ℝ D] |
| 11 | |
| 12 | /-- Quantitative approximation data. Constants may depend on the stage, while |
| 13 | the power losses and derivative thresholds are fixed functions of the jet order. -/ |
| 14 | structure ApproximationRates (l : Filter D) (q : D → ℝ) (gain : ℕ → ℝ) |
| 15 | (f : D → ℝ) (stage : ℕ → D → ℝ) where |
| 16 | growthLoss : ℕ → ℝ |
| 17 | tailLoss : ℕ → ℝ |
| 18 | threshold : ℕ → ℕ |
| 19 | stage_growth : ∀ J m, JetRate l q (stage J) m (-growthLoss m) |
| 20 | tail_rate : ∀ m J, threshold m ≤ J → |
| 21 | JetRate l q (fun x => f x - stage J x) m (gain J - tailLoss m) |
| 22 | |
| 23 | private def maxThreshold (M : ℕ → ℕ) (m : ℕ) : ℕ := |
| 24 | (Finset.range (m + 1)).sup M |
| 25 | |
| 26 | private theorem le_maxThreshold (M : ℕ → ℕ) {k m : ℕ} (hk : k ≤ m) : |
| 27 | M k ≤ maxThreshold M m := |
| 28 | Finset.le_sup (f := M) (Finset.mem_range.mpr (Nat.lt_succ_of_le hk)) |
| 29 | |
| 30 | variable {l : Filter D} {q : D → ℝ} {gain : ℕ → ℝ} {U : Set D} |
| 31 | variable {f g : D → ℝ} {fs gs : ℕ → D → ℝ} |
| 32 | |
| 33 | /-- A finite differential expression in scalar components with fixed variable |
| 34 | coefficients. Products, sums, and arbitrary fixed directional derivatives are |
| 35 | allowed at every node; consequently the order and polynomial degree are finite. -/ |
| 36 | inductive Expression (D ι κ : Type*) where |
| 37 | | input : ι → Expression D ι κ |
| 38 | | coeff : κ → Expression D ι κ |
| 39 | | add : Expression D ι κ → Expression D ι κ → Expression D ι κ |
| 40 | | mul : Expression D ι κ → Expression D ι κ → Expression D ι κ |
| 41 | | directional : D → Expression D ι κ → Expression D ι κ |
| 42 | |
| 43 | namespace Expression |
| 44 | |
| 45 | variable {ι κ : Type*} |
| 46 | |
| 47 | /-- Evaluation uses actual Fréchet derivatives, including at derivative nodes. -/ |
| 48 | def eval (c : κ → D → ℝ) (u : ι → D → ℝ) : Expression D ι κ → D → ℝ |
| 49 | | .input i => u i |
| 50 | | .coeff i => c i |
| 51 | | .add a b => fun x => eval c u a x + eval c u b x |
| 52 | | .mul a b => fun x => eval c u a x * eval c u b x |
| 53 | | .directional v a => fun x => fderiv ℝ (eval c u a) x v |
| 54 | |
| 55 | end Expression |
| 56 | |
| 57 | end NavierStokes.GenericDifferentialPolynomial |