Optional Intervals and Presence Literals
An optional interval is an interval variable equipped with a Boolean presence literal indicating whether the interval is scheduled. Constraints involving an optional interval apply only when the interval is present; absent intervals are ignored. This lesson covers the defining presence relation, counting and total-duration sums built from presence literals, and how NoOverlap and makespan behave with optional intervals.
Tutorial
Optional Intervals and Presence Literals
An optional interval is an interval variable that may or may not be scheduled. Each optional interval carries a Boolean presence literal :
- If , the interval is present, and its variables must satisfy the usual size relation .
- If , the interval is absent, and is ignored by every constraint involving it.
We denote an optional interval by the tuple , where is the start, is the size, is the end, and is the presence literal.
The defining rule of an optional interval is
When , the start, size, and end variables may still take any values in their domains, but those values have no effect on the rest of the model.
For example, suppose , , , . Then:
- is valid: and .
- is invalid: but .
- is valid: , so the relation need not hold.