Skip to content
Snippets Groups Projects
Commit 9b38d66a authored by oliver.sander_at_tu-dresden.de's avatar oliver.sander_at_tu-dresden.de
Browse files

IPOpt: Call Infeasibilities with five arguments

Starting with IPOpt 3.14 there is an overload of the Infeasibilities
method with five arguments. The old one with four arguments still
exists, but using it triggers a deprecation warning.

Use the new method if the IPOpt version is high enough.
parent e6c980fb
Branches
No related tags found
1 merge request!80Minor fixes for finding IPOpt
Pipeline #65300 passed
......@@ -815,11 +815,17 @@ void QuadraticIPOptSolver<MatrixType,VectorType,JacobianType>::solve()
else if (status == Ipopt::Search_Direction_Becomes_Too_Small) {
Ipopt::Number dual_inf; // dual infeasibility (Gradient of Lagrangian not zero)
Ipopt::Number constr_viol; // violation of constraints
#if IPOPT_VERSION_MAJOR>=3 && IPOPT_VERSION_MINOR>=14
Ipopt::Number varbounds_viol; // violation of variable bounds
#endif
Ipopt::Number complementarity; // violation of complementarity
Ipopt::Number kkt_error; // KKT error
app->Statistics()->Infeasibilities(dual_inf,
constr_viol,
#if IPOPT_VERSION_MAJOR>=3 && IPOPT_VERSION_MINOR>=14
varbounds_viol,
#endif
complementarity,
kkt_error);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment