User Tools

Site Tools


solver:terminate_the_optimization_after_gams_cplex_reaches_a_certain_value_of_the_objective

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
solver:terminate_the_optimization_after_gams_cplex_reaches_a_certain_value_of_the_objective [2016/02/25 17:05]
admin
solver:terminate_the_optimization_after_gams_cplex_reaches_a_certain_value_of_the_objective [2017/09/02 19:37] (current)
support
Line 1: Line 1:
 ====== Terminate the optimization after GAMS/CPLEX reaches a certain value of the objective ====== ====== Terminate the optimization after GAMS/CPLEX reaches a certain value of the objective ======
-The example model below shows how to interact with CPLEX  that it stops pretty much after CPLEX found the solution value 21 (or larger). This is done in using the same mechanism as described in "[[http://​www.gams.com/​docs/​bch.htm|The GAMS Branch-and-Cut-and-Heuristic Facility]]"​.+The example model below shows how to interact with CPLEX  that it stops pretty much after CPLEX found the solution value 21 (or larger). This is done in using the same mechanism as described in "[[https://​www.gams.com/latest/docs/UG_SolverUsage.html#​ADVANCED_USAGE_BCHFacility|The GAMS Branch-and-Cut-and-Heuristic Facility]]"​.
  
 First we have userincbicall which is called every time we find a new incumbent. We are also in ”interactive” mode, meaning that we accept new options on the fly. The trigger for reading in new options is a trigger file called readop2. This is created by the incumbent checking routine only if we reached 21 or higher. The Cplex option sets a very large optca (Cplex name for it is epagap), so we should terminate immediately. The iatriggertime is set to 1 meaning that Cplex checks every second if there is a triggerfile. This should be set to larger values (60 seconds or so) for real models. This can be used effieciently,​ for example, in the case when a model is decomposed into sub-models. When a sub-model is solved then the solution can be used in the other sub-models to create a integer cut, hence the solution speed is improved. First we have userincbicall which is called every time we find a new incumbent. We are also in ”interactive” mode, meaning that we accept new options on the fly. The trigger for reading in new options is a trigger file called readop2. This is created by the incumbent checking routine only if we reached 21 or higher. The Cplex option sets a very large optca (Cplex name for it is epagap), so we should terminate immediately. The iatriggertime is set to 1 meaning that Cplex checks every second if there is a triggerfile. This should be set to larger values (60 seconds or so) for real models. This can be used effieciently,​ for example, in the case when a model is decomposed into sub-models. When a sub-model is solved then the solution can be used in the other sub-models to create a integer cut, hence the solution speed is improved.
IMPRESSUM / LEGAL NOTICEPRIVACY POLICY solver/terminate_the_optimization_after_gams_cplex_reaches_a_certain_value_of_the_objective.txt · Last modified: 2017/09/02 19:37 by support