340 likes | 483 Views
Resource Constraint Propagation (Non-Preemptive Case). Outline. Classes of resources Constraint propagation models Explicit time-tables Disjunctive constraints Energetic reasoning Edge finding (task intervals) Comparison. Classes of resources. Unary resources Discrete resources
E N D
Outline • Classes of resources • Constraint propagation models • Explicit time-tables • Disjunctive constraints • Energetic reasoning • Edge finding (task intervals) • Comparison
Classes of resources • Unary resources • Discrete resources • State resources • Energetic resources
A B time C Unary resources • Main resources in 4/10 problems • Example: one individual machine or person
B A C time D Discrete resources • Main resources in 5/10 problems • Example: group of identical machines
B A C time D State resources • Main resources in 1/20 problems • Example: oven with different temperatures
C Energetic resources • Main resources in 1/20 problems • Example: number of man-days per week A B time
Constraint propagation models • Explicit time-tables • Disjunctive constraints • Energetic reasoning • Edge finding (task intervals)
Explicit time-tables (UD) • WA(t) = [start(A) £ t < end(A)] • "t, SA [WA(t) * capacity(A)] £ capacity(t) A C B time C
B Explicit time-tables (S) • WA(t) = [start(A) £ t < end(A)] • "t, WA(t) implies [state(A) = state(t)] D A C time D
Explicit time-tables (E) • aA(I) = max(0, endmin(A) - start(I)) • bA(I) = max(0, end(I) - startmax(A)) • d(I) = end(I) - start(I) • d(A) = durationmin(A) • WA(I) = min(aA(I), bA(I), d(I), d(A)) • SA [WA(I) * capacity(A)] £ capacity(I)
Explicit time-tables (E) A B time C
Explicit time-tables: 2 models • Discrete array • Sequential table or binary tree B D A C time
Explicit time-tables: extensions • Minimal capacity constraints (UDE) • Default state (S) • Constraints between time-tables or between time-tables and other variables (UDES)
Disjunctive constraints (U) • [end(A) £ start(B)] • OR [end(B) £ start(A)] • [endmin(A) > startmax(B)] • implies [end(B) £ start(A)] • [endmin(B) > startmax(A)] • implies [end(A) £ start(B)]
Disjunctive constraints (U) • Optional activities • Resource alternatives • Sub-contracts • Transition times • Tool setups • Color changes • Cleaning
Disjunctive constraints (U) • [end(A) + ttime(A, B) £ start(B)] • OR [end(B) + ttime(B, A) £ start(A)] • OR [duration(A) = 0] • OR [duration(B) = 0] • OR [capacity(A) = 0] • OR [capacity(B) = 0]
Disjunctive constraints (D) Redundant (but insufficient!) constraint [end(A) £ start(B)] • OR [end(B) £ start(A)] • OR [duration(A) = 0] • OR [duration(B) = 0] • OR [capacity(A) + capacity(B) £ capacity]
Disjunctive constraints (S) • [end(A) + ttime(A, B) £ start(B)] • OR [end(B) + ttime(B, A) £ start(A)] • OR [duration(A) = 0] • OR [duration(B) = 0] • OR [state(A) = state(B)]
Energetic reasoning (UD) • aA(I) = max(0, endmin(A) - start(I)) • bA(I) = max(0, end(I) - startmax(A)) • d(I) = end(I) - start(I) • d(A) = durationmin(A) • WA(I) = min(aA(I), bA(I), d(I), d(A)) • SA [WA(I) * capacity(A)] £ capacity(I)
Energetic reasoning (UD) • Habographs [Beck 92] • Intervals: [id .. jd) or [b + id .. b + jd) • Energetic resources [Le Pape 94] • Intervals: [id .. (i+1)d) or [b + id .. b + (i+1)d) • Energetic reasoning rules [Lopez 91] • Intervals: [startmin(A) .. endmax(B)) or [startmin(A) .. x)
Energetic reasoning (U) • I = [startmin(A) .. endmax(B)) • d(I) <SC<>A,BWC(I) +d(A) +d(B) • implies [end(B) £ start(A)] A[1..8 - 2 - 3..10] B[0..3 - 2 - 2..5] C[2..4 - 1 - 3..5] I = [1 .. 5) [4 < 1 + 2 + 2] implies [2 £ start(A)]
Energetic reasoning (U) • start(I) = startmin(A) • d(I) <SC<>AWC(I) + min(d(A), d(I)) • implies [start(I) +SC<>AWC(I) £ start(A)] A[0..11 - 6 - 6..17] B[1..7 - 4 - 5..11] C[1..8 - 3 - 4..11] I = [0 .. 11) [11 < 4 + 3 + 6] implies [7 £ start(A)]
Edge finding (U) • Basic idea Prove that an activity A executes before (or after) a set of other activities W • Notations smin(W) = minBÎW startmin(B) emax(W) = maxBÎW endmax(B) dmin(W) =SBÎW durationmin(B)
Edge finding (U) • emax(W) < smin(W + {A}) + dmin(W + {A}) • implies [smin(W') + dmin(W') £ start(A)] • for every W' included in W A[0..11 - 6 - 6..17] B[1..7 - 4 - 5..11] C[1..8 - 3 - 4..11] W= {B C} [11 < 0 + 13] implies [1 + 7 £ start(A)]
Edge finding (U) • Jackson's Preemptive Schedule [Pinson 88] [Carlier & Pinson 90/94] • O(n2) O(n*log(n)) • Iterative algorithm [Nuijten 93/94] • O(n2) with no specific data structure • Task intervals [Caseau & Laburthe 94] • O(n3) • Incremental • More deductions è more precise time-bounds
Edge finding (U) • "Not-first" deduction rule emax(W) < smin(A) + dmin(W + {A}) • implies [minBÎW(smin(B) + dmin(B)) £ start(A)] • [Nuijten 94] [Caseau & Laburthe 94] • [Baptiste & Le Pape 96]: Complete application in O(n2) time and O(n) space
Edge finding (U) • "Not-first" deduction rule with knapsack D= smin(A) + dmin(W + {A}) - emax(W) > 0 • implies [minW' | f(W')(smin(W') + dmin(W')) £ start(A)] • with f(W') defined as [W=W' OR D£ dmin(W')] • Complete application in exponential time (includes the NP-complete knapsack problem) • Partial application [Caseau & Laburthe 95]
Comparison • Theoretical results • Unique fixpoint semantics • Modelling power • Time and space complexity • Pruning power • Experimental results
Unique fixpoint semantics Time-tables YES arc-consistency (bounds) Disjunctive constraints YES arc-consistency (bounds) Habographs YES arc-consistency (bounds) Energetic resources YES arc-consistency (bounds) Energetic rules NO [Baptiste 95] Edge finding [CP90/94] YES proof in [Pinson 88] Edge finding [N93] YES proof in [Nuijten 94] Task intervals [CL94] NO [Baptiste & Le Pape 95]
Habographs Disjunctive constraints Energetic resources Task intervals Explicit time-tables Energetic rules Edge finding Modelling power (as of today)
Time and space complexity Time-tables O(n*h) O(n2) Incr. O(h) O(n) Disjunctive constraints O(n2) Incr. O(n) Habographs O(n*(h/d)2) Incr. O((h/d)2) Energetic resources O(n*h/d) O(n2) Incr. O(h/d) O(n) Energetic rules O(n3) O(n) Edge finding [CP90/94] O(n2) O(n*log(n)) O(n) Edge finding [N93] O(n2) O(n) Task intervals [CL94] O(n3) Incr. O(n2)
Edge finding + not-first/not-last Habographs Edge finding + disjunctive Energetic rules Energetic resources Edge finding (basic) Disjunctive constraints Explicit time-tables Pruning power (U)
Experiments (10/80) MT06 CAR1 CAR2 CAR3 CAR4 CAR5 CAR6 CAR7 CAR8 MT10 Edge finding [Nuijten et al 93] Number of fails CPU time Energetic reasoning [Erschler et al 91] Number of fails CPU time 215 210 25