ax + y + x > 0 Not supported by gurobi?

280 views
Skip to first unread message

Debjyoti Bhattacharjee

unread,
Jun 3, 2016, 12:28:55 AM6/3/16
to Gurobi Optimization
Hi,

I have the following constraint in my model.
m.addConstr(10000*y + w11 - v21 > 0, 'c_my121_1')

y is a binary variable, w11 and v21 are integers.

I am getting the following error -
 gurobipy.LinExpr.__richcmp__ (../../src/python/gurobipy.c:27710) NotImplementedError

Can someone kindly help to transform it into a form that gurobi can solve?
 

Tobias Achterberg

unread,
Jun 3, 2016, 2:57:20 AM6/3/16
to gur...@googlegroups.com
My guess is that this is due to the strict inequality you are using. This is not
possible with MIP solvers. But fortunately, all the variables in your constraint
are integer so that you can equivalently write

m.addConstr(10000*y + w11 - v21 >= 1, 'c_my121_1')


Regards,

Tobias
Reply all
Reply to author
Forward
0 new messages