Presentation is loading. Please wait.

Presentation is loading. Please wait.

15 July 2005Edward Tsang (Copyright)1 Constraint Satisfaction and Optimization Professor Edward Tsang University of Essex URL:

Similar presentations


Presentation on theme: "15 July 2005Edward Tsang (Copyright)1 Constraint Satisfaction and Optimization Professor Edward Tsang University of Essex URL:"— Presentation transcript:

1 15 July 2005Edward Tsang (Copyright)1 Constraint Satisfaction and Optimization Professor Edward Tsang University of Essex URL: http://cswww.essex.ac.uk/CSP/

2 15 July 2005Edward Tsang (Copyright) 2 What is Constraint Satisfaction? Constraint satisfaction is a decision problem –You are given a number of decisions to make –For each decision, you are given a (finite) number of choices –Decisions constrain each other Your task is to make those decisions without violating any of the constraints Sometimes you want the “best” solution –If so, you have a (constrained) optimisation problem

3 15 July 2005Edward Tsang (Copyright) 3 Why constraint satisfaction? It is a very general problem (seen everywhere) –Mainly logistics, scheduling, resources allocation Specialized methods available Now multi-million Pounds/Dollars business Scientific challenges: –Combinatorial explosion (fundamental problem) –Modelling (engineering problem)

4 15 July 2005Edward Tsang (Copyright) 4 Sample Constraint Applications Resources Allocation –Staff rostering, timetabling –British Telecom’s work force schedulingBritish Telecom’s work force scheduling –British Airway’s flight schedulingBritish Airway’s flight scheduling Transportation –ILOG Dispatcher for vehicle routing –Train and bus scheduling –Collective transportationCollective transportation Logistics –Satellite scheduling –Radio links assignment (military & mobiles) –Telephone Network routing –Airport / container port Industrial Scheduling –Just-in-time scheduling –Hardware configuration –Car sequencingCar sequencing

5 15 July 2005Edward Tsang (Copyright) 5 Car Sequencing Problem Options ABS CD …   30203040 Total: 120 Production: ABS area:  3/5 CD area:  2/3

6 15 July 2005Edward Tsang (Copyright) 6 Airline Applications Constraint satisfaction and optimization are behind many applications in airline operations; e.g. British Airways uses ECLiPSe (IC-Parc) for scheduling aircraft to serve their flights and ILOG Solver for aircraft stand allocation at airports.

7 15 July 2005Edward Tsang (Copyright) 7 Transportation Constraint satisfaction is one of the core technologies in transportation optimization. For example Guided Local Search was used in ILOG Solver’s vehicle routing package, Dispatcher. Cairo/Line schedule for collective transportation.

8 15 July 2005Edward Tsang (Copyright) 8 BT’s Workforce Scheduling BT has many jobs to be done in UK every day. It has to schedule a large number of teams to serve these jobs, subject to time, skill and other constraints. Saving of 0.5% could mean Millions of Pounds per year. Guided Local Search achieved the best results in one of BT’s challenge problems. Technicians Jobs

9 15 July 2005Edward Tsang (Copyright) 9 CP in Steel Industry IBM helped Korea’s biggest steel manufacturer to apply constraint technology to schedule its production to meet orders. This include the allocation of existing stocks to orders, subject to various constraints, such as size, quality and colour, in order to minimize waste and cost. OrdersSteel Slabs

10 15 July 2005Edward Tsang (Copyright) 10 Constraint Programming Areas: modelling, algorithms, algorithm mapping, monitoring, packages Given: Problem Description Formulations (Modelling) AlgorithmsImplementations (e.g. ILOG Solver)

11 15 July 2005Edward Tsang (Copyright) 11 Constraint Techniques Overview Brute-force Search Problem Reduction Lookahead Search –Forward Checking, Arc-consistency Lookahead, …Forward CheckingArc-consistency Lookahead Failure handling at dead-ends –Intelligent Backtracking, Learning Nogoods, …Intelligent Backtracking Variables ordering heuristics Stochastic methods –Local Search, GSAT, Guided Local Search, …Local SearchGuided Local Search Constrained optimization

12 15 July 2005Edward Tsang (Copyright) 12 Maintaining Arc-Consistency Variables: x, y, z Domains: {1, 2, 3, 4} Constraints: x < y ; y < z x1234 y1234 z1234 x is not supported by y and is not supported by x X y is not supported by z and & is not supported by y X X XX Re-check x as now (with gone) it has no support from y X

13 15 July 2005Edward Tsang (Copyright) 13 1 2 3 4 5 6 7 8 ABCD EFG H Backtracking Search In The 8-Queens Problem Place one queen per row Place one queen at a time Examine each column Backtrack at dead-ends X Complete search, till solution found, or “no solution” is concluded Strategies at dead-ends: Learning “no goods” dependency directed backtracking

14 15 July 2005Edward Tsang (Copyright) 14 1 2 3 4 5 6 7 8 ABCD EFG H Forward Checking Search Problem reduction –a major technique Combined with search methods Reduce domain of future variables Detect dead-ends –To backtrack early X X X X X X X X X X X X X X X X X X X X X X X X X XX X X X X X X X X X X Dead-end detected after Queen 4 – no legal space for row 6, backtrack…

15 15 July 2005Edward Tsang (Copyright) 15 Arc-Consistency Lookahead 8-Queens Problem Three queens have been placed Maintaining AC 1 2 3 4 5 6 7 8 ABCD EFG H X XX XXXX XXXXX XXXX XXX X X XXXXX 1616 1616 2626 2626 2626 2626 3434 4545 5858 Result: dead-end found in row 7 Backtrack required – typically remove Queen 3

16 15 July 2005Edward Tsang (Copyright) 16 1 2 3 4 5 6 7 8 ABCD EFG H Back Jumping Jump to the latest culprit 1 3 243123 Recorded earliest conflict Identify the latest culprit, which is 4 Undo queens 5 and 4, continue

17 15 July 2005Edward Tsang (Copyright) 17 Combinatorial Explosion of the Car Sequencing Problem Schedule 30 cars: –Search space: 30 factorial  10 32 leaf nodes Generously allow: –Explore one in every 10 10 leaf nodes! –Examine 10 10 nodes per second! Problem takes over 32 thousand years to solve!!! –10 32 ÷ 10 10 ÷ 10 10 ÷ 60 ÷ 60 ÷ 24 ÷ 365  31,710 How to contain combinatorial explosion?

18 15 July 2005Edward Tsang (Copyright) 18 Local Search Ingredients: –Cost function –Neighbourhood function –[Optional] Strategy for visiting neighbours e.g. steepest ascent Problems: –local optimum –Plateau –When to stop? Ok with satisfiability But not optimization local max. global max. Cost function plateau neighbourhood better worse

19 15 July 2005Edward Tsang (Copyright) 19 The GLS Algorithm Iterative local search In a local minimum s* –Select FeaturesSelect Features Maximize utility –Increase penalties (strengthen constraints) Resume Local Search from s* I i (s*) = 1 if s* exhibits feature i; 0 otherwise p i = penalty of feature I (init. to 0) c i = cost of feature i GLS->TSPFunction

20 15 July 2005Edward Tsang (Copyright) 20 GLS: Augmented Cost Function Identifying solution features, e.g. Edges used associate costs and penalties to features Given cost function g to minimize Augmented Cost Function h(s) = g (s) +  ×  p i × I i (s)) is parameter to GLS I i (s) = 1 if s exhibits feature i; 0 otherwise p i is penalty for feature i, initialized to 0

21 15 July 2005Edward Tsang (Copyright) 21 GLS on TSP Local search: 2-opting  = a  g ( t* ) / n Features:  n 2 Features  cost = distance given  e.g. tour [1,5,3,4,6,2] t* = first local minimum produced by local search; g(t*) = cost of t* n = # of cities a = parameter to tune, within (0, 1]

22 15 July 2005Edward Tsang (Copyright) 22 Summary, Constraint Programming Focus on (finite choices) decision problem Constraint satisfaction is a general problem –Many applications Efficient algorithms developed –To exploit the specific features of the problems CP is a successful multi-£/$M business –ILOG Solver, ECLiPSe, Actenum CP is a technique that can’t be ignored


Download ppt "15 July 2005Edward Tsang (Copyright)1 Constraint Satisfaction and Optimization Professor Edward Tsang University of Essex URL:"

Similar presentations


Ads by Google