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 | /- |
| 2 | Copyright 2026 The Formal Conjectures Authors. |
| 3 | |
| 4 | This file has been modified from its original form in the Formal Conjectures |
| 5 | project. |
| 6 | |
| 7 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 8 | you may not use this file except in compliance with the License. |
| 9 | You may obtain a copy of the License at |
| 10 | |
| 11 | https://www.apache.org/licenses/LICENSE-2.0 |
| 12 | |
| 13 | Unless required by applicable law or agreed to in writing, software |
| 14 | distributed under the License is distributed on an "AS IS" BASIS, |
| 15 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 16 | See the License for the specific language governing permissions and |
| 17 | limitations under the License. |
| 18 | -/ |
| 19 | |
| 20 | import Mathlib |
| 21 | |
| 22 | /-! |
| 23 | # Solution-side definitions for the Euler Comparator challenge |
| 24 | |
| 25 | Adapted from `FormalConjectures/Millenium/NavierStokes.lean` at |
| 26 | https://github.com/google-deepmind/formal-conjectures/blob/8323e878b83fcd7f4a448256069352a265460d75/FormalConjectures/Millenium/NavierStokes.lean |
| 27 | |
| 28 | This is the whole-space breakdown alternative specialized to zero viscosity |
| 29 | and zero external force. It retains the source's initial-data decay, joint |
| 30 | smoothness, square integrability, and uniform energy conditions. Velocity and |
| 31 | pressure take position before time. The time derivative at zero is taken |
| 32 | within `[0,∞)`. |
| 33 | |
| 34 | These definitions reproduce the independent reference exactly. This module |
| 35 | contains no challenge theorem or proof placeholder and does not import `Euler`. |
| 36 | -/ |
| 37 | |
| 38 | |
| 39 | -- Inline the only needed notation from FormalConjecturesForMathlib.Geometry.3d. |
| 40 | local notation "ℝ³" => EuclideanSpace ℝ (Fin 3) |
| 41 | |
| 42 | open ContDiff Set InnerProductSpace MeasureTheory |
| 43 | |
| 44 | namespace Euler |
| 45 | |
| 46 | /-- The divergence of a vector field, computed as the trace of its derivative. -/ |
| 47 | noncomputable def divergence (v : ℝ³ → ℝ³) (x : ℝ³) : ℝ := |
| 48 | (fderiv ℝ v x).trace ℝ ℝ³ |
| 49 | |
| 50 | local notation "∇⬝" => divergence |
| 51 | |
| 52 | /-- Smooth, divergence-free initial velocity. -/ |
| 53 | structure InitialVelocityCondition (u₀ : ℝ³ → ℝ³) : Prop where |
| 54 | div_free : ∀ x, ∇⬝ u₀ x = 0 |
| 55 | smooth : ContDiff ℝ ∞ u₀ |
| 56 | |
| 57 | /-- Every spatial derivative of the initial velocity decays faster than any polynomial. -/ |
| 58 | structure InitialVelocityConditionDecay (u₀ : ℝ³ → ℝ³) : Prop extends |
| 59 | InitialVelocityCondition u₀ where |
| 60 | decay : ∀ m : ℕ, ∀ K : ℝ, ∃ C : ℝ, ∀ x, |
| 61 | ‖iteratedFDeriv ℝ m u₀ x‖ ≤ C / (1 + ‖x‖) ^ K |
| 62 | |
| 63 | /-- A global smooth solution of unforced incompressible Euler on ℝ³. -/ |
| 64 | structure EulerExistenceAndSmoothness |
| 65 | (u₀ : ℝ³ → ℝ³) (v : ℝ³ → ℝ → ℝ³) (p : ℝ³ → ℝ → ℝ) : Prop where |
| 66 | /-- `∂ₜv + (v · ∇)v = -∇p`: viscosity and external force are both zero. -/ |
| 67 | euler : ∀ x, ∀ t ≥ 0, |
| 68 | derivWithin (v x ·) (Set.Ici 0) t + fderiv ℝ (v · t) x (v x t) = |
| 69 | -gradient (p · t) x |
| 70 | div_free : ∀ x, ∀ t ≥ 0, ∇⬝ (v · t) x = 0 |
| 71 | initial_condition : ∀ x, v x 0 = u₀ x |
| 72 | velocity_smooth : ContDiffOn ℝ ∞ (Function.uncurry v) (Set.univ ×ˢ Set.Ici 0) |
| 73 | pressure_smooth : ContDiffOn ℝ ∞ (Function.uncurry p) (Set.univ ×ˢ Set.Ici 0) |
| 74 | |
| 75 | /-- The whole-space solution class, retaining the source's finite, uniformly bounded energy. -/ |
| 76 | structure EulerExistenceAndSmoothnessR3 |
| 77 | (u₀ : ℝ³ → ℝ³) (v : ℝ³ → ℝ → ℝ³) (p : ℝ³ → ℝ → ℝ) : Prop |
| 78 | extends EulerExistenceAndSmoothness u₀ v p where |
| 79 | integrable : ∀ t ≥ 0, MemLp (‖v · t‖) 2 |
| 80 | globally_bounded_energy : ∃ E : ℝ, ∀ t ≥ 0, (∫ x : ℝ³, ‖v x t‖ ^ 2) < E |
| 81 | |
| 82 | open scoped ENNReal Topology |
| 83 | |
| 84 | /-- The L² equivalence class of a square-integrable function. The fallback makes |
| 85 | this a total function; the solution conditions require square integrability |
| 86 | wherever it is used. -/ |
| 87 | noncomputable def toL2 {V : Type*} [NormedAddCommGroup V] (f : ℝ³ → V) : |
| 88 | Lp V 2 (volume : Measure ℝ³) := by |
| 89 | classical |
| 90 | exact if h : MemLp f 2 volume then h.toLp f else 0 |
| 91 | |
| 92 | /-- A spatially smooth path whose actual spatial derivative tensors belong to L² |
| 93 | and depend continuously on time in L², at every finite order. -/ |
| 94 | structure SobolevSmoothOn (I : Set ℝ) (v : ℝ³ → ℝ → ℝ³) : Prop where |
| 95 | spatial_smooth : ∀ t ∈ I, ContDiff ℝ ∞ (v · t) |
| 96 | integrable : ∀ t ∈ I, MemLp (v · t) 2 |
| 97 | jets_integrable : ∀ m : ℕ, ∀ t ∈ I, MemLp (iteratedFDeriv ℝ m (v · t)) 2 |
| 98 | continuous : ContinuousOn (fun t => toL2 (v · t)) I |
| 99 | jets_continuous : ∀ m : ℕ, |
| 100 | ContinuousOn (fun t => toL2 (iteratedFDeriv ℝ m (v · t))) I |
| 101 | |
| 102 | /-- Scalar-pressure Euler on a time set `I` in the original theorem's smooth |
| 103 | Sobolev class. The velocity and its strong time derivative have continuous L² |
| 104 | spatial jets of every order. The Euler equation uses this derivative witness. |
| 105 | |
| 106 | As in `IsSmoothScalarEuler`, the time law and scalar-pressure equation are |
| 107 | required at interior times. There is no endpoint derivative condition. We use |
| 108 | `Ico 0 T` for a maximal lifespan and `Icc 0 T` for a closed interval. -/ |
| 109 | structure EulerSobolevExistenceAndSmoothnessR3On (I : Set ℝ) |
| 110 | (u₀ : ℝ³ → ℝ³) (v : ℝ³ → ℝ → ℝ³) (p : ℝ³ → ℝ → ℝ) : Prop where |
| 111 | div_free : ∀ x, ∀ t ∈ I, ∇⬝ (v · t) x = 0 |
| 112 | initial_condition : ∀ x, v x 0 = u₀ x |
| 113 | velocity_smooth : SobolevSmoothOn I v |
| 114 | pressure_differentiable : ∀ t ∈ interior I, Differentiable ℝ (p · t) |
| 115 | euler : ∃ w : ℝ³ → ℝ → ℝ³, |
| 116 | SobolevSmoothOn I w ∧ |
| 117 | (∀ t ∈ interior I, |
| 118 | HasDerivAt (fun s => toL2 (v · s)) (toL2 (w · t)) t) ∧ |
| 119 | (∀ x, ∀ t ∈ interior I, |
| 120 | w x t + fderiv ℝ (v · t) x (v x t) = -gradient (p · t) x) |
| 121 | |
| 122 | /-- The ordinary curl of a velocity field, expressed through its spatial derivative. |
| 123 | Indices in `Fin 3` are cyclic. -/ |
| 124 | noncomputable def vorticity (v : ℝ³ → ℝ³) (x : ℝ³) : ℝ³ := |
| 125 | WithLp.toLp 2 (fun i : Fin 3 => |
| 126 | (fderiv ℝ v x (EuclideanSpace.single (i + 1) 1)) (i + 2) - |
| 127 | (fderiv ℝ v x (EuclideanSpace.single (i + 2) 1)) (i + 1)) |
| 128 | |
| 129 | /-- The sum of the spatial suprema of the velocity norm and derivative operator norm. -/ |
| 130 | noncomputable def velocityC1Norm (v : ℝ³ → ℝ³) : ℝ≥0∞ := |
| 131 | (⨆ x, ENNReal.ofReal ‖v x‖) + (⨆ x, ENNReal.ofReal ‖fderiv ℝ v x‖) |
| 132 | |
| 133 | /-- The spatial supremum of the Euclidean norm of the actual vorticity. -/ |
| 134 | noncomputable def vorticityNorm (v : ℝ³ → ℝ³) : ℝ≥0∞ := |
| 135 | ⨆ x, ENNReal.ofReal ‖vorticity v x‖ |
| 136 | |
| 137 | |
| 138 | end Euler |