Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more ➡
Standard view
Full view
of .
×
0 of .
Results for:
P. 1
Make Span

# Make Span

Ratings: 0|Views: 14|Likes:

### Availability:

See More
See less

05/22/2013

pdf

text

original

ABetterAlgorithmForanAncientSchedulingProble
DavidR.Karger
StevenJ.Phillips
EricTorng
DepartmentofComputerScienceStanfordUniversityStanford,CA94305-2140
Abstract
Oneoftheoldestandsimplestvariantsofmultiprocessorschedulingistheon-lineschedulingproblemstudiedbyGrahamin1966.Inthisproblem,thejobsarriveon-lineandmustbeschedulednon-preemptivelyon

1
=
).Recentlyalgorithmswithsmallercompetitiveratiosthan ListProcessinghavebeendiscovered,culminatinginBartal,Fiat,Karlo,andVohra'sconstructionofanalgorithmwitcompetitiveratioboundedawayfrom2.Theiralgorithm hasacompetitiveratioofatmost(2

1
=
70)

1
:
986forall
;hencefor
m
70,theiralgorithmisprovablybetterthanListProcessing.WepresentamorenaturalalgorithmthatoutperformsListProcessingforany

6andhasacompetitiveratioofatmost1
:
945forall
,whichissignicantlyclosertothebestknownlowerboundof1
:
837fortheproblem.Weshowthatouranalysisofthealgorithmisalmosttightbypresentingalowerboundof1
:
9378onthealgorithm'scompetitiveratioforlarge
.
1Introduction
Schedulin
jobso
machinesisoneofthemostwidelystudiedproblemsincomputerscience.Oneofitsearliestandsimplestvariantsistheon-linescheduling problemintroducedbyGraham5]in1966.The
machinesareidentical,andthe
i
hassize
i
0.Thejobsarriveonebyone,andeachjomustbeimmediatelyandirrevocablyscheduledwithoutknowledgeoflaterjobs.Thesizeofajobisknowonarrival,andthejobsareexecutedonlyaftertheschedulingiscompleted.Thegoalistominimizethemakespan|thecompletiontimeofthelastjobtnish.Thisproblemisalsoreferredtoas
.
SupportedbyNSFGrantCCR-9010517,NSFYoungInvesti-gatorAwardCCR-9357849,andgrantsfromMitsubishiCorpora-tionandOTL.
compet-itiverati
.Forajobsequence

,let
(

)denotethemakespanofalgorithm
'sschedule,andlet
OP
(

)denotetheminimummakespanofall
-machinesched-ulesfor

.Thecompetitiveratioof
isdenedby
def
=su
(

)
OP
(

)
;
wherethesupremumisoverallnonemptyjobsequences.Thenaturalquestionis,howsmallcan

1
.Startingin1991,severalalgorithmsweredeveloped4,6]withbettercompetitiveratiosthanList,andrecentlBartal,Fiat,Karlo,andVohra1]gaveanalgorithm withacompetitiveratioof2

170

1
:
986.Faigle,Kern,andTuran3]provedlowerboundsontheachievabledeterministiccompetitiveratioof2

1
for
=2an3and1+
1
2
for

4(soListisoptimalfor
=2and3).Bartal,Karlo,andRabani2]improvedthislowerboundfor

4to1+
1
2
whichbecomes1
:
837for
AL

,thatismorenaturalthanthealgorithmofBar-taletal.Thealgorithm
AL

usesaparameter

thataectsitsbehavior;thebestchoiceof

dependson
.For

6,thereisan

suchthat
AL

outperformsList;furthermore,
AL
1
:
945
hasacompetitiveratioof1
:
945forall
.Figure1showsho
AL

(underthebestchoiceof

)comparestoList,Bartaletal'salgo-rithm,andtheasymptoticlowerbound.Weshowthatouranalysisof
AL

isalmosttightbypresentingalowerboundof1
:
9378onthe
1

2
Karger,Phillips,Torng
2 4 8 16 128 1024 81921.821.841.861.881.901.921.941.961.982.01.8
number of machines (log scale)ratiocompetitiveBFKV AlgorithmListLower Bound for Large mNew Algorithm
Figure1:ComparisonofouralgorithmtoList,Bartaletal'salgorithm,andtheasymptoticlowerbound competitiveratioof
AL

(foreachchoiceof

)forlarge
.
2Denitionof
AL

InordertodobetterthanList,wemustseewhatListdoeswronginitsworstcase,asequenceof
(

1) jobsofsize1followedbyonejobofsize

1small jobswhiletheoptimalscheduleassignsthelargejobtitsownmachine.TheproblemisthatListkeepstheschedulesoatthatwhenthelargejobarrivesithastgoonarelativelytallmachine.Thealgorithm
AL

hnhnk m-1 m-1o(a) Our Algorithm (b) Listo
Figure2:Schedulingmanysmalljobs,thenonebigjob Denethe
height
Definition2.1.
Tim
t
isthetimejustbeforethe
t
th
jobisscheduled.Attim
t
:
ti
isthe
(
i
+1)
st
shortestmachine(e.g.
t
0
istheshortestmachine),
ti
istheheightof
ti
(0

i<
)
,
ti
istheaverageheightofthe
i
shortestmachines,
1

i

,an
t
0
.
Notethat
t
istheaverageheightofall
ma-chinesattime
t
andisthusalowerboundonOPT.
Definition2.2.
Thealgorithm
AL

worksasfollows:whenjob
t
arrives,itisplacedonthetallestmachine
tk
suchthat
tk
t

tk
.
Theparameter

determinesthedegreeofimbal-ancethat
AL

triestomaintain.Notethatwiththeabovedenitionof
t
0
AL

whereajobcanonlybeplacedonmachine
t
0
(thesmallestmachine)orma-chine
t
;

0
:
before
after
tk
t
t
t
+1
k
0
where
0
istherankofmachine
tk
withjob
t
attime
t
+1).Furthermore,whynotcomparetheneheightofthemachinetotheaverageheightofallthemachines(i.e.compare
tk
t
t
t
+1
)?Bothofthesearebetterapproximationst
OP
(

),sotheywoulseemtobebetterchoices.However,neitheralgorithm isbetterthan(2

1
2
largejobstocreatecompletelyatschedule,afterwhichasinglelargejob makesthemakespan2

1
timestheoptimalmakespan.Inthenexttwosectionsweprovethefollowing theorem.
Theorem2.1.
Foreac

6
,thereexistssom

suchthat
AL

outperformsList,andfor


1
:
945
,
AL

is

-competitiveforall
.
3UpperBound:Fixe
Fi

6,and

,1

2.Thissectionshowshowtocomputeanupperboundonthecompetitiveratioof
AL

o
machines,byinductiononthelengthofthejobsequence.Let

beajobsequenceoflengt
,normalizedsothatthetotalsizeofall jobsi

is
(andthus
n
+1
=1).Let

n

1
betherst

1jobsi

,andassumeinductivelythat
AL

(

n

1
)

OP
(

n

1
).Therestofthissection isdevotedtoshowingthat
AL

(

)

OP
(

).Thefollowinglowerboundson
OP
(

)willbeused.
Fact3.1.
ThefollowingquantitiesareloweboundsonOPT
(

)
:1.
1
timesthetotalsizeofalljobsi

=1
).2.Thelargestjobi


n
).3.Twicethesizeofthe
(
+1)
st
largestjobi

.

ABetterAlgorithmForanAncientSchedulingProble
3If
AL

(

)
6
n
0
n
,thenthedenitionof
AL

andtheinductiveassumptioneasilyimpl
AL

(

)

OP
(

).If
AL

(

)


or
AL

(

)

n
,thenFact3.1(part(1)or(2)respectively)implies
AL

(

)


OP
(

).Therefore,fortherestofthissection,assume
AL

(

)
n
0
n
;
(3.1)
AL

(

)

;
(3.2)
AL

(

)

n
:
(3.3)Weprovethatfor

6,the(
+1)
st
largestjob i

hassizeatleast12
AL

(

)

(3.4)(forasuitablechoiceof

),whichcombinedwitFact3.1part(3)proves
AL

(

)

OP
(

).
Definition3.1.
Dene

b
1


n
0
.Den
=2


.Den
b
121

1

.Den
=1



b
.
Definition3.2.
Amachineis
tall
ifithasheightatleast
1


;otherwiseitis
short
.Let
s
bethecurrentnumberofshortmachines(s
ts
istheaverageheightoftheshortmachinesattim
t
).Ajobis
large
ifithassize

b
.
Definition3.3.
A
elevatingjob
raisesamachine frombeingshorttobeingtall,andwesaythataelevatingjob
elevates
themachineitisplacedon.
Eachmachineistallbytime
,sothereare
elevatingjobsi

.Wewillprovethatthelast jobislargeandthatalltheelevatingjobsarelarge.Lemma3.2belowshowsthatalargejobhassizeatleast
12
AL
(
)

,asrequiredby(3.4)above.Thesequence

isdividedintotwophases.Intherstphase,
ts
<
,andeachelevatingjobinthisphasemustgoonthesmallestmachineandisthereforelarge.
ts
increasesmonotonicallywit
t
untilwereachthesecondphase(calledthekickstart)when
ts

.Thekickstartisanalyzedinreverse:startingwitthelastelevatingjobi

andmovingbackwardsintime,weshowthateachelevatingjobislarge.Eventuallyatime
t
isreachedwheresomuchprocessing timeistakenbythejobsinthetallmachinesandthelaterelevatingjobsthatwemusthave
ts
<
.Thustherstphaseoftheproofappliestoallprecedingtimes.
3.1Largejobs
Lemma3.1.

satises
0
<

.Proof.
Thefactthat
0followsfrom1


n
0

n
<
n
+1
=1.Toseethat


,wehavefrom(3.1)(3.2)and(3.3)abovethat
n
0
n

n
an
n
0
n


.Therstinequalitygives
n

n
0
1

:
(3.5)Substitutingthisupperboundfor
n
intothesecond inequalitygives
n
0
(111

)

;
whichsimpliesto1


n
0

1

.
Lemma3.2.
b

12
AL
(
)

Proof.
Equation(3.5)abovegives
AL

(

)
n
0
n

n
0
(1
11

)

(1

)1

.Thelemmafollowsfrom thedenition
b
121

1

.Thusalargejobhassizeatleast
12
AL
(
)

.
Lemma3.3.
I

1

1
2

:
29
,thenjob
islarge.Proof.
Jo
raisesamachinefromheight1


tatleast

=2

,s
n

1


.Jo
islargewhenever1



121

1

.Setting

=0,theworstcase,thissimpliest

1

1
2

:
29.
3.2TheFirstPhas
Thissectionprovesthat

canbebrokenintotwphases,suchthat
ts
<
duringtherstphase,
ts

inthesecondphase,andallelevatingjobsintherstphasearelarge.
Lemma3.4.
Ifjob
t
isanelevatingjobformachine
tk
,then
tk

.Proof.
Supposejob
t
goesonmachine
tk
.Therulefor
AL

impliesthat
tk

tk
t
.Sincejob
t
isan elevatingjob,wehave
tk
t

1


.Bytransitivity,
tk

1


,s
tk

1


>
.
Lemma3.5.
Ifjob
t
isanelevatingjoband
ts
<
,thenjob
t
goesontheshortestmachine
t
0
andislarge.Proof.
Forall0
<i<s
,
ti
<
ts
<
.Therefore,byLemma3.4,elevatingjob
t
cannotgoonanyshortmachineexcepttheshortest,machine
t
0
.Since
t
0
istheshortestmachine,
t
0

ts
<
.Jo
t
isanelevatin job,s
t
0
t

1


whichimplies
t
1



b
.Therefore,job
t
islarge.
Lemma3.6.
I
t
+1
s
<
the
ts

t
+1
s
<
.Proof.
Case1:job
t
isnotelevating.
Thenumberofshortmachinesisthesameattimes
t
an
t
+1.Theonlydierencebetweentime
t
andtime
t
+1istheabsenceofjob
t
attime
t
.Therefore,
ts

t
+1
s
.

## Activity (0)

### Showing

AllMost RecentReviewsAll NotesLikes