LineSearch Class Reference

#include <ql/Optimization/linesearch.hpp>

Inheritance diagram for LineSearch:

Inheritance graph
[legend]
List of all members.

Detailed Description

Base class for line search.


Public Member Functions

 LineSearch (Real eps=1e-8)
 Default constructor.

virtual ~LineSearch ()
 Destructor.

const ArraylastX ()
 return last x value

Real lastFunctionValue ()
 return last cost function value

const ArraylastGradient ()
 return last gradient

Real lastGradientNorm2 ()
 return square norm of last gradient

bool succeed ()
virtual Real operator() (const Problem &P, Real t_ini)=0
 Perform line search.

Real update (Array &params, const Array &direction, Real beta, const Constraint &constraint)

Protected Attributes

Array xtd_
 new x and its gradient

Array gradient_
 new x and its gradient

Real qt_
 cost function value and gradient norm corresponding to xtd_

Real qpt_
 cost function value and gradient norm corresponding to xtd_

bool succeed_
 flag to know if linesearch succeed


QuantLib.org
QuantLib
Hosted by
SourceForge.net Logo
Documentation generated by
doxygen