Gurobi Matlab interface - Detected INFEASIBILITY when the problem should be feasible

83 views
Skip to first unread message

Domenico Cappello

unread,
May 17, 2016, 1:20:58 PM5/17/16
to Gurobi Optimization
Hello,
I am working on an implementation of a control law based on the Model Predictive Control algorithm in Matlab.
This algorithm involves the resolution of an optimal control problem at each sampling interval, and it generally performed very well using Gurobi as the solver.

For certain instances of the problem, Gurobi cannot find a feasible solution even when the feasible set must be non-empty.

So I was wondering:
1) What is the default precision for floating point representation used by the Gurobi matlab interface for real variables?
2) What is the maximum value that a real variable can take?
3) How can I access to these parameters?

Thank you.

Renan Garcia

unread,
May 17, 2016, 2:25:28 PM5/17/16
to gur...@googlegroups.com
1) What is the default precision for floating point representation used by the Gurobi matlab interface for real variables?


2) What is the maximum value that a real variable can take?

This is system dependent, but it's typically 1.79769e+308. However, Gurobi will treat anything larger than 1e+100 as infinite. Beware, though, that large matrix coefficient ranges can have an impact on solution quality. For more information, please refer to the pdf at:


3) How can I access to these parameters?

More precision is better (i.e., double vs single), so you wouldn't want to change the default precision.

Domenico Cappello

unread,
May 18, 2016, 8:01:33 AM5/18/16
to Gurobi Optimization
Thank you for your answers.

Currently I am solving this two convex problems one after the other:

[x*,y*] = argmin f(x,y)
s.t.
x \in X
y \in Y(x)

y_opt = argmin g(y)
s.t.
y \in Y(x*)

Actually, there are a few cases in which the first problem is solved, but the second one cannot be solved by Gurobi due to infeasibility, even if I set the initial guess as y = y*.
When a solution to the second problem cannot be found, if I take a look to the 'qcslack' field of the first problem's result, there are some negative slack variables.
Is Gurobi using different tolerances for asserting the feasibility of the initial guess and that of a computed solution?

Renan Garcia

unread,
May 18, 2016, 9:01:20 AM5/18/16
to gur...@googlegroups.com
When solving models in finite precision, Gurobi (along with most solvers) allows for small violations in the constraints. This is configurable through the FeasibilityTol parameter (see http://www.gurobi.com/documentation/6.5/refman/feasibilitytol.html#parameter:FeasibilityTol). If the violations in your initial model are larger than this tolerance, this could indicate your model has numerical issues. Please refer to the PDF I linked for more details.

--

---
You received this message because you are subscribed to the Google Groups "Gurobi Optimization" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gurobi+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages