JuliaOpt / MathProgBase.jl

DEPRECATED: Solver-independent functions (i.e. linprog and mixintprog) and low-level interface for Mathematical Programming
Other
80 stars 38 forks source link

Extend support of LinearQuadratic interface in NonlinearToLPQPBridge. #229

Closed martinbiel closed 5 years ago

martinbiel commented 5 years ago

I had a use case for setobj!, addconstr!, addvar!, delconstrs! when solving a quadratic program with Ipopt, which was not supported in the NonlinearToLPQPBridge. This adds support for most of the LinearQuadratic interface functions in the NonlinearToLPQPBridge and should be functional with Ipopt at least. I have my fork as a test dependency at the moment, but I thought this could be useful for others as well.

I Added a linprogsolvertest of IpoptSolver, with absolute tolerance 1e-5 as in nlp tests (I had to pass fixed_variable_treatment="make_constraint" to Ipopt to get correct reduced costs in the fixed variable case).

Passes all tests locally.

mlubin commented 5 years ago

LGTM! I'm not pointing out style issues since MPB is deprecated and will be replaced by MOI.