Originally posted by: AshishS
Hi,
I am working with an OPL model in CPLEX Optimization Studio 12.2, being solved with the CP Optimizer. I would like to customize search using the search phase functionality provided in OPL, to something like the following:
variables: x[1] through x[10], each with domain {0..5}.
variable selection: smallest to largest
value selection: select 0 if it is in the domain; select a random value otherwise
Looks like f.selectLargest(f.varIndex(x)), where f is cp.factory, will achieve the desired variable selection if I add it to an execute block before the model constraints. However, I don't see how to define a simple value selection heuristic such as the above. f.explicitValueEval(...) appears to be useful, but the documentation doesn't quite explain it.
Any help would be greatly appreciated!
Ashish
#CPOptimizer#DecisionOptimization