Skip to main content
Log in

A new upper bound on the work function algorithm for the k-server problem

  • Published:
Journal of Combinatorial Optimization Aims and scope Submit manuscript

Abstract

The k-server problem was introduced by Manasse et al. (in: Proceedings of the 20th annual ACM symposium on theory of computing, Chicago, Illinois, USA, pp 322–333, 1988), and is one of the most famous and well-studied online problems. Koutsoupias and Papadimitriou (J ACM 42(5):971–983, 1995) showed that the work function algorithm (WFA) has a competitive ratio of at most \(2k-1\) for the k-server problem. In this paper, by proposing a potential function that is different from the one in Koutsoupias and Papadimitriou (1995), we show that the WFA has a competitive ratio of at most \(n-1\), where n is the number of points in the metric space. When \(n<2k\), this ratio is less than \(2k-1\).

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  • Bartal Y, Koutsoupias E (2004) On the competitive ratio of the work function algorithm for the \(k\)-server problem. Theor Comput Sci 324(2–3):337–345

    Article  MathSciNet  Google Scholar 

  • Chrobak M, Larmore LL (1992) The server problem and on-line games. In: On-line algorithms, DIMACS series in discrete mathematics and theoretical computer science, vol 7

    MATH  Google Scholar 

  • Komm D (2016) An introduction to online computation. Springer International Publishing, Cham

    Book  Google Scholar 

  • Koutsoupias E (2009) The \(k\)-server problem. Comput Sci Rev 3(2):105–118

    Article  Google Scholar 

  • Koutsoupias E, Papadimitriou CH (1995) On the \(k\)-server conjecture. J ACM 42(5):971–983

    Article  MathSciNet  Google Scholar 

  • Manasse MS, Mcgeoch LA, Sleator DD (1988) Competitive algorithms for on-line problems. In: Proceedings of the 20th annual ACM symposium on theory of computing, 2–4 May 1988, Chicago, Illinois, USA, pp 322–333

  • Rudec T, Manger R (2015) A fast approximate implementation of the work function algorithm for solving the \(k\)-server problem. Cent Eur J Oper Res 23(3):699–722

    Article  MathSciNet  Google Scholar 

  • Rudec T, Baumgartner A, Manger R (2010) Measuring true performance of the work function algorithm for solving the on-line \(k\)-server problem. J Comput Inf Technol 18(4):361–367

    Article  Google Scholar 

  • Rudec T, Baumgartner A, Manger R (2013) A fast work function algorithm for solving the \(k\)-server problem. Cent Eur J Oper Res 21(1):187–205

    Article  MathSciNet  Google Scholar 

Download references

Acknowledgements

This work was partially supported by Special Scientific Research Plan of Shaanxi Province Education Department (17JK0785) and the National Natural Science Foundation of China under Grant No. 11771346. The authors would like to thank the reviewer for helpful comments and suggestions.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Yongxi Cheng.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Appendix A: Proof of Lemma 2.1

Appendix A: Proof of Lemma 2.1

The following is the proof of Lemma 2.1 given in Koutsoupias and Papadimitriou (1995).

Definition A.1

A function w is called quasiconvex if for all configurations A, B, there exists a bijection \(h: A \rightarrow B\) such that for all bipartitions of A into XY:

$$\begin{aligned} w(A)+w(B)\ge w(X\cup h(Y))+w(h(X)\cup Y). \end{aligned}$$
(1)

Notice that the union (\(\cup \)) in the definition denotes the union of multisets. Before showing that all work functions are quasiconvex, the following lemma provides a stronger form of the quasiconvexity condition by restricting the set of possible bijections.

Lemma A.1

If there exists a bijection h that satisfies the conditions in Definition A.1, then there exists a bijection \(h'\) that satisfies the same conditions and \(h'(x)=x\) for all \(x\in A\cap B\).

Proof

Let h be a bijection from A to B that satisfies the conditions of the definition above and maps the maximum number of elements in \(A\cap B\) to themselves. Assume that, for some \(a\in A \cap B\), we have \(h(a)\ne a\) . Define a bijection \(h'\) that agrees with h everywhere except that

$$\begin{aligned} h'(a)=a~~~~~~ \text{ and }~~~~~~ h'(h^{-1}(a))=h(a) \end{aligned}$$

(\(h'\) interchanges the values of h on a and \(h^{-1}(a))\).

Consider now a bipartition of A into X and Y and assume (without loss of generality) that \(h^{-1}(a)\in X\). If \(a\in X\), then \(h(X)= h'(X)\) and \(h(Y)=h'(Y)\) and (1) holds for \(h'\). Otherwise, when \(a\notin X\), we derive the quasiconvexity condition for X and Y from the quasiconvexity condition for \(X'=X+a\) and \(Y'=Y-a\) as follows:

Since, \(h(Y')=h'(Y')\) and \(h(X')=h'(X')\), we have that

$$\begin{aligned} X'\cup h(Y')=X'\cup h'(Y')=(X+a)\cup h'(Y-a)=X\cup h'(Y), \end{aligned}$$

and similarly, \(h(X')\cup Y'=h'(X)\cup Y\). From these, we get

$$\begin{aligned} \begin{array}{cl} w(A)+w(B) &{}\ge w(X'\cup h(Y'))+w(h(X')\cup Y')\\ {} &{} =w(X\cup h'(Y))+w(h'(X)\cup Y). \end{array} \end{aligned}$$

Therefore, \(h'\) satisfies the quasiconvexity condition. Because \(h'\) maps at least one more element in \(A\cap B\) to itself than h, it contradicts the assumption that h maps the maximum number of elements in \(A\cap B\) to themselves.

We conclude that \(h(a)=a\) for all \(a\in A\cap B\), and the lemma holds. \(\square \)

Lemma A.2

(Quasiconvexity lemma) All work functions are quasiconvex.

Proof

The proof is by induction on the number of requests.

Recall that the initial work function \(w_e(X)\) of a configuration X is equal to \(D(A_0,X)\), where \(A_0\) is the initial configuration. So we have

$$\begin{aligned} w(A)+w(B)=D(A_0,A)+D(A_0,B). \end{aligned}$$

Fix two matchings \(M(A_0,A)\) and \(M(A_0,B)\) that realize the minima of \(D(A_0,A)\) and \(D(A_0,B)\). Each point \(x_j\) in \(A_0\) is matched to some point \(a_j\) in A and \(b_j\) in B. Consider the bijection \(h: A\rightarrow B\) that maps each \(a_j\) to \(b_j\). For any bipartition of A into X and Y, \(w(X+h(Y))+w((h(X) + Y)\) is equal to the sum of two minima matchings between \(A_0\), \(X+ h(Y)\) and \(A_0\), \(h(X)+Y\). Since we can rearrange the matchings \(M(A_0,A)\) and \(M(A_0,B)\) to obtain two matchings (not necessarily minima) between \(A_0\), \(X+ h(Y)\) and \(A_0\), \(h(X)+Y\), it follows that \(w(A)+w(B)\ge w(X+h(Y))+w(h(X)+Y)\).

For the induction step, assume that w is quasiconvex. We want to show that the resulting \(w'\) after request r is also quasiconvex.

Fix two configurations A and B. Using Fact 1 to express \(w'\) in terms of w, we get that \(w'(A)=w(A-a+r)+d(r,a)\) for some \(a\in A\); similarly \(w'(B)=w(B-b+r)+d(r,b)\) for some \(b\in B\). The induction hypothesis is that w is quasiconvex, so there exists a bijection h from \(A-a+r\) to \(B-b+r\) that satisfies the quasiconvexity condition. Furthermore, Lemma A.1 allows us to assume that \(h(r)=r\).

Consider now a bijection \(h': A\rightarrow B\) that agrees with h everywhere, except that \(h'(a)=b\). We show that \(h'\) satisfies the requirements of the quasiconvexity condition of \(w'\). Consider a bipartition of A into X and Y and without loss of generality assume that \(a\in X\). We have:

$$\begin{aligned} \begin{array}{cl} w'(A)+w'(B) &{}=w(A-a+r)+w(B-b+r)+d(r,a)+d(r,b)\\ &{}=w((X-a+r)\cup Y)+w(B-b+r)+d(r,a)+d(r,b)\\ &{}\ge w((X-a+r)\cup h(Y))+w(h(X-a+r)\cup Y)\\ &{}\quad +d(r,a)+d(r,b)\\ &{}= w((X-a+r)\cup h'(Y))+w((h'(X)-b+r)\cup Y)\\ &{}\quad +d(r,a)+d(r,b)\\ &{}\ge w'(X\cup h'(Y))+w'(h'(X)\cup Y), \end{array} \end{aligned}$$

where the first inequality is based on the quasiconvexity of w and the second one on Fact 1. So, \(w'\) is quasiconvex and the lemma follows. \(\square \)

Now we use the quasiconvexity condition to prove the next two lemmata. In fact, the following weaker condition derived from quasiconvexity is used:

$$\begin{aligned} \forall a\in A~ \exists b\in B: ~~w(A)+w(B)\ge w(A-a+b)+w(B-b+a). \end{aligned}$$

Lemma A.3

Let w be a work function. Consider a new request at r and the resulting work function \(w'\). If A is a minimizer of r with respect to w, then A is also a minimizer of r with respect to \(w'\).

Proof

It suffices to show that for all configurations B:

$$\begin{aligned} w'(B)-\sum \limits _{b\in B} d(r,b)\ge w'(A)-\sum \limits _{a\in A} d(r,a), \end{aligned}$$

or equivalently:

$$\begin{aligned} w'(B)-\sum \limits _{b\in B} d(r,b)+w(A)\ge w'(A)-\sum \limits _{a\in A} d(r,a)+w(A). \end{aligned}$$

In order to show this we need the following: From Fact 1, we get that there exists \(b'\in B\) such that

$$\begin{aligned} w'(B)=w(B-b'+r)+d(r,b'). \end{aligned}$$

Using quasiconvexity, we get that there exists \(a'\in A\) such that

$$\begin{aligned} w(B-b'+r)+w(A)\ge w(B-b'+a')+w(A-a'+r). \end{aligned}$$

Finally, since A is a minimizer of r, we have that

$$\begin{aligned} w(B-b'+a')-\sum \limits _{b\in B-b'+a'} d(r,b)\ge w(A)-\sum \limits _{a\in A}d(r,a). \end{aligned}$$

Putting all these together:

$$\begin{aligned}\begin{array}{cl} &{}w'(B)+w(A)-\sum \limits _{b\in B} d(r,b) \\ &{}\quad =w(B-b'+r)+d(r,b')+w(A)-\sum \limits _{b\in B} d(r,b) \\ &{}\quad =w(B-b'+r)+w(A)-\sum \limits _{b\in B-b'+r} d(r,b) \\ &{}\quad \ge w(B-b'+a')+w(A-a'+r)-\sum \limits _{b\in B-b'+r} d(r,b) \\ &{}\quad =w(B-b'+a')+w(A-a'+r)+d(r,a')-\sum \limits _{b\in B-b'+a'} d(r,b) \\ &{}\quad \ge w(A)+w(A-a'+r)+d(r,a')-\sum \limits _{a\in A} d(r,a) \\ &{}\quad \ge w(A)+w'(A)-\sum \limits _{a\in A} d(r,a), \end{array} \end{aligned}$$

where the last inequality is based on Fact 1. The lemma follows. \(\square \)

The following lemma has the same premises with Lemma A.3, but a different conclusion:

Lemma A.4

Let w be a work function. Consider a new request at r and the resulting work function \(w'\). If A is a minimizer of r with respect to w, then the extended cost occurs at A, that is

$$\begin{aligned} w'(A)-w(A)=\max \limits _{X}\{w'(X)-w(X)\}. \end{aligned}$$

Proof

The proof is rather similar to the proof of Lemma A.3. Notice first that it suffices to show that for all configurations B:

$$\begin{aligned} w'(A)+w(B)\ge w'(B)+w(A). \end{aligned}$$

By Fact 1, we get that there exists \(a'\in A\) such that

$$\begin{aligned} w'(A)=w(A-a'+r)+d(r,a'). \end{aligned}$$

Using quasiconvexity, we also get that there exists \(b'\in B\) such that

$$\begin{aligned} w(A-a'+r)+w(B)\ge w(A-a'+b')+w(B-b'+r). \end{aligned}$$

Finally, since A is a minimizer of r with respect to w:

$$\begin{aligned} w(A-a'+b')-\sum \limits _{a\in A-a'+b'} d(r,a)\ge w(A)-\sum \limits _{a\in A} d(r,a), \end{aligned}$$

which is equivalent to

$$\begin{aligned} w(A-a'+b')+d(r,a')\ge w(A)+d(r,b'). \end{aligned}$$

Combining all these we get:

$$\begin{aligned} \begin{array}{cl} w'(A)+w(B) &{}=w(A-a'+r)+d(r,a')+w(B) \\ {} &{}\ge w(A-a'+b')+d(r,a')+w(B-b'+r) \\ {} &{}\ge w(A)+d(r,b')+w(B-b'+r) \\ {} &{}\ge w(A)+w'(B). \end{array} \end{aligned}$$

Again, the last inequality is based on Fact 1. \(\square \)

Lemmata A.3 and A.4 can be combined into Lemma 2.1, which characterizes where the extended cost occurs. The proof of Lemma 2.1 is established.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Zhang, W., Cheng, Y. A new upper bound on the work function algorithm for the k-server problem. J Comb Optim 39, 509–518 (2020). https://doi.org/10.1007/s10878-019-00493-z

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10878-019-00493-z

Keywords

Navigation