Package org.jacop.constraints.cumulative
Class CumulativeBasic
java.lang.Object
org.jacop.constraints.DecomposedConstraint<Constraint>
org.jacop.constraints.Constraint
org.jacop.constraints.cumulative.CumulativeBasic
- Direct Known Subclasses:
Cumulative
CumulativeBasic implements the cumulative constraint using time tabling
algorithm.
- Version:
- 4.8
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescription(package private) CumulativePrimary
private static final boolean
private static final boolean
private Comparator<CumulativeBasic.Event>
private static final AtomicInteger
final IntVar
It specifies the limit of the profile of cumulative use of resources.(package private) boolean
It specifies whether there possibly exist tasks that have duration or resource variable min value equal zero.private static final int
private static final int
private static final int
(package private) final TaskView[]
All tasks of the constraintFields inherited from class org.jacop.constraints.Constraint
atomicExecution, consistencyPruningEvents, constraintScope, earlyTerminationOK, increaseWeight, numberId, scope, trace
Fields inherited from class org.jacop.constraints.DecomposedConstraint
queueIndex
-
Constructor Summary
ConstructorsConstructorDescriptionCumulativeBasic
(List<? extends IntVar> starts, List<? extends IntVar> durations, List<? extends IntVar> resources, IntVar limit) It creates a cumulative constraint.CumulativeBasic
(IntVar[] starts, IntVar[] durations, IntVar[] resources, IntVar limit) It creates a cumulative constraint. -
Method Summary
Modifier and TypeMethodDescriptionvoid
consistency
(Store store) It is a (most probably incomplete) consistency function which removes the values from variables domains.int
(package private) void
profileProp
(Store store) private void
sweepPruning
(Store store) toString()
It produces a string representation of a constraint state.private void
updateTasksRes
(Store store) Methods inherited from class org.jacop.constraints.Constraint
afc, arguments, cleanAfterFailure, decompose, getConsistencyPruningEvent, getGuideConstraint, getGuideValue, getGuideVariable, grounded, grounded, id, impose, impose, imposeDecomposition, increaseWeight, intArrayToString, numberArgs, queueVariable, removeConstraint, requiresMonotonicity, setConsistencyPruningEvent, setConstraintScope, setScope, setScope, setScope, setScope, setScope, setWatchedVariableGrounded, supplyGuideFeedback, updateAFC, watchedVariableGrounded
Methods inherited from class org.jacop.constraints.DecomposedConstraint
auxiliaryVariables, checkInput, checkInput, checkInputForDuplication, checkInputForDuplicationSkipSingletons, checkInputForNullness, checkInputForNullness, checkInputForNullness, derivative, getDubletonsSkipSingletons, imposeDecomposition
-
Field Details
-
idNumber
-
debug
private static final boolean debug- See Also:
-
debugNarr
private static final boolean debugNarr- See Also:
-
eventComparator
-
taskNormal
All tasks of the constraint -
limit
It specifies the limit of the profile of cumulative use of resources. -
possibleZeroTasks
boolean possibleZeroTasksIt specifies whether there possibly exist tasks that have duration or resource variable min value equal zero. -
cumulativeForConstants
CumulativePrimary cumulativeForConstants -
profile
private static final int profile- See Also:
-
pruneStart
private static final int pruneStart- See Also:
-
pruneEnd
private static final int pruneEnd- See Also:
-
-
Constructor Details
-
CumulativeBasic
It creates a cumulative constraint.- Parameters:
starts
- variables denoting starts of the tasks.durations
- variables denoting durations of the tasks.resources
- variables denoting resource usage of the tasks.limit
- the overall limit of resources which has to be used.
-
CumulativeBasic
public CumulativeBasic(List<? extends IntVar> starts, List<? extends IntVar> durations, List<? extends IntVar> resources, IntVar limit) It creates a cumulative constraint.- Parameters:
starts
- variables denoting starts of the tasks.durations
- variables denoting durations of the tasks.resources
- variables denoting resource usage of the tasks.limit
- the overall limit of resources which has to be used.
-
-
Method Details
-
consistency
Description copied from class:Constraint
It is a (most probably incomplete) consistency function which removes the values from variables domains. Only values which do not have any support in a solution space are removed.- Specified by:
consistency
in classConstraint
- Parameters:
store
- constraint store within which the constraint consistency is being checked.
-
profileProp
-
getDefaultConsistencyPruningEvent
public int getDefaultConsistencyPruningEvent()- Specified by:
getDefaultConsistencyPruningEvent
in classConstraint
-
updateTasksRes
-
toString
Description copied from class:Constraint
It produces a string representation of a constraint state.- Overrides:
toString
in classConstraint
-
sweepPruning
-