PaGMO  1.1.5
Public Member Functions | Protected Member Functions | Friends
pagmo::algorithm::ipopt Class Reference

Wrapper for the IPOPT solver. More...

#include <ipopt.h>

Inheritance diagram for pagmo::algorithm::ipopt:
Inheritance graph
[legend]

Public Member Functions

 ipopt (const int &max_iter=100, const double &constr_viol_tol=1e-8, const double &dual_inf_tol=1e-8, const double &compl_inf_tol=1e-8, const bool &nlp_scaling_method=true, const double &obj_scaling_factor=1.0, const double &mu_init=0.1)
 Constructor. More...
 
base_ptr clone () const
 Clone method.
 
void evolve (population &) const
 Evolve implementation. More...
 
std::string get_name () const
 Algorithm name.
 
- Public Member Functions inherited from pagmo::algorithm::base
 base ()
 Default constructor. More...
 
virtual ~base ()
 Trivial destructor. More...
 
std::string human_readable () const
 Return human readable representation of the algorithm. More...
 
void set_screen_output (const bool p)
 Setter-Getter for protected m_screen_output data. More...
 
bool get_screen_output () const
 Gets screen output. More...
 
void reset_rngs (const unsigned int) const
 Resets the seed of the internal rngs using a user-provided seed. More...
 

Protected Member Functions

std::string human_readable_extra () const
 Extra human readable algorithm info. More...
 

Friends

class boost::serialization::access
 

Additional Inherited Members

- Protected Attributes inherited from pagmo::algorithm::base
bool m_screen_output
 Indicates to the derived class whether to print stuff on screen.
 
rng_double m_drng
 Random number generator for double-precision floating point values.
 
rng_uint32 m_urng
 Random number generator for unsigned integer values.
 
unsigned int m_fevals
 A counter for the number of function evaluations.
 

Detailed Description

Wrapper for the IPOPT solver.

IPOPT is an Interior Point Optimization solver released under the CPL licence. Our wrapper is generic and does not use the hessian information letting IPOPT deal with it. Gradients and Jacobian are evaluated by central differences with a stepsize of 10-8 stepsize. We offer control over only a few IPOPT options, take care in particular of the dual_inf_tol as the hessian_approximation, limited_memory option (i.e. hessian is not provided by the user) makes the dual_inf to remain quite high.

CAREFUL: 1 - IPOPT works only for minimization. 2 - The final solution is guaranteed to be within the box constraints by forcing it after the ipopt call

IPOPT has severa lib dependencies that overlaps with SNOPT lib dependencies. Take care that you link to the correct ones, especially for the blas lib that can give problem if coming from SNOPT native source code

Author
Dario Izzo (dario.nosp@m..izz.nosp@m.o@goo.nosp@m.glem.nosp@m.ail.c.nosp@m.om)

Definition at line 59 of file ipopt.h.

Constructor & Destructor Documentation

pagmo::algorithm::ipopt::ipopt ( const int &  max_iter = 100,
const double &  constr_viol_tol = 1e-8,
const double &  dual_inf_tol = 1e-8,
const double &  compl_inf_tol = 1e-8,
const bool &  nlp_scaling_method = true,
const double &  obj_scaling_factor = 1.0,
const double &  mu_init = 0.1 
)

Constructor.

Allows to specify some of the parameters of the IPOPT solver. The algorithm stopping criteria will be 1) if the number of iteration exceeds max_iter 2) the three tolerances are met

Parameters
[in]max_iterMaximum number of major iterations (refer to IPOPT manual).
[in]constr_viol_tolConstraint violation tolerance
[in]dual_inf_tolDual infeasibility tolerance
[in]compl_inf_tolComplementary feasibility tolerance
[in]nlp_scaling_methodSelect if the "gradient-based" scaling of the NLP should be used
[in]obj_scaling_factorScaling factor for the objective function.
[in]mu_initInitial value for the barrier parameter.
Exceptions
value_errorif max_iter or tolerances are negative

Definition at line 53 of file ipopt.cpp.

Member Function Documentation

void pagmo::algorithm::ipopt::evolve ( population pop) const
virtual

Evolve implementation.

Run IPOPT with the parameters specified in the constructor At the end, the velocity is updated

Parameters
[in,out]popinput/output pagmo::population to be evolved.

Implements pagmo::algorithm::base.

Definition at line 97 of file ipopt.cpp.

std::string pagmo::algorithm::ipopt::human_readable_extra ( ) const
protectedvirtual

Extra human readable algorithm info.

Returns
a formatted string displaying the parameters of the algorithm.

Reimplemented from pagmo::algorithm::base.

Definition at line 170 of file ipopt.cpp.


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