![]() |
Sleipnir C++ API
|
#include <sleipnir/optimization/solver/options.hpp>
Public Attributes | |
double | tolerance = 1e-8 |
The solver will stop once the error is below this tolerance. | |
int | max_iterations = 5000 |
The maximum number of solver iterations before returning a solution. | |
std::chrono::duration< double > | timeout |
The maximum elapsed wall clock time before returning a solution. | |
bool | feasible_ipm = false |
bool | diagnostics = false |
bool | spy = false |
Solver options.
bool slp::Options::diagnostics = false |
Enables diagnostic prints.
Heading | Description |
---|---|
iter | Iteration number |
type | Iteration type (normal, accepted second-order correction, rejected second-order correction) |
time (ms) | Duration of iteration in milliseconds |
error | Error estimate |
cost | Cost function value at current iterate |
infeas. | Constraint infeasibility at current iterate |
complement. | Complementary slackness at current iterate (sᵀz) |
μ | Barrier parameter |
reg | Iteration matrix regularization |
primal α | Primal step size |
dual α | Dual step size |
↩ | Number of line search backtracks |
bool slp::Options::feasible_ipm = false |
Enables the feasible interior-point method. When the inequality constraints are all feasible, step sizes are reduced when necessary to prevent them becoming infeasible again. This is useful when parts of the problem are ill-conditioned in infeasible regions (e.g., square root of a negative value). This can slow or prevent progress toward a solution though, so only enable it if necessary.
bool slp::Options::spy = false |
Enables writing sparsity patterns of H, Aₑ, and Aᵢ to files named H.spy, A_e.spy, and A_i.spy respectively during solve.
Use tools/spy.py to plot them.
std::chrono::duration<double> slp::Options::timeout |
The maximum elapsed wall clock time before returning a solution.