Go to the documentation of this file.
9 #ifndef INCLUDE_MATLABPROGRAM
10 #define INCLUDE_MATLABPROGRAM
37 virtual bool get_nlp_info (
int& n,
int&
m,
int& sizeOfJ,
int& sizeOfH,
42 double* cl,
double* cu);
46 bool initializez,
double* zl,
double* zu,
47 int m,
bool initializeLambda,
51 virtual bool eval_f (
int n,
const double* vars,
bool ignore,
double& f);
54 virtual bool eval_grad_f (
int n,
const double* vars,
bool ignore,
58 virtual bool eval_g (
int n,
const double* vars,
bool ignore,
int m,
64 virtual bool eval_jac_g (
int numVariables,
const double* variables,
65 bool ignoreThis,
int numConstraints,
66 int sizeOfJ,
int* rows,
int *cols,
double* Jx);
71 virtual bool eval_h (
int n,
const double* vars,
bool ignore,
double sigma,
72 int m,
const double* lambda,
bool ignoretoo,
73 int sizeOfH,
int* rows,
int* cols,
double* Hx);
77 const double* variables,
const double* zl,
78 const double* zu,
int numConstraints,
79 const double* constraints,
80 const double* lambda,
double objective,
87 double inf_pr,
double inf_du,
88 double mu,
double d_norm,
89 double regularization_size,
90 double alpha_du,
double alpha_pr,
virtual bool intermediate_callback(AlgorithmMode mode, int t, double f, double inf_pr, double inf_du, double mu, double d_norm, double regularization_size, double alpha_du, double alpha_pr, int ls_trials, const IpoptData *ip_data, IpoptCalculatedQuantities *ip_cq)
Intermediate Callback method for the user.
virtual bool get_bounds_info(int n, double *lb, double *ub, int m, double *cl, double *cu)
overload this method to return the information about the bound on the variables and constraints.
Class to organize all the data required by the algorithm.
virtual bool get_nlp_info(int &n, int &m, int &sizeOfJ, int &sizeOfH, IndexStyleEnum &indexStyle)
Class for all IPOPT specific calculated quantities.
const CallbackFunctions & funcs
virtual bool get_starting_point(int n, bool initializeVars, double *vars, bool initializez, double *zl, double *zu, int m, bool initializeLambda, double *lambda)
overload this method to return the starting point.
MatlabProgram(const Iterate &x0, const CallbackFunctions &funcs, const Options &options, Iterate &x, MatlabInfo &info)
virtual bool eval_jac_g(int numVariables, const double *variables, bool ignoreThis, int numConstraints, int sizeOfJ, int *rows, int *cols, double *Jx)
overload this method to return the jacobian of the constraints.
virtual bool eval_f(int n, const double *vars, bool ignore, double &f)
overload this method to return the value of the objective function
virtual bool eval_g(int n, const double *vars, bool ignore, int m, double *g)
overload this method to return the vector of constraint values
virtual void finalize_solution(SolverReturn status, int numVariables, const double *variables, const double *zl, const double *zu, int numConstraints, const double *constraints, const double *lambda, double objective, const IpoptData *ip_data, IpoptCalculatedQuantities *ip_cq)
virtual bool eval_grad_f(int n, const double *vars, bool ignore, double *grad)
overload this method to return the vector of the gradient of the objective w.r.t.
Base class for all NLP's that use standard triplet matrix form and dense vectors.
Number Number * g
Values of constraint at final point (output only - ignored if set to NULL)
IndexStyleEnum
overload this method to return the number of variables and constraints, and the number of non-zeros i...
SolverReturn
enum for the return from the optimize algorithm (obviously we need to add more)
virtual bool eval_h(int n, const double *vars, bool ignore, double sigma, int m, const double *lambda, bool ignoretoo, int sizeOfH, int *rows, int *cols, double *Hx)
overload this method to return the hessian of the lagrangian.
AlgorithmMode
enum to indicate the mode in which the algorithm is
Number Number Index m
Number of constraints.