Skip to main content
Log in

Minmax Regret k-Sink Location on a Dynamic Path Network with Uniform Capacities

  • Published:
Algorithmica Aims and scope Submit manuscript

Abstract

In Dynamic flow networks an edge’s capacity is the amount of flow (items) that can enter it in unit time. All flow must be moved to sinks and congestion occurs if flow has to wait at a vertex for other flow to leave. In the uniform capacity variant all edges have the same capacity. The minmax k-sink location problem is to place k sinks minimizing the maximum time before all items initially on vertices can be evacuated to a sink. The minmax regret version introduces uncertainty into the input; the amount at each source is now only specified to within a range. The problem is to find a universal solution (placement of k sinks) whose regret (difference from optimal for a given input) is minimized over all inputs consistent with the given range restrictions. The previous best algorithms for the minmax regret version of the k-sink location problem on a path with uniform capacities ran in O(n) time for \(k=1\), \(O(n \log ^ 4 n)\) time for \(k=2\) and \({\varOmega }(n^{k+1})\) for \( k >2\). A major bottleneck to improving those solutions was that minmax regret seemed an inherently global property. This paper derives new combinatorial insights that allow decomposition into local problems. This permits designing two new algorithms. The first runs in \(O(n^3 \log n)\) time independent of k and the second in \(O( n k^2 \log ^{k+1} n)\) time. These improve all previous algorithms for \(k >1\) and, for \(k > 2\), are the first polynomial time algorithms known.

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.

Institutional subscriptions

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9

Similar content being viewed by others

Notes

  1. On trees, a corresponding result for \(k=1\) [9, 21] shows the existence of a set of \(O(n^2)\) worst-case scenarios with nothing known when \(k >1\).

  2. Note that there is some redundancy in this definition in that, \(\forall t\), \(s^*_B(t,t)= s^*_B(0,0)\).

  3. Without delving into details we note that the algorithm presented can alternatively be derived as a parameteric search [29] implementation of binary search using the feasibility test of Lemma 13 to implement the binary search comparison.

  4. We note that a more delicate algorithm could actually calculate all \(O(n^2)\) values in \(O(n^2)\) time from scratch. That would not improve the overall running time, though, so we do not provide details.

  5. The statement, “Given x”, will always include knowing i such that \(x_i \le x \le x_{i+1}\).

  6. vertex refers to a vertex of P while node refers to a node of \(T^s\).

References

  1. Aissi, H., Bazgan, C., Vanderpooten, D.: Min–max and min–max regret versions of combinatorial optimization problems: a survey. Eur. J. Oper. Res. 197(2), 427–438 (2009)

    Article  MathSciNet  MATH  Google Scholar 

  2. Arumugam, G.P., Augustine, J., Golin, M.J., Srikanthan, P.: A polynomial time algorithm for minimax-regret evacuation on a dynamic path. arXiv:1404.5448 (2014)

  3. Averbakh, I., Berman, O.: Minimax regret p-center location on a network with demand uncertainty. Location Science 5(4), 247–254 (1997)

    Article  MATH  Google Scholar 

  4. Averbakh, I., Lebedev, V.: Interval data minmax regret network optimization problems. Discrete Appl. Math. 138(3), 289–301 (2004)

    Article  MathSciNet  MATH  Google Scholar 

  5. Benkoczi, R., Bhattacharya, B., Higashikawa, Y., Kameda, T., Katoh, N.: Minsum k-sink problem on dynamic flow path networks. In: International Workshop on Combinatorial Algorithms, pp. 78–89. Springer (2018)

  6. Bentley, J.L.: Multidimensional divide-and-conquer. Commun. ACM 23(4), 214–229 (1980)

    Article  MathSciNet  MATH  Google Scholar 

  7. Bhattacharya, B., Golin, M.J., Higashikawa, Y., Kameda, T., Katoh, N.: Improved algorithms for computing k-sink on dynamic flow path networks. In: Proceedings of WADS’2017 (2017)

  8. Bhattacharya, B., Higashikawa, Y., Kameda, T., Katoh, N.: An o (n\(\hat{~}\) 2 log\(\hat{~}\) 2 n) time algorithm for minmax regret minsum sink on path networks. In: 29th International Symposium on Algorithms and Computation (ISAAC 2018) (2018)

  9. Bhattacharya, B., Kameda, T.: Improved algorithms for computing minmax regret sinks on dynamic path and tree networks. Theor. Comput. Sci. 607, 411–425 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  10. Bhattacharya, B., Kameda, T., Song, Z.: A linear time algorithm for computing minmax regret 1-median on a tree network. Algorithmica 70(1), 2–21 (2014)

    Article  MathSciNet  MATH  Google Scholar 

  11. Bhattacharya, B., Kameda, T., Song, Z.: Minmax regret 1-center algorithms for path/tree/unicycle/cactus networks. Discrete Appl. Math. 195, 18–30 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  12. Bhattacharya, Binay K., Kameda, Tsunehiko: A linear time algorithm for computing minmax regret 1-median on a tree. In: COCOON’2012, pp. 1–12 (2012)

  13. Brodal, G.S., Georgiadis, L., Katriel, I.: An O(nlogn) version of the Averbakh–Berman algorithm for the robust median of a tree. Oper. Res. Lett. 36(1), 14–18 (2008)

    Article  MathSciNet  MATH  Google Scholar 

  14. Candia-Véjar, A., Álvarez-Miranda, E., Maculan, N.: Minmax regret combinatorial optimization problems: an algorithmic perspective. RAIRO - Oper. Res. 45(2), 101–129 (2011)

    Article  MathSciNet  MATH  Google Scholar 

  15. Chen, D., Golin, M.: Sink evacuation on trees with dynamic confluent flows. In: 27th International Symposium on Algorithms and Computation (ISAAC 2016), pp. 25:1–25:13 (2016)

  16. Cheng, S.-W., Higashikawa, Y., Katoh, N., Ni, G., Su, B., Xu, Y.: Minimax regret 1-sink location problems in dynamic path networks. In: Proceedings of TAMC’2013, pp. 121–132 (2013)

  17. Conde, E.: A note on the minmax regret centdian location on trees. Oper. Res. Lett. 36(2), 271–275 (2008)

    Article  MathSciNet  MATH  Google Scholar 

  18. Ford, L.R., Fulkerson, D.R.: Constructing maximal dynamic flows from static flows. Oper. Res. 6(3), 419–433 (1958)

    Article  MathSciNet  MATH  Google Scholar 

  19. Golin, M.J., Khodabande, H., Qin, B.: Non-approximability and polylogarithmic approximations of the single-sink unsplittable and confluent dynamic flow problems. In: 28th International Symposium on Algorithms and Computation (ISAAC 2017), pp. 41:1–41:13 (2017)

  20. Higashikawa, Y., Augustine, J., Cheng, S.-W., Golin, M.J., Katoh, N., Ni, G., Bing, S., Yinfeng, X.: Minimax regret 1-sink location problem in dynamic path networks. Theor. Comput. Sci. 588(11), 24–36 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  21. Higashikawa, Y., Golin, M.J., Katoh, N.: Minimax regret sink location [roblem in dynamic tree networks with uniform capacity. In: Proceedings of the 8’th International Workshop on Algorithms and Computation (WALCOM’2014), pp. 125–137 (2014)

  22. Higashikawa, Y., Golin, M.J., Katoh, N.: Multiple sink location problems in dynamic path networks. Theoretical Computer Science 607, 2–15 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  23. Hoppe, B., Tardos, É.: The quickest transshipment problem. Math. Oper. Res. 25(1), 36–62 (2000)

    Article  MathSciNet  MATH  Google Scholar 

  24. Kamiyama, N.: Studies on quickest flow problems in dynamic networks and arborescence problems in directed graphs: a theoretical approach to evacuation planning in urban areas. Ph.D. thesis, Kyoto University (2009)

  25. Kouvelis, P., Gang, Y.: Robust Discrete Optimization and Its Applications. Kluwer Academic Publishers, Dordrecht (1997)

    Book  MATH  Google Scholar 

  26. Li, H., Yinfeng, X.: Minimax regret 1-sink location problem with accessibility in dynamic general networks. Eur. J. Oper. Res. 250(2), 360–366 (2016)

    Article  MathSciNet  MATH  Google Scholar 

  27. Li, H., Xu, Y., Ni, G.: Minimax regret vertex 2-sink location problem in dynamic path networks. J. Comb. Optim. 31(1), 79–94 (2016)

    Article  MathSciNet  MATH  Google Scholar 

  28. Mamada, S., Uno, T., Makino, K., Fujishige, S.: An \(O(n \log ^2 n) \)algorithm for the optimal sink location problem in dynamic tree networks. Discrete Appl. Math. 154(2387–2401), 251–264 (2006)

    MATH  Google Scholar 

  29. Megiddo, N.: Applying parallel computation algorithms in the design of serial algorithms. J. ACM 30(4), 852–865 (1983)

    Article  MathSciNet  MATH  Google Scholar 

  30. Ni, G., Xu, Y., Dong, Y.: Minimax regret k-sink location problem in dynamic path networks. In: Proceedings of the 2014 International Conference on Algorithmic Aspects of Information and Management (AAIM 2014) (2014)

  31. Osborne, M.J., Rubinstein, A.: A Course in Game Theory. MIT Press, Cambridge (1994)

    MATH  Google Scholar 

  32. Puerto, J., Rodriguez-Chia, A.M., Tamir, A.: Minimax regret single-facility ordered median location problems on networks. INFORMS J. Comput. 21(1), 77–87 (2008)

    Article  MathSciNet  MATH  Google Scholar 

  33. Puerto, J., Ricca, F., Scozzari, A.: Minimax regret path location on trees. Networks 58(2), 147–158 (2011)

    MathSciNet  MATH  Google Scholar 

  34. Wang, H.: Minmax regret 1-facility location on uncertain path networks. In: Proceedings of the 24th International Symposium on Algorithms and Computation (ISAAC’13), pp. 733–743 (2013)

  35. Wang, H.: Minmax regret 1-facility location on uncertain path networks. Eur. J. Oper. Res. 239(3), 636–643 (2014)

    Article  MathSciNet  MATH  Google Scholar 

  36. Yinfeng, X., Li, H.: Minimax regret 1-sink location problem in dynamic cycle networks. Inf. Process. Lett. 115(2), 163–169 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  37. Ye, J.-H., Wang, B.-F.: On the minmax regret path median problem on trees. J. Comput. Syst. Sci. 1, 1–12 (2015)

    Article  MathSciNet  MATH  Google Scholar 

  38. Yu, H.-I., Lin, T.-C., Wang, B.-F.: Improved algorithms for the minmax-regret 1-center and 1-median problems. ACM Trans. Algorithms 4(3), 1–27 (2008)

    Article  MathSciNet  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Mordecai J. Golin.

Additional information

Publisher's Note

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

Guru Prakash Arumugam: Work done while at the Indian Institute of Technology Madras (IIT Madras) and when interning at Hong Kong UST. John Augustine: Work supported in part by an Extra Mural Research Grant (EMR/2016/003016) and a MATRICS Project (MTR/2018/001198) both funded by SERB, DST, India. Mordecai J. Golin: Work partially supported by RGC CERG 16208415. Prashanth Srikanthan: Work done while at IIT Madras and when interning at Hong Kong UST.

Appendices

Appendix

The Critical Vertex Tree Data Structure

In this section we describe the CVT Data Structure of [9] and how it can be used to implement the operations described in Lemma 11 in \(O(\log n)\) time.

Let s be any fixed scenario. We start with [9]’s O(n) time construction (slightly modified) of an O(n) space CVT for a fixed s and afterwards describe how this can be further modified, to construct in O(n) time an extended CVT that permits queries to any \(s \in S^*\).

Assume that \(n+1\) is a power of 2. If not, pad path P with empty vertices on the right (with no weights) to reach a power of 2. Also before starting, perform a O(n) preprocessing step, calculating and storing all of the values \(W^s_i = \sum _{j=0}^i w_{j}(s)\). After this step, for any \(a \le b\), the values \(W^s_{ a, b} = \sum _{j=a}^b w_{j}(s)\) can be calculated in O(1) time. Note that, givenFootnote 5\(x < y\), the values

$$\begin{aligned} W^s(x,y) = \sum _{x \le x_j \le y} w_j(s)= W^s_b - W^s_{a-1} \end{aligned}$$

can then also be calculated in O(1) time.

Recall that \({\varTheta }_{L}(P,x,s)\) and \({\varTheta }_{R}(P,x,s)\) were defined to be the time needed to evacuate everything to the left (resp. right) of sink x to x under scenario s. Then, from Eq. 1,

$$\begin{aligned} {\varTheta }_{L}([x',x],x,s)]=\max _{ x' \le x_i < x\,:\, W^s(x',x_i) > 0 } \left\{ (x-x_{i})\tau +\frac{W^s(x',x_i)}{c} \right\} . \end{aligned}$$
(49)

Similarly, set

$$\begin{aligned} {\varTheta }_{R}([x',x],x',s) = \max _{ x' < x_i \le x \,:\,W^s(x_i,x')>0} \left\{ (x_{i}-x')\tau +\frac{W^s(x_i,x')}{c} \right\} . \end{aligned}$$
(50)

Definition 17

The left/right critical vertices of \(([x',x],s)\) are

$$\begin{aligned} C_{L}([x',x],s)&\,{:=}\,&\mathop {\mathrm{arg~max}}\limits _{ i\,:\, x' \le x_i< x\,:\, W^s(x',x_i)>0} \left\{ (x-x_{i})\tau +\frac{W^s(x',x_i)}{c} \right\} ,\\ C_{R}([x',x],s)&\,{:=}\,&\mathop {\mathrm{arg~max}}\limits _{ i\,:\, x' < x_i \le x\,:\, W^s(x_i,x)> 0} \left\{ (x_{i}-x)\tau +\frac{W^s(x_i,x)}{c} \right\} . \end{aligned}$$
Fig. 10
figure 10

The left critical-vertex of path \([x',x]\) is the node m at which the top equation in Definition 17 is maximized. Intuitively, this is the last vertex at which the first supply from \(x'\) has to stop due to congestion when evacuating to x. The diagram illustrates two paths \([x',x]\) and \([x,x'']\) and their respective critical vertices \(m,m'\). The main fact upon which the CVT is based is that the critical vertex of combined path \([x',x'']\) must be one of m and \(m'\)

Intuitively, the critical vertex is the last location at which items starting on the leftmost (rightmost) vertex encounter congestion. Note that if the critical vertices of \([x',x]\) are known, then \({\varTheta }_{L}([x',x],x,s)\) and \({\varTheta }_{R}([x',x],x's)\) can be calculated in O(1) time. The major observation [9] upon which the CVT data structure is based is (Fig. 10) that if \(x' \le x \le x''\) then the left (right) critical vertex of \([x',x'']\) is either (i) the left (right) critical vertex of \([x',x]\) or (ii) the left (right) critical vertex of \([x,x'']\). Thus the critical vertices of \(([x',x''],s)\) can be found in O(1) time from the critical vertices of its two subpaths.

The data structure will require a slightly extended version of this.

Lemma 24

Let \(i \le j \le k\). The critical vertices of \((P_{i k},s)\) can be constructed in O(1) time from the critical vertices of \((P_{i j},s)\) and \((P_{(j+1) k},s)\).

Proof

First note that because \((P_{j (j+1)},s)\) only contains two vertices, its critical vertices can be found in O(1) time.

The critical vertices of \((P_{i (j+1)},s)\) can be calculated in O(1) time from those of \((P_{i j},s)\) and \((P_{j (j+1)},s)\). The critical vertices of \((P_{i k},s)\) can be calculated from those of \((P_{i (j+1)},s)\) and \((P_{(j+1) k},s)\) in a further O(1) time. \(\square \)

A critical vertex tree \(T^s\) for s was then defined by [9] as follows.

  • \(T^s\) is a balanced binary tree with the vertices of P as its leaf nodesFootnote 6.

  • For a node \(u \in T^s\) let L(u) (resp. R(u)) denote the index of the leftmost (rightmost) vertex on P that belongs to the subtree \(T^s(u)\) rooted at u. Node \( u \in T^s(u)\) corresponds to the subpath \(P(u) = \left[ x_{L(u)}, x_{R(u)}\right] \).

  • Vertex \(u \in T^s\) will store the critical values \(C_L(P(u),s)\) and \(C_R(P(u),s)\).

A leaf node corresponds to a single vertex path and is thus its own critical vertex. For non-leaf u, let \(u_l\) and \(u_r\) denote its left and right children. Then \(P(u_l) = \left[ x_{L(u_l)},x_{R(u_l)}\right] \) and \(P(u_r) = \left[ x_{L(u_r)},x_{R(u_r)}\right] \) where \(R(u_l) + 1 = L(u_r)\). Lemma 24 thus permits finding the critical vertices of P(u) from the critical vertices of \(P(u_l)\) and \(P(u_r)\) in O(1) time. The entire critical vertex tree \(T^s\) can therefore be constructed in O(n) time (Fig. 11).

Because \(n+1\) is a power of 2, \(T^s\) may be stored implicitly in an array so that any node u can be accessed directly in O(1) time. In addition, if u has height h then P(u) has the form \(\left[ x_{v 2^h}, x_{(v+1)2^h-1}\right] \) and every path of the form \(\left[ x_{v 2^h}, x_{(v+1)2^h-1}\right] \) is P(u) for some u. In particular, for any u this permits evaluating L(u) and R(u) in O(1) time. For \(u,u'\), this in turn permits checking in O(1) time whether \(P(u) \subset P(u')\), \(P(u') \subset P(u)\) or \(P(u) \cap P(u') = \emptyset \) (these three are the only possibilities).

Fig. 11
figure 11

The Critical Vertex Tree \(T^s\) for scenario s is a balanced tree with leaf nodes corresponding to path vertices and internal tree nodes corresponding to the subpath spanning descendant leaves. Node u, corresponding to subpath \(P(u)=\left[ x_{L(u)}, x_{R(u)}\right] \), will store the locations of the left and right critical vertices of P(u) under scenario s

We now define

Definition 18

Set \(s^+\) to be the scenario with \(\forall j, w_j(s) = w_j^+\) and \(s^-\) to be the scenario with \(\forall j, w_j(s) = w_j^-\). The Critical Vertex Tree (CVT) Data Structure is the pair \(T^{s^+}\) and \(T^{s^-}\) along with \(W^{s^+}_i\), \(W^{s^-}_i\) for all \(i=0,1,\ldots ,n\).

For \(t_1 \le t_2\) let \(s= s^*_B(t_1,t_2)\) and consider \(T^{s}\). Note that all three trees \(T^{s^+}\), \(T^{s^-}\) and \(T^{s}\) have the same topology and only differ in the values stored at the nodes. Let \(u^{s^+}\), \(u^{s^-}\) and \(u^s\) respectively denote the same node u in the three trees. It is straightforward to see that

  1. 1.

    If \(R(u) < t_1\) or \(R(u) > t_2\) then the subtrees rooted at \(u^{s^-}\) and \(u^s\) are identical (including their critical vertex values). Such nodes \(u\in T^s\) are called low nodes.

  2. 2.

    If \(t_1 \le L(u) \le R(u) \le t_2\) then the subtrees rooted at \(u^{s^+}\) and \(u^s\) are identical (including their critical vertex values). Such nodes \(u \in T^s\) are called high nodes.

  3. 3.

    If \( u \in T^s\) is neither low nor high it is called a split node. Split nodes must be one of the \(O(\log n)\) tree ancestors of \(x_{t_1}\) and/or \(x_{t_2}\).

Given the CVT Data Structure and \(s= s^*_B(t_1,t_2)\) this permits implicitly “constructing” \(T^s\) in \(O(\log n)\) time as follows. By processing the ancestors of \(x_{t_1}\) and \(x_{t_2}\) from lowest to highest and using the preprocessed information from the CVT, the critical vertices of the split nodes u can be calculated in O(1) time per node or \(O(\log n)\) total time. Since there are at most two such split nodes u’s of a given height, their information can be stored in an array permitting O(1) lookup.

The above gives an implicit construction of \(T^s\); the critical vertex information of any node \(u\in T^s\) can be retrieved in O(1) time from \(T^{s^+}\), \(T^{s^-}\) or the split node array by first determining whether it is low, high or split and then looking it up in the appropriate array. Finally, note that \(W_i^s\) values can be retrieved from the \(W^{s^+}_i\) and \(W^{s^-}_i\) values in O(1) time. Thus, given the CVT Data Structure, after the \(O(\log n)\) construction of the split-node array, we can assume the existence of the CVT for s. We write this as

Lemma 25

Assume the CVT Data Structure has already been built. Then for any \(t_1 \le t_2\) and \(s= s^*_B(t_1,t_2)\), \(T^s\) can be built in \(O(\log n)\) time.

Definition 19

  • A node path in P is a subpath of the form \(P(u) = \left[ x_{v 2^h}, x_{(v+1)2^h-1}\right] \) where \(u \in T^s\).

  • Let \( i \le j\). A Tree Decomposition of \(P_{i j}\) of size t is a sequence \(i-1=i_0< i_1< \ldots < i_{t} =j\) such that for \(k=1,\ldots ,t\), \(P_{(k)} =[x_{i_{k-1}+1}, x_{i_{k}}]\) is a node path. Equivalently, it is a sequence of nodes \(u_1,u_2,\ldots ,u_t \in T^s\) such that \(P(u_k) = [L(u_k), R(u_k)] = [x_{i_{k-1}+1}, x_{i_{k}}]\).

  • A Minimal Tree Decomposition (MTD) of \(P_{i j}\) is a tree decomposition of minimal size.

Note that the MTD of \(P_{i j}\) is unique and, for each h, contains at most two subpaths of length \(2^h\), and thus has size \(O(\log n)\). It can also easily be constructed in \(O(\log n)\) time. See Fig. 12 for an example.

Fig. 12
figure 12

The MTD for \(P_{i j}\) with \(i=29\) and \(j = 329\). The path \([x_i, x_j]\) can be decomposed into the sequence 28, 29, 31, 63, 127, 255, 319, 327, 329 which corresponds to the 8 node paths shown above, where the size of each node path is denoted below it

For a given \(P_{i j}\) and \(s= s^*_B(t_1,t_2)\) let MTD[ijs] denote the corresponding MTD of \(P_{i j}\) of size \(t = O(\log n)\) along with the associated three arrays L[1..t], R[1..t] and \(R'[1..t]\) defined as follows: for \(1 \le k \le t\), set

$$\begin{aligned} L[k]&\,{:=}\, {\varTheta }_L(P_{i {R(u_k)}}, x_{R(u_k)},s)&\quad&\text{(left } \text{ evacuation } \text{ time } \text{ from } \, x_i \, \text{ to } \, x_{R_{u_k}}\text{) },\\ R[k]&\,{:=}\, {\varTheta }_R(P_{L(u_k),x_j},x_{ L(u_k)},s)&\quad&\text{(right } \text{ evacuation } \text{ time } \text{ from } \, x_j \, \text{ to } \, x_{L_{u_k}}\text{) },\\ R'[k]&\,{:=}\, {\varTheta }_R(P_{i, {R(u_k)}}, x_i,s)&\quad&\text{(right } \text{ evacuation } \text{ time } \text{ from } \, x_{R_{u_k}} \, \text{ to } \, x_i\text{) }. \end{aligned}$$

Given a preconstructed CVT data structure these arrays can be filled in by first building \(T^s\) in \(O(\log n)\) time using Lemma 25 and then repeated applications of Lemma 24 utilizing the critical vertex values stored at the nodes of \(T^s\).

We can now prove Lemma 11.

Proof of Lemma 11

The proof first first proves (1), then (3) and (4) and then returns to prove (2). In what follows, the left and right children of node u will be denoted by \(u_l\) and \(u_r\). \(t=O(\log n)\) will always denote the size of the current MTD.

\({\hbox {Lemma}~11 \, (1): \, \hbox {Calculating} \, {\varTheta }_L(P_{i j},x, s) \, \hbox {and} \, {\varTheta }_R(P_{i j},x,s).}\)

To calculate \({\varTheta }_L(P_{i j},x, s)\), first binary search in \(O(\log n)\) time to find v such that \(x_{v-1} < x \le x_v \le x_j\). Next build MTD[ivs] in O(t) time. From Lemma 15

$$\begin{aligned} {\varTheta }_L(P_{i j},x, s) = {\varTheta }_L(P_{i v},x, s) - \tau (x_v-x) = L[t] - \tau (x_v-x). \end{aligned}$$

The calculation of \({\varTheta }_R(P_{i j},x,s)\) is similar (and symmetric).

\({\hbox {Lemma}~11 \, (3): \, \hbox {Constructing} \, x''=\max \{x' \in [x_i,x_j] \,:\, {\varTheta }_L(P',x',s) \le \alpha \}.}\)

First build MTD[ijs] in \(O(\log n)\) time.

If \({\varTheta }_L(P_{i j} ,x_j,s) = L[t] \le \alpha \) then the answer is just \(x''=x_j\). We therefore assume that there exists \(v \le j\) such that

$$\begin{aligned} v = \min \left\{ r \,:\, i \le r < j, \text{ and } {\varTheta }_L(P_{i j} ,x_r,s) \ge \alpha \right\} . \end{aligned}$$

Given v, part (1) of the Lemma permits calculating \({\varTheta }_L(P_{i v} ,x_v,s) \) in \(O(\log n)\) time. From Lemma 15, for \(x' \in (x_{v-1},x_v]\),

$$\begin{aligned} {\varTheta }_L(P_{i j},x',s) = {\varTheta }_L(P_{i v},x',s) = {\varTheta }_L(P_{i v} ,x_v,s) - \tau (x_v-x'). \end{aligned}$$

Thus

$$\begin{aligned} x'' =\left\{ \begin{array}{ll} x_{v-1} &{} \text{ if } {\varTheta }_L(P_{i v} ,x_v,s) - \tau (x_v-x_{v-1}) > \alpha ,\\ \frac{1}{\tau }\left( \alpha - {\varTheta }_L(P_{i v} ,x_v,s) + \tau x_v\right) &{} \text{ otherwise }. \end{array} \right. \end{aligned}$$

and \(x''\) can therefore be found in \(O(\log n)\) time from v. It remains to show how to find v in \(O(\log n)\) time from MTD[ijs].

To find v, first use \(O(\log n)\) time to find the smallest k such that \(L[k] \ge \alpha \).

Use part (1) of the Lemma to check, in \(O(\log n)\) time, whether \({\varTheta }_L(P_{i j},x_{L(u_k)}, s) \ge \alpha \). If yes, then because \(R(u_{k-1}) = L(u_k) -1\), \(v=L(u_k)\) and the process finishes.

Otherwise \(x_v \in P(u_k)\). Set \(u \,{:=}\, u_k\). We now simulate a binary search for \(x_v \in P(u)\) by walking down the subtree of \(T^s\) rooted at u, on each level deciding in O(1) time whether to walk left or right. See Fig. 13.

Fig. 13
figure 13

Illustration of the proof of Lemma 11 (3), trying to find leftmost v satisfying \({\varTheta }_L(P_{i v}, x_{v},s) \ge \alpha \). It is known in advance that \(x_v\in P(u)\). Testing whether \({\varTheta }_L(P_{i R(u_l)}, x_{R(u_l)},s) \ge \alpha \) permits determining whether \(x_v \in u_l\) or \(x_v \in u_r\)

To start, set \({\bar{P}} \,{:=}\, P_{i (L(u)-1)}\) and from MTD[ijs] construct the left critical vertices of \({\bar{P}}\) in \(O(\log n)\) time. We know that

$$\begin{aligned}&(\mathrm{i})\, x_v \in P(u),\quad (\mathrm{ii})\, {\varTheta }_L({\bar{P}} , x_{L(u)-1},s) < \alpha , \nonumber \\&(\mathrm{iii})\, {\varTheta }_L(P_{i R(u)}, x_{R(u)},s) \ge \alpha . \end{aligned}$$
(51)
  1. 1.

    If P(u) is one node, then \(u =x_v\). Stop.

  2. 2.

    Otherwise set \({\bar{P}}' \,{:=}\, P_{i R(u_l)}\), the concatenation of \({\bar{P}}\) and and \(P(u_l)\). The left critical vertices of \(P(u_l)\) can be extracted from \(T^{s}\) in O(1) time. Lemma 24 permits combining them with the known critical vertices of \({\bar{P}}\) to construct the left critical vertices of \({\bar{P}}'\) in O(1) time. This in turn permits the calculation of \({\varTheta }_L({\bar{P}}',x_{R(u_l)},s)\) in O(1) time

  3. 3.

    If \({\varTheta }_L({\bar{P}}',x_{R(u_l)},s) < \alpha \), set \({\bar{P}} \,{:=}\, {\bar{P}}'\) and \(u= u_r\). Otherwise, keep \({\bar{P}}\) unchanged and set \(u\,{:=}\, u_l\).

  4. 4.

    Return to step 1

Note that \(R(u_l) = L(u_r) -1\) so after step (3), Eq. 51 remains correct for the new value of v, regardless of whether the algorithm walks left or right.

Thus, after \(O(\log n)\) decision steps, this procedure reaches a leaf of the tree and this leaf must be \(x_v\). Since each step uses only O(1) time and the preceding parts used only \(O(\log n)\) time, the total procedure uses \(O(\log n)\) time.

\({\hbox {Lemma}~11 \, (4): \, \hbox {For} \, x \in [x_i,x_j], \, \hbox {calculate} \, {\bar{j}} = \max \{j' \le j\,:{\varTheta }_R([x,x_{j'}],x,s) \le \alpha \}.}\)

First use \(O(\log n)\) time to find v such that \(x_{v} \le x < x_{v+1}\). From Lemma 15,

$$\begin{aligned} {\varTheta }_R([x,x_{j'}],x,s) = {\varTheta }_R(P_{v j'} ,x_v,s) - \tau (x - x_{v}). \end{aligned}$$

Setting \(\alpha ' \,{:=}\, \alpha + \tau (x-x_{v})\), the problem is then equivalent to finding

$$\begin{aligned} \max \{j' \le j\,:{\varTheta }_R(P_{v j'},x_v,s) \le \alpha '\}. \end{aligned}$$

Now build MTD[vjs] in \(O(\log n)\) time. If \(R'[t] \le \alpha \) then \({\bar{j}} = j\) and the process finishes.

Otherwise, in \(O(\log n)\) time, find the largest index k such that \(R'[k] \le \alpha '\).

Next use Part 1 to check in \(O(\log n)\) time if \({\varTheta }_R\left( P_{v (R(u_k)+1)},x_{v},s \right) > \alpha '\).

If yes, then \({\bar{j}} = R(u_k)\). Otherwise \(x_{{\bar{j}}} \in u_k\) and can be found in \(O(\log n)\) time using essentially the same binary search procedure as in (3).

\({\hbox {Lemma}~11 \, (2): \, \hbox {Calculating} \, {\varTheta }^1(P_{i j}, s) \, \hbox {and associated} \, x^* \, \hbox {value}.}\)

Let

$$\begin{aligned} v \,{:=}\, \min \Bigl \{ r \,:\, i \le r \le j, \text{ and } {\varTheta }_L(P_{i j},x_v,s) \ge {\varTheta }_R(P_{i j} ,x_v,s) \Bigr \}. \end{aligned}$$

Then \( x_{v-1} \le x^* \le x_v\). If v were known we could use the techniques seen previously to calculate both \({\varTheta }_L(P_{i j},x_v,s)\) and \({\varTheta }_R(P_{i j},x_{v-1},s)\) in \(O(\log n)\) time and then use Lemma 15 to find \(x^*\) and \({\varTheta }^1(P_{i j}, s)\) in a further O(1) time.

Instead of directly finding v, we actually find the smallest \({\bar{v}}\) such that \({\varTheta }_L(P_{i j},x_{{\bar{v}}} ,s) \ge {\varTheta }_R(P_{i j} ,x_{{\bar{v}} +1} ,s)\). Then

$$\begin{aligned} {\varTheta }_L(P_{i j},x_{{\bar{v}} + 1} ,s) >{\varTheta }_L(P_{i j},x_{{\bar{v}}} ,s) \ge {\varTheta }_R(P_{i j} ,x_{{\bar{v}} +1} ,s) \end{aligned}$$

and

$$\begin{aligned} {\varTheta }_L(P_{i j},x_{{\bar{v}} -1} ,s) < {\varTheta }_R(P_{i j} ,x_{{\bar{v}}} ,s) \le {\varTheta }_R(P_{i j} ,x_{{\bar{v}} -1} ,s) \end{aligned}$$

so either \(v = {\bar{v}}\) or \(v = {\bar{v}}+1\). We can then find the value of v in \(O(\log n)\) time using 4 applications of part (1),

To find \({\bar{v}}\), first, in \(O(\log n)\) time build MTD[ijs]. In \(O(\log n)\) time, find the smallest k such that \(L[k] \ge R[k+1]\). Let \(u= u_k\). This implies that

$$\begin{aligned}&{\varTheta }_L(P_{i j}, x_{R(u)},s) \ge {\varTheta }_R(P_{i j}, x_{R(u)+1},s) \quad \text{ and } \\&{\varTheta }_L(P_{i j}, x_{L(u)-1},s) \ge {\varTheta }_R(P_{i j}, x_{L(u)},s) \end{aligned}$$

Thus \({\bar{v}} \in P(u_k)\). Set \(u \,{:=}\, u_k\), \(P_L \,{:=}\, P_{i (L(u)-1)}\) and \(P_R \,{:=}\, P_{(R(u)+1) j}\). \(P_L, P_R,u\) satisfy

$$\begin{aligned} (\mathrm{i})\, {\bar{v}} \in P(u),\quad (\mathrm{ii}) \, P_L = P_{i (L(u)-1)}, \quad (\mathrm{iii})\, P_R = P_{(R(u)+1) j} \end{aligned}$$
(52)
Fig. 14
figure 14

Illustration of the proof of Lemma 11 (2), trying to find leftmost \({\bar{v}}\) satisfying \({\varTheta }_L(P_{i j},x_{{\bar{v}}} ,s) \ge {\varTheta }_R(P_{i j} ,x_{{\bar{v}} +1} ,s)\). It is known that \(x_v \in P(u)\). Comparing \({\varTheta }_L(P_{i j},x_{R(u_l)} ,s)\) and \({\varTheta }_L(P_{i j},x_{L(u_r} ,s)\) permits determining whether \(x_{{\bar{v}}} \in P(u_l)\) or \(x_{{\bar{v}}} \in P(u_r)\)

We again do a simulated binary search for \({\bar{v}}\). To initialize, in \(O(\log n)\) time, find the left critical vertex of \(P_L\) and the right critical vertex of \(P_R\).

At each iterative step we will, in O(1) time, replace u by either \(u_l\) or \(u_r\) maintaining the correctness of all three invariants in Eq. 52. Since u starts at height \(O(\log n)\) this process only uses \(O(\log n)\) additional time (Fig. 14).

  1. 1.

    If u is a leaf stop and set \({\bar{v}} \,{:=}\, u\).

  2. 2.

    Set \({\bar{P}}_L \,{:=}\, P_{i R(u_l)}\) (the concatenation of \(P_L\) and \(P(u_l)\)) and \({\bar{P}}_R \,{:=}\, P_{L(u_r) j}\) (the concatenation of \(P(u_r)\) and \(P_R\)).

  3. 3.

    From MTD[ijs] find the left critical vertex of \(P(u_l)\) and right critical-vertex of \(P(u_r)\) for s in O(1) time. Use the known left critical vertex of \(P_L\) and right critical vertex of \(P_R\) and Lemma 24 to construct the left critical vertex of \({\bar{P}}_L\) and right critical vertex of \({\bar{P}}_R\) in O(1) time. Then calculate \({\varTheta }_L({\bar{P}}_L, x_{R(u_l)},s)\) and \({\varTheta }_R({\bar{P}}_R, x_{L(u_r)},s)\) in O(1) time.

  4. 4.

    If \({\varTheta }_L({\bar{P}}_L, x_{R(u_l)},s) \le {\varTheta }_R({\bar{P}}_R, x_{L(u_r)},s)\) set \(P_R \,{:=}\, {\bar{P}}_R\) and \(u \,{:=}\, u_l\). Otherwise set \(P_L \,{:=}\, {\bar{P}}_L\) and \(u \,{:=}\, u_r\).

  5. 5.

    Go to step 1

\(\square \)

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Arumugam, G.P., Augustine, J., Golin, M.J. et al. Minmax Regret k-Sink Location on a Dynamic Path Network with Uniform Capacities. Algorithmica 81, 3534–3585 (2019). https://doi.org/10.1007/s00453-019-00589-2

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00453-019-00589-2

Keywords

Navigation