Skip to main content

How do I model if and only if statements in Gurobi

Answered

Comments

3 comments

  • Jaromił Najman
    Gurobi Staff Gurobi Staff

    Hi Anggita,

    We discuss how to debug a key error in the Knowledge Base article Tutorial: Preparing a Minimal Reproducible Example.

    Best regards, 
    Jaromił

    0
  • Anggita Ketlin Bella Pratiwi
    First Comment
    First Question

    Hi, I want to ask more. To describe conditional statements whether there are additional indicator limits besides this

    m.addConstr((b == 1 ) >> (z == w1), name= "indicator_constr1" )
    m.addConstr((b == 0 ) >> (z == w2), nama= "indicator_constr2" )
    0
  • Jaromił Najman
    Gurobi Staff Gurobi Staff

    To describe conditional statements whether there are additional indicator limits besides this

    Could you elaborate what exactly you mean by "additional indicator limits"?

    Maybe the Knowledge Base article How do I model conditional statements in Gurobi? can help.

    0

Please sign in to leave a comment.