Simplex algorithm: no constraints, no gradient needed. More...
#include <roboptim/core/plugin/nag/nag-simplex.hh>
Public Types | |
typedef Solver< EigenMatrixDense > | parent_t |
typedef Function::argument_t | argument_t |
typedef Function::result_t | result_t |
typedef DifferentiableFunction::gradient_t | gradient_t |
Public Member Functions | |
Simplex (const problem_t &pb) | |
virtual | ~Simplex () |
void | solve () |
Solve the problem. | |
void | setIterationCallback (callback_t callback) |
const callback_t & | callback () const |
solverState_t & | solverState () |
Simplex algorithm: no constraints, no gradient needed.
Finds an approximation to a minimum of a function F x of n variables. You must supply a function to calculate the value of F x for any set of values of the variables.
The method is iterative. A simplex of n+1 points is set up in the n-dimensional space of the variables (for example, in two dimensions the simplex is a triangle) under the assumption that the problem has been scaled so that the values of the independent variables at the minimum are of order unity. The starting point you provide is the first vertex of the simplex, the remaining n vertices are generated internally (see Parkinson and Hutchinson (1972)). The vertex of the simplex with the largest function value is reflected in the center of gravity of the remaining vertices and the function value at this new point is compared with the remaining function values. Depending on the outcome of this test, the new point is accepted or rejected, a further expansion move may be made, or a contraction may be carried out. When no further progress can be made, the sides of the simplex are reduced in length and the method is repeated.
The method tends to be slow, but it is robust and therefore very useful for functions that are subject to inaccuracies.
typedef Function::argument_t roboptim::nag::Simplex::argument_t |
typedef DifferentiableFunction::gradient_t roboptim::nag::Simplex::gradient_t |
typedef Solver<EigenMatrixDense> roboptim::nag::Simplex::parent_t |
typedef Function::result_t roboptim::nag::Simplex::result_t |
roboptim::nag::Simplex::Simplex | ( | const problem_t & | pb | ) | [explicit] |
References DEFINE_PARAMETER.
roboptim::nag::Simplex::~Simplex | ( | ) | [virtual] |
const callback_t& roboptim::nag::Simplex::callback | ( | ) | const [inline] |
Referenced by roboptim::nag::detail::solverCallback().
void roboptim::nag::Simplex::setIterationCallback | ( | callback_t | callback | ) | [inline] |
void roboptim::nag::Simplex::solve | ( | ) |
Solve the problem.
References roboptim::nag::detail::solverCallback().
solverState_t& roboptim::nag::Simplex::solverState | ( | ) | [inline] |
Referenced by roboptim::nag::detail::solverCallback().