Hi,
I have a 4-objective optimization model using Gurobi, and there was the optimal solution when I set the poriority of one order (e.g. [4,3,2,1]). but when the priority changes ((e.g. [2,3,4,1])), the optimal solution cannot be obtained.
Below is the simple code I set and ran. Is there any wrong with this set?
using JuMP, Gurobi
import MultiObjectiveAlgorithms as MOA
model = Model()
@variable(…)
@constraint(…)
@expression(model,f1,…)
@expression(model,f2,…)
@expression(model,f3,…)
@expression(model,f4,…)
@objective(model,Min,[f1, f2, f3, f4])
set_optimizer(model, () -> MOA.Optimizer(Gurobi.Optimizer))
set_attribute(model, MOA.Algorithm(), MOA.Hierarchical())
set_attribute(model, MOA.ObjectivePriority(1), 4)
set_attribute(model, MOA.ObjectivePriority(2), 3)
set_attribute(model, MOA.ObjectivePriority(3), 2)
set_attribute(model, MOA.ObjectivePriority(4), 1)
optimize!(model)
And below is the output when there was no optimal solution.
Optimize a model with 2054 rows, 13260 columns and 46184 nonzeros
Coefficient statistics:
Matrix range [1e+00, 5e+10]
Objective range [1e+00, 5e+06]
Bounds range [1e+00, 1e+00]
RHS range [1e+00, 1e+11]
Warning: Model contains large matrix coefficients
Warning: Model contains large rhs
Consider reformulating model or setting NumericFocus parameter to avoid numerical issues.
LP warm-start: use basis
Warning: Markowitz tolerance tightened to 0.03125
Iteration Objective Primal Inf. Dual Inf. Time
0 -1.6384000e+34 7.420476e+36 1.638400e+04 0s
1 9.7566885e+07 0.000000e+00 0.000000e+00 0s
Solved in 1 iterations and 0.02 seconds (0.00 work units)
Optimal objective 9.756688463e+07
User-callback calls 27, time in user-callback 0.00 sec
Gurobi Optimizer version 11.0.0 build v11.0.0rc2 (win64 - Windows 10.0
(19045.2))
CPU model: Intel(R) Xeon(R) CPU E5-1620 v4 @ 3.50GHz, instruction set [SSE2|AVX|AVX2]
Thread count: 4 physical cores, 8 logical processors, using up to 4 threads
Optimize a model with 2055 rows, 13260 columns and 59444 nonzeros
Coefficient statistics:
Matrix range [1e+00, 5e+10]
Objective range [4e+05, 1e+13]
Bounds range [1e+00, 1e+00]
RHS range [1e+00, 1e+11]
Warning: Model contains large matrix coefficients
Warning: Model contains large objective coefficients
Warning: Model contains large rhs
Consider reformulating model or setting NumericFocus parameter to avoid numerical issues.
LP warm-start: use basis
Iteration Objective Primal Inf. Dual Inf. Time
0 -1.2542692e+40 4.531669e+33 1.254269e+10 0s
Solved in 1850 iterations and 0.09 seconds (0.11 work units)
Infeasible model
User-callback calls 1879, time in user-callback 0.00 sec
Thanks.