1 / 45

Approximation Algorithms for Scheduling

Approximation Algorithms for Scheduling. O3|| C max. Partition. Given natural numbers a 1 ,…, a n , B . Is there a subset S  {1,…, n }such that Reduction: n +1 jobs, p 01 = p 02 = p 03 = B, p i 1 = p i 2 = p i 3 = a i , i =1,…, n. Is there exist a schedule with C max = 3 B. M 1.

waterbury
Download Presentation

Approximation Algorithms for Scheduling

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Approximation Algorithms for Scheduling

  2. O3||Cmax Partition. Given natural numbers a1,…,an, B. • Is there a subset S  {1,…, n}such that • Reduction: • n+1 jobs, p01=p02=p03=B, pi1=pi2=pi3=ai , i=1,…,n. • Is there exist a schedule with Cmax= 3B. M1 M2 M3 0 B 2B 3B

  3. Partition M1 M2 M3 0 B 2B 3B Operations of partition jobs: M1 M2 M3 0 B 2B 3B

  4. F3||Cmax • 3-Partition. Given natural numbers a1,…,a3n, B, such that and B/4 < ai< B/2 for all i. • Can numbers a1,…,a3n be partitioned into n triplet S1,...,Sn such that the sum of the numbers in each subset is equal to B. Reduction: n–1“special” jobs and n“partition” jobs, • “special” jobs: q11=B, q12=B, q13=2B, qi1=2B, qi2=B, qi3=2B, i=2,…, n–2, qn–11=2B, qn–12=B, qn–13=B. • “partition” jobs pi1= 0, pi2=ai , pi3 = 0, i=1,…,n. • Is there exist a schedule with Cmax= (2n–1)B. M1 1 2 3 n–1 M2 1 2 3 n–1 M3 1 2 3 n–1 0 2B 4B 6B (2n–1)B

  5. Approximation • Scheduling problems provide a good starting point for the study approximation algorithms, and historically they were among the first problems to be analyzed this way. • When was the first time that someone presented a worst-case analysis of an approximation algorithm. • It was probably 1966, the year that Ron Graham analyzed a simple procedure for one of the most basic scheduling problem: minimizing makespan in an identical parallel machine environment.

  6. P||Cmax • We have a set of n jobs, J1,..., Jn, and m identical machines, M1,..., Mm. • Each job must be processed without interruption for a time pj > 0 on one of the m machines, each of which can process at most one job at a time.

  7. List Scheduling (LS) • We a given a list of the jobs in some arbitrary order. Whenever a machine becomes available, the next job on the list is assigned to begin processing on the machine.

  8. First Approximation Algorithm Theorem 10.1 (Graham [1966]) The List Scheduling Algorithm is a 2 – (1/m) factor approximation algorithm for P||Cmax.

  9. Proof M1 M2 Jk M3 M4 sk Ck t = 0

  10. Notation • Jobs are denoted as Jj, and n denotes the number of jobs. • Machines are denoted Mi, and when there is more than one machine, we use m to denote the number of machines. • A schedule σ is an assignment of jobs to machines and associated starting times s1(σ),...,sn(σ) of jobs J1,..., Jn, respectively.

  11. Feasible Schedule • A feasible schedule will have the property that at any point in time a machine processes at most one job at a time; that is if two jobs Jjand Jkare assigned to the same machine then either sj + pj≤ skor sk + pk≤ sj. • We use Cjto denote the time at which job Jjcompletes processing in given schedule, i.e., sj + pj= Cj. • A schedule associated with a given algorithm A is denoted σ(A).

  12. Precedence constraints

  13. 1||Lmax • We consider scheduling problem on a single machine. In a given instance, each job Jj has a due date dj associated with it, as well as a processing time pj > 0; for a given schedule σ we define the lateness of a job as Lj(σ) = Cj(σ) – dj ; in particular, if the job completes before its due date, its “lateness” can be negative. Our goal find a schedule that minimizes the maximum lateness over all jobs,

  14. Delivery times • We consider a new model with delivery times. In this model, each job Jj must be processed on the machine and then spend an additional amount of time qj being delivered. This “delivery” can be interpreted as an additional processing requirement on a non-bottleneck machine, or as a physical delivery (travel) time. • The delivery-completion time of a job Jj is sj + pj+ qj.

  15. 1|rj|Lmax • Next we introduce job release dates into the model: each job Jj cannot begin its processing before its release dates rj. This problem is strongly NP-hard; a reduction from 3-PARTITION is relatively straightforward.

  16. Lower Bounds

  17. List Scheduling Algorithm (LS) • Let us first consider a straightforward generalization of Graham’s list scheduling algorithm LS; whenever the machine becomes available, schedule the first available job on the list. A job is defined as “available” if it has already been released.

  18. Algorithm LS Theorem 10.2 and this bound is tight.

  19. Proof

  20. Bad case LS: J1, J2 OPT: J2, J1 ratio = (2M+1)/(M+2)

  21. Jackson’s Rule (J) • Apply List Scheduling Algorithm to a list with jobs ordered by non-increasing delivery times (equivalent to an EDD, or earliest due-date, ordering). • Of course, the two-job instance just given illustrates that the worst-case performance does not improve over arbitrary list scheduling.

  22. Algorithm J • Corollary 10.3 and this bound is tight.

  23. Critical job • Let us examine this heuristic J in slightly more detail. • Let us define a critical job Jcas one whose lateness attains that of the schedule,

  24. Critical job Jc, Interference job Jb qc qb< qc Jb Ja Jc 0 ra Lmax =Lc critical sequence S; S’S Jb is interference job

  25. A simple 3/2-Approximation Algorithm

  26. Algorithm NS • Construct the schedule given by Jackson’s rule, and determine a critical job Jcand critical sequence for the schedule. If there exists no interference job Jb, then stop and return this schedule. • If min{pb, qc} ≤ P/2, then stop and return the schedule of Step 1. Otherwise, order the jobs of A according to nondecreasing release dates and of B according to nonincreasing delivery times. (Note that Jb = Jd .) Construct a schedule given by the order set A, followed by Jb, followed by the ordered set B. Return the better of this schedule and that constructed in Step 1.

  27. Algorithm NS (2) Theorem 10.4 (Novicki & Smutnicki [1994]) Algorithm NS is a (3/2)-approximation algorithm.

  28. Proof (1st Schedule) qc Jb Ja Jc ra critical sequence S Lmax =Lc No interference job Jb schedule is optimal b = d a=b=c schedule is optimal

  29. Proof (2nd Schedule) Jb A; rj≤ qj B; rj> qj

  30. Case 1.1: Jh, Jk A Q Jh Jk Jb A; rj≤ qj Jb  Q rh≤ rk

  31. Case 1.2: Jh, Jk B Q Jb Jh Jk B; rj> qj Jb  Q qk≤ qh

  32. Case 2.1: Jk= Jb Q Jh Jk =Jb A; rj≤ qj B; rj> qj Case 2.1.1: All of the jobs of Q\{Jb} are processed before job Jb in σ*.

  33. Case 2.1: Jk= Jb Q Jh Jk =Jb A; rj≤ qj B; rj> qj Case 2.1.2: At least one job of Q\{Jb} is processed after job Jb in σ*. Q\{Jb}A rj≤ qj

  34. Case 2.2: Jh= Jb Q Jh =Jb Jk A; rj≤ qj B; rj> qj Case 2.1.1: All of the jobs of Q\{Jb} are processed after job Jb in σ*.

  35. Case 2.2: Jk= Jb Q Jh =Jb Jk A; rj≤ qj B; rj> qj Case 2.2.2: At least one job of Q\{Jb} is processed before job Jb in σ*. Q\{Jb} B rj> qj

  36. Case 3: Jh A, Jk B Q Jh Jb Jk A; rj≤ qj B; rj> qj Let Ji be that jobs of Q that gets processed first in σ*. Ji  A rh≤ ri Ji  B ri≥ qi ≥ qk Pi= Pb

  37. PTAS • While 1|rj|Lmax is strongly NP-hard, there do exist polynomial approximation schemes for it, that is, a family of (1+1/k)-approximation algorithms for k = 1, 2, 3, … . • To explain the polynomial approximation scheme, we first examine an artificial situation that we shall use as a tool in analyzing the eventual algorithm.

  38. Modified Instance

  39. Modified Instance (2) I Ji Jj Lmax ri rj Ji Jj Lmax

  40. Big and small jobs A B Ji Jj Jb Let us analyze the schedule σJdelivered by Jackson’s rule on this instance. Jc is critical job;Jb is interference job. Schedule σJis optimal No interference job Jb A

  41. Big and small jobs A B Ji Jb Jc is a critical job;Jb is an interference job. Jb B Job Jc begins processing after job Jb inσ*

  42. Conclusion

  43. How to design it? • In fact, in order to reconstruct σ it is sufficient to know simply positions that each of the jobs of B have in σ; we can then run Jackson’s rule with the exception that when a position belonging to a job of B is reached, we place that job next in the ordering. Of course, we also do not know the positions of the jobs of B in σ, but by trying every possible choice for positioning the jobs of B in the sequence and selecting the best schedule generated, we are guaranteed to find a schedule as good as σ. There are O(n|B|) such choices.

  44. How to choose δ?

  45. Exercise LPT rule: • Order the job list by non-increasing processing times. • Apply List Scheduling Algorithm Prove that LPT is a4/3-factor approximation algorithm forP||Cmax.

More Related