Multi-Objective Function
回答済みHello,
I'm currently trying to implement a dynamic optimization code (with Multi-Objective function) with Gurobi, except that it unfortunately works!
No concrete examples can be found in Gurobi's documentation. I don't know who to contact since I didn't find anything on google.
Please enlighten me further on this subject!
Thank you very much.
-
正式なコメント
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?. -
Have you had a chance to look at the example http://www.gurobi.com/documentation/8.1/examples/multiobj_py.html ?
# Set and configure i-th objective for i in Subsets: objn = sum(Elem[k]*Set[i][k] for k in range(len(Elem))) model.setObjectiveN(objn, i, SetObjPriority[i], SetObjWeight[i], 1.0 + i, 0.01, 'Set' + str(i))
0 -
I don't know how to introduce "setObjectiveN(____)" in my code.
I tried as much as I did in the capture I shared but without result.
0 -
Hi Aziz,
See the documentation here: http://www.gurobi.com/documentation/8.1/refman/py_model_setobjectiven.html
You do not have to specify the sense of the objective (you can set the overall sense of the model http://www.gurobi.com/documentation/8.1/refman/modelsense.html#attr:ModelSense).
You probably want to set
m.setObjectiveN(DEUD1[0] * u3 + DEUD2 * v3, index=0, priority=2)
m.setObjectiveN(FRAF1[0] * x3 + aaaa * y3 + FRAF3[0] * z3, index=1, priority=1)0
投稿コメントは受け付けていません。
コメント
4件のコメント