Relaxing the Irrevocability Requirement for Online Graph Algorithms
Joan Boyar, Lene M. Favrholdt, Kim S. Larsen, Michal Kotrb\v{c}\'ik

TL;DR
This paper explores models of online graph algorithms where the traditional irrevocability constraint is relaxed, allowing late acceptance or rejection of requests, leading to improved competitive ratios for certain problems.
Contribution
It introduces new online models with relaxed irrevocability constraints and analyzes their impact on competitive ratios for various graph problems.
Findings
Late Accept/Reject model achieves a constant competitive ratio for Independent Set.
Late Accept model suffices for Vertex Cover with improved ratios.
Matching problem's ratio improves from 2 to 3/2 in the new models.
Abstract
Online graph problems are considered in models where the irrevocability requirement is relaxed. Motivated by practical examples where, for example, there is a cost associated with building a facility and no extra cost associated with doing it later, we consider the Late Accept model, where a request can be accepted at a later point, but any acceptance is irrevocable. Similarly, we also consider a Late Reject model, where an accepted request can later be rejected, but any rejection is irrevocable (this is sometimes called preemption). Finally, we consider the Late Accept/Reject model, where late accepts and rejects are both allowed, but any late reject is irrevocable. For Independent Set, the Late Accept/Reject model is necessary to obtain a constant competitive ratio, but for Vertex Cover the Late Accept model is sufficient and for Minimum Spanning Forest the Late Reject model is…
| Problem | Standard | Late Accept | Late Reject | Late Accept/Reject | |||
|---|---|---|---|---|---|---|---|
| Independent Set | |||||||
| Matching | |||||||
| Vertex Cover | |||||||
| Min. Spanning Forest | |||||||
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsOptimization and Search Problems · Caching and Content Delivery · Auction Theory and Applications
11institutetext: University of Southern Denmark, Odense, Denmark, 11email: {joan,lenem,kslarsen}@imada.sdu.dk 22institutetext: The University of Queensland, Brisbane, Australia, 22email: [email protected]
Relaxing the Irrevocability Requirement for Online Graph Algorithms††thanks: Supported in part by the Danish Council for Independent Research, Natural Sciences, grant DFF-1323-00247, and the Villum Foundation, grant VKR023219.
Joan Boyar 11
Lene M. Favrholdt 11
Michal Kotrbčík 22
Kim S. Larsen 11
Abstract
Online graph problems are considered in models where the irrevocability requirement is relaxed. Motivated by practical examples where, for example, there is a cost associated with building a facility and no extra cost associated with doing it later, we consider the Late Accept model, where a request can be accepted at a later point, but any acceptance is irrevocable. Similarly, we also consider a Late Reject model, where an accepted request can later be rejected, but any rejection is irrevocable (this is sometimes called preemption). Finally, we consider the Late Accept/Reject model, where late accepts and rejects are both allowed, but any late reject is irrevocable. For Independent Set, the Late Accept/Reject model is necessary to obtain a constant competitive ratio, but for Vertex Cover the Late Accept model is sufficient and for Minimum Spanning Forest the Late Reject model is sufficient. The Matching problem has a competitive ratio of , but in the Late Accept/Reject model, its competitive ratio is .
1 Introduction
For an online problem, the input is a sequence of requests. For each request, the algorithm has to make some decision without any knowledge about possible future requests. Often (part of) the decision is whether to accept or reject the request and the decision is usually assumed to be irrevocable. However, many online problems have applications for which total irrevocability is not inherent or realistic. Furthermore, when analyzing the quality of online algorithms, relaxations of the irrevocability constraint often result in dramatically different results, especially for graph problems. This has already been realized and several papers study various relaxations of the irrevocability requirement. In this paper we initiate a systematic study of the nature of irrevocability and of the implications for the performance of the algorithms. Our aim is to understand whether it is the absence of knowledge of the future or the irrevocability restrictions on the manipulation of the solution set that makes an online problem difficult.
We consider graph problems and focus on four classical problems, Independent Set, Matching, Vertex Cover, and Minimum Spanning Forest. Independent Set and Vertex Cover are studied in the vertex arrival model. In this model, vertices arrive one by one together with all the edges between the newly arrived vertex and previous vertices. Matching and Minimum Spanning Forest are studied in the edge arrival model, but the results hold in the vertex arrival model as well. In the edge arrival model, edges arrive one by one, and if a vertex incident with the newly-arrived edge was not seen previously, it is also revealed.
Relaxed irrevocability
For the four problems considered in this paper, the online decision is whether to accept or reject the current request. In the standard model of online problems, this decision is irrevocable and has to be made without any knowledge about possible future requests. We relax the irrevocability requirement by allowing the algorithm to perform two additional operations, namely late accept and late reject. Late accept allows the algorithm to accept not only the current request but also requests that arrived earlier. Thus, late accept relaxes irrevocability by not forcing the algorithm to discard the items that are not used immediately. Late reject allows the algorithm to remove items from the solution being constructed, relaxing the irrevocability of the decision to accept an item. When the algorithm is allowed to perform late accept or late reject, but not both, we speak of a Late Accept model and Late Reject model, respectively. Note that, in these two models, the late operations are irrevocable. We also consider the situation where the algorithm is allowed to perform both late accepts and late rejects, focusing on the Late Accept/Reject model, where any item can be late-accepted and late-rejected, but once it is late-rejected, this decision is irrevocable. In other words, if the algorithm performs both late accept and late reject on a single item, the late accept has to precede the late reject.
We believe that the Late Accept, Late Reject, and Late Accept/Reject models are appropriate modeling tools corresponding to many natural settings. Matching, for example, in the context of online gaming or chats, functions in the Late Accept model. Indeed, the users are in the pool until assigned, allowing the late accept, but once the users are paired, the connection should not be broken by the operator. Note that the matching problem is a maximization problem. For minimization problems, accepting a request may correspond to establishing a resource at some cost. Often there is no natural reason to require the establishment to happen at a specific time. Late acceptance was considered for the dominating set problem in [2], which also contains further feasible practical applications and additional rationale behind the model.
When the knapsack problem is studied in the Late Reject model, items are usually called removable; see for example [15, 12, 11, 3, 13]. For most other problems, late rejection is usually called preemption and has been studied in variants of many online problems, for example call control [1, 8], maximum coverage [24, 23], and weighted matching problems [5, 6]. Preemption was also previously considered for one of the problems we consider here, independent set, in [19], but in a model where advice is used, presenting lower bounds on the amount of advice necessary to achieve given competitive ratios in a stated range.
Online Vertex Cover was studied in [4], where they considered the possibility of swapping some of the accepted vertices for other vertices at the very end, at some cost depending on the number of vertices involved.
A similar concept is studied in, for example, [14, 22, 9, 10] for online Steiner tree problems, MST, and TSP. Here, replacing an accepted edge with another is allowed, and the objective is to minimize the number of times this occurs while obtaining a good competitive ratio. The problem is said to allow rearrangements or recourse.
TSP has also been studied [16] in a model where the actual acceptances and rejections (rejections carry a cost) are made at any time.
Competitive analysis
For each graph problem, we study online algorithms in the standard, Late Accept, Late Reject, and Late Accept/Reject models using the standard tool of competitive analysis [25, 17], where the performance of an online algorithm is compared to the optimum algorithm via the competitive ratio. For any algorithm (online or offline), , we let denote the value of the objective function when is applied to the input sequence .
For minimization problems, we say that an algorithm, , is -competitive, if there exists a constant such that, for all inputs , . Similarly, for maximization problems, is -competitive, if there exists a constant such that, for all inputs , . In both cases, if the inequality holds for , the algorithm is strictly -competitive. The (strict) competitive ratio of is the infimum over all such that is (strictly) -competitive. The competitive ratio of a problem is the infimum over the competitive ratio of all online algorithms for the problem. For all combinations of the problem and the model, we obtain matching lower and upper bounds on the competitive ratio.
For ease of notation for our results, we adopt the following conventions to express that a problem essentially has competitive ratio , i.e., it is true up to an additive constant. We say that a problem has competitive ratio if
- •
for any algorithm, there is a constant such that the strict competitive ratio is at least , and
- •
for any constant , there is a strictly -competitive algorithm for graphs with at least vertices.
Similarly, we say that a problem has competitive ratio if
- •
for any algorithm, there is a constant such that the strict competitive ratio is at least , and
- •
for any constant , there is an -competitive algorithm for graphs with at least vertices.
This notation is used in Theorems 2.3 and 4.4. For all other results, the upper bounds hold for the strict competitive ratio. For convenience, when stating results containing both an upper bound on the strict competitive ratio and a lower bound on the competitive ratio, we use the term “competitive ratio” even though the result holds for the strict competitive ratio as well.
Our results
The paper shows that for some problems the Late Accept model allows for algorithms with significantly better competitive ratios, while for others it is the Late Reject model which does. For other problems, the Late Accept/Reject model is necessary to get these improvements. See Table 1. Note that only deterministic algorithms are considered, not randomized algorithms.
Our results on Minimum Spanning Forest follow from previous results. Thus, they are mainly included to give an example where late rejects bring down the competitive ratio dramatically. The technical highlights of the paper are the results for Independent Set in the Late Accept/Reject model, where, in Theorems 2.4 and 2.5, we prove matching lower and upper bounds of on the competitive ratio.
We consider only undirected graphs . Throughout the paper, will denote the graph under consideration, and and will denote its vertex and edge set, respectively. Moreover, will always denote the number of vertices in . We use for the undirected edge connecting vertices and , so denotes the same edge.
2 Independent Set
An independent set for a graph is a subset such that no two vertices in are connected by an edge. For the problem called Independent Set, the objective is to find an independent set of maximum cardinality. We consider online Independent Set in the vertex arrival model.
Theorem 2.1
For Independent Set in the standard model, the strict competitive ratio is .
Proof
For the upper bound, consider the greedy algorithm that accepts each vertex, if possible.
For the lower bound, consider the following adversarial strategy where independent vertices arrive until a vertex, , is accepted by the algorithm. From this point on, the adversary presents vertices with as their only neighbor. Hence, the algorithm cannot accept any further vertices, whereas rejects and accepts all other vertices, yielding the result. ∎
We first show that allowing only late rejects helps, but only very slightly.
Theorem 2.2
For Independent Set in the Late Reject model, the strict competitive ratio is .
Proof
For the lower bound, whenever there is at least one vertex in the current independent set constructed by , the adversary presents a vertex incident only to . The only vertex which can be accepted when rejects is the vertex which just arrived, so will never have more than one accepted vertex. On the other hand, the graph the adversary produces is bipartite, so can accept at least half of the vertices.
For the upper bound, consider the following algorithm : If the presented vertex can be added to the independent set being constructed, then accept it. Otherwise, if is adjacent to only one vertex in , then remove from and add to .
By definition, accepts the first vertex. If ever has two accepted vertices, it will also have at least two accepted vertices at the end, and the result holds. Otherwise, consider some vertex accepted by . If the adversary presented a vertex not adjacent to , would accept it without rejecting , which would be a contradiction. Thus, each vertex presented by the adversary is connected to the unique vertex currently in . By definition of the algorithm, in every step, the currently accepted vertex is rejected and the new one accepted. Thus, considering the vertices in the order they are presented, they form a path. No algorithm can accept more than every second vertex from a path, and since all vertices are on the path, accepts at most vertices, and the result follows. ∎
We now show that while allowing late accepts helps further, it is still not enough to obtain a finite (constant) competitive ratio.
Theorem 2.3
For Independent Set in the Late Accept model, the competitive ratio is .
Proof
For a given positive constant , an algorithm which does not accept any vertex until the presented graph has an independent set of size at least , and then accepts any such set, is -competitive (for a graph with no independent set of size , suffices for the additive constant).
For the lower bound, consider any algorithm, . Let denote a sequence consisting of independent vertices. Let be the smallest integer such that accepts at least one vertex of . If there is no such , then the competitive ratio of is unbounded. Assume that is a vertex accepted in . When accepts , the adversary extends to an arbitrarily long input by presenting vertices of degree one adjacent only to . Clearly, can accept vertices of the resulting graph, while can accept at most vertices. ∎
The following two theorems show that, in the Late Accept/Reject model, the optimal competitive ratio for Independent set is . The upper bound comes from a variant of the greedy algorithm, Algorithm 1, rejecting a set of vertices if it can be replaced by a set at least as large. The algorithmic idea is natural and has been used before (with other parameters than ) in [23, 24], for example. Thus, the challenge lies in deciding the parameter and proving the resulting competitive ratio. Pseudocode for Algorithm 1 is given below.
For Algorithm 1, we introduce the following notation. Let be the current set of vertices that have been accepted and not late-rejected. Let be the set of vertices that have been late-rejected, and let denote the set of vertices that have not been accepted (and, hence, not late-rejected).
For a set of vertices, let , where is the neighborhood of a vertex (not including ). We call a set, , of vertices admissible if all the following conditions are satisfied:
is an independent set; 2. 2)
; 3. 3)
.
For the analysis of Algorithm 1, we partition into the set, , of vertices accepted in line 1 and the set, , of vertices accepted in line 1. We let be the independent set constructed by . For any set, , of vertices, we let and . Thus, .
Lemma 1
When Algorithm 1 terminates, .
Proof
Clearly, the inequality is true before the first vertex is presented. Each time a set, , of vertices is moved from to , a set at least times as large as is added to . Thus, each time the size of increases by some number , the size of increases by at least . The result follows inductively. ∎
Lemma 2
When Algorithm 1 terminates, .
Proof
When the algorithm terminates, there are no admissible sets. This means, in particular, that is not admissible. Trivially, does not violate 2). Furthermore, since , it cannot violate 1). Thus, we conclude from 3) that , where the last inequality follows from the fact that there are no edges between and , since . ∎
Lemma 3
When Algorithm 1 terminates, .
Proof
Consider a set, , added to in line 1. Let . We prove that
[TABLE]
If , this is trivially true. Thus, we can assume that is a proper subset of . Since is admissible, it follows that
[TABLE]
Note that is independent, since is independent and there are no edges between and . Since the algorithm chooses such that is minimized, this means that
[TABLE]
Subtracting Ineq. (3) from Ineq. (2), we obtain Ineq. (1).
Let be all the admissible sets that are chosen in line 1 during the run of the algorithm, and let be the corresponding sets that are removed from . Then, , and thus, . Furthermore, . Hence,
[TABLE]
where the second inequality follows from Ineq. (1). ∎
Lemma 4
When Algorithm 1 terminates, .
Proof
Since and , we obtain the following.
[TABLE]
The result now follows by dividing both sides by . ∎
Theorem 2.4
For Independent Set in the Late Accept/Reject model, is strictly -competitive.
Proof
We prove that , establishing the result.
[TABLE]
∎
We prove a matching lower bound:
Theorem 2.5
For Independent Set in the Late Accept/Reject model, the competitive ratio is at least .
Proof
Assume that is strictly -competitive for some . We first show that is at least and then lift the strictness restriction. Assume for the sake of contradiction that .
Incrementally, we construct an input consisting of a collection of bags, where each bag is an independent set. Whenever a new vertex belonging to some bag is given, we make it adjacent to every vertex not in , except vertices that have been late-rejected by . Thus, if accepts , it cannot hold any vertex in any other bag. This implies that the currently accepted vertices of always form a subset of a single bag, which we refer to as ’s bag, and this is the crucial invariant in the proof. We say that switches when it rejects the vertices of its current bag and accepts vertices of a different bag.
For the incremental construction, the first bag is special in the sense that cannot switch to another bag. We discuss later when we decide to create the second bag, but all we will need is that the first bag is large enough. From the point where we have created a second bag, has the option of switching. Whenever switches to a bag, , we start the next bag, . All that this means is that the vertices we give from this point on and until switches bag again belong to , and never holds vertices in the newest bag.
Now we argue that as long as we keep giving vertices, will repeatedly have to switch bag in order to be -competitive. Choose some , let be ’s bag, be the new bag, and be the number of vertices which are not adjacent to any vertices in . If has accepted vertices of after vertices of the new bag have been given, has to accept at least one additional vertex to be -competitive, since at this point could accept all of the vertices in and additional vertices. Since is the new bag, has reached its final size, so eventually will have to switch to a different bag.
For the proof, we keep track of relevant parts of the behavior of using a tree structure. The first bag is the root of the tree. Recall that whenever switches to a bag, say , we start a new bag . In our tree structure we make a child of .
Since is -competitive and always holds vertices only from a single bag , the number of vertices held in satisfies . Since, by assumption, , it follows that can accept and then reject disjoint sets of vertices of at most twice, or equivalently, that each bag in the tree has at most two children. As we proved above, will have to keep switching bags, so if we keep giving vertices, this will eventually lead to leaves arbitrarily far from the root.
Consider a bag that holds after a “long enough” sequence has been presented.
Label the bags from the root to ’s bag by , where is a child of for each . Let , , be the number of vertices of held by immediately before it rejected already accepted vertices from for the first time and let be the number of vertices currently accepted in . Let , .
Furthermore, for each , if is even, let , and if is odd, let . Note that our choice of adjacencies between bags implies that can hold at least vertices in bags .
Thus, just before rejects the vertices in (just before the th vertex of is given), we must have , by the assumption that is -competitive. We want to introduce the arbitrarily small chosen above and eliminate the “” in this inequality: Since can always hold the vertices from the root bag, must hold for all . Since , we get that . Thus, at the beginning of the input sequence, we can keep giving vertices for the first bag, making large enough such that becomes large enough that . This establishes . Trivially, , so
[TABLE]
Next, we want to show that for any , there exists an such that
[TABLE]
contradicting the assumption that was -competitive. To accomplish this, we repeatedly strengthen Ineq. (5) by replacing with the bound from Ineq. (4), eventually arriving at an inequality which can be proven to hold, and then this will imply all the strengthened inequalities and, finally, Ineq. (5).
From Ineq. 5, we first use the definition of and collect the terms to get
[TABLE]
and then we use Ineq. (4) to obtain the following inequality, which implies Ineq. (6):
[TABLE]
Collecting terms gives
[TABLE]
and, using Ineq. (4) again, we get a stronger inequality
[TABLE]
and, after moving ,
[TABLE]
We proceed by labeling the coefficients of and in these inequalities of the form
[TABLE]
by sequences , respectively . We reverse the order of and so the index corresponds to applications of Ineq. (4), and simplifications as in the above. Therefore, and are the coefficients of and , respectively (recall that is fixed).
Our repeated rewriting of and terms to terms with smaller indices will eventually lead to , which is a constant, and to , which is zero. The above calculations show that
[TABLE]
Our aim is to show that the coefficients and satisfy
[TABLE]
With the derived constants for and with small indexes given above as the base case, we proceed by induction, assuming that for , the coefficients of Ineq. (8) have the values claimed in Eq. (9) up to index and in Eq. (10) up to index .
We emphasize that we are still strengthening inequalities, so it is the inequality for the -version of Ineq. (8) that we derive that will imply Ineq. (8) for . The induction is used to show that the coefficients in the inequalities fulfill the recurrence equations stated for them.
From Ineq. (8), we collect the to obtain
[TABLE]
and using Ineq. (4), we get the stronger inequality
[TABLE]
which can be rewritten as
[TABLE]
Reordering on the left-hand side and inserting the claimed Eqs. (9) and (10), we arrive at
[TABLE]
which is the -version of Ineq. (8), proving the claim.
This concludes the strengthening of the inequalities and the sequence of implications. Thus, to prove Ineq. (5), it is sufficient to prove that there exist and such that Ineq. (8) holds. This, in turn, will follow if is negative. Indeed, if eventually becomes negative, we can choose to be the smallest such index and Ineq. (8) then implies the desired Ineq. (5). This inequality contradicts the assumption of the algorithm being -competitive, and we will have established the theorem.
Plugging Eq. (10) into Eq. (9) gives us
[TABLE]
and this is the recurrence we use to show that becomes negative.
According to [18, Theorem 1.2.1], every solution to a linear homogeneous difference equation oscillates (around zero, and thus has negative values infinitely often) if and only if its characteristic equation has no positive roots. For a direct proof of the subcase of the above theorem that we need, see [21].
The characteristic equation of Eq. 11 is , which, for the interval , has two imaginary roots and one real root. Letting and
[TABLE]
this third root is , which is negative for . (Note that is no longer real when becomes negative, which occurs for . At , in addition to the negative real root, there is a double root at , and the solution to the recurrence never becomes negative.)
Thus, from [18, Theorem 1.2.1], any solution to the recurrence equation oscillates, implying, in particular, that it becomes negative at some point, giving the desired contradiction.
Finally, we return to the assumption of strictness, which can easily be removed. There are only two places we use the relation given by being strictly -competitive. One place is in the claim . However, we use this only to lead to Ineq. (4), and just as we used a large enough first bag to make , we can increase the size of the first bag to eliminate any additive constant. The other place was in the argument that . Also in this case, if bags are large enough, no additive constant makes a difference, and the minimum size of all bags can be increased by increasing , since that increases the lower bound on , and the algorithm can never hold fewer vertices in any bag than that. ∎
The previous two theorems give us:
Corollary 1
For Independent Set in the Late Accept/Reject model, the competitive ratio is .
3 Matching
A matching in a graph is a subset of consisting of pairwise non-incident edges. For the problem called Matching, the objective is to find a matching of maximum cardinality. We study online Matching in the edge arrival model, but note that the results hold in the vertex arrival model as well: For the upper bounds, an algorithm in the vertex arrival model can process the edges incident to the current vertex in any order. For the lower bounds, all adversarial sequences used in this section consist of paths, and hence, exactly the same input can be given in the vertex arrival model.
It is well known and easy to prove that the greedy algorithm which adds an edge to the matching whenever possible is -competitive and this is optimal in the standard model. The first published proof of this is perhaps in the classical paper of Korte and Hausmann [20]. The paper shows that in any graph, the ratio of the minimum size of a maximal matching to the size of a maximum matching is at least , and there are graphs where it is no more than . Since the greedy algorithm produces a maximal matching, the claim follows.
Late accept or late reject alone does not help:
Theorem 3.1
For Matching in the Late Accept model, the competitive ratio is .
Proof
The upper bound follows from the standard model. For the lower bound, we can use the same sequence as in the standard model: The adversary presents mutually non-incident edges to some algorithm, . For every edge accepted by at any point, the adversary presents edges and , which cannot accept. Thus, there will be connected components such that in each component, accepts at least twice as many edges as . ∎
Theorem 3.2
For Matching in the Late Reject model, the competitive ratio is .
Proof
The upper bound follows from the standard model. For the lower bound, the adversary presents mutually non-incident edges to some algorithm, . For each edge, , accepted by , the adversary presents an edge . If late-rejects , then the adversary presents an edge . can only accept one of the edges and and it cannot accept again, but accepts both and . Otherwise, must reject . In this case, the adversary presents an edge, . can only keep or , but accepts both and . This adversarial strategy results in connected components such that in each component, accepts at least twice as many edges as . ∎
Theorem 3.3
For Matching in the Late Accept/Reject model, the competitive ratio is at least .
Proof
The adversary presents a number of mutually non-incident edges to some algorithm, . If, for some such edge , during the entire processing of the input, does not accept , then will, and no more edges incident to or will be presented. The ratio is then unbounded on the subconstruction containing .
If accepts an edge , the adversary presents and . If never rejects , no more edges incident to any of these vertices will be presented, and the ratio is on this subconstruction.
If late-rejects at some point, then the adversary presents and . The algorithm cannot accept again, so it cannot accept more than two edges from this subconstruction, while can accept three, giving a ratio of . ∎
To prove a matching upper bound, we give an algorithm, Algorithm 2, which is strictly -competitive in the Late Accept/Reject model.
Recall that for a matching , a path is alternating with respect to , if for all , belongs to if and only if is even. Moreover, an alternating path is called augmenting if neither endpoint of is incident to a matched edge. Note that the symmetric difference of a matching and an augmenting path with respect to is a matching of size larger than . We focus on local changes, called short augmentations in [27]. We use a result which implies that if a maximal matching does not admit augmenting paths of length , then . This fact is part of the folklore and its proof can be found for example in [7, Lemma 2].
Theorem 3.4
For Matching in the Late Accept/Reject model, Algorithm 2 is strictly -competitive.
Proof
We first show that Algorithm 2 is a Late Accept/Reject algorithm, i.e., no edge which is late-rejected is later late-accepted. Suppose an edge is late-rejected in some step . For it to be accepted again, there must later be an augmenting path consisting of three edges, where is one of the outer edges, and one endpoint of must not be incident to any edges of the matching at that point. However, once a vertex is incident to an edge in some matching, it is always incident to some edge in all later matchings, due to the augmentation. Thus, cannot be late-accepted later, so after any edge is late-rejected, it will never be accepted again.
Next, we prove that the algorithm is strictly -competitive. Let be the matching constructed by Algorithm 2 on a graph . Algorithm 2 ensures that does not contain any augmenting paths of length at most three with respect to by augmenting on them when they do exist. To prove that this fact implies the bound, we present a proof similar to [7, Lemma 2]. Let be any maximum matching in . Consider the symmetric difference of and . Since and are matchings, any path in contains alternatingly edges from and . Since each augmenting path with respect to in contains one more edge of than of , we get that contains augmenting paths. Clearly, no augmenting path in consists of a single edge, since all edges which either are not accepted or are late-rejected by Algorithm 2 are incident to at least one edge accepted by the algorithm. Since there is no augmenting path of length at most three with respect to in , it follows that all of the augmenting paths in have length at least five. At least two edges of an augmenting path in of length at least five are contained in , and thus accepted by the algorithm, so we get that , giving that . ∎
4 Vertex Cover
A vertex cover for a graph is a subset such that for any edge, , . For the problem called Vertex Cover, the objective is to find a vertex cover of minimum cardinality. We study online Vertex Cover in the vertex arrival model.
Theorem 4.1
For Vertex Cover in the standard model, the strict competitive ratio is .
Proof
For the lower bound, consider any online algorithm, . For each , the adversary presents independent vertices until rejects some vertex or vertices have been presented. If vertices are presented, accepts none of them and the ratio is unbounded. If the algorithm rejects some vertex , then the remainder of the vertices will be adjacent only to . will only accept and the result follows.
For the upper bound, the algorithm only accepts a new vertex if at least one edge incident with is not already covered. Thus, it rejects the first vertex and therefore accepts at most vertices. accepts at least one vertex unless there are no edges, in which case the algorithm does not accept any vertices either. ∎
The situation improves dramatically if we can accept vertices at a later stage.
Theorem 4.2
For Vertex Cover in the Late Accept model, the competitive ratio is .
Proof
The best known offline -approximation algorithm for Vertex Cover greedily maintains a maximal matching, repeatedly covering both endpoints of an edge and removing all edges incident to these two endpoints. In the Late Accept model, a -competitive online algorithm can be obtained by mimicking the offline approximation algorithm. The online algorithm does not accept any vertex until it sees the second vertex incident to an uncovered edge; then it accepts both endpoints of that edge.
For the lower bound, consider any algorithm . The adversary presents isolated pairs of vertices, each pair connected by an edge. After the second vertex of a pair has arrived, must have accepted at least one of them, or the adversary could stop the input there, and ’s output would not be a vertex cover. If accepts both vertices, then no further vertices adjacent to the pair arrive, and could have covered the edge with only one vertex. If accepts only one vertex from a pair , then an additional vertex adjacent only to arrives, and could cover both edges with only , but must accept at least two of the three vertices. ∎
Allowing both late accept and late reject does not improve the situation further.
Theorem 4.3
For Vertex Cover in the Late Accept/Reject model, the competitive ratio is .
Proof
The upper bound follows from Theorem 4.2. The lower bound follows from the observation that no algorithm that ever late-rejects a vertex can be -competitive for any constant . Indeed, if late-rejects a vertex , then the adversary can present arbitrarily many vertices adjacent only to . Therefore, to be -competitive for any constant , can never late-reject a vertex and the lower bound from Theorem 4.2 applies. ∎
Theorem 4.4
For Vertex Cover in the Late Reject model, the competitive ratio is .
Proof
For the lower bound, the adversary keeps giving independent vertices until the algorithm rejects at least one vertex, . Since does not have to accept any vertices if they are all independent, the algorithm must eventually reject at least one vertex to avoid an unbounded competitive ratio. We let denote the number of vertices presented at the time the first vertex is rejected. After this point, all new vertices are adjacent to , so the algorithm has to accept all of them. In total, at least vertices are accepted, and accepts only .
For the upper bound, consider the following algorithm, : The first vertices are accepted (if they arrive). After that an optimal vertex cover, , for the edges seen so far is calculated. Each vertex not included in is rejected. After this, each new vertex is accepted only if necessary. Note that the size of is a lower bound on . Thus, for any input sequence of length at least , either or
[TABLE]
∎
5 Minimum Spanning Forest
A spanning forest for a graph is a subset which forms a spanning tree on each of the connected components of . Given a weight function , the objective of the Minimum Spanning Forest problem is to find a spanning forest of minimum total weight. We let denote the ratio between the largest and the smallest weight of any edge in the graph.
We study online Minimum Spanning Forest in the edge arrival model, but the results also hold in the vertex arrival model: For the upper bounds, an algorithm in the vertex arrival model can process the edges incident to the current vertex in any order. In the lower bound sequences presented here, all edges from a new vertex to all previous vertices are presented together in an arbitrary order.
Theorem 5.1
For Minimum Spanning Forest in the standard model, the competitive ratio is .
Proof
Since all spanning forests have the same number of edges, the ratio cannot be worse than . A matching upper bound can be realized by the adversary first presenting a tree consisting of edges of weight , and then presenting edges of weight from a new vertex to each of the vertices seen so far. The ratio is , giving an asymptotic lower bound of . ∎
Since an online algorithm does not know when the input ends, it must always have a forest spanning all the vertices seen so far, so in moving from the standard model to the Late Accept model, we do not gain any advantage:
Theorem 5.2
For Minimum Spanning Forest in the Late Accept model, the competitive ratio is .
Proof
We show that we can never perform a late accept. Assume to the contrary that an edge was late-accepted and added to a solution for the current graph . Since was late-accepted, both vertices and were seen earlier and thus contained in . By our requirement that the algorithms maintain a spanning forest on the set of vertices presented so far, is a spanning forest of . Therefore, adding created a cycle, contradicting that the algorithm finds a forest. ∎
On the other hand, in the Late Reject model, the greedy online algorithm mentioned by Tarjan in [26] can be used. We detail the algorithm in the proof.
Theorem 5.3
For Minimum Spanning Forest in the Late Reject model, the competitive ratio is .
Proof
No algorithm can be better than -competitive. For the upper bound, we note that the greedy online algorithm mentioned by Tarjan in [26] works in the Late Reject model: Assume that the current forest is when an edge arrives. If at least one of the two endpoints of is a vertex not seen earlier, accept . Otherwise, the greedy algorithm constructs the unique cycle in . If is not the heaviest edge in , then the algorithm late-rejects the heaviest edge in and replaces it by , obtaining . Otherwise, it rejects . It is easy to see that this produces an optimal spanning forest; it only uses the so-called red rule [26]. ∎
Since the Late Reject model leads to an optimal spanning tree, any model allowing that possibility inherits the result.
Theorem 5.4
For Minimum Spanning Forest in the Late Accept/Reject model, the competitive ratio is .
Future Work
Since we prove tight results for all combinations of problems and models considered, we leave no immediate open problems. However, one could reasonably consider late operations a resource to be used sparingly, as for the rearrangements in [14, 22, 9, 10], for example. Thus, an interesting continuation of our work would be a study of trade-offs between the number of late operations employed and the quality of the solution (in terms of competitiveness). Obviously, one could also investigate other online problems and further model variations.
The reference list from the paper itself. Each links out to its DOI / PubMed record.
- 1[1] Y. Bartal, A. Fiat, and S. Leonardi. Lower bounds for on-line graph problems with application to on-line circuit and optical routing. In 28th STOC , pages 531–540. ACM, 1996.
- 2[2] J. Boyar, S.J. Eidenbenz, L.M. Favrholdt, M. Kotrbčík, and K.S. Larsen. Online dominating set. In 15th SWAT , volume 53 of LIP Ics , pages 21:1–21:15. Schloss Dagstuhl – Leibniz-Zentrum für Informatik Gmb H, 2016.
- 3[3] M. Cygan, Ł. Jeż, and J. Sgall. Online knapsack revisited. Theor. Comput. Syst. , 58(1):153–190, 2016.
- 4[4] M. Demange and V.Th. Paschos. On-line vertex-covering. Theor. Comput. Sci. , 332:83–108, 2005.
- 5[5] L. Epstein, A. Levin, J. Mestre, and D. Segev. Improved approximation guarantees for weighted matching in the semi-streaming model. SIAM J. Discrete Math. , 25(3):1251–1265, 2011.
- 6[6] L. Epstein, A. Levin, D. Segev, and O. Weimann. Improved bounds for online preemptive matching. In 30th STACS , volume 20 of LIP Ics , pages 389–399. Schloss Dagstuhl – Leibniz-Zentrum für Informatik Gmb H, 2013.
- 7[7] J. Feigenbaum, S. Kannan, A. Mc Gregor, S. Suri, and J. Zhang. On graph problems in a semi-streaming model. Theor. Comput. Sci. , 348(2–3):207–216, 2005.
- 8[8] J.A. Garay, I.S. Gopal, S. Kutten, Y. Mansour, and M. Yung. Efficient on-line call control algorithms. J. Algorithm. , 23(1):180–194, 1997.
