Analysis and Counterexamples Regarding Yatsenkos Polynomial-Time Algorithm for Solving the Traveling Salesman Problem

Yatsenko gives a polynomial-time algorithm for solving the traveling salesman problem. We examine the correctness of the algorithm and its construction. We also comment on Yatsenko's evaluation of the algorithm.

Authors: Christopher Clingerman, Jeremiah Hemphill, Corey Proscia

Analysis and Counterexamples Regarding Yatsenkos Polynomial-Time   Algorithm for Solving the Traveling Salesman Problem
Analysis and Coun terexamples Regarding Y atsenk o’s P olynomial-Ti me A lgo rithm for Solving the T ra v eling Salesman Problem Christopher Clingerman Jeremiah Hemphill Corey Proscia The Univ ersit y of Ro ches ter Computer Science Departmen t Ro ch ester, NY 1462 7 T echnic al Rep ort No v em b er 2018 Abstract Y atsenk o giv es a p olynomial-time algorithm for solving the tra v eling s alesman problem. W e examine the correctness of the algorithm and its constru ction. W e also commen t on Y atsenko ’s ev aluatio n of the algorithm. The Universit y of Rochester Computer Science Department s up p orted this w ork. 1 In tro duc tion In th e stu dy of computer s cience, one of the most i nteresting a nd difficult qu estions is whether the set of P problems equals the set of N P problems. P is the class of languages that a re decidable in p olynomial time on a d eterministic T u ring mac hine (Sip06). N P is the class of languages th at ha ve p olynomial-time v erifiers. Currentl y it is unknown whether P = N P , but if those tw o complexit y classes are indeed equiv ale nt, it means that all problems in N P can b e solv ed in p olynomial time. Ho w ev er, if it tur n s out that P 6 = N P , ev ery one of the h un d reds of imp ortan t, natural N P -complete problems is not solv able in p olynomial time. Th e implications of P a nd N P equiv alence or inequalit y are incredibly imp ortant to the computer science comm un it y and to r elated fields. One p articularly imp ortant pr oblem that is currently kno wn to b e in N P i s the tra v eling salesman problem. T h is pr oblem is also N P -complete b ecause it is in N P and every pr oblem in N P is reducible to it in p olynomial time (Sip06), so if the tra v eling salesman problem can b e solv ed in p olynomial time, then every problem in N P can b e solv ed in p olynomial time and P = N P . The T rav eling S alesman Problem is state d th usly: a tra veli ng salesman has a table of d istances b et w een N cities. He wishes to tra vel to eac h of these cities in turn and try to sell h is wares. He also w an ts to min imize th e distance he tra v els in order to sav e time and tra v el exp enses. Ho w ev er, he can only visit eac h cit y once, and he must fi nish at the same cit y from whic h he started. A b rute force solution that examines ev ery p ossible route wo uld examine all N ! routes, whic h is impr actical for ev en mo derately large v alues of N . As one can see, the complexit y of this problem seemingly quickly increases with the num b er of cities. In his p ap er (Y at07), V adim Y atsenko claims to ha ve found an algorithm that b oth solv es th e tra ve ling salesman pr oblem and runs in p olynomial time. Ho w ev er, Y atsenk o’s algorithm on some inputs pro d u ces incorrect r esu lts, and ev en Y atsenk o’s pap er (on its second page) concedes that it is less reliable for larger v alues of N . 2 Description of the Algorithm Y atsenk o giv es an algorithm for solving the tra v eling salesman problem (Y at07). The algorithm is broke n in to three steps. The fir st t wo steps describ e how to start the algorithm, and the third step is applied iterativ ely . T he algorithm starts by creating a route with three p oin ts, whic h forms a triangle. This triangle is computed b y connecting the t wo p oin ts that are the farthest apart. A third p oint is add ed so that the route connecting all three p oints, or the sum of the distances b et w een the three pairs, is the largest p ossible. After th e triangle is constructed, p oin ts are added one at a time. F or eac h edge on the route, a third p oint is selected wh ose addition to the r oute, r ep lacing the edge, w ould c hange the length of the rou te by the smallest amount. This c han ge of length is referred to as the d isturbance and is the sum of the tw o added edges minus the remo v ed edge. Then, out of all of the thus chosen third p oin ts (one p er edge), 1 Figure 1: initial setup f or m ax-min the one wh ose add ition creates the greatest distur b ance is add ed to the r oute. This pro cess is rep eated, adding p oints to th e route one at a time, u n til all p oints are added. A t eac h step, the p oin t with the maxim um of the minim um disturbances is added. 3 Correctness of the Algorithm 3.1 The Max-min Algorit hm Y atsenk o claims that the inv erse of a cutting pr o cedure giv es an adding pro cedur e that giv es the optimal solution. Th e adding pro cedure that Y atsenk o describ es is not the in v erse of t he cutting pro cedure, and it do es n ot reconstruct the optimal solution. The cutting p ro cedure b egins w ith an optimal route, t he solution to a trav eli ng salesman p roblem. A t eac h step of the cu tting pro cedu re, Y atsenko remo ves the p oint that giv es the least d isturbance to the length of the rou te. When the p oint is remo v ed, the t w o p oin ts adjacen t to it on the r oute are connected, and the magnitude of the length of the added path minus the t w o remo v ed is the disturbance. T he magnitude of the d isturbances in cr eases as eac h v ertex is cut from th e rou te. In the final step of th e add ing pro cedur e, ther e is only one c hoice of whic h p oint to use for eac h edge in the current route. Of the w ays to replace these edges with t wo edges to the p oint , a ccording to the algorithm, t he one that give s the maxim um disturbance should b e chosen. Consid er Figur e 1, w h ic h giv es the initial triangle and a fourth p oint of a graph. This example is in Euclidean space, although Y atsenk o claims that his algorithm works in the general case. The initial triangle w as constructed by connecting p oints A and B, w hic h are the farthest apart, and adding p oint C to increase the route’s length by the largest amount. F or eac h edge, the only remaining p oin t is selected, and the edge whose replacemen t giv es the largest d isplacemen t is remo ved. This giv es the r oute sh own in Figure 2, wh ile the 2 Figure 2: max-min incorrect solution Figure 3: max-min correct solution optimal route is shown in Figure 3. This example sho ws that the add ing pr o cedure do es not giv e the optimal r oute, and it is not th e in verse of the cu tting pro cedur e. 3.2 The Min-min Algor ithm An alternativ e adding pr o cedure is to consider changing the route b y t he least amoun t p ossible at eac h step, s tarting with the same initial triangle, s o we also consider the m in -min case as b oth an in ve rse to the cutting pro cedure and with a coun ter-example of correctness. A t eac h step, th e p oin t with the min im um disturb ance is add ed. F or example, a no de that giv es the minimum d isturbance is added, f ollo w ed by adding another no de with min im um disturbance. If a no de is selected to b e cut, it w ould b e the fi r st no de added, not the most recent, assuming that the t wo no des are n ot adjacen t. If the no de with the minimum disturb an ce is add ed and then the no de with th e min im um disturbance is subtracted, they are not alw a ys the same, so the cutting p r o cedure 3 Figure 4: initial setup f or m in-min and this add ing p ro cedure do not remo v e and add p oin ts in th e same order. Since adding a p oin t and then cutting a p oint do es not alwa ys add and cut the same p oin t, the min-min adding pr o cedure and the cu tting pro cedur e do not corresp ond. Sp ecific graph constru ctions can also lead to coun ter-examples f or th is algorithm. Simply c hec king for the absence of intersect ions is n ot sufficient to sho w th at the route is optimal. Consid er the set of p oints in Figure 4 with the initial three r ou tes already determined. The three outer p oin ts form the initial triangle and the r est of the p oin ts fall inside of it. The distances b et we en the p oin ts can b e arranged so that the algorithm will p ro cess th e inner p oin ts in sequence, mo ving fr om th e outside to w ards the cen ter as in Figure 5. On ce all the p oin ts ha v e b een included, the route is sho wn in Figure 6, whic h is not the optimal route. The optimal rou te should connect the top p oin t to the other p oints w ith the shortest distance p ossible. Since the distance from the top to the side is sm aller than the d istance from the top to the midd le, the optimal route is s h o wn in Figure 7. 4 Exp onent ial Sub cases As Y atsenk o ment ions, situations can o ccur when m ultiple no des satisfy th e condi- tion to b e added. F or all b ut the initial r ou te of t wo p oints, this set of solutions can b e denoted max r k ∈ R i min p j ∈ P N − R i ∆( r k , p j ) → ( r k , p l 1 ) , ( r m 1 , p l 1 ) ... It m ay b e necessary , if one assu mes that tied cases are viable and must b e b rute-force explored, to searc h eac h solution along all p ossible v ariations of r i +1 j in termediate sub-routes, w here j is the n umb er of p ossib le solutions. T o solv e th is problem, the algorithm must essen tially run itself once for eac h p ossible solution from that p oint 4 Figure 5: p oints are pro cessed inw ard from the outsid e Figure 6: actual route with the min-min algorithm 5 Figure 7: optimal route forw ard. In addition, sub sequent steps ma y also ha ve multiple su bproblems, eac h of w h ic h must b e examined separately . When this s ituation o ccurs the ru n-time of the algorithm can n o longer b e considered O ( N 3 ). One d egenerate situation is a square grid of equally spaced no des in patterns of squares (see Figure 8.) In this case, nearly ev ery d ecision by the algorithm leads to m ultiple su bproblems. F or the initial R 2 route, there are t wo different c hoices, the ma jor and minor diagonals. The R 2 route calculates the maximum distance instead of the minimum and the solutions are d enoted, max p i ,p j ∈ P N d ( p i , p j ) → ( p k 1 , p l 1 ) , ( p k 2 , p l 2 ) ... Similarly , for the th ird no d e, there are t wo d ifferent solutions. Based on which diagonal is c hosen, th e tw o p ossible solutions are the corners opp osite the d iago- nal. After s electing t w o no d es, the algorithm now m ust calculate four iterations sim ultaneously . Once the initial maxim um size triangle is created, th e algorithm searc hes for the minim um increase in route distance. In this case, there are 3( N − 2) p oints that fall on the maximum triangle. Although an intelli gent algorithm could ignore these p oints and add them automatically , this is not sp ecifically handled in the pap er. The algorithm must iterate o v er every no d e to consider all the s olutions. In addition, after the first set of solutions is handled, the remaining 3( N − 2) − 1 n o des m ust b e considered for eac h iteration. F or a 100 n o de graph, there are an additional (3 × (10 − 2))! iterations of the algorithm, one for eac h p ermutation. After these zero-length increases of disturb ance, the smallest increase in total route length comes from c hanging a diagonal into t wo horizonta l or v ertical lines. If the distance b et wee n n o des is d , this pro cedu re adds d × √ 2 − d distance to th e total 6 Figure 8: example situation causing exp onen tial sub cases route. A solution set of 2( N − 2) n o des adjacen t to the ma jor or m in or diagonal m ust b e considered. If the algorithm iterates on a n o de on the corner of the grid, 2( N − 2) − 1 no des must still b e considered. On any other no d e in the solution set, 2( N − 2) − 2 no des will b e in the solution set in the next step. F or a 100 no de graph, this is an increase of 9! iterations of the algorithm. Once all the diagonals ha v e b een remo v ed, a t wo step pro cedur e of addin g a diagonal and remo ving it can b e u sed to fi ll in the rest of the graph . The solution set consists of eac h n o de adjacen t to the current route. Eac h no de has an av erage of t w o wa ys to connect it to the graph usin g a single d iagonal and a single h orizon tal or v ertical add ition to the route. O nce this c hange is made, the minimal route increase is to add the no d e th at remo v es the diagonal. This pro cess is rep eated to add the rest of th e no des to the route. This will add a significant num b er of iterations to the algorithm. Almost ev ery d ecision in this graph requires simulating additional instances of the route. Due to this, the algorithm no longer op erates in p olynomial time. A prun in g m etho d ma y b e p ossible to a v oid considering ov erlapping su bproblems, bu t this is not sp ecified in the algorithm. A graph with a grid or su bsection of a grid of equally spaced no des will alwa ys hav e this problem. 5 Commen ts on Y at senk o’s Ev aluation In h is pap er, Y atsenk o informs the reader that in ord er to v erify his algo rithm ’s success in fin ding the solution to a d ata set, he uses what h e calls “visual insp ec- tion.” Also provided in the pap er are several images of d ata sets with su p erimp osed solutions for N = 500, 1000, and 2000. Up on analysis of these images, ho we ver, one finds that a visual insp ection appr oac h to verify a s olution is n ot accurate. T his 7 ma y b e a goo d to ol for v ery small v alues of N , b ut for v alues of 500 and ab ov e, it is n ot an accurate metho d of determining the corr ectness of a solution. An alternativ e to visual insp ection would b e to use instances from standard data sets that ha v e known s olutions (VLS03). After runn ing the algorithm on th is data set, the total distance of the route the algorithm giv es could b e compared with the published resu lt. Man y heuristics also exist for the tra v eling salesman p roblem, whic h may pro vide a less thorough metho d of v erifying a resu lt for an u npub lished instance. Y atsenk o also admits that his algorithm f orms “lo ops” on a growing p ercen tage of solutions o v er random data sets as N increases. W e in terpret loops to mean the route intersects with itself. These solutions are n ot optimal b ecause unwinding the in tersection alw a ys give s a shorter route. F or pr oblems w ith 2000 p oints, Y at- senk o states these in tersections form 4 out of 5 times. Even if Y atsenko ’s algo rithm succeeds in op erating in p olynomial time, as the v alue of N increases his algorithm b ecomes more u nstable in that it p ro duces incorrect s olutions with greater frequency . While the algorithm may work for some N , it is n ot a v alid general solution for the tra v eling salesman p roblem. 6 Conclusion Y atsenk o’s solution to the tra v eling salesman pr oblem d o es not alw ays pr o duce op- timal results, so it cannot b e clearly considered an exact (in the sense of optimal) solution. It ma y b e considered a h euristic, but he do es not ev aluate it as one. Y at- senk o’s o wn ev aluation of the algorithm rev eals some cases where it give s incorrect solutions ev en though the ev a luation do es n ot detect all errors . There are cases where th e s ubprob lems formed b y equidistan t v ertices o v erlap, bu t the algorithm do es not sp ecify how to eliminate them, so th ere m ay b e an exp onentia l num b er of subpr oblems, and th e runnin g time of the algorithm would not b e p olynomial in the w orst case. 7 Ac kno wledgmen ts W e thank Lane Hemaspaandra and Saur abh Deshpande, the professor and teac hing assistan t for the course in w hic h we started this note, for helpful f eedb ac k on earlier drafts and sup p ort in editing. References [Sip06] M. Sipser. Intr o duction to the The ory of Computat ion . Thompson Course T ec hnology , 2006. [VLS03] VLSI Dat a Sets. http://w ww.tsp.g atech.edu/vlsi/index.html , 2003. 8 [Y at07] V. Y atsenk o. F ast Exact Metho d for Solving the T r a v elling Salesman Prob- lem. Arxiv pr eprint cs.CC/0702133 , 2007. 9

Original Paper

Loading high-quality paper...

Comments & Academic Discussion

Loading comments...

Leave a Comment