Full text
The Capacitated Minimum Spanning Tree Problem PhD Student: H´ector Efra´ın Ruiz y Ruiz Thesis directed by Maria Albareda Sambola Elena Fern´andez Ar´eizaga Department of Statistics and Operations Research Universitat Polit`ecnica de Catalunya. BarcelonaTech
Acknowledgments Along the development of this thesis I’ve had the pleasure of working with some researchers from whom I learnt a lot. I am specially grateful to Elena Fern´andez and Mari Albareda for their unconditional support and patience, specially in the most difficult moments. I also want to thank Mauricio Resende for his contributions to do part of this work. Most of this work was developed in the Departament d’Estad´ıstica i Investigaci´o Operativa of the Universitat Polit`ecnica de Catalunya. I want to thank the department and all its members for all the facilities and help I found here. Specially to Sonia Navarro and Laura Mar´ı for their help during the thesis deposit. I also want to thank the CONACYT for their financial support. Finally, I want to thank my parents for the gift of life; my brothers and sister for all the time and experiences that we have shared; and all my friends for their support and friendship. i
Contents Introduction 1 1 Problem definition and literature review 5 1.1 Problemdefinition ................................. 5 1.2 Literaturereview.................................. 8 1.2.1 Formulations and exact methods . . . . . . . . . . . . . . . . . . . . . 8 1.3 Heuristicmethods ................................. 10 2 Formulations and valid inequalities for the CMST 14 2.1 Two basic binary formulations . . . . . . . . . . . . . . . . . . . . . . . . . . 14 2.1.1 Directed formulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 2.1.2 Hop indexed formulation . . . . . . . . . . . . . . . . . . . . . . . . . 15 2.2 Well-known valid inequalities . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 2.2.1 Bin-packing inequalities . . . . . . . . . . . . . . . . . . . . . . . . . . 17 2.2.2 Multistar inequalities . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 2.2.3 Rootcutset inequalities . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 2.2.4 GSEhinequalities ............................. 20 3 New formulations for the CMST 22 3.1 Thesubrootformulation.............................. 22 3.2 Valid inequalities for the subroot formulation . . . . . . . . . . . . . . . . . . 23 3.2.1 Subroot multistar inequalities . . . . . . . . . . . . . . . . . . . . . . . 23 3.2.2 s-tree multistar inequalities . . . . . . . . . . . . . . . . . . . . . . . . 27 3.2.3 Subroot rootcutset inequalities . . . . . . . . . . . . . . . . . . . . . . 27 3.2.4 Otherinequalities ............................. 27 3.2.5 Solution algorithm for the subroot formulation . . . . . . . . . . . . . 28 3.3 Subroot hop indexed formulation. . . . . . . . . . . . . . . . . . . . . . . . . . 32 3.3.1 Solution algorithm for the subroot hop indexed formulation . . . . . . 34 4 A BRKGA heuristic for the CMST 39 4.1 Biased random-key genetic algorithms . . . . . . . . . . . . . . . . . . . . . . 39 4.2 Encodinganddecoding .............................. 40 4.2.1 Direct assignment decoder . . . . . . . . . . . . . . . . . . . . . . . . . 41 4.2.2 Cost-based assignment decoder . . . . . . . . . . . . . . . . . . . . . . 43 4.2.3 Predecessor assignment decoder . . . . . . . . . . . . . . . . . . . . . . 44 4.2.4 Feasibility recovery procedure for the predecessor assignment decoder 44 ii
4.3 Improvementphase................................. 45 4.3.1 Minimum spanning tree stage (MST-stage) . . . . . . . . . . . . . . . 46 4.3.2 Localsearchstage ............................. 47 4.3.3 Impact of MST computations . . . . . . . . . . . . . . . . . . . . . . . 49 4.3.4 Strategic oscillation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 4.3.5 Neighborhood reduction . . . . . . . . . . . . . . . . . . . . . . . . . . 50 4.4 BRKGA algorithm for the CMST . . . . . . . . . . . . . . . . . . . . . . . . . 50 5 Numerical Experience 53 5.1 Benchmarkinstances................................ 53 5.2 BRKGA experimental results . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 5.2.1 BRKGA implementation details . . . . . . . . . . . . . . . . . . . . . 58 5.2.2 BRKGA numerical results analysis . . . . . . . . . . . . . . . . . . . . 59 5.3 Experimental results with the cutting plane algorithms . . . . . . . . . . . . . 70 5.3.1 Variable elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 5.3.2 Results obtained with the subroot formulation . . . . . . . . . . . . . 72 5.3.3 Results obtained with the subroot hop indexed formulation . . . . . . 76 6 Conclusions and future research 83 iii
iv
Introduction Choices are part of our lives. In some occasions, the choice has to be made among a small number of alternatives, and intuition and common sense can be enough to make a good decision. However, when it comes to choose some elements of a large set that altogether satisfy our needs in the best possible way, the complexity of the decision can notably increase. In daily life situations, like choosing the best combination of possible dishes and drinks to design a banquet, the impact of the decision is relative, and most of the acceptable combinations are almost equally good. But when the decision affects the economy of a company (as for instance, when selecting the particular goods to be sold in a supermarket in order to produce the highest possible yields) or the cost and quality of a public service (e.g. when deciding which bus stops to set and the links between them to form the bus lines) it becomes very important to take all available information into account to make the best possible decision. In this case, mathematics are a very useful support. The study of sets as mathematical objects has always been a relevant field of mathematics that is called Combinatorics. Although some tools in this field, as the combinatorial coefficients, were already known in the 12th century, most of the relevant developments were carried out during the 17th century and afterwards. Indeed, the term combinatorics itself was not introduced until 1666, when Gottfried Leibniz published his book De Arte Combinatoria. Going beyond the study of the sets by themselves and their structural properties, many other fields of mathematics are strongly related to sets and make intensive use of results from combinatorics. Among them, we find, for instance, probability theory, order theory, graph theory and combinatorial optimization. The focus of this last field are optimization problems that are defined over discrete sets and whose feasible solutions are those subsets that fulfill some established conditions. If the ground set has a small number of elements, it is possible to explicitly enumerate all feasible solutions, and then, choose the most attractive one. However, as the ground set becomes larger, the number of subsets explodes and the time required just to enumerate the feasible solutions of a problem can be unaffordable for the decision maker. Therefore, specific tools are required to solve these problems. Given the fact that, as just mentioned, the optimization problems faced in combinatorial optimization are discrete and that the size of the set of solutions to consider can be extremely large, in most cases, the only way to solve these problems efficiently is to exploit the specific structure of each particular problem. For this reason, there is a large variety of problems that have been studied within the scope of combinatorial optimization. Many of these problems can be expressed in terms of graphs, which often allows to make use of results from graph theory to have a deeper knowledge of the properties of the involved sets. A very important class of graphs is that of connected graphs. In many problems defined 1
over a graph, solutions are subgraphs that are required to be connected. For instance, if one seeks to find a route for traveling between two cities, that route cannot be formed by unconnected links; also, in the design of a telecommunications network, all the nodes need to be accessible from the server. Since the most elemental connected graph is a tree, tree structures are often essential to guarantee connectivity in the solution of combinatorial optimization problems. For this reason, Minimum Spanning Tree (MST) problems are considered to be among the core problems in combinatorial optimization. These problems have been widely studied by researchers who have identified some of their structural properties and have developed efficient algorithms for solving them. This type of problems has applications in telecommunications, vehicle routing, network design, facility location, etc. From the theoretical point of view, the interest of studying the MST lies in its inherent particularity as a mathematical object. The MST problem considers a set of vertices which need to be all connected in the best possible way through the use of edges or arcs with an associated weight. This problem can be solved exactly in polynomial time. This can be done using greedy algorithms as the ones proposed by Kruskal (1956) and Prim (1957). From the practical point of view, as noted above, the connecting structures of the MST are of great utility in graph-related applications. Along with the traveling salesman problem, it is considered to be the basis of network systems design and a wide variety of scheduling and routing applications. Many results are known about integer programming formulations of this problem and their structure. Besides, many extensions of the MST problem have been studied, which consider other constraints in addition to the connectivity ones. Among these additional constraints the most common are the capacity constraints, as they are present in many real life applications and also in many problems that have the MST as a subproblem. Capacity constraints can be useful to model different types of situations. Most of them arise when the tree has a root, or special vertex, from which some communication flow must be sent (or received) to/from the rest of vertices. Depending on the situation they model, capacity constraints may be expressed in many ways. For instance, as a parameter over the links in the graph, when a limit exists on the flow that can circulate on each of the arcs of a tree. Also as a vertex degree limit, as a maximum number of links between two vertices, or as a maximum number of vertices on each of the branches of the rooted tree. Depending of how we express such capacity constraints we obtain different extensions of the problem. Among such extensions we can mention the k-minimum spanning tree, the degree-constrained minimum spanning tree, the hop constrained minimum spanning tree, and the capacitated minimum spanning tree. The k-minimum spanning tree problem deals with finding the MST which connects at least k vertices, while in the degree-constrained minimum spanning tree the number of edges connecting any vertex in the resulting graph is limited. When we are interested in trees with a limited depth, we talk about the hop constrained minimum spanning tree. In this thesis we focus on the Capacitated Minimum Spanning Tree (CMST), an extension of the MST which considers a central or root vertex which receives and sends commodities (information, goods, etc) to a group of terminals. Such commodities flow through links which have capacities that limit the total flow they can accommodate. These capacity constraints over the links result of interest because in many applications the capacity limits are inherent. We find the applications of the CMST in the same areas as 2
n 0 n 1 n 2 n 3 n 4ZZ n 5QQQ n 6 n 7 n 8 n 9 X X n 10 n 11 n 12 Z Z n 13 n 14 @ @ n 15 n 16 n 17 n 18 n 19 @ @ n 20 n 21 ZZ n 22 @ n 23Z Z n 24 n 25 a) MST Example n 0 n 1 6 n 2 ) n 3 n 4ZZ~ n 5QQQ Qs n 6 @@@@@@@@ @R n 73 n 8 @ @R n 9 / n 10 @ @I n 11 / n 12 Z Z~ n 13 n 14 n 15 * n 16 n 17 * n 18 n 19 @ @I n 20 * n 21 - n 22 AAAAAA AU n 23 @ @I n 24 n 25 7 b) CMST Example capacity = 5 Figure 1: MST and CMST solution comparison the applications of the MST; telecommunications network design, facility location planning, and vehicle routing. The CMST arises in telecommunications networks design when the presence of a central server is compulsory and the flow of information is limited by the capacity of either the server or the connection lines. Its study also results specially interesting in the context of the vehicle routing problem, due to the utility that spanning trees can have in constructive methods. As it is well known, the best heuristics for the vehicle routing problem from the point of view of the worst case behavior are based on the use of spanning trees (Christofides 1976). The same idea has also been successfully transferred to arc routing problems (Frederickson, Hecht, and Kim 1976) and it has already been shown how solving the CMST can help in the solution of capacitated arc routing problems (Amberg, Domeschke, and Voß 2000). By the simple fact of adding capacity constraints to the MST problem we move from a polynomially solvable problem to a non-polynomial one (See Figure 1). Its theoretical interest and applications, make the CMST, a problem of profound interest. Because the CMST is NP-hard, it is very difficult to find provable optimal solutions with exact methods. That explains why heuristic methods have been widely used in many of the works previous to this thesis. Nonetheless, there are also many exact methods, some of them with fairly good results. Given the difficulty of the CMST, our capability of solving different sets of instances relies to a large extent on our capability of proposing tight formulations. In this context, one further difficulty which limits the sizes of the instances that can be successfully addressed is the number of variables that the tighter formulations involve. From this point of view, finding an equilibrium between the tightness of the formulation and its memory requirements may become crucial. Another issue that becomes critical from an algorithmic point of view, 3
of minimum cost flow problems. They also proposed an overall additive lower bounding procedure, which was included within a branch and bound algorithm. A branch and bound algorithm was developed by Hall (1996) using the undirected version of the formulation by Gavish (1985). In this formulation arcs aij = (i, j) are replaced by edges eij = (i, j). The algorithm was used to solve instances for the general case as well as for the UD case. It incorporates a cutting plane method in which multistar and rootcutset inequalities are incorporated. These strong inequalities are separated using heuristic methods based on the contraction of vertices over the fractional graph induced by the solution of the LP relaxation of the model. The used valid inequalities are based on the previous polyhedral study of Araque, Hall, and Magnanti (1990), where it is shown that under certain conditions, multistar and rootcutset inequalities are facet defining. Zhang (1993) proved similar results but for the directed version of such inequalities. A review of directed formulations at that time can be found in Gouveia (1993). Based on the flow formulation, Gouveia (1995a) developed the 2n-formulation for the CMST. Using capacity indexed variables and following the idea of the flow conservation rules, Gouveia presented a binary formulation with 2nconstraints and Qn2variables. He also proposed valid inequalities and four solution methods based on Lagrangean relaxation. Two different types of test instances were introduced for the UD case. Such test instances became a standard, which started to be used by other researchers. Using the same benchmark instances has helped to compare the performance of the different algorithms. A complete description of those instances is given in Chapter 5. Gouveia and Martins (2000) presented another binary formulation, the hop indexed formulation, also based on the flow formulation. Valid inequalities based on the GSE inequalities were presented as well as a heuristic separation method. A cutting plane algorithm was used to solve the LP relaxation of the formulation obtaining fairly good results. A comparison between different types of formulations and methods was presented in that work. Using the same formulation, Gouveia and Martins (2005) enhanced their previous cutting plane algorithm using stronger valid inequalities as well as a new separation method that gave improved results. In Chapter 2 we present a more extensive review of such formulation. A different formulation for the CMST, the q-arb formulation proposed by Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008), is based on a type of arborescence structures called q-arbs which are used to define the variables. The model is solved using a branch-and-cut-and-price algorithm. Using this algorithm, many of the best known solutions of the test instances were improved or confirmed to be optimal. To the best of our knowledge, at present, such algorithm still produces the best results among all exact methods. 1.3 Heuristic methods Because of the theoretical and empirical difficulty of the CMST, many approximate solution methods have been developed to find upper bounds for the problem. Many of these methods include heuristics, metaheuristics and other approaches that have shown to be able to find good feasible solutions for the CMST. Among the different heuristics that have been developed for the CMST we can distinguish two types: Constructive heuristics, which build a solution, and improvement heuristics, which start with a given solution and try to improve it. Among constructive algorithms we can mention the modified versions of Prim’s, Kruskal’s and Vogel’s approximation algorithm 10
for the MST (Chandy and Russell 1972; Kershenbaum 1974). Modified Prim and modified Kruskal algorithms work as their original version, but include capacity checks to avoid the inclusion of edges that violate the capacity constraint. Vogel’s approximation algorithm works on a cost matrix which is modified using a trade-off function that considers the first and second closest vertex of every terminal. The above mentioned construction algorithms focus on arcs. In contrast, Sharma and El- Bardai (1970) and McGregor and Shen (1977) designed construction algorithms focused on vertices. The procedure in Sharma and El-Bardai (1970) uses polar coordinates to create clusters of vertices. Polar coordinates are estimated using the root as the main reference. A greedy method considering capacity constraints is used to build the solutions. McGregor and Shen (1977) proposed a vertex contraction procedure. When two vertices are selected to be linked by an edge such vertices are contracted and replaced by one new vertex and distances to other vertices are recomputed. Infeasible contractions of vertices are not allowed. Kershenbaum (1974) designed a heuristic based on Kruskal’s modified algorithm, that assigns weights to terminals. These weights are used to compute a modified cost matrix which is used to build solutions. One of the most important heuristic, among the improvement ones, is the one by Esau and Williams (1966). The initial solution for this procedure is the star tree (all terminals are subroots) which is subject to improvement using a savings strategy. It is simple and fast, and the quality of solutions is good. Due to the algorithm’s efficiency and simplicity, many other authors have developed enhanced versions. Whitney’s savings heuristic (1970) is very similar to the Esau-Williams algorithm. The starting solution is the same and the only difference lies in the savings strategy criterion used in the improvement phase. While Esau-Williams considers for replacement only the edges directly connected to the root, Whitney’s procedure considers all the edges in the current solution. The algorithm by Lee and Atiquzzaman (2005) generates an initial solution using Esau-Williams and then applies a local search based on vertex exchange. Battarra, ¨ Oncan, Altinel, Golden, Vigo, and Phillips (2011) presented a genetic algorithm for setting the parameters of the Esau-Williams algorithm. Gavish and Altinkemer (1986) proposed a parallel savings heuristic also based on Esau- Williams. In this heuristic multi-exchange of edges is allowed while in Esau-Williams only a pair of edges is exchanged at each step. Unfortunately, this algorithm has the tendency to produce solutions with a big number of s-trees with wasted capacity. For that reason Gavish (1991) introduced dummy vertices to cleverly control the maximum number of matches allowed at each iteration and thus reduce the number of s-trees with wasted capacity. Another important and natural improvement heuristic is to compute the MST of the s-trees which are part of the solution obtained by a construction algorithm. Esau and Williams (1966) and Whitney (1970) used such an approach to improve the solution when their algorithm is unable to find further improvement. This improvement procedure can be applied to any feasible solution. The improvement heuristic by Elias and Ferguson (1974), also based on Esau-Williams, starts using the MST solution of the problem instead of the star tree. The initial solution is infeasible (if it is feasible, then it is optimal) and unused edges replace edges in the current solution. Instead of using a savings strategy a least cost strategy is used. The algorithm stops when a feasible solution is found. 11
Karnaugh (1976) designed a second order greedy algorithm for the CMST. Second order algorithms create subproblems modifying the original model (changing data or including constraints), which are solved using a heuristic procedure. In that work the cost matrix is perturbed at each step and the resulting subproblem is solved with a modified version of Esau-Williams. An inhibition procedure is also included to help in the diversification of solutions. Martins (2007) proposed an enhanced second order algorithm based on Esau-Williams. The difference with a second order algorithm, is that the enhanced version is able to drop some of the previously defined constraints to find improved solutions. Dropped constraints are included in a tabu list to avoid local optima. As metaheuristics started to appear, many were applied to the CMST. One of the first attempts was done by Amberg, Domeschke, and Vob (1996) who used simulated annealing and tabu search. Their algorithm considers two neighborhoods: Vertex exchange and vertex shifting. Using also tabu search Sharaiha, Gendreau, Laporte, and Osman (1997) developed a procedure where the explored neighborhood is related to subtrees. Infeasible solutions (according to capacity) are allowed and an aspiration criterion is also applied. Ahuja, Orlin, and Sharma (2001) developed another tabu search algorithm that included a new type of neighborhood search structures. The new structures are based on neighborhoods previously defined in Amberg, Domeschke, and Vob (1996) and in Sharaiha, Gendreau, Laporte, and Osman (1997) and include vertex shifting, vertex exchange and subtrees shifting. The difference lies in the fact that the neighborhoods are explored using a cyclic multi-exchange strategy. Using a customized improvement graph, the algorithm is able to find cyclic multiexchanges to improve the solution. Further improvements of this algorithm were carried out in Ahuja, Orlin, and Sharma (2003) by creating a composite very large scale neighborhood in which cyclic multi-exchange improvements are found. To the best of our knowledge, the best heuristic results are obtained by this algorithm, which was applied both to UD and non-UD instances. Combining tabu and scatter search, Fern´andez, D´ıaz, and Ruiz (2005) designed a heuristic in which initial solutions are generated using a randomized version of Esau-Williams. Two arc related neighborhoods are explored during the tabu search and solutions are combined during the scatter search phase to create a support graph, which is transformed into a CMST solution by a vertex contraction procedure. Patterson, Pirkul, , and Rolland (1999) solved the CMST using the adaptive reasoning technique. This algorithm introduces special strategies to exploit construction neighborhoods combined with some memory functions of tabu search. The procedure is based on Esau- Williams with additional constraints that help to avoid local optima. GRASP was applied by Souza, Duhamel, and Ribeiro (2003) on the CMST. Their GRASP algorithm explores an edge exchange neighborhood and uses Esau-Williams to improve solutions. Genetic algorithms have also been used on the CMST, although with not so good results. One of the problems faced by genetic algorithms is the way solutions are coded for crossover. The predecessor coding, which is a common way to represent CMST solutions, has the difficulty that crossover can lead to infeasible offsprings. To overcome this problem Zhou, Cao, Cao, and Meng (2007) used a different encoding. On the other hand, Raidl and Drexel (2000) and de Lacerda and de Medeiros (2006) used complicated crossover techniques to obtain feasible solutions. Ant colony optimization (ACO) has been used by Reimann and Laumanns (2006), who developed a fast procedure to solve the UD case. Using a TSP savings procedure, solutions 12
for the capacitated vehicle routing problem (CVRP) are built and used to create clusters of vertices which are transformed into CMST solutions using Prim’s algorithm. A dual-primal relaxation adaptive memory programming heuristic was proposed by Rego, Mathew, and Glover (2010) to solve the CMST. This type of algorithm explores the dual solution space by incorporating cutting planes of relaxed surrogate constraints. Using tabu search and projecting dual solutions into the primal space, primal feasible solutions are obtained. Further improvement is accomplished by using a scatter search procedure. Rego and Mathew (2011) proposed a filter and fan algorithm that combines local search with tree search procedures. Diversification of the solutions is achieved by a fan procedure and a filter procedure helps to reduce the size of the search tree. The filter and fan algorithm makes use of tabu search adaptive memory as well as strategic oscillation. In addition, there are other types of approaches for finding bounds on the solution of the CMST like the one introduced by Gouveia and Paix˜ao (1991). Using clustering and decomposition techniques the original problem is transformed to obtain smaller size problems, which are solved using dynamic programming. Altinkemer and Gavish (1988) designed a heuristic algorithm based on the partitioning of a Hamiltonian tour that provides constant error guarantees for the bounds. 13
Chapter 2 Formulations and valid inequalities for the CMST In this chapter we give some preliminaries for the work we have developed in this thesis. First we present two basic formulations that use binary variables, which allow us to highlight some of the main issues related to the CMST. The chapter ends with an overview of the most used valid inequalities and their separation. Again, the aim is not to be exhaustive but to give the basis of the developments on this work. 2.1 Two basic binary formulations When modeling the CMST there are two important issues that need to be considered; connectivity of the tree and capacity constraints. An easy way to address these issues is the use of flow variables and flow conservation constraints. With such constraints we assure connectivity, while capacity issues are solved setting up an upper limit on the value of the flow variables. The formulations based on flow variables are mainly mixed integer programming (MIP) models as flow variables are essentially continuous. A common alternative to model the CMST is the use of integer (binary) variables associated with arcs in conjunction with cutset inequalities that guarantee connectivity and capacity constraints. Experience has shown that the linear relaxations (LP) of binary formulations provide tighter lower bounds than those of MIP models. Unfortunately, in binary formulations the number of constraints is exponential on the number of vertices of the problem and it is impossible to solve the CMST using the full formulation. Therefore, these constraints need to be relaxed and iteratively separated and added to the formulation. Formulations are also influenced by the CMST variant that is studied. The UD case allow for tighter formulations with the inconvenience that they are not useful or need to be adapted to solve the general case. Here we present two formulations, the first one considers the general demand case while the second one considers only the UD case. The first formulation is the classical one, commonly used by researchers to define the CMST. The second one is a three index formulation, which has been useful to develop part of the research presented in this thesis. To facilitate comprehension through this and the next chapter in some situations we will 14
abuse notation using: X i∈VX j∈V xij to express X (i,j)∈A i∈V,j∈V xij.(2.1) 2.1.1 Directed formulation A classical mathematical programming formulation for the CMST is the one proposed by Gavish (1983). In this directed formulation, arcs leave from the root towards the leaves. This formulation includes a set of inequalities based on the general subtour elimination constraints (GSE) (Malone and Bellmore 1971) to guarantee connectivity and capacity limit. The decision variables are the following: xij =1,if arc (i, j) is part of the solution, (i, j)∈Awith j∈V+ 0,otherwise. Then, the CMST is formulated as: min X i∈VX j∈V+ cijxij (2.2) s.t. X (i,j)∈A xij = 1 j∈V+(2.3) X i/∈SX j∈S xij ≥d(S) QS⊆V+,|S| ≥ 2 (2.4) xij ∈ {0,1}(i, j)∈Awith j∈V+(2.5) With equations (2.3) we guarantee that for every vertex there is only one incoming arc. Constraints (2.4) are the classical connectivity constraints, as extended by Laporte. and Nobert (1983) for the Vehicle Routing Problem (VRP) to take capacities into account. Also called bin-packing inequalities, with these constraints the connectivity of the solution is assured and the accumulated demand of the subtrees is limited so each subtree does not exceed the capacity in any solution. Recall that d(S) = P j∈S djdenotes the overall demand of the vertices of set S. The above formulation has n2variables, and a number of constraints, which is exponential on |V+|. Note that there are some variables which are not defined (i.e. arcs going from terminal vertices to the root). Additionally, it is possible to eliminate some other variables based on optimality criteria. Variants of this formulation have been also studied, like the non-directed version (Hall 1996). 2.1.2 Hop indexed formulation This formulation was presented in Gouveia and Martins (2000), and improved in Gouveia and Martins (2005). It is based on the single commodity network formulation by Gavish (1983) and applies only to the UD case. It takes into account the fact that every arc has a 15
certain depth in relation to the root. Consider an arc (i, j) with depth twhich is part of the solution. If t= 1, we have that such arc has as origin the root (i= 0) and as destination the subroot j. When t= 2 the arc (i, j) is originated at the subroot iand arrives to vertex j, which is neither the root nor a subroot. Arcs with t≥3, link vertices which are neither the root nor a subroot. Notice that the depth of a vertex is determined by the depth of its incoming arc (Figure 2.1). The following variables are defined: uijt =1,if arc (i, j) with depth tis in the solution, (i, j)∈Awith j∈V+, t = 1, ..., Q 0,otherwise zijt ≥0,The flow passing through arc (i, j), (i, j)∈Awith j∈V+, t = 1, ..., Q when this arc has depth t 0 1 2 3 4 5 6 7 8 9 10 11 15 12 13 14 15,9,5 U 11,15,4 U 10,11,3 U 3,10,2 U 0,3,1 U0,2,1 U 0,1,1 U 1,4,2 U 1,5,2 U 5,12,3 U 2,7,2 U 7,8,3 U7,6,3 U12,13,4 U 6,14,4 U Figure 2.1: Example of hop indexed variables It is important to notice that index tfor variables zand u, has values ranging from 1 to Qbecause no feasible solution would have any arc with depth greater than Q. Note that, since this formulation is used to model the UD case, the capacity constraints are in fact cardinality constraints. Therefore, in this situation the capacity gives directly the maximum depth in a subtree. Then using the previously defined variables, the hop indexed formulation is as follows: 16
Min Q X t=1 X (i∈VX j∈V+ cijuijt (2.6) s.t. Q X t=1 X (i,j)∈A uijt = 1 j∈V+(2.7) X i∈V zijt −X i∈V zji,t+1 =X i∈V Q X t=1 uijt j∈V+, t = 1, ..., Q −1 (2.8) uijt ≤zijt ≤(Q−t+ 1)uijt (i, j)∈A, j ∈V+, t = 1, ..., Q −1 (2.9) uijt ∈ {0,1}, zijt ∈0, .., Q (i, j)∈A, t ∈1, ..., Q (2.10) Constraints (2.7) are the classical ones that require there is exactly one incoming arc to every terminal and they are equivalent to (2.3) for the directed formulation. Constraints (2.8) are a generalization of the flow balance equations and also state that, if an arc (l, j) with depth tenters j, any outgoing flow would use some arc with depth t+ 1. Finally constraints (2.9) link variables and limit capacity. This formulation has 2Qn2variables. As in the directed formulation, there are variables which is possible to eliminate based on optimality criteria. 2.2 Well-known valid inequalities Many valid inequalities have been proposed for the different formulations for the CMST. Among the most important ones, we can mention the bin-packing inequalities (Hall 1996), multistar inequalities (Hall 1996; Gouveia and Lopes 2005), rootcutset inequalities (Araque, Hall, and Magnanti 1990), other based on the GSE inequalities (Gouveia and Martins 2005), and extended capacity cuts (Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade 2008). We will use the directed formulation to present these inequalities, except for the ones derived from another type of formulation. It is important to notice that many of these inequalities can be extended to different formulations. Let Pand Pddenote the convex hull of feasible solutions to the undirected and directed CMST formulations respectively. 2.2.1 Bin-packing inequalities Bin-packing inequalities apply both to the general and UD cases, and can be expressed as connectivity constraints, or as subtour elimination constraints. These inequalities have been widely used in vehicle routing and network design problems. An example of these inequalities is presented in Figure 2.2 considering Q= 5. Their expression for the general case as connectivity constraints, was given in (2.4) for the directed formulation. Their expression as a subtour elimination constraint is: X i∈SX j∈S xij ≤d(S)−MT(S)S⊆V+,|S| ≥ 2 (2.11) 17
where S⊆V+is a subset of terminals and MT(S) = ld(S) Qmrepresents the minimum number of s-trees (or the minimum number of incoming arcs) required to accommodate the demand of the vertices contained in subset S, taking into account the capacity constraint. For the UD case we have that MT(S) = l|S| Qmas d(S) = |S|. For the same case, these inequalities are facet defining for Pand Pdwhenever |S|is not a multiple of Q(Hall 1996), and (2.11) can be rewritten as: X i∈SX j∈S xij ≤ |S| − MT (S)S⊆V+,|S| ≥ 2 (2.12) or alternatively as a connectivity constraints: X i/∈SX j∈S xij ≥MT (S)S⊆V+,|S| ≥ 2 (2.13) 0 1 2 3 4 5 6 7 8 9 10 11 15 16 17 12 13 14 18 violated bin-packing inequality violated bin-packing inequality 0.5 1 Q =5 Figure 2.2: Example of violated bin-packing inequalities with UD and Q=5 Note that in the UD case MT (S) = l|S| Qm, because we have unitary demands. However, in the general case, computing MT (S) resorts to solving a bin-packing problem, which is itself a NP-hard problem. The separation problem of this type of inequalities was solved heuristically by Hall (1996) using a vertex contraction procedure over the graph induced by the fractional solution. 2.2.2 Multistar inequalities The multistar inequalities were first introduced by Araque, Hall, and Magnanti (1990) for capacitated tree and capacitated routing problems. These inequalities are capacity-connectivity constraints, that have different expressions depending on the type of demand considered on the terminals (UD case or general). In Figure 2.3, an example of this family of inequalities is presented. The example considers a capacity parameter of Q= 5. For the UD case these 18
inequalities are facet defining under certain conditions (Hall 1996) and have the following form: X i∈SX j∈S Qxij +X i∈S i6=0 X j /∈S i6=0 (xij +xji)≤ |S|(Q−1) S⊆V+,|S| ≥ 2 (2.14) 0 1 2 3 4 5 6 7 8 9 10 11 15 16 17 12 13 14 18 violated multistar inequality violated multistar inequality 0.5 1 Q =5 Figure 2.3: Example of violated multistar inequalities with UD and Q=5 The right hand side of (2.14) represents the maximum potential number of arcs between vertices in Sand leaving/entering S. The first term in the left hand side considers the arcs between vertices in Sand the second term refers to arcs leaving/entering Sthat do not come from the root. In total, if all the vertices in Sare subroots, then at most |S|(Q−1) arcs can leave S. If two vertices in Sare connected by one arc, it is clear that one of such vertices is not a subroot. Therefore the number of potential outgoing arcs from Sis reduced by Q. For the general demand case, Hall (1996) proposed a generalization based on the weighted version of (2.14). Gouveia and Lopes (2005) proposed another version of these inequalities as well as a reinforcement procedure to improve them. They are expressed as follows: X i/∈SX j∈S (Q−di)xij −X i/∈SX j∈S dixji ≥d(S) The left side of these inequalities represents the available capacity entering the set of vertices in S. This capacity has to be enough so as to satisfy the sum of the demands of the vertices in Splus the demand of the vertices outside Sdirectly connected with an outgoing arc from S. To separate these inequalities, Hall (1996) used a vertex contraction procedure over the graph induced by the fractional solution. Letchford and Salazar-Gonz´alez (2006) presented an exact separation procedure for these inequalities. The exact separation is achieved by creating an auxiliary graph and then solving a maximum flow-minimum cut problem. 2.2.3 Rootcutset inequalities The rootcutset inequalities were first proposed by Araque, Hall, and Magnanti (1990). Hall (1996) developed the version of these inequalities for the UD case while Zhang (1993) presented them for the general case. These inequalities help to enforce the connectivity of the 19
Enhancing the subroot multistar inequalities Proposition 2. For any given set S⊂V+the following enhanced subroot multistar inequality is valid for the CMST: X k∈SX j∈S djyjk +X k/∈SX j∈S (Q−dk)xkjk +X k/∈SX i/∈S i6=kX j∈S (Q−dk−di)xijk −X k/∈SX i∈SX j /∈S djxijk ≥d(S) (3.19) Proof: The proof of the validity of these inequalities is similar to that of inequalities (3.10). We only have to replace inequality (3.13), the flow entering the subroots in S, by the equality: z0k=X j∈V+ djyjk (3.20) since the flow entering a subroot k∈Kshould be equal to the demand of kplus the sum of the demands of the non-subroot vertices assigned to k. The resulting inequality is: X k∈SX j∈V+ djyjk +X i∈R1\SX j∈SX k∈K\S (Q−dk)xijk +X k∈K\SX i∈R2\SX j∈S (Q−di−dk)xijk ≥X j∈S dj+X k∈K∩SX j /∈S djyjk +X j∈R∩SX i/∈SX k∈K\S dixjik (3.21) which after some manipulation leads to: X k∈SX j∈S djyjk +X i∈R1\SX j∈SX k∈K\S (Q−dk)xijk +X k∈K\SX i∈R2\SX j∈S (Q−di−dk)xijk ≥X j∈S dj+X j∈R∩SX i/∈SX k∈K\S dixjik (3.22) that is equivalent to (3.19). Note that we can derive inequalities (3.19) from inequalities (3.10) by replacing P k∈S Qykk with P k∈SP j∈V+ djyjk and since, X j∈V+ djyjk ≤Qykk it is clear that (3.19) is stronger than (3.10). 26
3.2.2 s-tree multistar inequalities Using variables of the subroot formulation, another family of valid inequalities associated with s-trees can be derived. This family of inequalities arises from the disaggregation of inequalities (3.10). Proposition 3. For any given set S⊂V+and k∈V+\S, the following s-tree multistar inequality is valid for the CMST: X j∈S (Q−dk)xkjk +X i/∈S i6=kX j∈S (Q−dk−di)xijk −X i∈SX j /∈S djxijk ≥X j∈S djyjk (3.23) Proof: The result follows since for any s-tree rooted in kthe overall capacity Qmust cover the demand of k, of all vertices directly connected to kand at a distance 2or more from k. These are respectively the terms in the left hand side of inequalities (3.23). 3.2.3 Subroot rootcutset inequalities Using subroot variables a modified version of the rootcutset inequalities (2.16) is obtained and has the following form: MT (S)+1 MT (S)X k∈S ykk +MT (S) + 1 MT (S)X k/∈SX i∈¯ BX j∈S xijk S⊂V+,|S| ≥ 2 (3.24) +X k/∈SX i∈BX j∈S xijk ≥MT(S) + 1 where MT (S) is the minimum number of subroot vertices required to handle the accumulated demand of the vertices in S,B=ni /∈S|ld(S)+di Qm> MT (S)ois the set of vertices outside Sthat if included in Swould require the inclusion of an extra subroot arc, and B=V+\ {S∪B}. 3.2.4 Other inequalities There are also other sets of valid inequalities for the subroot formulation. Here, we present a list of them, as well as a brief description: •Minimum number of subroots constraint. Proposed by Elias and Ferguson (1974) this inequality imposes the minimum number of subroots required to handle the total demand of all vertices. X k∈V+ ykk ≥&d(V+) Q'(3.25) •Inequalities to restrict the values of variables yjk, using the upper bound defined by variables ykk. yjk ≤ykk k∈V+, j ∈V+, j 6=k(3.26) 27
•Inequalities to restrict values of variables xijk, using the upper bound defined by variables yik and yjk. They state that arc (i, j) can only be part of the s-tree s-Tkonly if both vertices are assigned to the s-tree in k. xijk +xjik ≤yik (i, j)∈A, i ∈V+, k ∈V+, i 6=k(3.27) xijk +xjik ≤yjk (i, j)∈A, j ∈V+, k ∈V+, j 6=k(3.28) •Constraints that relate the values of variables yjk with those of variables associated with arcs leaving the subroot. yjk ≤X i∈V+ xkik k∈V+, j ∈V+, j 6=k(3.29) 3.2.5 Solution algorithm for the subroot formulation Next we propose a cutting plane algorithm to for the CMST. It is an iterative algorithm in which each iteration considers a subproblem with only a subset of the constraints of formulation (3.1)-(3.8), and solves its linear programming (LP) relaxation. In addition, at each iteration of the algorithm, separation procedures are applied to identify inequalities of formulation (3.1)-(3.8), which are violated by the current LP solution. All violated inequalities found are incorporated into the current subproblem. When the separation procedures do not detect any violated inequalities, then a variable elimination procedure is applied. The algorithm stops when no cuts are found and no variable is eliminated, or after a certain number of iterations without improvement. A pseudocode for the algorithm is presented in Algorithm 1. The initial subproblem includes constraints (3.2), (3.3), (3.5) and (3.25). Constraints (3.27) and (3.28) are not considered because they are dominated by s-tree inequalities (3.23). At each iteration we try to separate violated inequalities of types (3.10), (3.23) and (3.24). Variables Elimination The algorithm includes a two variable elimination procedures. The first is based on optimality criteria, while the second is based on a lower bound (LB), an upper bound (UB) and reduced costs. The LB is obtained computing a MST with the minimum subroot vertices constraint (3.25). The UB is obtained by using a heuristic method (UB =h(V, A, d, c)). Let TLB and TUB denote the trees which produce the bounds LB and UB, respectively. Using an optimality criterion, variables xijk, i ∈V, j ∈V+, k ∈V+such that cij ≥c0j are eliminated. The reason is that, if the arc (i, j) is part of an optimal solution, there is an alternative optimal solution that does not include this arc (Gouveia and Martins 2000). In other words, the arc (i, j) can be always replaced by the arc (0, j) without deteriorating the objective function value, since there is no limit on the number of subtrees. Also based on a optimality criteron, variables xijk i∈V, j ∈V+, k ∈V+such that cij ≥ckj, can be eliminated for the same reason as in the previous case. This time the rationale is applied to the arcs associated with the s-tree rooted in k. If in an optimal solution, the arc (i, j) is part of the s-tree rooted in k, arc (i, j) can be always replaced by the arc (k, j), without deteriorating the objective function value. Finally using the LB and UB, we can eliminate 28
the variables xijk with i∈V, j ∈V+, k ∈V+such that LB +cij −cpj > UB, where p=pLB(j) is the predecessor of vertex jin TLB. For non-UD instances there is a third elimination procedure which eliminates variables xijk, i ∈V, j ∈V+, k ∈V+with di+dj>=Qor dk+di+dj>=Q Auxiliary network for the separation of inequalities Before presenting the separation procedures for inequalities (3.19), (3.23) and (3.24) we introduce some additional notation. In each case N(¯x, ¯y) = (V , A) denotes the auxiliary graph which is used for the separation procedure. It always contains all the vertices and arcs of the subgraph induced by the fractional solution (¯x, ¯y). It also always contains two pseudovertices, a source vertex s0and a sink vertex u0. Depending on the case, N(¯x, ¯y) will contain additional vertices and arcs. In most cases the separation resorts to finding a minimum cut between s0and u0in the corresponding network. Separation of subroot multistar inequalities As stated in Theorem 3 in Letchford and Salazar-Gonz´alez (2006) there is an exact separation algorithm for inequalities (3.9), based on the solution of a maximum flow problem on an auxiliary network induced by the fractional solution. Extending this theorem, subroot multistar inequalities can also be separated exactly in a similar way, using the auxiliary network N(¯x, ¯y). For this family of inequalities we include in V, the original set of terminals V+, a source vertex s0, a sink vertex u0, and a set of artificial vertices Vjassociated with each vertex j∈V+. For a given j,Vjcontains a copy kjof each subroot ksuch that ¯yjk >0, j6=k. That is, Vj={kj:yjk >0}. Then, V=V+∪ {s0, u0}∪{Vj, j ∈V+}.Acontains arcs of the following types: (i) arcs (s0, k), with k∈V+; (ii) arcs (k, u0) , with k∈V+; (iii) arcs linking two original vertices i, j ∈V+; (iv) arcs (j, kj) linking original vertices j∈V+ with artificial vertices kj∈Vj; and, arcs (kj, i) connecting artificial vertices kj∈Vjand original vertices i∈V+(i6=j). The weight wij associated with each arc a∈Adepends on the type of arc. The weight of the arcs between the source s0and the original vertices k∈V+is given by ¯ykk +Pi∈V+P j∈V+ dj¯xijk +P i∈V+ dk¯yki. The weight of the arcs linking original vertices k∈V+ with the sink u0is defined as dk+P j∈V+ dj¯yjk. The weight of the arcs linking two original vertices i∈V+,j∈V+is given by (Q−di)¯xkik +P j∈V+ di¯xjik −di¯yik. The arcs linking original vertices j∈V+with artificial vertices kj∈Vjhave a weight of Q. Finally, the weight of the arcs between artificial vertices kj∈Vjand original vertices i∈V+(i6=j) is defined as (Q−dk−di)¯xijk −dj¯xijk. Figure 3.1 illustrates how the weights of the arcs (i, j)∈Aare defined. On this network we find the minimum cut S⊆Vwith u0∈Sand s0/∈S. Then, there is a multistar inequality violated by the fractional solution (¯x, ¯y), if and only if, the capacity of S,W(S), is smaller than: L=X i∈V+ di+X k∈V+X i∈V+X j∈V+ dj¯xijk +X k∈V+X j∈V+ ¯yjk . 29
s0k u0 i kj j - ? - QQQQQQQs 3 - > ¯ykk +X i∈V+X j∈V+ dj¯xijk +X i∈V+ dk¯yki dk+X j∈V+ dj¯yjk (Q−di)¯xkik +X j∈V+ di¯xjik −di¯yik X j∈V+ dj¯xijk (Q−dk−di)¯xijk −dj¯xijk Q Figure 3.1: Auxiliary network for the exact separation of subroot multistar inequalities The subset of vertices S⊆V+which produces a violated inequality (3.19) is given by S=S∩V+. Separation of the s-tree multistar inequalities The separation for the family of inequalities (3.23) is solved exactly in a similar way to the subroot multistar ones (3.19). In this case we generate a different network Nk(¯x, ¯y) = (V , A) for each vertex kwith ¯ykk >0 in the fractional solution (¯x, ¯y). For this family of inequalities we include in V, the subroot k, the terminals Vk={j:yjk >0, j ∈V+}, a source vertex s0, and a sink vertex u0. Then, V=Vk∪ {k, s0, u0}.Acontains arcs of the following types: (i) arcs (s0, k), where k∈V+is a subroot; (ii) arcs (k, j) connecting subroot kand terminal j∈Vk; (iii) arcs (j, u0) linking terminal vertices j∈Vkfor some subroot kwith the sink u0; and, (iv) arcs (i, j) linking two original vertices i, j ∈Vkfor some subroot k. The weight wij associated with each arc (i, j)∈Adepends on the arc. The weight of the arcs between the source s0and subroot kis given by Q. For arcs between kand vertices j∈Vk,wkj is defined as (Q−dk)xkjk. For the arcs linking vertices j∈Vkwith the sink u0their weight is defined as P j∈V+ dj¯xijk. The weight of the arcs linking two vertices i∈Vk, j∈Vkis (Q−dk−di)¯xijk −dj¯xijk. Figure 3.2 shows how the weights for arcs (i, j)∈Aon the auxiliary network N(¯x, ¯y) are defined. Then for every vertex kwith ¯ykk >0 we find the minimum cut S⊆Vwith u0∈S and s0/∈Susing the auxiliary graph Nk(¯x, ¯y). Then, there is a s-tree multistar inequality violated by the fractional solution (¯x, ¯y), if and only if, the capacity of S,W(S), is smaller than: L=X j∈S djyjk . In this case, the subset of vertices S⊆V+which produces a violated inequality (3.23). is given by S=S\u0. 30
s0k u0 i j - ? - 3 > Q dk+X j∈V+ dj¯yjk (Q−dk)¯xkik X j∈V+ dj¯xijk (Q−dk−di)¯xijk −dj¯xijk Figure 3.2: Auxiliary network for the exact separation of s-tree multistar inequalities Separation of the subroot rootcutset inequalities The separation problem for the subroot rootcutset inequalities is solved heuristically using the network N(¯x, ¯y)=(V , A) induced by the fractional solution ¯x, ¯y. The set of vertices V includes the terminals V+, a source vertex s0, and a sink vertex u0(V=V+∪ {s0, u0}). A contains arcs of the following types: (i) arcs (s0, k), where k∈V+is a subroot; (ii) arcs (i, j) connecting terminal i∈V+with terminal j∈V+; and (iii) arcs (j, u0) linking terminal vertices j∈V+with the sink u0. Weights wij are defined using P k xijk, (i, j)∈A. In this case we apply a vertex shrinking procedure to N(¯x, ¯y), to find violated subroot rootcutset inequalities. It is important to notice that in any feasible solution of the CMST, every vertex in V+has only one predecessor (Figure 1) since we assume that the root is the origin. Vertices are shrunk with their predecessor and the shrinking starts by the leaves (vertices with no successors) and continues until all non subroot vertices have been shrunk. Every time two vertices are shrunk, a new artificial vertex containing a list of the shrunk vertices and its accumulated demand is created. Using the list of vertices and the accumulated demand in the artificial vertex we check for violated subroot rootcutset inequalities. Since in fractional solutions is common to find vertices with two or more predecessors, the shrinking is done with the vertex with greater wij value (Figure 3.3). 0 1 2 3 5 4 65 0.67 0.33 0.33 0.34 0.67 0.33 0.66 0.34 0.33 0 1,2 3 4,5 6 1 0.67 0.67 0.33 0.34 0.33 Figure 3.3: Vertex shrinking for the separation of subroot rootcutset inequalities 31
3.3 Subroot hop indexed formulation. This new formulation results from the combination of subroot and hop indexed variables (described in Section 2.1.2) and is designed to solve the UD case. It has two types of variables, yvariables which are the same as in the subroot formulation, and xvariables, which are arc variables that take into account the subroot of the s-tree they belong to and its depth relative to the root. The new model has an increased number of variables Q·n3+n2 and we will refer to this new formulation as Subroot Hop Indexed Formulation (SRHIF). The subroot hop indexed variables are defined as follows: yjk =1,if vertex jbelongs to the s-tree rooted at vertex k, 0,otherwise. xt ijk =1,if arc (i, j) is in depth tin the subtree rooted at vertex k, 0,otherwise. min Q X t=1 X k∈V+X (i∈VX j∈V+ cijxt ijk (3.30) s.t. X k∈V+ yjk = 1 j∈V+(3.31) Q X t=1 X k∈V+X i∈V+ xijk =yjk j, k ∈V+(3.32) ykk =x1 0kk j∈V+(3.33) Q X t=1 xt ijk +X t=1,..,Q xt jik ≤yik (i, j, k)∈V+i6=j, j 6=k(3.34) Q X t=1 xt ijk +X t=1,..,Q xt jik ≤yjk (i, j, k)∈V+i6=j, j 6=k(3.35) X j∈V+ j6=k djyjk ≤(Q−dk)ykk k∈V+(3.36) Q X t=1 X k∈V+X i/∈S∪{0}X j∈S xt ijk ≥&d(S) Q'S⊆V+(3.37) X k∈V+ ykk ≥&d(V+) Q'(3.38) yjk ∈ {0,1}j∈V+, k ∈V+(3.39) xt ijk ∈ {0,1}a= (i, j)∈A, k ∈V+, t ∈1, .., Q (3.40) With equation (3.31) we assign each vertex to a subroot and with (3.32) we guarantee that there is one incoming arc for each vertex. Equations (3.33) imposes subroot vertices to 32
be directly connected to the root. Inequalities (3.34) and (3.35) state that an arc can only be used only if both, its origin and end vertices, belong to the same s-tree. The capacity is controlled by constraints (3.36) and the connectivity of the solution is guaranteed by (3.37). For this new formulation we can adapt the different families of inequalities which we have already presented for the subroot formulation in the previous section. The coefficients of the multistar (3.19), s-tree multistar (3.23) and rootcutset (3.24) inequalities are improved with this new formulation. Additionally, a modified version of the GSEh inequalities (2.17) from Gouveia and Martins (2005) using the subroot hop indexed variables, is shown. Using subroot hop indexed variables, adapted multistar inequalities derived from (3.19) are expressed as follows: X k∈SX j∈S yjk + Q X t≥2X k/∈SX i/∈SX j∈S (Q−t+ 1)xt ijk −X t≥3X k/∈SX i∈SX j /∈S xt ijk ≥ |S|S⊂V+,|S| ≥ 2 (3.41) Using subroot hop indexed variables, s-tree multistar inequalities (3.23) have the following expression: X j∈S (Q−dk)x2 kjk + Q X t≥3X i/∈SX j∈S (Q−t+ 1)xt ijk −X i∈SX j /∈S djxt ijk ≥X j∈S djyjk S⊂V+,|S| ≥ 2 (3.42) Another family of inequalities that can be expressed using the subroot hop indexed variables are subroot rootcutset inequalities (3.24), that have the following expression: MT + 1 MT X k∈S ykk +MT + 1 MT Q X t≥2X k/∈SX i∈AX j∈S xt ijk S⊂V+,|S| ≥ Q(3.43) + Q X t≥2X k/∈SX i∈BX j∈S xt ijk ≥MT + 1 GSEh inequalities (2.17) can also be rewritten using the subroot hop indexed variables. The subroot GSEh inequalities have the following expression: X t≥h+1 X k∈V+X i∈SX j∈S xt ijk ≤ |S| − |S| Q−h+ 1S⊆V+,|S| ≥ 2,1≤h≤Q−1 (3.44) As in the original inequalities (2.17), the right hand side of the equation represents the maximum number of arcs considering the cardinality of S(|S|) and a fixed depth h. They are used to enhance the connectivity of the solution by finding GSE inequalities at different depths h. If we compare the previous inequalities (3.44) with (2.15), is easy to see that the last ones are a special case of the GSEh inequalities for h= 1. As the modified subroot rootcutset inequalities (3.43) are a modified version of (2.15), we can conclude that (3.43) are also a special case of the GSEh inequalities for h= 1, which have been subjected to a lifting procedure. 33
Hop ordering inequalities from Gouveia and Martins (2005) can also be expressed in terms of the subroot hop indexed variables. They have the following form: X k∈V+X m∈V m6=j xt mik ≥X k∈V+ xt+1 ijk (i, j)∈V+, t = 1, .., Q −1 (3.45) As mentioned in Section 2.2, these inequalities state that an arc (i, j) can be in depth t+ 1 only if there is an entering arc (m, i) in depth t. 3.3.1 Solution algorithm for the subroot hop indexed formulation We also propose a cutting plane algorithm for the CMST. It is an iterative algorithm in which each iteration considers a subproblem with only a a subset of constraints of formulation (3.30)-(3.40), and solves its linear programming (LP) relaxation. The initial subproblem includes constraints (3.31), (3.32), (3.36) and (3.38). Constraints (3.34) and (3.35) are not considered because they are dominated by s-tree inequalities (3.42). In addition, at each iteration, we try to separate violated inequalities of types (3.41), (3.42), (3.44), (3.43) and (3.45), violated by the current LP solution. All violated inequalities found are incorporated to the current subproblem. When the separation procedures do not detect any violated inequalities then a variable elimination procedure is applied. The algorithm stops when no cuts are found and no variable is eliminated, or after a certain number of iterations without improvement. The pseudocode for the algorithm is almost the same as the one for the subroot formulation, we just need to replace line 17 from Algorithm 1 by: “Separate violated extended subroot multistar, extended subroot rootcutset, extended s-tree multistar, extended GSEh and extended hop ordering inequalities” Variables Elimination As in the the subroot formulation, the algorithm includes two procedures to reduce the number of variables for the subroot hop indexed formulation. The procedures are a slight adaptation of the ones for the subroot formulation. The UB and LB are calculated as mentioned in Section 3.2.5. Again, using an optimality criterion, variables xijkt, i ∈V, j ∈V+, k ∈ V+, t ∈ {1, ..., Q}such that cij ≥c0jare eliminated as well as variables xijkt i∈V, j ∈ V+, k ∈V+such that cij ≥ckj. The reasons for these eliminations follow are the same ones stated in Section 3.2.5. Additionally, variables xkjkt, k ∈V, j ∈V+, t 6= 2 are eliminated, since the arcs leaving a subroot can be only at depth 2. the previous case. This time the rationale is applied to the arcs associated with the s-tree rooted in k. If in an optimal solution, the arc (i, j) is part of the s-tree rooted in k, arc (i, j) can be always replaced by the arc (k, j), without deteriorating the objective function value. Finally using the LB and UB, we can eliminate the variables xijkt with i∈V, j ∈V+, k ∈V+, t ∈ {1, ..., Q}such that LB +cij −cpj > UB, where p=pLB(j) is the predecessor of vertex jin TLB. For non-UD instances there is a third elimination procedure which eliminates variables xijk, i ∈V, j ∈V+, k ∈V+with di+dj>=Qor dk+di+dj>=Q The initial subproblem includes constraints (3.31), (3.32), (3.36) and (3.38). At each iteration we try to separate violated inequalities of types (3.41), (3.42) and (3.43). 34
0k u0 i kj j - ? - QQQQQQQs 3 > ¯ykk +X j∈V+ ¯yjk +X t>=2 X i∈V+X j∈V+ ¯xt ijk +X i∈V+ ¯yki 1 + ¯ykk +X j∈V+ ¯yjk +X j∈V+ ¯x2 kjk (Q−2)¯x2 kik +X t>=3 X j∈V+ ¯xt jik −¯yik X t>=3 X j∈V+ ¯xt ijk X t>=3 (Q−t+ 1)¯xt ijk −X t ¯xt ijk Q Figure 3.4: Auxiliary network for the exact separation of extended subroot multistar inequalities The separation procedures for inequalities (3.41) is similar to the one used for (3.19). For this family we also use the network induced by the fractional solution N(¯x, ¯y) = (V , A). The set of vertices Vand the set of arcs Aare the same as the ones defined for the network to separate inequalities (3.19). Remember that V=V+∪ {s0, u0}∪{Vj, j ∈V+}. The weight wij associated to each arc a∈A, is defined using the customized graph presented in Figure 3.4. On this network we find the minimum cut S⊆V+with u0∈Sand s0/∈S. Then, there is a multistar inequality violated by the fractional solution (¯x, ¯y), if and only if, the capacity of S,W(S), is smaller than: L=X i∈V di+X k∈V+X i∈V+X j∈V+ dj¯xijk +X k∈V+X j∈V+ ¯yjk . Again, in this case, the subset of vertices S⊆V+which produces a violated inequality (3.41). is given by S=S∩V+. The separation problem for the adapted s-tree multistar inequalities (3.42) is solved exactly in a similar way to inequalities (3.23). In this case we also generate a network Nk(¯x, ¯y)=(V , A) for each vertex kwith ¯ykk >0 in the fractional solution (¯x, ¯y). The set of vertices Vand the set of arcs Aare the same as the ones used for inequalities (3.23). Remember that V=Vk+∪{k, s0, u0}. The weight wij associated with each arc (i, j)∈Ais defined using the auxiliary graph presented in Figure 3.5. For every vertex kwith ¯ykk >0, we find the minimum cut S⊆Vwith u0∈Sand s0/∈Susing the corresponding auxiliary graph Nk(¯x, ¯y). Then, there is a s-tree multistar inequality violated by the fractional solution (¯x, ¯y), if and only if, the capacity of S,W(S), is smaller than L=X j∈S djyjk 35
is no longer met. Otherwise, in line 31 the next candidate vertex is considered to become a subroot. procedure direct assignment Input:X, V, E, Q, d, c Output: Assignment array a 1ai←0, si←Q, for i= 1, . . . , n; 2Initialize VERTICES with vertices 1, . . . , n sorted in increasing order of X; 3Initialize CANDIDATE with vertices 1, . . . , n sorted in increasing order of X; 4Initialize empty list SUBROOT; 5i←FIRST(VERTICES); 6while i6=nil do /* Try to assign ito an existing subroot */ 7k←FIRST(SUBROOT); 8while k6=nil and ai== 0 do 9if sk≥dithen 10 ai←k; 11 sk←sk−wi; 12 Remove ifrom CANDIDATE list; 13 end 14 k←NEXT(SUBROOT); 15 end 16 k←FIRST(CANDIDATE); 17 while ai== 0 do /* Set a new subroot kand assign ito it */ 18 if k== ithen 19 ai←i; 20 si←Q−di; 21 Add ito end of SUBROOT list; 22 Remove ifrom CANDIDATE and VERTICES lists; 23 else if sk≥di+dkthen 24 ak←k; 25 ai←k; 26 sk←Q−dk−di; 27 Add kto end of SUBROOT list; 28 Remove kfrom CANDIDATE and VERTICES lists; 29 Remove ifrom CANDIDATE list; 30 end 31 k←NEXT(CANDIDATE); 32 end 33 i←NEXT(VERTICES); 34 end 35 return Algorithm 2: Pseudo-code for direct assignment decoder. If doubly linked lists are used for implementing VERTICES,CANDIDATE, and SUBROOT, assuming all list insertion and deletion operations can be done in O(1) time, the runtime complexity of assignment-1 is O(n2). The efficiency of this algorithm is improved by eliminating from list SUBROOT the subroots whose residual capacity becomes smaller than the smallest demand of all the vertices, after lines 11, 20, and 26. 42
4.2.2 Cost-based assignment decoder The direct assignment decoder described above focuses mostly on the capacity constraints, and makes no use of arc costs for making assignments. We now describe an alternative procedure, cost-based assignment, which does. The central idea in this decoder is to scan the vertices in increasing order of the random keys in vector Xand try to assign the scanned vertex ito its closest s-tree among the already existing ones with enough available capacity. Here, the distance from a vertex ito an s-tree s-Tkis defined by the least cij value for j∈V(s-Tk). procedure cost-based assignment Input:X, V, E, Q, d, c Output: Assignment array a 1ai←0, si←Q, for i= 1, . . . , n; 2Initialize list VERTICES with vertices 1, . . . , n in increasing order of X; 3Initialize empty list ASSIGNED; 4i←FIRST(VERTICES); 5while i6=nil do /* Try to assign ito an existing subtree */ 6Sort vertices jin ASSIGNED in increasing order of cij; 7j←FIRST(ASSIGNED); 8while j6=nil and ai== 0 do 9k←aj; 10 if sk≥dithen 11 ai←k; 12 sk←sk−dk; 13 Remove ifrom CANDIDATE list; 14 Add ito ASSIGNED list; 15 end 16 j←NEXT(ASSIGNED); 17 end 18 if ai== 0 then /* Set ias a new subroot */ 19 ai←i; 20 si←si−di; 21 Add ito ASSIGNED list; 22 end 23 i←NEXT(VERTICES); 24 end 25 return Algorithm 3: Pseudo-code for cost-based assignment decoder. Algorithm 3 gives the pseudo-code of assignment-2, the cost-based assignment procedure. In line 1, the assignment vector aand available capacity vector sare initialized. 43
Vectors aand sare similar to those used in assignment-1. The lists are initialized in lines 2 and 3. The vertices to be assigned are scanned in the loop in lines 5 to 24. At each iteration, i denotes the vertex to be assigned (initialized in line 4). In line 7 an ordered list is built using the vertices already assigned which are stored in list ASSIGNED. The loop in lines 9 to 16 assigns vertex ito the s-tree s-Tkcontaining the closest vertex j. In line 11 the available capacity at s-Tkis checked and in case sk≥di, vertex iis assigned to s-tree s-Tk(line 12). skis updated in line 13 and iis removed from list VERTICES and included in list ASSIGNED in lines 13 and 14. If there is no s-tree with available capacity to accommodate i, then iis set as a new subroot and included in list ASSIGNED (lines 20 to 23). Sorting the list of already assigned vertices according to their distance to the vertex being currently scanned (line 6) is computationally expensive. For this reason, in our implementation of this algorithm, one heap is kept for each vertex, containing the distances from that vertex to all already assigned vertices. However, for clarity, we present here the basic version of the algorithm, since it allows a simpler comparison with Algorithm 2. 4.2.3 Predecessor assignment decoder As in the previously described assignment procedures, the predecessor assignment decoder takes as input a random-key vector X, the graph structure GU= (V, E) and demands d, and returns an n-dimensional integer assignment vector aand predecessor vector p. In this procedure the central idea is to use the key to define the predecessor vertex of each terminal. For a given a tree T, the predecessor pjof a terminal j∈V+is the vertex i∈V, if the edge (i, j) is part of T((i, j)∈T) and iis in the only path from the root to j. This decoder has a preprocessing phase in which the possible predecessors of each vertex j∈V+are stored in a predecessor list for j(lj). This list does not consider the vertices which have a cost greater than or equal to the cost of connecting vertex jto the root (i.e. lj={i:cij < c0j}). Then we divide the interval [0,1] into |lj|small subintervals, each of which is assigned to a member of the list lj. Algorithm 4 shows the pseudo-code for the predecessor assignment. In line 1, the assignment vector ais initialized and in line 2 the predecessor pjfor each terminal jis defined using the list ljand the random-key vector X(pj=f(lj,Xj)). Predecessor vector pis used to build the tree T(line 3), which might be infeasible by two causes. The first is that a given s-tree s-Tkwith pk= 0, has an accumulated demand that violates the capacity constraint (d(s-Tk)> Q). The second one is that a given subtree Tiviolates the connectivity constraint (no connection to the root and containing a loop). In both cases, a feasibility recovery phase “R()” is applied to make s-Tkor Tia feasible s-tree or subtree respectively. In the loop in lines 4 to 7 we check vertex subtree Tifor infeasibility. If necessary, feasibility of Tiis recovered in line 6, and in line 7 we update tree T0using Ti. Finally assignment list aand predecessor vector pare defined using T0in line 8 to 9. 4.2.4 Feasibility recovery procedure for the predecessor assignment decoder Once the decoding has ended for the predecessor assignment, we check every subtree Tjfor possible feasibility violations. Infeasible subtrees Tjeither violate the connectivity 44
procedure Predecessor-assignment Input:X, V, E, Q, w, c Output: Assignment array a,predecessor vector p 1aj←0, for j= 1, . . . , n; 2pj←f(lj,Xj) for j= 1, . . . , n; 3Build Tusing predecessor vector p; 4for i= 1, . . . , n do 5if (Ti)is infeasible then 6Execute feasibility recovery procedure R(Ti); 7end 8T0←Ti; 9end 10 a←T0; 11 p←T0; 12 return Algorithm 4: Pseudo-code for predecessor assignment decoder. constraint, the capacity constraint, or both. First we check if Tjviolates the connectivity constraint. If so, we connect Tjto the root and Tjbecomes the s-tree s-Tj. Then we check if s-Tjviolates the capacity constraint (d(s-Tj)> Q). If so, we remove subtrees Tifrom s-Tj (Ti⊂s-Tj,d(Ti)≤Q) until d(s-Tj)≤Q. Every removed subtree Tiis either connected to the root or to the closest s-tree s-Tk(k6=j) with enough capacity to accommodate Ti. The distance of Tito an s-tree s-Tk, is defined as the minimum distance between any vertex of Tiand any vertex of s−Tk. That is: dist(Ti, s-Tk) = min{clm |l∈V(s−Tk), m ∈V(Ti)}. We connect Tito s-Tk, if dist(Ti, s-Tk)≤c0iand d(s-Tk)+d(Ti)≤Q, or to the root otherwise. Algorithm 5 shows the pseudocode for this procedure. In line 1 we check if the subtree Tjis an s-tree. If not we connect Tjto the root in line 2. Then if the s-tree s-Tjviolates the capacity constraint, the algorithm enters the loop in lines 4 to 15 to make s-Tjbecome feasible according to capacity. Inside the loop, in line 5, we find a subtree Tiand an s-tree s-Tkwith the minimum dist(Ti, s-Tk) (i∈V(s-Tj), k 6=j, k ∈V+). If dist(Ti, s-Tk)≤c0i (line 8) we connect Tito s-Tk(line 9) and update the accumulated demand of s-Tk(line 10). If not, we connect Tito the root in line 13. 4.3 Improvement phase Since decoding is a crucial part of the BRKGA algorithm, some tests were carried out to evaluate the performance of the three different decoders. The complete results and other important details will be presented in Chapter 5. As it will become evident from the numerical results, all decoders required an improvement phase to enhance their performance. Therefore, after decoding, changes are introduced into the solution to look for improvements. The proposed improvement phase considers the use of reoptimization and local search. Since the set of vertices associated with a given s-tree s-Tksatisfies the capacity constraint we can 45
procedure Feasibility Recovery R() Input: Infeasible subtree Tj,V, E, Q, d, c, T Output: Feasible subtree Tj 1if pj6= 0 then 2pj←0; 3end 4while d(Tj)> Q do 5Find Tiand s-Tksuch that arg min{dist(Ti, s- Tk) : Ti⊂Tj, k ∈V+subrootwithd(s-Tk) + d(Ti)≤Q)}; 6Remove Tifrom Tj; 7d(Tj) := d(Tj)−d(Ti) ; 8if dist(Ti, s-Tk)≤c0ithen 9Add Tito s-Tk; 10 d(s-Tk) := d(s-Tk) + d(Ti) ; 11 end 12 else 13 pi←0; 14 end 15 end 16 return Algorithm 5: Pseudo-code for feasibility recovery procedure. reoptimize every s-tree s-Tkcomputing the MST in V(s-Tk)∪ {0}. This reoptimization will be used in two different ways during the improvement phase. We can also modify the s-trees applying local search within different neighborhoods. In particular, the improvement phase consists of two stages: in the first one each s-tree is reoptimized whereas the second stage is a local search that explores several neighborhoods. 4.3.1 Minimum spanning tree stage (MST-stage) As mentioned, in this stage every s-tree s-Tkin the solution is subject to a reoptimization process. In the output from the decoding phase, the array a= [a1, . . . , an], vertices are partitioned in subsets, which are used to build s-trees. For each s-tree s-Tk, the MST-stage computes a MST. All arcs connecting the root 0 to each subroot are added to the minimum cost spanning trees to jointly produce the capacitated minimum spanning tree. The cost of the tree is the sum of the costs of the s-trees plus the cost of the arcs connecting the subroot vertices to the root. To reoptimize an s-tree we use the set of vertices V(s-Tk) associated with the s-tree s-Tkplus the root 0. Then, using Kruskal’s algorithm we compute the MST for V(s-Tk)∪ {0}, which gives as result an s-tree with its associated cost plus the cost of connecting it to the root. Typically Kruskal’s algorithm uses a list of the arcs which is sorted by increasing values of their costs. To avoid such sorting we created a data structure using linked lists which reduces significantly the time for computing the MST for each s-tree. 46
Figure 4.1: Neighborhood N1, exchange of vertices. 4.3.2 Local search stage Once the solution has been reoptimized, a local search stage is used to improve it. In the local search phase neighborhoods are defined as well as exploration policies. In this section we describe the chosen neighborhoods and how they are explored. We have considered four different neighborhoods. Every neighborhood is explored using a first improvement policy. The first proposed neighborhood N1, involves the swap of two vertices iand j. Vertices iand jinvolved in the swapping, belong to different s-trees, s- Tkand s-Tmrespectively. Swaps are only allowed if capacity restrictions are not violated d(s-Tk)−di+dj≤Qand d(s-Tm) + di−dj≤Q. A second neighborhood N2, is a move neighborhood, where a vertex iassigned to s-tree s-Tkis reassigned to another s-tree, say s-Tm. Such a move can only be made if s-Tmhas sufficient available capacity to accommodate vertex i(d(s-Tm) + di≤Q). The third neighborhood N3 also corresponds to a move. In this case instead of reassigning a vertex i, we reassign the subtree Tiwith origin in the non-subroot vertex iwhich is part of the s-tree s-Tk, to another s-tree s-Tm. The move is done only when the s-tree s-Tm has enough capacity to include the subtree Tiwithout violating capacity constraints (d(s- Tm)+d(Ti)≤Q). Finally the fourth neighborhood considers the merging of two s-trees, s-Tk Figure 4.2: Neighborhood N2, vertex reassignment. 47
Figure 4.3: Neighborhood N3, sub-tree reassignment. and s-Tm, into one s-tree s-Tr. The merging is allowed when the sum of the accumulated demand of both s-trees does not exceeds capacity parameter Q(d(s-Tk)+d(s-Tm)≤Q). For every move in any neighborhood, the residual capacity (array s) used during the assignment phase and accumulated demands, are updated for the vertices and subtrees involved in the move. Figures 4.1- 4.4 allow to visualize neighborhoods N1−N4 described above. A variable neighborhood search (VNS) (Mladenovi´c and Hansen 1997) strategy was used to search for improved solutions in the different proposed neighborhoods. VNS is a metaheuristic which systematically changes neighborhoods, to avoid local optima. We used the most simple version of VNS in which neighborhoods are explored sequentially in a given order. The neighborhoods are explored in the order (N1, N2, N3, N4) until no further improvement is reached in any neighborhood. The pseudocode for VNS is shown in Algorithm 6. The VNS receives the solution tree Tand returns the improved solution tree. In line 1 the algorithm computes the tree cost (Z) and in line 2 an the auxiliary variable Z0is initialized. Then the algorithm enters the loop in lines 3 to 9 where the 4 neighborhoods are explored sequentially. After exploring each neighborhood, the cost (Z) of the tree is updated. The algorithm leaves the loop when the solution cost Zis not improved. Figure 4.4: Neighborhood N4,s-tree merging. 48
procedure VNS Input: Solution tree T,V, E, Q, d, c Output: Updated solution tree T 1Compute solution value Zusing solution tree T 2end=false; 3while end==false do 4Explore Neighborhood N1; 5Explore Neighborhood N2; 6Explore Neighborhood N3; 7Explore Neighborhood N4; 8if Thas not been updated then 9end=true; 10 end 11 end 12 return Algorithm 6: Pseudocode for Variable Neighborhood search 4.3.3 Impact of MST computations To explore each of the neighborhoods we have presented above, we propose three different strategies. In the first one we apply a MST-stage if no further improvement is found after exploring a neighborhood. If the solution is improved, we continue exploring the neighborhood, if not we jump to the next neighborhood. We will refer to this strategy as MST-at-end. In the second strategy that we will call MST-at-change, when an improvement is found a MST-stage is executed for the s-trees involved in such improvement. This is done in all explored neighborhoods. In the third strategy every time a movement is considered, we run a MST-stage for the subtrees involved in the movement. In other words, to evaluate each movement we tentatively make the movement and then the resulting subtrees are reoptimized. If the movement improves the solution cost, the movement is kept, otherwise it is discarded. As this strategy requires the computation of two MSTs to evaluate every movement, it is much more time consuming than the two other strategies. We refer to this third strategy as All-MST. 4.3.4 Strategic oscillation Strategic oscillation has shown to be helpful to improve the results of heuristic methods, so we have used it in our BRKGA algorithm. Strategic oscillation allows the local search procedure to alternatively cross the border between the feasible and unfeasible regions. The idea is to use strategic oscillation to prevent the local search stage to get trapped at a local optima. In our case we propose the relaxation of capacity constraints using a penalty term and a maximum value of capacity violation MaxQ. The maximum violation allowed is set using the average weight of the vertices d(V+)/n and is computed using the following formula MaxQ = 1.1d(V+)/n. Initially, for updating the penalty term, we only considered a descent policy (Descent-SO), but later we also considered two other oscillation strategies. All three are explained next. 49
The Descent-SO strategy, uses a fixed starting value for the penalty term which is updated until it reaches the zero value. After reaching this value, no further update is done to the penalty term. The second approach, Descent-ascent-SO, uses an upper and a lower limit for the penalty term, which decreases when the upper limit is reached and increases when it is equal to the lower limit. The initial value for the penalty is the upper limit. The third approach, Alternate-SO, starts as Descent-SO but when it reaches the zero value, the penalty term is set to either +αor −α. The value of αis close to zero, and the idea of having a negative value is to encourage the solutions to move in the infeasible area to avoid local optima. 4.3.5 Neighborhood reduction As mentioned previously, strategy All-MST is more time consuming than the other two. For this reason we applied a neighborhood reduction for this strategy. To apply this reduction we made some tests and observed the time spent by the algorithm in each of the neighborhoods. We found out that the most time consuming ones were N1 and N2. For those two neighborhoods we implemented a neighborhood reduction policy considering two factors: Distance between vertices, and the number of times that the movement was successful in improving the solution in the history of the search. If the distance between a pair of vertices (i, j) multiplied by a certain factor β, is smaller than or equal to the sum of the distances between such vertices and the root (βcij ≤c0i+c0j), then the move (interchange or reassignment) is explored. Otherwise the move is not considered for exploration. The complete results are presented in the next chapter. 4.4 BRKGA algorithm for the CMST A framework designed for the BRKGA with the capability of handling parallel populations was used with the 2-phase predecessor decoder (see Section 4.2.3). In the first phase keys are decoded and the resulting solutions are then subjected to an improvement phase. The improvement phase has two stages, in the first one each s-tree is reoptimized computing its MST (see 4.3.1). In the second one local search is applied using the VNS of Algorithm 6 with the All-MST exploration strategy of Section 4.3.3, the Neighborhood Reduction of Section 4.3.5 and the Strategic Oscillation Alternate-SO of section 4.3.4 (see Algorithm 7). For each population a set of elite solutions is kept. After a certain number of generations a exchange of these elite sets is made among the different populations. After initial testing a set of parameters was chosen to run the algorithm in the different sets of test instances. After testing different combinations of the features and options proposed in the previous sections for the decoder and improvement phase, we arrived to a final version for the algorithm. Based on preliminary computational testing we selected the following alternatives. For the decoding phase we chose the predecessor assignment decoder. In the improvement phase we apply VNS, exhaustive exploring strategies (All-MST), neighborhood reduction and strategic oscillation. The pseudocode is presented in Algorithm 7 and details are given next. 50
Algorithm BRKGACMST Input:V, E, c, d, Q, H, L, ItEx, StopCriterion Output: Best solution tree T∗,Z∗ 1Z∗:= ∞;it := 0; 2Generate first generation of Lpopulations containing Mrandom keys; 3while StopCriterion == FALSE do 4it := it + 1; 5for l= 1, . . . , L do 6for h= 1, . . . , H do 7Obtain tree Tusing predecessor decoder on key h; 8Apply MST-stage to T; 9Apply VNS search to T; 10 Compute Zhusing T; 11 if Zh< Z∗then 12 Z∗:= Zh;T∗←T; 13 end 14 Recode key husing T; 15 end 16 Sort elements of population laccording to their fitness value Zh 17 Execute Crossover; 18 Add pmmutants to population l 19 end 20 if it mod ItEx == 0 then 21 Interchange elite solutions between populations; 22 end 23 end 24 return Algorithm 7: Pseudocode for the final algorithm The input of the algorithm includes the set of vertices V, the set of edges E, the cost matrix c, the demand vector d, the capacity parameter Q, the number of populations L, the number of elements in each population H, the number of iterations between interchange of elite elements of populations ItEX, and the stopping rule StopCriterion. First, the algorithm introduces Lpopulations, each one with Hrandom keys (line 2), which are part of the first generation. Each random key hof each population lis decoded to obtain a solution Tfor the CMST (line 7). If Tis infeasible, it is modified to make it feasible and then is subject of an improvement phase that stops when it is not possible to improve it. In the improvement phase, Tis first reoptimized applying to it a MST-stage (line 8). Then it enters into the local search stage (Section 4.3.2), where VNS is used to search sequentially in neighborhoods, N1, N2, N3 and N4, which are explored using the All-MST strategy (line 9). For N1 and N2 a neighborhood reduction policy is additionally used in order to reduce the computational time (Section 4.3.3). At a certain point, when is difficult to improve the best solution, strategic oscillation is use within the VNS search. The strategic oscillation is performed using the alternate-SO policy (Section 4.3.4) 51
Table 5.7: Strategic oscillation results for cm100 with Q= 200 and cm200 with Q= 400 Strategic Without Descent Descent Alternate Oscillation type -ascent Group vertices Avg gap CPU Avg gap CPU Avg gap CPU Avg gap CPU cm100 100 1.04 365.16 0.98 365.13 1.08 368.12 0.95 366.68 Q= 200 cm200 200 0.54 3580.03 0.84 3468.41 0.78 3548.88 0.42 3501.86 Q= 400 proximately the same computational effort. Surprisingly, Without-SO algorithm performed better than Descent-ascent-SO and SO-descent for the instances in set cm200 with Q= 400. This is due to the magnitude of the penalty term, which sometimes is too big in relation to account the cost of the tree. This also explains why Alternate-SO performs better, because in this procedure the penalty term oscillates between (−α, α) and takes small values more often. 5.2.1 BRKGA implementation details The BRKGA algorithm for the CMST was implemented in C++. All the testing and the results presented in this section were obtained using a PC with an Intel core 2 at 3.1 GHZ processor and 2 GB of RAM. The BRKGA framework requires the setting of 7 parameters: •L, the number of populations to use. •pe, the percentage of elite elements in each population. •pm, the percentage of mutants introduced in each population after crossover. •ItEx, the number of iterations between exchanges of elite solutions among populations. •ElitetoEx, the number of elite solutions to exchange. •ρ, the probability that an offspring inherits the vector component of its elite parent. •ItStop, the number of iterations without improvement in the stopping criterion. The values used for each parameter are presented in Table 5.8. Since non-UD instances are considered to be more difficult than UD instances, in this case we allowed for larger numbers of iterations both, between population exchanges and without improvement before termination. In particular, the initial experiments showed that, in the case of UD instances, the difficulty of an instance was related both, to the size of the instance and to the capacity parameter. As opposite, in the case of non-UD instances the main source of complexity was the capacity, and the effect of the instance size was smaller. This evidence led us to the development of the expressions used for setting the parameter itStop. 58
Table 5.8: Parameter settings for the BRKGA framework Parameter UD Non-UD L5 pe 0.25 pm 0.10 ElitetoEx 1 ρ0.65 ItEx 5 40 ItStop n−20 Q 45Q Q−100 5.2.2 BRKGA numerical results analysis To evaluate the performance of Algorithm 7, taking into account that it is not deterministic, it was executed 7 times for each test instance. The solutions obtained were compared with the values of the best solutions known so far for the benchmark instances. Algorithm 7 was executed 7 times for each test instance to evaluate the performance of the algorithm. The values of best known solutions for instances in sets tc80 and te80 were taken from (Ahuja, Orlin, and Sharma 2001), for sets tc120, te120, tc160 and te160 from Martins (2007) and Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008). For instances of sets td80 from Martins (2007) and Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008). Finally, for sets cm50, cm100, and cm200, best known solutions are taken from Ahuja, Orlin, and Sharma (2003), Ahuja, Orlin, and Sharma (2001), Ahuja, Orlin, and Sharma (2003) and Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008). The values of those best known solutions are given for each instance in Tables 5.13, 5.14 and 5.15, under the heading best/opt. Known optima are highlighted in bold. Table 5.9 summarizes the results obtained with BRKGA for the different groups of instances. Entries are averages taken over all the instances in the same group. Columns Average mean gap,Minimum mean gap and Maximum mean gap give, respectively, the average, the minimum and the maximum, over the instances in the same group, of the average of deviations with respect to the best known solution taken over the 7 runs of the algorithm. Instead, columns Average best gap,Minimum best gap and Maximum best gap give results related to the best of the seven runs of each instance. That is, Average best gap, Minimum best gap and Maximum best gap give the values of the average, minimum and maximum percentage deviation of the solution obtained in the best of the 7 runs of each instance, respectively. Column Mean avg. CPU shows the average CPU time until termination for the seven runs in seconds, while column CPU to best gives the average CPU time until the best solution was found. The difference between these two last columns, gives the average CPU time spent to fulfill the stopping criterion after the algorithm has found the best UB (for each run). More detailed results for all the test instances are given in Tables 5.13, 5.14 and 5.15. In particular, columns Best BRKGA and Worst BRKGA show, respectively, the best UB 59
and the worst UB obtained by the algorithm for each of the instances after the seven runs. As can be seen, the obtained results are good. Our BRKGA found the best-known solution for 77 out of the 81 UD instances and for 34 out of the 45 non-UD instances. Furthermore, for 7 instances, the algorithm found a solution improving the currently bestknown solution. The specific instances and the value of the new best solution we found are given in Table 5.10. In general, our algorithm was robust in the sense that there are small variations in the output of different runs on the same instances. This can be appreciated by comparing columns Best BRKGA and Worst BRKGA in Tables 5.13-5.15 and also in Figure 5.1 where an histogram is given for the values of the percent deviations of the worst solution found among the seven runs with respect to the best one, for all the instances. 40% 50% 60% 70% 80% 90% 100% 0% 10% 20% 30% 40% [0,0.25)[0.25,0.5) [0.5,0.75)[0.75,1) [1,1.25)[1.25,1.5) [1.5,1.75)[1.75,2) Figure 5.1: Histogram of percent deviations of best with respect to worst solution found in the seven runs. In fact, there is a considerable number of instances for which BRKGA found the bestknown solution in each of the 7 executions. For the UD instances this happens in 38 out of the 45 instances with 80 vertices, 11 out of the 30 instances with 120 vertices and in 1 out of 6 for the 160 vertices instances. The performance of the algorithm is however less predictable with the non-UD instances. The algorithm works remarkably well for the instances with larger capacities (Q= 800) where it always produces a best-known solution for all instances with 50 and 100 vertices, and it improves the best-known solution in 2 out of the 5 instances with 200 vertices. Similar results are obtained for the instances with medium capacities (Q= 400), where it finds a best-known solution for all instances with up to 100 vertices except one, and it improves the value of the best-known solution for 3 out of the 5 instances with 200 vertices, although for the other 2 instances in this group, it was not able to find a solution with the best-known value. The performance of the algorithm somehow decreases with some of the instances with smaller capacities (Q= 200). Now, BRKGA finds an optimal solution for all the small 50 vertex instances, and 2 out of the 5 instances with 100 vertices, but it fails in finding a best known solution for the remaining 8 instances. In fact, we could improve the performance of our algorithm for this specific subset of instances by further fine-tuning the values of the parameters of the BRKGA heuristic, but we preferred to use the same parameters values for all the instances in the same class at the expense of 60
Table 5.9: Summary BRKGA results nAverage Minimum Maximum Average Minimum Maximum Mean avg. CPU to Group mean gap mean gap mean gap best gap best gap best gap CPU(secs.) best (secs.) tc80 80 0.004 0.005 0.069 0.000 0.000 0.000 99.77 24.45 td80 80 0.004 0.000 0.022 0.000 0.000 0.000 259.01 125.76 te80 80 0.005 0.005 0.035 0.000 0.000 0.000 217.88 76.76 tc120 120 0.039 0.000 0.224 0.000 0.000 0.000 324.55 147.31 te120 120 0.091 -0.129 0.457 0.013 -0.259 0.245 694.73 422.37 tc160 160 0.168 0.115 0.197 -0.025 -0.076 0.000 1753.70 1210.47 te160 160 0.011 0.000 0.025 0.000 0.000 0.000 1587.30 941.33 cm50 50 0.072 0.000 0.524 0.000 0.000 0.000 98.97 6.23 cm100 100 0.354 0.000 2.072 0.171 0.171 1.541 459.50 122.18 cm200 200 0.820 -0.781 2.894 0.412 0.336 2.666 3275.26 2092.95 61
Table 5.10: New best-known solutions Instance Q Previous UB New UB te120 −4 20 773 771 tc160 −1 10 1319 1318 cm200 −2 400 476 475 cm200 −3 400 559 557 cm200 −4 400 389 388 cm200 −2 800 294 293 cm200 −3 800 361 360 not obtaining the best possible results. The times required by the BRKGA algorithm to obtain the above results are quite modest. All UD instances with Euclidean distances and 80 vertices (te80, td80, te80) terminated in less than 5 minutes. The average CPU time to termination for instances in the same class with more than 80 vertices (tc120, te120, tc160 and te160) was less than haf an hour; indeed the most time consuming instances in this group where te160 that took an average of 1753.70 seconds. In total, the most demanding instances were, non-UD instances cm200 where the average computing time is 3275.26 seconds (less than an hour). Additionally, in Table 5.9 there is a comparison for each set of instances, between the average CPU times (in seconds) and the average CPU times when the best solution was found. It is clear from the results that many CPU time is spend to fulfill the stopping criterion, as many of the best UB’s are found in early iterations. It is important to remember that the stopping criterion was set using the information obtained in the initial experiments which led to the formulas presented in section 5.2.1. Since the stopping criterion was defined in function of the capacity Q, it was expected that Qwill have an effect over the CPU times. Figure 5.2 shows the average CPU times over instances of the same size and with the same capacity. Here, for an easier comparison of the behavior of the algorithm for UD and non-UD instances, capacities are presented in terms of the average number of vertices that fit in a tree (rin the figure). In the case of UD instances r=Q, whereas, in the case of non-UD instances r=Q/50, since 50 is approximately the average demand of the vertices in the non-UD instances. The figure shows clearly how the time taken by BRKGA to solve the instances increases with the instance size in a similar way for UD and non-UD instances. As opposite, as already noticed in the preliminary tests carried out for tunning the algorithm, the effect of the instance capacities on the computational effort required for their solution is different depending on the type of instance, being much more relevant in the case of UD instances. Nonetheless, in both cases, the instances that seem to 62
1500 2000 2500 3000 3500 nonrUD r=4 r=8 r=16 1500 2000 2500 3000 3500 UD r=5 r=10 r=20 0 500 1000 1500 2000 50 100 150 200 n r=16 0 500 1000 1500 2000 50 100 150 200 n r10 r=20 0 50 100 150 200 0 50 100 150 200 Figure 5.2: CPU time increase with instance size for different values of r, the average number of terminals per tree require the smallest times are those where capacity constraints are either the tightest or the loosest, while situations in between appear to be the most difficult ones. 150 200 250 300 350 tc80 td80 0 50 100 150 200 Q=5 Q=10 Q=20 0 Q=5 Q=10 Q=20 Figure 5.3: Average CPU times Euclidean between sets tc80 and td80 In order to evaluate the sensitivity of BRKGA to the type of distances we have concentrated in instance sets tc80 and td80, containing UD instances of the same sizes and the same type of location of the root. The only difference between those sets is the type of distances; they are Euclidean in set tc80 and non Euclidean in set td80. Figure 5.3 shows the average CPU times taken to solve the problem for the different capacities considered in these sets. The figure shows very different behaviors in the two sets. In particular, the computational effort required to solve instances with non-Euclidean distances is much higher than what is needed for solving instances with Euclidean distances with the same characteristics. As for the effect of the capacity in the instances difficulty, the observed behavior coincides with what was observed in general, solving instances with extreme capacities tends to be a bit less demanding than for moderate capacities, and this effect is larger for non-Euclidean instances. We close this section by comparing our results with those of other heuristics for the 63
CMST. For the comparison we have chosen the VLNS heuristic of Ahuja, Orlin, and Sharma (2003) which, in our opinion, is so far the heuristic which has produced the best results, the more recent ant colony heuristic (ACO) of Reimann and Laumanns (2006), the enhanced second order (ESO) algorithm by Martins (2007) and the RAMP heuristic of Rego, Mathew, and Glover (2010). For instances tc and te with 80 vertices and UD the best results are obtained by the VLNS algorithm, although the results of the BRKGA are also very good since the average mean gaps are really close to zero. The ACO, ESO and RAMP algorithms perform worse than the BRKGA and VLNS. For instances of type td and 80 vertices, the results of the BRKGA are better than those of the ESO in terms of average mean gap. For instances of tc120, te120, tc160 and te160 vertices and UD, the best average mean gaps are obtained by the BRKGA with values below 2% for the set te160 and below 1% for the other three sets. For the non-UD set with 50 vertices, again, the VLNS performs better than the BRKGA and the other algorithms. For non-UD instances with 100 and 200 vertices, the RAMP algorithm obtains the best average gap, although only instances with Q= 200 are considered in that work. The BRKGA obtains very close results in instances with Q= 200, and improves the results obtained by VLNS in instances with Q= 400 and Q= 800. Notice that for this set of instances, the average CPU times of the RAMP algorithm are very large. Finally, for non-UD instances with 200 vertices, the BRKGA obtains better results than the other algorithms in terms of the average mean gap. Comparing the VLNS with the BRKGA in terms of the mean average gap, we can see that the BRKGA performs better for the instances with larger number of vertices (100, 120, 160 and 200) and slightly worse for the sets with 80 vertices. If compared with the ACO, the BRKGA always performs better in terms of the mean average gap. This is explained by the fact that ACO was designed to obtain fairly good results using a small computation effort (small CPU times). It is important to mention that the results of the ACO for non-UD instances were not published for reasons related to its performance, which are explained in the original article. If compared with the ESO, the BRKGA mean average gaps are also better. Finally, the BRKGA results are also better in terms of the average mean gap for all test instances, when compared to those of the RAMP, except for the cm100 as it has been explained. In fact, in general terms, the BRKGA obtains good results without regard of the type of test instance. Since it is hard to compare the CPU times of the different algorithms, we decided to compile the BRKGA with the previously mentioned compiling options (g++ with the the flags “-c” and “-O3”), on a pentium IV machine with 712 MB of RAM, and solved some of the test instances. The results showed that the pentium core2 was about 10 times faster than the Pentium IV. Therefore, the 1/10 of a second of CPU time on the pentium core2 represents approximately one second of CPU timee on a pentium IV. No test were performed on machines with pentium M or Athlon processors. In table 5.12 the best results obtained by each algorithm for the different sets of instances are presented. The results shows that the BRKGA obtains the best results among the different algorithms. For the UD sets, the BRKGA found the best know solutions for 77 of the 81 test instances. For the non-UD sets, the algorithm found the best known solution for 33 out of the 45 instances. 64
Table 5.11: Comparison of average mean GAP and CPU time by instance group with state of the art heuristics VLNS ACO ESO RAMP BRKGA nAverage Mean avg. Average Mean avg. Average Mean avg. Average Mean avg. Average Mean avg. Group mean gap CPU(secs.) mean gap CPU(secs.) mean gap CPU(secs.) mean gap CPU(secs.) mean gap CPU(secs.) tc80 80 0.000 1800 0.205 6.52 0.078 3600 0.018 267.33 0.004 99.77 td80 80 NA NA NA NA 0.075 3600 NA NA 0.004 259.01 te80 80 0.000 1800 0.085 18.81 0.179 3600 0.217 1842.67 0.005 217.88 tc120 120 0.281 NA 0.074* 66.00 0.474 5400 NA NA 0.039 324.55 te120 120 0.240 NA 0.766* 178.00 0.458 5400 NA NA 0.091 694.73 tc160 160 0.716 NA 0.867 543.33 0.412 7200 NA NA 0.168 1753.70 te160 160 0.583 NA 0.358 545.00 0.216 7200 NA NA 0.011 1587.30 cm50 50 0.020 1000 NA NA NA NA 0.146 850.53 0.072 98.97 cm100 100 0.407 1800 NA NA NA NA 0.314** 35800.00 0.354 459.50 cm200 200 1.021 3600 NA NA NA NA NA NA 0.820 3275.26 Computer used Pentium 4 Pentium M AMD Athlon Pentium P4 Pentium Core2 *Only tc120-1 and te120-1 instances were tested. ** Only instances with Q= 200 were solved. NA, no information was found/available for the algorithm and the set of instances. 65
Table 5.12: Number of best known solutions found by instance group for each state of the art heuristic Group ntotal number VLNS ACO ESO RAMP BRKGA of instances tc80 80 15 15 8 11 13 15 td80 80 15 NA NA 5 NA 15 te80 80 15 15 10 7 6 15 tc120 120 15 5 2* 7 NA 15 te120 120 15 3 1* 1 NA 11 tc160 160 3 0 0 0 NA 3 te160 160 3 0 0 0 NA 3 cm50 50 15 14 NA NA 11 15 cm100 100 15 9 NA NA 3** 11 cm200 200 15 5 NA NA NA 8 *Only tc120-1 and te120-1 instances were tested. ** Only instances with Q= 200 were solved. NA, no information was found/available for the algorithm and the set of instances. 66
Table 5.13: Results for UD instances with n= 80 vertices Instance Average CPU Best/Opt* Best Worst Group Qnumber gap (seconds) Solution BRKGA BRKGA tc80 5 1 0.00 38.84 1099 1099 1099 2 0.00 99.04 1100 1100 1100 3 0.00 106.49 1073 1073 1073 4 0.00 105.53 1080 1080 1080 5 0.00 119.08 1287 1287 1287 10 1 0.00 53.06 888 888 888 2 0.00 105.36 877 877 877 3 0.00 112.78 878 878 878 4 0.07 121.26 868 868 872 5 0.00 126.02 1002 1002 1002 20 1 0.00 61.63 834 834 834 2 0.00 117.17 820 820 820 3 0.00 102.85 828 828 828 4 0.00 103.56 820 820 820 5 0.00 123.88 916 916 916 td80 5 1 0.00 279.23 6068 6068 6070 2 0.00 266.01 6019 6019 6019 3 0.01 285.57 5994 5994 5997 4 0.00 206.99 6012 6012 6012 5 0.00 197.89 5977 5977 5977 10 1 0.00 341.31 3223 3223 3223 2 0.00 228.83 3205 3205 3205 3 0.00 317.28 3212 3212 3212 4 0.00 323.99 3203 3203 3203 5 0.00 237.86 3180 3180 3180 20 1 0.00 196.10 1832 1832 1832 2 0.02 262.74 1829 1829 1830 3 0.00 230.66 1839 1839 1839 4 0.02 243.12 1834 1834 1835 5 0.00 267.65 1826 1826 1826 te80 5 1 0.00 180.05 2544 2544 2544 2 0.03 341.61 2551 2551 2556 3 0.01 270.51 2612 2612 2614 4 0.03 277.84 2558 2558 2560 5 0.00 199.06 2469 2469 2469 10 1 0.00 186.13 1657 1657 1657 2 0.00 215.17 1639 1639 1639 3 0.00 221.18 1687 1687 1687 4 0.00 218.45 1629 1629 1629 5 0.00 201.22 1603 1603 1603 20 1 0.00 185.14 1275 1275 1275 2 0.00 190.74 1224 1224 1224 3 0.00 187.42 1267 1267 1267 4 0.00 216.44 1265 1265 1265 5 0.00 177.27 1240 1240 1240 * Marked in bold are the values that have been proven to be optimal. 67
Table 5.19: Individual effect of each family of valid inequalities LP Bin-packing Multistar s-tree multistar Rootcutset relaxation inequalities inequalities inequalities inequalities Group Avg gap CPU Avg gap Avg CPU Avg gap Avg CPU Avg gap Avg CPU Avg gap Avg CPU cm50 34.07 0.12 20.30 7.37 7.18 8.92 5.61 21.56 9.71 5.37 cm100 12.55 5.22 6.54 299.68 4.54 252.74 4.10 917.58 7.99 139.01 tc80 6.64 0.27 5.36 46.83 1.78 11.24 1.20 27.06 4.09 11.02 td80 15.18 2.28 10.23 128.35 3.26 216.58 2.95 985.60 2.52 98.37 te80 28.27 1.33 20.85 143.11 4.85 297.02 3.10 1790.10 7.55 78.62 74
Table 5.20: Inequalities combination, effect on the gap by groups of test instances solalg1solalg2 Group Avg gap CPU Avg gap Avg CPU cm50 6.08 38.65 4.06 91.25 cm100 3.95 347.02 3.68 1517.93 tc80 1.53 17.64 1.13 327.06 td80 2.03 480.24 1.78 2100.87 te80 3.89 590.55 2.85 3290.10 Table 5.21: Summary results for subroot formulation algorithm Group Avg gap Avg CPU tc80 1.12 30.86 td80 1.60 607.99 te80 2.84 2765.40 cm50 4.01 30.23 cm100 3.43 683.48 The results show that the location of the root node and the type of distances have an important effect on the gaps and CPU times on the UD instances. For tc (root in the center and euclidean distances) the average gap is close to one percent and the CPU time is close to 30 seconds. For td instances (root in the center and euclidean distances), the change in the CPU time and the gap reflect the effect of having non euclidean distances. The difference between the results for tc and te instances, reflect the effect produced by the location of the root node. Somehow this was expected, since the number of variables for te instances is greater than for those for the tc and td ones, except for td with Q= 5. For non-UD instances, we can observe in the average gaps the effect of having non unitary demands and non euclidean distances. The gaps increase significantly if compared with the UD instances, although the initial number of variables usually are greater than those for tc instances but smaller than for td and te ones. The effect generated by the number of vertices, is observed when comparing the results of cm50 and cm100 instances. The results show that CPU times are significantly greater when 75
Table 5.22: Comparison with other formulations Group Subroot q −arb HIF Avg gap Avg CPU Avg gap Avg CPU Avg gap Avg CPU tc80 1.12 30.86 0.00 30.42 0.31* 554.5 td80 1.60 607.99 0.00 15480.65 NA NA te80 3.13 2765.40 0.00 3562.17 0.55* 2273 cm50 4.01 30.23 0.00 150.77 ** ** cm100 3.43 683.48 0.00 23241.27 ** ** * Instances with Q= 20 were not solved. **The formulation is designed to solve only UD instances NA, no information was found/available for the algorithm and the set of instances. the number of vertices increases. Surprisingly, the average gap is greater for cm50 instances than for cm100. This behavior is explained if we look at the percentage of eliminated variables, which is greater for cm50 than for cm100 (See Table 5.18) We can conclude that the type of demand (UD and non-UD), the location of the root(centered or not), and the type of distances (euclidean and non-euclidean) have influence over the initial number of variables, which have an effect on the gaps and CPU times. We close this section by comparing the obtained results with the ones obtained by other formulations. We use for comparison the q-arb formulation by Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008) and the hop indexed formulation (HIF) by Gouveia and Martins (2005) which are the more recent works. Table 5.22 presents the above mentioned comparison. Columns Subroot,q−arb and HIF show, respectively, the results for the subroot, q-arb and hop indexed formulations. The best results in terms of gap are obtained by the q-arb formulation, which finds the optimal solution of all the instances with significantly higher CPU times than for the other two formulations. The hop indexed formulation gaps for UD instances are between those of the q-arb and subroot formualtion. In general the subroot formulation obtains small gaps at small CPU times. 5.3.3 Results obtained with the subroot hop indexed formulation To developed the subroot hop indexed formulation the solution algorithm presented we used the information already obtained for the subroot formulation. Therefore, the algorithm included the separation of the extensions of the three families of valid inequalities used above: subroot multistar, s-tree multistar and subroot rootcutset. Additionally, GSEh and hop ordering inequalities are separated. The separation problem for GSEh inequalities is solved heuristically by solving a maximum flow problem over a customized graph (see Section 3.3), while hop ordering inequalities are separated by inspection. A complete description of the algorithm and the separation problems can be found in Section 3.3.1. 76
Table 5.23: Complete results for UD instances with 80 vertices using subroot formulation Group Q Instance Bound gap CPU tc80 5 1 1099 1.78 123.91 21100 1.81 62.70 31073 1.99 38.39 41080 2.69 42.78 51287 2.31 44.75 10 1 888 1.20 75.39 2877 0.54 16.80 3878 1.59 12.66 4868 0.81 7.13 51002 0.97 28.50 20 1 834 0.48 2.84 2820 0.49 1.17 3828 0.00 1.50 4820 0.00 0.87 5916 0.27 3.44 td80 5 1 6068 1.93 771.95 26019 1.78 772.16 35994 1.77 623.85 46012 1.46 726.30 55977 1.22 651.66 10 1 3223 2.11 637.90 23205 1.47 745.45 33212 2.12 610.59 43203 1.12 471.11 53180 1.26 642.07 20 1 1832 1.20 131.51 21829 1.53 838.03 31839 1.85 383.67 41834 1.31 542.67 51826 1.92 570.90 te80 5 1 2544 1.43 3522.47 22551 2.28 2738.87 32612 2.34 3730.89 42558 2.45 2110.47 52469 2.22 1987.83 10 1 1657 5.51 5693.27 21639 5.66 5802.42 31687 4.63 5631.63 41629 4.66 4482.54 51603 3.35 4206.96 20 1 1275 2.46 205.40 21224 2.52 679.20 31267 2.64 268.73 41265 2.76 309.87 51240 2.05 111.28 77
Table 5.24: Complete results for non-UD instances of up to 100 vertices using subroot formulation Group Q Instance Bound gap CPU cm50 200 1 1098 5.49 24.78 2974 5.38 25.23 31186 5.86 27.17 4800 5.08 4.44 5928 6.41 15.02 400 1 679 4.40 142.09 2631 2.23 42.92 3732 6.85 56.61 4564 4.79 5.73 5611 4.76 17.52 800 1 495 3.16 18.61 2513 1.77 36.34 3532 1.72 29.84 4471 0.90 1.09 5492 2.16 6.05 cm100 200 1 509 7.51 444.76 2252 2.37 443.31 3182 0.38 77.19 4584 6.03 1444.55 5277 1.47 1079.74 400 1 179 0.98 47.72 2540 6.97 964.04 3236 2.75 439.06 4175 1.61 30.59 5435 8.70 739.28 800 1 219 3.49 2443.41 2183 0.41 120.94 3418 8.50 576.32 4223 2.56 1372.34 5186 1.46 29.02 78
Table 5.25: Summary results for UD instances for subroot hop indexed formulation Group vertices Q Avg gap Avg CPU 5 0.31 1927.03 tc80 80 10 0.41 3082.80 20 0.19 276.39 Average 0.30 1762.07 5 0.23 3896.18 td80 80 10 0.29 6959.28 20 0.60 3773.71 Average 0.37 4876.39 5 0.58 116799.80 te80 80 10 4.64 10783.19 20 2.07 4248.50 Average 2.43 43943.39 Since the subroot hop indexed formulation is specially designed for solving the UD case of the problem, the algorithm was tested for the groups of instances tc80, td80 and te80. A summary of the results are presented in Table 5.25. The complete results are shown in Table 5.27 From the results in Table 5.25 we can observe that the average gaps by group of instance obtained by the subroot hop indexed formulation are better for the tc80 instances as these are less difficult than the two other groups of instances. Also the CPU times for tc80 group, are smaller because the initial number of variables is smaller than for the two other groups (see Table 5.17). The results for td instances are not far from those of tc ones, since an important part of the cost of the tree is due to the arcs linking the root with the subroots and somehow the formulation puts special emphasis on these vertices. From Table 5.25 we can see that the gap increases as Qincreases (the number of subroots decreases as Qincreases). Remember that the proposed formulation focuses on the connectivity of the subroots. Finally instances of type te obtain not so good results as they are the most difficult ones. However, the algorithm obtained small gaps for te instances with Q= 5, although the CPU times are larger. For this group of instances, the algorithm is capable of finding violated inequalities with the inconvenient that such cuts only represent a small increase in the objective function, thus explaining the large CPU times. The complete results of the algorithm are shown is Table 5.27. Notice that for 11 of the 45 instances an optimal solution was found. We close this section by comparing the results of the subroot hop indexed formulation with the subroot formulation, the q-arb and hop indexed formulations. From Table 5.26 we can see that subroot hop indexed formulation obtains better results than those of the subroot formulation but still not as good as the ones by Uchoa, Fukasawa, Lysgaard, Pessoa, 79
de Aragao, and Andrade (2008) and Gouveia and Martins (2005). The gaps obtained for UD instances with the subroot hop indexed formulation are a bit larger than those obtained by Uchoa, Fukasawa, Lysgaard, Pessoa, de Aragao, and Andrade (2008) but the computational burden for obtaining them is, in general, much smaller. The comparison with the results from Gouveia and Martins (2005) is rather poor, since that work does not report experiments on many of the instance groups tested in thi thesis. However, in the groups for which data is available their results are slightly better than those obtained with the subroot hop indexed formulation, specially in what refers to the CPU times. This is probably due to the fact that subroot formulations have a larger number of variables and it requires larger times to solve the LP subproblems. 80
Table 5.26: Comparison of subroot hop indexed formulation results for UD instances with other formulations SRHIF SR q-arb Hop Indexed Group vertices Q Avg gap Avg CPU Avg gap Avg CPU Avg gap Avg CPU Avg gap Avg CPU tc80 80 5 0.31 1927.03 2.11 62.46 0.00 67.46 0.256 276.00 10 0.41 3082.80 1.02 28.07 0.00 23.50 0.363 833.00 20 0.19 276.39 0.25 1.96 0.00 0.32 NA NA Average 0.30 1762.07 1.12 30.83 0.00 30.42 0.31 554.50 td80 80 5 0.23 3896.18 1.63 709.18 0.00 106.30 NA NA 10 0.29 6959.28 1.61 621.42 0.00 45883.30 NA NA 20 0.60 3773.71 1.56 493.36 0.00 451.86 NA NA Average 0.37 4876.39 1.60 607.99 0.00 15480.65 NA NA te80 80 5 0.58 116799.80 2.14 2818.04 0.00 188.84 0.288 786.00 10 4.64 10783.19 4.76 5163.32 0.00 10452.96 0.811 3760.00 20 2.07 4248.50 2.49 314.90 0.00 44.72 NA NA Average 2.43 43943.39 3.13 2765.42 0.00 3562.17 0.55 2273.00 81
Table 5.27: Complete results UD instances for the subroot hop indexed cutting plane algorithm Group Q Instance number Bound gap CPU tc80 5 1 1099 0.00 797.48 21100 0.00 454.76 31073 0.00 1140.99 41080 0.83 3632.92 51287 0.70 3609.00 10 1 888 0.90 4838.04 2877 0.00 93.79 3878 1.14 3247.60 4868 0.00 3776.59 51002 0.00 3457.97 20 1 834 0.48 650.07 2820 0.49 391.94 3828 0.00 34.59 4820 0.00 39.75 5916 0.00 265.60 td80 5 1 6068 0.33 4531.67 26019 0.22 3989.07 35994 0.28 3652.14 46012 0.17 3665.81 55977 0.17 3642.23 10 1 3223 0.37 4912.60 23205 0.00 3718.04 33212 0.50 4683.27 43203 0.03 18451.66 53180 0.53 3030.85 20 1 1832 0.33 628.78 21829 0.98 5242.27 31839 0.49 6303.54 41834 0.60 4064.32 51826 0.60 2629.65 te80 5 1 2544 0.00 32714.59 22551 0.94 5522.19 32612 0.69 5074.56 42558 0.90 5521.12 52469 0.36 5083.48 10 1 1657 5.37 26899.64 21639 5.86 223545.99 31687 4.80 57644.98 41629 3.93 233945.16 51603 3.24 41963.21 20 1 1275 2.82 4510.92 21224 2.37 4206.50 31267 2.29 4175.73 41265 1.74 4156.61 51240 1.13 4192.75 82
Chapter 6 Conclusions and future research The CMST is one of the most interesting problems in combinatorial optimization and network design. Along with the TSP, the CMST is considered to be the core of network systems design and a wide variety of scheduling and routing applications. In this thesis we focus on the CMST, for which we develop a heuristic method and present two alternative formulations. Both formulations are enhanced with a series of valid inequalities and different procedures are proposed for their separation. The subroot formulation is the first of the proposed formulations that we have presented. This formulation is based on identifying a special type of vertices on the network;the subroots, which are the vertices directly connected to the root. This type of formulation is aimed at tackling problems in which the location of special equipments in a special type of vertices is of relevance for the design of the network and can be extended in a straight-forward way to situations where there are fixed costs for locating these equipements or different subroot locations have associated different capacities. Using this formulation, some of the already known valid inequalities are extended. Also new stronger inequalities are presented. These new families of inequalities include the subroot multistar inequalities, the s-tree multistar inequalities and the subroot rootcutset inequalities. The first two families are separated exactly by solving a maximun flow problem. For the third family the subroot rootcutset, a heuristic separation procedure is used. The cutting plane algorithm for this formulation founds good results, although the gap from the optimal value is not closed in general. A strong point of this algorithm is the variable elimination procedure, which importantly reduces the number of variables of the test instances (95.2% and 81.5% for tc and te instances respectively) The second proposed formulation is the subroot hop indexed formulation, which is able to obtain better results for the test instances with unitary demands. Extended versions of the subroot multistar, s-tree multistar and subroot rootcutset inequalities are shown. Additionally, GSEh and hop ordering inequalities are included for this formulation. We present exact separation methods for the multistar and s-tree inequalities and heuristic separation methods for the GSEh and subroot rootcutset inequalities. The solution algorithm for this formulation also implements a variable elimination procedure that yields dramatic reductions on the number of variables. Better lower bounds are obtained using the solution algorithm and for some of the test instances the gap was closed arriving to the optimal solution. 83
90
Notation and Abbreviations Notation bThe maximum number of saturated s-trees in S i∈I. cCost matrix. cij Distance between vertex iand vertex j c(T) Cost of T. dDemand vector. diDemand associated to terminal i∈V+. d(S) Sum of the demands of the vertices in set S⊆V+. d(Ti) Sum of the demands of the vertices in subtree Ti. dist(Ti, s-Tk) Minimum distance between subtree Tiand s-tree s-Tk. nNumber of components in the solution vector of an individual. ljPredecessor list for j. peNumber of elite individuals. pmNumber of mutants. s0Source vertex. s-Tks-tree rooted at k. u0Sink vertex. v0Root vertex. ρeProbability that an offspring inherits the vector component of its elite parent. ASet of arcs. ASet of arcs in auxiliary graph N(¯x, ¯y). 91
ESet of edges in graph GU. ElitetoEx Number of elite solutions to exchange. G= (V, A) Directed network without loops. GU= (V, E) Undirected graph for BRKGA. ItEX Number of iterations between interchange of elite elements of populations. ItStop Number of iterations without improvement in the stopping criterion. LNumber of populations. MaxQ Maximum Value of Capacity Violation for strategic oscillation. MT (S) Minimum number of s-trees required to accommodate the demand of the vertices contained in subset S. N1 Local search neighborhood 1. N(¯x, ¯y) Auxiliary graph used for inequalities separation procedures. QCapacity parameter. “R()”Feasibility recovery phase for predecessor decoder. SSubset of vertices. StopCriterion Stopping rule for BRKGA algorithm. TSpanning tree subset of A. TiSubtree rooted at vertex i. VSet of vertices. VSet of vertices in auxiliary graph N(¯x, ¯y). V+Set of terminals. V(Ti) Set of terminals connected by subtree Ti. XVector of nrandom keys. ZTree cost. 92
Abbreviations ACO Ant Colony Optimization CMST Capacitated Minimum Spanning Tree CVRP Capacitated Vehicle Routing Problem ECC Extended Capacity Cuts ESO Enhance Second Order algorithm GSE Generalized Subtour Elimination CPLP Capacitated Plant Location Problem BRKGA Biased Random Key Genetic Algorithm HECC Homogeneous Extended Capacity Cuts LIFO Last Input First Output LB Lower Bound LP Linear Programming LIFO Last Input First Output MST Minimum Spanning Tree MIP Mixed Integer Programming NP-Hard Non Polynomial Hard Non-UD Non Unitary Demands GRASP Greedy Randomized Adaptive Search Procedure LS Local Search RKGA Random Key Genetic Algorithm SRHIF Subroot Hop Indexed Formulation TSP Traveling Salesman Problem UB Upper Bound UD Unitary Demands VLNS Very Large Neighborhood Search heuristic VNS Variable Neighborhood Search VRP Vehicle Routing Problem 93
94
List of Figures 1 MST and CMST solution comparison . . . . . . . . . . . . . . . . . . . . . . 3 1.1 Tree Trootedatvertex0.............................. 6 2.1 Example of hop indexed variables . . . . . . . . . . . . . . . . . . . . . . . . . 16 2.2 Example of violated bin-packing inequalities with UD and Q=5 . . . . . . . . 18 2.3 Example of violated multistar inequalities with UD and Q=5 . . . . . . . . . 19 2.4 Example of violated rootcutset inequalities with UD and Q=5 . . . . . . . . . 20 2.5 Example of violated GSEh inequalities with UD and Q=5 . . . . . . . . . . . 21 3.1 Auxiliary network for the exact separation of subroot multistar inequalities . 30 3.2 Auxiliary network for the exact separation of s-tree multistar inequalities . . 31 3.3 Vertex shrinking for the separation of subroot rootcutset inequalities . . . . . 31 3.4 Auxiliary network for the exact separation of extended subroot multistar inequalities ...................................... 35 3.5 Auxiliary network for the exact separation of extended s-tree multistar inequalities ...................................... 36 3.6 Auxiliary network for the heuristic separation of GSEh inequalities . . . . . . 36 4.1 Neighborhood N1, exchange of vertices. . . . . . . . . . . . . . . . . . . . . . 47 4.2 Neighborhood N2, vertex reassignment. . . . . . . . . . . . . . . . . . . . . . 47 4.3 Neighborhood N3, sub-tree reassignment. . . . . . . . . . . . . . . . . . . . . 48 4.4 Neighborhood N4,s-treemerging. ........................ 48 5.1 Histogram of percent deviations of best with respect to worst solution found inthesevenruns................................... 60 5.2 CPU time increase with instance size for different values of r, the average number of terminals per tree . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 5.3 Average CPU times Euclidean between sets tc80 and td80........... 63 95
96
List of Tables 5.1 Summary of instances characteristics . . . . . . . . . . . . . . . . . . . . . . . 54 5.2 Decoderscomparison................................ 55 5.3 Decoders comparison with improvement phase . . . . . . . . . . . . . . . . . 56 5.4 Results with local search using different neighborhood exploring strategies . . 56 5.5 Results with local search including strategic oscillation . . . . . . . . . . . . . 57 5.6 Results including neighborhood reduction . . . . . . . . . . . . . . . . . . . . 57 5.7 Strategic oscillation results for cm100 with Q= 200 and cm200 with Q= 400 58 5.8 Parameter settings for the BRKGA framework . . . . . . . . . . . . . . . . . 59 5.9 SummaryBRKGAresults............................. 61 5.10 New best-known solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 5.11 Comparison of average mean GAP and CPU time by instance group with stateoftheartheuristics ............................. 65 5.12 Number of best known solutions found by instance group for each state of the artheuristic..................................... 66 5.13 Results for UD instances with n=80vertices.................. 67 5.14 Results for UD instances with n= 120 and n= 160 vertices . . . . . . . . . . 68 5.15 Results for non-UD instances with n= 50, n= 100 and n= 200 vertices . . . 69 5.16 Average percentage deviation for the obtained LB’s . . . . . . . . . . . . . . . 70 5.17 Variable Elimination Comparison for UD instances . . . . . . . . . . . . . . . 72 5.18 Variable elimination of subroot formulation for non-UD instances . . . . . . . 72 5.19 Individual effect of each family of valid inequalities . . . . . . . . . . . . . . . 74 5.20 Inequalities combination, effect on the gap by groups of test instances . . . . 75 5.21 Summary results for subroot formulation algorithm . . . . . . . . . . . . . . . 75 5.22 Comparison with other formulations . . . . . . . . . . . . . . . . . . . . . . . 76 5.23 Complete results for UD instances with 80 vertices using subroot formulation 77 5.24 Complete results for non-UD instances of up to 100 vertices using subroot formulation ..................................... 78 5.25 Summary results for UD instances for subroot hop indexed formulation . . . 79 5.26 Comparison of subroot hop indexed formulation results for UD instances with otherformulations ................................. 81 5.27 Complete results UD instances for the subroot hop indexed cutting plane algorithm ...................................... 82 97
98
List of Algorithms 1 Pseudo-code of the solution algorithm of subroot formulation. . . . . . . . . . 38 2 Pseudo-code for direct assignment decoder. .................. 42 3 Pseudo-code for cost-based assignment decoder................. 43 4 Pseudo-code for predecessor assignment decoder................ 45 5 Pseudo-code for feasibility recovery procedure. . . . . . . . . . . . . . . . . . . 46 6 Pseudocode for Variable Neighborhood search . . . . . . . . . . . . . . . . . . 49 7 Pseudocode for the final algorithm . . . . . . . . . . . . . . . . . . . . . . . . . 51 99