Go to the documentation of this file.
27 #ifndef IFOPT_INCLUDE_OPT_IPOPT_ADAPTER_H_
28 #define IFOPT_INCLUDE_OPT_IPOPT_ADAPTER_H_
30 #include <IpIpoptApplication.hpp>
31 #include <IpSolveStatistics.hpp>
75 virtual bool get_nlp_info(Index& n, Index& m, Index& nnz_jac_g,
76 Index& nnz_h_lag, IndexStyleEnum& index_style);
79 virtual bool get_bounds_info(Index n,
double* x_l,
double* x_u, Index m,
80 double* g_l,
double* g_u);
84 double* z_L,
double* z_U, Index m,
85 bool init_lambda,
double* lambda);
88 virtual bool eval_f(Index n,
const double* x,
bool new_x,
double& obj_value);
91 virtual bool eval_grad_f(Index n,
const double* x,
bool new_x,
95 virtual bool eval_g(Index n,
const double* x,
bool new_x, Index m,
double* g);
101 virtual bool eval_jac_g(Index n,
const double* x,
bool new_x, Index m,
102 Index nele_jac, Index* iRow, Index* jCol,
108 double obj_value,
double inf_pr,
109 double inf_du,
double mu,
double d_norm,
110 double regularization_size,
111 double alpha_du,
double alpha_pr,
112 Index ls_trials,
const IpoptData* ip_data,
113 IpoptCalculatedQuantities* ip_cq);
118 const double* z_L,
const double* z_U, Index m,
119 const double* g,
const double* lambda,
120 double obj_value,
const IpoptData* ip_data,
121 IpoptCalculatedQuantities* ip_cq);
Component::VectorXd VectorXd
Problem::Jacobian Jacobian
namespace defined by the Ipopt solver.
virtual ~IpoptAdapter()=default
Component::Jacobian Jacobian
Problem * nlp_
The solver independent problem definition.
virtual bool eval_jac_g(Index n, const double *x, bool new_x, Index m, Index nele_jac, Index *iRow, Index *jCol, double *values)
Solves the optimization problem using the IPOPT solver.
A generic optimization problem with variables, costs and constraints.
virtual bool get_nlp_info(Index &n, Index &m, Index &nnz_jac_g, Index &nnz_h_lag, IndexStyleEnum &index_style)
virtual bool eval_f(Index n, const double *x, bool new_x, double &obj_value)
IpoptAdapter(Problem &nlp, bool finite_diff=false)
Creates an IpoptAdapter wrapping the nlp.
bool finite_diff_
Flag that indicates the "finite-difference-values" option is set.
virtual bool get_bounds_info(Index n, double *x_l, double *x_u, Index m, double *g_l, double *g_u)
virtual void finalize_solution(SolverReturn status, Index n, const double *x, const double *z_L, const double *z_U, Index m, const double *g, const double *lambda, double obj_value, const IpoptData *ip_data, IpoptCalculatedQuantities *ip_cq)
virtual bool get_starting_point(Index n, bool init_x, double *x, bool init_z, double *z_L, double *z_U, Index m, bool init_lambda, double *lambda)
Problem::VectorXd VectorXd
virtual bool eval_g(Index n, const double *x, bool new_x, Index m, double *g)
virtual bool eval_grad_f(Index n, const double *x, bool new_x, double *grad_f)
virtual bool intermediate_callback(AlgorithmMode mode, Index iter, double obj_value, double inf_pr, double inf_du, double mu, double d_norm, double regularization_size, double alpha_du, double alpha_pr, Index ls_trials, const IpoptData *ip_data, IpoptCalculatedQuantities *ip_cq)
ifopt
Author(s): Alexander W. Winkler
autogenerated on Mon Sep 18 2023 02:14:38