A C++17 library for solving constrained optimization problems.
This project currently implements a Sequential Quadratic Programming (SQP) method for solving nonlinear programs (NLP's). On each iteration of the SQP solver, the optimization problem is approximated with a quadratic cost and linear constraints. This quadratic subproblem is then passed to a QP solver which solves for the next step in the decision variables. This is repeated until the convergence criteria are met. OSQP is used to solve the quadratic subproblems in this project using the osqp-cpp interface.
The interface is defined in opt_problem.hpp in the SqpProblem class. Override the functions in this class to implement your own objective and constraint functions and their hessian and gradients. Examples of this are given in example_prob.hpp/.cpp.
From the root directory of this project:
mkdir build cd build cmake .. make
To run the examples (from the build directory):
./run_examples
Cornell University Computational Optimization Open Textbook
https://en.wikipedia.org/wiki/Sequential_quadratic_programming