90 likes | 200 Views
Temporal Constraint Propagation (Preemptive Case). Outline. New variables Definition Implementation Relations between the variables Temporal constraints. New variables (definition). set(A) = {t such that A executes at time t} W A (t) = 1 when t Î set(A), 0 otherwise
E N D
Outline • New variables • Definition • Implementation • Relations between the variables • Temporal constraints
New variables (definition) • set(A) = {t such that A executes at time t} • WA(t) = 1 when tÎset(A), 0 otherwise • start(A) = mintÎset(A)(t) • end(A) = maxtÎset(A)(t + 1) • duration(A) = |set(A)| • span(A) = end(A) - start(A)
New variables (implementation) • Three possible implementations for set(A) • Explicit set variable set(A) • Explicit Boolean variables WA(t) • Dynamic list of intervals Ii(A) = [si(A), ei(A)) with • W(Ii(A)) = 1 if "tÎ[si(A), ei(A)), tÎset(A) • W(Ii(A)) = 0 if "tÎ[si(A), ei(A)), tÏset(A) • W(Ii(A)) = unknown otherwise • Explicit or implicit integer variables for start(A), end(A), duration(A), and span(A)
Relations between the variables • end(A) = start(A) + span(A) • duration(A) £ span(A) • duration(A) = |set(A)| cardinality constraint specific implementation for a list of intervals
Relations between the variables • start(A) = mintÎset(A)(t) start(A)Îset(A) [t = startmin(A) = startmax(A)] implies [tÎset(A)] [t = startmin(A)Ïset(A)] implies [t < start(A)] [t = startmax(A)Ïset(A)] implies [start(A) < t] "tÎset(A), start(A) £ t [tÎset(A)] implies [start(A) £ t] [t < startmin(A)] implies [tÏset(A)]
Relations between the variables • end(A) = maxtÎset(A)(t + 1) (end(A) - 1)Îset(A) [t = endmin(A) = endmax(A)] implies [(t - 1)Îset(A)] [t = (endmin(A) - 1)Ïset(A)] implies [(t + 1) < end(A)] [t = (endmax(A) - 1)Ïset(A)] implies [end(A) < (t + 1)] "tÎset(A), t < end(A) [tÎset(A)] implies [t < end(A)] [endmax(A) £ t] implies [tÏset(A)]
Relation between the variables • pos(A) = {t such that WA(t) can be 1} • |{t'Îpos(A) such that t' < t}| < durationmin(A) implies [t < end(A)] • |{t'Îpos(A) such that t £ t'}| < durationmin(A) implies [start(A) < t]
Temporal constraints • Constraints between start and end variables Similar to the non-preemptive case when start(A) and end(A) are explicit • Other constraints "tÎset(A), tÎset(B) (inclusion) "tÎset(A), tÏset(B) (exclusion) "tÏset(A), tÎset(B) (coverage)