Skip to main content

Converting equations into constraints

Answered

Comments

1 comment

  • Marika Karbstein
    • Gurobi Staff

    Your constraints look ok. But you also need to define your decision variables as Gurobi variables, for example

    Q_ug = m.addVars(u, g, vtype=gp.GRB.INTEGER, name="Q_ug")

    You can also write a model file in the end with m.write("Test.lp") and check if the formulation looks like you expected.


    0

Please sign in to leave a comment.