The study presents the Half Max Insertion Heuristic (HMIH) as a novel approach to solving the Travelling Salesman Problem (TSP). The goal is to outperform existing techniques such as the Farthest Insertion Heuristic (FIH) and Nearest Neighbour Heuristic (NNH). The paper discusses the limitations of current construction tour heuristics, focusing particularly on the significant margin of error in FIH. It then proposes HMIH as an alternative that minimizes the increase in tour distance and includes more nodes. HMIH improves tour quality by starting with an initial tour consisting of a ‘minimum’ polygon and iteratively adding nodes using our novel Half Max routine. The paper thoroughly examines and compares HMIH with FIH and NNH via rigorous testing on standard TSP benchmarks. The results indicate that HMIH consistently delivers superior performance, particularly with respect to tour cost and computational efficiency. HMIH's tours were sometimes 16% shorter than those generated by FIH and NNH, showcasing its potential and value as a novel benchmark for TSP solutions. The study used statistical methods, including Friedman's Non-parametric Test, to validate the performance of HMIH over FIH and NNH. This guarantees that the identified advantages are statistically significant and consistent in various situations. This comprehensive analysis emphasizes the reliability and efficiency of the heuristic, making a compelling case for its use in solving TSP issues. The research shows that, in general, HMIH fared better than FIH in all cases studied, except for a few instances (

Various methods exist to solve the Travelling Salesman Problem (TSP), including exact solutions and heuristics [

The TSP is simple to define, but the complexity can easily expand exponentially as the solution space increases; thus, it is classified as an NP-Hard problem [

Exact techniques involve the explicit enumeration of the solution space; they try out all possible permutations of the solution. Thus, they have a complexity of

Unlike precise methods [

There are different classifications of heuristics based on the atomicity of their solution procedures, such as Tour Construction, Improvement/Local Search Heuristics, and Compound Heuristics [

Construction heuristic techniques have been widely utilized in addressing traditional combinatorial optimization challenges. Various methods, such as the Nearest Neighbour Heuristic (NNH), Nearest Insertion (NIH), Cheapest Insertion, Random Insertion, Addition heuristics, Savings Heuristics, and more are commonly used. Existing tour construction methods typically fall short by between 10–30% in terms of solution quality with a worst-case complexity of

Some well-known constructive heuristic methods are described briefly in

HEURISTICS | DESCRIPTION |
---|---|

Nearest Neighbour Heuristic (NNH) | The NNH starts its tour with a single subtour of node/city |

Nearest Insertion Heuristic (NIH) | The NIH belong to the class of Insertion Heuristics. The Insertion heuristics start from an arbitrary point to form a sub-tour or partial circuit. Nodes not already in the subtour are then inserted based on predefined criteria such that the increment to the total distance of the subtour is minimized. Given the sub-tour |

Farthest Insertion Heuristic (FIH) | The FIH obtains a tour solution by first building its sub tour; initial node |

Cheapest Insertion Heuristic (CIH) | This method is reminiscent of the Nearest Insertion heuristic. Commence at node |

Random Insertion Heuristic (RIH) | The Random Insertion Heuristic starts by choosing two arbitrary nodes |

The Nearest Neighbour Heuristic can efficiently solve the TSP, albeit with slightly lower solution quality. The Nearest Neighbour Heuristic is a popular choice in research due to its quick implementation and straightforward approach. Experimentally,

Recent research has highlighted the importance of using the Nearest Neighbor Heuristic in ways such as integrating it into methods [

Lity et al. [

In implementing the Iterated Local Search technique, Bernardino et al. [

In the study by Kitjacharoenchaia [

Víctor et al. [

Insertion heuristics starts from an arbitrary point to form a sub-tour or partial circuit. Nodes not already in the sub-tour are then inserted based on predefined criteria such that the increment to the total distance of the sub-tour is minimized [

Insertion techniques are desirable because of their speed, ease of implementation, quality of solutions, and the fact that they can be easily modified to handle complex constraints [

Insertion techniques can be used to get a good tour construction solution [

Experimentally, the Farthest Insertion Heuristic has been known to outperform the Random Insertion, the Cheapest Insertion, and the Nearest Insertion in that order [

The proposed technique is an insertion method referred to in this study as the Half Max Insertion Heuristic (HMIH). The motivation was to explore some strategies with the possibility of improved tour accuracy. The design of the HMIH was motivated by two observations in literature: One, the superior solution quality of insertion techniques based on the use of polygons as an initial tour [

Suppose that a new node

The insertion heuristics randomly pick one node from

Let

Consider an insertion of a node

The method first determines the longest distance.

The procedure is as follows:

The HMIH searches require

In implementing the proposed technique, the JAVA programming language version 13.0.1. was used, while GNUplot 5.2 and patch-level eight were used to plot the path graph. The heuristic was implemented on Intel Pentium Core i7 3 GHz, Windows 10 (64 bit).

We experimented with the HMIH, together with two State-of-the-art heuristics (namely Nearest Neighbour Heuristic (NNH) and Farthest Insertion Heuristic (FIH)) on ten publicly available benchmark instances from TSPLIB made available by Heidelberg University on

S/N | Instances | No. of nodes | Computational speed ( |
||
---|---|---|---|---|---|

NNH | FIH | HMIH | |||

1 | 48 | 14.9 | 19.5 | 24.8 | |

2 | 51 | 24.0 | 26.2 | 28.4 | |

3 | 101 | 5.1 | 83.7 | 99.2 | |

4 | 130 | 28.4 | 130.3 | 85.0 | |

5 | 150 | 8.4 | 163.0 | 217.3 | |

6 | 439 | 74.7 | 458.4 | 707.8 | |

7 | 783 | 284.6 | 340.6 | 723.9 | |

8 | 1000 | 487.6 | 1334.3 | 2054.9 | |

9 | 2319 | 334.4 | 2.316.4 | 4.072.9 | |

10 | 3038 | 652.8 | 6.571.1 | 10118.5 |

S/N | Instances | No. of Nodes | OPT | Tour cost | ||
---|---|---|---|---|---|---|

NNH | FIH | HMIH | ||||

1 | 48 | 33523 | 40524 | 35775 | 35657 | |

2 | 51 | 426 | 510 | 471 | 471 | |

3 | 101 | 629 | 811 | 690 | 690 | |

4 | 130 | 6110 | 7198 | 6951 | 6650 | |

5 | 150 | 6528 | 8191 | 7542 | 7211 | |

6 | 439 | 107217 | 139149 | 122957 | 124322 | |

7 | 783 | 8806 | 10779 | 10828 | 10434 | |

8 | 1000 | 18659688 | 24631468 | 23563031 | 20610943 | |

9 | 2319 | 234256 | 281978 | 272959 | 256601 | |

10 | 3038 | 137694 | 175788 | 173038 | 166196 |

It is evident from

The FIH and HMIH tour graph for some benchmark instances is presented in

Non-parametric analysis was conducted using Friedman’s test to validate the superior performance of the HMIH solutions for both NNH and FIH, which are classic tour construction heuristics. The test was conducted for all the ten instances considered in this study. The Friedman ranking was conducted based on the tour cost of the three algorithms, as presented in

Heuristic | Mean rank |
---|---|

Nearest Neighbor Heuristic (NNH) | Average Rank = 2.7 |

Farthest Insertion Heuristic (FIH) | Average Rank = 2.2 |

Half Max Insertion Heuristic (HMIH) | Average Rank = 1.1 |

These rank scores indicate that, on average, the HMIH algorithm (with the least score) performed best, followed by FIH and NNH.

Given the rank, as presented in

The test was premised on the following hypothesis

- Null Hypothesis

- Alternative Hypothesis

Thus, Friedman’s test on the given data instances for the three TSP heuristics (NNH, FIH, HMIH) yielded a test statistic of approximately 15.37 and a

Friedman’s analysis revealed that the HMIH technique exhibits a statistically significant superiority to NNH and FIH in performance.

The quality of the heuristic’s solution was assessed using the following factors:

S/N | Instances | No. of nodes | HMIH (%) | FIH (%) | NNH (%) | |||||
---|---|---|---|---|---|---|---|---|---|---|

1 | 48 | 6.3 | 14.6 | 0.4 | 93.7 | 6.7 | 93.3 | 20.9 | 79.1 | |

2 | 51 | 10.6 | 9.1 | 0 | 89.4 | 10.6 | 89.4 | 19.7 | 80.3 | |

3 | 101 | 9.7 | 19.2 | 0 | 90.3 | 9.7 | 90.3 | 28.9 | 71.1 | |

4 | 130 | 8.8 | 9.0 | 5.0 | 91.2 | 13.8 | 86.2 | 17.8 | 82.2 | |

5 | 150 | 10.5 | 15 | 5 | 89.5 | 15.5 | 84.5 | 25.5 | 74.5 | |

6 | 439 | 15.9 | 13.9 | −1.2 | 84.1 | 14.7 | 85.3 | 29.8 | 70.2 | |

7 | 783 | 18.5 | 4.9 | 4.4 | 81.5 | 22.9 | 77.1 | 22.4 | 77.6 | |

8 | 1655 | 10.5 | 21.5 | 15.8 | 89.5 | 26.3 | 73.7 | 32 | 68 | |

9 | 2319 | 9.5 | 10.9 | 7 | 90.5 | 16.5 | 83.5 | 20.4 | 79.6 | |

10 | 3038 | 20.7 | 7 | 5 | 79.3 | 25.7 | 74.3 | 27.7 | 72.3 |

From

The shaded area of the chart denotes the quality improvement of the HMIH over the FIH.

The proposed Half Max Insertion Heuristic consistently outperformed the Farthest Insertion. As seen by the shaded region of quality improvement in

Additionally, while the Farthest Insertion is faster, the computation speed of the proposed HMIH is within the same range, and since the HMIH searches were conducted

The authors gratefully acknowledge the support of the Landmark University Center for Research Innovation and Development (LUCRID) for access to research repositories, literary materials, useful insights from affiliate researchers and funding.

This research is supported by the Centre of Excellence in Mobile and e-Services, the University of Zululand, Kwadlangezwa, South Africa.

The authors confirm their contribution to the paper as follows: Study conception and design: E. O. Asani, A. E. Okeyinka; data collection: A. A. Adebiyi, E. O. Asani, and R. O. Ogundokun; methodology: A. E. Okeyinka, A. A. Adebiyi, and E. O. Asani; validation and visualization: E. O. Asani, R. O. Ogundokun, T. S. Adekunle, P. Mudali, and M. O. Adigun; analysis and interpretation of results: E. O. Asani, S. A. Ajagbe, T. S. Adekunle, P. Mudali, and M. O. Adigun; draft manuscript preparation: R. O. Ogundokun, E. O. Asani, S. A. Ajagbe. All authors reviewed the results and approved the final version of the manuscript.

The data used for the implementation of this study is publicly available benchmark instances from TSPLIB made available by Heidelberg University on

The authors declare that there is no conflict of interest regarding the publication of this paper.