Modifier and Type | Method and Description |
---|---|
Constraint |
Model.falseConstraint()
The basic "false" constraint, which is always violated
|
Constraint[] |
Model.getCstrs()
Returns the array of
Constraint objects posted in this Model . |
Constraint |
Model.trueConstraint()
The basic "true" constraint, which is always satisfied
|
Modifier and Type | Method and Description |
---|---|
void |
Model.post(Constraint... cs)
Posts constraints
cs permanently in the constraints network of this :
- add them to the data structure,
- set the fixed idx,
- checks for restrictions |
void |
Model.postTemp(Constraint... cs)
Posts constraints
cs temporary, that is, they will be unposted upon backtrack. |
void |
Model.unpost(Constraint... constraints)
Remove permanently the constraint
c from the constraint network. |
Modifier and Type | Class and Description |
---|---|
class |
Arithmetic
A constraint dedicated to arithmetic operations.
|
class |
ReificationConstraint
Implication constraint: boolean b => constraint c
Also known as half reification
|
Modifier and Type | Field and Description |
---|---|
protected Constraint |
Propagator.constraint
Encapsuling constraint.
|
protected Constraint |
ReificationConstraint.falseCons |
protected Constraint |
ReificationConstraint.trueCons |
Modifier and Type | Method and Description |
---|---|
default Constraint |
IIntConstraintFactory.absolute(IntVar var1,
IntVar var2)
Creates an absolute value constraint: var1 = |var2|
|
default Constraint |
IIntConstraintFactory.allDifferent(IntVar... vars)
Creates an allDifferent constraint.
|
default Constraint |
IIntConstraintFactory.allDifferent(IntVar[] vars,
String CONSISTENCY)
Creates an allDifferent constraint.
|
default Constraint |
ISetConstraintFactory.allDifferent(SetVar... sets)
Creates a constraint stating that sets should all be different (not necessarily disjoint)
Note that there cannot be more than one empty set
|
default Constraint |
IIntConstraintFactory.allDifferentExcept0(IntVar[] vars)
Creates an allDifferent constraint for variables that are not equal to 0.
|
default Constraint |
IIntConstraintFactory.allDifferentUnderCondition(IntVar[] vars,
Condition condition,
boolean singleCondition)
Creates an allDifferent constraint subject to the given condition.
|
default Constraint |
ISetConstraintFactory.allDisjoint(SetVar... sets)
Creates a constraint stating that the intersection of sets should be empty
Note that there can be multiple empty sets
|
default Constraint |
IIntConstraintFactory.allEqual(IntVar... vars)
Creates an allEqual constraint.
|
default Constraint |
ISetConstraintFactory.allEqual(SetVar... sets)
Creates a constraint stating that sets should be all equal
|
default Constraint |
IIntConstraintFactory.among(IntVar nbVar,
IntVar[] vars,
int[] values)
Creates an among constraint.
|
default Constraint |
IIntConstraintFactory.and(BoolVar... bools)
Creates an and constraint that is satisfied if all boolean variables in bools are true
|
default Constraint |
IIntConstraintFactory.and(Constraint... cstrs)
Creates an and constraint that is satisfied if all constraints in cstrs are satisfied
BEWARE: this should not be used to post several constraints at once but in a reification context
|
default Constraint |
IIntConstraintFactory.arithm(IntVar var,
String op,
int cste)
Creates an arithmetic constraint : var op cste,
where op in {"=", "!=", ">","<",">=","<="}
|
default Constraint |
IIntConstraintFactory.arithm(IntVar var1,
String op,
IntVar var2)
Creates an arithmetic constraint: var1 op var2,
where op in {"=", "!=", ">","<",">=","<="}
|
default Constraint |
IIntConstraintFactory.arithm(IntVar var1,
String op1,
IntVar var2,
String op2,
int cste)
Creates an arithmetic constraint : var1 op var2,
where op in {"=", "!=", ">","<",">=","<="} or {"+", "-", "*", "/"}
|
default Constraint |
IIntConstraintFactory.arithm(IntVar var1,
String op1,
IntVar var2,
String op2,
IntVar var3)
Creates an arithmetic constraint: var1 op1 var2 op2 var3,
where op1 and op2 in {"=", "!=", ">","<",">=","<="} or {"+", "-", "*", "/"}
|
default Constraint |
IIntConstraintFactory.atLeastNValues(IntVar[] vars,
IntVar nValues,
boolean AC)
Creates an atLeastNValue constraint.
|
default Constraint |
IIntConstraintFactory.atMostNValues(IntVar[] vars,
IntVar nValues,
boolean STRONG)
Creates an atMostNValue constraint.
|
default Constraint |
IIntConstraintFactory.binPacking(IntVar[] itemBin,
int[] itemSize,
IntVar[] binLoad,
int offset)
Creates a BinPacking constraint.
|
default Constraint |
IIntConstraintFactory.bitsIntChanneling(BoolVar[] bits,
IntVar var)
Creates an channeling constraint between an integer variable and a set of bit variables.
|
default Constraint |
IIntConstraintFactory.boolsIntChanneling(BoolVar[] bVars,
IntVar var,
int offset)
Creates an channeling constraint between an integer variable and a set of boolean variables.
|
default Constraint |
IIntConstraintFactory.circuit(IntVar[] vars)
Creates a circuit constraint which ensures that
the elements of vars define a covering circuit
where vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.circuit(IntVar[] vars,
int offset)
Creates a circuit constraint which ensures that
the elements of vars define a covering circuit
where vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.circuit(IntVar[] vars,
int offset,
CircuitConf conf)
Creates a circuit constraint which ensures that
the elements of vars define a covering circuit
where vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.clausesIntChanneling(IntVar var,
BoolVar[] eVars,
BoolVar[] lVars)
Creates an channeling constraint between an integer variable and a set of clauses.
|
default Constraint |
IIntConstraintFactory.costRegular(IntVar[] vars,
IntVar cost,
ICostAutomaton costAutomaton)
Creates a regular constraint that supports a cost function.
|
default Constraint |
IIntConstraintFactory.count(int value,
IntVar[] vars,
IntVar limit)
Creates a count constraint.
|
default Constraint |
IIntConstraintFactory.count(IntVar value,
IntVar[] vars,
IntVar limit)
Creates a count constraint.
|
default Constraint |
IIntConstraintFactory.cumulative(Task[] tasks,
IntVar[] heights,
IntVar capacity)
Creates a cumulative constraint: Enforces that at each point in time,
the cumulated height of the set of tasks that overlap that point
does not exceed a given limit.
|
default Constraint |
IIntConstraintFactory.cumulative(Task[] tasks,
IntVar[] heights,
IntVar capacity,
boolean incremental)
Creates a cumulative constraint: Enforces that at each point in time,
the cumulated height of the set of tasks that overlap that point
does not exceed a given limit.
|
default Constraint |
IIntConstraintFactory.cumulative(Task[] tasks,
IntVar[] heights,
IntVar capacity,
boolean incremental,
Cumulative.Filter... filters)
Creates a cumulative constraint: Enforces that at each point in time,
the cumulated height of the set of tasks that overlap that point
does not exceed a given limit.
|
default Constraint |
IIntConstraintFactory.cumulative(Task[] tasks,
IntVar[] heights,
IntVar capacity,
boolean incremental,
CumulFilter... filters)
Creates a cumulative constraint: Enforces that at each point in time,
the cumulated height of the set of tasks that overlap that point
does not exceed a given limit.
|
default Constraint |
IIntConstraintFactory.diffN(IntVar[] X,
IntVar[] Y,
IntVar[] width,
IntVar[] height,
boolean addCumulativeReasoning)
Creates a diffN constraint.
|
default Constraint |
ISetConstraintFactory.disjoint(SetVar set1,
SetVar set2)
Creates a constraint stating that the intersection of set1 and set2 should be empty
Note that they can be both empty
|
default Constraint |
IIntConstraintFactory.distance(IntVar var1,
IntVar var2,
String op,
int cste)
Creates a distance constraint : |var1-var2| op cste
where op can take its value among {"=", ">", "<", "!="} |
default Constraint |
IIntConstraintFactory.distance(IntVar var1,
IntVar var2,
String op,
IntVar var3)
Creates a distance constraint: |var1-var2| op var3
where op can take its value among {"=", ">", "<"} |
default Constraint |
IIntConstraintFactory.div(IntVar dividend,
IntVar divisor,
IntVar result)
Creates an euclidean division constraint.
|
default Constraint |
IIntConstraintFactory.element(IntVar value,
int[] table,
IntVar index)
Creates an element constraint: value = table[index]
|
default Constraint |
IIntConstraintFactory.element(IntVar value,
int[] table,
IntVar index,
int offset)
Creates an element constraint: value = table[index-offset]
|
default Constraint |
IIntConstraintFactory.element(IntVar value,
IntVar[] table,
IntVar index,
int offset)
Creates a element constraint: value = table[index-offset]
where table is an array of variables.
|
default Constraint |
ISetConstraintFactory.element(IntVar index,
SetVar[] sets,
int offset,
SetVar set)
Creates a constraint enabling to retrieve an element set in sets:
sets[index-offset] = set
|
default Constraint |
ISetConstraintFactory.element(IntVar index,
SetVar[] sets,
SetVar set)
Creates a constraint enabling to retrieve an element set in sets:
sets[index] = set
|
Constraint |
Propagator.getConstraint() |
Constraint |
Constraint.getOpposite()
Get the opposite constraint of this constraint.
|
default Constraint |
IIntConstraintFactory.globalCardinality(IntVar[] vars,
int[] values,
IntVar[] occurrences,
boolean closed)
Creates a global cardinality constraint (GCC):
Each value values[i] should be taken by exactly occurrences[i] variables of vars.
|
default Constraint |
ISetConstraintFactory.intersection(SetVar[] sets,
SetVar intersectionSet)
Creates a constraint which ensures that the intersection of sets is equal to intersectionSet
|
default Constraint |
ISetConstraintFactory.intersection(SetVar[] sets,
SetVar intersectionSet,
boolean boundConsistent)
Creates a constraint which ensures that the intersection of sets is equal to intersectionSet
|
default Constraint |
IIntConstraintFactory.intValuePrecedeChain(IntVar[] X,
int[] V)
Creates an intValuePrecedeChain constraint.
|
default Constraint |
IIntConstraintFactory.intValuePrecedeChain(IntVar[] X,
int S,
int T)
Creates an intValuePrecedeChain constraint.
|
default Constraint |
IIntConstraintFactory.inverseChanneling(IntVar[] vars1,
IntVar[] vars2)
Creates an inverse channeling between vars1 and vars2:
vars1[i] = j <=> vars2[j] = i
Performs AC if domains are enumerated.
|
default Constraint |
IIntConstraintFactory.inverseChanneling(IntVar[] vars1,
IntVar[] vars2,
int offset1,
int offset2)
Creates an inverse channeling between vars1 and vars2:
vars1[i-offset2] = j <=> vars2[j-offset1] = i
Performs AC if domains are enumerated.
|
default Constraint |
ISetConstraintFactory.inverseSet(SetVar[] sets,
SetVar[] invSets,
int offset1,
int offset2)
Creates a constraint stating that :
x in sets[y-offset1] <=> y in invSets[x-offset2]
|
default Constraint |
IIntConstraintFactory.keySort(IntVar[][] vars,
IntVar[] PERMvars,
IntVar[][] SORTEDvars,
int K)
Creates a keySort constraint which ensures that the variables of SORTEDvars correspond to the variables
of vars according to a permutation stored in PERMvars (optional, can be null).
|
default Constraint |
IIntConstraintFactory.knapsack(IntVar[] occurrences,
IntVar weightSum,
IntVar energySum,
int[] weight,
int[] energy)
Creates a knapsack constraint.
|
default Constraint |
IIntConstraintFactory.lexChainLess(IntVar[]... vars)
Creates a lexChainLess constraint.
|
default Constraint |
IIntConstraintFactory.lexChainLessEq(IntVar[]... vars)
Creates a lexChainLessEq constraint.
|
default Constraint |
IIntConstraintFactory.lexLess(IntVar[] vars1,
IntVar[] vars2)
Creates a lexLess constraint.
|
default Constraint |
IIntConstraintFactory.lexLessEq(IntVar[] vars1,
IntVar[] vars2)
Creates a lexLessEq constraint.
|
Constraint |
Arithmetic.makeOpposite() |
protected Constraint |
Constraint.makeOpposite()
Make the opposite constraint of this.
|
default Constraint |
IIntConstraintFactory.max(BoolVar max,
BoolVar[] vars)
Creates a maximum constraint.
|
default Constraint |
IIntConstraintFactory.max(IntVar max,
IntVar[] vars)
Creates a maximum constraint.
|
default Constraint |
IIntConstraintFactory.max(IntVar max,
IntVar var1,
IntVar var2)
Creates a maximum constraint : max = max(var1, var2)
(Bound Consistency)
|
default Constraint |
ISetConstraintFactory.max(SetVar indices,
int[] weights,
int offset,
IntVar maxElementValue,
boolean notEmpty)
Creates a constraint over the maximum element induces by a set:
max{weights[i-offset] | i in indices} = maxElementValue
|
default Constraint |
ISetConstraintFactory.max(SetVar set,
IntVar maxElementValue,
boolean notEmpty)
Creates a constraint over the maximum element in a set:
max{i | i in set} = maxElementValue
|
default Constraint |
IIntConstraintFactory.mddc(IntVar[] vars,
MultivaluedDecisionDiagram MDD)
Create a constraint where solutions (tuples) are encoded by a multi-valued decision diagram.
|
default Constraint |
ISetConstraintFactory.member(int cst,
SetVar set)
Creates a member constraint stating that the constant cst is in set
|
default Constraint |
IIntConstraintFactory.member(IntVar var,
int[] table)
Creates a member constraint.
|
default Constraint |
IIntConstraintFactory.member(IntVar var,
int lb,
int ub)
Creates a member constraint.
|
default Constraint |
ISetConstraintFactory.member(IntVar intVar,
SetVar set)
Creates a member constraint stating that the value of intVar is in set
|
default Constraint |
ISetConstraintFactory.member(SetVar[] sets,
SetVar set)
Creates a member constraint stating that set belongs to sets
|
static Constraint |
Constraint.merge(String name,
Constraint... toMerge)
Creates a new constraint with all propagators of toMerge
|
default Constraint |
IIntConstraintFactory.min(BoolVar min,
BoolVar[] vars)
Creates a minimum constraint.
|
default Constraint |
IIntConstraintFactory.min(IntVar min,
IntVar[] vars)
Creates a minimum constraint.
|
default Constraint |
IIntConstraintFactory.min(IntVar min,
IntVar var1,
IntVar var2)
Creates a minimum constraint: min = min(var1, var2)
(Bound Consistency)
|
default Constraint |
ISetConstraintFactory.min(SetVar indices,
int[] weights,
int offset,
IntVar minElementValue,
boolean notEmpty)
Creates a constraint over the minimum element induces by a set:
min{weights[i-offset] | i in indices} = minElementValue
|
default Constraint |
ISetConstraintFactory.min(SetVar set,
IntVar minElementValue,
boolean notEmpty)
Creates a constraint over the minimum element in a set:
min{i | i in set} = minElementValue
|
default Constraint |
IIntConstraintFactory.mod(IntVar X,
IntVar Y,
IntVar Z)
Creates a modulo constraint.
|
default Constraint |
IIntConstraintFactory.multiCostRegular(IntVar[] vars,
IntVar[] costVars,
ICostAutomaton costAutomaton)
Creates a regular constraint that supports a multiple cost function.
|
default Constraint |
IIntConstraintFactory.multiCostRegular(IntVar[] vars,
IntVar[] costVars,
ICostAutomaton costAutomaton,
double precision)
Creates a regular constraint that supports a multiple cost function.
|
default Constraint |
ISetConstraintFactory.nbEmpty(SetVar[] sets,
int nbEmpty)
Creates a constraint counting the number of empty sets sets
|{s in sets where |s|=0}| = nbEmpty
|
default Constraint |
ISetConstraintFactory.nbEmpty(SetVar[] sets,
IntVar nbEmpty)
Creates a constraint counting the number of empty sets sets
|{s in sets where |s|=0}| = nbEmpty
|
default Constraint |
IIntConstraintFactory.not(Constraint cstr)
Gets the opposite of a given constraint
Works for any constraint, including globals, but the associated performances might be weak
|
default Constraint |
IIntConstraintFactory.notAllEqual(IntVar... vars)
Creates an allEqual constraint.
|
default Constraint |
ISetConstraintFactory.notEmpty(SetVar set)
Creates a constraint preventing set to be empty
|
default Constraint |
ISetConstraintFactory.notMember(int cst,
SetVar set)
Creates a member constraint stating that the constant cst is not in set
|
default Constraint |
IIntConstraintFactory.notMember(IntVar var,
int[] table)
Creates a notMember constraint.
|
default Constraint |
IIntConstraintFactory.notMember(IntVar var,
int lb,
int ub)
Creates a notMember constraint.
|
default Constraint |
ISetConstraintFactory.notMember(IntVar intVar,
SetVar set)
Creates a member constraint stating that the value of intVar is not in set
|
default Constraint |
IIntConstraintFactory.nValues(IntVar[] vars,
IntVar nValues)
Creates an nValue constraint.
|
default Constraint |
ISetConstraintFactory.offSet(SetVar set1,
SetVar set2,
int offset)
Creates a constraint linking set1 and set2 with an index offset :
x in set1 <=> x+offset in set2
|
default Constraint |
IIntConstraintFactory.or(BoolVar... bools)
Creates an and constraint that is satisfied if at least one boolean variables in bools is true
|
default Constraint |
IIntConstraintFactory.or(Constraint... cstrs)
Creates an and constraint that is satisfied if at least one constraint in cstrs are satisfied
|
default Constraint |
ISetConstraintFactory.partition(SetVar[] sets,
SetVar universe)
Creates a constraint stating that partitions universe into sets:
union(sets) = universe
intersection(sets) = {}
|
default Constraint |
IIntConstraintFactory.path(IntVar[] vars,
IntVar start,
IntVar end)
Creates a path constraint which ensures that
the elements of vars define a covering path from start to end
where vars[i] = j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.path(IntVar[] vars,
IntVar start,
IntVar end,
int offset)
Creates a path constraint which ensures that
the elements of vars define a covering path from start to end
where vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.regular(IntVar[] vars,
IAutomaton automaton)
Creates a regular constraint.
|
default Constraint |
IIntConstraintFactory.scalar(IntVar[] vars,
int[] coeffs,
String operator,
int scalar)
Creates a scalar constraint which ensures that Sum(vars[i]*coeffs[i]) operator scalar
|
default Constraint |
IIntConstraintFactory.scalar(IntVar[] vars,
int[] coeffs,
String operator,
int scalar,
int minCardForDecomp)
Creates a scalar constraint which ensures that Sum(vars[i]*coeffs[i]) operator scalar
|
default Constraint |
IIntConstraintFactory.scalar(IntVar[] vars,
int[] coeffs,
String operator,
IntVar scalar)
Creates a scalar constraint which ensures that Sum(vars[i]*coeffs[i]) operator scalar
|
default Constraint |
IIntConstraintFactory.scalar(IntVar[] vars,
int[] coeffs,
String operator,
IntVar scalar,
int minCardForDecomp)
Creates a scalar constraint which ensures that Sum(vars[i]*coeffs[i]) operator scalar
|
default Constraint |
IRealConstraintFactory.scalar(Variable[] vars,
double[] coeffs,
String op,
double bound)
Creates a linear equation constraint over RealVar, IntVar or BoolVar
which ensures that Sum(vars[i]*coeffs[i]) op bound
|
default Constraint |
ISetConstraintFactory.setBoolsChanneling(BoolVar[] bools,
SetVar set)
Creates a constraint channeling a set variable with boolean variables :
i in set <=> bools[i] = TRUE
|
default Constraint |
ISetConstraintFactory.setBoolsChanneling(BoolVar[] bools,
SetVar set,
int offset)
Creates a constraint channeling a set variable with boolean variables :
i in set <=> bools[i-offset] = TRUE
|
default Constraint |
ISetConstraintFactory.setsIntsChanneling(SetVar[] sets,
IntVar[] ints)
Creates a constraint channeling set variables and integer variables :
x in sets[y] <=> ints[x] = y
|
default Constraint |
ISetConstraintFactory.setsIntsChanneling(SetVar[] sets,
IntVar[] ints,
int offset1,
int offset2)
Creates a constraint channeling set variables and integer variables :
x in sets[y-offset1] <=> ints[x-offset2] = y
|
default Constraint |
IIntConstraintFactory.sort(IntVar[] vars,
IntVar[] sortedVars)
Creates a sort constraint which ensures that the variables of sortedVars correspond to the variables
of vars according to a permutation.
|
default Constraint |
IIntConstraintFactory.square(IntVar var1,
IntVar var2)
Creates a square constraint: var1 = var2^2
|
default Constraint |
IIntConstraintFactory.subCircuit(IntVar[] vars,
int offset,
IntVar subCircuitLength)
Creates a subCircuit constraint which ensures that
the elements of vars define a single circuit of subcircuitSize nodes where
vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
IIntConstraintFactory.subPath(IntVar[] vars,
IntVar start,
IntVar end,
int offset,
IntVar SIZE)
Creates a subPath constraint which ensures that
the elements of vars define a path of SIZE vertices, leading from start to end
where vars[i] = offset+j means that j is the successor of i.
|
default Constraint |
ISetConstraintFactory.subsetEq(SetVar... sets)
Creates a constraint establishing that sets[i] is a subset of sets[j] if i |
default Constraint |
IIntConstraintFactory.sum(BoolVar[] vars,
String operator,
int sum)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(BoolVar[] vars,
String operator,
IntVar sum)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(BoolVar[] vars,
String operator,
IntVar sum,
int minCardForDecomp)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(IntVar[] vars,
String operator,
int sum)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(IntVar[] vars,
String operator,
int sum,
int minCardForDecomp)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(IntVar[] vars,
String operator,
IntVar sum)
Creates a sum constraint.
|
default Constraint |
IIntConstraintFactory.sum(IntVar[] vars,
String operator,
IntVar sum,
int minCardForDecomp)
Creates a sum constraint.
|
default Constraint |
ISetConstraintFactory.sum(SetVar set,
IntVar sum)
Creates a constraint summing elements of set
sum{i | i in set} = sum
|
default Constraint |
ISetConstraintFactory.sumElements(SetVar indices,
int[] weights,
int offset,
IntVar sum)
Creates a constraint summing weights given by a set of indices:
sum{weights[i-offset] | i in indices} = sum
Also ensures that elements in indices belong to [offset, offset+weights.length-1]
|
default Constraint |
ISetConstraintFactory.sumElements(SetVar indices,
int[] weights,
IntVar sum)
Creates a constraint summing weights given by a set of indices:
sum{weights[i] | i in indices} = sum
Also ensures that elements in indices belong to [0, weights.length-1]
|
default Constraint |
ISetConstraintFactory.symmetric(SetVar... sets)
Creates a constraint stating that sets are symmetric sets:
x in sets[y] <=> y in sets[x]
|
default Constraint |
ISetConstraintFactory.symmetric(SetVar[] sets,
int offset)
Creates a constraint stating that sets are symmetric sets:
x in sets[y-offset] <=> y in sets[x-offset]
|
default Constraint |
IIntConstraintFactory.table(IntVar[] vars,
Tuples tuples)
Creates a table constraint specifying that the sequence of variables vars must belong to the list of tuples
(or must NOT belong in case of infeasible tuples)
Default configuration with GACSTR+ algorithm for feasible tuples and GAC3rm otherwise
|
default Constraint |
IIntConstraintFactory.table(IntVar[] vars,
Tuples tuples,
String algo)
Creates a table constraint, with the specified algorithm defined algo
|
default Constraint |
IIntConstraintFactory.table(IntVar var1,
IntVar var2,
Tuples tuples)
Create a table constraint over a couple of variables var1 and var2
Uses AC3rm algorithm by default
|
default Constraint |
IIntConstraintFactory.table(IntVar var1,
IntVar var2,
Tuples tuples,
String algo)
Creates a table constraint over a couple of variables var1 and var2:
- AC2001: table constraint which applies the AC2001 algorithm, - AC3: table constraint which applies the AC3 algorithm, - AC3rm: table constraint which applies the AC3 rm algorithm, - AC3bit+rm (default): table constraint which applies the AC3 bit+rm algorithm, - FC: table constraint which applies forward checking algorithm. |
default Constraint |
IIntConstraintFactory.times(IntVar X,
int Y,
IntVar Z)
Creates a multiplication constraint: X * Y = Z
|
default Constraint |
IIntConstraintFactory.times(IntVar X,
IntVar Y,
int Z)
Creates a multiplication constraint: X * Y = Z
|
default Constraint |
IIntConstraintFactory.times(IntVar X,
IntVar Y,
IntVar Z)
Creates a multiplication constraint: X * Y = Z
|
default Constraint |
IIntConstraintFactory.tree(IntVar[] succs,
IntVar nbTrees)
Creates a tree constraint.
|
default Constraint |
IIntConstraintFactory.tree(IntVar[] succs,
IntVar nbTrees,
int offset)
Creates a tree constraint.
|
default Constraint |
ISetConstraintFactory.union(IntVar[] ints,
SetVar union)
Creates a constraint ensuring that union is exactly the union of values taken by ints,
|
default Constraint |
ISetConstraintFactory.union(SetVar[] sets,
SetVar unionSet)
Creates a constraint which ensures that the union of sets is equal to unionSet
|
Modifier and Type | Method and Description |
---|---|
default boolean |
ISatFactory.addConstructiveDisjunction(Constraint... cstrs)
Make a constructive disjunction constraint
|
default Constraint |
IIntConstraintFactory.and(Constraint... cstrs)
Creates an and constraint that is satisfied if all constraints in cstrs are satisfied
BEWARE: this should not be used to post several constraints at once but in a reification context
|
default void |
IReificationFactory.ifOnlyIf(Constraint cstr1,
Constraint cstr2)
Posts an equivalence constraint stating that
cstr1 is satisfied <=> cstr2 is satisfied,
BEWARE : it is automatically posted (it cannot be reified)
|
default void |
IReificationFactory.ifThen(BoolVar ifVar,
Constraint thenCstr)
Posts an implication constraint: ifVar => thenCstr
Also called half reification constraint
Ensures:
- ifVar = 1 => thenCstr is satisfied, - thenCstr is not satisfied => ifVar = 0 Example : - ifThen(b1, arithm(v1, "=", 2)); :
b1 is equal to 1 => v1 = 2, so v1 != 2 => b1 is equal to 0
But if b1 is equal to 0, nothing happens
BEWARE : it is automatically posted (it cannot be reified)
|
default void |
IReificationFactory.ifThen(Constraint ifCstr,
Constraint thenCstr)
Posts a constraint ensuring that if ifCstr is satisfied, then thenCstr is satisfied as well
BEWARE : it is automatically posted (it cannot be reified)
|
default void |
IReificationFactory.ifThenElse(BoolVar ifVar,
Constraint thenCstr,
Constraint elseCstr)
Posts an implication constraint: ifVar => thenCstr && not(ifVar) => elseCstr.
|
default void |
IReificationFactory.ifThenElse(Constraint ifCstr,
Constraint thenCstr,
Constraint elseCstr)
Posts a constraint ensuring that if ifCstr is satisfied, then thenCstr must be satisfied as well
Otherwise, elseCstr must be satisfied
ifCstr => ThenCstr
not(ifCstr) => ElseCstr
BEWARE : it is automatically posted (it cannot be reified)
|
static Constraint |
Constraint.merge(String name,
Constraint... toMerge)
Creates a new constraint with all propagators of toMerge
|
default Constraint |
IIntConstraintFactory.not(Constraint cstr)
Gets the opposite of a given constraint
Works for any constraint, including globals, but the associated performances might be weak
|
default Constraint |
IIntConstraintFactory.or(Constraint... cstrs)
Creates an and constraint that is satisfied if at least one constraint in cstrs are satisfied
|
default void |
IReificationFactory.reification(BoolVar var,
Constraint cstr)
Reify a constraint with a boolean variable:
var = 1 <=> cstr is satisfied,
Equivalent to ifOnlyIf
BEWARE : it is automatically posted (it cannot be reified)
|
protected void |
Constraint.setOpposite(Constraint opp) |
Constructor and Description |
---|
ReificationConstraint(BoolVar bVar,
Constraint consIfBoolTrue,
Constraint consIfBoolFalse) |
Modifier and Type | Method and Description |
---|---|
static Constraint |
ElementFactory.detect(IntVar VALUE,
int[] TABLE,
IntVar INDEX,
int OFFSET)
Detect and return the most adapted Element propagator wrt to the values in TABLE
|
Modifier and Type | Class and Description |
---|---|
class |
AllDifferent
Ensures that all variables from VARS take a different value.
|
Modifier and Type | Class and Description |
---|---|
class |
CostRegular
COST_REGULAR constraint
|
Modifier and Type | Class and Description |
---|---|
class |
SatConstraint
|
Modifier and Type | Class and Description |
---|---|
class |
Cumulative
Cumulative constraint
|
Modifier and Type | Class and Description |
---|---|
class |
GlobalCardinality
Global Cardinality constraint
|
Modifier and Type | Method and Description |
---|---|
static Constraint |
GlobalCardinality.reformulate(IntVar[] vars,
IntVar[] card,
Model model) |
Modifier and Type | Class and Description |
---|---|
class |
NogoodConstraint
Created by cprudhom on 21/01/15.
|
Modifier and Type | Class and Description |
---|---|
class |
SumConstraint
Project: choco-solver.
|
Modifier and Type | Method and Description |
---|---|
protected Constraint |
SumConstraint.makeOpposite()
The only reason this class exists
|
static Constraint |
IntLinCombFactory.reduce(IntVar[] VARS,
int[] COEFFS,
Operator OPERATOR,
IntVar SCALAR,
int minCardForDecomposition)
Reduce coefficients, and variables if required, when dealing with a scalar product
|
static Constraint |
IntLinCombFactory.reduce(IntVar[] VARS,
Operator OPERATOR,
IntVar SUM,
int minCardForDecomposition)
Reduce coefficients, and variables if required, when dealing with a sum (all coefficients are implicitly equal to 1)
|
static Constraint |
IntLinCombFactory.selectScalar(IntVar[] VARS,
int[] COEFFS,
Operator OPERATOR,
int RESULT)
Select the most relevant ScalarProduct constraint to return
|
static Constraint |
IntLinCombFactory.selectSum(IntVar[] VARS,
int[] COEFFS,
Operator OPERATOR,
int RESULT,
int nbools)
Select the most relevant Sum constraint to return
|
Modifier and Type | Class and Description |
---|---|
class |
IntEqRealConstraint
Deprecated.
|
class |
RealConstraint
A constraint on real variables, solved using IBEX.
|
Modifier and Type | Class and Description |
---|---|
class |
LocalConstructiveDisjunction
Project: choco.
|
class |
Opposite
Default opposite of a constraint
|
Constructor and Description |
---|
LocalConstructiveDisjunction(Constraint... constraints)
Make a new constraint defined as a set of given propagators
|
Opposite(Constraint cons)
Make a new opposite constraint defined as a set of given propagators
|
PropConditionnal(Variable[] vars2observe,
Constraint[] condTrue,
Constraint[] condFalse) |
PropConditionnal(Variable[] vars2observe,
Constraint[] condTrue,
Constraint[] condFalse) |
PropOpposite(Constraint original,
Variable[] vars) |
PropReif(Variable[] allVars,
Constraint consIfBoolTrue,
Constraint consIfBoolFalse) |
Modifier and Type | Class and Description |
---|---|
class |
Member
|
class |
NotMember
|
Modifier and Type | Method and Description |
---|---|
Constraint |
NotMember.makeOpposite() |
Constraint |
Member.makeOpposite() |
Modifier and Type | Method and Description |
---|---|
Constraint |
BiCReExpression.ibex(double p) |
Constraint |
CReExpression.ibex(double p) |
Modifier and Type | Method and Description |
---|---|
Constraint |
NaLoExpression.decompose() |
Constraint |
BiLoExpression.decompose() |
Constraint |
UnLoExpression.decompose() |
Modifier and Type | Method and Description |
---|---|
default Constraint |
ReExpression.decompose() |
Constraint |
BiReExpression.decompose() |
Constraint |
NaReExpression.decompose() |
default Constraint |
ReExpression.extension() |
Copyright © 2018. All rights reserved.