Complex Scheduling III: Interval Consistency Tests for the RCPSPTextbook
Motivation
Exact methods for the resource-constrained project scheduling problem — branch-and-bound over activity lists or over start-time assignments, and the lower-bound computations inside them — live or die by how much of the search space can be discarded before it is enumerated. The standard tool is constraint propagation: deducing, from the precedence, resource and time-window data, new precedence relations that every feasible schedule must satisfy, and tighter time windows for the activities. Brucker and Knust's Section 3.6 (doi:10.1007/978-3-642-23929-8) presents the family of interval consistency tests — input, output, input-or-output and their negations — that constraint-programming schedulers apply at every node of the search, following Carlier and Pinson (An algorithm for solving the job-shop problem, Management Science 35, 1989, doi:10.1287/mnsc.35.2.164) and Baptiste, Le Pape and Nuijten (Constraint-Based Scheduling, Kluwer, 2001, doi:10.1007/978-1-4615-1479-4). Every test is an instance of one theorem, Theorem 3.7, and its cumulative-resource analogue, Theorem 3.8. Those two theorems, and the tests as their corollaries, are this mission.
Setting
The instance is the RCPSP of mission I: activities with integer processing times , renewable resources with capacities and demands , and precedence arcs; a schedule is an integer start-time vector , feasible when it meets the precedences and never exceeds a capacity. Section 3.6 adds three things.
Relations. A conjunction holds in when . Two activities are parallel, , when they overlap for at least one time unit, and a disjunction is the negation of that: or . The instance carries a set of conjunctions and a set of disjunctions that every feasible schedule must satisfy; initially is the precedence relation and the pairs whose combined demand exceeds some capacity, and propagation adds to them.
Disjunctive sets. A set of at least two activities is disjunctive when any two of its members are related by a disjunction or a conjunction, so no two are ever processed together: the activities of a unit-capacity resource, the jobs of a single machine, the operations of one job in a shop. Its total processing time is .
Time windows. Each activity has a head and a deadline , and a feasible schedule has and . An activity starts first in a set when no activity of starts earlier, and ends last when none completes later.
For a cumulative resource the work of activity is and .
Formalization targets
Goal — Theorem 3.7 (printed p. 169)
Let be a disjunctive set, , and proper subsets of with . If
then in every feasible schedule an activity from starts first in or an activity from ends last in .
The first infeasibility test (printed p. 169)
If some nonempty has , no feasible schedule exists.
The input test (3.123) and the output test (3.124) (printed p. 171)
For nonempty and : if then for all ; symmetrically, if then for all .
The input-or-output test (printed p. 170)
For , : if then starts first in or ends last in , and when .
Theorem 3.8 (printed p. 186)
For a cumulative resource , and proper subsets of : if then an activity from starts first in or an activity from ends last in .
Significance
Theorem 3.7 is the single statement behind a whole toolbox. Every interval consistency test in the literature — the input and output tests that fix a new conjunction, the input-or-output test, the negation tests that only shrink a window — is the theorem with a particular choice of and , and the book's Section 3.6.4 derives them one by one. A propagation engine that applies these tests to a fixpoint is what makes branch-and-bound for the job shop and the RCPSP practical; Carlier and Pinson's solution of the 10×10 job-shop instance is the historical demonstration. Theorem 3.8 extends the same reasoning from disjunctive to cumulative resources by replacing "no overlap" with "at most units per time unit", the energetic-reasoning viewpoint that the rest of Section 3.6.5 develops.
The results are elementary and proved; formalizing them fixes, once, what "feasible" means in the presence of the relation sets and and time windows, on top of the RCPSP model of mission I. That layer is reusable: the start-start distance matrix of Section 3.6.2 and the symmetric-triple rules of Section 3.6.3 are statements about the same schedules and the same relations. Nothing here is on the platform or in Mathlib.
Difficulty
The obvious argument for Theorem 3.7 is the correct one, and its difficulty is in the bookkeeping. If no activity of starts first and none of ends last, the first starter is some and the last finisher some , and every activity of is processed inside . Since the activities of a disjunctive set are pairwise non-overlapping, their total length fits in that interval, contradicting (3.121). The formal work is the packing lemma: pairwise disjoint integer intervals inside an interval of length have total length at most , which requires ordering the activities by start time and an induction that Mathlib does not supply.
The subtle point is the restriction in (3.121). The book allows it because "an activity which starts first cannot complete also last" when there are at least two activities with positive durations. The formal statement reads "starts first" and "ends last" with , which makes the theorem true without a positivity hypothesis: when the restriction empties the index set, , the conclusion holds because cannot be both the unique first starter and the unique last finisher of a disjunctive set with two or more members. A solver should expect to handle that corner separately.
For the tests the extra step is turning "starts first" into a conjunction , which uses the disjunction between and together with positive processing times: with an activity could start at the same instant as without violating the disjunction, so the tests carry the positivity hypothesis that Theorem 3.7 itself does not need. Theorem 3.8 replaces the packing lemma by a work-counting lemma: over an interval of length a resource of capacity supplies at most units, and every activity of consumes of them.
Formalization scope
Schedules are integer start-time vectors on Fin n, as in missions I and II, and a feasible
schedule of this mission is one that is FeasibleSchedule for the RCPSP instance (mission I),
respects the arcs of (RespectsArcs, mission II), satisfies the disjunctions of and lies
within the time windows; these four hypotheses are the book's "feasible schedule" in Section 3.6
and are carried on every statement, although the arguments use only the last two, or, for
Theorem 3.8, the resource constraint and the windows. The sets and are parameters, not
derived from the instance, since propagation enlarges them.
Every inequality "" is stated as the family of inequalities over the same index pairs. This is equivalent, avoids natural-number subtraction, and gives an empty index set the value the convention would: the hypothesis is then vacuous. "Starts first" and "ends last" use . Proper-subset hypotheses , are the book's; the first infeasibility test needs nonempty, and the input-or-output test needs .
A trivializing reading is ruled out on the disjunctive side by the nonemptiness hypotheses (an empty would make the infeasibility test's family vacuous and its conclusion false) and on the cumulative side by the observation that Theorem 3.8 with asserts infeasibility, which is the book's intended reading. Welcome contributions beyond the milestones: the input-negation and output-negation tests, the window-tightening rules of Section 3.6.4, and the SSD-matrix results of Section 3.6.2.
Selected references
- Peter Brucker and Sigrid Knust, Complex Scheduling, 2nd ed., Springer, 2012, Section 3.6. doi:10.1007/978-3-642-23929-8
- Jacques Carlier and Eric Pinson, An algorithm for solving the job-shop problem, Management Science 35 (1989). doi:10.1287/mnsc.35.2.164
- Philippe Baptiste, Claude Le Pape and Wim Nuijten, Constraint-Based Scheduling, Kluwer, 2001. doi:10.1007/978-1-4615-1479-4
- Ulrich Dorndorf, Erwin Pesch and Toàn Phan-Huy, Constraint propagation techniques for the disjunctive scheduling problem, Artificial Intelligence 122 (2000). doi:10.1016/S0004-3702(00)00040-0