Originally posted by: SystemAdmin
Hi everybody,
When one tries to write a customized neighborhood as far as I could understand it has to be done using IloNHoodI.
Almost every thing is done in
define(). Now the problem is the following:
Assume I have a representation of my current solution as
a,b,c,pivot,d,e. if neighbors are defined to be swapping every two elements either of which from left side of pivot and the other one on the right hand side then depending on where pivot is I have different neighborhood seizes for every
current solution.
As an example the cardinalities of sets of neighbors of
a,b,c,pivot,d,e and
a,b,c,d,pivot,e with respect to the swap move I mentioned are not the same.
On the other hand, another function of a derived class from IloNHoodI is
getSize()
which must know in advance how many time
define()
must be called. That means it must know what is the size of my neighborhood.
Now, I am in trouble that I do not have a unique size.
Is there any workaround for this?
Any comment is appreciated.
#CPOptimizer#DecisionOptimization