classmethod Objective.message()
用法
v = message
說明
message
獲取最近使用此目標求解後求解器返回的結果消息。僅對標量目標有效。
輸出參數
v
在最近使用此目標求解後求解器返回的結果消息
示例
創建一個目標 z 並顯示其信息。然後解決問題並再次顯示。
ampl.eval('var x{i in 1..2} <= i;');
ampl.eval('maximize z: sum{i in 1..2} x[i];');
z = ampl.getObjective('z')
z.message
ampl.solve;
z.message
給出:
ans =
?
ans =
CBC 2.8.2 optimal, objective -3
0 iterations
相關用法
- Matlab AMPL Objective.astatus用法及代碼示例
- Matlab AMPL Objective.value用法及代碼示例
- Matlab AMPL Objective.get用法及代碼示例
- Matlab AMPL Objective.result用法及代碼示例
- Matlab AMPL Objective.exitcode用法及代碼示例
- Matlab AMPL Objective.getValues用法及代碼示例
- Matlab AMPL ObjectiveInstance.value用法及代碼示例
- Matlab AMPL ObjectiveInstance.astatus用法及代碼示例
- Matlab AMPL ObjectiveInstance.message用法及代碼示例
- Matlab AMPL ObjectiveInstance.result用法及代碼示例
- Matlab AMPL ObjectiveInstance.exitcode用法及代碼示例
- Matlab AMPL ConstraintInstance.lb用法及代碼示例
- Matlab AMPL ConstraintInstance.ub用法及代碼示例
- Matlab AMPL VariableInstance.ub用法及代碼示例
- Matlab AMPL Constraint.body用法及代碼示例
- Matlab AMPL Parameter.hasDefault用法及代碼示例
- Matlab AMPL SetInstance.contains用法及代碼示例
- Matlab AMPL Variable.getIntegrality用法及代碼示例
- Matlab AMPL DataFrame.setMatrix用法及代碼示例
- Matlab AMPL Parameter.set用法及代碼示例
注:本文由純淨天空篩選整理自ampl.com大神的英文原創作品 message。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。