Package org.xcsp.modeler.api
Interface ProblemAPI
-
- All Superinterfaces:
ProblemAPIBase,ProblemAPIOnVals,ProblemAPIOnVars,ProblemAPISymbolic
- All Known Implementing Classes:
AllInterval,Bibd,Blackhole,BoardColoration,MagicSequence,Pic,Pic2,Queens,Rack,Rack2,Sudoku,Warehouse,Zebra
public interface ProblemAPI extends ProblemAPIOnVars, ProblemAPIOnVals, ProblemAPISymbolic
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.xcsp.modeler.api.ProblemAPIBase
ProblemAPIBase.Index, ProblemAPIBase.Occurrences
-
-
Field Summary
-
Fields inherited from interface org.xcsp.modeler.api.ProblemAPIBase
ANY, api2imp, BLOCKS, CHANNELING, CLOSED, CLUES, COLUMNS, DECREASING, DIAGONALS, EQ, EXPRESSION, FIRST, GE, GT, IN, INCREASING, LAST, LE, LEX, LT, MAXIMUM, MINIMUM, NE, NEGATIVE, NOGOODS, NOTIN, NVALUES, POSITIVE, PRODUCT, REDUNDANT_CONSTRAINTS, ROWS, STAR, STAR_INT, STAR_SYMBOL, STRICTLY_DECREASING, STRICTLY_INCREASING, SUM, SYMMETRY_BREAKING
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description default XNodeParent<IVar>abs(Object operand)Returns the root of a syntactic tree built with the unary operatorabsapplied to the specified operand.default XNodeParent<IVar>add(Object... operands)Returns the root of a syntactic tree built with the operatoraddapplied to the specified operands.default CtrEntities.CtrEntityallDifferent(java.util.stream.Stream<XNode<IVar>> trees)Builds a constraintallDifferenton the specified (stream of) syntactic trees (predicates): the predicates, when evaluated, must all take different values.default CtrEntities.CtrEntityallDifferent(IVar.Var[] list)Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.default CtrEntities.CtrEntityallDifferent(IVar.Var[]... list)Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.default CtrEntities.CtrEntityallDifferent(IVar.Var[][][] list)Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.default CtrEntities.CtrEntityallDifferent(IVar.Var[] list, int... exceptValues)Builds a constraintallDifferenton the specified integer variables: the variables must take different values, except those that take one of the specified 'exceptional' values.default CtrEntities.CtrEntityallDifferent(IVar.Var x, IVar.Var... others)Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.default CtrEntities.CtrEntityallDifferent(XNode<IVar>[] trees)Builds a constraintallDifferenton the specified syntactic trees (predicates): the predicates, when evaluated, must all take different values.default CtrEntities.CtrEntityallDifferentExcept(IVar.Var[] list, int... exceptValues)Deprecated.default CtrEntities.CtrEntityallDifferentList(IVar.Var[]... lists)Builds a constraintallDifferentListon the specified lists of variables: all tuples formed by the different lists must be different.default CtrEntities.CtrEntityallDifferentMatrix(IVar.Var[][] matrix)Builds a constraintallDifferentMatrixon the specified matrix of variables.default CtrEntities.CtrEntityallEqual(IVar.Var... list)Builds a constraintallEqualon the specified integer variables: the variables must all take the same value.default CtrEntities.CtrEntityallEqual(IVar.Var[][] list)Builds a constraintallEqualon the specified integer variables: the variables must all take the same value.default CtrEntities.CtrEntityallEqualList(IVar.Var[]... lists)Builds a constraintallEqualListon the specified lists of variables: all tuples formed by the different lists must be equal.default CtrEntities.CtrEntityamong(IVar.Var[] list, int[] values, int k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values is exactlyk.default CtrEntities.CtrEntityamong(IVar.Var[] list, int[] values, IVar.Var k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values is exactlyk.default XNodeParent<IVar>and(Object... operands)Returns the root of a syntactic tree built with the operatorandapplied to the specified operands.default IVar.Var[]array(String id, Size.Size1D size, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a 1-dimensional array of integer variables with the specified id, size, domain, note and classes.default IVar.Var[]array(String id, Size.Size1D size, Domains.Dom dom, Types.TypeClass... classes)Builds a 1-dimensional array of integer variables with the specified id, size, domain, and classes.default IVar.Var[]array(String id, Size.Size1D size, FunctionalInterfaces.IntToDom f, String note, Types.TypeClass... classes)Builds a 1-dimensional array of integer variables with the specified id, size, note (short comment) and classes.default IVar.Var[]array(String id, Size.Size1D size, FunctionalInterfaces.IntToDom f, Types.TypeClass... classes)Builds a 1-dimensional array of integer variables with the specified id, size, and classes.default IVar.Var[][]array(String id, Size.Size2D size, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a 2-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes.default IVar.Var[][]array(String id, Size.Size2D size, Domains.Dom dom, Types.TypeClass... classes)Builds a 2-dimensional array of integer variables with the specified id, size, domain, and classes.default IVar.Var[][]array(String id, Size.Size2D size, FunctionalInterfaces.Intx2ToDom f, String note, Types.TypeClass... classes)Builds a 2-dimensional array of integer variables with the specified id, size, note (short comment) and classes.default IVar.Var[][]array(String id, Size.Size2D size, FunctionalInterfaces.Intx2ToDom f, Types.TypeClass... classes)Builds a 2-dimensional array of integer variables with the specified id, size, and classes.default IVar.Var[][][]array(String id, Size.Size3D size, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a 3-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes.default IVar.Var[][][]array(String id, Size.Size3D size, Domains.Dom dom, Types.TypeClass... classes)Builds a 3-dimensional array of integer variables with the specified id, size, domain, and classes.default IVar.Var[][][]array(String id, Size.Size3D size, FunctionalInterfaces.Intx3ToDom f, String note, Types.TypeClass... classes)Builds a 3-dimensional array of integer variables with the specified id, size, note (short comment) and classes.default IVar.Var[][][]array(String id, Size.Size3D size, FunctionalInterfaces.Intx3ToDom f, Types.TypeClass... classes)Builds a 3-dimensional array of integer variables with the specified id, size, and classes.default IVar.Var[][][][]array(String id, Size.Size4D size, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a 4-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes.default IVar.Var[][][][]array(String id, Size.Size4D size, Domains.Dom dom, Types.TypeClass... classes)Builds a 4-dimensional array of integer variables with the specified id, size, domain, and classes.default IVar.Var[][][][]array(String id, Size.Size4D size, FunctionalInterfaces.Intx4ToDom f, String note, Types.TypeClass... classes)Builds a 4-dimensional array of integer variables with the specified id, size, note (short comment) and classes.default IVar.Var[][][][]array(String id, Size.Size4D size, FunctionalInterfaces.Intx4ToDom f, Types.TypeClass... classes)Builds a 4-dimensional array of integer variables with the specified id, size, and classes.default IVar.Var[][][][][]array(String id, Size.Size5D size, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a 5-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes.default IVar.Var[][][][][]array(String id, Size.Size5D size, Domains.Dom dom, Types.TypeClass... classes)Builds a 5-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes.default IVar.Var[][][][][]array(String id, Size.Size5D size, FunctionalInterfaces.Intx5ToDom f, String note, Types.TypeClass... classes)Builds a 5-dimensional array of integer variables with the specified id, size, note (short comment) and classes.default IVar.Var[][][][][]array(String id, Size.Size5D size, FunctionalInterfaces.Intx5ToDom f, Types.TypeClass... classes)Builds a 5-dimensional array of integer variables with the specified id, size, and classes.default CtrEntities.CtrEntityatLeast(IVar.Var[] list, int value, int k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least equal tok.default CtrEntities.CtrEntityatLeast(IVar.Var[] list, int value, IVar.Var k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least equal tok.default CtrEntities.CtrEntityatLeast1(IVar.Var[] list, int value)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least 1.default CtrEntities.CtrEntityatMost(IVar.Var[] list, int value, int k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most equal tok.default CtrEntities.CtrEntityatMost(IVar.Var[] list, int value, IVar.Var k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most equal tok.default CtrEntities.CtrEntityatMost1(IVar.Var[] list, int value)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most 1.default CtrEntities.CtrEntitybelong(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorinapplied to the specified arguments.default CtrEntities.CtrEntitycardinality(IVar.Var[] list, int[] values, boolean mustBeClosed, ProblemAPIBase.Occurrences occurrences)Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences.default CtrEntities.CtrEntitycardinality(IVar.Var[] list, int[] values, ProblemAPIBase.Occurrences occurrences)Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences.default CtrEntities.CtrEntitycardinality(IVar.Var[] list, IVar.Var[] values, boolean mustBeClosed, ProblemAPIBase.Occurrences occurrences)Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences.default CtrEntities.CtrEntitycardinality(IVar.Var[] list, IVar.Var[] values, ProblemAPIBase.Occurrences occurs)Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences.default CtrEntities.CtrEntitycardinality(IVar.Var[] list, Range values, ProblemAPIBase.Occurrences occurrences)Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer in the rangevaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences.default CtrEntities.CtrEntitychannel(IVar.Var[] list)Builds a constraintchannelfrom the specified arguments: the valuejis assigned to the ith variable oflistiff the valueiis assigned to the jth variable oflist.default CtrEntities.CtrEntitychannel(IVar.Var[] list, int startIndex)Builds a constraintchannelfrom the specified arguments: the valuejis assigned to the ith variable oflistiff the valueiis assigned to the jth variable oflist.default CtrEntities.CtrEntitychannel(IVar.Var[] list, int startIndex, IVar.Var value)Builds a constraintchannelfrom the specified arguments: the valueiis assigned tovalueiff only the ith variable oflistis assigned the value 1 (0 is the value assigned to the other variables oflist).default CtrEntities.CtrEntitychannel(IVar.Var[] list1, int startIndex1, IVar.Var[] list2, int startIndex2)Builds a constraintchannelfrom the specified arguments: assuming for simplicity that indexing start at 0, the valuejis assigned to the ith variable oflist1iff the valueiis assigned to the jth variable oflist2.default CtrEntities.CtrEntitychannel(IVar.Var[] list, IVar.Var value)Builds a constraintchannelfrom the specified arguments: the valueiis assigned tovalueiff only the ith variable oflistis assigned the value 1 (0 is the value assigned to the other variables oflist).default CtrEntities.CtrEntitychannel(IVar.Var[] list1, IVar.Var[] list2)Builds a constraintchannelfrom the specified arguments.default CtrEntities.CtrEntitycircuit(IVar.Var[] list)Builds a constraintcircuiton the specified array of variables.default CtrEntities.CtrEntitycircuit(IVar.Var[] list, int startIndex)Builds a constraintcircuitfrom the specified arguments.default CtrEntities.CtrEntitycircuit(IVar.Var[] list, int startIndex, int size)Builds a constraintcircuitfrom the specified arguments.default CtrEntities.CtrEntitycircuit(IVar.Var[] list, int startIndex, IVar.Var size)Builds a constraintcircuitfrom the specified arguments.default CtrEntities.CtrEntitycircuit(IVar.Var[] list, IVar.Var size)Builds a constraintcircuitfrom the specified arguments.default CtrEntities.CtrEntityclause(IVar.Var[] list, Boolean[] phases)Builds a constraintclausefrom the specified arguments.default CtrEntities.CtrEntityclause(IVar.Var[] pos, IVar.Var[] neg)Builds a constraintclausefrom the specified arguments.default CtrEntities.CtrEntityconjunction(Object... operands)Builds a constraintintension, while considering the operatoraddapplied to the specified arguments.default CtrEntities.CtrEntitycount(IVar.Var[] list, int[] values, Condition condition)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the specified condition.default CtrEntities.CtrEntitycount(IVar.Var[] list, int[] values, Types.TypeConditionOperatorRel op, int limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, int[] values, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, int[] values, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified set of values.default CtrEntities.CtrEntitycount(IVar.Var[] list, int[] values, Types.TypeConditionOperatorSet op, Range range)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitycount(IVar.Var[] list, int value, Types.TypeConditionOperatorRel op, int limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, int value, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, int value, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified set operator and the specified set of values.default CtrEntities.CtrEntitycount(IVar.Var[] list, int value, Types.TypeConditionOperatorSet op, Range range)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var[] values, Condition condition)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the specified condition.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorRel op, int limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified set of values.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorSet op, Range range)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorRel op, int limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the assigned value must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the assigned value must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the value must respect the condition expressed by the specified set operator and the specified set of values.default CtrEntities.CtrEntitycount(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorSet op, Range range)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the value must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntityctrFalse(IVar.Var[] scp)Builds a disentailed integer constraint, i.e., a special constraint that always returnsfalse.default CtrEntities.CtrEntityctrTrue(IVar.Var[] scp)Builds an entailed integer constraint, i.e., a special constraint that always returnstrue.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, int[] heights, long limit)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, int[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] ends, int[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] heights, long limit)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] ends, IVar.Var[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, int[] heights, long limit)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, int[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] ends, int[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] heights, long limit)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights.default CtrEntities.CtrEntitycumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] ends, IVar.Var[] heights, Condition condition)Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights.default voiddecisionVariables(IVar[] list)Sets the specified variables as those on which a solver should branch in priority.default voiddecisionVariables(IVar[][] list)Sets the specified variables as those on which a solver should branch in priority.default CtrEntities.CtrEntitydecreasing(IVar.Var... list)Builds a constraintorderedon the specified lists of variables, while considering a decreasing order.default CtrEntities.CtrEntitydecreasing(IVar.Var[]... lists)Builds a constraintlexon the specified 2-dimensional array of variables, while considering a decreasing order on rows.default CtrEntities.CtrEntitydifferent(Object... operands)Builds a constraintintension, while considering the operatorneapplied to the specified arguments.default CtrEntities.CtrEntitydisjunction(Object... operands)Builds a constraintintension, while considering the operatororapplied to the specified arguments.default XNodeParent<IVar>dist(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatordistapplied to the specified operands.default XNodeParent<IVar>div(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatordivapplied to the specified operands.default Domains.Domdom(int[] values)Returns an integer domain composed of the sorted distinct values that come from the specified array.default Domains.Domdom(int[][] m)Returns an integer domain composed of the sorted distinct values that come from the specified array.default Domains.Domdom(int[] values, FunctionalInterfaces.Intx1Predicate p)Returns an integer domain composed of the sorted distinct values that come from the specified array and that respect the specified predicate.default Domains.Domdom(int value, int... otherValues)Returns an integer domain composed of the sorted distinct values that come from the specified values.default Domains.Domdom(Collection<Integer> values)Returns an integer domain composed of the sorted distinct values that come from the specified collection.default Domains.Domdom(java.util.stream.IntStream values)Returns an integer domain composed of the sorted distinct values that come from the specified streamdefault Domains.Domdom(Range range)Returns an integer domain composed of the values contained in the specified range.default CtrEntities.CtrEntityelement(int[][] matrix, int startRowIndex, IVar.Var rowIndex, int startColIndex, IVar.Var colIndex, Condition condition)default CtrEntities.CtrEntityelement(int[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)default CtrEntities.CtrEntityelement(int[] list, IVar.Var index, Condition condition)default CtrEntities.CtrEntityelement(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)default CtrEntities.CtrEntityelement(IVar.Var[] list, Condition condition)default CtrEntities.CtrEntityelement(IVar.Var[] list, IVar.Var index, Condition condition)default XNodeParent<IVar>eq(Object... operands)Returns the root of a syntactic tree built with the operatoreqapplied to the specified operands.default CtrEntities.CtrEntityequal(Object... operands)Builds a constraintintension, while considering the operatoreqapplied to the specified arguments.default CtrEntities.CtrEntityequivalence(Object... operands)Builds a constraintintension, while considering the operatoriffapplied to the specified arguments.default CtrEntities.CtrEntityexactly(IVar.Var[] list, int value, int k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactlyk.default CtrEntities.CtrEntityexactly(IVar.Var[] list, int value, IVar.Var k)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactlyk.default CtrEntities.CtrEntityexactly1(IVar.Var[] list, int value)Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactly 1.default CtrEntities.CtrEntityextension(IVar.Var[] scp, int[]... tuples)Builds a constraintextensionfrom the specified scope and the specified array of tuples, seen as supports.default CtrEntities.CtrEntityextension(IVar.Var[] scp, int[][] tuples, Boolean positive)Builds a constraintextensionfrom the specified scope and the specified array of tuples, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse).default CtrEntities.CtrEntityextension(IVar.Var[] scp, Collection<int[]> tuples)Builds a constraintextensionfrom the specified scope and the specified collection of tuples, seen as supports.default CtrEntities.CtrEntityextension(IVar.Var[] scp, Collection<int[]> tuples, Boolean positive)Builds a constraintextensionfrom the specified scope and the specified collection of tuples, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse).default CtrEntities.CtrEntityextension(IVar.Var[] scp, Table table)Builds a constraintextensionfrom the specified scope and the specified table, whose elements are seen as supports.default CtrEntities.CtrEntityextension(IVar.Var x, int... values)Builds a unary constraintextensionfrom the specified variable and the specified array of values, seen as supports.default CtrEntities.CtrEntityextension(IVar.Var x, int[] values, Boolean positive)Builds a unary constraintextensionfrom the specified variable and the specified array of values, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse).default CtrEntities.CtrEntityextension(IVar.Var x, Table table)Builds a unary constraintextensionfrom the specified variable and the specified table.default CtrEntities.CtrAloneextension(XNodeParent<IVar> tree)Builds a constraintextensionfrom the specified syntactic tree (predicate).default CtrEntities.CtrAloneextensionDisjunction(List<XNodeParent<IVar>> trees)default CtrEntities.CtrAloneextensionDisjunction(XNodeParent<IVar>... trees)default XNodeParent<IVar>ge(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorgeapplied to the specified operands.default CtrEntities.CtrEntitygreaterEqual(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorgeapplied to the specified arguments.default CtrEntities.CtrEntitygreaterThan(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorgtapplied to the specified arguments.default XNodeParent<IVar>gt(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorgtapplied to the specified operands.default XNodeParent<IVar>iff(Object... operands)Returns the root of a syntactic tree built with the operatoriffapplied to the specified operands.default CtrEntities.CtrEntityifThen(CtrEntities.CtrEntity c1, CtrEntities.CtrEntity c2)Builds a meta-constraintifThenfrom the two specified constraints.default XNodeParent<IVar>ifThenElse(Object operand1, Object operand2, Object operand3)Returns the root of a syntactic tree built with the binary operatorifapplied to the specified operands.default CtrEntities.CtrEntityifThenElse(CtrEntities.CtrEntity c1, CtrEntities.CtrEntity c2, CtrEntities.CtrEntity c3)Builds a meta-constraintifThenElsefrom the three specified constraints.default XNodeParent<IVar>imp(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorimpapplied to the specified operands.default CtrEntities.CtrEntityimplication(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorimpapplied to the specified arguments.default CtrEntities.CtrEntityimply(Object operand1, Object operand2)Deprecated.default XNodeParent<IVar>in(Object var, Object set)Returns the root of a syntactic tree built with the operatorinapplied to the specified operands.default CtrEntities.CtrEntityincreasing(IVar.Var... list)Builds a constraintorderedon the specified lists of variables, while considering an increasing order.default CtrEntities.CtrEntityincreasing(IVar.Var[]... lists)Builds a constraintlexon the specified 2-dimensional array of variables, while considering an increasing order on rows.default CtrEntities.CtrEntityinstantiation(java.util.stream.Stream<IVar.Var> list, java.util.stream.IntStream values)Builds a constraintinstantiation, assigning each specified variable with its corresponding value.default CtrEntities.CtrEntityinstantiation(IVar.Var[][][] list, int[][][] values, FunctionalInterfaces.Intx3Predicate p)Builds a constraintinstantiation, assigning each specified variable at index(i,j,k)with its corresponding value at index(i,j,k), provided that the specified predicate accepts(i,j,k).default CtrEntities.CtrEntityinstantiation(IVar.Var[][] list, int[][] values, FunctionalInterfaces.Intx2Predicate p)Builds a constraintinstantiation, assigning each specified variable at index(i,j)with its corresponding value at index(i,j), provided that the specified predicate accepts(i,j).default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, int value)Builds a constraintinstantiation, assigning each specified variable with the specified value.default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, int... values)Builds a constraintinstantiation, assigning each specified variable with its corresponding value.default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, int[] values, FunctionalInterfaces.Intx1Predicate p)Builds a constraintinstantiation, assigning each specified variable at indexiwith its corresponding value at indexi, provided that the specified predicate acceptsi.default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, Collection<Integer> values)Builds a constraintinstantiation, assigning each specified variable with its corresponding value in the specified collection.default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, java.util.stream.IntStream values)Builds a constraintinstantiation, assigning each specified variable with its corresponding value in the specified stream.default CtrEntities.CtrEntityinstantiation(IVar.Var[] list, Range values)Builds a constraintinstantiation, assigning each specified variable with its corresponding value (from the range).default CtrEntities.CtrEntityintension(XNodeParent<IVar> tree)Builds a constraintintensionfrom the specified argument that represents the root of a syntactic tree.default XNodeParent<IVar>knightAttack(IVar x, IVar y, int order)Returns the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two cells of a flattened matrix (whose order is specified) at a knight distance.default XNodeParent<IVar>le(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorleapplied to the specified operands.default CtrEntities.CtrEntitylessEqual(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorleapplied to the specified arguments.default CtrEntities.CtrEntitylessThan(Object operand1, Object operand2)Builds a constraintintension, while considering the operatorltapplied to the specified arguments.default CtrEntities.CtrEntitylex(IVar.Var[][] lists, Types.TypeOperatorRel operator)Builds a constraintlexon the specified 2-dimensional array of variables: any two successive rows of variables must respect the specified operator.default CtrEntities.CtrEntitylexMatrix(IVar.Var[][] matrix, Types.TypeOperatorRel operator)Builds a constraintlexMatrixon the specified matrix of variables.default XNodeParent<IVar>lt(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorltapplied to the specified operands.default XNodeParent<IVar>max(Object... operands)Returns the root of a syntactic tree built with the operatormaxapplied to the specified operands.default ObjEntities.ObjEntitymaximize(IVar x)Builds an objective (function) to maximize: the value of the specified variable.default ObjEntities.ObjEntitymaximize(XNode<IVar> tree)default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees)default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs)default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar... list)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified array of variables.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][] list)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][][] list)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs, FunctionalInterfaces.Intx3Predicate p)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][] list, int[][] coeffs)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[][] list, int[][] coeffs, FunctionalInterfaces.Intx2Predicate p)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, IVar[] list, int[] coeffs)Builds an objective (function) to maximize: the objective is defined by the specified type on the specified array of variables, each of them being given a coefficient.default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, XNode<IVar>[] trees)default ObjEntities.ObjEntitymaximize(Types.TypeObjective type, XNode<IVar>[] trees, int[] coeffs)default CtrEntities.CtrEntitymaximum(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition.default CtrEntities.CtrEntitymaximum(IVar.Var[] list, Condition condition)Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust respect the specified condition.default CtrEntities.CtrEntitymaximum(IVar.Var[] list, IVar.Var value)Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be equal to the value assigned to the variablevalue.default CtrEntities.CtrEntitymaximum(IVar.Var[] list, IVar.Var index, Condition condition)Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition.default CtrEntities.CtrEntitymaximum(IVar.Var[] list, ProblemAPIBase.Index index)Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variable.default CtrEntities.CtrEntitymdd(IVar.Var[] scp, Transition[] transitions)Builds a constraintmddfrom the specified scope and the specified transitions.default CtrEntities.CtrEntitymdd(IVar.Var[] scp, Transitions transitions)default XNodeParent<IVar>min(Object... operands)Returns the root of a syntactic tree built with the operatorminapplied to the specified operands.default ObjEntities.ObjEntityminimize(IVar x)Builds an objective (function) to minimize: the value of the specified variable.default ObjEntities.ObjEntityminimize(XNode<IVar> tree)default ObjEntities.ObjEntityminimize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees)default ObjEntities.ObjEntityminimize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs)default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar... list)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified array of variables.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][] list)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][][] list)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs, FunctionalInterfaces.Intx3Predicate p)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][] list, int[][] coeffs)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[][] list, int[][] coeffs, FunctionalInterfaces.Intx2Predicate p)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, IVar[] list, int[] coeffs)Builds an objective (function) to minimize: the objective is defined by the specified type on the specified array of variables, each of them being given a coefficient.default ObjEntities.ObjEntityminimize(Types.TypeObjective type, XNode<IVar>[] trees)default ObjEntities.ObjEntityminimize(Types.TypeObjective type, XNode<IVar>[] trees, int[] coeffs)default CtrEntities.CtrEntityminimum(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition.default CtrEntities.CtrEntityminimum(IVar.Var[] list, Condition condition)Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust respect the specified condition.default CtrEntities.CtrEntityminimum(IVar.Var[] list, IVar.Var value)Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be equal to the value assigned to the variablevalue.default CtrEntities.CtrEntityminimum(IVar.Var[] list, IVar.Var index, Condition condition)Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition.default CtrEntities.CtrEntityminimum(IVar.Var[] list, ProblemAPIBase.Index index)Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variable.default XNodeParent<IVar>mod(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatormodapplied to the specified operands.voidmodel()Builds the model.default XNodeParent<IVar>mul(Object... operands)Returns the root of a syntactic tree built with the operatormulapplied to the specified operands.default XNodeParent<IVar>ne(Object... operands)Returns the root of a syntactic tree built with the operatorneapplied to the specified operands.default XNodeParent<IVar>neg(Object operand)Returns the root of a syntactic tree built with the unary operatornegapplied to the specified operand.default CtrEntities.CtrEntitynoOverlap(IVar.Var[][] origins, int[]... lengths)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[][] origins, int[][] lengths, boolean zeroIgnored)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[][] origins, IVar.Var[]... lengths)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[][] origins, IVar.Var[][] lengths, boolean zeroIgnored)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[] origins, int... lengths)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[] origins, int[] lengths, boolean zeroIgnored)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[] origins, IVar.Var... lengths)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var[] origins, IVar.Var[] lengths, boolean zeroIgnored)Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var x1, IVar.Var x2, int length1, int length2)Builds a constraintnoOverlapfrom the specified arguments: we are given two tasks, defined by their origins and durations (lengths), which must not overlap.default CtrEntities.CtrEntitynoOverlap(IVar.Var x1, IVar.Var x2, IVar.Var length1, IVar.Var length2)Builds a constraintnoOverlapfrom the specified arguments: we are given two tasks, defined by their origins and durations (lengths), which must not overlap.default XNodeParent<IVar>not(Object operand)Returns the root of a syntactic tree built with the unary operatornotapplied to the specified operand.default CtrEntities.CtrEntitynotAllEqual(IVar.Var... list)Builds a constraintnValuesfrom the specified arguments: at least two distinct values are assigned to the variables of the specified list.default CtrEntities.CtrEntitynotEqual(Object... operands)Deprecated.default XNodeParent<IVar>notin(Object var, Object set)Returns the root of a syntactic tree built with the operatornotinapplied to the specified operands.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Condition condition)Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the specified condition.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Condition condition, int... exceptValues)Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the specified condition.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, int limit)Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, int limit, int... exceptValues)Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit, int... exceptValues)Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified set operator and the specified set of values.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set, int... exceptValues)Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified set of values.default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range)Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitynValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range, int... exceptValues)Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified interval (range).default XNodeParent<IVar>or(Object... operands)Returns the root of a syntactic tree built with the operatororapplied to the specified operands.default CtrEntities.CtrEntityordered(IVar.Var[] list, int[] lengths, Types.TypeOperatorRel operator)Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator, while considering the specified lengths.default CtrEntities.CtrEntityordered(IVar.Var[] list, IVar.Var[] lengths, Types.TypeOperatorRel operator)Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator, while considering the specified lengths.default CtrEntities.CtrEntityordered(IVar.Var[] list, Types.TypeOperatorRel operator)Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator.default XNodeParent<IVar>pow(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorpowapplied to the specified operands.default voidprettyDisplay(String[] values)Called to display a solution given by the specified array.default XNodeParent<IVar>queenAttack(IVar x, IVar y, int order)Returns the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two distinct cells of a flattened matrix (whose order is specified) on the same row, column or diagonal.default Rangerange(int length)Constructs an objectRangefrom the specified length (using implicitly a lower bound equal to 0 and a step equal to 1).default Rangerange(int startInclusive, int endExclusive)Constructs an objectRangefrom the specified bounds (using implicitly a step equal to 1).default Rangerange(int startInclusive, int endExclusive, int step)Constructs an objectRangefrom the specified bounds and step (difference between each two successive numbers).default RangerangeClosed(int startInclusive, int endInclusive)Constructs an objectRangefrom the specified bounds (using implicitly a step equal to 1).default RangerangeClosed(int startInclusive, int endInclusive, int step)Constructs an objectRangefrom the specified bounds and step (difference between each two successive numbers).default CtrEntities.CtrEntityregular(IVar.Var[] scp, Automaton automaton)Builds a constraintregularfrom the specified scope and the specified automaton.default XNode<IVar>set(int[] operands)Returns the node of a syntactic tree built with the operatorsetapplied to the integers from the specified array.default XNode<IVar>set(Object... operands)Returns the root of a syntactic tree built with the operatorsetapplied to the specified operands.default Size.Size1Dsize(int length)Builds an object that represents the size (length) of a 1-dimensional array.default Size.Size2Dsize(int length0, int length1)Builds an object that represents the size (i.e., length of each dimension) of a 2-dimensional array.default Size.Size3Dsize(int length0, int length1, int length2)Builds an object that represents the size (i.e., length of each dimension) of a 3-dimensional array.default Size.Size4Dsize(int length0, int length1, int length2, int length3)Builds an object that represents the size (i.e., length of each dimension) of a 4-dimensional array.default Size.Size5Dsize(int length0, int length1, int length2, int length3, int length4)Builds an object that represents the size (i.e., length of each dimension) of a 5-dimensional array.default CtrEntities.CtrEntityslide(IVar[] list, Range range, java.util.function.IntFunction<CtrEntities.CtrEntity> template)Builds a meta-constraintslidefrom the specified arguments.default XNodeParent<IVar>sqr(Object operand)Returns the root of a syntactic tree built with the unary operatorsqrapplied to the specified operand.default CtrEntities.CtrEntitystretch(IVar.Var[] list, int[] values, int[] widthsMin, int[] widthsMax)default CtrEntities.CtrEntitystretch(IVar.Var[] list, int[] values, int[] widthsMin, int[] widthsMax, int[][] patterns)default CtrEntities.CtrEntitystrictlyDecreasing(IVar.Var... list)Builds a constraintorderedon the specified lists of variables, while considering a strict decreasing order.default CtrEntities.CtrEntitystrictlyDecreasing(IVar.Var[]... lists)Builds a constraintlexon the specified 2-dimensional array of variables, while considering a strict decreasing order on rows.default CtrEntities.CtrEntitystrictlyIncreasing(IVar.Var... list)Builds a constraintorderedon the specified lists of variables, while considering a strict increasing order.default CtrEntities.CtrEntitystrictlyIncreasing(IVar.Var[]... lists)Builds a constraintlexon the specified 2-dimensional array of variables, while considering a strict increasing order on rows.default XNodeParent<IVar>sub(Object operand1, Object operand2)Returns the root of a syntactic tree built with the binary operatorsubapplied to the specified operands.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Condition condition)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, Condition condition)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the specified condition.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(java.util.stream.Stream<XNode<IVar>> trees, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, int[] coeffs, Condition condition)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.default CtrEntities.CtrEntitysum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified set of values.default CtrEntities.CtrEntitysum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorSet op, Range range)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitysum(IVar.Var[] list, Condition condition)Builds a constraintsumfrom the specified arguments: the sum must respect the specified condition.default CtrEntities.CtrEntitysum(IVar.Var[] list, IVar.Var[] coeffs, Condition condition)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.default CtrEntities.CtrEntitysum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified set of values.default CtrEntities.CtrEntitysum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorSet op, Range range)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitysum(IVar.Var[] list, Range coeffs, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified set of values.default CtrEntities.CtrEntitysum(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified set operator and the specified interval (range).default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, int[] coeffs, Condition condition)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, Condition condition)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the specified condition.default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, Types.TypeConditionOperatorRel op, long limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default CtrEntities.CtrEntitysum(XNode<IVar>[] trees, Types.TypeConditionOperatorRel op, IVar.Var limit)Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.default java.util.stream.Stream<XNode<IVar>>treesFrom(int[] t, java.util.function.Function<Integer,XNode<IVar>> f)Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified array.default java.util.stream.Stream<XNode<IVar>>treesFrom(Collection<Integer> c, java.util.function.Function<Integer,XNode<IVar>> f)Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified collection.default java.util.stream.Stream<XNode<IVar>>treesFrom(java.util.stream.IntStream stream, java.util.function.Function<Integer,XNode<IVar>> f)Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified stream.default java.util.stream.Stream<XNode<IVar>>treesFrom(IVar[] t, java.util.function.Function<IVar,XNode<IVar>> f)Returns a stream of syntactic trees (predicates) built by applying the specified function to each variable of the specified array.default java.util.stream.Stream<XNode<IVar>>treesFrom(Range r, java.util.function.Function<Integer,XNode<IVar>> f)Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified range.default IVar.Varvar(String id, Domains.Dom dom, String note, Types.TypeClass... classes)Builds a stand-alone integer variable with the specified id, domain, note (short comment) and classes.default IVar.Varvar(String id, Domains.Dom dom, Types.TypeClass... classes)Builds a stand-alone integer variable with the specified id, domain and classes.default XNodeParent<IVar>xor(Object... operands)Returns the root of a syntactic tree built with the operatorxorapplied to the specified operands.-
Methods inherited from interface org.xcsp.modeler.api.ProblemAPIBase
at, automaton, automaton, automaton, block, condition, condition, condition, condition, control, exceptValue, exceptValues, finalState, finalStates, forall, forall, forall, forall, forall, forall, imp, index, index, indexing, indexing, indexing, indexingTuples, indexingTuples, isModel, modelVariant, modelVariant, name, number, occurBetween, occurExactly, occurExactly, occurrences, occurrences, occursBetween, occursEachBetween, occursEachExactly, onlyOn, readFileLines, readFileLines, startIndex, table, table, table, table, table, table, table, table, tableIntersection, tableWithNewColumn, takingValue, takingValue, takingValues, takingValues, takingValues, transitions, transitions, tuple, weightedBy, weightedBy, weightedBy, weightedBy
-
Methods inherited from interface org.xcsp.modeler.api.ProblemAPIOnVals
addInt, addInt, allCartesian, allCartesian, allCartesian, allCartesian, allCombinations, allCombinations, allPermutations, allPermutations, columnOf, contains, distinctSorted, distinctSorted, dub, dub, firstFrom, firstFrom, maxOf, minOf, repeat, select, select, select, select, select, selectFromIndexing, selectFromIndexing, selectFromIndexing, singleValuesFrom, singleValuesFrom, singleValuesFrom, singleValuesFrom, singleValuesFrom, singleValuesFrom, singleValuesIn, sumOf, sumOf, transpose, vals, valuesFrom, valuesFrom, valuesFrom, valuesFrom, valuesFrom, valuesFrom, valuesFrom, valuesFrom, valuesIn
-
Methods inherited from interface org.xcsp.modeler.api.ProblemAPIOnVars
addObject, addObject, clean, columnOf, contains, diagonalDown, diagonalDown, diagonalDown, diagonalsDown, diagonalsUp, diagonalUp, diagonalUp, diagonalUp, eliminateDim2, eliminateDim3, firstFrom, select, select, select, select, select, select, select, select, select, select, select, select, select, singleVariablesFrom, singleVariablesFrom, singleVariablesIn, transpose, variablesFrom, variablesFrom, variablesFrom, variablesFrom, variablesFrom, variablesFrom, variablesIn, vars, vars, vars, vars, vars, vars, vars, vars
-
Methods inherited from interface org.xcsp.modeler.api.ProblemAPISymbolic
allDifferent, allDifferent, allDifferent, allDifferent, allEqual, allEqual, arraySymbolic, arraySymbolic, arraySymbolic, arraySymbolic, arraySymbolic, arraySymbolic, arraySymbolic, arraySymbolic, ctrFalse, ctrTrue, dom, dom, extension, extension, extension, extension, extension, tableSymbolic, tableSymbolic, tableSymbolic, tableSymbolic, tuple, var, var
-
-
-
-
Method Detail
-
dom
default Domains.Dom dom(int[] values, FunctionalInterfaces.Intx1Predicate p)
Returns an integer domain composed of the sorted distinct values that come from the specified array and that respect the specified predicate.- Parameters:
values- a 1-dimensional array of integersp- a predicate allowing us to test if a valuevmust be kept in the domain- Returns:
- an integer domain composed of the sorted distinct values that come from the specified array and that respect the specified predicate
-
dom
default Domains.Dom dom(int[] values)
Returns an integer domain composed of the sorted distinct values that come from the specified array.- Parameters:
values- a 1-dimensional array of integers- Returns:
- an integer domain composed of the sorted distinct values that come from the specified array
-
dom
default Domains.Dom dom(int value, int... otherValues)
Returns an integer domain composed of the sorted distinct values that come from the specified values.- Parameters:
value- a first integer (value)otherValues- a sequence of other integers (values)- Returns:
- an integer domain composed of the sorted distinct values that come from the specified values
-
dom
default Domains.Dom dom(Collection<Integer> values)
Returns an integer domain composed of the sorted distinct values that come from the specified collection.- Parameters:
values- a collection of integers (values)- Returns:
- an integer domain composed of the sorted distinct values that come from the specified collection
-
dom
default Domains.Dom dom(java.util.stream.IntStream values)
Returns an integer domain composed of the sorted distinct values that come from the specified stream- Parameters:
values- a stream of integer values- Returns:
- an integer domain composed of the sorted distinct values that come from the specified stream
-
dom
default Domains.Dom dom(int[][] m)
Returns an integer domain composed of the sorted distinct values that come from the specified array.- Parameters:
m- a 2-dimensional array of variables- Returns:
- an integer domain composed of the sorted distinct values that come from the specified array
-
dom
default Domains.Dom dom(Range range)
Returns an integer domain composed of the values contained in the specified range.- Parameters:
range- the range of values to be considered for the domain- Returns:
- an integer domain composed of the values contained in the specified range
-
size
default Size.Size1D size(int length)
Builds an object that represents the size (length) of a 1-dimensional array.- Parameters:
length- the size (length) of the array- Returns:
- an object that represents the size (length) of a 1-dimensional array
-
size
default Size.Size2D size(int length0, int length1)
Builds an object that represents the size (i.e., length of each dimension) of a 2-dimensional array.- Parameters:
length0- the size (length) of the first dimension of a 2-dimensional arraylength1- the size (length) of the second dimension of a 2-dimensional array- Returns:
- an object that represents the size (i.e., length of each dimension) of a 2-dimensional array
-
size
default Size.Size3D size(int length0, int length1, int length2)
Builds an object that represents the size (i.e., length of each dimension) of a 3-dimensional array.- Parameters:
length0- the size (length) of the first dimension of a 3-dimensional arraylength1- the size (length) of the second dimension of a 3-dimensional arraylength2- the size (length) of the third dimension of a 3-dimensional array- Returns:
- an object that represents the size (i.e., length of each dimension) of a 3-dimensional array
-
size
default Size.Size4D size(int length0, int length1, int length2, int length3)
Builds an object that represents the size (i.e., length of each dimension) of a 4-dimensional array.- Parameters:
length0- the size (length) of the first dimension of a 4-dimensional arraylength1- the size (length) of the second dimension of a 4-dimensional arraylength2- the size (length) of the third dimension of a 4-dimensional arraylength3- the size (length) of the fourth dimension of a 4-dimensional array- Returns:
- an object that represents the size (i.e., length of each dimension) of a 4-dimensional array
-
size
default Size.Size5D size(int length0, int length1, int length2, int length3, int length4)
Builds an object that represents the size (i.e., length of each dimension) of a 5-dimensional array.- Parameters:
length0- the size (length) of the first dimension of a 5-dimensional arraylength1- the size (length) of the second dimension of a 5-dimensional arraylength2- the size (length) of the third dimension of a 5-dimensional arraylength3- the size (length) of the fourth dimension of a 5-dimensional arraylength4- the size (length) of the fifth dimension of a 5-dimensional array- Returns:
- an object that represents the size (i.e., length of each dimension) of a 5-dimensional array
-
range
default Range range(int startInclusive, int endExclusive, int step)
Constructs an objectRangefrom the specified bounds and step (difference between each two successive numbers).- Parameters:
startInclusive- the lower bound (inclusive) of this rangeendExclusive- the upper bound (exclusive) of this rangestep- the step of this range- Returns:
- the object
Rangethat represents an interval of values (while considering the specified step)
-
rangeClosed
default Range rangeClosed(int startInclusive, int endInclusive, int step)
Constructs an objectRangefrom the specified bounds and step (difference between each two successive numbers).- Parameters:
startInclusive- the lower bound (inclusive) of this rangeendInclusive- the upper bound (inclusive) of this rangestep- the step of this range- Returns:
- the object
Rangethat represents an interval of values (while considering the specified step)
-
range
default Range range(int startInclusive, int endExclusive)
Constructs an objectRangefrom the specified bounds (using implicitly a step equal to 1).- Parameters:
startInclusive- the lower bound (inclusive) of this rangeendExclusive- the upper bound (exclusive) of this range- Returns:
- the object
Rangethat represents an interval of values
-
rangeClosed
default Range rangeClosed(int startInclusive, int endInclusive)
Constructs an objectRangefrom the specified bounds (using implicitly a step equal to 1).- Parameters:
startInclusive- the lower bound (inclusive) of this rangeendInclusive- the upper bound (inclusive) of this range- Returns:
- the object
Rangethat represents an interval of values
-
range
default Range range(int length)
Constructs an objectRangefrom the specified length (using implicitly a lower bound equal to 0 and a step equal to 1).- Parameters:
length- the length of this range- Returns:
- the object
Rangethat represents an interval of values, from 0 to the specified value (excluded)
-
var
default IVar.Var var(String id, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a stand-alone integer variable with the specified id, domain, note (short comment) and classes. Use methodsdom()for building integer domains. For example:
On our example, we build a stand-alone variable whose domain contains 10 values.Var x = var("x", dom(range(10), "x is the number of products");- Parameters:
id- the id (unique name) of the variabledom- the integer domain of the variablenote- a short comment about the variableclasses- the tags (possibly, none) associated with the variable- Returns:
- a stand-alone integer variable
-
var
default IVar.Var var(String id, Domains.Dom dom, Types.TypeClass... classes)
Builds a stand-alone integer variable with the specified id, domain and classes. Use methodsdom()for building integer domains. For example:
On our example, we build a stand-alone variable whose domain contains 10 values.Var x = var("x", dom(range(10));- Parameters:
id- the id (unique name) of the variabledom- the integer domain of the variableclasses- the tags (possibly, none) associated with the variable- Returns:
- a stand-alone integer variable
-
array
default IVar.Var[] array(String id, Size.Size1D size, FunctionalInterfaces.IntToDom f, String note, Types.TypeClass... classes)
Builds a 1-dimensional array of integer variables with the specified id, size, note (short comment) and classes. Use Methodsize(int)for building the size (length) of the array. The specified functionfassociates an integer domain with each variable at indexiof the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, the first five variables have a domain containing 10 values whereas the next five variables have a domain containing two values only:Var[] = array("x", size(10), i -> i < 5 ? dom(range(10)) : dom(0,1),"x[i] is the number of carrots eaten by the ith rabbit");- Parameters:
id- the id (unique name) of the arraysize- the length of the arrayf- a function that associates an integer domain with any possible indexiof a variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 1-dimensional array of integer variables
-
array
default IVar.Var[] array(String id, Size.Size1D size, FunctionalInterfaces.IntToDom f, Types.TypeClass... classes)
Builds a 1-dimensional array of integer variables with the specified id, size, and classes. Use Methodsize(int)for building the size (length) of the array. The specified functionfassociates an integer domain with each variable at indexiof the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, the first five variables have a domain containing 10 values whereas the next five variables have a domain containing two values only:Var[] = array("x", size(10), i -> i < 5 ? dom(range(10)) : dom(0,1));- Parameters:
id- the id (unique name) of the arraysize- the length of the arrayf- a function that associates an integer domain with any possible indexiof a variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 1-dimensional array of integer variables
-
array
default IVar.Var[] array(String id, Size.Size1D size, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a 1-dimensional array of integer variables with the specified id, size, domain, note and classes. Use Methodsize(int)for building the size (length) of the array. Each variable of the array has the specified integer domain. In the following example, the ten variables have a domain containing 10 values:Var[] = array("x", size(10), dom(range(10), "x[i] is the number of carrots eaten by the ith rabbit");- Parameters:
id- the id (unique name) of the arraysize- the length of the arraydom- the domain of each variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 1-dimensional array of integer variables
-
array
default IVar.Var[] array(String id, Size.Size1D size, Domains.Dom dom, Types.TypeClass... classes)
Builds a 1-dimensional array of integer variables with the specified id, size, domain, and classes. Use Methodsize(int)for building the size (length) of the array. Each variable of the array has the specified integer domain. In the following example, the ten variables have a domain containing 10 values:Var[] = array("x", size(10), dom(range(10));- Parameters:
id- the id (unique name) of the arraysize- the length of the arraydom- the domain of each variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 1-dimensional array of integer variables
-
array
default IVar.Var[][] array(String id, Size.Size2D size, FunctionalInterfaces.Intx2ToDom f, String note, Types.TypeClass... classes)
Builds a 2-dimensional array of integer variables with the specified id, size, note (short comment) and classes. Use Methodsize(int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][] = array("x", size(10, 5), (i,j) -> i < j ? dom(range(10)) : dom(0,1), "x[i][j] is the number of forks built by the jth worker at the ith factory");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j)of a variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 2-dimensional array of integer variables
-
array
default IVar.Var[][] array(String id, Size.Size2D size, FunctionalInterfaces.Intx2ToDom f, Types.TypeClass... classes)
Builds a 2-dimensional array of integer variables with the specified id, size, and classes. Use Methodsize(int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][] = array("x", size(10, 5), (i,j) -> i < j ? dom(range(10)) : dom(0,1));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j)of a variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 2-dimensional array of integer variables
-
array
default IVar.Var[][] array(String id, Size.Size2D size, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a 2-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes. Use Methodsize(int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][] = array("x", size(10, 5), dom(range(10)), "x[i][j] is the number of forks built by the jth worker at the ith factory");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 2-dimensional array of integer variables
-
array
default IVar.Var[][] array(String id, Size.Size2D size, Domains.Dom dom, Types.TypeClass... classes)
Builds a 2-dimensional array of integer variables with the specified id, size, domain, and classes. Use Methodsize(int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][] = array("x", size(10, 5), dom(range(10)));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 2-dimensional array of integer variables
-
array
default IVar.Var[][][] array(String id, Size.Size3D size, FunctionalInterfaces.Intx3ToDom f, String note, Types.TypeClass... classes)
Builds a 3-dimensional array of integer variables with the specified id, size, note (short comment) and classes. Use Methodsize(int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][] = array("x", size(10, 5, 5), (i,j,k) -> i+j == k ? dom(range(10)) : dom(0,1), "x[i][j][k] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k)of a variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 3-dimensional array of integer variables
-
array
default IVar.Var[][][] array(String id, Size.Size3D size, FunctionalInterfaces.Intx3ToDom f, Types.TypeClass... classes)
Builds a 3-dimensional array of integer variables with the specified id, size, and classes. Use Methodsize(int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][] = array("x", size(10, 5, 5), (i,j,k) -> i+j == k ? dom(range(10)) : dom(0,1));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k)of a variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 3-dimensional array of integer variables
-
array
default IVar.Var[][][] array(String id, Size.Size3D size, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a 3-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes. Use Methodsize(int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][] = array("x", size(10, 5, 2), dom(range(10)), "x[i][j][k] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 3-dimensional array of integer variables
-
array
default IVar.Var[][][] array(String id, Size.Size3D size, Domains.Dom dom, Types.TypeClass... classes)
Builds a 3-dimensional array of integer variables with the specified id, size, domain, and classes. Use Methodsize(int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][] = array("x", size(10, 5, 2), dom(range(10)));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 3-dimensional array of integer variables
-
array
default IVar.Var[][][][] array(String id, Size.Size4D size, FunctionalInterfaces.Intx4ToDom f, String note, Types.TypeClass... classes)
Builds a 4-dimensional array of integer variables with the specified id, size, note (short comment) and classes. Use Methodsize(int,int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k,l)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][][] = array("x", size(10, 5, 5, 2), (i,j,k,l) -> i+j == k+l ? dom(range(10)) : dom(0,1), "x[i][j][k][l] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k,l)of a variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 4-dimensional array of integer variables
-
array
default IVar.Var[][][][] array(String id, Size.Size4D size, FunctionalInterfaces.Intx4ToDom f, Types.TypeClass... classes)
Builds a 4-dimensional array of integer variables with the specified id, size, and classes. Use Methodsize(int,int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k,l)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][][] = array("x", size(10, 5, 5, 2), (i,j,k,l) -> i+j == k+l ? dom(range(10)) : dom(0,1));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k,l)of a variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 4-dimensional array of integer variables
-
array
default IVar.Var[][][][] array(String id, Size.Size4D size, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a 4-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes. Use Methodsize(int,int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][][] = array("x", size(10, 5, 2, 2), dom(range(10)), "x[i][j][k][l] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 4-dimensional array of integer variables
-
array
default IVar.Var[][][][] array(String id, Size.Size4D size, Domains.Dom dom, Types.TypeClass... classes)
Builds a 4-dimensional array of integer variables with the specified id, size, domain, and classes. Use Methodsize(int,int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][][] = array("x", size(10, 5, 2, 2), dom(range(10)));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 4-dimensional array of integer variables
-
array
default IVar.Var[][][][][] array(String id, Size.Size5D size, FunctionalInterfaces.Intx5ToDom f, String note, Types.TypeClass... classes)
Builds a 5-dimensional array of integer variables with the specified id, size, note (short comment) and classes. Use Methodsize(int,int,int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k,l,m)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][][][] = array("x", size(10, 5, 5, 2, 2), (i,j,k,l) -> i+j == k+l ? dom(range(10)) : dom(0,1), "x[i][j][k][l] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k,l),mof a variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 5-dimensional array of integer variables
-
array
default IVar.Var[][][][][] array(String id, Size.Size5D size, FunctionalInterfaces.Intx5ToDom f, Types.TypeClass... classes)
Builds a 5-dimensional array of integer variables with the specified id, size, and classes. Use Methodsize(int,int,int,int,int)for building the size (length of each dimension) of the array. The specified functionfassociates an integer domain with each variable at index(i,j,k,l,m)of the array. In case the specified functionfreturn the valuenull, the variable is not built. In the following example, some variables have a domain containing 10 values whereas others have a domain containing two values only:Var[][][][][] = array("x", size(10, 5, 5, 2, 2), (i,j,k,l) -> i+j == k+l ? dom(range(10)) : dom(0,1));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arrayf- a function that associates an integer domain with any possible index(i,j,k,l,m)of a variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 5-dimensional array of integer variables
-
array
default IVar.Var[][][][][] array(String id, Size.Size5D size, Domains.Dom dom, String note, Types.TypeClass... classes)
Builds a 5-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes. Use Methodsize(int,int,int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][][][] = array("x", size(10, 5, 2, 2, 2), dom(range(10)), "x[i][j][k][l][m] is something I can't reveal");- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arraynote- a short comment about the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 5-dimensional array of integer variables
-
array
default IVar.Var[][][][][] array(String id, Size.Size5D size, Domains.Dom dom, Types.TypeClass... classes)
Builds a 5-dimensional array of integer variables with the specified id, size, domain, note (short comment) and classes. Use Methodsize(int,int,int,int,int)for building the size (length of each dimension) of the array. Each variable of the array has the specified integer domain. In the following example, all variables have a domain containing 10 values:Var[][][][][] = array("x", size(10, 5, 2, 2, 2), dom(range(10)));- Parameters:
id- the id (unique name) of the arraysize- the size (length of each dimension) of the arraydom- the domain of each variable in the arrayclasses- the tags (possibly, none) associated with the array- Returns:
- a 5-dimensional array of integer variables
-
ctrFalse
default CtrEntities.CtrEntity ctrFalse(IVar.Var[] scp)
Builds a disentailed integer constraint, i.e., a special constraint that always returnsfalse.- Parameters:
scp- the scope of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by means of method chaining.
-
ctrTrue
default CtrEntities.CtrEntity ctrTrue(IVar.Var[] scp)
Builds an entailed integer constraint, i.e., a special constraint that always returnstrue. For example, it may be useful to achieve some sophisticated tasks related to some forms of consistency.- Parameters:
scp- the scope of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by means of method chaining.
-
intension
default CtrEntities.CtrEntity intension(XNodeParent<IVar> tree)
Builds a constraintintensionfrom the specified argument that represents the root of a syntactic tree. This method can be used with integer variables but also with symbolic variables (but currently, it is not allowed to have both integer and symbolic variables involved simultaneously). As an illustration,
allows us to post:intension(eq(x, add(y, z)))x = y+z- Parameters:
tree- a syntactic tree- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining.
-
abs
default XNodeParent<IVar> abs(Object operand)
Returns the root of a syntactic tree built with the unary operatorabsapplied to the specified operand. For example, one possible call isabs(sub(x,y))that represents|x-y|- Parameters:
operand- an object that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
neg
default XNodeParent<IVar> neg(Object operand)
Returns the root of a syntactic tree built with the unary operatornegapplied to the specified operand. For example, one possible call isneg(add(x,y))that represents-(x+y)- Parameters:
operand- an object that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
sqr
default XNodeParent<IVar> sqr(Object operand)
Returns the root of a syntactic tree built with the unary operatorsqrapplied to the specified operand. For example, one possible call issqr(x)that representsx*x- Parameters:
operand- an object that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
add
default XNodeParent<IVar> add(Object... operands)
Returns the root of a syntactic tree built with the operatoraddapplied to the specified operands. For example, one possible call isadd(x,y,z)that representsx+y+z- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
sub
default XNodeParent<IVar> sub(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorsubapplied to the specified operands. For example, one possible call issub(x,y)that representsx-y- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
mul
default XNodeParent<IVar> mul(Object... operands)
Returns the root of a syntactic tree built with the operatormulapplied to the specified operands. For example, one possible call ismul(x,y)that representsx*y- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
div
default XNodeParent<IVar> div(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatordivapplied to the specified operands. For example, one possible call isdiv(x,y)that representsx/y(integer division)- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
mod
default XNodeParent<IVar> mod(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatormodapplied to the specified operands. For example, one possible call ismod(x,2)that representsx%2- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
pow
default XNodeParent<IVar> pow(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorpowapplied to the specified operands. For example, one possible call ispow(x,3)that representsx^3- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
min
default XNodeParent<IVar> min(Object... operands)
Returns the root of a syntactic tree built with the operatorminapplied to the specified operands. For example, one possible call ismin(x,y,z)- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
max
default XNodeParent<IVar> max(Object... operands)
Returns the root of a syntactic tree built with the operatormaxapplied to the specified operands. For example, one possible call ismax(x,y,z).- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
dist
default XNodeParent<IVar> dist(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatordistapplied to the specified operands. For example, one possible call isdist(x,y)that represents|x-y|- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
lt
default XNodeParent<IVar> lt(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorltapplied to the specified operands. For example, one possible call islt(x,10that representsx<10- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
le
default XNodeParent<IVar> le(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorleapplied to the specified operands. For example, one possible call isle(x,10)that representsx≤10- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
ge
default XNodeParent<IVar> ge(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorgeapplied to the specified operands. For example, one possible call isge(x,10)that representsx≥10- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
gt
default XNodeParent<IVar> gt(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorgtapplied to the specified operands. For example, one possible call isgt(x,10)that representsx>10- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
ne
default XNodeParent<IVar> ne(Object... operands)
Returns the root of a syntactic tree built with the operatorneapplied to the specified operands. For example, one possible call isne(x,y)that representsx≠y- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
eq
default XNodeParent<IVar> eq(Object... operands)
Returns the root of a syntactic tree built with the operatoreqapplied to the specified operands. For example, one possible call iseq(x,y)that representsx=y- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
set
default XNode<IVar> set(Object... operands)
Returns the root of a syntactic tree built with the operatorsetapplied to the specified operands. For example, one possible call isset(1,2,3)that represents{1,2,3}- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
set
default XNode<IVar> set(int[] operands)
Returns the node of a syntactic tree built with the operatorsetapplied to the integers from the specified array. For example, iftid an array containing values 1, 2 and 3, then the callset(t)represents{1,2,3}- Parameters:
operands- an array of integers- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
in
default XNodeParent<IVar> in(Object var, Object set)
Returns the root of a syntactic tree built with the operatorinapplied to the specified operands. For example, one possible call isin(x,set(1,2,3))that representsx∈{1,2,3}- Parameters:
var- the first operand that is typically a variable but can also can be an objectXNodeset- the second operand that must have been built with the operatorset- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
notin
default XNodeParent<IVar> notin(Object var, Object set)
Returns the root of a syntactic tree built with the operatornotinapplied to the specified operands. For example, one possible call isnotin(x,set(1,2,3))that representsx∉{1,2,3}- Parameters:
var- the first operand that is typically a variable but can also can be an objectXNodeset- the second operand that must have been built with the operatorset- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
not
default XNodeParent<IVar> not(Object operand)
Returns the root of a syntactic tree built with the unary operatornotapplied to the specified operand. For example, one possible call isnot(eq(x,y))that represents¬(x=y)- Parameters:
operand- an object that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
and
default XNodeParent<IVar> and(Object... operands)
Returns the root of a syntactic tree built with the operatorandapplied to the specified operands. For example, one possible call isand(eq(x,y),lt(z,3))that representsx=y∧z<3- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
or
default XNodeParent<IVar> or(Object... operands)
Returns the root of a syntactic tree built with the operatororapplied to the specified operands. For example, one possible call isor(eq(x,y),lt(z,3))that representsx=y∨z<3- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
xor
default XNodeParent<IVar> xor(Object... operands)
Returns the root of a syntactic tree built with the operatorxorapplied to the specified operands. For example, one possible call isxor(eq(x,y),lt(z,3))that representsx=y⨁z<3- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
iff
default XNodeParent<IVar> iff(Object... operands)
Returns the root of a syntactic tree built with the operatoriffapplied to the specified operands. For example, one possible call isiff(eq(x,y),lt(z,3))that representsx=y⇔z<3- Parameters:
operands- a sequence of operands that can be integers, variables, or objectsXNode- Returns:
- an object
XNodethat represents the node of a syntactic tree
-
imp
default XNodeParent<IVar> imp(Object operand1, Object operand2)
Returns the root of a syntactic tree built with the binary operatorimpapplied to the specified operands. For example, one possible call isimp(eq(x,y),lt(z,3)that representsx=y⇒z<3- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
XNodeParentthat represents the root of a syntactic tree
-
ifThenElse
default XNodeParent<IVar> ifThenElse(Object operand1, Object operand2, Object operand3)
Returns the root of a syntactic tree built with the binary operatorifapplied to the specified operands. For example, one possible call isif(eq(x,y),2,4)that representsx=y?2:4- Parameters:
operand1- the first operand that must correspond to a Boolean expression (values 0 or 1)operand2- the second operand that can be an integer, a variable, or an objectXNodeoperand3- the third operand that can be an integer, a variable, or an objectXNode- Returns:
- the root of a syntactic tree built from the specified operands
-
knightAttack
default XNodeParent<IVar> knightAttack(IVar x, IVar y, int order)
Returns the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two cells of a flattened matrix (whose order is specified) at a knight distance.- Parameters:
x- a first variabley- a second variableorder- the order of the matrix- Returns:
- the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two distinct cells of a flattened matrix (whose order is specified) at a knight distance
-
queenAttack
default XNodeParent<IVar> queenAttack(IVar x, IVar y, int order)
Returns the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two distinct cells of a flattened matrix (whose order is specified) on the same row, column or diagonal.- Parameters:
x- a first variabley- a second variableorder- the order of the matrix- Returns:
- the root of a syntactic tree that represents the predicate ensuring that the specified variables are put in two cells of a flattened matrix (whose order is specified) at a knight distance
-
lessThan
default CtrEntities.CtrEntity lessThan(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorltapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:lessThan(x, y);intension(lt(x, y));- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
lessEqual
default CtrEntities.CtrEntity lessEqual(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorleapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:lessEqual(x, y);intension(le(x, y));- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
greaterEqual
default CtrEntities.CtrEntity greaterEqual(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorgeapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:greaterEqual(x, y);intension(ge(x, y));- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
greaterThan
default CtrEntities.CtrEntity greaterThan(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorgtapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:greaterThan(x, y);intension(gt(x, y));- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
equal
default CtrEntities.CtrEntity equal(Object... operands)
Builds a constraintintension, while considering the operatoreqapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:equal(x, y);intension(eq(x, y));- Parameters:
operands- the operands that can be integers, variables, or objectsXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
different
default CtrEntities.CtrEntity different(Object... operands)
Builds a constraintintension, while considering the operatorneapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:different(x, y);intension(ne(x, y));- Parameters:
operands- the operands that can be integers, variables, or objectsXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
notEqual
@Deprecated default CtrEntities.CtrEntity notEqual(Object... operands)
Deprecated.
-
belong
default CtrEntities.CtrEntity belong(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorinapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:belong(x, set(1, 2, 3));intension(in(x, set(1, 2, 3)));- Parameters:
operand1- the first operand that can be a variable, or an objectXNodeoperand2- the second operand that must have been built with the operatorset- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
imply
@Deprecated default CtrEntities.CtrEntity imply(Object operand1, Object operand2)
Deprecated.
-
implication
default CtrEntities.CtrEntity implication(Object operand1, Object operand2)
Builds a constraintintension, while considering the operatorimpapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:implication(eq(x, y), lt(z, 3));intension(imp(eq(x, y), lt(z, 3)));- Parameters:
operand1- the first operand that can be an integer, a variable, or an objectXNodeoperand2- the second operand that can be an integer, a variable, or an objectXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
equivalence
default CtrEntities.CtrEntity equivalence(Object... operands)
Builds a constraintintension, while considering the operatoriffapplied to the specified arguments. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:equivalence(eq(x, y), lt(z, 3));intension(iff(eq(x, y), lt(z, 3)));- Parameters:
operands- the operands that can be integers, variables, or objectsXNodehe operands that can be integers, variables, or objectsXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
conjunction
default CtrEntities.CtrEntity conjunction(Object... operands)
Builds a constraintintension, while considering the operatoraddapplied to the specified arguments. This is a modeling ease of use.- Parameters:
operands- the operands that can be integers, variables, or objectsXNodehe operands that can be integers, variables, or objectsXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
disjunction
default CtrEntities.CtrEntity disjunction(Object... operands)
Builds a constraintintension, while considering the operatororapplied to the specified arguments. This is a modeling ease of use.- Parameters:
operands- the operands that can be integers, variables, or objectsXNode- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
treesFrom
default java.util.stream.Stream<XNode<IVar>> treesFrom(IVar[] t, java.util.function.Function<IVar,XNode<IVar>> f)
Returns a stream of syntactic trees (predicates) built by applying the specified function to each variable of the specified array.nullvalues in the array are discarded.- Parameters:
t- an array of variablesf- a function mapping variables into syntactic trees (predicates)- Returns:
- a stream of syntactic trees built by applying the specified function to each variable of the specified array
-
treesFrom
default java.util.stream.Stream<XNode<IVar>> treesFrom(java.util.stream.IntStream stream, java.util.function.Function<Integer,XNode<IVar>> f)
Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified stream.- Parameters:
stream- a stream of integersf- a function mapping integers into syntactic trees (predicates)- Returns:
- a stream of syntactic trees built by applying the specified function to each integer of the specified stream
-
treesFrom
default java.util.stream.Stream<XNode<IVar>> treesFrom(Collection<Integer> c, java.util.function.Function<Integer,XNode<IVar>> f)
Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified collection.nullvalues in the collection are discarded.- Parameters:
c- a collection of integersf- a function mapping integers into syntactic trees (predicates)- Returns:
- a stream of syntactic trees built by applying the specified function to each integer of the specified collection
-
treesFrom
default java.util.stream.Stream<XNode<IVar>> treesFrom(int[] t, java.util.function.Function<Integer,XNode<IVar>> f)
Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified array.- Parameters:
t- an array of integersf- a function mapping integers into syntactic trees (predicates)- Returns:
- a stream of syntactic trees built by applying the specified function to each integer of the specified array
-
treesFrom
default java.util.stream.Stream<XNode<IVar>> treesFrom(Range r, java.util.function.Function<Integer,XNode<IVar>> f)
Returns a stream of syntactic trees (predicates) built by applying the specified function to each integer of the specified range.- Parameters:
r- a rangef- a function mapping integers into syntactic trees (predicates)- Returns:
- a stream of syntactic trees built by applying the specified function to each integer of the specified range
-
extension
default CtrEntities.CtrAlone extension(XNodeParent<IVar> tree)
Builds a constraintextensionfrom the specified syntactic tree (predicate). The specified intentional constraint is converted in extensional form.- Parameters:
tree- the root of a syntactic tree (predicate)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extensionDisjunction
default CtrEntities.CtrAlone extensionDisjunction(List<XNodeParent<IVar>> trees)
-
extensionDisjunction
default CtrEntities.CtrAlone extensionDisjunction(XNodeParent<IVar>... trees)
-
extension
default CtrEntities.CtrEntity extension(IVar.Var[] scp, int[][] tuples, Boolean positive)
Builds a constraintextensionfrom the specified scope and the specified array of tuples, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse). Note that you can use constantsPOSITIVEandNEGATIVE.- Parameters:
scp- the scope of the constrainttuples- the tuples defining the semantics of the constraintpositive- boolean value indicating if the tuples are supports or conflicts- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var[] scp, int[]... tuples)
Builds a constraintextensionfrom the specified scope and the specified array of tuples, seen as supports.- Parameters:
scp- the scope of the constrainttuples- the tuples defining the supports of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var[] scp, Collection<int[]> tuples, Boolean positive)
Builds a constraintextensionfrom the specified scope and the specified collection of tuples, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse). Note that you can use constantsPOSITIVEandNEGATIVE.- Parameters:
scp- the scope of the constrainttuples- the tuples defining the semantics of the constraintpositive- boolean value indicating if the tuples are supports or conflicts- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var[] scp, Collection<int[]> tuples)
Builds a constraintextensionfrom the specified scope and the specified collection of tuples, seen as supports.- Parameters:
scp- the scope of the constrainttuples- the tuples defining the supports of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var[] scp, Table table)
Builds a constraintextensionfrom the specified scope and the specified table, whose elements are seen as supports. An example of integer table that can be constructed is
For a negative table, you can write:table("(1,2,3)(2,1,1)")table("(1,2,3)(2,1,1)").positive(false)- Parameters:
scp- the scope of the constrainttable- the table containing the tuples defining the supports of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var x, int[] values, Boolean positive)
Builds a unary constraintextensionfrom the specified variable and the specified array of values, seen as either supports (whenpositiveistrue) or conflicts (whenpositiveisfalse). Note that you can use constantsPOSITIVEandNEGATIVE.- Parameters:
x- the variable involved in this unary constraintvalues- the values defining the semantics of the constraintpositive- boolean value indicating if the values are supports or conflicts- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var x, int... values)
Builds a unary constraintextensionfrom the specified variable and the specified array of values, seen as supports.- Parameters:
x- the variable involved in this unary constraintvalues- the values defining the semantics of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
extension
default CtrEntities.CtrEntity extension(IVar.Var x, Table table)
Builds a unary constraintextensionfrom the specified variable and the specified table.- Parameters:
x- the variable involved in this unary constrainttable- the table defining the semantics of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
regular
default CtrEntities.CtrEntity regular(IVar.Var[] scp, Automaton automaton)
Builds a constraintregularfrom the specified scope and the specified automaton. Note that an automaton can be built as in the following example:Transitions transitions = Transitions.parse("(q0,0,q1)(q0,2,q2)(q1,0,q3)(q2,2,q3)"); Automaton automata = new Automaton(transitions, "q0", tuple("q2", "q3"));)- Parameters:
scp- the scope of the constraintautomaton- the automaton defining the semantics of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
mdd
default CtrEntities.CtrEntity mdd(IVar.Var[] scp, Transitions transitions)
-
mdd
default CtrEntities.CtrEntity mdd(IVar.Var[] scp, Transition[] transitions)
Builds a constraintmddfrom the specified scope and the specified transitions. Note that transitions can be built as in the following example:Transitions transitions = Transitions.parse("(q0,0,q1)(q0,2,q2)(q1,0,q3)(q2,2,q3)");- Parameters:
scp- the scope of the constrainttransitions- the transitions defining the MDD, and consequently the semantics of the constraint- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(IVar.Var[] list)
Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(IVar.Var x, IVar.Var... others)
Builds a constraintallDifferenton the specified integer variables: the variables must all take different values.- Parameters:
x- a first integer variableothers- a sequence of other integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(IVar.Var[]... list)
Builds a constraintallDifferenton the specified integer variables: the variables must all take different values. Note that the specified 2-dimensional array of variables will be flattened (i.e., converted into a 1-dimensional array of variables). Do not mistake this form withallDifferentList- Parameters:
list- the involved integer variables (a 2-dimensional array)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(IVar.Var[][][] list)
Builds a constraintallDifferenton the specified integer variables: the variables must all take different values. Note that the specified 3-dimensional array of variables will be flattened (i.e., converted into a 1-dimensional array of variables).- Parameters:
list- the involved integer variables (a 3-dimensional array)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferentExcept
@Deprecated default CtrEntities.CtrEntity allDifferentExcept(IVar.Var[] list, int... exceptValues)
Deprecated.
-
allDifferent
default CtrEntities.CtrEntity allDifferent(IVar.Var[] list, int... exceptValues)
Builds a constraintallDifferenton the specified integer variables: the variables must take different values, except those that take one of the specified 'exceptional' values.- Parameters:
list- the involved integer variablesexceptValues- the values that must be ignored- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferentList
default CtrEntities.CtrEntity allDifferentList(IVar.Var[]... lists)
Builds a constraintallDifferentListon the specified lists of variables: all tuples formed by the different lists must be different.- Parameters:
lists- a 2-dimensional array of variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferentMatrix
default CtrEntities.CtrEntity allDifferentMatrix(IVar.Var[][] matrix)
Builds a constraintallDifferentMatrixon the specified matrix of variables. On each row and on each column, the variables must all take different values.- Parameters:
matrix- a 2-dimensional array of variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(XNode<IVar>[] trees)
Builds a constraintallDifferenton the specified syntactic trees (predicates): the predicates, when evaluated, must all take different values.- Parameters:
trees- an array of syntactic trees (predicates)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allDifferent
default CtrEntities.CtrEntity allDifferent(java.util.stream.Stream<XNode<IVar>> trees)
Builds a constraintallDifferenton the specified (stream of) syntactic trees (predicates): the predicates, when evaluated, must all take different values.- Parameters:
trees- a stream of syntactic trees (predicates)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allEqual
default CtrEntities.CtrEntity allEqual(IVar.Var... list)
Builds a constraintallEqualon the specified integer variables: the variables must all take the same value. Basically, this is a modeling ease of use.- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allEqual
default CtrEntities.CtrEntity allEqual(IVar.Var[][] list)
Builds a constraintallEqualon the specified integer variables: the variables must all take the same value. Basically, this is a modeling ease of use. Note that the specified 2-dimensional array of variables will be flattened (i.e., converted into a 1-dimensional array of variables). Do not mistake this form withallEqualList- Parameters:
list- the involved integer variables (a 2-dimensional array)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
allEqualList
default CtrEntities.CtrEntity allEqualList(IVar.Var[]... lists)
Builds a constraintallEqualListon the specified lists of variables: all tuples formed by the different lists must be equal.- Parameters:
lists- a 2-dimensional array of variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
ordered
default CtrEntities.CtrEntity ordered(IVar.Var[] list, int[] lengths, Types.TypeOperatorRel operator)
Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator, while considering the specified lengths. We have:
In general, the size offor any i in 0..list.length-1, list[i] + lengths[i] <op> list[i+1]lengthsis the size oflistminus 1. But, for simplicity, it is authorized to have the size oflengthsbeing equal to that oflist, in which case the last value of the integer array is simply ignored. Basically, this constraint is a modeling ease of use.- Parameters:
list- the involved integer variableslengths- the lengths usedoperator- a relational operator (STRICTLY_INCREASING, INCREASING, DECREASING or STRICTLY_DECREASING)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
ordered
default CtrEntities.CtrEntity ordered(IVar.Var[] list, IVar.Var[] lengths, Types.TypeOperatorRel operator)
Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator, while considering the specified lengths. We have:
In general, the size offor any i in 0..list.length-1, list[i] + lengths[i] <op> list[i+1]lengthsis the size oflistminus 1. But, for simplicity, it is authorized to have the size oflengthsbeing equal to that oflist, in which case the last value of the integer array is simply ignored. Basically, this constraint is a modeling ease of use.- Parameters:
list- the involved integer variableslengths- the lengths usedoperator- a relational operator (STRICTLY_INCREASING, INCREASING, DECREASING or STRICTLY_DECREASING)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
ordered
default CtrEntities.CtrEntity ordered(IVar.Var[] list, Types.TypeOperatorRel operator)
Builds a constraintorderedon the specified lists of variables: any two successive variables must respect the specified operator. Basically, this is a modeling ease of use.- Parameters:
list- the involved integer variablesoperator- a relational operator (STRICTLY_INCREASING, INCREASING, DECREASING or STRICTLY_DECREASING)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
strictlyIncreasing
default CtrEntities.CtrEntity strictlyIncreasing(IVar.Var... list)
Builds a constraintorderedon the specified lists of variables, while considering a strict increasing order. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:strictlyIncreasing(x);ordered(x, STRICTLY_INCREASING);- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
increasing
default CtrEntities.CtrEntity increasing(IVar.Var... list)
Builds a constraintorderedon the specified lists of variables, while considering an increasing order. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:increasing(x);ordered(x, INCREASING);- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
decreasing
default CtrEntities.CtrEntity decreasing(IVar.Var... list)
Builds a constraintorderedon the specified lists of variables, while considering a decreasing order. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:decreasing(x);ordered(x, DECREASING);- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
strictlyDecreasing
default CtrEntities.CtrEntity strictlyDecreasing(IVar.Var... list)
Builds a constraintorderedon the specified lists of variables, while considering a strict decreasing order. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:strictlydecreasing(x);ordered(x, STRICTLY_DeCREASING);- Parameters:
list- the involved integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
lex
default CtrEntities.CtrEntity lex(IVar.Var[][] lists, Types.TypeOperatorRel operator)
Builds a constraintlexon the specified 2-dimensional array of variables: any two successive rows of variables must respect the specified operator. Basically, this is a modeling ease of use.- Parameters:
lists- a 2-dimensional array of integer variablesoperator- a relational operator (STRICTLY_INCREASING, INCREASING, DECREASING or STRICTLY_DECREASING)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
strictlyIncreasing
default CtrEntities.CtrEntity strictlyIncreasing(IVar.Var[]... lists)
Builds a constraintlexon the specified 2-dimensional array of variables, while considering a strict increasing order on rows. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:strictlyIncreasing(x);ordered(x, STRICTLY_INCREASING);- Parameters:
lists- a 2-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
increasing
default CtrEntities.CtrEntity increasing(IVar.Var[]... lists)
Builds a constraintlexon the specified 2-dimensional array of variables, while considering an increasing order on rows. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:increasing(x);ordered(x, INCREASING);- Parameters:
lists- a 2-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
decreasing
default CtrEntities.CtrEntity decreasing(IVar.Var[]... lists)
Builds a constraintlexon the specified 2-dimensional array of variables, while considering a decreasing order on rows. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:decreasing(x);ordered(x, DeCREASING);- Parameters:
lists- a 2-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
strictlyDecreasing
default CtrEntities.CtrEntity strictlyDecreasing(IVar.Var[]... lists)
Builds a constraintlexon the specified 2-dimensional array of variables, while considering a strict decreasing order on rows. This is a modeling ease of use. As an illustration,
is equivalent (a shortcut) to:strictlyDecreasing(x);ordered(x, STRICTLY_DECREASING);- Parameters:
lists- a 2-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
lexMatrix
default CtrEntities.CtrEntity lexMatrix(IVar.Var[][] matrix, Types.TypeOperatorRel operator)
Builds a constraintlexMatrixon the specified matrix of variables. Any two successive rows of variables and any two successive columns of variables must respect the specified operator.- Parameters:
matrix- a 2-dimensional array of integer variablesoperator- a relational operator (STRICTLY_INCREASING, INCREASING, DECREASING or STRICTLY_DECREASING)- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, int[] coeffs, Condition condition)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Condition condition)
Builds a constraintsumfrom the specified arguments: the sum must respect the specified condition.- Parameters:
list- the summed variablescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, t, EQ, 10);- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Range coeffs, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit. The coefficients are given under the form of a range. As an illustration,sum(x, range(5), EQ, 10);- Parameters:
list- the summed variablescoeffs- the range of values used as coefficients for the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, EQ, 10);- Parameters:
list- the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, t, GT, z);- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, GT, z);- Parameters:
list- the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,sum(x, t, IN, range(1, 4));- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,sum(x, IN, 1, 4);- Parameters:
list- the summed variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, int[] coeffs, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified set of values. As an illustration,sum(x, t, NOTIN, vals(1, 3, 5, 6));- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified set of values. As an illustration,sum(x, NOTIN, vals(1, 3, 5, 6));- Parameters:
list- the summed variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, IVar.Var[] coeffs, Condition condition)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, y, LE, 100);- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit. As an illustration,sum(x, y, LE, z);- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,sum(x, y, IN, 1, 4);- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(IVar.Var[] list, IVar.Var[] coeffs, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified set of values. As an illustration,sum(x, y, NOTIN, vals(1, 3, 5, 6));- Parameters:
list- the summed variablescoeffs- the coefficients associated with the summed variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, int[] coeffs, Condition condition)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.- Parameters:
trees- an array of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, Condition condition)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the specified condition.- Parameters:
trees- an array of syntactic trees (usually, predicates)condition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- an array of syntactic trees (usually, predicates)op- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- an array of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- an array of syntactic trees (usually, predicates)op- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(XNode<IVar>[] trees, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- an array of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Condition condition)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the specified condition.- Parameters:
trees- a stream of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, Condition condition)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the specified condition.- Parameters:
trees- a stream of syntactic trees (usually, predicates)condition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- a stream of syntactic trees (usually, predicates)op- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Types.TypeConditionOperatorRel op, long limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- a stream of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the (simple) sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- a stream of syntactic trees (usually, predicates)op- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
sum
default CtrEntities.CtrEntity sum(java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintsumfrom the specified arguments: the weighted sum must respect the condition expressed by the specified operator and the specified limit.- Parameters:
trees- a stream of syntactic trees (usually, predicates)coeffs- the coefficients associated with the syntactic treesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the sum is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int[] values, Condition condition)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the specified condition.- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integerscondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int[] values, Types.TypeConditionOperatorRel op, int limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, vals(0, 1), LE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int value, Types.TypeConditionOperatorRel op, int limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, 0, LE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int[] values, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, vals(0, 1), LE, z);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int value, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, 0, LE, z);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int[] values, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,count(x, vals(0, 1), IN, 1, 4);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int value, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,count(x, 0, IN, 1, 4);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int[] values, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified set of values. As an illustration,count(x, vals(0, 1), IN, t);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, int value, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value must respect the condition expressed by the specified set operator and the specified set of values. As an illustration,count(x, 1, IN, t);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var[] values, Condition condition)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the specified condition.- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorRel op, int limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, y, LE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorRel op, int limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the assigned value must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, y, LE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer variableop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, y, LE, z);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the assigned value must respect the condition expressed by the specified operator and the specified limit. As an illustration,count(x, y, LE, z);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer variableop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the count is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the values must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,count(x, y, IN, 1, 4);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the value must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,count(x, y, IN, 1, 4);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer variableop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var[] values, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values must respect the condition expressed by the specified set operator and the specified set of values. As an illustration,count(x, y, IN, t);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
count
default CtrEntities.CtrEntity count(IVar.Var[] list, IVar.Var value, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the value must respect the condition expressed by the specified set operator and the specified set of values. As an illustration,count(x, y, IN, t);- Parameters:
list- a 1-dimensional array of integer variablesvalue- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atLeast
default CtrEntities.CtrEntity atLeast(IVar.Var[] list, int value, int k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least equal tok. As an illustration,
is equivalent (a shortcut) to:atLeast(x, 0, 5);count(x, 0, GE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atMost
default CtrEntities.CtrEntity atMost(IVar.Var[] list, int value, int k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most equal tok. As an illustration,
is equivalent (a shortcut) to:atMost(x, 0, 5);count(x, 0, LE, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
exactly
default CtrEntities.CtrEntity exactly(IVar.Var[] list, int value, int k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactlyk. As an illustration,
is equivalent (a shortcut) to:exactly(x, 0, 5);count(x, 0, EQ, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
among
default CtrEntities.CtrEntity among(IVar.Var[] list, int[] values, int k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values is exactlyk. As an illustration,
is equivalent (a shortcut) to:among(x, vals(2, 3, 4), 5);count(x, vals(2, 3, 4), EQ, 5);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersk- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atLeast
default CtrEntities.CtrEntity atLeast(IVar.Var[] list, int value, IVar.Var k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least equal tok. As an illustration,
is equivalent (a shortcut) to:atLeast(x, 0, k);count(x, 0, GE, k);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atMost
default CtrEntities.CtrEntity atMost(IVar.Var[] list, int value, IVar.Var k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most equal tok. As an illustration,
is equivalent (a shortcut) to:atMost(x, 0, k);count(x, 0, LE, k);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
exactly
default CtrEntities.CtrEntity exactly(IVar.Var[] list, int value, IVar.Var k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactlyk. As an illustration,
is equivalent (a shortcut) to:exactly(x, 0, k);count(x, 0, EQ, k);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integerk- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
among
default CtrEntities.CtrEntity among(IVar.Var[] list, int[] values, IVar.Var k)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take one of the specified values is exactlyk. As an illustration,
is equivalent (a shortcut) to:among(x, vals(2, 3, 4), k);count(x, vals(2, 3, 4), EQ, k);- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersk- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atLeast1
default CtrEntities.CtrEntity atLeast1(IVar.Var[] list, int value)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at least 1. As an illustration,
is equivalent (a shortcut) to:atLeast1(x, 2);count(x, 2, GE, 1);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
atMost1
default CtrEntities.CtrEntity atMost1(IVar.Var[] list, int value)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is at most 1. As an illustration,
is equivalent (a shortcut) to:atMost1(x, 2);count(x, 2, LE, 1);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
exactly1
default CtrEntities.CtrEntity exactly1(IVar.Var[] list, int value)
Builds a constraintcountfrom the specified arguments: the number of variables in the specified list that take the specified value is exactly 1. As an illustration,
is equivalent (a shortcut) to:exactly1(x, 2);count(x, 2, EQ, 1);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Condition condition)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the specified condition.- Parameters:
list- a 1-dimensional array of integer variablescondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, int limit)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified operator and the specified limit. As an illustration,nValues(x, GE, 3);- Parameters:
list- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the number is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified operator and the specified limit. As an illustration,nValues(x, GE, k);- Parameters:
list- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the number is compared- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified set operator and the specified interval (range). As an illustration,nValues(x, IN, range(1, 3));- Parameters:
list- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values taken by variables of the specified list must respect the condition expressed by the specified set operator and the specified set of values. As an illustration,nValues(x, IN, vals(2, 3, 4));- Parameters:
list- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparison- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Condition condition, int... exceptValues)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the specified condition.- Parameters:
list- a 1-dimensional array of integer variablescondition- an objectconditioncomposed of an operator and an operandexceptValues- a sequence of integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, int limit, int... exceptValues)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified limit. As an illustration,nValues(x, GT, 3, exceptValue(0));- Parameters:
list- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the number is comparedexceptValues- a sequence of integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorRel op, IVar.Var limit, int... exceptValues)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified limit. As an illustration,nValuesExcept(x, GT, k, exceptValue(0));- Parameters:
list- a 1-dimensional array of integer variablesop- a relational operator (LT, LE, GE, GT, NE, or EQ)limit- the right operand to which the number is comparedexceptValues- a sequence of integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, Range range, int... exceptValues)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified interval (range). As an illustration,nValuesExcept(x, IN, range(1, 3), exceptValue(0));- Parameters:
list- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)range- a range (interval) of values involved in the comparisonexceptValues- a sequence of integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
nValues
default CtrEntities.CtrEntity nValues(IVar.Var[] list, Types.TypeConditionOperatorSet op, int[] set, int... exceptValues)
Builds a constraintnValuesfrom the specified arguments: the number of distinct values that are taken by variables of the specified list and that do not occur among those specified must respect the condition expressed by the specified operator and the specified set of values. As an illustration,nValuesExcept(x, IN, vals(1, 3, 5), exceptValue(0));- Parameters:
list- a 1-dimensional array of integer variablesop- a set operator (IN or NOTIN)set- the set of values involved in the comparisonexceptValues- a sequence of integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
notAllEqual
default CtrEntities.CtrEntity notAllEqual(IVar.Var... list)
Builds a constraintnValuesfrom the specified arguments: at least two distinct values are assigned to the variables of the specified list.- Parameters:
list- a 1-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cardinality
default CtrEntities.CtrEntity cardinality(IVar.Var[] list, int[] values, boolean mustBeClosed, ProblemAPIBase.Occurrences occurrences)
Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences. These conditions can be stated as follows:- when the object
Occurrencesrepresents a simple integerv, obtained by calling MethodoccursEachExactly(int),k_imust be exactlyv - when the object
Occurrencesrepresents a 1-dimensional array of integerst, obtained by calling MethodoccurExactly(int[]),k_imust be exactlyt[i] - when the object
OccursEachBetweeenrepresents an interval of integersv..w, obtained by calling MethodoccursEachBetween(int,int),k_imust belong tov..w - when the object
OccursBetweenrepresents two 1-dimensional arrays of integerst1 and t2, obtained by calling MethodoccurBetween(int[],int[]),k_imust belong tot1[i]..t2[i] - when the object
Occurrencesrepresents a 1-dimensional array of integer variablesx, obtained by calling MethodoccurExactly(Var[]),k_imust be the same value asx[i]
true, it is required that all variables inlistare assigned a value invalues.
As an illustration, enforcing values 1 and 2 to occur exactly 5 times each is given by:
Enforcing values 1 and 2 to occur between 3 and 5 times each is given by:cardinality(x, vals(1, 2), true, occursEachExactly(5));
Enforcing values 1 and 2 to occur exactly y1 and y2 times, with y1 and y2 two variables, each is given by:cardinality(x, vals(1, 2), true, occursEachBetween(3, 5));cardinality(x, vals(1, 2), true, occurExactly(y1, y2));- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersmustBeClosed-trueiff all variables oflistmust necessarily be assigned to a value invaluesoccurrences- an objectOccurrences- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- when the object
-
cardinality
default CtrEntities.CtrEntity cardinality(IVar.Var[] list, int[] values, ProblemAPIBase.Occurrences occurrences)
Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences. These conditions can be stated as follows:- when the object
Occurrencesrepresents a simple integerv, obtained by calling MethodoccursEachExactly(int),k_imust be exactlyv - when the object
Occurrencesrepresents a 1-dimensional array of integerst, obtained by calling MethodoccurExactly(int[]),k_imust be exactlyt[i] - when the object
OccursEachBetweeenrepresents an interval of integersv..w, obtained by calling MethodoccursEachBetween(int,int),k_imust belong tov..w - when the object
OccursBetweenrepresents two 1-dimensional arrays of integerst1 and t2, obtained by calling MethodoccurBetween(int[],int[]),k_imust belong tot1[i]..t2[i] - when the object
Occurrencesrepresents a 1-dimensional array of integer variablesx, obtained by calling MethodoccurExactly(Var[]),k_imust be the same value asx[i]
Enforcing values 1 and 2 to occur between 3 and 5 times each is given by:cardinality(x, vals(1, 2), occursEachExactly(5));
Enforcing values 1 and 2 to occur exactly y1 and y2 times, with y1 and y2 two variables, each is given by:cardinality(x, vals(1, 2), occursEachBetween(3, 5));cardinality(x, vals(1, 2), occurExactly(y1, y2));- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integersoccurrences- an objectOccurrences- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- when the object
-
cardinality
default CtrEntities.CtrEntity cardinality(IVar.Var[] list, Range values, ProblemAPIBase.Occurrences occurrences)
Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer in the rangevaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences. These conditions can be stated as follows:- when the object
Occurrencesrepresents a simple integerv, obtained by calling MethodoccursEachExactly(int),k_imust be exactlyv - when the object
Occurrencesrepresents a 1-dimensional array of integerst, obtained by calling MethodoccurExactly(int[]),k_imust be exactlyt[i] - when the object
OccursEachBetweeenrepresents an interval of integersv..w, obtained by calling MethodoccursEachBetween(int,int),k_imust belong tov..w - when the object
OccursBetweenrepresents two 1-dimensional arrays of integerst1 and t2, obtained by calling MethodoccurBetween(int[],int[]),k_imust belong tot1[i]..t2[i] - when the object
Occurrencesrepresents a 1-dimensional array of integer variablesx, obtained by calling MethodoccurExactly(Var[]),k_imust be the same value asx[i]
Enforcing values 1, 2, 3 and 4 to occur between 3 and 5 times each is given by:cardinality(x, range(1, 4), occursEachExactly(5));
Enforcing values 1, 2, 3 and 4 to occur exactly y[i] times, with y an array of variables and i the index of each value in turn, each is given by:cardinality(x, range(1, 4), occursEachBetween(3, 5));cardinality(x, range(1, 4), occurExactly(y));- Parameters:
list- a 1-dimensional array of integer variablesvalues- a range of integersoccurrences- an objectOccurrences- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- when the object
-
cardinality
default CtrEntities.CtrEntity cardinality(IVar.Var[] list, IVar.Var[] values, boolean mustBeClosed, ProblemAPIBase.Occurrences occurrences)
Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences. These conditions can be stated as follows:- when the object
Occurrencesrepresents a simple integerv, obtained by calling MethodoccursEachExactly(int),k_imust be exactlyv - when the object
Occurrencesrepresents a 1-dimensional array of integerst, obtained by calling MethodoccurExactly(int[]),k_imust be exactlyt[i] - when the object
OccursEachBetweeenrepresents an interval of integersv..w, obtained by calling MethodoccursEachBetween(int,int),k_imust belong tov..w - when the object
OccursBetweenrepresents two 1-dimensional arrays of integerst1 and t2, obtained by calling MethodoccurBetween(int[],int[]),k_imust belong tot1[i]..t2[i] - when the object
Occurrencesrepresents a 1-dimensional array of integer variablesx, obtained by calling MethodoccurExactly(Var[]),k_imust be the same value asx[i]
true, it is required that all variables inlistare assigned a value invalues.
As an illustration, enforcing values from array y to occur exactly 5 times each is given by:
Enforcing values from array y to occur between 3 and 5 times each is given by:cardinality(x, y, true, occursEachExactly(5));
Enforcing value y[i] to occur exactly z[i] times is given by:cardinality(x, y, true, occursEachBetween(3, 5));cardinality(x, y, true, occurExactly(z));- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesmustBeClosed-trueiff all variables oflistmust necessarily be assigned to a value invaluesoccurrences- an objectOccurrences- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- when the object
-
cardinality
default CtrEntities.CtrEntity cardinality(IVar.Var[] list, IVar.Var[] values, ProblemAPIBase.Occurrences occurs)
Builds a constraintcardinalityfrom the specified arguments: when considering the sequence of values assigned to the variables oflist, each integer invaluesat indeximust occur a number of timesk_ithat respects the conditions imposed by the objectOccurrences. These conditions can be stated as follows:- when the object
Occurrencesrepresents a simple integerv, obtained by calling MethodoccursEachExactly(int),k_imust be exactlyv - when the object
Occurrencesrepresents a 1-dimensional array of integerst, obtained by calling MethodoccurExactly(int[]),k_imust be exactlyt[i] - when the object
OccursEachBetweeenrepresents an interval of integersv..w, obtained by calling MethodoccursEachBetween(int,int),k_imust belong tov..w - when the object
OccursBetweenrepresents two 1-dimensional arrays of integerst1 and t2, obtained by calling MethodoccurBetween(int[],int[]),k_imust belong tot1[i]..t2[i] - when the object
Occurrencesrepresents a 1-dimensional array of integer variablesx, obtained by calling MethodoccurExactly(Var[]),k_imust be the same value asx[i]
Enforcing values from array y to occur between 3 and 5 times each is given by:cardinality(x, y, occursEachExactly(5));
Enforcing value y[i] to occur exactly z[i] times is given by:cardinality(x, y, occursEachBetween(3, 5));cardinality(x, y, occurrences(z));- Parameters:
list- a 1-dimensional array of integer variablesvalues- a 1-dimensional array of integer variablesoccurs- an objectOccurrences- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- when the object
-
maximum
default CtrEntities.CtrEntity maximum(IVar.Var[] list, Condition condition)
Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust respect the specified condition. Note that the arraylistis cleaned (i.e.,nullvalues are discarded).
As an illustration, enforcing the maximum value of x to be strictly less than 10 is given by:maximum(x, condition(LT, 10));- Parameters:
list- a 1-dimensional array of integer variablescondition- an objectConditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
maximum
default CtrEntities.CtrEntity maximum(IVar.Var[] list, IVar.Var value)
Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be equal to the value assigned to the variablevalue. Note that the arraylistis cleaned (i.e.,nullvalues are discarded).
As an illustration, enforcing the maximum value of x to be m is given by:maximum(x, m);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
maximum
default CtrEntities.CtrEntity maximum(IVar.Var[] list, ProblemAPIBase.Index index)
Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variable. Note thatindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith maximum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith maximum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith maximum value.
Index, use Methodindex(Var)or Methodindex(Var,TypeRank).
As an illustration, enforcing i to be the index of any variable in x (indexing being started at 0) with maximum value is given by:
Enforcing i to be the index of the first variable in x (indexing being started at 0) with maximum value is given by:maximum(x, index(i));maximum(x, index(i, FIRST));- Parameters:
list- a 1-dimensional array of integer variablesindex- an object wrapping the variable corresponding to the index of a variable inlistwith maximum value- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
maximum
default CtrEntities.CtrEntity maximum(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)
Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition. Note thatstartIndex.valueindicates the number used to access the first variable inlistwhereasindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith maximum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith maximum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith maximum value.
StartIndex, use MethodstartIndex(int), for building an objectIndex, use Methodindex(Var)or Methodindex(Var,TypeRank)and for building an objectConditionuse methodscondition().
As an illustration, enforcing i to be the index of any variable in x (indexing being started at 1) with maximum value strictly greater than 10 is given by:
Enforcing i to be the index of the first variable in x (indexing being started at 10) with maximum value strictly greater than 10 is given by:maximum(x, startIndex(1), index(i), condition(GT, 10));maximum(x, startIndex(10), index(i, FIRST), condition(GT, 10));- Parameters:
list- a 1-dimensional array of integer variablesstartIndex- the number used to access the first variable inlistindex- an object wrapping the variable corresponding to the index of a variable inlistwith maximum valuecondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
maximum
default CtrEntities.CtrEntity maximum(IVar.Var[] list, IVar.Var index, Condition condition)
Builds a constraintmaximumfrom the specified arguments: the maximum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition. Note that indexing starts at 0 and thatindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith maximum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith maximum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith maximum value.
Index, use Methodindex(Var)or Methodindex(Var,TypeRank)and for building an objectConditionuse methodscondition().
As an illustration, enforcing i to be the index of any variable in x (indexing starting at 0, by default) with maximum value strictly greater than 10 is given by:maximum(x, at(i), condition(GT, 10));- Parameters:
list- a 1-dimensional array of integer variablesindex- the variable corresponding to the index of a variable inlistwith maximum valuecondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
minimum
default CtrEntities.CtrEntity minimum(IVar.Var[] list, Condition condition)
Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust respect the specified condition. Note that the arraylistis cleaned (i.e.,nullvalues are discarded).
As an illustration, enforcing the minimum value of x to be strictly less than 10 is given by:minimum(x, condition(LT, 10));- Parameters:
list- a 1-dimensional array of integer variablescondition- an objectConditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
minimum
default CtrEntities.CtrEntity minimum(IVar.Var[] list, IVar.Var value)
Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be equal to the value assigned to the variablevalue. Note that the arraylistis cleaned (i.e.,nullvalues are discarded).
As an illustration, enforcing the minimum value of x to be m is given by:minimum(x, m);- Parameters:
list- a 1-dimensional array of integer variablesvalue- an integer variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
minimum
default CtrEntities.CtrEntity minimum(IVar.Var[] list, ProblemAPIBase.Index index)
Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variable. Note thatindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith minimum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith minimum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith minimum value.
Index, use Methodindex(Var)or Methodindex(Var,TypeRank).
As an illustration, enforcing i to be the index of any variable in x (indexing being started at 0) with minimum value is given by:
Enforcing i to be the index of the first variable in x (indexing being started at 0) with minimum value is given by:minimum(x, index(i));minimum(x, index(i, FIRST));- Parameters:
list- a 1-dimensional array of integer variablesindex- an object wrapping the variable corresponding to the index of a variable inlistwith minimum value- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
minimum
default CtrEntities.CtrEntity minimum(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)
Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition. Note thatstartIndex.valueindicates the number used to access the first variable inlistwhereasindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith minimum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith minimum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith minimum value.
StartIndex, use MethodstartIndex(int), for building an objectIndex, use Methodindex(Var)or Methodindex(Var,TypeRank)and for building an objectConditionuse methodscondition().
As an illustration, enforcing i to be the index of any variable in x (indexing being started at 1) with minimum value strictly greater than 10 is given by:
Enforcing i to be the index of the first variable in x (indexing being started at 10) with minimum value strictly greater than 10 is given by:minimum(x, startIndex(1), index(i), condition(GT, 10));minimum(x, startIndex(10), index(i, FIRST), condition(GT, 10));- Parameters:
list- a 1-dimensional array of integer variablesstartIndex- the number used to access the first variable inlistindex- an object wrapping the variable corresponding to the index of a variable inlistwith minimum valuecondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
minimum
default CtrEntities.CtrEntity minimum(IVar.Var[] list, IVar.Var index, Condition condition)
Builds a constraintminimumfrom the specified arguments: the minimum of the values assigned to the variables oflistmust be the value assigned to the variable oflistatindex.variableand besides this value must respect the specified condition. Note that indexing starts at 0 and thatindex.rankindicates ifindex.variablemust be:- the smallest valid number (FIRST), meaning that
index.variablemust refer to the first variable inlistwith minimum value - the greatest valid number (LAST), meaning that
index.variablemust refer to the last variable inlistwith minimum value - or any valid number (ANY), meaning that
index.variablecan refer to any variable inlistwith minimum value.
Index, use Methodindex(Var)or Methodindex(Var,TypeRank)and for building an objectConditionuse methodscondition().
As an illustration, enforcing i to be the index of any variable in x (indexing starting at 0, by default) with minimum value strictly greater than 10 is given by:
Enforcing i to be the index of the first variable in x (indexing starting at 0, by default) with minimum value strictly greater than 10 is given by:minimum(x, index(i), condition(GT, 10));minimum(x, index(i, FIRST), condition(GT, 10));- Parameters:
list- a 1-dimensional array of integer variablesindex- the variable corresponding to the index of a variable inlistwith minimum valuecondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
- the smallest valid number (FIRST), meaning that
-
element
default CtrEntities.CtrEntity element(IVar.Var[] list, Condition condition)
-
element
default CtrEntities.CtrEntity element(IVar.Var[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)
-
element
default CtrEntities.CtrEntity element(IVar.Var[] list, IVar.Var index, Condition condition)
-
element
default CtrEntities.CtrEntity element(int[] list, int startIndex, ProblemAPIBase.Index index, Condition condition)
-
element
default CtrEntities.CtrEntity element(int[] list, IVar.Var index, Condition condition)
-
element
default CtrEntities.CtrEntity element(int[][] matrix, int startRowIndex, IVar.Var rowIndex, int startColIndex, IVar.Var colIndex, Condition condition)
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list, int startIndex)
Builds a constraintchannelfrom the specified arguments: the valuejis assigned to the ith variable oflistiff the valueiis assigned to the jth variable oflist. Note thatstartIndex.valueindicates the number used to access the first variable inlist. Important: for building an objectStartIndex, use MethodstartIndex(int)
As an illustration, enforcing a channeling constraint on x (indexing starting at 1) is given by:channel(x, startIndex(1));- Parameters:
list- a 1-dimensional array of integer variablesstartIndex- the number used to access the first variable inlist- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list)
Builds a constraintchannelfrom the specified arguments: the valuejis assigned to the ith variable oflistiff the valueiis assigned to the jth variable oflist. Note that indexing starts at 0 (default value).
As an illustration, enforcing a channeling constraint on x (indexing starting at 0, by default) is given by:channel(x);- Parameters:
list- a 1-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list1, int startIndex1, IVar.Var[] list2, int startIndex2)
Builds a constraintchannelfrom the specified arguments: assuming for simplicity that indexing start at 0, the valuejis assigned to the ith variable oflist1iff the valueiis assigned to the jth variable oflist2.
The size of the arraylist1[i] = j => list2|j] = ilist1must be less than or equal to the size oflist2. Still, assuming for simplicity that indexing starts at 0, When both arrays have the same size, we have:
Note thatlist1[i] = j <=> list2|j] = istartIndex1.valueindicates the number used to access the first variable inlist1, and similarlystartIndex2.valueindicates the number used to access the first variable inlist2. Important: for building an objectStartIndex, use MethodstartIndex(int)
As an illustration, enforcing a channeling constraint between x and y (indexing starting at 1 and 0, respectively) is given by:channel(x, startIndex(1), y, startIndex(0));- Parameters:
list1- a first 1-dimensional array of integer variablesstartIndex1- the number used to access the first variable inlist1list2- a second 1-dimensional array of integer variablesstartIndex2- the number used to access the first variable inlist2- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list1, IVar.Var[] list2)
Builds a constraintchannelfrom the specified arguments. The valuejis assigned to the ith variable oflist1implies that the valueiis assigned to the jth variable oflist2.
The size of the arraylist1[i] = j => list2|j] = ilist1must be less than or equal to the size oflist2. When both arrays have the same size, we have:
Note that indexing starts at 0 (default value).list1[i] = j <=> list2|j] = i
As an illustration, enforcing a channeling constraint between x and y (indexing starting at 0, by default) is given by:channel(x, y);- Parameters:
list1- a first 1-dimensional array of integer variableslist2- a second 1-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list, int startIndex, IVar.Var value)
Builds a constraintchannelfrom the specified arguments: the valueiis assigned tovalueiff only the ith variable oflistis assigned the value 1 (0 is the value assigned to the other variables oflist). Note thatlistmust only contain variables with domain 0/1 and thatstartIndex.valueindicates the number used to access the first variable inlist. Important: for building an objectStartIndex, use MethodstartIndex(int)
As an illustration, enforcing a channeling constraint between x (indexing starting at 1) and v is given by:channel(x, startIndex(1), v);- Parameters:
list- a 1-dimensional array of integer variablesstartIndex- the number used to access the first variable inlist- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
channel
default CtrEntities.CtrEntity channel(IVar.Var[] list, IVar.Var value)
Builds a constraintchannelfrom the specified arguments: the valueiis assigned tovalueiff only the ith variable oflistis assigned the value 1 (0 is the value assigned to the other variables oflist). Note thatlistmust only contain variables with domain 0/1 and that indexing starts at 0 (default value).
As an illustration, enforcing a channeling constraint between x (indexing starting at 0, by default) and v is given by:channel(x, v);- Parameters:
list- a 1-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
stretch
default CtrEntities.CtrEntity stretch(IVar.Var[] list, int[] values, int[] widthsMin, int[] widthsMax, int[][] patterns)
-
stretch
default CtrEntities.CtrEntity stretch(IVar.Var[] list, int[] values, int[] widthsMin, int[] widthsMax)
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[] origins, int[] lengths, boolean zeroIgnored)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. WhenzeroIgnoredisfalse, it means that zero-length tasks cannot be packed anywhere (cannot overlap with other tasks).
As an illustration, enforcing that tasks defined by x (origins) and t (lengths) must not overlap is given by:noOverlap(x, t, true);- Parameters:
origins- a 1-dimensional array of integer variableslengths- a 1-dimensional array of integer integerszeroIgnored- indicates if tasks of length 0 can be ignored- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[] origins, int... lengths)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. Note that zero-length tasks are simply ignored (default value).
As an illustration, enforcing that tasks defined by x (origins) and t (lengths) must not overlap is given by:noOverlap(x, t);- Parameters:
origins- a 1-dimensional array of integer variableslengths- a 1-dimensional array of integer integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var x1, IVar.Var x2, int length1, int length2)
Builds a constraintnoOverlapfrom the specified arguments: we are given two tasks, defined by their origins and durations (lengths), which must not overlap.
As an illustration, enforcing that the task of origin x1 and length 5 must not overlap with the task of origin x2 and length 3 is given by:noOverlap(x1, x2, 5, 3);- Parameters:
x1- a first integer variable, denoting the origin of a first taskx2- a second integer variable, denoting the origin of a second tasklength1- the length associated with the first variablelength2- the length associated with the second variable- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[] origins, IVar.Var[] lengths, boolean zeroIgnored)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. WhenzeroIgnoredisfalse, it means that zero-length tasks cannot be packed anywhere (cannot overlap with other tasks).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y, true);- Parameters:
origins- a 1-dimensional array of integer variableslengths- a 1-dimensional array of integer variableszeroIgnored- indicates if tasks of length 0 can be ignored- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[] origins, IVar.Var... lengths)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. Note that zero-length tasks are simply ignored (default value).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y);- Parameters:
origins- a 1-dimensional array of integer variableslengths- a 1-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var x1, IVar.Var x2, IVar.Var length1, IVar.Var length2)
Builds a constraintnoOverlapfrom the specified arguments: we are given two tasks, defined by their origins and durations (lengths), which must not overlap. Note that zero-length tasks are simply ignored (default value).
As an illustration, enforcing that the task of origin x1 and length y1 must not overlap with the task of origin x2 and length y2 is given by:noOverlap(x1, x2, y1, y2);- Parameters:
x1- a first integer variable, denoting the origin of a first taskx2- a second integer variable, denoting the origin of a second tasklength1- the length associated withx1length2- the length associated withx2- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[][] origins, int[][] lengths, boolean zeroIgnored)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. The ith task is defined by its originorigins[i][j]wrt the jth axis and its lengthlengths[i][j]wrt the jth axis. WhenzeroIgnoredisfalse, it means that tasks with a length 0 on some axis cannot be packed anywhere (cannot overlap with other tasks).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y, true);- Parameters:
origins- a 2-dimensional array of integer variableslengths- a 2-dimensional array of integer integerszeroIgnored- indicates if tasks of length 0 (on any axis) can be ignored- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[][] origins, int[]... lengths)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. The ith task is defined by its originorigins[i][j]wrt the jth axis and its lengthlengths[i][j]wrt the jth axis. Note that tasks of length 0 on some axis are simply ignored (default value).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y);- Parameters:
origins- a 2-dimensional array of integer variableslengths- a 2-dimensional array of integer integers- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[][] origins, IVar.Var[][] lengths, boolean zeroIgnored)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. The ith task is defined by its originorigins[i][j]wrt the jth axis and its lengthlengths[i][j]wrt the jth axis. WhenzeroIgnoredisfalse, it means that tasks with a length 0 on some axis cannot be packed anywhere (cannot overlap with other tasks).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y, true);- Parameters:
origins- a 2-dimensional array of integer variableslengths- a 2-dimensional array of integer variableszeroIgnored- indicates if tasks of length 0 (on any axis) can be ignored- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
noOverlap
default CtrEntities.CtrEntity noOverlap(IVar.Var[][] origins, IVar.Var[]... lengths)
Builds a constraintnoOverlapfrom the specified arguments: we are given a set of tasks, defined by their origins and durations (lengths), which must not overlap. The ith task is defined by its originorigins[i][j]wrt the jth axis and its lengthlengths[i][j]wrt the jth axis. Note that tasks of length 0 on some axis are simply ignored (default value).
As an illustration, enforcing that tasks defined by x (origins) and y (lengths) must not overlap is given by:noOverlap(x, y);- Parameters:
origins- a 2-dimensional array of integer variableslengths- a 2-dimensional array of integer variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] ends, int[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskends- the end of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, int[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, int[] heights, long limit)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point does not exceed the specified limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each tasklimit- the limit that must not be exceeded- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] ends, int[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskends- the end of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, int[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, int[] heights, long limit)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point does not exceed the specified limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each tasklimit- the limit that must not be exceeded- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] ends, IVar.Var[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskends- the end of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, int[] lengths, IVar.Var[] heights, long limit)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point does not exceed the specified limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each tasklimit- the limit that must not be exceeded- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] ends, IVar.Var[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), ends and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskends- the end of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] heights, Condition condition)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point, respects a numerical condition. When the operator "le" is used, this corresponds to not exceeding a given limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each taskcondition- an objectconditioncomposed of an operator and an operand- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
cumulative
default CtrEntities.CtrEntity cumulative(IVar.Var[] origins, IVar.Var[] lengths, IVar.Var[] heights, long limit)
Builds a constraintcumulativefrom the specified arguments: we are given a set of tasks, defined by their origins, durations (lengths), and heights. The constraint enforces that at each point in time, the summed height of tasks that overlap that point does not exceed the specified limit.- Parameters:
origins- the origin (beginning) of each tasklengths- the duration (length) of each taskheights- the height of each tasklimit- the limit that must not be exceeded- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
circuit
default CtrEntities.CtrEntity circuit(IVar.Var[] list, int startIndex)
Builds a constraintcircuitfrom the specified arguments.- Parameters:
list- an array of variablesstartIndex- the index used to refer to the first variable of the array- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
circuit
default CtrEntities.CtrEntity circuit(IVar.Var[] list)
Builds a constraintcircuiton the specified array of variables. Note that 0 is the index used to refer to the first variable of the array.- Parameters:
list- an array of variables- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
circuit
default CtrEntities.CtrEntity circuit(IVar.Var[] list, int startIndex, int size)
Builds a constraintcircuitfrom the specified arguments.- Parameters:
list- an array of variablesstartIndex- the index used to refer to the first variable of the arraysize- the size of the circuit- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
circuit
default CtrEntities.CtrEntity circuit(IVar.Var[] list, int startIndex, IVar.Var size)
Builds a constraintcircuitfrom the specified arguments.- Parameters:
list- an array of variablesstartIndex- the index used to refer to the first variable of the arraysize- the size of the circuit- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
circuit
default CtrEntities.CtrEntity circuit(IVar.Var[] list, IVar.Var size)
Builds a constraintcircuitfrom the specified arguments. Note that 0 is the index used to refer to the first variable of the array- Parameters:
list- an array of variablessize- the size of the circuit- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
clause
default CtrEntities.CtrEntity clause(IVar.Var[] list, Boolean[] phases)
Builds a constraintclausefrom the specified arguments. For each variable and its corresponding phase (i.e., at the same index), a literal is present in the clause: a positive literal when the phase istrueand a negative literal when the phase isfalse.- Parameters:
list- an array of variablesphases- an array of boolean values- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
clause
default CtrEntities.CtrEntity clause(IVar.Var[] pos, IVar.Var[] neg)
Builds a constraintclausefrom the specified arguments. For each variable, a literal is present in the clause: a positive literal when the variable belongs to the first specified array and a negative literal when the variable belongs to the second specified array.- Parameters:
pos- a first array of variables involved in positive literalsneg- a second array of variables involved in negative literals- Returns:
- an object
CtrEntitythat wraps the built constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, int... values)
Builds a constraintinstantiation, assigning each specified variable with its corresponding value. For example:instantiation(x, t);- Parameters:
list- an array of variablesvalues- an array of integers- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, Range values)
Builds a constraintinstantiation, assigning each specified variable with its corresponding value (from the range). For example:instantiation(x, range(10));- Parameters:
list- an array of variablesvalues- a range of values- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, java.util.stream.IntStream values)
Builds a constraintinstantiation, assigning each specified variable with its corresponding value in the specified stream.- Parameters:
list- an array of variablesvalues- a stream of integers- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, Collection<Integer> values)
Builds a constraintinstantiation, assigning each specified variable with its corresponding value in the specified collection.- Parameters:
list- an array of variablesvalues- a collection of integers- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, int value)
Builds a constraintinstantiation, assigning each specified variable with the specified value. For example:instantiation(x, 0);- Parameters:
list- an array of variablesvalue- an integer- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(java.util.stream.Stream<IVar.Var> list, java.util.stream.IntStream values)
Builds a constraintinstantiation, assigning each specified variable with its corresponding value. For example:instantiation(x, t);- Parameters:
list- a stream of variablesvalues- a stream of integers- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[] list, int[] values, FunctionalInterfaces.Intx1Predicate p)
Builds a constraintinstantiation, assigning each specified variable at indexiwith its corresponding value at indexi, provided that the specified predicate acceptsi. For example:instantiation(x, t, i -> i % 2 == 0);- Parameters:
list- a 1-dimensional array of variablesvalues- a 1-dimensional array of integersp- a predicate allowing us to test if a variable (and its value) at indeximust be considered- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[][] list, int[][] values, FunctionalInterfaces.Intx2Predicate p)
Builds a constraintinstantiation, assigning each specified variable at index(i,j)with its corresponding value at index(i,j), provided that the specified predicate accepts(i,j). For example:instantiation(x, t, (i, j) -> i < j);- Parameters:
list- a 2-dimensional array of variablesvalues- a 2-dimensional array of integersp- a predicate allowing us to test if a variable (and its value) at index(i,j)must be considered- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
instantiation
default CtrEntities.CtrEntity instantiation(IVar.Var[][][] list, int[][][] values, FunctionalInterfaces.Intx3Predicate p)
Builds a constraintinstantiation, assigning each specified variable at index(i,j,k)with its corresponding value at index(i,j,k), provided that the specified predicate accepts(i,j,k). For example:instantiation(x, t, (i, j, k) -> i == j + k);- Parameters:
list- a 3-dimensional array of variablesvalues- a 3-dimensional array of integersp- a predicate allowing us to test if a variable (and its value) at index(i,j,k)must be considered- Returns:
- an object
CtrEntitythat wraps the build constraint and allows us to provide note and tags by method chaining
-
slide
default CtrEntities.CtrEntity slide(IVar[] list, Range range, java.util.function.IntFunction<CtrEntities.CtrEntity> template)
Builds a meta-constraintslidefrom the specified arguments. The specified template represents a sliding constraint over the specified variables. More precisely, for each value of the specified range, the specified template is called to generate a constraint using the specified variables. For example:slide(x, range(nCards - 1), i -> extension(vars(x[i], x[i + 1]), tuples));- Parameters:
list- a 1-dimensional array of variablesrange- a range of valuestemplate- a lambda used to generate a constraint for each value of the range- Returns:
- an object
CtrEntitythat wraps the build meta-constraint and allows us to provide note and tags by method chaining
-
ifThen
default CtrEntities.CtrEntity ifThen(CtrEntities.CtrEntity c1, CtrEntities.CtrEntity c2)
Builds a meta-constraintifThenfrom the two specified constraints. This is equivalent to:if c1 then c2- Parameters:
c1- a first constraint (used as condition of the alternative)c2- a second constraint (used as "then" part of the alternative)- Returns:
- an object
CtrEntitythat wraps the built meta-constraint and allows us to provide note and tags by method chaining
-
ifThenElse
default CtrEntities.CtrEntity ifThenElse(CtrEntities.CtrEntity c1, CtrEntities.CtrEntity c2, CtrEntities.CtrEntity c3)
Builds a meta-constraintifThenElsefrom the three specified constraints. This is equivalent to:if c1 then c2 else c3- Parameters:
c1- a first constraint (used as condition of the alternative)c2- a second constraint (used as "then" part of the alternative)c3- a third constraint (used as "else" part of the alternative)- Returns:
- an object
CtrEntitythat wraps the built meta-constraint and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(IVar x)
Builds an objective (function) to minimize: the value of the specified variable.- Parameters:
x- a variable- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(IVar x)
Builds an objective (function) to maximize: the value of the specified variable.- Parameters:
x- a variable- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(XNode<IVar> tree)
-
maximize
default ObjEntities.ObjEntity maximize(XNode<IVar> tree)
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar... list)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified array of variables. For example:minimize(SUM, x, y, z);- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][] list)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][][] list)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar... list)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified array of variables. For example:maximize(SUM, x, y, z);- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][] list)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][][] list)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables that will be flattened (i.e., converted into a 1-dimensional array of variables).- Parameters:
type- the type of the objectivelist- the involved variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[] list, int[] coeffs)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified array of variables, each of them being given a coefficient. For example:minimize(SUM, vars(x, y, z), vals(1, 2, 1));- Parameters:
type- the type of tProblemAPIhe objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][] list, int[][] coeffs)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays).- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][] list, int[][] coeffs, FunctionalInterfaces.Intx2Predicate p)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays). Only variables at index accepted by the specified predicate are considered. For example:minimize(SUM, x, t, (i, j) -> i < j);- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variablesp- a predicate allowing us to test if a variable (and its coefficient) at index(i,j)must be considered.- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays).- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs, FunctionalInterfaces.Intx3Predicate p)
Builds an objective (function) to minimize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays). Only variables at index accepted by the specified predicate are considered. For example:minimize(SUM, x, t, (i, j, k) -> i < j + k);- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variablesp- a predicate allowing us to test if a variable (and its coefficient) at index(i,j,k)must be considered- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[] list, int[] coeffs)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified array of variables, each of them being given a coefficient. For example:maximize(SUM, vars(x, y, z), vals(1, 2, 1));- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][] list, int[][] coeffs)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays).- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][] list, int[][] coeffs, FunctionalInterfaces.Intx2Predicate p)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 2-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays). Only variables at index accepted by the specified predicate are considered. For example:maximize(SUM, x, t, (i, j) -> i < j);- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variablesp- a predicate allowing us to test if a variable (and its coefficient) at index(i,j)must be considered.- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays).- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variables- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, IVar[][][] list, int[][][] coeffs, FunctionalInterfaces.Intx3Predicate p)
Builds an objective (function) to maximize: the objective is defined by the specified type on the specified 3-dimensional array of variables, each of them being given a coefficient. The arrays will be flattened (i.e., converted into 1-dimensional arrays). Only variables at index accepted by the specified predicate are considered. For example:maximize(SUM, x, t, (i, j, k) -> i < j + k);- Parameters:
type- the type of the objectivelist- the involved variablescoeffs- the coefficients associated with the variablesp- a predicate allowing us to test if a variable (and its coefficient) at index(i,j,k)must be considered.- Returns:
- an object
ObjEntitythat wraps the built objective and allows us to provide note and tags by method chaining
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, XNode<IVar>[] trees)
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees)
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, XNode<IVar>[] trees, int[] coeffs)
-
minimize
default ObjEntities.ObjEntity minimize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs)
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, XNode<IVar>[] trees)
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees)
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, XNode<IVar>[] trees, int[] coeffs)
-
maximize
default ObjEntities.ObjEntity maximize(Types.TypeObjective type, java.util.stream.Stream<XNode<IVar>> trees, int[] coeffs)
-
model
void model()
Builds the model. You have to declare variables, constraints and objectives in this method.
-
prettyDisplay
default void prettyDisplay(String[] values)
Called to display a solution given by the specified array. Advanced use: relevant if a solver is plugged. By default, it does nothing.- Parameters:
values- the values assigned to the variables
-
decisionVariables
default void decisionVariables(IVar[] list)
Sets the specified variables as those on which a solver should branch in priority. This generates an annotation.- Parameters:
list- a 1-dimensional array of variables
-
decisionVariables
default void decisionVariables(IVar[][] list)
Sets the specified variables as those on which a solver should branch in priority. This generates an annotation.- Parameters:
list- a 2-dimensional array of variables
-
-