Solution Approaches for the Elementary Shortest Path Problem

Size: px
Start display at page:

Download "Solution Approaches for the Elementary Shortest Path Problem"

Transcription

1 Solution Approaches for the Elementary Shortest Path Problem Luigi Di Puglia Pugliese Francesca Guerriero Department of Electronics, Computer Science and Systems, University of Calabria, Rende, Italy. Abstract In this paper, the elementary single-source all-destinations shortest path problem is considered. Given a directed graph, containing negative cost cycles, the aim is to find the paths with minimum cost from a source node to each other node, that do not contain repeated nodes. Three different solution strategies are proposed to solve the problem under investigation and their theoretical properties are investigated. The first is a dynamic programming approach, the second method is based on the solution of the k shortest paths problem, where k is considered as a variable. The last solution strategy is an enumerative approach based on a tree structure, constructed with a cycle elimination rule. Theoretical aspects related to the innovative proposed strategies to solve the problem at hand are investigated. The practical behaviour of the defined algorithms is also evaluated by considering a meaningful number of test problems. Keywords: shortest path; negative cost cycles; dynamic programming; k shortest paths; enumerative method. 1 Introduction The Shortest Path Problem (SPP) is one of the most studied problems in network optimization [16, 23, 28]. The problem comes up in practice and arises as subproblem in many network optimization algorithms. Solution approaches for the SPP have been studied for a long time (e.g., [7, 22, 23, 29, 46, 47]). More recently, some improvements and computational study have been presented by Ahuja et al. [1], Gabow and Tarjan [31] and Goldberg [35]. The reader is referred to the works of Cherkassky et al. [11] and Gallo and Pallottino [32] for detailed surveys. In its basic formulation, the objective is to determine the minimum cost path through a network from a given source node to a destination node. Several polynomial time solution approaches have been developed in the scientific literature to Corresponding Author, ldipuglia@deis.unical.it 1

2 address the SPP in the case there are no negative cost cycles (e.g., see [17, 23, 43]). On a network with negative arc costs, but with non-negative cost cycles, the best currently known time bound O(nm) is achieved by the Bellman-Ford-Moore algorithm [7, 29, 46], where n and m denote the number of nodes and arcs in the network, respectively. If the arc costs are non-negative, implementations of Dijkstra s algorithm [23] achieve better bounds. In particular, an implementation presented by Fredman and Tarjan [30] runs in O(m + n log n) time. A trivial extension of the SPP is to find the shortest path tree rooted at a source node, by considering as destination all the nodes of the network (SPT P). This problem can be easily solved by the label-correcting methods used to address the SPP (e.g., see [11, 32]). An interesting extension of the SPP is the problem to find the first k shortest paths (kspp). A set of k shortest paths have to be determined for each node by considering the first, the second and so on up to the k-th shortest path. This problem arises in many real-life applications, e.g., in telecommunication and transportation fields. In these contexts, alternative solutions should be available when the current best is forbidden for various reasons, e.g., link interruption in telecommunication network or street closed in transportation plant. Many solution approaches have been defined to solve the kspp. The scientific literature takes into account two variants of the kspp: 1) the pure kspp and 2) the so-called loopless kspp. In the first case, a node can appear more than once in the solution paths, whereas, in the latter we are interested in finding the first k shortest paths such that they contain a node only once. A wide number of papers address the kspp (e.g., see [4, 12, 24, 25, 38, 45, 51]). Solution approaches for the loopless ksp P have been defined by Martins et al. [44] and Yen [62]. Dreyfus [24] and Yen [62] cite several additional papers on this subject going back as far as When negative cost cycles are present in the network, the SPP is not well defined, that is, a finite optimal solution does not exist. In this case, the problem is to check whether a simple cycle, whose arc costs sum up to a negative number, is present in the network. This problem is known as Negative Cost Cycle Detection Problem (N CCDP). It is worth noting that the N CCDP is polynomial. Several procedures have been defined for the N CCDP, see, e.g.,[15, 54]. The Bellman-Ford algorithm is one of the earliest and to date asymptotically fastest algorithm for the N CCDP [11, 34]. Recently, Subramani [53] has introduced a new approach for the N CCDP; the proposed solution strategy is based on exploiting the connections between the N CCDP and the problem of checking whether a system of difference constraints is feasible. It is important to point out that the scientific literature provides several works dealing with algorithms that list up all cycles in directed as well as undirected graphs in which arc costs are not considered [10, 48, 56, 57, 59, 60]. Yamada and Kinoshita [61] addressed the problem of finding all cycles in a directed graph with negative costs and they proposed a recursive algorithm. It is worth observing that all the 2

3 cited references do not solve the SPP in presence of negative cost cycles, rather they enumerate all the cycles in the network or check whether a negative cost cycle exists. The problem to find a shortest path in a network with negative cost cycles is still a very challenging problem. To the best of our knowledge, no solution approaches have been defined up to now to solve the elementary shortest path problem (ESPP). It is, of course, well known that computing shortest paths in the presence of negative cost cycles is a strongly N P-hard problem [33]. When constraints on the consumption of resource along the path are introduced, the problem is referred to as the Resource Constrained Elementary Shortest Path Problem (RCESPP). This problem has attracted the attention of many researchers in the last years. Starting with the seminal work of Beasley and Christofides [6], a variety of solution approaches have been developed to solve to optimality the RCESPP (see, e.g., [19, 39, 40]). The single-source single-destination version of the ESPP can be viewed as a particular instance of the RCESPP, where the resource consumption constraints are removed. In addition, it is possible to relax the elementarity constraints from the ESPP introducing a new resource that takes into account the number of visited nodes. Thus, the relaxed ESPP can be modeled as a RCSPP. This issue is explained in more detail in the following. In this paper, we deal with the more general case in which an elementary shortest path must be found for all nodes. In other words, we address the single-source all-destinations version of the ESPP. In order to solve to optimality the singlesource all-destinations ESPP, we apply the concepts proposed by Boland et al. [9] and Righini and Salani [49]. Beside the solution approach derived from the optimal strategies developed for the RCESPP, innovative methods are also presented. In particular, we have designed a dynamic k shortest paths algorithm, in which k is a variable and may assume an arbitrary value for each node of the network. An enumerative solution approach is also presented. In addition, an in depth analysis is carried out to evaluate the theoretical complexity of the proposed solution approaches and an extensive computational phase is conducted in order to asses the efficiency of the defined optimal strategies. In the context of the RCSPP, the single-source all-destinations SPP is applied in order to perform network reduction procedure based on the cost, to determine lower bounds on the optimal cost and to solve the dual Lagrangean problem when the resource constraints are relaxed in a Lagrangean objective function. When the RCESPP is considered, the aforementioned elements cannot be applied because of the negative cost cycles. Thus, the solution approaches for the ESPP proposed in this paper, can be used to determine lower bounds on the optimal cost and to solve the dual Lagrangean problem associated with the RCESPP. This information can be used to improve the performance of the state-of-the-art methods. In addition, it is worth observing that the ESPP can be used to model the 3

4 currency conversion problem [50]. When the nodes represent currencies and the arcs the transactions with costs equal to exchange rate, the problem is to find the maximum product path, that is, the best exchange sequence. The problem can be easily transformed in the SPP and, since the graph can contain negative cost cycles, it can be viewed as an instance of the ESPP. The proposed methods are able to solve also the single-source single-destination ESPP. However, it is worth observing that well-tailored solution approaches for the single-source single-destination version can be devised but this topic is out of the scope of this work. The paper is organized as follows. In Section 2 we give some notations and definitions used in the paper. The proposed solution approaches, along with their theoretical analysis are presented in Section 3. Section 4 is devoted to the discussion of the computational results. Section 5 presents our conclusions. The appendix reports the results of the computational experiments. 2 Notations and Definitions Let G = (N, A) be a directed graph where N is the set of n nodes, whereas A denotes the set of m N N arcs. N contains also the source node s. A cost c ij is associated with each arc (i, j) A. A cycle on node i is defined as an ordered sequence of nodes C i = (i, j 1,..., j g, i), where j i j k for all pairs i, k {1,..., g} such that i k. It can also be viewed as a sequence of g + 1 arcs {(i, j 1 ),..., (j g 1, j g ), (j g, i)}. It is worth observing, as shown by Allender [2], that n!(ρ 1)! ρ!(n ρ)!. the maximum number of cycles in a complete graph is equal to C = n ρ=1 Let π si be a path from node s to node i. It is a sequence of nodes π si = (s = i 1,..., i l = i), l 2 and a corresponding sequence of l 1 arcs such that the h-th arc in the sequence is (i h, i h+1 ) A for h = 1,..., l 1. Thus, each path contains at least one arc. Let M π (j) be the multiplicity of node j in path π, that is M π (j) = {v : 0 v π, i v = j}. The path π is said to be an elementary path if M π (j) = 1, for all j π. A cycle C i on node i N is said to be a negative cost cycle (N CC) if c(c i ) = (h,k) C i c hk < 0. Let π sj be an elementary path from node s to node j such that i π sj for some i N \ {s}. Let π si = π sj {(j, i)} be the path obtained by extending path π sj to node i through arc (j, i). Since i π sj, a cycle C i = π ij {j, i} is created. Proposition 1. Given a path π sj and its sub-path π si, C i is a N CC if c(π si ) > c(π sj ) + c ji. Proof. The cost of the path π sj can be viewed as the sum of the cost of the sub-path π si and the sub-path from i to j, that is c(π sj ) = c(π si ) + c(π ij ). It follows that c(π si ) > c(π sj ) + c ji c(π si ) > c(π si ) + c(π ij ) + c ji 0 > c(π ij ) + c ji = c(c i ). This concludes the proof. 4

5 Since the directed graph G is not assumed to be acyclic and the arc costs are not constrained in sign, there may be N CCs in G. The ESPP, from the source s to all other nodes, consists in finding the paths π si, i N \ {s} such that c(π si ) is minimized and M πsi (j) = 1, j π si. It is well known that the Bellman s optimality principle is not verified for this problem, indeed sub-paths of the optimal path for some node cannot be optimal. In what follows, we formalize this property. Let us assume that π su, u N, u s, represents the path with minimum cost and no repeated nodes in a graph with N CCs. The following consideration can be formulated. Observation 1. The optimal path π su from node s to node u is composed by subpaths π si from node s to each other node i π su that are not guaranteed to be optimal for node i. Proof. We prove the result by contradiction. Let us suppose that a sub-path πsj = πsi π ij is part of the optimal solution π su, and, for the purpose of contradiction, we assume that πsi is the optimal path from s to i. It follows that c(π sj ) = c(π si )+c(π ij ). Let us suppose that another path π sj : i π sj exists to reach node j. Since π sj is different from πsj, we have that c( π sj) c(πsj ). Let us suppose that a path π ji exists. If the path π sj is extended to node i through path π ji, then we have that c( π si ) = c( π sj ) + c( π ji ). We assume that πij π ji = C i is a N CC. Since we assume that πsi is the optimal path from node s to node i, it follows that c( π si ) c(πsi ). This means that c( π sj) + c( π ji ) c(πsj ) c(π ij ), thus c( π sj ) c(πsj ) c(c i). Since c(c i ) < 0, for a sufficiently low cost c( π sj ), that is, for c( π sj ) < c(πsj ) c(c i), the relation c( π sj ) c(πsj ) c(c i) is not verified, contradicting the optimality hypothesis on path πsi. In order to better explain Observation 1, let us consider the directed graph of Figure 1. Figure 1: Directed graph example. The optimal path from node s to node 3 is πs3 = {s, 1, 2, 3} of cost 0. The cost of sub-path πs1 is equal to 1 but c(π s1 ) is not the least cost from s to 1. Indeed, the path π s1 = {s, 2, 1} is the optimal path of cost 0 to node 1. 5

6 Observation 1 suggests that it should be necessary to keep more than one path for some node. It follows that the optimal solution of the ESPP is not guaranteed to be a spanning tree. Under this respect, it is possible to devise a modified label-correcting scheme for the SPP in order to obtain valid upper bounds for the ESPP. Let y i be the label that stores the value of the dual price for each node i N and L denote the list of nodes, that have to be processed. We indicate with pred R N the vector of predecessors, that is pred i = j is the predecessor of node i in the path π si. A set F S(i) of successor nodes is associated with each node i N, that is defined as follows: F S(i) = {j : (i, j) A}. A general scheme of a label-correcting method to obtain upper bounds for the ESPP is reported in Algorithm 1. Algorithm 1 : Label Correcting Scheme 1: Step 1 (Initialization phase) 2: y s = 0; y i = +, i N \ {s}; pred i = i, i N ; L = {s}. 3: 4: Step 2 (Node selection) 5: Select a node i from the list L and remove it from L. 6: 7: Step 3 (Label extension) 8: for all j F S(i) do 9: if y j > y i + c ij then 10: if j π si then 11: y j = y i + c ij ; 12: pred j = i; 13: add node j to L if it does not already belong to it. 14: end if 15: end if 16: end for 17: 18: Step 4 (Termination check) 19: if L = then 20: STOP. y i, i N, is an upper bound on the optimal cost of the path from node s to node i. 21: else 22: Go to Step 2. 23: end if Algorithm 1 is a classical label-correcting method where the elementarity constraints are taken into account. The combination of conditions introduced in line 10 and line 19 ensures that the built paths do not contain repeated nodes and that the algorithm terminates in a finite number of iterations. Since the procedure is based on Bellman s optimality conditions, at the end of Algorithm 1, the label y i, i N, represents an upper bound on the elementary shortest path cost from node s to node i. 6

7 3 Proposed Solution Approaches The solution approaches proposed in this paper are based on the idea to compute for each node the minimum set of paths such that the elementary shortest path is found for all nodes. Three strategies have been developed. The first one can be viewed as an application of the methods proposed to solve the RCESPP. A multi-dimensional labeling procedure is devised and the dimension of the label is updated dynamically. The second strategy is based on a labeling approach to solve the kspp. In our case, k is considered as a variable that can take different values for each node. In the last solution approach, a tree structure is defined and an enumerative procedure is devised in order to exploit the defined tree. It is worth observing that, while the first solution approach can be viewed as an extension of the algorithms for solving the RCESPP well-tailored to the ESPP, the last two strategies are proposed for the first time to solve instances of the SPP in presence of N CCs. 3.1 Dynamic Multi-Dimensional Labeling Approach The approaches, presented in this section, use the concept of critical node introduced by Kohl [42]. In particular, a node i is said to be critical if there exists a cycle C i that is a N CC. A binary variable is introduced for each critical node in order to keep track of whether the node is visited. This binary variable can be viewed as a resource associated with node i, bounded to be less than or equal to one (see [6]). Let S = {i 1, i 2,..., i S }, be the set of critical nodes and r[p], p = 1,..., S be the binary variable associated with node i p S. We denote as y i = (c(π si ), r i ) the label that contains the cost and the resource consumptions vector of the path π si from node s to node i. The resource consumptions vector r i has the following form: r i [p] = 1, p : j p π si and r i [p] = 0, p : j p π si. In other words, the vector r i keeps trace of the nodes j S that are visited along the path π si. Definition 1. Let yi 1 = (c(πsi 1 ), r1 i ) and y2 i = (c(πsi 2 ), r2 i ) be two labels associated with node i. The label yi 2 is dominated by the label yi 1 if c(πsi 1 ) c(π2 si ), r1 i [p] r2 i [p] for p = 1,..., S and at least one inequality is strict. Definition 2. A label y i = (c(π si ), r i ) associated with node i is said to be efficient or Pareto-optimal if there does not exist a label ȳ i that dominates it. Definition 3. A label y i = (c(π si ), r i ) associated with node i is said to be feasible if r i [p] 1, p = 1,..., S. A set D(i), containing all the efficient labels, is associated with each node i N. The procedure defined by Desrochers [18] can be applied to solve the ESPP. It is worth observing that the Desrochers algorithm is an extension of Algorithm 1, 7

8 without line 10, to the constrained case. In Algorithm 2, we report the steps of the label-correcting method extended to the constrained case. Algorithm 2 : Label-Correcting Scheme for the ESPP 1: Step 1 (Initialization phase) 2: y 1 s = (0, 0); D(s) = {y 1 s}; D(j) =, j N \ {s}; L = {s}. 3: 4: Step 2 (Node selection) 5: Select a node i from the list L and remove it from L. 6: 7: Step 3 (Label extention) 8: for all y ξ i D(i) do 9: for all j F S(i), j s do 10: Set: c( π sj ) = c(π ξ si ) + c ij; r j [p] = r ξ i [p], p = 1,..., S ; 11: if j S then 12: r j [ˆp] + 1 with iˆp = j. 13: end if 14: if r i [p] 1, p = 1,..., S then 15: if ȳ j = (c( π sj ), r j ) is not dominated by any label in D(j) then 16: D(j) = D(j) {ȳ j }; 17: remove from D(j) all the labels that are dominated by ȳ j ; 18: add node j to L if it does not already belong to it. 19: end if 20: end if 21: end for 22: end for 23: 24: Step 4 (Termination check) 25: if L = then 26: STOP. The label y i = minȳ D(i) {c( π) si } is associated with the optimal elementary path from s to i, i N. 27: else 28: Go to Step 2. 29: end if It is possible to devise also a label-setting algorithm by slightly modifying Algorithm 2. Indeed, the set L stores all the efficient and feasible labels and it is initialized by the label y s. At Step 2, from the list L, the lexicographically minimal label is selected. This label is used to generate feasible and efficient labels to each successor node. This procedure is the same as the one proposed by Boland et al. [9] called general label-setting algorithm. The main drawback of the procedure is that the set S of critical nodes must be known in advance. The enumerative procedure of Yamada and Kinoshita [61] could be executed to determine the entire set of negative cost cycles. The nodes belonging to each negative cost cycle can be used to initialize set S and the Algorithm 2 can be performed. However, this strategy could be inefficient, since only a sub-set of all nodes belonging to all negative cost cycles need to be considered. In addition, the procedure defined by Yamada and Kinoshita [61] is not polynomial. If the set S is not known in advance, then we can relax the elementarity constraints and introduce a surrogate resource γ that counts the number of nodes in the path to get the relaxed ESPP (ESPP R ). This idea was proposed by Feillet et al. 8

9 [26] and applied by Righini and Salani [49] for solving the RCESPP. The ESPP R is a RCSPP where the resource γ is bounded to be less than or equal to the number of nodes n. The optimal solution to the ESPP R may not be an elementary path. The nodes that appear more than once in the optimal paths π si, i N \ {s}, are marked as critical nodes and the RCSPP is run again until an elementary path is found. The approach to augment the set S is the same of that proposed by Boland et al. [9] and by Righini and Salani [49]. The difference is that in the latters only one path has to be found. For more detail, the reader is referred to [20]. Very recently, in [37] the authors proposed a new state-space reduction technique combined with the strategies defined in [49]. This strategy cannot be extended to the single-source all-destinations version of the ESPP. The solution approaches presented in [49, 9] can be modified in order to define well-tailored procedure for the ESPP. In particular, starting from S =, the labelsetting algorithm is executed. The search is stopped when a N CC, named C i, is detected. The set S is incremented by adding node i and the label-setting algorithm is run again. The procedure terminates when no N CC is detected. This approach is similar to the general state-space augmenting algorithm proposed in [9] with the difference that the label-setting algorithm is stopped when a negative cost cycle is detected. In this case, the surrogate resource γ is not necessary. In Algorithm 3, we describe the steps of the aforementioned procedure, whereas the truncated label-setting algorithm is depicted in Algorithm 4 Algorithm 3 : Dynamic Multi-Dimensional Labeling Approach 1: Step 1 (Initialization phase) 2: Set: ζ = 0; S ζ = 3: 4: Step 2 (Run the truncated label-setting algorithm) 5: Run Algorithm 4 with critical node restricted to S ζ and get C. 6: 7: Step 3 (Cycle detection) 8: if C then 9: S ζ+1 = S ζ {j}, j : M(j) C = 2; 10: ζ + +; 11: Go to Step 2. 12: else 13: STOP. 14: end if The defined solution approach is quite different from those proposed by Boland et al. [9] and Righini and Salani [49]. For this reason and for the sake of completeness, in the next Section we prove its correctness Correctness of the Dynamic Multi-Dimensional Labeling Approach In this section, we prove the correctness of the proposed solution approach. In particular, at the end of Algorithm 3, the label y i with the smallest cost among 9

10 Algorithm 4 : Truncated label-setting algorithm with S ζ 1: Step 1 (Initialization phase) 2: Set: y 1 s = (0, 0); D(s) = {y 1 s}; D(j) =, j N \ {s}; L = {y 1 s}; C =. 3: 4: Step 2 (Label selection) 5: Select the lexicografically minimal label y ξ i from the list L and remove it from L. 6: 7: Step 3 (Label extension) 8: for all j F S(i), j s do 9: Set: c( π sj ) = c(π ξ si ) + c ij; r j [p] = r ξ i [p], p = 1,..., Sζ ; 10: if j S ζ then 11: r j [ˆp] + 1 with iˆp = j. 12: end if 13: if j S ζ and j π ξ si and c( π sj) < c(π ξ sj ) then 14: STOP. A N CC C is detected. 15: Return C. 16: else 17: if r i [p] 1, p = 1,..., S ζ then 18: if ȳ j = (c( π sj ), r j ) is not dominated by any label in D(j) then 19: D(j) = D(j) {ȳ j }; L = L {ȳ j }; 20: remove from D(j) and L all the labels that are dominated by ȳ j. 21: end if 22: end if 23: end if 24: end for 25: 26: Step 4 (Termination check) 27: if L = then 28: STOP. The label y i = min {ȳ D(i)} {c( π) si } is associated with the optimal elementary path from s to i, i N. 29: Return C. 30: else 31: Go to Step 2. 32: end if those belonging to the set D(i) is associated with the least cost elementary path from s to i. Proposition 2. At the end of Algorithm 4, two situations can occur: 1. a N CC is detected, that is, the stop conditions of line 13 are verified; 2. if the procedure is stopped by condition of line 27, then all the efficient and feasible paths from s to each other node i N \ {s} are determined. (a) At the end of each iteration, the following conditions hold: i. D(s) = {ys} 1 = {(0, 0)}; ii. j N, if D(j) [i.e.: D(j) = {yj 1, y2 j,..., yl j }] and j s, then y ξ j, ξ = 1,..., l is a label related to a feasible path from node s to node j and D(j) is an efficient set. 10

11 (b) Upon termination of the algorithm, if D(j), j N and j s, then D(j) contains the labels of all efficient and feasible paths from node s to node j. Proof. Let us consider case 1. The conditions of line 13 derive from Proposition 1. Thus, if they are verified, then a N CC is detected. If case 1 does not occur, then all N CCs have been detected and the algorithm terminates when the list L is found empty, that is, case 2. In what follows, we prove case 2. Let us consider case 2a. Condition 2(a)i holds because, initially, D(s) = {ys} 1 = {(0, 0)} and, by the rules of the algorithm, D(s) cannot change. We prove condition 2(a)ii by induction on the iteration count. Indeed, initially, condition 2(a)ii holds, since node s is the only node for which the set D(s) is nonempty. Suppose that 2(a)ii holds for some node j at the beginning of some iteration. Let yi δ be the label removed from L. If i = s (which only occurs at the first iteration) and δ = 1, then at the end of this iteration, we have D(j) = yj 1 for all successor nodes j of s such that the corresponding path π sj is feasible, D(j) = for all other nodes j s, j / F S(i). Thus, the set of labels has the required property. If i s, then yi δ is the label of some feasible path πδ si starting from s and ending to i that is not dominated by the other paths in D(i), by the induction hypothesis. If the set D(j) changes, for some node j, such that j F S(i), as a result of the iteration, a new feasible label ȳ j = (c( π sj ), r j ) is obtained for node j. The created label is related to the feasible path π sj consisting of path πsi δ followed by the arc (i, j). Finally, note that, by the rules of the algorithm, the newly created label is added to D(j) only if it is an efficient label. This completes the induction proof of 2(a)ii. Let now consider condition 2b. Using part 2(a)ii, we have that, at each iteration, j N such that D(j), D(j) is an efficient set. Thus, the property mentioned is also satisfied when the algorithm terminates. In addition, the way in which the candidate list L is updated and the termination condition (i.e., the algorithm terminates when there are no more labels left to be scanned) guarantee that all the labels with the potential to determine a new label for at least one node are scanned during the execution of the algorithm. Proposition 3. (Correctness of Algorithm 3). At the end of Algorithm 3, the label y i with the smallest cost among those belonging to the set D(i) is associated with the least cost elementary path from s to i, i N. Proof. From Proposition 2, it follows that all the efficient and feasible labels y i, i N, are determined. Since the set D(i) is an efficient set, the path 11

12 π si = arg min {y D(i)} {c(π si )} has the cost as low as possible among all the feasible paths from s to i, that is π si is the optimal solution i N Complexity Analysis As far as the complexity analysis of the proposed dynamic multi-dimensional labeling approach for the ESPP is concerned, let D be the set of efficient and feasible labels with the highest cardinality. The complexity of Algorithm 3 is O(n 2 n τ=1 τ22τ ), in the worst case. This result is formally stated in the following lemma. Lemma 1. In the worst case, the complexity of Algorithm 3 is O(4 n n 3 ). Proof. Let D be the maximum number of labels at a node. The operations executed in lines 9-23 of Algorithm 4 are S D, that is, the test of dominance. Since the F S can contain at most n 1 elements, the total number of operations executed in lines 8-24 is n S D. Since the for-loop of line 8 is invoked n D times, that is an upper bound on the total number of generated labels, thus Algorithm 4 takes O(n 2 S D 2 ) operations. In the worst case, the number of efficient labels stored at each node is equal to 2 S. It follows that Algorithm 4 takes O(n 2 S 4 S ) operations. Starting from S =, the set of critical nodes is incremented by one at each iteration. In the worst case, set S contains all nodes. In other words, the operations executed by Algorithm 3 are n n n 2 n 4 n = 4 9 n2 [4 n (3n 1) + 1]. Consequently, the complexity of Algorithm 3 is O(4 n n 3 ), in the worst case. In order to better explain how Algorithm 3 works, let us consider the example of Figure 2. In Table 1, we report set S, the labels at the last iteration of Algorithm 4, the last selected label and the detected cycle C. The labels reported in Table 1 have the following form: < π(y) >. The superscript reported next to the labels indicates that the related label is dominated. Figure 2: Toy example. At the first iteration (see column 1 st iteration of Table 1), the label < s, 2, 5, 4( 8) > is selected. When we try to extend the label to node 2 a N CC is detected. Indeed, path π s2 = {s, 2, 5, 4} {2} has a cost equal to 5 that is less than the cost of path π s2 = {s, 2} associated with label < s, 2( 4) >. The dummy resource is introduced to node 2. At the 2 nd iteration, the N CC {1, 2, 3, 1} is detected and node 1 is inserted 12

13 1 st iteration 2 nd iteration 3 rd iteration S {2} {2, 1} s < s(0) > < s(0, 0) > < s(0, 0, 0) > 1 < s, 1(2) > < s, 1(2, 0) > < s, 1(2, 0, 1) > < s, 2, 1( 1, 1) > < s, 2, 1( 1, 1, 1) > 2 < s, 2( 4) > < s, 2( 4, 1) > D < s, 2( 4, 1, 0) > < s, 1, 2( 5, 1) > < s, 1, 2( 5, 1, 1) > 3 < s, 2, 3( 2) > < s, 2, 3( 2, 1) > D < s, 2, 3( 2, 1, 0) > < s, 1, 2, 3( 3, 1) > < s, 1, 2, 3( 3, 1, 1) > 4 < s, 2, 5, 4( 8) > < s, 2, 3, 1, 4(4, 1) > D < s, 2, 3, 1, 4(4, 1, 1) > D < s, 2, 5, 4( 8, 1) > D < s, 2, 5, 4( 8, 1, 0) > < s, 1, 4(7, 0) > < s, 1, 4(7, 0, 1) > < s, 1, 2, 5, 4( 9, 1) > < s, 1, 2, 5, 4( 9, 1, 1) > 5 < s, 2, 5( 6) > < s, 2, 5( 6, 1) > < s, 2, 5( 6, 1, 0) > < s, 1, 2, 5( 7, 1) > < s, 1, 2, 5( 7, 1, 1) > 6 < s, 2, 5, 6( 4) > < s, 2, 5, 6( 4, 1) > D < s, 2, 5, 6( 4, 1, 0) > D < s, 2, 5, 4, 6( 5, 1) > D < s, 2, 5, 4, 6( 5, 1, 0) > < s, 1, 2, 5, 4, 6( 6, 1) > < s, 1, 2, 5, 4, 6( 6, 1, 1) > < s, 1, 2, 5, 6( 5, 1, 1) > D < s, 1, 4, 6(10, 0, 1) > last extracted label < s, 2, 5, 4( 8) > < s, 1, 2, 3( 3, 1) > < s, 1, 4(7, 0, 1) > C {2, 5, 4, 2} {1, 2, 3, 1} Table 1: Labels associated with each node at the end of the corresponding iteration of Algorithm 4. in the set S. The introduction of the resource at node 2 and to node 1 avoids the generation of N CCs and the optimal solution is found at the 3 rd iteration. 3.2 Labeling Approach based on the k Shortest Paths Problem In this Section we describe a labeling approach in which the first k paths are determined for each node i N. The aim of the procedure is to determine the smallest set of paths for each node i. Under this respect, k is a variable and it can take different values for each node. The main idea is to start with k = 1 for each node, whenever a N CC is detected, k is incremented for a specific node and the labeling algorithm is run again. When no N CC is detected, from the set of paths associated with each node, the optimal solution is chosen. It is worth observing that when the kspp is solved, the paths are ranked by nondecreasing cost. In our context, it is necessary to store equivalent paths. This is necessary because paths with the same cost can have a different structure, that is, they can contain different nodes. Let K i be the number of best paths from node s to node i. The set Π i contains the K i paths ordered by nondecreasing cost, that is c(πsi k ) c(πk+1 si ), k = 1,..., K i 1 and if c(πsi k ) = c(πk+1 si ), then πsi k πk+1 si. In other words, Π i [k] = πsi k is the k-th shortest path from node s to node i. Definition 4. Set Π i, i N is said to be path-elementary, if each path π k si Π i, k = 1,..., K i does not contain repeated nodes. A vector y i R K i is associated with each node i that stores the costs of the paths belonging to the set Π i, that is, y i [k] represents the cost of path πsi k Π i. 13

14 Algorithm 5 : Truncated labeling algorithm for dynamic kspp 1: Step 1 (Initialization phase) 2: Set: y s[1] = 0; y i [k] = +, k = 1,..., K i, i N \ {s}; π 1 ss = {s}, Π s = {π 1 ss}; Π i =, i N \ {s}; L = {s}; C =. 3: 4: Step 2 (Node selection) 5: Select a node i from L and delete it from L. 6: 7: Step 3 (Label extension) 8: for all j F S(i), j s do 9: if y k i +, k {1,..., K i} AND k : j π k si AND k : j π k si, y i [ k] + c ij < y j [1] then 10: STOP. A cycle C = π k si {(i, j)} is detected. 11: Return C. 12: else 13: for all k = 1,..., K i : y i [k] +, j π k si do 14: for all ξ = 1,..., K j do 15: if y i [k] + c ij < y j [ξ] OR (y i [k] + c ij = y j [ξ] AND π k si {(i, j)} = πξ sj ) then 16: y j [δ + 1] = y j [δ], δ = ξ,..., K j ; 17: π δ+1 sj = π δ sj, δ = ξ,..., K j; 18: y j [ξ] = y i [k] + c ij ; 19: π ξ sj = πk si {j}; 20: add node j to L if it does not already belong to it. 21: BREAK 22: end if 23: end for 24: end for 25: end if 26: end for 27: 28: Step 4 (termination check) 29: if L = then 30: STOP. y i [1] is the cost of the optimal elementary path π 1 si. 31: Return C. 32: else 33: Go to Step 2. 34: end if Every time a N CC C is detected, the number of paths that have to be found for each node i C is increased, that is, K i = K i + 1, i C, and the labeling algorithm is executed again. When no N CC is detected, y i [1] is the cost of the optimal elementary shortest path from node s to node i N. The proposed solution approach iteratively solves the kspp for a fixed value of K i, i N. The steps of the labeling procedure are depicted in Algorithm 5. In the proposed strategy, Algorithm 5 is iteratively run after that K i, i N, is coherently updated. The dynamic labeling solution strategy is reported in Algorithm Correctness of the Dynamic Labeling Approach In this section, we prove the correctness of the proposed solution approach. In particular, at the end of Algorithm 5, πsi 1 is the least cost elementary path from s 14

15 Algorithm 6 : Dynamic Labeling Approach 1: Step 1 (Initialization phase) 2: Set: ζ = 0; K s = 1; K ζ i = 1 i N \ {s}. 3: 4: Step 2 (Run the truncated labeling algorithm) 5: Run Algorithm 5 with K ζ i, i N and get C. 6: 7: Step 3 (Cycle detection) 8: if C then 9: K ζ+1 i + 1, i C, K ζ+1 i = K ζ i, i N \ C; 10: ζ + +; 11: Go to Step 2. 12: else 13: STOP. 14: end if to i. Proposition 4. At the end of Algorithm 5 we have that: 1. a N CC is detected, that is, conditions of line 9 are verified; 2. if condition of line 29 is verified, then all the first K i elementary paths are determined for each node i N, that is, sets Π i, i N, are path-elementary. (a) At the end of each iteration, the following conditions hold: i. y s [1] = 0; ii. i N \ {s}, if y i [k] +, then πsi k is an elementary path. (b) Upon termination of the algorithm, Π i, i N, is path-elementary. Proof. Let us consider case 1: The first part of conditions in line 9, that is, yi k +, k {1,..., K i }, checks whether all the K i paths to node i are determined. The second part derives from Proposition 1, thus if it is verified for some k, a N CC is found and the algorithm terminates. It follows that the presence of a N CC is verified only if the entire set of paths from node s to the considered node i are determined. If case 1 does not occur, then all N CCs have been detected and the algorithm terminates when the list L is found empty, that is, case 2. Case 2: Let us consider case 2a. Condition 2(a)i holds because, initially, y s [1] = 0 and, by the rules of the algorithm, y s [1] cannot change. We prove condition 2(a)ii by induction on the iteration count. Indeed, initially, condition 2(a)ii holds, since node s is the only node for which the cost is not equal to +. Suppose that 2(a)ii holds for some node j at the beginning of some iteration. Let i be the node removed from L. If i = s (which only occurs at the first iteration), then at the end of this iteration, we have y j [1] + for all successor nodes j of s and the corresponding path 15

16 π sj = {(s, j)} is elementary, y j [k] = +, k 1 and y j [k] = + for all other nodes j s, j / F S(i). Thus, the set of paths has the required property. If i s, then y i [k] is the cost of the k-th path πsi k starting from s and ending to i that does not contain repeated nodes, by the induction hypothesis. If y j [k] changes, for some node j F S(i) and k, then a new path is obtained for node j. The created path πsj k consists of path πk si followed by the arc (i, j). Finally, note that, by the rules of the algorithm, the newly created path is elementary because j πsi k. This completes the induction proof of 2(a)ii. Let now consider condition 2b. Using part 2(a)ii, we have that, at each iteration, πsj k, j N such that y j[k] + is an elementary path. Thus, the property mentioned is also satisfied when the algorithm terminates. In addition, the way in which the candidate list L is updated and the termination condition (i.e., the algorithm terminates when there are no more nodes left to be scanned) guarantee that all the nodes with the potential to determine a new path for at least one node are scanned during the execution of the algorithm. Proposition 5. (Correctness of Algorithm 6). At the end of Algorithm 6, πsi 1 is the optimal path from node s to node i, i N. Proof. The algorithm terminates when no cycle is detected. From Proposition 4, we know that if no cycles are detected, then Algorithm 5 provides a path-elementary set Π i, i N. Since the paths are ordered in nondecreasing order of the cost, the first path of each set represents the least cost path. In addition, being Π i pathelementary, πsi 1 is the optimal path Complexity Analysis The complexity of Algorithm 6 is derived in the following lemma. Lemma 2. In the worst case, the complexity of the proposed solution approach is O(n 9 C7 ). Proof. Let K be the highest number of paths that have to be found. The operations executed in lines are 2K + 3. Since the forloops of line 13 and 14 take K 2, the number of iterations in lines is 2K 3 + 3K 2. The F S contains at most n 1 elements. The for-loop of line 8 is invoked nk times. Consequently, Algorithm 5 takes O(n 2 (2K 4 + 3K 3 )). Since each node can be part of each cycle, the iterations executed by Algorithm 6 are n C in the worst case. This means that the proposed approach executes n 2 ( )+n 2 ( )+...+n 2 (2 n C 4 +3 n C 3 ) = 2 15 (n C) 6 (6n C + 15) (n C) 4 (n C + 1) (n C) 3 (10(n C) 2 1) operations, thus the complexity of Algorithm 6 is O(n 9 C7 ). 16

17 In Table 2, we report the paths and the related cost (< πsi k (y i[k]) >) at the end of each iteration of Algorithm 6 when solving the ESPP on the network of Figure 2. At the 1 st iteration, node 3 is selected. Since all the conditions of line 9 are verified, Algorithm 5 terminates and the cycle {1, 2, 3, 1} is returned. The value of K i, i = 1, 2, 3 is incremented of one and Algorithm 5 is executed again. Node 4 is selected (see 2 nd iteration). When path πs4 1 = {s, 1, 2, 5, 4} is extended to node 2, conditions of line 9 are satisfied, thus the N CC {2, 5, 4, 2} is detected and Algorithm 5 is stopped. The number of paths that need to be found for nodes 2, 5 and 4 is increased. After other three iterations, see 3 rd, 4 th and 5 th iteration of Table 2, condition of line 29 is verified. Since C =, Algorithm 6 terminates and y i [1], i N, is the optimal cost. 17

18 18 1 st iteration 2 nd iteration 3 rd iteration 4 th iteration 5 th iteration K i y i K i y i K i y i K i y i K i y i s 1 < s(0) > 1 < s(0) > 1 < s(0) > 1 < s(0) > 1 < s(0) > 1 1 < s, 1(2) > 2 < s, 2, 3, 1( 1) > 2 < s, 2, 3, 1( 1) > 2 < s, 2, 3, 1( 1) > 2 < s, 2, 3, 1( 1) > < s, 1(2) > < s, 1(2) > < s, 1(2) > < s, 1(2) > 2 1 < s, 1, 2( 5) > 2 < s, 1, 2( 5) > 3 < s, 1, 2( 5) > 4 < s, 1, 2( 5) > 5 < s, 1, 2( 5) > < s, 2( 4) > < s, 2( 4) > < s, 2( 4) > < s, 2( 4) > < s, 1, 4, 2(10) > < s, 1, 4, 2(10) > < s, 1, 4, 2(10) > < s, 1, 2, 3( 3) > 2 < s, 1, 2, 3( 3) > 2 < s, 1, 2, 3( 3) > 2 < s, 1, 2, 3( 3) > 2 < s, 1, 2, 3( 3) > < s, 2, 3( 2) > < s, 2, 3( 2) > < s, 2, 3( 2) > < s, 2, 3( 2) > 4 1 < s, 1, 4(7) > 1 < s, 1, 2, 5, 4( 9) > 2 < s, 1, 2, 5, 4( 9) > 3 < s, 1, 2, 5, 4( 9) > 4 < s, 1, 2, 5, 4( 9) > < s, 2, 5, 4( 8) > < s, 2, 5, 4( 8) > < s, 2, 5, 4( 8) > < s, 2, 3, 1, 4(4) > < s, 2, 3, 1, 4(4) > < s, 1, 4(7) > 5 1 < s, 1, 2, 5( 7) > 1 < s, 1, 2, 5( 7) > 2 < s, 1, 2, 5( 7) > 3 < s, 1, 2, 5( 7) > 4 < s, 1, 2, 5( 7) > < s, 2, 5( 6) > < s, 2, 5( 6) > < s, 2, 5( 6) > + < s, 1, 4, 2, 5(8) > < s, 1, 2, 5, 4, 6( 6) > 1 < s, 1, 2, 5, 4, 6( 6) > 1 < s, 1, 2, 5, 4, 6( 6) > 1 < s, 1, 2, 5, 4, 6( 6) > last extracted node C {1, 2, 3, 1} {2, 5, 4, 2} {2, 5, 4, 2} {2, 5, 4, 2} Table 2: Paths and costs that are found for each node at the end of Algorithm 5.

19 3.3 Enumerative Strategy The proposed approach looks for the optimal solution through a tree structure. Each node is associated with a sub-graph of G excluding the root node that represents the graph G. The nodes at a certain level are associated with sub-graphs in which at least one N CC is removed. Given a father node, all child nodes are associated with sub-graphs in which the same N CCs are removed. Figure 3 shows the structure of the aforementioned tree. Figure 3: The Figure represents the tree structure of a graph with two negative cost cycles, that is < u, v, u > and < j, u, v, j >. Each node is associated with a graph. The root node is the graph G(N, A). Under each node is reported the detected cycle, whereas, the set of arcs is reported over each node. From both graphs G 1 and G 2 the cycle < u, v, u > is removed. Both cycles < u, v, u > and < j, u, v, j > are removed from graphs G 3, G 4 and G 5. In what follows we formalize the search process in the tree. Let G(N, A) be a graph associated with a generic node of the tree. The truncated labeling approach, that is, Algorithm 5 with K i = 1, i N, is run on G(N, A). If a N CC C i is detected, then δ = C i 1 sub-graphs are generated starting from G(N, A) by removing the δ-th arc of C i. In other words, the graph G δ (N, A δ ), δ = 1,..., C i 1 are generated where A δ = A \ {(u δ, v δ )}, with (u δ, v δ ) C i. Since at least one arc of the detected N CC C i is removed, the related sub-graph does not contain this cycle. When the truncated labeling algorithm is run on this sub-graph, if a N CC C i, for some node i N is detected, we are sure that C i C i. This means that at a certain level σ of the tree exactly σ N CCs have been detected. Consequently, in all the sub-graphs at level σ, at least σ N CCs are removed (the same arc can be part of many N CCs). 19

20 3.3.1 Algorithm Let y ζ R N be the vector that stores the best solutions for each node i N, determined so far, and y R N be the vector of the optimal solutions for each node i N. The value ζ is the iterations counter. At the last iteration ζ, y ζ = y, that is y i is the cost of the optimal path from node s to node i. Let y i (G) be the cost of the path from node s to node i obtained applying the truncated labeling algorithm on graph G. If a N CC C j is detected when the truncated labeling algorithm is executed on G, then we have that y i (G) is a valid upper bound for all nodes i N, where N = {u N : v π su, v C j }. This means that y i (G), i N can be used to initialize the cost of node i for the sub-graph G δ. In other words, y i (G δ ) = y i (G), i N. In addition, if y i (G) < y ζ i for some i N, then y ζ i = y i(g). Let L be the list containing the nodes of the tree that have to be processed. The steps of the proposed enumerative approach are reported in Algorithm 7. Algorithm 7 : Enumerative Algorithm 1: Step 1 (Initialization phase) 2: Set: ζ = 0; y ζ [s] = 0; y ζ [i] = +, i N \ {s}; L 0 = {G}, G = (N, A); y G [s] = 0; y G [i] = +, i N. 3: 4: Step 2 (Selection phase) 5: Select a graph Ḡ = (N, Ā) from Lζ and remove it from L ζ. 6: 7: Step 3 (Search process) 8: Apply the truncated labeling algorithm to Ḡ. 9: if a N CC C j is detected then 10: Generate δ = C j 1 sub-graphs G δ = (N, Ā {(u δ, v δ )}) and add them to L ζ ; 11: set: y G δ [i] = y Ḡ [i], i N. 12: if y Ḡ [i] < yζ [i] for some i N then 13: y ζ [i] = y Ḡ [i]. 14: end if 15: y ζ+1 = y ζ ; 16: L ζ+1 = L ζ ; 17: ζ + +; 18: go to Step 4. 19: else 20: if y Ḡ [i] < yζ [i] for some i N then 21: y ζ [i] = y Ḡ [i]. 22: end if 23: y ζ+1 = y ζ ; 24: L ζ+1 = L ζ ; 25: ζ + +; 26: go to Step 4 27: end if 28: 29: Step 4 (Termination check) 30: if L ζ = then 31: STOP. y ζ 1 [i] is the cost of the optimal path from node s to node i. 32: else 33: Go to Step 2. 34: end if 20

21 3.3.2 Correctness of the Enumerative Algorithm The correctness of the method follows from the search procedure. As mentioned above, the nodes represent sub-graphs for which the detected cycle in the father graph is excluded. Each sub-graph is defined by removing at most one arc of the detected cycle. In the sub-graphs of the last level all the cycles are removed, thus for each node i we have a path for each sub-graph that is an elementary path. The path with the smallest cost among those obtained in the sub-graphs is the optimal one Complexity Analysis Let M be the maximum cardinality among those of the N CCs in the graph, that is M = n. We know that the maximum number of N CCs in the graph is C. In addition, for each level σ of the tree exactly σ N CCs have been removed from the graphs at level σ. Thus the maximum number of levels in the tree is C. The complexity of the proposed approach is O(n 2 C τ=0 nτ ). This result is formally stated in the following lemma. Lemma 3. In the worst case, the complexity of the proposed method for the ESPP is O(n 2 C τ=0 nτ ). Proof. In the worst case, the original graph associated with the first node of the tree is solved and a N CC is detected. The branching procedure is applied and δ = n 1 sub-graphs are generated. When each of these sub-graph is solved, another N CC is detected and n 1 graphs of the next level are generated. This means that the number of graphs that have to be solved at level σ is (n 1) σ n σ. Since we know that the levels are bounded above by C, thus the total number of node is C τ=0 nτ. In addition, the complexity to solve each graph associated with a node with Algorithm 5 where K = 1 takes O(n 2 ) (see Lemma 2). It follows that the worst case complexity of the proposed method is O(n 2 C τ=0 nτ ). In Table 3, we show the tree structure explored by Algorithm 7 when solving the network of Figure 2. We report the graph associated with each node of the tree. In Table 4, we report for each iteration, the selected node/graph, the cost associated with each node after Algorithm 5 with K i = 1 is run, the label y ζ and the detected cycle. 21

22 G 4 (N, A \ {(1, 2); (2, 5)}) G 1 (N, A \ {(1, 2)}) G 5 (N, A \ {(1, 2); (5, 4)}) G 6 (N, A \ {(1, 2); (4, 2)}) G 7 (N, A \ {(2, 3); (2, 5)}) G 0 (N, A) G 2 (N, A \ {(2, 3)}) G 8 (N, A \ {(2, 3); (5, 4)}) G 9 (N, A \ {(2, 3); (4, 2)}) G 10 (N, A \ {(3, 1); (2, 5)}) G 3 (N, A \ {(3, 1)}) G 11 (N, A \ {(3, 1); (5, 4)}) G 12 (N, A \ {(3, 1); (4, 2)}) Table 3: Graph associated with the nodes of the tree structure. 22

23 23 y(g) ζ Selected node C 0 G 0 (N, A) < 1, 2, 3, 1 > 1 G 1 (N, A \ {(1, 2)}) < 2, 5, 4, 2 > 2 G 2 (N, A \ {(2, 3)}) < 2, 5, 4, 2 > 3 G 3 (N, A \ {(3, 1)}) < 2, 5, 4, 2 > 4 G 4 (N, A \ {(1, 2); (2, 5)}) G 5 (N, A \ {(1, 2); (5, 4)}) G 6 (N, A \ {(1, 2); (4, 2)}) G 7 (N, A \ {(2, 3); (2, 5)}) G 8 (N, A \ {(2, 3); (5, 4)}) G 9 (N, A \ {(2, 3); (4, 2)}) G 10 (N, A \ {(3, 1); (2, 5)}) G 11 (N, A \ {(3, 1); (5, 4)}) G 12 (N, A \ {(3, 1); (4, 2)}) y ζ Table 4: Information available at the end of each iteration. Under column y(g) we report, for each node i N \ {s}, the cost as output of Algorithm 5 with K i = 1. Column y ζ shows the potential optimal cost for each node i N \ {s}. C indicates the cycle returned by Algorithm 5.

24 4 Computational Experiments The aim of this Section is to evaluate the behaviour of the proposed solution approaches and to compare them in terms of computational cost. The experiments have been carried out on instances generated by ourselves. Indeed, the ESPP is not addressed by the scientific literature, thus no benchmark instances are available. In the next Section, we present the considered instances and how they were generated. 4.1 Test Problems The computational results are carried out on two groups of test problems. The first one is composed of random networks, the instances belonging to the second group are derived from Vehicle Routing Problem (VRP) benchmark test problems. The test problems of the first group (i.e., fully random networks) have been generated randomly by using the Netgen generator of Klinglman et al. [41]. Table 5 shows the characteristics of the considered fully random networks, where the number of nodes, the number of arcs and the density, that is the ratio between the number of arcs and the number of nodes are highlighted. The cost c ij, (i, j) A is randomly generated from the interval [0, 100]. test nodes arcs density R R R R R R R R R R R R R R R Table 5: Characteristic of the fully random networks. For each network, a given number of instances has been generated, in such a way that at least a fixed number of negative cost cycles is present. The procedure used to build the test problems is detailed in what follows. Let #c be the number of negative cost cycles and let leng be the number of arcs belonging to a given cycle. For each 24

EXERCISES SHORTEST PATHS: APPLICATIONS, OPTIMIZATION, VARIATIONS, AND SOLVING THE CONSTRAINED SHORTEST PATH PROBLEM. 1 Applications and Modelling

EXERCISES SHORTEST PATHS: APPLICATIONS, OPTIMIZATION, VARIATIONS, AND SOLVING THE CONSTRAINED SHORTEST PATH PROBLEM. 1 Applications and Modelling SHORTEST PATHS: APPLICATIONS, OPTIMIZATION, VARIATIONS, AND SOLVING THE CONSTRAINED SHORTEST PATH PROBLEM EXERCISES Prepared by Natashia Boland 1 and Irina Dumitrescu 2 1 Applications and Modelling 1.1

More information

The Shortest Path Problem. The Shortest Path Problem. Mathematical Model. Integer Programming Formulation

The Shortest Path Problem. The Shortest Path Problem. Mathematical Model. Integer Programming Formulation The Shortest Path Problem jla,jc@imm.dtu.dk Department of Management Engineering Technical University of Denmark The Shortest Path Problem Given a directed network G = (V,E,w) for which the underlying

More information

3 No-Wait Job Shops with Variable Processing Times

3 No-Wait Job Shops with Variable Processing Times 3 No-Wait Job Shops with Variable Processing Times In this chapter we assume that, on top of the classical no-wait job shop setting, we are given a set of processing times for each operation. We may select

More information

arxiv: v2 [cs.ds] 15 Feb 2017

arxiv: v2 [cs.ds] 15 Feb 2017 ALGORITHMS FOR NON-LINEAR AND STOCHASTIC RESOURCE CONSTRAINED SHORTEST PATH. AXEL PARMENTIER arxiv:1504.07880v2 [cs.ds] 15 Feb 2017 Abstract. Resource constrained shortest path problems are usually solved

More information

x ji = s i, i N, (1.1)

x ji = s i, i N, (1.1) Dual Ascent Methods. DUAL ASCENT In this chapter we focus on the minimum cost flow problem minimize subject to (i,j) A {j (i,j) A} a ij x ij x ij {j (j,i) A} (MCF) x ji = s i, i N, (.) b ij x ij c ij,

More information

Single Source Shortest Path

Single Source Shortest Path Single Source Shortest Path A directed graph G = (V, E) and a pair of nodes s, d is given. The edges have a real-valued weight W i. This time we are looking for the weight and the shortest path from s

More information

Solution Methods for the Multi-trip Elementary Shortest Path Problem with Resource Constraints

Solution Methods for the Multi-trip Elementary Shortest Path Problem with Resource Constraints Solution Methods for the Multi-trip Elementary Shortest Path Problem with Resource Constraints Zeliha Akca Ted K. Ralphs Rosemary T. Berger December 31, 2010 Abstract We investigate the multi-trip elementary

More information

Paths, Flowers and Vertex Cover

Paths, Flowers and Vertex Cover Paths, Flowers and Vertex Cover Venkatesh Raman M. S. Ramanujan Saket Saurabh Abstract It is well known that in a bipartite (and more generally in a König) graph, the size of the minimum vertex cover is

More information

CS599: Convex and Combinatorial Optimization Fall 2013 Lecture 14: Combinatorial Problems as Linear Programs I. Instructor: Shaddin Dughmi

CS599: Convex and Combinatorial Optimization Fall 2013 Lecture 14: Combinatorial Problems as Linear Programs I. Instructor: Shaddin Dughmi CS599: Convex and Combinatorial Optimization Fall 2013 Lecture 14: Combinatorial Problems as Linear Programs I Instructor: Shaddin Dughmi Announcements Posted solutions to HW1 Today: Combinatorial problems

More information

22 Elementary Graph Algorithms. There are two standard ways to represent a

22 Elementary Graph Algorithms. There are two standard ways to represent a VI Graph Algorithms Elementary Graph Algorithms Minimum Spanning Trees Single-Source Shortest Paths All-Pairs Shortest Paths 22 Elementary Graph Algorithms There are two standard ways to represent a graph

More information

Theorem 2.9: nearest addition algorithm

Theorem 2.9: nearest addition algorithm There are severe limits on our ability to compute near-optimal tours It is NP-complete to decide whether a given undirected =(,)has a Hamiltonian cycle An approximation algorithm for the TSP can be used

More information

Solution for Homework set 3

Solution for Homework set 3 TTIC 300 and CMSC 37000 Algorithms Winter 07 Solution for Homework set 3 Question (0 points) We are given a directed graph G = (V, E), with two special vertices s and t, and non-negative integral capacities

More information

2.3.4 Optimal paths in directed acyclic graphs

2.3.4 Optimal paths in directed acyclic graphs .3.4 Optimal paths in directed acyclic graphs Definition: A directed graph G = (N, A) is acyclic if it contains no circuits. A directed acyclic graph is referred to as DAG. circuit Problem Given a directed

More information

Artificial Intelligence

Artificial Intelligence Artificial Intelligence Shortest Path Problem G. Guérard Department of Nouvelles Energies Ecole Supérieur d Ingénieurs Léonard de Vinci Lecture 3 GG A.I. 1/42 Outline 1 The Shortest Path Problem Introduction

More information

Algorithms for Integer Programming

Algorithms for Integer Programming Algorithms for Integer Programming Laura Galli November 9, 2016 Unlike linear programming problems, integer programming problems are very difficult to solve. In fact, no efficient general algorithm is

More information

Scan Scheduling Specification and Analysis

Scan Scheduling Specification and Analysis Scan Scheduling Specification and Analysis Bruno Dutertre System Design Laboratory SRI International Menlo Park, CA 94025 May 24, 2000 This work was partially funded by DARPA/AFRL under BAE System subcontract

More information

Job-shop scheduling with limited capacity buffers

Job-shop scheduling with limited capacity buffers Job-shop scheduling with limited capacity buffers Peter Brucker, Silvia Heitmann University of Osnabrück, Department of Mathematics/Informatics Albrechtstr. 28, D-49069 Osnabrück, Germany {peter,sheitman}@mathematik.uni-osnabrueck.de

More information

A Note on the Separation of Subtour Elimination Constraints in Asymmetric Routing Problems

A Note on the Separation of Subtour Elimination Constraints in Asymmetric Routing Problems Gutenberg School of Management and Economics Discussion Paper Series A Note on the Separation of Subtour Elimination Constraints in Asymmetric Routing Problems Michael Drexl March 202 Discussion paper

More information

Dynamic programming for the orienteering problem with time windows

Dynamic programming for the orienteering problem with time windows Dynamic programming for the orienteering problem with time windows Giovanni Righini, Matteo Salani Dipartimento di Tecnologie dell Informazione Università degli Studi di Milano, Via Bramante 65, 26013

More information

Conflict Graphs for Combinatorial Optimization Problems

Conflict Graphs for Combinatorial Optimization Problems Conflict Graphs for Combinatorial Optimization Problems Ulrich Pferschy joint work with Andreas Darmann and Joachim Schauer University of Graz, Austria Introduction Combinatorial Optimization Problem CO

More information

Branch-and-bound: an example

Branch-and-bound: an example Branch-and-bound: an example Giovanni Righini Università degli Studi di Milano Operations Research Complements The Linear Ordering Problem The Linear Ordering Problem (LOP) is an N P-hard combinatorial

More information

Shortest path problems

Shortest path problems Next... Shortest path problems Single-source shortest paths in weighted graphs Shortest-Path Problems Properties of Shortest Paths, Relaxation Dijkstra s Algorithm Bellman-Ford Algorithm Shortest-Paths

More information

2.3 Optimal paths. Optimal (shortest or longest) paths have a wide range of applications:

2.3 Optimal paths. Optimal (shortest or longest) paths have a wide range of applications: . Optimal paths Optimal (shortest or longest) paths have a wide range of applications: Google maps, GPS navigators planning and management of transportation, electrical and telecommunication networks project

More information

1 Dijkstra s Algorithm

1 Dijkstra s Algorithm Lecture 11 Dijkstra s Algorithm Scribes: Himanshu Bhandoh (2015), Virginia Williams, and Date: November 1, 2017 Anthony Kim (2016), G. Valiant (2017), M. Wootters (2017) (Adapted from Virginia Williams

More information

A NETWORK SIMPLEX ALGORITHM FOR SOLVING THE MINIMUM DISTRIBUTION COST PROBLEM. I-Lin Wang and Shiou-Jie Lin. (Communicated by Shu-Cherng Fang)

A NETWORK SIMPLEX ALGORITHM FOR SOLVING THE MINIMUM DISTRIBUTION COST PROBLEM. I-Lin Wang and Shiou-Jie Lin. (Communicated by Shu-Cherng Fang) JOURNAL OF INDUSTRIAL AND doi:10.3934/jimo.2009.5.929 MANAGEMENT OPTIMIZATION Volume 5, Number 4, November 2009 pp. 929 950 A NETWORK SIMPLEX ALGORITHM FOR SOLVING THE MINIMUM DISTRIBUTION COST PROBLEM

More information

Network optimization: An overview

Network optimization: An overview Network optimization: An overview Mathias Johanson Alkit Communications 1 Introduction Various kinds of network optimization problems appear in many fields of work, including telecommunication systems,

More information

A Bi-directional Resource-bounded Dynamic Programming Approach for the Traveling Salesman Problem with Time Windows

A Bi-directional Resource-bounded Dynamic Programming Approach for the Traveling Salesman Problem with Time Windows Submitted manuscript A Bi-directional Resource-bounded Dynamic Programming Approach for the Traveling Salesman Problem with Time Windows Jing-Quan Li California PATH, University of California, Berkeley,

More information

2.3 Optimal paths. E. Amaldi Foundations of Operations Research Politecnico di Milano 1

2.3 Optimal paths. E. Amaldi Foundations of Operations Research Politecnico di Milano 1 . Optimal paths E. Amaldi Foundations of Operations Research Politecnico di Milano Optimal (minimum or maximum) paths have a wide range of applications: Google maps, GPS navigators planning and management

More information

Lecture 18 Solving Shortest Path Problem: Dijkstra s Algorithm. October 23, 2009

Lecture 18 Solving Shortest Path Problem: Dijkstra s Algorithm. October 23, 2009 Solving Shortest Path Problem: Dijkstra s Algorithm October 23, 2009 Outline Lecture 18 Focus on Dijkstra s Algorithm Importance: Where it has been used? Algorithm s general description Algorithm steps

More information

Graphs and Network Flows IE411. Lecture 21. Dr. Ted Ralphs

Graphs and Network Flows IE411. Lecture 21. Dr. Ted Ralphs Graphs and Network Flows IE411 Lecture 21 Dr. Ted Ralphs IE411 Lecture 21 1 Combinatorial Optimization and Network Flows In general, most combinatorial optimization and integer programming problems are

More information

A Benders decomposition approach for the robust shortest path problem with interval data

A Benders decomposition approach for the robust shortest path problem with interval data A Benders decomposition approach for the robust shortest path problem with interval data R. Montemanni, L.M. Gambardella Istituto Dalle Molle di Studi sull Intelligenza Artificiale (IDSIA) Galleria 2,

More information

Approximability Results for the p-center Problem

Approximability Results for the p-center Problem Approximability Results for the p-center Problem Stefan Buettcher Course Project Algorithm Design and Analysis Prof. Timothy Chan University of Waterloo, Spring 2004 The p-center

More information

Greedy Algorithms 1. For large values of d, brute force search is not feasible because there are 2 d

Greedy Algorithms 1. For large values of d, brute force search is not feasible because there are 2 d Greedy Algorithms 1 Simple Knapsack Problem Greedy Algorithms form an important class of algorithmic techniques. We illustrate the idea by applying it to a simplified version of the Knapsack Problem. Informally,

More information

CS 161 Lecture 11 BFS, Dijkstra s algorithm Jessica Su (some parts copied from CLRS) 1 Review

CS 161 Lecture 11 BFS, Dijkstra s algorithm Jessica Su (some parts copied from CLRS) 1 Review 1 Review 1 Something I did not emphasize enough last time is that during the execution of depth-firstsearch, we construct depth-first-search trees. One graph may have multiple depth-firstsearch trees,

More information

A two-level metaheuristic for the All Colors Shortest Path Problem

A two-level metaheuristic for the All Colors Shortest Path Problem Noname manuscript No (will be inserted by the editor) A two-level metaheuristic for the All Colors Shortest Path Problem F Carrabs R Cerulli R Pentangelo A Raiconi Received: date / Accepted: date Abstract

More information

A Faster Algorithm for the Inverse Spanning Tree Problem

A Faster Algorithm for the Inverse Spanning Tree Problem A Faster Algorithm for the Inverse Spanning Tree Problem Ravindra K. Ahuja Department of Industrial & Systems Engineering University of Florida, Gainesville, FL 32611, USA ahuja@ufl.edu James B. Orlin

More information

Mathematical and Algorithmic Foundations Linear Programming and Matchings

Mathematical and Algorithmic Foundations Linear Programming and Matchings Adavnced Algorithms Lectures Mathematical and Algorithmic Foundations Linear Programming and Matchings Paul G. Spirakis Department of Computer Science University of Patras and Liverpool Paul G. Spirakis

More information

Online algorithms for clustering problems

Online algorithms for clustering problems University of Szeged Department of Computer Algorithms and Artificial Intelligence Online algorithms for clustering problems Summary of the Ph.D. thesis by Gabriella Divéki Supervisor Dr. Csanád Imreh

More information

α Coverage to Extend Network Lifetime on Wireless Sensor Networks

α Coverage to Extend Network Lifetime on Wireless Sensor Networks Noname manuscript No. (will be inserted by the editor) α Coverage to Extend Network Lifetime on Wireless Sensor Networks Monica Gentili Andrea Raiconi Received: date / Accepted: date Abstract An important

More information

Copyright 2007 Pearson Addison-Wesley. All rights reserved. A. Levitin Introduction to the Design & Analysis of Algorithms, 2 nd ed., Ch.

Copyright 2007 Pearson Addison-Wesley. All rights reserved. A. Levitin Introduction to the Design & Analysis of Algorithms, 2 nd ed., Ch. Iterative Improvement Algorithm design technique for solving optimization problems Start with a feasible solution Repeat the following step until no improvement can be found: change the current feasible

More information

Material handling and Transportation in Logistics. Paolo Detti Dipartimento di Ingegneria dell Informazione e Scienze Matematiche Università di Siena

Material handling and Transportation in Logistics. Paolo Detti Dipartimento di Ingegneria dell Informazione e Scienze Matematiche Università di Siena Material handling and Transportation in Logistics Paolo Detti Dipartimento di Ingegneria dell Informazione e Scienze Matematiche Università di Siena Introduction to Graph Theory Graph Theory As Mathematical

More information

and 6.855J March 6, Maximum Flows 2

and 6.855J March 6, Maximum Flows 2 5.08 and.855j March, 00 Maximum Flows Network Reliability Communication Network What is the maximum number of arc disjoint paths from s to t? How can we determine this number? Theorem. Let G = (N,A) be

More information

Shortest Path Problem

Shortest Path Problem Shortest Path Problem CLRS Chapters 24.1 3, 24.5, 25.2 Shortest path problem Shortest path problem (and variants) Properties of shortest paths Algorithmic framework Bellman-Ford algorithm Shortest paths

More information

COL351: Analysis and Design of Algorithms (CSE, IITD, Semester-I ) Name: Entry number:

COL351: Analysis and Design of Algorithms (CSE, IITD, Semester-I ) Name: Entry number: Name: Entry number: There are 6 questions for a total of 75 points. 1. Consider functions f(n) = 10n2 n + 3 n and g(n) = n3 n. Answer the following: (a) ( 1 / 2 point) State true or false: f(n) is O(g(n)).

More information

Adaptations of the A* Algorithm for the Computation of Fastest Paths in Deterministic Discrete-Time Dynamic Networks

Adaptations of the A* Algorithm for the Computation of Fastest Paths in Deterministic Discrete-Time Dynamic Networks 60 IEEE TRANSACTIONS ON INTELLIGENT TRANSPORTATION SYSTEMS, VOL. 3, NO. 1, MARCH 2002 Adaptations of the A* Algorithm for the Computation of Fastest Paths in Deterministic Discrete-Time Dynamic Networks

More information

A Recovery Algorithm for a Disrupted Airline Schedule

A Recovery Algorithm for a Disrupted Airline Schedule 1 A Recovery Algorithm for a Disrupted Airline Schedule Niklaus Eggenberg Matteo Salani and Prof. M. Bierlaire In collaboration with APM Technologies Index 2 Index Airline Scheduling in general The Disrupted

More information

These are not polished as solutions, but ought to give a correct idea of solutions that work. Note that most problems have multiple good solutions.

These are not polished as solutions, but ought to give a correct idea of solutions that work. Note that most problems have multiple good solutions. CSE 591 HW Sketch Sample Solutions These are not polished as solutions, but ought to give a correct idea of solutions that work. Note that most problems have multiple good solutions. Problem 1 (a) Any

More information

Subset sum problem and dynamic programming

Subset sum problem and dynamic programming Lecture Notes: Dynamic programming We will discuss the subset sum problem (introduced last time), and introduce the main idea of dynamic programming. We illustrate it further using a variant of the so-called

More information

Last topic: Summary; Heuristics and Approximation Algorithms Topics we studied so far:

Last topic: Summary; Heuristics and Approximation Algorithms Topics we studied so far: Last topic: Summary; Heuristics and Approximation Algorithms Topics we studied so far: I Strength of formulations; improving formulations by adding valid inequalities I Relaxations and dual problems; obtaining

More information

Network Design and Optimization course

Network Design and Optimization course Effective maximum flow algorithms Modeling with flows Network Design and Optimization course Lecture 5 Alberto Ceselli alberto.ceselli@unimi.it Dipartimento di Tecnologie dell Informazione Università degli

More information

CHAPTER 3 A TIME-DEPENDENT k-shortest PATH ALGORITHM FOR ATIS APPLICATIONS

CHAPTER 3 A TIME-DEPENDENT k-shortest PATH ALGORITHM FOR ATIS APPLICATIONS CHAPTER 3 A TIME-DEPENDENT k-shortest PATH ALGORITHM FOR ATIS APPLICATIONS 3.1. Extension of a Static k-sp Algorithm to the Time-Dependent Case Kaufman and Smith [1993] showed that under the consistency

More information

Methods and Models for Combinatorial Optimization Exact methods for the Traveling Salesman Problem

Methods and Models for Combinatorial Optimization Exact methods for the Traveling Salesman Problem Methods and Models for Combinatorial Optimization Exact methods for the Traveling Salesman Problem L. De Giovanni M. Di Summa The Traveling Salesman Problem (TSP) is an optimization problem on a directed

More information

and 6.855J. The Successive Shortest Path Algorithm and the Capacity Scaling Algorithm for the Minimum Cost Flow Problem

and 6.855J. The Successive Shortest Path Algorithm and the Capacity Scaling Algorithm for the Minimum Cost Flow Problem 15.082 and 6.855J The Successive Shortest Path Algorithm and the Capacity Scaling Algorithm for the Minimum Cost Flow Problem 1 Pseudo-Flows A pseudo-flow is a "flow" vector x such that 0 x u. Let e(i)

More information

1 Non greedy algorithms (which we should have covered

1 Non greedy algorithms (which we should have covered 1 Non greedy algorithms (which we should have covered earlier) 1.1 Floyd Warshall algorithm This algorithm solves the all-pairs shortest paths problem, which is a problem where we want to find the shortest

More information

22 Elementary Graph Algorithms. There are two standard ways to represent a

22 Elementary Graph Algorithms. There are two standard ways to represent a VI Graph Algorithms Elementary Graph Algorithms Minimum Spanning Trees Single-Source Shortest Paths All-Pairs Shortest Paths 22 Elementary Graph Algorithms There are two standard ways to represent a graph

More information

Dominance Constraints and Dominance Graphs

Dominance Constraints and Dominance Graphs Dominance Constraints and Dominance Graphs David Steurer Saarland University Abstract. Dominance constraints logically describe trees in terms of their adjacency and dominance, i.e. reachability, relation.

More information

Two-Levels-Greedy: a generalization of Dijkstra s shortest path algorithm

Two-Levels-Greedy: a generalization of Dijkstra s shortest path algorithm Electronic Notes in Discrete Mathematics 17 (2004) 81 86 www.elsevier.com/locate/endm Two-Levels-Greedy: a generalization of Dijkstra s shortest path algorithm Domenico Cantone 1 Simone Faro 2 Department

More information

Bi-objective Network Flow Optimization Problem

Bi-objective Network Flow Optimization Problem Bi-objective Network Flow Optimization Problem Pedro Miguel Guedelha Dias Department of Engineering and Management, Instituto Superior Técnico June 2016 Abstract Network flow problems, specifically minimum

More information

On the Computational Behavior of a Dual Network Exterior Point Simplex Algorithm for the Minimum Cost Network Flow Problem

On the Computational Behavior of a Dual Network Exterior Point Simplex Algorithm for the Minimum Cost Network Flow Problem On the Computational Behavior of a Dual Network Exterior Point Simplex Algorithm for the Minimum Cost Network Flow Problem George Geranis, Konstantinos Paparrizos, Angelo Sifaleras Department of Applied

More information

1 Linear programming relaxation

1 Linear programming relaxation Cornell University, Fall 2010 CS 6820: Algorithms Lecture notes: Primal-dual min-cost bipartite matching August 27 30 1 Linear programming relaxation Recall that in the bipartite minimum-cost perfect matching

More information

The Encoding Complexity of Network Coding

The Encoding Complexity of Network Coding The Encoding Complexity of Network Coding Michael Langberg Alexander Sprintson Jehoshua Bruck California Institute of Technology Email: mikel,spalex,bruck @caltech.edu Abstract In the multicast network

More information

FUTURE communication networks are expected to support

FUTURE communication networks are expected to support 1146 IEEE/ACM TRANSACTIONS ON NETWORKING, VOL 13, NO 5, OCTOBER 2005 A Scalable Approach to the Partition of QoS Requirements in Unicast and Multicast Ariel Orda, Senior Member, IEEE, and Alexander Sprintson,

More information

Job Management & Network Flows

Job Management & Network Flows Job Management & Network Flows How to solve job management problems with networks flow techniques Francesca Armandillo BMI paper Vre Universiteit Faculty of Sciences Business Mathematics and Informatics

More information

A Computational Study of Bi-directional Dynamic Programming for the Traveling Salesman Problem with Time Windows

A Computational Study of Bi-directional Dynamic Programming for the Traveling Salesman Problem with Time Windows A Computational Study of Bi-directional Dynamic Programming for the Traveling Salesman Problem with Time Windows Jing-Quan Li California PATH, University of California, Berkeley, Richmond, CA 94804, jingquan@path.berkeley.edu

More information

6. Lecture notes on matroid intersection

6. Lecture notes on matroid intersection Massachusetts Institute of Technology 18.453: Combinatorial Optimization Michel X. Goemans May 2, 2017 6. Lecture notes on matroid intersection One nice feature about matroids is that a simple greedy algorithm

More information

CS 6783 (Applied Algorithms) Lecture 5

CS 6783 (Applied Algorithms) Lecture 5 CS 6783 (Applied Algorithms) Lecture 5 Antonina Kolokolova January 19, 2012 1 Minimum Spanning Trees An undirected graph G is a pair (V, E); V is a set (of vertices or nodes); E is a set of (undirected)

More information

Computational complexity

Computational complexity Computational complexity Heuristic Algorithms Giovanni Righini University of Milan Department of Computer Science (Crema) Definitions: problems and instances A problem is a general question expressed in

More information

Lecture 11: Analysis of Algorithms (CS ) 1

Lecture 11: Analysis of Algorithms (CS ) 1 Lecture 11: Analysis of Algorithms (CS583-002) 1 Amarda Shehu November 12, 2014 1 Some material adapted from Kevin Wayne s Algorithm Class @ Princeton 1 2 Dynamic Programming Approach Floyd-Warshall Shortest

More information

Final Exam Solutions

Final Exam Solutions Introduction to Algorithms December 14, 2010 Massachusetts Institute of Technology 6.006 Fall 2010 Professors Konstantinos Daskalakis and Patrick Jaillet Final Exam Solutions Final Exam Solutions Problem

More information

Solutions for the Exam 6 January 2014

Solutions for the Exam 6 January 2014 Mastermath and LNMB Course: Discrete Optimization Solutions for the Exam 6 January 2014 Utrecht University, Educatorium, 13:30 16:30 The examination lasts 3 hours. Grading will be done before January 20,

More information

arxiv: v2 [cs.ds] 30 Sep 2016

arxiv: v2 [cs.ds] 30 Sep 2016 Synergistic Sorting, MultiSelection and Deferred Data Structures on MultiSets Jérémy Barbay 1, Carlos Ochoa 1, and Srinivasa Rao Satti 2 1 Departamento de Ciencias de la Computación, Universidad de Chile,

More information

Graphs and Network Flows ISE 411. Lecture 7. Dr. Ted Ralphs

Graphs and Network Flows ISE 411. Lecture 7. Dr. Ted Ralphs Graphs and Network Flows ISE 411 Lecture 7 Dr. Ted Ralphs ISE 411 Lecture 7 1 References for Today s Lecture Required reading Chapter 20 References AMO Chapter 13 CLRS Chapter 23 ISE 411 Lecture 7 2 Minimum

More information

1 The Shortest Path Problem

1 The Shortest Path Problem CS161 Lecture 11 Single Source Shortest Paths Scribed by: Romil Verma (2015), Virginia Date: May 8, 2016 1 The Shortest Path Problem In this lecture, we ll discuss the shortest path problem. Assume we

More information

Unifying and extending hybrid tractable classes of CSPs

Unifying and extending hybrid tractable classes of CSPs Journal of Experimental & Theoretical Artificial Intelligence Vol. 00, No. 00, Month-Month 200x, 1 16 Unifying and extending hybrid tractable classes of CSPs Wady Naanaa Faculty of sciences, University

More information

Local Search for Hop-constrained Directed Steiner Tree Problem with Application to UAV-based Multi-target Surveillance

Local Search for Hop-constrained Directed Steiner Tree Problem with Application to UAV-based Multi-target Surveillance Local Search for Hop-constrained Directed Steiner Tree Problem with Application to UAV-based Multi-target Surveillance Oleg Burdakov a,1 Patrick Doherty b Jonas Kvarnström b LiTH-MAT-R 2014/10 SE a Department

More information

15.083J Integer Programming and Combinatorial Optimization Fall Enumerative Methods

15.083J Integer Programming and Combinatorial Optimization Fall Enumerative Methods 5.8J Integer Programming and Combinatorial Optimization Fall 9 A knapsack problem Enumerative Methods Let s focus on maximization integer linear programs with only binary variables For example: a knapsack

More information

2. True or false: even though BFS and DFS have the same space complexity, they do not always have the same worst case asymptotic time complexity.

2. True or false: even though BFS and DFS have the same space complexity, they do not always have the same worst case asymptotic time complexity. 1. T F: Consider a directed graph G = (V, E) and a vertex s V. Suppose that for all v V, there exists a directed path in G from s to v. Suppose that a DFS is run on G, starting from s. Then, true or false:

More information

Basic Graph Theory with Applications to Economics

Basic Graph Theory with Applications to Economics Basic Graph Theory with Applications to Economics Debasis Mishra February, 0 What is a Graph? Let N = {,..., n} be a finite set. Let E be a collection of ordered or unordered pairs of distinct elements

More information

COL 702 : Assignment 1 solutions

COL 702 : Assignment 1 solutions COL 70 : Assignment 1 solutions 1(a ( n T (n = T + bn log n ( n = T + b n ( n log + bn log n ( n = T + b n ( n 8 log + b n log ( n + bn log n = bn log n + b n log n + bn log n +... log n terms = nb [(log

More information

The optimal routing of augmented cubes.

The optimal routing of augmented cubes. The optimal routing of augmented cubes. Meirun Chen, Reza Naserasr To cite this version: Meirun Chen, Reza Naserasr. The optimal routing of augmented cubes.. Information Processing Letters, Elsevier, 28.

More information

CMPSCI 311: Introduction to Algorithms Practice Final Exam

CMPSCI 311: Introduction to Algorithms Practice Final Exam CMPSCI 311: Introduction to Algorithms Practice Final Exam Name: ID: Instructions: Answer the questions directly on the exam pages. Show all your work for each question. Providing more detail including

More information

The Size Robust Multiple Knapsack Problem

The Size Robust Multiple Knapsack Problem MASTER THESIS ICA-3251535 The Size Robust Multiple Knapsack Problem Branch and Price for the Separate and Combined Recovery Decomposition Model Author: D.D. Tönissen, Supervisors: dr. ir. J.M. van den

More information

Minimum Cost Edge Disjoint Paths

Minimum Cost Edge Disjoint Paths Minimum Cost Edge Disjoint Paths Theodor Mader 15.4.2008 1 Introduction Finding paths in networks and graphs constitutes an area of theoretical computer science which has been highly researched during

More information

Integer Programming Theory

Integer Programming Theory Integer Programming Theory Laura Galli October 24, 2016 In the following we assume all functions are linear, hence we often drop the term linear. In discrete optimization, we seek to find a solution x

More information

6.854J / J Advanced Algorithms Fall 2008

6.854J / J Advanced Algorithms Fall 2008 MIT OpenCourseWare http://ocw.mit.edu 6.854J / 18.415J Advanced Algorithms Fall 2008 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms. 18.415/6.854 Advanced

More information

Heuristic (Informed) Search

Heuristic (Informed) Search Heuristic (Informed) Search (Where we try to choose smartly) R&N: Chap., Sect..1 3 1 Search Algorithm #2 SEARCH#2 1. INSERT(initial-node,Open-List) 2. Repeat: a. If empty(open-list) then return failure

More information

Solving problems on graph algorithms

Solving problems on graph algorithms Solving problems on graph algorithms Workshop Organized by: ACM Unit, Indian Statistical Institute, Kolkata. Tutorial-3 Date: 06.07.2017 Let G = (V, E) be an undirected graph. For a vertex v V, G {v} is

More information

11.1 Facility Location

11.1 Facility Location CS787: Advanced Algorithms Scribe: Amanda Burton, Leah Kluegel Lecturer: Shuchi Chawla Topic: Facility Location ctd., Linear Programming Date: October 8, 2007 Today we conclude the discussion of local

More information

Introduction. I Given a weighted, directed graph G =(V, E) with weight function

Introduction. I Given a weighted, directed graph G =(V, E) with weight function ntroduction Computer Science & Engineering 2/82 Design and Analysis of Algorithms Lecture 06 Single-Source Shortest Paths (Chapter 2) Stephen Scott (Adapted from Vinodchandran N. Variyam) sscott@cse.unl.edu

More information

Efficient Edge-Swapping Heuristics for the Reload Cost Spanning Tree Problem

Efficient Edge-Swapping Heuristics for the Reload Cost Spanning Tree Problem Efficient Edge-Swapping Heuristics for the Reload Cost Spanning Tree Problem S. Raghavan and Mustafa Sahin Smith School of Business & Institute for Systems Research, University of Maryland, College Park,

More information

A Bucket Graph Based Labelling Algorithm for the Resource Constrained Shortest Path Problem with Applications to Vehicle Routing

A Bucket Graph Based Labelling Algorithm for the Resource Constrained Shortest Path Problem with Applications to Vehicle Routing 1 / 23 A Bucket Graph Based Labelling Algorithm for the Resource Constrained Shortest Path Problem with Applications to Vehicle Routing Ruslan Sadykov 1,2 Artur Pessoa 3 Eduardo Uchoa 3 1 Inria Bordeaux,

More information

Framework for Design of Dynamic Programming Algorithms

Framework for Design of Dynamic Programming Algorithms CSE 441T/541T Advanced Algorithms September 22, 2010 Framework for Design of Dynamic Programming Algorithms Dynamic programming algorithms for combinatorial optimization generalize the strategy we studied

More information

Introduction to Mathematical Programming IE406. Lecture 16. Dr. Ted Ralphs

Introduction to Mathematical Programming IE406. Lecture 16. Dr. Ted Ralphs Introduction to Mathematical Programming IE406 Lecture 16 Dr. Ted Ralphs IE406 Lecture 16 1 Reading for This Lecture Bertsimas 7.1-7.3 IE406 Lecture 16 2 Network Flow Problems Networks are used to model

More information

CSE 431/531: Analysis of Algorithms. Greedy Algorithms. Lecturer: Shi Li. Department of Computer Science and Engineering University at Buffalo

CSE 431/531: Analysis of Algorithms. Greedy Algorithms. Lecturer: Shi Li. Department of Computer Science and Engineering University at Buffalo CSE 431/531: Analysis of Algorithms Greedy Algorithms Lecturer: Shi Li Department of Computer Science and Engineering University at Buffalo Main Goal of Algorithm Design Design fast algorithms to solve

More information

Instituto de Engenharia de Sistemas e Computadores de Coimbra Institute of Systems Engineering and Computers INESC Coimbra

Instituto de Engenharia de Sistemas e Computadores de Coimbra Institute of Systems Engineering and Computers INESC Coimbra Instituto de Engenharia de Sistemas e Computadores de Coimbra Institute of Systems Engineering and Computers INESC Coimbra Marta Pascoal and Marisa Resende Minmax regret robust shortest path problem in

More information

Distributed minimum spanning tree problem

Distributed minimum spanning tree problem Distributed minimum spanning tree problem Juho-Kustaa Kangas 24th November 2012 Abstract Given a connected weighted undirected graph, the minimum spanning tree problem asks for a spanning subtree with

More information

General properties of staircase and convex dual feasible functions

General properties of staircase and convex dual feasible functions General properties of staircase and convex dual feasible functions JÜRGEN RIETZ, CLÁUDIO ALVES, J. M. VALÉRIO de CARVALHO Centro de Investigação Algoritmi da Universidade do Minho, Escola de Engenharia

More information

Institutionen för datavetenskap Department of Computer and Information Science

Institutionen för datavetenskap Department of Computer and Information Science Institutionen för datavetenskap Department of Computer and Information Science Final thesis K Shortest Path Implementation by RadhaKrishna Nagubadi LIU-IDA/LITH-EX-A--13/41--SE 213-6-27 Linköpings universitet

More information

09 B: Graph Algorithms II

09 B: Graph Algorithms II Correctness and Complexity of 09 B: Graph Algorithms II CS1102S: Data Structures and Algorithms Martin Henz March 19, 2010 Generated on Thursday 18 th March, 2010, 00:20 CS1102S: Data Structures and Algorithms

More information

An Evolutionary Algorithm for the Multi-objective Shortest Path Problem

An Evolutionary Algorithm for the Multi-objective Shortest Path Problem An Evolutionary Algorithm for the Multi-objective Shortest Path Problem Fangguo He Huan Qi Qiong Fan Institute of Systems Engineering, Huazhong University of Science & Technology, Wuhan 430074, P. R. China

More information