Eqs. (13.2.21)–(13.2.22) — The integral candidate solves the free-boundary system
ProvedPeskirShiryaev.Maximality.boundary_ode_equivalenceLet be continuous real coefficients, with , and let be continuously differentiable with . Define . Then solves the generator equation for , normal reflection at , instantaneous stopping at , and smooth fit at , if and only if
This identifies the ODE constraint on an analytic free boundary, independently of stochastic optimality.
Formalization Note Boundary derivatives are inward derivatives; the formula for has an analytic extension beyond the continuation region. The stochastic process is unnecessary for this deterministic equivalence.
import Definitions.Def_PeskirShiryaev_Maximality_Boundary
/- Imported declaration context (verbatim, for a self-contained blind code audit):
structure Coefficients where
drift : ℝ → ℝ
volatility : ℝ → ℝ
cost : ℝ → ℝ
drift_continuous : Continuous drift
volatility_continuous : Continuous volatility
volatility_pos : ∀ x, 0 < volatility x
cost_continuous : Continuous cost
cost_pos : ∀ x, 0 < cost x
noncomputable def itoSum {Ω : Type*} (σ : ℝ → ℝ)
(X B : ℝ≥0 → Ω → ℝ) (t : ℝ≥0) (n : ℕ) (ω : Ω) : ℝ :=
∑ k ∈ Finset.range (2 ^ n),
σ (X (t * (k : ℝ≥0) / (2 ^ n : ℝ≥0)) ω) *
(B (t * ((k + 1 : ℕ) : ℝ≥0) / (2 ^ n : ℝ≥0)) ω -
B (t * (k : ℝ≥0) / (2 ^ n : ℝ≥0)) ω)
/-- A nonexplosive weak solution on R. The stochastic integral is specified by
its defining left dyadic sums in probability, not by an unconstrained integral oracle. -/
structure Diffusion {Ω : Type*} [MeasurableSpace Ω] (p : Coefficients)
(P : Measure Ω) (X : ℝ≥0 → Ω → ℝ) (x : ℝ) : Prop where
probability : IsProbabilityMeasure P
measurable : ∀ t, Measurable (X t)
continuous : ∀ ω, Continuous (fun t => X t ω)
initial : ∀ᵐ ω ∂P, X 0 ω = x
weak_solution : ∃ (ℱ : Filtration ℝ≥0 ‹MeasurableSpace Ω›) (B : ℝ≥0 → Ω → ℝ),
Adapted ℱ X ∧ Adapted ℱ B ∧ IsBrownianReal B P ∧
(∀ s t : ℝ≥0, s ≤ t →
Indep (MeasurableSpace.comap (fun ω => B t ω - B s ω) inferInstance) (ℱ s) P) ∧
∀ t : ℝ≥0, TendstoInMeasure P (itoSum p.volatility X B t) atTop
(fun ω => X t ω - x -
∫ r in (0 : ℝ)..(t : ℝ), p.drift (X r.toNNReal ω))
/-- Right-continuous natural past, augmented by ambient measurable null sets. -/
noncomputable def naturalPast {Ω : Type*} [MeasurableSpace Ω]
(P : Measure Ω) (X : ℝ≥0 → Ω → ℝ) (t : ℝ≥0) : MeasurableSpace Ω :=
⨅ u : ℝ≥0, ⨅ (_ : t < u),
((⨆ r : ℝ≥0, ⨆ (_ : r ≤ u), MeasurableSpace.comap (X r) inferInstance) ⊔
MeasurableSpace.generateFrom {N : Set Ω | MeasurableSet N ∧ P N = 0})
/-- The book's Markov times; a stopping time must additionally be finite a.s. -/
def IsMarkovTime {Ω : Type*} [MeasurableSpace Ω]
(P : Measure Ω) (X : ℝ≥0 → Ω → ℝ) (τ : Ω → ℝ≥0∞) : Prop :=
Measurable τ ∧ ∀ t : ℝ≥0, MeasurableSet[naturalPast P X t] {ω | τ ω ≤ (t : ℝ≥0∞)}
noncomputable def scaleDensity (p : Coefficients) (y : ℝ) : ℝ :=
Real.exp (- ∫ z in (0 : ℝ)..y, 2 * p.drift z / p.volatility z ^ 2)
noncomputable def scale (p : Coefficients) (x : ℝ) : ℝ :=
∫ y in (0 : ℝ)..x, scaleDensity p y
noncomputable def speedDensity (p : Coefficients) (x : ℝ) : ℝ :=
2 / (scaleDensity p x * p.volatility x ^ 2)
noncomputable def speed (p : Coefficients) : Measure ℝ :=
volume.withDensity (fun y => ENNReal.ofReal (speedDensity p y))
noncomputable def green (p : Coefficients) (a b x y : ℝ) : ℝ :=
if y ≤ x then (scale p b - scale p x) * (scale p y - scale p a) /
(scale p b - scale p a)
else (scale p b - scale p y) * (scale p x - scale p a) /
(scale p b - scale p a)
noncomputable def odeRhs (p : Coefficients) (s y : ℝ) : ℝ :=
p.volatility y ^ 2 * scaleDensity p y /
(2 * p.cost y * (scale p s - scale p y))
/-- Global C1 solutions strictly below the diagonal; no optimality is assumed. -/
def AdmissibleBoundary (p : Coefficients) (g : ℝ → ℝ) : Prop :=
ContDiff ℝ 1 g ∧ ∀ s, g s < s ∧ HasDerivAt g (odeRhs p s (g s)) s
def MaximalBoundary (p : Coefficients) (g : ℝ → ℝ) : Prop :=
AdmissibleBoundary p g ∧ ∀ h, AdmissibleBoundary p h → ∀ s, h s ≤ g s
/-- The analytic expression, extended to either side of its lower integration limit. -/
noncomputable def integralCandidate (p : Coefficients) (g : ℝ → ℝ) (x s : ℝ) : ℝ :=
s + ∫ y in g s..x, (scale p x - scale p y) * p.cost y * speedDensity p y
noncomputable def candidate (p : Coefficients) (g : ℝ → ℝ) (x s : ℝ) : ℝ :=
if x ≤ g s then s else integralCandidate p g x s
/-- Equations (13.2.9)--(13.2.12), with inward derivatives at the two boundaries. -/
def FreeBoundarySystem (p : Coefficients) (g : ℝ → ℝ) : Prop :=
(∀ s x, g s < x → x < s →
p.drift x * deriv (fun z => integralCandidate p g z s) x +
p.volatility x ^ 2 / 2 * deriv (deriv (fun z => integralCandidate p g z s)) x =
p.cost x) ∧
(∀ s, HasDerivWithinAt (fun u => integralCandidate p g s u) 0 (Set.Ici s) s) ∧
(∀ s, integralCandidate p g (g s) s = s) ∧
(∀ s, HasDerivWithinAt (fun x => integralCandidate p g x s) 0 (Set.Ici (g s)) (g s))
/-- A solution up to its first diagonal contact, extended by the diagonal afterwards. -/
def DiagonalBoundary (p : Coefficients) (g : ℝ → ℝ) (d : ℝ) : Prop :=
Continuous g ∧
(∀ s, s < d → g s < s ∧ HasDerivAt g (odeRhs p s (g s)) s) ∧
∀ s, d ≤ s → g s = s
-/
namespace PeskirShiryaev.Maximality
theorem boundary_ode_equivalence (p : Coefficients) (g : ℝ → ℝ)
(hg : ContDiff ℝ 1 g) (hbelow : ∀ s, g s < s) :
FreeBoundarySystem p g ↔ AdmissibleBoundary p g := by sorry
end PeskirShiryaev.Maximality
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Data. Let be a coefficient triple: continuous on with and everywhere. Define
with oriented integrals. Let be continuously differentiable on , with for every . These two properties are the hypotheses. Set
Claim. The following two conditions are equivalent; the statement claims both directions.
(A) The four free-boundary conditions hold:
- For all and all with :
Derivatives are the library's derivative, which equals wherever the function fails to be differentiable. This applies both to and to its first-derivative function. 2. For every , the map has right derivative at . In this map the first argument is held at the number and the second varies over . 3. For every , . This holds automatically, since the integral is over a degenerate interval. 4. For every , the map has right derivative at , relative to .
(B) is an admissible boundary. That is, is , and for every , and is differentiable at with
Degenerate cases.
- The ODE denominator. Because is assumed and is strictly increasing, the denominator in (B) is strictly positive. The division-by-zero convention never applies there.
- Condition 1 is never vacuous. The interval is nonempty for every .
- What (B) actually adds. Given the hypotheses, the and parts of (B) are already assumed. So (B) contributes only the pointwise ODE.
- Derivative conventions in (A). At points where or its derivative is not differentiable, condition 1 is evaluated with the value substituted for the missing derivative.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.