Solve traveling salesman problem using EMF-CE algorithm Solve traveling salesman problem using EMF-CE algorithm

—In this paper, a novel search algorithm that based on the Contraction-Expansion algorithm and 10 integrated three operators Exchange, Move, and Flip (EMF-CE) is proposed for the traveling salesman 11 problem (TSP). EMF-CE uses a negative exponent function to generate critical value as the feedback 12 regulation of algorithm implementation. Also, combined Exchange Step, Move step with Flip step and 13 constitute of more than twenty combinatorial optimizations of program elements. It has been shown that the 14 integration of local search operators can significantly improve the performance of EMF-CE for TSPs. We 15 test small and medium scale (51-1000 cities) TSPs were taken from the TSPLIB online library. The 16 experimental results show the efficiency of the proposed EMF-CE for addressing TSPs compared to other 17 state-of-the-art algorithms.


23
The traveling salesman problem (TSP) is well known for the classical and fundamental NP-hard 24 combinatorial optimization problems. The classical TSP that can be described as following: find a path 25 through a weighted graph that starts and ends in the same city, includes every other city exactly once and 26 minimizes the total distance tour of n cities. The above-described path is always a Hamiltonian cycle or 27 tour. In the mathematical field of graph theory, the Hamiltonian path problem and the Hamiltonian cycle 28 problem are problems of determining whether a Hamiltonian path or a Hamiltonian cycle exists in a given 29 graph (whether directed or undirected). Both problems are NP-complete [1][2][3]. Special cases of the TSP that 30 included metric TSP, Euclidean TSP, asymmetric TSP, analyst's traveling salesman problem, and TSP path 31 length for random sets of points in a square. TSPs raise important issues because various problems in 32 (EAs) [18], neural network [30,31], and so on. These diverse approaches have demonstrated various degrees 48 of strength and success. 49 Most exact methods, e.g., Concorde, and heuristic methods, e.g., Lin-Kernighan, 2-Opt or 3-Opt, are not 50 (directly) applicable for asymmetric TSP cases since they are based on the triangle inequality of Euclidean 51 distance associated with symmetric TSPs. Methods for asymmetric TSPs are less studied with only a few 52 exceptions [32,33]. Of course, symmetric methods can be applied with some modifications to the problem 53 or the method itself. But, this may significantly increase the computation time or degrade their 54 effectiveness [29], [52]. Evolutionary algorithms(EAs) and Ant colony optimization (ACO) algorithms 55 have proved to be powerful methods to tackle such problems due to their adaptation capabilities. Such 56 methods are capable of finding the global optimum (or close to the global optimum) solution for symmetric 57 TSP cases in seconds. 58 annealing algorithm with greedy search to solve TSP, which was better than the former of the 66 performance [25,38]. In hybrid methods that PSO is used for determining parameters, and which affected 67 the performance of the ACO, and the 3-Opt is used for getting rid of the local solution found in the ACO 68 algorithm. The metaheuristics approach looks for more effective mutations, a more rational greedy search 69 strategy, and more universal adaptive parameter control of the proposed algorithm to achieve better results Evolutionary algorithms(EAs) [18] for tackling the large-scale cities. 74 The rest of this paper is organized as follows. Section II introduces the TSP problem definition and 75 describes how the TSP cases are generated. Section III describes the approaches from the literature that 76 have been applied to solve the TSPs. Section IV gives details of the proposed EMF-CE algorithm. Section 77 V presents the experimental studies that include comparisons with other popular heuristics and state-of-the-78 art algorithms. Finally, concluding remarks and future work directions are presented in Section VI. Quintessentially, a TSP instance is modeled by a fully connected weighted graph ( solving large-scale problem instances, respectively. As we all know, LKH-2 is the best search algorithm to 194 achieve the best optimal tour so far. Rego et al.[15] surveyed leading heuristics for the TSPs, which 195 gathered with Lin-Kernighan (LK) and stem-and-cycle (S&C) methods, as well known the most effective 196 and efficient local search ejection chain (EC) methods. Proposing six and two variants of the  Kernighan (LK) and stem-and-cycle (S&C) ejection chain method, respectively. Flip techniques, and cooperated the CE to search for the optimal solution of TSPs. We will use ten nodes as 215 an example to illustrate the process of the EMF-CE algorithm, as

231
Where 0 , it is indicated that the new path superior old path, then exchanged x 2 and x 4 two nodes.

232
Here, if 2 , then that the difference of tour length only is between the red and blue dashed lines should be the following: was called sequential [66], i was small to large, j>i) executed or inverse (i was large to small, j<i) executed.

244
Identically, for the next Move step and Flip step both should be executed and following this principle.

245
Given a feasible TSP tour, the algorithm repeatedly performs exchanges that reduce the length of the 246 current tour, until a tour is reached for which no exchange yields an improvement. All possible tours are made of ten nodes that more than one hundred and eighty thousand. But in the 250 original tour of ten nodes (the sequence was random permutation), where only exchanged 5 times and 251 instantly achieved optimal result Fig.1a-b. In the completely random (or random permutation nodes) 252 condition, where the exchange times will be an increase, while will not considerably increase, and also can 253 achieve preferably (maybe optimal) result. If found the better tour or smallest tsp (1)  lines, respectively. And the difference of tour length between the segments line should be as following: As a show, if 0 , only exchange the adjoin nodes x i and x j or move x j to the front of x i . When moving 279 multiple nodes (from two to five) that should make a judge whether may insert forward or insert backward, 280 and only picking the proper insert direction that can make a decrease. Depending on the orientations of 281 the paths within the current structure, the path between i and j city may have to be reversed. As illustrated 282 above that move could be forward or backward. For example, the original path (Fig.4a) that only by four 283 times single node moving and instantly can achieve the optimum result as shown in Fig.5-Fig.6 show. But 284 after another random permutation of the current tour that the move times will increase. Also, the move step 285 always stops after may n iterations if its rerouting strategy fails to improve the current best solution and 286 will immediately execute another step. A similar local search algorithm starts at some location in the search 287 space and subsequently moves from the present location to a neighboring location or interval two and three 288 nodes. Move algorithm is used for the purpose of improving tour arrangement operations. The concept of Flip in this paper that means Fliplr. If flip a segment line (or an edge) can make the tsp (1) 299 value decrease, then executed flip step operation. As Fig.7a, there is a crossover link between x 4 , x 5, and x 6 , 300 and this kink between edge(x 3 , x 4 ) and edge(x 6 , x 7 ) make tours more complex and lengthy. Therefore, 301 removing these kinks is wise action. Eliminating kinks from the current tour that means the path 3-4-5-6-7 302 should become 3-6-5-4-7, and achieve that only to flip x 4 , x 5 , x 6 to x 6 , x 5 , x 4 . The difference of tour length 303 between the new path and old path as following (Fig.7b, two blue and two red dashed lines): Universally, before or after flip that the difference of tour length δ, as follows, which only involved four 319 segments line (or edges): Where should instantly flip edges (x i , x j ) path, when the δ<0. As above example Fig.7a, which only flip 322 three times and could realize the optimum result. If the original path was completely disarrayed, requiring 323 number of times of flip will comfortably increase. As we know, flip step can easily eliminate the crossover 324 link than others step hard completed. It is an implementation of the path transform that for not generated 325 the kinks yet before, and also play a complementary role for combining the exchange and move steps, 326 accelerating the speed that tends to optimum results and finds the best solution.

329
It is easy to achieve global optimal for simple TSPs that only combined exchange, move and flip three 330 steps, while is hard to achieve global optimization for generalized traveling salesman problems. Here, we 331 used the contraction-expansion algorithm to expand the search spaces for searching for the best tours. The 332 algorithm is specified in exchanges (or moves, flips) that can convert one candidate solution into another 333 gainful move. Therefore, we set of rules for δ that gave an appropriate critical value ( crt supplement 334 algorithms 11), if crt , even though exchange and move steps may increase target function tsp (1) value, 335 we are still forced to execute these operations (the process of operation that we call redeploy of 336 enforceability). It can help to drop out the pitfall of the local optimal, and greatly increase the possibility of 337 realizing global optimal.

338
With the feasibility criterion that the loop is stopped as soon as the chain represents a gainful exchange, 339 and move, or when the chain cannot be produced better optimum tsp (1)    Practically, after certainly loops that random to implement those programs of elements, it can prevent 364 happened of invalid remove and vibration from the process of exchange and move nodes, also, yielding a 365 better tour solution and more efficient to nearness optimal solution. Included all process of these program 366 of elements is called loop times (round). It is impossible to achieve the global optimal for complicated 367 traveling salesman problems just one loop times, and even hundreds of cycle rounds for large scare TSPs.

368
But for small or middle scare TSPs that above procedure can produce a better tour solution. Above that procedure of exchange, move and flip the position of the start point, and endpoint won't 372 implement the exchange and move steps. Also, it was hard to generate efficient exchange for the closely 373 linked nodes. Sometimes, it will be not only left the dead corner to achieving the optimal tour, and also 374 obstruct from yield the global optimal tour. Therefore, after certainly loop times that need to redefine the 375 start node and keep the search for the best optimal tour. Usually, it is based on before generating the best 376 tour that random forward or backward move to certainly nodes, and rotate TSP cycle that the lots of  In this section, we describe the test problems and implementation details of the algorithms that we use 386 in our computational study. We present and discuss the results generated by other different algorithms that 387 have reported from the literature on the same problems in TSPLIB. Also, in our experiments, which we 388 presented a new evaluation index described as following, and it was used to evaluate the performance of 389 EMF-CE algorithm. And used the following index that was described as the efficiency index of EMF-CE 390 algorithm. the test problems, we both random permutation for the initial path (disorganize the original data sequence) 398 as the restart path after yield optimal solution. Which also records the optimal rates and time of achieved 399 the global optima twenty times. And gave the optimal solution of the result was from the Condore 400 1.1(current best software) running in windows as the benchmark. 401 We used the rates of optimal solution (R o =N o /N r , N o is the number of optimal, N r is the number of runs), 402 the average tour length, and median tour length as the power of evaluation index. And the efficiency of the 403 index included the shortest time, average time, and median time. By reason of complicated problems in a 404 set of loops can't all achieve global optima and early quit, which also can't calculate the meantime to reach 405 to global optima. In some way, it was fake that if we take early quit time into consideration. While median 406 time (must have more than half to achieve global optima) isn't affected by extremes value; therefore, it is 407 more stable and more valuable as an efficiency index. Executed one thousand times for this issue and the rates of optimal was 100%(Ro=1000/1000), also 420 all of the lengths of the tour were 426, but between all of them, the CPU time has a more significant 421 difference Fig.9. As the show that the last group was 53 times for CPU time more than 30 seconds. The 422 minimum and maximum CPU time was 0.05s and 65.01s, respectively. Because exist of the extreme value, 423 the mean of the CPU time was 5.09s (the red line show) which wasn't reasonable as the efficiency of the 424 index for indicating the effectiveness of the algorithm. While the median was 1.61s (the green line show) 425 and has run for 775 times that the CPU time was less than 3s to achieve global optimal, also, it is indicating 426 the median better than average as the efficiency of index.

427
As we all know, the tour length of the global optimal of eil51.tsp problem was 426. While we dig 428 deeper and found that situation was different. We tried to retain 3 decimals, the tour length was 429.118, 429 but this is not the real global optimal, and the tour length of global optimal should be 428.871 (the rounded 430 number was 427) Fig.10-b. Otherwise, if round the tour length to nearest the integer was 426 Fig.9 Fig 10 the global optimal solution of integer (a) and non-integer (b) for eil51.tsp problem the optimal results and relatively easy to obtain the optimal results, also convenient to compare each other 438 with different algorithms, which maybe was the reason for the widespread use. But there are some test TSP 439 problems, if retain 4~6 decimals, the optimal results will be the global optimal.

440
Where also executed one thousand times for ch150.tsp issue and the rates of optimal was 441 90.5%(Ro=905/1000), all of the lengths of the tours were 426, but between all of them, the CPU time has a 442 more significant difference Fig.10. And have 156 times for the CPU time more than 60s in the last group as 443 show Fig.10. The results indicated that minimum, average, maximum, and median tour length was 6528 444 (integer), 6593, 6531.06, and 6528, respectively. Also, the minimum, average, maximum, and median time 445 were 1.04s, 58.12, 760.66, and 1.61s, respectively. Indicating that already have Ro=726/1000 for the CPU 446 time less than 3s. It was also indicating that median time or tour length will be better than average time or 447 tour length as an index for proving the effectiveness of the algorithm. But the set of iteration times less than 448 300 that can't achieve global optimal.

449
There were three weak peaks that respectively nearby the 20s, 40s, and 50s both achieved the global 450 optimal. After researched the program and found that appeared these phenomena, which has certain 451 relations with the periodic variation of crt. While these peaks relatively the crt value both in the bottom and 452 easy to achieve global optimal after early big crt value broke the pitfall of local optimal. For the other test that the new algorithm to achieve global optimal with a shorter median time, and another small part of it 457 takes a long time to run. With the complexity of the problem, this phenomenon will become more obvious.

458
This also reflects algorithmic programs to improve the possibility of need.

461
All the experimental results were obtained by an Intel(R) Core(TM)2 Duo 2.93GHz with 2-GB main memory 462 using MATLAB environment and running the Windows 7 operating system. For comparing EMF-CE with other 463 algorithms in terms of CPU time, we scaled the CPU time of each algorithm by an appropriate scaling coefficient 464 related to its processing system. We utilized the results reported to obtain the scaling coefficients as shown in Table I. 465 Note that the codes made by 3-GL programming languages such as C/C++, PASCAL, and FORTRAN are more 466 efficient than M-codes in the MATLAB interpreter. Nevertheless, we did not consider any scaling coefficient for 467 comparing M-codes with 3-GL codes. In other words, it is expected to obtain better performance by implementing 468 our algorithm using an efficient programming language like C or C++. 469 We select 43 problems from the TSPLIB online library. Each problem is randomly generated. We use Euclidean 481 distances (all of the Euclidean distances are real distances). The problems range in size from small to middle-scale 51 482 to 1000. Following Johnson and McGeoch[71], and only on e running pr2392 was performed for this instance, which 483 were used in previous computational studies (see Jin et al. [19,25,26,62,70]. Each entry gives the number of nodes 484 in the problem (e.g., eil51 has 51 nodes). We use the approximate Euclidean distance metric specified in TSPLIB. 485 Moreover, we did not apply EMF-CE to the instances with 3000 or more cities since it would have taken too much 486 time (future work for large TSP). Therefore, we considered only a qualitative comparison between the different 487 algorithms. The results are listed in Table II. For each benchmark problem, the first ten columns of this table are 1) 488 number; 2) the TSP name; 3) optimal tour length (OPT) as reported in TSPLIB, and some in stances renew calculated 489 that used the Concorde (http://www.math.uwaterloo.ca/tsp/concorde/gui/gui.htm), and 4)described inⅤ.A 5) were 490 Shortest tour lengths (SL, the result from EMF-CE) and RE(%); 6) average tour lengths(AL) and RE(%); 7) median 491 tour lengths(ML) and RE(%); 8) the shortest of running time in second; 9) the average of running time in second; 9) 492 the median of running time in second. And the CPU time of average and median distribution as the Fig.11 scatter 493 diagram demo. Also, in order to facilitate comparison with different algorithms. According to Pepper et al. [46], we 494 split the set of selection problems into the first three sets that 51 to 299 nodes(31 instances), 318 to 574 nodes(7 495 instances), and 666 to 100 and one 2392 nodes(5instances). 496  As illustrated in Fig. 12, the three evaluation indexes showed that the solution qualities of EMF-CE are range 507 0.00% ~ 0.46%, 0.00%~2.28%, and 0.00%~2.58% for all test benchmark TSPs TABLE II. Furthermore, EMF-CE 508 gave the optimal solutions for 29 benchmark TSPs, in which the number of cities less than 300. 509 510

D. Comparing with Computationally Comparable Algorithms 511
In this section, we compared EMF-CE with several well-known evolutionary algorithms, simulated annealing, 512 evolutionary algorithms, and neural network including ASA-GS, GCGA, HGA, CONN, and LBSA, and so on. , respectively. Also, these algorithm methodologies that we 514 already briefly described in section II. EMF-CE has a competitive computational complexity with respect to these 515 algorithms (O(n 3 )). The third set of experiments was performed on 38 benchmark TSPs from TSPLIB with 51(small-516 scale) to 783 cities (medium-scale). The results are only given the percent difference of shortest tour lengths in Table  517 III. 518 For average shortest tour length that corresponding to the same TSP instances and EMF-CE provided 0.35%, 519 1.49%, 0.82, 3.11%, and 0.02% improvements over ASA-GS, GCGA, HGA, CONN, and LBSA, respectively. When 520 we also split the set of problems into three sets, as described in section V.C. Over the corresponding to first set 521 problems Fig.13, we see that EMF-CE and LBSA was the most accurate algorithm with the difference of 0.003%. 522 However, EMF-CE provided 0.22%, 0.92%, 0.47%, and 2.75% improvements over ASA-GS, GCGA, HGA and 523 provided 0.16%, 0.80%, 3.09%,4.62% and 4.51% improvements over LBSA, ASA-GS, HGA, GCGA and CONN to 525 the average shortest tour length, respectively. We can see that for the medium-scale TSPs, and the EMF-CE gave the 526 best tour length. 527

VI. CONCLUSION 537
In this paper, we presented a new method, which Contraction -expansion algorithm based on Move, Change, and 538 Flip three operators called EMF-CE for TSPs. The main purpose of designing EMF-CE is to achieve near to optimal 539 solution quality and the most accurate algorithm while the method would give comparatively slower of convergence 540 speed. Its computational intensity is O(n 3 ). But it is now can achieve global optimal for the small scale TSPs. For the 541 generalized traveling salesman problems that round number and round integer may affect the end optimal result. 542 Usually can take 4 to 6 significant digit to calculate the distance and TSP path length, in order to prevent the loss of 543 precision and affect the realization of the optimal solution. 544 The EMF-CE performance was compared with those of several computationally comparable including ASA-GS, 545 GCGA, HGA, CONN, and LBSA, etc.. in terms of the qualitative comparison between those algorithms. However, we only show that five algorithms compares with the EMF-CE (have compared and reported in[25, 26, 38, 54], etc.). 547 Cause the others state-of-the-art (GATM, GSM, SA, ITS, GSA-ACS-PSO, RABNET-TSP, and MSA-IBS, etc. have 548 described and overviewed in section II) algorithm that can't give the best tour lengths (reach to global optimal) for 549 the small scale TSPs and let alone the medium-scale TSPs. Where EMF-CE has outperformed these state-of-the-art 550 NNs and evolution algorithms in terms of accuracy and in a reasonable time for the best tour length and average tour 551 length. But these algorithms provided a better and promising CPU time with poverty solution quality. Also, the CPU 552 time of EMF-CE with M code and only using single-core for computing. Moreover, the scaling coefficients large 553 than any 3G program language TABLE I. In other words, it is expected to obtain better performance by 554 implementing our algorithm using an efficient programming language like C/C++. 555 Future work should investigate and improve convergence speed. While the encouraging results presented here led 556 us to adapt the algorithm to solve more complex routing problems, such as both symmetric and asymmetric DTSPs, 557 and the capacitated vehicle routing problem (CVRP). Also, further investigations must be performed with larger TSP 558 instances and hybrid use of the proposed algorithm with route improvement heuristics, such as k-opt and simulated 559 annealing.