Classification - Examples -1- 1 r j C max given: n jobs with processing times p 1,..., p n and release dates



Similar documents
Classification - Examples

Scheduling Single Machine Scheduling. Tim Nieberg

Single machine models: Maximum Lateness -12- Approximation ratio for EDD for problem 1 r j,d j < 0 L max. structure of a schedule Q...

Scheduling Shop Scheduling. Tim Nieberg

Complexity Theory. IE 661: Scheduling Theory Fall 2003 Satyaki Ghosh Dastidar

Single machine parallel batch scheduling with unbounded capacity

JUST-IN-TIME SCHEDULING WITH PERIODIC TIME SLOTS. Received December May 12, 2003; revised February 5, 2004

Real Time Scheduling Basic Concepts. Radek Pelánek

Approximability of Two-Machine No-Wait Flowshop Scheduling with Availability Constraints

Tutorial 8. NP-Complete Problems

Factors to Describe Job Shop Scheduling Problem

Duplicating and its Applications in Batch Scheduling

Real-Time Scheduling (Part 1) (Working Draft) Real-Time System Example

Introduction to Scheduling Theory

5 INTEGER LINEAR PROGRAMMING (ILP) E. Amaldi Fondamenti di R.O. Politecnico di Milano 1

Approximation Algorithms

Algorithm Design and Analysis

Common Approaches to Real-Time Scheduling

Aperiodic Task Scheduling

NP-complete? NP-hard? Some Foundations of Complexity. Prof. Sven Hartmann Clausthal University of Technology Department of Informatics

! Solve problem to optimality. ! Solve problem in poly-time. ! Solve arbitrary instances of the problem. #-approximation algorithm.

Offline sorting buffers on Line

Completion Time Scheduling and the WSRPT Algorithm

Abstract Title: Planned Preemption for Flexible Resource Constrained Project Scheduling

A binary search algorithm for a special case of minimizing the lateness on a single machine

Lecture Outline Overview of real-time scheduling algorithms Outline relative strengths, weaknesses

An improved on-line algorithm for scheduling on two unrestrictive parallel batch processing machines

Introducción a Calendarización en Sistemas Paralelas, Grids y Nubes

Fairness in Routing and Load Balancing

5.1 Bipartite Matching

Lecture 7: NP-Complete Problems

List Scheduling in Order of α-points on a Single Machine

Topic: Greedy Approximations: Set Cover and Min Makespan Date: 1/30/06

Stiffie's On Line Scheduling Algorithm

Scheduling Real-time Tasks: Algorithms and Complexity

NP-Completeness and Cook s Theorem

Near Optimal Solutions

CSC2420 Spring 2015: Lecture 3

Dimensioning an inbound call center using constraint programming

Real-Time Software. Basic Scheduling and Response-Time Analysis. René Rydhof Hansen. 21. september 2010

Lecture 19: Introduction to NP-Completeness Steven Skiena. Department of Computer Science State University of New York Stony Brook, NY

Scheduling Sporadic Tasks with Shared Resources in Hard-Real-Time Systems

Batch Scheduling of Deteriorating Products

3. Scheduling issues. Common approaches /1. Common approaches /2. Common approaches / /13 UniPD / T. Vardanega 23/01/2013. Real-Time Systems 1

Discrete Optimization

THROUGHPUT OPTIMIZATION IN ROBOTIC CELLS

24. The Branch and Bound Method

Research Article Batch Scheduling on Two-Machine Flowshop with Machine-Dependent Setup Times

8.1 Min Degree Spanning Tree

Why? A central concept in Computer Science. Algorithms are ubiquitous.

NP-Completeness I. Lecture Overview Introduction: Reduction and Expressiveness

MIP-Based Approaches for Solving Scheduling Problems with Batch Processing Machines

Applied Algorithm Design Lecture 5

University Dortmund. Robotics Research Institute Information Technology. Job Scheduling. Uwe Schwiegelshohn. EPIT 2007, June 5 Ordonnancement

Exponential time algorithms for graph coloring

Chapter Load Balancing. Approximation Algorithms. Load Balancing. Load Balancing on 2 Machines. Load Balancing: Greedy Scheduling

Literature Review of Single Machine Scheduling Problem with Uniform Parallel Machines

Page 1. CSCE 310J Data Structures & Algorithms. CSCE 310J Data Structures & Algorithms. P, NP, and NP-Complete. Polynomial-Time Algorithms

A Beam Search Heuristic for Multi-Mode Single Resource Constrained Project Scheduling

! Solve problem to optimality. ! Solve problem in poly-time. ! Solve arbitrary instances of the problem. !-approximation algorithm.

Heuristic Algorithms for Open Shop Scheduling to Minimize Mean Flow Time, Part I: Constructive Algorithms

Partitioned real-time scheduling on heterogeneous shared-memory multiprocessors

Scheduling Parallel Jobs with Monotone Speedup 1

Today s topic: So far, we have talked about. Question. Task models

A generalized job-shop problem with more than one resource demand per task

Constraint-Based Scheduling: A Tutorial

CSC 373: Algorithm Design and Analysis Lecture 16

Scheduling Parallel Jobs with Linear Speedup

CS 3719 (Theory of Computation and Algorithms) Lecture 4

11. APPROXIMATION ALGORITHMS

OHJ-2306 Introduction to Theoretical Computer Science, Fall

Arithmetic Coding: Introduction

Minimizing the Number of Machines in a Unit-Time Scheduling Problem

The Trip Scheduling Problem

CAD Algorithms. P and NP

Computer Algorithms. NP-Complete Problems. CISC 4080 Yanjun Li

Diversity Coloring for Distributed Data Storage in Networks 1

Bounded Cost Algorithms for Multivalued Consensus Using Binary Consensus Instances

Dynamic programming. Doctoral course Optimization on graphs - Lecture 4.1. Giovanni Righini. January 17 th, 2013

How To Find An Optimal Search Protocol For An Oblivious Cell

The P versus NP Solution

1. Nondeterministically guess a solution (called a certificate) 2. Check whether the solution solves the problem (called verification)

The Model Checker SPIN

2. (a) Explain the strassen s matrix multiplication. (b) Write deletion algorithm, of Binary search tree. [8+8]

Truthful Mechanisms for Value-Based Scheduling in Cloud Computing

Quantum and Non-deterministic computers facing NP-completeness

NP-Completeness. CptS 223 Advanced Data Structures. Larry Holder School of Electrical Engineering and Computer Science Washington State University

Load Balancing and Rebalancing on Web Based Environment. Yu Zhang

SIMS 255 Foundations of Software Design. Complexity and NP-completeness

Distributed Load Balancing for Machines Fully Heterogeneous

On-line machine scheduling with batch setups

Scheduling a sequence of tasks with general completion costs

Efficiency of algorithms. Algorithms. Efficiency of algorithms. Binary search and linear search. Best, worst and average case.

The Goldberg Rao Algorithm for the Maximum Flow Problem

How To Solve A Minimum Set Covering Problem (Mcp)

A Working Knowledge of Computational Complexity for an Optimizer

A Study of Crossover Operators for Genetic Algorithm and Proposal of a New Crossover Operator to Solve Open Shop Scheduling Problem

Guessing Game: NP-Complete?

Proximal mapping via network optimization

Online Scheduling for Cloud Computing and Different Service Levels

Transcription:

Lecture 2 Scheduling 1 Classification - Examples -1-1 r j C max given: n jobs with processing times p 1,..., p n and release dates r 1,..., r n jobs have to be scheduled without preemption on one machine taking into account the earliest starting times of the jobs, such that the makespan is minimized n = 4, p = (2, 4, 2, 3), r = (5, 4, 0, 3)

Lecture 2 Scheduling 2 Classification - Examples -1-1 r j C max given: n jobs with processing times p 1,..., p n and release dates r 1,..., r n jobs have to be scheduled without preemption on one machine taking into account the earliest starting times of the jobs, such that the makespan is minimized n = 4, p = (2, 4, 2, 3), r = (5, 4, 0, 3) 3 4 1 2 0 5 10 12 Feasible Schedule with C max = 12 (schedule is optimal)

Lecture 2 Scheduling 3 Classification - Examples -2- F 2 w j T j given n jobs with weights w 1,..., w n and due dates d 1,..., d n operations (i, j) with processing times p ij, i = 1, 2; j = 1,..., n jobs have to be scheduled on two machines such that operation (2, j) is schedules on machine 2 and does not start before operation (1, j), which is scheduled on machine 1, is finished and the total weighted tardiness ( is ) minimized 2 1 3 n = 3, p =, w = (3, 1, 5), d = (6, 8, 4) 3 4 1

Lecture 2 Scheduling 4 Classification - Examples -2- F 2 w j T j given n jobs with weights w 1,..., w n and due dates d 1,..., d n operations (i, j) with processing times p ij, i = 1, 2; j = 1,..., n jobs have to be scheduled on two machines such that operation (2, j) is schedules on machine 2 and does not start before operation (1, j), which is scheduled on machine 1, is finished and the total weighted tardiness ( is ) minimized 2 1 3 n = 3, p =, w = (3, 1, 5), d = (6, 8, 4) 3 4 1 M1 3 1 2 wj T j = 3(8 6) + (12 9) M2 3 1 2 +5(4 4) = 9 0 5 10 12 d 3 d 1 d 2

Lecture 2 Scheduling 5 Classes of Schedules Nondelay Schedules: A feasible schedule is called a nondelay schedule if no machine is kept idle while a job/an operation is waiting for processing Example: P 3 prec C max n = 6 p = (1, 1, 2, 2, 3, 3) 1 2 3 4 5 6-1-

Lecture 2 Scheduling 6 Classes of Schedules Nondelay Schedules: A feasible schedule is called a nondelay schedule if no machine is kept idle while a job/an operation is waiting for processing Example: P 3 prec C max n = 6 p = (1, 1, 2, 2, 3, 3) Best nondelay: M1 M2 M3 1 2 3 4 5 6 1 2 3 4 5 6 Optimal M1 M2 M3 1 2 5 3 4 6-1-

Lecture 2 Scheduling 7 Classes of Schedules Remark: restricted to non preemptive schedules Active Schedules: A feasible schedule is called active if it is not possible to construct another schedule by changing the order of processing on the machines and having at least one job/operation finishing earlier and no job/operation finishing later. Semi-Active Schedules: A feasible schedule is called semi-active if no job/operation can be finishing earlier without changing the order of processing on any one of the machines. -2-

Lecture 2 Scheduling 8 Classes of Schedules Examples of (semi)-active schedules: Prec: 1 2; 2 3 not semi-active M1 M2 1 2 3 4 5-3-

Lecture 2 Scheduling 9 Classes of Schedules Examples of (semi)-active schedules: Prec: 1 2; 2 3 not semi-active semi-active M1 M2 M1 M2 1 1 2 2 3 3 4 4 5 5-3-

Lecture 2 Scheduling 10 Classes of Schedules Examples of (semi)-active schedules: Prec: 1 2; 2 3 not semi-active semi-active active M1 M2 M1 M2 M1 M2 1 1 2 2 3 3 1 5 3 4 2 4 4 5 5-3-

Lecture 2 Scheduling 11 Classes of Schedules Properties: every nonpreemptive nondelay schedule is active every active schedule is semiactive if the objective criterion is regular, the set of active schedules contains an optimal schedule (regular = non decreasing with respect to the completion times) Summary: All schedules -4- x non- delay active optimal schedule Semi active

Lecture 2 Scheduling 12 Research topics for Scheduling determine boarder line between polynomially solvable and NP-hard models for polynomially solvable models find the most efficient solution method (low complexity) for NP-hard models develop enumerative methods (DP, branch and bound, branch and cut,...) develop heuristic approached (priority based, local search,...) consider approximation methods (with quality guarantee)

Lecture 2 Scheduling 13 Intermezzo: Complexity Theory -1- mathematical framework to study the difficulty of algorithmic problems Notations/Definitions problem: generic description of a problem (e.g. 1 C j ) instance of a problem: given set of numerical data (e.g. n, p 1,..., p n ) size of an instance I: length of the string necessary to specify the data (Notation: I ) binary encoding: I = n + log(p 1 ) +... + log(p n ) unary encoding: I = n + p 1 +... + p n

Lecture 2 Scheduling 14 Intermezzo: Complexity Theory -2- Notations/Definitions efficiency of an algorithm: upper bound on number of steps depending on the size of the instance (worst case consideration) big O-notation: for an O(f(n)) algorithm a constant c > 0 and an integer n 0 exist, such that for an instance I with size n = I and n n 0 the number of steps is bounded by cf(n) Example: 7n 3 + 230n + 10 log(n) is O(n 3 ) (pseud)polynomial algorithm: O(p( I )) algorithm, where p is a polynomial and I is coded binary (unary) Example: an O(n log( p j )) algorithm is a polynomial algorithm and an O(n p j ) algorithm is a pseudopolynomial algorithm

Lecture 2 Scheduling 15 Intermezzo: Complexity Theory -3- Classes P and N P a problem is (pseudo)polynomial solvable if a (pseudo)polynomial algorithm exists which solves the problem Class P: contains all decision problems which are polynomial solvable Class N P: contains all decision problems for which - given an yes instance - the correct answer, given a proper clue, can be verified by a polynomial algorithm Remark: each optimization problem has a corresponding decision problem by introducing a threshold for the objective value (does a schedule exist with objective smaller k?)

Lecture 2 Scheduling 16 Intermezzo: Complexity Theory -4- Polynomial reduction a decision problem P polynomially reduces to a problem Q, if a polynomial function g exists that transforms instances of P to instances of Q such that I is a yes instance of P if and only is g(i) is a yes instance of Q Notation: P Q NP-complete a decision problem P N P is called NP-complete if all problems from the class N P polynomially reduce to P an optimization problem is called NP-hard if the corresponding decision problem is NP-complete

Lecture 2 Scheduling 17 Intermezzo: Complexity Theory -5- Examples of NP-complete problems: SATISFIABILITY: decision problem in Boolean logic, Cook in 1967 showed that all problems from N P polynomially reduce to it PARTITION: given n positive integers s 1,..., s n and b = 1/2 n j=1 s j does there exist a subset J I = {1,..., n} such that s j = b = j J j I\J s j

Lecture 2 Scheduling 18 Intermezzo: Complexity Theory -6- Examples of NP-complete problems (cont.): 3-PARTITION: given 3n positive integers s 1,..., s 3n and b with b/4 < s j < b/2, j = 1,..., 3n and b = 1/n 3n j=1 s j do there exist disjoint subsets J i I = {1,..., 3n} such that s j = b; i = 1,..., n j J i

Lecture 2 Scheduling 19 Intermezzo: Complexity Theory -7- Proofing NP-completeness If an NP-complete problem P can be polynomially reduced to a problem Q N P, than this proves that Q is NP-complete (transitivity of polynomial reductions) Example: P ART IT ION P 2 C max Proof: on the board Famous open problem: Is P = N P? solving one NP-complete problem polynomially, would imply P = N P

Lecture 2 Scheduling 20 Single machine models Observation: for non-preemptive problems and regular objectives, a sequence in which the jobs are processed is sufficient to describe a solution Dispatching (priority) rules static rules - not time dependent e.g. shortest processing time first, earliest due date first dynamic rules - time dependent e.g. minimum slack first (slack= d j p j t; t current time) for some problems dispatching rules lead to optimal solutions

Lecture 2 Scheduling 21 Single machine models: 1 w j C j -1- Given: n jobs with processing times p 1,..., p n and weights w 1,..., w n Consider case: w 1 =... = w n (= 1):

Lecture 2 Scheduling 22 Single machine models: 1 w j C j -1- Given: n jobs with processing times p 1,..., p n and weights w 1,..., w n Consider special case: w 1 =... = w n (= 1): SPT-rule: shortest processing time first Theorem: SPT is optimal for 1 C j Proof: by an exchange argument (on board) Complexity: O(n log(n))

Lecture 2 Scheduling 23 Single machine models: 1 w j C j -2- General case WSPT-rule: weighted shortest processing time first, i.e. sort jobs by increasing p j /w j -values Theorem: WSPT is optimal for 1 w j C j Proof: by an exchange argument (exercise) Complexity: O(n log(n)) Further results: 1 tree w j C j can be solved by in polynomial time (O(n log(n))) (see [Brucker 2004]) 1 prec C j is NP-hard in the strong sense (see [Brucker 2004])

Lecture 2 Scheduling 24 Single machine models: 1 prec f max -1- Given: n jobs with processing times p 1,..., p n regular functions f 1,..., f n objective criterion f max = max{f 1 (C 1 ),..., f n (C n )} Observation: completion time of last job = p j

Lecture 2 Scheduling 25 Single machine models: 1 prec f max -1- Given: n jobs with processing times p 1,..., p n regular functions f 1,..., f n objective criterion f max = max{f 1 (C 1 ),..., f n (C n )} Observation: completion time of last job = p j Method plan backwards from p j to 0 from all available jobs (jobs from which all successors have already been scheduled), schedule the job which is cheapest on that position

Lecture 2 Scheduling 26 Single machine models: 1 prec f max -2- S set of already scheduled jobs (initial: S = ) J set of all jobs, which successors have been scheduled (initial: all jobs without successors) t time where next job will be completed (initial: t = p j ) Algorithm 1 prec f max (Lawler s Algorithm) REPEAT select j J such that h j (t) = min k J f k (t); schedule j such that it completes at t; add j to S, delete j from J and update J; t := t p j ; UNTIL J =.

Lecture 2 Scheduling 27 Single machine models: 1 prec f max -3- Theorem: Algorithm 1 prec f max is optimal for 1 prec f max Proof: on the board Complexity: O(n 2 )