Skip to main content

Same results of optimization model for different function parameters - RHS of constraint?

Answered

Comments

3 comments

  • Official comment
    Simranjit Kaur
    • Gurobi Staff
    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?.
  • Jaromił Najman
    • Gurobi Staff

    I am not sure why this is happening, and therefore would like to investigate the RHS values of one constraint. How can I do this?

    You can access the RHS value of a constraint via the RHS attribute.

    If you want to access the value of the LHS of a constraint, you first have to get the LinExpr object representing it. You can obtain the LHS LinExpr object of a linear constraint via the getRow method.

    The procedure for getting the LHS value of quadratic constraint is the same but uses methods and objects specialized for quadratic terms.

    Best regards,
    Jaromił

    0
  • Pavithra Sreekumar
    • Gurobi-versary
    • Curious
    • Conversationalist

    Thanks a lot for your help Jaromil!

    Best Regards,

    Pavithra 

    0

Post is closed for comments.