It is not often that I can use a XOR in a GAMS model. But here we are..
I am working on some tools for a randomized algorithm for a multi-criteria 0-1 problem. As the algorithm can produce duplicate points we want a simple way to filter these out.
loop(pmax, |
The results look like:
---- 54 PARAMETER solpool solution pool of unique solutions i1 i2 i3 i4 i5 count |
Of course instead of the XOR we could have written:
dup(p) = not sum(i$(x.l(i)<>solpool(p,i)),1);
No comments:
Post a Comment