Skip to main content

Get relaxed solution value in callback MIPNODE

Answered

Comments

4 comments

  • Official comment
    Simranjit Kaur
    • Gurobi Staff
    This post is more than two 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 try Gurobot, our chatbot interface offering instant, expert-level support.
  • Jaromił Najman
    • Gurobi Staff

    To access the node relaxation solution through the JAVA API, you have to use the GRBCallback.getNodeRel() method.

    0
  • Lorenzo Moreschini
    • Gurobi-versary
    • Investigator
    • Conversationalist

    In that way I still have to compute the obj function value, is there any shortcut? (a workaround could be to assign the obj function to a single variable and then read its relaxed value...)

    0
  • Jaromił Najman
    • Gurobi Staff

    In that way I still have to compute the obj function value, is there any shortcut? (a workaround could be to assign the obj function to a single variable and then read its relaxed value...)

    Unfortunately, there is currently no shortcut. Introducing an auxiliary variable to capture the value of the objective function is the correct way to go here.

    0

Post is closed for comments.