Pinned topic How to detect proven solution in cp
I'm trying to combine MIP and CP using opl. I have an algorithm and I want to stop it when CP found a proven optimal rather than terminated by fail limit or stg else.
CP shows if it is proven solution, but how can I represent it with opl?
Does anyone know an opl parameter something like above?
rdumeur 270002SSEV67 Posts
Re: How to detect proven solution in cp2013-05-10T14:13:11ZThis is the accepted answer. This is the accepted answer.
Sorry for the late answer. As you may have found by yourself, optimality is proven by letting the solver run without specifying any limit.
That is if you invoke solve() on the solver, it will run until optimality is reached. If you use startNewSearch() and next(), you will possibly obtain multiple solutions until next() returns false. In which case, the latest obtained solution is optimal.
I hope this helps,