Gurobi and second- order cone constraints.
AnsweredHello,
I have SOC constraints set in my model, and Gurobi can not solve it. I guess it could relate to the format of the constraint (the linear part), but I am not sure. This is the constraint:
where y, \tau, a, \rho, and \mu are variables. Can anyone help me?
Thank you
Nazanin
-
I stumbled onto this 6 months after the initial post. You might have gotten a faster response if you'd simplified the expression above by setting all your constraint values and your index sets to single items. If that doesn't fit Gurobi's SOC constraint format, then surely the more complicated expression above won't either. If I understand the above correctly, the simplest example would be something like this:
y^2 + s^2 + a +t <= vz
Looking at the accepted SOC/quadratic constraints listed in https://www.gurobi.com/documentation/9.0/refman/constraints.html, it looks like the problem is the two linear variables. Perhaps I've overlooked the appropriate transformation, but I don't see how to turn this into a second order cone. Yes, you could do some additional transformations:
w = a+t
y^2 + s^2 + w*r <= vz
r=1
But this is not a rotated cone, nor a second order cone. Are you sure you constraint is a true SOC? And note that SOCs also have some specific requirements on the nonnegativity of some of the variables.
Ed0
Please sign in to leave a comment.
Comments
1 comment