Title: Optimal Preemptive Scheduling for General Target Functions
1Optimal Preemptive Scheduling for General Target
Functions
- Leah Epstein
- The Interdisciplinary Center, Herzliya, Israel
- Tamir Tassa
- The Open University, Ramat Aviv, Tel Aviv, Israel
- Ben Gurion University, Beer Sheva, Israel
2How to cook three pancakes in 3 minutes
- Each pancake has to be cooked for one minute on
each side - We may use two frying pans
- Non-preemptive cooking - Cooking of a pancake
must be done continuously - Preemptive cooking - Cooking of a pancake may be
stopped and resumed at a later stage
3The non-preemptive optimal offline schedule
The preemptive optimal offline schedule
4
2
4Non-preemptive scheduling
- A set of m uniformly related machines
- Machine i has speed si
- A set of jobs J
- Job j has weight pj which is its processing time
on a unit speed machine - Time to run job j on machine i is pj / si
- This is called the load of job j on machine i
- Each job is assigned to one of the machines
5Load versus Weight
- The weight of a machine i is the sum of weights
of jobs assigned to it - Notation
- The weight of a machine i is the sum of loads of
jobs assigned to it - Notation
- We have
6Goal functions
- The goal is to minimize a function of machine
completion times - A standard goal function is Minimizing the
makespan (the maximum completion time, i.e. the
maximum load of any machine)
7Jobs Machines
1 2 4
8An optimal non-preemptive schedule
9Preemptive scheduling
- Each job is cut into pieces and each piece is
assigned to one of the machines - Two parts of the same job cannot run
simultaneously - The goal is to minimize a function of machine
completion times - Makespan is again a common goal function
10Jobs Machines
11An optimal preemptive schedule
12Optimal preemptive scheduling to minimize makespan
- Was studied by Horvath, Lam and Sethi, 1977
- gave the first optimal polynomial time
algorithm - They give an exact solution, but with a large
number of preemptions - Gonzalez and Sahni, 1978 reduce the number of
preemptions to 2(m-1) - Shachnai, Tamir and Woeginger 2002, also study
the problem with respect to the number of
preemptions.
13Optimality for various goal functions
- Is the optimal makespan solution optimal for any
goal function? - For any nice goal function?
- Symmetric
- Monotone
- Convex
- Examples norms (in particular the
norm), threshold functions.
14 - are the completion times
- The norm for
- The threshold function
- also known as Extensible Bin Packing
15Applications
- The norm measures the balance in the
schedule, we would like most completion times not
to vary to much - The threshold function gives the cost in the case
where some running time of the machines was
bought in advance, and needs to be paid for no
matter if it is used or not
16The norm and the threshold function versus
makespan
The norm cost is
The threshold function cost with c1 is 12
6
10
12
17The norm versus makespan
The norm cost is
16/3 12/3 8/3 4/3 0
5/3
13/6
8/3
3/2
6
10
12
18The threshold function versus makespan
The threshold function cost with c1 is 8.25
2.25
4 3 2 1 0
2.5
1.5
1
1
6
10
12
19Properties of nice functions
- Idle time (holes) is not necessary
- The completion times are non-decreasing (I.e. a
faster machine has a larger (or equal) completion
time) than a slower machine. - This is not true for general functions
20Non-symmetric functions
- Speeds 1 and 2
- One job of size 5
- An optimal schedule must have a hole
21Conditions on Load and Weight
- Let Wm be the sum of all job weights, then
- Assume that
- Let Wk be the sum of the k largest job weights,
- for some then
- i.e. the amount (weight) assigned to the k
fastest machines is at least the weight of the
largest k jobs
22The mathematical program
- Let be the bounded polyhedron of
all non-negative machine weights - that satisfy the conditions from the previous
slide - The optimal value of the goal function is
23An optimal solution
- Two independent steps
- Finding the completion times by solving a
mathematical program - scheduling the jobs given the completion times
- For special cases as the norm and the
threshold function we solve the mathematical
program using relatively simple algorithms
24Solving the assignment problem (given the
solution of the math. Program)
- Sort the jobs according to size (starting from
largest) - We define two functions
- Red function time
- Green function speed
- (also identifies the machine, if there are
identical speeds, we need to add a third
function) - Given the completion times and speeds
- Speed 1, completion time 10 interval 0,10
- Speed 0.8, completion time 8 interval 10,18
- Speed 0.6, completion time 6 interval 18,24
- Speed 0.3, completion time 3 interval 24,27
25Green function (speed)
26Red function time
27(No Transcript)
28Intervals which are valid for removal
29CUT
SHIFT
30(No Transcript)
31 32(No Transcript)
3310
9
8
7
6
5
4
3
2
1
0
3410
9
8
7
6
5
4
3
2
1
0
3510
9
8
7
6
5
4
3
2
1
0
3610
9
8
7
6
5
4
3
2
1
0
3710
9
8
7
6
5
4
3
2
1
0
3810
9
8
7
6
5
4
3
2
1
0
3910
9
8
7
6
5
4
3
2
1
0
4010
9
8
7
speed 0.8
6
5
4
speed 0.6
speed 1
3
2
speed 0.3
1
0
4110
9
8
7
6
5
4
3
2
1
0
4210
9
8
7
6
5
4
3
2
1
0
4310
9
8
7
6
5
4
3
2
1
0
4410
9
8
7
6
5
4
3
2
1
0
45Future work
- Given the completion times, is it necessary to
sort the jobs to assign them? (no) - Simple solution of the mathematical program for
other goal functions