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 Euler.FiniteGradeSupport |
| 2 | |
| 3 | /-! Reindexing the literal primary/corrector packet into its actual power coefficients. -/ |
| 4 | |
| 5 | noncomputable section |
| 6 | |
| 7 | namespace EulerFiniteGrades |
| 8 | |
| 9 | open Finset |
| 10 | |
| 11 | variable {V : Type*} [AddCommGroup V] [Module ℝ V] |
| 12 | |
| 13 | def shiftUp (M : ℕ) (u : ℕ → V) : ℕ → V |
| 14 | | 0 => 0 |
| 15 | | n+1 => truncate M u n |
| 16 | |
| 17 | def assemble (M : ℕ) (u c : ℕ → V) (n : ℕ) : V := |
| 18 | truncate M u n + shiftUp M c n |
| 19 | |
| 20 | theorem evaluate_shiftUp (M : ℕ) (κ : ℝ) (u : ℕ → V) : |
| 21 | evaluate (M+1) κ (shiftUp M u) = κ • evaluate M κ u := by |
| 22 | unfold evaluate |
| 23 | rw [sum_range_succ'] |
| 24 | simp only [shiftUp, smul_zero, add_zero, smul_sum, smul_smul] |
| 25 | apply sum_congr rfl |
| 26 | intro i hi |
| 27 | rw [truncate_of_le M i u (by have h := mem_range.mp hi; omega), pow_succ'] |
| 28 | |
| 29 | theorem evaluate_assemble (M : ℕ) (κ : ℝ) (u c : ℕ → V) : |
| 30 | evaluate (M+1) κ (assemble M u c) = evaluate M κ u + κ • evaluate M κ c := by |
| 31 | change evaluate (M+1) κ (fun n => truncate M u n+shiftUp M c n) = _ |
| 32 | rw [evaluate_add, evaluate_shiftUp, evaluate_truncate_extend M (M+1) (by omega)] |
| 33 | |
| 34 | theorem evaluate_from_one (M : ℕ) (κ : ℝ) (u : ℕ → V) (hu : u 0=0) : |
| 35 | evaluate M κ u = ∑ i ∈ range M, κ^(i+1) • u (i+1) := by |
| 36 | unfold evaluate |
| 37 | rw [sum_range_succ'] |
| 38 | simp only [hu, smul_zero, add_zero] |
| 39 | |
| 40 | /-- Equation (13), with the extra final corrector retained rather than dropped. -/ |
| 41 | theorem evaluate_assemble_from_one (M : ℕ) (κ : ℝ) (u c : ℕ → V) |
| 42 | (hu : u 0=0) (hc : c 0=0) : |
| 43 | evaluate (M+1) κ (assemble M u c) = |
| 44 | ∑ i ∈ range M, (κ^(i+1) • u (i+1) + κ^(i+2) • c (i+1)) := by |
| 45 | rw [evaluate_assemble, evaluate_from_one M κ u hu, evaluate_from_one M κ c hc, |
| 46 | smul_sum, ← sum_add_distrib] |
| 47 | apply sum_congr rfl |
| 48 | intro i _ |
| 49 | simp only [smul_smul, show i+2=(i+1)+1 by omega, pow_succ'] |
| 50 | |
| 51 | omit [Module ℝ V] in |
| 52 | theorem assemble_zero (M : ℕ) (u c : ℕ → V) (hu : u 0=0) : |
| 53 | assemble M u c 0 = 0 := by |
| 54 | simp [assemble, shiftUp, hu] |
| 55 | |
| 56 | omit [Module ℝ V] in |
| 57 | theorem assemble_interior (M n : ℕ) (hn : 1 ≤ n) (hMn : n ≤ M) (u c : ℕ → V) : |
| 58 | assemble M u c n = u n+c (n-1) := by |
| 59 | obtain ⟨j, rfl⟩ := Nat.exists_eq_succ_of_ne_zero (by omega : n ≠ 0) |
| 60 | simp only [Nat.succ_eq_add_one, assemble, shiftUp, truncate_of_le M (j+1) u hMn, |
| 61 | truncate_of_le M j c (by omega), Nat.add_sub_cancel] |
| 62 | |
| 63 | omit [Module ℝ V] in |
| 64 | theorem assemble_last (M : ℕ) (u c : ℕ → V) : |
| 65 | assemble M u c (M+1) = c M := by |
| 66 | simp only [assemble, shiftUp, truncate_of_gt M (M+1) u (by omega), |
| 67 | truncate_of_le M M c le_rfl, zero_add] |
| 68 | |
| 69 | omit [Module ℝ V] in |
| 70 | theorem assemble_above (M n : ℕ) (hn : M+1 < n) (u c : ℕ → V) : |
| 71 | assemble M u c n = 0 := by |
| 72 | obtain ⟨j, rfl⟩ := Nat.exists_eq_succ_of_ne_zero (by omega : n ≠ 0) |
| 73 | simp only [assemble, shiftUp, truncate_of_gt M (j+1) u (by omega), |
| 74 | truncate_of_gt M j c (by omega), add_zero] |
| 75 | |
| 76 | end EulerFiniteGrades |