The Traveling Firefighter Problem

Majid Farhadi∗ Alejandro Toriello Prasad Tetali† Georgia Tech Georgia Tech Georgia Tech [email protected] [email protected] [email protected]

Abstract optimized for a specific norm, particularly yielding a 5.65-approximation for the TFP on general metrics. We introduce the Lp Traveling Salesman Problem (Lp- TSP), given by an origin, a set of destinations, and We leave open several interesting directions to fur- underlying distances. The objective is to schedule a ther develop this line of research. destination visit sequence for a traveler of unit speed to minimize the Minkowski p-norm of the resulting vector 1 Introduction of visit/service times. For p = ∞ the problem becomes The Lp-TSP is a routing problem seeking to minimize a path variant of the TSP, and for p = 1 it defines the Lp norm of the vector of visit/service times to a set the Traveling Repairman Problem (TRP), both at the of customer locations. It generalizes and interpolates center of classical combinatorial optimization. between two well-studied problems, the path variant of

Lp-TSP can be formulated as a convex mixed- the TSP and the TRP, also known as the Minimum integer program and enables a smooth interpolation Latency Problem, which are the two extreme cases between path-TSP and TRP, corresponding to optimal in which one minimizes either the largest or the sum routes from the perspective of a server versus the of service times. By assuming the server’s speed is customers, respectively. The parameter p can affect constant, we use time and distance interchangeably in fairness or efficiency of the solution: The case p = 2, the remainder of the paper. which we term the Traveling Firefighter Problem (TFP), As one motivating example, the Lp-TSP for p = 2, models the scenario when the cost/damage due to a which we call the Traveling Firefighter Problem (TFP), delay in service is quadratic in time. abstracts a macro-scale optimal strategy for dispatching a firefighter to minimize the total damage due to fires We provide a polynomial-time reduction of L - p at various locations. Ride-sharing is another use-case of TSP (losing a factor of 1 + ε in performance) to our problem. For example, devising the return route of the segmented-TSP, a routing problem that defines a a school bus, should we optimize the fuel consumption constant O(1+ε−2) number of deadlines by which given (i.e. the driver’s time en route) or the average student numbers of vertices should be visited. Subsequently we waiting time? Is it fairer to further penalize larger derive polynomial-time approximation schemes for L - p waiting times, e.g. minimizing the sum of squares/cubes TSP in the Euclidean metric and the tree metric (for of the waiting times? Before formulating the problems which the problem is strongly NP-hard). under study we introduce some notation. We also study the all-norm-TSP, in which the Notation. [z] denotes the set {1, ··· , z} for any arXiv:2107.10454v1 [cs.DS] 22 Jul 2021 objective is to find a route that is (approximately) positive integer z. O˜(·) is equivalent to O(·), treating optimal with respect to the minimization of any norm ε > 0 as a constant. A metric over a set of nodes V is of the visit times. We improve the approximation a distance function d : V × V → that satisfies bound for this problem to 8, down from 16, and R≥0 symmetry, d(x, y) = d(y, x) ∀x, y ∈ V , identity, further prove an impossibility for an approximation d(x, x) = 0, and the triangle inequality, d(x, y) ≤ factor better than 1.78, even in line metrics. Finally, d(x, z) + d(z, y) ∀x, y, z ∈ V. we show the performance of our algorithm can be The inputs to the problem are the set of vertices V , including both the destinations and the server’s ∗Supported in part by aco.gatech.edu, triad.gatech.edu. starting location, s ∈ V , and the underlying metric Part of this work was conducted when authors visited Simons d(·, ·) over V , corresponding to distances (or times) Institute for the Theory of Computing. between vertex pairs. †Research supported in part by the NSF grant DMS-2055022. The author’s new affiliation is Department of Mathematical A feasible solution or route is a permutation σ th Sciences, Carnegie Mellon University, Pittsburgh. over V that starts at the origin; σi denotes the i vertex

1 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited to be visited, so we always have σ1 = s. F denotes the set of all feasible solutions. The ith smallest visit time, σ A S B C due to a solution σ ∈ F, is denoted Ti , i.e. ( (a) L2-TSP route σ 0 i = 1 Ti = Pi j=2 d(σj−1, σj) i ∈ {2, ··· , n}

σ A S B C The visit time for vertex v is denoted `v . Similarly, σ σ Pσi=v `s = 0 and `v = i=2 d(σi−1, σi) ∀v 6= s. (b) L1-TSP route Definition 1. (L -TSP) The input of the optimiza- p Figure 1: Different norms cause different routes. tion problem Lp-TSP is a set of destinations V , a start- ing vertex s ∈ V , and a metric d : V × V → R≥0. The objective is to find a feasible route, σ ∈ F, starting at s and visiting all v ∈ V , that minimizes the Minkowski the best solution for the firefighter: L∞-TSP minimizes σ the latest visit time for all fires, while the cost could be p-norm of the visit times, i.e. minσ∈F k` kp, where affected by all visit times; thus an aggregated measure 1 ! p could be a better objective. σ X σ p k` kp := |`v | . For example, consider the following simple dynam- v∈V ics for the spread of wildfires over uniform territory, ig- noring possible differences such as vegetation, weather When the problem/objective is clear from context, and wind. After every second, a flammable point of we denote an optimal route as OPT and the answer of territory is ignited if it is within a unit distance from our algorithm as ALG. the burning flames. Under these dynamics, the area of A Better Objective. One can verify that the land scorched by the fire is a quadratic function of the objective (norm) affects various aspects of the routing elapsed time. Therefore, the damage due to the delay th 2 problem, such as efficiency. Lp-TSP enables a smooth on the i visit can be better represented by ` and σi transition between two extreme objectives. For larger P 2 2 minimizing v `v = k`k2, or equivalently k`k2, is a bet- p’s the objective is strongly affected by dominating ter objective for this scenario compared to other norms, (larger) entries of the delay vector and minimizing k`kp particularly k`k1 or k`k∞. Motivated by this example, is more to the benefit of the server. In contrast, smaller we term L2-TSP as the Traveling Firefighter Problem p’s provide a further aggregated measure of the amount (TFP). of time that the customers have waited. This trade-off In an applied setting, this approach may require can also be interpreted from a fairness perspective, as some refinement but the basic idea still applies. Land increasing p discourages the longest waiting time from and weather asymmetries can be modeled by a mul- becoming too large. tiplicity of vertices: If a fire spreads twice as fast in Firefighter Example. We further elaborate on area, we can represent it by two vertices overlapping why p∈ / {1, ∞} can be a useful objective by considering in the metric. One could also generalize the objec- the routing of a firefighter.1 Consider a set of wildfires tive to a weighted sum of the squared delays and/or in dispersed locations, and suppose a skilled firefighter discretize large fires into smaller ones. Moreover, the extinguishes any fire the second they arrive at a loca- time required to extinguish a fire can be accounted for tion; the firefighter must choose the order in which to by adding a new edge, hanging from the original desti- visit and extinguish the fires. One possible strategy is nation at a distance proportional to the time required to choose a sequence in order to finish extinguishing all to contain that fire, and moving the destination to the fires as soon as possible, which corresponds to solving other endpoint of the new edge. the L∞-TSP (the path-TSP). However, this may not be The Argument versus The Objective. The set of feasible routes for all Lp-TSP problems is the same, 1Over the past decade, and for the first time on record, the while the objectives are different. For any p 6= q, annual number of acres burned in the United States exceeded there exist instances where the two optimal routes are 10 million; this occurred twice [Hoo18]. During 2018, wildfire different. As a simple example, depicted by Figure 1, + damages in California totalled $150 billion [WGZ 21]. In July consider four vertices S, A, B, and C over a line metric 2019, a record 2.4 million acres of the Amazon rainforest were torched [Bor19]. The optimal allocation, scheduling, and routing at locations 0, −1−ε, +1, and +2 respectively. Starting of firefighting resources may help to better address this global at S, the route SABC is optimal for L2-TSP with challenge. corresponding objective of k(0, 1 + ε, 3 + 2ε, 4 + 2ε)k2 '

2 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited (a) Path-TSP route (b) TFP route

Figure 2: Optimal path-TSP versus TFP routes for 10 U.S. locations; the areas of the discs at visit locations are proportional to the expected (quadratic) damage at each location, due to the delay along the route. Here, taking the TFP route (instead of the TSP) reduces total damage by 5%.

√ 26, in contrast to the optimal route for L1-TSP that for all norms. In this line, a natural question is whether is SBCA with the objective k(0, 1, 2, 5 + ε)k1 = 8 + ε. there exists a single route that is approximately optimal Consider the effect of a “wrong” norm on the concerning the minimization of any norm of the visit optimal route. Figure 2 demonstrates an example times, and whether we can efficiently find one. This can in which we consider 10 locations with simultaneous be viewed also as an online problem where the adversary wildfires in the United States.2 Dispatching a firefighter chooses the norm, e.g. Lp, and the objective is to provide from Atlanta, and traveling 100 times faster than the a competitive solution with respect to the optimal route. spread of fire, TFP would look quite different than L∞- TSP, i.e., path-TSP. In particular, a TFP optimal route Definition 2. (all-norm-TSP) Given s, V 3 s, d : reduces the total damage by 5% compared to that of V ×V → as before, the objective is to choose a route the path-TSP. R≥0 that minimizes the maximum possible ratio between a As another example, consider destinations on the x symmetric norm of the visit time vector of the output axis, with many fires located at +1 and a single fire at route σ and the optimal route for that norm, −1 + ε. Starting at x = 0, the optimal L∞-TSP route moves left first and then right, resulting in a solution k` k roughly three times as expensive as the optimal TFP min sup σ . σ∈F k·k minσ0∈F k`σ0 k route, in terms of the L2 objective. In fact, the relative performance of an L∞-TSP route for the L2 objective can be unbounded. For instance, consider the Euclidean Golovin et al. [GGKT08] introduced this problem as metric over the plane with n−2 fires located at complex the all-norm-TSP and gave an algorithm that outputs coded locations a route that is a 16-approximation with respect to any norm of the visit time vector. The concept of all-norm 2π· k i {e n : k ∈ {1, ··· , n − 2}}, minimization has been of interest in many applications, e.g., for routing, load balancing [KRT99], and machine 2π n−1−ε i and m distinct fires located at e n . Starting at scheduling [AERW04, BP03]. (1, 0) = e0i and moving at unit speed, for n → ∞ and m/n → ∞ the damage (squared delay) due to L∞- 1.1 Main Results & Proof Ideas. Optimizing the TSP route (by walking in the wrong direction around non-linear objective of L -TSP can be computationally 2 p the circle) converges to 4π , while for the optimal TFP challenging. The problem is already NP-hard even in solution it goes to zero. the linear case, p = 1, on a tree metric [Sit02], i.e. when All-norm-TSP. We observed that TSP may not the metric is pairwise distances over a graph on V that be a good solution for other Lp objectives. One may forms a tree. In contrast, TSP on trees is solvable, in consider whether a different Lp-TSP is hopefully good linear time. Archer and Williamson [AW03] showed that a 2Wildfires observed during the first week of Dec 2019, accord- (1 + ε)-approximate solution for TRP exists that is ing to satellite data [NAS]. a concatenation of O(log n · ε−1) TSP paths. This

3 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited can be generalized as the following Lemma, which en- theorem 1. [Lp-TSP ⇒ segmented-TSP] Let ε > 0 be ables a quasipolynomial time approximation scheme for a constant and A be an α-approximation algorithm for weighted trees. segmented-TSP for some k = O(1 + ε−2) of our choice. There is a (1 + ε) · α-approximation algorithm for L - Lemma 1.1. ([AW03]) L -TSP can be (1 + ε)- p p TSP that calls A (on the same network (V, s, d)) for a approximated by a concatenation of O(log n · ε−1) TSP strongly polynomial number of times. paths.

Proof. Without loss of generality we can assume inte- Theorem 1, proved in Section 2, along with a gral and polynomially bounded input distances, d(i, j) ∈ PTAS for segmented-TSP [Sit14] on tree metrics and {0}∪[O(n2/ε)] = {0}∪[O˜(n2)], as an appropriate quan- Euclidean metrics imply the following results. tization by rounding only adds a multiplicative error of 1 + O(ε/n2) to any edge and keeps any norm of a valid Corollary 1.1. There exist polynomial-time approxi- tour, within a factor (1 ± ε). mation schemes (PTAS) for Lp-TSP on weighted trees Now break the optimal route according to time and Euclidean plane metrics. spots 1, (1 + ε), ··· , (1 + ε)γ where γ = O(log n · ε−1) because O(n3 · ε−1) is a bound on the length of the Note that due to our reduction of Lp-TSP optimal route. Replacing each sub-route between two to segmented-TSP, any approximation results for consecutive time spots, with the shortest path TSP over segmented-TSP, on specific metrics, would follow for the same points does not increase any visit time beyond Lp-TSP, at the cost of an additional factor of (1 + ε) a factor 1+ε, and hence preserves any norm of the visit to the approximation bound. Our results can be gen- times by a factor of 1 + ε. eralized to the case of multiple travelers, starting from arbitrary locations, as discussed in Section 5. The above approach can only lead to a pseudo- For general metrics, a PTAS is unlikely, as the prob- polynomial time approximation algorithm, even for lem becomes Max-SNP-hard. On the other hand, the trees. Reducing the problem to many shortest paths constant factor approximability of L -TSP for general cannot lead to an efficient polynomial-time reduction, p metrics is immediate due to the 16-approximation of the because a concatenation of o(log n) path-TSP routes all-norm-TSP by Golovin et. al. [GGKT08]. In this line, cannot approximate L -TSP within a constant factor 1 we improve the approximation bound for all-norm-TSP [Sit14]. To further reduce the number of paths, we by a factor of 2. use the notion of segmented-TSP, introduced by Sitters [Sit14], to enable some dependence between consecutive theorem 2. [all-norm-TSP] There is a polynomial- deadlines. This problem requires a (sequence of mono- time algorithm to find a route that is 8-approximate with tonically non-decreasing) number of destinations to be respect to the minimization of any symmetric norm of visited by a number of deadlines, formulated as follows. the visit times (including Lp-TSP, TFP, and TRP). Definition 3. (segmented-TSP) Given V 3 s, d : Theorem 2 is proved in Section 3. Our algorithm V × V → R≥0 as before, in addition to integer numbers n1 ≤ n2 ≤ · · · ≤ nk ≤ |V | = n and fractional numbers builds on the partial covering idea, presented as Algo- + t1 ≤ t2 ≤ · · · ≤ tk as inputs, the segmented-TSP rithm 1, that was pioneered by Blum et al. [BCC 94] problem is a decision problem to verify whether a route for TRP, and was developed through subsequent studies exists that visits at least ni distinct vertices by time ti [GK98, CGRT03, GGKT08, BKL21]. for all i ∈ [k], starting at s. Algorithm 1 Routing via Partial Covering Approximation of segmented-TSP, i.e. a decision problem, can be defined as follows. 1: procedure Geometric-Covering(V, s, d) 2: Algorithm Parameters: b ∈ (0, ∞), c ∈ (1, ∞) Definition 4. An α-approximate solution to a 3: i ← 0 segmented-TSP instance, must visit the first ni vertices 4: while there remains destinations to visit do by the modified deadline α · ti, ∀i ∈ [k], if an answer to 5: . Conducting sub-tours i the original segmented-TSP exists. 6: Ci ← a maximal route of length ≤ b · c . 7: Travel through Ci (and return to the origin) We generalize a main result of Sitters [Sit14] that 8: i ← i + 1 showed TRP can be reduced to (a polynomially many 9: return an ordering σ of V according to their number of approximate) segmented-TSP problems with (first) visit time through the above loop. a constant number of deadlines.

4 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited The parameters b and c strongly affect the perfor- possible way, i.e., optimizing the time spent by the mance of the algorithm. For all-norm-TSP, we choose server/traveler. In contrast, the Traveling Repair- b = mini,j∈V d(i, j) and c = 2, as in [GGKT08]. The man Problem (TRP), a.k.a. Minimum Latency Prob- key difference of our algorithm is in line 6. Instead of an lem, the school bus driver problem [Wil94], hidden approximation algorithm for k-TSP, i.e. a route of min- treasure [BCC+94, KPY96, ALMS00], and the deliv- imum length that visits k-vertices, we utilize a milder eryman problem [Min89, FLM93, MDZL08], optimizes relaxation, which is a tree (instead of a route/stroll) the route purely from the perspective of clients, i.e., rooted at s, including k vertices, and of total length the total waiting time to be visited, and is another not larger than an optimal k-TSP. Such a good k-tree extensively studied combinatorial optimization prob- can be found in polynomial time using the primal-dual lem [ACP+86, PY93, BCC+94, GK98, CGRT03, AW03] method that solves a Lagrangian relaxation of k-TSP with a state-of-the-art approximation factor of ' 3.59 [CGRT03, ALW08, PS14]. for general metrics [CGRT03, PS14]. On the other hand, we provide a first impossibil- Containment of fires can be abstracted from various ity result for all-norm-TSP, notably beyond known in- perspectives. Hartnell [Har95] modeled a constant approximability bounds for specific L -TSP problems. p speed spread of fires through edges of a graph, along The following is proved in Section 3.2. which the firefighters also displace. Many objectives, theorem 3. There is no approximation algorithm for such as minimization of the number of burned vertices, all-norm-TSP with multiplicative factor better than or the required time to contain the fire(s) are studied 1.78, independent of P = NP or other complexity hy- in this model and the problem is an active area of potheses. research. See [FM09, KLL14, ABZ18, ABK20, DFH21] and references therein. The above result reaffirms the need for approxi- mation algorithms specifically designed for each norm. Generalizing the objective to Minkowski norm of Along this line, we present a randomized 5.65 approxi- the solution has allowed interpolating other classi- mation algorithm for the Traveling Firefighter Problem. cal problems, e.g., Lp [GGKT08, BBFT20] that further united the greedy algorithms for set-cover and the minimum-sum-set-cover [FLT04] theorem 4. There is a randomized, polynomial-time problems. Set cover is better approximable for p = 1 5.65-approximation algorithm for TFP on general met- than p = ∞ , while TSP (p = ∞) is currently better rics. approximated than TRP (p = 1). Nevertheless, this order is not expected to be reversed as TRP is intrin- Theorem 4 is proved in Section 4, for which we sically a harder problem. Moreover, in contrast to the adapt the ideas by Chaudhuri et. al. [CGRT03] and concordance among L set cover problems, for which optimize the parameter c in line 2 of Algorithm 1. p the same greedy algorithm gives best (possible) bounds Choosing b ∈ [1, c] at random, with a distribution for any p ∈ [1, ∞), state-of-the-art algorithms for TSP of uniform density for log(b), simplifies the analysis, and TRP are significantly different, and potentially far while one can efficiently de-randomize the algorithm by from the best possible. This is yet another motivation quantization of b. to study Lp-TSP, ultimately towards unified best algo- rithms for all underlying problems. 1.2 Literature Review. Traveling Salesman Prob- lem is a principal problem in computer science, combi- natorial optimization, and operations research, and its 1.3 Paper Organization. In Section 2 we pro- th first formulations date back as early as 19 century (c.f. vide a reduction from Lp-TSP to segmented-TSP and [ABCC06]). Since the celebrated 3/2-approximation al- subsequent approximation schemes for Euclidean and gorithm of Christofides-Serdyukov [Chr76, Ser78], for weighted-tree metrics. In Section 3, we present the its tour-variant on general metrics, TSP has been exten- 8-approximation for all-norm-TSP in general metrics, sively studied for half a century [Wol80, SW90, BP90, along with a first inapproximability bound. This Goe95, CV00, GLS05, BC11, SWVZ12, HNR19]. Very will also be a preliminary for optimized algorithm recently, Karlin, Klein, and Oveis Gharan [KKG20] for L2-TSP in Section 4, where we present a 5.65- showed TSP can be approximated strictly better than approximation for the Traveling Firefighter Problem on 3/2, while the problem remains NP-hard to approximate general metrics. We discuss generalizations to multiple within a factor of 123/122 [KLS15]. vehicle scenarios in Section 5 and conclude the paper The common ground in numerous variants of TSP with a set of interesting open problems to continue this is that a set of vertices are to be visited in the fastest line of research.

5 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited 2 Reducing Lp-TSP to Segmented TSP which is immediate having λi = cλi−1 ≥ 3λi−1. In this section, we provide our reduction from L -TSP p The modified tour OPT0 is approximately to polynomially many instances of segmented-TSP. Let Lemma 2.2. optimal in expectation, i.e., for some k ∈ O(1 + ε−2) us restate Theorem 1. h 0 i kT OPT kp ≤ (1 + ε)kT OPTkp . theorem 1. [Lp-TSP ⇒ segmented-TSP] Let ε > 0 be Ej p p a constant and A be an α-approximation algorithm for segmented-TSP for some k = O(1 + ε−2) of our choice. Proof. All vertices are visited (for the first time) in the same order, by OPT and OPT0 . Let the dth service time There is a (1 + ε) · α-approximation algorithm for Lp- TSP that calls A (on the same network (V, s, d)) for a by the optimal solution be strongly polynomial number of times. OPT δ δ+1 Td ∈ ((1 + ε) , (1 + ε) ] In particular, a corollary of the above Theorem for some integer δ ≥ 0 . (and the following Lemma) is a (1 + ε) approximation If this vertex is visited in the ith sub-tour of OPT0 , algorithm for any Lp-TSP on weighted-tree metrics - we can write where the problem becomes strongly NP-hard even for OPT0 OPT p = 1 - as well as the Euclidean plane. Td = Td + 3λi−1 . Lemma 2.1. ([Sit14]) Segmented TSP, for any con- We can bound this additional delay by stant number of segments M, can be solved in polyno- 0 0 T OPT − T OPT ≤ 3(1 + ε)δ−j mial time for weighted trees, and 1+ε approximated for d d unweighted Euclidean metric. where j0 has the same distribution as j . We can prove the desired by bounding the per- Corollary 1.1. There exist polynomial-time approxi- vertex ratio by mation schemes (PTAS) for Lp-TSP on weighted trees and Euclidean plane metrics. h OPT0 pi Ej0 (Td ) ≤ (1 + ε) In the rest of this section, we prove Theorem 1, OPT p (Td ) by providing a dynamic programming algorithm that P i ai ai approximates Lp-TSP using polynomially many calls to because P ≤ maxi where a1, ··· and b1, ··· are i bi bi (approximate) segmented-TSP. More precisely, we show positive real numbers. OPT0 OPT if there is an α-approximate solution for segmented- Considering p ≥ 1 and Td = Td + 3λi−1, TSP, the dynamic program guarantees an approxima- the left hand side of the target ratio is maximized for OPT δ tion factor of at most α · (1 + ε) for arbitrary constant Td = (1 + ε) , so it suffices to prove ε > 0 .  δ p 0 ((1 + ε) + 3λ ) The algorithm is presented in a few steps, each Ej i−1 δ p ≤ (1 + ε) . imposing no more than 1+O(ε) multiplicative error. To ((1 + ε) ) achieve exact 1+ε precision, one may run the algorithm We will have for a constant fraction of the target ε .  δ p j0 ((1 + ε) + 3λi−1) −2 E For some k as large as O(1 + ε ) we can ensure δ p def ((1 + ε) ) c = (1 + ε)k ≥ 3 . Let OPTλi denote the maximal h δ δ−j0 pi prefix of OPT route for L -TSP of length at most Ej0 ((1 + ε) + 3(1 + ε) ) p ≤ ((1 + ε)δ)p λ def= (1 + ε)−j · ci , ∀i ≥ 0 , i h −j0 pi = Ej0 (1 + 3(1 + ε) ) where j is a fixed random number, uniformly distributed h −j0 p pi over {0, ··· , k − 1}. = 1 + Ej0 (1 + 3(1 + ε) ) − 1 0 Let OPT be a tour made of sub-tours consisting k−1 λi 1 X 0 of traversing OPT and returning to the origin and ≤ 1 + (3p)p(1 + ε)−j k waiting until time 3λi before starting the next sub-tour. j0=0 To confirm the above is feasible, we need to show sub- (3p)p 1 tour i+1 , being allowed to begin at 3λ , does not leave ≤ 1 + · i k 1 − (1 + ε)−1 before the return of previous sub-tour, i.e., (3p)p 1 + ε OPTλi = 1 + · . 3λi−1 + 2kT k∞ ≤ λi + 2λi = 3λi k ε

6 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited To get the desired (from the last inequality) it stage can increase (any) norm of the delay vector kT k suffices to assume by a factor α so we have an α · (1 + ε) approximation, that was promised by Theorem 1. (3p)p(1 + ε) k ≥ . Finally it is worth to mention that the route (in- ε2 stead of the value) can be reconstructed using update (parent) information of D[·][·] and a constructive ap- proximate solver for Seg-TSP[·] and we can short-cut We can now complete the proof of Theorem 1, potential re-visits of vertices to have a valid Hamilto- similar to the main idea of Sitters [Sit14], presented as nian route. follows. Lemma 2.2 implies for some j ∈ [k], where k = 3 All-norm TSP −2 0 O(1 + ε ), there exists a near optimal routing, OPT , Since the introduction of a first constant approximation ˜ 2 that for each i ∈ [O(n )], visits new vertices only during for TRP by Blum et al. [BCC+94], partial covering [3λi−1, λi] , and returns to the origin and remains there through applying a geometric series of limits on the until length of the sub-tours has been a core in the design 3 ki 3λi = · (1 + ε) . of routing algorithms. In this section, we improve the (1 + ε)j 16-approximate/competitive solution for all-norm TSP We can search for such a path by reconstructing by a factor of 2. We further provide a first lower bound OPTλi for all i and upper bounding the consequent for this problem. OPT0 p kT kp using dynamic programming. Define D[i][d] as (an upper bound on) the contribu- 3.1 Approximation for General Metrics. The tion of visit times of vertices that are visited by OPTλi , idea is to iteratively cover more and more vertices OPT0 p by sub-tours of exponentially (geometrically) increasing to kT kp, further assuming the number of these ver- tices is d. length while trying to maximize the total number of k vertices that are visited (not necessarily for the first We can compute D[i][d] considering O(n ) cases time) in each iteration. Our algorithm uses the following of (m1, m2, ··· , mk) where mr denotes the number of milder relaxation of k-TSP, called a good k-tree, in place λi vertices that are visited by OPT during of line 6 in Algorithm 1. r−k−1 r−k (3λi−1 + λi · (1 + ε) , 3λi−1 + λi · (1 + ε) ] . Definition 5. A good k-tree is a tree of size k, includ- P ing s, and with a total edge-weight of no more than that Note that it is necessary to have r mr ≤ d and let 0 P of the optimal k-TSP (starting from s). d = d − r mr be the number of vertices visited by λi−1 OPT . We can write Lemma 3.1. ([CGRT03]) A good k-tree can be found in polynomial time. D[i][d] = min D[i − 1][d0]+ m1,··· ,mk Chaudhuri et. al. [CGRT03] proved the above us- 0 X r−k p Seg-TSPi(d , m[r]) · mr · (3λi−1 + λi · (1 + ε) ) , ing a primal-dual approach [Gar96, AK00] that allows r finding a feasible solution to the primal (integer) linear 0 program of the k-tree problem paired with a feasible where Seg-TSPi(d , m[r]) has value 1 if segmented-TSP is feasible for visiting at least dual solution to k-TSP, that by weak duality has no less of a cost. 0 0 0 d , d + m1, ··· , d + m1 + ··· + mr We are now ready to prove Theorem 2. vertices by deadlines theorem 2. [all-norm-TSP] There is a polynomial- time algorithm to find a route that is 8-approximate with −k λi−1, 3λi−1 + λi · (1 + ε) , ··· , 3λi−1 + λi respect to the minimization of any symmetric norm of the visit times (including Lp-TSP, TFP, and TRP). is feasible, and otherwise has value ∞. Note that we have an α approximate solver for Segmented-TSP, Proof. WLOG assume the nearest neighbor to s is at though for convenience we can alternatively assume the distance 1. For k = 1, 2, . . . , n find a good-k-tree. traveller goes at the speed of α instead of 1, to get a 1+ε Among these, name the largest tree (with respect to OPT 2 1/p i approximate solution to kT kp by (D[O˜(n )][n]) . number of vertices) of total length at most 2 as Gi for In the end, moving at unit speed (instead of α) at every i = 0, 1, 2,....

7 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited n+1 Let C be a (randomized) depth-first traversal of G 1+2n+b /(b−1)−n−1 i i route, is bn+1/(b−1)−n−1+2bn−1 . The minimum of these and let C be the concatenation of Ci’s for i = 0,.... The two ratios will be at least 1.67, achieved for n = 2100, final tour ALG will visit vertices in the order that they ε = 1e − 3. Constructing a numerical example with appear in C, which does not increase the first-visit time similar structure, depicted as Figure 3, we considered all for any vertex, due to triangle inequality of the metric, candidate optimal routes the measured approximation while short-cutting vertices that are being re-visited. ratios with respect to various norms. The min max Let over these ratios was 1.78, verifying nonexistence of OPT i i+1 Tk ∈ [2 , 2 ) . an approximate all-norm-TSP with better performance. For reproducibility we include this example in the This shows the shortest (length) k-path in G is no longer Appendix. than 2i+1 . So our good-k-tree is no longer than 2i+1 , hence Ci+1 has at least k distinct vertices, allowing us th The above example, is yet another motivation to to upper bound our k visit time by study and optimize routing algorithms specific to the i+1 i+1 appropriate objective/norm, as one solution cannot be ALG X X j i+3 good for all. Tk ≤ |Cj| ≤ 2 × 2 < 2 . j=0 j=0 4 Traveling firefighter in general metrics OPT i Together with Tk ≥ 2 and the above inequality In this section we build upon our geometric partial- we have ALG OPT covering algorithm with good k-trees to improve approx- Tk ≤ 8 × Tk . imation bound for a specific norm, i.e., the Traveling ALG OPT Firefighter Problem. We showed Tk ≤ 8 · Tk ∀i ∈ [n], i.e., T OPT is 8-submajorized by T ALG in terminology of We achieve the improved approximation bound [GGKT08, HLP88]. The result is that by randomization (of parameter b) and optimization

ALG OPT of our analysis w.r.t. approximation guarantee for a kT k ≤ 8 · kT k specific norm. Our approach can provide approximation guarantees (better than 8) for other L -TSP problems. w.r.t. any norm k · k. p We present main ideas in the rest of the section by One can verify the above algorithm performs proving the following result. asymptotically 3 times worse than the optimal TRP for i Theorem 4.1. Traveling Firefighter Problem for gen- the example with service points at {2 : i ∈ N} and starting at x = 0 . eral metrics can be 5.641-approximated in polynomial time. 3.2 Inapproximability. We conclude this section by Proof. We present a randomized approximation algo- providing a lower bound for all-norm TSP. We show rithm for general metrics, that can be efficiently de- even for line metrics, an α-approximate all-norm TSP randomized. cannot be guaranteed in general, for α < 1.78. Among the set of good k-trees, pre-computed for all i theorem 3. There is no approximation algorithm for k , let Gi be the largest one of total length at most b·c , all-norm-TSP with multiplicative factor better than and let Ci be a depth first traversal of that. Parameter 1.78, independent of P = NP or other complexity hy- c > 1 is a constant, to be optimized for performance potheses. guarantees, and [1, c] 3 b = cU Proof. We prove this for the special case of a line metric, i.e., when distances are absolute differences between where U is a random variable distributed uniformly points (vertices) on the real line. Our example has a over the interval [0, 1] . Finally, we reverse each Ci with similar structure as follows. Starting the walk from the probability half, and concatenate Ci’s (and shortcut origin at x = 0, there is a single destination at x = −1, repeated visits) to achieve the output ordering ALG .  i in addition to n destinations at x ∈ b − 1 : i ∈ [n] , Let the latency of the kth vertex visited by the for b = 1+ε. The approximation ratio of the route that optimal route be first visits points to the right of the origin with respect n 2b −1 OPT i to L∞-TSP objective is bn+1 , that converges to 2 when Tk = ac , n → ∞. Alternatively, the approximation ratio w.r.t. L1-TSP for the route that first goes left, i.e., optimal L∞ for some a ∈ [1, c] and integer i ≥ 0 .

8 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited 1 0 -1 -2 0 2 4 6 8 10 12

Figure 3: An example with no better than 1.78 all-norm TSP

It is easy to see that our (i + 1[a ≥ b])th sub-tour considering random variable b we have contains at least k vertices, hence, we can bound  ALG 2 E (Tk )  2  2i 2c  2 2[a≥b] ≤ E c · 2 b c i−1[a

9 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited vehicles at starting locations simultaneously at all 3λi, In the end, in addition to further improving the with negligible degrade of the optima. approximation bounds for the problems under study, we Finally, adapting the dynamic programming, we mention but a few of many interesting open problems can guarantee a multiplicative O(ε) loss given an (ap- and potential research directions regarding Lp-TSP and proximate) solver for multi-vehicle segmented TSP with all-norm-TSP. constant O(ε−2) deadlines, and the corresponding total number of destinations to be visited (by at least one • L1-TSP, i.e., TRP is harder than L∞-TSP, at least vehicle) until up to each. This is indeed fruitful as re- on trees. For what p is the Lp-TSP problem the sults on segmented-TSP also generalize to multi-vehicle hardest? variant, e.g., in tree-distance or Euclidean metric. • While TRP is strongly NP-hard on weighted trees, Our algorithms can be similarly adapted in the case its complexity is unknown for caterpillars [Sit02]. where release dates are added for the destinations. Similarly TFP and Lp-TSP seem challenging even Generalizing results in Sections 3-4 to multi-vehicle on such fundamental examples, that is yet to be variants of the problems is also possible. For this resolved. purpose, the k-stroll subproblem, for which we used the While we theoretically claimed p = 2 to be ideal for mild relaxation of good k-tree, can be generalized to • the Traveling Firefighter Problem, this assumption bottleneck-stroll of Post and Swamy [PS14]. This will should be given further justification / investigation be at the cost of further degrades to the approximation in practice. constants and proposes interesting open problems for study. For general metrics, current best approximation • Further applications of Lp-TSP can be inspected, guarantees for multi vehicle {single, multi} depot L1- e.g. in optimal containment of spread of pandemics TSP is {7.183, 8.497} [PS14]. [Har04, TCM20].

Discussion and Open Problems • We observe c = 2 to be optimal for the analysis We studied combinatorial optimization problems whose of all-norm-TSP algorithm. For TRP, the current objectives can be more appropriate, efficient, fair, and best result is due to a base c ≈ 3.59 for the adjustable, depending on enormous applications of op- geometric series, while c ≈ 2.54 is better for timal routing/scheduling. TFP, as we discussed. In this vein, one can inspect the best base for the geometric series used For TSP and TRP, the analyses of approximation by the partial covering algorithm, depending on algorithms as well as complexity results heavily rely on the objective, which naturally seems to be non- the linearity of the objective function. Hence, TFP increasing on p. and more generally Lp-TSP pose further challenging problems and require new techniques to be developed. • Stronger impossibility results for all-norm-TSP and even larger hardness of approximation bounds for We developed two approaches, towards high preci- this problem seem plausible. sion and scalable approximation of the answer. First, we provided a high precision polynomial time Acknowledgements reduction of L -TSP to segmented-TSP with only a p We would like to thank anonymous reviewers for their constant number of deadlines for visiting the required comments. First author would like to thank Joseph number of destinations. Our reduction enables approx- Bakhtiar for discussions, and Jai Moondra for a careful imation schemes for L -TSP on Euclidean as well as p reading of the paper, and their helpful comments. weighted tree metrics; this is yet another motivation to further study the segmented-TSP problem. References The other approach relied mainly on the fact that the objective is a norm of the delay vector. In this line, we developed an algorithm for all-norm-TSP, on general [ABCC06] David L Applegate, Robert E Bixby, Vasek metrics, of approximation factor 8. We also provided a Chvatal, and William J Cook, The traveling salesman first inapproximability result for all-norm-TSP. problem: a computational study, Princeton university press, 2006. Last but not least, we showed how the performance [ABK20] Gideon Amir, Rangel Baldasso, and Gady Kozma, of the latter algorithm can be optimized for a specific The firefighter problem on polynomial and intermedi- norm, particularly approximating Traveling Firefighter ate growth groups, Discrete Mathematics 343 (2020), Problem within a factor 5.65. no. 11, 112077.

10 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited [ABZ18] David Adjiashvili, Andrea Baggio, and Rico Zen- [CGRT03] Kamalika Chaudhuri, Brighten Godfrey, Satish klusen, Firefighting on trees beyond integrality gaps, Rao, and Kunal Talwar, Paths, trees, and minimum la- ACM Transactions on Algorithms (TALG) 15 (2018), tency tours, 44th Annual IEEE Symposium on Founda- no. 2, 1–33. tions of Computer Science, 2003. Proceedings., IEEE, [ACP+86] Foto Afrati, Stavros Cosmadakis, Christos H 2003, pp. 36–45. Papadimitriou, George Papageorgiou, and Nadia Pa- [Chr76] Nicos Christofides, Worst-case analysis of a new pakostantinou, The complexity of the travelling repair- heuristic for the Travelling Salesman Problem, Tech. man problem, RAIRO-Theoretical Informatics and Ap- Report RR-388, February 1976. plications 20 (1986), no. 1, 79–87. [CV00] Robert Carr and Santosh Vempala, Towards a 4/3 [AERW04] Yossi Azar, Leah Epstein, Yossi Richter, and approximation for the asymmetric traveling salesman Gerhard J Woeginger, All-norm approximation algo- problem, 116–125. rithms, Journal of Algorithms 52 (2004), no. 2, 120– [DFH21] Arye Deutch, Ohad Noy Feldheim, and Rani 133. Hod, Multi-layered planar firefighting, arXiv preprint [AK00] Sanjeev Arora and George Karakostas, A 2+ ap- arXiv:2105.03759 (2021). proximation algorithm for the k-MST problem, Pro- [FLM93] Matteo Fischetti, Gilbert Laporte, and Silvano ceedings of the 11th Annual ACM-SIAM Symposium Martello, The delivery man problem and cumulative on Discrete Algorithms, 2000, pp. 754–759. matroids, Operations Research 41 (1993), no. 6, 1055– [ALMS00] Giorgio Ausiello, Stefano Leonardi, and Alberto 1064. Marchetti-Spaccamela, On salesmen, repairmen, spi- [FLT04] Uriel Feige, L´aszl´o Lov´asz, and Prasad Tetali, ders, and other traveling agents, Italian Conference on Approximating min sum set cover, Algorithmica 40 Algorithms and Complexity, Springer, 2000, pp. 1–16. (2004), no. 4, 219–234. [ALW08] Aaron Archer, Asaf Levin, and David P [FM09] Stephen Finbow and Gary MacGillivray, The fire- Williamson, A faster, better approximation algorithm fighter problem: a survey of results, directions and for the minimum latency problem, SIAM Journal on questions., Australas. J Comb. 43 (2009), 57–78. Computing 37 (2008), no. 5, 1472–1498. [Gar96] Naveen Garg, A 3-approximation for the minimum [AW03] Aaron Archer and David P Williamson, Faster tree spanning k vertices, Proceedings of 37th Confer- approximation algorithms for the minimum latency ence on Foundations of Computer Science, IEEE, 1996, problem, Proceedings of the fourteenth annual ACM- pp. 302–309. SIAM symposium on Discrete algorithms, Society for [GGKT08] Daniel Golovin, Anupam Gupta, Amit Kumar, Industrial and Applied Mathematics, 2003, pp. 88–96. and Kanat Tangwongsan, All-norms and all-l p-norms [BBFT20] Nikhil Bansal, Jatin Batra, Majid Farhadi, and approximation algorithms, IARCS Annual Conference Prasad Tetali, Improved approximations for min sum on Foundations of Software Technology and Theo- and generalized min sum set cover, arXiv retical Computer Science, Schloss Dagstuhl-Leibniz- preprint arXiv:2007.09172 (2020). Zentrum f¨urInformatik, 2008. [BC11] Sylvia Boyd and Robert Carr, Finding low cost TSP [GK98] Michel Goemans and Jon Kleinberg, An improved and 2-matching solutions using certain half-integer approximation ratio for the minimum latency problem, subtour vertices, Discrete Optimization 8 (2011), no. 4, Mathematical Programming 82 (1998), no. 1-2, 111– 525–539. 124. [BCC+94] Avrim Blum, Prasad Chalasani, Don Copper- [GLS05] David Gamarnik, Moshe Lewenstein, and Maxim smith, Bill Pulleyblank, Prabhakar Raghavan, and Sviridenko, An improved upper bound for the TSP Madhu Sudan, On the minimum latency problem, Pro- in cubic 3-edge-connected graphs, Operations Research ceedings of the twenty-sixth annual ACM symposium Letters 33 (2005), no. 5, 467–474. on Theory of computing, pages 163–171. ACM (1994). [Goe95] Michel X Goemans, Worst-case comparison of valid [BKL21] Marcin Bienkowski, Artur Kraska, and Hsiang- inequalities for the TSP, Mathematical Programming Hsuan Liu, Traveling repairperson, unrelated machines, 69 (1995), no. 1-3, 335–349. and other stories about average completion times, arXiv [Har95] Bert Hartnell, Firefighter! an application of domi- preprint arXiv:2102.06904 (2021). nation, the 24th Manitoba Conference on Combinato- [Bor19] Alejandra Borunda, See how much of the Amazon rial Mathematics and Computing, University of Mini- forest is burning, how it compares to other years, toba, Winnipeg, Cadada, 1995, 1995. National Geographic (2019). [Har04] Stephen G Hartke, Attempting to narrow the inte- [BP90] Sylvia C Boyd and William R Pulleyblank, Optimiz- grality gap for the firefighter problem on trees., Discrete ing over the subtour polytope of the travelling salesman Methods in Epidemiology, 2004, pp. 225–231. problem, Mathematical programming 49 (1990), no. 1- [HLP88] GH Hardy, JE Littlewood, and G Polya, Inequali- 3, 163–187. ties cambridge univ, Press, Cambridge (1988). [BP03] Nikhil Bansal and Kirk Pruhs, Server scheduling in [HNR19] Arash Haddadan, Alantha Newman, and R Ravi, the lp norm: a rising tide lifts all boat, Proceedings of Shorter tours and longer detours: uniform covers and the thirty-fifth annual ACM symposium on Theory of a bit beyond, Mathematical Programming (2019), 1–29. computing, 2003, pp. 242–250. [Hoo18] K Hoover, Wildfire statistics congressional research

11 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited service, 2018. 35 (1990), no. 6, 281–285. [KKG20] Anna R Karlin, Nathan Klein, and Shayan Oveis [SWVZ12] Frans Schalekamp, David P Williamson, and Gharan, A (slightly) improved approximation algo- Anke Van Zuylen, A proof of the Boyd-Carr conjec- rithm for metric TSP, arXiv preprint arXiv:2007.01409 ture, Proceedings of the twenty-third annual ACM- (2020). SIAM symposium on Discrete Algorithms, SIAM, [KLL14] Rolf Klein, Christos Levcopoulos, and Andrzej 2012, pp. 1477–1486. Lingas, Approximation algorithms for the geometric [TCM20] Guy Tennenholtz, Constantine Caramanis, and firefighter and budget fence problems, Latin American Shie Mannor, Sequential vaccination for containing Symposium on Theoretical Informatics, Springer, 2014, epidemics, medRxiv (2020). pp. 261–272. [WGZ+21] Daoping Wang, Dabo Guan, Shupeng Zhu, [KLS15] Marek Karpinski, Michael Lampis, and Richard Michael Mac Kinnon, Guannan Geng, Qiang Zhang, Schmied, New inapproximability bounds for tsp, Jour- Heran Zheng, Tianyang Lei, Shuai Shao, Peng Gong, nal of Computer and System Sciences 81 (2015), no. 8, et al., Economic footprint of california wildfires in 1665–1677. 2018, Nature Sustainability 4 (2021), no. 3, 252–260. [KP20] Miroslav Kulich and Libor Preucil, Multi-robot [Wil94] Todd Gerald Will, Extremal results and algorithms search for a stationary object placed in a known en- for degree sequences of graphs. vironment. [Wol80] Laurence A Wolsey, Heuristic analysis, linear pro- [KPY96] Elias Koutsoupias, , and gramming and branch and bound, Combinatorial Opti- Mihalis Yannakakis, Searching a fixed graph, Interna- mization II, Springer, 1980, pp. 121–134. tional Colloquium on Automata, Languages, and Pro- gramming, Springer, 1996, pp. 280–289. [KRT99] Jon Kleinberg, Yuval Rabani, and Eva´ Tardos, Fairness in routing and load balancing, 40th Annual Symposium on Foundations of Computer Science (Cat. No. 99CB37039), IEEE, 1999, pp. 568–578. [MDZL08] Isabel M´endez-D´ıaz, Paula Zabala, and Abilio Lucena, A new formulation for the traveling deliv- eryman problem, Discrete applied mathematics 156 (2008), no. 17, 3223–3237. [Min89] Edward Minieka, The delivery man problem on a tree network, Annals of Operations Research 18 (1989), no. 1, 261–266. [NAS] Fire information for resource management system, NASA, https://firms.modaps.eosdis.nasa.gov. [PS14] Ian Post and Chaitanya Swamy, Linear programming-based approximation algorithms for multi-vehicle minimum latency problems, Proceedings of the Twenty-Sixth Annual ACM-SIAM Symposium on Discrete Algorithms, SIAM, 2014, pp. 512–531. [PY93] Christos H Papadimitriou and Mihalis Yannakakis, The traveling salesman problem with distances one and two, Mathematics of Operations Research 18 (1993), no. 1, 1–11. [Ser78] AI Serdyukov, O nekotorykh ekstremal’nykh obkho- dakh v grafakh, Upravlyayemyye sistemy 17 (1978), 76– 79. [Sit02] Ren´eSitters, The minimum latency problem is NP- hard for weighted trees, International conference on integer programming and combinatorial optimization, Springer, 2002, pp. 230–239. [Sit14] , Polynomial time approximation schemes for the traveling repairman and other minimum la- tency problems., Proceedings of the twenty-fifth annual ACM-SIAM symposium on Discrete algorithms, SIAM, 2014, pp. 604–616. [SW90] David B Shmoys and David P Williamson, Analyz- ing the held-karp TSP bound: A monotonicity prop- erty with application, Information Processing Letters

12 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited A From Section 3 Our example for 1.78 inapproximability of all-norm- TSP has similar structure as the exponential sequence presented in Section 3, yet is computationally tuned and verified. This suggests the best (worst) example can have a different structure. Follows the locations of the destinations over the line to be visited by a traveler, starting at x = 200. All points are over the x-axis. Figure 4 depicts performance of candidate routes with respect to different norms.

V = {0, 200, 202, 204, 206, 208, 210, 212, 214, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 228, 230, 232, 234, 236, 238, 240, 242, 244, 246, 250, 254, 258, 262, 266, 270, 274, 278, 282, 286, 289, 292, 295, 298, 301, 304, 307, 310, 313, 316, 316, 316, 316, 316, 316, 316, 316, 316, 316, 316, 322, 328, 334, 340, 346, 352, 358, 364, 370, 376, 382, 388, 394, 400, 406, 412, 418, 424, 430, 436, 446, 456, 466, 476, 486, 496, 506, 516, 526, 536, 540, 544, 548, 552, 556, 560, 564, 568, 572, 576, 595, 614, 633, 652, 671, 690, 709, 728, 747, 766, 775, 784, 793, 802, 811, 820, 829, 838, 847, 856, 888, 920, 952, 984, 1016, 1048, 1080, 1112, 1144, 1176, 1199, 1222, 1245, 1268, 1291, 1314, 1337, 1360, Figure 4: Nonexistence of a 1.78-approximate all-norm- 1383, 1406, 1519, 1632, 1745, 1858, TSP 1971, 2084, 2197, 2310, 2423, 2536}

13 Copyright © 2021 by SIAM Unauthorized reproduction of this article is prohibited