unscaled primal/dual violation Topic is solved

Solver related questions
Post Reply
Posts: 85
Joined: 1 year ago

unscaled primal/dual violation

Post by yanzhiping » 1 year ago

I tried Gurobi&Cplex in GAMS for a MILP problem.
I got infeasible message from Cplex that says
model has been proven infeasible.
But in Gurobi, it says
optimal objective XXXX
warning: unscaled primal violation = xxxxe-06 and residual = yyye-06
warning: unscaled dual violation=xxxxe-05 and residual yyye-05
So I am confused whether the optimal value found by Gurobi is the actual optimal objective or not. when either Cplex or Gurobi throws warning like this, can we accept the optimal value still?


User avatar
Posts: 198
Joined: 2 years ago

Re: unscaled primal/dual violation

Post by bussieck » 1 year ago


All solvers work with tolerances and suffer from rounding errors. There are cases where your model is on the brink of feasibility. Hence with some solver settings (or different solvers) you get an "optimal" solution with others the model is reported as infeasible. The Cplex guys have done a nice video about analyzing infeasible models. Perhaps this helps: https://www.youtube.com/watch?v=tUALbhJ2xWY


Post Reply