Class SolverIpopt
Defined in File ipopt.hpp
Inheritance Relationships
Base Type
public crocoddyl::SolverAbstract(Class SolverAbstract)
Class Documentation
-
class SolverIpopt : public crocoddyl::SolverAbstract
Ipopt solver.
This solver solves the optimal control problem by transcribing with the multiple shooting approach.
See also
Public Functions
Initialize the Ipopt solver.
- Parameters:
problem – [in] solver to be diagnostic
-
~SolverIpopt()
-
virtual bool solve(const std::vector<Eigen::VectorXd> &init_xs = DEFAULT_VECTOR, const std::vector<Eigen::VectorXd> &init_us = DEFAULT_VECTOR, const std::size_t maxiter = 100, const bool is_feasible = false, const double reg_init = 1e-9)
Compute the optimal trajectory \(\mathbf{x}^*_s,\mathbf{u}^*_s\) as lists of \(T+1\) and \(T\) terms.
From an initial guess
init_xs,init_us(feasible or not), iterate overcomputeDirection()andtryStep()untilstoppingCriteria()is below threshold. It also describes the globalization strategy used during the numerical optimization.- Parameters:
init_xs – [in] initial guess for state trajectory with \(T+1\) elements (default [])
init_us – [in] initial guess for control trajectory with \(T\) elements (default [])
maxiter – [in] maximum allowed number of iterations (default 100)
is_feasible – [in] true if the
init_xsare obtained from integrating theinit_us(rollout) (default false)init_reg – [in] initial guess for the regularization value. Very low values are typical used with very good guess points (default 1e-9).
- Returns:
A boolean that describes if convergence was reached.
-
virtual void resizeData()
Resizing the solver data.
If the shooting problem has changed after construction, then this function resizes all the data before starting resolve the problem.
-
void setStringIpoptOption(const std::string &tag, const std::string &value)
Set a string ipopt option.
- Parameters:
tag – [in] name of the parameter
value – [in] string value for the parameter
-
void setNumericIpoptOption(const std::string &tag, Ipopt::Number value)
Set a string ipopt option.
- Parameters:
tag – [in] name of the parameter
value – [in] numeric value for the parameter
-
void set_th_stop(const double th_stop)