pyomo icon indicating copy to clipboard operation
pyomo copied to clipboard

Enable Extreme Ray Retrieval e.g. from Gurobi

Open maximilian-hoffmann opened this issue 2 years ago • 1 comments

For Benders decomposition, extreme rays need to be retrieved from unbounded sub-problems to add feasibility cuts to the master problem. However, the example on Benders decomposition from Pyomo https://github.com/Pyomo/pyomo/blob/main/examples/pyomo/benders/runbenders seems to consider dual variables for optimality cuts only. Is there a generic way (just like for dual variables) to also access extreme rays in case of unboundedness? If not, an implementation would be very beneficial. E.g. Gurobi can return extreme rays and Farkas Duals https://support.gurobi.com/hc/en-us/community/posts/360078072572-FarkasDual-and-FarkasProof and it would be great if these options could also be handled by Pyomo.

Best, Max

maximilian-hoffmann avatar Jul 06 '23 21:07 maximilian-hoffmann

See these methods on the persistent interface to Gurobi:

https://github.com/Pyomo/pyomo/blob/be93e575f9b3075f9427411f00c574025d560cc2/pyomo/contrib/appsi/solvers/gurobi.py#L1152

https://github.com/Pyomo/pyomo/blob/be93e575f9b3075f9427411f00c574025d560cc2/pyomo/contrib/appsi/solvers/gurobi.py#L1240

https://github.com/Pyomo/pyomo/blob/be93e575f9b3075f9427411f00c574025d560cc2/pyomo/contrib/appsi/solvers/gurobi.py#L1256

michaelbynum avatar Jul 18 '23 18:07 michaelbynum