Difference between revisions of "Lbfgs.m"
(→Notes) |
|||
| Line 1: | Line 1: | ||
{{DISPLAYTITLE:lbfgs.m}} | {{DISPLAYTITLE:lbfgs.m}} | ||
| − | + | Calculates an approximation to the Newton-Raphson search direction using past gradients to build a serviceable substitute to a Hessian. The Hessian matrix is never explicitly formed or inverted. This function is the implementation from section 4 of http://dx.doi.org/10.1090/S0025-5718-1980-0572855-7 | |
| − | |||
==Syntax== | ==Syntax== | ||
| − | direction=lbfgs( | + | direction=lbfgs(dx_hist,dg_hist,g,n_grads) |
| − | |||
| − | |||
| − | |||
==Arguments== | ==Arguments== | ||
| − | + | dx_hist - history of x increments, | |
| + | bookshelf array | ||
| − | + | dg_hist - history of gradient increments, | |
| + | bookshelf array | ||
| − | + | g - current gradient | |
| − | + | n_grads - max number of past gradients to | |
| + | use for the Hessian estimate | ||
==Returns== | ==Returns== | ||
| − | + | direction - LBFGS approximation to the | |
| + | search direction | ||
==Notes== | ==Notes== | ||
| Line 28: | Line 28: | ||
==See also== | ==See also== | ||
| − | + | [[fminnewton.m]], [[hess_reg.m]] | |
| − | ''Version | + | ''Version 2.2, authors: [[Ilya Kuprov]], [[David Goodwin]]'' |
Revision as of 16:22, 13 August 2018
Calculates an approximation to the Newton-Raphson search direction using past gradients to build a serviceable substitute to a Hessian. The Hessian matrix is never explicitly formed or inverted. This function is the implementation from section 4 of http://dx.doi.org/10.1090/S0025-5718-1980-0572855-7
Contents
Syntax
direction=lbfgs(dx_hist,dg_hist,g,n_grads)
Arguments
dx_hist - history of x increments,
bookshelf array
dg_hist - history of gradient increments,
bookshelf array
g - current gradient
n_grads - max number of past gradients to
use for the Hessian estimate
Returns
direction - LBFGS approximation to the
search direction
Notes
The L-BFGS algorithm is the default of fminnewton.m, and is a good mix of computational efficiency and fast convergence.
See also
Version 2.2, authors: Ilya Kuprov, David Goodwin