Skip to content
AI360XpertBeta

Convergence Rates

Rates name how fast error shrinks: halving the leftovers, dividing by steps, or squaring the accuracy. The name predicts your compute budget.

On a log-error plot the sublinear curve crawls while linear descends steadily and quadratic plunges past 1e-6 in three squarings
On a log-error plot the sublinear curve crawls while linear descends steadily and quadratic plunges past 1e-6 in three squarings

Why Does This Exist?

"Gradient descent converges" promises nothing about Friday. Sublinear O(1/k)O(1/k) needs a million steps for 10−610^{-6}; linear 0.5k0.5^k needs 20; quadratic needs 3 squarings from 0.10.1. The rate is the budget, and picking Newton versus gradient descent without it is gambling.

Rates classify error recursions: sublinear ek+1≤ek−c ek2e_{k+1} \leq e_k - c\,e_k^2-ish, linear ek+1≤ρ eke_{k+1} \leq \rho\,e_k, superlinear ρk→0\rho_k \to 0, quadratic ek+1≤C ek2e_{k+1} \leq C\,e_k^2. They rest on smooth convex geometry and explain the variants in gradient descent variants.

The one idea you need first

Error ek=f(xk)−f⋆e_k = f(x_k) - f^\star (or ∥xk−x⋆∥\|x_k - x^\star\|) tracked per iteration. Strong convexity (μ>0\mu > 0) plus smoothness (LL) gives linear gradient descent with ρ=1−μ/L\rho = 1 - \mu/L; bare convexity gives O(1/k)O(1/k); Newton near a regular root gives quadratic.

Think of It Like This

Draining three tubs

Sublinear tub drains through a straw that narrows as it empties: fast at first, endless at the end. Linear tub drains a fixed fraction per minute: predictable halves. Quadratic tub doubles its drain width each minute: a few gulps and dry.

Condition number κ=L/μ\kappa = L/\mu is the tub shape: stretched tubs drain linearly but slowly. Where it stops: tubs are deterministic, while stochastic drains add noise floors that no rate outruns without variance fixes.

How It Actually Works

Gradient descent on LL-smooth convex objectives gives f(xk)−f⋆≤∥x0−x⋆∥2/(2αk)f(x_k) - f^\star \leq \|x_0-x^\star\|^2/(2\alpha k), sublinear. Add μ\mu-strong convexity: linear with 1−μ/L1 - \mu/L per step (κ\kappa steps per digit). Accelerated gradient lifts smooth convex to O(1/k2)O(1/k^2). Newton: quadratic once inside the basin (ek+1∼ek2e_{k+1} \sim e_k^2), e.g. 0.1→0.01→0.00010.1 \to 0.01 \to 0.0001. Lower bounds certify tightness: no first-order method beats O(1/k2)O(1/k^2) on smooth convex objectives generally.

Worked example

Target 10−610^{-6}. Sublinear 1/k1/k: k=106k = 10^6 steps. Linear 0.5k0.5^k: 0.520≈9.5×10−70.5^{20} \approx 9.5 \times 10^{-7}, so 20 steps (and 0.5190.5^{19} is still above target, so 20 is exact). Quadratic from 0.10.1 with C=1C = 1: 0.1→0.01→10−4→10−80.1 \to 0.01 \to 10^{-4} \to 10^{-8}, 3 squarings to pass the target. Gradient descent on (x−3)2(x-3)^2 (μ=L=2\mu = L = 2, κ=1\kappa = 1) with α=1/L\alpha = 1/L: exact in 1 step, the degenerate best case of linear with ρ=0\rho = 0.

Code

Standard library only: three tiny computations that budget three regimes. Quote them before choosing the optimizer.

import math
print(math.ceil(1 / 1e-6))  # -> 1000000  sublinear steps to 1e-6print(math.ceil(math.log(1e-6, 0.5)))  # -> 20  linear steps at 0.5^ke = 0.1for i in range(3):    e = e**2  # quadratic squaringprint(f"{e:.0e}")  # -> 1e-08  after 3 squarings

Watch Out For

Expecting linear rates without strong convexity

Plain convex objectives (logistic regression without regularization, Lasso) give sublinear theory, yet teams budget linear and declare a stall at 10−310^{-3}. The algorithm is fine; the geometry never promised more.

Add strong convexity (regularize), accelerate (O(1/k2)O(1/k^2)), or budget sublinear. If error falls like 1/k1/k, the theory already told you.

Quoting quadratic from outside the basin

Newton far from the root diverges or cycles; quadratic speed starts only inside a neighborhood that shrinks with nonlinearity. Damped phases precede it, and skipping them explodes.

Globalize (line search, trust region) then enjoy local quadratic speed. If Newton jumps wildly, you are outside, not broken.

The Quick Version

  • Sublinear O(1/k)O(1/k): smooth convex default; a million steps per 10−610^{-6}.
  • Linear ρk\rho^k: needs strong convexity; 20 steps at ρ=0.5\rho = 0.5.
  • Quadratic e2e^2: Newton inside the basin; 3 squarings from 0.1 to pass the target.
  • Acceleration lifts smooth convex to O(1/k2)O(1/k^2); nothing first-order beats it generally.
  • Condition number sets linear speed; regularize or precondition stretched bowls.
  • Stochastic noise floors need variance reduction before rates apply.