Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Gradient descent with exact line search: linear rate

Proved
ConvexOptimization.gradient_descent_exact_linear_rate

by Shuze Chen · Aug 13, 2026 · Mathlib 0df444a (Lean v4.33.1)

convexoptimizationnewtonmethodoptimizationalgorithms

Linear convergence of gradient descent with exact line search.

Let f:Rn→Rf : \mathbb{R}^n \to \mathbb{R}f:Rn→R with gradient field ∇f\nabla f∇f satisfy, for constants 0<m≤M0 < m \le M0<m≤M, the two-sided quadratic bounds

f(x)+⟨∇f(x),y−x⟩+m2∥y−x∥22  ≤  f(y)  ≤  f(x)+⟨∇f(x),y−x⟩+M2∥y−x∥22(x,y∈Rn),f(x) + \langle \nabla f(x), y - x\rangle + \frac{m}{2}\lVert y - x\rVert_2^2 \;\le\; f(y) \;\le\; f(x) + \langle \nabla f(x), y - x\rangle + \frac{M}{2}\lVert y - x\rVert_2^2 \qquad (x, y \in \mathbb{R}^n),f(x)+⟨∇f(x),y−x⟩+2m​∥y−x∥22​≤f(y)≤f(x)+⟨∇f(x),y−x⟩+2M​∥y−x∥22​(x,y∈Rn),

i.e. fff is mmm-strongly convex and MMM-smooth. Let x⋆x^{\star}x⋆ be a global minimizer, p⋆=f(x⋆)p^{\star} = f(x^{\star})p⋆=f(x⋆), and let (xk)(x_k)(xk​) be a gradient-descent sequence with exact line search: each iterate has the form xk+1=xk−t ∇f(xk)x_{k+1} = x_k - t\,\nabla f(x_k)xk+1​=xk​−t∇f(xk​) for some t≥0t \ge 0t≥0 and is optimal along the ray, f(xk+1)≤f(xk−s ∇f(xk))f(x_{k+1}) \le f(x_k - s\,\nabla f(x_k))f(xk+1​)≤f(xk​−s∇f(xk​)) for every s≥0s \ge 0s≥0. Then for every kkk

f(xk)−p⋆  ≤  (1−mM)k(f(x0)−p⋆).f(x_k) - p^{\star} \;\le\; \Bigl(1 - \frac{m}{M}\Bigr)^{k}\bigl(f(x_0) - p^{\star}\bigr).f(xk​)−p⋆≤(1−Mm​)k(f(x0​)−p⋆).

The error decays geometrically with ratio 1−m/M1 - m/M1−m/M, so the iteration count to reach accuracy ε\varepsilonε scales with the condition number M/mM/mM/m and with log⁡(1/ε)\log(1/\varepsilon)log(1/ε). This is the benchmark against which the mission's goal theorem — Newton's dimension-free, log⁡log⁡(1/ε)\log\log(1/\varepsilon)loglog(1/ε) count — is to be read.

Formalization Note Exact line search is expressed as the conjunction of "the step is along −∇f(xk)-\nabla f(x_k)−∇f(xk​) with a nonnegative step size" and "no nonnegative step size along that ray gives a smaller value", which avoids assuming a minimizer of the line-search subproblem exists as a chosen value. The minimizer is IsMinOn f Set.univ xstar. Source: B&V §9.3.1, pp. 467–468.

Preamble
import Mathlib

open scoped RealInnerProductSpace ENNReal
open MeasureTheory

Formal statement
theorem ConvexOptimization.gradient_descent_exact_linear_rate {n : ℕ} (m M : ℝ)
    (hm : 0 < m) (hmM : m ≤ M)
    (f : EuclideanSpace ℝ (Fin n) → ℝ)
    (g : EuclideanSpace ℝ (Fin n) → EuclideanSpace ℝ (Fin n))
    (hg : ∀ x, HasGradientAt f (g x) x)
    (hsc : ∀ x y : EuclideanSpace ℝ (Fin n),
      f x + ⟪g x, y - x⟫ + m / 2 * ‖y - x‖ ^ 2 ≤ f y)
    (hsm : ∀ x y : EuclideanSpace ℝ (Fin n),
      f y ≤ f x + ⟪g x, y - x⟫ + M / 2 * ‖y - x‖ ^ 2)
    (xstar : EuclideanSpace ℝ (Fin n)) (hstar : IsMinOn f Set.univ xstar)
    (x : ℕ → EuclideanSpace ℝ (Fin n))
    (hstep : ∀ k, (∃ t : ℝ, 0 ≤ t ∧ x (k + 1) = x k - t • g (x k)) ∧
      ∀ s : ℝ, 0 ≤ s → f (x (k + 1)) ≤ f (x k - s • g (x k))) :
    ∀ k, f (x k) - f xstar ≤ (1 - m / M) ^ k * (f (x 0) - f xstar) := by
  sorry
Source
Boyd & Vandenberghe 2004, Convex Optimization, Cambridge University Press (seventh printing with corrections, 2009), https://web.stanford.edu/~boyd/cvxbook/, pp. 467-468, §9.3.1 eq. (9.18) (gradient descent with exact line search: linear convergence with ratio 1 - m/M)

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 paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me