280 likes | 474 Views
Constraint Satisfaction Problem (CSP) Applications and Job-Shop Scheduling. Factory Automation Lab. SNU. Nov. 18. 1999 Min, Dai ki. Contents. Introduction Constraint Satisfaction Problem Algorithms Applications Evaluation Job shop scheduling using CSP paper review
E N D
Constraint Satisfaction Problem (CSP) Applications and Job-Shop Scheduling Factory Automation Lab. SNU. Nov. 18. 1999 Min, Dai ki
Contents • Introduction • Constraint Satisfaction Problem • Algorithms • Applications • Evaluation • Job shop scheduling using CSP • paper review • Conclusions
Introduction • Many combinatorial problems in OR has an exponential time requirement. (NP-hard) • In CSPs, it may be sufficient to find a solution at a reasonable computational expense, that satisfies as many constraints as possible. • The representation as a CSP is often much closer to the original problem. • CHIP, ILOG Solver
CSP Problem definition • A CSP consists of • a set of variablesX={x1,…,xn}; • for each variable xi, a finite set Di of possible values (domain); • a set of constraints restricting the values that the variables can simultaneously take. • Constraint Cijk Di Dj Dk ... • A solution is an assignment of a value from its domain to every variables.
CSP consistency techniques • Constraint graph (binary constraints) • nodes (variables) and arcs (constraints) • deterministic and pre-processing stage • Node consistency • unary constraint on variable • Arc consistency • binary constraints correspond to arc • K-consistency (path consistency) • constraint propagation
CSP Search algorithm • Simple backtracking • the constraints b/w the current vars. and the past vars. • Forward checking (by Haralick and Elliott in 1980) • the constraints b/w the current vars. and the future vars. • Temporal assignment and removal • Maintaining Arc Consistency (by Freuder in 1994) • Look Ahead • the constraints b/w the future vars. • Note that it does more work
CSP Variable and value ordering • Variable ordering • Static ordering vs. Dynamic ordering • first-fail • Value ordering • impact on the time to find the first solution • success first • Variable and value ordering heuristics for the job shop scheduling constraint satisfaction problem ; Norman Sadeh
Location variables yi : whether facility is established or not at location i zj : location of the facility that supplies customer j vj : supply cost constraints vj = czj,j yi=0zj i fiyi+vj < C Car sequencing variables set of cars constraints ratio constraint grouping constraint calendar constraint just-in-time constraint In some cases, the traditional variable and value ordering may not necessarily be best Succeed-first or fail-first ; smith (1996) CSP Applications
Cutting stock variables cutting pattern constraints cost demand yield rate Integer linear programming and constraint programming approaches to a template design problem ; Proll(1998) Vehicle routing variables weather a vehicle travels directly from a customer to another constraints a vehicle travels from and travels to each customer all vehicles that leave the depot to return to the depot subtour elimination vehicle capacity There is a hybrid approach in which local search is combined CSP Applications
CSP Applications • Time tabling • Rostering • etc...
CSP Applications in Scheduling • Common obj. ; min. makespan • Modeling • variable : start time (operation) • domain : predecessors and successors of an operation • constraints : precedence, disjunctive, capacity… • Prev. researches • Thuriot et al.(1994) • Nuijten and Aarts(1996), edge finding Baptiste and Le Pape(1995), ILOG shcedule • alternative formulation : Cheng and Smith (1997)
CSP Evaluation • CSP and B&B • tree search techniques. • Constraint propagation vs. bounding scheme • cost and tightness of the lower bound • CSP and local search • if CSP is used in a pure form, it is unlikely to be competitive with the best local search method. • But the ideas from local search can be incorporated • randomization • restart procedures
A computational study of constraint satisfaction for multiple capacitated job shop scheduling W.P.M Nuijten a , E.H.L. Aarts b,c a ILOG S.A., France b Eindhoven Univ. of Tech., Dept. of Mathematics and Computing Science, Netherlands c Philips Research Lab., Netherlands E.J.O.R., Vol.90, 1996.
Contents • The multiple capacitated job shop scheduling • A constraint satisfaction approach • Consistency checking algorithm • Forward checking • Arc consistent • Sequencing checking • Checking remaining capacity • Computational results • Conclusion
Multiple capacitated job shop problem • General job shop scheduling problem • Variable : operation o • Domain : start time D(o) = [0, D-pt(o)] • Constraints : • precedence constraint : c{o,o’}(s) s(o) + pt(o) s(o’) • capacity constraint : c, machine m
Operation and start time selection randomization Dead end handling chronological backtracking complete restart of the search while not solved and not infeasible do check consistency if a dead end is detected then try to escape from dead end else select variable select value end_if end_while Constraint satisfaction approach
Consistency checking Forward Checking • capacity constraint • Theorem all start times in (a1 - pt(o),b1] … (ax - pt(o), bx] are inconsistent for o.
Consistency checking Arc consistency • capacity constraint • Theorem c{o,o’}(s) s(o) + pt(o) s(o’) s(o’)+pt(o’) s(o). Then current domain (o) is arc consistent with (o’) for c{o,o’}, if and only if (o)(lst(o’)-pt(o), ect(o’))=
Consistency checkingSequencing Checking • Three different bounds • lower bound on the earliest start time • upper bound on the latest completion time • Time complexity • LBest(o),UBlct(o) : O(||2) • LB2est(o),UB2lct(o) & LB3est(o),UB3lct(o) : O(||3) • Nuijten et al.[1993] • an operation must be scheduled before or after a specific subset of operations on the same machine for machines with capacity 1.
Consistency checkingSequencing Checking continue • LBest(o) ; earliest start time of operation o • UBlct(o) ; latest completion time of operation o b) a) b) a) A(S) = oSpt(o)·sz(o) rest(S,j)=A(S)-(C(S)-e(S)) (cp()-j)
Consistency checking Checking remaining capa. • the capacity o uses in time • Theorem V=[a1,b1]...[an,bn]N be such that then all start times in (a1-pt(o),b1] ...(an-pt(o),bn] are inconsistent for o.
The algorithm CheckConsistency Proc CheckConsistency Forward_Check; while domain have changed do 2-ConsCheck ; Sequencing_Check; RCP_Check; end_while end_Proc
Computational results Problem Sets • Job shop scheduling • 40 instances of the JSSP from Lawrence (1984) • 3 instances from Fisher and Thompson (1963) • Multiple capacitated job shop scheduling • 30 randomly generated instances with 5-10 machines and 100-200 operations
Computational results Multiple capacitated job shop scheduling
Conclusions • Present an algorithm based on constraint satisfaction techniques. • Performs well both on instances of the JSSP and the MCJSSP. • Shown the extensive consistency checking algorithm
References • A computational study of constraint satisfaction for multiple capacitated job shop scheduling, W.P.M. Nuijten, E.H.L. Aarts, EJOR Vol.90(1996). • Edge-finding constraint propagation algorithm for disjunctive and cumulative scheduling, Phillip Baptiste and Clause Le Pape, Proceeding of the 15th workshop of the U.K. Planning Special Interest Group, 1996 • Guide to Constraint Programming, Roman Bart, 1998 http://kti.msmff.cuni.cz/~bartak/constraints/intro.html • etc...