L-BFGS-B
3.0
Large-scale Bound-constrained Optimization
|
Go to the source code of this file.
Functions/Subroutines | |
subroutine | dcsrch (f, g, stp, ftol, gtol, xtol, stpmin, stpmax, task, isave, dsave) |
This subroutine finds a step that satisfies a sufficient decrease condition and a curvature condition. More... | |
subroutine dcsrch | ( | double precision | f, |
double precision | g, | ||
double precision | stp, | ||
double precision | ftol, | ||
double precision | gtol, | ||
double precision | xtol, | ||
double precision | stpmin, | ||
double precision | stpmax, | ||
character*(*) | task, | ||
integer, dimension(2) | isave, | ||
double precision, dimension(13) | dsave | ||
) |
This subroutine finds a step that satisfies a sufficient decrease condition and a curvature condition.
Each call of the subroutine updates an interval with endpoints stx and sty. The interval is initially chosen so that it contains a minimizer of the modified function
psi(stp) = f(stp) - f(0) - ftol*stp*f'(0).
If psi(stp) <= 0 and f'(stp) >= 0 for some step, then the interval is chosen so that it contains a minimizer of f.
The algorithm is designed to find a step that satisfies the sufficient decrease condition
f(stp) <= f(0) + ftol*stp*f'(0),
and the curvature condition
abs(f'(stp)) <= gtol*abs(f'(0)).
If ftol is less than gtol and if, for example, the function is bounded below, then there is always a step which satisfies both conditions.
If no step can be found that satisfies both conditions, then the algorithm stops with a warning. In this case stp only satisfies the sufficient decrease condition.
A typical invocation of dcsrch has the following outline:
NOTE: The user must no alter work arrays between calls.
f | On initial entry f is the value of the function at 0. On subsequent entries f is the value of the function at stp. On exit f is the value of the function at stp. |
g | On initial entry g is the derivative of the function at 0. On subsequent entries g is the derivative of the function at stp. On exit g is the derivative of the function at stp. |
stp | On entry stp is the current estimate of a satisfactory step. On initial entry, a positive initial estimate must be provided. On exit stp is the current estimate of a satisfactory step if task = 'FG'. If task = 'CONV' then stp satisfies the sufficient decrease and curvature condition. |
ftol | On entry ftol specifies a nonnegative tolerance for the sufficient decrease condition. On exit ftol is unchanged. |
gtol | On entry gtol specifies a nonnegative tolerance for the curvature condition. On exit gtol is unchanged. |
xtol | On entry xtol specifies a nonnegative relative tolerance for an acceptable step. The subroutine exits with a warning if the relative difference between sty and stx is less than xtol. On exit xtol is unchanged. |
stpmin | On entry stpmin is a nonnegative lower bound for the step. On exit stpmin is unchanged. |
stpmax | On entry stpmax is a nonnegative upper bound for the step. On exit stpmax is unchanged. |
task | On initial entry task must be set to 'START'. On exit task indicates the required action:
|
isave | work array |
dsave | work array |
Definition at line 94 of file dcsrch.f.
References dcstep().
Referenced by lnsrlb().