Most algorithms for solving such problems are iterative,
Start in some point x0.
Go from xk to xk+1 by some rule.
Terminate based on some criterion.
Line Search Methods
We will firstly look at line search methods.
Definition 1 (Line Search Methods)
A line search algorithm has the form,
Step 0: Set k=0 and choose an initial guess x0.
Step 1: Find search direction, pk∈Rn.
Step 2: Perform line search, i.e., find step length αk>0, such that f(xk+αkpk)<f(xk).
Step 3: Update, xk+1=xk+αkpk.
Step 4: If termination criterion is satisfied, stop. Otherwise, set k=k+1 and go to Step 1.
Steps 0, 3, and 4 are trivial, therefore, we will spend most of our time on Steps 1 and 2.
Step 1 - Search Direction
To understand how we should find a search direction, let’s recap what a descent direction is.
Definition 2 (Descent direction)
Let xk∈S, a vector pk∈Rn is called a descent direction with respect to f at the point xk, if,
∃δ>0:f(xk+αpk)<f(xK),∀α∈(0,δ]
Thus, pk=−∇f(xk) is a descent direction (if ∇f(xk)=0).
It is called the steepest descent direction (since the gradient points in the direction of steepest ascent, the negative gradient points in the direction of steepest descent).
Furthermore, if ∇f(xk)Tpk<0, then pk is a descent direction.
We will mainly derive two methods for finding a search direction, but for this we need the following lemma.
Lemma 1 (Descent direction)
Let f∈C1 and Q∈Rn×n be symmetric and positive definite matrix, if ∇f(xk)=0, then,
pk=−Q∇f(xk)is a descent direction.Note
Q=I gives the steepest descent direction.
We will now introduce Newton’s method.
Newton’s Method
Definition 3 (Newton’s Method)
Let f∈C2 and ∇2f(xk) be positive definite, i.e., ∇2f(xk)≻0.
By a second-order Taylor expansion of f around xk, we have,
Taking the gradient of φxk(p) and setting it to zero, we get,
∇φxk(p)∇f(xk)+∇2f(xk)pp=0=0=−has inverse due to full rank assumption, i.e.,≻0(∇2f(xk))−1∇f(xk)
Some remarks about Newton’s method. When the Hessian ∇2f(xk) is positive definite, then pk is a descent direction (by the lemma).
However, if ∇2f(xk) is negative definite (may also be non invertible), then pk is an ascent direction.
This means that Newton’s method works for both minimization and maximization problems, but may be problematic at times.
How do we solve this issue? Perturbing the Hessian matrix so it can be made positive definite.
Definition 4 (Levenberg-Marquardt modification)
We take the search direction,
pk=−(∇2f(xk)+γI)−1∇f(xk),
for γ>0 such that ∇2f(xk)+γI≻0.
An interesting thing to consider is what is the lower bound needed for γ to make the matrix positive definite?
Let (λi,vi) be the eigenpairs of ∇2f(xk), then the eigenpairs of ∇2f(xk)+γI are (λi+γ,vi).
Thus, we need γ>−λmin, where λmin is the smallest eigenvalue of ∇2f(xk).
Note
When γ=0, we have the original Newton’s method, why?
Solution
Because ∇2f(xk)+0I=∇2f(xk).
When γ→∞, we have the steepest descent method, why?
Solution
Because (∇2f(xk)+γI)−1≈I, when γ is large, thus pk≈−I∇f(xk)=−∇f(xk).
We will note that computing the Hessian and its inverse is expensive, therefore, quasi-Newton methods are often used instead, where one approximatates the Hessian.
We will not go into them, but it is good to know that they exist.
Let’s also summarize the algorithms strengths and weaknesses.
Summary (Strengths and Weaknesses of Steepest Descent and Newton’s Method)
Steepest Descent:
Strengths:
Cheap (only need gradient).
Weaknesses:
“Zig-zagging” behavior ~ needs many (cheap) iterations.
Newton’s Method:
Strengths:
Fast convergence ~ needs few (expensive) iterations.
Weaknesses:
Expensive (need Hessian and its inverse).
Step 2 - Line Search
We will now look at how to perform a line search, i.e., how to find a step length αk>0 such that f(xk+αkpk)<f(xk).
In a point xk and a direction pk (from Step 1), we would like to solve,
α>0min=:φ(α)f(xk+αpk).
This procedure is called exact step length calculation.
Most of the time, it is unnecessary (since (on average) it may be unlikely that we are on the exact line for the minimum).
However, we still want to take a step that decreases the function value sufficiently, or “sufficient decrease”.
We will often use the Armijo Step Length Rule,
Definition 5 (Armijo Step Length Rule)
To find α that gives “sufficient decrease”, note that,
f(xk+αpk)≈f(xk)+α∇f(xk)Tpk,
where α∇f(xk)Tpk is the prediction of change of f from point xk to xk+αpk.
But we want to ensure that the predicted change is not too large and that the actual change is “sufficiently” large.
Solution to this problem, accept a step length α if it achieves a fraction μ of the predicted decrease, i.e., if,
f(xk+αpk)≤f(xk)+μα∇f(xk)Tpk,
then we accept α as our step length.
else, let α=2α and repeat until the condition is satisfied.
Note
Eventually, some α will satisfy the condition.
Step 4 - Termination Criteria
We will now look at some termination criterias that are commonly used.
Definition 6 (Termination Criteria)
Three common termination criteria are,
∥∇f(xk)∥<ϵ1(1+∣f(xk∣) for some small ϵ1>0.
f(xk−1)−f(xk)<ϵ2(1+∣f(xk∣) for some small ϵ2>0.
∥xk−xk−1∥<ϵ3(1+∥xk∥) for some small ϵ3>0.
The first criterion checks if we are close to a stationary point, the second checks if we have a small change in function value, and the third checks if we have a small change in the solution.
The factors (1+∣f(xk∣) and (1+∥xk∥) are included to make the criteria scale-invariant (i.e., independent of the scaling of f and x).
Now, we have covered all the steps of a line search method, but it is also of interest to look at the convergence of such methods, so let’s do that.
Convergence
If {xk} are the iterates of a line search method, we want,
{xk}→x∗
We will formalize this, but for now, let’s go over some conditions over our search direction pk.
Definition 7 (Descent direction conditions)
All search directions pk should satisfy the following conditions,
∥pk∥ is bounded, i.e., ∃M>0:∥pk∥≤M,∀k.
∥pk∥≥s1∥∇f(xk)∥, for some s1>0.
−∥∇f(xk)∥∥pk∥∇f(xk)Tpk≥s2, for some s2>0.
Condition 1 ensures that the step length does not become too large.
Condition 2 ensures that the step length does not become too small (or, that we actually move and do not get stuck).
Condition 3 ensures that pk is a descent direction (since ∇f(xk)Tpk<0).
We will now state a theorem regarding convergence.
Theorem 1 (Convergence of Line Search Methods)
Let f∈C1 and assume for x0, the level set,
{x∈Rn∣f(x)≤f(x0)}is bounded.
Furthermore, assume pk satisfies the descent direction conditions and that αk is chosen by the Armijo step length rule.
Then,
The sequence {xk} is bounded.
The sequence {f(xk)} is decreasing and lower bounded.
Every limit point of {xk} is a stationary point, or in looser terms,
k→∞limxk=x∗:∇f(x∗)=0Note
The steepest descent direction fulfills conditions 2 and 3 with s2=s3=1.