Hello Daniele,

*  The routine ios_relative_gap computes the relative mip gap using the
*  formula:
*
*     gap = |best_mip - best_bnd| / (|best_mip| + DBL_EPSILON)

Minimization example:
- Best integer solution 2
- Best bound -1.3
=> Gap = (2 - -1.3) / 2 = 1.65

If you called
glpsol --mipgap 1.7 -m problem.mod
the solver would stop with this soution.

Beware: The mip gap may rise while you solution gets better:

Integer optimization begins...
+   213: mip =     not found yet <=              +inf        (1; 0)
+   481: >>>>>  -4.000000000e+00 <=   7.000000000e+00 275.0% (10; 0)
+   875: >>>>>  -3.000000000e+00 <=   2.600000000e+00 186.7% (15; 3)
+  1215: >>>>>  -1.000000000e+00 <=   1.000000000e+00 200.0% (15; 11)
+  1397: mip =  -1.000000000e+00 <=     tree is empty   0.0% (0; 47)
INTEGER OPTIMAL SOLUTION FOUND

The mip gap rose from 1.867 to 2. while the objective rose from -3 to -1
in this maximization problem.

Best regards

Xypron



On 30.07.2012 16:22, Daniele Micarelli wrote:
> hi
> I wanted to know more precisely what is the command: *mipgap tol*
>
>
> and the number that goes in place of tol to indicate precisely what is?
>
> thank you very much
>
>
> _______________________________________________
> Help-glpk mailing list
> [email protected]
> https://lists.gnu.org/mailman/listinfo/help-glpk

_______________________________________________
Help-glpk mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-glpk

Reply via email to