incremental algorithms: solving …asharp/papers/thesis.pdfincremental algorithms: solving problems...

121
INCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD A Dissertation Presented to the Faculty of the Graduate School of Cornell University in Partial Fulfillment of the Requirements for the Degree of Doctor of Philosophy by Alexa Megan Sharp August 2007

Upload: vothuan

Post on 06-Apr-2018

220 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

INCREMENTAL ALGORITHMS: SOLVING PROBLEMS

IN A CHANGING WORLD

A Dissertation

Presented to the Faculty of the Graduate School

of Cornell University

in Partial Fulfillment of the Requirements for the Degree of

Doctor of Philosophy

by

Alexa Megan Sharp

August 2007

Page 2: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

c© 2007 Alexa Megan Sharp

ALL RIGHTS RESERVED

Page 3: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm
Page 4: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

INCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING

WORLD

Alexa Megan Sharp, Ph.D.

Cornell University 2007

A typical algorithm for a combinatorial optimization problem is given a static

set of input, and finds a single solution. This kind of algorithm cannot be used,

however, in situations where the input and solutions change over time due to

evolving constraints. This dissertation explores incremental problems, one class

of optimization problems that deals with this type of situation. An incremental

algorithm is given a sequence of input, and finds a sequence of solutions that build

incrementally while adapting to the changes in the input.

Online algorithms also take in a sequence of input and produce incremental

solutions; unlike their incremental counterparts, however, they do not know the

input sequence in advance. We use our incremental results to better understand

online algorithms and to indicate how their performance can be improved.

Most combinatorial optimization problems can be extended to the incremen-

tal setting. We define general incremental formulations of covering and packing

problems, and give incremental algorithms for such classes of problems. We study

specific problems in detail, such as incremental bipartite matching, network flow,

and edge cover, and find bounds on their complexity and competitiveness.

Lastly, we explore different ways to define incremental problems, and discuss

how to relax some of the constraints that limit the power of our incremental model.

Page 5: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

BIOGRAPHICAL SKETCH

Alexa Sharp, born in Ottawa, Canada on August 30, 1978, believed for many years

that she was born on the 31st. She spent her childhood in the lovely northern

capital, until her parents moved the family to Jakarta, Indonesia in 1992. Three

years and countless pineapples later, Alexa graduated from Jakarta International

School and spent her summer working the cash register at a trailer park; Alexa

hoped her math skills could be put to better use.

Thus Alexa began her six years at the University of Waterloo. After a long

string of Co-op jobs she decided that “real work” and applying one’s skills in an

industry job were overrated. Alexa received a B.Math in Computer Science and

Combinatorics and Optimization in 2001, and decided that school was cool.

For the last six years, Alexa has lived in Ithaca, New York while completing

her doctorate in computer science at Cornell University. During this time she has

acquired a niece and nephew, as well as an M.S. in Computer Science.

Alexa estimates she has run enough miles to circle the globe around the 28th

parallel, and eaten enough candy to feed, but not nourish, a small nation.

iii

Page 6: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

To Grandma,

the coolest grandma around.

iv

Page 7: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ACKNOWLEDGEMENTS

I would like to gratefully acknowledge the enthusiastic supervision of my advisor

Dexter Kozen; this work would not have been possible without his support, guid-

ance, and encouragement. I can only hope to balance work and play as he does,

ideally getting a little more sleep along the way. I would like to thank Joe Halpern,

not only for his advice on my thesis and future plans, but, also for the teaching

opportunities he provided. Special thanks to Bob Bland for participating in the

whole thesis process. From my Waterloo days, I am indebted to Serge Kruk for

providing some of my most enjoyable undergraduate courses, as well as piquing

my interest in graduate school and academia.

My research partner, Jeff Hartline, deserves props for his patience and brilliant

ideas; without him, I’m pretty sure this thesis wouldn’t exist. Our contrasting

styles made for many a lively discussion, some louder than others, all of which I

will miss terribly.

Not be overlooked are Kelly Patwell, Becky Stewart, and Stephanie Meik; ev-

erything would be 10 times harder without your help and friendship.

I cannot end without thanking my friends and family—my friends for feeding

my candy habit and putting up with my telephone delinquency, and my family

for setting the precedent of spending decades on higher education. To my parents,

thank you for not telling me what I could and could not do, or, what I should and

should not do. Your willingness to embark on new adventures will always amaze

me. To Sariya and Johnny, thank you for Ariadne and Freddie. To Sariya, thanks

for being the best sister ever, even if your sitting on me traumatized me for life.

v

Page 8: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

TABLE OF CONTENTS

1 Introduction 11.1 Model and Related Work . . . . . . . . . . . . . . . . . . . . . . . . 5

1.1.1 Incremental Problems . . . . . . . . . . . . . . . . . . . . . 51.1.2 Online Problems . . . . . . . . . . . . . . . . . . . . . . . . 61.1.3 Stochastic Problems . . . . . . . . . . . . . . . . . . . . . . 7

1.2 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81.2.1 Analysis of Online Algorithms . . . . . . . . . . . . . . . . . 81.2.2 Combinatorial Maximization Problems . . . . . . . . . . . . 91.2.3 Combinatorial Minimization Problems . . . . . . . . . . . . 101.2.4 Alternative Problem Formulations . . . . . . . . . . . . . . . 111.2.5 Model Limitations . . . . . . . . . . . . . . . . . . . . . . . 12

2 Analysis of Online Performance 132.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132.2 The Adversarial Constraint . . . . . . . . . . . . . . . . . . . . . . 162.3 The Incremental Constraint . . . . . . . . . . . . . . . . . . . . . . 172.4 A Deeper Understanding of the Competitive Ratio . . . . . . . . . . 19

2.4.1 Bipartite Matching . . . . . . . . . . . . . . . . . . . . . . . 202.4.2 Coloring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212.4.3 Steiner Tree . . . . . . . . . . . . . . . . . . . . . . . . . . . 232.4.4 Set Cover . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242.4.5 Vertex Cover . . . . . . . . . . . . . . . . . . . . . . . . . . 252.4.6 Metric k-Center . . . . . . . . . . . . . . . . . . . . . . . . . 262.4.7 Network Flow . . . . . . . . . . . . . . . . . . . . . . . . . . 27

2.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

3 Combinatorial Maximization Problems 293.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

3.1.1 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313.2 The General Model . . . . . . . . . . . . . . . . . . . . . . . . . . . 32

3.2.1 Single-Level Problems . . . . . . . . . . . . . . . . . . . . . 323.2.2 Incremental Problems . . . . . . . . . . . . . . . . . . . . . 33

3.3 Bipartite Matching . . . . . . . . . . . . . . . . . . . . . . . . . . . 343.3.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 353.3.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 36

3.4 Network Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443.4.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 463.4.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 52

3.5 Knapsack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543.5.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 553.5.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 58

vi

Page 9: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

3.6 The General Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . 593.6.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 593.6.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 60

4 Combinatorial Minimization Problems 614.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61

4.1.1 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624.2 The General Model . . . . . . . . . . . . . . . . . . . . . . . . . . . 644.3 The General Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . 654.4 Edge Cover . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

4.4.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 694.4.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 71

4.5 Minimum Cut . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 784.5.1 Aggregate Objective . . . . . . . . . . . . . . . . . . . . . . 794.5.2 Ratio Objective . . . . . . . . . . . . . . . . . . . . . . . . . 82

4.6 r-Domination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84

5 Alternative Incremental Formulations 855.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 855.2 Network Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86

5.2.1 Fractional Flow . . . . . . . . . . . . . . . . . . . . . . . . . 865.2.2 Undirected Flow . . . . . . . . . . . . . . . . . . . . . . . . 88

5.3 Minimum Spanning Tree . . . . . . . . . . . . . . . . . . . . . . . . 895.3.1 Node-Incremental Spanning Tree . . . . . . . . . . . . . . . 905.3.2 Cost-Incremental Spanning Tree . . . . . . . . . . . . . . . . 92

5.4 Edge Cover . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94

6 Algorithmic Extensions 966.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96

6.1.1 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 976.2 Probabilistic Algorithms . . . . . . . . . . . . . . . . . . . . . . . . 976.3 Relaxed Incremental Constraint . . . . . . . . . . . . . . . . . . . . 98

7 Conclusion 1017.1 Online Algorithms . . . . . . . . . . . . . . . . . . . . . . . . . . . 1017.2 Extensions to the Incremental Model . . . . . . . . . . . . . . . . . 1017.3 Other General Models . . . . . . . . . . . . . . . . . . . . . . . . . 1027.4 Correlation Clustering . . . . . . . . . . . . . . . . . . . . . . . . . 1037.5 Completing the Picture . . . . . . . . . . . . . . . . . . . . . . . . . 104

Bibliography 105

vii

Page 10: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

LIST OF TABLES

2.1 Summary of Chapter 2. . . . . . . . . . . . . . . . . . . . . . . . . 28

3.1 Main results of Chapter 3. . . . . . . . . . . . . . . . . . . . . . . . 32

4.1 Main results of Chapter 4. . . . . . . . . . . . . . . . . . . . . . . . 64

viii

Page 11: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

LIST OF FIGURES

1.1 An instance of the restaurant coverage problem. . . . . . . . . . . . 21.2 Restaurant customer base growing over 2 years. . . . . . . . . . . . 21.3 An optimal year 1 solution produces a suboptimal year 2 solution. 3

2.1 An incremental multicasting instance. . . . . . . . . . . . . . . . . 18

3.1 Incremental bipartite matching is ≤ 23-competitive. . . . . . . . . . 37

3.2 The 23-competitive algorithm is not always optimal. . . . . . . . . . 39

3.3 Incremental weighted bipartite matching is ≤ r∗M -competitive. . . . 413.4 An example of the weighted bipartite matching reduction. . . . . . 423.5 An incremental flow network. . . . . . . . . . . . . . . . . . . . . . 453.6 The clause and variable gadgets of the incremental flow reduction. 473.7 An example of the incremental flow reduction. . . . . . . . . . . . . 483.8 The hardness of approximation reduction for incremental flow. . . . 513.9 Incremental flow is ≤ 2

nd -competitive. . . . . . . . . . . . . . . . . . 523.10 The 2

n-competitive algorithm is not always optimal. . . . . . . . . . 54

3.11 Incremental flow is strictly ≤ 2n-competitive. . . . . . . . . . . . . . 55

4.1 Illustration of the general 4α-competitive covering algorithm. . . . 674.2 Solving incremental edge cover using subset edge cover. . . . . . . 714.3 Incremental edge cover is ≥ 4

3-competitive. . . . . . . . . . . . . . . 72

4.4 The 43-competitive algorithm is not always optimal. . . . . . . . . . 75

4.5 Incremental weighted edge cover is ≥ ϕ-competitive. . . . . . . . . 764.6 An example of the weighted edge cover reduction. . . . . . . . . . . 774.7 An illustration of the incremental cut reduction. . . . . . . . . . . 804.8 Incremental cut is ≥ ϕ-competitive. . . . . . . . . . . . . . . . . . 824.9 The ϕ-competitive algorithm is not always optimal. . . . . . . . . . 83

5.1 Node-incremental spanning tree is ≥ r∗n-competitive. . . . . . . . . 915.2 Cost-incremental spanning tree is ≥ r∗c -competitive. . . . . . . . . . 935.3 An example of the cost-incremental spanning tree reduction. . . . . 94

ix

Page 12: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 1

IntroductionSuppose restaurant chain X wants to expand its franchise into a new community.

Market research provides X with a projection of customer locations in the target

community; X wants to conveniently locate its franchises for these customers such

that no customer need travel more than distance r to reach an open franchise. X

also wants to minimize its operating cost by limiting the number of its restaurants.

The company’s goal is thus to open the fewest number of restaurants such that

all projected customers are within radius r of an open franchise. This is known as

the r-domination problem, a special case of (k, r)-center [6] that is well-studied in

theoretical computer science; an example is shown in Figure 1.1.

As with many conventional problems in theoretical computer science, the goal

of r-domination is to find a solution for one instant in time, that is, to determine

where to build franchises for one static set of customers. In reality, however,

we expect the customer base to grow dynamically over time, as in Figure 1.2(a).

Rather than a single static solution, we prefer a solution that adapts to cover new

customers as they arrive. The customer base is small initially, and few franchises

suffice to serve everyone. As demand increases and the customer base grows, more

franchises are necessary. Given a projection for how demand will grow annually,

where should X locate its franchises each year so that all customers are provided

for at any given time, and the number of restaurants built in the first ` years is

not much more than the minimum number needed to satisfy the year ` demand?

One approach simply uses the optimal set of franchises each year; however, this

may require a prohibitive amount of relocation and demolition, as illustrated in

1

Page 13: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

2r

2r

> 2r

(a)

2r

(b)

Figure 1.1: 1.1(a) An r-domination instance. The dots represent individual cus-

tomers in a metric space. The radius r is large enough that any one restaurant can

cover customers either vertically or horizontally aligned, but no other combina-

tions. 1.1(b) The optimal solution for this instance, where the circles of diameter

2r represent the coverage balls of radius r around open franchises.

year 1 year 2

(a)

year 1 year 2

2r

(b)

Figure 1.2: 1.2(a) Restaurant customer base growing over 2 years. 1.2(b) Using

the optimal solution each year may require restaurant relocation.

2

Page 14: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

year 1 year 2

2r

(a)

year 1 year 2

(b)

Figure 1.3: 1.3(a) A year 1 optimal solution produces a suboptimal year 2 solution.

1.3(b) A year 2 optimal solution is obtained with a suboptimal year 1 solution.

Figure 1.2(b). This leads to an additional constraint to prevent franchise removals:

once a restaurant is opened, we require it to remain open for all subsequent years.

We can now formally define the incremental r-domination problem. The input

is a client set that grows at discrete time intervals; a solution produces restaurant

locations for each year such that current customers are within radius r of some

location. As it is impractical to relocate restaurants once they are built, the set

of open franchises must increase monotonically; once built, a restaurant remains

part of the solution in perpetuity. If not for this incremental constraint, we would

simply use the optimal set of franchises at each time step; what can we do now?

One option places restaurants as best you can each year, given the restaurants

already built. This strategy is not necessarily optimal each year: Figure 1.3(a)

shows how year-one optimality can cause year-two sub-optimality. Conversely,

Figure 1.3(b) shows how year-two optimality is only achieved by sacrificing year-

one optimality.

3

Page 15: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Figures 1.3(a) and 1.3(b) thus define two feasible solutions; which is better?

For the r-domination problem, comparing solutions is straightforward—the fewer

restaurants, the better. It is no longer clear, however, how to compare the sequence

of r-domination solutions returned by an incremental algorithm.

If there is some fixed annual operating cost, such as rent or salary, then mini-

mizing net cost over all years is a reasonable goal: this is equivalent to minimizing

the sum of individual solutions over all time steps. The solutions of Figures 1.3(a)

and 1.3(b) both have a sum of 4 restaurants; thus, under this objective, both

solutions are equally good (or, equally bad). This measure, however, called the

aggregate value, fails to take balance into account. In particular, Figure 1.3(a) is

wasteful in year two, as it opens 3 franchises where 2 would suffice. Conversely,

Figure 1.3(b) is optimal at year two, but wasteful in year 1 when it uses twice as

many franchises as necessary. Under this measure, called the competitive ratio, we

conclude that the solution in Figure 1.3(a) is more balanced and thus preferable,

as its wastefulness never surpasses 32, whereas the solution in Figure 1.3(b) cannot

make the same guarantee.

Franchise expansion is only one example of an incremental problem; however,

most combinatorial optimization problems can be extended to the incremental set-

ting. Traditional algorithms can only be used in situations that require a single

static solution; incremental algorithms can be used in situations that require solu-

tions to build over time due to limited resources and rising constraints. We want

a good solution at all stages; however, a commitment at some stage may limit the

options at later stages. It is this tension between local and global optimality that

makes these incremental problems challenging.

4

Page 16: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

1.1 Model and Related Work

We now describe the incremental model in more detail. There are k time steps, or

levels, defined by a sequence of k inputs. The goal is to produce a sequence of k

outputs, one per time step, such that two constraints are satisfied. The first, known

as the feasibility constraint, requires the level ` output to be feasible with respect

to the level ` input. The second, known as the incremental constraint, requires

the level ` output to be a superset of that of level `− 1, that is, the output builds

incrementally. These two constraints define feasible incremental solutions; we can

then evaluate and compare these solutions using a variety of objective functions,

such as the aggregate value and competitive ratio objectives.

1.1.1 Incremental Problems

Recent work on incremental optimization predominantly focuses on cardinality

constrained minimization problems. Such problems specify a fixed parameter k

that designates the cardinality of feasible solutions; for example, the k-vertex cover

problem finds a set of k vertices that covers the maximum number of edges. Incre-

mental versions of these problems require solutions for all values of k such that the

`th solution contains the (`−1)st. Mettu and Plaxton [66] give a 29.86-competitive

algorithm for incremental uncapacitated k-median, Plaxton [71] gives a 12.16-

competitive algorithm for incremental facility location, and Gonzales [39] gives a

2-competitive algorithm for incremental k-center, also studied by [66, 71, 64, 21].

Lin et al. [64] use a general framework for cardinality constrained problems to

study all such problems at once; this results in competitive algorithms for incre-

mental k-vertex cover, k-set cover, k-median, k-spanning tree, and facility location.

5

Page 17: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

The franchise expansion problem, however, motivates an alternative approach

to incremental optimization that is the subject of this dissertation. Specifically, the

incremental aspect of the franchise problem is driven by a growing customer base,

as opposed to a parameter increasing the number of restaurants to build. Thus

rather than require solutions to be of a specific cardinality, we require feasibility

in a more general sense, such as covering or packing a certain set of items.

1.1.2 Online Problems

The online and incremental models share many similarities. For both frameworks,

the input arrives over time and solutions build incrementally; the main difference

is that online algorithms have no knowledge of the input sequence [11, 25] whereas

incremental algorithms have complete knowledge.

The performance of an online algorithm, as measured by its competitive ratio

[74], is influenced by two principle factors. The first factor is that online algo-

rithms have no knowledge of future input, and thus an adversary may select input

sequences that prevent an algorithm from obtaining a good competitive ratio; this

is the adversarial constraint. The second factor is that online solutions are con-

strained to keep all intermediate solutions, and it may not be possible to obtain

reasonable solutions at each level while simultaneously guaranteeing a final solu-

tion with good competitive ratio; this is the incremental constraint. Both these

factors may contribute to an algorithm’s performance, but the competitive ratio

fails to distinguish the two. In contrast, incremental problems are only hampered

by the incremental constraint, and are thus the offline versions of online problems.

The concept of online algorithms has been around for some time, but Sleator

and Tarjan were the first to define and study them formally [74]. They have been

6

Page 18: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

considered in many contexts, including graph coloring [42], bipartite matching [58],

Steiner tree [2, 67], set cover [1], and monotone set systems [55].

1.1.3 Stochastic Problems

Both the online and incremental models require an incremental solution based on

a sequence of changing input, however, they differ in their level of foresight: the

former has no knowledge of future input, whereas the latter has perfect knowledge.

The stochastic model offers a compromise between these two extremes by assuming

its input is drawn from some known probability distribution.

Thus the stochastic model has as a sequence of input, drawn from a known

probability distribution, and must produce an incremental solution. The perfor-

mance evaluation of a stochastic algorithm is a little different than that of online

and incremental models. Rather, the goal of a stochastic problem is to optimize

the expected value of some function G(x, ω) over all feasible solutions x, where ω

is an abstract probability space representing the stochastic aspects of the problem.

The most widely studied stochastic models are two-stage linear programs, that

is, G(x, ω) is a linear function and the set of feasible solutions can be described by

a finite set of linear constraints. Here the algorithm makes some decision in the

first stage, after which a random event occurs affecting the quality of the decision.

A second decision must then be made in the second stage that does as best it can

in expectation, given the first-stage decision.

Applications of stochastic optimization include portfolio optimization [20, 79],

power generation [22, 13], pollution control [7, 32, 31], and airline scheduling [8].

7

Page 19: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

1.2 Results

1.2.1 Analysis of Online Algorithms

As mentioned in Section 1.1.2, the adversarial constraint, or lack of foresight,

can affect the quality of an online solution. For many online problems, however,

knowing the input sequence in advance still does not yield 1-competitive solutions;

there is a second factor affecting the algorithm’s performance. This factor is the

incremental constraint, that is, the requirement that solutions build incrementally.

Incremental problems are also affected by the incremental constraint, but not the

adversarial constraint, as they know the input sequence in advance. We can there-

fore use a problem’s incremental results to determine how to best improve the

online problem’s competitiveness. If the performance gap between a problem’s

online and incremental results is large then we conclude the adversarial constraint

is the dominating factor. In this case, better predictions of the input sequence can

drastically improve the online algorithm’s performance. Conversely, if the gap is

small then we conclude the adversarial constraint does not significantly contribute

to the competitive ratio of the problem, but rather the incremental constraint is

at fault. In this case, better estimates of future input are unlikely to yield better

performance; our only hope is a better incremental algorithm.

For many classic online problems, such as paging, k-server, and list-update,

removing the adversarial constraint allows 1-competitive solutions, and our incre-

mental results give no further insight. There are, however, many online problems

for which this is not the case, such as online bipartite matching, Steiner tree, ver-

tex cover, and k-center. Chapter 2 uses the incremental results of these problems

and others to obtain new insight into their online performance.

8

Page 20: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

1.2.2 Combinatorial Maximization Problems

The goal of many combinatorial maximization problems is to select a maximum-

value subset of items subject to constraints that limit certain items from being

selected simultaneously. For example, the independent set problem on a graph

finds a maximum subset of vertices such that no two selected vertices are adjacent.

Chapter 3 defines a general incremental formulation of such problems, in which

some of the constraints relax over time. The goal is to find a sequence of feasible

solutions, one per time step, such that later solutions build on earlier solutions

incrementally. We also define incremental versions of individual maximization

problems such as network flow, bipartite matching, and knapsack.

The incremental version of an NP-hard problem contains its non-incremental

version as a special case and is therefore also NP-hard; in contrast, the incremen-

tal version of a polynomial-time problem is not necessarily polynomial-time. In

particular, incremental bipartite matching remains polynomial-time in many cases

but becomes NP-hard in others, whereas incremental flow is NP-hard even for

very basic models. To the best of our knowledge, this is the first instance of a

polynomial-time problem whose incremental version is NP-hard.

Thus the incremental constraint can affect a problem’s complexity; it can also

affect its competitiveness. We determine that incremental bipartite matching is 23-

competitive and strictly 12-competitive; moreover, these bounds are tight. We find

that incremental flow is 2n- and strictly 2

n-competitive; these bounds are almost

tight. Lastly, we find that knapsack has an arbitrarily bad competitive ratio;

however, an algorithm exists that (1− ε)-approximates its ratio for any ε > 0.

These three problems fit the model of packing problems, a large class of combi-

natorial maximization problems. We use our general incremental model to give gen-

9

Page 21: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

eral techniques that translate exact or approximate algorithms for non-incremental

packing problems into decent algorithms for their corresponding incremental defi-

nitions. The algorithm is tight for network flow, but can be improved for bipartite

matching and knapsack. Table 3.1 gives a summary of the maximization results.

1.2.3 Combinatorial Minimization Problems

The goal of many combinatorial minimization problems is to select a minimum-

cost subset of items that collectively achieve a certain objective [60]. For example,

the vertex cover problem finds a minimum subset of vertices such that at least one

endpoint of every edge is in the selected set.

Chapter 4 defines a general incremental model of covering problems, a large

class of minimization problems, in which the collective objective changes over time.

The goal is to find a sequence of feasible solutions, one per time step, such that

later solutions build on earlier solutions incrementally. We introduce incremental

versions of the edge cover and network cut problems, and analyze their complexity

with respect to the competitive ratio and aggregate value objective functions. We

find that, as with bipartite matching and network flow, incremental edge cover

remains polynomial-time in many cases, whereas incremental cut is NP-hard.

In contrast, the competitiveness results are not analogous to those of the pack-

ing problems. More specifically, we determine that edge cover is 43-competitive

and strictly 32-competitive; the 4

3bound is tight. We find that incremental cut is

ϕ-competitive, where ϕ is the golden ratio1, and this bound is tight.

As with packing problems, we describe a general technique to translate exact

or approximate algorithms for covering problems into decent algorithms for their

1The golden ratio is the solution to ϕ = ϕ2 − 1, or approximately 1.6.

10

Page 22: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

corresponding incremental versions. In particular, given an α-approximation for

a covering problem, we present a 4α-approximation for its incremental version for

both the ratio and aggregate objectives. This is more efficient and more general

than the O( αlog k

)-approximation to the aggregate value of incremental packing

problems. The minimization results are shown in Table 4.1.

1.2.4 Alternative Problem Formulations

A combinatorial optimization problem may have several different incremental for-

mulations; not only are alternative definitions of practical interest, they can also

admit different complexity and competitiveness results.

There are two steps to constructing an incremental problem. We must first

decide which single-level problem to use as our basis, and then which parameter

to change over time. For example, the network flow problem has many variations,

such as fractional and undirected flow; the incremental problems differ greatly

depending on which problem we choose as our basis. Varying the incremental

parameters can have a similar effect; for example, the incremental r-domination

problem has the customers arriving over time; however, an equally appealing model

has the cost of each location increasing. Both formulations seem reasonable, and

yet the choice could lead to different performance results.

These two decisions can produce a wide variety of problems suiting different

situations. In Chapter 5 we look at two examples of the first decision by studying

incremental versions of undirected and fractional flow; we also consider two exam-

ples of the second decision by studying incremental versions of minimum spanning

tree and edge cover. We find that the complexity and competitiveness of a problem

varies depending on how we make these decisions.

11

Page 23: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

1.2.5 Model Limitations

The incremental model is by no means perfect. Upon first glance, knowledge of

the input sequence may seem implausible, but in many situations it is available or

reasonable to expect. For example, it is unlikely that company X would expand

business into a new area without some idea of where their customers are likely

to be located. More importantly, though, this assumption allows us to better

understand the online model, a connection explored in Chapter 2.

The incremental constraint, requiring solutions to build up over time, may also

seem somewhat rigid. For example, if a certain restaurant location is incurring big

losses then it may be better to close it and open a more profitable restaurant nearby.

We cannot remove the constraint altogether, however, and allow restaurants to

relocate indiscriminately—it is necessary in situations where there is an implicit

cost associated with changing the solution from one interval to the next. Perhaps

a more realistic model would allow violations of the incremental constraint, but

at the expense of a penalty (say, charging a demolition cost in the case of the

restaurant expansion). We briefly consider such a model in Chapter 6.

Finally, the feasibility constraint, which requires the interval ` solution to be

feasible with respect to the interval ` input, may seem strict. For example, a

customer situated over distance 2r from any other will be serviced by a restaurant

covering just this customer—not a likely profitable strategy. This is not really an

issue with the incremental model, however, but rather with the underlying non-

incremental problem (in this case, r-domination). We could study a relaxation

that allows violations of the feasibility constraint at the cost of a penalty, as with

facility location with outliers [17]; however, this is really studying the incremental

version of a relaxed problem, not a relaxed version of the incremental problem.

12

Page 24: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 2

Analysis of Online Performance

2.1 Introduction

Traditional algorithm design assumes we know the input in advance, allowing us

to process this input as a whole to produce output optimizing a given objective

function. This is a reasonable framework in many contexts; however, there are

practical situations in which the algorithm does not have full knowledge of the

input, but must make partial decisions about the output as the input is revealed.

A standard example of this situation is the ski rental problem. In this scenario,

you are in need of some skis. You could rent the skis for r dollars, or buy them

for b > r dollars. Unfortunately, you are not sure how many times you will need

skis in the future; if you knew this value, k say, then minimizing your cost would

be simple: you would buy skis if b ≤ kr and rent otherwise. Instead, each time

you ski, you must decide whether to rent or buy without knowing how many more

opportunities to ski you will have. This lack of foresight can have an adverse effect:

if you buy on the first day and never ski again, you spend b dollars when r would

suffice. If you only rent, however, and you find yourself skiing often, you will again

spend more than necessary. How do you balance these factors in finding a solution

that determines whether you should rent or buy on any given day?

Algorithms that make their decisions gradually as unknown data arrive are

called online algorithms. The concept of online algorithms has been around since

the seventies in the bin packing literature [54, 78], but Sleator and Tarjan were

the first to define and study them formally [74]. There are many problems one

naturally encounters in this type of setting, including the following three.

13

Page 25: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

The k-server Problem. Suppose we have a news service with k reporters. When

a newsworthy event occurs somewhere in the country, one reporter is selected to go

on location to cover the story. When another event occurs, some reporter, perhaps

the same one, is selected to cover this next story at its location. The events must

be covered in order, and the service does not know in advance how many events

will occur where. Our goal is to minimize the sum of distances the reporters must

travel, over all event requests. An online algorithm for this problem decides which

reporter to dispatch to each new event, without any information on the location

or number of subsequent events.

The Paging Problem. Suppose we have a two-level memory cache divided into

pages of fixed size. There are k pages in fast memory; the remaining pages are in

slow memory. When a page p is requested, if it is not in fast memory (a page fault)

then the system must decide which page in fast memory to swap out to make room

for p. Our goal is to minimize the number of page faults over all page requests. An

online algorithm for this problem decides which page to evict from fast memory

on each page fault, without any information on the subsequent page requests.

The Multicasting Problem. Suppose we have a multicast group in a computer

network. Multicast protocols involve the distribution of the same information

stream to all members of a multicast group. We want to select communication

links so as to minimize the cost of supporting multicast routing through a tree.

When a new member is added to the multicast group, we need to add links to our

tree to connect the new member inexpensively. Our goal is to minimize the cost of

the tree over all member additions. An online algorithm for this problem decides

which links to add to the tree for each new member, without any information on

the subsequent member additions.

14

Page 26: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

In each of these cases, we are in a situation where any online algorithm will

make suboptimal decisions at times. How should we evaluate this algorithm’s

performance? One possibility is to assume the input is given according to a certain

probability distribution, and analyze the algorithm’s expected performance with

respect to this distribution; this sort of analysis is done in stochastic optimization.

If we wish to avoid making assumptions about the input distribution, however, then

we use a different measure that compares the performance of an online algorithm

with that of the best offline algorithm, that is, an algorithm that knows the future.

This notion of comparison is called competitive analysis and was introduced by

Sleator and Tarjan [74].

Definition 2.1 An online algorithm A is α-competitive if there exists some con-

stant c such that for all input sequences σ,

vA(σ) ≤ α · vOPT (σ) + c,

where vA(σ) is the cost of the online strategy A for σ and vOPT (σ) is the cost of

the optimal offline algorithm for σ.

Thus, an α-competitive algorithm A has cost no worse than α times that of

the optimal offline algorithm plus some c initial advantage given to the optimal

algorithm based on the problem setup. The constant c can be considered a “startup

cost” of the online algorithm. An algorithm is considered strictly α-competitive if

it is α-competitive with the constant c = 0.

Note that Definition 2.1 is for minimization problems, whose goal is to minimize

the cost vA(σ); we easily define the analogous concept for maximization problems

by requiring vA(σ) ≥ α · vOPT (σ)− c.

15

Page 27: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Let us now reconsider the ski rental problem in light of the above definition.

The input σ is a sequence of an unknown number of ski opportunities. The strategy

of buying on the first day is br-competitive in the worst-case scenario when |σ| = 1.

A different strategy may rent for the first br− 1 days and then buy on day b

r. If

|σ| < br

then the online and optimal offline strategies are the same; if |σ| ≥ br

then

the online strategy costs r · ( br− 1) + b = 2b − r and the optimal offline strategy

costs b. Hence this algorithm is (2− rb)-competitive; moreover, it is known that no

online algorithm can do any better.

2.2 The Adversarial Constraint

It is often helpful to view competitiveness as a game between the online algorithm A

and the optimal offline algorithm OPT . The adversary OPT makes the first move

by selecting the first input σ1, which player A has to process. The adversary then

selects his second move σ2, which A must process, and so on. The adversary knows

A’s strategy ahead of time, which allows him to simulate the game in advance and

therefore find and play very bad input sequences for A.

Introducing randomization into A’s algorithm can help weaken the adversary

in this respect, but cannot eliminate his power altogether. Obviously, not knowing

the future can make it challenging for an algorithm to achieve a good competitive

ratio. This motivates the introduction of the following definition.

Definition 2.2 The adversarial constraint is the constraint imposed on an online

algorithm by not knowing the input sequence in advance.

In many ways, competitive analysis is concerned with determining what effect

the adversarial constraint has on the competitive ratio of a problem. For exam-

16

Page 28: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ple, the (2 − rb)-competitive algorithm for the ski rental problem reveals that the

adversarial constraint can affect the quality of a solution by at most a factor of

2 − rb. Similarly, the least-recently-used k-competitive algorithm for the paging

problem [38] suggests that the adversarial constraint can affect the quality of an

online paging solution by at most a factor of k.

These two observations are ‘positive’ in the sense that they bound the pos-

sible detrimental effect of the adversarial constraint. We can get corresponding

‘negative’ results that lower-bound the effect of the adversarial constraint. For

example, it is known that for each online paging algorithm A, there is a sequence

of requests σA = σA1 · · ·σA

n such that vA(σA) ≥ k · vOPT (σA) [38]. This implies that

the adversarial constraint affects the quality of any online solution to the paging

problem by at least a factor of k.

2.3 The Incremental Constraint

Section 2.2 demonstrates how the adversarial constraint, or lack of foresight, can

affect the quality of an online solution. If this were the only factor, then knowing

the future would admit a 1-competitive solution. For many problems, however,

this is not the case; there is another factor contributing to the competitive ratio.

Online algorithms must build up their solutions as input arrives, in such a way

that all solutions along the way are competitive. It may not be possible, however,

to obtain reasonable solutions for each input subsequence while simultaneously

guaranteeing a final solution with good competitive ratio. In other words, if we

were allowed to change our solution at each step, rather than build on the previous

solution, we could possibly achieve a better performance. For example, consider

the multicasting instance in Figure 2.1. An online algorithm does not know the

17

Page 29: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

sequence of members it will need to connect, and it must build up its solution

greedily, in the sense that it cannot reverse previous decisions. Even if the al-

gorithm knows the input sequence in advance, however, it still cannot obtain an

optimal solution at each step, that is, a 1-competitive solution, without modifying

previous solutions. This motivates the introduction of the following definition.

1

1 1

v1

v2 v3

1 + ε

2

2w

(a)

1

1 1

v1

v2 v3

1 + ε

2

2w

(b)

1

1 1

v1

v2 v3

1 + ε

2

2w

(c)

Figure 2.1: 2.1(a) A multicast network with 3 members arriving in the order

v1, v2, v3. 2.1(b) shows the optimal offline solution of cost 3 in bold edges. 2.1(c)

shows its sub-solution for v1, v2, of cost 2, whereas the optimal costs 1 + ε.

Definition 2.3 The incremental constraint is the constraint imposed on an online

algorithm by requiring its solution to build on itself over the input sequence.

For many classic online problems, such as ski rental, paging, k-server, portfolio

selection, and list-update, the incremental constraint is implicitly contained in the

offline problem. That is, the offline problems are also required to make irreversible

decisions over time as input is revealed; they only differ from their online versions

because the sequence of input is known in advance. For example, the offline paging

problem still requires you to make a decision as each new request arrives, and you

cannot reverse a paging decision once it is made. For these problems, removing

the adversarial constraint allows for 1-competitive solutions.

There are, however, many online problems whose offline versions are not incre-

mentally constrained. In particular, the offline problems not only know all future

18

Page 30: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

requests, but also can be completely different at each step; they contain neither

the adversarial nor the incremental constraint. The multicasting problem is one

such example, where it may not be possible to obtain the optimal offline solution

at each step and still satisfy the incremental constraint. Thus the online and offline

problems differ by both the adversarial and incremental constraints.

As with the adversarial constraint, we can analyze how the incremental con-

straint affects the competitive ratio. For a problem whose offline version is already

incremental, the incremental constraint has no effect on its competitiveness. For

the other problems, however, the analysis is more revealing. For example, the gen-

eral 4α-competitive algorithm for incremental covering problems (Theorem 4.2)

shows that the incremental constraint adds at most a constant factor to the per-

formance of any online covering problem.

2.4 A Deeper Understanding of the Competitive Ratio

Now that we have defined the adversarial and incremental constraints, we can

take another look at the competitive ratio. Both constraints may contribute to

an algorithm’s poor performance, but the competitive ratio fails to discern which

is more significant. In contrast, incremental problems are only hampered by the

incremental constraint; they are online problems with knowledge of future input,

and in this sense can be viewed as the offline version of online problems. We can

therefore use an incremental problem’s ratio results to determine which constraint

contributes more to the competitiveness of an online problem. If the performance

gap between an online and incremental problem is large then we conclude the ad-

versarial constraint is a dominating factor. In this case, resources should not be

wasted investigating improved online algorithms, but instead should be spent de-

19

Page 31: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

veloping better predictions of future input to counteract the adversarial constraint;

even if the online algorithm is tight, it is possible to improve its performance in

this way. On the other hand, if the performance gap is small then we conclude the

adversarial constraint does not contribute significantly to the competitive ratio of

the problem, but rather the incremental constraint is at fault. In this case, better

estimates of future input are unlikely to yield better performance; our only hope

is a better incremental algorithm.

For problems such as paging, k-server, and ski rental, whose offline formu-

loations implicitly contain the incremental constraint, their current competitive

analysis is solely affected by the adversarial constraint, and no further insight is

obtained with any incremental results. For the large number of problems whose

offline formulations do not contain the incremental constraint, however, we can

obtain some interesting new understanding. The next few sections discuss seven

such problems in more detail, largely referencing and comparing existing online

and incremental results from both inside and outside this dissertation.

2.4.1 Bipartite Matching

Given a bipartite graph G = (V, E), the bipartite matching problem finds a max-

imum matching in G, that is, a maximum set of edges M ⊆ E such that no two

edges of M share a common endpoint. Bipartite matching is a well-studied prob-

lem in both computer science and mathematics, and has applications ranging from

computer graphics to job assignment; it can be solved in polynomial time using

maximum flow and other techniques. In online bipartite matching [58], the edges

of G arrive in some unknown order and the goal is to decide, as the edges arrive,

which edges to use in the matching so that the size of the matching is maximized.

20

Page 32: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Karp et al. give a tight 12-competitive algorithm for the online bipartite matching

problem [58]. Incremental bipartite matching, presented in detail in Chapter 3, is

quite similar to the online case; the order of edge arrival is known in advance, and

the goal is to decide, as the edges arrive, which edges to use in the matching.

Bipartite matching belongs to the class of packing problem discussed in Chapter

3. Theorems 3.2, 3.3, and 3.4 show there is a tight 23-competitive algorithm for

incremental bipartite matching, and this algorithm is optimal, in that it achieves

the best possible competitive ratio on each incremental input.

Considering the similarity between online and incremental bipartite matching,

this result is actually quite revealing. Recall the two factors that contribute to

the competitive ratio of an online problem: the incremental and adversarial con-

straints. The performance gap between the online and incremental versions of

bipartite matching allows us to understand how these factors contribute to the

competitive ratio of online bipartite matching. In particular, there are instances

for which we could be at least 23-competitive, but the adversarial constraint lim-

its us to 12-competitive. Therefore, if we wish to improve an online algorithm’s

performance, getting better estimates of future input is a good start. However,

even the best estimates can at best improve its competitiveness to 23. Thus both

the incremental and adversarial constraints contribute to the online algorithm’s

performance, and the incremental results allow us to quantify this contribution.

2.4.2 Coloring

Given a graph G = (V, E), the minimum coloring problem finds a coloring of G

with the fewest colors, that is, an assignment f : V → C of colors to vertices such

that adjacent vertices are assigned different colors and |C| is minimized. The min-

21

Page 33: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

imum coloring problem, along with other variations and generalizations, has been

studied extensively in both computer science and mathematics [10, 26, 9, 77, 18]

and is NP-complete [34]. Its applications range from frequency assignment [33] and

register allocation [14, 15, 12] to circuit board testing [35] and time table schedul-

ing [63]. The best-known polynomial-time algorithm for approximate minimum

coloring is currently a O(n(log log n)2

log3 n)-approximation due to Halldorsson [43].

The definition of online graph coloring arises by placing restrictions on how an

algorithm is allowed to process the input graph [44, 45, 59]. An online coloring

of a graph G is a coloring assigned to G by coloring its vertices in some unknown

order v1, v2, . . . , vn. The color of vi is assigned by only looking at the subgraph

of G induced by v1, v2, . . . , vi, and the assigned color of vi is never changed.

Halldorsson and Szegedy [45] show that any deterministic online coloring algorithm

has competitive ratio at least 2nlog2 n

. The incremental coloring problem is the same

as the online version, except the order of the vertices is known in advance.

Although minimum coloring does not belong to the class of covering problems

discussed in Chapter 4, it still exhibits a useful modified monotonicity property. If

f and f ′ are feasible colorings of G and G′ ⊆ G, respectively, then there exists a

feasible coloring g of G using at most |f |+ |f ′| colors that agrees with f ′ on G′. In

other words, we can augment the coloring f ′ of G′ to a coloring of G using at most

|f | additional colors. For the purpose of the proofs and algorithms given in Theo-

rem 4.2, this modified monotonicity property suffices, and therefore Theorem 4.2

gives a O(n(log log n)2

log3 n)-competitive algorithm for the incremental coloring problem.

Thus there is a performance gap between online and incremental coloring; there

are instances of online coloring for which any algorithm has competitive ratio at

least 2nlog2 n

, however, the removal of the adversarial constraint admits a competitive

22

Page 34: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ratio of O(n(log log n)2

log3 n). Thus there are online instances for which the adversarial

constraint contributes at least a factor of log n(log log n)2

to the competitive ratio, and

better estimates of future input would improve any online algorithm’s performance.

2.4.3 Steiner Tree

Given an undirected graph G = (V, E) with edge weights and terminal set T ⊆ V ,

the Steiner tree problem finds a minimum-cost tree that spans all of T . This is

precisely the multicast problem of Section 2.1, and is NP-complete [34]; the best-

known polynomial-time algorithm for Steiner tree is a 1.55-approximation [73]. In

online Steiner tree, terminal nodes arrive one at a time and the solution tree is

expanded in discrete steps to include each new terminal [2, 67]. Alon and Azar

[2] show an almost tight lower bound of Ω( log nlog log n

) for the competitive ratio of

any online algorithm for Steiner Tree. Incremental Steiner tree is the same as the

online case except the sequence of terminal nodes is known in advance.

As with minimum coloring, Steiner tree is a minimization problem that does

not quite fit the covering model of Chapter 4 because it is not monotonic; solutions

are required to be minimal, and therefore supersets of feasible solutions are not

necessarily feasible (that is, supersets of trees aren’t necessarily trees). However,

if S is a Steiner tree for terminals T , and S ′ is a Steiner tree for T ′ ⊆ T , then

there exists a Steiner tree U of T such that S ′ ⊆ U ⊆ S ′ ∪ S, that is, we can

augment the solution S ′ into a Steiner tree for T using only elements from S;

furthermore, v(U) ≤ v(S ′) + v(S). For the proofs and algorithms of Theorem 4.2,

this modified monotonicity property suffices, and therefore Theorem 4.2 gives a

(4 · 1.55)-competitive algorithm for the incremental Steiner tree problem.

The performance gap between incremental and online Steiner tree reveals that

23

Page 35: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

the performance of the latter has little to do with the incremental constraint.

Whereas online Steiner tree cannot be better than Ω( log nlog log n

)-competitive, incre-

mental Steiner tree has constant competitiveness. Thus there are incremental in-

stances for which the addition of the adversarial constraint pushes any algorithm’s

performance from constant to Ω( log nlog log n

). This is an example of a problem for which

better estimates of future input would significantly improve competitiveness.

2.4.4 Set Cover

Given a set X of n elements and a family of m subsets S ⊆ 2X , the set cover

problem finds the minimum number of subsets of S such that their union is X.

Set cover is an NP-hard problem studied extensively in the literature; the best-

known polynomial-time algorithm is a Θ(log n)-approximation [19, 24, 53, 65]. In

online set cover, some set X ′ ⊆ X of the elements are given to the algorithm

one-by-one, and the algorithm must cover the new elements with sets of S as the

elements appear. It is assumed that the set cover instance (that is, the elements

of X and the members of S) is known in advance to the algorithm, although the

set X ′ is not. Alon et al. [1] show that for all interesting values of m and n, the

competitive ratio of any deterministic online algorithm for the online set cover

problem is at least Ω( log n log mlog log m+log log n

). Incremental set cover is the same as online

set cover, except the set X ′, and the order in which it appears, is known in advance.

Set cover is a covering problem as defined in Chapter 4; therefore, by Theorem

4.2, there is a Θ(log n)-competitive algorithm for incremental set cover.

The performance gap between incremental and online set cover reveals that the

performance of the latter is predominantly influenced by the adversarial constraint;

the incremental constraint adds at most a factor of 4 to the competitive ratio, yet

24

Page 36: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

there are instances for which the adversarial constraint contributes a factor of

log mlog log m+log log n

. Therefore the best way to improve the performance of an online

set cover algorithm is to get better estimates for its future input.

2.4.5 Vertex Cover

Given a graph G = (V, E), the vertex cover problem finds a minimum vertex cover

in G, that is, a minimum set of vertices V ′ ⊆ V such that at least one endpoint of

every edge is in V ′. Vertex cover is a well-studied problem in theoretical computer

science, and is NP-complete [34]. The best-known polynomial-time algorithm for

vertex cover is a (2− log log n2 log n

)-approximation due to Monien and Speckenmeyer [68];

it cannot be approximated within 1.1666 for any sufficiently large vertex degree

[49]. There is, however, a simple 2-approximation that selects both endpoints of

any edge for the cover, removes the endpoints from the graph and repeats.

In the online vertex cover problem, the edges of E appear over time (all vertices

V are known at the outset) and the algorithm must cover the edges as they appear.

Note that the simple 2-approximation is in fact a 2-competitive algorithm for the

online problem. In the incremental vertex cover problem, the edges of E are

also appearing over time, however, the sequence is known in advance. Again, the

simple 2-approximation is a 2-competitive incremental algorithm; no incremental

algorithm is better than 1.1666-competitive.

The fact that incremental vertex cover is no less than 1.1666-competitive, and

online vertex cover is at most 2-competitive allows us to bound the effect of the

adversarial constraint; there are instances of online vertex cover for which the

incremental constraint contributes at least a factor of 1.1666 to the competitive

ratio, and yet the incremental and adversarial constraints combined contribute at

25

Page 37: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

most a factor of 2. Thus better estimates of the future may help, but they can at

best improve an online algorithm’s competitiveness from 2 to 1.1666.

2.4.6 Metric k-Center

Given a set of n points in a metric space, the k-center problem selects k of these

points as centers such that the radius, that is, the maximum distance from any

point to its closest center, is minimized. The k-center problem is one example of

a cardinality constrained location problem, and is known to be NP-complete [34].

The best-known polynomial-time algorithm is a 2-approximation due to Gonzalez

[39]; moreover, it is not approximable within 2 − ε for any ε > 0 [50, 72]. Online

center has the same input as k-center, except that k is not specified; that is, the

number of centers is not known in advance. Rather, the number of selected centers

is the parameter that is increasing over time, as with the ski rental problem.

The goal of the online problem is to select a sequence of centers such that the

centers selected at any point in the sequence yield a small radius. Gonzalez’ 2-

approximation is also a 2-competitive algorithm for online center.

The incremental center problem [64] knows the parameter k in advance; how-

ever, it is not equivalent to the offline k-center problem. The incremental version

finds a sequence of k centers such that the radius of the first ` centers is close to

that of the optimal ` centers, for each ` ≤ k. In contrast, the offline problem is

not concerned with finding a solution that is good at each stage, but rather wants

the best k-center solution.

Once again, Gonzalez’ 2-approximation is a 2-competitive incremental algo-

rithm; furthermore, incremental center cannot have a (2−ε)-competitive algorithm

for any ε > 0, because of the offline k-center result. Thus the adversarial constraint

26

Page 38: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

does not affect the competitiveness of an online algorithm; knowing the sequence

of input in advance will not improve the quality of your algorithm.

2.4.7 Network Flow

Given a directed network G = (V, E) with source s, sink t, and capacity function

c : E → Q, the maximum flow problem finds the maximum s-t flow f : E → Q in

G. Network flow is a well-studied problem in computer science and can be solved

in polynomial time. The online flow problem can be defined in many ways, as

discussed in Chapter 5, but here we consider the model where the edge capacities

increase over time, and the goal is to decide, as the capacities increase, how to

send more flow from s to t. The algorithm of Theorem 3.19 achieves a strict 2n-

competitive ratio, where n = |V |. Incremental flow, discussed in detail in Chapter

3, is the same as online flow, except the sequence of capacity functions is known

in advance. Theorem 3.19 gives a strictly 2n-competitive algorithm for incremental

flow, and Theorem 3.21 shows no incremental algorithm can do any better.

These results allow us to absolve the adversarial constraint, as the online algo-

rithm achieves the best performance possible for any incremental solution; more-

over, the incremental constraint is a major factor. Thus online flow is an example

of a problem for which better estimates of future input will not help online perfor-

mance, and attempts to find a better algorithm will also fail.

2.5 Summary

The problems discussed in Section 2.4 give a broad spectrum of competitive ratio

analysis. Table 2.1 summarizes how each constraint contributes to the performance

of the individual problems.

27

Page 39: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Table 2.1: How the adversarial and incremental constraints contribute to the per-

formance of the problems discussed in Section 2.4.

Constraint Contribution

Problems Adversarial Incremental

paging, k-server yes no

bipartite matching yes yes

coloring yes yes

Steiner tree yes not much

set cover yes not much

vertex cover yes not much

metric k-center no yes

strictly competitive flow no yes

any problem with 1-competitive online alg no no

28

Page 40: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 3

Combinatorial Maximization Problems

3.1 Introduction

The goal of many combinatorial maximization problems is to select a maximum-

value subset of items subject to constraints that limit certain items from being

selected simultaneously. For example, consider routing a message from a source to

a destination in an untrusted network. Adversaries within the network must inter-

cept all components of a message in order to decipher it; therefore, it is desirable

to divide the message among many node-disjoint paths [23]. Selecting more paths

not only increases security, but also preserves power at the internal router nodes by

preventing individual routers from depleting their battery faster than their neigh-

bors. Thus the goal is to select a maximum number of source-destination routing

paths subject to constraints prohibiting any two paths from sharing a node.

We consider an incremental version of such maximization problems, in which

some of the constraints relax over time at discrete time intervals. The goal is to

find a sequence of feasible solutions, one per time step, such that later solutions

build on earlier solutions incrementally. One wants the best solution at each step,

subject to the constraint that elements in the current solution cannot be removed.

In terms of the routing problem, suppose the underlying network changes over

time as new routers and links appear. We still want as many node-disjoint paths

as possible, but would rather not reprogram the routers. More specifically, we do

not want to change any existing node-disjoint path. We would like a good solution

at all stages; however, a commitment early on may limit the options later.

The routing problem is an application of incremental flow, defined on a network

29

Page 41: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

with a source s, sink t, and a non-decreasing sequence of capacity functions, one

per time step. The goal is to find a sequence of s-t flows such that each flow obeys

its corresponding capacity constraints and does not remove flow from any prior

solution. Whereas determining the quality of a network flow solution is straight-

forward (the more flow, the better), it is not clear how to evaluate the quality of

an incremental flow solution. We propose two natural objective functions.

The first objective is analogous to the competitive ratio of online problems. For

each time step `, we compare the value of the current flow to that of the optimal

flow satisfying the `th capacity constraints. We want this ratio to be close to 1, but

because we must keep all flow from previous time steps, this may not be possible.

Therefore our goal is to find a sequence of flows that maximizes the minimum of

this ratio over all values of `. An algorithm for this problem is α-competitive if

this minimum ratio is no less than α.

The second objective is concerned less with performance at each time step and

more with performance overall. It does this by maximizing the weighted sum of

the solutions over all time steps for any set of weights given as parameters. This

allows us to disregard the occasional bad solution, provided that we are sufficiently

compensated at other steps. In our routing example, this objective would enable

us to maximize throughput over all time steps. An algorithm is σ-aggregate if the

weighted sum of its solutions is at least σ.

We can formulate incremental versions of combinatorial maximization problems

other than network flow. Incremental bipartite matching is defined on a bipartite

graph whose edges appear over time; a solution is a sequence of matchings, one per

time step, such that each matching in the sequence contains all previous matchings.

Incremental knapsack is defined by a set of items and a knapsack capacity that is

30

Page 42: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

increasing over time; a solution is a sequence of knapsack packings such that each

packing in the sequence contains all items from the previous packing.

3.1.1 Results

The incremental version of an NP-hard problem contains its non-incremental ver-

sion as a special case and is therefore also NP-hard. Does the incremental version

of a polynomial-time problem remain polynomial-time, or does the incremental

structure alter its complexity? We find that imposing an incremental structure

on a problem can drastically change its complexity. In particular, incremental

bipartite matching remains polynomial-time in many cases but becomes NP-hard

in others, whereas incremental flow is NP-hard even for very basic models. To

the best of our knowledge, this is the first instance of a polynomial-time problem

whose incremental version is NP-hard.

Thus the incremental constraint may affect a problem’s complexity; it also

may affect its competitiveness. The extent to which the incremental constraint

contributes to a problem’s competitiveness is of particular interest due to its role

in understanding online problems (Chapter 2). We determine that incremental

bipartite matching is 23-competitive and strictly 1

2-competitive; moreover, these

bounds are tight, in the sense that there are instances for which no incremental

algorithm can perform any better. We find that incremental flow is 2n- and strictly

2n-competitive; these bounds are almost tight. Lastly, we find that knapsack has an

arbitrarily bad competitive ratio; however, an algorithm exists that approximates

its ratio within a factor of 1− ε for ε > 0.

These three problems fit the model of packing problems, a large class of com-

binatorial maximization problems. We introduce a general incremental model for

31

Page 43: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

packing problems, and use this model to give general techniques that translate

exact or approximate algorithms for non-incremental problems into decent algo-

rithms for their corresponding incremental definitions. The algorithm is tight for

network flow, but can be improved for bipartite matching and knapsack.

The incremental packing model is defined in Section 3.2. We discuss the bipar-

tite matching, network flow, and knapsack problems in detail in Sections 3.3, 3.4,

and 3.5, respectively, and discuss the general approximation algorithm in Section

3.6. Many of these results appear in [47], and are summarized in Table 3.1.

Table 3.1: Main results of Chapter 3. The parameter k is the number of time

steps, Hk =∑k

i=11i∈ Θ(log k), and r∗M , r∗K can be arbitrarily small.

Bipartite Weighted Network Knapsack

Matching Matching Flow

Best-know Offline Approximation 1 1 1 (1− ε)

Aggregate Approximation 1 1 1Hk

(1− ε)

Competitive Ratio Upper Bound 23 r∗M > 0 2

nd r∗K > 0

Competitive Ratio Lower Bound 23 (k = 2) r∗M > 0 2

n r∗K > 0

12 (k > 2)

Competitive Ratio Approximation 1 (k = 2) r∗M > 0 2n

(1−ε)2

2

12 (k > 2)

3.2 The General Model

3.2.1 Single-Level Problems

We define a model for single-level combinatorial optimization problems that is then

extended to the incremental setting in Section 3.2.2. Such a problem Π consists

32

Page 44: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

of a ground set from which we select an optimal-value subset satisfying input

constraints. In particular, let X be the ground set, F ⊆ 2X the set of feasible

solutions as defined by problem constraints, and v : 2X → R a valuation function

on element sets. The goal is to return an S ∈ F optimizing v(S). Let A(X,F , v),

or A(F) when X and v are understood, denote the solution found by algorithm A.

This notation is adapted from the general minimization models of [41, 52];

however, it is general enough to represent both maximization and minimization

problems. This chapter deals with packing problems, a subclass of maximization

problems that are monotone, that is, any subset of a feasible solution is also feasible.

In particular, if F is nonempty then the empty set is a feasible solution, that is,

∅ ∈ F ; we assume that v(∅) = 0.

3.2.2 Incremental Problems

Given a maximization problem Π, we define its incremental version Πk as follows.

There are k levels, each level ` with its own feasible set F`. A feasible solution is a

tuple S = (S1, S2, . . . , Sk) such that S` ∈ F` and S1 ⊆ S2 ⊆ · · · ⊆ Sk. Although we

do not explicitly assume that F` ⊆ F`+1, we may do so without loss of generality.

A (v1, v2, . . . , vk)-solution is a feasible solution (S1, S2, . . . , Sk) with v(S`) = v`.

In contrast to the single-level problems, whose sole objective is to find a solution

of maximum value, there are several possible objectives for an incremental problem.

We focus on the following competitive ratio and aggregate value objectives.

Definition 3.1 An incremental algorithm A is α-competitive if there exists some

constant c such that for all input sequences (F1,F2, . . . ,Fk) and 1 ≤ ` ≤ k,

v(S`) ≥ α · v(OPT (F`))− c,

33

Page 45: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

where (S1, S2, . . . , Sk) is the incremental solution found by algorithm A.

That is, the objective is to obtain an α-proportion of each level’s optimal so-

lution. This is analogous to the competitive ratio for online algorithms, and is

a standard metric for incremental problems [71, 66]. An algorithm is considered

strictly α-competitive if it is α-competitive with the constant c = 0. The value of

α is called the (strict) competitive ratio.

Definition 3.2 An incremental algorithm A is σ-aggregate for weights w1, . . . , wk

if for all input sequences (F1,F2, . . . ,Fk),

k∑`=1

w` · v(S`) ≥ σ,

where (S1, S2, . . . , Sk) is the incremental solution found by algorithm A.

That is, the objective is to obtain a weighted sum of at least σ. This is not a

standard metric for incremental problems; however, it allows us to achieve a better

solution overall by disregarding each level’s individual performance. The value of

σ is called the aggregate value.

We now consider the three problems discussed in Section 3.1, and demonstrate

how they fit into this framework. There are many ways to define incremental ver-

sions of these problems; we consider a limited number in this chapter. Alternative

interpretations of network flow and other problems are discussed in Chapter 5.

3.3 Bipartite Matching

Given a bipartite graph G = (V, E), the bipartite matching problem finds a max-

imum matching in G, that is, a maximum set of edges M ⊆ E such that no two

edges of M share a common endpoint. In terms of our model, the elements are

34

Page 46: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

the edges of G, and the feasible solutions are matchings contained in E. The value

of a matching M is v(M) = |M |. Bipartite matching is a well-studied problem in

both computer science and mathematics, and can be solved in polynomial time.

Incremental bipartite matching is defined on a sequence of k bipartite graphs

G` = (V, E`) for ` = 1, . . . k, where E` ⊆ E`+1. The elements are the edges of

Ek, and the level ` feasible set contains the matchings of E` ⊆ Ek. Therefore a

solution is a sequence of matchings (M1, M2, . . . ,Mk) such that M` is a matching

in the graph G`, and M` ⊆ M`+1. The maximum single-level matching for level

` is denoted by M∗` . The weighted case is defined analogously, except each edge

e ∈ Ek has a fixed weight ce ≥ 0, and v(M`) =∑

e∈M`ce.

3.3.1 Aggregate Objective

Imposing the incremental constraint on bipartite matching does not increase its

complexity with respect to the aggregate objective function. In fact, the following

theorem shows that for any number of levels, the optimal aggregate solution can

be found in polynomial time, even for the weighted bipartite matching problem.

Theorem 3.1 There is a polynomial-time algorithm for incremental weighted bi-

partite matching that achieves the optimal aggregate value on every instance.

Proof. We transform our incremental instance (G1, G2, . . . , Gk, c) into a single

instance (G, c′) of the maximum-weight matching problem, which is polynomial-

time solvable [62]. The graph G = (V, E) has E = Ek, and edge e ∈ E is assigned

weight c′e = ce ·∑k

i=` wi if e first appears in the edge set E`, i.e., if e ∈ E`\E`−1;

this is the amount e would contribute to the sum if it were added to our solution at

level `. For a matching M returned by the maximum-weight matching algorithm,

35

Page 47: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

we define an incremental solution M` = M ∩E`, 1 ≤ ` ≤ k. We claim that M is a

maximum-weight matching if and only if (M1, M2, . . . ,Mk) is the optimal aggregate

solution; this follows from a one-to-one correspondence between the value of the

maximum-weight matching and the weighted sum our incremental solution:

v(M) =∑e∈M

c′e =k∑

`=1

∑e∈M`\M`−1

c′e =k∑

`=1

∑e∈M`\M`−1

ce ·k∑

i=`

wi

=k∑

`=1

v(M`\M`−1) ·k∑

i=`

wi =k∑

`=1

w` · v(M`) . ut

3.3.2 Ratio Objective

Although there is a polynomial-time algorithm achieving the optimal aggregate

value for incremental bipartite matching, the situation is more complicated for

the competitive ratio. This is due, in part, to the fact that we not only want to

determine the complexity of finding the optimal ratio, but also want to bound what

this optimal ratio, that is, its competitiveness, may be. The distinction between

complexity and competitiveness is important; we may have a tight α-competitive

algorithm, however, this algorithm may not be optimal on all instances, in fact, it

may even be NP-hard to find such an optimal algorithm.

This section is divided into three parts: the first and second discuss unweighted

and weighted bipartite matching, respectively, and the third shows how the results

change when enforcing a strict competitive ratio.

Unweighted Bipartite Matching

Theorem 3.2 No algorithm for incremental bipartite matching is > 23-competitive.

36

Page 48: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

n copies

Figure 3.1: No incremental algorithm is α-competitive on this instance for α > 23.

The level-one edges are solid and the level-two edges are dashed.

Proof. Consider the incremental bipartite matching instance given in Figure 3.1,

constructed from n copies of a 3-edge gadget. Note that |M∗1 | = n, |M∗

2 | = 2n =

2 · |M∗1 |, and that for each gadget we take either a (1, 1)-matching or a (0, 2)-

matching. Suppose there is a (23+α)-competitive algorithm for some α > 0. Then

there is a constant c such that |M1| ≥ (23

+ α)|M∗1 | − c, and

(2

3+ α)|M∗

2 | − c ≤ |M2| ≤ |M∗2 | − |M1|

≤ |M∗2 | − (

2

3+ α)|M∗

1 |+ c

= |M∗2 | −

1

2(2

3+ α)|M∗

2 |+ c

= (2

3− 1

2α)|M∗

2 |+ c.

Therefore c ≥ 3α4|M∗

2 |, which is not a constant, a contradiction.

Thus for any number of levels, it is not possible to find an α-competitive algo-

rithm with α > 23. For k = 2, we have an algorithm that matches this bound.

Theorem 3.3 Two-level incremental bipartite matching is 23-competitive.

Proof. We argue that Algorithm 1 is 23-competitive. Let P1,P2 denote the sets of

alternating paths selected for M1 and M2 \M1, respectively, and let 2q + 1 be the

length of the last path selected for M1. If q = 0 then M2 = M∗2 and we are done.

Otherwise, each path P ∈ P1 contributes at least q edges to M1, except the last,

37

Page 49: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Algorithm 1 Finds a 23-competitive incremental bipartite matching.

Given input graphs G1 and G2, first find maximum matchings M∗1 , M∗

2 of G1 and

G2, respectively. Consider any alternating path P of M∗1 ∪ M∗

2 . Without loss of

generality, |P | is odd (if it were even then swapping the edges of M∗2 ∩ P and

M∗1 ∩ P would yield a new M∗

2 of the same size). Initialize M1 = M∗1 ∩M∗

2 .

While |M1| < b23|M∗

1 |c, select the longest remaining alternating path P and set

M1 = M1 ∪ (M∗1 ∩ P ), breaking the last P in two, if necessary, to ensure |M1| ≤

b23|M∗

1 |c. For all remaining paths P , set M2 = M1 ∪ (M∗2 ∩ P ).

PL, which contributes c ≤ q. Thus

|M∗1 ∩ P1| ≥ c + q(|P1| − 1) ⇒ |P1| ≤ 1

q|M∗

1 ∩ P1|+ 1, and

|M∗1 ∩ P2| ≤ q|P2| ⇒ |P2| ≥ 1

q|M∗

1 ∩ P2| .

Since |P ∩M∗1 | = |P ∩M∗

2 | − 1 for any path P , we have

|M∗2 ∩ P1| = |M∗

1 ∩ P1|+ |P1| ≤ q+1q|M∗

1 ∩ P1|+ 1,

|M∗2 ∩ P2| = |M∗

1 ∩ P2|+ |P2| ≥ q+1q|M∗

1 ∩ P2|, and

|M∗2 ∩ P2| ≥ q+1

q|M∗

1 ∩ P2| ≥ q+1q

12|M∗

1 ∩ P1| ≥ 12|M∗

2 ∩ P1| − 1 .

Putting all this together implies that

|M2| = |M∗1 ∩ P1|+ |M∗

2 ∩ P2| ≥ qq+1

· |M∗2 ∩ P1| − 1 + |M∗

2 ∩ P2|

= 23|M∗

2 |+ ( qq+1

− 23)|M∗

2 ∩ P1|+ 13|M∗

2 ∩ P2| − 1

≥ 23|M∗

2 |+ ( qq+1

− 23)|M∗

2 ∩ P1|+ 16|M∗

2 ∩ P1| − 2 ≥ 23|M∗

2 | − 2,

where the last step follows from qq+1

≥ 12.

Although there is no evidence to suggest that a 23-competitive algorithm cannot

be found for k ≥ 3 levels, we have not yet found one.

Theorems 3.2 and 3.3 show that no algorithm has better competitive ratio than

Algorithm 1, however, Algorithm 1 is not optimal; there are instances, as in Figure

38

Page 50: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(a) (b) (c)

Figure 3.2: The bold edges in 3.2(b) and 3.2(c) show two possible M∗1 of 3.2(a). If

Algorithm 1 selects the matching in 3.2(b) then it can be 1-competitive; however,

if it selects the matching in 3.2(c) then it can at best be 23-competitive.

3.2, for which it obtains a competitive ratio of 23

although better solutions exist.

The following theorem shows that an optimal algorithm exists, in the sense that

it achieves the best ratio for every instance.

Theorem 3.4 There is a polynomial-time algorithm for 2-level incremental bipar-

tite matching that achieves the optimal competitive ratio on every instance.

Proof. We transform our incremental instance (G1, G2) into an instance (G, c) of

the maximum-weight matching problem, which is polynomial-time solvable [62].

The edge set of G is E2, where e has weight 1 if e ∈ E1 and weight 0 otherwise.

For each 1 ≤ m ≤ |M∗2 | ∈ O(|V |) we find the maximum-weight matching Mm of

size m and define an incremental solution Mm` = Mm ∩ E`; we return a solution

(Mm1 , Mm

2 ) with best competitive ratio. By the nature of the weights given to

level-one edges, if an (m′, m) matching exists then |Mm1 | ≥ m′. Therefore our

solution must have a ratio no worse than that of the (m′, m) matching.

39

Page 51: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

This technique can be generalized for k ≥ 3 when the instance has competitive

ratio 1; however, no more is known for instances with arbitrary competitive ratio.

Weighted Bipartite Matching

Theorems 3.3 and 3.4 give us nice results on the complexity and competitiveness

of incremental bipartite matching. Interestingly, allowing arbitrary edge weights

changes both these measures significantly. For each edge e = (u, v) ∈ E`, let eu, ev

be the maximum-weight edges in E`+1 \ e incident to u and v, respectively. We

define r`e = c(e)

maxc(e),c(eu)+c(ev) , that is, r`e is the proportion of level ` + 1 value

obtained by selecting e instead of eu and ev. Let r∗M = min1≤`≤k−1,e∈G`r`

e.

Theorem 3.5 No algorithm for incremental weighted bipartite matching is α-

competitive for α > r∗M .

Proof. Consider the incremental weighted bipartite matching instance given in

Figure 3.3. Note that |M∗1 | = r∗MA, |M∗

2 | = A. Suppose there is an (r∗M + α)-

competitive algorithm for some α > 0. Then there is a constant c such that

|M1| ≥ (r∗M +α)|M∗1 |−c and |M2| ≥ (r∗M +α)|M∗

2 |−c. Let A > max cr∗M (r∗M+α)

, cα.

|M1| = 0 ⇒ 0 ≥ (r∗M + α)r∗MA− c > 0,

a contradiction. Therefore |M1| = r∗MA and |M2| = r∗MA. Then

r∗MA ≥ (r∗M + α)A− c ⇒ c ≥ αA > c,

another contradiction. Therefore no such α exists.

We observe that r∗M can be much less than the 23

lower bound obtained for

the unweighted problem in Theorem 3.3 (it could be 1n, for example). Thus, the

introduction of edge weights adversely affects the problem’s competitiveness, and

40

Page 52: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

A r∗

MA

Figure 3.3: No incremental algorithm is > r∗M -competitive on this instance, for A

defined in the proof of Theorem 3.5.

any attainable algorithm is at most r∗M -competitive. As with the unweighted case,

we have an algorithm that achieves the bound.

Theorem 3.6 Incremental weighted bipartite matching is r∗M -competitive.

Proof. Consider the greedy algorithm that sets M1 = M∗1 for some optimal M∗

1 ,

then adds as many edges as possible at each level, given the incremental constraint

imposed by the previous matching. Certainly |M1| ≥ r∗M |M∗1 | since r∗M ≤ 1, and

|M`| = |M∗` | − (value of M∗

` ruined by M`−1) + |M`−1 \M∗` |

≥ |M∗` | − (

1

r∗M− 1)|M`−1 \M∗

` |

≥ |M∗` | − (

1

r∗M− 1)|M`−1| ≥ |M∗

` | − (1

r∗M− 1)|M`| ≥ r∗M |M∗

` | . ut

Theorems 3.5 and 3.6 show that we have a tight r∗M -competitive algorithm. In

the unweighted case, however, we not only found a tight algorithm (Theorem 3.3),

but also an optimal algorithm (Theorem 3.4). Unfortunately, the following result

implies that finding an optimal algorithm with weighted edges may prove difficult.

Theorem 3.7 No polynomial-time algorithm for two-level incremental weighted

bipartite matching achieves the optimal competitive ratio on every instance, unless

P = NP .

41

Page 53: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

C· s(a

1)C· s(a

3)C· s(a

4)

C3 · s(a4

)C

3 · s(a3)

C3 · s(a1

)

C· s(a

2)

C3 · s(a2

)

Figure 3.4: An incremental weighted bipartite matching instance constructed from

a partition instance with A = a1, a2, a3, a4. Edges are labeled with their weights.

The proof of Theorem 3.7 follows from a reduction from Partition, known to

be NP-complete [57]. Given a finite set A and sizes s(a) ∈ Z+ for all a in A, the

partition problem finds a subset A′ ⊆ A such that∑

a∈A′ s(a) =∑

a∈A\A′ s(a). We

construct a 2-level instance of incremental weighted bipartite matching such that

the optimal competitive ratio is 12

if and only if the desired partition of A exists.

For each element a ∈ A, we create a 2-level gadget consisting of two incident

edges e1a and e2

a. Edge e1a is a level-1 edge of weight C ·s(a), and edge e2

a is a level-2

edge of weight C3 · s(a), for some C > 1. This construction is shown in Figure 3.4.

Let S =∑

a∈A s(a). Then M∗1 contains all level-1 edges, with total weight C ·S,

and M∗2 contains all level-2 edges, with total weight C3 · S.

Lemma 3.8 The optimal competitive ratio of this construction is at most 12.

Proof. By way of contradiction, suppose there is a (12+ α)-competitive algorithm

for some α > 0. Then there is a constant c such that v(M1) ≥ (12

+ α)v(M∗1 )− c,

v(M2) ≥ (12

+ α)v(M∗2 ) − c, and v(M1) > 1

2v(M∗

1 ) = CS2

for CS > cα. We observe

that v(M1) = C · d for some integer d ≥ 1, so v(M1) ≥ C(S2

+ 12), and

v(M2) = v(M∗2 )− (C2 − 1)v(M1) ≤ v(M∗

2 )− (C2 − 1)C(S2

+ 12)

= v(M∗2 )− C3S

2+ CS

2− C3

2+ C

2= 1

2v(M∗

2 )− C2(C2 − S − 1).

If C2 > S + 1 then c ≥ αv(M∗2 ), a contradiction to c being constant.

42

Page 54: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Lemma 3.9 There is a partition of A if and only if there is a 12-competitive in-

cremental matching.

[⇒] Suppose we have a partition A′ ⊆ A such that∑

a∈A′ s(a) =∑

a∈A\A′ s(a) = S2.

We create an incremental matching (M1, M2) by selecting M1 = e1a | a ∈ A′ and

M2 = M1 ∪ e2a | a ∈ A \ A′. This is a feasible solution, as the matching uses

exactly one gadget edge for each element a ∈ A. Furthermore,

v(M1) = C ·∑

a∈A′ s(a) v(M2) = v(M1) + C3 ·∑

a∈A\A′ s(a)

= 12v(M∗

1 ) = 12v(M∗

2 ) + CS2

[⇐] Suppose we have a 12-competitive incremental matching (M1, M2). Then we

claim v(M1) = C·S2

, using the fact that v(M1) = C · d for some integer d ≥ 1:

v(M1) < C · S2

implies v(M1) ≤ C · (S2− 1

2) = 1

2v(M∗

1 ) − C2, and M1 is not 1

2-

competitive. Conversely, v(M1) > CS2

implies v(M1) ≥ C · (S2

+ 12), and M2 is not

12-competitive by Lemma 3.8. Thus (M1, M2) is such that v(M1) = C S

2; we define

A′ = a ∈ A | e1a ∈ M1 so that

∑a∈A′ s(a) = v(M1)

C= S

2.

Theorem 3.7 follows directly from Lemmas 3.8 and 3.9. Although it may be

possible to find an algorithm achieving the optimal competitive ratio on instances

with polynomial-size weights (partition is only hard if the s(a) are non-polynomial),

Theorem 3.7 still illustrates a dichotomy between the aggregate and ratio objec-

tives: the optimal aggregate value for weighted bipartite matching can be found in

polynomial time, whereas the optimal competitive ratio cannot (unless P = NP ).

Strictly Competitive Bipartite Matching

When we restrict our competitive analysis to prohibit constant fluctuations in

competitive performance, our lower and upper bounds on the competitive ratio

43

Page 55: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

can only decrease. For instance, Theorem 3.10 shows that strict analysis lowers

our unweighted bipartite matching upper bound from 23

to 12.

Theorem 3.10 No algorithm for incremental bipartite matching is strictly α-

competitive for α > 12.

Proof. Suppose we have just one copy of the 3-edge gadget of Figure 3.1. In order

to achieve a strict 12-competitive ratio, an algorithm must find |M1| ≥ 1

2|M∗

1 | = 12.

Integrality implies that |M1| = 1, therefore |M2| = 1 = 12|M∗

2 |.

We can use Theorem 3.6’s algorithm as a strictly 12-competitive algorithm in

the unweighted case, because r∗M ≥ 12. Furthermore, the algorithm of Theorem 3.4

finds the optimal strict competitive ratio. This proves the following two theorems.

Theorem 3.11 Incremental bipartite matching is strictly 12-competitive.

Theorem 3.12 There is a polynomial-time algorithm for 2-level incremental bi-

partite matching that achieves the optimal strict competitive ratio on every in-

stance.

When we consider weighted edges, the results of Theorems 3.5, 3.6, and 3.7 all

hold under the strict analysis.

3.4 Network Flow

Given a directed network G = (V, E) with source s, sink t, and capacity function

c : E → Q, a flow is a function f : E → Q satisfying

(i) capacity constraints f(e) ≤ c(e) for all e ∈ E, and

(ii) flow conservation f in(v) = f out(v) for all v ∈ V \ s, t.

44

Page 56: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

s

t

uv

Figure 3.5: An incremental network with solid level-one edges and dashed level-two

edges. Unless otherwise specified, the edges have unit capacity.

The maximum flow problem finds the maximum s-t flow f . In terms of the model

of Section 3.2, elements are unit s-t flow paths, and feasible solutions are flows

satisfying the given capacity function. The value of a flow f , denoted by |f |, is the

number of unit s-t flow paths it contains. Network flow is a well-studied problem in

computer science, with applications from airline scheduling to computer graphics.

It can be solved in polynomial time.

Incremental flow is defined on a directed network G = (V, E) with source s,

sink t, and a non-decreasing sequence of k capacity functions c` : E → Q that

define k feasible sets. A solution is a sequence of s-t flows (f1, f2, . . . , fk) such that

f` is feasible with respect to capacity function c`, and f`(e) ≥ f`−1(e) for every

edge e. The flow f ∗` denotes the maximum single-level flow at level `.

As an example, Figure 3.5 is a 2-level incremental flow network. We obtain a

(0, 2)-flow in this network by sending no level-1 flow and two units of level-2 flow

in parallel along paths s · u · t and s · v · t. Alternatively, we obtain a (1, 1)-flow

by sending one unit of level-1 flow along the only level-1 path s · u · v · t and no

additional level-2 flow. No (1, 2)-flow exists because using uv in level 1 precludes us

from sending any additional level-2 flow. In this chapter we only consider directed

integral flows; however, undirected and fractional flows are discussed in Chapter 5.

45

Page 57: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

3.4.1 Aggregate Objective

Theorem 3.1 shows that for the aggregate objective, the incremental structure does

not affect the complexity of bipartite matching; this is an example of a polynomial

problem whose incremental version remains polynomial. However, the following

theorem demonstrates that the incremental structure affects network flow enough

to significantly change its complexity, thereby illustrating an intriguing dichotomy

between the closely related problems of bipartite matching and network flow.

Theorem 3.13 No algorithm for two-level incremental flow achieves the optimal

aggregate value on every instance in polynomial time, unless P = NP .

The proof of Theorem 3.13 follows from a reduction from 3-SAT. We are given a

3-SAT formula φ with variables V and clauses C. Each clause is a set of three

literals; the set of literals is the union of all positive literals v and all negative

literals v for v ∈ V . We denote each literal occurrence as a clause-literal pair

(c ∈ C, ` ∈ c). Given the formula φ, we construct an instance of incremental flow

such that a 3-aggregate solution exists if and only if φ is satisfiable.

Literal Gadgets For every literal occurrence (c, `) we create a literal gadget:

an in vertex, an out vertex, and a level-1 edge between the two.

Clause Gadgets For every clause c ∈ C we create a clause gadget: an in vertex,

an out vertex, and the three literal gadgets of the form (c, ` ∈ c), joined by

level-1 edges as shown in Figure 3.6.

Variable Gadgets For every variable v ∈ V we create a variable gadget: an in

vertex, an out vertex, and all literal gadgets of the form (c, v) or (c, v) for

any c, linked together as shown in Figure 3.6: positive literals on one side,

negative literals on the other, and each side joined by level-2 edges.

46

Page 58: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

c.in

c.out

c

(c, u)

(c, w)

(c, v)

v v.in

v.out

(a, v)(b, v)

(d, v)(c, v)

Figure 3.6: The gadgets for clause c and variable v constructed from the formula

(u∨ v∨w)∧ (u∨ v∨w)∧ (u∨ v∨w)∧ (u∨ v∨w); the clauses are denoted a, b, c, d.

Literal gadgets appear inside labeled ovals.

Connectors We link the source, sink, and all clause gadgets together in series

with level-1 edges, forming the clause component ; the same is done for the

variable gadgets with level-2 edges, forming the variable component. These

edges are called connectors and are shown in Figure 3.7(a).

Lemma 3.14 The maximum single-level flows have values |f ∗1 | = 1 and |f ∗

2 | = 2.

Proof. The sink t has in-degree 1 and in-degree 2 in the level-1 and 2 graphs,

respectively, indicating that |f ∗1 | ≤ 1 and |f ∗

2 | ≤ 2. The level-1 graph is connected,

hence |f ∗1 | ≥ 1, and the level-2 graph has no cut of size 1, hence |f ∗

2 | ≥ 2.

Lemma 3.15 There is a satisfying assignment iff there is a 3-aggregate flow.

[⇒] Given a satisfying assignment, we route one unit of level-1 flow through all

clause gadgets, passing through gadget c using literal gadget (c, `) for some true

literal `. We route an additional unit of flow at level two through all variable

gadgets, using only false literals by passing through the positive (negative) side of

gadget v if v is false (true). Such a flow is shown in Figure 3.7(b).

47

Page 59: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

a

b

c

d

u

v

w

(a, u)

(b, u)

(c, u)

(d, u)

(a, v)

(c, v)

(b, v)

(d, v)

(a,w)

(b, w)

(c, w)

(d,w)

(a, u) (a,w)

(b, u) (b, w)

(c, u) (c, w)

(d, u) (d,w)

(a, v)

(c, v)

(d, v)

(b, v)

s

t

(a)

a

b

c

d

u

v

w

(a, u)

(a, v)

(c, v)

(c, w)

(d,w)

(a,w)

(b, w)

(c, u)

(d, v)

s

t

(b)

Figure 3.7: 3.7(a) The incremental instance for formula (u∨v∨w)∧(u∨v∨w)∧(u∨v∨w)∧(u∨v∨w); the clauses are a, b, c, d. Each of the twelve literal gadgets appears

once in a clause gadget and once in a variable gadget, and thus the seemingly

separate source-sink paths in 3.7(a) actually share many vertices. The dotted

paths in 3.7(b) show a (1, 2)-flow based on the assignment u = 0, v = 0, w = 1.

[⇐] We make the following observations concerning (1, 2)-flows in our construction:

1. The level 1 component of any (1, 2)-flow is a path including every level-1

connector and one literal from each clause gadget. This is because the three

literals of any clause form a level 1 cut, as does any level-1 connector.

2. In any (1, 2)-flow, level 2 flow at (c, v).in (or (c, v).in) must proceed to

(c, v).out ((c, v).out) and back to the positive (negative) side of variable gad-

get v. The only other path would be to c.out, whose sole out-edge is a level-1

48

Page 60: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

connector already carrying level 1 flow (see observation 1).

3. In any (1, 2)-flow, level 2 flow at v.in proceeds through either all (c, v) gadgets

or all (c, v) gadgets to v.out. This is because v.in has two out edges: one to a

sequence of all (c, v) gadgets and one to a sequence of all (c, v) gadgets. Once

flow proceeds to one of these sequences, induction on observation 2 implies it

passes through every literal gadget in the target sequence and ends at v.out.

4. The level 2 component of any (1, 2)-flow is a path passing through the posi-

tive or negative side of each variable gadget. The source vertex has only two

out edges: a level-1 connector to a clause gadget and a level-2 connector to

a sequence of all variable gadgets. By observation 1, the level-1 connector is

already used, forcing the flow to the first variable gadget. Repeated applica-

tion of observation 3 implies that the flow proceeds through the positive or

negative side of every variable gadget to the sink.

By observation 4, every variable v carries level-2 flow through one side of its gadget.

We set v false if this flow passes through v’s positive side and true otherwise; under

this assignment, all false literals carry level-2 flow. By observation 1, one literal

from each clause must carry level-1 flow (and not level-2 flow) and thus cannot be

false. This assignment satisfies the given formula.

Theorem 3.13 follows from Lemma 3.15 and the polynomial nature of our re-

duction. Thus, finding the optimal aggregate value is not possible, and we turn

to approximation algorithms. Theorem 3.26 gives a 1Hk

-approximation to the ag-

gregate objective for incremental flow; the next theorem proves that this approxi-

mation is tight. The proof relies on the reduction described in Theorem 3.13: we

make multiple copies of Theorem 3.13’s clause and variable components, which

49

Page 61: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

appear1 over k levels rather than just two. If a clause component appears at level

`c and its corresponding (i.e., linked) variable component appears at level `v > `c,

then the observations of 3.15 are easily extended to the following lemma.

Lemma 3.16 Let `′c ≥ `c denote the earliest level in which clause component c

carries flow. If `′c < `v, then any flow through variable component v determines

a satisfying assignment. Also, any satisfying assignment can be used to achieve a

flow with separate flow paths through components c and v.

Theorem 3.17 It is NP-hard to find a β-approximation algorithm for the aggre-

gate objective of incremental flow for β > 1Hk

.

Proof. Suppose we have a ( 1Hk−ε

)-approximation algorithm. We will show we

can solve any instance of 3-SAT by constructing an incremental flow network and

using the approximation algorithm to identify satisfiable formulas.

Let b = kd1εe. We create a b × b matrix of components as shown in Fig-

ure 3.8. For 0 ≤ a0 ≤ a1 ≤ · · · ≤ ak ≤ b defined later, assign to level ` the

columns a`−1 + 1 through a`; each level ` column j contains variable components

v1j, v2j, . . . , va`−1j and clause components cj(a`+1), . . . , cj(b−1), cjb, all linked in series

between the source and the sink. Components in these columns contain only level

` edges. Variable component vij is linked to clause component cij. Then

1. The maximum flow at level ` has value a`, therefore we can obtain an a`(k +

1− `)-sum for any level `, regardless of whether φ is satisfiable or not.

2. Any level ` flow must pass through clause components cj(a`+1), . . . , cjb for

some column j ≤ a`. If there is any flow being sent down a level i column

1A component is said to appear at level ` if, in the incremental network, all ofits edges have capacity 0 prior to level ` and capacity 1 for all subsequent levels.

50

Page 62: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

s

t

v12 v13 v14 v15

c15

c14

c13

c12

c23

v23

v35

c35 c45

v45

c16

c17

c18

c24

c25

c26

c27

c28

c36

c37

c38

c46

c47

c48

v16 v17 v18

v28

v38

v48v47v46

v36 v37

v24 v25 v26 v27

level 1 level 5

level 7 level 8

Figure 3.8: Circles denote clause components and squares denote variable com-

ponents. Clause-variable tuple (cij, vij) consists of clause component cij in row j,

column i, and variable component vij in row i, column j. k = 8 and ε = b = 1.

for i > ` then this extra flow must pass through variable component vij for

some a` < j ≤ b. Thus if φ is unsatisfiable and there is level ` flow then

there cannot be any flow being sent down a level i column, i > `.

3. For any incremental flow (f1, f2, . . . , fk), consider the smallest ` such that

a` ≥ |fk|. Then aj < |fk| for j < `, and if φ is unsatisfiable then |fj| = 0 and

the maximum sum we can obtain is∑k

j=` |f`| ≤∑k

j=` a` = a`(k − ` + 1).

4. If φ is satisfiable then we can obtain a sum of∑k

`=1 a`.

Therefore, if we choose our a` such that∑k

`=1 a` > (Hk−ε)·max`a`(k+1−`) then

a ( 1Hk−ε

) approximation would distinguish between satisfiable and unsatisfiable

instances. Selecting a` = b bk+1−`

c suffices.

51

Page 63: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ts

Figure 3.9: No incremental algorithm is > 2nd -competitive on this instance, d < 1.

3.4.2 Ratio Objective

Unlike the unweighted bipartite matching problem, we upper-bound the incremen-

tal flow competitive ratio by a non-constant that can be very small. Let n = |V |.

Theorem 3.18 No algorithm for incremental flow is > 2nd -competitive for d < 1.

Proof. Consider the incremental flow instance given in Figure 3.9, constructed

such that |f ∗1 | = n

1−d2 and |f ∗

2 | = n2|f∗1 |

. Note that any non-zero amount of level-1

flow prevents level 2 from getting more than |f ∗1 | flow. Suppose there is a ( 2

nd +α)-

competitive algorithm for some α > 0. Then there is a constant c such that

|f1| ≥ ( 2nd +α)|f ∗

1 |−c and |f2| ≥ ( 2nd +α)|f ∗

2 |−c. In order for f1 to be competitive,

we need |f1| > 0. But then |f2| ≤ |f ∗1 |, and

(2

nd+ α)|f ∗

2 | − c ≤ |f ∗1 | =

2|f ∗1 |2

n|f ∗

2 | =2

nd|f ∗

2 |,

which implies that c ≥ α|f ∗2 |, a non-constant.

Theorem 3.18 demonstrates that for any d < 1, there is an incremental flow

instance for which any algorithm is at best O( 2nd )-competitive. The following is an

algorithm with competitiveness almost matching this bound.

52

Page 64: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Theorem 3.19 Incremental flow is 2n-competitive.

Proof. Consider the algorithm that starts at level 1 and sequentially sends the

maximum flow possible on each level, given the incremental constraint imposed by

the previous flow. For any level `, let P be a single unit flow path of the greedily

constructed f`. At most every other edge of P could be used by the flow paths

of f ∗j , j ≥ `, and since length(P ) < n, the path P could have blocked at most n

2

units of f ∗j ’s flow. Therefore

|fj| = |f ∗j | −# paths fj−1 blocks + |fj−1 \ f ∗

j | ≥ |f ∗j | − (

n

2− 1)|fj−1 \ f ∗

j |

≥ |f ∗j | − (

n

2− 1)|fj| ≥

2

n|f ∗

j | .

Therefore we have an almost tight algorithm for competitive ratio incremental

flow. The algorithm is not necessarily optimal, however, in the sense that there will

be instances on which it performs badly (see Figure 3.10). With bipartite matching

we were able to find an optimal algorithm for the 2-level case; unfortunately, such

an optimal algorithm for incremental flow is NP-hard to find.

Theorem 3.20 No algorithm for two-level incremental flow achieves the optimal

competitive ratio on every instance in polynomial time, unless P = NP .

Proof. We use the reduction from Theorem 3.17 for just two levels, with some

ε > 0. The instance is such that a 1-competitive solution exists if and only if the

3SAT formula is satisfiable; therefore, an algorithm finding the optimal competitive

ratio would distinguish between satisfiable and unsatisfiable instances.

53

Page 65: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

s tu

Figure 3.10: An example for which the greedy algorithm of Theorem 3.19 may find

an 2n-competitive solution (using the upper path from s to u) when a 1-competitive

solution exists (using the lower path from s to u).

Strictly Competitive Network Flow

When we consider strict analysis, we can obtain tight competitive results. The

2n-competitive algorithm described in Theorem 3.19 is also strictly 2

n-competitive,

and the following theorem shows that no algorithm can do any better.

Theorem 3.21 There is no strictly α-competitive algorithm for incremental flow

for α > 2n.

Proof. Consider the network shown in Figure 3.11. In this case |f ∗1 | = 1 and

|f ∗2 | = n

2. We need |f1| > 0 but sending one unit of level-1 flow limits level 2 to

|f2| = 1 = 2n|f ∗

2 |. With integral flow, this is the best ratio we can achieve.

3.5 Knapsack

Given a knapsack capacity B and a set of items U , item u ∈ U with size |u|

and value vu, the knapsack problem finds a maximum-value set of items U ′ ⊆ U

that fit in the knapsack, that is,∑

u∈U ′ |u| ≤ B. In terms of our model, elements

are the items of U , while feasible solutions are subsets of items that fit in the

54

Page 66: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

s

t

Figure 3.11: No incremental algorithm is strictly > 2n-competitive on this instance.

knapsack. In this section we consider the case where vu = |u|; the value of a

set of items U ′ is therefore their combined size |U ′| =∑

u∈U ′ |u|. This special

case is often referred to as the maximum subset sum problem. Maximum subset

sum is NP-complete [34]; however, it can be solved in pseudo-polynomial time

with dynamic programming [75, 60], or approximated with a fully polynomial-

time approximation scheme (FPTAS) [51].

Incremental knapsack is defined on a set of items U , item u ∈ U with size

|u|, but instead of a single capacity B we have a sequence of k capacities B1 ≤

B2 ≤ · · · ≤ Bk that define k feasible sets. A solution is a sequence of subsets

(U1, U2, . . . , Uk) of U such that |U`| ≤ B`, and U` ⊆ U`+1. We denote the value of

the maximum single-level solution at level ` by U∗` .

3.5.1 Aggregate Objective

Unlike bipartite matching and network flow, we cannot hope to find a polynomial-

time algorithm that obtains the optimal aggregate value on every instance: such

an algorithm would solve knapsack when k = 1. We can, however, extend the

O(n2P ) dynamic programming algorithm for knapsack to an O(nk+1P k) algo-

rithm that finds the optimal aggregate incremental knapsack solution, where P =

55

Page 67: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

maxu∈U |u|: the knapsack subproblems M(i, b) represent the maximum sum solu-

tion for items u1, u2, . . . , ui and knapsack capacity b; the modified subproblems

M(i, b1, b2, . . . , bk) represent the maximum aggregate incremental solution for items

u1, u2, . . . , ui and knapsack capacities b1 ≤ b2 ≤ . . . ≤ bi.

Theorem 3.22 There is a (1 − ε)-approximation algorithm to the aggregate ob-

jective of incremental knapsack with running time exponential in k.

The proof of Theorem 3.22 follows from Algorithm 2, which is a modified version

of Ibarra and Kim’s single-level knapsack FPTAS [51]. Our dynamic programming

algorithm is intractable when the items are large, that is, when their sizes are

not bounded by a polynomial in n; if we could somehow guarantee that our items

were small, however, then dynamic programming would be suitable. The idea of

Algorithm 2 is to scale down the items so that they are polynomial-size. We then

run our (now polynomial-time) algorithm and reconstruct a solution to the original

problem, losing a factor of at most (1− ε) along the way.

Algorithm 2 An FPTAS for the aggregate objective of incremental knapsack.

Let C = εPWn

, where W =∑k

`=1 w`. We create a new incremental knapsack instance

as follows. For each item ui ∈ U we define a new item u′i with size b |ui|Cc. Now we

use these items in the dynamic programming algorithm and return its solution S′.

Lemma 3.23 The set S′ output by the algorithm is a (1− ε)-approximation to the

optimal aggregate value.

56

Page 68: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Proof. Let O = (O1, O2, . . . , Ok) denote the optimal aggregate solution. For any

item u, because of rounding down, C · |u′i| ≤ |ui|, however, C · |u′i| ≥ |ui|−C. Then

k∑`=1

w`

∑ui∈O`

|ui| − C ·k∑

`=1

w`

∑ui∈O`

|u′i| =k∑

`=1

w`

∑ui∈O`

(|ui| − C|u′i|)

≤k∑

`=1

w`

∑ui∈O`

C

≤ nCk∑

`=1

w` ≤ nCW.

The dynamic programming algorithm finds the best solution S′ with the modified

sizes, which is at least as good as O, thus

k∑`=1

w`

∑ui∈S′`

|ui| ≥ C ·k∑

`=1

w`

∑ui∈S′`

|u′i|

≥ C ·k∑

`=1

w`

∑ui∈O`

|u′i|

≥k∑

`=1

w`

∑ui∈O`

|ui| − nCW

= OPT − εP ≥ (1− ε)OPT,

where the last inequality follows from the observation that OPT ≥ P .

The bound of Theorem 3.22 follows from Lemma 3.23, and the running time

is O(nk+1bPCck) = O(nk+1bWn

εck), which is polynomial in n, W , and 1

ε. This algo-

rithm is still exponential in the number of levels k and polynomial in the sum of

the level weights W ; however, it is no longer dependent on the knapsack capacities.

If this running time is not acceptable, then we may consider approximation algo-

rithms. Theorem 3.26 finds a solution that is at least a 1Hk

-fraction of the optimal.

It is possible that techniques similar to those of [47] will give an approximation

better than that of Theorem 3.26; however, this has yet to be determined.

57

Page 69: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

3.5.2 Ratio Objective

The incremental bipartite matching and network flow problems have upper bounds

on the competitive ratio of 23

and 2nd , respectively. In contrast, the bound for knap-

sack can be arbitrarily small, as with the weighted bipartite matching problem.

For a given knapsack instance with items U , define r∗K = minu∈U |u|maxu∈U |u| .

Theorem 3.24 No algorithm for incremental knapsack is > r∗K-competitive.

Proof. Suppose there is an (r∗K + α)-competitive algorithm for some α > 0. Then

there is a constant c such that |U1| ≥ (r∗K +α)|U∗1 |− c and |U2| ≥ (r∗K +α)|U∗

2 |− c.

Consider the incremental knapsack instance with B1 = max c+1r∗K+α

,r∗Kα

(c + 1),

B2 = 1r∗K|B1|, and two items u1, u2 with |u1| = B1 and |u2| = B2. |U1| = 0 would

imply c ≥ (r∗K + α)|U∗1 | ≥ c + 1; therefore, |U1| = B1. Then |U2| = B1 and

(r∗K + α)|U∗2 | − c ≤ B1, which implies

c ≥ (r∗K + α)1

r∗K|B1| − |B1| ≥

α

r∗K|B1|,

a contradiction.

Theorem 3.24 shows that the competitive ratio of incremental knapsack can be

arbitrarily bad (that is, small). This in itself does not preclude the existence of an

optimal algorithm; however, the complexity of the single-level knapsack problem

implies such an algorithm is NP-hard to find. Therefore, if we are to get positive

results, they will be approximation algorithms. We demonstrate in [47] that there is

a polynomial-time algorithm that closely approximates the optimal ratio solution,

which, as mentioned, can be arbitrarily bad.

Theorem 3.25 [47] There is an O(k2n5

εlog(P )

− log(1−ε)) algorithm that obtains a (1−ε)2

2-

approximate competitive ratio for the incremental knapsack problem.

58

Page 70: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

3.6 The General Algorithm

Although Theorems 3.1 and 3.4 present optimal algorithms for both the aggregate

and ratio objectives of the bipartite matching problem, finding such algorithms for

flow and knapsack is NP-hard. In situations where finding an algorithm is difficult

or unlikely, it would be helpful to have an approximation algorithm. Rather than

find an approximation algorithm for each individual problem, we use the general

packing model of Section 3.2 to construct a single algorithm that works for any

packing problem. We present such an algorithm for the aggregate objective, and

discuss some obstacles preventing a similar algorithm for the ratio objective.

3.6.1 Aggregate Objective

For the following result we make the assumption that the level weights are all

equal, that is, w1 = w2 = · · · = wk = 1, although we could modify the analysis to

include the weights to get an approximation factor of O( αlog k

·∑k

`=1w`Pk

j=` wj).

Theorem 3.26 Given an α-approximation algorithm A for a problem Π, there is

an O( αlog k

)-approximation for the aggregate objective of its incremental version Πk.

Proof. Use the approximation algorithm on each single-level input to obtain A(F`)

with v(A(F`)) ≥ α · v(OPT(F`)). We then consider the k incremental solutions

H` = (∅, ∅, . . . , ∅︸ ︷︷ ︸`−1

, A(F`), . . . , A(F`)),

with aggregate value V(H`) = v(A(F`)) · (k − ` + 1). Out of these k solutions,

return one of maximum value. Denote this solution by H∗ such that for all `

V(H∗) ≥ α · v(OPT(F`)) · (k − ` + 1), and therefore

v(OPT(F`)) ≤ 1

α· 1

k − ` + 1· V(H∗).

59

Page 71: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

If O∗ is an incremental solution with optimal aggregate value, then

V(O∗) ≤k∑

`=1

v(OPT(F`)) ≤ V(H∗) · 1

α·

k∑`=1

1

k − ` + 1

= V(H∗) · Hk

α= V(H∗) ·O

(log k

α

),

where Hk is the kth harmonic number.

Theorems 3.1 and 3.17 show that this algorithm is not tight for bipartite match-

ing, but it is for network flow. Although we do not know if it is tight for knapsack,

we have no evidence to the contrary.

3.6.2 Ratio Objective

The aggregate objective does not require each level to be competitive with its

current optimal, and is therefore more amenable to approximation than the com-

petitive ratio objective.

For weighted bipartite matching and knapsack, we defined a ratio r∗ represent-

ing the greedy cost of a solution, that is, the most we could lose in a later level

by greedily selecting any one element at the current level. The greedy algorithm,

which at each level finds the best solution possible that obeys the incremental con-

straints, achieves an r∗-competitive solution. This ratio can be quite small, and

yet for some problems, such as weighted bipartite matching and knapsack, this is

the best any algorithm can obtain (Theorems 3.5 and 3.24).

We believe that problems with constant r∗ (such as unweighted bipartite match-

ing, with r∗ = 12) are such that variations of the greedy algorithm will achieve

competitive ratio better than r∗, however, this is only a hypothesis; more work

needs to be done in this area.

60

Page 72: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 4

Combinatorial Minimization Problems

4.1 Introduction

We now consider covering problems, a class of minimization problems dual to those

discussed in Chapter 3. The goal of these problems is to select a minimum-cost

subset of items that collectively achieve a certain goal [60]. For example, consider

the restaurant coverage problem from Chapter 1: there are customers located in

a metric space, and the object is to build the fewest number of restaurants such

that every customer is within radius r of one of your locations. This is known as

the r-domination problem.

In reality, however, the customer base expands over time, and you need to build

more restaurants to ensure your goal remains satisfied. Given a projection for how

demand will grow annually, where should you locate your restaurants each year so

that all customers are within radius r at any given time? Conventional algorithms

for r-domination can be used for any static customer base, but they cannot handle

the time-dependencies intrinsic to this type of real-world scenario. Instead, we need

an incremental version of r-domination that allows the customer base to grow at

discrete time intervals. As it is impractical and costly to relocate restaurants once

they are constructed, the locations of restaurants increases monotonically; once

built, a restaurant remains at its location as part of the solution in perpetuity.

We consider incremental versions of combinatorial minimization problems, in

which the collective goal becomes harder to achieve over time. As with the maxi-

mization problems, the goal is to find a sequence of feasible solutions, one per time

step, such that later solutions build on earlier solutions incrementally. In terms

61

Page 73: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

of restaurant coverage, as more customers appear, more restaurants are needed to

satisfy the collective goal requiring solutions of radius at most r.

We define two objective functions analogous to those of Chapter 3. The first is

the competitive ratio, where we compare the number of restaurants used in each

step to the minimum required by the current customer base; we want to minimize

the maximum of this ratio over all time steps. An algorithm is α-competitive if

this maximum is no more than α. The second objective is the aggregate value,

where we minimize the weighted sum of the solution costs over all time steps. An

algorithm is σ-aggregate if this sum is no more than σ.

Most combinatorial minimization problems can be viewed in the incremental

setting. The incremental cut problem is defined on a network with source s, sink

t, and a growing set of edges; a solution is a sequence of cuts, one per time step,

such that each cut disconnects s from t given the current edge set, and also builds

on earlier cuts incrementally. Incremental edge cover is defined on a graph with

a non-decreasing sequence of target vertex sets. We want an edge cover for each

target set such that each cover builds on the previous one.

4.1.1 Results

Network flow is one example of a polynomial-time problem whose incremental

version is NP-hard; incremental cut is another such example. This may not be

surprising, since edge cut is the dual of network flow; however, not all of their per-

formance results are in agreement. In a similar vein, edge cover is dual to bipartite

matching, and is likewise a polynomial-time problem whose incremental formula-

tion remains polynomial-time. These results are parallel to those of Chapter 3;

however, the methods of proof are fundamentally different.

62

Page 74: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

In contrast, the competitiveness results are not complementary to those of

Chapter 3. This is due primarily to the fact that, at any step, adding that step’s

optimal solution to the current incremental solution is always feasible; the anal-

ogous property for packing problems allows you to keep the current incremental

solution as is, with no additions. Unfortunately, the latter property does not

much help the competitive ratio whereas the former property guarantees constant

competitiveness. More specifically, we determine that edge cover is 43-competitive

and strictly 32-competitive; the 4

3bound is tight. We find that incremental cut is

ϕ-competitive, where ϕ is the golden ratio1, and this bound is tight.

We use the model of Chapter 3 to define a general model for covering prob-

lems, and discuss how edge cover, s-t cut, and r-domination fit this model. We

then describe a general technique to translate exact or approximate algorithms for

covering problems into decent algorithms for their corresponding incremental ver-

sions. In particular, given an α-approximation for a covering problem, we present

a 4α-approximation for its incremental version for both the ratio and aggregate

objectives. This is more efficient and more general than the O( αlog k

)-approximation

to the aggregate value of incremental packing problems shown in Chapter 3.

The incremental model for covering problems is defined in Section 4.2, and the

general techniques are presented in Section 4.3. We then discuss the edge cover, s-t

cut, and r-domination problems in detail in Sections 4.4, 4.5, and 4.6, respectively.

Many of the results appear in [48], and are summarized in Table 4.1.

1The golden ratio is the solution to ϕ = ϕ2 − 1, or approximately 1.6.

63

Page 75: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Table 4.1: Main results of Chapter 4. The variable k is the number of time steps.

Edge Weighted Edge r-

Cover Cover Cut Domination

Best-know Offline Approximation 1 1 1 log n

Aggregate Approximation (k = 2) 1 1 ϕ ϕ · log n

Aggregate Approximation (k > 2) 1 1 4 4 · log n

Competitive Ratio Upper Bound (k = 2) 43 ϕ ϕ ϕ · log n

Competitive Ratio Upper Bound (k > 2) 4 4 4 4 · log n

Competitive Ratio Lower Bound 43 ϕ ϕ 1

4.2 The General Model

The single-level model defined in Chapter 3 is general enough to represent both

maximization and minimization problems. We again focus on a class of problems

that exhibit monotonicity, which is redefined in the minimization setting. The

class is that of covering problems, monotone in the sense that S ∈ F and S ′ ⊇ S

imply S ′ ∈ F . In other words, any superset of a feasible solution is also feasible.

Edge cover, minimum cut, r-domination, vertex cover, and many other classic

minimization problems are all monotonic.

The incremental model is thus analogously defined, and we may assume without

loss of generality that F1 ⊇ F2 ⊇ . . . ⊇ Fk. The two objective functions of Chapter

3 are recast to reflect the shift from maximization to minimization problems.

Definition 4.1 An incremental algorithm A is α-competitive if there exists some

constant c such that for all input sequences (F1,F2, . . . ,Fk) and 1 ≤ ` ≤ k,

v(S`) ≤ α · v(OPT (F`)) + c,

64

Page 76: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

where (S1, S2, . . . , Sk) is the incremental solution found by algorithm A.

That is, the objective is to limit the factor by which our solution exceeds the op-

timal to α. An algorithm is considered strictly α-competitive if it is α-competitive

with the constant c = 0. The value of α is called the (strict) competitive ratio.

Definition 4.2 An incremental algorithm A is σ-aggregate for weights w1, . . . , wk

if for all input sequences (F1,F2, . . . ,Fk),

k∑`=1

w` · v(S`) ≤ σ,

where (S1, S2, . . . , Sk) is the incremental solution found by algorithm A.

That is, the objective is to obtain a weighted sum of at most σ. As with

maximization problems, this objective allows us to achieve a better solution overall

by disregarding each level’s individual performance. The value of σ is called the

aggregate value.

4.3 The General Algorithm

We use the model of Section 4.2 to convert single-level algorithms into incremental

algorithms for both objective functions. Theorem 4.1 considers two-level incre-

mental instances, whereas Theorem 4.2 deals with three or more levels.

Theorem 4.1 Given an α-approximation algorithm A for a problem Π, we obtain

a (ϕ·α)-approximate aggregate value and a (ϕ·α)-competitive ratio for its two-level

incremental version Π2.

Proof. Run A on each level individually to obtain v(A(F1)) ≤ α ·v(OPT(F1)) and

v(A(F2)) ≤ α · v(OPT(F2)). We define an incremental solution (S1, S2) as follows:

65

Page 77: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(i) If v(A(F2)) > ϕ · v(A(F1)), set S1 = A(F1) and S2 = S1 ∪ A(F2). Then

v(S1) = v(A(F1)) v(S2) ≤ v(A(F1)) + v(A(F2))

≤ α · v(OPT(F1)) ≤ 1ϕ· v(A(F2)) + v(A(F2))

≤ (1 + 1ϕ) · α · v(OPT(F2)).

(ii) If v(A(F2)) ≤ ϕ · v(A(F1)), set S1 = A(F2) = S2. Then

v(S1) = v(A(F2)) v(S2) = v(A(F2))

≤ ϕ · v(A(F1)) ≤ α · v(OPT(F2))

≤ ϕ · α · v(OPT(F1)).

The optimal aggregate value is at least w1 ·v(OPT(F1))+w2 ·v(OPT(F2)), and we

obtain aggregate value at most α·ϕ·[w1 ·v(OPT(F1))+w2 ·v(OPT(F2))]. Moreover,

our solution has competitive ratio at most maxα · (1 + 1ϕ), α · ϕ = α · ϕ.

We now generalize this algorithm to k levels. The idea is to place the optimal

solutions into buckets, using each bucket’s largest solution in our incremental so-

lution. If we choose the buckets suitably then this results in a nice approximation.

Theorem 4.2 Given an α-approximate algorithm A for a problem Π, we obtain

a 4α-approximate aggregate value and a 4α-competitive ratio for its k-level incre-

mental version Πk.

Proof. The idea is to run A on each of the k single-level problems contained

within Πk. We then cluster the k solutions into intervals such that the cost of the

last solution in each interval is at most twice that of the first solution in the same

interval. The incremental solution for level ` will be the last solution in `’s interval

together with the last solution in each preceding interval.

66

Page 78: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

More formally, let A` denote A’s level ` solution and v` denote its cost, that

is, v` = v(A`) = v(A(F`)) ≤ α · v(OPT(F`)). Define interval i as all levels ` with

2i−1v1 ≤ v` < 2iv1. Thus interval 1 contains ` with v1 ≤ v` < 2v1, interval 2

contains ` with 2v1 ≤ v` < 22v1, and so on. Let max(i) denote the last level in

interval i. This notation is illustrated in Figure 4.1.

Figure 4.1: Ten-level incremental input clustered into four intervals. Black dots

represent single-level solutions, labeled by cost and sorted on a number line. All

max(i) levels are indicated.

For each level ` in interval i, define S` =⋃i

j=1 Amax(j). Then S = (S1, S2, . . . , Sk)

is an incremental solution by construction. Note that S is also feasible because,

by monotonicity, any superset of Amax(i) is feasible for all levels in interval i. To

establish the approximation bound, recall that 2i−1v1 ≤ v` < 2iv1. Then

v(S`) ≤i∑

j=1

vmax(j) <i∑

j=0

2jv1 < 2i+1v1

= 4 · 2i−1v1 ≤ 4 · v` ≤ 4 · α · v(OPT(F`)) .

Thus each S` is at most a factor of 4α greater than the optimal at each level, and

hence the desired bound holds for both the aggregate and ratio objectives.

It is worth comparing the performance of these two algorithms to that of the

general ( αHk

)-approximation for incremental packing problems given in Chapter

3. First, the above results apply to both the aggregate and competitive ratio

objectives, whereas the packing result applies only to the former. For two levels,

the result of Chapter 3 gives an ( α1.5

)-approximation to the aggregate value, which

67

Page 79: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

is slightly better than the (ϕ·α)-approximation provided by Theorem 4.1. For large

k, however, covering problems have a (4α)-approximation, which is much better

than the O( αlog k

)-approximation for packing problems. This approximation gap

can only get wider, as the latter algorithm is tight for incremental flow, whereas

there is no evidence to suggest that the former algorithm cannot be improved.

We now consider the three problems discussed in Section 4.1 and illustrate how

they fit the covering framework. There are many ways to define incremental ver-

sions of these problems; we consider a limited number in this chapter. Alternative

interpretations of edge cover and other problems are discussed in Chapter 5.

4.4 Edge Cover

Given an undirected graph G = (V, E), the edge cover problem finds a minimum

edge cover of G, that is, a minimum set of edges E ′ ⊆ E such that each vertex is

incident to at least one edge of E ′. Strict application of our incremental model to

edge cover has a negligible effect on the nature of the problem (an issue discussed

in Chapter 5). We instead consider subset edge cover, a generalization of edge cover

defined in [70]. In addition to G there is an input T ⊆ V , where T is a target set

of vertices that must be covered. In terms of our model, the objects are the edges

of G, and feasible solutions are edge sets that cover all vertices of T . The cost of

an edge cover S is v(S) = |S|. Subset edge cover can be solved in polynomial time

by reducing it to an instance of edge cover [70].

Incremental edge cover (IEC) is defined on an undirected graph G = (V, E)

with an increasing sequence of k target sets T1 ⊆ T2 ⊆ . . . ⊆ Tk. The objects

are the edges E, and the level ` feasible set contains the subset edge covers of T`.

Therefore a solution is a sequence of edge covers (S1, S2, . . . , Sk) such that S` is a

68

Page 80: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

subset edge cover of T` in G, and S` ⊆ S`+1. The minimum single-level cover for

level ` is denoted by S∗` . The weighted case is defined analogously, except each

edge e ∈ E has a fixed cost ce ≥ 0, and v(S`) =∑

e∈S`ce.

4.4.1 Aggregate Objective

As with bipartite matching (Section 3.3), imposing the incremental constraint on

edge cover does not increase its complexity with respect to the aggregate objective.

The following theorem shows that for any number of levels, the optimal aggregate

solution can be found in polynomial time, even when the edges of E are weighted.

Theorem 4.3 There is an algorithm for incremental weighted edge cover that

achieves the optimal aggregate value on every instance.

We introduce some preliminary concepts and results to aid in the proof of

Theorem 4.3. Given an IEC instance (G, c,T = (T1, T2, . . . , Tk)), a vertex t ∈ Tk

is a level ` vertex if t first appears in target set T`; this level of t is denoted `t. For

each such vertex t, let et denote a minimum-cost edge incident to t.

Definition 4.3 An incremental solution is reduced if, for each edge u, v, either

(1) u, v ∈ Tk and u, v is added to the solution at level min`u, `v, or (2) u, v =

et for some t ∈ Tk and is added at level `t.

Lemma 4.4 For every incremental cover there is a reduced cover of no higher

cost.

Proof. Given an incremental cover S, we convert it into a reduced cover of equal

or lower cost. Let e = u, v be any edge in S. There are three cases.

(i) |u, v ∩ Tk| = 0. Remove e to produce a feasible solution of lower cost.

69

Page 81: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(ii) |u, v ∩ Tk| = 1. Without loss of generality, assume u ∈ Tk. If e is added to

S after level `u, remove it, because u must be covered by some other edge at

or prior to level `u. Otherwise, replace e with eu at level `u.

(iii) |u, v ∩ Tk| = 2. Without loss of generality, assume `u ≤ `v. If e is added

to S after level `v, remove it. If e appears at or before level `u, keep e in the

cover, but remove it from all levels prior to `u. Otherwise, e appears after

level `u but no later than level `v. In this case, replace e with ev at level `v.

Executing these modification on all edges in the original cover S neither affects the

feasibility of the cover nor increases its cost. All edges in the produced cover are

of the appropriate form and therefore the new cover is reduced.

Algorithm 3 Finds an optimal aggregate incremental edge cover.

We construct a subset edge cover instance (G′, c′, Tk) such that covers of G′ corre-

spond to reduced incremental covers of G of equal cost. There are two phases:

(i) Begin with the subgraph of G induced by Tk. For each e = u, v set c′(e) =

c(e)∑k

`=min`u,`v w`: the cost of using e to cover u and v in a reduced cover.

(ii) For each u ∈ Tk, create a new vertex u and edge u, u of cost c(eu)∑k

`=`uw`:

the cost of using eu to cover only u in a reduced cover.

We solve this single-level instance to obtain a minimum-cost subset edge cover S,

and build an incremental solution S = (S1, S2, . . . , Sk) as follows: if u, v ∈ S

then place u, v in Smin`u,`v, and if u, u ∈ S then place eu in S`u .

Lemma 4.5 Algorithm 3 finds a subset edge cover S of cost σ if and only if there

is a reduced incremental edge cover S of (G,T) with aggregate value σ.

70

Page 82: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

2

1

3

2 2

1

1

(a)

2

1

3

2

2

2

2

3 33

333

3

(b)

Figure 4.2: 4.2(a): A three-level instance of IEC. Labels indicate the level at

which vertices first appear in the target set. 4.2(b): A subset edge cover instance

constructed from the graph in 4.2(a), where shaded vertices are the target set.

[⇐] Given a reduced cover S, we build a subset edge cover S by considering each

edge e ∈ S. By definition, there are only two types of edges in a reduced cover. If

e = u, v for u, v ∈ Tk appears in S at level min(`u, `v) then include u, v in S.

Otherwise, e = eu for some u ∈ Tk and appears at level `u; in this case, include

u, u in S. Because S incrementally covers Tk, S covers Tk. Moreover, the cost of

S and S are edge-by-edge equivalent, therefore v(S) is exactly the aggregate value.

[⇒] For analogous reasons, any S produced as described in Algorithm IEC from

some S that covers Tk will be a feasible reduced v(S)-aggregate solution.

The proof of Theorem 4.3 follow from Lemmas 4.4 and 4.5.

4.4.2 Ratio Objective

Although there is a polynomial-time algorithm achieving the optimal aggregate

value for incremental edge cover, the situation is more complicated for the com-

petitive ratio, where we must deal with both complexity and competitiveness.

This section has three parts: the first and second explore unweighted and

weighted edge cover, respectively, and the third studies the strict competitive ratio.

71

Page 83: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

n copies

Figure 4.3: No algorithm is < 43-competitive on this instance. The level-1 target

nodes are shaded and the level-2 target nodes are white.

Unweighted Edge Cover

Theorem 4.6 No algorithm for incremental edge cover is < 43-competitive.

Proof. Consider the incremental edge cover instance given in Figure 4.3, con-

structed from n copies of a 3-edge gadget. Note that |S∗1 | = n, |S∗

2 | = 2n = 2 · |S∗1 |,

and that for each gadget we take either a (1, 3)-cover or a (2, 2)-cover. Suppose

there is a (43− α)-competitive algorithm for some α > 0. Then there is a constant

c such that |S1| ≤ (43− α)|S∗

1 |+ c, and

(43− α)|S∗

2 |+ c ≥ |S2| ≥ 2|S∗2 | − |S1|

≥ 2|S∗2 | − (4

3− α)|S∗

1 | − c

= 2|S∗2 | − 1

2(4

3− α)|S∗

2 | − c

= (43

+ 12α)|S∗

2 | − c.

Therefore c ≥ 3α4|S∗

2 |, a contradiction.

Thus for any number of levels, it is not possible to find an α-competitive algo-

rithm with α < 43. For k = 2, we have an algorithm that matches this bound.

Theorem 4.7 Two-level incremental edge cover is 43-competitive.

Proof. We argue that Algorithm 4 is 43-competitive. First observe that, since each

72

Page 84: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Algorithm 4 Finds a 43-competitive incremental edge cover.

Given input target sets T1 and T2, first find the minimum edge covers S∗1 , S

∗2 of

T1 and T2, respectively. Consider any edge e = u, v ∈ S∗1 \ S∗

2 . Without loss

of generality we may assume that both u, v ∈ T1 and u, v are covered by edges of

S∗2 \ S∗

1 at level 2. (If only u ∈ T1 then we swap e with the S∗2 edge that covers u.

If u is covered at level 2 with an edge in S∗2 ∩ S∗

1 then we swap e with the S∗2 \ S∗

1

edge covering v.) Initialize S1 = S∗1 ∩ S∗

2 .

While |S1| < b23|S∗

1 |c, select the remaining component C of S∗1 ∪ S∗

2 with the

smallest ratio|S∗2∩C||S∗1∩C| and set S1 = S1 ∪ (S∗

1 ∩ C), breaking the last component in

two, if necessary, to ensure |S1| ≤ b23|S∗

1 |c. For all remaining components C, set

S1 = S1 ∪ (S∗2 ∩ C ∩ T1). Let S∗

2 = S1 plus all edges of S∗2 \ S∗

1 with at most one

endpoint in S1.

edge of S∗1 has at most two edges of S∗

2 covering its endpoints,

|S1| ≤ b23|S∗

1 |c+ 2d13|S∗

1 |e ≤ 2

3|S∗

1 |+ 1.

Let C1, C2 denote the sets of components selected for S1 and S2\S1, respectively,

and let q be the ratio of the last component selected for S1. Then all components

C ∈ C1 have|S∗2∩C||S∗1∩C| ≤ q, all components C ∈ C2 have

|S∗2∩C||S∗1∩C| ≥ q, and

|S∗1 ∩ C1| ≥ 1

q|S∗

2 ∩ C1|,

|S∗1 ∩ C2| ≤ 1

q|S∗

2 ∩ C2|, and

|S∗2 ∩ C1| ≤ q|S∗

1 ∩ C1| ≤ q · 2|S∗1 ∩ C2| ≤ 2|S∗

2 ∩ C2|.

Since S∗2 = (S∗

2 ∩ C1) ∪ (S∗2 ∩ C2), we have |S∗

2 ∩ C2| ≥ 13|S∗

2 |. Let E0, E1, and E2

be the edges of (S∗2 \ S∗

1) ∩ C1 with zero, one, and two endpoints in (S∗1 \ S∗

2) ∩ C1,

73

Page 85: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

respectively. Then 2|(S∗1 \ S∗

2) ∩ C1| = |E1|+ 2|E2|, and

|S∗1 ∩ C1|+ |E1 ∪ E0| = |(S∗

1 ∩ S∗2) ∩ C1|+ |(S∗

1 \ S∗2) ∩ C1|+ |E1 ∪ E0|

= |(S∗1 ∩ S∗

2) ∩ C1|+ 12|E1|+ |E2|+ |E1 ∪ E0|

≤ |(S∗1 ∩ S∗

2) ∩ C1|+ 32|E1 ∪ E2 ∪ E0|

= |(S∗1 ∩ S∗

2) ∩ C1|+ 32|(S∗

2 \ S∗1) ∩ C1|

≤ 32|S∗

2 ∩ C1|.

Finally we get the desired bound on |S2|,

|S2| ≤ |S∗1 ∩ C1|+ |E1 ∪ E0|+ |S∗

2 ∩ C2|

≤ 32|S∗

2 ∩ C1|+ |S∗2 ∩ C2|

= 32|S∗

2 | − 32|S∗

2 ∩ C2|+ |S∗2 ∩ C2|

≤ 32|S∗

2 | − 12· 1

3|S∗

2 | = 43|S∗

2 |. ut

Theorems 4.6 and 4.7 show that for two levels, no algorithm has better com-

petitive ratio than Algorithm 4. Algorithm 4 is not optimal, however: there are

instances, as in Figure 4.4, for which it obtains a competitive ratio of 43

although

better solutions exist. In the bipartite matching analog, we were able to show that

an optimal algorithm existed by using a black box that found the maximum-weight

matching of a certain size. Unfortunately, we have no such algorithm for the in-

cremental edge cover problem. We are able, however, to use the general result of

Theorem 4.2 to get a 4-competitive algorithm for k ≥ 3 levels.

Weighted Edge Cover

The addition of edge weights significantly changes both the complexity and com-

petitiveness of edge cover, although not as considerably as the weighted bipartite

matching problem (whose competitive ratio became arbitrarily small).

74

Page 86: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(a) (b) (c)

Figure 4.4: The bold edges in 4.4(b) and 4.4(c) show two possible S∗1 of 4.4(a). If

Algorithm 4 selects the edge cover in 4.4(b) then it can be 1-competitive; however,

if it selects the edge cover in 4.4(c) then it can at best be 43-competitive.

Theorem 4.8 There is no ϕ-competitive algorithm for incremental weighted edge

cover.

Proof. Consider the incremental weighted edge cover instance given in Figure

4.5. Note that |S∗1 | = 1

ϕA and |S∗

2 | = A. Suppose there is a (ϕ − α)-competitive

algorithm for some α > 0. Then there is a constant c such that |S1| ≤ (ϕ−α)|S∗1 |+c

and |S2| ≤ (ϕ− α)|S∗2 |+ c. Then

|S1| = A ⇒ (ϕ− α) 1ϕA + c ≥ |S1| = A

⇒ c ≥ α 1ϕA, a non-constant, and

|S1| = 1ϕA ⇒ (ϕ− α)A + c ≥ |S2| = A + 1

ϕA

⇒ c ≥ αA, also a non-constant.

Therefore no such α exists.

In contrast to the weighted bipartite matching problem, we have a constant

bound on the competitive ratio, and this bound is tight due to Theorem 4.1. Thus

75

Page 87: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

A1

ϕA

Figure 4.5: No incremental algorithm is < ϕ-competitive on this instance, for A

defined in the proof of Theorem 4.8. The black vertex is in neither T1 nor T2.

for edge cover, the incremental constraint adversely affects the problem’s compet-

itiveness, but by at most a constant factor. However, there are still instances on

which the general ϕ-competitive algorithm does not obtain the optimal ratio; in

fact, finding such an optimal algorithm is NP-hard.

Theorem 4.9 No algorithm for two-level incremental weighted edge cover achieves

the optimal competitive ratio on every instance, unless P = NP .

We prove Theorem 4.9 by a reduction from Partition, an NP-hard problem [57].

Given a finite set A and sizes s(a) ∈ Z+ for all a ∈ A, a partition of A is some

A′ ⊆ A such that∑

a∈A′ s(a) =∑

a∈A\A′ s(a). We construct a 2-level instance of

IEC such that the optimal competitive ratio is 1+ϕ2

if and only if A has a partition.

We start with a vertex s, and for each element a ∈ A, we create vertices ua, va

and edges e1a = s, ua, e2

a = ua, va of cost C · s(a) and ϕ · C · s(a), respectively,

for some C > 1. The target sets are T1 =⋃

a∈A ua and T2 =⋃

a∈Aua, va; this

construction is shown in Figure 4.6.

Let S =∑

a∈A s(a). The optimal level-one cover S∗1 is all e1

a edges and has cost

C · S. The optimal level-two cover S∗2 is all e2

a edges and has cost ϕ · C · S.

Lemma 4.10 The optimal competitive ratio of this construction is at least 1+ϕ2

.

Proof. By way of contradiction, suppose there is an algorithm finding (S1, S2)

such that v(S1) ≤ (1+ϕ2− α)v(S∗

1) + c and v(S2) ≤ (1+ϕ2− α)v(S∗

2) + c for some

76

Page 88: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

C · s(a1) ϕ · C · s(a1)

ϕ · C · s(a2)

ϕ · C · s(a3)C· s(a3)

C · s(a2)s

ua1

ua2

ua3va3

va2

va1

Figure 4.6: The two-level IEC graph for partition instance A = a1, a2, a3.

α > 0 and constant c. If we take C > cα·ϕ·S then v(S2) < 1+ϕ

2v(S∗

2). Note that

v(S2) = ϕ · CS + C · d for some integer d ≥ 0, so v(S2) ≤ ϕ · CS + (S2− 1

2)C, and

v(S1) ≥ ϕ · CS − (ϕ− 1)(v(S2)− ϕ · CS)

≥ ϕ · CS − (ϕ− 1)(ϕ · CS + (S2− 1

2)C − ϕ · CS)

= ϕ · CS − (ϕ− 1)(S2− 1

2)C

= ϕ+12

CS + ϕ−12

C.

Then c ≥ αv(S∗1) + ϕ−1

2C, a contradiction to c being constant.

Lemma 4.11 There is a partition of A if and only if there is a 1+ϕ2

-competitive

incremental cover.

Proof. [⇒] Given a partition A′ ⊆ A such that∑

a∈A′ s(a) = S2, we construct an

incremental cover (S1, S2) by selecting S1 = e1a | a ∈ A′ ∪ e2

a | a ∈ A \ A′ and

S2 = S1 ∪ e2a | a ∈ A′. This is a feasible solution, as both va and wa are covered

for each element a ∈ A. Furthermore,

v(S1) = C∑

a∈A′ s(a) + C∑

a∈A\A′ ϕs(a) v(S2) = ϕ · CS + C∑

a∈A′ s(a)

= CS2

+ ϕCS2

= ϕ · CS + CS2

= 1+ϕ2

v(S∗1) = 1+ϕ

2v(S∗

2) .

[⇐] Suppose we have a 1+ϕ2

-competitive cover (S1, S2). Then we claim that v(S2) =

1+ϕ2

v(S∗2), using the fact that v(S2) = ϕ · CS + C · d for some integer d ≥ 0:

77

Page 89: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

v(S2) > ϕ+12

v(S∗2) implies v(S2) ≥ ϕ·CS+(S

2− 1

2)C, and S2 is not ϕ+1

2-competitive.

Conversely, v(S2) < ϕ+12

v(S∗2) implies v(S2) ≤ ϕ · CS + (S

2− 1

2)C, and S1 is not

competitive by Lemma 4.10. Thus (S1, S2) is such that v(S2) = 1+ϕ2

CS; we define

A′ = a | e1a ∈ S2 so that

∑a∈A′ s(a) = 1

C(v(S2)− ϕCS) = S

2.

Theorem 4.9 follows from Lemmas 4.10 and 4.11. As with bipartite matching,

it may be possible to find an algorithm achieving the optimal competitive ratio on

instances with polynomial-size edge weights.

Strictly Competitive Edge Cover

When we consider the strict competitive ratio, we have the following results.

Theorem 4.12 There is no strictly α-competitive algorithm for incremental edge

cover, for α < 32.

Proof. Consider one copy of the 3-edge gadget of Figure 4.3. In order to achieve

a strict 32-competitive ratio, an algorithm must find |S1| ≤ 3

2. Integrality implies

that |S1| = 1, therefore |S2| = 3 = 32|S∗

2 |.

The algorithms of Theorems 4.1 and 4.2 find strictly competitive solutions for 2

and k ≥ 3 levels, respectively, for both unweighted and weighted edges. Moreover,

the reduction of Theorem 4.9 also holds for strict competitive ratio.

4.5 Minimum Cut

Given a directed network G = (V, E) with source s, sink t, and a capacity function

c : E → Q, the minimum cut problem finds a minimum capacity s-t cut, that is, a

minimum capacity set of edges S ⊆ E such that all paths directed from s to t are

disconnected in G \ S. In terms of our model, the objects are the edges of G, and

78

Page 90: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

feasible solutions are subsets of E that cut s from t. The cost of a cut is the sum

of the weights of its edges, v(S) =∑

e∈S ce. Minimum cut is the dual problem to

network flow, and can thus be solved in polynomial time.

Incremental cut is defined on a directed network G = (V, E) with source s, sink

t, and a non-decreasing sequence of k capacity functions c` : E → Q. A solution

is a sequence of edge sets (S1, S2, . . . , Sk) such that S` is an s-t cut of (G, E`) and

S` ⊆ S`+1. The minimum single-level cut for level ` is denoted by S∗` .

4.5.1 Aggregate Objective

As with the network flow problem, we show that the incremental structure in-

creases the complexity of minimum cut from polynomial-time to NP-hard for both

objectives.

Theorem 4.13 No algorithm for two-level incremental cut achieves the optimal

aggregate value on every instance in polynomial time, unless P = NP .

Theorem 4.13 follows via a reduction from 3-SAT. Given a formula φ with n vari-

ables and m clauses, we construct an incremental cut instance (G1, G2) such that

the optimal aggregate value is 18m if and only if φ is satisfiable.

Create source s, sink t, auxiliary vertices s′, t′, and edges (s, s′), (t′, t) of capacity

C > 0. Let |v| denote the number of literals using variable v or its negation v.

For each v, create 2|v| unit-capacity edges e1v, e

2v, . . . , e

|v|v , e1

v, e2v, . . . , e

|v|v joined by

high-capacity edges as shown in Figure 4.7(a). Connect all variable gadgets in

parallel between s′ and t′ using high-capacity edges to form G1 as in Figure 4.7(b).

Next construct the level-two graph G2. First add high-capacity bypass edges

(s, t′) and (s′, t). Then for each clause c, create an s-t path that passes in series

79

Page 91: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

e1

ve2

ve3

ve4

v

e4

ve3

ve2

ve1

v

(a)

e1

ve2

ve3

ve4

v

e4

ve3

ve2

ve1

v

s

s′

t′

t

C

C

e1

we2

we3

we2

ue1

u

e1

ue2

ue2

we1

we3

w

(b)

e1

v

s

s′

t′

t

C

C

e3

w

e1

u

(c)

Figure 4.7: 4.7(a): A variable gadget. 4.7(b): The level-one graph. 4.7(c): The

level-two graph, showing bypass edges and a clausal path for clause c = u, v, w.Bold edges have prohibitively high cost. Thin edges have unit cost unless labelled

otherwise. Solid edges are level-one edges whereas dashed edges are level-two edges.

through some ei` for each of the three literals ` in c; these paths are such that

every ei` edge is used by at most one clausal path, and non-ei

` edges are given

high capacity. The bypass edges and one example clausal path are illustrated

in Figure 4.7(c). Give the high-capacity edges capacity 20m, thereby preventing

their use in any reasonable-cost solution. Finally, replace capacity c edges with c

unit-capacity parallel paths.

Set C = 6m. Then all minimum cuts of G1 have cost 3m and contain either all

eiv edges or all ei

v edges for each variable v; the only other reasonable-cost minimal

cuts are (s, s′) and (t′, t) which cost C > 3m. Moreover, all reasonable-cost

cuts of G2 contain both (s, s′) and (t′, t). The graph G2 can be cut optimally at

cost 2C + m = 13m by cutting (s, s′), (t′, t), and the first unit-cost edge in each of

the m clausal paths. Lemma 4.14 completes the proof.

80

Page 92: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Lemma 4.14 There is a satisfying assigment iff there is an 18m-aggregate cut.

[⇒] Given a satisfying assignment A, we construct an incremental cut as follows:

if A(v) = true then cut all eiv, otherwise cut all ei

v. This selection of 3m edges is

a cut of G1. To cut G2, we only add (s, s′) and (t′, t). This costs an additional

2C = 12m, yielding an incremental cut with aggregate value 3m + 15m = 18m.

We claim these edges are sufficient to cut s from t in G2: if not, then some s-t

path would remain. Because (s, s′) is cut, this path must originate along one of

the m clausal paths. It cannot follow such a path all the way from s to t, as each

clause contains one true literal whose edge is contained in our G1 cut. On the other

hand, any deviation from a clausal path is only possible immediately after the path

passes through an eiv or ei

v edge. If it deviates after an edge of the form eiv, then

the only path remaining to t passes through the cut edge (t′, t), a contradiction.

And if it deviates after an edge of the form eiv, then all ei

v must be cut, and it is

impossible to exit the variable gadget except to follow the clausal path.

[⇐] Now suppose we are given an incremental cut (S1, S2) with aggregate value

18m. Without loss of generality, we may assume that the cut S1 is minimal.

Furthermore, we claim that neither (s, s′) nor (t′, t) is contained in S1; if they

were, then our aggregate value would be at least 6m + 13m = 19m > 18m. Thus

the cut S1 must contain either all eiv or ei

v edges for each variable v, at cost 3m. This

defines our truth assignment A: set A(v) = true if all eiv are cut and A(v) = false

if all eiv are cut. In addition to S1, the cut S2 contains only (s, s′) and (t′, t); if it

contained even one more edge, it would have aggregate value 3m+15m+1 > 18m.

Hence the addition of (s, s′) and (t′, t) to S2 must suffice to cut s from t in G2, and

all clausal paths are cut by our level-one cut, indicating that under our assignment

every clause contains at least one true literal.

81

Page 93: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

A ϕ · A

1ϕ · A + 2

s t

Figure 4.8: No incremental algorithm is < ϕ-competitive on this instance, for A

defined in Theorem 4.8.

Thus, finding the optimal aggregate value is not possible. However, Theorems

4.1 and 4.2 give ϕ- and 4-approximations to the optimal aggregate value for k =

2 and k ≥ 3, respectively. These bounds are much nicer than the tight 1Hk

-

approximation for incremental flow, illustrating that the incremental versions of

dual problems are not themselves duals.

4.5.2 Ratio Objective

Theorem 4.15 No algorithm for incremental cut is < ϕ-competitive.

Proof. Consider the incremental cut instance given in Figure 4.8. Note that

|S∗1 | = A and |S∗

2 | = ϕ · A + 1. Suppose there is a (ϕ − α)-competitive algorithm

for some α > 0. Then there is a constant c such that |S1| ≤ (ϕ − α)|S∗1 | + c and

|S2| ≤ (ϕ− α)|S∗2 |+ c. Then

|S1| = ϕ · A ⇒ (ϕ− α)A + c ≥ |S1| = ϕ · A

⇒ c ≥ αA, a non-constant, and

|S1| = A ⇒ (ϕ− α)(ϕ · A + 1) + c ≥ |S2| ≥ A + ϕ · A + 1

⇒ c ≥ α(ϕ · A + 1)− ϕ + 1, also a non-constant.

Therefore no such α exists.

82

Page 94: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

A ϕ · A

s

ϕ · A

t

(a)

A ϕ · A

s

ϕ · A

t

(b)

A ϕ · A

s

ϕ · A

t

(c)

Figure 4.9: The bold edges in 4.9(b) and 4.9(c) show two possible S∗1 of 4.9(a). If

the algorithm of Theorem 4.1 selects the cut in 4.9(b) then it can be 1-competitive;

however, if it selects the cut in 4.9(c) then it can at best be ϕ-competitive.

This bound is matched by the two-level algorithm of Theorem 4.1; however,

there are instances, as in Figure 4.9, for which this tight algorithm is not optimal.

As with incremental flow, such an optimal algorithm is NP-hard to find.

Theorem 4.16 No algorithm for two-level incremental cut achieves the optimal

competitive ratio on every instance in polynomial time, unless P = NP .

Proof. We modify the reduction from Theorem 4.13 by multiplying each edge

capacity by a suitably large D ≥ 1. We then claim that a formula φ is satisfiable

if and only if there is a 1513

-competitive incremental cut.

[⇒] Given a satisfying assignment A, Theorem 4.13 describes how to construct a

(3mD, 15mD)-cut, which is 1513

-competitive.

[⇐] Suppose we have a 1513

-competitive incremental cut (S1, S2). Then there exists

a constant c such that v(S1) ≤ 1513

v(S∗1) + c and v(S2) ≤ 15

13v(S∗

2) + c. If either

(s, s′) or (t′, t) are contained in S1 then v(S1) ≥ 6mD = 1513

3mD + 3313

mD, which

is a contradiction for c < 3313

mD. Thus the cut S1 must contain either all eiv or ei

v

edges for each variable v, at cost 3mD. If S1 contains more than 3m edges then

v(S2) ≥ 15mD + D = 1513

13mD + D, which is a contradiction for c < D. Therefore

the cut S1 defines our truth assignment as in Theorem 4.13.

83

Page 95: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Therefore both incremental flow and incremental cut are NP-hard; however,

the latter has a constant-competitive algorithm, but the former does not.

4.6 r-Domination

Given a set of points in a metric space, the (k, r)-center problem finds a set of at

most k centers to open such that every point is within distance r of some open

center. There are two natural approaches (k, r)-center.

(i) k-center : fix the number of centers k and minimize the maximum distance

between any client and its closest center. The k-center problem is NP-hard;

however, Gonzalez [39] gives a 2-approximation algorithm.

(ii) r-domination [6, 37]: fix the radius r and cover all clients with as few cen-

ters as possible. The r-domination problem is NP-hard; the current best

algorithm is an O(log n)-approximation [6].

Incremental k-center is a well-studied problem [66, 71, 64, 21]; the input is the

same as k-center, but the goal is to find a sequence of k centers such that, for any

`, the first ` centers are competitive with the optimal `-center solution. The k-

center problem is not monotonic and therefore our model does not apply; however,

Gonzalez’ 2-approximation [39] translates to a 2-competitive incremental solution.

In contrast, there is no known work on incremental r-domination, but we can

apply our general model. The objects are potential center locations, and feasible

solutions are sets of centers that cover an incrementally increasing client base. This

precisely models restaurant expansion. Theorem 4.2 and the log n-approximation

of [6] yield a 4 log n-approximation for incremental r-domination – a new problem

and solution which arise naturally from our general minimization model.

84

Page 96: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 5

Alternative Incremental Formulations

5.1 Introduction

Chapters 3 and 4 discuss some standard minimization and maximization problems,

along with their natural incremental formulations. Each of these problems has

several possible incremental definitions, only one of which was explored in depth.

The selected variants are not the only interesting formulations, they are just the

most instructive; not only are alternative definitions of practical interest, they can

admit different complexity and competitiveness results.

There are two steps to constructing an incremental problem. First one must

decide which single-level problem to make incremental, and then which param-

eter to change over time. For example, the maximum flow problem has many

variations, such as fractional and undirected flow; the incremental problems differ

greatly depending on which problem is chosen as the basis. Varying the incremen-

tal parameters can have a similar effect; for example, Chapter 3 studies incremental

bipartite matching where the edges appear over time. An equally appealing model,

however, has edge costs increasing, rather than edge sets. Both formulations seem

reasonable, yet the choice could lead to different performance results.

Both of these decisions can produce a wide variety of problems suiting different

situations. We look at two examples of the first decision by studying incremental

versions of undirected and fractional flow; we find that removing directionality

does not change the complexity or competitiveness of the problem from the di-

rected version, yet allowing fractional solutions improves both the complexity and

competitiveness. We then consider two examples of the second decision by study-

85

Page 97: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ing incremental versions of minimum spanning tree and edge cover. We find that

the complexity and competitiveness of incremental spanning tree varies depending

on whether node sets or edge costs are increasing over time. Moreover, we study a

new version of edge cover with different complexity than that of the version studied

in Chapter 4, although its competitiveness is unchanged.

5.2 Network Flow

Chapter 3 studies a version of network flow where the underlying network is di-

rected and flow must be integral. In this section we consider both undirected and

fractional flow as the underlying problem in our incremental setting, and discuss

how this variation affects incremental performance. We investigate the undirected

and fractional cases separately in the following two sections, focusing on the strict

competitive ratio objective. Many of the proofs appear in [46], and are omitted.

5.2.1 Fractional Flow

For a network with integer edge capacities, the optimal fractional flow is no larger

than the optimal integral flow [28, 29, 30]. This property does not carry over to

flow’s incremental variant, however, as even with integer capacities, a fractional

incremental flow may have better competitive ratio than the best integral solution.

Theorem 3.21 shows that no integral incremental flow is strictly α-competitive for

α > 2n

on the instance of Figure 3.11; with fractional flow there is a strictly 12-

competitive solution that sends a 12

unit of flow along each level-1 flow path, leaving

at least half the capacity of each edge free for the level-2 flow. We generalize

this concept to a simple 1k-competitive algorithm for any k-level incremental flow

instance.

86

Page 98: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Theorem 5.1 The incremental fractional flow problem is strictly 1k-competitive.

Proof. First determine optimal single-level integral flows f ∗1 , f∗

2 , . . . , f ∗k . For each

edge e, set f`(e) = f`−1(e) + 1kf ∗

` (e), where f0(e) = 0. The incremental constraint

and flow conservation are easily verified; the capacity constraints are satisfied

because f`−1(e) = 1k

∑`−1i=1 f ∗

i (e) ≤ `−1k

f ∗`−1(e) ≤ k−1

kf ∗

` (e). Finally, |f`| ≥ 1k|f ∗

` |,

and we have the desired strict competitive ratio.

Thus we see a contrast between integral and fractional flow: no algorithm is

more than strictly 2n-competitive for the former, whereas the latter admits strictly

1k-competitive solutions. Moreover, it is NP-hard to find the optimal strict com-

petitive ratio for integral flows (Theorem 3.20); this is not true of fractional flows.

Theorem 5.2 There is an algorithm for incremental fractional flow that achieves

the optimal strict competitive ratio on every instance.

Proof. The proof relies on linear programming techniques; see [46] for details.

The linear programming (LP) techniques used in Theorem 5.2, although of the-

oretical interest, are impractical in many situations due to the constant associated

with solving LPs. This motivates a search for faster algorithms that find either

optimal or even approximate solutions. We give a polynomial-time approximation

scheme to find a near-optimal solution in almost polynomial-time.

Theorem 5.3 For any ε > 0, there is a strictly (1− ε)3-competitive algorithm for

k-level incremental fractional flow with runtime O(S(m, k)(mk + k2)1εlog1+ε

km1−ε

),

where S(m, k) is O(mk)+ the running time for a shortest paths algorithm.

Proof. The proof, described in [46], is based on the techniques of [36, 27, 76].

Thus we conclude that both complexity and competitiveness are much improved

if we study an incremental model based on fractional rather than integral flow.

87

Page 99: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

5.2.2 Undirected Flow

We now examine incremental networks where the underlying edges are undirected.

In such networks, each edge e = u, v is considered as two directed edges e = (u, v)

and e = (v, u). There are two possible interpretations of undirected edges: in

bidirected networks, both e and e can carry flow provided that their sum is less

than c(e). In unidirected networks, either e or e can carry flow, but not both.

These two interpretations are equivalent in the integral unit-capacity case.

Theorem 5.4 There is no strictly α-competitive algorithm for incremental undi-

rected flow for α > 2n.

Proof. We remove directionality from Figure 3.11; Theorem 3.21’s proof carries

over directly for both bidirected and unidirected flow.

As with integral flow, but unlike fractional, it is NP-hard to find the optimal

competitive ratio for both bidirected and unidirected flow.

Theorem 5.5 No algorithm for two-level incremental undirected flow achieves the

optimal strict competitive ratio on every instance, unless P = NP .

Proof. The result follows with slight modification from Theorem 3.20’s reduction;

see [46] for details.

With fractional flows, however, the bidirected case becomes tractable.

Theorem 5.6 There is an algorithm for incremental bidirected fractional flow that

achieves the optimal strict competitive ratio on every instance.

Proof. Incremental bidirected fractional flow can be formulated as an LP; see [46]

for details.

88

Page 100: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Unfortunately, unidirected fractional flow contains a non-linear constraint and

therefore cannot be modeled by an LP. Thus LP techniques cannot be used to

solve the problem optimally, moreover, neither can any polynomial technique.

Theorem 5.7 No algorithm for 3-level incremental unidirected fractional flow

achieves the optimal strict competitive ratio on every instance, unless P = NP .

Proof. The result follows with slight modification from Theorem 3.20’s reduction;

see [46] for details.

5.3 Minimum Spanning Tree

Given an undirected graph G = (V, E) with edge cost ce ≥ 0 for each edge e ∈ E,

the minimum spanning tree (MST) problem finds a minimum-cost tree T ⊆ E

that spans all nodes of V . This is a classic problem in theoretical computer science

with many paradigmatic polynomial-time algorithms [60].

Minimum spanning tree fits the minimization model of Chapter 4; the objects

are the edges E, and feasible solutions are minimal edge sets that span V . If we

apply Chapter 4’s model directly then our incremental input is a graph G = (V, E)

with an increasing set of vertices V1 ⊆ V2 ⊆ · · · ⊆ Vk ⊆ V that must be covered at

each step using subsets of E. This is a special case of the incremental Steiner tree

problem discussed in Section 2.4.3, that is, our general model produces incremental

versions of MST and SMT that are very similar. This formulation of MST is

therefore nothing new, and we consider two alternative constructions that define

problems not special cases of Steiner tree.

89

Page 101: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

5.3.1 Node-Incremental Spanning Tree

In the first formulation, the input is a graph G = (V, E) with a sequence of

vertices V1 ⊆ V2 ⊆ · · · ⊆ Vk ⊆ V , that is, nodes arrive over time. The goal is

to find an incremental sequence of trees (T1, T2, . . . , Tk), where T` spans precisely

the vertices of V`. We call this the node-incremental spanning tree problem. This

model prohibits a solution T` from using edges with endpoints in V \V`; therefore, it

is possible for v(T ∗` ) < v(T ∗

`−1), where T ∗` denotes level `’s minimum spanning tree.

Thus the model does not display Steiner Tree’s modified monotonicity property

(Section 2.4.3), and Theorem 4.2’s 4-competitive algorithm does not apply.

Let E` ⊆ E be the set of edges with both endpoints in V`, that is, the edges of

the subgraph induced by V`, and let cmin` , cmax

` denote the minimum- and maximum-

cost of any edge in E`, respectively. Define r∗n = max`cmax` /cmin

` .

Theorem 5.8 There is no α-competitive algorithm for node-incremental spanning

tree for α < r∗n.

Proof. Consider the node-incremental spanning tree instance given in Figure

5.1, where A = r∗nB. Note that v(T ∗1 ) = A(n − 1), v(T ∗

2 ) = Bn, and r∗n = A/B.

Suppose there is an (r∗n − α)-competitive algorithm for some α > 0. Then there is

a constant c such that v(T1) ≤ (r∗n − α)A(n− 1) + c, and

(A

B− α)Bn + c ≥ v(T2) = A(n− 1) + B.

Therefore c ≥ αBn + B − A, which is not a constant.

Therefore no algorithm achieves ratio better than r∗n on all instances of node-

incremental spanning tree. This bound can be arbitrarily bad, as r∗n is not bounded

from above; however, there is an algorithm matching this r∗n bound.

90

Page 102: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

A

B

A A A

B B B B

n copies

Figure 5.1: All incremental algorithms are at best r∗n-competitive on this instance;

level-1 nodes and edges are solid, level-2 nodes and edges are dashed.

Theorem 5.9 There is an r∗n-competitive algorithm that achieves the optimal com-

petitive ratio and aggregate value for node-incremental spanning tree.

Proof. The algorithm initializes T1 = T ∗1 ; for each subsequent level `, it sets

T` = T`−1, then repeatedly adds the cheapest edge connecting each node of V`\V`−1

to the current minimum tree T`. We can view this as contracting V`−1 into a single

vertex v`−1 and running Prim’s MST algorithm [40, 69, 60] on v`−1∪ (V` \V`−1).

Let (S1, S2, . . . , Sk) denote any incremental solution; we show that v(T`) ≤

v(S`) for all `, which will imply the optimality of (T1, T2, . . . , Tk) for both the

aggregate and ratio objectives. Clearly v(T1) = v(T ∗1 ) ≤ v(S1). Now suppose by

induction that v(T`−1) ≤ v(S`−1). By the optimality of Prim’s algorithm we know

v(T` \ T`−1) ≤ v(S` \ S`−1), implying v(T`) ≤ v(S`).

Any spanning tree of |V`| contains |V`|−1 edges, therefore v(T`) ≤ cmax` (|V`|−1),

v(T ∗` ) ≥ cmin

`−1 (|V`| − 1), and our solution is r∗n-competitive.

Theorem 5.9’s greedy algorithm is not only incremental, but also online, there-

fore both incremental and online spanning tree are r∗n-competitive; moreover, no

incremental algorithm can do any better. Online spanning tree is thus an ex-

ample of a problem whose incremental constraint contributes significantly to the

competitive ratio, whereas the adversarial constraint contributes nothing.

91

Page 103: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

5.3.2 Cost-Incremental Spanning Tree

Consider another incremental model of spanning tree, where the input is a single

graph G = (V, E) with a non-decreasing sequence of cost functions c, that is,

edge-costs increase over time; the goal is to find a single tree T that is good at all

levels. We call this the cost-incremental spanning tree problem. As with the node-

incremental version, there is an algorithm finding the optimal aggregate value.

Theorem 5.10 There is an algorithm that achieves the optimal aggregate value

on every instance of cost-incremental spanning tree.

Proof. Given a cost-incremental spanning tree instance (G, c), we construct an

instance (G, c′) of the MST problem by setting c′(e) =∑k

`=1 w`c`(e). Then the

cost of spanning tree T of G with respect to c′ is precisely its aggregate value.

Let cmin` , cmax

` denote the level ` minimum- and maximum-cost of any edge e,

that is, cmin` = mine∈Ec`(e), cmax

` = maxe∈Ec`(e). Define r∗c = max`cmax` /cmin

` .

Theorem 5.11 There is no α-competitive algorithm for cost-incremental spanning

tree for α < r∗c .

Proof. Consider the cost-incremental spanning tree instance shown in Figure 5.2,

where A = r∗cB. Note that v(T ∗1 ) = 4, v(T ∗

2 ) = 4B, and r∗c = A/B. Suppose there

is an (r∗c − α)-competitive algorithm for some α > 0. Then there is a constant c

such that v(T1) ≤ (r∗c − α)4 + c and v(T2) ≤ (r∗c − α)4B + c. Furthermore,

v(T1) = 4 ⇒ v(T2) = 4A = AB

4B

⇒ c ≥ α4B, a non-constant, and

v(T1) > 4 ⇒ v(T1) ≥ 3 + B

⇒ c ≥ 4α + 3 + B − 4r∗c .

92

Page 104: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(1, A) (1, A)

(1, A)

(1, A)

(B,B)

(B,B)(B,B)

(B,B)

Figure 5.2: All incremental algorithms are at best r∗c -competitive on this instance;

the edge vectors display the level-1 and level-2 costs.

We set B ≥ 4r∗c + c to obtain a contradiction.

Once again, there is an algorithm matching this lower bound.

Theorem 5.12 There is an r∗c -competitive algorithm for cost-incremental span-

ning tree.

Proof. We claim T ∗1 is r∗c -competitive. Let S∗ be any solution. Then at level `,

v`(S∗) =

∑e∈S∗ c`(e) ≥ cmin

` (|V | − 1), and v`(T∗1 ) ≤ cmax

` (|V | − 1) ≤ cmax`

cmin`

v`(S∗` ).

Thus there are tight competitive algorithms for both node-incremental and cost-

incremental spanning tree; however, unlike the former, we cannot easily obtain the

optimal competitive ratio for the latter.

Theorem 5.13 No algorithm for cost-incremental spanning tree achieves the op-

timal ratio on every instance, unless P = NP .

Proof. We prove Theorem 5.13 by a reduction from Partition, as in Theorem

4.9. We construct a 2-level instance of cost-incremental spanning tree such that

the optimal competitive ratio is 1+ϕ2

if and only if the set A has a partition.

93

Page 105: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

(0, 0)

(0,0)

(0, 0)

(0,0)

(0, 0)

(0,0)

(ϕCs(a1),ϕCs(a

1))

(ϕCs(a2),ϕCs(a

2))

(ϕCs(a3),ϕCs(a

3))

(Cs(a3),ϕ

2 Cs(a3))

(Cs(a1),ϕ

2 Cs(a1))

(Cs(a2),ϕ

2 Cs(a2))

Figure 5.3: The two-level cost-incremental spanning tree instance for partition

instance A = a1, a2, a3.

For each element a ∈ A, we create a gadget consisting of two parallel two-edge

paths. One edge from each path has cost (0, 0); the other two edges have cost

(C ·s(a), ϕ2C ·s(a)) and (ϕC ·s(a), ϕC ·s(a)), for some C > 1. Let S =∑

a∈A s(a).

Then the optimal level-one spanning tree S∗1 has cost CS and the optimal level-two

spanning tree S∗2 has cost ϕCS. This construction is shown in Figure 5.3.

From this point onward, the proof follows that of Theorem 4.9 exactly, that is,

Lemmas 4.10 and 4.11 can be applied directly.

Therefore the three versions of incremental spanning tree, defined by three

different incremental input, yield different complexity and competitiveness results.

5.4 Edge Cover

Chapter 4 studies the incremental version of the subset edge cover problem, defined

by an increasing sequence of target vertices T1 ⊆ T2 ⊆ · · · ⊆ Tk ⊆ V that must

be covered by edges at each stage. Here we consider the incremental version of

the standard edge cover problem, defined by an increasing sequence of graphs

G1 ⊆ G2 ⊆ · · · ⊆ Gk, where G` = (V`, E`), and V` must be covered at each stage

using edges of E`. The results are more straightforward because the latter version

is a special case of the former. In fact, Theorems 4.6 and 4.7 apply directly to

94

Page 106: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

show there is a tight 43-competitive algorithm for this version of the incremental

edge cover problem. For subset edge cover, however, we did not find an algorithm

achieving the optimal competitive ratio on each instance; such an algorithm would

need to decide whether to cover a current vertex with an expensive edge from a

future level or with a cheaper edge from the current level. There is no such trade-

off in the standard edge cover formulation; we are restricted to using edges with

both endpoints in the current level. This enables us to find an optimal algorithm.

Theorem 5.14 There is an algorithm for incremental standard edge cover that

achieves the optimal competitive ratio and aggregate value on every instance.

Proof. The algorithm initializes S1 = S∗1 , then for each subsequent level `, sets

S` = S`−1∪minimum subset edge cover of V` \ V`−1 in the graph induced by V`.

Let (U1, U2, . . . , Uk) be any incremental solution. We show that v(S`) ≤ v(U`) for

all ` ≤ k, which will imply the optimality of (S1, S2, . . . , Sk) for both the aggregate

and ratio objectives. Certainly v(S1) = v(S∗1) ≤ v(U1). By induction, suppose that

v(S`−1) ≤ v(U`−1). At step `, we add the minimum subset edge cover of V` \ V`−1.

Note that U` \ U`−1 is also such a cover, thus v(S` \ S`−1) ≤ v(U` \ U`−1). Then

v(S`) = v(S`−1) + v(S` \ S`−1) ≤ v(U`−1) + v(U` \ U`−1) = v(U`).

This algorithm applies even with weighted edges; therefore, the complexity

of finding the optimal competitive ratio is polynomial-time, whereas it was NP-

hard for the subset edge cover version (Theorem 4.9). Edge cover is thus another

example of a problem where different incremental formulations have different com-

plexities.

95

Page 107: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 6

Algorithmic Extensions

6.1 Introduction

The algorithms presented thus far have two properties in common: they (1) are

deterministic, and (2) produce incremental solutions. This chapter investigates

whether relaxing these properties can result in improved performance.

Certainly when the input sequence is not known in advance (as with online

algorithms), randomization can help mitigate some of the adversarial constraint’s

power, thereby lessening its contribution to the competitive ratio. Even when the

input sequence is known, however, randomization can still improve performance;

that is, it can diminish the incremental constraint’s contribution to the competitive

ratio. At first glance this may seem surprising, as the input is deterministic;

however, randomization has been used with deterministic input to solve problems

such as MAX-3SAT [53] and global minimum cut [56].

The incremental constraint is reasonable in general, but there are situations in

which violating the constraint is desirable. If we remove the constraint altogether,

however, allowing unlimited violations, then our model degenerates into the single-

level problem: using each individual level’s optimal solution is now feasible. We

find a balance between these two extremes by considering a model that allows

incremental constraint violations, but charges a penalty p for each such infraction.

For example, if p = 0, then we ignore the incremental constraint completely; in

this case, an α-approximation for the single-level problem leads to an α-competitive

algorithm for its incremental formulation by just using each level’s α-approximate

solution. At the other end of the spectrum, if p is large, then the incremental

96

Page 108: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

constraint is law, and the best we can do is determined by the results of the model

without penalties. How do we deal with values of p between these extremes?

Clearly, the complexity of any problem with the addition of penalties cannot

be better than that without, as setting p very large reduces the former problem to

the latter. Similarly, the competitiveness cannot improve; however, we can hope to

express an algorithm’s competitive ratio as a function of p such that small values

of p lead to improved competitiveness.

6.1.1 Results

We first consider probabilistic algorithms and find that randomization leads to

an improved competitive algorithm for k-level covering problems; in particular,

Theorem 4.2’s 4α competitive ratio is lowered to an expected ratio of eα, where α

is the best-known approximation bound for the single-level covering problem.

We then relax the incremental constraint by studying a model whose solu-

tions can violate the constraint at a cost of p for each such violation. We con-

sider the (unweighted) bipartite matching problem, and find we can achieve a

max2/3, |M∗2 |/(|M∗

2 |+ p|M∗1 |)-competitive algorithm for any penalty p ≥ 0.

6.2 Probabilistic Algorithms

We use ideas from [64] to show that randomization improves Theorem 4.2’s de-

terministic 4α-competitive algorithm for covering problems to a probabilistic algo-

rithm with expected competitiveness of eα.

Theorem 6.1 Given an α-approximate algorithm A for a problem Π, we obtain

an eα-approximate aggregate value and an eα-competitive ratio in expectation for

97

Page 109: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

its k-level incremental version Πk.

Proof. The algorithm is the same as that of Theorem 4.2, except the intervals

are defined differently. Let A` denote A’s level ` solution and v` denote its cost,

that is, v` = v(A`) = v(A(F`)) ≤ α · v(OPT(F`)). Rather than define interval i as

the set of levels ` with 2i−1v1 ≤ v` < 2iv1 (Theorem 4.2), we define interval i as

all levels ` with βei−1v1 ≤ v` < βeiv1, where β = eX for X a random variable in

[0, 1). Then if v′` = v`/(ei−1v1) then β ≤ v′` < βe, in fact, v′` = βeY for Y ∈ [0, 1).

Let max(i) denote the last level in interval i.

For each level ` in interval i, define S` =⋃i

j=1 Amax(j). Then S = (S1, . . . , Sk)

is an incremental solution by construction. Note that S is also feasible because by

monotonicity, any superset of Amax(i) is feasible for all levels in interval i. Then

E[v(S`)] ≤ E[∑i

j=1 vmax(j)] <∑i

j=0 E[βejv1] < E[βei+1v1

e−1], and

E[v(S`)v`

] < E[β·eiv1

v`· e

e−1] = e

e−1E[βe

v′`] = e

e−1E[e1−Y ]

= ee−1

E[eY ] = ee−1

e−1ln e

= e .

Thus each S` is at most an expected factor of eα greater than the optimal at each

level, and the desired bound holds for both the aggregate and ratio objectives.

Similar techniques could be used to possibly improve the performance of non-

covering problems, although no attempts have been made in this direction.

6.3 Relaxed Incremental Constraint

We consider the two-level bipartite matching problem discussed in Chapter 3. The-

orem 3.4 shows there is an algorithm that finds the incremental bipartite matching

of optimal ratio, and this optimal ratio may be as bad as 23

but no worse (Theorems

3.3, 3.2). Now consider the problem that still wants to maximize the competitive

98

Page 110: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

ratio, however later solutions are allowed to remove edges from earlier solutions by

paying a penalty p for each such edge.

For bipartite matching, we assume p < 1 without loss of generality; if p ≥ 1

then we will never violate the incremental constraint and Theorem 3.4 can obtain

an optimal 23-competitive solution.

Theorem 6.2 Incremental bipartite matching is (|M∗

2 ||M∗

2 |+p|M∗1 |

)-competitive for 2 lev-

els, where 0 ≤ p < 1 is the penalty for each violation of the incremental constraint.

Proof. Consider Algorithm 1 of Theorem 3.3, which finds a 23-competitive incre-

mental bipartite matching (M1, M2) starting from some M∗1 , M∗

2 . We partition the

set of alternating paths of M∗1 ∪M∗

2 as follows. Let P1,P2 denote the sets of alter-

nating paths selected for M1 and M2\M1, respectively, in Algorithm 1. We further

partition P1; let P11 denote the set of alternating paths of P1 with p ≥ 1|P∩M∗

1 |.

These paths will not violate the incremental constraint because the penalty is too

high. Let P12 denote the set of alternating paths of P1 with p < 1|P∩M∗

1 |. These

paths will violate the incremental constraint on edges P ∩M∗1 for a |P ∩M∗

1 | ·p < 1

penalty in order to gain the edges of P ∩M∗2 .

We construct an (|M∗

2 ||M∗

2 |+p|M∗1 |

)-competitive incremental matching (M ′1, M

′2) by

initializing M ′1 = M1 and M ′

2 = M2. For each alternating path P of P12, we

augment M ′2 with P ’s level-2 edges and reduce M ′

2 by P ’s level-1 edges, that is,

M ′2 = M ′

2∪(P ∩M∗2 )\(P ∩M∗

1 ); this increases the value of M ′2 by 1−p|P ∩M∗

1 | > 0.

We now augment M ′1 with bQc level-1 edges from the alternating paths of P2, where

Q =|M∗

1 ||M∗

2 |+ p|M∗1 |

(|M∗2 | − p|M1| − |M∗

2 ||M1||M∗

1 |) .

This increases the value of M ′1 by bQc ≥ Q− 1 and decreases the value of M ′

2 by

99

Page 111: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

at most bQcp ≤ Qp. Therefore

v(M ′1) = |M1|+ bQc ≥ |M1|+ Q− 1

=|M1||M∗

2 |+ p|M1||M∗1 |+ |M∗

1 ||M∗2 | − p|M1||M∗

1 | − |M1||M∗2 |

|M∗2 |+ p|M∗

1 |− 1

=|M∗

2 ||M∗

2 |+ p|M∗1 |· |M∗

1 | − 1, and

v(M ′2) ≥ |M2| − p|P12 ∩M1|+ |P12| − bQcp

≥ |M∗2 | − |P11 ∪ P12| − p|P12 ∩M1|+ |P12| −Qp

= |M∗2 | − |P11| − p|P12 ∩M1| −Qp

≥ |M∗2 | − p|P11 ∩M1| − p|P12 ∩M1| −Qp

= |M∗2 | − p|M1| −Qp

=|M∗

2 |2 + p|M∗1 ||M∗

2 | − p|M∗1 ||M∗

2 |+ p2|M1||M∗1 |+ p|M1||M∗

2 ||M∗

2 |+ p|M∗1 |

− p|M1|

=|M∗

2 ||M∗

2 |+ p|M∗1 |· |M∗

2 | .

Therefore the algorithm achieves a competitive ratio of|M∗

2 ||M∗

2 |+p|M∗1 |

.

If the bound|M∗

2 ||M∗

2 |+p|M∗1 |

< 23

then we ignore the penalties in order to obtain

Theorem 3.4’s optimal 23-competitive solution.

Similar techniques could be applied to other incremental problems that have

polynomial-time algorithms; however, no work has been done in the area. More-

over, it would be interesting to generalize the penalty model to support different

penalties for each individual incremental constraint.

100

Page 112: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Chapter 7

ConclusionWe now explore some of the more interesting open problems inspired by this thesis.

7.1 Online Algorithms

Chapter 2 examines select online problems, using their incremental results to ana-

lyze their online performance. We find that a gap between online and incremental

performance indicates the adversarial constraint contributes to the online compet-

itive ratio; conversely, little or no gap indicates the incremental constraint is pos-

sibly at fault. In this way, bounds on incremental competitiveness and complexity

reveal how much we can hope to improve an online algorithm’s performance.

Other online problems, such as online load balancing, robot navigation, trav-

eling salesman, call admission, and facility location could benefit from this sort of

analysis. These problems must first be studied in the incremental and online set-

tings before any such analysis can be done. If removing the adversarial constraint

leads to a 1-competitive solution then incremental analysis will not help; otherwise,

we can hope to determine what makes the problem’s online performance suffer.

7.2 Extensions to the Incremental Model

We would like to adapt our incremental model to handle the following limitations.

1. We require our solutions to build over time; a more realistic model allows

violations of this constraint at the expense of a penalty. We briefly consider

such a model for bipartite matching in Chapter 6, but more work should be

101

Page 113: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

done with other problems and the general models of Chapters 3 and 4.

2. We require feasible solutions at each time step; in appropriate situations we

could allow violations of this constraint, but at the expense of a penalty.

This idea is used in facility location with outliers [17].

3. The incremental model assumes perfect knowledge of the input sequence.

However restrictive this may seem, it allows us to better understand models

with other levels of foresight, such as stochastic and online problems. Chapter

2 begins to address this issue, but it is not comprehensive.

7.3 Other General Models

Chapters 3 and 4 formulate general incremental models for packing and covering

problems; however, these are not the only two classes of interest. Partitioning and

sequencing problems, for instance, are large categories of combinatorial problems

that would also extend naturally to the incremental setting.

Packing and covering problems search over subsets of a collection of objects; in

contrast, partitioning problems search over all partitions of a collection of objects

[60]. Typically, such problems try to solve a covering and packing problem simul-

taneously by choosing some number of subsets under conflict, yet completely cover

the ground elements. For example, the interval scheduling and coloring problems

partition objects in the presence of conflicts, where conflicting objects cannot be

in the same partition. A natural incremental model for these problems reveals

the conflicts over time, as with incremental covering problems; the incremental

solution produces more finely grained partitions of the objects as time goes on.

For instance, the incremental coloring problem could have the edges appear over

102

Page 114: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

time; a solution would be a sequence of colorings such that later colorings are

refinements of earlier colorings. Alternatively, our incremental model could reveal

the collection of objects over time, and now the incremental solution would grow

the partitions as time goes on; this variation is used in the online coloring problem

studied in Section 2.4.2.

Another large class of interest is that of sequencing problems, which search over

all permutations of a collection of objects [60]. For example, the Hamiltonian cycle

problem finds an ordering of n vertices subject to restrictions preventing one vertex

from following another. Similarly, the traveling salesman problem finds an ordering

of n vertices, but there is a cost associated with placing one vertex after another,

rather than a hard constraint. Online models where the objects are revealed over

time have been studied in [3, 4, 61]; the goal is to produce an ongoing sequence

of minimum cost. Notice that the competitive ratio and aggregate value objective

functions may not be the best choices in new classes of problems.

7.4 Correlation Clustering

There are individual combinatorial problems that do not fit the problem classes

discussed thus far in this dissertation. Of particular interest is correlation clustering

[5, 16], a problem of theoretical and practical value. The input is a set of items for

which it is known whether any pair is similar or dissimilar. The goal is to cluster

the items such that either (a) disagreements (similar pairs in different clusters

plus dissimilar pairs in the same cluster) are minimized, or (b) agreements are

maximized. Correlation clustering is challenging in its own right; its incremental

counterpart will only prove more difficult. However, it has natural applicability.

For instance, suppose a set of web pages needs to be organized into a directory

103

Page 115: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

structure; one knows whether each pair is similar enough to be in the same directory

or sub-directory, or sub-sub-directory, down to the desired level of granularity.

One wants to cluster the pages at each level, that is, assign them to a directory,

a sub-directory, etc., such that items clustered together at an early stage (e.g., a

sub-directory) are necessarily clustered together in later stages (e.g., a directory).

This precisely fits the incremental framework, but we do not yet have the tools to

handle such a problem.

7.5 Completing the Picture

Finally, there are some open problems motivated by incomplete results of this

dissertation. For example, Chapter 3 presents a general approximation algorithm

for the aggregate value of any incremental packing problem; we do not, however,

have such an algorithm for the competitive ratio. We believe that Algorithm 1 for

bipartite matching can be generalized to certain packing problems, and that the

greedy algorithm of Theorem 3.19 can be generalized to others; however, we have

no formal proof as yet.

104

Page 116: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

BIBLIOGRAPHY

[1] N. Alon, B. Awerbuch, Y. Azar, N. Buchbinder, and J. Naor. The online setcover problem. In Proceedings of the 35th Annual ACM Symposium on Theoryof Computing, pages 100–105. ACM Press, 2003.

[2] N. Alon and Y. Azar. On-line Steiner trees in the euclidean plane. In Pro-ceedings of the 8th Annual Symposium on Computational Geometry, pages337–343. ACM Press, 1992.

[3] G. Ausiello, V. Bonifaci, and L. Laura. The on-line asymmetric travelingsalesman problem. In Proceedings of the 9th Workshop on Algorithms andData Structures, pages 306–317, 2005.

[4] G. Ausiello, E. Feuerstein, S. Leonardi, L. Stougie, and M. Talamo. Compet-itive algorithms for the on-line traveling salesman problem. In Proceedings ofthe 4th Workshop on Algorithms and Data Structures, volume 955 of LectureNotes in Comput. Sci., pages 206–217. Springer, 1995.

[5] N. Bansal, A. Blum, and S. Chawla. Correlation clustering. Mach. Learn.,56(1-3):89–113, 2004.

[6] J. Bar-Ilan, G. Kortsarz, and D. Peleg. How to allocate network centers. J.Algorithms, 15(3):385–415, 1993.

[7] P. Benedek, A. Darazs, and J.D. Pinter. Risk management of accidental waterpollution: An illustrative application. Water Science and Technology, 22:265–274, 1990.

[8] J.R. Birge and J.W. Yen. A stochastic programming approach to the airlinecrew scheduling problem. In Proceedings of the 35th Annual Conference of theOperational Research Society of New Zealand, pages 19–30, 2000.

[9] B. Bollobas and A. J. Harris. List-colourings of graphs. Graphs and Combi-natorics, 1(2):115–127, 1985.

[10] J.A. Bondy and U.S.R. Murty. Graph Theory with Applications. The MacMil-lan Press Ltd, 1978.

[11] A. Borodin and R. El-Yaniv. Online Computation and Competitive Analysis.Cambridge University Press, New York, NY, USA, 1998.

[12] P. Briggs, K. D. Cooper, K. Kennedy, and L. Torczon. Coloring heuristics forregister allocation. In Proceedings of the ACM SIGPLAN 1989 Conference onProgramming language design and implementation, pages 275–284, New York,NY, USA, 1989. ACM Press.

105

Page 117: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

[13] D. W. Bunn and S. N. Paschentis. Development of a stochastic model for theeconomic dispatch of electric power. Eur. J. Oper. Res. 27, 179-191, 1986.

[14] G. J. Chaitin. Register allocation and spilling via graph coloring. Proceedingsof the SIGPLAN 1982 Symposium on Compiler Construction, 17(6):98–105,June 1982.

[15] G. J. Chaitin, M. A. Auslander, A. K. Chandra, J. Cocke, M. E. Hopkins,and P. W. Markstein. Register allocation via coloring. Computer Languages,6:47–57, 1981.

[16] M. Charikar, V. Guruswami, and A. Wirth. Clustering with qualitative infor-mation. J. Comput. Syst. Sci., 71(3):360–383, 2005.

[17] M. Charikar, S. Khuller, D. M. Mount, and G. Narasimhan. Algorithms forfacility location problems with outliers. In Proceedings of the 12th annualACM-SIAM Symposium on Discrete algorithms, pages 642–651, 2001.

[18] A. Chetwynd. Total colourings of graphs. In R. Nelson and R. J. Wilson,editors, Graph Colourings, Pitman Research Notes in Mathematics Series,pages 65–77. Longman Scientific & Technical, Longman house, Burnt Mill,Harlow, Essex, UK, 1990.

[19] V. Chvatal. A greedy heuristic for the set-covering problem. Mathematics ofOperations Research, 4:233–235, 1979.

[20] G. B. Dantzig and G. Infanger. Multi-stage stochastic linear programs forportfolio optimization. Ann. Oper. Res., 45(1-4):59–76, 1993.

[21] S. Dasgupta. Performance guarantees for hierarchical clustering. In Proceed-ings of the 15th Annual Conference on Computational Learning Theory, pages351–363. Springer-Verlag, 2002.

[22] D. Dentcheva and W. Romisch, editors. Optimal power generation underuncertainty via stochastic programming, volume 458 of Lecture Notes in Eco-nomics and Mathematical Systems. Springer-Verlag, 1998.

[23] Y. Fang and W. Lou. A multipath routing approach for secured data delivery.In Proceedings of IEEE Micron, pages 1467–1473. IEEE Computer Society,2001.

[24] U. Feige. A threshold of ln n for approximating set cover. J. ACM, 45(4):634–652, 1998.

[25] A. Fiat and G. J. Woeginger, editors. Online Algorithms, The State of theArt, volume 1442 of Lecture Notes in Computer Science. Springer, 1998.

106

Page 118: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

[26] S. Fiorini and R. J. Wilson. Edge-colourings of graphs. In L. W. Beinekeand R. J. Wilson, editors, Selected Topics in Graph Theory, chapter 5, pages103–126. Academic Press, Inc., London, 1978.

[27] L. K. Fleischer. Approximating fractional multicommodity flow independentof the number of commodities. SIAM J. Discret. Math., 13(4):505–520, 2000.

[28] Jr. L.R. Ford and D.R. Fulkerson. Maximal flow through a network. CanadianJournal of Mathematics, 8:399–404, 1956.

[29] Jr. L.R. Ford and D.R. Fulkerson. A simple algorithm for finding maximalnetwork flows and an application to the Hitchcock problem. Canadian Journalof Mathematics, 9:210–218, 1957.

[30] Jr. L.R. Ford and D.R. Fulkerson. Flows in Networks. Princeton UniversityPress, 1962.

[31] E. Fragniere and A. Haurie. A stochastic programming model for en-ergy/environment choices under uncertainty. International Journal of En-vironment and Pollution, 6(4–6):587–603, 1996.

[32] A.A. Gajvoronskij. Numerical minimization methods for convex function-als dependent on probability measures with applications to optimal pollutionmonitoring. Cybernetics 25, No.4, 471-482 translation from Kibernetika 1989,No.4, 43-51 (1989)., 1989.

[33] A. Gamst. Some lower bounds for a class of frequency assignment problems.IEEE Trans. Veh. Technol., VT-35:8–14, 1986.

[34] M. R. Garey and D. S. Johnson. Computers and Intractability; A Guide tothe Theory of NP-Completeness. W. H. Freeman & Co., 1990.

[35] M. R. Garey, D. S. Johnson, and H. C. So. An application of graph coloringto printed circuit testing. IEEE Transactions on Circuits and Systems, Vol.CAS-23(10):591–598, October 1976.

[36] N. Garg and J. Koenemann. Faster and simpler algorithms for multicommod-ity flow and other fractional packing problems. In Proceedings of the 39thAnnual Symposium on Foundations of Computer Science, page 300. IEEEComputer Society, 1998.

[37] C. Gavoile, D. Peleg, A. Raspaud, and E. Sopena. Small k-dominating setsin planar graphs with applications. In Proc. Workshop on Graphs, WG’01,LNCS 2204, pages 201–216, 2001.

[38] M. X. Goemans. Advanced algorithms. Technical Report MIT/LCS/RSS-27,M.I.T., 1994.

107

Page 119: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

[39] T. Gonzalez. Clustering to minimize the maximum intercluster distance. The-oretical Computer Science, 38:293–306, 1985.

[40] R.L. Graham and P. Hell. On the history of the minimum spanning treeproblem. IEEE Annals of the History of Computing, 7(1):43–57, 1985.

[41] A. Gupta, M. Pal, R. Ravi, and A. Sinha. Boosted sampling: approximationalgorithms for stochastic optimization. In Proceedings of the 36th AnnualACM Symposium on Theory of Computing, pages 417–426. ACM Press, 2004.

[42] A. Gyarfas and J. Lehel. Online and first-fit colorings of graphs. J. GraphTh., 12:217–227, 1988.

[43] M. M. Halldorsson. A still better performance guarantee for approximategraph coloring. Inf. Process. Lett., 45(1):19–23, 1993.

[44] M. M. Halldorsson. Online coloring known graphs. In Proceedings of the10th annual ACM-SIAM Symposium on Discrete algorithms, pages 917–918,Philadelphia, PA, USA, 1999. Society for Industrial and Applied Mathematics.

[45] M. M. Halldorsson and M. Szegedy. Lower bounds for on-line graph coloring.In Proceedings of the 3rd annual ACM-SIAM Symposium on Discrete algo-rithms, pages 211–216, Philadelphia, PA, USA, 1992. Society for Industrialand Applied Mathematics.

[46] J. Hartline and A. Sharp. Hierarchical flow. In Proceedings of the 2nd Inter-national Network Optimization Conference, pages 681–687, 2005.

[47] J. Hartline and A. Sharp. An incremental model for combinatorial max-imization problems. In Proceedings of the 5th International Workshop onExperimental Algorithms, pages 36–48. Springer-Verlag, 2006.

[48] J. Hartline and A. Sharp. An incremental model for combinatorial minimiza-tion. technical report. Available at www.cs.cornell.edu/~asharp., 2006.

[49] J. Hastad. Some optimal inapproximability results. In STOC ’97: Proceedingsof the twenty-ninth annual ACM symposium on Theory of computing, pages1–10, New York, NY, USA, 1997. ACM Press.

[50] W. Hsu and G. L. Nemhauser. Easy and hard bottleneck location prpoblems.Discrete Applied Math, 1:209–215, 1979.

[51] O. H. Ibarra and C. E. Kim. Fast approximation algorithms for the knapsackand sum of subset problems. J. ACM, 22(4):463–468, 1975.

[52] N. Immorlica, D. Karger, M. Minkoff, and V. S. Mirrokni. On the costs andbenefits of procrastination: approximation algorithms for stochastic combina-torial optimization problems. In Proceedings of the 15th Annual ACM-SIAM

108

Page 120: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

Symposium on Discrete Algorithms, pages 691–700. Society for Industrial andApplied Mathematics, 2004.

[53] D. S. Johnson. Approximation algorithms for combinatorial problems. InSTOC ’73: Proceedings of the fifth annual ACM symposium on Theory ofcomputing, pages 38–49, New York, NY, USA, 1973. ACM Press.

[54] D. S. Johnson. Fast algorithms for bin packing. Journal of Computer andSystem Sciences, 8:272–314, 1974.

[55] H. Kaplan and M. Szegedy. On-line complexity of monotone set systems.In Proceedings of the 10th annual ACM-SIAM symposium on Discrete algo-rithms, pages 507–516. Society for Industrial and Applied Mathematics, 1999.

[56] D. R. Karger. Random sampling in graph optimization problems. PhD thesis,Stanford University, Stanford, CA, USA, 1995.

[57] R. M. Karp. Reducibility among combinatorial problems. In R. E. Millerand J. W. Thatcher, editors, Complexity of Computer Computations, pages85–103. Plenum Press, 1972.

[58] R. M. Karp, U. V. Vazirani, and V. V. Vazirani. An optimal algorithm for on-line bipartite matching. In Proceedings of the 22nd Annual ACM Symposiumon Theory of Computing, pages 352–358. ACM Press, 1990.

[59] H. A. Kierstead, S. G. Penrice, and W. T. Trotter. On-line coloring andrecursive graph theory. SIAM J. Discret. Math., 7(1):72–89, 1994.

[60] J. Kleinberg and E. Tardos. Algorithm Design. Addison-Wesley, 2005.

[61] S. O. Krumke, W. E. de Paepe, D. Poensgen, and L. Stougie. News from theonline traveling repairman. In Proc. 26th Symp. on Mathematical Foundationsof Computer Science (MFCS), volume 2136 of Lecture Notes in Comput. Sci.,pages 487–499. Springer, 2001.

[62] H.W. Kuhn. The hungarian method for the assignment problem. Naval Re-search Logistics Quarterly, 2:83–97, 1955.

[63] F. T. Leighton. A graph colouring algorithm for large scheduling problems.Journal of Research of the National Bureau of Standards, 84(6):489–503, 1979.

[64] G. Lin, C. Nagarajan, R. Rajaraman, and D. P. Williamson. A general ap-proach for incremental approximation and hierarchical clustering. In Pro-ceedings of the 17th Annual ACM-SIAM Symposium on Discrete Algorithms,2006.

[65] L. Lovasz. On the ratio of optimal and fractional covers. Discrete Mathemat-ics, 13:383–390, 1975.

109

Page 121: INCREMENTAL ALGORITHMS: SOLVING …asharp/papers/thesis.pdfINCREMENTAL ALGORITHMS: SOLVING PROBLEMS IN A CHANGING WORLD Alexa Megan Sharp, Ph.D. Cornell University 2007 A typical algorithm

[66] R. R. Mettu and C. G. Plaxton. The online median problem. In Proceedings ofthe 41st Annual Symposium on Foundations of Computer Science, page 339.IEEE Computer Society, 2000.

[67] A. Meyerson. Online algorithms for network design. In Proceedings of the16th Annual ACM Symposium on Parallelism in Algorithms and Architec-tures, pages 275–280. ACM Press, 2004.

[68] B. Monien and E. Speckenmeyer. Ramsey numbers and an approximationalgorithm for the vertex cover problem. Acta Inf., 22(1):115–123, 1985.

[69] J. Nesetril. A few remarks on the history of the mst-problem. ArchivumMathematicum, 9:15–22, 1997.

[70] O. Parekh. Edge dominating and hypomatchable sets. In Proceedings of the13th Annual ACM-SIAM Symposium on Discrete Algorithms, pages 287–291.Society for Industrial and Applied Mathematics, 2002.

[71] C. G. Plaxton. Approximation algorithms for hierarchical location problems.In Proceedings of the 35th Annual ACM Symposium on Theory of Computing,pages 40–49. ACM Press, 2003.

[72] J. Plesnık. On the computational complexity of centers locating in a graph.Aplikace Matematiky, 25:445–452, 1980.

[73] G. Robins and A. Zelikovsky. Improved Steiner tree approximation in graphs.In Proceedings of the 11th Annual ACM-SIAM Symposium on Discrete Algo-rithms, pages 770–779. Society for Industrial and Applied Mathematics, 2000.

[74] D. D. Sleator and R. E. Tarjan. Amortized efficiency of list update and pagingrules. Commun. ACM, 28(2):202–208, 1985.

[75] V. V. Vazirani. Approximation Algorithms. Springer-Verlag, 2003.

[76] K. D. Wayne and L. Fleischer. Faster approximation algorithms for generalizedflow. In Proceedings of the 10th annual ACM-SIAM Symposium on Discretealgorithms, pages 981–982. Society for Industrial and Applied Mathematics,1999.

[77] B. Wilson. Line-distinguishing and harmonious colourings. In Roy Nelsonand Robin J. Wilson, editors, Graph Colourings, Pitman Research Notes inMathematics Series, pages 115–133. Longman Scientific & Technical, Long-man house, Burnt Mill, Harlow, Essex, UK, 1990.

[78] A. Yao. New algorithms for bin packing. J. ACM, 27(2):207–227, 1980.

[79] L. Yu, X. Ji, and S. Wang. Stochastic programming models in financial opti-mization: A survey. Advanced Modeling and Optimization, 5(1), 2003.

110