Unbounded Ray
AnsweredHello,
I have a problem and I am using Bender's Decomposition to solve it. This is my subproblem which gets unbounded:

I want to get the unboundedness ray to add it to the master problem's feasibility cut as below:

Note that I = 238, J = 19, K = 15. So I have 4522 q(ij)s, 4522 p(ij)s, and 19 r(j)s. (Totally 9063 variables)
I am using UnbdRay function as below:
-
Official comment
This post is more than two years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum, or try Gurobot, our chatbot interface offering instant, expert-level support. -
Hi Mina,
I guess your question is how to obtain the unbounded ray for one particular variable, right?
You can access the UnbdRay attribute directly for each variable viavar.UnbdRay
In your code, it seems you want to access the UnbdRay attribute for the whole variable array (sp1?) in one step.
How did you create your variables? If you created them via addVars() liker = model.addVars(J, ...)
p = model.addVars(I, J, ...)
q = model.addVars(I, J, ...)with I and J being the index sets for your constraints, then you can access the attribute via
q[i,j].UnbdRay
for one particular index i and index j. With this, you can build your feasibility cut.
Best regards,
Mario0
Post is closed for comments.
Comments
2 comments