Modeling of conditional constraints
回答済みHi,
Is there any way to modeling a conditional constraint like follows:
if x > X0, then y = 1
if x = X0, then y = 0
where x and y are decision variables, and X0 is a predefined constant number.
Thanks.
0
-
正式なコメント
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?. -
Hi,
This stackexchange post should answer your question How to write if else statement in linear programming?
Note that strict inequalities are not allowed in (mixed-integer) linear programming due to compactness assumptions.
Best regards,
Jaromił0 -
Hi Jaromił,
Many thanks for your answer.
Kind regards,
Yongning
0
投稿コメントは受け付けていません。
コメント
3件のコメント