yat  0.21pre
Classes | Public Member Functions | Protected Member Functions | List of all members
theplu::yat::utility::MultiMinimizerDerivative Class Reference

Wrapper class around gsl_multimin_fdfminimizer in GSL. More...

#include <yat/utility/MultiMinimizerDerivative.h>

Inheritance diagram for theplu::yat::utility::MultiMinimizerDerivative:
theplu::yat::utility::BFGS theplu::yat::utility::BFGS2 theplu::yat::utility::FletcherReevesConjugate theplu::yat::utility::PolakRibiereConjugate theplu::yat::utility::SteepestDescent

Classes

class  Gradient
 
class  Stopper
 

Public Member Functions

 MultiMinimizerDerivative (const MultiMinimizerDerivative &)=delete
 Copy is not allowed.
 
MultiMinimizerDerivativeoperator= (const MultiMinimizerDerivative &)=delete
 Assignment not allowed.
 
unsigned int epochs (void) const
 Number of epochs (iterations) used in last minimisation.
 
double step_size (void) const
 
void step_size (double ss)
 
double tolerance (void) const
 
void tolerance (double tol)
 
template<class FUNC >
void operator() (yat::utility::VectorMutable &, FUNC &func, MultiMinimizerDerivative::Stopper &&stopper)
 
template<class FUNC >
void operator() (yat::utility::VectorMutable &, FUNC &func, MultiMinimizerDerivative::Stopper &&stopper, unsigned int max_epochs)
 

Protected Member Functions

 MultiMinimizerDerivative (const gsl_multimin_fdfminimizer_type *t, size_t size)
 Constructor. More...
 

Detailed Description

Wrapper class around gsl_multimin_fdfminimizer in GSL.

Class is the abstract base class for several minimisation algorithms using the derivative.

Constructor & Destructor Documentation

◆ MultiMinimizerDerivative()

theplu::yat::utility::MultiMinimizerDerivative::MultiMinimizerDerivative ( const gsl_multimin_fdfminimizer_type *  t,
size_t  size 
)
protected

Constructor.

Parameters
tdefines type of GSL minimizer
sizeNumber of dimensions in the input space.

Member Function Documentation

◆ operator()() [1/2]

template<class FUNC >
void theplu::yat::utility::MultiMinimizerDerivative::operator() ( yat::utility::VectorMutable x,
FUNC &  func,
MultiMinimizerDerivative::Stopper &&  stopper 
)

Function finds an x that minimizes the function defined by func. It calls gsl_multimin_fdfminimizer_iterate until either GSL_ENOPROG is returned or the norm of the gradient is smaller than epsabs, as tested by gsl_multimin_test_gradient.

Type Requirements:

  • FUNC must have an operator defining the function double operator()(const VectorBase& x)
  • FUNC must have an operator defining the gradient void operator()(const VectorBase& x, VectorMutable&)

◆ operator()() [2/2]

template<class FUNC >
void theplu::yat::utility::MultiMinimizerDerivative::operator() ( yat::utility::VectorMutable x,
FUNC &  func,
MultiMinimizerDerivative::Stopper &&  stopper,
unsigned int  max_epochs 
)

Same as operator()(yat::utility::VectorMutable&, FUNC& func, double epsabs) but iterate at maximum max_epochs iterations.

◆ step_size() [1/2]

double theplu::yat::utility::MultiMinimizerDerivative::step_size ( void  ) const

The size of the first trial step is given by step_size

See also
gsl_multimin_fdfminimizer_set

◆ step_size() [2/2]

void theplu::yat::utility::MultiMinimizerDerivative::step_size ( double  ss)

The size of the first trial step is given by step_size

See also
gsl_multimin_fdfminimizer_set

◆ tolerance() [1/2]

double theplu::yat::utility::MultiMinimizerDerivative::tolerance ( void  ) const

The accuracy of the line minimization is specified by tolerance

See also
gsl_multimin_fdfminimizer_set

◆ tolerance() [2/2]

void theplu::yat::utility::MultiMinimizerDerivative::tolerance ( double  tol)

The accuracy of the line minimization is specified by tolerance

See also
gsl_multimin_fdfminimizer_set

The documentation for this class was generated from the following file:

Generated on Wed Jan 25 2023 03:34:29 for yat by  doxygen 1.8.14