Unconstrained Optimisation
Let be a set and be a function. An optimisation problem is the problem of finding the smallest value of the objective function over the feasible set whose points are feasible, and the points at which it is attained.
The optimal value is the infimum of over which is if is unbounded below and if is empty. A minimiser or optimal solution is a point with and the set of minimisers is written
Maximising is equivalent to minimising so only minimisation is considered. The problem is unconstrained if the feasible set is or an open subset of it, so that every point near a feasible point is feasible, and constrained otherwise.
A point is a local minimiser of if and only if there exists such that for all with a strict local minimiser if the inequality is strict for and a global minimiser if and only if A global minimiser is a local minimiser, but a local minimiser need not be global unless is convex.
By the Heine–Borel theorem a set is compact if and only if it is closed and bounded, and a continuous function on a non-empty compact set attains its minimum and maximum, so a global minimiser exists. For an unconstrained problem on a global minimiser exists if is continuous and coercive, meaning that grows without bound as does, since minimising over then reduces to minimising over a compact sublevel set.
Let be open and be differentiable at a local minimiser The first-order necessary condition states that the gradient vanishes at since otherwise decreases along
A point satisfying this condition is a stationary point of as in the univariate case. If the second-order necessary condition states that the Hessian matrix at a local minimiser is positive semi-definite, and the second-order sufficient condition states that a stationary point at which the Hessian matrix is positive definite is a strict local minimiser. Both follow from the second-order Taylor expansion
A stationary point whose Hessian matrix has both positive and negative eigenvalues, so is neither positive nor negative semi-definite, is a saddle point and is neither a local minimiser nor a local maximiser. A stationary point with a positive semi-definite Hessian matrix that is singular may be any of the three; for example, is a minimiser of a maximiser of and neither for
Most optimisation problems cannot be solved by finding stationary points in closed form and are solved by an iterative method that generates a sequence of iterates intended to converge to a minimiser. A line search method chooses at each iterate a search direction and a step size and updates
A direction is a descent direction of at if and only if the directional derivative along it is negative, in which case for all sufficiently small The method stops when or the change in falls below a tolerance.
The step size may be fixed, chosen by exact line search as the minimiser of along the search direction,
or chosen by backtracking line search, which starts from an initial step size and repeatedly multiplies it by a factor until the Armijo condition holds for some guaranteeing a decrease in proportional to the step size and directional derivative.
Let converge to and The convergence is linear if there exist and with superlinear if and quadratic if there exist and with Convergence is sublinear if but no such exists, for example Quadratic convergence roughly doubles the number of correct digits at each iteration.
Gradient descent or steepest descent is the line search method with search direction the negative gradient.
The negative gradient is a descent direction whenever and by the Cauchy-Schwarz inequality it is the direction with that makes the directional derivative most negative. In the context of gradient descent the step size is also called the learning rate.
Let be differentiable with a gradient that is Lipschitz continuous with constant in which case is -smooth.
If is convex and -smooth with a global minimiser then gradient descent with fixed step size converges sublinearly in objective value,
and if is additionally strongly convex with parameter then it converges linearly,
The ratio is the condition number of the problem, and for a strongly convex quadratic objective it is the ratio of the largest to the smallest eigenvalue of the Hessian matrix. Gradient descent is slow when is large because the gradient points across the narrow valley of the objective rather than along it. A step size that is too large causes the iterates to diverge, and one that is too small makes progress slow.
Newton’s method chooses the search direction by minimising the second-order Taylor expansion of at the current iterate. If is positive definite this quadratic has the unique minimiser where the Newton direction solves
so that the Newton step with step size is
Newton’s method is equivalently the method for solving the stationarity equation by repeatedly solving its linear approximation, which for a univariate equation is the iteration If is a stationary point with positive definite and is Lipschitz continuous near then Newton’s method converges quadratically to from any sufficiently close starting point, and it minimises a strongly convex quadratic function exactly in one step. The Newton direction is a descent direction only when the Hessian matrix is positive definite, so far from the minimiser the method is combined with backtracking line search, giving the damped Newton method, or the Hessian matrix is modified to be positive definite. Each iteration requires the Hessian matrix and the solution of an linear system, which is prohibitive for large
Quasi-Newton methods replace the inverse Hessian matrix with a positive definite approximation that is updated at each iteration using only gradient differences, giving the search direction and a cost per iteration comparable to gradient descent. The update is chosen so that the new approximation satisfies the secant condition
which the true inverse Hessian matrix satisfies approximately by the mean value theorem, and the most widely used update is the Broyden–Fletcher–Goldfarb–Shanno (BFGS) update. Quasi-Newton methods with line search converge superlinearly under the conditions that give Newton’s method quadratic convergence.