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

Using "addGenConstrPow" but model is infeasible

回答済み

コメント

4件のコメント

  • 正式なコメント
    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

    Hi Jack,

    The issue is caused by the default value of the FuncMaxVal parameter which is 1e+6. This limits the bounds on variables participating in general constraints, but \(220^4 > 10^6\). Thus, your model is declared as infeasible.

    To avoid this, you have to set the parameter to a larger value, e.g.,

    model.setParam("FuncMaxVal",10e+20)

    Please note that working with such large values is not recommended. So, if you want to extend your model and indeed work with the value of \(\texttt{x_pow4}\) in an extension of your model, then this might very likely lead to numerical issues.

    Best regards, 
    Jaromił

    0
  • Jack Kaz
    • Gurobi-versary
    • First Comment
    • First Question

    Hi Jaromil,

    thank you very much for your advice!

    Unfortunately, we have this big values in thermodynamics when working with absolute temperatures.. Is there a suggestion to reduce the possibility of numerical issues? I was thinking of a way to limit the value range of the function.. or is it done when defining upper and lower bounds to the variables?

    0
  • Jaromił Najman
    • Gurobi Staff

    Hi Jack,

    Unfortunately, we have this big values in thermodynamics when working with absolute temperatures.. Is there a suggestion to reduce the possibility of numerical issues? I was thinking of a way to limit the value range of the function.. or is it done when defining upper and lower bounds to the variables?

    I understand. You could re-scale the orders of magnitude, e.g., say that 1 unit for some variable equals 1000 degrees instead of 1. This would already scale the values by 4 orders of magnitude. For more detailed tips, please have a look at our Guidelines for Numerical Issues.

    0

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