Add nonlinear optimization constraint
Hi, I need to add the following optimization constraint:
Where
and M_j is a decision variable included in the objective function (MINIMIZE).
instead of using the square root of N_j I added a new auxiliar decision variable Nr_j as
Nr_j * Nr_j = N_j but an error occurred:
GurobiError: Invalid argument to QuadExpr multiplication
Does anyone know how to include it, please?
Thank you.
0
-
Official comment
This post is more than three 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 why not try our AI Gurobot?. -
What data type is Nr_j and N_j?
0 -
N_j is integer and Nr would be continuous
0 -
I should have been more specific, scalar or vector, numpy, sciPy arrays, Mvar?
Could you also add your code here for us to review?
0
Post is closed for comments.
Comments
4 comments