determininstic rounding of linear programs
TRANSCRIPT
Shibbir Ahmed
Student Id : 0805097
Determininstic Rounding of Linear Programs
Chapter: 4 Section: 4.1 Chapter: 4
Section: 4.1
Minimizing the Sum of Completion Times on a Single Machine
February 23, 2014
Sunday
Overview of Section 4.1
Considering a Problem of Scheduling Jobs on a Single Machine with given Inputs & Constraints to minimize the sum of job completion time
Illustrating an example of Nonpreemptive Schedule
Finding an optimal solution to the Preemptive version of the scheduling problem via the rule of Shortest Remaining Processing Time (SRPT)
Illustrating an example of Preemptive Schedule using SRPT rule
2/15
Overview of Section 4.1 (contd.)
Observation from the fact that an Optimal Nonpreemptive Schedule is feasible for the Preemptive Scheduling problem
Lemma showing that scheduling nonpreemptively does not delay the jobs by too much
Proving a Theorem for scheduling a single machine to minimize the sum of completion times by the Lemma & the Observation
3/15
Explanation of Some Terms
Scheduling
Allocation of limited resources to the given set of jobs over time
Components of a Scheduling Problem Tasks/Jobs
Constraints
Resources
Objective/Goal
Single Machine
Only one resource available for the processing of tasks/jobs
4/15
Explanation of Some Terms (contd.)
Nonpreemptive
In which a running job can be interrupted before the completion
of a Job or
For starting another Job
Preemptive
Running Job is executed till Completion of that job
For delaying to complete Jobs with higher priority
Nonpreemtive Job can not be interrupted
5/15
Problem of Scheduling Job on a Single Machine
Constraints
Inputs
A schedule for jobs on a single machine is to be constructed such that ;
Number of Jobs π
Release Date i.e., The time of arrival of job in the scheduling system ππ
Processing Time i.e., The time for which job executes on a machine ππ
(i) At most One Job is processed at each point in time
(ii) No Job is processed before its release date
(iii) Each Job must be processed nonpreemptively
6/15
Problem of Scheduling Job on a Single Machine (contd.)
Objective
Find the schedule that minimizes ,
Completion Time i.e., The time at which Job j finished its processing
Cπ
Cπ
π
π=1
The Problem of Minimizing the Average Completion Time
Equivalent to
because
The Average Completion Time just rescales the objective function for each
π/π feasible solution by a factor of
7/15
Example of Nonpreemptive Schedule
Job No. Processing
Time (p) Release
Date (r)
Job1 2 0
Job2 1 4
Job3 4 1
Completion
Time (C)
2
5
9
Job 1 Job 2 Job 3
0 4 2 5 9 Time
Cπ π
= 2 + 5 + 9
= 16
8/15
Shortest Remaining Processing Time (SRPT) Rule
An Optimal Solution to the Preemptive version of the scheduling problem can be found in polynomial time via
SRPT rule.
(i) Starting at time 0 and schedule the job with the smallest amount of remaining processing time as long as the job is past its release date &
have not been already completed
(ii) Scheduling the job until either it is completed or a new job is released
(iii) Iterating the process
9/15
Job No. Processing
Time (p) Release
Date (r)
Job1 2 0
Job2 1 4
Job3 4 1
Completion
Time (C)
2
5
7
Job 1 Job 2 Job 3
0 4
Job 3
2 5 7 Time
Cπ π
= 2 + 5 + 7
= 14
Example of Preemptive Schedule using SRPT rule
Note: The Processing of
job1 is not interrupted when
job3 arrives at time 1
10/15
Observation: 4.1
πΆππ π
π=1 β€ OPT
The Completion time of job j in an optimal preemptive schedule πΆππ
Let,
OPT The Sum of Completion time in an optimal nonpreemptive schedule
the fact that an Optimal Nonpreemptive Schedule is feasible for the Preemptive
Scheduling problem
Observation
Proved by
11/15
Scheduling Algorithm
Now, Considering this Scheduling Algorithm a Lemma is to be proved.
(i) Finding an optimal preemptive schedule using SRPT
(ii) Scheduling the job nonpreemptively in the same order that they complete in this preemptive schedule
Example πΆ1π
πΆ2π
πΆππ
β€ β€ β¦ β€
(i) Schedule Job1 from its release date ππ π‘π π‘πππ (ππ+ ππ)
(ii) Schedule Job2 as soon as possible after Job1 ; i.e., max(ππ+ ππ, ππ) to max(ππ+ ππ, ππ) + ππ
πππ πͺππ΅ Job j is processed from max *πͺπβπ
π΅ , ππ+ π‘π max *πͺπβππ΅ , ππ+ + ππ
12/15
Lemma: 4.2
Proof
Consequently, in the time interval from ππππ=π,β¦,π
ππ to πͺππ΅ , there
can not be any point in time at which machine is idle.
πππ πππβ πππ π = 1,β¦ , π πΆππ β€ 2πΆπ
π
As, π is processed in the optimal preemptive schedule after jobs1,β¦ , π β 1
& πͺππ· β₯ ππππ=π,β¦,π
ππ πͺππ· β₯ ππ
π
π=1
πͺππ΅ β₯ ππππ=π,β¦,π
ππ
So,
Therefore, πͺππ΅ β€ πππ
π=π,β¦,πππ + ππ
ππ=1 β€ ππͺπ
π·
13/15
Theorem: 4.3
Therefore,
ππππ π³ππππ π. π πΆππ β€ 2πΆπ
π
& ππππ πΆππππππππππ π. π β€ πΆπ
π
π
π=1
OPT
2 πΆππ
π
π=1
πΆππ
π
π=1
β€ β€ 2 OPT
Concluding Remark Scheduling in order of the completion times of an optimal preemptive schedule is a 2-approximation
algorithm for scheduling a single machine with release dates to minimize the sum of completion times.
14/15