Commit 7f03035d authored by Ramon's avatar Ramon
Browse files

fixed a very stupid typo-bug

parent 9011b009
Pipeline #2735 skipped
......@@ -146,20 +146,11 @@ public class ChocoWrapper {
constraints = constraints.prepareForSolver();
solver.post(arithm(toVar(constraints), Choco.EQ, 1));
if (useRandomisation) {
IntVar randomOptimization = distToRandomPoint();
IntVar randomOptimization = distToRandomPoint();
if (randomOptimization != null) {
solver.findOptimalSolution(ResolutionPolicy.MINIMIZE, randomOptimization);
}
}
/*if (random != null) {
Collection<Variable> varCollection = this.chocoVars.values();
IntVar[] vars = new IntVar[varCollection.size()];
int i = 0;
for (Variable var : this.chocoVars.values()) {
vars[i++] = (IntVar) var;
}
solver.set(ISF.custom(ISF.random_var_selector(random.nextLong()), ISF.random_value_selector(random.nextLong()), vars));
}*/
if (!solver.findSolution()) {
return null;
}
......@@ -307,7 +298,7 @@ public class ChocoWrapper {
left = toVar(binExpr.getLeftChild());
right = toVar(binExpr.getRightChild());
if (left instanceof IntVar && right instanceof IntVar) {
return toComparisonVariable((IntVar)left, (IntVar)right, Choco.EQ);
return toComparisonVariable((IntVar)left, (IntVar)right, Choco.NEQ);
} else if (left instanceof SetVar && right instanceof SetVar) {
Constraint setEq = SetConstraintsFactory.all_equal(new SetVar[]{(SetVar) left, (SetVar) right});
tmpBool = newBool();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment