Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.

 View Only
Expand all | Collapse all

Polishing CP Optimizer Solutions

  • 1.  Polishing CP Optimizer Solutions

    Posted Wed September 09, 2015 01:42 PM

    Originally posted by: AdamGregory


    Hi everyone,

    I'm working on a complex scheduling problem where the ideal turnaround time for determining the optimal schedule is very short. Because of the size of the solution space and the time constraints for the problem, I do not believe it is possible to allow the solver to complete normally. Instead I believe I need to limit the optimizer to stop after a certain point. I notice that there are several ways to limit the optimizer solve time: timeLimit, branchLimit, failLimit, etc. can all be used to terminate the optimizer prematurely and work with the best solution found so far.

    However, the schedule produced when the solver is terminated by limit is often obviously non optimal. It would be trivial to improve the objective function working from the provided schedule. For example, my model includes a set of optional interval with a penalty for each interval included. The solution found when the solver is terminated by a limit will often include a number of optional intervals with size 0--the penalty is included, but the intervals do not contribute any way to the solution. The objective function could be improved by removing these unnecessary intervals from the schedule.

    I notice that for MILP problems using CPLEX there is an option to polish a solution, but I can not see any similar option available for CP problems. Is it possible to polish solutions found by the CP optimizer when the solver is terminated by a limit? Or is there an alternative way to achieve the desired result?

    Thank you,
    Adam


    #CPOptimizer
    #DecisionOptimization


  • 2.  Re: Polishing CP Optimizer Solutions

    Posted Fri September 11, 2015 04:28 AM

    Originally posted by: Petr Vilím


    Hello,

    I'm only guessing, but isn't your objective function quite complicated? I.e. there is probably also something else in the objective aside the penalties for execution of some interval variables.

    The default behavior of CP Optimizer is to set as much interval variables as present as possible. I.e. it is the first thing the solver tries. Sometimes, CP Optimizer can recognize that it is better not to execute an interval variable and then it first tries to set it as absent. But it works only if the objective is simple enough.

    There is no direct polishing functionality in CP Optimizer. I would suggest to reoptimize again with simplified objective function. Starting point functionality is an obvious choice. But you can do probably even better. Before resolving (with the starting point) you can fix the dates in the model, but keep interval variables optional. This way the second solve can only set some interval variables to absent.

    It depends on how much you want to polish. In general, if you can recognize some parts of the solution as "good" then it is better to stick with it by assigning the value to the variable(s). It drastically reduces the search space. The values for the remaining variables can be set in the starting point.

    I hope it helps, Petr


    #CPOptimizer
    #DecisionOptimization