Gurobi's multi-objective feature can handle more than one objective function in several of the ways that are envisioned by goal programming. To use this feature, you will need to first specify
option gurobi_options 'multiobj=1';
or, if you are already defining a gurobi_options string, add multiobj=1 to it. Then you will need to use suffix commands to define some suffixes, which may include the following:
suffix objpriority IN;
suffix objweight IN;
suffix objreltol IN;
suffix objabstol IN;
As an example, suppose you have used AMPL "minimize" statements to define three objective functions, A, B, and C. If you want Gurobi to minimize a weighted combination 8*A + 2*B + C, use AMPL "let" statements to assign objweight values to the objectives:
let A.objweight := 8;
let B.objweight := 2;
let C.objweight := 1;
Or, if you want Gurobi to first minimize A, then fix A at its minimum value and minimize B, then also fix B at its minimum value and minimize C, you can assign objpriority values to the objectives:
let A.objpriority := 3;
let B.objpriority := 2;
let C.objpriority := 1;
You can use any integers as objpriority values; the objective with the highest priority is minimized first, then the objective with the next highest priority, and so forth. Gurobi also offers two generalizations of this approach:
- If two objectives have the same priority, then their weighted sum is minimized, using weights given by objweight. For example if B.objpriority is set instead to 1 above, then after A is minimized, Gurobi fixes A at its minimum value and minimizes 2*B + C.
- You can assign an objreltol or objabstol value to an objective to allow its objective value to be degraded by a limited amount when lower-priority objectives are optimized. For example, if in addition to the priorities shown above, you set A.objreltol to 0.05, then instead of fixing A at its minimum value, Gurobi adds a constraint that A's value must be <= its minimum value plus 5%. Or, if you set A.objabstol to 100, then instead of fixing A at its minimum value, Gurobi adds a constraint that A's value must be <= its minimum value plus 100.
These generalizations can be combined to specify a variety of ways in which objective functions are handled. Also the same ideas apply to maximized objective functions.
--
Robert Fourer
am...@googlegroups.com