メインコンテンツへスキップ

How to solve different objective function at the same time (with the same set of constraints)?

回答済み

コメント

2件のコメント

  • 正式なコメント
    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 try Gurobot, our chatbot interface offering instant, expert-level support.
  • Jaromił Najman
    • Gurobi Staff

    Hi,

    Each process has to hold its own Gurobi model. What you could try is constructing the constraints on each process or construct the model in one process together with a given objective and then use the GRBcopymodel method to construct a model copy and pass it to another process.

    Since constraints have to be added to the model sequentially anyway, I would recommend constructing the model in each independent process. You can write a method which adds the constraints to the model and call it in each independent process to have a clean code.

    You could also consider using the Multiple Scenarios feature provided by Gurobi.

    Best regards,
    Jaromił

    0

投稿コメントは受け付けていません。