Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 4.6 — the online Newton step regret-to-matrix-sum reduction

Disproved
OnlineConvexOpt.SecondOrder.online_newton_step_regret_bound

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

online-convex-optimizationonline-newton-stepregret-bound

Let KKK be a decision set of diameter DDD in a real inner-product space, let f0,f1,…f_0, f_1, \dotsf0​,f1​,… be α\alphaα-exp-concave, GGG-gradient-bounded cost functions on KKK, and run online Newton step (Algorithm 12) with γ=12min⁡{1/(GD),α}\gamma = \tfrac12\min\{1/(GD), \alpha\}γ=21​min{1/(GD),α} and ε=1/(γ2D2)\varepsilon = 1/(\gamma^2 D^2)ε=1/(γ2D2), producing decisions xtx_txt​, gradients ∇t\nabla_t∇t​, and running matrices AtA_tAt​. Then for every horizon TTT,

RegretT(ONS)  ≤  (1α+GD)(∑t=1T∇t⊤At−1∇t  +  1).\mathrm{Regret}_T(\mathrm{ONS}) \;\le\; \Bigl(\frac1\alpha + GD\Bigr) \left(\sum_{t=1}^T \nabla_t^\top A_t^{-1} \nabla_t \;+\; 1\right) .RegretT​(ONS)≤(α1​+GD)(t=1∑T​∇t⊤​At−1​∇t​+1).

This is the key reduction of the chapter: it converts the regret bound into a sum of quadratic forms ∇t⊤At−1∇t\nabla_t^\top A_t^{-1}\nabla_t∇t⊤​At−1​∇t​ that the running matrix's own definition makes telescope (Theorem 4.5 bounds this sum by nlog⁡Tn \log TnlogT via a log-determinant argument). The proof follows the same generalized-Pythagorean template as online gradient descent's regret bound, but in the norm induced by AtA_tAt​ rather than the Euclidean norm, which is exactly why online Newton step needs the generalized projection of Algorithm 12 in place of the ordinary metric projection.


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

Preamble
import Mathlib
import Definitions.Def_OnlineConvexOpt_SecondOrder_ExpConcave
import Definitions.Def_OnlineConvexOpt_SecondOrder_OnlineNewtonStep
import Definitions.Def_OnlineConvexOpt_FirstOrder_Protocol

open OnlineConvexOpt.SecondOrder OnlineConvexOpt.FirstOrder
Formal statement
namespace OnlineConvexOpt.SecondOrder

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

/-- Lemma 4.6 (Hazan, *Introduction to Online Convex Optimization*, 2nd ed.,
arXiv:1909.05207v3, p. 63, PDF p. 85). The regret of online Newton step (Algorithm 12, run with
parameters `γ = (1/2) min{1/(GD), α}`, `ε = 1/(γ²D²)` against `α`-exp-concave cost functions `f`
with gradient bound `G` over a decision set `K` of diameter `D`) is bounded by
`Regret_T(ONS) ≤ (1/α + GD)(Σ_{t=1}^T ∇_t^⊤A_t^{-1}∇_t + 1)`, where `∇_t^⊤A_t^{-1}∇_t` is the
quadratic form `quadForm (A (t+1)).inverse (g t)` — the sum runs over the 0-indexed rounds
`t = 0, ..., T - 1`, i.e. the book's `t = 1, ..., T`, matching `A (t + 1)`'s shift in
`IsOnlineNewtonStep`. -/
theorem online_newton_step_regret_bound
    (K : Set E) (α D G γ ε : ℝ) (f : ℕ → E → ℝ)
    (hf : ∀ t, IsExpConcaveOn α K (f t))
    (hD : ∀ p ∈ K, ∀ q ∈ K, dist p q ≤ D)
    (hG : ∀ t, ∀ p ∈ K, ∀ v, HasGradientAt (f t) v p → ‖v‖ ≤ G)
    (hα : 0 < α) (hGpos : 0 < G) (hDpos : 0 < D)
    (hγ : γ = (1 / 2) * min (1 / (G * D)) α) (hε : ε = 1 / (γ ^ 2 * D ^ 2))
    (x g : ℕ → E) (A : ℕ → E →L[ℝ] E) (hONS : IsOnlineNewtonStep K γ ε f x g A)
    (T : ℕ) :
    RegretT K f x T ≤
      (1 / α + G * D) *
        ((∑ t ∈ Finset.range T, quadForm (A (t + 1)).inverse (g t)) + 1) := by sorry

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

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

The setting is an arbitrary type EEE carrying the structure of a real inner-product space that is complete (a real Hilbert space); EEE is not assumed finite-dimensional, nonzero, or separable. The statement takes:

  • a set K⊆EK \subseteq EK⊆E;
  • real numbers α,D,G,γ,ε\alpha, D, G, \gamma, \varepsilonα,D,G,γ,ε;
  • a family of cost functions f:N→E→Rf : \mathbb{N} \to E \to \mathbb{R}f:N→E→R, with the hypothesis that every ftf_tft​, for every natural number ttt, satisfies IsExpConcaveOn(α,K,ft)\mathrm{IsExpConcaveOn}(\alpha, K, f_t)IsExpConcaveOn(α,K,ft​) — a predicate defined elsewhere in this bundle and not unfolded here;
  • a diameter hypothesis: for all p,q∈Kp, q \in Kp,q∈K, dist(p,q)≤D\mathrm{dist}(p,q) \le Ddist(p,q)≤D;
  • a gradient-bound hypothesis: for every t∈Nt \in \mathbb{N}t∈N, every p∈Kp \in Kp∈K and every vector v∈Ev \in Ev∈E, if ftf_tft​ has gradient vvv at ppp (Lean's HasGradientAt), then ∥v∥≤G\|v\| \le G∥v∥≤G;
  • positivity: α>0\alpha > 0α>0, G>0G > 0G>0, D>0D > 0D>0;
  • two defining equations for the algorithm's parameters,
γ=12min⁡ ⁣(1GD, α),ε=1γ2D2;\gamma = \tfrac12 \min\!\Big(\tfrac{1}{GD},\ \alpha\Big), \qquad \varepsilon = \frac{1}{\gamma^2 D^2};γ=21​min(GD1​, α),ε=γ2D21​;
  • sequences x,g:N→Ex, g : \mathbb{N} \to Ex,g:N→E and a sequence A:N→(E→L[R]E)A : \mathbb{N} \to (E \to_{L[\mathbb{R}]} E)A:N→(E→L[R]​E) of continuous linear maps E→EE \to EE→E, satisfying IsOnlineNewtonStep(K,γ,ε,f,x,g,A)\mathrm{IsOnlineNewtonStep}(K, \gamma, \varepsilon, f, x, g, A)IsOnlineNewtonStep(K,γ,ε,f,x,g,A) — again a predicate defined elsewhere in this bundle and not unfolded here;
  • a natural number TTT, with no lower bound imposed on it.

The conclusion is the single non-strict inequality

RegretT(K,f,x,T)  ≤  (1α+GD)( ∑t∈{0,1,…,T−1}Q(At+1−1; gt)  +  1),\mathrm{RegretT}(K, f, x, T) \;\le\; \Big(\frac{1}{\alpha} + G D\Big)\left(\ \sum_{t \in \{0,1,\dots,T-1\}} Q\big(A_{t+1}^{-1};\, g_t\big) \;+\; 1\right),RegretT(K,f,x,T)≤(α1​+GD)​ t∈{0,1,…,T−1}∑​Q(At+1−1​;gt​)+1​,

where RegretT\mathrm{RegretT}RegretT is defined elsewhere in this bundle (its content is not visible here), the sum ranges over the TTT natural numbers 0,1,…,T−10,1,\dots,T-10,1,…,T−1, At+1−1A_{t+1}^{-1}At+1−1​ denotes Lean's ContinuousLinearMap.inverse applied to the continuous linear map At+1A_{t+1}At+1​, and Q( ⋅ ; ⋅ )Q(\,\cdot\,;\,\cdot\,)Q(⋅;⋅) is the bundle's quadForm applied to that map and to the vector gtg_tgt​ — a definition also not visible here, so this read-back cannot say what value it produces beyond that it is a real number determined by a continuous linear map and a vector. Note that the index shift is explicit: the summand at ttt pairs At+1A_{t+1}At+1​ with gtg_tgt​.

Several points about what is and is not constrained. The gradient hypothesis is conditional: it says only that any vvv which happens to be a gradient of ftf_tft​ at p∈Kp \in Kp∈K has norm at most GGG; it does not assert that ftf_tft​ is differentiable anywhere, so it is satisfied vacuously by a nowhere-differentiable family. Likewise the diameter hypothesis is conditional on membership in KKK and says nothing if KKK is empty. KKK is not assumed nonempty, convex, measurable, bounded (beyond what hDhDhD gives), or closed. The sequences xxx, ggg, AAA are given, with their relationship to the algorithm carried entirely by IsOnlineNewtonStep\mathrm{IsOnlineNewtonStep}IsOnlineNewtonStep; no existence or uniqueness is claimed, and no invertibility of any At+1A_{t+1}At+1​ is hypothesised. The parameters γ\gammaγ and ε\varepsilonε are pinned by equations rather than inequalities, so they are determined by G,D,αG, D, \alphaG,D,α; in particular γ>0\gamma > 0γ>0 follows from hGposhGposhGpos, hDposhDposhDpos, hαh\alphahα, hence γ2D2≠0\gamma^2 D^2 \neq 0γ2D2=0 and ε\varepsilonε is an ordinary real number. Note that ε\varepsilonε appears only in the hypothesis hONShONShONS and nowhere in the conclusion, and likewise γ\gammaγ; ggg and AAA appear in the conclusion only through the sum.

On degenerate cases permitted by the hypotheses: T=0T = 0T=0 is allowed, and then the sum over Finset.range 0\mathrm{Finset.range}\,0Finset.range0 is empty and equals 000, so the claim reduces to RegretT(K,f,x,0)≤1α+GD\mathrm{RegretT}(K,f,x,0) \le \frac{1}{\alpha} + GDRegretT(K,f,x,0)≤α1​+GD. If K=∅K = \emptysetK=∅, the hypotheses hDhDhD and hGhGhG hold vacuously and IsExpConcaveOn\mathrm{IsExpConcaveOn}IsExpConcaveOn may or may not, depending on its unseen definition. If EEE is the zero space (a one-element type, which the typeclass assumptions permit), then all xt=gt=0x_t = g_t = 0xt​=gt​=0, DDD may be any positive real since all distances are 000, and the conclusion is whatever the unseen RegretT\mathrm{RegretT}RegretT and quadForm\mathrm{quadForm}quadForm evaluate to there. Where At+1A_{t+1}At+1​ is not invertible, ContinuousLinearMap.inverse returns the zero map by Lean's total-function convention, and the summand is then Q(0;gt)Q(0; g_t)Q(0;gt​), whose value depends on the unseen definition of quadForm; nothing in the statement excludes this. Divisions are safe: 1/α1/\alpha1/α with α>0\alpha > 0α>0, 1/(GD)1/(GD)1/(GD) with G,D>0G, D > 0G,D>0, and 1/(γ2D2)1/(\gamma^2 D^2)1/(γ2D2) with γ≠0\gamma \ne 0γ=0 as noted. Because IsOnlineNewtonStep\mathrm{IsOnlineNewtonStep}IsOnlineNewtonStep, IsExpConcaveOn\mathrm{IsExpConcaveOn}IsExpConcaveOn, RegretT\mathrm{RegretT}RegretT and quadForm\mathrm{quadForm}quadForm are all opaque here, it cannot be determined from this text whether the hypothesis bundle is satisfiable for any given parameters, and the theorem holds vacuously wherever it is not.

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