25#ifndef quantlib_optimization_line_search_h_
26#define quantlib_optimization_line_search_h_
62 const Array& direction,
1-D array used in linear algebra.
1-D array used in linear algebra.
Criteria to end optimization process:
Base class for line search.
const Array & lastGradient()
return last gradient
Array & searchDirection()
const Array & searchDirection() const
current value of the search direction
virtual ~LineSearch()=default
Destructor.
bool succeed_
flag to know if linesearch succeed
Array searchDirection_
current values of the search direction
const Array & lastX()
return last x value
Real update(Array ¶ms, const Array &direction, Real beta, const Constraint &constraint)
Array xtd_
new x and its gradient
virtual Real operator()(Problem &P, EndCriteria::Type &ecType, const EndCriteria &, Real t_ini)=0
Perform line search.
Real lastGradientNorm2() const
return square norm of last gradient
LineSearch(Real=0.0)
Default constructor.
Real lastFunctionValue() const
return last cost function value
Real qt_
cost function value and gradient norm corresponding to xtd_
Constrained optimization problem.
Optimization criteria class.