-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to use feasRelax in Gurobi ? #407
Comments
Use the C API: https://www.gurobi.com/documentation/9.1/refman/c_feasrelax.html using JuMP, Gurobi
jump_model = direct_model(Gurobi.Optimizer())
model = backend(jump_model) Then pass Gurobi.jl/src/gen91/libgrb_api.jl Lines 301 to 303 in d9cebe4
You should be aware that this operation is advanced, and that Gurobi.jl is not officially supported by Gurobi. |
Thanks for your help. But in Gurobi documents, it have 2 signatures for this method, as i can see in the function above is the simpler one. Can i call out the more complex one to specify extractly which contraints should be violated? |
There is only one signature in the Gurobi documentation, which is identical to this one. using JuMP, Gurobi
jump_model = direct_model(Gurobi.Optimizer())
model = backend(jump_model)
penalties = Cdouble[]
error = GRBfeasrelax(model, 0, 0, C_NULL, C_NULL, penalties, C_NULL) |
Sorry, i read that method in C++API. Thank you so much for your help. |
I have some constraints that should be allowed to be violated for creating a feasibility relaxation. How can i use C API GRBModel::feasRelax() to do that?
The text was updated successfully, but these errors were encountered: