1 IOE/MFG 543 Chapter 14: General purpose procedures for scheduling in practice Section 14.4: Local search (Simulated annealing and tabu search)

Slides:



Advertisements
Similar presentations
Decision Support Andry Pinto Hugo Alves Inês Domingues Luís Rocha Susana Cruz.
Advertisements

1 Tabu Search Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations.
© J. Christopher Beck Lecture 17: Tabu Search.
Simulated Annealing Premchand Akella. Agenda Motivation The algorithm Its applications Examples Conclusion.
Genetic Algorithms Contents 1. Basic Concepts 2. Algorithm
CHAPTER 8 A NNEALING- T YPE A LGORITHMS Organization of chapter in ISSO –Introduction to simulated annealing –Simulated annealing algorithm Basic algorithm.
CHAPTER 2 D IRECT M ETHODS FOR S TOCHASTIC S EARCH Organization of chapter in ISSO –Introductory material –Random search methods Attributes of random search.
Spie98-1 Evolutionary Algorithms, Simulated Annealing, and Tabu Search: A Comparative Study H. Youssef, S. M. Sait, H. Adiche
Tabu Search for Model Selection in Multiple Regression Zvi Drezner California State University Fullerton.
1 IOE/MFG 543 Chapter 14: General purpose procedures for scheduling in practice Section 14.5: Local search – Genetic Algorithms.
MAE 552 – Heuristic Optimization Lecture 24 March 20, 2002 Topic: Tabu Search.
1 Tardiness Models Contents 1. Moor’s algorithm which gives an optimal schedule with the minimum number of tardy jobs 1 ||  U j 2. An algorithm which.
Optimization via Search CPSC 315 – Programming Studio Spring 2009 Project 2, Lecture 4 Adapted from slides of Yoonsuck Choe.
MAE 552 – Heuristic Optimization Lecture 6 February 6, 2002.
1 Approximate Solution to an Exam Timetabling Problem Adam White Dept of Computing Science University of Alberta Adam White Dept of Computing Science University.
21st European Conference on Operational Research Algorithms for flexible flow shop problems with unrelated parallel machines, setup times and dual criteria.
1 IOE/MFG 543 Chapter 14: General purpose procedures for scheduling in practice Sections : Dispatching rules and filtered beam search.
A TABU SEARCH APPROACH TO POLYGONAL APPROXIMATION OF DIGITAL CURVES.
Simulated Annealing Van Laarhoven, Aarts Version 1, October 2000.
Material Management 2010 Mid-Term Exam-#2 Solution By: Prof. Y. Peter Chiu 5 / 2010.
1 IOE/MFG 543 Chapter 7: Job shops Sections 7.1 and 7.2 (skip section 7.3)
Introduction to Simulated Annealing 22c:145 Simulated Annealing  Motivated by the physical annealing process  Material is heated and slowly cooled.
Optimization via Search CPSC 315 – Programming Studio Spring 2008 Project 2, Lecture 4 Adapted from slides of Yoonsuck Choe.
Metaheuristics The idea: search the solution space directly. No math models, only a set of algorithmic steps, iterative method. Find a feasible solution.
Elements of the Heuristic Approach
Optimization of thermal processes2007/2008 Optimization of thermal processes Maciej Marek Czestochowa University of Technology Institute of Thermal Machinery.
Escaping local optimas Accept nonimproving neighbors – Tabu search and simulated annealing Iterating with different initial solutions – Multistart local.
Towers of Hanoi. Introduction This problem is discussed in many maths texts, And in computer science an AI as an illustration of recursion and problem.
Markov Decision Processes1 Definitions; Stationary policies; Value improvement algorithm, Policy improvement algorithm, and linear programming for discounted.
Heuristic Optimization Methods
Boltzmann Machine (BM) (§6.4) Hopfield model + hidden nodes + simulated annealing BM Architecture –a set of visible nodes: nodes can be accessed from outside.
Dr.Abeer Mahmoud ARTIFICIAL INTELLIGENCE (CS 461D) Dr. Abeer Mahmoud Computer science Department Princess Nora University Faculty of Computer & Information.
1 Simulated Annealing Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations.
Simulated Annealing.
David Luebke 1 10/25/2015 CS 332: Algorithms Skip Lists Hash Tables.
1 Short Term Scheduling. 2  Planning horizon is short  Multiple unique jobs (tasks) with varying processing times and due dates  Multiple unique jobs.
Thursday, May 9 Heuristic Search: methods for solving difficult optimization problems Handouts: Lecture Notes See the introduction to the paper.
A Simple Example The Traveling Salesman Problem: Find a tour of a given set of cities so that each city is visited only once the total distance traveled.
Single-solution based metaheuristics. Outline Local Search Simulated annealing Tabu search …
Vaida Bartkutė, Leonidas Sakalauskas
Simulated Annealing. Difficulty in Searching Global Optima starting point descend direction local minima global minima barrier to local search.
Probabilistic Algorithms Evolutionary Algorithms Simulated Annealing.
A local search algorithm with repair procedure for the Roadef 2010 challenge Lauri Ahlroth, André Schumacher, Henri Tokola
Outline Problem Definition Related Works & Complexity MILP Formulation Solution Algorithms Computational Experiments Conclusions & Future Research 1/26.
Heuristic Methods for the Single- Machine Problem Chapter 4 Elements of Sequencing and Scheduling by Kenneth R. Baker Byung-Hyun Ha R2.
1 Chapter 5-1 Greedy Algorithms Slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved.
Earliness and Tardiness Penalties Chapter 5 Elements of Sequencing and Scheduling by Kenneth R. Baker Byung-Hyun Ha R1.
Local Search Algorithms and Optimization Problems
1 Simulated Annealing Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations.
1 Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations Genetic Algorithm (GA)
Intro. ANN & Fuzzy Systems Lecture 37 Genetic and Random Search Algorithms (2)
Escaping Local Optima. Where are we? Optimization methods Complete solutions Partial solutions Exhaustive search Hill climbing Exhaustive search Hill.
CS621: Artificial Intelligence
1 Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations Simulated Annealing (SA)
1 Genetic Algorithms Contents 1. Basic Concepts 2. Algorithm 3. Practical considerations.
General Purpose Procedures Applied to Scheduling
Scientific Research Group in Egypt (SRGE)
Heuristic Optimization Methods
Tabu Search Review: Branch and bound has a “rigid” memory structure (i.e. all branches are completed or fathomed). Simulated Annealing has no memory structure.
Local Search Local search algorithms try to improve a given solution by modifying it   Constructive Algorithms Improvement Algorithms Need to specify:
Artificial Intelligence (CS 370D)
Subject Name: Operation Research Subject Code: 10CS661 Prepared By:Mrs
General Purpose Procedures Applied to Scheduling
Study Guide for ES205 Yu-Chi Ho Jonathan T. Lee Nov. 7, 2000
School of Computer Science & Engineering
Introduction to Simulated Annealing
Lecture 9: Tabu Search © J. Christopher Beck 2005.
EMIS 8373: Integer Programming
Schedulıng algorıthms
Stochastic Methods.
Presentation transcript:

1 IOE/MFG 543 Chapter 14: General purpose procedures for scheduling in practice Section 14.4: Local search (Simulated annealing and tabu search)

2 Introduction Constructive vs. improvement type algorithms Constructive vs. improvement type algorithms Constructive type Constructive type –Construct the schedule by, e.g., adding one job at the time Improvement type Improvement type –Start with some complete schedule –Try to obtain a better schedule by manipulating the current schedule

3 General local search algorithm G(S) is the value of the objective under schedule S G(S) is the value of the objective under schedule S 1.Let k=1. Start with a schedule S 1 and let the best schedule S 0 =S 1 2.Choose a schedule S c from the neighborhood of S k N(S k ) 3.If S c is accepted let S k+1 = S c, otherwise let S k+1 = S k. If G(S k+1 )<G(S 0 ) let S 0 =S k+1 4.Let k=k+1. Terminate the search if the stopping criteria are satisfied. Otherwise return to 2.

4 Local search example 1||  w j T j Jobs1234 wjwj 4535 pjpj djdj

5 Local search example (2) Schedule representation Let the vector S=(j 1,…,j n ) represent the schedule Let the vector S=(j 1,…,j n ) represent the schedule –j k =j if j is the kth job in the sequence Use EDD to construct the initial schedule Use EDD to construct the initial schedule  S 1 = … The total weighted tardiness The total weighted tardiness –Let G(S) be  w j T j under schedule S => G(S 1 )= …

6 Local search example (3) Neighborhood structure Manipulating S 1 Manipulating S 1 1.Pairwise adjacent interchange 2.Try to move a job to a different location in the sequence Rules 1 and 2 above define two types of neighborhoods N 1 and N 2 Rules 1 and 2 above define two types of neighborhoods N 1 and N 2 N 1 (S 1 )=… N 1 (S 1 )=… N 2 (S 1 )=… N 2 (S 1 )=…

7 Local search example (4) Choosing S c Assume we use N 1 Assume we use N 1 Methods for choosing S c from N 1 (S k ) Methods for choosing S c from N 1 (S k ) 1.Randomly 2.Move the job forward that has the highest contribution to the objective Follow rule 2 Follow rule 2  Interchange jobs … and …  S c = (,,, )  G(S c ) =

8 Local search example (5) Acceptance criteria Is G(S c ) < G(S k )? Is G(S c ) < G(S k )? Should we consider accepting S c if G(S c ) ≥ G(S k ) ? Should we consider accepting S c if G(S c ) ≥ G(S k ) ? In this example we only accept if we get an improvement in the objective In this example we only accept if we get an improvement in the objective

9 Local search example (6) Stopping criteria Max number of iterations Max number of iterations No or little improvement No or little improvement –We would terminate the search since we did not improve the current schedule Local optimal solution Local optimal solution –No solution S in N(S k ) satisfies G(S)<G(S k )

10 Local search example (7) Continuing S 2 =S 1 =(1,3,2,4) S 2 =S 1 =(1,3,2,4) –Swap 3 and 2 => G(1,2,3,4) = 115 S 3 =(1,2,3,4) S 3 =(1,2,3,4) –Swap 4 and 3 => G(1,2,4,3) = 67 S 4 =(1,2,4,3) S 4 =(1,2,4,3) –Swap 4 and 2 => G(1,4,2,3) = 72 S 5 =S 4 S 5 =S 4 –Swap 2 and 1 => G(2,1,4,3) = 83 STOP and return (1,2,4,3) as the solution STOP and return (1,2,4,3) as the solution

11 Local search example (8) Total enumeration j1j1 j2j2 j3j3 j4j4 wjTjwjTj j1j1 j2j2 j3j3 j4j4 wjTjwjTj

12 Local search Design criteria i.The representation of the schedule ii.The design of the neighborhood iii.The search process within the neighborhood iv.The acceptance-rejection criteria v.Stopping criteria

13 Simulated Annealing (SA) Annealing: Heating of a material (metal) to a high temperature and then cooling it at a certain rate to achieve a desired crystalline structure Annealing: Heating of a material (metal) to a high temperature and then cooling it at a certain rate to achieve a desired crystalline structure SA: Avoids getting stuck at a local minimum by accepting a worse schedule S c with probability SA: Avoids getting stuck at a local minimum by accepting a worse schedule S c with probability P(S k,S c )= exp ( - G(S c )-G(S k ) ) kkkk

14 SA: Temperature parameter  k ≥ 0 is the temperature (also called cooling parameter)  k ≥ 0 is the temperature (also called cooling parameter) Initially the temperature is high making moves to a worse schedule more likely Initially the temperature is high making moves to a worse schedule more likely ~50% chance of accepting a slightly worse schedule seems to work well As the temperature decreases the probability of accepting a worse schedule decreases As the temperature decreases the probability of accepting a worse schedule decreases –Often,  k =Ta k for some.9 0

15 SA algorithm 1.Set k=1 and select  1. Select S 1 and set S 0 =S 1. 2.Select S c (randomly) from N(S k ). i.If G(S 0 )<G(S c )<G(S k ) set S k+1 =S c and go to 3 ii.If G(S c )<G(S 0 ) set S 0 =S k+1 =S c and go to 3 iii.If G(S c )>G(S k ), generate a uniform random number U k from a Uniform(0,1) distribution (e.g., rand() in Excel) If U k ≤P(S k,S c ), set S k+1 =S c ; otherwise set S k+1 =S k. 3.Select  k+1 ≤  k. Set k=k+1. Stop if stopping criteria are satisfied; otherwise go to 2.

16 SA example: 1||  w j T j Jobs1234 wjwj 4535 pjpj djdj

17 SA example Iteration 1 Step 1: S 0 =S 1 =(1,3,2,4). G(S 1 )=136. Let T=10 and a=.9 =>  1 =9 Step 1: S 0 =S 1 =(1,3,2,4). G(S 1 )=136. Let T=10 and a=.9 =>  1 =9 Step 2. Select randomly which jobs to swap, suppose a Uniform(0,1) random number is V 1 =.24 => swap first two jobs Step 2. Select randomly which jobs to swap, suppose a Uniform(0,1) random number is V 1 =.24 => swap first two jobs –Sc=(3,1,2,4), G(S c )=174, P(S k,S c )=1.5% –U 1 =.91 => Reject S c Step 3: Let k=2 Step 3: Let k=2

18 SA example Iteration 2 Step 2. Select randomly which jobs to swap, suppose a Uniform(0,1) random number is V 2 =.46 => swap 2 nd and 3 rd jobs Step 2. Select randomly which jobs to swap, suppose a Uniform(0,1) random number is V 2 =.46 => swap 2 nd and 3 rd jobs –Sc=(1,2,3,4), G(S c )=115 => S 3 =S 0 =S c Step 3: Let k=3 Step 3: Let k=3

19 SA example Iteration 3 Step 2. V 3 =.88 => swap jobs in 3 rd and 4 th position Step 2. V 3 =.88 => swap jobs in 3 rd and 4 th position –Sc=(1,2,4,3), G(S c )=67 => S 4 =S 0 =S c Step 3: Let k=4 Step 3: Let k=4

20 SA example Iterations 4 and 5 Step 2: V 4 =.49 => swap jobs in 2 nd and 3 rd position Step 2: V 4 =.49 => swap jobs in 2 nd and 3 rd position –S c =(1,4,2,3), G(S c )=72,  4 =10(.9) 4 =6.6 –P(S k,S c )=47%, U 4 =.90 => S 5 =S 4 Step 3: Let k=5 Step 3: Let k=5 Step 2: V 5 =.11 => swap 1 st and 2 nd jobs Step 2: V 5 =.11 => swap 1 st and 2 nd jobs –S c =(2,1,4,3), G(S c )=83,  5 =10(.9) 5 =5.9 –P(S k,S c )=7%, U 5 =.61 => S 6 =S 5 Step 3: Let k=6 Step 3: Let k=6 Are you bored yet? Are you bored yet?

21 Tabu (taboo?) search Tabu search tries to model human memory processes Tabu search tries to model human memory processes A “tabu-list” is maintained throughout the search A “tabu-list” is maintained throughout the search –Moves according to the items on the list are forbidden

22 Tabu search algorithm 1.Set k=1. Select S 1 and set S 0 =S 1. 2.Select S c from N(S k ). i.If the move S k  S c is on the tabu list set S k+1 =S k and go to 3 ii.If S k  S c is not on the tabu list set S k+1 =S c. Add the reverse move to the top of the tabu list and delete the entry on the bottom. If G(S c )<G(S 0 ), set S 0 =S c. 3.Set k=k+1. Stop if stopping criteria are satisfied; otherwise go to 2.

23 Tabu search example: 1||  w j T j Jobs1234 wjwj 4535 pjpj djdj Determine S c by the best schedule in the neighborhood that is not tabu Determine S c by the best schedule in the neighborhood that is not tabu Use tabu-list length = 2 Use tabu-list length = 2 –The tabu list is denoted by L

24 Tabu search example Iteration 1 Step 1: S 0 =S 1 =(1,3,2,4). G(S 1 )=136. Set L={}. Step 1: S 0 =S 1 =(1,3,2,4). G(S 1 )=136. Set L={}. Step 2. N(S 1 )= {(3,1,2,4), (1,2,3,4), (1,3,4,2)} with respective cost = {174, 115, 141} => S c =S 0 =S 2 =(1,2,3,4). Set L={(3,2)}, i.e., swapping 3 and 2 is not allowed Step 2. N(S 1 )= {(3,1,2,4), (1,2,3,4), (1,3,4,2)} with respective cost = {174, 115, 141} => S c =S 0 =S 2 =(1,2,3,4). Set L={(3,2)}, i.e., swapping 3 and 2 is not allowed Step 3: Let k=2 Step 3: Let k=2

25 Tabu search example Iteration 2 Step 2. Step 2. –N(S 2 )= {(2,1,3,4), (1,3,2,4), (1,2,4,3)} –with respective costs = {131, -, 67} => S c =S 3 =(1,2,4,3) –Set S 0 =S c –Set L={(3,4),(3,2)} Step 3: Let k=3 Step 3: Let k=3

26 Tabu search example Iteration 3 Step 2 Step 2 –N(S 3 )= {(2,1,4,3), (1,4,2,3), (1,2,3,4)} –with respective costs = {83, 72, -} => S c =S 4 =(1,4,2,3) –Set L={(2,4),(3,4)} Step 3: Let k=4 Step 3: Let k=4

27 Tabu search example Iteration 4 Step 2 Step 2 –N(S 4 )= {(4,1,2,3), (1,2,4,3), (1,4,3,2)} –with respective costs = {92, -, 123} => S c =S 5 =(4,1,2,3) –Set L={(1,4),(2,4)} Step 3: Let k=5 Step 3: Let k=5

28 Tabu search example Iteration 5 Step 2 Step 2 –N(S 5 )= {(1,4,2,3), (4,2,1,3), (4,1,3,2)} –with respective costs = {-, 109, 143} => S c =S 6 =(4,2,1,3) –Set L={(2,1),(4,1)} Step 3: Let k=6 Step 3: Let k=6