Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lyapunov stability condition: JJJ decreases along optimal prices when λjej<32mvivi\lambda^je_j<\frac32 mv^iv_iλjej​<23​mvivi​

Proved
LindgrenPriceDynamics.lyapunov_stability_condition

by LG · Sep 30, 2026 · Mathlib 0df444a (Lean v4.33.1)

dynamic-programminggeneral-equilibriumhamilton-jacobi-bellmanlyapunov-stability

Let m>0m>0m>0, weights λj\lambda_jλj​, expenditure functions eje_jej​, and let J(s,p)J(s,p)J(s,p) be continuously differentiable and solve the time-inverted HJB equation

∂J∂s=−12m⟨∇J,∇J⟩+λjej.\frac{\partial J}{\partial s}=-\frac1{2m}\langle\nabla J,\nabla J\rangle+\lambda^je_j .∂s∂J​=−2m1​⟨∇J,∇J⟩+λjej​.

Let the price path satisfy p˙(s)=v(s):=−1m∇J(s,p(s))\dot p(s)=v(s):=-\frac1m\nabla J(s,p(s))p˙​(s)=v(s):=−m1​∇J(s,p(s)) for all sss. Suppose that on an interval [t,T][t,T][t,T] price adjustments are large enough:

∑j=1nλjej(p(s))<32 m ⟨v(s),v(s)⟩for all s∈[t,T].\sum_{j=1}^n\lambda_je_j(p(s))<\tfrac32\,m\,\langle v(s),v(s)\rangle\qquad\text{for all } s\in[t,T].j=1∑n​λj​ej​(p(s))<23​m⟨v(s),v(s)⟩for all s∈[t,T].

Then:

  1. s↦J(s,p(s))s\mapsto J(s,p(s))s↦J(s,p(s)) is strictly decreasing on [t,T][t,T][t,T];
  2. if in addition J(T,p(T))=0J(T,p(T))=0J(T,p(T))=0 (the value function vanishes at the equilibrium time TTT), then J(s,p(s))>0J(s,p(s))>0J(s,p(s))>0 for all s∈[t,T)s\in[t,T)s∈[t,T).

This is the paper's conclusion that the value function acts as a Lyapunov function, and the equilibrium is approached, as long as the squared price velocity is large compared with aggregate expenditure.

Formalization Note The paper's informal notion of 'stability' is rendered as strict decrease of JJJ along the optimal path together with positivity before the terminal time; the HJB equation and the optimal feedback law are hypotheses.

Preamble
import Mathlib
import Definitions.Def_LindgrenPriceDynamics
Formal statement
namespace LindgrenPriceDynamics

/-- Section 3 (Lyapunov stability, eq. (19) and the following paragraph): under the
hypotheses of eq. (19), if on `[t, T]` the price velocity is large enough,
`λ^j e_j < (3/2) m v^i v_i`, then the value function `J` is strictly decreasing along the
optimal price path on `[t, T]`; and if moreover `J` vanishes at the equilibrium time `T`,
it is strictly positive on `[t, T)`. -/
theorem lyapunov_stability_condition {n l : ℕ} (m : ℝ) (hm : 0 < m) (lam : Fin n → ℝ)
    (e : Fin n → (Fin l → ℝ) → ℝ) (J : ℝ → (Fin l → ℝ) → ℝ)
    (hJ : ContDiff ℝ 1 (fun x : ℝ × (Fin l → ℝ) => J x.1 x.2))
    (hHJB : ∀ s p, timePartial J s p =
      -(dot (priceGrad (J s) p) (priceGrad (J s) p)) / (2 * m) + aggregateExpenditure lam e p)
    (p : ℝ → Fin l → ℝ) (hp : ∀ s, HasDerivAt p (optimalVelocity m J s (p s)) s)
    (t T : ℝ)
    (hlarge : ∀ s ∈ Set.Icc t T, aggregateExpenditure lam e (p s)
      < (3 / 2) * m * dot (optimalVelocity m J s (p s)) (optimalVelocity m J s (p s))) :
    StrictAntiOn (fun s => J s (p s)) (Set.Icc t T) ∧
      (J T (p T) = 0 → ∀ s ∈ Set.Ico t T, 0 < J s (p s)) := by
  sorry

end LindgrenPriceDynamics
Source
J. Lindgren, General Equilibrium with Price Adjustments — A Dynamic Programming Approach, Analytics 2022, 1, 27–34, https://doi.org/10.3390/analytics1010003, pp. 31–32, Section 3 'Conditions for Lyapunov Stability of the Economy', eq. (19) and the following paragraph
Read-back

What the Lean code literally says, in plain math · Aristotle (Harmonic) — non-blind, same agent as drafter

Non-blind read-back. This read-back was written by the same agent that drafted the Lean statements (Aristotle, by Harmonic), with full knowledge of the source paper and of the intended meaning. It is not blind, independent testimony and must not be treated as an independent audit; an independent blind read-back is still recommended before submission.

Let n,l∈Nn,l\in\mathbb Nn,l∈N, m>0m>0m>0, arbitrary real weights λj\lambda_jλj​ and arbitrary functions ej:Rl→Re_j:\mathbb R^l\to\mathbb Rej​:Rl→R, and J:R×Rl→RJ:\mathbb R\times\mathbb R^l\to\mathbb RJ:R×Rl→R that is C1C^1C1 jointly. Write E=∑jλjejE=\sum_j\lambda_je_jE=∑j​λj​ej​ and g=∇pJg=\nabla_pJg=∇p​J.

Hypotheses:

  1. (inverted HJB) for all s,ps,ps,p: ∂sJ(s,p)=−12m∑igi(s,p)2+E(p)\partial_sJ(s,p)=-\frac1{2m}\sum_ig_i(s,p)^2+E(p)∂s​J(s,p)=−2m1​∑i​gi​(s,p)2+E(p);
  2. p:R→Rlp:\mathbb R\to\mathbb R^lp:R→Rl has, at every s∈Rs\in\mathbb Rs∈R, derivative v(s)v(s)v(s) with vi(s)=−1mgi(s,p(s))v_i(s)=-\frac1m g_i(s,p(s))vi​(s)=−m1​gi​(s,p(s));
  3. t,Tt,Tt,T are arbitrary reals (no order assumed), and for every sss with t≤s≤Tt\le s\le Tt≤s≤T: E(p(s))<32m∑ivi(s)2E(p(s))<\frac32 m\sum_iv_i(s)^2E(p(s))<23​m∑i​vi​(s)2.

Conclusion (both parts):

  1. for all a,b∈[t,T]a,b\in[t,T]a,b∈[t,T] with a<ba<ba<b: J(b,p(b))<J(a,p(a))J(b,p(b))<J(a,p(a))J(b,p(b))<J(a,p(a));
  2. if J(T,p(T))=0J(T,p(T))=0J(T,p(T))=0, then J(s,p(s))>0J(s,p(s))>0J(s,p(s))>0 for all sss with t≤s<Tt\le s<Tt≤s<T.

Edge cases: if t>Tt>Tt>T the interval is empty and both conclusions hold trivially; if t=Tt=Tt=T part 1 is trivial and part 2 is vacuous. The hypotheses are global in sss and ppp except the large-velocity condition, which is only required on [t,T][t,T][t,T].

Human review
  • Endorsed by Shuze Chen · Sep 30, 2026

    Confirmed by the moderator at approval.

  • Endorsed by LG · Sep 30, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me