Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 4.2 — exp-concavity via the Hessian

Disproved
OnlineConvexOpt.SecondOrder.exp_concave_iff_hessian

by mikedeng1 · Sep 19, 2026 · Mathlib 0df444a (Lean v4.33.1)

exp-concavityhessianonline-convex-optimization

This is the Hessian characterization of pointwise exp-concavity referenced in the definitions above. Let f:E→Rf : E \to \mathbb{R}f:E→R be twice differentiable at a point xxx of a real inner-product space EEE, and let α>0\alpha > 0α>0. Then fff is α\alphaα-exp-concave at xxx — i.e. g(y)=e−αf(y)g(y) = e^{-\alpha f(y)}g(y)=e−αf(y) is concave to second order at xxx — if and only if

∇2f(x)⪰α ∇f(x) ∇f(x)⊤,\nabla^2 f(x) \succeq \alpha\, \nabla f(x)\, \nabla f(x)^\top ,∇2f(x)⪰α∇f(x)∇f(x)⊤,

meaning that for every direction v∈Ev \in Ev∈E,

v⊤∇2f(x) v  ≥  α(∇f(x)⊤v)2.v^\top \nabla^2 f(x)\, v \;\ge\; \alpha \bigl(\nabla f(x)^\top v\bigr)^2 .v⊤∇2f(x)v≥α(∇f(x)⊤v)2.

Since ∇f(x)∇f(x)⊤\nabla f(x)\nabla f(x)^\top∇f(x)∇f(x)⊤ has rank one, this says the Hessian of fff need only dominate α\alphaα times the outer product of the gradient with itself: strong curvature exactly along the gradient direction, unlike α\alphaα-strong convexity, which demands ∇2f(x)⪰αI\nabla^2 f(x) \succeq \alpha I∇2f(x)⪰αI in every direction. This is the precise sense in which exp-concave functions form a strictly larger class than strongly convex, Lipschitz functions, and it is what allows functions with a low-rank Hessian, such as the negative log-loss −log⁡(r⊤x)-\log(r^\top x)−log(r⊤x) of online portfolio selection, to be exp-concave.

Formalization Note v⊤∇2f(x)vv^\top\nabla^2f(x)vv⊤∇2f(x)v is the iterated Fréchet derivative (fderiv ℝ (fderiv ℝ f) x) v v, and ∇f(x)⊤v\nabla f(x)^\top v∇f(x)⊤v is the differential (fderiv ℝ f x) v; both sides avoid naming a gradient vector via Riesz representation.


Retired. Retired because its Lean statement was unfaithful to Hazan (see the replacement's Formalization Note); replaced by OnlineConvexOpt.SecondOrder.exp_concave_iff_hessian_v2.

Preamble
import Mathlib
import Definitions.Def_OnlineConvexOpt_SecondOrder_ExpConcave

open OnlineConvexOpt.SecondOrder
Formal statement
namespace OnlineConvexOpt.SecondOrder

variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E]

/-- Lemma 4.2 (Hazan, *Introduction to Online Convex Optimization*, 2nd ed.,
arXiv:1909.05207v3, p. 59, PDF p. 81). A twice-differentiable function `f : E → ℝ` is
`α`-exp-concave at `x` (`IsExpConcaveAt`, the pointwise Hessian formulation of `g(y) =
exp(-α f(y))` being concave to second order at `x`) if and only if `∇²f(x) ⪰ α∇f(x)∇f(x)^⊤`.
The matrix inequality is stated as a comparison of the two quadratic forms it induces: for every
direction `v`, `v^⊤∇²f(x)v ≥ α(∇f(x)^⊤v)^2`, where `v^⊤∇²f(x)v` is the iterated Fréchet
derivative `(fderiv ℝ (fderiv ℝ f) x) v v` and `∇f(x)^⊤v` is the differential `(fderiv ℝ f x) v`.
-/
theorem exp_concave_iff_hessian (α : ℝ) (f : E → ℝ) (x : E) (hf : ContDiffAt ℝ 2 f x) :
    IsExpConcaveAt α f x ↔
      ∀ v : E, α * ((fderiv ℝ f x) v) ^ 2 ≤ (fderiv ℝ (fderiv ℝ f) x) v v := by sorry

end OnlineConvexOpt.SecondOrder
Source
Hazan, Introduction to Online Convex Optimization, 2nd ed., arXiv:1909.05207v3, p. 59, PDF p. 81, Lemma 4.2
Read-back

What the Lean code literally says, in plain math · claude-opus-5

This declaration fixes an arbitrary real number α\alphaα, an arbitrary real inner product space EEE (a normed additive commutative group carrying a real inner product structure, with no completeness, finite-dimensionality, or nontriviality assumed), an arbitrary function f:E→Rf : E \to \mathbb{R}f:E→R, and an arbitrary point x∈Ex \in Ex∈E. It assumes a single hypothesis, hfhfhf: that fff is twice continuously differentiable at xxx in the sense of ContDiffAt ℝ 2 f x, i.e. fff agrees with a C2C^2C2 function on some neighbourhood of xxx. Under these assumptions it asserts a two-way equivalence (an "if and only if", not a one-directional implication):

IsExpConcaveAt(α,f,x)  ⟺  ∀v∈E,α⋅(Df(x)[v])2  ≤  D2f(x)[v][v].\text{IsExpConcaveAt}(\alpha, f, x) \iff \forall v \in E,\quad \alpha \cdot \big(Df(x)[v]\big)^2 \;\le\; D^2f(x)[v][v].IsExpConcaveAt(α,f,x)⟺∀v∈E,α⋅(Df(x)[v])2≤D2f(x)[v][v].

Here the right-hand side quantifies universally over every vector v∈Ev \in Ev∈E, with no restriction (no normalization ∥v∥=1\|v\| = 1∥v∥=1, no nonzero requirement, no restriction to a domain or convex set). The quantity Df(x)[v]Df(x)[v]Df(x)[v] is the Fréchet derivative of fff at xxx, a continuous linear functional on EEE, evaluated at vvv; the expression (Df(x)[v])2\big(Df(x)[v]\big)^2(Df(x)[v])2 is the square of that real number. The quantity D2f(x)[v][v]D^2f(x)[v][v]D2f(x)[v][v] is obtained by forming the map y↦Df(y)y \mapsto Df(y)y↦Df(y) (a function from EEE into the space of continuous linear functionals on EEE), taking its Fréchet derivative at xxx — a continuous linear map from EEE into that functional space — applying it to vvv, and then applying the resulting functional to vvv again. The inequality is a non-strict ≤\le≤, oriented so that α\alphaα times the squared first-order term is at most the second-order term.

The predicate IsExpConcaveAt(α,f,x)\text{IsExpConcaveAt}(\alpha, f, x)IsExpConcaveAt(α,f,x) on the left is not a standard notion and its definition is not visible in the code presented to me: it is imported from a separate module (Definitions.Def_OnlineConvexOpt_SecondOrder_ExpConcave) and only described in the documentation comment, which is not part of the asserted mathematical content. I therefore cannot expand what it literally means; a reader of this read-back must consult that definition separately to know what is being claimed equivalent to the displayed quantitative inequality. Nothing in this statement constrains it beyond the equivalence itself. Likewise, nothing here requires α>0\alpha > 0α>0, or α≠0\alpha \ne 0α=0; α\alphaα may be negative or zero.

Note also what the statement does not say. It does not assert that fff is convex, exp-concave, or differentiable anywhere other than at xxx. It makes no claim about any point besides the single fixed xxx, and no claim about a domain, a constraint set, or a global property of fff. It does not assert that D2f(x)D^2f(x)D2f(x) is symmetric or positive semidefinite in general — only the stated comparison of the two quadratic forms, and only in the direction vvv paired with itself (the "off-diagonal" values D2f(x)[u][v]D^2f(x)[u][v]D2f(x)[u][v] for u≠vu \ne vu=v are never mentioned).

In the degenerate cases the hypotheses permit: if EEE is the zero space (a single point), the universal quantifier ranges over v=0v = 0v=0 only, where both sides are 000 and the inequality α⋅0≤0\alpha \cdot 0 \le 0α⋅0≤0 holds trivially, so the right-hand side of the equivalence is vacuously true and the theorem then asserts that IsExpConcaveAt(α,f,x)\text{IsExpConcaveAt}(\alpha, f, x)IsExpConcaveAt(α,f,x) holds for every α\alphaα, every fff and the unique xxx (whatever that predicate turns out to mean). Taking v=0v = 0v=0 in a general EEE likewise contributes only the trivial instance 0≤00 \le 00≤0, so it imposes nothing. Because Lean's fderiv is a total function that returns the zero map whenever fff (respectively y↦Df(y)y \mapsto Df(y)y↦Df(y)) fails to be differentiable at the point in question, the symbols Df(x)Df(x)Df(x) and D2f(x)D^2f(x)D2f(x) are always well-formed even where no derivative exists; the hypothesis hfhfhf is what is meant to rule that out for fff itself, but note that ContDiffAt ℝ 2 f x gives twice continuous differentiability on a neighbourhood of xxx and does not, on its own syntactic face, guarantee that the outer fderiv ℝ (fderiv ℝ f) is not silently the junk zero map — if it were, the right-hand condition would degrade to ∀v, α(Df(x)[v])2≤0\forall v,\ \alpha (Df(x)[v])^2 \le 0∀v, α(Df(x)[v])2≤0, which for α>0\alpha > 0α>0 forces Df(x)=0Df(x) = 0Df(x)=0. Finally, the hypothesis hfhfhf is satisfiable (constant functions on any EEE satisfy it), so the theorem is not vacuous for that reason; but if one instantiates fff with a function failing to be C2C^2C2 near xxx, the hypothesis is unsatisfiable at that instance and the statement says nothing there. The conclusion is proved by sorry, i.e. no proof is supplied in this code.

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

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 28, 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