alpaqa
0.0.1
Nonconvex constrained optimization
|
#include <alpaqa/util/problem.hpp>
Problem description for minimization problems.
Definition at line 26 of file include/alpaqa/util/problem.hpp.
Public Types | |
using | f_sig = real_t(crvec x) |
Signature of the function that evaluates the cost | |
using | grad_f_sig = void(crvec x, rvec grad_fx) |
Signature of the function that evaluates the gradient of the cost function | |
using | g_sig = void(crvec x, rvec gx) |
Signature of the function that evaluates the constraints | |
using | grad_g_prod_sig = void(crvec x, crvec y, rvec grad_gxy) |
Signature of the function that evaluates the gradient of the constraints times a vector | |
using | grad_gi_sig = void(crvec x, unsigned i, rvec grad_gi) |
Signature of the function that evaluates the gradient of one specific constraints | |
using | hess_L_prod_sig = void(crvec x, crvec y, crvec v, rvec Hv) |
Signature of the function that evaluates the Hessian of the Lagrangian multiplied by a vector | |
using | hess_L_sig = void(crvec x, crvec y, rmat H) |
Signature of the function that evaluates the Hessian of the Lagrangian | |
Public Member Functions | |
Problem ()=default | |
Problem (unsigned int n, unsigned int m) | |
Problem (unsigned n, unsigned int m, Box C, Box D, std::function< f_sig > f, std::function< grad_f_sig > grad_f, std::function< g_sig > g, std::function< grad_g_prod_sig > grad_g_prod, std::function< grad_gi_sig > grad_gi, std::function< hess_L_prod_sig > hess_L_prod, std::function< hess_L_sig > hess_L) | |
Public Attributes | |
unsigned int | n |
Number of decision variables, dimension of x. More... | |
unsigned int | m |
Number of constraints, dimension of g(x) and z. More... | |
Box | C |
Constraints of the decision variables, | |
Box | D |
Other constraints, | |
std::function< f_sig > | f |
Cost function | |
std::function< grad_f_sig > | grad_f |
Gradient of the cost function | |
std::function< g_sig > | g |
Constraint function | |
std::function< grad_g_prod_sig > | grad_g_prod |
Gradient of the constraint function times vector | |
std::function< grad_gi_sig > | grad_gi |
Gradient of a specific constraint | |
std::function< hess_L_prod_sig > | hess_L_prod |
Hessian of the Lagrangian function times vector | |
std::function< hess_L_sig > | hess_L |
Hessian of the Lagrangian function | |
Signature of the function that evaluates the cost
[in] | x | Decision variable |
Definition at line 35 of file include/alpaqa/util/problem.hpp.
using grad_f_sig = void(crvec x, rvec grad_fx) |
Signature of the function that evaluates the gradient of the cost function
[in] | x | Decision variable |
[out] | grad_fx | Gradient of cost function |
Definition at line 42 of file include/alpaqa/util/problem.hpp.
Signature of the function that evaluates the constraints
[in] | x | Decision variable |
[out] | gx | Value of the constraints |
Definition at line 48 of file include/alpaqa/util/problem.hpp.
using grad_g_prod_sig = void(crvec x, crvec y, rvec grad_gxy) |
Signature of the function that evaluates the gradient of the constraints times a vector
[in] | x | Decision variable |
[in] | y | Vector |
[out] | grad_gxy | Gradient of the constraints |
Definition at line 59 of file include/alpaqa/util/problem.hpp.
using grad_gi_sig = void(crvec x, unsigned i, rvec grad_gi) |
Signature of the function that evaluates the gradient of one specific constraints
[in] | x | Decision variable |
[in] | i | Which constraint |
[out] | grad_gi | Gradient of the constraint |
Definition at line 70 of file include/alpaqa/util/problem.hpp.
using hess_L_prod_sig = void(crvec x, crvec y, crvec v, rvec Hv) |
Signature of the function that evaluates the Hessian of the Lagrangian multiplied by a vector
[in] | x | Decision variable |
[in] | y | Lagrange multipliers |
[in] | v | Vector to multiply by |
[out] | Hv | Hessian-vector product |
Definition at line 83 of file include/alpaqa/util/problem.hpp.
using hess_L_sig = void(crvec x, crvec y, rmat H) |
Signature of the function that evaluates the Hessian of the Lagrangian
[in] | x | Decision variable |
[in] | y | Lagrange multipliers |
[out] | H | Hessian |
Definition at line 92 of file include/alpaqa/util/problem.hpp.
|
default |
|
inline |
Definition at line 111 of file include/alpaqa/util/problem.hpp.
|
inline |
Definition at line 114 of file include/alpaqa/util/problem.hpp.
unsigned int n |
Number of decision variables, dimension of x.
Definition at line 27 of file include/alpaqa/util/problem.hpp.
unsigned int m |
Number of constraints, dimension of g(x) and z.
Definition at line 28 of file include/alpaqa/util/problem.hpp.
Box C |
Constraints of the decision variables,
Definition at line 29 of file include/alpaqa/util/problem.hpp.
Box D |
Other constraints,
Definition at line 30 of file include/alpaqa/util/problem.hpp.
std::function<f_sig> f |
Cost function
Definition at line 95 of file include/alpaqa/util/problem.hpp.
std::function<grad_f_sig> grad_f |
Gradient of the cost function
Definition at line 97 of file include/alpaqa/util/problem.hpp.
std::function<g_sig> g |
Constraint function
Definition at line 99 of file include/alpaqa/util/problem.hpp.
std::function<grad_g_prod_sig> grad_g_prod |
Gradient of the constraint function times vector
Definition at line 101 of file include/alpaqa/util/problem.hpp.
std::function<grad_gi_sig> grad_gi |
Gradient of a specific constraint
Definition at line 103 of file include/alpaqa/util/problem.hpp.
std::function<hess_L_prod_sig> hess_L_prod |
Hessian of the Lagrangian function times vector
Definition at line 106 of file include/alpaqa/util/problem.hpp.
std::function<hess_L_sig> hess_L |
Hessian of the Lagrangian function
Definition at line 108 of file include/alpaqa/util/problem.hpp.