r*u,cut the segment rq, insert it between e f. Case1—one new break point.Step 2:dhijklabcmfqrep*uStep 3:dhijklaperqfmcb*uStep 4:dhi*bcmfqrepalkjuStep 5:dhilaperqfmcb*kjuStep 6:dhilabcmfqrep*kjuStep 7:dhi*perqfmcbalkjuStep 8:dhi*fqrepmcbalkjuStep 9:dhi*rqfepmcbalkjuStep 10:dhilabcmpefqr*kjuStep 11:dhilabcmperqf*kjuStep 12:dhilabc*fmperq*kju Case 2—two new break points, you cannot get less. Choice q*k as the new mainbreak point, another break point can be the same asformers.Step 13:dhilabc*fqrepm*kju m*k as the new mainbreak point, cannot choice c*f at current stepStep 14:dhi*mperqf*cbalkjuStep 15:dhi*qrepmf*cbalkjuStep 16:dqrepmf*cba*hilkju the main cycle has 3 partsStep 17:dqrepmf*abchilkju the main cycle has 2 partsStep 18:dqrefmpabchilkju Case 3—no new break point, only one part
Our main proof idea is: using limited number of graphs,each graph only has 12 vertices(also 11,10), to constituteunlimited number of all kinds of graphs. Then we onlyneed to prove all cases of graphs with 12 vertices(also11,10) to fit our algorithm(need to combine and to split) bycalculating all.
From the algorithm, we can see, at each step, nomatter how many vertices the graph has, only at most 6parts or 12 vertices are important. Assume the graph has atleast one Hamilton cycle. At each step of our algorithm,there always is a Hamilton cycle(we call it “mainHamilton cycle”) which has the following characters: themain Hamilton cycle has k parts at current step, for eachpart, the two end vertices are very important, the innervertices are not. We can delete all or some of the innervertices, then the rest still fit our algorithm. Also we candelete any whole part of the main Hamilton cycle. Afterdeleting a whole part, one edge should be added, in orderto keep the main Hamilton cycle. In this way, any biggraph can be constituted by many 12 vertex graphs at anystep of our algorithm.For example, in example 1,at step 11, we can deletevertices r and/or i,, the inner vertex. Also we can delete thewhole part “qre”, then add an edge between f and d. Andwhen “qre” be deleted, the vertices f and p be connectednaturally. Notes: A big graph can become many smallgraphs(with 12,11,or 10 vertices) by all available deleting,
the other direction is also true
(the word “all” isimportant)!
In example 1, no matter for case 1,case 2, or case 3,when the graph’s number of vertices is bigger than somefigure, say 24, we always can delete some part or vertex,the case does not change. So each time, we at most need toconsider 24 vertices(by combining some 12 vertexgraphs).
At first, any Hamilton cycle can be as the mainHamilton cycle. The main Hamilton cycle keeps all theway down, no matter deleting, combining and separatingas described before, until the final(The final result may beanother cycle). At any step until the final, if we do the “cutand insert” in this way: to keep every part of the mainHamilton cycle as a whole, other rules are the same asdescribed before, we can do it, and the least number of new break points is at most 2. This character is veryimportant for our proof.From
, we can see our proof only need tocalculate all cases of 12(include 11, 10) vertexgraphs(need to combine and separate). Thus all. Thecalculation is a very big job, but there are some ways todecrease it a lot.
EXPERIMENT DATAThough we have theoretically proved this algorithm.Here we give the experiment data.A program on this algorithm has been designed inVC++. Not losing generality, for an undirected graph withN nodes, node number is 0,1,2…N-1, the algorithmcalculates Hamilton path from node 0 to node N-1. Theinput data is randomly produced un-directed graphs. Inorder to test the program, each graph includes a randomlyproduced Hamilton path which the program does not know.We have tested the program over one hundred millioninputs, no one fails. The data is as Table 1 (computer:HPPC, CPU:Intel 1G, Memery:1G):
TABLE 1 EXPERIMENT DATAnumberof Nodescalculationtimes ondifferentinputssuccesstimesfailtimesaveragerunningtime100 100000000 100000000 0 0.0014second1000 10000000 10000000 0 0.07second10000 10000 10000 0 48seconds